sy-form-designer 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.umd.cjs ADDED
@@ -0,0 +1,1011 @@
1
+ (function(e,u){typeof exports=="object"&&typeof module<"u"?module.exports=u(require("vue"),require("vuedraggable")):typeof define=="function"&&define.amd?define(["vue","vuedraggable"],u):(e=typeof globalThis<"u"?globalThis:e||self,e["sy-form-designer"]=u(e.Vue,e.draggable))})(this,function(vue,draggable){"use strict";/*! Element Plus Icons Vue v2.3.1 */var arrow_down_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"ArrowDown",__name:"arrow-down",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M831.872 340.864 512 652.672 192.128 340.864a30.592 30.592 0 0 0-42.752 0 29.12 29.12 0 0 0 0 41.6L489.664 714.24a32 32 0 0 0 44.672 0l340.288-331.712a29.12 29.12 0 0 0 0-41.728 30.592 30.592 0 0 0-42.752 0z"})]))}}),arrow_down_default=arrow_down_vue_vue_type_script_setup_true_lang_default,arrow_up_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"ArrowUp",__name:"arrow-up",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"m488.832 344.32-339.84 356.672a32 32 0 0 0 0 44.16l.384.384a29.44 29.44 0 0 0 42.688 0l320-335.872 319.872 335.872a29.44 29.44 0 0 0 42.688 0l.384-.384a32 32 0 0 0 0-44.16L535.168 344.32a32 32 0 0 0-46.336 0"})]))}}),arrow_up_default=arrow_up_vue_vue_type_script_setup_true_lang_default,circle_close_filled_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"CircleCloseFilled",__name:"circle-close-filled",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 393.664L407.936 353.6a38.4 38.4 0 1 0-54.336 54.336L457.664 512 353.6 616.064a38.4 38.4 0 1 0 54.336 54.336L512 566.336 616.064 670.4a38.4 38.4 0 1 0 54.336-54.336L566.336 512 670.4 407.936a38.4 38.4 0 1 0-54.336-54.336z"})]))}}),circle_close_filled_default=circle_close_filled_vue_vue_type_script_setup_true_lang_default,circle_plus_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"CirclePlus",__name:"circle-plus",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M352 480h320a32 32 0 1 1 0 64H352a32 32 0 0 1 0-64"}),vue.createElementVNode("path",{fill:"currentColor",d:"M480 672V352a32 32 0 1 1 64 0v320a32 32 0 0 1-64 0"}),vue.createElementVNode("path",{fill:"currentColor",d:"M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768m0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896"})]))}}),circle_plus_default=circle_plus_vue_vue_type_script_setup_true_lang_default,close_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"Close",__name:"close",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M764.288 214.592 512 466.88 259.712 214.592a31.936 31.936 0 0 0-45.12 45.12L466.752 512 214.528 764.224a31.936 31.936 0 1 0 45.12 45.184L512 557.184l252.288 252.288a31.936 31.936 0 0 0 45.12-45.12L557.12 512.064l252.288-252.352a31.936 31.936 0 1 0-45.12-45.184z"})]))}}),close_default=close_vue_vue_type_script_setup_true_lang_default,delete_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"Delete",__name:"delete",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M160 256H96a32 32 0 0 1 0-64h256V95.936a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32V192h256a32 32 0 1 1 0 64h-64v672a32 32 0 0 1-32 32H192a32 32 0 0 1-32-32zm448-64v-64H416v64zM224 896h576V256H224zm192-128a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32m192 0a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32"})]))}}),delete_default=delete_vue_vue_type_script_setup_true_lang_default,edit_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"Edit",__name:"edit",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M832 512a32 32 0 1 1 64 0v352a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32h352a32 32 0 0 1 0 64H192v640h640z"}),vue.createElementVNode("path",{fill:"currentColor",d:"m469.952 554.24 52.8-7.552L847.104 222.4a32 32 0 1 0-45.248-45.248L477.44 501.44l-7.552 52.8zm422.4-422.4a96 96 0 0 1 0 135.808l-331.84 331.84a32 32 0 0 1-18.112 9.088L436.8 623.68a32 32 0 0 1-36.224-36.224l15.104-105.6a32 32 0 0 1 9.024-18.112l331.904-331.84a96 96 0 0 1 135.744 0z"})]))}}),edit_default=edit_vue_vue_type_script_setup_true_lang_default,info_filled_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"InfoFilled",__name:"info-filled",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896.064A448 448 0 0 1 512 64m67.2 275.072c33.28 0 60.288-23.104 60.288-57.344s-27.072-57.344-60.288-57.344c-33.28 0-60.16 23.104-60.16 57.344s26.88 57.344 60.16 57.344M590.912 699.2c0-6.848 2.368-24.64 1.024-34.752l-52.608 60.544c-10.88 11.456-24.512 19.392-30.912 17.28a12.992 12.992 0 0 1-8.256-14.72l87.68-276.992c7.168-35.136-12.544-67.2-54.336-71.296-44.096 0-108.992 44.736-148.48 101.504 0 6.784-1.28 23.68.064 33.792l52.544-60.608c10.88-11.328 23.552-19.328 29.952-17.152a12.8 12.8 0 0 1 7.808 16.128L388.48 728.576c-10.048 32.256 8.96 63.872 55.04 71.04 67.84 0 107.904-43.648 147.456-100.416z"})]))}}),info_filled_default=info_filled_vue_vue_type_script_setup_true_lang_default,minus_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"Minus",__name:"minus",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M128 544h768a32 32 0 1 0 0-64H128a32 32 0 0 0 0 64"})]))}}),minus_default=minus_vue_vue_type_script_setup_true_lang_default,plus_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"Plus",__name:"plus",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M480 480V128a32 32 0 0 1 64 0v352h352a32 32 0 1 1 0 64H544v352a32 32 0 1 1-64 0V544H128a32 32 0 0 1 0-64z"})]))}}),plus_default=plus_vue_vue_type_script_setup_true_lang_default,search_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"Search",__name:"search",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"m795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704"})]))}}),search_default=search_vue_vue_type_script_setup_true_lang_default,success_filled_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"SuccessFilled",__name:"success-filled",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m-55.808 536.384-99.52-99.584a38.4 38.4 0 1 0-54.336 54.336l126.72 126.72a38.272 38.272 0 0 0 54.336 0l262.4-262.464a38.4 38.4 0 1 0-54.272-54.336z"})]))}}),success_filled_default=success_filled_vue_vue_type_script_setup_true_lang_default,warning_filled_vue_vue_type_script_setup_true_lang_default=vue.defineComponent({name:"WarningFilled",__name:"warning-filled",setup(e){return(u,l)=>(vue.openBlock(),vue.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[vue.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 192a58.432 58.432 0 0 0-58.24 63.744l23.36 256.384a35.072 35.072 0 0 0 69.76 0l23.296-256.384A58.432 58.432 0 0 0 512 256m0 512a51.2 51.2 0 1 0 0-102.4 51.2 51.2 0 0 0 0 102.4"})]))}}),warning_filled_default=warning_filled_vue_vue_type_script_setup_true_lang_default;function registerIcon(e){e.component("el-icon-edit",edit_default),e.component("el-icon-minus",minus_default),e.component("el-icon-plus",plus_default),e.component("el-icon-info",info_filled_default),e.component("el-icon-search",search_default),e.component("el-icon-circle-plus-outline",circle_plus_default),e.component("el-icon-delete",delete_default),e.component("el-icon-arrow-down",arrow_down_default),e.component("el-icon-arrow-up",arrow_up_default)}const panels=Object.assign({"./libs/panels/render.jsx":()=>Promise.resolve().then(()=>render$1),"./libs/panels/settings.vue":()=>Promise.resolve().then(()=>settings),"./libs/panels/widgets.vue":()=>Promise.resolve().then(()=>widgets$1)}),components$1=Object.assign({"./libs/designer.vue":()=>Promise.resolve().then(()=>designer)}),extensions=Object.assign({"./libs/extensions/image-view/index.vue":()=>Promise.resolve().then(()=>index$5),"./libs/extensions/picture-upload/index.vue":()=>Promise.resolve().then(()=>index$3),"./libs/extensions/svg-icon/index.vue":()=>Promise.resolve().then(()=>index$1)}),registerGlobalComponent=e=>{for(const[u,l]of Object.entries(panels)){const d=u.slice(u.lastIndexOf("/")+1,u.lastIndexOf("."));e.component("sy-"+d,vue.defineAsyncComponent(l))}for(const[u,l]of Object.entries(components$1)){const d=u.slice(u.lastIndexOf("/")+1,u.lastIndexOf("."));e.component("sy-"+d,vue.defineAsyncComponent(l))}for(const[u,l]of Object.entries(extensions)){const E=u.match(/\.\/libs\/extensions\/([^/]+)\/index\.vue$/)[1];e.component("sy-"+E,vue.defineAsyncComponent(l))}},install=function(e){install.installed||(install.installed=!0,registerGlobalComponent(e),registerIcon(e))},index$7={install,...components$1},configProviderContextKey=Symbol(),defaultNamespace="el",statePrefix="is-",_bem=(e,u,l,d,E)=>{let b=`${e}-${u}`;return l&&(b+=`-${l}`),d&&(b+=`__${d}`),E&&(b+=`--${E}`),b},namespaceContextKey=Symbol("namespaceContextKey"),useGetDerivedNamespace=e=>{const u=e||(vue.getCurrentInstance()?vue.inject(namespaceContextKey,vue.ref(defaultNamespace)):vue.ref(defaultNamespace));return vue.computed(()=>vue.unref(u)||defaultNamespace)},useNamespace=(e,u)=>{const l=useGetDerivedNamespace(u);return{namespace:l,b:(i="")=>_bem(l.value,e,i,"",""),e:i=>i?_bem(l.value,e,"",i,""):"",m:i=>i?_bem(l.value,e,"","",i):"",be:(i,c)=>i&&c?_bem(l.value,e,i,c,""):"",em:(i,c)=>i&&c?_bem(l.value,e,"",i,c):"",bm:(i,c)=>i&&c?_bem(l.value,e,i,"",c):"",bem:(i,c,h)=>i&&c&&h?_bem(l.value,e,i,c,h):"",is:(i,...c)=>{const h=c.length>=1?c[0]:!0;return i&&h?`${statePrefix}${i}`:""},cssVar:i=>{const c={};for(const h in i)i[h]&&(c[`--${l.value}-${h}`]=i[h]);return c},cssVarName:i=>`--${l.value}-${i}`,cssVarBlock:i=>{const c={};for(const h in i)i[h]&&(c[`--${l.value}-${e}-${h}`]=i[h]);return c},cssVarBlockName:i=>`--${l.value}-${e}-${i}`}};/**
2
+ * @vue/shared v3.5.13
3
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
+ * @license MIT
5
+ **/process.env.NODE_ENV!=="production"&&Object.freeze({}),process.env.NODE_ENV!=="production"&&Object.freeze([]);const hasOwnProperty$6=Object.prototype.hasOwnProperty,hasOwn$1=(e,u)=>hasOwnProperty$6.call(e,u),isFunction$3=e=>typeof e=="function",isString$3=e=>typeof e=="string",isObject$3=e=>e!==null&&typeof e=="object";var freeGlobal=typeof global=="object"&&global&&global.Object===Object&&global,freeSelf=typeof self=="object"&&self&&self.Object===Object&&self,root=freeGlobal||freeSelf||Function("return this")(),Symbol$1=root.Symbol,objectProto$4=Object.prototype,hasOwnProperty$5=objectProto$4.hasOwnProperty,nativeObjectToString$1=objectProto$4.toString,symToStringTag$1=Symbol$1?Symbol$1.toStringTag:void 0;function getRawTag(e){var u=hasOwnProperty$5.call(e,symToStringTag$1),l=e[symToStringTag$1];try{e[symToStringTag$1]=void 0;var d=!0}catch{}var E=nativeObjectToString$1.call(e);return d&&(u?e[symToStringTag$1]=l:delete e[symToStringTag$1]),E}var objectProto$3=Object.prototype,nativeObjectToString=objectProto$3.toString;function objectToString$1(e){return nativeObjectToString.call(e)}var nullTag="[object Null]",undefinedTag="[object Undefined]",symToStringTag=Symbol$1?Symbol$1.toStringTag:void 0;function baseGetTag(e){return e==null?e===void 0?undefinedTag:nullTag:symToStringTag&&symToStringTag in Object(e)?getRawTag(e):objectToString$1(e)}function isObjectLike(e){return e!=null&&typeof e=="object"}var symbolTag="[object Symbol]";function isSymbol(e){return typeof e=="symbol"||isObjectLike(e)&&baseGetTag(e)==symbolTag}function arrayMap(e,u){for(var l=-1,d=e==null?0:e.length,E=Array(d);++l<d;)E[l]=u(e[l],l,e);return E}var isArray$2=Array.isArray,symbolProto=Symbol$1?Symbol$1.prototype:void 0,symbolToString=symbolProto?symbolProto.toString:void 0;function baseToString(e){if(typeof e=="string")return e;if(isArray$2(e))return arrayMap(e,baseToString)+"";if(isSymbol(e))return symbolToString?symbolToString.call(e):"";var u=e+"";return u=="0"&&1/e==-1/0?"-0":u}function isObject$2(e){var u=typeof e;return e!=null&&(u=="object"||u=="function")}var asyncTag="[object AsyncFunction]",funcTag="[object Function]",genTag="[object GeneratorFunction]",proxyTag="[object Proxy]";function isFunction$2(e){if(!isObject$2(e))return!1;var u=baseGetTag(e);return u==funcTag||u==genTag||u==asyncTag||u==proxyTag}var coreJsData=root["__core-js_shared__"],maskSrcKey=function(){var e=/[^.]+$/.exec(coreJsData&&coreJsData.keys&&coreJsData.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function isMasked(e){return!!maskSrcKey&&maskSrcKey in e}var funcProto$1=Function.prototype,funcToString$1=funcProto$1.toString;function toSource(e){if(e!=null){try{return funcToString$1.call(e)}catch{}try{return e+""}catch{}}return""}var reRegExpChar=/[\\^$.*+?()[\]{}|]/g,reIsHostCtor=/^\[object .+?Constructor\]$/,funcProto=Function.prototype,objectProto$2=Object.prototype,funcToString=funcProto.toString,hasOwnProperty$4=objectProto$2.hasOwnProperty,reIsNative=RegExp("^"+funcToString.call(hasOwnProperty$4).replace(reRegExpChar,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function baseIsNative(e){if(!isObject$2(e)||isMasked(e))return!1;var u=isFunction$2(e)?reIsNative:reIsHostCtor;return u.test(toSource(e))}function getValue(e,u){return e==null?void 0:e[u]}function getNative(e,u){var l=getValue(e,u);return baseIsNative(l)?l:void 0}function eq(e,u){return e===u||e!==e&&u!==u}var reIsDeepProp=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,reIsPlainProp=/^\w*$/;function isKey(e,u){if(isArray$2(e))return!1;var l=typeof e;return l=="number"||l=="symbol"||l=="boolean"||e==null||isSymbol(e)?!0:reIsPlainProp.test(e)||!reIsDeepProp.test(e)||u!=null&&e in Object(u)}var nativeCreate=getNative(Object,"create");function hashClear(){this.__data__=nativeCreate?nativeCreate(null):{},this.size=0}function hashDelete(e){var u=this.has(e)&&delete this.__data__[e];return this.size-=u?1:0,u}var HASH_UNDEFINED$1="__lodash_hash_undefined__",objectProto$1=Object.prototype,hasOwnProperty$3=objectProto$1.hasOwnProperty;function hashGet(e){var u=this.__data__;if(nativeCreate){var l=u[e];return l===HASH_UNDEFINED$1?void 0:l}return hasOwnProperty$3.call(u,e)?u[e]:void 0}var objectProto=Object.prototype,hasOwnProperty$2=objectProto.hasOwnProperty;function hashHas(e){var u=this.__data__;return nativeCreate?u[e]!==void 0:hasOwnProperty$2.call(u,e)}var HASH_UNDEFINED="__lodash_hash_undefined__";function hashSet(e,u){var l=this.__data__;return this.size+=this.has(e)?0:1,l[e]=nativeCreate&&u===void 0?HASH_UNDEFINED:u,this}function Hash(e){var u=-1,l=e==null?0:e.length;for(this.clear();++u<l;){var d=e[u];this.set(d[0],d[1])}}Hash.prototype.clear=hashClear,Hash.prototype.delete=hashDelete,Hash.prototype.get=hashGet,Hash.prototype.has=hashHas,Hash.prototype.set=hashSet;function listCacheClear(){this.__data__=[],this.size=0}function assocIndexOf(e,u){for(var l=e.length;l--;)if(eq(e[l][0],u))return l;return-1}var arrayProto=Array.prototype,splice=arrayProto.splice;function listCacheDelete(e){var u=this.__data__,l=assocIndexOf(u,e);if(l<0)return!1;var d=u.length-1;return l==d?u.pop():splice.call(u,l,1),--this.size,!0}function listCacheGet(e){var u=this.__data__,l=assocIndexOf(u,e);return l<0?void 0:u[l][1]}function listCacheHas(e){return assocIndexOf(this.__data__,e)>-1}function listCacheSet(e,u){var l=this.__data__,d=assocIndexOf(l,e);return d<0?(++this.size,l.push([e,u])):l[d][1]=u,this}function ListCache(e){var u=-1,l=e==null?0:e.length;for(this.clear();++u<l;){var d=e[u];this.set(d[0],d[1])}}ListCache.prototype.clear=listCacheClear,ListCache.prototype.delete=listCacheDelete,ListCache.prototype.get=listCacheGet,ListCache.prototype.has=listCacheHas,ListCache.prototype.set=listCacheSet;var Map$1=getNative(root,"Map");function mapCacheClear(){this.size=0,this.__data__={hash:new Hash,map:new(Map$1||ListCache),string:new Hash}}function isKeyable(e){var u=typeof e;return u=="string"||u=="number"||u=="symbol"||u=="boolean"?e!=="__proto__":e===null}function getMapData(e,u){var l=e.__data__;return isKeyable(u)?l[typeof u=="string"?"string":"hash"]:l.map}function mapCacheDelete(e){var u=getMapData(this,e).delete(e);return this.size-=u?1:0,u}function mapCacheGet(e){return getMapData(this,e).get(e)}function mapCacheHas(e){return getMapData(this,e).has(e)}function mapCacheSet(e,u){var l=getMapData(this,e),d=l.size;return l.set(e,u),this.size+=l.size==d?0:1,this}function MapCache(e){var u=-1,l=e==null?0:e.length;for(this.clear();++u<l;){var d=e[u];this.set(d[0],d[1])}}MapCache.prototype.clear=mapCacheClear,MapCache.prototype.delete=mapCacheDelete,MapCache.prototype.get=mapCacheGet,MapCache.prototype.has=mapCacheHas,MapCache.prototype.set=mapCacheSet;var FUNC_ERROR_TEXT="Expected a function";function memoize(e,u){if(typeof e!="function"||u!=null&&typeof u!="function")throw new TypeError(FUNC_ERROR_TEXT);var l=function(){var d=arguments,E=u?u.apply(this,d):d[0],b=l.cache;if(b.has(E))return b.get(E);var C=e.apply(this,d);return l.cache=b.set(E,C)||b,C};return l.cache=new(memoize.Cache||MapCache),l}memoize.Cache=MapCache;var MAX_MEMOIZE_SIZE=500;function memoizeCapped(e){var u=memoize(e,function(d){return l.size===MAX_MEMOIZE_SIZE&&l.clear(),d}),l=u.cache;return u}var rePropName=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,reEscapeChar=/\\(\\)?/g,stringToPath=memoizeCapped(function(e){var u=[];return e.charCodeAt(0)===46&&u.push(""),e.replace(rePropName,function(l,d,E,b){u.push(E?b.replace(reEscapeChar,"$1"):d||l)}),u});function toString$1(e){return e==null?"":baseToString(e)}function castPath(e,u){return isArray$2(e)?e:isKey(e,u)?[e]:stringToPath(toString$1(e))}function toKey(e){if(typeof e=="string"||isSymbol(e))return e;var u=e+"";return u=="0"&&1/e==-1/0?"-0":u}function baseGet(e,u){u=castPath(u,e);for(var l=0,d=u.length;e!=null&&l<d;)e=e[toKey(u[l++])];return l&&l==d?e:void 0}function get(e,u,l){var d=e==null?void 0:baseGet(e,u);return d===void 0?l:d}function fromPairs(e){for(var u=-1,l=e==null?0:e.length,d={};++u<l;){var E=e[u];d[E[0]]=E[1]}return d}const isUndefined$1=e=>e===void 0,isBoolean$2=e=>typeof e=="boolean",isNumber$2=e=>typeof e=="number",isElement=e=>typeof Element>"u"?!1:e instanceof Element,isStringNumber=e=>isString$3(e)?!Number.isNaN(Number(e)):!1;var _a;const isClient=typeof window<"u",isString$2=e=>typeof e=="string",noop$1=()=>{};isClient&&((_a=window==null?void 0:window.navigator)!=null&&_a.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function resolveUnref(e){return typeof e=="function"?e():vue.unref(e)}function identity(e){return e}function tryOnScopeDispose(e){return vue.getCurrentScope()?(vue.onScopeDispose(e),!0):!1}function tryOnMounted(e,u=!0){vue.getCurrentInstance()?vue.onMounted(e):u?e():vue.nextTick(e)}function useTimeoutFn(e,u,l={}){const{immediate:d=!0}=l,E=vue.ref(!1);let b=null;function C(){b&&(clearTimeout(b),b=null)}function A(){E.value=!1,C()}function a(...g){C(),E.value=!0,b=setTimeout(()=>{E.value=!1,b=null,e(...g)},resolveUnref(u))}return d&&(E.value=!0,isClient&&a()),tryOnScopeDispose(A),{isPending:vue.readonly(E),start:a,stop:A}}function unrefElement(e){var u;const l=resolveUnref(e);return(u=l==null?void 0:l.$el)!=null?u:l}const defaultWindow=isClient?window:void 0;function useEventListener(...e){let u,l,d,E;if(isString$2(e[0])||Array.isArray(e[0])?([l,d,E]=e,u=defaultWindow):[u,l,d,E]=e,!u)return noop$1;Array.isArray(l)||(l=[l]),Array.isArray(d)||(d=[d]);const b=[],C=()=>{b.forEach(n=>n()),b.length=0},A=(n,s,o,r)=>(n.addEventListener(s,o,r),()=>n.removeEventListener(s,o,r)),a=vue.watch(()=>[unrefElement(u),resolveUnref(E)],([n,s])=>{C(),n&&b.push(...l.flatMap(o=>d.map(r=>A(n,o,r,s))))},{immediate:!0,flush:"post"}),g=()=>{a(),C()};return tryOnScopeDispose(g),g}function useSupported(e,u=!1){const l=vue.ref(),d=()=>l.value=!!e();return d(),tryOnMounted(d,u),l}const _global$1=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},globalKey="__vueuse_ssr_handlers__";_global$1[globalKey]=_global$1[globalKey]||{};var __getOwnPropSymbols$g=Object.getOwnPropertySymbols,__hasOwnProp$g=Object.prototype.hasOwnProperty,__propIsEnum$g=Object.prototype.propertyIsEnumerable,__objRest$2=(e,u)=>{var l={};for(var d in e)__hasOwnProp$g.call(e,d)&&u.indexOf(d)<0&&(l[d]=e[d]);if(e!=null&&__getOwnPropSymbols$g)for(var d of __getOwnPropSymbols$g(e))u.indexOf(d)<0&&__propIsEnum$g.call(e,d)&&(l[d]=e[d]);return l};function useResizeObserver(e,u,l={}){const d=l,{window:E=defaultWindow}=d,b=__objRest$2(d,["window"]);let C;const A=useSupported(()=>E&&"ResizeObserver"in E),a=()=>{C&&(C.disconnect(),C=void 0)},g=vue.watch(()=>unrefElement(e),s=>{a(),A.value&&E&&s&&(C=new ResizeObserver(u),C.observe(s,b))},{immediate:!0,flush:"post"}),n=()=>{a(),g()};return tryOnScopeDispose(n),{isSupported:A,stop:n}}var SwipeDirection;(function(e){e.UP="UP",e.RIGHT="RIGHT",e.DOWN="DOWN",e.LEFT="LEFT",e.NONE="NONE"})(SwipeDirection||(SwipeDirection={}));var __defProp=Object.defineProperty,__getOwnPropSymbols=Object.getOwnPropertySymbols,__hasOwnProp=Object.prototype.hasOwnProperty,__propIsEnum=Object.prototype.propertyIsEnumerable,__defNormalProp=(e,u,l)=>u in e?__defProp(e,u,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[u]=l,__spreadValues=(e,u)=>{for(var l in u||(u={}))__hasOwnProp.call(u,l)&&__defNormalProp(e,l,u[l]);if(__getOwnPropSymbols)for(var l of __getOwnPropSymbols(u))__propIsEnum.call(u,l)&&__defNormalProp(e,l,u[l]);return e};const _TransitionPresets={easeInSine:[.12,0,.39,0],easeOutSine:[.61,1,.88,1],easeInOutSine:[.37,0,.63,1],easeInQuad:[.11,0,.5,0],easeOutQuad:[.5,1,.89,1],easeInOutQuad:[.45,0,.55,1],easeInCubic:[.32,0,.67,0],easeOutCubic:[.33,1,.68,1],easeInOutCubic:[.65,0,.35,1],easeInQuart:[.5,0,.75,0],easeOutQuart:[.25,1,.5,1],easeInOutQuart:[.76,0,.24,1],easeInQuint:[.64,0,.78,0],easeOutQuint:[.22,1,.36,1],easeInOutQuint:[.83,0,.17,1],easeInExpo:[.7,0,.84,0],easeOutExpo:[.16,1,.3,1],easeInOutExpo:[.87,0,.13,1],easeInCirc:[.55,0,1,.45],easeOutCirc:[0,.55,.45,1],easeInOutCirc:[.85,0,.15,1],easeInBack:[.36,0,.66,-.56],easeOutBack:[.34,1.56,.64,1],easeInOutBack:[.68,-.6,.32,1.6]};__spreadValues({linear:identity},_TransitionPresets);class ElementPlusError extends Error{constructor(u){super(u),this.name="ElementPlusError"}}function debugWarn(e,u){if(process.env.NODE_ENV!=="production"){const l=isString$3(e)?new ElementPlusError(`[${e}] ${u}`):e;console.warn(l)}}const initial={current:0},zIndex=vue.ref(0),defaultInitialZIndex=2e3,ZINDEX_INJECTION_KEY=Symbol("elZIndexContextKey"),zIndexContextKey=Symbol("zIndexContextKey"),useZIndex=e=>{const u=vue.getCurrentInstance()?vue.inject(ZINDEX_INJECTION_KEY,initial):initial,l=e||(vue.getCurrentInstance()?vue.inject(zIndexContextKey,void 0):void 0),d=vue.computed(()=>{const C=vue.unref(l);return isNumber$2(C)?C:defaultInitialZIndex}),E=vue.computed(()=>d.value+zIndex.value),b=()=>(u.current++,zIndex.value=u.current,E.value);return!isClient&&!vue.inject(ZINDEX_INJECTION_KEY)&&debugWarn("ZIndexInjection",`Looks like you are using server rendering, you must provide a z-index provider to ensure the hydration process to be succeed
6
+ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`),{initialZIndex:d,currentZIndex:E,nextZIndex:b}};var English={name:"en",el:{breadcrumb:{label:"Breadcrumb"},colorpicker:{confirm:"OK",clear:"Clear",defaultLabel:"color picker",description:"current color is {color}. press enter to select a new color.",alphaLabel:"pick alpha value"},datepicker:{now:"Now",today:"Today",cancel:"Cancel",clear:"Clear",confirm:"OK",dateTablePrompt:"Use the arrow keys and enter to select the day of the month",monthTablePrompt:"Use the arrow keys and enter to select the month",yearTablePrompt:"Use the arrow keys and enter to select the year",selectedDate:"Selected date",selectDate:"Select date",selectTime:"Select time",startDate:"Start Date",startTime:"Start Time",endDate:"End Date",endTime:"End Time",prevYear:"Previous Year",nextYear:"Next Year",prevMonth:"Previous Month",nextMonth:"Next Month",year:"",month1:"January",month2:"February",month3:"March",month4:"April",month5:"May",month6:"June",month7:"July",month8:"August",month9:"September",month10:"October",month11:"November",month12:"December",week:"week",weeks:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},weeksFull:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"},months:{jan:"Jan",feb:"Feb",mar:"Mar",apr:"Apr",may:"May",jun:"Jun",jul:"Jul",aug:"Aug",sep:"Sep",oct:"Oct",nov:"Nov",dec:"Dec"}},inputNumber:{decrease:"decrease number",increase:"increase number"},select:{loading:"Loading",noMatch:"No matching data",noData:"No data",placeholder:"Select"},mention:{loading:"Loading"},dropdown:{toggleDropdown:"Toggle Dropdown"},cascader:{noMatch:"No matching data",loading:"Loading",placeholder:"Select",noData:"No data"},pagination:{goto:"Go to",pagesize:"/page",total:"Total {total}",pageClassifier:"",page:"Page",prev:"Go to previous page",next:"Go to next page",currentPage:"page {pager}",prevPages:"Previous {pager} pages",nextPages:"Next {pager} pages",deprecationWarning:"Deprecated usages detected, please refer to the el-pagination documentation for more details"},dialog:{close:"Close this dialog"},drawer:{close:"Close this dialog"},messagebox:{title:"Message",confirm:"OK",cancel:"Cancel",error:"Illegal input",close:"Close this dialog"},upload:{deleteTip:"press delete to remove",delete:"Delete",preview:"Preview",continue:"Continue"},slider:{defaultLabel:"slider between {min} and {max}",defaultRangeStartLabel:"pick start value",defaultRangeEndLabel:"pick end value"},table:{emptyText:"No Data",confirmFilter:"Confirm",resetFilter:"Reset",clearFilter:"All",sumText:"Sum"},tour:{next:"Next",previous:"Previous",finish:"Finish"},tree:{emptyText:"No Data"},transfer:{noMatch:"No matching data",noData:"No data",titles:["List 1","List 2"],filterPlaceholder:"Enter keyword",noCheckedFormat:"{total} items",hasCheckedFormat:"{checked}/{total} checked"},image:{error:"FAILED"},pageHeader:{title:"Back"},popconfirm:{confirmButtonText:"Yes",cancelButtonText:"No"},carousel:{leftArrow:"Carousel arrow left",rightArrow:"Carousel arrow right",indicator:"Carousel switch to index {index}"}}};const buildTranslator=e=>(u,l)=>translate$1(u,l,vue.unref(e)),translate$1=(e,u,l)=>get(l,e,e).replace(/\{(\w+)\}/g,(d,E)=>{var b;return`${(b=u==null?void 0:u[E])!=null?b:`{${E}}`}`}),buildLocaleContext=e=>{const u=vue.computed(()=>vue.unref(e).name),l=vue.isRef(e)?e:vue.ref(e);return{lang:u,locale:l,t:buildTranslator(e)}},localeContextKey=Symbol("localeContextKey"),useLocale=e=>{const u=e||vue.inject(localeContextKey,vue.ref());return buildLocaleContext(vue.computed(()=>u.value||English))},epPropKey="__epPropKey",definePropType=e=>e,isEpProp=e=>isObject$3(e)&&!!e[epPropKey],buildProp=(e,u)=>{if(!isObject$3(e)||isEpProp(e))return e;const{values:l,required:d,default:E,type:b,validator:C}=e,a={type:b,required:!!d,validator:l||C?g=>{let n=!1,s=[];if(l&&(s=Array.from(l),hasOwn$1(e,"default")&&s.push(E),n||(n=s.includes(g))),C&&(n||(n=C(g))),!n&&s.length>0){const o=[...new Set(s)].map(r=>JSON.stringify(r)).join(", ");vue.warn(`Invalid prop: validation failed${u?` for prop "${u}"`:""}. Expected one of [${o}], got value ${JSON.stringify(g)}.`)}return n}:void 0,[epPropKey]:!0};return hasOwn$1(e,"default")&&(a.default=E),a},buildProps=e=>fromPairs(Object.entries(e).map(([u,l])=>[u,buildProp(l,u)])),componentSizes=["","default","small","large"],useSizeProp=buildProp({type:String,values:componentSizes,required:!1}),SIZE_INJECTION_KEY=Symbol("size"),emptyValuesContextKey=Symbol("emptyValuesContextKey"),useEmptyValuesProps=buildProps({emptyValues:Array,valueOnClear:{type:[String,Number,Boolean,Function],default:void 0,validator:e=>isFunction$3(e)?!e():!e}}),keysOf=e=>Object.keys(e),globalConfig=vue.ref();function useGlobalConfig(e,u=void 0){return vue.getCurrentInstance()?vue.inject(configProviderContextKey,globalConfig):globalConfig}function useGlobalComponentSettings(e,u){const l=useGlobalConfig(),d=useNamespace(e,vue.computed(()=>{var A;return((A=l.value)==null?void 0:A.namespace)||defaultNamespace})),E=useLocale(vue.computed(()=>{var A;return(A=l.value)==null?void 0:A.locale})),b=useZIndex(vue.computed(()=>{var A;return((A=l.value)==null?void 0:A.zIndex)||defaultInitialZIndex})),C=vue.computed(()=>{var A;return vue.unref(u)||((A=l.value)==null?void 0:A.size)||""});return provideGlobalConfig(vue.computed(()=>vue.unref(l)||{})),{ns:d,locale:E,zIndex:b,size:C}}const provideGlobalConfig=(e,u,l=!1)=>{var d;const E=!!vue.getCurrentInstance(),b=E?useGlobalConfig():void 0,C=(d=void 0)!=null?d:E?vue.provide:void 0;if(!C){debugWarn("provideGlobalConfig","provideGlobalConfig() can only be used inside setup().");return}const A=vue.computed(()=>{const a=vue.unref(e);return b!=null&&b.value?mergeConfig$2(b.value,a):a});return C(configProviderContextKey,A),C(localeContextKey,vue.computed(()=>A.value.locale)),C(namespaceContextKey,vue.computed(()=>A.value.namespace)),C(zIndexContextKey,vue.computed(()=>A.value.zIndex)),C(SIZE_INJECTION_KEY,{size:vue.computed(()=>A.value.size||"")}),C(emptyValuesContextKey,vue.computed(()=>({emptyValues:A.value.emptyValues,valueOnClear:A.value.valueOnClear}))),(l||!globalConfig.value)&&(globalConfig.value=A.value),A},mergeConfig$2=(e,u)=>{const l=[...new Set([...keysOf(e),...keysOf(u)])],d={};for(const E of l)d[E]=u[E]!==void 0?u[E]:e[E];return d};var _export_sfc$1=(e,u)=>{const l=e.__vccOpts||e;for(const[d,E]of u)l[d]=E;return l};const SCOPE="utils/dom/style";function addUnit(e,u="px"){if(!e)return"";if(isNumber$2(e)||isStringNumber(e))return`${e}${u}`;if(isString$3(e))return e;debugWarn(SCOPE,"binding value must be a string or number")}const withInstall=(e,u)=>(e.install=l=>{for(const d of[e,...Object.values({})])l.component(d.name,d)},e),withInstallFunction=(e,u)=>(e.install=l=>{e._context=l._context,l.config.globalProperties[u]=e},e),iconProps=buildProps({size:{type:definePropType([Number,String])},color:{type:String}}),__default__$2=vue.defineComponent({name:"ElIcon",inheritAttrs:!1}),_sfc_main$a=vue.defineComponent({...__default__$2,props:iconProps,setup(e){const u=e,l=useNamespace("icon"),d=vue.computed(()=>{const{size:E,color:b}=u;return!E&&!b?{}:{fontSize:isUndefined$1(E)?void 0:addUnit(E),"--color":b}});return(E,b)=>(vue.openBlock(),vue.createElementBlock("i",vue.mergeProps({class:vue.unref(l).b(),style:vue.unref(d)},E.$attrs),[vue.renderSlot(E.$slots,"default")],16))}});var Icon=_export_sfc$1(_sfc_main$a,[["__file","icon.vue"]]);const ElIcon=withInstall(Icon),iconPropType=definePropType([String,Object,Function]),TypeComponents={Close:close_default},TypeComponentsMap={success:success_filled_default,warning:warning_filled_default,error:circle_close_filled_default,info:info_filled_default},mutable=e=>e,EVENT_CODE={esc:"Escape"},badgeProps=buildProps({value:{type:[String,Number],default:""},max:{type:Number,default:99},isDot:Boolean,hidden:Boolean,type:{type:String,values:["primary","success","warning","info","danger"],default:"danger"},showZero:{type:Boolean,default:!0},color:String,badgeStyle:{type:definePropType([String,Object,Array])},offset:{type:definePropType(Array),default:[0,0]},badgeClass:{type:String}}),__default__$1=vue.defineComponent({name:"ElBadge"}),_sfc_main$9=vue.defineComponent({...__default__$1,props:badgeProps,setup(e,{expose:u}){const l=e,d=useNamespace("badge"),E=vue.computed(()=>l.isDot?"":isNumber$2(l.value)&&isNumber$2(l.max)?l.max<l.value?`${l.max}+`:`${l.value}`:`${l.value}`),b=vue.computed(()=>{var C,A,a,g,n;return[{backgroundColor:l.color,marginRight:addUnit(-((A=(C=l.offset)==null?void 0:C[0])!=null?A:0)),marginTop:addUnit((g=(a=l.offset)==null?void 0:a[1])!=null?g:0)},(n=l.badgeStyle)!=null?n:{}]});return u({content:E}),(C,A)=>(vue.openBlock(),vue.createElementBlock("div",{class:vue.normalizeClass(vue.unref(d).b())},[vue.renderSlot(C.$slots,"default"),vue.createVNode(vue.Transition,{name:`${vue.unref(d).namespace.value}-zoom-in-center`,persisted:""},{default:vue.withCtx(()=>[vue.withDirectives(vue.createElementVNode("sup",{class:vue.normalizeClass([vue.unref(d).e("content"),vue.unref(d).em("content",C.type),vue.unref(d).is("fixed",!!C.$slots.default),vue.unref(d).is("dot",C.isDot),vue.unref(d).is("hide-zero",!C.showZero&&l.value===0),C.badgeClass]),style:vue.normalizeStyle(vue.unref(b))},[vue.renderSlot(C.$slots,"content",{value:vue.unref(E)},()=>[vue.createTextVNode(vue.toDisplayString(vue.unref(E)),1)])],6),[[vue.vShow,!C.hidden&&(vue.unref(E)||C.isDot||C.$slots.content)]])]),_:3},8,["name"])],2))}});var Badge=_export_sfc$1(_sfc_main$9,[["__file","badge.vue"]]);const ElBadge=withInstall(Badge);function getDefaultExportFromCjs(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}const configProviderProps=buildProps({a11y:{type:Boolean,default:!0},locale:{type:definePropType(Object)},size:useSizeProp,button:{type:definePropType(Object)},experimentalFeatures:{type:definePropType(Object)},keyboardNavigation:{type:Boolean,default:!0},message:{type:definePropType(Object)},zIndex:Number,namespace:{type:String,default:"el"},...useEmptyValuesProps}),messageConfig={};vue.defineComponent({name:"ElConfigProvider",props:configProviderProps,setup(e,{slots:u}){vue.watch(()=>e.message,d=>{Object.assign(messageConfig,d??{})},{immediate:!0,deep:!0});const l=provideGlobalConfig(e);return()=>vue.renderSlot(u,"default",{config:l==null?void 0:l.value})}});const messageTypes=["success","info","warning","error"],messageDefaults=mutable({customClass:"",center:!1,dangerouslyUseHTMLString:!1,duration:3e3,icon:void 0,id:"",message:"",onClose:void 0,showClose:!1,type:"info",plain:!1,offset:16,zIndex:0,grouping:!1,repeatNum:1,appendTo:isClient?document.body:void 0}),messageProps=buildProps({customClass:{type:String,default:messageDefaults.customClass},center:{type:Boolean,default:messageDefaults.center},dangerouslyUseHTMLString:{type:Boolean,default:messageDefaults.dangerouslyUseHTMLString},duration:{type:Number,default:messageDefaults.duration},icon:{type:iconPropType,default:messageDefaults.icon},id:{type:String,default:messageDefaults.id},message:{type:definePropType([String,Object,Function]),default:messageDefaults.message},onClose:{type:definePropType(Function),default:messageDefaults.onClose},showClose:{type:Boolean,default:messageDefaults.showClose},type:{type:String,values:messageTypes,default:messageDefaults.type},plain:{type:Boolean,default:messageDefaults.plain},offset:{type:Number,default:messageDefaults.offset},zIndex:{type:Number,default:messageDefaults.zIndex},grouping:{type:Boolean,default:messageDefaults.grouping},repeatNum:{type:Number,default:messageDefaults.repeatNum}}),messageEmits={destroy:()=>!0},instances=vue.shallowReactive([]),getInstance=e=>{const u=instances.findIndex(E=>E.id===e),l=instances[u];let d;return u>0&&(d=instances[u-1]),{current:l,prev:d}},getLastOffset=e=>{const{prev:u}=getInstance(e);return u?u.vm.exposed.bottom.value:0},getOffsetOrSpace=(e,u)=>instances.findIndex(d=>d.id===e)>0?16:u,__default__=vue.defineComponent({name:"ElMessage"}),_sfc_main$8=vue.defineComponent({...__default__,props:messageProps,emits:messageEmits,setup(e,{expose:u}){const l=e,{Close:d}=TypeComponents,{ns:E,zIndex:b}=useGlobalComponentSettings("message"),{currentZIndex:C,nextZIndex:A}=b,a=vue.ref(),g=vue.ref(!1),n=vue.ref(0);let s;const o=vue.computed(()=>l.type?l.type==="error"?"danger":l.type:"info"),r=vue.computed(()=>{const $=l.type;return{[E.bm("icon",$)]:$&&TypeComponentsMap[$]}}),t=vue.computed(()=>l.icon||TypeComponentsMap[l.type]||""),i=vue.computed(()=>getLastOffset(l.id)),c=vue.computed(()=>getOffsetOrSpace(l.id,l.offset)+i.value),h=vue.computed(()=>n.value+c.value),f=vue.computed(()=>({top:`${c.value}px`,zIndex:C.value}));function v(){l.duration!==0&&({stop:s}=useTimeoutFn(()=>{y()},l.duration))}function p(){s==null||s()}function y(){g.value=!1}function m({code:$}){$===EVENT_CODE.esc&&y()}return vue.onMounted(()=>{v(),A(),g.value=!0}),vue.watch(()=>l.repeatNum,()=>{p(),v()}),useEventListener(document,"keydown",m),useResizeObserver(a,()=>{n.value=a.value.getBoundingClientRect().height}),u({visible:g,bottom:h,close:y}),($,N)=>(vue.openBlock(),vue.createBlock(vue.Transition,{name:vue.unref(E).b("fade"),onBeforeLeave:$.onClose,onAfterLeave:M=>$.$emit("destroy"),persisted:""},{default:vue.withCtx(()=>[vue.withDirectives(vue.createElementVNode("div",{id:$.id,ref_key:"messageRef",ref:a,class:vue.normalizeClass([vue.unref(E).b(),{[vue.unref(E).m($.type)]:$.type},vue.unref(E).is("center",$.center),vue.unref(E).is("closable",$.showClose),vue.unref(E).is("plain",$.plain),$.customClass]),style:vue.normalizeStyle(vue.unref(f)),role:"alert",onMouseenter:p,onMouseleave:v},[$.repeatNum>1?(vue.openBlock(),vue.createBlock(vue.unref(ElBadge),{key:0,value:$.repeatNum,type:vue.unref(o),class:vue.normalizeClass(vue.unref(E).e("badge"))},null,8,["value","type","class"])):vue.createCommentVNode("v-if",!0),vue.unref(t)?(vue.openBlock(),vue.createBlock(vue.unref(ElIcon),{key:1,class:vue.normalizeClass([vue.unref(E).e("icon"),vue.unref(r)])},{default:vue.withCtx(()=>[(vue.openBlock(),vue.createBlock(vue.resolveDynamicComponent(vue.unref(t))))]),_:1},8,["class"])):vue.createCommentVNode("v-if",!0),vue.renderSlot($.$slots,"default",{},()=>[$.dangerouslyUseHTMLString?(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:1},[vue.createCommentVNode(" Caution here, message could've been compromised, never use user's input as message "),vue.createElementVNode("p",{class:vue.normalizeClass(vue.unref(E).e("content")),innerHTML:$.message},null,10,["innerHTML"])],2112)):(vue.openBlock(),vue.createElementBlock("p",{key:0,class:vue.normalizeClass(vue.unref(E).e("content"))},vue.toDisplayString($.message),3))]),$.showClose?(vue.openBlock(),vue.createBlock(vue.unref(ElIcon),{key:2,class:vue.normalizeClass(vue.unref(E).e("closeBtn")),onClick:vue.withModifiers(y,["stop"])},{default:vue.withCtx(()=>[vue.createVNode(vue.unref(d))]),_:1},8,["class","onClick"])):vue.createCommentVNode("v-if",!0)],46,["id"]),[[vue.vShow,g.value]])]),_:3},8,["name","onBeforeLeave","onAfterLeave"]))}});var MessageConstructor=_export_sfc$1(_sfc_main$8,[["__file","message.vue"]]);let seed=1;const normalizeOptions=e=>{const u=!e||isString$3(e)||vue.isVNode(e)||isFunction$3(e)?{message:e}:e,l={...messageDefaults,...u};if(!l.appendTo)l.appendTo=document.body;else if(isString$3(l.appendTo)){let d=document.querySelector(l.appendTo);isElement(d)||(debugWarn("ElMessage","the appendTo option is not an HTMLElement. Falling back to document.body."),d=document.body),l.appendTo=d}return isBoolean$2(messageConfig.grouping)&&!l.grouping&&(l.grouping=messageConfig.grouping),isNumber$2(messageConfig.duration)&&l.duration===3e3&&(l.duration=messageConfig.duration),isNumber$2(messageConfig.offset)&&l.offset===16&&(l.offset=messageConfig.offset),isBoolean$2(messageConfig.showClose)&&!l.showClose&&(l.showClose=messageConfig.showClose),l},closeMessage=e=>{const u=instances.indexOf(e);if(u===-1)return;instances.splice(u,1);const{handler:l}=e;l.close()},createMessage=({appendTo:e,...u},l)=>{const d=`message_${seed++}`,E=u.onClose,b=document.createElement("div"),C={...u,id:d,onClose:()=>{E==null||E(),closeMessage(n)},onDestroy:()=>{vue.render(null,b)}},A=vue.createVNode(MessageConstructor,C,isFunction$3(C.message)||vue.isVNode(C.message)?{default:isFunction$3(C.message)?C.message:()=>C.message}:null);A.appContext=l||message._context,vue.render(A,b),e.appendChild(b.firstElementChild);const a=A.component,n={id:d,vnode:A,vm:a,handler:{close:()=>{a.exposed.visible.value=!1}},props:A.component.props};return n},message=(e={},u)=>{if(!isClient)return{close:()=>{}};const l=normalizeOptions(e);if(l.grouping&&instances.length){const E=instances.find(({vnode:b})=>{var C;return((C=b.props)==null?void 0:C.message)===l.message});if(E)return E.props.repeatNum+=1,E.props.type=l.type,E.handler}if(isNumber$2(messageConfig.max)&&instances.length>=messageConfig.max)return{close:()=>{}};const d=createMessage(l,u);return instances.push(d),d.handler};messageTypes.forEach(e=>{message[e]=(u={},l)=>{const d=normalizeOptions(u);return message({...d,type:e},l)}});function closeAll(e){for(const u of instances)(!e||e===u.props.type)&&u.handler.close()}message.closeAll=closeAll,message._context=null;const ElMessage=withInstallFunction(message,"$message");function isNull(e){return e==null}const getRegExp=function(e){return{number:"/^[-]?\\d+(\\.\\d+)?$/",letter:"/^[A-Za-z]+$/",letterAndNumber:"/^[A-Za-z0-9]+$/",mobilePhone:"/^[1][3-9][0-9]{9}$/",letterStartNumberIncluded:"/^[A-Za-z]+[A-Za-z\\d]*$/",noChinese:"/^[^一-龥]+$/",chinese:"/^[一-龥]+$/",email:"/^([-_A-Za-z0-9.]+)@([_A-Za-z0-9]+\\.)+[A-Za-z0-9]{2,3}$/",url:"/^([hH][tT]{2}[pP]:\\/\\/|[hH][tT]{2}[pP][sS]:\\/\\/)(([A-Za-z0-9-~]+)\\.)+([A-Za-z0-9-~\\/])+$/"}[e]},validateFn=function(validatorName,rule,value,callback,defaultErrorMsg){if(isNull(value)||value.length<=0){callback();return}const reg=eval(getRegExp(validatorName));if(reg.test(value))callback();else{let e=rule.errorMsg||defaultErrorMsg;callback(new Error(e))}},FormValidators={number(e,u,l){validateFn("number",e,u,l,"["+e.label+"]包含非数字字符")},letter(e,u,l){validateFn("letter",e,u,l,"["+e.label+"]包含非字母字符")},letterAndNumber(e,u,l){validateFn("letterAndNumber",e,u,l,"["+e.label+"]只能输入字母或数字")},mobilePhone(e,u,l){validateFn("mobilePhone",e,u,l,"["+e.label+"]手机号码格式有误")},noBlankStart(e,u,l){},noBlankEnd(e,u,l){},letterStartNumberIncluded(e,u,l){validateFn("letterStartNumberIncluded",e,u,l,"["+e.label+"]必须以字母开头,可包含数字")},noChinese(e,u,l){validateFn("noChinese",e,u,l,"["+e.label+"]不可输入中文字符")},chinese(e,u,l){validateFn("chinese",e,u,l,"["+e.label+"]只能输入中文字符")},email(e,u,l){validateFn("email",e,u,l,"["+e.label+"]邮箱格式有误")},url(e,u,l){validateFn("url",e,u,l,"["+e.label+"]URL格式有误")},regExp(rule,value,callback){if(isNull(value)||value.length<=0){callback();return}const pattern=eval(rule.regExp);if(pattern.test(value))callback();else{let e=rule.errorMsg||"["+rule.label+"]invalid value";callback(new Error(e))}}},fieldOptionMixin={inject:["refDict"],methods:{getWidgets:function(){return this.refDict}}};function useFieldMixin(e,u){const l=vue.inject("refDict"),d=vue.ref([]),E=()=>{l==null||!e.options.name||(l.value[e.options.name]=u)},b=()=>{if(e.options.onCreated)try{new Function(e.options.onCreated).call(u)}catch(s){console.error(s)}},C=()=>{if(e.options.onMounted)try{new Function(e.options.onMounted).call(u)}catch(s){console.error(s)}},A=s=>{e.options.onChange&&new Function("value","oldValue",e.options.onChange).call(u,s)};return{registerRef:E,handleOnCreated:b,handleOnMounted:C,handleOnChange:s=>{A(s)},removeRef:s=>{delete l.value[s]},rebuildRules:()=>{if(e.formItemFlag&&(e.options.required&&d.value.push({required:!0,trigger:["blur"],message:e.options.requiredHint||"必须填写"}),e.options.validation)){let s=e.options.validation;FormValidators[s]?d.value.push({validator:FormValidators[s],trigger:["blur","change"],label:e.options.label,errorMsg:e.options.validationHint}):d.value.push({validator:FormValidators.regExp,trigger:["blur","change"],regExp:s,label:e.options.label,errorMsg:e.options.validationHint})}},rules:d}}function _isSlot(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!vue.isVNode(e)}const render=vue.defineComponent({components:{},props:{conf:{type:Object,default:()=>{}},mode:{type:String,default:()=>"edit"},active:{type:Object,default:null},formData:{type:Object,default:{}}},emits:["update:active","setting"],setup(e,u){const l=vue.getCurrentInstance().proxy,d=vue.ref({}),E=vue.ref(e),b=vue.ref([]);let C=vue.ref(e.active);vue.watch(()=>C.value,S=>{u.emit("update:active",S)});const A=(S,O)=>{e.mode==="edit"&&(S.stopPropagation(),C.value=O)},a=S=>{const O=[];return S.widgetList&&S.widgetList.length&&S.widgetList.forEach(x=>{O.push(s({conf:x,parent:S}))}),O},g=vue.defineComponent({props:["conf","mode","rules"],setup(S,{slots:O}){const x=vue.computed(()=>C.value&&C.value.id===S.conf.id);return()=>{let L,I;return vue.createVNode(vue.Fragment,null,[S.mode==="edit"&&vue.createVNode(vue.resolveComponent("el-form-item"),{rules:S.rules,label:S.conf.options.labelHidden?" ":S.conf.options.label,"label-width":S.conf.options.labelWidth,class:`${x.value&&"selected"||""} ${S.conf.options.labelHidden?"hidden-label":""} ${S.conf.options.labelAlign}`,onClick:w=>{A(w,S.conf)},required:S.conf.options.required},_isSlot(L=O.default())?L:{default:()=>[L]}),S.mode==="view"&&(!S.conf.options.hidden||M(S.conf))&&vue.createVNode(vue.resolveComponent("el-form-item"),{rules:S.rules,prop:S.conf.options.name,label:S.conf.options.labelHidden?" ":S.conf.options.label,"label-width":S.conf.options.labelHidden?"0px":S.conf.options.labelWidth,class:` ${S.conf.options.labelHidden?"hidden-label":""} ${S.conf.options.labelAlign}`,required:S.conf.options.required},_isSlot(I=O.default())?I:{default:()=>[I]})])}}}),n=vue.defineComponent({props:{self:{type:Object},parent:{type:Object},childrenKey:{type:String,default:()=>"widgetList"}},setup(S){const O=S.parent[S.childrenKey],x=_=>{A(_,S.parent)},L=_=>{_.stopPropagation(),O&&O.splice(O.indexOf(S.self),1)},I=_=>{if(_.stopPropagation(),O){let T=O.indexOf(S.self);if(T==0){ElMessage("已经是第一个了");return}let k=O.splice(T,1)[0];O.splice(T-1,0,k)}},w=_=>{if(_.stopPropagation(),O){let T=O.indexOf(S.self);if(T==O.length-1){ElMessage("已经是最后一个了");return}let k=O.splice(T,1)[0];O.splice(T+1,0,k)}};return()=>vue.createVNode("div",null,[vue.createVNode("i",{title:"选中父组件"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true",onClick:x},[vue.createVNode("use",{"xlink:href":"#icon-el-back"},null)])]),vue.createVNode("i",{title:"上移组件"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true",onClick:I},[vue.createVNode("use",{"xlink:href":"#icon-el-move-up"},null)])]),vue.createVNode("i",{title:"下移组件"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true",onClick:w},[vue.createVNode("use",{"xlink:href":"#icon-el-move-down"},null)])]),vue.createVNode("i",{title:"配置组件"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true"},[vue.createVNode("use",{"xlink:href":"#icon-el-set-up"},null)])]),vue.createVNode("i",{title:"移除组件"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true",onClick:L},[vue.createVNode("use",{"xlink:href":"#icon-el-delete"},null)])])])}}),s=({conf:S,parent:O})=>{let x="",L=null;const I=vue.computed(()=>C.value&&C.value.id===S.id);if(S.category=="container"?x="container-wrapper":x="field-wrapper",S.type=="grid"){const w=vue.defineComponent({props:["conf","active"],setup(T){const k=vue.computed(()=>T.active&&T.active.id===T.conf.id),R={item:({element:B,index:F})=>vue.createVNode("div",{className:"transition-group-el"},[vue.createTextVNode(" "),vue.h(s,{conf:B,parent:T.conf})])},D=B=>{C.value=T.conf.widgetList[B.newIndex]},V=()=>{};return()=>vue.createVNode(vue.resolveComponent("el-col"),{class:`grid-cell ${k.value&&"selected"||""}`,span:T.conf.options.span},{default:()=>{var B;return[E.value.mode=="edit"&&vue.createVNode(draggable,{tag:"div",class:"form-widget-list","item-key":"id",modelValue:T.conf.widgetList,"onUpdate:modelValue":F=>T.conf.widgetList=F,group:"people",ghostClass:"ghost",animation:200,handle:".drag-handler",onEnd:V,onAdd:D},R),E.value.mode=="view"&&vue.createVNode(vue.Fragment,null,[(B=T.conf.widgetList)==null?void 0:B.map(F=>vue.h(s,{conf:F,parent:T.conf}))]),k.value&&vue.createVNode(n,{className:"grid-col-action",self:T.conf,parent:S,childrenKey:"cols"},null),k.value&&vue.createVNode("div",{className:"grid-col-handler"},[vue.createVNode("i",null,[vue.createTextVNode("栅格列")])])]}})}}),_=vue.defineComponent({props:["conf"],setup(T){return()=>{let k,R;return vue.createVNode("div",{class:[x].join(" ")},[E.value.mode=="edit"&&vue.createVNode(vue.resolveComponent("el-row"),{class:`grid-container ${I.value?"selected":""}`,gutter:S.options.gutter},_isSlot(k=T.conf.cols.map(D=>vue.createVNode(w,{id:D.id,conf:D,active:C.value,onClick:V=>A(V,D)},null)))?k:{default:()=>[k]}),E.value.mode=="view"&&(!T.conf.options.hidden||M(T.conf))&&vue.createVNode(vue.resolveComponent("el-row"),{class:"grid-container",gutter:S.options.gutter},_isSlot(R=T.conf.cols.map(D=>vue.createVNode(vue.Fragment,null,[(!D.options.hidden||M(D))&&vue.createVNode(w,{id:D.id,conf:D},null)])))?R:{default:()=>[R]}),I.value&&vue.createVNode(n,{class:"container-action",self:T.conf,parent:O},null),I.value&&vue.createVNode("div",{className:"drag-handler"},[vue.createVNode("i",{title:"拖拽手柄"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true"},[vue.createVNode("use",{"xlink:href":"#icon-el-drag-move"},null)])]),vue.createVNode("i",null,[vue.createTextVNode("栅格")])])])}}});L=T=>vue.createVNode(_,{id:T.id,conf:T,onClick:k=>A(k,T)},null)}else if(S.type=="input"){const w=vue.defineComponent({inject:["render"],mixins:[fieldOptionMixin],props:["conf"],setup(T){const k=vue.getCurrentInstance().proxy,R=useFieldMixin(S,k);return R.registerRef(),R.rebuildRules(),R.handleOnCreated(),vue.onMounted(()=>{R.handleOnMounted()}),()=>vue.createVNode("div",{className:x},[vue.createVNode(g,{rules:R.rules.value,conf:T.conf,mode:E.value.mode},{default:()=>[E.value.mode=="edit"&&vue.createVNode(vue.resolveComponent("el-input"),{clearable:T.conf.options.clearable,placeholder:T.conf.options.placeholder,modelValue:T.conf.options.defaultValue,"onUpdate:modelValue":D=>T.conf.options.defaultValue=D,onChange:R.handleOnChange},null),E.value.mode=="view"&&vue.createVNode(vue.resolveComponent("el-input"),{clearable:T.conf.options.clearable,placeholder:T.conf.options.placeholder,modelValue:t.value[T.conf.options.name],"onUpdate:modelValue":D=>t.value[T.conf.options.name]=D,onChange:R.handleOnChange},null)]}),I.value&&vue.createVNode(n,{className:"field-action",self:T.conf,parent:O},null),I.value&&vue.createVNode("div",{className:"drag-handler"},[vue.createVNode("i",{title:"拖拽手柄"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true"},[vue.createVNode("use",{"xlink:href":"#icon-el-drag-move"},null)])]),vue.createVNode("i",null,[vue.createTextVNode("单行输入")])])])}});L=T=>vue.createVNode(w,{id:T.id,conf:T,onClick:k=>A(k,T)},null)}else if(S.type=="textarea"){const w=vue.defineComponent({props:["conf"],mixins:[fieldOptionMixin],setup(_){const T=vue.getCurrentInstance().proxy,k=useFieldMixin(S,T);return k.registerRef(),k.rebuildRules(),k.handleOnCreated(),vue.onMounted(()=>{k.handleOnMounted()}),()=>vue.createVNode("div",{className:x},[vue.createVNode(g,{rules:k.rules.value,conf:_.conf,mode:E.value.mode},{default:()=>[E.value.mode=="edit"&&vue.createVNode(vue.resolveComponent("el-input"),{type:"textarea",rows:S.options.rows,placeholder:_.conf.options.placeholder,modelValue:_.conf.options.defaultValue,"onUpdate:modelValue":R=>_.conf.options.defaultValue=R,onChange:k.handleOnChange},null),E.value.mode=="view"&&vue.createVNode(vue.resolveComponent("el-input"),{type:"textarea",rows:S.options.rows,placeholder:_.conf.options.placeholder,modelValue:t.value[_.conf.options.name],"onUpdate:modelValue":R=>t.value[_.conf.options.name]=R,onChange:k.handleOnChange},null)]}),I.value&&vue.createVNode(n,{className:"field-action",self:_.conf,parent:O},null),I.value&&vue.createVNode("div",{className:"drag-handler"},[vue.createVNode("i",{title:"拖拽手柄"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true"},[vue.createVNode("use",{"xlink:href":"#icon-el-drag-move"},null)])]),vue.createVNode("i",null,[vue.createTextVNode("多行输入")])])])}});L=_=>vue.createVNode(w,{id:_.id,conf:_,onClick:T=>A(T,_)},null)}else if(S.type=="radio"){const w=vue.defineComponent({props:["conf"],mixins:[fieldOptionMixin],setup(_){const T=vue.getCurrentInstance().proxy,k=useFieldMixin(S,T);return k.registerRef(),k.rebuildRules(),k.handleOnCreated(),vue.onMounted(()=>{k.handleOnMounted()}),()=>vue.createVNode("div",{className:x},[vue.createVNode(g,{rules:k.rules.value,conf:_.conf,mode:E.value.mode},{default:()=>[E.value.mode=="edit"&&vue.createVNode(vue.resolveComponent("el-radio-group"),{style:{display:"inline"},modelValue:_.conf.options.defaultValue,"onUpdate:modelValue":R=>_.conf.options.defaultValue=R,onChange:k.handleOnChange},{default:()=>{var R;return[(R=_.conf.options.optionItems)==null?void 0:R.map((D,V)=>vue.createVNode(vue.resolveComponent("el-radio"),{key:V,value:D.value,disabled:D.disabled,style:{display:_.conf.options.displayStyle}},{default:()=>[D.label]}))]}}),E.value.mode=="view"&&vue.createVNode(vue.resolveComponent("el-radio-group"),{style:{display:"inline"},modelValue:t.value[_.conf.options.name],"onUpdate:modelValue":R=>t.value[_.conf.options.name]=R,onChange:k.handleOnChange},{default:()=>{var R;return[(R=_.conf.options.optionItems)==null?void 0:R.map((D,V)=>vue.createVNode(vue.resolveComponent("el-radio"),{key:V,value:D.value,disabled:D.disabled,style:{display:_.conf.options.displayStyle}},{default:()=>[D.label]}))]}})]}),I.value&&vue.createVNode(n,{className:"field-action",self:_.conf,parent:O},null),I.value&&vue.createVNode("div",{className:"drag-handler"},[vue.createVNode("i",{title:"拖拽手柄"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true"},[vue.createVNode("use",{"xlink:href":"#icon-el-drag-move"},null)])]),vue.createVNode("i",null,[vue.createTextVNode("单选项")])])])}});L=_=>vue.createVNode(w,{id:_.id,conf:_,onClick:T=>A(T,_)},null)}else if(S.type=="checkbox"){const w=vue.defineComponent({props:["conf"],mixins:[fieldOptionMixin],setup(_){const T=vue.getCurrentInstance().proxy,k=useFieldMixin(S,T);return k.registerRef(),k.rebuildRules(),k.handleOnCreated(),vue.onMounted(()=>{k.handleOnMounted()}),()=>vue.createVNode("div",{className:x},[vue.createVNode(g,{rules:k.rules.value,conf:_.conf,mode:E.value.mode},{default:()=>[E.value.mode=="edit"&&vue.createVNode(vue.resolveComponent("el-checkbox-group"),{style:{lineHeight:"32px"},modelValue:_.conf.options.defaultValue,"onUpdate:modelValue":R=>_.conf.options.defaultValue=R,onChange:k.handleOnChange},{default:()=>{var R;return[(R=_.conf.options.optionItems)==null?void 0:R.map((D,V)=>vue.createVNode(vue.resolveComponent("el-checkbox"),{key:V,value:D.value,disabled:D.disabled,style:{display:_.conf.options.displayStyle}},{default:()=>[D.label]}))]}}),E.value.mode=="view"&&vue.createVNode(vue.resolveComponent("el-checkbox-group"),{style:{lineHeight:"32px"},modelValue:t.value[_.conf.options.name],"onUpdate:modelValue":R=>t.value[_.conf.options.name]=R,onChange:k.handleOnChange},{default:()=>{var R;return[(R=_.conf.options.optionItems)==null?void 0:R.map((D,V)=>vue.createVNode(vue.resolveComponent("el-checkbox"),{key:V,value:D.value,disabled:D.disabled,style:{display:_.conf.options.displayStyle}},{default:()=>[D.label]}))]}})]}),I.value&&vue.createVNode(n,{className:"field-action",self:_.conf,parent:O},null),I.value&&vue.createVNode("div",{className:"drag-handler"},[vue.createVNode("i",{title:"拖拽手柄"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true"},[vue.createVNode("use",{"xlink:href":"#icon-el-drag-move"},null)])]),vue.createVNode("i",null,[vue.createTextVNode("单选项")])])])}});L=_=>vue.createVNode(w,{id:_.id,conf:_,onClick:T=>A(T,_)},null)}else if(S.type=="select"){const w=vue.defineComponent({props:["conf"],mixins:[fieldOptionMixin],setup(_){const T=vue.getCurrentInstance().proxy,k=useFieldMixin(S,T);return k.registerRef(),k.rebuildRules(),k.handleOnCreated(),vue.onMounted(()=>{k.handleOnMounted()}),()=>vue.createVNode("div",{className:x},[vue.createVNode(g,{rules:k.rules.value,conf:_.conf,mode:E.value.mode},{default:()=>[E.value.mode=="edit"&&vue.createVNode(vue.resolveComponent("el-select"),{style:{lineHeight:"32px"},clearable:_.conf.options.clearable,modelValue:_.conf.options.defaultValue,"onUpdate:modelValue":R=>_.conf.options.defaultValue=R,onChange:k.handleOnChange},{default:()=>{var R;return[(R=_.conf.options.optionItems)==null?void 0:R.map((D,V)=>vue.createVNode(vue.resolveComponent("el-option"),{key:V,value:D.value,label:D.label,disabled:D.disabled,style:{display:_.conf.options.displayStyle}},null))]}}),E.value.mode=="view"&&vue.createVNode(vue.resolveComponent("el-select"),{style:{lineHeight:"32px"},clearable:_.conf.options.clearable,modelValue:t.value[_.conf.options.name],"onUpdate:modelValue":R=>t.value[_.conf.options.name]=R,onChange:k.handleOnChange},{default:()=>{var R;return[(R=_.conf.options.optionItems)==null?void 0:R.map((D,V)=>vue.createVNode(vue.resolveComponent("el-option"),{key:V,value:D.value,label:D.label,disabled:D.disabled,style:{display:_.conf.options.displayStyle}},null))]}})]}),I.value&&vue.createVNode(n,{className:"field-action",self:_.conf,parent:O},null),I.value&&vue.createVNode("div",{className:"drag-handler"},[vue.createVNode("i",{title:"拖拽手柄"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true"},[vue.createVNode("use",{"xlink:href":"#icon-el-drag-move"},null)])]),vue.createVNode("i",null,[vue.createTextVNode("下拉选项")])])])}});L=_=>vue.createVNode(w,{id:_.id,conf:_,onClick:T=>A(T,_)},null)}else if(S.type=="picture-upload"){const w=vue.defineComponent({props:["conf"],mixins:[fieldOptionMixin],setup(_){const T=vue.getCurrentInstance().proxy,k=useFieldMixin(S,T);return k.registerRef(),k.rebuildRules(),k.handleOnCreated(),vue.onMounted(()=>{k.handleOnMounted()}),()=>vue.createVNode("div",{className:x},[vue.createVNode(g,{rules:k.rules.value,conf:_.conf,mode:E.value.mode},{default:()=>[E.value.mode=="edit"&&vue.createVNode(vue.resolveComponent("sy-picture-upload"),{fileType:_.conf.options.fileTypes,fileMaxSize:_.conf.options.fileMaxSize,isShowTip:_.conf.options.isShowTip,multipleSelect:_.conf.options.multipleSelect,defaultBg:_.conf.options.defaultBg},null),E.value.mode=="view"&&vue.createVNode(vue.resolveComponent("sy-picture-upload"),{fileType:_.conf.options.fileTypes,fileMaxSize:_.conf.options.fileMaxSize,isShowTip:_.conf.options.isShowTip,multipleSelect:_.conf.options.multipleSelect,defaultBg:_.conf.options.defaultBg,oss:{signatureUrl:_.conf.options.signatureUrl},md5:{requireMd5:_.conf.options.requireMd5,addFileMd5Url:_.conf.options.addFileMd5Url,queryFileMd5Url:_.conf.options.queryFileMd5Url},modelValue:t.value[_.conf.options.name],"onUpdate:modelValue":R=>t.value[_.conf.options.name]=R},null)]}),I.value&&vue.createVNode(n,{className:"field-action",self:_.conf,parent:O},null),I.value&&vue.createVNode("div",{className:"drag-handler"},[vue.createVNode("i",{title:"拖拽手柄"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true"},[vue.createVNode("use",{"xlink:href":"#icon-el-drag-move"},null)])]),vue.createVNode("i",null,[vue.createTextVNode("下拉选项")])])])}});L=_=>vue.createVNode(w,{id:_.id,conf:_,onClick:T=>A(T,_)},null)}else if(S.type=="static-title"){const w=vue.defineComponent({props:["conf"],setup(_){return()=>vue.createVNode("div",{className:`${x}`},[_.conf.options.titleLevel===1&&vue.createVNode("h1",{style:`text-align: ${_.conf.options.textAlign};`},[_.conf.options.textContent]),_.conf.options.titleLevel===2&&vue.createVNode("h2",{style:`text-align: ${_.conf.options.textAlign};`},[_.conf.options.textContent]),_.conf.options.titleLevel===3&&vue.createVNode("h3",{style:`text-align: ${_.conf.options.textAlign};`},[_.conf.options.textContent]),I.value&&vue.createVNode(n,{className:"field-action",self:_.conf,parent:O},null),I.value&&vue.createVNode("div",{className:"drag-handler"},[vue.createVNode("i",{title:"拖拽手柄"},[vue.createVNode("svg",{class:"svg-icon","aria-hidden":"true"},[vue.createVNode("use",{"xlink:href":"#icon-el-drag-move"},null)])]),vue.createVNode("i",null,[vue.createTextVNode("静态标题")])])])}});L=_=>vue.createVNode("div",{class:`static-content-item ${I.value&&"selected"||""}`,onClick:T=>A(T,_)},[vue.createVNode(w,{id:_.id,conf:_},null)])}if(L==null)throw new Error("Component "+S.type+" is not exists.");return L(S)},o=()=>{},r=S=>{C.value=e.conf.widgetList[S.newIndex]},t=vue.ref({}),i=vue.ref({}),c=S=>{let O=typeof S;return O=="object"&&S instanceof Array&&(O="array"),O},h=(S,O)=>{let x=typeof S;if(x=="object"&&S instanceof Array&&(x="array"),S==null||S===""){if(O=="array")return[];if(O=="object")return{};if(O=="string"||O=="number"||O=="boolean")return null}return x==O?S:x=="string"&&O=="array"?S.split(","):x=="string"&&O=="object"?JSON.parse(S):x=="string"&&O=="number"?S*1:x=="array"&&O=="string"?S.join(","):S},f=S=>{S.forEach((O,x)=>{O.type==="grid"?O.cols.forEach((L,I)=>{f(L.widgetList)}):Object.keys(O.options).indexOf("defaultValue")!=-1&&Object.assign(t.value,{[O.options.name]:E.value.formData.hasOwnProperty(O.options.name)?h(E.value.formData[O.options.name],c(O.options.defaultValue)):O.options.defaultValue})})},v=S=>{S.forEach((O,x)=>{if(O.type==="grid")O.cols.forEach((L,I)=>{v(L.widgetList)});else if(Object.keys(O.options).indexOf("defaultValue")!=-1){if(O.options.hidden)return;Object.assign(i.value,{[O.options.name]:h(E.value.formData[O.options.name],O.options.submitType)})}})},p=()=>(i.value={},v(e.conf.widgetList),i.value);e.mode=="view"&&(f(e.conf.widgetList),b.value=a(e.conf));const y={item:({element:S,index:O})=>vue.createVNode("div",{tag:"div",className:"transition-group-el"},[vue.createTextVNode(" "),vue.h(s,{conf:S,parent:e.conf})])},m=S=>d.value[S],$=(S=[],O)=>{const x={eq:"==",lt:"<",gt:">",elt:"<=",egt:">="};return S.reduce((L,I,w)=>(I.operator in x&&(L+=[O[I.left]?O[I.left]:"null",x[I.operator],I.right].join(" ")),w<S.length-1&&(L+=" "+(I.relation=="and"?"&&":"||")+" "),L),"")},N=(S,O={})=>new Function("return "+S).call(O),M=S=>S.options.hidden?S.options.showCondition&&!S.options.showCondition.length?!1:N($(S.options.showCondition,t.value),{}):!0;return vue.provide("refDict",d),vue.provide("render",l),l.$getWidgetRef=m,u.expose({getWidgetRef:m,getFormData:p}),()=>vue.createVNode(vue.Fragment,null,[e.mode==="edit"&&vue.createVNode("div",{class:"form-widget-container"},[vue.createVNode(vue.resolveComponent("el-form"),{class:`full-height-width widget-form ${e.conf.formConfig.labelAlign}`,"label-position":e.conf.formConfig.labelPosition,"label-width":e.conf.formConfig.labelWidth},{default:()=>[vue.createVNode(draggable,{tag:"div",class:"form-widget-list","item-key":"id",modelValue:e.conf.widgetList,"onUpdate:modelValue":S=>e.conf.widgetList=S,group:"people",ghostClass:"ghost",animation:200,handle:".drag-handler",onEnd:o,onAdd:r},y)]})]),e.mode==="view"&&vue.createVNode("div",{class:"form-render-wrapper"},[vue.createVNode(vue.resolveComponent("el-form"),{class:`full-height-width render-form ${e.conf.formConfig.labelAlign}`,"label-position":e.conf.formConfig.labelPosition,"label-width":e.conf.formConfig.labelWidth,model:t},{default:()=>[b.value]})])])}}),render$1=Object.freeze(Object.defineProperty({__proto__:null,default:render},Symbol.toStringTag,{value:"Module"}));var ace$2={exports:{}},hasRequiredAce;function requireAce(){return hasRequiredAce||(hasRequiredAce=1,function(e,u){(function(){var l="ace",d=function(){return this}();!d&&typeof window<"u"&&(d=window);var E=function(n,s,o){if(typeof n!="string"){E.original?E.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace());return}arguments.length==2&&(o=s),E.modules[n]||(E.payloads[n]=o,E.modules[n]=null)};E.modules={},E.payloads={};var b=function(n,s,o){if(typeof s=="string"){var r=a(n,s);if(r!=null)return o&&o(),r}else if(Object.prototype.toString.call(s)==="[object Array]"){for(var t=[],i=0,c=s.length;i<c;++i){var h=a(n,s[i]);if(h==null&&C.original)return;t.push(h)}return o&&o.apply(null,t)||!0}},C=function(n,s){var o=b("",n,s);return o==null&&C.original?C.original.apply(this,arguments):o},A=function(n,s){if(s.indexOf("!")!==-1){var o=s.split("!");return A(n,o[0])+"!"+A(n,o[1])}if(s.charAt(0)=="."){var r=n.split("/").slice(0,-1).join("/");for(s=r+"/"+s;s.indexOf(".")!==-1&&t!=s;){var t=s;s=s.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return s},a=function(n,s){s=A(n,s);var o=E.modules[s];if(!o){if(o=E.payloads[s],typeof o=="function"){var r={},t={id:s,uri:"",exports:r,packaged:!0},i=function(h,f){return b(s,h,f)},c=o(i,r,t);r=c||t.exports,E.modules[s]=r,delete E.payloads[s]}o=E.modules[s]=r||o}return o};function g(n){var s=d;d[n]||(d[n]={}),s=d[n],(!s.define||!s.define.packaged)&&(E.original=s.define,s.define=E,s.define.packaged=!0),(!s.require||!s.require.packaged)&&(C.original=s.require,s.require=C,s.require.packaged=!0)}g(l)})(),ace.define("ace/lib/es6-shim",["require","exports","module"],function(l,d,E){function b(C,A,a){Object.defineProperty(C,A,{value:a,enumerable:!1,writable:!0,configurable:!0})}String.prototype.startsWith||b(String.prototype,"startsWith",function(C,A){return A=A||0,this.lastIndexOf(C,A)===A}),String.prototype.endsWith||b(String.prototype,"endsWith",function(C,A){var a=this;(A===void 0||A>a.length)&&(A=a.length),A-=C.length;var g=a.indexOf(C,A);return g!==-1&&g===A}),String.prototype.repeat||b(String.prototype,"repeat",function(C){for(var A="",a=this;C>0;)C&1&&(A+=a),(C>>=1)&&(a+=a);return A}),String.prototype.includes||b(String.prototype,"includes",function(C,A){return this.indexOf(C,A)!=-1}),Object.assign||(Object.assign=function(C){if(C==null)throw new TypeError("Cannot convert undefined or null to object");for(var A=Object(C),a=1;a<arguments.length;a++){var g=arguments[a];g!=null&&Object.keys(g).forEach(function(n){A[n]=g[n]})}return A}),Object.values||(Object.values=function(C){return Object.keys(C).map(function(A){return C[A]})}),Array.prototype.find||b(Array.prototype,"find",function(C){for(var A=this.length,a=arguments[1],g=0;g<A;g++){var n=this[g];if(C.call(a,n,g,this))return n}}),Array.prototype.findIndex||b(Array.prototype,"findIndex",function(C){for(var A=this.length,a=arguments[1],g=0;g<A;g++){var n=this[g];if(C.call(a,n,g,this))return g}}),Array.prototype.includes||b(Array.prototype,"includes",function(C,A){return this.indexOf(C,A)!=-1}),Array.prototype.fill||b(Array.prototype,"fill",function(C){for(var A=this,a=A.length>>>0,g=arguments[1],n=g>>0,s=n<0?Math.max(a+n,0):Math.min(n,a),o=arguments[2],r=o===void 0?a:o>>0,t=r<0?Math.max(a+r,0):Math.min(r,a);s<t;)A[s]=C,s++;return A}),Array.of||b(Array,"of",function(){return Array.prototype.slice.call(arguments)})}),ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/es6-shim"],function(l,d,E){l("./es6-shim")}),ace.define("ace/lib/deep_copy",["require","exports","module"],function(l,d,E){d.deepCopy=function b(C){if(typeof C!="object"||!C)return C;var A;if(Array.isArray(C)){A=[];for(var a=0;a<C.length;a++)A[a]=b(C[a]);return A}if(Object.prototype.toString.call(C)!=="[object Object]")return C;A={};for(var a in C)A[a]=b(C[a]);return A}}),ace.define("ace/lib/lang",["require","exports","module","ace/lib/deep_copy"],function(l,d,E){d.last=function(A){return A[A.length-1]},d.stringReverse=function(A){return A.split("").reverse().join("")},d.stringRepeat=function(A,a){for(var g="";a>0;)a&1&&(g+=A),(a>>=1)&&(A+=A);return g};var b=/^\s\s*/,C=/\s\s*$/;d.stringTrimLeft=function(A){return A.replace(b,"")},d.stringTrimRight=function(A){return A.replace(C,"")},d.copyObject=function(A){var a={};for(var g in A)a[g]=A[g];return a},d.copyArray=function(A){for(var a=[],g=0,n=A.length;g<n;g++)A[g]&&typeof A[g]=="object"?a[g]=this.copyObject(A[g]):a[g]=A[g];return a},d.deepCopy=l("./deep_copy").deepCopy,d.arrayToMap=function(A){for(var a={},g=0;g<A.length;g++)a[A[g]]=1;return a},d.createMap=function(A){var a=Object.create(null);for(var g in A)a[g]=A[g];return a},d.arrayRemove=function(A,a){for(var g=0;g<=A.length;g++)a===A[g]&&A.splice(g,1)},d.escapeRegExp=function(A){return A.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},d.escapeHTML=function(A){return(""+A).replace(/&/g,"&#38;").replace(/"/g,"&#34;").replace(/'/g,"&#39;").replace(/</g,"&#60;")},d.getMatchOffsets=function(A,a){var g=[];return A.replace(a,function(n){g.push({offset:arguments[arguments.length-2],length:n.length})}),g},d.deferredCall=function(A){var a=null,g=function(){a=null,A()},n=function(s){return n.cancel(),a=setTimeout(g,s||0),n};return n.schedule=n,n.call=function(){return this.cancel(),A(),n},n.cancel=function(){return clearTimeout(a),a=null,n},n.isPending=function(){return a},n},d.delayedCall=function(A,a){var g=null,n=function(){g=null,A()},s=function(o){g==null&&(g=setTimeout(n,o||a))};return s.delay=function(o){g&&clearTimeout(g),g=setTimeout(n,o||a)},s.schedule=s,s.call=function(){this.cancel(),A()},s.cancel=function(){g&&clearTimeout(g),g=null},s.isPending=function(){return g},s},d.supportsLookbehind=function(){try{new RegExp("(?<=.)")}catch{return!1}return!0},d.skipEmptyMatch=function(A,a,g){return g&&A.codePointAt(a)>65535?2:1}}),ace.define("ace/lib/useragent",["require","exports","module"],function(l,d,E){d.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},d.getOS=function(){return d.isMac?d.OS.MAC:d.isLinux?d.OS.LINUX:d.OS.WINDOWS};var b=typeof navigator=="object"?navigator:{},C=(/mac|win|linux/i.exec(b.platform)||["other"])[0].toLowerCase(),A=b.userAgent||"",a=b.appName||"";d.isWin=C=="win",d.isMac=C=="mac",d.isLinux=C=="linux",d.isIE=a=="Microsoft Internet Explorer"||a.indexOf("MSAppHost")>=0?parseFloat((A.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((A.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),d.isOldIE=d.isIE&&d.isIE<9,d.isGecko=d.isMozilla=A.match(/ Gecko\/\d+/),d.isOpera=typeof opera=="object"&&Object.prototype.toString.call(window.opera)=="[object Opera]",d.isWebKit=parseFloat(A.split("WebKit/")[1])||void 0,d.isChrome=parseFloat(A.split(" Chrome/")[1])||void 0,d.isSafari=parseFloat(A.split(" Safari/")[1])&&!d.isChrome||void 0,d.isEdge=parseFloat(A.split(" Edge/")[1])||void 0,d.isAIR=A.indexOf("AdobeAIR")>=0,d.isAndroid=A.indexOf("Android")>=0,d.isChromeOS=A.indexOf(" CrOS ")>=0,d.isIOS=/iPad|iPhone|iPod/.test(A)&&!window.MSStream,d.isIOS&&(d.isMac=!0),d.isMobile=d.isIOS||d.isAndroid}),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],function(l,d,E){var b=l("./useragent"),C="http://www.w3.org/1999/xhtml";d.buildDom=function o(r,t,i){if(typeof r=="string"&&r){var c=document.createTextNode(r);return t&&t.appendChild(c),c}if(!Array.isArray(r))return r&&r.appendChild&&t&&t.appendChild(r),r;if(typeof r[0]!="string"||!r[0]){for(var h=[],f=0;f<r.length;f++){var v=o(r[f],t,i);v&&h.push(v)}return h}var p=document.createElement(r[0]),y=r[1],m=1;y&&typeof y=="object"&&!Array.isArray(y)&&(m=2);for(var f=m;f<r.length;f++)o(r[f],p,i);return m==2&&Object.keys(y).forEach(function($){var N=y[$];$==="class"?p.className=Array.isArray(N)?N.join(" "):N:typeof N=="function"||$=="value"||$[0]=="$"?p[$]=N:$==="ref"?i&&(i[N]=p):$==="style"?typeof N=="string"&&(p.style.cssText=N):N!=null&&p.setAttribute($,N)}),t&&t.appendChild(p),p},d.getDocumentHead=function(o){return o||(o=document),o.head||o.getElementsByTagName("head")[0]||o.documentElement},d.createElement=function(o,r){return document.createElementNS?document.createElementNS(r||C,o):document.createElement(o)},d.removeChildren=function(o){o.innerHTML=""},d.createTextNode=function(o,r){var t=r?r.ownerDocument:document;return t.createTextNode(o)},d.createFragment=function(o){var r=o?o.ownerDocument:document;return r.createDocumentFragment()},d.hasCssClass=function(o,r){var t=(o.className+"").split(/\s+/g);return t.indexOf(r)!==-1},d.addCssClass=function(o,r){d.hasCssClass(o,r)||(o.className+=" "+r)},d.removeCssClass=function(o,r){for(var t=o.className.split(/\s+/g);;){var i=t.indexOf(r);if(i==-1)break;t.splice(i,1)}o.className=t.join(" ")},d.toggleCssClass=function(o,r){for(var t=o.className.split(/\s+/g),i=!0;;){var c=t.indexOf(r);if(c==-1)break;i=!1,t.splice(c,1)}return i&&t.push(r),o.className=t.join(" "),i},d.setCssClass=function(o,r,t){t?d.addCssClass(o,r):d.removeCssClass(o,r)},d.hasCssString=function(o,r){var t=0,i;if(r=r||document,i=r.querySelectorAll("style")){for(;t<i.length;)if(i[t++].id===o)return!0}},d.removeElementById=function(o,r){r=r||document,r.getElementById(o)&&r.getElementById(o).remove()};var A,a=[];d.useStrictCSP=function(o){A=o,o==!1?g():a||(a=[])};function g(){var o=a;a=null,o&&o.forEach(function(r){n(r[0],r[1])})}function n(o,r,t){if(!(typeof document>"u")){if(a){if(t)g();else if(t===!1)return a.push([o,r])}if(!A){var i=t;!t||!t.getRootNode?i=document:(i=t.getRootNode(),(!i||i==t)&&(i=document));var c=i.ownerDocument||i;if(r&&d.hasCssString(r,i))return null;r&&(o+=`
7
+ /*# sourceURL=ace/css/`+r+" */");var h=d.createElement("style");h.appendChild(c.createTextNode(o)),r&&(h.id=r),i==c&&(i=d.getDocumentHead(c)),i.insertBefore(h,i.firstChild)}}}if(d.importCssString=n,d.importCssStylsheet=function(o,r){d.buildDom(["link",{rel:"stylesheet",href:o}],d.getDocumentHead(r))},d.scrollbarWidth=function(o){var r=d.createElement("ace_inner");r.style.width="100%",r.style.minWidth="0px",r.style.height="200px",r.style.display="block";var t=d.createElement("ace_outer"),i=t.style;i.position="absolute",i.left="-10000px",i.overflow="hidden",i.width="200px",i.minWidth="0px",i.height="150px",i.display="block",t.appendChild(r);var c=o&&o.documentElement||document&&document.documentElement;if(!c)return 0;c.appendChild(t);var h=r.offsetWidth;i.overflow="scroll";var f=r.offsetWidth;return h===f&&(f=t.clientWidth),c.removeChild(t),h-f},d.computedStyle=function(o,r){return window.getComputedStyle(o,"")||{}},d.setStyle=function(o,r,t){o[r]!==t&&(o[r]=t)},d.HAS_CSS_ANIMATION=!1,d.HAS_CSS_TRANSFORMS=!1,d.HI_DPI=b.isWin?typeof window<"u"&&window.devicePixelRatio>=1.5:!0,b.isChromeOS&&(d.HI_DPI=!1),typeof document<"u"){var s=document.createElement("div");d.HI_DPI&&s.style.transform!==void 0&&(d.HAS_CSS_TRANSFORMS=!0),!b.isEdge&&typeof s.style.animationName<"u"&&(d.HAS_CSS_ANIMATION=!0),s=null}d.HAS_CSS_TRANSFORMS?d.translate=function(o,r,t){o.style.transform="translate("+Math.round(r)+"px, "+Math.round(t)+"px)"}:d.translate=function(o,r,t){o.style.top=Math.round(t)+"px",o.style.left=Math.round(r)+"px"}}),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(l,d,E){/*
8
+ * based on code from:
9
+ *
10
+ * @license RequireJS text 0.25.0 Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved.
11
+ * Available via the MIT or new BSD license.
12
+ * see: http://github.com/jrburke/requirejs for details
13
+ */var b=l("./dom");d.get=function(C,A){var a=new XMLHttpRequest;a.open("GET",C,!0),a.onreadystatechange=function(){a.readyState===4&&A(a.responseText)},a.send(null)},d.loadScript=function(C,A){var a=b.getDocumentHead(),g=document.createElement("script");g.src=C,a.appendChild(g),g.onload=g.onreadystatechange=function(n,s){(s||!g.readyState||g.readyState=="loaded"||g.readyState=="complete")&&(g=g.onload=g.onreadystatechange=null,s||A())}},d.qualifyURL=function(C){var A=document.createElement("a");return A.href=C,A.href}}),ace.define("ace/lib/oop",["require","exports","module"],function(l,d,E){d.inherits=function(b,C){b.super_=C,b.prototype=Object.create(C.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}})},d.mixin=function(b,C){for(var A in C)b[A]=C[A];return b},d.implement=function(b,C){d.mixin(b,C)}}),ace.define("ace/lib/event_emitter",["require","exports","module"],function(l,d,E){var b={},C=function(){this.propagationStopped=!0},A=function(){this.defaultPrevented=!0};b._emit=b._dispatchEvent=function(a,g){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var n=this._eventRegistry[a]||[],s=this._defaultHandlers[a];if(!(!n.length&&!s)){(typeof g!="object"||!g)&&(g={}),g.type||(g.type=a),g.stopPropagation||(g.stopPropagation=C),g.preventDefault||(g.preventDefault=A),n=n.slice();for(var o=0;o<n.length&&(n[o](g,this),!g.propagationStopped);o++);if(s&&!g.defaultPrevented)return s(g,this)}},b._signal=function(a,g){var n=(this._eventRegistry||{})[a];if(n){n=n.slice();for(var s=0;s<n.length;s++)n[s](g,this)}},b.once=function(a,g){var n=this;if(this.on(a,function s(){n.off(a,s),g.apply(null,arguments)}),!g)return new Promise(function(s){g=s})},b.setDefaultHandler=function(a,g){var n=this._defaultHandlers;if(n||(n=this._defaultHandlers={_disabled_:{}}),n[a]){var s=n[a],o=n._disabled_[a];o||(n._disabled_[a]=o=[]),o.push(s);var r=o.indexOf(g);r!=-1&&o.splice(r,1)}n[a]=g},b.removeDefaultHandler=function(a,g){var n=this._defaultHandlers;if(n){var s=n._disabled_[a];if(n[a]==g)s&&this.setDefaultHandler(a,s.pop());else if(s){var o=s.indexOf(g);o!=-1&&s.splice(o,1)}}},b.on=b.addEventListener=function(a,g,n){this._eventRegistry=this._eventRegistry||{};var s=this._eventRegistry[a];return s||(s=this._eventRegistry[a]=[]),s.indexOf(g)==-1&&s[n?"unshift":"push"](g),g},b.off=b.removeListener=b.removeEventListener=function(a,g){this._eventRegistry=this._eventRegistry||{};var n=this._eventRegistry[a];if(n){var s=n.indexOf(g);s!==-1&&n.splice(s,1)}},b.removeAllListeners=function(a){a||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[a]=void 0),this._defaultHandlers&&(this._defaultHandlers[a]=void 0)},d.EventEmitter=b}),ace.define("ace/lib/report_error",["require","exports","module"],function(l,d,E){d.reportError=function(C,A){var a=new Error(C);a.data=A,typeof console=="object"&&console.error&&console.error(a),setTimeout(function(){throw a})}}),ace.define("ace/lib/default_english_messages",["require","exports","module"],function(l,d,E){var b={"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"};d.defaultEnglishMessages=b}),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(l,d,E){"no use strict";var b=l("./oop"),C=l("./event_emitter").EventEmitter,A=l("./report_error").reportError,a=l("./default_english_messages").defaultEnglishMessages,g={setOptions:function(t){Object.keys(t).forEach(function(i){this.setOption(i,t[i])},this)},getOptions:function(t){var i={};if(t)Array.isArray(t)||(i=t,t=Object.keys(i));else{var c=this.$options;t=Object.keys(c).filter(function(h){return!c[h].hidden})}return t.forEach(function(h){i[h]=this.getOption(h)},this),i},setOption:function(t,i){if(this["$"+t]!==i){var c=this.$options[t];if(!c)return n('misspelled option "'+t+'"');if(c.forwardTo)return this[c.forwardTo]&&this[c.forwardTo].setOption(t,i);c.handlesSet||(this["$"+t]=i),c&&c.set&&c.set.call(this,i)}},getOption:function(t){var i=this.$options[t];return i?i.forwardTo?this[i.forwardTo]&&this[i.forwardTo].getOption(t):i&&i.get?i.get.call(this):this["$"+t]:n('misspelled option "'+t+'"')}};function n(t){typeof console<"u"&&console.warn&&console.warn.apply(console,arguments)}var s,o,r=function(){function t(){this.$defaultOptions={},s=a,o="dollarSigns"}return t.prototype.defineOptions=function(i,c,h){return i.$options||(this.$defaultOptions[c]=i.$options={}),Object.keys(h).forEach(function(f){var v=h[f];typeof v=="string"&&(v={forwardTo:v}),v.name||(v.name=f),i.$options[v.name]=v,"initialValue"in v&&(i["$"+v.name]=v.initialValue)}),b.implement(i,g),this},t.prototype.resetOptions=function(i){Object.keys(i.$options).forEach(function(c){var h=i.$options[c];"value"in h&&i.setOption(c,h.value)})},t.prototype.setDefaultValue=function(i,c,h){if(!i){for(i in this.$defaultOptions)if(this.$defaultOptions[i][c])break;if(!this.$defaultOptions[i][c])return!1}var f=this.$defaultOptions[i]||(this.$defaultOptions[i]={});f[c]&&(f.forwardTo?this.setDefaultValue(f.forwardTo,c,h):f[c].value=h)},t.prototype.setDefaultValues=function(i,c){Object.keys(c).forEach(function(h){this.setDefaultValue(i,h,c[h])},this)},t.prototype.setMessages=function(i,c){s=i,c&&c.placeholders&&(o=c.placeholders)},t.prototype.nls=function(i,c,h){s[i]||(n("No message found for the key '"+i+"' in messages with id "+s.$id+", trying to find a translation for the default string '"+c+"'."),s[c]||n("No message found for the default string '"+c+"' in the provided messages. Falling back to the default English message."));var f=s[i]||s[c]||c;return h&&(o==="dollarSigns"&&(f=f.replace(/\$(\$|[\d]+)/g,function(v,p){return p=="$"?"$":h[p]})),o==="curlyBrackets"&&(f=f.replace(/\{([^\}]+)\}/g,function(v,p){return h[p]}))),f},t}();r.prototype.warn=n,r.prototype.reportError=A,b.implement(r.prototype,C),d.AppConfig=r}),ace.define("ace/theme/textmate-css",["require","exports","module"],function(l,d,E){E.exports=`.ace-tm .ace_gutter {
14
+ background: #f0f0f0;
15
+ color: #333;
16
+ }
17
+
18
+ .ace-tm .ace_print-margin {
19
+ width: 1px;
20
+ background: #e8e8e8;
21
+ }
22
+
23
+ .ace-tm .ace_fold {
24
+ background-color: #6B72E6;
25
+ }
26
+
27
+ .ace-tm {
28
+ background-color: #FFFFFF;
29
+ color: black;
30
+ }
31
+
32
+ .ace-tm .ace_cursor {
33
+ color: black;
34
+ }
35
+
36
+ .ace-tm .ace_invisible {
37
+ color: rgb(191, 191, 191);
38
+ }
39
+
40
+ .ace-tm .ace_storage,
41
+ .ace-tm .ace_keyword {
42
+ color: blue;
43
+ }
44
+
45
+ .ace-tm .ace_constant {
46
+ color: rgb(197, 6, 11);
47
+ }
48
+
49
+ .ace-tm .ace_constant.ace_buildin {
50
+ color: rgb(88, 72, 246);
51
+ }
52
+
53
+ .ace-tm .ace_constant.ace_language {
54
+ color: rgb(88, 92, 246);
55
+ }
56
+
57
+ .ace-tm .ace_constant.ace_library {
58
+ color: rgb(6, 150, 14);
59
+ }
60
+
61
+ .ace-tm .ace_invalid {
62
+ background-color: rgba(255, 0, 0, 0.1);
63
+ color: red;
64
+ }
65
+
66
+ .ace-tm .ace_support.ace_function {
67
+ color: rgb(60, 76, 114);
68
+ }
69
+
70
+ .ace-tm .ace_support.ace_constant {
71
+ color: rgb(6, 150, 14);
72
+ }
73
+
74
+ .ace-tm .ace_support.ace_type,
75
+ .ace-tm .ace_support.ace_class {
76
+ color: rgb(109, 121, 222);
77
+ }
78
+
79
+ .ace-tm .ace_keyword.ace_operator {
80
+ color: rgb(104, 118, 135);
81
+ }
82
+
83
+ .ace-tm .ace_string {
84
+ color: rgb(3, 106, 7);
85
+ }
86
+
87
+ .ace-tm .ace_comment {
88
+ color: rgb(76, 136, 107);
89
+ }
90
+
91
+ .ace-tm .ace_comment.ace_doc {
92
+ color: rgb(0, 102, 255);
93
+ }
94
+
95
+ .ace-tm .ace_comment.ace_doc.ace_tag {
96
+ color: rgb(128, 159, 191);
97
+ }
98
+
99
+ .ace-tm .ace_constant.ace_numeric {
100
+ color: rgb(0, 0, 205);
101
+ }
102
+
103
+ .ace-tm .ace_variable {
104
+ color: rgb(49, 132, 149);
105
+ }
106
+
107
+ .ace-tm .ace_xml-pe {
108
+ color: rgb(104, 104, 91);
109
+ }
110
+
111
+ .ace-tm .ace_entity.ace_name.ace_function {
112
+ color: #0000A2;
113
+ }
114
+
115
+
116
+ .ace-tm .ace_heading {
117
+ color: rgb(12, 7, 255);
118
+ }
119
+
120
+ .ace-tm .ace_list {
121
+ color:rgb(185, 6, 144);
122
+ }
123
+
124
+ .ace-tm .ace_meta.ace_tag {
125
+ color:rgb(0, 22, 142);
126
+ }
127
+
128
+ .ace-tm .ace_string.ace_regex {
129
+ color: rgb(255, 0, 0)
130
+ }
131
+
132
+ .ace-tm .ace_marker-layer .ace_selection {
133
+ background: rgb(181, 213, 255);
134
+ }
135
+ .ace-tm.ace_multiselect .ace_selection.ace_start {
136
+ box-shadow: 0 0 3px 0px white;
137
+ }
138
+ .ace-tm .ace_marker-layer .ace_step {
139
+ background: rgb(252, 255, 0);
140
+ }
141
+
142
+ .ace-tm .ace_marker-layer .ace_stack {
143
+ background: rgb(164, 229, 101);
144
+ }
145
+
146
+ .ace-tm .ace_marker-layer .ace_bracket {
147
+ margin: -1px 0 0 -1px;
148
+ border: 1px solid rgb(192, 192, 192);
149
+ }
150
+
151
+ .ace-tm .ace_marker-layer .ace_active-line {
152
+ background: rgba(0, 0, 0, 0.07);
153
+ }
154
+
155
+ .ace-tm .ace_gutter-active-line {
156
+ background-color : #dcdcdc;
157
+ }
158
+
159
+ .ace-tm .ace_marker-layer .ace_selected-word {
160
+ background: rgb(250, 250, 255);
161
+ border: 1px solid rgb(200, 200, 250);
162
+ }
163
+
164
+ .ace-tm .ace_indent-guide {
165
+ background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;
166
+ }
167
+
168
+ .ace-tm .ace_indent-guide-active {
169
+ background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAAZSURBVHjaYvj///9/hivKyv8BAAAA//8DACLqBhbvk+/eAAAAAElFTkSuQmCC") right repeat-y;
170
+ }
171
+ `}),ace.define("ace/theme/textmate",["require","exports","module","ace/theme/textmate-css","ace/lib/dom"],function(l,d,E){d.isDark=!1,d.cssClass="ace-tm",d.cssText=l("./textmate-css"),d.$id="ace/theme/textmate";var b=l("../lib/dom");b.importCssString(d.cssText,d.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(l,d,E){"no use strict";var b=l("./lib/lang"),C=l("./lib/net"),A=l("./lib/dom"),a=l("./lib/app_config").AppConfig;E.exports=d=new a;var g={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{},loadWorkerFromBlob:!0,sharedPopups:!1,useStrictCSP:null};d.get=function(r){if(!g.hasOwnProperty(r))throw new Error("Unknown config key: "+r);return g[r]},d.set=function(r,t){if(g.hasOwnProperty(r))g[r]=t;else if(this.setDefaultValue("",r,t)==!1)throw new Error("Unknown config key: "+r);r=="useStrictCSP"&&A.useStrictCSP(t)},d.all=function(){return b.copyObject(g)},d.$modes={},d.moduleUrl=function(r,t){if(g.$moduleUrls[r])return g.$moduleUrls[r];var i=r.split("/");t=t||i[i.length-2]||"";var c=t=="snippets"?"/":"-",h=i[i.length-1];if(t=="worker"&&c=="-"){var f=new RegExp("^"+t+"[\\-_]|[\\-_]"+t+"$","g");h=h.replace(f,"")}(!h||h==t)&&i.length>1&&(h=i[i.length-2]);var v=g[t+"Path"];return v==null?v=g.basePath:c=="/"&&(t=c=""),v&&v.slice(-1)!="/"&&(v+="/"),v+t+c+h+this.get("suffix")},d.setModuleUrl=function(r,t){return g.$moduleUrls[r]=t};var n=function(r,t){if(r==="ace/theme/textmate"||r==="./theme/textmate")return t(null,l("./theme/textmate"));if(s)return s(r,t);console.error("loader is not configured")},s;d.setLoader=function(r){s=r},d.dynamicModules=Object.create(null),d.$loading={},d.$loaded={},d.loadModule=function(r,t){var i;if(Array.isArray(r))var c=r[0],h=r[1];else if(typeof r=="string")var h=r;var f=function(v){if(v&&!d.$loading[h])return t&&t(v);if(d.$loading[h]||(d.$loading[h]=[]),d.$loading[h].push(t),!(d.$loading[h].length>1)){var p=function(){n(h,function(y,m){m&&(d.$loaded[h]=m),d._emit("load.module",{name:h,module:m});var $=d.$loading[h];d.$loading[h]=null,$.forEach(function(N){N&&N(m)})})};if(!d.get("packaged"))return p();C.loadScript(d.moduleUrl(h,c),p),o()}};if(d.dynamicModules[h])d.dynamicModules[h]().then(function(v){v.default?f(v.default):f(v)});else{try{i=this.$require(h)}catch{}f(i||d.$loaded[h])}},d.$require=function(r){if(typeof E.require=="function"){var t="require";return E[t](r)}},d.setModuleLoader=function(r,t){d.dynamicModules[r]=t};var o=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"),o=function(){})};d.version="1.39.1"}),ace.define("ace/loader_build",["require","exports","module","ace/lib/fixoldbrowsers","ace/config"],function(l,d,E){l("./lib/fixoldbrowsers");var b=l("./config");b.setLoader(function(g,n){l([g],function(s){n(null,s)})});var C=function(){return this||typeof window<"u"&&window}();E.exports=function(g){b.init=A,b.$require=l,g.require=l},A(!0);function A(g){if(!(!C||!C.document)){b.set("packaged",g||l.packaged||E.packaged||C.define&&(void 0).packaged);var n={},s="",o=document.currentScript||document._currentScript,r=o&&o.ownerDocument||document;o&&o.src&&(s=o.src.split(/[?#]/)[0].split("/").slice(0,-1).join("/")||"");for(var t=r.getElementsByTagName("script"),i=0;i<t.length;i++){var c=t[i],h=c.src||c.getAttribute("src");if(h){for(var f=c.attributes,v=0,p=f.length;v<p;v++){var y=f[v];y.name.indexOf("data-ace-")===0&&(n[a(y.name.replace(/^data-ace-/,""))]=y.value)}var m=h.match(/^(.*)\/ace([\-.]\w+)?\.js(\?|$)/);m&&(s=m[1])}}s&&(n.base=n.base||s,n.packaged=!0),n.basePath=n.base,n.workerPath=n.workerPath||n.base,n.modePath=n.modePath||n.base,n.themePath=n.themePath||n.base,delete n.base;for(var $ in n)typeof n[$]<"u"&&b.set($,n[$])}}function a(g){return g.replace(/-(.)/g,function(n,s){return s.toUpperCase()})}}),ace.define("ace/range",["require","exports","module"],function(l,d,E){var b=function(){function C(A,a,g,n){this.start={row:A,column:a},this.end={row:g,column:n}}return C.prototype.isEqual=function(A){return this.start.row===A.start.row&&this.end.row===A.end.row&&this.start.column===A.start.column&&this.end.column===A.end.column},C.prototype.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},C.prototype.contains=function(A,a){return this.compare(A,a)==0},C.prototype.compareRange=function(A){var a,g=A.end,n=A.start;return a=this.compare(g.row,g.column),a==1?(a=this.compare(n.row,n.column),a==1?2:a==0?1:0):a==-1?-2:(a=this.compare(n.row,n.column),a==-1?-1:a==1?42:0)},C.prototype.comparePoint=function(A){return this.compare(A.row,A.column)},C.prototype.containsRange=function(A){return this.comparePoint(A.start)==0&&this.comparePoint(A.end)==0},C.prototype.intersects=function(A){var a=this.compareRange(A);return a==-1||a==0||a==1},C.prototype.isEnd=function(A,a){return this.end.row==A&&this.end.column==a},C.prototype.isStart=function(A,a){return this.start.row==A&&this.start.column==a},C.prototype.setStart=function(A,a){typeof A=="object"?(this.start.column=A.column,this.start.row=A.row):(this.start.row=A,this.start.column=a)},C.prototype.setEnd=function(A,a){typeof A=="object"?(this.end.column=A.column,this.end.row=A.row):(this.end.row=A,this.end.column=a)},C.prototype.inside=function(A,a){return this.compare(A,a)==0?!(this.isEnd(A,a)||this.isStart(A,a)):!1},C.prototype.insideStart=function(A,a){return this.compare(A,a)==0?!this.isEnd(A,a):!1},C.prototype.insideEnd=function(A,a){return this.compare(A,a)==0?!this.isStart(A,a):!1},C.prototype.compare=function(A,a){return!this.isMultiLine()&&A===this.start.row?a<this.start.column?-1:a>this.end.column?1:0:A<this.start.row?-1:A>this.end.row?1:this.start.row===A?a>=this.start.column?0:-1:this.end.row===A?a<=this.end.column?0:1:0},C.prototype.compareStart=function(A,a){return this.start.row==A&&this.start.column==a?-1:this.compare(A,a)},C.prototype.compareEnd=function(A,a){return this.end.row==A&&this.end.column==a?1:this.compare(A,a)},C.prototype.compareInside=function(A,a){return this.end.row==A&&this.end.column==a?1:this.start.row==A&&this.start.column==a?-1:this.compare(A,a)},C.prototype.clipRows=function(A,a){if(this.end.row>a)var g={row:a+1,column:0};else if(this.end.row<A)var g={row:A,column:0};if(this.start.row>a)var n={row:a+1,column:0};else if(this.start.row<A)var n={row:A,column:0};return C.fromPoints(n||this.start,g||this.end)},C.prototype.extend=function(A,a){var g=this.compare(A,a);if(g==0)return this;if(g==-1)var n={row:A,column:a};else var s={row:A,column:a};return C.fromPoints(n||this.start,s||this.end)},C.prototype.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},C.prototype.isMultiLine=function(){return this.start.row!==this.end.row},C.prototype.clone=function(){return C.fromPoints(this.start,this.end)},C.prototype.collapseRows=function(){return this.end.column==0?new C(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new C(this.start.row,0,this.end.row,0)},C.prototype.toScreenRange=function(A){var a=A.documentToScreenPosition(this.start),g=A.documentToScreenPosition(this.end);return new C(a.row,a.column,g.row,g.column)},C.prototype.moveBy=function(A,a){this.start.row+=A,this.start.column+=a,this.end.row+=A,this.end.column+=a},C}();b.fromPoints=function(C,A){return new b(C.row,C.column,A.row,A.column)},b.comparePoints=function(C,A){return C.row-A.row||C.column-A.column},d.Range=b}),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],function(l,d,E){for(var b=l("./oop"),C={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:"*"}},A={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},a=0;a<10;a++)A["Digit"+a]=48+a,A["Numpad"+a]=96+a,C.PRINTABLE_KEYS[48+a]=""+a,C.FUNCTION_KEYS[96+a]="Numpad"+a;for(var a=65;a<91;a++){var g=String.fromCharCode(a+32);A["Key"+g.toUpperCase()]=a,C.PRINTABLE_KEYS[a]=g}for(var a=1;a<13;a++)A["F"+a]=111+a,C.FUNCTION_KEYS[111+a]="F"+a;var n={Shift:16,Control:17,Alt:18,Meta:224};for(var s in n)A[s]=A[s+"Left"]=A[s+"Right"]=n[s];d.$codeToKeyCode=A,C.PRINTABLE_KEYS[173]="-";for(var o in C.FUNCTION_KEYS){var r=C.FUNCTION_KEYS[o].toLowerCase();C[r]=parseInt(o,10)}for(var o in C.PRINTABLE_KEYS){var r=C.PRINTABLE_KEYS[o].toLowerCase();C[r]=parseInt(o,10)}b.mixin(C,C.MODIFIER_KEYS),b.mixin(C,C.PRINTABLE_KEYS),b.mixin(C,C.FUNCTION_KEYS),C.enter=C.return,C.escape=C.esc,C.del=C.delete,function(){for(var t=["cmd","ctrl","alt","shift"],i=Math.pow(2,t.length);i--;)C.KEY_MODS[i]=t.filter(function(c){return i&C.KEY_MODS[c]}).join("-")+"-"}(),C.KEY_MODS[0]="",C.KEY_MODS[-1]="input-",b.mixin(d,C),d.default=d,d.keyCodeToString=function(t){var i=C[t];return typeof i!="string"&&(i=String.fromCharCode(t)),i.toLowerCase()}}),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(l,d,E){var b=l("./keys"),C=l("./useragent"),A=null,a=0,g;function n(){g=!1;try{document.createComment("").addEventListener("test",function(){},{get passive(){return g={passive:!1},!0}})}catch{}}function s(){return g==null&&n(),g}function o(v,p,y){this.elem=v,this.type=p,this.callback=y}o.prototype.destroy=function(){t(this.elem,this.type,this.callback),this.elem=this.type=this.callback=void 0};var r=d.addListener=function(v,p,y,m){v.addEventListener(p,y,s()),m&&m.$toDestroy.push(new o(v,p,y))},t=d.removeListener=function(v,p,y){v.removeEventListener(p,y,s())};d.stopEvent=function(v){return d.stopPropagation(v),d.preventDefault(v),!1},d.stopPropagation=function(v){v.stopPropagation&&v.stopPropagation()},d.preventDefault=function(v){v.preventDefault&&v.preventDefault()},d.getButton=function(v){return v.type=="dblclick"?0:v.type=="contextmenu"||C.isMac&&v.ctrlKey&&!v.altKey&&!v.shiftKey?2:v.button},d.capture=function(v,p,y){var m=v&&v.ownerDocument||document;function $(N){p&&p(N),y&&y(N),t(m,"mousemove",p),t(m,"mouseup",$),t(m,"dragstart",$)}return r(m,"mousemove",p),r(m,"mouseup",$),r(m,"dragstart",$),$},d.addMouseWheelListener=function(v,p,y){r(v,"wheel",function(m){var $=.15,N=m.deltaX||0,M=m.deltaY||0;switch(m.deltaMode){case m.DOM_DELTA_PIXEL:m.wheelX=N*$,m.wheelY=M*$;break;case m.DOM_DELTA_LINE:var S=15;m.wheelX=N*S,m.wheelY=M*S;break;case m.DOM_DELTA_PAGE:var O=150;m.wheelX=N*O,m.wheelY=M*O;break}p(m)},y)},d.addMultiMouseDownListener=function(v,p,y,m,$){var N=0,M,S,O,x={2:"dblclick",3:"tripleclick",4:"quadclick"};function L(I){if(d.getButton(I)!==0?N=0:I.detail>1?(N++,N>4&&(N=1)):N=1,C.isIE){var w=Math.abs(I.clientX-M)>5||Math.abs(I.clientY-S)>5;(!O||w)&&(N=1),O&&clearTimeout(O),O=setTimeout(function(){O=null},p[N-1]||600),N==1&&(M=I.clientX,S=I.clientY)}if(I._clicks=N,y[m]("mousedown",I),N>4)N=0;else if(N>1)return y[m](x[N],I)}Array.isArray(v)||(v=[v]),v.forEach(function(I){r(I,"mousedown",L,$)})};function i(v){return 0|(v.ctrlKey?1:0)|(v.altKey?2:0)|(v.shiftKey?4:0)|(v.metaKey?8:0)}d.getModifierString=function(v){return b.KEY_MODS[i(v)]};function c(v,p,y){var m=i(p);if(!y&&p.code&&(y=b.$codeToKeyCode[p.code]||y),!C.isMac&&A){if(p.getModifierState&&(p.getModifierState("OS")||p.getModifierState("Win"))&&(m|=8),A.altGr)if((3&m)!=3)A.altGr=0;else return;if(y===18||y===17){var $=p.location;if(y===17&&$===1)A[y]==1&&(a=p.timeStamp);else if(y===18&&m===3&&$===2){var N=p.timeStamp-a;N<50&&(A.altGr=!0)}}}if(y in b.MODIFIER_KEYS&&(y=-1),!(!m&&y===13&&p.location===3&&(v(p,m,-y),p.defaultPrevented))){if(C.isChromeOS&&m&8){if(v(p,m,y),p.defaultPrevented)return;m&=-9}return!m&&!(y in b.FUNCTION_KEYS)&&!(y in b.PRINTABLE_KEYS)?!1:v(p,m,y)}}d.addCommandKeyListener=function(v,p,y){var m=null;r(v,"keydown",function($){A[$.keyCode]=(A[$.keyCode]||0)+1;var N=c(p,$,$.keyCode);return m=$.defaultPrevented,N},y),r(v,"keypress",function($){m&&($.ctrlKey||$.altKey||$.shiftKey||$.metaKey)&&(d.stopEvent($),m=null)},y),r(v,"keyup",function($){A[$.keyCode]=null},y),A||(h(),r(window,"focus",h))};function h(){A=Object.create(null)}if(typeof window=="object"&&window.postMessage&&!C.isOldIE){var f=1;d.nextTick=function(v,p){p=p||window;var y="zero-timeout-message-"+f++,m=function($){$.data==y&&(d.stopPropagation($),t(p,"message",m),v())};r(p,"message",m),p.postMessage(y,"*")}}d.$idleBlocked=!1,d.onIdle=function(v,p){return setTimeout(function y(){d.$idleBlocked?setTimeout(y,100):v()},p)},d.$idleBlockId=null,d.blockIdle=function(v){d.$idleBlockId&&clearTimeout(d.$idleBlockId),d.$idleBlocked=!0,d.$idleBlockId=setTimeout(function(){d.$idleBlocked=!1},v||100)},d.nextFrame=typeof window=="object"&&(window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame),d.nextFrame?d.nextFrame=d.nextFrame.bind(window):d.nextFrame=function(v){setTimeout(v,17)}}),ace.define("ace/clipboard",["require","exports","module"],function(l,d,E){var b;E.exports={lineMode:!1,pasteCancelled:function(){return b&&b>Date.now()-50?!0:b=!1},cancel:function(){b=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(l,d,E){var b=l("../lib/event"),C=l("../config").nls,A=l("../lib/useragent"),a=l("../lib/dom"),g=l("../lib/lang"),n=l("../clipboard"),s=A.isChrome<18,o=A.isIE,r=A.isChrome>63,t=400,i=l("../lib/keys"),c=i.KEY_MODS,h=A.isIOS,f=h?/\s/:/\n/,v=A.isMobile,p;p=function(y,m){var $=a.createElement("textarea");$.className="ace_text-input",$.setAttribute("wrap","off"),$.setAttribute("autocorrect","off"),$.setAttribute("autocapitalize","off"),$.setAttribute("spellcheck","false"),$.style.opacity="0",y.insertBefore($,y.firstChild);var N=!1,M=!1,S=!1,O=!1,x="";v||($.style.fontSize="1px");var L=!1,I=!1,w="",_=0,T=0,k=0,R=Number.MAX_SAFE_INTEGER,D=Number.MIN_SAFE_INTEGER,V=0;try{var B=document.activeElement===$}catch{}this.setNumberOfExtraLines=function(P){if(R=Number.MAX_SAFE_INTEGER,D=Number.MIN_SAFE_INTEGER,P<0){V=0;return}V=P},this.setAriaLabel=function(){var P="";if(m.$textInputAriaLabel&&(P+="".concat(m.$textInputAriaLabel,", ")),m.session){var q=m.session.selection.cursor.row;P+=C("text-input.aria-label","Cursor at row $0",[q+1])}$.setAttribute("aria-label",P)},this.setAriaOptions=function(P){P.activeDescendant?($.setAttribute("aria-haspopup","true"),$.setAttribute("aria-autocomplete",P.inline?"both":"list"),$.setAttribute("aria-activedescendant",P.activeDescendant)):($.setAttribute("aria-haspopup","false"),$.setAttribute("aria-autocomplete","both"),$.removeAttribute("aria-activedescendant")),P.role&&$.setAttribute("role",P.role),P.setLabel&&($.setAttribute("aria-roledescription",C("text-input.aria-roledescription","editor")),this.setAriaLabel())},this.setAriaOptions({role:"textbox"}),b.addListener($,"blur",function(P){I||(m.onBlur(P),B=!1)},m),b.addListener($,"focus",function(P){if(!I){if(B=!0,A.isEdge)try{if(!document.hasFocus())return}catch{}m.onFocus(P),A.isEdge?setTimeout(H):H()}},m),this.$focusScroll=!1,this.focus=function(){if(this.setAriaOptions({setLabel:m.renderer.enableKeyboardAccessibility}),x||r||this.$focusScroll=="browser")return $.focus({preventScroll:!0});var P=$.style.top;$.style.position="fixed",$.style.top="0px";try{var q=$.getBoundingClientRect().top!=0}catch{return}var ee=[];if(q)for(var ie=$.parentElement;ie&&ie.nodeType==1;)ee.push(ie),ie.setAttribute("ace_nocontext","true"),!ie.parentElement&&ie.getRootNode?ie=ie.getRootNode().host:ie=ie.parentElement;$.focus({preventScroll:!0}),q&&ee.forEach(function(le){le.removeAttribute("ace_nocontext")}),setTimeout(function(){$.style.position="",$.style.top=="0px"&&($.style.top=P)},0)},this.blur=function(){$.blur()},this.isFocused=function(){return B},m.on("beforeEndOperation",function(){var P=m.curOp,q=P&&P.command&&P.command.name;if(q!="insertstring"){var ee=q&&(P.docChanged||P.selectionChanged);S&&ee&&(w=$.value="",W()),H()}}),m.on("changeSelection",this.setAriaLabel);var F=function(P,q){for(var ee=q,ie=1;ie<=P-R&&ie<2*V+1;ie++)ee+=m.session.getLine(P-ie).length+1;return ee},H=h?function(P){if(!(!B||N&&!P||O)){P||(P="");var q=`
172
+ ab`+P+`cde fg
173
+ `;q!=$.value&&($.value=w=q);var ee=4,ie=4+(P.length||(m.selection.isEmpty()?0:1));(_!=ee||T!=ie)&&$.setSelectionRange(ee,ie),_=ee,T=ie}}:function(){if(!(S||O)&&!(!B&&!Y)){S=!0;var P=0,q=0,ee="";if(m.session){var ie=m.selection,le=ie.getRange(),ue=ie.cursor.row;ue===D+1?(R=D+1,D=R+2*V):ue===R-1?(D=R-1,R=D-2*V):(ue<R-1||ue>D+1)&&(R=ue>V?ue-V:0,D=ue>V?ue+V:2*V);for(var de=[],pe=R;pe<=D;pe++)de.push(m.session.getLine(pe));if(ee=de.join(`
174
+ `),P=F(le.start.row,le.start.column),q=F(le.end.row,le.end.column),le.start.row<R){var he=m.session.getLine(R-1);P=le.start.row<R-1?0:P,q+=he.length+1,ee=he+`
175
+ `+ee}else if(le.end.row>D){var ce=m.session.getLine(D+1);q=le.end.row>D+1?ce.length:le.end.column,q+=ee.length+1,ee=ee+`
176
+ `+ce}else v&&ue>0&&(ee=`
177
+ `+ee,q+=1,P+=1);ee.length>t&&(P<t&&q<t?ee=ee.slice(0,t):(ee=`
178
+ `,P==q?P=q=0:(P=0,q=1)));var ve=ee+`
179
+
180
+ `;ve!=w&&($.value=w=ve,_=T=ve.length)}if(Y&&(_=$.selectionStart,T=$.selectionEnd),T!=q||_!=P||$.selectionEnd!=T)try{$.setSelectionRange(P,q),_=P,T=q}catch{}S=!1}};this.resetSelection=H,B&&m.onFocus();var U=function(P){return P.selectionStart===0&&P.selectionEnd>=w.length&&P.value===w&&w&&P.selectionEnd!==T},z=function(P){S||(N?N=!1:U($)?(m.selectAll(),H()):v&&$.selectionStart!=_&&H())},K=null;this.setInputHandler=function(P){K=P},this.getInputHandler=function(){return K};var Y=!1,Q=function(P,q){if(Y&&(Y=!1),M)return H(),P&&m.onPaste(P),M=!1,"";for(var ee=$.selectionStart,ie=$.selectionEnd,le=_,ue=w.length-T,de=P,pe=P.length-ee,he=P.length-ie,ce=0;le>0&&w[ce]==P[ce];)ce++,le--;for(de=de.slice(ce),ce=1;ue>0&&w.length-ce>_-1&&w[w.length-ce]==P[P.length-ce];)ce++,ue--;pe-=ce-1,he-=ce-1;var ve=de.length-ce+1;if(ve<0&&(le=-ve,ve=0),de=de.slice(0,ve),!q&&!de&&!pe&&!le&&!ue&&!he)return"";O=!0;var Ce=!1;return A.isAndroid&&de==". "&&(de=" ",Ce=!0),de&&!le&&!ue&&!pe&&!he||L?m.onTextInput(de):m.onTextInput(de,{extendLeft:le,extendRight:ue,restoreStart:pe,restoreEnd:he}),O=!1,w=P,_=ee,T=ie,k=he,Ce?`
181
+ `:de},J=function(P){if(S)return ye();if(P&&P.inputType){if(P.inputType=="historyUndo")return m.execCommand("undo");if(P.inputType=="historyRedo")return m.execCommand("redo")}var q=$.value,ee=Q(q,!0);(q.length>t+100||f.test(ee)||v&&_<1&&_==T)&&H()},ne=function(P,q,ee){var ie=P.clipboardData||window.clipboardData;if(!(!ie||s)){var le=o||ee?"Text":"text/plain";try{return q?ie.setData(le,q)!==!1:ie.getData(le)}catch(ue){if(!ee)return ne(ue,q,!0)}}},re=function(P,q){var ee=m.getCopyText();if(!ee)return b.preventDefault(P);ne(P,ee)?(h&&(H(ee),N=ee,setTimeout(function(){N=!1},10)),q?m.onCut():m.onCopy(),b.preventDefault(P)):(N=!0,$.value=ee,$.select(),setTimeout(function(){N=!1,H(),q?m.onCut():m.onCopy()}))},j=function(P){re(P,!0)},se=function(P){re(P,!1)},ae=function(P){var q=ne(P);n.pasteCancelled()||(typeof q=="string"?(q&&m.onPaste(q,P),A.isIE&&setTimeout(H),b.preventDefault(P)):($.value="",M=!0))};b.addCommandKeyListener($,function(P,q,ee){if(!S)return m.onCommandKey(P,q,ee)},m),b.addListener($,"select",z,m),b.addListener($,"input",J,m),b.addListener($,"cut",j,m),b.addListener($,"copy",se,m),b.addListener($,"paste",ae,m),(!("oncut"in $)||!("oncopy"in $)||!("onpaste"in $))&&b.addListener(y,"keydown",function(P){if(!(A.isMac&&!P.metaKey||!P.ctrlKey))switch(P.keyCode){case 67:se(P);break;case 86:ae(P);break;case 88:j(P);break}},m);var me=function(P){if(!(S||!m.onCompositionStart||m.$readOnly)&&(S={},!L)){P.data&&(S.useTextareaForIME=!1),setTimeout(ye,0),m._signal("compositionStart"),m.on("mousedown",G);var q=m.getSelectionRange();q.end.row=q.start.row,q.end.column=q.start.column,S.markerRange=q,S.selectionStart=_,m.onCompositionStart(S),S.useTextareaForIME?(w=$.value="",_=0,T=0):($.msGetInputContext&&(S.context=$.msGetInputContext()),$.getInputContext&&(S.context=$.getInputContext()))}},ye=function(){if(!(!S||!m.onCompositionUpdate||m.$readOnly)){if(L)return G();if(S.useTextareaForIME)m.onCompositionUpdate($.value);else{var P=$.value;Q(P),S.markerRange&&(S.context&&(S.markerRange.start.column=S.selectionStart=S.context.compositionStartOffset),S.markerRange.end.column=S.markerRange.start.column+T-S.selectionStart+k)}}},W=function(P){!m.onCompositionEnd||m.$readOnly||(S=!1,m.onCompositionEnd(),m.off("mousedown",G),P&&J())};function G(){I=!0,$.blur(),$.focus(),I=!1}var X=g.delayedCall(ye,50).schedule.bind(null,null);function te(P){P.keyCode==27&&$.value.length<$.selectionStart&&(S||(w=$.value),_=T=-1,H()),X()}b.addListener($,"compositionstart",me,m),b.addListener($,"compositionupdate",ye,m),b.addListener($,"keyup",te,m),b.addListener($,"keydown",X,m),b.addListener($,"compositionend",W,m),this.getElement=function(){return $},this.setCommandMode=function(P){L=P,$.readOnly=!1},this.setReadOnly=function(P){L||($.readOnly=P)},this.setCopyWithEmptySelection=function(P){},this.onContextMenu=function(P){Y=!0,H(),m._emit("nativecontextmenu",{target:m,domEvent:P}),this.moveToMouse(P,!0)},this.moveToMouse=function(P,q){x||(x=$.style.cssText),$.style.cssText=(q?"z-index:100000;":"")+(A.isIE?"opacity:0.1;":"")+"text-indent: -"+(_+T)*m.renderer.characterWidth*.5+"px;";var ee=m.container.getBoundingClientRect(),ie=a.computedStyle(m.container),le=ee.top+(parseInt(ie.borderTopWidth)||0),ue=ee.left+(parseInt(ie.borderLeftWidth)||0),de=ee.bottom-le-$.clientHeight-2,pe=function(he){a.translate($,he.clientX-ue-2,Math.min(he.clientY-le-2,de))};pe(P),P.type=="mousedown"&&(m.renderer.$isMousePressed=!0,clearTimeout(ge),A.isWin&&b.capture(m.container,pe,fe))},this.onContextMenuClose=fe;var ge;function fe(){clearTimeout(ge),ge=setTimeout(function(){x&&($.style.cssText=x,x=""),m.renderer.$isMousePressed=!1,m.renderer.$keepTextAreaAtCursor&&m.renderer.$moveTextAreaToCursor()},0)}var oe=function(P){m.textInput.onContextMenu(P),fe()};b.addListener($,"mouseup",oe,m),b.addListener($,"mousedown",function(P){P.preventDefault(),fe()},m),b.addListener(m.renderer.scroller,"contextmenu",oe,m),b.addListener($,"contextmenu",oe,m),h&&Z(y,m,$);function Z(P,q,ee){var ie=null,le=!1;ee.addEventListener("keydown",function(de){ie&&clearTimeout(ie),le=!0},!0),ee.addEventListener("keyup",function(de){ie=setTimeout(function(){le=!1},100)},!0);var ue=function(de){if(document.activeElement===ee&&!(le||S||q.$mouseHandler.isMousePressed)&&!N){var pe=ee.selectionStart,he=ee.selectionEnd,ce=null,ve=0;if(pe==0?ce=i.up:pe==1?ce=i.home:he>T&&w[he]==`
182
+ `?ce=i.end:pe<_&&w[pe-1]==" "?(ce=i.left,ve=c.option):pe<_||pe==_&&T!=_&&pe==he?ce=i.left:he>T&&w.slice(0,he).split(`
183
+ `).length>2?ce=i.down:he>T&&w[he-1]==" "?(ce=i.right,ve=c.option):(he>T||he==T&&T!=_&&pe==he)&&(ce=i.right),pe!==he&&(ve|=c.shift),ce){var Ce=q.onCommandKey({},ve,ce);if(!Ce&&q.commands){ce=i.keyCodeToString(ce);var be=q.commands.findKeyCommand(ve,ce);be&&q.execCommand(be)}_=pe,T=he,H("")}}};document.addEventListener("selectionchange",ue),q.on("destroy",function(){document.removeEventListener("selectionchange",ue)})}this.destroy=function(){$.parentElement&&$.parentElement.removeChild($)}},d.TextInput=p,d.$setUserAgentForTests=function(y,m){v=y,h=m}}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],function(l,d,E){var b=l("../lib/useragent"),C=0,A=550,a=function(){function s(o){o.$clickSelection=null;var r=o.editor;r.setDefaultHandler("mousedown",this.onMouseDown.bind(o)),r.setDefaultHandler("dblclick",this.onDoubleClick.bind(o)),r.setDefaultHandler("tripleclick",this.onTripleClick.bind(o)),r.setDefaultHandler("quadclick",this.onQuadClick.bind(o)),r.setDefaultHandler("mousewheel",this.onMouseWheel.bind(o));var t=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];t.forEach(function(i){o[i]=this[i]},this),o.selectByLines=this.extendSelectionBy.bind(o,"getLineRange"),o.selectByWords=this.extendSelectionBy.bind(o,"getWordRange")}return s.prototype.onMouseDown=function(o){var r=o.inSelection(),t=o.getDocumentPosition();this.mousedownEvent=o;var i=this.editor,c=o.getButton();if(c!==0){var h=i.getSelectionRange(),f=h.isEmpty();(f||c==1)&&i.selection.moveToPosition(t),c==2&&(i.textInput.onContextMenu(o.domEvent),b.isMozilla||o.preventDefault());return}if(this.mousedownEvent.time=Date.now(),r&&!i.isFocused()&&(i.focus(),this.$focusTimeout&&!this.$clickSelection&&!i.inMultiSelectMode)){this.setState("focusWait"),this.captureMouse(o);return}return this.captureMouse(o),this.startSelect(t,o.domEvent._clicks>1),o.preventDefault()},s.prototype.startSelect=function(o,r){o=o||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var t=this.editor;this.mousedownEvent&&(this.mousedownEvent.getShiftKey()?t.selection.selectToPosition(o):r||t.selection.moveToPosition(o),r||this.select(),t.setStyle("ace_selecting"),this.setState("select"))},s.prototype.select=function(){var o,r=this.editor,t=r.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var i=this.$clickSelection.comparePoint(t);if(i==-1)o=this.$clickSelection.end;else if(i==1)o=this.$clickSelection.start;else{var c=n(this.$clickSelection,t);t=c.cursor,o=c.anchor}r.selection.setSelectionAnchor(o.row,o.column)}r.selection.selectToPosition(t),r.renderer.scrollCursorIntoView()},s.prototype.extendSelectionBy=function(o){var r,t=this.editor,i=t.renderer.screenToTextCoordinates(this.x,this.y),c=t.selection[o](i.row,i.column);if(this.$clickSelection){var h=this.$clickSelection.comparePoint(c.start),f=this.$clickSelection.comparePoint(c.end);if(h==-1&&f<=0)r=this.$clickSelection.end,(c.end.row!=i.row||c.end.column!=i.column)&&(i=c.start);else if(f==1&&h>=0)r=this.$clickSelection.start,(c.start.row!=i.row||c.start.column!=i.column)&&(i=c.end);else if(h==-1&&f==1)i=c.end,r=c.start;else{var v=n(this.$clickSelection,i);i=v.cursor,r=v.anchor}t.selection.setSelectionAnchor(r.row,r.column)}t.selection.selectToPosition(i),t.renderer.scrollCursorIntoView()},s.prototype.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting")},s.prototype.focusWait=function(){var o=g(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),r=Date.now();(o>C||r-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},s.prototype.onDoubleClick=function(o){var r=o.getDocumentPosition(),t=this.editor,i=t.session,c=i.getBracketRange(r);c?(c.isEmpty()&&(c.start.column--,c.end.column++),this.setState("select")):(c=t.selection.getWordRange(r.row,r.column),this.setState("selectByWords")),this.$clickSelection=c,this.select()},s.prototype.onTripleClick=function(o){var r=o.getDocumentPosition(),t=this.editor;this.setState("selectByLines");var i=t.getSelectionRange();i.isMultiLine()&&i.contains(r.row,r.column)?(this.$clickSelection=t.selection.getLineRange(i.start.row),this.$clickSelection.end=t.selection.getLineRange(i.end.row).end):this.$clickSelection=t.selection.getLineRange(r.row),this.select()},s.prototype.onQuadClick=function(o){var r=this.editor;r.selectAll(),this.$clickSelection=r.getSelectionRange(),this.setState("selectAll")},s.prototype.onMouseWheel=function(o){if(!o.getAccelKey()){o.getShiftKey()&&o.wheelY&&!o.wheelX&&(o.wheelX=o.wheelY,o.wheelY=0);var r=this.editor;this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0});var t=this.$lastScroll,i=o.domEvent.timeStamp,c=i-t.t,h=c?o.wheelX/c:t.vx,f=c?o.wheelY/c:t.vy;c<A&&(h=(h+t.vx)/2,f=(f+t.vy)/2);var v=Math.abs(h/f),p=!1;if(v>=1&&r.renderer.isScrollableBy(o.wheelX*o.speed,0)&&(p=!0),v<=1&&r.renderer.isScrollableBy(0,o.wheelY*o.speed)&&(p=!0),p)t.allowed=i;else if(i-t.allowed<A){var y=Math.abs(h)<=1.5*Math.abs(t.vx)&&Math.abs(f)<=1.5*Math.abs(t.vy);y?(p=!0,t.allowed=i):t.allowed=0}if(t.t=i,t.vx=h,t.vy=f,p)return r.renderer.scrollBy(o.wheelX*o.speed,o.wheelY*o.speed),o.stop()}},s}();a.prototype.selectEnd=a.prototype.selectByLinesEnd,a.prototype.selectAllEnd=a.prototype.selectByLinesEnd,a.prototype.selectByWordsEnd=a.prototype.selectByLinesEnd,d.DefaultHandlers=a;function g(s,o,r,t){return Math.sqrt(Math.pow(r-s,2)+Math.pow(t-o,2))}function n(s,o){if(s.start.row==s.end.row)var r=2*o.column-s.start.column-s.end.column;else if(s.start.row==s.end.row-1&&!s.start.column&&!s.end.column)var r=o.column-4;else var r=2*o.row-s.start.row-s.end.row;return r<0?{cursor:s.start,anchor:s.end}:{cursor:s.end,anchor:s.start}}}),ace.define("ace/lib/scroll",["require","exports","module"],function(l,d,E){d.preventParentScroll=function(C){C.stopPropagation();var A=C.currentTarget,a=A.scrollHeight>A.clientHeight;a||C.preventDefault()}}),ace.define("ace/tooltip",["require","exports","module","ace/lib/dom","ace/lib/event","ace/range","ace/lib/scroll"],function(l,d,E){var b=this&&this.__extends||function(){var i=function(c,h){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,v){f.__proto__=v}||function(f,v){for(var p in v)Object.prototype.hasOwnProperty.call(v,p)&&(f[p]=v[p])},i(c,h)};return function(c,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");i(c,h);function f(){this.constructor=c}c.prototype=h===null?Object.create(h):(f.prototype=h.prototype,new f)}}(),C=this&&this.__values||function(i){var c=typeof Symbol=="function"&&Symbol.iterator,h=c&&i[c],f=0;if(h)return h.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&f>=i.length&&(i=void 0),{value:i&&i[f++],done:!i}}};throw new TypeError(c?"Object is not iterable.":"Symbol.iterator is not defined.")},A=l("./lib/dom");l("./lib/event");var a=l("./range").Range,g=l("./lib/scroll").preventParentScroll,n="ace_tooltip",s=function(){function i(c){this.isOpen=!1,this.$element=null,this.$parentNode=c}return i.prototype.$init=function(){return this.$element=A.createElement("div"),this.$element.className=n,this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},i.prototype.getElement=function(){return this.$element||this.$init()},i.prototype.setText=function(c){this.getElement().textContent=c},i.prototype.setHtml=function(c){this.getElement().innerHTML=c},i.prototype.setPosition=function(c,h){this.getElement().style.left=c+"px",this.getElement().style.top=h+"px"},i.prototype.setClassName=function(c){A.addCssClass(this.getElement(),c)},i.prototype.setTheme=function(c){this.$element.className=n+" "+(c.isDark?"ace_dark ":"")+(c.cssClass||"")},i.prototype.show=function(c,h,f){c!=null&&this.setText(c),h!=null&&f!=null&&this.setPosition(h,f),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},i.prototype.hide=function(c){this.isOpen&&(this.getElement().style.display="none",this.getElement().className=n,this.isOpen=!1)},i.prototype.getHeight=function(){return this.getElement().offsetHeight},i.prototype.getWidth=function(){return this.getElement().offsetWidth},i.prototype.destroy=function(){this.isOpen=!1,this.$element&&this.$element.parentNode&&this.$element.parentNode.removeChild(this.$element)},i}(),o=function(){function i(){this.popups=[]}return i.prototype.addPopup=function(c){this.popups.push(c),this.updatePopups()},i.prototype.removePopup=function(c){var h=this.popups.indexOf(c);h!==-1&&(this.popups.splice(h,1),this.updatePopups())},i.prototype.updatePopups=function(){var c,h,f,v;this.popups.sort(function(x,L){return L.priority-x.priority});var p=[];try{for(var y=C(this.popups),m=y.next();!m.done;m=y.next()){var $=m.value,N=!0;try{for(var M=(f=void 0,C(p)),S=M.next();!S.done;S=M.next()){var O=S.value;if(this.doPopupsOverlap(O,$)){N=!1;break}}}catch(x){f={error:x}}finally{try{S&&!S.done&&(v=M.return)&&v.call(M)}finally{if(f)throw f.error}}N?p.push($):$.hide()}}catch(x){c={error:x}}finally{try{m&&!m.done&&(h=y.return)&&h.call(y)}finally{if(c)throw c.error}}},i.prototype.doPopupsOverlap=function(c,h){var f=c.getElement().getBoundingClientRect(),v=h.getElement().getBoundingClientRect();return f.left<v.right&&f.right>v.left&&f.top<v.bottom&&f.bottom>v.top},i}(),r=new o;d.popupManager=r,d.Tooltip=s;var t=function(i){b(c,i);function c(h){h===void 0&&(h=document.body);var f=i.call(this,h)||this;f.timeout=void 0,f.lastT=0,f.idleTime=350,f.lastEvent=void 0,f.onMouseOut=f.onMouseOut.bind(f),f.onMouseMove=f.onMouseMove.bind(f),f.waitForHover=f.waitForHover.bind(f),f.hide=f.hide.bind(f);var v=f.getElement();return v.style.whiteSpace="pre-wrap",v.style.pointerEvents="auto",v.addEventListener("mouseout",f.onMouseOut),v.tabIndex=-1,v.addEventListener("blur",(function(){v.contains(document.activeElement)||this.hide()}).bind(f)),v.addEventListener("wheel",g),f}return c.prototype.addToEditor=function(h){h.on("mousemove",this.onMouseMove),h.on("mousedown",this.hide),h.renderer.getMouseEventTarget().addEventListener("mouseout",this.onMouseOut,!0)},c.prototype.removeFromEditor=function(h){h.off("mousemove",this.onMouseMove),h.off("mousedown",this.hide),h.renderer.getMouseEventTarget().removeEventListener("mouseout",this.onMouseOut,!0),this.timeout&&(clearTimeout(this.timeout),this.timeout=null)},c.prototype.onMouseMove=function(h,f){this.lastEvent=h,this.lastT=Date.now();var v=f.$mouseHandler.isMousePressed;if(this.isOpen){var p=this.lastEvent&&this.lastEvent.getDocumentPosition();(!this.range||!this.range.contains(p.row,p.column)||v||this.isOutsideOfText(this.lastEvent))&&this.hide()}this.timeout||v||(this.lastEvent=h,this.timeout=setTimeout(this.waitForHover,this.idleTime))},c.prototype.waitForHover=function(){this.timeout&&clearTimeout(this.timeout);var h=Date.now()-this.lastT;if(this.idleTime-h>10){this.timeout=setTimeout(this.waitForHover,this.idleTime-h);return}this.timeout=null,this.lastEvent&&!this.isOutsideOfText(this.lastEvent)&&this.$gatherData(this.lastEvent,this.lastEvent.editor)},c.prototype.isOutsideOfText=function(h){var f=h.editor,v=h.getDocumentPosition(),p=f.session.getLine(v.row);if(v.column==p.length){var y=f.renderer.pixelToScreenCoordinates(h.clientX,h.clientY),m=f.session.documentToScreenPosition(v.row,v.column);if(m.column!=y.column||m.row!=y.row)return!0}return!1},c.prototype.setDataProvider=function(h){this.$gatherData=h},c.prototype.showForRange=function(h,f,v,p){var y=10;if(!(p&&p!=this.lastEvent)&&!(this.isOpen&&document.activeElement==this.getElement())){var m=h.renderer;this.isOpen||(r.addPopup(this),this.$registerCloseEvents(),this.setTheme(m.theme)),this.isOpen=!0,this.addMarker(f,h.session),this.range=a.fromPoints(f.start,f.end);var $=m.textToScreenCoordinates(f.start.row,f.start.column),N=m.scroller.getBoundingClientRect();$.pageX<N.left&&($.pageX=N.left);var M=this.getElement();M.innerHTML="",M.appendChild(v),M.style.maxHeight="",M.style.display="block";var S=M.clientHeight,O=M.clientWidth,x=window.innerHeight-$.pageY-m.lineHeight,L=!0;$.pageY-S<0&&$.pageY<x&&(L=!1),M.style.maxHeight=(L?$.pageY:x)-y+"px",M.style.top=L?"":$.pageY+m.lineHeight+"px",M.style.bottom=L?window.innerHeight-$.pageY+"px":"",M.style.left=Math.min($.pageX,window.innerWidth-O-y)+"px"}},c.prototype.addMarker=function(h,f){this.marker&&this.$markerSession.removeMarker(this.marker),this.$markerSession=f,this.marker=f&&f.addMarker(h,"ace_highlight-marker","text")},c.prototype.hide=function(h){!h&&document.activeElement==this.getElement()||h&&h.target&&(h.type!="keydown"||h.ctrlKey||h.metaKey)&&this.$element.contains(h.target)||(this.lastEvent=null,this.timeout&&clearTimeout(this.timeout),this.timeout=null,this.addMarker(null),this.isOpen&&(this.$removeCloseEvents(),this.getElement().style.display="none",this.isOpen=!1,r.removePopup(this)))},c.prototype.$registerCloseEvents=function(){window.addEventListener("keydown",this.hide,!0),window.addEventListener("wheel",this.hide,!0),window.addEventListener("mousedown",this.hide,!0)},c.prototype.$removeCloseEvents=function(){window.removeEventListener("keydown",this.hide,!0),window.removeEventListener("wheel",this.hide,!0),window.removeEventListener("mousedown",this.hide,!0)},c.prototype.onMouseOut=function(h){this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.lastEvent=null,this.isOpen&&(!h.relatedTarget||this.getElement().contains(h.relatedTarget)||h&&h.currentTarget.contains(h.relatedTarget)||h.relatedTarget.classList.contains("ace_content")||this.hide())},c}(s);d.HoverTooltip=t}),ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/tooltip","ace/config"],function(l,d,E){var b=this&&this.__extends||function(){var i=function(c,h){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,v){f.__proto__=v}||function(f,v){for(var p in v)Object.prototype.hasOwnProperty.call(v,p)&&(f[p]=v[p])},i(c,h)};return function(c,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");i(c,h);function f(){this.constructor=c}c.prototype=h===null?Object.create(h):(f.prototype=h.prototype,new f)}}(),C=this&&this.__values||function(i){var c=typeof Symbol=="function"&&Symbol.iterator,h=c&&i[c],f=0;if(h)return h.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&f>=i.length&&(i=void 0),{value:i&&i[f++],done:!i}}};throw new TypeError(c?"Object is not iterable.":"Symbol.iterator is not defined.")},A=l("../lib/dom"),a=l("../lib/event"),g=l("../tooltip").Tooltip,n=l("../config").nls,s=5,o=3;d.GUTTER_TOOLTIP_LEFT_OFFSET=s,d.GUTTER_TOOLTIP_TOP_OFFSET=o;function r(i){var c=i.editor,h=c.renderer.$gutterLayer,f=new t(c,!0);i.editor.setDefaultHandler("guttermousedown",function(N){if(!(!c.isFocused()||N.getButton()!=0)){var M=h.getRegion(N);if(M!="foldWidgets"){var S=N.getDocumentPosition().row,O=c.session.selection;if(N.getShiftKey())O.selectTo(S,0);else{if(N.domEvent.detail==2)return c.selectAll(),N.preventDefault();i.$clickSelection=c.selection.getLineRange(S)}return i.setState("selectByLines"),i.captureMouse(N),N.preventDefault()}}});var v,p;function y(){var N=p.getDocumentPosition().row,M=c.session.getLength();if(N==M){var S=c.renderer.pixelToScreenCoordinates(0,p.y).row,O=p.$pos;if(S>c.session.documentToScreenRow(O.row,O.column))return m()}if(f.showTooltip(N),!!f.isOpen)if(c.on("mousewheel",m),c.on("changeSession",m),window.addEventListener("keydown",m,!0),i.$tooltipFollowsMouse)$(p);else{var x=p.getGutterRow(),L=h.$lines.get(x);if(L){var I=L.element.querySelector(".ace_gutter_annotation"),w=I.getBoundingClientRect(),_=f.getElement().style;_.left=w.right-s+"px",_.top=w.bottom-o+"px"}else $(p)}}function m(N){N&&N.type==="keydown"&&(N.ctrlKey||N.metaKey)||N&&N.type==="mouseout"&&(!N.relatedTarget||f.getElement().contains(N.relatedTarget))||(v&&(v=clearTimeout(v)),f.isOpen&&(f.hideTooltip(),c.off("mousewheel",m),c.off("changeSession",m),window.removeEventListener("keydown",m,!0)))}function $(N){f.setPosition(N.x,N.y)}i.editor.setDefaultHandler("guttermousemove",function(N){var M=N.domEvent.target||N.domEvent.srcElement;if(A.hasCssClass(M,"ace_fold-widget"))return m();f.isOpen&&i.$tooltipFollowsMouse&&$(N),p=N,!v&&(v=setTimeout(function(){v=null,p&&!i.isMousePressed&&y()},50))}),a.addListener(c.renderer.$gutter,"mouseout",function(N){p=null,f.isOpen&&(v=setTimeout(function(){v=null,m(N)},50))},c)}d.GutterHandler=r;var t=function(i){b(c,i);function c(h,f){f===void 0&&(f=!1);var v=i.call(this,h.container)||this;v.editor=h,v.visibleTooltipRow;var p=v.getElement();return p.setAttribute("role","tooltip"),p.style.pointerEvents="auto",f&&(v.onMouseOut=v.onMouseOut.bind(v),p.addEventListener("mouseout",v.onMouseOut)),v}return c.prototype.onMouseOut=function(h){this.isOpen&&(!h.relatedTarget||this.getElement().contains(h.relatedTarget)||h&&h.currentTarget.contains(h.relatedTarget)||this.hideTooltip())},c.prototype.setPosition=function(h,f){var v=window.innerWidth||document.documentElement.clientWidth,p=window.innerHeight||document.documentElement.clientHeight,y=this.getWidth(),m=this.getHeight();h+=15,f+=15,h+y>v&&(h-=h+y-v),f+m>p&&(f-=20+m),g.prototype.setPosition.call(this,h,f)},Object.defineProperty(c,"annotationLabels",{get:function(){return{error:{singular:n("gutter-tooltip.aria-label.error.singular","error"),plural:n("gutter-tooltip.aria-label.error.plural","errors")},security:{singular:n("gutter-tooltip.aria-label.security.singular","security finding"),plural:n("gutter-tooltip.aria-label.security.plural","security findings")},warning:{singular:n("gutter-tooltip.aria-label.warning.singular","warning"),plural:n("gutter-tooltip.aria-label.warning.plural","warnings")},info:{singular:n("gutter-tooltip.aria-label.info.singular","information message"),plural:n("gutter-tooltip.aria-label.info.plural","information messages")},hint:{singular:n("gutter-tooltip.aria-label.hint.singular","suggestion"),plural:n("gutter-tooltip.aria-label.hint.plural","suggestions")}}},enumerable:!1,configurable:!0}),c.prototype.showTooltip=function(h){var f,v=this.editor.renderer.$gutterLayer,p=v.$annotations[h],y;p?y={displayText:Array.from(p.displayText),type:Array.from(p.type)}:y={displayText:[],type:[]};var m=v.session.getFoldLine(h);if(m&&v.$showFoldedAnnotations){for(var $={error:[],security:[],warning:[],info:[],hint:[]},N={error:1,security:2,warning:3,info:4,hint:5},M,S=h+1;S<=m.end.row;S++)if(v.$annotations[S])for(var O=0;O<v.$annotations[S].text.length;O++){var x=v.$annotations[S].type[O];$[x].push(v.$annotations[S].text[O]),(!M||N[x]<N[M])&&(M=x)}if(["error","security","warning"].includes(M)){var L="".concat(c.annotationsToSummaryString($)," in folded code.");y.displayText.push(L),y.type.push(M+"_fold")}}if(y.displayText.length===0)return this.hideTooltip();for(var I={error:[],security:[],warning:[],info:[],hint:[]},w=v.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",S=0;S<y.displayText.length;S++){var _=A.createElement("span"),T=A.createElement("span");(f=T.classList).add.apply(f,["ace_".concat(y.type[S]),w]),T.setAttribute("aria-label","".concat(c.annotationLabels[y.type[S].replace("_fold","")].singular)),T.setAttribute("role","img"),T.appendChild(A.createTextNode(" ")),_.appendChild(T),_.appendChild(A.createTextNode(y.displayText[S])),_.appendChild(A.createElement("br")),I[y.type[S].replace("_fold","")].push(_)}var k=this.getElement();A.removeChildren(k),I.error.forEach(function(R){return k.appendChild(R)}),I.security.forEach(function(R){return k.appendChild(R)}),I.warning.forEach(function(R){return k.appendChild(R)}),I.info.forEach(function(R){return k.appendChild(R)}),I.hint.forEach(function(R){return k.appendChild(R)}),k.setAttribute("aria-live","polite"),this.isOpen||(this.setTheme(this.editor.renderer.theme),this.setClassName("ace_gutter-tooltip")),this.show(),this.visibleTooltipRow=h,this.editor._signal("showGutterTooltip",this)},c.prototype.hideTooltip=function(){this.isOpen&&(this.$element.removeAttribute("aria-live"),this.hide(),this.visibleTooltipRow=void 0,this.editor._signal("hideGutterTooltip",this))},c.annotationsToSummaryString=function(h){var f,v,p=[],y=["error","security","warning","info","hint"];try{for(var m=C(y),$=m.next();!$.done;$=m.next()){var N=$.value;if(h[N].length){var M=h[N].length===1?c.annotationLabels[N].singular:c.annotationLabels[N].plural;p.push("".concat(h[N].length," ").concat(M))}}}catch(S){f={error:S}}finally{try{$&&!$.done&&(v=m.return)&&v.call(m)}finally{if(f)throw f.error}}return p.join(", ")},c}(g);d.GutterTooltip=t}),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(l,d,E){var b=l("../lib/event"),C=l("../lib/useragent"),A=function(){function a(g,n){this.speed,this.wheelX,this.wheelY,this.domEvent=g,this.editor=n,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 a.prototype.stopPropagation=function(){b.stopPropagation(this.domEvent),this.propagationStopped=!0},a.prototype.preventDefault=function(){b.preventDefault(this.domEvent),this.defaultPrevented=!0},a.prototype.stop=function(){this.stopPropagation(),this.preventDefault()},a.prototype.getDocumentPosition=function(){return this.$pos?this.$pos:(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY),this.$pos)},a.prototype.getGutterRow=function(){var g=this.getDocumentPosition().row,n=this.editor.session.documentToScreenRow(g,0),s=this.editor.session.documentToScreenRow(this.editor.renderer.$gutterLayer.$lines.get(0).row,0);return n-s},a.prototype.inSelection=function(){if(this.$inSelection!==null)return this.$inSelection;var g=this.editor,n=g.getSelectionRange();if(n.isEmpty())this.$inSelection=!1;else{var s=this.getDocumentPosition();this.$inSelection=n.contains(s.row,s.column)}return this.$inSelection},a.prototype.getButton=function(){return b.getButton(this.domEvent)},a.prototype.getShiftKey=function(){return this.domEvent.shiftKey},a.prototype.getAccelKey=function(){return C.isMac?this.domEvent.metaKey:this.domEvent.ctrlKey},a}();d.MouseEvent=A}),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(l,d,E){var b=l("../lib/dom"),C=l("../lib/event"),A=l("../lib/useragent"),a=200,g=200,n=5;function s(r){var t=r.editor,i=b.createElement("div");i.style.cssText="top:-100px;position:absolute;z-index:2147483647;opacity:0.5",i.textContent=" ";var c=["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"];c.forEach(function(F){r[F]=this[F]},this),t.on("mousedown",this.onMouseDown.bind(r));var h=t.container,f,v,p,y,m,$,N=0,M,S,O,x,L;this.onDragStart=function(F){if(this.cancelDrag||!h.draggable){var H=this;return setTimeout(function(){H.startSelect(),H.captureMouse(F)},0),F.preventDefault()}m=t.getSelectionRange();var U=F.dataTransfer;U.effectAllowed=t.getReadOnly()?"copy":"copyMove",t.container.appendChild(i),U.setDragImage&&U.setDragImage(i,0,0),setTimeout(function(){t.container.removeChild(i)}),U.clearData(),U.setData("Text",t.session.getTextRange()),S=!0,this.setState("drag")},this.onDragEnd=function(F){if(h.draggable=!1,S=!1,this.setState(null),!t.getReadOnly()){var H=F.dataTransfer.dropEffect;!M&&H=="move"&&t.session.remove(t.getSelectionRange()),t.$resetCursorStyle()}this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(F){if(!(t.getReadOnly()||!V(F.dataTransfer)))return v=F.clientX,p=F.clientY,f||T(),N++,F.dataTransfer.dropEffect=M=B(F),C.preventDefault(F)},this.onDragOver=function(F){if(!(t.getReadOnly()||!V(F.dataTransfer)))return v=F.clientX,p=F.clientY,f||(T(),N++),R!==null&&(R=null),F.dataTransfer.dropEffect=M=B(F),C.preventDefault(F)},this.onDragLeave=function(F){if(N--,N<=0&&f)return k(),M=null,C.preventDefault(F)},this.onDrop=function(F){if($){var H=F.dataTransfer;if(S)switch(M){case"move":m.contains($.row,$.column)?m={start:$,end:$}:m=t.moveText(m,$);break;case"copy":m=t.moveText(m,$,!0);break}else{var U=H.getData("Text");m={start:$,end:t.session.insert($,U)},t.focus(),M=null}return k(),C.preventDefault(F)}},C.addListener(h,"dragstart",this.onDragStart.bind(r),t),C.addListener(h,"dragend",this.onDragEnd.bind(r),t),C.addListener(h,"dragenter",this.onDragEnter.bind(r),t),C.addListener(h,"dragover",this.onDragOver.bind(r),t),C.addListener(h,"dragleave",this.onDragLeave.bind(r),t),C.addListener(h,"drop",this.onDrop.bind(r),t);function I(F,H){var U=Date.now(),z=!H||F.row!=H.row,K=!H||F.column!=H.column;if(!x||z||K)t.moveCursorToPosition(F),x=U,L={x:v,y:p};else{var Y=o(L.x,L.y,v,p);Y>n?x=null:U-x>=g&&(t.renderer.scrollCursorIntoView(),x=null)}}function w(F,H){var U=Date.now(),z=t.renderer.layerConfig.lineHeight,K=t.renderer.layerConfig.characterWidth,Y=t.renderer.scroller.getBoundingClientRect(),Q={x:{left:v-Y.left,right:Y.right-v},y:{top:p-Y.top,bottom:Y.bottom-p}},J=Math.min(Q.x.left,Q.x.right),ne=Math.min(Q.y.top,Q.y.bottom),re={row:F.row,column:F.column};J/K<=2&&(re.column+=Q.x.left<Q.x.right?-3:2),ne/z<=1&&(re.row+=Q.y.top<Q.y.bottom?-1:1);var j=F.row!=re.row,se=F.column!=re.column,ae=!H||F.row!=H.row;j||se&&!ae?O?U-O>=a&&t.renderer.scrollCursorIntoView(re):O=U:O=null}function _(){var F=$;$=t.renderer.screenToTextCoordinates(v,p),I($,F),w($,F)}function T(){m=t.selection.toOrientedRange(),f=t.session.addMarker(m,"ace_selection",t.getSelectionStyle()),t.clearSelection(),t.isFocused()&&t.renderer.$cursorLayer.setBlinking(!1),clearInterval(y),_(),y=setInterval(_,20),N=0,C.addListener(document,"mousemove",D)}function k(){clearInterval(y),t.session.removeMarker(f),f=null,t.selection.fromOrientedRange(m),t.isFocused()&&!S&&t.$resetCursorStyle(),m=null,$=null,N=0,O=null,x=null,C.removeListener(document,"mousemove",D)}var R=null;function D(){R==null&&(R=setTimeout(function(){R!=null&&f&&k()},20))}function V(F){var H=F.types;return!H||Array.prototype.some.call(H,function(U){return U=="text/plain"||U=="Text"})}function B(F){var H=["copy","copymove","all","uninitialized"],U=["move","copymove","linkmove","all","uninitialized"],z=A.isMac?F.altKey:F.ctrlKey,K="uninitialized";try{K=F.dataTransfer.effectAllowed.toLowerCase()}catch{}var Y="none";return z&&H.indexOf(K)>=0?Y="copy":U.indexOf(K)>=0?Y="move":H.indexOf(K)>=0&&(Y="copy"),Y}}(function(){this.dragWait=function(){var r=Date.now()-this.mousedownEvent.time;r>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var r=this.editor.container;r.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(r){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var r=this.editor,t=r.container;t.draggable=!0,r.renderer.$cursorLayer.setBlinking(!1),r.setStyle("ace_dragging");var i=A.isWin?"default":"move";r.renderer.setCursorStyle(i),this.setState("dragReady")},this.onMouseDrag=function(r){var t=this.editor.container;if(A.isIE&&this.state=="dragReady"){var i=o(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);i>3&&t.dragDrop()}if(this.state==="dragWait"){var i=o(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);i>0&&(t.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(r){if(this.$dragEnabled){this.mousedownEvent=r;var t=this.editor,i=r.inSelection(),c=r.getButton(),h=r.domEvent.detail||1;if(h===1&&c===0&&i){if(r.editor.inMultiSelectMode&&(r.getAccelKey()||r.getShiftKey()))return;this.mousedownEvent.time=Date.now();var f=r.domEvent.target||r.domEvent.srcElement;if("unselectable"in f&&(f.unselectable="on"),t.getDragDelay()){if(A.isWebKit){this.cancelDrag=!0;var v=t.container;v.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(r,this.onMouseDrag.bind(this)),r.defaultPrevented=!0}}}}).call(s.prototype);function o(r,t,i,c){return Math.sqrt(Math.pow(i-r,2)+Math.pow(c-t,2))}d.DragdropHandler=s}),ace.define("ace/mouse/touch_handler",["require","exports","module","ace/mouse/mouse_event","ace/lib/event","ace/lib/dom"],function(l,d,E){var b=l("./mouse_event").MouseEvent,C=l("../lib/event"),A=l("../lib/dom");d.addTouchListeners=function(a,g){var n="scroll",s,o,r,t,i,c,h=0,f,v=0,p=0,y=0,m,$;function N(){var I=window.navigator&&window.navigator.clipboard,w=!1,_=function(){var R=g.getCopyText(),D=g.session.getUndoManager().hasUndo();$.replaceChild(A.buildDom(w?["span",!R&&T("selectall")&&["span",{class:"ace_mobile-button",action:"selectall"},"Select All"],R&&T("copy")&&["span",{class:"ace_mobile-button",action:"copy"},"Copy"],R&&T("cut")&&["span",{class:"ace_mobile-button",action:"cut"},"Cut"],I&&T("paste")&&["span",{class:"ace_mobile-button",action:"paste"},"Paste"],D&&T("undo")&&["span",{class:"ace_mobile-button",action:"undo"},"Undo"],T("find")&&["span",{class:"ace_mobile-button",action:"find"},"Find"],T("openCommandPalette")&&["span",{class:"ace_mobile-button",action:"openCommandPalette"},"Palette"]]:["span"]),$.firstChild)},T=function(R){return g.commands.canExecute(R,g)},k=function(R){var D=R.target.getAttribute("action");if(D=="more"||!w)return w=!w,_();D=="paste"?I.readText().then(function(V){g.execCommand(D,V)}):D&&((D=="cut"||D=="copy")&&(I?I.writeText(g.getCopyText()):document.execCommand("copy")),g.execCommand(D)),$.firstChild.style.display="none",w=!1,D!="openCommandPalette"&&g.focus()};$=A.buildDom(["div",{class:"ace_mobile-menu",ontouchstart:function(R){n="menu",R.stopPropagation(),R.preventDefault(),g.textInput.focus()},ontouchend:function(R){R.stopPropagation(),R.preventDefault(),k(R)},onclick:k},["span"],["span",{class:"ace_mobile-button",action:"more"},"..."]],g.container)}function M(){if(!g.getOption("enableMobileMenu")){$&&S();return}$||N();var I=g.selection.cursor,w=g.renderer.textToScreenCoordinates(I.row,I.column),_=g.renderer.textToScreenCoordinates(0,0).pageX,T=g.renderer.scrollLeft,k=g.container.getBoundingClientRect();$.style.top=w.pageY-k.top-3+"px",w.pageX-k.left<k.width-70?($.style.left="",$.style.right="10px"):($.style.right="",$.style.left=_+T-k.left+"px"),$.style.display="",$.firstChild.style.display="none",g.on("input",S)}function S(I){$&&($.style.display="none"),g.off("input",S)}function O(){i=null,clearTimeout(i);var I=g.selection.getRange(),w=I.contains(f.row,f.column);(I.isEmpty()||!w)&&(g.selection.moveToPosition(f),g.selection.selectWord()),n="wait",M()}function x(){i=null,clearTimeout(i),g.selection.moveToPosition(f);var I=v>=2?g.selection.getLineRange(f.row):g.session.getBracketRange(f);I&&!I.isEmpty()?g.selection.setRange(I):g.selection.selectWord(),n="wait"}C.addListener(a,"contextmenu",function(I){if(m){var w=g.textInput.getElement();w.focus()}},g),C.addListener(a,"touchstart",function(I){var w=I.touches;if(i||w.length>1){clearTimeout(i),i=null,r=-1,n="zoom";return}m=g.$mouseHandler.isMousePressed=!0;var _=g.renderer.layerConfig.lineHeight,T=g.renderer.layerConfig.lineHeight,k=I.timeStamp;t=k;var R=w[0],D=R.clientX,V=R.clientY;Math.abs(s-D)+Math.abs(o-V)>_&&(r=-1),s=I.clientX=D,o=I.clientY=V,p=y=0;var B=new b(I,g);if(f=B.getDocumentPosition(),k-r<500&&w.length==1&&!h)v++,I.preventDefault(),I.button=0,x();else{v=0;var F=g.selection.cursor,H=g.selection.isEmpty()?F:g.selection.anchor,U=g.renderer.$cursorLayer.getPixelPosition(F,!0),z=g.renderer.$cursorLayer.getPixelPosition(H,!0),K=g.renderer.scroller.getBoundingClientRect(),Y=g.renderer.layerConfig.offset,Q=g.renderer.scrollLeft,J=function(j,se){return j=j/T,se=se/_-.75,j*j+se*se};if(I.clientX<K.left){n="zoom";return}var ne=J(I.clientX-K.left-U.left+Q,I.clientY-K.top-U.top+Y),re=J(I.clientX-K.left-z.left+Q,I.clientY-K.top-z.top+Y);ne<3.5&&re<3.5&&(n=ne>re?"cursor":"anchor"),re<3.5?n="anchor":ne<3.5?n="cursor":n="scroll",i=setTimeout(O,450)}r=k},g),C.addListener(a,"touchend",function(I){m=g.$mouseHandler.isMousePressed=!1,c&&clearInterval(c),n=="zoom"?(n="",h=0):i?(g.selection.moveToPosition(f),h=0,M()):n=="scroll"?(L(),S()):M(),clearTimeout(i),i=null},g),C.addListener(a,"touchmove",function(I){i&&(clearTimeout(i),i=null);var w=I.touches;if(!(w.length>1||n=="zoom")){var _=w[0],T=s-_.clientX,k=o-_.clientY;if(n=="wait")if(T*T+k*k>4)n="cursor";else return I.preventDefault();s=_.clientX,o=_.clientY,I.clientX=_.clientX,I.clientY=_.clientY;var R=I.timeStamp,D=R-t;if(t=R,n=="scroll"){var V=new b(I,g);V.speed=1,V.wheelX=T,V.wheelY=k,10*Math.abs(T)<Math.abs(k)&&(T=0),10*Math.abs(k)<Math.abs(T)&&(k=0),D!=0&&(p=T/D,y=k/D),g._emit("mousewheel",V),V.propagationStopped||(p=y=0)}else{var B=new b(I,g),F=B.getDocumentPosition();n=="cursor"?g.selection.moveCursorToPosition(F):n=="anchor"&&g.selection.setSelectionAnchor(F.row,F.column),g.renderer.scrollCursorIntoView(F),I.preventDefault()}}},g);function L(){h+=60,c=setInterval(function(){h--<=0&&(clearInterval(c),c=null),Math.abs(p)<.01&&(p=0),Math.abs(y)<.01&&(y=0),h<20&&(p=.9*p),h<20&&(y=.9*y);var I=g.session.getScrollTop();g.renderer.scrollBy(10*p,10*y),I==g.session.getScrollTop()&&(h=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(l,d,E){var b=l("../lib/event"),C=l("../lib/useragent"),A=l("./default_handlers").DefaultHandlers,a=l("./default_gutter_handler").GutterHandler,g=l("./mouse_event").MouseEvent,n=l("./dragdrop_handler").DragdropHandler,s=l("./touch_handler").addTouchListeners,o=l("../config"),r=function(){function t(i){this.$dragDelay,this.$dragEnabled,this.$mouseMoved,this.mouseEvent,this.$focusTimeout;var c=this;this.editor=i,new A(this),new a(this),new n(this);var h=function(p){var y=!document.hasFocus||!document.hasFocus()||!i.isFocused()&&document.activeElement==(i.textInput&&i.textInput.getElement());y&&window.focus(),i.focus(),setTimeout(function(){i.isFocused()||i.focus()})},f=i.renderer.getMouseEventTarget();b.addListener(f,"click",this.onMouseEvent.bind(this,"click"),i),b.addListener(f,"mousemove",this.onMouseMove.bind(this,"mousemove"),i),b.addMultiMouseDownListener([f,i.renderer.scrollBarV&&i.renderer.scrollBarV.inner,i.renderer.scrollBarH&&i.renderer.scrollBarH.inner,i.textInput&&i.textInput.getElement()].filter(Boolean),[400,300,250],this,"onMouseEvent",i),b.addMouseWheelListener(i.container,this.onMouseWheel.bind(this,"mousewheel"),i),s(i.container,i);var v=i.renderer.$gutter;b.addListener(v,"mousedown",this.onMouseEvent.bind(this,"guttermousedown"),i),b.addListener(v,"click",this.onMouseEvent.bind(this,"gutterclick"),i),b.addListener(v,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick"),i),b.addListener(v,"mousemove",this.onMouseEvent.bind(this,"guttermousemove"),i),b.addListener(f,"mousedown",h,i),b.addListener(v,"mousedown",h,i),C.isIE&&i.renderer.scrollBarV&&(b.addListener(i.renderer.scrollBarV.element,"mousedown",h,i),b.addListener(i.renderer.scrollBarH.element,"mousedown",h,i)),i.on("mousemove",function(p){if(!(c.state||c.$dragDelay||!c.$dragEnabled)){var y=i.renderer.screenToTextCoordinates(p.x,p.y),m=i.session.selection.getRange(),$=i.renderer;!m.isEmpty()&&m.insideStart(y.row,y.column)?$.setCursorStyle("default"):$.setCursorStyle("")}},i)}return t.prototype.onMouseEvent=function(i,c){this.editor.session&&this.editor._emit(i,new g(c,this.editor))},t.prototype.onMouseMove=function(i,c){var h=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;!h||!h.length||this.editor._emit(i,new g(c,this.editor))},t.prototype.onMouseWheel=function(i,c){var h=new g(c,this.editor);h.speed=this.$scrollSpeed*2,h.wheelX=c.wheelX,h.wheelY=c.wheelY,this.editor._emit(i,h)},t.prototype.setState=function(i){this.state=i},t.prototype.captureMouse=function(i,c){this.x=i.x,this.y=i.y,this.isMousePressed=!0;var h=this.editor,f=this.editor.renderer;f.$isMousePressed=!0;var v=this,p=function(M){if(M){if(C.isWebKit&&!M.which&&v.releaseMouse)return v.releaseMouse();v.x=M.clientX,v.y=M.clientY,c&&c(M),v.mouseEvent=new g(M,v.editor),v.$mouseMoved=!0}},y=function(M){h.off("beforeEndOperation",$),clearInterval(N),h.session&&m(),v[v.state+"End"]&&v[v.state+"End"](M),v.state="",v.isMousePressed=f.$isMousePressed=!1,f.$keepTextAreaAtCursor&&f.$moveTextAreaToCursor(),v.$onCaptureMouseMove=v.releaseMouse=null,M&&v.onMouseEvent("mouseup",M),h.endOperation()},m=function(){v[v.state]&&v[v.state](),v.$mouseMoved=!1};if(C.isOldIE&&i.domEvent.type=="dblclick")return setTimeout(function(){y(i)});var $=function(M){v.releaseMouse&&h.curOp.command.name&&h.curOp.selectionChanged&&(v[v.state+"End"]&&v[v.state+"End"](),v.state="",v.releaseMouse())};h.on("beforeEndOperation",$),h.startOperation({command:{name:"mouse"}}),v.$onCaptureMouseMove=p,v.releaseMouse=b.capture(this.editor.container,p,y);var N=setInterval(m,20)},t.prototype.cancelContextMenu=function(){var i=(function(c){c&&c.domEvent&&c.domEvent.type!="contextmenu"||(this.editor.off("nativecontextmenu",i),c&&c.domEvent&&b.stopEvent(c.domEvent))}).bind(this);setTimeout(i,10),this.editor.on("nativecontextmenu",i)},t.prototype.destroy=function(){this.releaseMouse&&this.releaseMouse()},t}();r.prototype.releaseMouse=null,o.defineOptions(r.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:C.isMac?150:0},dragEnabled:{initialValue:!0},focusTimeout:{initialValue:0},tooltipFollowsMouse:{initialValue:!0}}),d.MouseHandler=r}),ace.define("ace/mouse/fold_handler",["require","exports","module","ace/lib/dom"],function(l,d,E){var b=l("../lib/dom"),C=function(){function A(a){a.on("click",function(g){var n=g.getDocumentPosition(),s=a.session,o=s.getFoldAt(n.row,n.column,1);o&&(g.getAccelKey()?s.removeFold(o):s.expandFold(o),g.stop());var r=g.domEvent&&g.domEvent.target;r&&b.hasCssClass(r,"ace_inline_button")&&b.hasCssClass(r,"ace_toggle_wrap")&&(s.setOption("wrap",!s.getUseWrapMode()),a.renderer.scrollCursorIntoView())}),a.on("gutterclick",function(g){var n=a.renderer.$gutterLayer.getRegion(g);if(n=="foldWidgets"){var s=g.getDocumentPosition().row,o=a.session;o.foldWidgets&&o.foldWidgets[s]&&a.session.onFoldWidgetClick(s,g),a.isFocused()||a.focus(),g.stop()}}),a.on("gutterdblclick",function(g){var n=a.renderer.$gutterLayer.getRegion(g);if(n=="foldWidgets"){var s=g.getDocumentPosition().row,o=a.session,r=o.getParentFoldRangeData(s,!0),t=r.range||r.firstRange;if(t){s=t.start.row;var i=o.getFoldAt(s,o.getLine(s).length,1);i?o.removeFold(i):(o.addFold("...",t),a.renderer.scrollCursorIntoView({row:t.start.row,column:0}))}g.stop()}})}return A}();d.FoldHandler=C}),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],function(l,d,E){var b=l("../lib/keys"),C=l("../lib/event"),A=function(){function a(g){this.$editor=g,this.$data={editor:g},this.$handlers=[],this.setDefaultHandler(g.commands)}return a.prototype.setDefaultHandler=function(g){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=g,this.addKeyboardHandler(g,0)},a.prototype.setKeyboardHandler=function(g){var n=this.$handlers;if(n[n.length-1]!=g){for(;n[n.length-1]&&n[n.length-1]!=this.$defaultHandler;)this.removeKeyboardHandler(n[n.length-1]);this.addKeyboardHandler(g,1)}},a.prototype.addKeyboardHandler=function(g,n){if(g){typeof g=="function"&&!g.handleKeyboard&&(g.handleKeyboard=g);var s=this.$handlers.indexOf(g);s!=-1&&this.$handlers.splice(s,1),n==null?this.$handlers.push(g):this.$handlers.splice(n,0,g),s==-1&&g.attach&&g.attach(this.$editor)}},a.prototype.removeKeyboardHandler=function(g){var n=this.$handlers.indexOf(g);return n==-1?!1:(this.$handlers.splice(n,1),g.detach&&g.detach(this.$editor),!0)},a.prototype.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},a.prototype.getStatusText=function(){var g=this.$data,n=g.editor;return this.$handlers.map(function(s){return s.getStatusText&&s.getStatusText(n,g)||""}).filter(Boolean).join(" ")},a.prototype.$callKeyboardHandlers=function(g,n,s,o){for(var r,t=!1,i=this.$editor.commands,c=this.$handlers.length;c--&&(r=this.$handlers[c].handleKeyboard(this.$data,g,n,s,o),!(!(!r||!r.command)&&(r.command=="null"?t=!0:t=i.exec(r.command,this.$editor,r.args,o),t&&o&&g!=-1&&r.passEvent!=!0&&r.command.passEvent!=!0&&C.stopEvent(o),t))););return!t&&g==-1&&(r={command:"insertstring"},t=i.exec("insertstring",this.$editor,n)),t&&this.$editor._signal&&this.$editor._signal("keyboardActivity",r),t},a.prototype.onCommandKey=function(g,n,s){var o=b.keyCodeToString(s);return this.$callKeyboardHandlers(n,o,s,g)},a.prototype.onTextInput=function(g){return this.$callKeyboardHandlers(-1,g)},a}();d.KeyBinding=A}),ace.define("ace/lib/bidiutil",["require","exports","module"],function(l,d,E){var b=0,C=0,A=!1,a=!1,g=!1,n=[[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]],s=[[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]],o=0,r=1,t=0,i=1,c=2,h=3,f=4,v=5,p=6,y=7,m=8,$=9,N=10,M=11,S=12,O=13,x=14,L=15,I=16,w=17,_=18,T=[_,_,_,_,_,_,_,_,_,p,v,p,m,v,_,_,_,_,_,_,_,_,_,_,_,_,_,_,v,v,v,p,m,f,f,M,M,M,f,f,f,f,f,N,$,N,$,$,c,c,c,c,c,c,c,c,c,c,$,f,f,f,f,f,f,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,f,f,f,f,f,f,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,f,f,f,f,_,_,_,_,_,_,v,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,$,f,M,M,M,M,f,f,f,f,t,f,f,_,f,f,M,M,c,c,f,t,f,f,f,c,t,f,f,f,f,f],k=[m,m,m,m,m,m,m,m,m,m,m,_,_,_,t,i,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,m,v,O,x,L,I,w,$,M,M,M,M,M,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,$,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,m];function R(F,H,U,z){var K=b?s:n,Y=null,Q=null,J=null,ne=0,re=null,j=null,se=-1,ae=null,me=null,ye=[];if(!z)for(ae=0,z=[];ae<U;ae++)z[ae]=B(F[ae]);for(C=b,A=!1,a=!1,g=!1,me=0;me<U;me++){if(Y=ne,ye[me]=Q=V(F,z,ye,me),ne=K[Y][Q],re=ne&240,ne&=15,H[me]=J=K[ne][5],re>0)if(re==16){for(ae=se;ae<me;ae++)H[ae]=1;se=-1}else se=-1;if(j=K[ne][6],j)se==-1&&(se=me);else if(se>-1){for(ae=se;ae<me;ae++)H[ae]=J;se=-1}z[me]==v&&(H[me]=0),C|=J}if(g){for(ae=0;ae<U;ae++)if(z[ae]==p){H[ae]=b;for(var W=ae-1;W>=0&&z[W]==m;W--)H[W]=b}}}function D(F,H,U){if(!(C<F)){if(F==1&&b==r&&!a){U.reverse();return}for(var z=U.length,K=0,Y,Q,J,ne;K<z;){if(H[K]>=F){for(Y=K+1;Y<z&&H[Y]>=F;)Y++;for(Q=K,J=Y-1;Q<J;Q++,J--)ne=U[Q],U[Q]=U[J],U[J]=ne;K=Y}K++}}}function V(F,H,U,z){var K=H[z],Y,Q,J,ne;switch(K){case t:case i:A=!1;case f:case h:return K;case c:return A?h:c;case y:return A=!0,i;case m:return f;case $:return z<1||z+1>=H.length||(Y=U[z-1])!=c&&Y!=h||(Q=H[z+1])!=c&&Q!=h?f:(A&&(Q=h),Q==Y?Q:f);case N:return Y=z>0?U[z-1]:v,Y==c&&z+1<H.length&&H[z+1]==c?c:f;case M:if(z>0&&U[z-1]==c)return c;if(A)return f;for(ne=z+1,J=H.length;ne<J&&H[ne]==M;)ne++;return ne<J&&H[ne]==c?c:f;case S:for(J=H.length,ne=z+1;ne<J&&H[ne]==S;)ne++;if(ne<J){var re=F[z],j=re>=1425&&re<=2303||re==64286;if(Y=H[ne],j&&(Y==i||Y==y))return i}return z<1||(Y=H[z-1])==v?f:U[z-1];case v:return A=!1,a=!0,b;case p:return g=!0,f;case O:case x:case I:case w:case L:A=!1;case _:return f}}function B(F){var H=F.charCodeAt(0),U=H>>8;return U==0?H>191?t:T[H]:U==5?/[\u0591-\u05f4]/.test(F)?i:t:U==6?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(F)?S:/[\u0660-\u0669\u066b-\u066c]/.test(F)?h:H==1642?M:/[\u06f0-\u06f9]/.test(F)?c:y:U==32&&H<=8287?k[H&255]:U==254&&H>=65136?y:f}d.L=t,d.R=i,d.EN=c,d.ON_R=3,d.AN=4,d.R_H=5,d.B=6,d.RLE=7,d.DOT="·",d.doBidiReorder=function(F,H,U){if(F.length<2)return{};var z=F.split(""),K=new Array(z.length),Y=new Array(z.length),Q=[];b=U?r:o,R(z,Q,z.length,H);for(var J=0;J<K.length;K[J]=J,J++);D(2,Q,K),D(1,Q,K);for(var J=0;J<K.length-1;J++)H[J]===h?Q[J]=d.AN:Q[J]===i&&(H[J]>y&&H[J]<O||H[J]===f||H[J]===_)?Q[J]=d.ON_R:J>0&&z[J-1]==="ل"&&/\u0622|\u0623|\u0625|\u0627/.test(z[J])&&(Q[J-1]=Q[J]=d.R_H,J++);z[z.length-1]===d.DOT&&(Q[z.length-1]=d.B),z[0]==="‫"&&(Q[0]=d.RLE);for(var J=0;J<K.length;J++)Y[J]=Q[K[J]];return{logicalFromVisual:K,bidiLevels:Y}},d.hasBidiCharacters=function(F,H){for(var U=!1,z=0;z<F.length;z++)H[z]=B(F.charAt(z)),!U&&(H[z]==i||H[z]==y||H[z]==h)&&(U=!0);return U},d.getVisualFromLogicalIdx=function(F,H){for(var U=0;U<H.logicalFromVisual.length;U++)if(H.logicalFromVisual[U]==F)return U;return 0}}),ace.define("ace/bidihandler",["require","exports","module","ace/lib/bidiutil","ace/lib/lang"],function(l,d,E){var b=l("./lib/bidiutil"),C=l("./lib/lang"),A=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\u202B]/,a=function(){function g(n){this.session=n,this.bidiMap={},this.currentRow=null,this.bidiUtil=b,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=A.test(n.getValue())}return g.prototype.isBidiRow=function(n,s,o){return this.seenBidi?(n!==this.currentRow&&(this.currentRow=n,this.updateRowLine(s,o),this.updateBidiMap()),this.bidiMap.bidiLevels):!1},g.prototype.onChange=function(n){this.seenBidi?this.currentRow=null:n.action=="insert"&&A.test(n.lines.join(`
184
+ `))&&(this.seenBidi=!0,this.currentRow=null)},g.prototype.getDocumentRow=function(){var n=0,s=this.session.$screenRowCache;if(s.length){var o=this.session.$getRowCacheIndex(s,this.currentRow);o>=0&&(n=this.session.$docRowCache[o])}return n},g.prototype.getSplitIndex=function(){var n=0,s=this.session.$screenRowCache;if(s.length)for(var o,r=this.session.$getRowCacheIndex(s,this.currentRow);this.currentRow-n>0&&(o=this.session.$getRowCacheIndex(s,this.currentRow-n-1),o===r);)r=o,n++;else n=this.currentRow;return n},g.prototype.updateRowLine=function(n,s){n===void 0&&(n=this.getDocumentRow());var o=n===this.session.getLength()-1,r=o?this.EOF:this.EOL;if(this.wrapIndent=0,this.line=this.session.getLine(n),this.isRtlDir=this.$isRtl||this.line.charAt(0)===this.RLE,this.session.$useWrapMode){var t=this.session.$wrapData[n];t&&(s===void 0&&(s=this.getSplitIndex()),s>0&&t.length?(this.wrapIndent=t.indent,this.wrapOffset=this.wrapIndent*this.charWidths[b.L],this.line=s<t.length?this.line.substring(t[s-1],t[s]):this.line.substring(t[t.length-1])):this.line=this.line.substring(0,t[s]),s==t.length&&(this.line+=this.showInvisibles?r:b.DOT))}else this.line+=this.showInvisibles?r:b.DOT;var i=this.session,c=0,h;this.line=this.line.replace(/\t|[\u1100-\u2029, \u202F-\uFFE6]/g,function(f,v){return f===" "||i.isFullWidth(f.charCodeAt(0))?(h=f===" "?i.getScreenTabSize(v+c):2,c+=h-1,C.stringRepeat(b.DOT,h)):f}),this.isRtlDir&&(this.fontMetrics.$main.textContent=this.line.charAt(this.line.length-1)==b.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 n=[];b.hasBidiCharacters(this.line,n)||this.isRtlDir?this.bidiMap=b.doBidiReorder(this.line,n,this.isRtlDir):this.bidiMap={}},g.prototype.markAsDirty=function(){this.currentRow=null},g.prototype.updateCharacterWidths=function(n){if(this.characterWidth!==n.$characterSize.width){this.fontMetrics=n;var s=this.characterWidth=n.$characterSize.width,o=n.$measureCharWidth("ה");this.charWidths[b.L]=this.charWidths[b.EN]=this.charWidths[b.ON_R]=s,this.charWidths[b.R]=this.charWidths[b.AN]=o,this.charWidths[b.R_H]=o*.45,this.charWidths[b.B]=this.charWidths[b.RLE]=0,this.currentRow=null}},g.prototype.setShowInvisibles=function(n){this.showInvisibles=n,this.currentRow=null},g.prototype.setEolChar=function(n){this.EOL=n},g.prototype.setContentWidth=function(n){this.contentWidth=n},g.prototype.isRtlLine=function(n){return this.$isRtl?!0:n!=null?this.session.getLine(n).charAt(0)==this.RLE:this.isRtlDir},g.prototype.setRtlDirection=function(n,s){for(var o=n.getCursorPosition(),r=n.selection.getSelectionAnchor().row;r<=o.row;r++)!s&&n.session.getLine(r).charAt(0)===n.session.$bidiHandler.RLE?n.session.doc.removeInLine(r,0,1):s&&n.session.getLine(r).charAt(0)!==n.session.$bidiHandler.RLE&&n.session.doc.insert({column:0,row:r},n.session.$bidiHandler.RLE)},g.prototype.getPosLeft=function(n){n-=this.wrapIndent;var s=this.line.charAt(0)===this.RLE?1:0,o=n>s?this.session.getOverwrite()?n:n-1:s,r=b.getVisualFromLogicalIdx(o,this.bidiMap),t=this.bidiMap.bidiLevels,i=0;!this.session.getOverwrite()&&n<=s&&t[r]%2!==0&&r++;for(var c=0;c<r;c++)i+=this.charWidths[t[c]];return!this.session.getOverwrite()&&n>s&&t[r]%2===0&&(i+=this.charWidths[t[r]]),this.wrapIndent&&(i+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset),this.isRtlDir&&(i+=this.rtlLineOffset),i},g.prototype.getSelections=function(n,s){var o=this.bidiMap,r=o.bidiLevels,t,i=[],c=0,h=Math.min(n,s)-this.wrapIndent,f=Math.max(n,s)-this.wrapIndent,v=!1,p=!1,y=0;this.wrapIndent&&(c+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);for(var m,$=0;$<r.length;$++)m=o.logicalFromVisual[$],t=r[$],v=m>=h&&m<f,v&&!p?y=c:!v&&p&&i.push({left:y,width:c-y}),c+=this.charWidths[t],p=v;if(v&&$===r.length&&i.push({left:y,width:c-y}),this.isRtlDir)for(var N=0;N<i.length;N++)i[N].left+=this.rtlLineOffset;return i},g.prototype.offsetToCol=function(o){this.isRtlDir&&(o-=this.rtlLineOffset);var s=0,o=Math.max(o,0),r=0,t=0,i=this.bidiMap.bidiLevels,c=this.charWidths[i[t]];for(this.wrapIndent&&(o-=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);o>r+c/2;){if(r+=c,t===i.length-1){c=0;break}c=this.charWidths[i[++t]]}return t>0&&i[t-1]%2!==0&&i[t]%2===0?(o<r&&t--,s=this.bidiMap.logicalFromVisual[t]):t>0&&i[t-1]%2===0&&i[t]%2!==0?s=1+(o>r?this.bidiMap.logicalFromVisual[t]:this.bidiMap.logicalFromVisual[t-1]):this.isRtlDir&&t===i.length-1&&c===0&&i[t-1]%2===0||!this.isRtlDir&&t===0&&i[t]%2!==0?s=1+this.bidiMap.logicalFromVisual[t]:(t>0&&i[t-1]%2!==0&&c!==0&&t--,s=this.bidiMap.logicalFromVisual[t]),s===0&&this.isRtlDir&&s++,s+this.wrapIndent},g}();d.BidiHandler=a}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(l,d,E){var b=l("./lib/oop"),C=l("./lib/lang"),A=l("./lib/event_emitter").EventEmitter,a=l("./range").Range,g=function(){function n(s){this.session=s,this.doc=s.getDocument(),this.clearSelection(),this.cursor=this.lead=this.doc.createAnchor(0,0),this.anchor=this.doc.createAnchor(0,0),this.$silent=!1;var o=this;this.cursor.on("change",function(r){o.$cursorChanged=!0,o.$silent||o._emit("changeCursor"),!o.$isEmpty&&!o.$silent&&o._emit("changeSelection"),!o.$keepDesiredColumnOnChange&&r.old.column!=r.value.column&&(o.$desiredColumn=null)}),this.anchor.on("change",function(){o.$anchorChanged=!0,!o.$isEmpty&&!o.$silent&&o._emit("changeSelection")})}return n.prototype.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},n.prototype.isMultiLine=function(){return!this.$isEmpty&&this.anchor.row!=this.cursor.row},n.prototype.getCursor=function(){return this.lead.getPosition()},n.prototype.setAnchor=function(s,o){this.$isEmpty=!1,this.anchor.setPosition(s,o)},n.prototype.getAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},n.prototype.getSelectionLead=function(){return this.lead.getPosition()},n.prototype.isBackwards=function(){var s=this.anchor,o=this.lead;return s.row>o.row||s.row==o.row&&s.column>o.column},n.prototype.getRange=function(){var s=this.anchor,o=this.lead;return this.$isEmpty?a.fromPoints(o,o):this.isBackwards()?a.fromPoints(o,s):a.fromPoints(s,o)},n.prototype.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},n.prototype.selectAll=function(){this.$setSelection(0,0,Number.MAX_VALUE,Number.MAX_VALUE)},n.prototype.setRange=function(s,o){var r=o?s.end:s.start,t=o?s.start:s.end;this.$setSelection(r.row,r.column,t.row,t.column)},n.prototype.$setSelection=function(s,o,r,t){if(!this.$silent){var i=this.$isEmpty,c=this.inMultiSelectMode;this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(s,o),this.cursor.setPosition(r,t),this.$isEmpty=!a.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||i!=this.$isEmpty||c)&&this._emit("changeSelection")}},n.prototype.$moveSelection=function(s){var o=this.lead;this.$isEmpty&&this.setSelectionAnchor(o.row,o.column),s.call(this)},n.prototype.selectTo=function(s,o){this.$moveSelection(function(){this.moveCursorTo(s,o)})},n.prototype.selectToPosition=function(s){this.$moveSelection(function(){this.moveCursorToPosition(s)})},n.prototype.moveTo=function(s,o){this.clearSelection(),this.moveCursorTo(s,o)},n.prototype.moveToPosition=function(s){this.clearSelection(),this.moveCursorToPosition(s)},n.prototype.selectUp=function(){this.$moveSelection(this.moveCursorUp)},n.prototype.selectDown=function(){this.$moveSelection(this.moveCursorDown)},n.prototype.selectRight=function(){this.$moveSelection(this.moveCursorRight)},n.prototype.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},n.prototype.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},n.prototype.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},n.prototype.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},n.prototype.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},n.prototype.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},n.prototype.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},n.prototype.getWordRange=function(s,o){if(typeof o>"u"){var r=s||this.lead;s=r.row,o=r.column}return this.session.getWordRange(s,o)},n.prototype.selectWord=function(){this.setSelectionRange(this.getWordRange())},n.prototype.selectAWord=function(){var s=this.getCursor(),o=this.session.getAWordRange(s.row,s.column);this.setSelectionRange(o)},n.prototype.getLineRange=function(s,o){var r=typeof s=="number"?s:this.lead.row,t,i=this.session.getFoldLine(r);return i?(r=i.start.row,t=i.end.row):t=r,o===!0?new a(r,0,t,this.session.getLine(t).length):new a(r,0,t+1,0)},n.prototype.selectLine=function(){this.setSelectionRange(this.getLineRange())},n.prototype.moveCursorUp=function(){this.moveCursorBy(-1,0)},n.prototype.moveCursorDown=function(){this.moveCursorBy(1,0)},n.prototype.wouldMoveIntoSoftTab=function(s,o,r){var t=s.column,i=s.column+o;return r<0&&(t=s.column-o,i=s.column),this.session.isTabStop(s)&&this.doc.getLine(s.row).slice(t,i).split(" ").length-1==o},n.prototype.moveCursorLeft=function(){var s=this.lead.getPosition(),o;if(o=this.session.getFoldAt(s.row,s.column,-1))this.moveCursorTo(o.start.row,o.start.column);else if(s.column===0)s.row>0&&this.moveCursorTo(s.row-1,this.doc.getLine(s.row-1).length);else{var r=this.session.getTabSize();this.wouldMoveIntoSoftTab(s,r,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-r):this.moveCursorBy(0,-1)}},n.prototype.moveCursorRight=function(){var s=this.lead.getPosition(),o;if(o=this.session.getFoldAt(s.row,s.column,1))this.moveCursorTo(o.end.row,o.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 r=this.session.getTabSize(),s=this.lead;this.wouldMoveIntoSoftTab(s,r,1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,r):this.moveCursorBy(0,1)}},n.prototype.moveCursorLineStart=function(){var s=this.lead.row,o=this.lead.column,r=this.session.documentToScreenRow(s,o),t=this.session.screenToDocumentPosition(r,0),i=this.session.getDisplayLine(s,null,t.row,t.column),c=i.match(/^\s*/);c[0].length!=o&&!this.session.$useEmacsStyleLineStart&&(t.column+=c[0].length),this.moveCursorToPosition(t)},n.prototype.moveCursorLineEnd=function(){var s=this.lead,o=this.session.getDocumentLastRowColumnPosition(s.row,s.column);if(this.lead.column==o.column){var r=this.session.getLine(o.row);if(o.column==r.length){var t=r.search(/\s+$/);t>0&&(o.column=t)}}this.moveCursorTo(o.row,o.column)},n.prototype.moveCursorFileEnd=function(){var s=this.doc.getLength()-1,o=this.doc.getLine(s).length;this.moveCursorTo(s,o)},n.prototype.moveCursorFileStart=function(){this.moveCursorTo(0,0)},n.prototype.moveCursorLongWordRight=function(){var s=this.lead.row,o=this.lead.column,r=this.doc.getLine(s),t=r.substring(o);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var i=this.session.getFoldAt(s,o,1);if(i){this.moveCursorTo(i.end.row,i.end.column);return}if(this.session.nonTokenRe.exec(t)&&(o+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,t=r.substring(o)),o>=r.length){this.moveCursorTo(s,r.length),this.moveCursorRight(),s<this.doc.getLength()-1&&this.moveCursorWordRight();return}this.session.tokenRe.exec(t)&&(o+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(s,o)},n.prototype.moveCursorLongWordLeft=function(){var s=this.lead.row,o=this.lead.column,r;if(r=this.session.getFoldAt(s,o,-1)){this.moveCursorTo(r.start.row,r.start.column);return}var t=this.session.getFoldStringAt(s,o,-1);t==null&&(t=this.doc.getLine(s).substring(0,o));var i=C.stringReverse(t);if(this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.nonTokenRe.exec(i)&&(o-=this.session.nonTokenRe.lastIndex,i=i.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0),o<=0){this.moveCursorTo(s,0),this.moveCursorLeft(),s>0&&this.moveCursorWordLeft();return}this.session.tokenRe.exec(i)&&(o-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(s,o)},n.prototype.$shortWordEndIndex=function(s){var o=0,r,t=/\s/,i=this.session.tokenRe;if(i.lastIndex=0,this.session.tokenRe.exec(s))o=this.session.tokenRe.lastIndex;else{for(;(r=s[o])&&t.test(r);)o++;if(o<1){for(i.lastIndex=0;(r=s[o])&&!i.test(r);)if(i.lastIndex=0,o++,t.test(r))if(o>2){o--;break}else{for(;(r=s[o])&&t.test(r);)o++;if(o>2)break}}}return i.lastIndex=0,o},n.prototype.moveCursorShortWordRight=function(){var s=this.lead.row,o=this.lead.column,r=this.doc.getLine(s),t=r.substring(o),i=this.session.getFoldAt(s,o,1);if(i)return this.moveCursorTo(i.end.row,i.end.column);if(o==r.length){var c=this.doc.getLength();do s++,t=this.doc.getLine(s);while(s<c&&/^\s*$/.test(t));/^\s+/.test(t)||(t=""),o=0}var h=this.$shortWordEndIndex(t);this.moveCursorTo(s,o+h)},n.prototype.moveCursorShortWordLeft=function(){var s=this.lead.row,o=this.lead.column,r;if(r=this.session.getFoldAt(s,o,-1))return this.moveCursorTo(r.start.row,r.start.column);var t=this.session.getLine(s).substring(0,o);if(o===0){do s--,t=this.doc.getLine(s);while(s>0&&/^\s*$/.test(t));o=t.length,/\s+$/.test(t)||(t="")}var i=C.stringReverse(t),c=this.$shortWordEndIndex(i);return this.moveCursorTo(s,o-c)},n.prototype.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},n.prototype.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},n.prototype.moveCursorBy=function(s,o){var r=this.session.documentToScreenPosition(this.lead.row,this.lead.column),t;if(o===0&&(s!==0&&(this.session.$bidiHandler.isBidiRow(r.row,this.lead.row)?(t=this.session.$bidiHandler.getPosLeft(r.column),r.column=Math.round(t/this.session.$bidiHandler.charWidths[0])):t=r.column*this.session.$bidiHandler.charWidths[0]),this.$desiredColumn?r.column=this.$desiredColumn:this.$desiredColumn=r.column),s!=0&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]){var i=this.session.lineWidgets[this.lead.row];s<0?s-=i.rowsAbove||0:s>0&&(s+=i.rowCount-(i.rowsAbove||0))}var c=this.session.screenToDocumentPosition(r.row+s,r.column,t);s!==0&&o===0&&c.row===this.lead.row&&(c.column,this.lead.column),this.moveCursorTo(c.row,c.column+o,o===0)},n.prototype.moveCursorToPosition=function(s){this.moveCursorTo(s.row,s.column)},n.prototype.moveCursorTo=function(s,o,r){var t=this.session.getFoldAt(s,o,1);t&&(s=t.start.row,o=t.start.column),this.$keepDesiredColumnOnChange=!0;var i=this.session.getLine(s);/[\uDC00-\uDFFF]/.test(i.charAt(o))&&i.charAt(o-1)&&(this.lead.row==s&&this.lead.column==o+1?o=o-1:o=o+1),this.lead.setPosition(s,o),this.$keepDesiredColumnOnChange=!1,r||(this.$desiredColumn=null)},n.prototype.moveCursorToScreen=function(s,o,r){var t=this.session.screenToDocumentPosition(s,o);this.moveCursorTo(t.row,t.column,r)},n.prototype.detach=function(){this.lead.detach(),this.anchor.detach()},n.prototype.fromOrientedRange=function(s){this.setSelectionRange(s,s.cursor==s.start),this.$desiredColumn=s.desiredColumn||this.$desiredColumn},n.prototype.toOrientedRange=function(s){var o=this.getRange();return s?(s.start.column=o.start.column,s.start.row=o.start.row,s.end.column=o.end.column,s.end.row=o.end.row):s=o,s.cursor=this.isBackwards()?s.start:s.end,s.desiredColumn=this.$desiredColumn,s},n.prototype.getRangeOfMovements=function(s){var o=this.getCursor();try{s(this);var r=this.getCursor();return a.fromPoints(o,r)}catch{return a.fromPoints(o,o)}finally{this.moveCursorToPosition(o)}},n.prototype.toJSON=function(){if(this.rangeCount)var s=this.ranges.map(function(o){var r=o.clone();return r.isBackwards=o.cursor==o.start,r});else{var s=this.getRange();s.isBackwards=this.isBackwards()}return s},n.prototype.fromJSON=function(s){if(s.start==null)if(this.rangeList&&s.length>1){this.toSingleRange(s[0]);for(var o=s.length;o--;){var r=a.fromPoints(s[o].start,s[o].end);s[o].isBackwards&&(r.cursor=r.start),this.addRange(r,!0)}return}else s=s[0];this.rangeList&&this.toSingleRange(s),this.setSelectionRange(s,s.isBackwards)},n.prototype.isEqual=function(s){if((s.length||this.rangeCount)&&s.length!=this.rangeCount)return!1;if(!s.length||!this.ranges)return this.getRange().isEqual(s);for(var o=this.ranges.length;o--;)if(!this.ranges[o].isEqual(s[o]))return!1;return!0},n}();g.prototype.setSelectionAnchor=g.prototype.setAnchor,g.prototype.getSelectionAnchor=g.prototype.getAnchor,g.prototype.setSelectionRange=g.prototype.setRange,b.implement(g.prototype,A),d.Selection=g}),ace.define("ace/tokenizer",["require","exports","module","ace/lib/report_error"],function(l,d,E){var b=l("./lib/report_error").reportError,C=2e3,A=function(){function a(g){this.splitRegex,this.states=g,this.regExps={},this.matchMappings={};for(var n in this.states){for(var s=this.states[n],o=[],r=0,t=this.matchMappings[n]={defaultToken:"text"},i="g",c=[],h=0;h<s.length;h++){var f=s[h];if(f.defaultToken&&(t.defaultToken=f.defaultToken),f.caseInsensitive&&i.indexOf("i")===-1&&(i+="i"),f.unicode&&i.indexOf("u")===-1&&(i+="u"),f.regex!=null){f.regex instanceof RegExp&&(f.regex=f.regex.toString().slice(1,-1));var v=f.regex,p=new RegExp("(?:("+v+")|(.))").exec("a").length-2;Array.isArray(f.token)?f.token.length==1||p==1?f.token=f.token[0]:p-1!=f.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:f,groupCount:p-1}),f.token=f.token[0]):(f.tokenArray=f.token,f.token=null,f.onMatch=this.$arrayTokens):typeof f.token=="function"&&!f.onMatch&&(p>1?f.onMatch=this.$applyToken:f.onMatch=f.token),p>1&&(/\\\d/.test(f.regex)?v=f.regex.replace(/\\([0-9]+)/g,function(y,m){return"\\"+(parseInt(m,10)+r+1)}):(p=1,v=this.removeCapturingGroups(f.regex)),!f.splitRegex&&typeof f.token!="string"&&c.push(f)),t[r]=h,r+=p,o.push(v),f.onMatch||(f.onMatch=null)}}o.length||(t[0]=0,o.push("$")),c.forEach(function(y){y.splitRegex=this.createSplitterRegexp(y.regex,i)},this),this.regExps[n]=new RegExp("("+o.join(")|(")+")|($)",i)}}return a.prototype.$setMaxTokenCount=function(g){C=g|0},a.prototype.$applyToken=function(g){var n=this.splitRegex.exec(g).slice(1),s=this.token.apply(this,n);if(typeof s=="string")return[{type:s,value:g}];for(var o=[],r=0,t=s.length;r<t;r++)n[r]&&(o[o.length]={type:s[r],value:n[r]});return o},a.prototype.$arrayTokens=function(g){if(!g)return[];var n=this.splitRegex.exec(g);if(!n)return"text";for(var s=[],o=this.tokenArray,r=0,t=o.length;r<t;r++)n[r+1]&&(s[s.length]={type:o[r],value:n[r+1]});return s},a.prototype.removeCapturingGroups=function(g){var n=g.replace(/\\.|\[(?:\\.|[^\\\]])*|\(\?[:=!<]|(\()/g,function(s,o){return o?"(?:":s});return n},a.prototype.createSplitterRegexp=function(g,n){if(g.indexOf("(?=")!=-1){var s=0,o=!1,r={};g.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,function(t,i,c,h,f,v){return o?o=f!="]":f?o=!0:h?(s==r.stack&&(r.end=v+1,r.stack=-1),s--):c&&(s++,c.length!=1&&(r.stack=s,r.start=v)),t}),r.end!=null&&/^\)*$/.test(g.substr(r.end))&&(g=g.substring(0,r.start)+g.substr(r.end))}return g.charAt(0)!="^"&&(g="^"+g),g.charAt(g.length-1)!="$"&&(g+="$"),new RegExp(g,(n||"").replace("g",""))},a.prototype.getLineTokens=function(g,n){if(n&&typeof n!="string"){var s=n.slice(0);n=s[0],n==="#tmp"&&(s.shift(),n=s.shift())}else var s=[];var o=n||"start",r=this.states[o];r||(o="start",r=this.states[o]);var t=this.matchMappings[o],i=this.regExps[o];i.lastIndex=0;for(var c,h=[],f=0,v=0,p={type:null,value:""};c=i.exec(g);){var y=t.defaultToken,m=null,$=c[0],N=i.lastIndex;if(N-$.length>f){var M=g.substring(f,N-$.length);p.type==y?p.value+=M:(p.type&&h.push(p),p={type:y,value:M})}for(var S=0;S<c.length-2;S++)if(c[S+1]!==void 0){m=r[t[S]],m.onMatch?y=m.onMatch($,o,s,g):y=m.token,m.next&&(typeof m.next=="string"?o=m.next:o=m.next(o,s),r=this.states[o],r||(this.reportError("state doesn't exist",o),o="start",r=this.states[o]),t=this.matchMappings[o],f=N,i=this.regExps[o],i.lastIndex=N),m.consumeLineEnd&&(f=N);break}if($){if(typeof y=="string")(!m||m.merge!==!1)&&p.type===y?p.value+=$:(p.type&&h.push(p),p={type:y,value:$});else if(y){p.type&&h.push(p),p={type:null,value:""};for(var S=0;S<y.length;S++)h.push(y[S])}}if(f==g.length)break;if(f=N,v++>C){for(v>2*g.length&&this.reportError("infinite loop with in ace tokenizer",{startState:n,line:g});f<g.length;)p.type&&h.push(p),p={value:g.substring(f,f+=500),type:"overflow"};o="start",s=[];break}}return p.type&&h.push(p),s.length>1&&s[0]!==o&&s.unshift("#tmp",o),{tokens:h,state:s.length?s:o}},a}();A.prototype.reportError=b,d.Tokenizer=A}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/deep_copy"],function(l,d,E){var b=l("../lib/deep_copy").deepCopy,C;C=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}},(function(){this.addRules=function(g,n){if(!n){for(var s in g)this.$rules[s]=g[s];return}for(var s in g){for(var o=g[s],r=0;r<o.length;r++){var t=o[r];(t.next||t.onMatch)&&(typeof t.next=="string"&&t.next.indexOf(n)!==0&&(t.next=n+t.next),t.nextState&&t.nextState.indexOf(n)!==0&&(t.nextState=n+t.nextState))}this.$rules[n+s]=o}},this.getRules=function(){return this.$rules},this.embedRules=function(g,n,s,o,r){var t=typeof g=="function"?new g().getRules():g;if(o)for(var i=0;i<o.length;i++)o[i]=n+o[i];else{o=[];for(var c in t)o.push(n+c)}if(this.addRules(t,n),s)for(var h=Array.prototype[r?"push":"unshift"],i=0;i<o.length;i++)h.apply(this.$rules[o[i]],b(s));this.$embeds||(this.$embeds=[]),this.$embeds.push(n)},this.getEmbeds=function(){return this.$embeds};var A=function(g,n){return(g!="start"||n.length)&&n.unshift(this.nextState,g),this.nextState},a=function(g,n){return n.shift(),n.shift()||"start"};this.normalizeRules=function(){var g=0,n=this.$rules;function s(o){var r=n[o];r.processed=!0;for(var t=0;t<r.length;t++){var i=r[t],c=null;Array.isArray(i)&&(c=i,i={}),!i.regex&&i.start&&(i.regex=i.start,i.next||(i.next=[]),i.next.push({defaultToken:i.token},{token:i.token+".end",regex:i.end||i.start,next:"pop"}),i.token=i.token+".start",i.push=!0);var h=i.next||i.push;if(h&&Array.isArray(h)){var f=i.stateName;f||(f=i.token,typeof f!="string"&&(f=f[0]||""),n[f]&&(f+=g++)),n[f]=h,i.next=f,s(f)}else h=="pop"&&(i.next=a);if(i.push&&(i.nextState=i.next||i.push,i.next=A,delete i.push),i.rules)for(var v in i.rules)n[v]?n[v].push&&n[v].push.apply(n[v],i.rules[v]):n[v]=i.rules[v];var p=typeof i=="string"?i:i.include;if(p&&(p==="$self"&&(p="start"),Array.isArray(p)?c=p.map(function(m){return n[m]}):c=n[p]),c){var y=[t,1].concat(c);i.noEscape&&(y=y.filter(function(m){return!m.next})),r.splice.apply(r,y),t--}i.keywordMap&&(i.token=this.createKeywordMapper(i.keywordMap,i.defaultToken||"text",i.caseInsensitive),delete i.defaultToken)}}Object.keys(n).forEach(s,this)},this.createKeywordMapper=function(g,n,s,o){var r=Object.create(null);return this.$keywordList=[],Object.keys(g).forEach(function(t){for(var i=g[t],c=i.split(o||"|"),h=c.length;h--;){var f=c[h];this.$keywordList.push(f),s&&(f=f.toLowerCase()),r[f]=t}},this),g=null,s?function(t){return r[t.toLowerCase()]||n}:function(t){return r[t]||n}},this.getKeywords=function(){return this.$keywords}}).call(C.prototype),d.TextHighlightRules=C}),ace.define("ace/mode/behaviour",["require","exports","module"],function(l,d,E){var b;b=function(){this.$behaviours={}},(function(){this.add=function(C,A,a){switch(void 0){case this.$behaviours:this.$behaviours={};case this.$behaviours[C]:this.$behaviours[C]={}}this.$behaviours[C][A]=a},this.addBehaviours=function(C){for(var A in C)for(var a in C[A])this.add(A,a,C[A][a])},this.remove=function(C){this.$behaviours&&this.$behaviours[C]&&delete this.$behaviours[C]},this.inherit=function(C,A){if(typeof C=="function")var a=new C().getBehaviours(A);else var a=C.getBehaviours(A);this.addBehaviours(a)},this.getBehaviours=function(C){if(C){for(var A={},a=0;a<C.length;a++)this.$behaviours[C[a]]&&(A[C[a]]=this.$behaviours[C[a]]);return A}else return this.$behaviours}}).call(b.prototype),d.Behaviour=b}),ace.define("ace/token_iterator",["require","exports","module","ace/range"],function(l,d,E){var b=l("./range").Range,C=function(){function A(a,g,n){this.$session=a,this.$row=g,this.$rowTokens=a.getTokens(g);var s=a.getTokenAt(g,n);this.$tokenIndex=s?s.index:-1}return A.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]},A.prototype.stepForward=function(){this.$tokenIndex+=1;for(var a;this.$tokenIndex>=this.$rowTokens.length;){if(this.$row+=1,a||(a=this.$session.getLength()),this.$row>=a)return this.$row=a-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},A.prototype.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},A.prototype.getCurrentTokenRow=function(){return this.$row},A.prototype.getCurrentTokenColumn=function(){var a=this.$rowTokens,g=this.$tokenIndex,n=a[g].start;if(n!==void 0)return n;for(n=0;g>0;)g-=1,n+=a[g].value.length;return n},A.prototype.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},A.prototype.getCurrentTokenRange=function(){var a=this.$rowTokens[this.$tokenIndex],g=this.getCurrentTokenColumn();return new b(this.$row,g,this.$row,g+a.value.length)},A}();d.TokenIterator=C}),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],function(l,d,E){var b=l("../../lib/oop"),C=l("../behaviour").Behaviour,A=l("../../token_iterator").TokenIterator,a=l("../../lib/lang"),g=["text","paren.rparen","rparen","paren","punctuation.operator"],n=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],s,o={},r={'"':'"',"'":"'"},t=function(h){var f=-1;if(h.multiSelect&&(f=h.selection.index,o.rangeCount!=h.multiSelect.rangeCount&&(o={rangeCount:h.multiSelect.rangeCount})),o[f])return s=o[f];s=o[f]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},i=function(h,f,v,p){var y=h.end.row-h.start.row;return{text:v+f+p,selection:[0,h.start.column+1,y,h.end.column+(y?0:1)]}},c;c=function(h){h=h||{},this.add("braces","insertion",function(f,v,p,y,m){var $=p.getCursorPosition(),N=y.doc.getLine($.row);if(m=="{"){t(p);var M=p.getSelectionRange(),S=y.doc.getTextRange(M),O=y.getTokenAt($.row,$.column);if(S!==""&&S!=="{"&&p.getWrapBehavioursEnabled())return i(M,S,"{","}");if(O&&/(?:string)\.quasi|\.xml/.test(O.type)){var x=[/tag\-(?:open|name)/,/attribute\-name/];return x.some(function(R){return R.test(O.type)})||/(string)\.quasi/.test(O.type)&&O.value[$.column-O.start-1]!=="$"?void 0:(c.recordAutoInsert(p,y,"}"),{text:"{}",selection:[1,1]})}else if(c.isSaneInsertion(p,y))return/[\]\}\)]/.test(N[$.column])||p.inMultiSelectMode||h.braces?(c.recordAutoInsert(p,y,"}"),{text:"{}",selection:[1,1]}):(c.recordMaybeInsert(p,y,"{"),{text:"{",selection:[1,1]})}else if(m=="}"){t(p);var L=N.substring($.column,$.column+1);if(L=="}"){var I=y.$findOpeningBracket("}",{column:$.column+1,row:$.row});if(I!==null&&c.isAutoInsertedClosing($,N,m))return c.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}else if(m==`
185
+ `||m==`\r
186
+ `){t(p);var w="";c.isMaybeInsertedClosing($,N)&&(w=a.stringRepeat("}",s.maybeInsertedBrackets),c.clearMaybeInsertedClosing());var L=N.substring($.column,$.column+1);if(L==="}"){var _=y.findMatchingBracket({row:$.row,column:$.column+1},"}");if(!_)return null;var T=this.$getIndent(y.getLine(_.row))}else if(w)var T=this.$getIndent(N);else{c.clearMaybeInsertedClosing();return}var k=T+y.getTabString();return{text:`
187
+ `+k+`
188
+ `+T+w,selection:[1,k.length,1,k.length]}}else c.clearMaybeInsertedClosing()}),this.add("braces","deletion",function(f,v,p,y,m){var $=y.doc.getTextRange(m);if(!m.isMultiLine()&&$=="{"){t(p);var N=y.doc.getLine(m.start.row),M=N.substring(m.end.column,m.end.column+1);if(M=="}")return m.end.column++,m;s.maybeInsertedBrackets--}}),this.add("parens","insertion",function(f,v,p,y,m){if(m=="("){t(p);var $=p.getSelectionRange(),N=y.doc.getTextRange($);if(N!==""&&p.getWrapBehavioursEnabled())return i($,N,"(",")");if(c.isSaneInsertion(p,y))return c.recordAutoInsert(p,y,")"),{text:"()",selection:[1,1]}}else if(m==")"){t(p);var M=p.getCursorPosition(),S=y.doc.getLine(M.row),O=S.substring(M.column,M.column+1);if(O==")"){var x=y.$findOpeningBracket(")",{column:M.column+1,row:M.row});if(x!==null&&c.isAutoInsertedClosing(M,S,m))return c.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("parens","deletion",function(f,v,p,y,m){var $=y.doc.getTextRange(m);if(!m.isMultiLine()&&$=="("){t(p);var N=y.doc.getLine(m.start.row),M=N.substring(m.start.column+1,m.start.column+2);if(M==")")return m.end.column++,m}}),this.add("brackets","insertion",function(f,v,p,y,m){if(m=="["){t(p);var $=p.getSelectionRange(),N=y.doc.getTextRange($);if(N!==""&&p.getWrapBehavioursEnabled())return i($,N,"[","]");if(c.isSaneInsertion(p,y))return c.recordAutoInsert(p,y,"]"),{text:"[]",selection:[1,1]}}else if(m=="]"){t(p);var M=p.getCursorPosition(),S=y.doc.getLine(M.row),O=S.substring(M.column,M.column+1);if(O=="]"){var x=y.$findOpeningBracket("]",{column:M.column+1,row:M.row});if(x!==null&&c.isAutoInsertedClosing(M,S,m))return c.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("brackets","deletion",function(f,v,p,y,m){var $=y.doc.getTextRange(m);if(!m.isMultiLine()&&$=="["){t(p);var N=y.doc.getLine(m.start.row),M=N.substring(m.start.column+1,m.start.column+2);if(M=="]")return m.end.column++,m}}),this.add("string_dquotes","insertion",function(f,v,p,y,m){var $=y.$mode.$quotes||r;if(m.length==1&&$[m]){if(this.lineCommentStart&&this.lineCommentStart.indexOf(m)!=-1)return;t(p);var N=m,M=p.getSelectionRange(),S=y.doc.getTextRange(M);if(S!==""&&(S.length!=1||!$[S])&&p.getWrapBehavioursEnabled())return i(M,S,N,N);if(!S){var O=p.getCursorPosition(),x=y.doc.getLine(O.row),L=x.substring(O.column-1,O.column),I=x.substring(O.column,O.column+1),w=y.getTokenAt(O.row,O.column),_=y.getTokenAt(O.row,O.column+1);if(L=="\\"&&w&&/escape/.test(w.type))return null;var T=w&&/string|escape/.test(w.type),k=!_||/string|escape/.test(_.type),R;if(I==N)R=T!==k,R&&/string\.end/.test(_.type)&&(R=!1);else{if(T&&!k||T&&k)return null;var D=y.$mode.tokenRe;D.lastIndex=0;var V=D.test(L);D.lastIndex=0;var B=D.test(I),F=y.$mode.$pairQuotesAfter,H=F&&F[N]&&F[N].test(L);if(!H&&V||B||I&&!/[\s;,.})\]\\]/.test(I))return null;var U=x[O.column-2];if(L==N&&(U==N||D.test(U)))return null;R=!0}return{text:R?N+N:"",selection:[1,1]}}}}),this.add("string_dquotes","deletion",function(f,v,p,y,m){var $=y.$mode.$quotes||r,N=y.doc.getTextRange(m);if(!m.isMultiLine()&&$.hasOwnProperty(N)){t(p);var M=y.doc.getLine(m.start.row),S=M.substring(m.start.column+1,m.start.column+2);if(S==N)return m.end.column++,m}}),h.closeDocComment!==!1&&this.add("doc comment end","insertion",function(f,v,p,y,m){if(f==="doc-start"&&(m===`
189
+ `||m===`\r
190
+ `)&&p.selection.isEmpty()){var $=p.getCursorPosition();if($.column===0)return;for(var N=y.doc.getLine($.row),M=y.doc.getLine($.row+1),S=y.getTokens($.row),O=0,x=0;x<S.length;x++){O+=S[x].value.length;var L=S[x];if(O>=$.column){if(O===$.column){if(!/\.doc/.test(L.type))return;if(/\*\//.test(L.value)){var I=S[x+1];if(!I||!/\.doc/.test(I.type))return}}var w=$.column-(O-L.value.length),_=L.value.indexOf("*/"),T=L.value.indexOf("/**",_>-1?_+2:0);if(T!==-1&&w>T&&w<T+3||_!==-1&&T!==-1&&w>=_&&w<=T||!/\.doc/.test(L.type))return;break}}var k=this.$getIndent(N);if(/\s*\*/.test(M))return/^\s*\*/.test(N)?{text:m+k+"* ",selection:[1,2+k.length,1,2+k.length]}:{text:m+k+" * ",selection:[1,3+k.length,1,3+k.length]};if(/\/\*\*/.test(N.substring(0,$.column)))return{text:m+k+" * "+m+" "+k+"*/",selection:[1,4+k.length,1,4+k.length]}}})},c.isSaneInsertion=function(h,f){var v=h.getCursorPosition(),p=new A(f,v.row,v.column);if(!this.$matchTokenType(p.getCurrentToken()||"text",g)){if(/[)}\]]/.test(h.session.getLine(v.row)[v.column]))return!0;var y=new A(f,v.row,v.column+1);if(!this.$matchTokenType(y.getCurrentToken()||"text",g))return!1}return p.stepForward(),p.getCurrentTokenRow()!==v.row||this.$matchTokenType(p.getCurrentToken()||"text",n)},c.$matchTokenType=function(h,f){return f.indexOf(h.type||h)>-1},c.recordAutoInsert=function(h,f,v){var p=h.getCursorPosition(),y=f.doc.getLine(p.row);this.isAutoInsertedClosing(p,y,s.autoInsertedLineEnd[0])||(s.autoInsertedBrackets=0),s.autoInsertedRow=p.row,s.autoInsertedLineEnd=v+y.substr(p.column),s.autoInsertedBrackets++},c.recordMaybeInsert=function(h,f,v){var p=h.getCursorPosition(),y=f.doc.getLine(p.row);this.isMaybeInsertedClosing(p,y)||(s.maybeInsertedBrackets=0),s.maybeInsertedRow=p.row,s.maybeInsertedLineStart=y.substr(0,p.column)+v,s.maybeInsertedLineEnd=y.substr(p.column),s.maybeInsertedBrackets++},c.isAutoInsertedClosing=function(h,f,v){return s.autoInsertedBrackets>0&&h.row===s.autoInsertedRow&&v===s.autoInsertedLineEnd[0]&&f.substr(h.column)===s.autoInsertedLineEnd},c.isMaybeInsertedClosing=function(h,f){return s.maybeInsertedBrackets>0&&h.row===s.maybeInsertedRow&&f.substr(h.column)===s.maybeInsertedLineEnd&&f.substr(0,h.column)==s.maybeInsertedLineStart},c.popAutoInsertedClosing=function(){s.autoInsertedLineEnd=s.autoInsertedLineEnd.substr(1),s.autoInsertedBrackets--},c.clearMaybeInsertedClosing=function(){s&&(s.maybeInsertedBrackets=0,s.maybeInsertedRow=-1)},b.inherits(c,C),d.CstyleBehaviour=c}),ace.define("ace/unicode",["require","exports","module"],function(l,d,E){for(var b=[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],C=0,A=[],a=0;a<b.length;a+=2)A.push(C+=b[a]),b[a+1]&&A.push(45,C+=b[a+1]);d.wordChars=String.fromCharCode.apply(null,A)}),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(l,d,E){var b=l("../config"),C=l("../tokenizer").Tokenizer,A=l("./text_highlight_rules").TextHighlightRules,a=l("./behaviour/cstyle").CstyleBehaviour,g=l("../unicode"),n=l("../lib/lang"),s=l("../token_iterator").TokenIterator,o=l("../range").Range,r;r=function(){this.HighlightRules=A},(function(){this.$defaultBehaviour=new a,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 C(this.$highlightRules.getRules())),this.$tokenizer},this.lineCommentStart="",this.blockComment="",this.toggleCommentLines=function(t,i,c,h){var f=i.doc,v=!0,p=!0,y=1/0,m=i.getTabSize(),$=!1;if(this.lineCommentStart){if(Array.isArray(this.lineCommentStart))var S=this.lineCommentStart.map(n.escapeRegExp).join("|"),N=this.lineCommentStart[0];else var S=n.escapeRegExp(this.lineCommentStart),N=this.lineCommentStart;S=new RegExp("^(\\s*)(?:"+S+") ?"),$=i.getUseSoftTabs();var L=function(B,F){var H=B.match(S);if(H){var U=H[1].length,z=H[0].length;!_(B,U,z)&&H[0][z-1]==" "&&z--,f.removeInLine(F,U,z)}},w=N+" ",x=function(B,F){(!v||/\S/.test(B))&&(_(B,y,y)?f.insertInLine({row:F,column:y},w):f.insertInLine({row:F,column:y},N))},I=function(B,F){return S.test(B)},_=function(B,F,H){for(var U=0;F--&&B.charAt(F)==" ";)U++;if(U%m!=0)return!1;for(var U=0;B.charAt(H++)==" ";)U++;return m>2?U%m!=m-1:U%m==0}}else{if(!this.blockComment)return!1;var N=this.blockComment.start,M=this.blockComment.end,S=new RegExp("^(\\s*)(?:"+n.escapeRegExp(N)+")"),O=new RegExp("(?:"+n.escapeRegExp(M)+")\\s*$"),x=function(R,D){I(R,D)||(!v||/\S/.test(R))&&(f.insertInLine({row:D,column:R.length},M),f.insertInLine({row:D,column:y},N))},L=function(R,D){var V;(V=R.match(O))&&f.removeInLine(D,R.length-V[0].length,R.length),(V=R.match(S))&&f.removeInLine(D,V[1].length,V[0].length)},I=function(R,D){if(S.test(R))return!0;for(var V=i.getTokens(D),B=0;B<V.length;B++)if(V[B].type==="comment")return!0}}function T(R){for(var D=c;D<=h;D++)R(f.getLine(D),D)}var k=1/0;T(function(R,D){var V=R.search(/\S/);V!==-1?(V<y&&(y=V),p&&!I(R,D)&&(p=!1)):k>R.length&&(k=R.length)}),y==1/0&&(y=k,v=!1,p=!1),$&&y%m!=0&&(y=Math.floor(y/m)*m),T(p?L:x)},this.toggleBlockComment=function(t,i,c,h){var f=this.blockComment;if(f){!f.start&&f[0]&&(f=f[0]);var v=new s(i,h.row,h.column),p=v.getCurrentToken();i.selection;var y=i.selection.toOrientedRange(),m,$;if(p&&/comment/.test(p.type)){for(var N,M;p&&/comment/.test(p.type);){var S=p.value.indexOf(f.start);if(S!=-1){var O=v.getCurrentTokenRow(),x=v.getCurrentTokenColumn()+S;N=new o(O,x,O,x+f.start.length);break}p=v.stepBackward()}for(var v=new s(i,h.row,h.column),p=v.getCurrentToken();p&&/comment/.test(p.type);){var S=p.value.indexOf(f.end);if(S!=-1){var O=v.getCurrentTokenRow(),x=v.getCurrentTokenColumn()+S;M=new o(O,x,O,x+f.end.length);break}p=v.stepForward()}M&&i.remove(M),N&&(i.remove(N),m=N.start.row,$=-f.start.length)}else $=f.start.length,m=c.start.row,i.insert(c.end,f.end),i.insert(c.start,f.start);y.start.row==m&&(y.start.column+=$),y.end.row==m&&(y.end.column+=$),i.selection.fromOrientedRange(y)}},this.getNextLineIndent=function(t,i,c){return this.$getIndent(i)},this.checkOutdent=function(t,i,c){return!1},this.autoOutdent=function(t,i,c){},this.$getIndent=function(t){return t.match(/^\s*/)[0]},this.createWorker=function(t){return null},this.createModeDelegates=function(t){this.$embeds=[],this.$modes={};for(var i in t)if(t[i]){var c=t[i],h=c.prototype.$id,f=b.$modes[h];f||(b.$modes[h]=f=new c),b.$modes[i]||(b.$modes[i]=f),this.$embeds.push(i),this.$modes[i]=f}for(var v=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"],p=function(m){(function($){var N=v[m],M=$[N];$[v[m]]=function(){return this.$delegator(N,arguments,M)}})(y)},y=this,i=0;i<v.length;i++)p(i)},this.$delegator=function(t,i,c){var h=i[0]||"start";if(typeof h!="string"){if(Array.isArray(h[2])){var f=h[2][h[2].length-1],v=this.$modes[f];if(v)return v[t].apply(v,[h[1]].concat([].slice.call(i,1)))}h=h[0]||"start"}for(var p=0;p<this.$embeds.length;p++)if(this.$modes[this.$embeds[p]]){var y=h.split(this.$embeds[p]);if(!y[0]&&y[1]){i[0]=y[1];var v=this.$modes[this.$embeds[p]];return v[t].apply(v,i)}}var m=c.apply(this,i);return c?m:void 0},this.transformAction=function(t,i,c,h,f){if(this.$behaviour){var v=this.$behaviour.getBehaviours();for(var p in v)if(v[p][i]){var y=v[p][i].apply(this,arguments);if(y)return y}}},this.getKeywords=function(t){if(!this.completionKeywords){var i=this.$tokenizer.rules,c=[];for(var h in i)for(var f=i[h],v=0,p=f.length;v<p;v++)if(typeof f[v].token=="string")/keyword|support|storage/.test(f[v].token)&&c.push(f[v].regex);else if(typeof f[v].token=="object"){for(var y=0,m=f[v].token.length;y<m;y++)if(/keyword|support|storage/.test(f[v].token[y])){var h=f[v].regex.match(/\(.+?\)/g)[y];c.push(h.substr(1,h.length-2))}}this.completionKeywords=c}return t?c.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(t,i,c,h){var f=this.$keywordList||this.$createKeywordList();return f.map(function(v){return{name:v,value:v,score:0,meta:"keyword"}})},this.$id="ace/mode/text"}).call(r.prototype),d.Mode=r}),ace.define("ace/line_widgets",["require","exports","module","ace/lib/dom"],function(l,d,E){var b=l("./lib/dom"),C=function(){function A(a){this.session=a,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 A.prototype.getRowLength=function(a){var g;return this.lineWidgets?g=this.lineWidgets[a]&&this.lineWidgets[a].rowCount||0:g=0,!this.$useWrapMode||!this.$wrapData[a]?1+g:this.$wrapData[a].length+1+g},A.prototype.$getWidgetScreenLength=function(){var a=0;return this.lineWidgets.forEach(function(g){g&&g.rowCount&&!g.hidden&&(a+=g.rowCount)}),a},A.prototype.$onChangeEditor=function(a){this.attach(a.editor)},A.prototype.attach=function(a){a&&a.widgetManager&&a.widgetManager!=this&&a.widgetManager.detach(),this.editor!=a&&(this.detach(),this.editor=a,a&&(a.widgetManager=this,a.renderer.on("beforeRender",this.measureWidgets),a.renderer.on("afterRender",this.renderWidgets)))},A.prototype.detach=function(a){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 n=this.session.lineWidgets;n&&n.forEach(function(s){s&&s.el&&s.el.parentNode&&(s._inDocument=!1,s.el.parentNode.removeChild(s.el))})}},A.prototype.updateOnFold=function(a,g){var n=g.lineWidgets;if(!(!n||!a.action)){for(var s=a.data,o=s.start.row,r=s.end.row,t=a.action=="add",i=o+1;i<r;i++)n[i]&&(n[i].hidden=t);n[r]&&(t?n[o]?n[r].hidden=t:n[o]=n[r]:(n[o]==n[r]&&(n[o]=void 0),n[r].hidden=t))}},A.prototype.updateOnChange=function(a){var g=this.session.lineWidgets;if(g){var n=a.start.row,s=a.end.row-n;if(s!==0)if(a.action=="remove"){var o=g.splice(n+1,s);!g[n]&&o[o.length-1]&&(g[n]=o.pop()),o.forEach(function(t){t&&this.removeLineWidget(t)},this),this.$updateRows()}else{var r=new Array(s);g[n]&&g[n].column!=null&&a.start.column>g[n].column&&n++,r.unshift(n,0),g.splice.apply(g,r),this.$updateRows()}}},A.prototype.$updateRows=function(){var a=this.session.lineWidgets;if(a){var g=!0;a.forEach(function(n,s){if(n)for(g=!1,n.row=s;n.$oldWidget;)n.$oldWidget.row=s,n=n.$oldWidget}),g&&(this.session.lineWidgets=null)}},A.prototype.$registerLineWidget=function(a){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var g=this.session.lineWidgets[a.row];return g&&(a.$oldWidget=g,g.el&&g.el.parentNode&&(g.el.parentNode.removeChild(g.el),g._inDocument=!1)),this.session.lineWidgets[a.row]=a,a},A.prototype.addLineWidget=function(a){if(this.$registerLineWidget(a),a.session=this.session,!this.editor)return a;var g=this.editor.renderer;a.html&&!a.el&&(a.el=b.createElement("div"),a.el.innerHTML=a.html),a.text&&!a.el&&(a.el=b.createElement("div"),a.el.textContent=a.text),a.el&&(b.addCssClass(a.el,"ace_lineWidgetContainer"),a.className&&b.addCssClass(a.el,a.className),a.el.style.position="absolute",a.el.style.zIndex="5",g.container.appendChild(a.el),a._inDocument=!0,a.coverGutter||(a.el.style.zIndex="3"),a.pixelHeight==null&&(a.pixelHeight=a.el.offsetHeight)),a.rowCount==null&&(a.rowCount=a.pixelHeight/g.layerConfig.lineHeight);var n=this.session.getFoldAt(a.row,0);if(a.$fold=n,n){var s=this.session.lineWidgets;a.row==n.end.row&&!s[n.start.row]?s[n.start.row]=a:a.hidden=!0}return this.session._emit("changeFold",{data:{start:{row:a.row}}}),this.$updateRows(),this.renderWidgets(null,g),this.onWidgetChanged(a),a},A.prototype.removeLineWidget=function(a){if(a._inDocument=!1,a.session=null,a.el&&a.el.parentNode&&a.el.parentNode.removeChild(a.el),a.editor&&a.editor.destroy)try{a.editor.destroy()}catch{}if(this.session.lineWidgets){var g=this.session.lineWidgets[a.row];if(g==a)this.session.lineWidgets[a.row]=a.$oldWidget,a.$oldWidget&&this.onWidgetChanged(a.$oldWidget);else for(;g;){if(g.$oldWidget==a){g.$oldWidget=a.$oldWidget;break}g=g.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:a.row}}}),this.$updateRows()},A.prototype.getWidgetsAtRow=function(a){for(var g=this.session.lineWidgets,n=g&&g[a],s=[];n;)s.push(n),n=n.$oldWidget;return s},A.prototype.onWidgetChanged=function(a){this.session._changedWidgets.push(a),this.editor&&this.editor.renderer.updateFull()},A.prototype.measureWidgets=function(a,g){var n=this.session._changedWidgets,s=g.layerConfig;if(!(!n||!n.length)){for(var o=1/0,r=0;r<n.length;r++){var t=n[r];if(!(!t||!t.el)&&t.session==this.session){if(!t._inDocument){if(this.session.lineWidgets[t.row]!=t)continue;t._inDocument=!0,g.container.appendChild(t.el)}t.h=t.el.offsetHeight,t.fixedWidth||(t.w=t.el.offsetWidth,t.screenWidth=Math.ceil(t.w/s.characterWidth));var i=t.h/s.lineHeight;t.coverLine&&(i-=this.session.getRowLineCount(t.row),i<0&&(i=0)),t.rowCount!=i&&(t.rowCount=i,t.row<o&&(o=t.row))}}o!=1/0&&(this.session._emit("changeFold",{data:{start:{row:o}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]}},A.prototype.renderWidgets=function(a,g){var n=g.layerConfig,s=this.session.lineWidgets;if(s){for(var o=Math.min(this.firstRow,n.firstRow),r=Math.max(this.lastRow,n.lastRow,s.length);o>0&&!s[o];)o--;this.firstRow=n.firstRow,this.lastRow=n.lastRow,g.$cursorLayer.config=n;for(var t=o;t<=r;t++){var i=s[t];if(!(!i||!i.el)){if(i.hidden){i.el.style.top=-100-(i.pixelHeight||0)+"px";continue}i._inDocument||(i._inDocument=!0,g.container.appendChild(i.el));var c=g.$cursorLayer.getPixelPosition({row:t,column:0},!0).top;i.coverLine||(c+=n.lineHeight*this.session.getRowLineCount(i.row)),i.el.style.top=c-n.offset+"px";var h=i.coverGutter?0:g.gutterWidth;i.fixedWidth||(h-=g.scrollLeft),i.el.style.left=h+"px",i.fullWidth&&i.screenWidth&&(i.el.style.minWidth=n.width+2*n.padding+"px"),i.fixedWidth?i.el.style.right=g.scrollBar.getWidth()+"px":i.el.style.right=""}}}},A}();d.LineWidgets=C}),ace.define("ace/apply_delta",["require","exports","module"],function(l,d,E){d.applyDelta=function(b,C,A){var a=C.start.row,g=C.start.column,n=b[a]||"";switch(C.action){case"insert":var s=C.lines;if(s.length===1)b[a]=n.substring(0,g)+C.lines[0]+n.substring(g);else{var o=[a,1].concat(C.lines);b.splice.apply(b,o),b[a]=n.substring(0,g)+b[a],b[a+C.lines.length-1]+=n.substring(g)}break;case"remove":var r=C.end.column,t=C.end.row;a===t?b[a]=n.substring(0,g)+n.substring(r):b.splice(a,t-a+1,n.substring(0,g)+b[t].substring(r));break}}}),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(l,d,E){var b=l("./lib/oop"),C=l("./lib/event_emitter").EventEmitter,A=function(){function n(s,o,r){this.$onChange=this.onChange.bind(this),this.attach(s),typeof o!="number"?this.setPosition(o.row,o.column):this.setPosition(o,r)}return n.prototype.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},n.prototype.getDocument=function(){return this.document},n.prototype.onChange=function(s){if(!(s.start.row==s.end.row&&s.start.row!=this.row)&&!(s.start.row>this.row)){var o=g(s,{row:this.row,column:this.column},this.$insertRight);this.setPosition(o.row,o.column,!0)}},n.prototype.setPosition=function(s,o,r){var t;if(r?t={row:s,column:o}:t=this.$clipPositionToDocument(s,o),!(this.row==t.row&&this.column==t.column)){var i={row:this.row,column:this.column};this.row=t.row,this.column=t.column,this._signal("change",{old:i,value:t})}},n.prototype.detach=function(){this.document.off("change",this.$onChange)},n.prototype.attach=function(s){this.document=s||this.document,this.document.on("change",this.$onChange)},n.prototype.$clipPositionToDocument=function(s,o){var r={};return s>=this.document.getLength()?(r.row=Math.max(0,this.document.getLength()-1),r.column=this.document.getLine(r.row).length):s<0?(r.row=0,r.column=0):(r.row=s,r.column=Math.min(this.document.getLine(r.row).length,Math.max(0,o))),o<0&&(r.column=0),r},n}();A.prototype.$insertRight=!1,b.implement(A.prototype,C);function a(n,s,o){var r=o?n.column<=s.column:n.column<s.column;return n.row<s.row||n.row==s.row&&r}function g(n,s,o){var r=n.action=="insert",t=(r?1:-1)*(n.end.row-n.start.row),i=(r?1:-1)*(n.end.column-n.start.column),c=n.start,h=r?c:n.end;return a(s,c,o)?{row:s.row,column:s.column}:a(h,s,!o)?{row:s.row+t,column:s.column+(s.row==h.row?i:0)}:{row:c.row,column:c.column}}d.Anchor=A}),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"],function(l,d,E){var b=l("./lib/oop"),C=l("./apply_delta").applyDelta,A=l("./lib/event_emitter").EventEmitter,a=l("./range").Range,g=l("./anchor").Anchor,n=function(){function s(o){this.$lines=[""],o.length===0?this.$lines=[""]:Array.isArray(o)?this.insertMergedLines({row:0,column:0},o):this.insert({row:0,column:0},o)}return s.prototype.setValue=function(o){var r=this.getLength()-1;this.remove(new a(0,0,r,this.getLine(r).length)),this.insert({row:0,column:0},o||"")},s.prototype.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},s.prototype.createAnchor=function(o,r){return new g(this,o,r)},s.prototype.$detectNewLine=function(o){var r=o.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=r?r[1]:`
191
+ `,this._signal("changeNewLineMode")},s.prototype.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return`\r
192
+ `;case"unix":return`
193
+ `;default:return this.$autoNewLine||`
194
+ `}},s.prototype.setNewLineMode=function(o){this.$newLineMode!==o&&(this.$newLineMode=o,this._signal("changeNewLineMode"))},s.prototype.getNewLineMode=function(){return this.$newLineMode},s.prototype.isNewLine=function(o){return o==`\r
195
+ `||o=="\r"||o==`
196
+ `},s.prototype.getLine=function(o){return this.$lines[o]||""},s.prototype.getLines=function(o,r){return this.$lines.slice(o,r+1)},s.prototype.getAllLines=function(){return this.getLines(0,this.getLength())},s.prototype.getLength=function(){return this.$lines.length},s.prototype.getTextRange=function(o){return this.getLinesForRange(o).join(this.getNewLineCharacter())},s.prototype.getLinesForRange=function(o){var r;if(o.start.row===o.end.row)r=[this.getLine(o.start.row).substring(o.start.column,o.end.column)];else{r=this.getLines(o.start.row,o.end.row),r[0]=(r[0]||"").substring(o.start.column);var t=r.length-1;o.end.row-o.start.row==t&&(r[t]=r[t].substring(0,o.end.column))}return r},s.prototype.insertLines=function(o,r){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(o,r)},s.prototype.removeLines=function(o,r){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(o,r)},s.prototype.insertNewLine=function(o){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(o,["",""])},s.prototype.insert=function(o,r){return this.getLength()<=1&&this.$detectNewLine(r),this.insertMergedLines(o,this.$split(r))},s.prototype.insertInLine=function(o,r){var t=this.clippedPos(o.row,o.column),i=this.pos(o.row,o.column+r.length);return this.applyDelta({start:t,end:i,action:"insert",lines:[r]},!0),this.clonePos(i)},s.prototype.clippedPos=function(o,r){var t=this.getLength();o===void 0?o=t:o<0?o=0:o>=t&&(o=t-1,r=void 0);var i=this.getLine(o);return r==null&&(r=i.length),r=Math.min(Math.max(r,0),i.length),{row:o,column:r}},s.prototype.clonePos=function(o){return{row:o.row,column:o.column}},s.prototype.pos=function(o,r){return{row:o,column:r}},s.prototype.$clipPosition=function(o){var r=this.getLength();return o.row>=r?(o.row=Math.max(0,r-1),o.column=this.getLine(r-1).length):(o.row=Math.max(0,o.row),o.column=Math.min(Math.max(o.column,0),this.getLine(o.row).length)),o},s.prototype.insertFullLines=function(o,r){o=Math.min(Math.max(o,0),this.getLength());var t=0;o<this.getLength()?(r=r.concat([""]),t=0):(r=[""].concat(r),o--,t=this.$lines[o].length),this.insertMergedLines({row:o,column:t},r)},s.prototype.insertMergedLines=function(o,r){var t=this.clippedPos(o.row,o.column),i={row:t.row+r.length-1,column:(r.length==1?t.column:0)+r[r.length-1].length};return this.applyDelta({start:t,end:i,action:"insert",lines:r}),this.clonePos(i)},s.prototype.remove=function(o){var r=this.clippedPos(o.start.row,o.start.column),t=this.clippedPos(o.end.row,o.end.column);return this.applyDelta({start:r,end:t,action:"remove",lines:this.getLinesForRange({start:r,end:t})}),this.clonePos(r)},s.prototype.removeInLine=function(o,r,t){var i=this.clippedPos(o,r),c=this.clippedPos(o,t);return this.applyDelta({start:i,end:c,action:"remove",lines:this.getLinesForRange({start:i,end:c})},!0),this.clonePos(i)},s.prototype.removeFullLines=function(o,r){o=Math.min(Math.max(0,o),this.getLength()-1),r=Math.min(Math.max(0,r),this.getLength()-1);var t=r==this.getLength()-1&&o>0,i=r<this.getLength()-1,c=t?o-1:o,h=t?this.getLine(c).length:0,f=i?r+1:r,v=i?0:this.getLine(f).length,p=new a(c,h,f,v),y=this.$lines.slice(o,r+1);return this.applyDelta({start:p.start,end:p.end,action:"remove",lines:this.getLinesForRange(p)}),y},s.prototype.removeNewLine=function(o){o<this.getLength()-1&&o>=0&&this.applyDelta({start:this.pos(o,this.getLine(o).length),end:this.pos(o+1,0),action:"remove",lines:["",""]})},s.prototype.replace=function(o,r){if(o instanceof a||(o=a.fromPoints(o.start,o.end)),r.length===0&&o.isEmpty())return o.start;if(r==this.getTextRange(o))return o.end;this.remove(o);var t;return r?t=this.insert(o.start,r):t=o.start,t},s.prototype.applyDeltas=function(o){for(var r=0;r<o.length;r++)this.applyDelta(o[r])},s.prototype.revertDeltas=function(o){for(var r=o.length-1;r>=0;r--)this.revertDelta(o[r])},s.prototype.applyDelta=function(o,r){var t=o.action=="insert";(t?o.lines.length<=1&&!o.lines[0]:!a.comparePoints(o.start,o.end))||(t&&o.lines.length>2e4?this.$splitAndapplyLargeDelta(o,2e4):(C(this.$lines,o,r),this._signal("change",o)))},s.prototype.$safeApplyDelta=function(o){var r=this.$lines.length;(o.action=="remove"&&o.start.row<r&&o.end.row<r||o.action=="insert"&&o.start.row<=r)&&this.applyDelta(o)},s.prototype.$splitAndapplyLargeDelta=function(o,r){for(var t=o.lines,i=t.length-r+1,c=o.start.row,h=o.start.column,f=0,v=0;f<i;f=v){v+=r-1;var p=t.slice(f,v);p.push(""),this.applyDelta({start:this.pos(c+f,h),end:this.pos(c+v,h=0),action:o.action,lines:p},!0)}o.lines=t.slice(f),o.start.row=c+f,o.start.column=h,this.applyDelta(o,!0)},s.prototype.revertDelta=function(o){this.$safeApplyDelta({start:this.clonePos(o.start),end:this.clonePos(o.end),action:o.action=="insert"?"remove":"insert",lines:o.lines.slice()})},s.prototype.indexToPosition=function(o,r){for(var t=this.$lines||this.getAllLines(),i=this.getNewLineCharacter().length,c=r||0,h=t.length;c<h;c++)if(o-=t[c].length+i,o<0)return{row:c,column:o+t[c].length+i};return{row:h-1,column:o+t[h-1].length+i}},s.prototype.positionToIndex=function(o,r){for(var t=this.$lines||this.getAllLines(),i=this.getNewLineCharacter().length,c=0,h=Math.min(o.row,t.length),f=r||0;f<h;++f)c+=t[f].length+i;return c+o.column},s.prototype.$split=function(o){return o.split(/\r\n|\r|\n/)},s}();n.prototype.$autoNewLine="",n.prototype.$newLineMode="auto",b.implement(n.prototype,A),d.Document=n}),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(l,d,E){var b=l("./lib/oop"),C=l("./lib/event_emitter").EventEmitter,A=function(){function a(g,n){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=g;var s=this;this.$worker=function(){if(s.running){for(var o=new Date,r=s.currentLine,t=-1,i=s.doc,c=r;s.lines[r];)r++;var h=i.getLength(),f=0;for(s.running=!1;r<h;){s.$tokenizeRow(r),t=r;do r++;while(s.lines[r]);if(f++,f%5===0&&new Date-o>20){s.running=setTimeout(s.$worker,20);break}}s.currentLine=r,t==-1&&(t=r),c<=t&&s.fireUpdateEvent(c,t)}}}return a.prototype.setTokenizer=function(g){this.tokenizer=g,this.lines=[],this.states=[],this.start(0)},a.prototype.setDocument=function(g){this.doc=g,this.lines=[],this.states=[],this.stop()},a.prototype.fireUpdateEvent=function(g,n){var s={first:g,last:n};this._signal("update",{data:s})},a.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)},a.prototype.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},a.prototype.$updateOnChange=function(g){var n=g.start.row,s=g.end.row-n;if(s===0)this.lines[n]=null;else if(g.action=="remove")this.lines.splice(n,s+1,null),this.states.splice(n,s+1,null);else{var o=Array(s+1);o.unshift(n,1),this.lines.splice.apply(this.lines,o),this.states.splice.apply(this.states,o)}this.currentLine=Math.min(n,this.currentLine,this.doc.getLength()),this.stop()},a.prototype.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},a.prototype.getTokens=function(g){return this.lines[g]||this.$tokenizeRow(g)},a.prototype.getState=function(g){return this.currentLine==g&&this.$tokenizeRow(g),this.states[g]||"start"},a.prototype.$tokenizeRow=function(g){var n=this.doc.getLine(g),s=this.states[g-1],o=this.tokenizer.getLineTokens(n,s,g);return this.states[g]+""!=o.state+""?(this.states[g]=o.state,this.lines[g+1]=null,this.currentLine>g+1&&(this.currentLine=g+1)):this.currentLine==g&&(this.currentLine=g+1),this.lines[g]=o.tokens},a.prototype.cleanup=function(){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.removeAllListeners()},a}();b.implement(A.prototype,C),d.BackgroundTokenizer=A}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/range"],function(l,d,E){var b=l("./lib/lang"),C=l("./range").Range,A=function(){function a(g,n,s){s===void 0&&(s="text"),this.setRegexp(g),this.clazz=n,this.type=s,this.docLen=0}return a.prototype.setRegexp=function(g){this.regExp+""!=g+""&&(this.regExp=g,this.cache=[])},a.prototype.update=function(g,n,s,o){if(this.regExp){for(var r=o.firstRow,t=o.lastRow,i={},c=s.$editor.$search,h=c.$isMultilineSearch(s.$editor.getLastSearchOptions()),f=r;f<=t;f++){var v=this.cache[f];if(v==null||s.getValue().length!=this.docLen){if(h){v=[];var p=c.$multiLineForward(s,this.regExp,f,t);if(p){var y=p.endRow<=t?p.endRow-1:t;y>f&&(f=y),v.push(new C(p.startRow,p.startCol,p.endRow,p.endCol))}v.length>this.MAX_RANGES&&(v=v.slice(0,this.MAX_RANGES))}else v=b.getMatchOffsets(s.getLine(f),this.regExp),v.length>this.MAX_RANGES&&(v=v.slice(0,this.MAX_RANGES)),v=v.map(function(M){return new C(f,M.offset,f,M.offset+M.length)});this.cache[f]=v.length?v:""}if(v.length!==0)for(var m=v.length;m--;){var $=v[m].toScreenRange(s),N=$.toString();i[N]||(i[N]=!0,n.drawSingleLineMarker(g,$,this.clazz,o))}}this.docLen=s.getValue().length}},a}();A.prototype.MAX_RANGES=500,d.SearchHighlight=A}),ace.define("ace/undomanager",["require","exports","module","ace/range"],function(l,d,E){var b=function(){function y(){this.$keepRedoStack,this.$maxRev=0,this.$fromUndo=!1,this.$undoDepth=1/0,this.reset()}return y.prototype.addSession=function(m){this.$session=m},y.prototype.add=function(m,$,N){if(!this.$fromUndo&&m!=this.$lastDelta){if(this.$keepRedoStack||(this.$redoStack.length=0),$===!1||!this.lastDeltas){this.lastDeltas=[];var M=this.$undoStack.length;M>this.$undoDepth-1&&this.$undoStack.splice(0,M-this.$undoDepth+1),this.$undoStack.push(this.lastDeltas),m.id=this.$rev=++this.$maxRev}(m.action=="remove"||m.action=="insert")&&(this.$lastDelta=m),this.lastDeltas.push(m)}},y.prototype.addSelection=function(m,$){this.selections.push({value:m,rev:$||this.$rev})},y.prototype.startNewGroup=function(){return this.lastDeltas=null,this.$rev},y.prototype.markIgnored=function(m,$){$==null&&($=this.$rev+1);for(var N=this.$undoStack,M=N.length;M--;){var S=N[M][0];if(S.id<=m)break;S.id<$&&(S.ignore=!0)}this.lastDeltas=null},y.prototype.getSelection=function(m,$){for(var N=this.selections,M=N.length;M--;){var S=N[M];if(S.rev<m)return $&&(S=N[M+1]),S}},y.prototype.getRevision=function(){return this.$rev},y.prototype.getDeltas=function(m,$){$==null&&($=this.$rev+1);for(var N=this.$undoStack,M=null,S=0,O=N.length;O--;){var x=N[O][0];if(x.id<$&&!M&&(M=O+1),x.id<=m){S=O+1;break}}return N.slice(S,M)},y.prototype.getChangedRanges=function(m,$){$==null&&($=this.$rev+1)},y.prototype.getChangedLines=function(m,$){$==null&&($=this.$rev+1)},y.prototype.undo=function(m,$){this.lastDeltas=null;var N=this.$undoStack;if(C(N,N.length)){m||(m=this.$session),this.$redoStackBaseRev!==this.$rev&&this.$redoStack.length&&(this.$redoStack=[]),this.$fromUndo=!0;var M=N.pop(),S=null;return M&&(S=m.undoChanges(M,$),this.$redoStack.push(M),this.$syncRev()),this.$fromUndo=!1,S}},y.prototype.redo=function(m,$){if(this.lastDeltas=null,m||(m=this.$session),this.$fromUndo=!0,this.$redoStackBaseRev!=this.$rev){var N=this.getDeltas(this.$redoStackBaseRev,this.$rev+1);p(this.$redoStack,N),this.$redoStackBaseRev=this.$rev,this.$redoStack.forEach(function(O){O[0].id=++this.$maxRev},this)}var M=this.$redoStack.pop(),S=null;return M&&(S=m.redoChanges(M,$),this.$undoStack.push(M),this.$syncRev()),this.$fromUndo=!1,S},y.prototype.$syncRev=function(){var m=this.$undoStack,$=m[m.length-1],N=$&&$[0].id||0;this.$redoStackBaseRev=N,this.$rev=N},y.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=[]},y.prototype.canUndo=function(){return this.$undoStack.length>0},y.prototype.canRedo=function(){return this.$redoStack.length>0},y.prototype.bookmark=function(m){m==null&&(m=this.$rev),this.mark=m},y.prototype.isAtBookmark=function(){return this.$rev===this.mark},y.prototype.toJSON=function(){return{$redoStack:this.$redoStack,$undoStack:this.$undoStack}},y.prototype.fromJSON=function(m){this.reset(),this.$undoStack=m.$undoStack,this.$redoStack=m.$redoStack},y.prototype.$prettyPrint=function(m){return m?s(m):s(this.$undoStack)+`
197
+ ---
198
+ `+s(this.$redoStack)},y}();b.prototype.hasUndo=b.prototype.canUndo,b.prototype.hasRedo=b.prototype.canRedo,b.prototype.isClean=b.prototype.isAtBookmark,b.prototype.markClean=b.prototype.bookmark;function C(y,m){for(var $=m;$--;){var N=y[$];if(N&&!N[0].ignore){for(;$<m-1;){var M=t(y[$],y[$+1]);y[$]=M[0],y[$+1]=M[1],$++}return!0}}}var A=l("./range").Range,a=A.comparePoints;A.comparePoints;function g(y){return{row:y.row,column:y.column}}function n(y){return{start:g(y.start),end:g(y.end),action:y.action,lines:y.lines.slice()}}function s(y){if(y=y||this,Array.isArray(y))return y.map(s).join(`
199
+ `);var m="";return y.action?(m=y.action=="insert"?"+":"-",m+="["+y.lines+"]"):y.value&&(Array.isArray(y.value)?m=y.value.map(o).join(`
200
+ `):m=o(y.value)),y.start&&(m+=o(y)),(y.id||y.rev)&&(m+=" ("+(y.id||y.rev)+")"),m}function o(y){return y.start.row+":"+y.start.column+"=>"+y.end.row+":"+y.end.column}function r(y,m){var $=y.action=="insert",N=m.action=="insert";if($&&N)if(a(m.start,y.end)>=0)c(m,y,-1);else if(a(m.start,y.start)<=0)c(y,m,1);else return null;else if($&&!N)if(a(m.start,y.end)>=0)c(m,y,-1);else if(a(m.end,y.start)<=0)c(y,m,-1);else return null;else if(!$&&N)if(a(m.start,y.start)>=0)c(m,y,1);else if(a(m.start,y.start)<=0)c(y,m,1);else return null;else if(!$&&!N)if(a(m.start,y.start)>=0)c(m,y,1);else if(a(m.end,y.start)<=0)c(y,m,-1);else return null;return[m,y]}function t(y,m){for(var $=y.length;$--;)for(var N=0;N<m.length;N++)if(!r(y[$],m[N])){for(;$<y.length;){for(;N--;)r(m[N],y[$]);N=m.length,$++}return[y,m]}return y.selectionBefore=m.selectionBefore=y.selectionAfter=m.selectionAfter=null,[m,y]}function i(y,m){var $=y.action=="insert",N=m.action=="insert";if($&&N)a(y.start,m.start)<0?c(m,y,1):c(y,m,1);else if($&&!N)a(y.start,m.end)>=0?c(y,m,-1):(a(y.start,m.start)<=0||c(y,A.fromPoints(m.start,y.start),-1),c(m,y,1));else if(!$&&N)a(m.start,y.end)>=0?c(m,y,-1):(a(m.start,y.start)<=0||c(m,A.fromPoints(y.start,m.start),-1),c(y,m,1));else if(!$&&!N)if(a(m.start,y.end)>=0)c(m,y,-1);else if(a(m.end,y.start)<=0)c(y,m,-1);else{var M,S;return a(y.start,m.start)<0&&(M=y,y=f(y,m.start)),a(y.end,m.end)>0&&(S=f(y,m.end)),h(m.end,y.start,y.end,-1),S&&!M&&(y.lines=S.lines,y.start=S.start,y.end=S.end,S=y),[m,M,S].filter(Boolean)}return[m,y]}function c(y,m,$){h(y.start,m.start,m.end,$),h(y.end,m.start,m.end,$)}function h(y,m,$,N){y.row==(N==1?m:$).row&&(y.column+=N*($.column-m.column)),y.row+=N*($.row-m.row)}function f(y,m){var $=y.lines,N=y.end;y.end=g(m);var M=y.end.row-y.start.row,S=$.splice(M,$.length),O=M?m.column:m.column-y.start.column;$.push(S[0].substring(0,O)),S[0]=S[0].substr(O);var x={start:g(m),end:N,lines:S,action:y.action};return x}function v(y,m){m=n(m);for(var $=y.length;$--;){for(var N=y[$],M=0;M<N.length;M++){var S=N[M],O=i(S,m);m=O[0],O.length!=2&&(O[2]?(N.splice(M+1,1,O[1],O[2]),M++):O[1]||(N.splice(M,1),M--))}N.length||y.splice($,1)}return y}function p(y,m){for(var $=0;$<m.length;$++)for(var N=m[$],M=0;M<N.length;M++)v(y,N[M])}d.UndoManager=b}),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(l,d,E){var b=l("../range").Range,C=function(){function A(a,g){this.foldData=a,Array.isArray(g)?this.folds=g:g=this.folds=[g];var n=g[g.length-1];this.range=new b(g[0].start.row,g[0].start.column,n.end.row,n.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach(function(s){s.setFoldLine(this)},this)}return A.prototype.shiftRow=function(a){this.start.row+=a,this.end.row+=a,this.folds.forEach(function(g){g.start.row+=a,g.end.row+=a})},A.prototype.addFold=function(a){if(a.sameRow){if(a.start.row<this.startRow||a.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(a),this.folds.sort(function(g,n){return-g.range.compareEnd(n.start.row,n.start.column)}),this.range.compareEnd(a.start.row,a.start.column)>0?(this.end.row=a.end.row,this.end.column=a.end.column):this.range.compareStart(a.end.row,a.end.column)<0&&(this.start.row=a.start.row,this.start.column=a.start.column)}else if(a.start.row==this.end.row)this.folds.push(a),this.end.row=a.end.row,this.end.column=a.end.column;else if(a.end.row==this.start.row)this.folds.unshift(a),this.start.row=a.start.row,this.start.column=a.start.column;else throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");a.foldLine=this},A.prototype.containsRow=function(a){return a>=this.start.row&&a<=this.end.row},A.prototype.walk=function(a,g,n){var s=0,o=this.folds,r,t,i,c=!0;g==null&&(g=this.end.row,n=this.end.column);for(var h=0;h<o.length;h++){if(r=o[h],t=r.range.compareStart(g,n),t==-1){a(null,g,n,s,c);return}if(i=a(null,r.start.row,r.start.column,s,c),i=!i&&a(r.placeholder,r.start.row,r.start.column,s),i||t===0)return;c=!r.sameRow,s=r.end.column}a(null,g,n,s,c)},A.prototype.getNextFoldTo=function(a,g){for(var n,s,o=0;o<this.folds.length;o++){if(n=this.folds[o],s=n.range.compareEnd(a,g),s==-1)return{fold:n,kind:"after"};if(s===0)return{fold:n,kind:"inside"}}return null},A.prototype.addRemoveChars=function(a,g,n){var s=this.getNextFoldTo(a,g),o,r;if(s){if(o=s.fold,s.kind=="inside"&&o.start.column!=g&&o.start.row!=a)window.console&&window.console.log(a,g,o);else if(o.start.row==a){r=this.folds;var t=r.indexOf(o);for(t===0&&(this.start.column+=n),t;t<r.length;t++){if(o=r[t],o.start.column+=n,!o.sameRow)return;o.end.column+=n}this.end.column+=n}}},A.prototype.split=function(a,g){var n=this.getNextFoldTo(a,g);if(!n||n.kind=="inside")return null;var s=n.fold,o=this.folds,r=this.foldData,t=o.indexOf(s),i=o[t-1];this.end.row=i.end.row,this.end.column=i.end.column,o=o.splice(t,o.length-t);var c=new A(r,o);return r.splice(r.indexOf(this)+1,0,c),c},A.prototype.merge=function(a){for(var g=a.folds,n=0;n<g.length;n++)this.addFold(g[n]);var s=this.foldData;s.splice(s.indexOf(a),1)},A.prototype.toString=function(){var a=[this.range.toString()+": ["];return this.folds.forEach(function(g){a.push(" "+g.toString())}),a.push("]"),a.join(`
201
+ `)},A.prototype.idxToPosition=function(a){for(var g=0,n=0;n<this.folds.length;n++){var s=this.folds[n];if(a-=s.start.column-g,a<0)return{row:s.start.row,column:s.start.column+a};if(a-=s.placeholder.length,a<0)return s.start;g=s.end.column}return{row:this.end.row,column:this.end.column+a}},A}();d.FoldLine=C}),ace.define("ace/range_list",["require","exports","module","ace/range"],function(l,d,E){var b=l("./range").Range,C=b.comparePoints,A=function(){function a(){this.ranges=[],this.$bias=1}return a.prototype.pointIndex=function(g,n,s){for(var o=this.ranges,r=s||0;r<o.length;r++){var t=o[r],i=C(g,t.end);if(!(i>0)){var c=C(g,t.start);return i===0?n&&c!==0?-r-2:r:c>0||c===0&&!n?r:-r-1}}return-r-1},a.prototype.add=function(g){var n=!g.isEmpty(),s=this.pointIndex(g.start,n);s<0&&(s=-s-1);var o=this.pointIndex(g.end,n,s);return o<0?o=-o-1:o++,this.ranges.splice(s,o-s,g)},a.prototype.addList=function(g){for(var n=[],s=g.length;s--;)n.push.apply(n,this.add(g[s]));return n},a.prototype.substractPoint=function(g){var n=this.pointIndex(g);if(n>=0)return this.ranges.splice(n,1)},a.prototype.merge=function(){var g=[],n=this.ranges;n=n.sort(function(i,c){return C(i.start,c.start)});for(var s=n[0],o,r=1;r<n.length;r++){o=s,s=n[r];var t=C(o.end,s.start);t<0||t==0&&!o.isEmpty()&&!s.isEmpty()||(C(o.end,s.end)<0&&(o.end.row=s.end.row,o.end.column=s.end.column),n.splice(r,1),g.push(s),s=o,r--)}return this.ranges=n,g},a.prototype.contains=function(g,n){return this.pointIndex({row:g,column:n})>=0},a.prototype.containsPoint=function(g){return this.pointIndex(g)>=0},a.prototype.rangeAtPoint=function(g){var n=this.pointIndex(g);if(n>=0)return this.ranges[n]},a.prototype.clipRows=function(g,n){var s=this.ranges;if(s[0].start.row>n||s[s.length-1].start.row<g)return[];var o=this.pointIndex({row:g,column:0});o<0&&(o=-o-1);var r=this.pointIndex({row:n,column:0},o);r<0&&(r=-r-1);for(var t=[],i=o;i<r;i++)t.push(s[i]);return t},a.prototype.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},a.prototype.attach=function(g){this.session&&this.detach(),this.session=g,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},a.prototype.detach=function(){this.session&&(this.session.removeListener("change",this.onChange),this.session=null)},a.prototype.$onChange=function(g){for(var n=g.start,s=g.end,o=n.row,r=s.row,t=this.ranges,i=0,c=t.length;i<c;i++){var h=t[i];if(h.end.row>=o)break}if(g.action=="insert")for(var f=r-o,v=-n.column+s.column;i<c;i++){var h=t[i];if(h.start.row>o)break;if(h.start.row==o&&h.start.column>=n.column&&(h.start.column==n.column&&this.$bias<=0||(h.start.column+=v,h.start.row+=f)),h.end.row==o&&h.end.column>=n.column){if(h.end.column==n.column&&this.$bias<0)continue;h.end.column==n.column&&v>0&&i<c-1&&h.end.column>h.start.column&&h.end.column==t[i+1].start.column&&(h.end.column-=v),h.end.column+=v,h.end.row+=f}}else for(var f=o-r,v=n.column-s.column;i<c;i++){var h=t[i];if(h.start.row>r)break;h.end.row<r&&(o<h.end.row||o==h.end.row&&n.column<h.end.column)?(h.end.row=o,h.end.column=n.column):h.end.row==r?h.end.column<=s.column?(f||h.end.column>n.column)&&(h.end.column=n.column,h.end.row=n.row):(h.end.column+=v,h.end.row+=f):h.end.row>r&&(h.end.row+=f),h.start.row<r&&(o<h.start.row||o==h.start.row&&n.column<h.start.column)?(h.start.row=o,h.start.column=n.column):h.start.row==r?h.start.column<=s.column?(f||h.start.column>n.column)&&(h.start.column=n.column,h.start.row=n.row):(h.start.column+=v,h.start.row+=f):h.start.row>r&&(h.start.row+=f)}if(f!=0&&i<c)for(;i<c;i++){var h=t[i];h.start.row+=f,h.end.row+=f}},a}();A.prototype.comparePoints=C,d.RangeList=A}),ace.define("ace/edit_session/fold",["require","exports","module","ace/range_list"],function(l,d,E){var b=this&&this.__extends||function(){var o=function(r,t){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,c){i.__proto__=c}||function(i,c){for(var h in c)Object.prototype.hasOwnProperty.call(c,h)&&(i[h]=c[h])},o(r,t)};return function(r,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");o(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),C=l("../range_list").RangeList,A=function(o){b(r,o);function r(t,i){var c=o.call(this)||this;return c.foldLine=null,c.placeholder=i,c.range=t,c.start=t.start,c.end=t.end,c.sameRow=t.start.row==t.end.row,c.subFolds=c.ranges=[],c}return r.prototype.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},r.prototype.setFoldLine=function(t){this.foldLine=t,this.subFolds.forEach(function(i){i.setFoldLine(t)})},r.prototype.clone=function(){var t=this.range.clone(),i=new r(t,this.placeholder);return this.subFolds.forEach(function(c){i.subFolds.push(c.clone())}),i.collapseChildren=this.collapseChildren,i},r.prototype.addSubFold=function(t){if(!this.range.isEqual(t)){g(t,this.start);for(var v=t.start.row,p=t.start.column,i=0,c=-1;i<this.subFolds.length&&(c=this.subFolds[i].range.compare(v,p),c==1);i++);var h=this.subFolds[i],f=0;if(c==0){if(h.range.containsRange(t))return h.addSubFold(t);f=1}for(var v=t.range.end.row,p=t.range.end.column,y=i,c=-1;y<this.subFolds.length&&(c=this.subFolds[y].range.compare(v,p),c==1);y++);c==0&&y++;for(var m=this.subFolds.splice(i,y-i,t),$=c==0?m.length-1:m.length,N=f;N<$;N++)t.addSubFold(m[N]);return t.setFoldLine(this.foldLine),t}},r.prototype.restoreRange=function(t){return s(t,this.start)},r}(C);function a(o,r){o.row-=r.row,o.row==0&&(o.column-=r.column)}function g(o,r){a(o.start,r),a(o.end,r)}function n(o,r){o.row==0&&(o.column+=r.column),o.row+=r.row}function s(o,r){n(o.start,r),n(o.end,r)}d.Fold=A}),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(l,d,E){var b=l("../range").Range,C=l("./fold_line").FoldLine,A=l("./fold").Fold,a=l("../token_iterator").TokenIterator,g=l("../mouse/mouse_event").MouseEvent;function n(){this.getFoldAt=function(s,o,r){var t=this.getFoldLine(s);if(!t)return null;for(var i=t.folds,c=0;c<i.length;c++){var h=i[c].range;if(h.contains(s,o)){if(r==1&&h.isEnd(s,o)&&!h.isEmpty())continue;if(r==-1&&h.isStart(s,o)&&!h.isEmpty())continue;return i[c]}}},this.getFoldsInRange=function(s){var o=s.start,r=s.end,t=this.$foldData,i=[];o.column+=1,r.column-=1;for(var c=0;c<t.length;c++){var h=t[c].range.compareRange(s);if(h!=2){if(h==-2)break;for(var f=t[c].folds,v=0;v<f.length;v++){var p=f[v];if(h=p.range.compareRange(s),h==-2)break;if(h==2)continue;if(h==42)break;i.push(p)}}}return o.column-=1,r.column+=1,i},this.getFoldsInRangeList=function(s){if(Array.isArray(s)){var o=[];s.forEach(function(r){o=o.concat(this.getFoldsInRange(r))},this)}else var o=this.getFoldsInRange(s);return o},this.getAllFolds=function(){for(var s=[],o=this.$foldData,r=0;r<o.length;r++)for(var t=0;t<o[r].folds.length;t++)s.push(o[r].folds[t]);return s},this.getFoldStringAt=function(s,o,r,t){if(t=t||this.getFoldLine(s),!t)return null;for(var i={end:{column:0}},c,h,f=0;f<t.folds.length;f++){h=t.folds[f];var v=h.range.compareEnd(s,o);if(v==-1){c=this.getLine(h.start.row).substring(i.end.column,h.start.column);break}else if(v===0)return null;i=h}return c||(c=this.getLine(h.start.row).substring(i.end.column)),r==-1?c.substring(0,o-i.end.column):r==1?c.substring(o-i.end.column):c},this.getFoldLine=function(s,o){var r=this.$foldData,t=0;for(o&&(t=r.indexOf(o)),t==-1&&(t=0),t;t<r.length;t++){var i=r[t];if(i.start.row<=s&&i.end.row>=s)return i;if(i.end.row>s)return null}return null},this.getNextFoldLine=function(s,o){var r=this.$foldData,t=0;for(o&&(t=r.indexOf(o)),t==-1&&(t=0),t;t<r.length;t++){var i=r[t];if(i.end.row>=s)return i}return null},this.getFoldedRowCount=function(s,o){for(var r=this.$foldData,t=o-s+1,i=0;i<r.length;i++){var c=r[i],h=c.end.row,f=c.start.row;if(h>=o){f<o&&(f>=s?t-=o-f:t=0);break}else h>=s&&(f>=s?t-=h-f:t-=h-s+1)}return t},this.$addFoldLine=function(s){return this.$foldData.push(s),this.$foldData.sort(function(o,r){return o.start.row-r.start.row}),s},this.addFold=function(s,o){var r=this.$foldData,t=!1,i;s instanceof A?i=s:(i=new A(o,s),i.collapseChildren=o.collapseChildren),this.$clipRangeToDocument(i.range);var c=i.start.row,h=i.start.column,f=i.end.row,v=i.end.column,p=this.getFoldAt(c,h,1),y=this.getFoldAt(f,v,-1);if(p&&y==p)return p.addSubFold(i);p&&!p.range.isStart(c,h)&&this.removeFold(p),y&&!y.range.isEnd(f,v)&&this.removeFold(y);var m=this.getFoldsInRange(i.range);m.length>0&&(this.removeFolds(m),i.collapseChildren||m.forEach(function(S){i.addSubFold(S)}));for(var $=0;$<r.length;$++){var N=r[$];if(f==N.start.row){N.addFold(i),t=!0;break}else if(c==N.end.row){if(N.addFold(i),t=!0,!i.sameRow){var M=r[$+1];if(M&&M.start.row==f){N.merge(M);break}}break}else if(f<=N.start.row)break}return t||(N=this.$addFoldLine(new C(this.$foldData,i))),this.$useWrapMode?this.$updateWrapData(N.start.row,N.start.row):this.$updateRowLengthCache(N.start.row,N.start.row),this.$modified=!0,this._signal("changeFold",{data:i,action:"add"}),i},this.addFolds=function(s){s.forEach(function(o){this.addFold(o)},this)},this.removeFold=function(s){var o=s.foldLine,r=o.start.row,t=o.end.row,i=this.$foldData,c=o.folds;if(c.length==1)i.splice(i.indexOf(o),1);else if(o.range.isEnd(s.end.row,s.end.column))c.pop(),o.end.row=c[c.length-1].end.row,o.end.column=c[c.length-1].end.column;else if(o.range.isStart(s.start.row,s.start.column))c.shift(),o.start.row=c[0].start.row,o.start.column=c[0].start.column;else if(s.sameRow)c.splice(c.indexOf(s),1);else{var h=o.split(s.start.row,s.start.column);c=h.folds,c.shift(),h.start.row=c[0].start.row,h.start.column=c[0].start.column}this.$updating||(this.$useWrapMode?this.$updateWrapData(r,t):this.$updateRowLengthCache(r,t)),this.$modified=!0,this._signal("changeFold",{data:s,action:"remove"})},this.removeFolds=function(s){for(var o=[],r=0;r<s.length;r++)o.push(s[r]);o.forEach(function(t){this.removeFold(t)},this),this.$modified=!0},this.expandFold=function(s){this.removeFold(s),s.subFolds.forEach(function(o){s.restoreRange(o),this.addFold(o)},this),s.collapseChildren>0&&this.foldAll(s.start.row+1,s.end.row,s.collapseChildren-1),s.subFolds=[]},this.expandFolds=function(s){s.forEach(function(o){this.expandFold(o)},this)},this.unfold=function(s,o){var r,t;if(s==null)r=new b(0,0,this.getLength(),0),o==null&&(o=!0);else if(typeof s=="number")r=new b(s,0,s,this.getLine(s).length);else if("row"in s)r=b.fromPoints(s,s);else{if(Array.isArray(s))return t=[],s.forEach(function(c){t=t.concat(this.unfold(c))},this),t;r=s}t=this.getFoldsInRangeList(r);for(var i=t;t.length==1&&b.comparePoints(t[0].start,r.start)<0&&b.comparePoints(t[0].end,r.end)>0;)this.expandFolds(t),t=this.getFoldsInRangeList(r);if(o!=!1?this.removeFolds(t):this.expandFolds(t),i.length)return i},this.isRowFolded=function(s,o){return!!this.getFoldLine(s,o)},this.getRowFoldEnd=function(s,o){var r=this.getFoldLine(s,o);return r?r.end.row:s},this.getRowFoldStart=function(s,o){var r=this.getFoldLine(s,o);return r?r.start.row:s},this.getFoldDisplayLine=function(s,o,r,t,i){t==null&&(t=s.start.row),i==null&&(i=0),o==null&&(o=s.end.row),r==null&&(r=this.getLine(o).length);var c=this.doc,h="";return s.walk(function(f,v,p,y){if(!(v<t)){if(v==t){if(p<i)return;y=Math.max(i,y)}f!=null?h+=f:h+=c.getLine(v).substring(y,p)}},o,r),h},this.getDisplayLine=function(s,o,r,t){var i=this.getFoldLine(s);if(i)return this.getFoldDisplayLine(i,s,o,r,t);var c;return c=this.doc.getLine(s),c.substring(t||0,o||c.length)},this.$cloneFoldData=function(){var s=[];return s=this.$foldData.map(function(o){var r=o.folds.map(function(t){return t.clone()});return new C(s,r)}),s},this.toggleFold=function(s){var o=this.selection,r=o.getRange(),t,i;if(r.isEmpty()){var c=r.start;if(t=this.getFoldAt(c.row,c.column),t){this.expandFold(t);return}else(i=this.findMatchingBracket(c))?r.comparePoint(i)==1?r.end=i:(r.start=i,r.start.column++,r.end.column--):(i=this.findMatchingBracket({row:c.row,column:c.column+1}))?(r.comparePoint(i)==1?r.end=i:r.start=i,r.start.column++):r=this.getCommentFoldRange(c.row,c.column)||r}else{var h=this.getFoldsInRange(r);if(s&&h.length){this.expandFolds(h);return}else h.length==1&&(t=h[0])}if(t||(t=this.getFoldAt(r.start.row,r.start.column)),t&&t.range.toString()==r.toString()){this.expandFold(t);return}var f="...";if(!r.isMultiLine()){if(f=this.getTextRange(r),f.length<4)return;f=f.trim().substring(0,2)+".."}this.addFold(f,r)},this.getCommentFoldRange=function(s,o,r){var t=new a(this,s,o),i=t.getCurrentToken(),c=i&&i.type;if(i&&/^comment|string/.test(c)){c=c.match(/comment|string/)[0],c=="comment"&&(c+="|doc-start|\\.doc");var h=new RegExp(c),f=new b;if(r!=1){do i=t.stepBackward();while(i&&h.test(i.type));i=t.stepForward()}f.start.row=t.getCurrentTokenRow(),f.start.column=t.getCurrentTokenColumn()+i.value.length,t=new a(this,s,o);var v=this.getState(t.$row);if(r!=-1){var p=-1;do if(i=t.stepForward(),p==-1){var y=this.getState(t.$row);v.toString()!==y.toString()&&(p=t.$row)}else if(t.$row>p)break;while(i&&h.test(i.type));i=t.stepBackward()}else i=t.getCurrentToken();return f.end.row=t.getCurrentTokenRow(),f.end.column=t.getCurrentTokenColumn(),f}},this.foldAll=function(s,o,r,t){r==null&&(r=1e5);var i=this.foldWidgets;if(i){o=o||this.getLength(),s=s||0;for(var c=s;c<o;c++)if(i[c]==null&&(i[c]=this.getFoldWidget(c)),i[c]=="start"&&!(t&&!t(c))){var h=this.getFoldWidgetRange(c);h&&h.isMultiLine()&&h.end.row<=o&&h.start.row>=s&&(c=h.end.row,h.collapseChildren=r,this.addFold("...",h))}}},this.foldToLevel=function(s){for(this.foldAll();s-- >0;)this.unfold(null,!1)},this.foldAllComments=function(){var s=this;this.foldAll(null,null,null,function(o){for(var r=s.getTokens(o),t=0;t<r.length;t++){var i=r[t];if(!(i.type=="text"&&/^\s+$/.test(i.value)))return!!/comment/.test(i.type)}})},this.$foldStyles={manual:1,markbegin:1,markbeginend:1},this.$foldStyle="markbegin",this.setFoldStyle=function(s){if(!this.$foldStyles[s])throw new Error("invalid fold style: "+s+"["+Object.keys(this.$foldStyles).join(", ")+"]");if(this.$foldStyle!=s){this.$foldStyle=s,s=="manual"&&this.unfold();var o=this.$foldMode;this.$setFolding(null),this.$setFolding(o)}},this.$setFolding=function(s){if(this.$foldMode!=s){if(this.$foldMode=s,this.off("change",this.$updateFoldWidgets),this.off("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets),this._signal("changeAnnotation"),!s||this.$foldStyle=="manual"){this.foldWidgets=null;return}this.foldWidgets=[],this.getFoldWidget=s.getFoldWidget.bind(s,this,this.$foldStyle),this.getFoldWidgetRange=s.getFoldWidgetRange.bind(s,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(s,o){var r=this.foldWidgets;if(!r||o&&r[s])return{};for(var t=s-1,i;t>=0;){var c=r[t];if(c==null&&(c=r[t]=this.getFoldWidget(t)),c=="start"){var h=this.getFoldWidgetRange(t);if(i||(i=h),h&&h.end.row>=s)break}t--}return{range:t!==-1&&h,firstRange:i}},this.onFoldWidgetClick=function(s,o){o instanceof g&&(o=o.domEvent);var r={children:o.shiftKey,all:o.ctrlKey||o.metaKey,siblings:o.altKey},t=this.$toggleFoldWidget(s,r);if(!t){var i=o.target||o.srcElement;i&&/ace_fold-widget/.test(i.className)&&(i.className+=" ace_invalid")}},this.$toggleFoldWidget=function(s,o){if(this.getFoldWidget){var r=this.getFoldWidget(s),t=this.getLine(s),i=r==="end"?-1:1,c=this.getFoldAt(s,i===-1?0:t.length,i);if(c)return o.children||o.all?this.removeFold(c):this.expandFold(c),c;var h=this.getFoldWidgetRange(s,!0);if(h&&!h.isMultiLine()&&(c=this.getFoldAt(h.start.row,h.start.column,1),c&&h.isEqual(c.range)))return this.removeFold(c),c;if(o.siblings){var f=this.getParentFoldRangeData(s);if(f.range)var v=f.range.start.row+1,p=f.range.end.row;this.foldAll(v,p,o.all?1e4:0)}else o.children?(p=h?h.end.row:this.getLength(),this.foldAll(s+1,p,o.all?1e4:0)):h&&(o.all&&(h.collapseChildren=1e4),this.addFold("...",h));return h}},this.toggleFoldWidget=function(s){var o=this.selection.getCursor().row;o=this.getRowFoldStart(o);var r=this.$toggleFoldWidget(o,{});if(!r){var t=this.getParentFoldRangeData(o,!0);if(r=t.range||t.firstRange,r){o=r.start.row;var i=this.getFoldAt(o,this.getLine(o).length,1);i?this.removeFold(i):this.addFold("...",r)}}},this.updateFoldWidgets=function(s){var o=s.start.row,r=s.end.row-o;if(r===0)this.foldWidgets[o]=null;else if(s.action=="remove")this.foldWidgets.splice(o,r+1,null);else{var t=Array(r+1);t.unshift(o,1),this.foldWidgets.splice.apply(this.foldWidgets,t)}},this.tokenizerUpdateFoldWidgets=function(s){var o=s.data;o.first!=o.last&&this.foldWidgets.length>o.first&&this.foldWidgets.splice(o.first,this.foldWidgets.length)}}d.Folding=n}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(l,d,E){var b=l("../token_iterator").TokenIterator,C=l("../range").Range;function A(){this.findMatchingBracket=function(a,g){if(a.column==0)return null;var n=g||this.getLine(a.row).charAt(a.column-1);if(n=="")return null;var s=n.match(/([\(\[\{])|([\)\]\}])/);return s?s[1]?this.$findClosingBracket(s[1],a):this.$findOpeningBracket(s[2],a):null},this.getBracketRange=function(a){var g=this.getLine(a.row),n=!0,s,o=g.charAt(a.column-1),r=o&&o.match(/([\(\[\{])|([\)\]\}])/);if(r||(o=g.charAt(a.column),a={row:a.row,column:a.column+1},r=o&&o.match(/([\(\[\{])|([\)\]\}])/),n=!1),!r)return null;if(r[1]){var t=this.$findClosingBracket(r[1],a);if(!t)return null;s=C.fromPoints(a,t),n||(s.end.column++,s.start.column--),s.cursor=s.end}else{var t=this.$findOpeningBracket(r[2],a);if(!t)return null;s=C.fromPoints(t,a),n||(s.start.column++,s.end.column--),s.cursor=s.start}return s},this.getMatchingBracketRanges=function(a,g){var n=this.getLine(a.row),s=/([\(\[\{])|([\)\]\}])/,o=!g&&n.charAt(a.column-1),r=o&&o.match(s);if(r||(o=(g===void 0||g)&&n.charAt(a.column),a={row:a.row,column:a.column+1},r=o&&o.match(s)),!r)return null;var t=new C(a.row,a.column-1,a.row,a.column),i=r[1]?this.$findClosingBracket(r[1],a):this.$findOpeningBracket(r[2],a);if(!i)return[t];var c=new C(i.row,i.column,i.row,i.column+1);return[t,c]},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(a,g,n){var s=this.$brackets[a],o=1,r=new b(this,g.row,g.column),t=r.getCurrentToken();if(t||(t=r.stepForward()),!!t){n||(n=new RegExp("(\\.?"+t.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)").replace(/-close\b/,"-(close|open)")+")+"));for(var i=g.column-r.getCurrentTokenColumn()-2,c=t.value;;){for(;i>=0;){var h=c.charAt(i);if(h==s){if(o-=1,o==0)return{row:r.getCurrentTokenRow(),column:i+r.getCurrentTokenColumn()}}else h==a&&(o+=1);i-=1}do t=r.stepBackward();while(t&&!n.test(t.type));if(t==null)break;c=t.value,i=c.length-1}return null}},this.$findClosingBracket=function(a,g,n){var s=this.$brackets[a],o=1,r=new b(this,g.row,g.column),t=r.getCurrentToken();if(t||(t=r.stepForward()),!!t){n||(n=new RegExp("(\\.?"+t.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)").replace(/-open\b/,"-(close|open)")+")+"));for(var i=g.column-r.getCurrentTokenColumn();;){for(var c=t.value,h=c.length;i<h;){var f=c.charAt(i);if(f==s){if(o-=1,o==0)return{row:r.getCurrentTokenRow(),column:i+r.getCurrentTokenColumn()}}else f==a&&(o+=1);i+=1}do t=r.stepForward();while(t&&!n.test(t.type));if(t==null)break;i=0}return null}},this.getMatchingTags=function(a){var g=new b(this,a.row,a.column),n=this.$findTagName(g);if(n){var s=g.stepBackward();return s.value==="<"?this.$findClosingTag(g,n):this.$findOpeningTag(g,n)}},this.$findTagName=function(a){var g=a.getCurrentToken(),n=!1,s=!1;if(g&&g.type.indexOf("tag-name")===-1)do s?g=a.stepBackward():g=a.stepForward(),g&&(g.value==="/>"?s=!0:g.type.indexOf("tag-name")!==-1&&(n=!0));while(g&&!n);return g},this.$findClosingTag=function(a,g){var n,s=g.value,o=g.value,r=0,t=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+1);g=a.stepForward();var i=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+g.value.length),c=!1;do{if(n=g,n.type.indexOf("tag-close")!==-1&&!c){var h=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+1);c=!0}if(g=a.stepForward(),g){if(g.value===">"&&!c){var h=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+1);c=!0}if(g.type.indexOf("tag-name")!==-1){if(s=g.value,o===s){if(n.value==="<")r++;else if(n.value==="</"&&(r--,r<0)){a.stepBackward();var f=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+2);g=a.stepForward();var v=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+g.value.length);if(g.type.indexOf("tag-close")===-1&&(g=a.stepForward()),g&&g.value===">")var p=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+1);else return}}}else if(o===s&&g.value==="/>"&&(r--,r<0))var f=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+2),v=f,p=v,h=new C(i.end.row,i.end.column,i.end.row,i.end.column+1)}}while(g&&r>=0);if(t&&h&&f&&p&&i&&v)return{openTag:new C(t.start.row,t.start.column,h.end.row,h.end.column),closeTag:new C(f.start.row,f.start.column,p.end.row,p.end.column),openTagName:i,closeTagName:v}},this.$findOpeningTag=function(a,g){var n=a.getCurrentToken(),s=g.value,o=0,r=a.getCurrentTokenRow(),t=a.getCurrentTokenColumn(),i=t+2,c=new C(r,t,r,i);a.stepForward();var h=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+g.value.length);if(g.type.indexOf("tag-close")===-1&&(g=a.stepForward()),!(!g||g.value!==">")){var f=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+1);a.stepBackward(),a.stepBackward();do if(g=n,r=a.getCurrentTokenRow(),t=a.getCurrentTokenColumn(),i=t+g.value.length,n=a.stepBackward(),g){if(g.type.indexOf("tag-name")!==-1){if(s===g.value)if(n.value==="<"){if(o++,o>0){var v=new C(r,t,r,i),p=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+1);do g=a.stepForward();while(g&&g.value!==">");var y=new C(a.getCurrentTokenRow(),a.getCurrentTokenColumn(),a.getCurrentTokenRow(),a.getCurrentTokenColumn()+1)}}else n.value==="</"&&o--}else if(g.value==="/>"){for(var m=0,$=n;$;){if($.type.indexOf("tag-name")!==-1&&$.value===s){o--;break}else if($.value==="<")break;$=a.stepBackward(),m++}for(var N=0;N<m;N++)a.stepForward()}}while(n&&o<=0);if(p&&y&&c&&f&&v&&h)return{openTag:new C(p.start.row,p.start.column,y.end.row,y.end.column),closeTag:new C(c.start.row,c.start.column,f.end.row,f.end.column),openTagName:v,closeTagName:h}}}}d.BracketMatch=A}),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(l,d,E){var b=l("./lib/oop"),C=l("./lib/lang"),A=l("./bidihandler").BidiHandler,a=l("./config"),g=l("./lib/event_emitter").EventEmitter,n=l("./selection").Selection,s=l("./mode/text").Mode,o=l("./range").Range,r=l("./line_widgets").LineWidgets,t=l("./document").Document,i=l("./background_tokenizer").BackgroundTokenizer,c=l("./search_highlight").SearchHighlight,h=l("./undomanager").UndoManager,f=function(){function x(L,I){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"+ ++x.$uid,this.$foldData.toString=function(){return this.join(`
202
+ `)},this.bgTokenizer=new i(new s().getTokenizer(),this);var w=this;this.bgTokenizer.on("update",function(_){w._signal("tokenizerUpdate",_)}),this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this),(typeof L!="object"||!L.getLine)&&(L=new t(L)),this.setDocument(L),this.selection=new n(this),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.selection.on("changeCursor",this.$onSelectionChange),this.$bidiHandler=new A(this),a.resetOptions(this),this.setMode(I),a._signal("session",this),this.destroyed=!1,this.$initOperationListeners()}return x.prototype.$initOperationListeners=function(){var L=this;this.curOp=null,this.on("change",function(){L.curOp||(L.startOperation(),L.curOp.selectionBefore=L.$lastSel),L.curOp.docChanged=!0},!0),this.on("changeSelection",function(){L.curOp||(L.startOperation(),L.curOp.selectionBefore=L.$lastSel),L.curOp.selectionChanged=!0},!0),this.$operationResetTimer=C.delayedCall(this.endOperation.bind(this,!0))},x.prototype.startOperation=function(L){if(this.curOp){if(!L||this.curOp.command)return;this.prevOp=this.curOp}L||(L={}),this.$operationResetTimer.schedule(),this.curOp={command:L.command||{},args:L.args},this.curOp.selectionBefore=this.selection.toJSON(),this._signal("startOperation",L)},x.prototype.endOperation=function(L){if(this.curOp){if(L&&L.returnValue===!1){this.curOp=null,this._signal("endOperation",L);return}if(L==!0&&this.curOp.command&&this.curOp.command.name=="mouse")return;var I=this.selection.toJSON();this.curOp.selectionAfter=I,this.$lastSel=this.selection.toJSON(),this.getUndoManager().addSelection(I),this._signal("beforeEndOperation"),this.prevOp=this.curOp,this.curOp=null,this._signal("endOperation",L)}},x.prototype.setDocument=function(L){this.doc&&this.doc.off("change",this.$onChange),this.doc=L,L.on("change",this.$onChange,!0),this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},x.prototype.getDocument=function(){return this.doc},Object.defineProperty(x.prototype,"widgetManager",{get:function(){var L=new r(this);return this.widgetManager=L,this.$editor&&L.attach(this.$editor),L},set:function(L){Object.defineProperty(this,"widgetManager",{writable:!0,enumerable:!0,configurable:!0,value:L})},enumerable:!1,configurable:!0}),x.prototype.$resetRowCache=function(L){if(!L){this.$docRowCache=[],this.$screenRowCache=[];return}var I=this.$docRowCache.length,w=this.$getRowCacheIndex(this.$docRowCache,L)+1;I>w&&(this.$docRowCache.splice(w,I),this.$screenRowCache.splice(w,I))},x.prototype.$getRowCacheIndex=function(L,I){for(var w=0,_=L.length-1;w<=_;){var T=w+_>>1,k=L[T];if(I>k)w=T+1;else if(I<k)_=T-1;else return T}return w-1},x.prototype.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.destroyed||this.bgTokenizer.start(0)},x.prototype.onChangeFold=function(L){var I=L.data;this.$resetRowCache(I.start.row)},x.prototype.onChange=function(L){this.$modified=!0,this.$bidiHandler.onChange(L),this.$resetRowCache(L.start.row);var I=this.$updateInternalDataOnChange(L);!this.$fromUndo&&this.$undoManager&&(I&&I.length&&(this.$undoManager.add({action:"removeFolds",folds:I},this.mergeUndoDeltas),this.mergeUndoDeltas=!0),this.$undoManager.add(L,this.mergeUndoDeltas),this.mergeUndoDeltas=!0,this.$informUndoManager.schedule()),this.bgTokenizer.$updateOnChange(L),this._signal("change",L)},x.prototype.onSelectionChange=function(){this._signal("changeSelection")},x.prototype.setValue=function(L){this.doc.setValue(L),this.selection.moveTo(0,0),this.$resetRowCache(0),this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},x.fromJSON=function(L){typeof L=="string"&&(L=JSON.parse(L));var I=new h;I.$undoStack=L.history.undo,I.$redoStack=L.history.redo,I.mark=L.history.mark,I.$rev=L.history.rev;var w=new x(L.value);return L.folds.forEach(function(_){w.addFold("...",o.fromPoints(_.start,_.end))}),w.setAnnotations(L.annotations),w.setBreakpoints(L.breakpoints),w.setMode(L.mode),w.setScrollLeft(L.scrollLeft),w.setScrollTop(L.scrollTop),w.setUndoManager(I),w.selection.fromJSON(L.selection),w},x.prototype.toJSON=function(){return{annotations:this.$annotations,breakpoints:this.$breakpoints,folds:this.getAllFolds().map(function(L){return L.range}),history:this.getUndoManager(),mode:this.$mode.$id,scrollLeft:this.$scrollLeft,scrollTop:this.$scrollTop,selection:this.selection.toJSON(),value:this.doc.getValue()}},x.prototype.toString=function(){return this.doc.getValue()},x.prototype.getSelection=function(){return this.selection},x.prototype.getState=function(L){return this.bgTokenizer.getState(L)},x.prototype.getTokens=function(L){return this.bgTokenizer.getTokens(L)},x.prototype.getTokenAt=function(L,I){var w=this.bgTokenizer.getTokens(L),_,T=0;if(I==null){var k=w.length-1;T=this.getLine(L).length}else for(var k=0;k<w.length&&(T+=w[k].value.length,!(T>=I));k++);return _=w[k],_?(_.index=k,_.start=T-_.value.length,_):null},x.prototype.setUndoManager=function(L){if(this.$undoManager=L,this.$informUndoManager&&this.$informUndoManager.cancel(),L){var I=this;L.addSession(this),this.$syncInformUndoManager=function(){I.$informUndoManager.cancel(),I.mergeUndoDeltas=!1},this.$informUndoManager=C.delayedCall(this.$syncInformUndoManager)}else this.$syncInformUndoManager=function(){}},x.prototype.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},x.prototype.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},x.prototype.getTabString=function(){return this.getUseSoftTabs()?C.stringRepeat(" ",this.getTabSize()):" "},x.prototype.setUseSoftTabs=function(L){this.setOption("useSoftTabs",L)},x.prototype.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},x.prototype.setTabSize=function(L){this.setOption("tabSize",L)},x.prototype.getTabSize=function(){return this.$tabSize},x.prototype.isTabStop=function(L){return this.$useSoftTabs&&L.column%this.$tabSize===0},x.prototype.setNavigateWithinSoftTabs=function(L){this.setOption("navigateWithinSoftTabs",L)},x.prototype.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},x.prototype.setOverwrite=function(L){this.setOption("overwrite",L)},x.prototype.getOverwrite=function(){return this.$overwrite},x.prototype.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},x.prototype.addGutterDecoration=function(L,I){this.$decorations[L]||(this.$decorations[L]=""),this.$decorations[L]+=" "+I,this._signal("changeBreakpoint",{})},x.prototype.removeGutterDecoration=function(L,I){this.$decorations[L]=(this.$decorations[L]||"").replace(" "+I,""),this._signal("changeBreakpoint",{})},x.prototype.getBreakpoints=function(){return this.$breakpoints},x.prototype.setBreakpoints=function(L){this.$breakpoints=[];for(var I=0;I<L.length;I++)this.$breakpoints[L[I]]="ace_breakpoint";this._signal("changeBreakpoint",{})},x.prototype.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},x.prototype.setBreakpoint=function(L,I){I===void 0&&(I="ace_breakpoint"),I?this.$breakpoints[L]=I:delete this.$breakpoints[L],this._signal("changeBreakpoint",{})},x.prototype.clearBreakpoint=function(L){delete this.$breakpoints[L],this._signal("changeBreakpoint",{})},x.prototype.addMarker=function(L,I,w,_){var T=this.$markerId++,k={range:L,type:w||"line",renderer:typeof w=="function"?w:null,clazz:I,inFront:!!_,id:T};return _?(this.$frontMarkers[T]=k,this._signal("changeFrontMarker")):(this.$backMarkers[T]=k,this._signal("changeBackMarker")),T},x.prototype.addDynamicMarker=function(L,I){if(L.update){var w=this.$markerId++;return L.id=w,L.inFront=!!I,I?(this.$frontMarkers[w]=L,this._signal("changeFrontMarker")):(this.$backMarkers[w]=L,this._signal("changeBackMarker")),L}},x.prototype.removeMarker=function(L){var I=this.$frontMarkers[L]||this.$backMarkers[L];if(I){var w=I.inFront?this.$frontMarkers:this.$backMarkers;delete w[L],this._signal(I.inFront?"changeFrontMarker":"changeBackMarker")}},x.prototype.getMarkers=function(L){return L?this.$frontMarkers:this.$backMarkers},x.prototype.highlight=function(L){if(!this.$searchHighlight){var I=new c(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker(I)}this.$searchHighlight.setRegexp(L)},x.prototype.highlightLines=function(L,I,w,_){typeof I!="number"&&(w=I,I=L),w||(w="ace_step");var T=new o(L,0,I,1/0);return T.id=this.addMarker(T,w,"fullLine",_),T},x.prototype.setAnnotations=function(L){this.$annotations=L,this._signal("changeAnnotation",{})},x.prototype.getAnnotations=function(){return this.$annotations||[]},x.prototype.clearAnnotations=function(){this.setAnnotations([])},x.prototype.$detectNewLine=function(L){var I=L.match(/^.*?(\r?\n)/m);I?this.$autoNewLine=I[1]:this.$autoNewLine=`
203
+ `},x.prototype.getWordRange=function(L,I){var w=this.getLine(L),_=!1;if(I>0&&(_=!!w.charAt(I-1).match(this.tokenRe)),_||(_=!!w.charAt(I).match(this.tokenRe)),_)var T=this.tokenRe;else if(/^\s+$/.test(w.slice(I-1,I+1)))var T=/\s/;else var T=this.nonTokenRe;var k=I;if(k>0){do k--;while(k>=0&&w.charAt(k).match(T));k++}for(var R=I;R<w.length&&w.charAt(R).match(T);)R++;return new o(L,k,L,R)},x.prototype.getAWordRange=function(L,I){for(var w=this.getWordRange(L,I),_=this.getLine(w.end.row);_.charAt(w.end.column).match(/[ \t]/);)w.end.column+=1;return w},x.prototype.setNewLineMode=function(L){this.doc.setNewLineMode(L)},x.prototype.getNewLineMode=function(){return this.doc.getNewLineMode()},x.prototype.setUseWorker=function(L){this.setOption("useWorker",L)},x.prototype.getUseWorker=function(){return this.$useWorker},x.prototype.onReloadTokenizer=function(L){var I=L.data;this.bgTokenizer.start(I.first),this._signal("tokenizerUpdate",L)},x.prototype.setMode=function(L,I){if(L&&typeof L=="object"){if(L.getTokenizer)return this.$onChangeMode(L);var w=L,_=w.path}else _=L||"ace/mode/text";if(this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new s),this.$modes[_]&&!w){this.$onChangeMode(this.$modes[_]),I&&I();return}this.$modeId=_,a.loadModule(["mode",_],(function(T){if(!this.destroyed){if(this.$modeId!==_)return I&&I();this.$modes[_]&&!w?this.$onChangeMode(this.$modes[_]):T&&T.Mode&&(T=new T.Mode(w),w||(this.$modes[_]=T,T.$id=_),this.$onChangeMode(T)),I&&I()}}).bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0)},x.prototype.$onChangeMode=function(L,I){if(I||(this.$modeId=L.$id),this.$mode!==L){var w=this.$mode;this.$mode=L,this.$stopWorker(),this.$useWorker&&this.$startWorker();var _=L.getTokenizer();if(_.on!==void 0){var T=this.onReloadTokenizer.bind(this);_.on("update",T)}this.bgTokenizer.setTokenizer(_),this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=L.tokenRe,this.nonTokenRe=L.nonTokenRe,I||(L.attachToSession&&L.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(L.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode",{oldMode:w,mode:L}))}},x.prototype.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},x.prototype.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(L){a.warn("Could not load worker",L),this.$worker=null}},x.prototype.getMode=function(){return this.$mode},x.prototype.setScrollTop=function(L){this.$scrollTop===L||isNaN(L)||(this.$scrollTop=L,this._signal("changeScrollTop",L))},x.prototype.getScrollTop=function(){return this.$scrollTop},x.prototype.setScrollLeft=function(L){this.$scrollLeft===L||isNaN(L)||(this.$scrollLeft=L,this._signal("changeScrollLeft",L))},x.prototype.getScrollLeft=function(){return this.$scrollLeft},x.prototype.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},x.prototype.getLineWidgetMaxWidth=function(){if(this.lineWidgetsWidth!=null)return this.lineWidgetsWidth;var L=0;return this.lineWidgets.forEach(function(I){I&&I.screenWidth>L&&(L=I.screenWidth)}),this.lineWidgetWidth=L},x.prototype.$computeWidth=function(L){if(this.$modified||L){if(this.$modified=!1,this.$useWrapMode)return this.screenWidth=this.$wrapLimit;for(var I=this.doc.getAllLines(),w=this.$rowLengthCache,_=0,T=0,k=this.$foldData[T],R=k?k.start.row:1/0,D=I.length,V=0;V<D;V++){if(V>R){if(V=k.end.row+1,V>=D)break;k=this.$foldData[T++],R=k?k.start.row:1/0}w[V]==null&&(w[V]=this.$getStringScreenWidth(I[V])[0]),w[V]>_&&(_=w[V])}this.screenWidth=_}},x.prototype.getLine=function(L){return this.doc.getLine(L)},x.prototype.getLines=function(L,I){return this.doc.getLines(L,I)},x.prototype.getLength=function(){return this.doc.getLength()},x.prototype.getTextRange=function(L){return this.doc.getTextRange(L||this.selection.getRange())},x.prototype.insert=function(L,I){return this.doc.insert(L,I)},x.prototype.remove=function(L){return this.doc.remove(L)},x.prototype.removeFullLines=function(L,I){return this.doc.removeFullLines(L,I)},x.prototype.undoChanges=function(L,I){if(L.length){this.$fromUndo=!0;for(var w=L.length-1;w!=-1;w--){var _=L[w];_.action=="insert"||_.action=="remove"?this.doc.revertDelta(_):_.folds&&this.addFolds(_.folds)}!I&&this.$undoSelect&&(L.selectionBefore?this.selection.fromJSON(L.selectionBefore):this.selection.setRange(this.$getUndoSelection(L,!0))),this.$fromUndo=!1}},x.prototype.redoChanges=function(L,I){if(L.length){this.$fromUndo=!0;for(var w=0;w<L.length;w++){var _=L[w];(_.action=="insert"||_.action=="remove")&&this.doc.$safeApplyDelta(_)}!I&&this.$undoSelect&&(L.selectionAfter?this.selection.fromJSON(L.selectionAfter):this.selection.setRange(this.$getUndoSelection(L,!1))),this.$fromUndo=!1}},x.prototype.setUndoSelect=function(L){this.$undoSelect=L},x.prototype.$getUndoSelection=function(L,I){function w(D){return I?D.action!=="insert":D.action==="insert"}for(var _,T,k=0;k<L.length;k++){var R=L[k];if(R.start){if(!_){w(R)?_=o.fromPoints(R.start,R.end):_=o.fromPoints(R.start,R.start);continue}w(R)?(T=R.start,_.compare(T.row,T.column)==-1&&_.setStart(T),T=R.end,_.compare(T.row,T.column)==1&&_.setEnd(T)):(T=R.start,_.compare(T.row,T.column)==-1&&(_=o.fromPoints(R.start,R.start)))}}return _},x.prototype.replace=function(L,I){return this.doc.replace(L,I)},x.prototype.moveText=function(L,I,w){var _=this.getTextRange(L),T=this.getFoldsInRange(L),k=o.fromPoints(I,I);if(!w){this.remove(L);var R=L.start.row-L.end.row,D=R?-L.end.column:L.start.column-L.end.column;D&&(k.start.row==L.end.row&&k.start.column>L.end.column&&(k.start.column+=D),k.end.row==L.end.row&&k.end.column>L.end.column&&(k.end.column+=D)),R&&k.start.row>=L.end.row&&(k.start.row+=R,k.end.row+=R)}if(k.end=this.insert(k.start,_),T.length){var V=L.start,B=k.start,R=B.row-V.row,D=B.column-V.column;this.addFolds(T.map(function(U){return U=U.clone(),U.start.row==V.row&&(U.start.column+=D),U.end.row==V.row&&(U.end.column+=D),U.start.row+=R,U.end.row+=R,U}))}return k},x.prototype.indentRows=function(L,I,w){w=w.replace(/\t/g,this.getTabString());for(var _=L;_<=I;_++)this.doc.insertInLine({row:_,column:0},w)},x.prototype.outdentRows=function(L){for(var I=L.collapseRows(),w=new o(0,0,0,0),_=this.getTabSize(),T=I.start.row;T<=I.end.row;++T){var k=this.getLine(T);w.start.row=T,w.end.row=T;for(var R=0;R<_&&k.charAt(R)==" ";++R);R<_&&k.charAt(R)==" "?(w.start.column=R,w.end.column=R+1):(w.start.column=0,w.end.column=R),this.remove(w)}},x.prototype.$moveLines=function(L,I,w){if(L=this.getRowFoldStart(L),I=this.getRowFoldEnd(I),w<0){var _=this.getRowFoldStart(L+w);if(_<0)return 0;var T=_-L}else if(w>0){var _=this.getRowFoldEnd(I+w);if(_>this.doc.getLength()-1)return 0;var T=_-I}else{L=this.$clipRowToDocument(L),I=this.$clipRowToDocument(I);var T=I-L+1}var k=new o(L,0,I,Number.MAX_VALUE),R=this.getFoldsInRange(k).map(function(V){return V=V.clone(),V.start.row+=T,V.end.row+=T,V}),D=w==0?this.doc.getLines(L,I):this.doc.removeFullLines(L,I);return this.doc.insertFullLines(L+T,D),R.length&&this.addFolds(R),T},x.prototype.moveLinesUp=function(L,I){return this.$moveLines(L,I,-1)},x.prototype.moveLinesDown=function(L,I){return this.$moveLines(L,I,1)},x.prototype.duplicateLines=function(L,I){return this.$moveLines(L,I,0)},x.prototype.$clipRowToDocument=function(L){return Math.max(0,Math.min(L,this.doc.getLength()-1))},x.prototype.$clipColumnToRow=function(L,I){return I<0?0:Math.min(this.doc.getLine(L).length,I)},x.prototype.$clipPositionToDocument=function(L,I){if(I=Math.max(0,I),L<0)L=0,I=0;else{var w=this.doc.getLength();L>=w?(L=w-1,I=this.doc.getLine(w-1).length):I=Math.min(this.doc.getLine(L).length,I)}return{row:L,column:I}},x.prototype.$clipRangeToDocument=function(L){L.start.row<0?(L.start.row=0,L.start.column=0):L.start.column=this.$clipColumnToRow(L.start.row,L.start.column);var I=this.doc.getLength()-1;return L.end.row>I?(L.end.row=I,L.end.column=this.doc.getLine(I).length):L.end.column=this.$clipColumnToRow(L.end.row,L.end.column),L},x.prototype.setUseWrapMode=function(L){if(L!=this.$useWrapMode){if(this.$useWrapMode=L,this.$modified=!0,this.$resetRowCache(0),L){var I=this.getLength();this.$wrapData=Array(I),this.$updateWrapData(0,I-1)}this._signal("changeWrapMode")}},x.prototype.getUseWrapMode=function(){return this.$useWrapMode},x.prototype.setWrapLimitRange=function(L,I){(this.$wrapLimitRange.min!==L||this.$wrapLimitRange.max!==I)&&(this.$wrapLimitRange={min:L,max:I},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode"))},x.prototype.adjustWrapLimit=function(L,I){var w=this.$wrapLimitRange;w.max<0&&(w={min:I,max:I});var _=this.$constrainWrapLimit(L,w.min,w.max);return _!=this.$wrapLimit&&_>1?(this.$wrapLimit=_,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0):!1},x.prototype.$constrainWrapLimit=function(L,I,w){return I&&(L=Math.max(I,L)),w&&(L=Math.min(w,L)),L},x.prototype.getWrapLimit=function(){return this.$wrapLimit},x.prototype.setWrapLimit=function(L){this.setWrapLimitRange(L,L)},x.prototype.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},x.prototype.$updateInternalDataOnChange=function(L){var I=this.$useWrapMode,w=L.action,_=L.start,T=L.end,k=_.row,R=T.row,D=R-k,V=null;if(this.$updating=!0,D!=0)if(w==="remove"){this[I?"$wrapData":"$rowLengthCache"].splice(k,D);var B=this.$foldData;V=this.getFoldsInRange(L),this.removeFolds(V);var F=this.getFoldLine(T.row),H=0;if(F){F.addRemoveChars(T.row,T.column,_.column-T.column),F.shiftRow(-D);var U=this.getFoldLine(k);U&&U!==F&&(U.merge(F),F=U),H=B.indexOf(F)+1}for(H;H<B.length;H++){var F=B[H];F.start.row>=T.row&&F.shiftRow(-D)}R=k}else{var z=Array(D);z.unshift(k,0);var K=I?this.$wrapData:this.$rowLengthCache;K.splice.apply(K,z);var B=this.$foldData,F=this.getFoldLine(k),H=0;if(F){var Y=F.range.compareInside(_.row,_.column);Y==0?(F=F.split(_.row,_.column),F&&(F.shiftRow(D),F.addRemoveChars(R,0,T.column-_.column))):Y==-1&&(F.addRemoveChars(k,0,T.column-_.column),F.shiftRow(D)),H=B.indexOf(F)+1}for(H;H<B.length;H++){var F=B[H];F.start.row>=k&&F.shiftRow(D)}}else{D=Math.abs(L.start.column-L.end.column),w==="remove"&&(V=this.getFoldsInRange(L),this.removeFolds(V),D=-D);var F=this.getFoldLine(k);F&&F.addRemoveChars(k,_.column,D)}return I&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,I?this.$updateWrapData(k,R):this.$updateRowLengthCache(k,R),V},x.prototype.$updateRowLengthCache=function(L,I){this.$rowLengthCache[L]=null,this.$rowLengthCache[I]=null},x.prototype.$updateWrapData=function(L,I){var w=this.doc.getAllLines(),_=this.getTabSize(),T=this.$wrapData,k=this.$wrapLimit,R,D,V=L;for(I=Math.min(I,w.length-1);V<=I;)D=this.getFoldLine(V,D),D?(R=[],D.walk((function(B,F,H,U){var z;if(B!=null){z=this.$getDisplayTokens(B,R.length),z[0]=y;for(var K=1;K<z.length;K++)z[K]=m}else z=this.$getDisplayTokens(w[F].substring(U,H),R.length);R=R.concat(z)}).bind(this),D.end.row,w[D.end.row].length+1),T[D.start.row]=this.$computeWrapSplits(R,k,_),V=D.end.row+1):(R=this.$getDisplayTokens(w[V]),T[V]=this.$computeWrapSplits(R,k,_),V++)},x.prototype.$computeWrapSplits=function(L,I,w){if(L.length==0)return[];var _=[],T=L.length,k=0,R=0,D=this.$wrapAsCode,V=this.$indentedSoftWrap,B=I<=Math.max(2*w,8)||V===!1?0:Math.floor(I/2);function F(){var Y=0;if(B===0)return Y;if(V)for(var Q=0;Q<L.length;Q++){var J=L[Q];if(J==N)Y+=1;else if(J==M)Y+=w;else{if(J==S)continue;break}}return D&&V!==!1&&(Y+=w),Math.min(Y,B)}function H(Y){for(var Q=Y-k,J=k;J<Y;J++){var ne=L[J];(ne===12||ne===2)&&(Q-=1)}_.length||(U=F(),_.indent=U),R+=Q,_.push(R),k=Y}for(var U=0;T-k>I-U;){var z=k+I-U;if(L[z-1]>=N&&L[z]>=N){H(z);continue}if(L[z]==y||L[z]==m){for(z;z!=k-1&&L[z]!=y;z--);if(z>k){H(z);continue}for(z=k+I,z;z<L.length&&L[z]==m;z++);if(z==L.length)break;H(z);continue}for(var K=Math.max(z-(I-(I>>2)),k-1);z>K&&L[z]<y;)z--;if(D){for(;z>K&&L[z]<y;)z--;for(;z>K&&L[z]==$;)z--}else for(;z>K&&L[z]<N;)z--;if(z>K){H(++z);continue}z=k+I,L[z]==p&&z--,H(z-U)}return _},x.prototype.$getDisplayTokens=function(L,I){var w=[],_;I=I||0;for(var T=0;T<L.length;T++){var k=L.charCodeAt(T);if(k==9){_=this.getScreenTabSize(w.length+I),w.push(M);for(var R=1;R<_;R++)w.push(S)}else k==32?w.push(N):k>39&&k<48||k>57&&k<64?w.push($):k>=4352&&O(k)?w.push(v,p):w.push(v)}return w},x.prototype.$getStringScreenWidth=function(L,I,w){if(I==0)return[0,0];I==null&&(I=1/0),w=w||0;var _,T;for(T=0;T<L.length&&(_=L.charCodeAt(T),_==9?w+=this.getScreenTabSize(w):_>=4352&&O(_)?w+=2:w+=1,!(w>I));T++);return[w,T]},x.prototype.getRowLength=function(L){var I=1;return this.lineWidgets&&(I+=this.lineWidgets[L]&&this.lineWidgets[L].rowCount||0),!this.$useWrapMode||!this.$wrapData[L]?I:this.$wrapData[L].length+I},x.prototype.getRowLineCount=function(L){return!this.$useWrapMode||!this.$wrapData[L]?1:this.$wrapData[L].length+1},x.prototype.getRowWrapIndent=function(L){if(this.$useWrapMode){var I=this.screenToDocumentPosition(L,Number.MAX_VALUE),w=this.$wrapData[I.row];return w.length&&w[0]<I.column?w.indent:0}else return 0},x.prototype.getScreenLastRowColumn=function(L){var I=this.screenToDocumentPosition(L,Number.MAX_VALUE);return this.documentToScreenColumn(I.row,I.column)},x.prototype.getDocumentLastRowColumn=function(L,I){var w=this.documentToScreenRow(L,I);return this.getScreenLastRowColumn(w)},x.prototype.getDocumentLastRowColumnPosition=function(L,I){var w=this.documentToScreenRow(L,I);return this.screenToDocumentPosition(w,Number.MAX_VALUE/10)},x.prototype.getRowSplitData=function(L){if(this.$useWrapMode)return this.$wrapData[L]},x.prototype.getScreenTabSize=function(L){return this.$tabSize-(L%this.$tabSize|0)},x.prototype.screenToDocumentRow=function(L,I){return this.screenToDocumentPosition(L,I).row},x.prototype.screenToDocumentColumn=function(L,I){return this.screenToDocumentPosition(L,I).column},x.prototype.screenToDocumentPosition=function(L,I,w){if(L<0)return{row:0,column:0};var _,T=0,k=0,R,D=0,V=0,B=this.$screenRowCache,F=this.$getRowCacheIndex(B,L),H=B.length;if(H&&F>=0)var D=B[F],T=this.$docRowCache[F],U=L>B[H-1];else var U=!H;for(var z=this.getLength()-1,K=this.getNextFoldLine(T),Y=K?K.start.row:1/0;D<=L&&(V=this.getRowLength(T),!(D+V>L||T>=z));)D+=V,T++,T>Y&&(T=K.end.row+1,K=this.getNextFoldLine(T,K),Y=K?K.start.row:1/0),U&&(this.$docRowCache.push(T),this.$screenRowCache.push(D));if(K&&K.start.row<=T)_=this.getFoldDisplayLine(K),T=K.start.row;else{if(D+V<=L||T>z)return{row:z,column:this.getLine(z).length};_=this.getLine(T),K=null}var Q=0,J=Math.floor(L-D);if(this.$useWrapMode){var ne=this.$wrapData[T];ne&&(R=ne[J],J>0&&ne.length&&(Q=ne.indent,k=ne[J-1]||ne[ne.length-1],_=_.substring(k)))}return w!==void 0&&this.$bidiHandler.isBidiRow(D+J,T,J)&&(I=this.$bidiHandler.offsetToCol(w)),k+=this.$getStringScreenWidth(_,I-Q)[1],this.$useWrapMode&&k>=R&&(k=R-1),K?K.idxToPosition(k):{row:T,column:k}},x.prototype.documentToScreenPosition=function(L,I){if(typeof I>"u")var w=this.$clipPositionToDocument(L.row,L.column);else w=this.$clipPositionToDocument(L,I);L=w.row,I=w.column;var _=0,T=null,k=null;k=this.getFoldAt(L,I,1),k&&(L=k.start.row,I=k.start.column);var R,D=0,V=this.$docRowCache,B=this.$getRowCacheIndex(V,L),F=V.length;if(F&&B>=0)var D=V[B],_=this.$screenRowCache[B],H=L>V[F-1];else var H=!F;for(var U=this.getNextFoldLine(D),z=U?U.start.row:1/0;D<L;){if(D>=z){if(R=U.end.row+1,R>L)break;U=this.getNextFoldLine(R,U),z=U?U.start.row:1/0}else R=D+1;_+=this.getRowLength(D),D=R,H&&(this.$docRowCache.push(D),this.$screenRowCache.push(_))}var K="";U&&D>=z?(K=this.getFoldDisplayLine(U,L,I),T=U.start.row):(K=this.getLine(L).substring(0,I),T=L);var Y=0;if(this.$useWrapMode){var Q=this.$wrapData[T];if(Q){for(var J=0;K.length>=Q[J];)_++,J++;K=K.substring(Q[J-1]||0,K.length),Y=J>0?Q.indent:0}}return this.lineWidgets&&this.lineWidgets[D]&&this.lineWidgets[D].rowsAbove&&(_+=this.lineWidgets[D].rowsAbove),{row:_,column:Y+this.$getStringScreenWidth(K)[0]}},x.prototype.documentToScreenColumn=function(L,I){return this.documentToScreenPosition(L,I).column},x.prototype.documentToScreenRow=function(L,I){return this.documentToScreenPosition(L,I).row},x.prototype.getScreenLength=function(){var L=0,I=null;if(this.$useWrapMode)for(var T=this.$wrapData.length,k=0,_=0,I=this.$foldData[_++],R=I?I.start.row:1/0;k<T;){var D=this.$wrapData[k];L+=D?D.length+1:1,k++,k>R&&(k=I.end.row+1,I=this.$foldData[_++],R=I?I.start.row:1/0)}else{L=this.getLength();for(var w=this.$foldData,_=0;_<w.length;_++)I=w[_],L-=I.end.row-I.start.row}return this.lineWidgets&&(L+=this.$getWidgetScreenLength()),L},x.prototype.$setFontMetrics=function(L){this.$enableVarChar&&(this.$getStringScreenWidth=function(I,w,_){if(w===0)return[0,0];w||(w=1/0),_=_||0;var T,k;for(k=0;k<I.length&&(T=I.charAt(k),T===" "?_+=this.getScreenTabSize(_):_+=L.getCharacterWidth(T),!(_>w));k++);return[_,k]})},x.prototype.getPrecedingCharacter=function(){var L=this.selection.getCursor();if(L.column===0)return L.row===0?"":this.doc.getNewLineCharacter();var I=this.getLine(L.row);return I[L.column-1]},x.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()},x}();f.$uid=0,f.prototype.$modes=a.$modes,f.prototype.getValue=f.prototype.toString,f.prototype.$defaultUndoManager={undo:function(){},redo:function(){},hasUndo:function(){},hasRedo:function(){},reset:function(){},add:function(){},addSelection:function(){},startNewGroup:function(){},addSession:function(){}},f.prototype.$overwrite=!1,f.prototype.$mode=null,f.prototype.$modeId=null,f.prototype.$scrollTop=0,f.prototype.$scrollLeft=0,f.prototype.$wrapLimit=80,f.prototype.$useWrapMode=!1,f.prototype.$wrapLimitRange={min:null,max:null},f.prototype.lineWidgets=null,f.prototype.isFullWidth=O,b.implement(f.prototype,g);var v=1,p=2,y=3,m=4,$=9,N=10,M=11,S=12;function O(x){return x<4352?!1:x>=4352&&x<=4447||x>=4515&&x<=4519||x>=4602&&x<=4607||x>=9001&&x<=9002||x>=11904&&x<=11929||x>=11931&&x<=12019||x>=12032&&x<=12245||x>=12272&&x<=12283||x>=12288&&x<=12350||x>=12353&&x<=12438||x>=12441&&x<=12543||x>=12549&&x<=12589||x>=12593&&x<=12686||x>=12688&&x<=12730||x>=12736&&x<=12771||x>=12784&&x<=12830||x>=12832&&x<=12871||x>=12880&&x<=13054||x>=13056&&x<=19903||x>=19968&&x<=42124||x>=42128&&x<=42182||x>=43360&&x<=43388||x>=44032&&x<=55203||x>=55216&&x<=55238||x>=55243&&x<=55291||x>=63744&&x<=64255||x>=65040&&x<=65049||x>=65072&&x<=65106||x>=65108&&x<=65126||x>=65128&&x<=65131||x>=65281&&x<=65376||x>=65504&&x<=65510}l("./edit_session/folding").Folding.call(f.prototype),l("./edit_session/bracket_match").BracketMatch.call(f.prototype),a.defineOptions(f.prototype,"session",{wrap:{set:function(x){if(!x||x=="off"?x=!1:x=="free"?x=!0:x=="printMargin"?x=-1:typeof x=="string"&&(x=parseInt(x,10)||!1),this.$wrap!=x)if(this.$wrap=x,!x)this.setUseWrapMode(!1);else{var L=typeof x=="number"?x:null;this.setWrapLimitRange(L,L),this.setUseWrapMode(!0)}},get:function(){return this.getUseWrapMode()?this.$wrap==-1?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(x){x=x=="auto"?this.$mode.type!="text":x!="text",x!=this.$wrapAsCode&&(this.$wrapAsCode=x,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(x){this.$useWorker=x,this.$stopWorker(),x&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(x){x=parseInt(x),x>0&&this.$tabSize!==x&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=x,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(x){this.setFoldStyle(x)},handlesSet:!0},overwrite:{set:function(x){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(x){this.doc.setNewLineMode(x)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(x){this.setMode(x)},get:function(){return this.$modeId},handlesSet:!0}}),d.EditSession=f}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(l,d,E){var b=l("./lib/lang"),C=l("./lib/oop"),A=l("./range").Range,a=function(){function o(){this.$options={}}return o.prototype.set=function(r){return C.mixin(this.$options,r),this},o.prototype.getOptions=function(){return b.copyObject(this.$options)},o.prototype.setOptions=function(r){this.$options=r},o.prototype.find=function(r){var t=this.$options,i=this.$matchIterator(r,t);if(!i)return!1;var c=null;return i.forEach(function(h,f,v,p){return c=new A(h,f,v,p),f==p&&t.start&&t.start.start&&t.skipCurrent!=!1&&c.isEqual(t.start)?(c=null,!1):!0}),c},o.prototype.findAll=function(r){var t=this.$options;if(!t.needle)return[];this.$assembleRegExp(t);var i=t.range,c=i?r.getLines(i.start.row,i.end.row):r.doc.getAllLines(),h=[],f=t.re;if(t.$isMultiLine){var v=f.length,p=c.length-v,y;e:for(var m=f.offset||0;m<=p;m++){for(var $=0;$<v;$++)if(c[m+$].search(f[$])==-1)continue e;var N=c[m],M=c[m+v-1],S=N.length-N.match(f[0])[0].length,O=M.match(f[v-1])[0].length;y&&y.end.row===m&&y.end.column>S||(h.push(y=new A(m,S,m+v-1,O)),v>2&&(m=m+v-2))}}else for(var x,L=0;L<c.length;L++)if(this.$isMultilineSearch(t)){var I=c.length-1;if(x=this.$multiLineForward(r,f,L,I),x){var w=x.endRow<=I?x.endRow-1:I;w>L&&(L=w),h.push(new A(x.startRow,x.startCol,x.endRow,x.endCol))}}else{x=b.getMatchOffsets(c[L],f);for(var $=0;$<x.length;$++){var _=x[$];h.push(new A(L,_.offset,L,_.offset+_.length))}}if(i){for(var T=i.start.column,k=i.end.column,L=0,$=h.length-1;L<$&&h[L].start.column<T&&h[L].start.row==0;)L++;for(var R=i.end.row-i.start.row;L<$&&h[$].end.column>k&&h[$].end.row==R;)$--;for(h=h.slice(L,$+1),L=0,$=h.length;L<$;L++)h[L].start.row+=i.start.row,h[L].end.row+=i.start.row}return h},o.prototype.parseReplaceString=function(r){for(var t={DollarSign:36,Ampersand:38,Digit0:48,Digit1:49,Digit9:57,Backslash:92,n:110,t:116},i="",c=0,h=r.length;c<h;c++){var f=r.charCodeAt(c);if(f===t.Backslash){if(c++,c>=h){i+="\\";break}var v=r.charCodeAt(c);switch(v){case t.Backslash:i+="\\";break;case t.n:i+=`
204
+ `;break;case t.t:i+=" ";break}continue}if(f===t.DollarSign){if(c++,c>=h){i+="$";break}var p=r.charCodeAt(c);if(p===t.DollarSign){i+="$$";continue}if(p===t.Digit0||p===t.Ampersand){i+="$&";continue}if(t.Digit1<=p&&p<=t.Digit9){i+="$"+r[c];continue}}i+=r[c]}return i||r},o.prototype.replace=function(r,t){var i=this.$options,c=this.$assembleRegExp(i);if(i.$isMultiLine)return t;if(c){var h=this.$isMultilineSearch(i);h&&(r=r.replace(/\r\n|\r|\n/g,`
205
+ `));var f=c.exec(r);if(!f||!h&&f[0].length!=r.length)return null;if(t=i.regExp?this.parseReplaceString(t):t.replace(/\$/g,"$$$$"),t=r.replace(c,t),i.preserveCase){t=t.split("");for(var v=Math.min(r.length,r.length);v--;){var p=r[v];p&&p.toLowerCase()!=p?t[v]=t[v].toUpperCase():t[v]=t[v].toLowerCase()}t=t.join("")}return t}},o.prototype.$assembleRegExp=function(r,t){if(r.needle instanceof RegExp)return r.re=r.needle;var i=r.needle;if(!r.needle)return r.re=!1;r.regExp||(i=b.escapeRegExp(i));var c=r.caseSensitive?"gm":"gmi";try{new RegExp(i,"u"),r.$supportsUnicodeFlag=!0,c+="u"}catch{r.$supportsUnicodeFlag=!1}if(r.wholeWord&&(i=g(i,r)),r.$isMultiLine=!t&&/[\n\r]/.test(i),r.$isMultiLine)return r.re=this.$assembleMultilineRegExp(i,c);try{var h=new RegExp(i,c)}catch{h=!1}return r.re=h},o.prototype.$assembleMultilineRegExp=function(r,t){for(var i=r.replace(/\r\n|\r|\n/g,`$
206
+ ^`).split(`
207
+ `),c=[],h=0;h<i.length;h++)try{c.push(new RegExp(i[h],t))}catch{return!1}return c},o.prototype.$isMultilineSearch=function(r){return r.re&&/\\r\\n|\\r|\\n/.test(r.re.source)&&r.regExp&&!r.$isMultiLine},o.prototype.$multiLineForward=function(r,t,i,c){for(var h,f=s(r,i),v=i;v<=c;){for(var p=0;p<f&&!(v>c);p++){var y=r.getLine(v++);h=h==null?y:h+`
208
+ `+y}var m=t.exec(h);if(t.lastIndex=0,m){var $=h.slice(0,m.index).split(`
209
+ `),N=m[0].split(`
210
+ `),M=i+$.length-1,S=$[$.length-1].length,O=M+N.length-1,x=N.length==1?S+N[0].length:N[N.length-1].length;return{startRow:M,startCol:S,endRow:O,endCol:x}}}return null},o.prototype.$multiLineBackward=function(r,t,i,c,h){for(var f,v=s(r,c),p=r.getLine(c).length-i,y=c;y>=h;){for(var m=0;m<v&&y>=h;m++){var $=r.getLine(y--);f=f==null?$:$+`
211
+ `+f}var N=n(f,t,p);if(N){var M=f.slice(0,N.index).split(`
212
+ `),S=N[0].split(`
213
+ `),O=y+M.length,x=M[M.length-1].length,L=O+S.length-1,I=S.length==1?x+S[0].length:S[S.length-1].length;return{startRow:O,startCol:x,endRow:L,endCol:I}}}return null},o.prototype.$matchIterator=function(r,t){var i=this.$assembleRegExp(t);if(!i)return!1;var c=this.$isMultilineSearch(t),h=this.$multiLineForward,f=this.$multiLineBackward,v=t.backwards==!0,p=t.skipCurrent!=!1,y=i.unicode,m=t.range,$=t.start;$||($=m?m[v?"end":"start"]:r.selection.getRange()),$.start&&($=$[p!=v?"end":"start"]);var N=m?m.start.row:0,M=m?m.end.row:r.getLength()-1;if(v)var S=function(L){var I=$.row;if(!x(I,$.column,L)){for(I--;I>=N;I--)if(x(I,Number.MAX_VALUE,L))return;if(t.wrap!=!1){for(I=M,N=$.row;I>=N;I--)if(x(I,Number.MAX_VALUE,L))return}}};else var S=function(I){var w=$.row;if(!x(w,$.column,I)){for(w=w+1;w<=M;w++)if(x(w,0,I))return;if(t.wrap!=!1){for(w=N,M=$.row;w<=M;w++)if(x(w,0,I))return}}};if(t.$isMultiLine)var O=i.length,x=function(L,I,w){var _=v?L-O+1:L;if(!(_<0||_+O>r.getLength())){var T=r.getLine(_),k=T.search(i[0]);if(!(!v&&k<I||k===-1)){for(var R=1;R<O;R++)if(T=r.getLine(_+R),T.search(i[R])==-1)return;var D=T.match(i[O-1])[0].length;if(!(v&&D>I)&&w(_,k,_+O-1,D))return!0}}};else if(v)var x=function(I,w,_){if(c){var T=f(r,i,w,I,N);if(!T)return!1;if(_(T.startRow,T.startCol,T.endRow,T.endCol))return!0}else{var k=r.getLine(I),R=[],D,V=0;for(i.lastIndex=0;D=i.exec(k);){var B=D[0].length;if(V=D.index,!B){if(V>=k.length)break;i.lastIndex=V+=b.skipEmptyMatch(k,V,y)}if(D.index+B>w)break;R.push(D.index,B)}for(var F=R.length-1;F>=0;F-=2){var H=R[F-1],B=R[F];if(_(I,H,I,H+B))return!0}}};else var x=function(I,w,_){if(i.lastIndex=w,c){var T=h(r,i,I,M);if(T){var k=T.endRow<=M?T.endRow-1:M;k>I&&(I=k)}if(!T)return!1;if(_(T.startRow,T.startCol,T.endRow,T.endCol))return!0}else for(var R=r.getLine(I),D,V;V=i.exec(R);){var B=V[0].length;if(D=V.index,_(I,D,I,D+B))return!0;if(!B&&(i.lastIndex=D+=b.skipEmptyMatch(R,D,y),D>=R.length))return!1}};return{forEach:S}},o}();function g(o,r){var t=b.supportsLookbehind();function i(v,p){p===void 0&&(p=!0);var y=t&&r.$supportsUnicodeFlag?new RegExp("[\\p{L}\\p{N}_]","u"):new RegExp("\\w");return y.test(v)||r.regExp?t&&r.$supportsUnicodeFlag?p?"(?<=^|[^\\p{L}\\p{N}_])":"(?=[^\\p{L}\\p{N}_]|$)":"\\b":""}var c=Array.from(o),h=c[0],f=c[c.length-1];return i(h)+o+i(f,!1)}function n(o,r,t){for(var i=null,c=0;c<=o.length;){r.lastIndex=c;var h=r.exec(o);if(!h)break;var f=h.index+h[0].length;if(f>o.length-t)break;(!i||f>i.index+i[0].length)&&(i=h),c=h.index+1}return i}function s(o,r){var t=5e3,i={row:r,column:0},c=o.doc.positionToIndex(i),h=c+t,f=o.doc.indexToPosition(h),v=f.row;return v+1}d.Search=a}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(l,d,E){var b=this&&this.__extends||function(){var o=function(r,t){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,c){i.__proto__=c}||function(i,c){for(var h in c)Object.prototype.hasOwnProperty.call(c,h)&&(i[h]=c[h])},o(r,t)};return function(r,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");o(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),C=l("../lib/keys"),A=l("../lib/useragent"),a=C.KEY_MODS,g=function(){function o(r,t){this.$init(r,t,!1)}return o.prototype.$init=function(r,t,i){this.platform=t||(A.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(r),this.$singleCommand=i},o.prototype.addCommand=function(r){this.commands[r.name]&&this.removeCommand(r),this.commands[r.name]=r,r.bindKey&&this._buildKeyHash(r)},o.prototype.removeCommand=function(r,t){var i=r&&(typeof r=="string"?r:r.name);r=this.commands[i],t||delete this.commands[i];var c=this.commandKeyBinding;for(var h in c){var f=c[h];if(f==r)delete c[h];else if(Array.isArray(f)){var v=f.indexOf(r);v!=-1&&(f.splice(v,1),f.length==1&&(c[h]=f[0]))}}},o.prototype.bindKey=function(r,t,i){if(typeof r=="object"&&r&&(i==null&&(i=r.position),r=r[this.platform]),!!r){if(typeof t=="function")return this.addCommand({exec:t,bindKey:r,name:t.name||r});r.split("|").forEach(function(c){var h="";if(c.indexOf(" ")!=-1){var f=c.split(/\s+/);c=f.pop(),f.forEach(function(y){var m=this.parseKeys(y),$=a[m.hashId]+m.key;h+=(h?" ":"")+$,this._addCommandToBinding(h,"chainKeys")},this),h+=" "}var v=this.parseKeys(c),p=a[v.hashId]+v.key;this._addCommandToBinding(h+p,t,i)},this)}},o.prototype._addCommandToBinding=function(r,t,i){var c=this.commandKeyBinding,h;if(!t)delete c[r];else if(!c[r]||this.$singleCommand)c[r]=t;else{Array.isArray(c[r])?(h=c[r].indexOf(t))!=-1&&c[r].splice(h,1):c[r]=[c[r]],typeof i!="number"&&(i=n(t));var f=c[r];for(h=0;h<f.length;h++){var v=f[h],p=n(v);if(p>i)break}f.splice(h,0,t)}},o.prototype.addCommands=function(r){r&&Object.keys(r).forEach(function(t){var i=r[t];if(i){if(typeof i=="string")return this.bindKey(i,t);typeof i=="function"&&(i={exec:i}),typeof i=="object"&&(i.name||(i.name=t),this.addCommand(i))}},this)},o.prototype.removeCommands=function(r){Object.keys(r).forEach(function(t){this.removeCommand(r[t])},this)},o.prototype.bindKeys=function(r){Object.keys(r).forEach(function(t){this.bindKey(t,r[t])},this)},o.prototype._buildKeyHash=function(r){this.bindKey(r.bindKey,r)},o.prototype.parseKeys=function(r){var t=r.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(p){return p}),i=t.pop(),c=C[i];if(C.FUNCTION_KEYS[c])i=C.FUNCTION_KEYS[c].toLowerCase();else if(t.length){if(t.length==1&&t[0]=="shift")return{key:i.toUpperCase(),hashId:-1}}else return{key:i,hashId:-1};for(var h=0,f=t.length;f--;){var v=C.KEY_MODS[t[f]];if(v==null)return typeof console<"u"&&console.error("invalid modifier "+t[f]+" in "+r),!1;h|=v}return{key:i,hashId:h}},o.prototype.findKeyCommand=function(r,t){var i=a[r]+t;return this.commandKeyBinding[i]},o.prototype.handleKeyboard=function(r,t,i,c){if(!(c<0)){var h=a[t]+i,f=this.commandKeyBinding[h];return r.$keyChain&&(r.$keyChain+=" "+h,f=this.commandKeyBinding[r.$keyChain]||f),f&&(f=="chainKeys"||f[f.length-1]=="chainKeys")?(r.$keyChain=r.$keyChain||h,{command:"null"}):(r.$keyChain&&((!t||t==4)&&i.length==1?r.$keyChain=r.$keyChain.slice(0,-h.length-1):(t==-1||c>0)&&(r.$keyChain="")),{command:f})}},o.prototype.getStatusText=function(r,t){return t.$keyChain||""},o}();function n(o){return typeof o=="object"&&o.bindKey&&o.bindKey.position||(o.isDefault?-100:0)}var s=function(o){b(r,o);function r(t,i){var c=o.call(this,t,i)||this;return c.$singleCommand=!0,c}return r}(g);s.call=function(o,r,t){g.prototype.$init.call(o,r,t,!0)},g.call=function(o,r,t){g.prototype.$init.call(o,r,t,!1)},d.HashHandler=s,d.MultiHashHandler=g}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(l,d,E){var b=this&&this.__extends||function(){var n=function(s,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,t){r.__proto__=t}||function(r,t){for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(r[i]=t[i])},n(s,o)};return function(s,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(s,o);function r(){this.constructor=s}s.prototype=o===null?Object.create(o):(r.prototype=o.prototype,new r)}}(),C=l("../lib/oop"),A=l("../keyboard/hash_handler").MultiHashHandler,a=l("../lib/event_emitter").EventEmitter,g=function(n){b(s,n);function s(o,r){var t=n.call(this,r,o)||this;return t.byName=t.commands,t.setDefaultHandler("exec",function(i){return i.args?i.command.exec(i.editor,i.args,i.event,!1):i.command.exec(i.editor,{},i.event,!0)}),t}return s.prototype.exec=function(o,r,t){if(Array.isArray(o)){for(var i=o.length;i--;)if(this.exec(o[i],r,t))return!0;return!1}typeof o=="string"&&(o=this.commands[o]);var c={editor:r,command:o,args:t};return this.canExecute(o,r)?(c.returnValue=this._emit("exec",c),this._signal("afterExec",c),c.returnValue!==!1):(this._signal("commandUnavailable",c),!1)},s.prototype.canExecute=function(o,r){return typeof o=="string"&&(o=this.commands[o]),!(!o||r&&r.$readOnly&&!o.readOnly||this.$checkCommandState!=!1&&o.isAvailable&&!o.isAvailable(r))},s.prototype.toggleRecording=function(o){if(!this.$inReplay)return o&&o._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(r){this.macro.push([r.command,r.args])}).bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},s.prototype.replay=function(o){if(!(this.$inReplay||!this.macro)){if(this.recording)return this.toggleRecording(o);try{this.$inReplay=!0,this.macro.forEach(function(r){typeof r=="string"?this.exec(r,o):this.exec(r[0],o,r[1])},this)}finally{this.$inReplay=!1}}},s.prototype.trimMacro=function(o){return o.map(function(r){return typeof r[0]!="string"&&(r[0]=r[0].name),r[1]||(r=r[0]),r})},s}(A);C.implement(g.prototype,a),d.CommandManager=g}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(l,d,E){var b=l("../lib/lang"),C=l("../config"),A=l("../range").Range;function a(n,s){return{win:n,mac:s}}d.commands=[{name:"showSettingsMenu",description:"Show settings menu",bindKey:a("Ctrl-,","Command-,"),exec:function(n){C.loadModule("ace/ext/settings_menu",function(s){s.init(n),n.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",description:"Go to next error",bindKey:a("Alt-E","F4"),exec:function(n){C.loadModule("ace/ext/error_marker",function(s){s.showErrorMarker(n,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",description:"Go to previous error",bindKey:a("Alt-Shift-E","Shift-F4"),exec:function(n){C.loadModule("ace/ext/error_marker",function(s){s.showErrorMarker(n,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",description:"Select all",bindKey:a("Ctrl-A","Command-A"),exec:function(n){n.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:a(null,"Ctrl-L"),exec:function(n){n.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:a("Ctrl-L","Command-L"),exec:function(n,s){typeof s=="number"&&!isNaN(s)&&n.gotoLine(s),n.prompt({$type:"gotoLine"})},readOnly:!0},{name:"fold",bindKey:a("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(n){n.session.toggleFold(!1)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:a("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(n){n.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",description:"Toggle fold widget",bindKey:a("F2","F2"),exec:function(n){n.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",description:"Toggle parent fold widget",bindKey:a("Alt-F2","Alt-F2"),exec:function(n){n.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:a(null,"Ctrl-Command-Option-0"),exec:function(n){n.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:a(null,"Ctrl-Command-Option-0"),exec:function(n){n.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:a("Alt-0","Command-Option-0"),exec:function(n){n.session.foldAll(),n.session.unfold(n.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",description:"Unfold all",bindKey:a("Alt-Shift-0","Command-Option-Shift-0"),exec:function(n){n.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:a("Ctrl-K","Command-G"),exec:function(n){n.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:a("Ctrl-Shift-K","Command-Shift-G"),exec:function(n){n.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",description:"Select or find next",bindKey:a("Alt-K","Ctrl-G"),exec:function(n){n.selection.isEmpty()?n.selection.selectWord():n.findNext()},readOnly:!0},{name:"selectOrFindPrevious",description:"Select or find previous",bindKey:a("Alt-Shift-K","Ctrl-Shift-G"),exec:function(n){n.selection.isEmpty()?n.selection.selectWord():n.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:a("Ctrl-F","Command-F"),exec:function(n){C.loadModule("ace/ext/searchbox",function(s){s.Search(n)})},readOnly:!0},{name:"overwrite",description:"Overwrite",bindKey:"Insert",exec:function(n){n.toggleOverwrite()},readOnly:!0},{name:"selecttostart",description:"Select to start",bindKey:a("Ctrl-Shift-Home","Command-Shift-Home|Command-Shift-Up"),exec:function(n){n.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",description:"Go to start",bindKey:a("Ctrl-Home","Command-Home|Command-Up"),exec:function(n){n.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",description:"Select up",bindKey:a("Shift-Up","Shift-Up|Ctrl-Shift-P"),exec:function(n){n.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",description:"Go line up",bindKey:a("Up","Up|Ctrl-P"),exec:function(n,s){n.navigateUp(s.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",description:"Select to end",bindKey:a("Ctrl-Shift-End","Command-Shift-End|Command-Shift-Down"),exec:function(n){n.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",description:"Go to end",bindKey:a("Ctrl-End","Command-End|Command-Down"),exec:function(n){n.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",description:"Select down",bindKey:a("Shift-Down","Shift-Down|Ctrl-Shift-N"),exec:function(n){n.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",description:"Go line down",bindKey:a("Down","Down|Ctrl-N"),exec:function(n,s){n.navigateDown(s.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",description:"Select word left",bindKey:a("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(n){n.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",description:"Go to word left",bindKey:a("Ctrl-Left","Option-Left"),exec:function(n){n.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",description:"Select to line start",bindKey:a("Alt-Shift-Left","Command-Shift-Left|Ctrl-Shift-A"),exec:function(n){n.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",description:"Go to line start",bindKey:a("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(n){n.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",description:"Select left",bindKey:a("Shift-Left","Shift-Left|Ctrl-Shift-B"),exec:function(n){n.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",description:"Go to left",bindKey:a("Left","Left|Ctrl-B"),exec:function(n,s){n.navigateLeft(s.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",description:"Select word right",bindKey:a("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(n){n.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",description:"Go to word right",bindKey:a("Ctrl-Right","Option-Right"),exec:function(n){n.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",description:"Select to line end",bindKey:a("Alt-Shift-Right","Command-Shift-Right|Shift-End|Ctrl-Shift-E"),exec:function(n){n.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",description:"Go to line end",bindKey:a("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(n){n.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",description:"Select right",bindKey:a("Shift-Right","Shift-Right"),exec:function(n){n.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:a("Right","Right|Ctrl-F"),exec:function(n,s){n.navigateRight(s.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",description:"Select page down",bindKey:"Shift-PageDown",exec:function(n){n.selectPageDown()},readOnly:!0},{name:"pagedown",description:"Page down",bindKey:a(null,"Option-PageDown"),exec:function(n){n.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:a("PageDown","PageDown|Ctrl-V"),exec:function(n){n.gotoPageDown()},readOnly:!0},{name:"selectpageup",description:"Select page up",bindKey:"Shift-PageUp",exec:function(n){n.selectPageUp()},readOnly:!0},{name:"pageup",description:"Page up",bindKey:a(null,"Option-PageUp"),exec:function(n){n.scrollPageUp()},readOnly:!0},{name:"gotopageup",description:"Go to page up",bindKey:"PageUp",exec:function(n){n.gotoPageUp()},readOnly:!0},{name:"scrollup",description:"Scroll up",bindKey:a("Ctrl-Up",null),exec:function(n){n.renderer.scrollBy(0,-2*n.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:a("Ctrl-Down",null),exec:function(n){n.renderer.scrollBy(0,2*n.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",description:"Select line start",bindKey:"Shift-Home",exec:function(n){n.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",description:"Select line end",bindKey:"Shift-End",exec:function(n){n.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",description:"Toggle recording",bindKey:a("Ctrl-Alt-E","Command-Option-E"),exec:function(n){n.commands.toggleRecording(n)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:a("Ctrl-Shift-E","Command-Shift-E"),exec:function(n){n.commands.replay(n)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:a("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(n){n.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:a("Ctrl-Shift-\\|Ctrl-Shift-P","Command-Shift-\\"),exec:function(n){n.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",description:"Expand to matching",bindKey:a("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(n){n.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",description:"Pass keys to browser",bindKey:a(null,null),exec:function(){},passEvent:!0,readOnly:!0},{name:"copy",description:"Copy",exec:function(n){},readOnly:!0},{name:"cut",description:"Cut",exec:function(n){var s=n.$copyWithEmptySelection&&n.selection.isEmpty(),o=s?n.selection.getLineRange():n.selection.getRange();n._emit("cut",o),o.isEmpty()||n.session.remove(o),n.clearSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",description:"Paste",exec:function(n,s){n.$handlePaste(s)},scrollIntoView:"cursor"},{name:"removeline",description:"Remove line",bindKey:a("Ctrl-D","Command-D"),exec:function(n){n.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:a("Ctrl-Shift-D","Command-Shift-D"),exec:function(n){n.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:a("Ctrl-Alt-S","Command-Alt-S"),exec:function(n){n.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:a("Ctrl-/","Command-/"),exec:function(n){n.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:a("Ctrl-Shift-/","Command-Shift-/"),exec:function(n){n.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:a("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(n){n.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:a("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(n){n.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:a("Ctrl-H","Command-Option-F"),exec:function(n){C.loadModule("ace/ext/searchbox",function(s){s.Search(n,!0)})}},{name:"undo",description:"Undo",bindKey:a("Ctrl-Z","Command-Z"),exec:function(n){n.undo()}},{name:"redo",description:"Redo",bindKey:a("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(n){n.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:a("Alt-Shift-Up","Command-Option-Up"),exec:function(n){n.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:a("Alt-Up","Option-Up"),exec:function(n){n.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:a("Alt-Shift-Down","Command-Option-Down"),exec:function(n){n.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:a("Alt-Down","Option-Down"),exec:function(n){n.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:a("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(n){n.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:a("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(n){n.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",description:"Cut or delete",bindKey:a("Shift-Delete",null),exec:function(n){if(n.selection.isEmpty())n.remove("left");else return!1},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",description:"Remove to line start",bindKey:a("Alt-Backspace","Command-Backspace"),exec:function(n){n.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:a("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(n){n.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:a("Ctrl-Shift-Backspace",null),exec:function(n){var s=n.selection.getRange();s.start.column=0,n.session.remove(s)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineendhard",description:"Remove to line end hard",bindKey:a("Ctrl-Shift-Delete",null),exec:function(n){var s=n.selection.getRange();s.end.column=Number.MAX_VALUE,n.session.remove(s)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",description:"Remove word left",bindKey:a("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(n){n.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:a("Ctrl-Delete","Alt-Delete"),exec:function(n){n.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:a("Shift-Tab","Shift-Tab"),exec:function(n){n.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:a("Tab","Tab"),exec:function(n){n.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:a("Ctrl-[","Ctrl-["),exec:function(n){n.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:a("Ctrl-]","Ctrl-]"),exec:function(n){n.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",description:"Insert string",exec:function(n,s){n.insert(s)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",description:"Insert text",exec:function(n,s){n.insert(b.stringRepeat(s.text||"",s.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:a(null,"Ctrl-O"),exec:function(n){n.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:a("Alt-Shift-X","Ctrl-T"),exec:function(n){n.transposeLetters()},multiSelectAction:function(n){n.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:a("Ctrl-U","Ctrl-U"),exec:function(n){n.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:a("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(n){n.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:a(null,null),exec:function(n){n.autoIndent()},scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:a("Ctrl-Shift-L","Command-Shift-L"),exec:function(n){var s=n.selection.getRange();s.start.column=s.end.column=0,s.end.row++,n.selection.setRange(s,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"openlink",bindKey:a("Ctrl+F3","F3"),exec:function(n){n.openLink()}},{name:"joinlines",description:"Join lines",bindKey:a(null,null),exec:function(n){for(var s=n.selection.isBackwards(),o=s?n.selection.getSelectionLead():n.selection.getSelectionAnchor(),r=s?n.selection.getSelectionAnchor():n.selection.getSelectionLead(),t=n.session.doc.getLine(o.row).length,i=n.session.doc.getTextRange(n.selection.getRange()),c=i.replace(/\n\s*/," ").length,h=n.session.doc.getLine(o.row),f=o.row+1;f<=r.row+1;f++){var v=b.stringTrimLeft(b.stringTrimRight(n.session.doc.getLine(f)));v.length!==0&&(v=" "+v),h+=v}r.row+1<n.session.doc.getLength()-1&&(h+=n.session.doc.getNewLineCharacter()),n.clearSelection(),n.session.doc.replace(new A(o.row,0,r.row+2,0),h),c>0?(n.selection.moveCursorTo(o.row,o.column),n.selection.selectTo(o.row,o.column+c)):(t=n.session.doc.getLine(o.row).length>t?t+1:t,n.selection.moveCursorTo(o.row,t))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:a(null,null),exec:function(n){var s=n.session.doc.getLength()-1,o=n.session.doc.getLine(s).length,r=n.selection.rangeList.ranges,t=[];r.length<1&&(r=[n.selection.getRange()]);for(var i=0;i<r.length;i++)i==r.length-1&&(r[i].end.row===s&&r[i].end.column===o||t.push(new A(r[i].end.row,r[i].end.column,s,o))),i===0?r[i].start.row===0&&r[i].start.column===0||t.push(new A(0,0,r[i].start.row,r[i].start.column)):t.push(new A(r[i-1].end.row,r[i-1].end.column,r[i].start.row,r[i].start.column));n.exitMultiSelectMode(),n.clearSelection();for(var i=0;i<t.length;i++)n.selection.addRange(t[i],!1)},readOnly:!0,scrollIntoView:"none"},{name:"addLineAfter",description:"Add new line after the current line",exec:function(n){n.selection.clearSelection(),n.navigateLineEnd(),n.insert(`
214
+ `)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"addLineBefore",description:"Add new line before the current line",exec:function(n){n.selection.clearSelection();var s=n.getCursorPosition();n.selection.moveTo(s.row-1,Number.MAX_VALUE),n.insert(`
215
+ `),s.row===0&&n.navigateUp()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"openCommandPallete",exec:function(n){console.warn("This is an obsolete command. Please use `openCommandPalette` instead."),n.prompt({$type:"commands"})},readOnly:!0},{name:"openCommandPalette",description:"Open command palette",bindKey:a("F1","F1"),exec:function(n){n.prompt({$type:"commands"})},readOnly:!0},{name:"modeSelect",description:"Change language mode...",bindKey:a(null,null),exec:function(n){n.prompt({$type:"modes"})},readOnly:!0}];for(var g=1;g<9;g++)d.commands.push({name:"foldToLevel"+g,description:"Fold To Level "+g,level:g,exec:function(n){n.session.foldToLevel(this.level)},scrollIntoView:"center",readOnly:!0})}),ace.define("ace/keyboard/gutter_handler",["require","exports","module","ace/lib/keys","ace/mouse/default_gutter_handler"],function(l,d,E){var b=l("../lib/keys"),C=l("../mouse/default_gutter_handler").GutterTooltip,A=function(){function g(n){this.editor=n,this.gutterLayer=n.renderer.$gutterLayer,this.element=n.renderer.$gutter,this.lines=n.renderer.$gutterLayer.$lines,this.activeRowIndex=null,this.activeLane=null,this.annotationTooltip=new C(this.editor)}return g.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))},g.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))},g.prototype.$onGutterKeyDown=function(n){if(this.annotationTooltip.isOpen){n.preventDefault(),n.keyCode===b.escape&&this.annotationTooltip.hideTooltip();return}if(n.target===this.element){if(n.keyCode!=b.enter)return;n.preventDefault();var s=this.editor.getCursorPosition().row;this.editor.isRowVisible(s)||this.editor.scrollToLine(s,!0,!0),setTimeout((function(){var o=this.$rowToRowIndex(this.gutterLayer.$cursorCell.row),r=this.$findNearestFoldWidget(o),t=this.$findNearestAnnotation(o);if(!(r===null&&t===null)){if(r===null&&t!==null){this.activeRowIndex=t,this.activeLane="annotation",this.$focusAnnotation(this.activeRowIndex);return}if(r!==null&&t===null){this.activeRowIndex=r,this.activeLane="fold",this.$focusFoldWidget(this.activeRowIndex);return}if(Math.abs(t-o)<Math.abs(r-o)){this.activeRowIndex=t,this.activeLane="annotation",this.$focusAnnotation(this.activeRowIndex);return}else{this.activeRowIndex=r,this.activeLane="fold",this.$focusFoldWidget(this.activeRowIndex);return}}}).bind(this),10);return}this.$handleGutterKeyboardInteraction(n),setTimeout((function(){this.editor._signal("gutterkeydown",new a(n,this))}).bind(this),10)},g.prototype.$handleGutterKeyboardInteraction=function(n){if(n.keyCode===b.tab){n.preventDefault();return}if(n.keyCode===b.escape){n.preventDefault(),this.$blurGutter(),this.element.focus(),this.lane=null;return}if(n.keyCode===b.up){switch(n.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetUp();break;case"annotation":this.$moveAnnotationUp();break}return}if(n.keyCode===b.down){switch(n.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetDown();break;case"annotation":this.$moveAnnotationDown();break}return}if(n.keyCode===b.left){n.preventDefault(),this.$switchLane("annotation");return}if(n.keyCode===b.right){n.preventDefault(),this.$switchLane("fold");return}if(n.keyCode===b.enter||n.keyCode===b.space){switch(n.preventDefault(),this.activeLane){case"fold":if(this.gutterLayer.session.foldWidgets[this.$rowIndexToRow(this.activeRowIndex)]==="start"){var s=this.$rowIndexToRow(this.activeRowIndex);this.editor.session.onFoldWidgetClick(this.$rowIndexToRow(this.activeRowIndex),n),setTimeout((function(){this.$rowIndexToRow(this.activeRowIndex)!==s&&(this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=this.$rowToRowIndex(s),this.$focusFoldWidget(this.activeRowIndex))}).bind(this),10);break}else if(this.gutterLayer.session.foldWidgets[this.$rowIndexToRow(this.activeRowIndex)]==="end")break;return;case"annotation":var o=this.lines.cells[this.activeRowIndex].element.childNodes[2],r=o.getBoundingClientRect(),t=this.annotationTooltip.getElement().style;t.left=r.right+"px",t.top=r.bottom+"px",this.annotationTooltip.showTooltip(this.$rowIndexToRow(this.activeRowIndex));break}return}},g.prototype.$blurGutter=function(){if(this.activeRowIndex!==null)switch(this.activeLane){case"fold":this.$blurFoldWidget(this.activeRowIndex);break;case"annotation":this.$blurAnnotation(this.activeRowIndex);break}this.annotationTooltip.isOpen&&this.annotationTooltip.hideTooltip()},g.prototype.$isFoldWidgetVisible=function(n){var s=this.editor.isRowFullyVisible(this.$rowIndexToRow(n)),o=this.$getFoldWidget(n).style.display!=="none";return s&&o},g.prototype.$isAnnotationVisible=function(n){var s=this.editor.isRowFullyVisible(this.$rowIndexToRow(n)),o=this.$getAnnotation(n).style.display!=="none";return s&&o},g.prototype.$getFoldWidget=function(n){var s=this.lines.get(n),o=s.element;return o.childNodes[1]},g.prototype.$getAnnotation=function(n){var s=this.lines.get(n),o=s.element;return o.childNodes[2]},g.prototype.$findNearestFoldWidget=function(n){if(this.$isFoldWidgetVisible(n))return n;for(var s=0;n-s>0||n+s<this.lines.getLength()-1;){if(s++,n-s>=0&&this.$isFoldWidgetVisible(n-s))return n-s;if(n+s<=this.lines.getLength()-1&&this.$isFoldWidgetVisible(n+s))return n+s}return null},g.prototype.$findNearestAnnotation=function(n){if(this.$isAnnotationVisible(n))return n;for(var s=0;n-s>0||n+s<this.lines.getLength()-1;){if(s++,n-s>=0&&this.$isAnnotationVisible(n-s))return n-s;if(n+s<=this.lines.getLength()-1&&this.$isAnnotationVisible(n+s))return n+s}return null},g.prototype.$focusFoldWidget=function(n){if(n!=null){var s=this.$getFoldWidget(n);s.classList.add(this.editor.renderer.keyboardFocusClassName),s.focus()}},g.prototype.$focusAnnotation=function(n){if(n!=null){var s=this.$getAnnotation(n);s.classList.add(this.editor.renderer.keyboardFocusClassName),s.focus()}},g.prototype.$blurFoldWidget=function(n){var s=this.$getFoldWidget(n);s.classList.remove(this.editor.renderer.keyboardFocusClassName),s.blur()},g.prototype.$blurAnnotation=function(n){var s=this.$getAnnotation(n);s.classList.remove(this.editor.renderer.keyboardFocusClassName),s.blur()},g.prototype.$moveFoldWidgetUp=function(){for(var n=this.activeRowIndex;n>0;)if(n--,this.$isFoldWidgetVisible(n)){this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=n,this.$focusFoldWidget(this.activeRowIndex);return}},g.prototype.$moveFoldWidgetDown=function(){for(var n=this.activeRowIndex;n<this.lines.getLength()-1;)if(n++,this.$isFoldWidgetVisible(n)){this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=n,this.$focusFoldWidget(this.activeRowIndex);return}},g.prototype.$moveAnnotationUp=function(){for(var n=this.activeRowIndex;n>0;)if(n--,this.$isAnnotationVisible(n)){this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=n,this.$focusAnnotation(this.activeRowIndex);return}},g.prototype.$moveAnnotationDown=function(){for(var n=this.activeRowIndex;n<this.lines.getLength()-1;)if(n++,this.$isAnnotationVisible(n)){this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=n,this.$focusAnnotation(this.activeRowIndex);return}},g.prototype.$switchLane=function(n){switch(n){case"annotation":if(this.activeLane==="annotation")break;var s=this.$findNearestAnnotation(this.activeRowIndex);if(s==null)break;this.activeLane="annotation",this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=s,this.$focusAnnotation(this.activeRowIndex);break;case"fold":if(this.activeLane==="fold")break;var o=this.$findNearestFoldWidget(this.activeRowIndex);if(o==null)break;this.activeLane="fold",this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=o,this.$focusFoldWidget(this.activeRowIndex);break}},g.prototype.$rowIndexToRow=function(n){var s=this.lines.get(n);return s?s.row:null},g.prototype.$rowToRowIndex=function(n){for(var s=0;s<this.lines.getLength();s++){var o=this.lines.get(s);if(o.row==n)return s}return null},g}();d.GutterKeyboardHandler=A;var a=function(){function g(n,s){this.gutterKeyboardHandler=s,this.domEvent=n}return g.prototype.getKey=function(){return b.keyCodeToString(this.domEvent.keyCode)},g.prototype.getRow=function(){return this.gutterKeyboardHandler.$rowIndexToRow(this.gutterKeyboardHandler.activeRowIndex)},g.prototype.isInAnnotationLane=function(){return this.gutterKeyboardHandler.activeLane==="annotation"},g.prototype.isInFoldLane=function(){return this.gutterKeyboardHandler.activeLane==="fold"},g}();d.GutterKeyboardEvent=a}),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(l,d,E){var b=this&&this.__values||function(I){var w=typeof Symbol=="function"&&Symbol.iterator,_=w&&I[w],T=0;if(_)return _.call(I);if(I&&typeof I.length=="number")return{next:function(){return I&&T>=I.length&&(I=void 0),{value:I&&I[T++],done:!I}}};throw new TypeError(w?"Object is not iterable.":"Symbol.iterator is not defined.")},C=l("./lib/oop"),A=l("./lib/dom"),a=l("./lib/lang"),g=l("./lib/useragent"),n=l("./keyboard/textinput").TextInput,s=l("./mouse/mouse_handler").MouseHandler,o=l("./mouse/fold_handler").FoldHandler,r=l("./keyboard/keybinding").KeyBinding,t=l("./edit_session").EditSession,i=l("./search").Search,c=l("./range").Range,h=l("./lib/event_emitter").EventEmitter,f=l("./commands/command_manager").CommandManager,v=l("./commands/default_commands").commands,p=l("./config"),y=l("./token_iterator").TokenIterator,m=l("./keyboard/gutter_handler").GutterKeyboardHandler,$=l("./config").nls,N=l("./clipboard"),M=l("./lib/keys"),S=l("./lib/event"),O=l("./tooltip").HoverTooltip,x=function(){function I(w,_,T){this.session,this.$toDestroy=[];var k=w.getContainerElement();this.container=k,this.renderer=w,this.id="editor"+ ++I.$uid,this.commands=new f(g.isMac?"mac":"win",v),typeof document=="object"&&(this.textInput=new n(w.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.$mouseHandler=new s(this),new o(this)),this.keyBinding=new r(this),this.$search=new i().set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=a.delayedCall((function(){this._signal("input",{}),this.session&&!this.session.destroyed&&this.session.bgTokenizer.scheduleStart()}).bind(this)),this.on("change",function(R,D){D._$emitInputEvent.schedule(31)}),this.setSession(_||T&&T.session||new t("")),p.resetOptions(this),T&&this.setOptions(T),p._signal("editor",this)}return I.prototype.$initOperationListeners=function(){this.commands.on("exec",this.startOperation.bind(this),!0),this.commands.on("afterExec",this.endOperation.bind(this),!0)},I.prototype.startOperation=function(w){this.session.startOperation(w)},I.prototype.endOperation=function(w){this.session.endOperation(w)},I.prototype.onStartOperation=function(w){this.curOp=this.session.curOp,this.curOp.scrollTop=this.renderer.scrollTop,this.prevOp=this.session.prevOp,w||(this.previousCommand=null)},I.prototype.onEndOperation=function(w){if(this.curOp&&this.session){if(w&&w.returnValue===!1){this.curOp=null;return}if(this._signal("beforeEndOperation"),!this.curOp)return;var _=this.curOp.command,T=_&&_.scrollIntoView;if(T){switch(T){case"center-animate":T="animate";case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var k=this.selection.getRange(),R=this.renderer.layerConfig;(k.start.row>=R.lastRow||k.end.row<=R.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break}T=="animate"&&this.renderer.animateScrolling(this.curOp.scrollTop)}this.$lastSel=this.session.selection.toJSON(),this.prevOp=this.curOp,this.curOp=null}},I.prototype.$historyTracker=function(w){if(this.$mergeUndoDeltas){var _=this.prevOp,T=this.$mergeableCommands,k=_.command&&w.command.name==_.command.name;if(w.command.name=="insertstring"){var R=w.args;this.mergeNextCommand===void 0&&(this.mergeNextCommand=!0),k=k&&this.mergeNextCommand&&(!/\s/.test(R)||/\s/.test(_.args)),this.mergeNextCommand=!0}else k=k&&T.indexOf(w.command.name)!==-1;this.$mergeUndoDeltas!="always"&&Date.now()-this.sequenceStartTime>2e3&&(k=!1),k?this.session.mergeUndoDeltas=!0:T.indexOf(w.command.name)!==-1&&(this.sequenceStartTime=Date.now())}},I.prototype.setKeyboardHandler=function(w,_){if(w&&typeof w=="string"&&w!="ace"){this.$keybindingId=w;var T=this;p.loadModule(["keybinding",w],function(k){T.$keybindingId==w&&T.keyBinding.setKeyboardHandler(k&&k.handler),_&&_()})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(w),_&&_()},I.prototype.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},I.prototype.setSession=function(w){if(this.session!=w){this.curOp&&this.endOperation(),this.curOp={};var _=this.session;if(_){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 T=this.session.getSelection();T.off("changeCursor",this.$onCursorChange),T.off("changeSelection",this.$onSelectionChange)}this.session=w,w?(this.$onDocumentChange=this.onDocumentChange.bind(this),w.on("change",this.$onDocumentChange),this.renderer.setSession(w),this.$onChangeMode=this.onChangeMode.bind(this),w.on("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),w.on("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),w.on("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),w.on("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),w.on("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),w.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=w.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(w)),this._signal("changeSession",{session:w,oldSession:_}),this.curOp=null,_&&_._signal("changeEditor",{oldEditor:this}),_&&(_.$editor=null),w&&w._signal("changeEditor",{editor:this}),w&&(w.$editor=this),w&&!w.destroyed&&w.bgTokenizer.scheduleStart()}},I.prototype.getSession=function(){return this.session},I.prototype.setValue=function(w,_){return this.session.doc.setValue(w),_?_==1?this.navigateFileEnd():_==-1&&this.navigateFileStart():this.selectAll(),w},I.prototype.getValue=function(){return this.session.getValue()},I.prototype.getSelection=function(){return this.selection},I.prototype.resize=function(w){this.renderer.onResize(w)},I.prototype.setTheme=function(w,_){this.renderer.setTheme(w,_)},I.prototype.getTheme=function(){return this.renderer.getTheme()},I.prototype.setStyle=function(w){this.renderer.setStyle(w)},I.prototype.unsetStyle=function(w){this.renderer.unsetStyle(w)},I.prototype.getFontSize=function(){return this.getOption("fontSize")||A.computedStyle(this.container).fontSize},I.prototype.setFontSize=function(w){this.setOption("fontSize",w)},I.prototype.$highlightBrackets=function(){if(!this.$highlightPending){var w=this;this.$highlightPending=!0,setTimeout(function(){w.$highlightPending=!1;var _=w.session;if(!(!_||_.destroyed)){_.$bracketHighlight&&(_.$bracketHighlight.markerIds.forEach(function(U){_.removeMarker(U)}),_.$bracketHighlight=null);var T=w.getCursorPosition(),k=w.getKeyboardHandler(),R=k&&k.$getDirectionForHighlight&&k.$getDirectionForHighlight(w),D=_.getMatchingBracketRanges(T,R);if(!D){var V=new y(_,T.row,T.column),B=V.getCurrentToken();if(B&&/\b(?:tag-open|tag-name)/.test(B.type)){var F=_.getMatchingTags(T);F&&(D=[F.openTagName.isEmpty()?F.openTag:F.openTagName,F.closeTagName.isEmpty()?F.closeTag:F.closeTagName])}}if(!D&&_.$mode.getMatching&&(D=_.$mode.getMatching(w.session)),!D){w.getHighlightIndentGuides()&&w.renderer.$textLayer.$highlightIndentGuide();return}var H="ace_bracket";Array.isArray(D)?D.length==1&&(H="ace_error_bracket"):D=[D],D.length==2&&(c.comparePoints(D[0].end,D[1].start)==0?D=[c.fromPoints(D[0].start,D[1].end)]:c.comparePoints(D[0].start,D[1].end)==0&&(D=[c.fromPoints(D[1].start,D[0].end)])),_.$bracketHighlight={ranges:D,markerIds:D.map(function(U){return _.addMarker(U,H,"text")})},w.getHighlightIndentGuides()&&w.renderer.$textLayer.$highlightIndentGuide()}},50)}},I.prototype.focus=function(){this.textInput.focus()},I.prototype.isFocused=function(){return this.textInput.isFocused()},I.prototype.blur=function(){this.textInput.blur()},I.prototype.onFocus=function(w){this.$isFocused||(this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",w))},I.prototype.onBlur=function(w){this.$isFocused&&(this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",w))},I.prototype.$cursorChange=function(){this.renderer.updateCursor(),this.$highlightBrackets(),this.$updateHighlightActiveLine()},I.prototype.onDocumentChange=function(w){var _=this.session.$useWrapMode,T=w.start.row==w.end.row?w.end.row:1/0;this.renderer.updateLines(w.start.row,T,_),this._signal("change",w),this.$cursorChange()},I.prototype.onTokenizerUpdate=function(w){var _=w.data;this.renderer.updateLines(_.first,_.last)},I.prototype.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},I.prototype.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},I.prototype.onCursorChange=function(){this.$cursorChange(),this._signal("changeSelection")},I.prototype.$updateHighlightActiveLine=function(){var w=this.getSession(),_;if(this.$highlightActiveLine&&((this.$selectionStyle!="line"||!this.selection.isMultiLine())&&(_=this.getCursorPosition()),this.renderer.theme&&this.renderer.theme.$selectionColorConflict&&!this.selection.isEmpty()&&(_=!1),this.renderer.$maxLines&&this.session.getLength()===1&&!(this.renderer.$minLines>1)&&(_=!1)),w.$highlightLineMarker&&!_)w.removeMarker(w.$highlightLineMarker.id),w.$highlightLineMarker=null;else if(!w.$highlightLineMarker&&_){var T=new c(_.row,_.column,_.row,1/0);T.id=w.addMarker(T,"ace_active-line","screenLine"),w.$highlightLineMarker=T}else _&&(w.$highlightLineMarker.start.row=_.row,w.$highlightLineMarker.end.row=_.row,w.$highlightLineMarker.start.column=_.column,w._signal("changeBackMarker"))},I.prototype.onSelectionChange=function(w){var _=this.session;if(_.$selectionMarker&&_.removeMarker(_.$selectionMarker),_.$selectionMarker=null,this.selection.isEmpty())this.$updateHighlightActiveLine();else{var T=this.selection.getRange(),k=this.getSelectionStyle();_.$selectionMarker=_.addMarker(T,"ace_selection",k)}var R=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(R),this._signal("changeSelection")},I.prototype.$getSelectionHighLightRegexp=function(){var w=this.session,_=this.getSelectionRange();if(!(_.isEmpty()||_.isMultiLine())){var T=_.start.column,k=_.end.column,R=w.getLine(_.start.row),D=R.substring(T,k);if(!(D.length>5e3||!/[\w\d]/.test(D))){var V=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:D}),B=R.substring(T-1,k+1);if(V.test(B))return V}}},I.prototype.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},I.prototype.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},I.prototype.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},I.prototype.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},I.prototype.onChangeMode=function(w){this.renderer.updateText(),this._emit("changeMode",w)},I.prototype.onChangeWrapLimit=function(){this.renderer.updateFull()},I.prototype.onChangeWrapMode=function(){this.renderer.onResize(!0)},I.prototype.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},I.prototype.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},I.prototype.getCopyText=function(){var w=this.getSelectedText(),_=this.session.doc.getNewLineCharacter(),T=!1;if(!w&&this.$copyWithEmptySelection){T=!0;for(var k=this.selection.getAllRanges(),R=0;R<k.length;R++){var D=k[R];R&&k[R-1].start.row==D.start.row||(w+=this.session.getLine(D.start.row)+_)}}var V={text:w};return this._signal("copy",V),N.lineMode=T?V.text:!1,V.text},I.prototype.onCopy=function(){this.commands.exec("copy",this)},I.prototype.onCut=function(){this.commands.exec("cut",this)},I.prototype.onPaste=function(w,_){var T={text:w,event:_};this.commands.exec("paste",this,T)},I.prototype.$handlePaste=function(w){typeof w=="string"&&(w={text:w}),this._signal("paste",w);var _=w.text,T=_===N.lineMode,k=this.session;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)T?k.insert({row:this.selection.lead.row,column:0},_):this.insert(_);else if(T)this.selection.rangeList.ranges.forEach(function(H){k.insert({row:H.start.row,column:0},_)});else{var R=_.split(/\r\n|\r|\n/),D=this.selection.rangeList.ranges,V=R.length==2&&(!R[0]||!R[1]);if(R.length!=D.length||V)return this.commands.exec("insertstring",this,_);for(var B=D.length;B--;){var F=D[B];F.isEmpty()||k.remove(F),k.insert(F.start,R[B])}}},I.prototype.execCommand=function(w,_){return this.commands.exec(w,this,_)},I.prototype.insert=function(w,_){var T=this.session,k=T.getMode(),R=this.getCursorPosition();if(this.getBehavioursEnabled()&&!_){var D=k.transformAction(T.getState(R.row),"insertion",this,T,w);D&&(w!==D.text&&(this.inVirtualSelectionMode||(this.session.mergeUndoDeltas=!1,this.mergeNextCommand=!1)),w=D.text)}if(w==" "&&(w=this.session.getTabString()),this.selection.isEmpty()){if(this.session.getOverwrite()&&w.indexOf(`
216
+ `)==-1){var V=c.fromPoints(R,R);V.end.column+=w.length,this.session.remove(V)}}else{var V=this.getSelectionRange();R=this.session.remove(V),this.clearSelection()}if(w==`
217
+ `||w==`\r
218
+ `){var U=T.getLine(R.row);if(R.column>U.search(/\S|$/)){var B=U.substr(R.column).search(/\S|$/);T.doc.removeInLine(R.row,R.column,R.column+B)}}this.clearSelection();var F=R.column,H=T.getState(R.row),U=T.getLine(R.row),z=k.checkOutdent(H,U,w);if(T.insert(R,w),D&&D.selection&&(D.selection.length==2?this.selection.setSelectionRange(new c(R.row,F+D.selection[0],R.row,F+D.selection[1])):this.selection.setSelectionRange(new c(R.row+D.selection[0],D.selection[1],R.row+D.selection[2],D.selection[3]))),this.$enableAutoIndent){if(T.getDocument().isNewLine(w)){var K=k.getNextLineIndent(H,U.slice(0,R.column),T.getTabString());T.insert({row:R.row+1,column:0},K)}z&&k.autoOutdent(H,T,R.row)}},I.prototype.autoIndent=function(){for(var w=this.session,_=w.getMode(),T=this.selection.isEmpty()?[new c(0,0,w.doc.getLength()-1,0)]:this.selection.getAllRanges(),k="",R="",D="",V=w.getTabString(),B=0;B<T.length;B++)for(var F=T[B].start.row,H=T[B].end.row,U=F;U<=H;U++){U>0&&(k=w.getState(U-1),R=w.getLine(U-1),D=_.getNextLineIndent(k,R,V));var z=w.getLine(U),K=_.$getIndent(z);if(D!==K){if(K.length>0){var Y=new c(U,0,U,K.length);w.remove(Y)}D.length>0&&w.insert({row:U,column:0},D)}_.autoOutdent(k,w,U)}},I.prototype.onTextInput=function(w,_){if(!_)return this.keyBinding.onTextInput(w);this.startOperation({command:{name:"insertstring"}});var T=this.applyComposition.bind(this,w,_);this.selection.rangeCount?this.forEachSelection(T):T(),this.endOperation()},I.prototype.applyComposition=function(w,_){if(_.extendLeft||_.extendRight){var T=this.selection.getRange();T.start.column-=_.extendLeft,T.end.column+=_.extendRight,T.start.column<0&&(T.start.row--,T.start.column+=this.session.getLine(T.start.row).length+1),this.selection.setRange(T),!w&&!T.isEmpty()&&this.remove()}if((w||!this.selection.isEmpty())&&this.insert(w,!0),_.restoreStart||_.restoreEnd){var T=this.selection.getRange();T.start.column-=_.restoreStart,T.end.column-=_.restoreEnd,this.selection.setRange(T)}},I.prototype.onCommandKey=function(w,_,T){return this.keyBinding.onCommandKey(w,_,T)},I.prototype.setOverwrite=function(w){this.session.setOverwrite(w)},I.prototype.getOverwrite=function(){return this.session.getOverwrite()},I.prototype.toggleOverwrite=function(){this.session.toggleOverwrite()},I.prototype.setScrollSpeed=function(w){this.setOption("scrollSpeed",w)},I.prototype.getScrollSpeed=function(){return this.getOption("scrollSpeed")},I.prototype.setDragDelay=function(w){this.setOption("dragDelay",w)},I.prototype.getDragDelay=function(){return this.getOption("dragDelay")},I.prototype.setSelectionStyle=function(w){this.setOption("selectionStyle",w)},I.prototype.getSelectionStyle=function(){return this.getOption("selectionStyle")},I.prototype.setHighlightActiveLine=function(w){this.setOption("highlightActiveLine",w)},I.prototype.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},I.prototype.setHighlightGutterLine=function(w){this.setOption("highlightGutterLine",w)},I.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},I.prototype.setHighlightSelectedWord=function(w){this.setOption("highlightSelectedWord",w)},I.prototype.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},I.prototype.setAnimatedScroll=function(w){this.renderer.setAnimatedScroll(w)},I.prototype.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},I.prototype.setShowInvisibles=function(w){this.renderer.setShowInvisibles(w)},I.prototype.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},I.prototype.setDisplayIndentGuides=function(w){this.renderer.setDisplayIndentGuides(w)},I.prototype.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},I.prototype.setHighlightIndentGuides=function(w){this.renderer.setHighlightIndentGuides(w)},I.prototype.getHighlightIndentGuides=function(){return this.renderer.getHighlightIndentGuides()},I.prototype.setShowPrintMargin=function(w){this.renderer.setShowPrintMargin(w)},I.prototype.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},I.prototype.setPrintMarginColumn=function(w){this.renderer.setPrintMarginColumn(w)},I.prototype.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},I.prototype.setReadOnly=function(w){this.setOption("readOnly",w)},I.prototype.getReadOnly=function(){return this.getOption("readOnly")},I.prototype.setBehavioursEnabled=function(w){this.setOption("behavioursEnabled",w)},I.prototype.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},I.prototype.setWrapBehavioursEnabled=function(w){this.setOption("wrapBehavioursEnabled",w)},I.prototype.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},I.prototype.setShowFoldWidgets=function(w){this.setOption("showFoldWidgets",w)},I.prototype.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},I.prototype.setFadeFoldWidgets=function(w){this.setOption("fadeFoldWidgets",w)},I.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},I.prototype.remove=function(w){this.selection.isEmpty()&&(w=="left"?this.selection.selectLeft():this.selection.selectRight());var _=this.getSelectionRange();if(this.getBehavioursEnabled()){var T=this.session,k=T.getState(_.start.row),R=T.getMode().transformAction(k,"deletion",this,T,_);if(_.end.column===0){var D=T.getTextRange(_);if(D[D.length-1]==`
219
+ `){var V=T.getLine(_.end.row);/^\s+$/.test(V)&&(_.end.column=V.length)}}R&&(_=R)}this.session.remove(_),this.clearSelection()},I.prototype.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},I.prototype.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},I.prototype.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},I.prototype.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var w=this.getSelectionRange();w.start.column==w.end.column&&w.start.row==w.end.row&&(w.end.column=0,w.end.row++),this.session.remove(w),this.clearSelection()},I.prototype.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var w=this.getCursorPosition();this.insert(`
220
+ `),this.moveCursorToPosition(w)},I.prototype.setGhostText=function(w,_){this.renderer.setGhostText(w,_)},I.prototype.removeGhostText=function(){this.renderer.removeGhostText()},I.prototype.transposeLetters=function(){if(this.selection.isEmpty()){var w=this.getCursorPosition(),_=w.column;if(_!==0){var T=this.session.getLine(w.row),k,R;_<T.length?(k=T.charAt(_)+T.charAt(_-1),R=new c(w.row,_-1,w.row,_+1)):(k=T.charAt(_-1)+T.charAt(_-2),R=new c(w.row,_-2,w.row,_)),this.session.replace(R,k),this.session.selection.moveToPosition(R.end)}}},I.prototype.toLowerCase=function(){var w=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var _=this.getSelectionRange(),T=this.session.getTextRange(_);this.session.replace(_,T.toLowerCase()),this.selection.setSelectionRange(w)},I.prototype.toUpperCase=function(){var w=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var _=this.getSelectionRange(),T=this.session.getTextRange(_);this.session.replace(_,T.toUpperCase()),this.selection.setSelectionRange(w)},I.prototype.indent=function(){var w=this.session,_=this.getSelectionRange();if(_.start.row<_.end.row){var T=this.$getSelectedRows();w.indentRows(T.first,T.last," ");return}else if(_.start.column<_.end.column){var k=w.getTextRange(_);if(!/^\s+$/.test(k)){var T=this.$getSelectedRows();w.indentRows(T.first,T.last," ");return}}var R=w.getLine(_.start.row),D=_.start,V=w.getTabSize(),B=w.documentToScreenColumn(D.row,D.column);if(this.session.getUseSoftTabs())var F=V-B%V,H=a.stringRepeat(" ",F);else{for(var F=B%V;R[_.start.column-1]==" "&&F;)_.start.column--,F--;this.selection.setSelectionRange(_),H=" "}return this.insert(H)},I.prototype.blockIndent=function(){var w=this.$getSelectedRows();this.session.indentRows(w.first,w.last," ")},I.prototype.blockOutdent=function(){var w=this.session.getSelection();this.session.outdentRows(w.getRange())},I.prototype.sortLines=function(){for(var w=this.$getSelectedRows(),_=this.session,T=[],k=w.first;k<=w.last;k++)T.push(_.getLine(k));T.sort(function(V,B){return V.toLowerCase()<B.toLowerCase()?-1:V.toLowerCase()>B.toLowerCase()?1:0});for(var R=new c(0,0,0,0),k=w.first;k<=w.last;k++){var D=_.getLine(k);R.start.row=k,R.end.row=k,R.end.column=D.length,_.replace(R,T[k-w.first])}},I.prototype.toggleCommentLines=function(){var w=this.session.getState(this.getCursorPosition().row),_=this.$getSelectedRows();this.session.getMode().toggleCommentLines(w,this.session,_.first,_.last)},I.prototype.toggleBlockComment=function(){var w=this.getCursorPosition(),_=this.session.getState(w.row),T=this.getSelectionRange();this.session.getMode().toggleBlockComment(_,this.session,T,w)},I.prototype.getNumberAt=function(w,_){var T=/[\-]?[0-9]+(?:\.[0-9]+)?/g;T.lastIndex=0;for(var k=this.session.getLine(w);T.lastIndex<_;){var R=T.exec(k);if(R.index<=_&&R.index+R[0].length>=_){var D={value:R[0],start:R.index,end:R.index+R[0].length};return D}}return null},I.prototype.modifyNumber=function(w){var _=this.selection.getCursor().row,T=this.selection.getCursor().column,k=new c(_,T-1,_,T),R=this.session.getTextRange(k);if(!isNaN(parseFloat(R))&&isFinite(R)){var D=this.getNumberAt(_,T);if(D){var V=D.value.indexOf(".")>=0?D.start+D.value.indexOf(".")+1:D.end,B=D.start+D.value.length-V,F=parseFloat(D.value);F*=Math.pow(10,B),V!==D.end&&T<V?w*=Math.pow(10,D.end-T-1):w*=Math.pow(10,D.end-T),F+=w,F/=Math.pow(10,B);var H=F.toFixed(B),U=new c(_,D.start,_,D.end);this.session.replace(U,H),this.moveCursorTo(_,Math.max(D.start+1,T+H.length-D.value.length))}}else this.toggleWord()},I.prototype.toggleWord=function(){var w=this.selection.getCursor().row,_=this.selection.getCursor().column;this.selection.selectWord();var T=this.getSelectedText(),k=this.selection.getWordRange().start.column,R=T.replace(/([a-z]+|[A-Z]+)(?=[A-Z_]|$)/g,"$1 ").split(/\s/),D=_-k-1;D<0&&(D=0);var V=0,B=0,F=this;T.match(/[A-Za-z0-9_]+/)&&R.forEach(function(re,j){B=V+re.length,D>=V&&D<=B&&(T=re,F.selection.clearSelection(),F.moveCursorTo(w,V+k),F.selection.selectTo(w,B+k)),V=B});for(var H=this.$toggleWordPairs,U,z=0;z<H.length;z++)for(var K=H[z],Y=0;Y<=1;Y++){var Q=+!Y,J=T.match(new RegExp("^\\s?_?("+a.escapeRegExp(K[Y])+")\\s?$","i"));if(J){var ne=T.match(new RegExp("([_]|^|\\s)("+a.escapeRegExp(J[1])+")($|\\s)","g"));ne&&(U=T.replace(new RegExp(a.escapeRegExp(K[Y]),"i"),function(re){var j=K[Q];return re.toUpperCase()==re?j=j.toUpperCase():re.charAt(0).toUpperCase()==re.charAt(0)&&(j=j.substr(0,0)+K[Q].charAt(0).toUpperCase()+j.substr(1)),j}),this.insert(U),U="")}}},I.prototype.findLinkAt=function(w,_){var T,k,R=this.session.getLine(w),D=R.split(/((?:https?|ftp):\/\/[\S]+)/),V=_;V<0&&(V=0);var B=0,F=0,H;try{for(var U=b(D),z=U.next();!z.done;z=U.next()){var K=z.value;if(F=B+K.length,V>=B&&V<=F&&K.match(/((?:https?|ftp):\/\/[\S]+)/)){H=K.replace(/[\s:.,'";}\]]+$/,"");break}B=F}}catch(Y){T={error:Y}}finally{try{z&&!z.done&&(k=U.return)&&k.call(U)}finally{if(T)throw T.error}}return H},I.prototype.openLink=function(){var w=this.selection.getCursor(),_=this.findLinkAt(w.row,w.column);return _&&window.open(_,"_blank"),_!=null},I.prototype.removeLines=function(){var w=this.$getSelectedRows();this.session.removeFullLines(w.first,w.last),this.clearSelection()},I.prototype.duplicateSelection=function(){var w=this.selection,_=this.session,T=w.getRange(),k=w.isBackwards();if(T.isEmpty()){var R=T.start.row;_.duplicateLines(R,R)}else{var D=k?T.start:T.end,V=_.insert(D,_.getTextRange(T));T.start=D,T.end=V,w.setSelectionRange(T,k)}},I.prototype.moveLinesDown=function(){this.$moveLines(1,!1)},I.prototype.moveLinesUp=function(){this.$moveLines(-1,!1)},I.prototype.moveText=function(w,_,T){return this.session.moveText(w,_,T)},I.prototype.copyLinesUp=function(){this.$moveLines(-1,!0)},I.prototype.copyLinesDown=function(){this.$moveLines(1,!0)},I.prototype.$moveLines=function(w,_){var T,k,R=this.selection;if(!R.inMultiSelectMode||this.inVirtualSelectionMode){var D=R.toOrientedRange();T=this.$getSelectedRows(D),k=this.session.$moveLines(T.first,T.last,_?0:w),_&&w==-1&&(k=0),D.moveBy(k,0),R.fromOrientedRange(D)}else{var V=R.rangeList.ranges;R.rangeList.detach(this.session),this.inVirtualSelectionMode=!0;for(var B=0,F=0,H=V.length,U=0;U<H;U++){var z=U;V[U].moveBy(B,0),T=this.$getSelectedRows(V[U]);for(var K=T.first,Y=T.last;++U<H;){F&&V[U].moveBy(F,0);var Q=this.$getSelectedRows(V[U]);if(_&&Q.first!=Y)break;if(!_&&Q.first>Y+1)break;Y=Q.last}for(U--,B=this.session.$moveLines(K,Y,_?0:w),_&&w==-1&&(z=U+1);z<=U;)V[z].moveBy(B,0),z++;_||(B=0),F+=B}R.fromOrientedRange(R.ranges[0]),R.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},I.prototype.$getSelectedRows=function(w){return w=(w||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(w.start.row),last:this.session.getRowFoldEnd(w.end.row)}},I.prototype.onCompositionStart=function(w){this.renderer.showComposition(w)},I.prototype.onCompositionUpdate=function(w){this.renderer.setCompositionText(w)},I.prototype.onCompositionEnd=function(){this.renderer.hideComposition()},I.prototype.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},I.prototype.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},I.prototype.isRowVisible=function(w){return w>=this.getFirstVisibleRow()&&w<=this.getLastVisibleRow()},I.prototype.isRowFullyVisible=function(w){return w>=this.renderer.getFirstFullyVisibleRow()&&w<=this.renderer.getLastFullyVisibleRow()},I.prototype.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},I.prototype.$moveByPage=function(w,_){var T=this.renderer,k=this.renderer.layerConfig,R=w*Math.floor(k.height/k.lineHeight);_===!0?this.selection.$moveSelection(function(){this.moveCursorBy(R,0)}):_===!1&&(this.selection.moveCursorBy(R,0),this.selection.clearSelection());var D=T.scrollTop;T.scrollBy(0,R*k.lineHeight),_!=null&&T.scrollCursorIntoView(null,.5),T.animateScrolling(D)},I.prototype.selectPageDown=function(){this.$moveByPage(1,!0)},I.prototype.selectPageUp=function(){this.$moveByPage(-1,!0)},I.prototype.gotoPageDown=function(){this.$moveByPage(1,!1)},I.prototype.gotoPageUp=function(){this.$moveByPage(-1,!1)},I.prototype.scrollPageDown=function(){this.$moveByPage(1)},I.prototype.scrollPageUp=function(){this.$moveByPage(-1)},I.prototype.scrollToRow=function(w){this.renderer.scrollToRow(w)},I.prototype.scrollToLine=function(w,_,T,k){this.renderer.scrollToLine(w,_,T,k)},I.prototype.centerSelection=function(){var w=this.getSelectionRange(),_={row:Math.floor(w.start.row+(w.end.row-w.start.row)/2),column:Math.floor(w.start.column+(w.end.column-w.start.column)/2)};this.renderer.alignCursor(_,.5)},I.prototype.getCursorPosition=function(){return this.selection.getCursor()},I.prototype.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},I.prototype.getSelectionRange=function(){return this.selection.getRange()},I.prototype.selectAll=function(){this.selection.selectAll()},I.prototype.clearSelection=function(){this.selection.clearSelection()},I.prototype.moveCursorTo=function(w,_){this.selection.moveCursorTo(w,_)},I.prototype.moveCursorToPosition=function(w){this.selection.moveCursorToPosition(w)},I.prototype.jumpToMatching=function(w,_){var T=this.getCursorPosition(),k=new y(this.session,T.row,T.column),R=k.getCurrentToken(),D=0;R&&R.type.indexOf("tag-name")!==-1&&(R=k.stepBackward());var V=R||k.stepForward();if(V){var B,F=!1,H={},U=T.column-V.start,z,K={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(V.value.match(/[{}()\[\]]/g)){for(;U<V.value.length&&!F;U++)if(K[V.value[U]])switch(z=K[V.value[U]]+"."+V.type.replace("rparen","lparen"),isNaN(H[z])&&(H[z]=0),V.value[U]){case"(":case"[":case"{":H[z]++;break;case")":case"]":case"}":H[z]--,H[z]===-1&&(B="bracket",F=!0);break}}else V.type.indexOf("tag-name")!==-1&&(isNaN(H[V.value])&&(H[V.value]=0),R.value==="<"&&D>1?H[V.value]++:R.value==="</"&&H[V.value]--,H[V.value]===-1&&(B="tag",F=!0));F||(R=V,D++,V=k.stepForward(),U=0)}while(V&&!F);if(B){var Y,Q;if(B==="bracket")Y=this.session.getBracketRange(T),Y||(Y=new c(k.getCurrentTokenRow(),k.getCurrentTokenColumn()+U-1,k.getCurrentTokenRow(),k.getCurrentTokenColumn()+U-1),Q=Y.start,(_||Q.row===T.row&&Math.abs(Q.column-T.column)<2)&&(Y=this.session.getBracketRange(Q)));else if(B==="tag"){if(!V||V.type.indexOf("tag-name")===-1)return;if(Y=new c(k.getCurrentTokenRow(),k.getCurrentTokenColumn()-2,k.getCurrentTokenRow(),k.getCurrentTokenColumn()-2),Y.compare(T.row,T.column)===0){var J=this.session.getMatchingTags(T);J&&(J.openTag.contains(T.row,T.column)?(Y=J.closeTag,Q=Y.start):(Y=J.openTag,J.closeTag.start.row===T.row&&J.closeTag.start.column===T.column?Q=Y.end:Q=Y.start))}Q=Q||Y.start}Q=Y&&Y.cursor||Q,Q&&(w?Y&&_?this.selection.setRange(Y):Y&&Y.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(Q.row,Q.column):this.selection.moveTo(Q.row,Q.column))}}},I.prototype.gotoLine=function(w,_,T){this.selection.clearSelection(),this.session.unfold({row:w-1,column:_||0}),this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(w-1,_||0),this.isRowFullyVisible(w-1)||this.scrollToLine(w-1,!0,T)},I.prototype.navigateTo=function(w,_){this.selection.moveTo(w,_)},I.prototype.navigateUp=function(w){if(this.selection.isMultiLine()&&!this.selection.isBackwards()){var _=this.selection.anchor.getPosition();return this.moveCursorToPosition(_)}this.selection.clearSelection(),this.selection.moveCursorBy(-w||-1,0)},I.prototype.navigateDown=function(w){if(this.selection.isMultiLine()&&this.selection.isBackwards()){var _=this.selection.anchor.getPosition();return this.moveCursorToPosition(_)}this.selection.clearSelection(),this.selection.moveCursorBy(w||1,0)},I.prototype.navigateLeft=function(w){if(this.selection.isEmpty())for(w=w||1;w--;)this.selection.moveCursorLeft();else{var _=this.getSelectionRange().start;this.moveCursorToPosition(_)}this.clearSelection()},I.prototype.navigateRight=function(w){if(this.selection.isEmpty())for(w=w||1;w--;)this.selection.moveCursorRight();else{var _=this.getSelectionRange().end;this.moveCursorToPosition(_)}this.clearSelection()},I.prototype.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},I.prototype.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},I.prototype.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},I.prototype.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},I.prototype.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},I.prototype.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},I.prototype.replace=function(w,_){_&&this.$search.set(_);var T=this.$search.find(this.session),k=0;return T&&(this.$tryReplace(T,w)&&(k=1),this.selection.setSelectionRange(T),this.renderer.scrollSelectionIntoView(T.start,T.end)),k},I.prototype.replaceAll=function(w,_){_&&this.$search.set(_);var T=this.$search.findAll(this.session),k=0;if(!T.length)return k;var R=this.getSelectionRange();this.selection.moveTo(0,0);for(var D=T.length-1;D>=0;--D)this.$tryReplace(T[D],w)&&k++;return this.selection.setSelectionRange(R),k},I.prototype.$tryReplace=function(w,_){var T=this.session.getTextRange(w);return _=this.$search.replace(T,_),_!==null?(w.end=this.session.replace(w,_),w):null},I.prototype.getLastSearchOptions=function(){return this.$search.getOptions()},I.prototype.find=function(w,_,T){_||(_={}),typeof w=="string"||w instanceof RegExp?_.needle=w:typeof w=="object"&&C.mixin(_,w);var k=this.selection.getRange();_.needle==null&&(w=this.session.getTextRange(k)||this.$search.$options.needle,w||(k=this.session.getWordRange(k.start.row,k.start.column),w=this.session.getTextRange(k)),this.$search.set({needle:w})),this.$search.set(_),_.start||this.$search.set({start:k});var R=this.$search.find(this.session);if(_.preventScroll)return R;if(R)return this.revealRange(R,T),R;_.backwards?k.start=k.end:k.end=k.start,this.selection.setRange(k)},I.prototype.findNext=function(w,_){this.find({skipCurrent:!0,backwards:!1},w,_)},I.prototype.findPrevious=function(w,_){this.find(w,{skipCurrent:!0,backwards:!0},_)},I.prototype.revealRange=function(w,_){this.session.unfold(w),this.selection.setSelectionRange(w);var T=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(w.start,w.end,.5),_!==!1&&this.renderer.animateScrolling(T)},I.prototype.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},I.prototype.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},I.prototype.destroy=function(){this.$toDestroy&&(this.$toDestroy.forEach(function(w){w.destroy()}),this.$toDestroy=null),this.$mouseHandler&&this.$mouseHandler.destroy(),this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy(),this._$emitInputEvent&&this._$emitInputEvent.cancel(),this.removeAllListeners()},I.prototype.setAutoScrollEditorIntoView=function(w){if(w){var _,T=this,k=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var R=this.$scrollAnchor;R.style.cssText="position:absolute",this.container.insertBefore(R,this.container.firstChild);var D=this.on("changeSelection",function(){k=!0}),V=this.renderer.on("beforeRender",function(){k&&(_=T.renderer.container.getBoundingClientRect())}),B=this.renderer.on("afterRender",function(){if(k&&_&&(T.isFocused()||T.searchBox&&T.searchBox.isFocused())){var F=T.renderer,H=F.$cursorLayer.$pixelPos,U=F.layerConfig,z=H.top-U.offset;H.top>=0&&z+_.top<0?k=!0:H.top<U.height&&H.top+_.top+U.lineHeight>window.innerHeight?k=!1:k=null,k!=null&&(R.style.top=z+"px",R.style.left=H.left+"px",R.style.height=U.lineHeight+"px",R.scrollIntoView(k)),k=_=null}});this.setAutoScrollEditorIntoView=function(F){F||(delete this.setAutoScrollEditorIntoView,this.off("changeSelection",D),this.renderer.off("afterRender",B),this.renderer.off("beforeRender",V))}}},I.prototype.$resetCursorStyle=function(){var w=this.$cursorStyle||"ace",_=this.renderer.$cursorLayer;_&&(_.setSmoothBlinking(/smooth/.test(w)),_.isBlinking=!this.$readOnly&&w!="wide",A.setCssClass(_.element,"ace_slim-cursors",/slim/.test(w)))},I.prototype.prompt=function(w,_,T){var k=this;p.loadModule("ace/ext/prompt",function(R){R.prompt(k,w,_,T)})},I}();x.$uid=0,x.prototype.curOp=null,x.prototype.prevOp={},x.prototype.$mergeableCommands=["backspace","del","insertstring"],x.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"],["&&","||"],["==","!="]],C.implement(x.prototype,h),p.defineOptions(x.prototype,"editor",{selectionStyle:{set:function(I){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:I})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(I){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(I){var w=this;this.textInput.setReadOnly(I),this.$resetCursorStyle(),this.$readOnlyCallback||(this.$readOnlyCallback=function(T){var k=!1;if(T&&T.type=="keydown"){if(k=T&&T.key&&T.key.length==1&&!T.ctrlKey&&!T.metaKey,!k)return}else T&&T.type!=="exec"&&(k=!0);if(k){w.hoverTooltip||(w.hoverTooltip=new O);var R=A.createElement("div");R.textContent=$("editor.tooltip.disable-editing","Editing is disabled"),w.hoverTooltip.isOpen||w.hoverTooltip.showForRange(w,w.getSelectionRange(),R)}else w.hoverTooltip&&w.hoverTooltip.isOpen&&w.hoverTooltip.hide()});var _=this.textInput.getElement();I?(S.addListener(_,"keydown",this.$readOnlyCallback,this),this.commands.on("exec",this.$readOnlyCallback),this.commands.on("commandUnavailable",this.$readOnlyCallback)):(S.removeListener(_,"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(I){this.textInput.setCopyWithEmptySelection(I)},initialValue:!1},cursorStyle:{set:function(I){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(I){this.setAutoScrollEditorIntoView(I)}},keyboardHandler:{set:function(I){this.setKeyboardHandler(I)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function(I){this.session.setValue(I)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function(I){this.setSession(I)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function(I){this.renderer.$gutterLayer.setShowLineNumbers(I),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),I&&this.$relativeLineNumbers?L.attach(this):L.detach(this)},initialValue:!0},relativeLineNumbers:{set:function(I){this.$showLineNumbers&&I?L.attach(this):L.detach(this)}},placeholder:{set:function(I){this.$updatePlaceholder||(this.$updatePlaceholder=(function(){var w=this.session&&(this.renderer.$composition||this.session.getLength()>1||this.session.getLine(0).length>0);if(w&&this.renderer.placeholderNode)this.renderer.off("afterRender",this.$updatePlaceholder),A.removeCssClass(this.container,"ace_hasPlaceholder"),this.renderer.placeholderNode.remove(),this.renderer.placeholderNode=null;else if(!w&&!this.renderer.placeholderNode){this.renderer.on("afterRender",this.$updatePlaceholder),A.addCssClass(this.container,"ace_hasPlaceholder");var _=A.createElement("div");_.className="ace_placeholder",_.textContent=this.$placeholder||"",this.renderer.placeholderNode=_,this.renderer.content.appendChild(this.renderer.placeholderNode)}else!w&&this.renderer.placeholderNode&&(this.renderer.placeholderNode.textContent=this.$placeholder||"")}).bind(this),this.on("input",this.$updatePlaceholder)),this.$updatePlaceholder()}},enableKeyboardAccessibility:{set:function(I){var w={name:"blurTextInput",description:"Set focus to the editor content div to allow tabbing through the page",bindKey:"Esc",exec:function(k){k.blur(),k.renderer.scroller.focus()},readOnly:!0},_=function(k){if(k.target==this.renderer.scroller&&k.keyCode===M.enter){k.preventDefault();var R=this.getCursorPosition().row;this.isRowVisible(R)||this.scrollToLine(R,!0,!0),this.focus()}},T;I?(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",$("editor.scroller.aria-roledescription","editor")),this.renderer.scroller.classList.add(this.renderer.keyboardFocusClassName),this.renderer.scroller.setAttribute("aria-label",$("editor.scroller.aria-label","Editor content, press Enter to start editing, press Escape to exit")),this.renderer.scroller.addEventListener("keyup",_.bind(this)),this.commands.addCommand(w),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",$("editor.gutter.aria-roledescription","editor gutter")),this.renderer.$gutter.setAttribute("aria-label",$("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),T||(T=new m(this)),T.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",_.bind(this)),this.commands.removeCommand(w),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),T&&T.removeListener())},initialValue:!1},textInputAriaLabel:{set:function(I){this.$textInputAriaLabel=I},initialValue:""},enableMobileMenu:{set:function(I){this.$enableMobileMenu=I},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",tooltipFollowsMouse:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",navigateWithinSoftTabs:"session",tabSize:"session",wrap:"session",indentedSoftWrap:"session",foldStyle:"session",mode:"session"});var L={getText:function(I,w){return(Math.abs(I.selection.lead.row-w)||w+1+(w<9?"·":""))+""},getWidth:function(I,w,_){return Math.max(w.toString().length,(_.lastRow+1).toString().length,2)*_.characterWidth},update:function(I,w){w.renderer.$loop.schedule(w.renderer.CHANGE_GUTTER)},attach:function(I){I.renderer.$gutterLayer.$renderer=this,I.on("changeSelection",this.update),this.update(null,I)},detach:function(I){I.renderer.$gutterLayer.$renderer==this&&(I.renderer.$gutterLayer.$renderer=null),I.off("changeSelection",this.update),this.update(null,I)}};d.Editor=x}),ace.define("ace/layer/lines",["require","exports","module","ace/lib/dom"],function(l,d,E){var b=l("../lib/dom"),C=function(){function A(a,g){this.element=a,this.canvasHeight=g||5e5,this.element.style.height=this.canvasHeight*2+"px",this.cells=[],this.cellCache=[],this.$offsetCoefficient=0}return A.prototype.moveContainer=function(a){b.translate(this.element,0,-(a.firstRowScreen*a.lineHeight%this.canvasHeight)-a.offset*this.$offsetCoefficient)},A.prototype.pageChanged=function(a,g){return Math.floor(a.firstRowScreen*a.lineHeight/this.canvasHeight)!==Math.floor(g.firstRowScreen*g.lineHeight/this.canvasHeight)},A.prototype.computeLineTop=function(a,g,n){var s=g.firstRowScreen*g.lineHeight,o=Math.floor(s/this.canvasHeight),r=n.documentToScreenRow(a,0)*g.lineHeight;return r-o*this.canvasHeight},A.prototype.computeLineHeight=function(a,g,n){return g.lineHeight*n.getRowLineCount(a)},A.prototype.getLength=function(){return this.cells.length},A.prototype.get=function(a){return this.cells[a]},A.prototype.shift=function(){this.$cacheCell(this.cells.shift())},A.prototype.pop=function(){this.$cacheCell(this.cells.pop())},A.prototype.push=function(a){if(Array.isArray(a)){this.cells.push.apply(this.cells,a);for(var g=b.createFragment(this.element),n=0;n<a.length;n++)g.appendChild(a[n].element);this.element.appendChild(g)}else this.cells.push(a),this.element.appendChild(a.element)},A.prototype.unshift=function(a){if(Array.isArray(a)){this.cells.unshift.apply(this.cells,a);for(var g=b.createFragment(this.element),n=0;n<a.length;n++)g.appendChild(a[n].element);this.element.firstChild?this.element.insertBefore(g,this.element.firstChild):this.element.appendChild(g)}else this.cells.unshift(a),this.element.insertAdjacentElement("afterbegin",a.element)},A.prototype.last=function(){return this.cells.length?this.cells[this.cells.length-1]:null},A.prototype.$cacheCell=function(a){a&&(a.element.remove(),this.cellCache.push(a))},A.prototype.createCell=function(a,g,n,s){var o=this.cellCache.pop();if(!o){var r=b.createElement("div");s&&s(r),this.element.appendChild(r),o={element:r,text:"",row:a}}return o.row=a,o},A}();d.Lines=C}),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(l,d,E){var b=l("../lib/dom"),C=l("../lib/oop"),A=l("../lib/lang"),a=l("../lib/event_emitter").EventEmitter,g=l("./lines").Lines,n=l("../config").nls,s=function(){function r(t){this.element=b.createElement("div"),this.element.className="ace_layer ace_gutter-layer",t.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 r.prototype.setSession=function(t){this.session&&this.session.off("change",this.$updateAnnotations),this.session=t,t&&t.on("change",this.$updateAnnotations)},r.prototype.addGutterDecoration=function(t,i){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(t,i)},r.prototype.removeGutterDecoration=function(t,i){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(t,i)},r.prototype.setAnnotations=function(t){this.$annotations=[];for(var i=0;i<t.length;i++){var c=t[i],h=c.row,f=this.$annotations[h];f||(f=this.$annotations[h]={text:[],type:[],displayText:[]});var v=c.text,p=c.text,y=c.type;v=v?A.escapeHTML(v):c.html||"",p=p||c.html||"",f.text.indexOf(v)===-1&&(f.text.push(v),f.type.push(y),f.displayText.push(p));var m=c.className;m?f.className=m:y==="error"?f.className=" ace_error":y==="security"&&!/\bace_error\b/.test(f.className)?f.className=" ace_security":y==="warning"&&!/\bace_(error|security)\b/.test(f.className)?f.className=" ace_warning":y==="info"&&!f.className?f.className=" ace_info":y==="hint"&&!f.className&&(f.className=" ace_hint")}},r.prototype.$updateAnnotations=function(t){if(this.$annotations.length){var i=t.start.row,c=t.end.row-i;if(c!==0)if(t.action=="remove")this.$annotations.splice(i,c+1,null);else{var h=new Array(c+1);h.unshift(i,1),this.$annotations.splice.apply(this.$annotations,h)}}},r.prototype.update=function(t){this.config=t;var i=this.session,c=t.firstRow,h=Math.min(t.lastRow+t.gutterOffset,i.getLength()-1);this.oldLastRow=h,this.config=t,this.$lines.moveContainer(t),this.$updateCursorRow();for(var f=i.getNextFoldLine(c),v=f?f.start.row:1/0,p=null,y=-1,m=c;;){if(m>v&&(m=f.end.row+1,f=i.getNextFoldLine(m,f),v=f?f.start.row:1/0),m>h){for(;this.$lines.getLength()>y+1;)this.$lines.pop();break}p=this.$lines.get(++y),p?p.row=m:(p=this.$lines.createCell(m,t,this.session,o),this.$lines.push(p)),this.$renderCell(p,t,f,m),m++}this._signal("afterRender"),this.$updateGutterWidth(t)},r.prototype.$updateGutterWidth=function(t){var i=this.session,c=i.gutterRenderer||this.$renderer,h=i.$firstLineNumber,f=this.$lines.last()?this.$lines.last().text:"";(this.$fixedWidth||i.$useWrapMode)&&(f=i.getLength()+h-1);var v=c?c.getWidth(i,f,t):f.toString().length*t.characterWidth,p=this.$padding||this.$computePadding();v+=p.left+p.right,v!==this.gutterWidth&&!isNaN(v)&&(this.gutterWidth=v,this.element.parentNode.style.width=this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._signal("changeGutterWidth",v))},r.prototype.$updateCursorRow=function(){if(this.$highlightGutterLine){var t=this.session.selection.getCursor();this.$cursorRow!==t.row&&(this.$cursorRow=t.row)}},r.prototype.updateLineHighlight=function(){if(this.$highlightGutterLine){var t=this.session.selection.cursor.row;if(this.$cursorRow=t,!(this.$cursorCell&&this.$cursorCell.row==t)){this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ",""));var i=this.$lines.cells;this.$cursorCell=null;for(var c=0;c<i.length;c++){var h=i[c];if(h.row>=this.$cursorRow){if(h.row>this.$cursorRow){var f=this.session.getFoldLine(this.$cursorRow);if(c>0&&f&&f.start.row==i[c-1].row)h=i[c-1];else break}h.element.className="ace_gutter-active-line "+h.element.className,this.$cursorCell=h;break}}}}},r.prototype.scrollLines=function(t){var i=this.config;if(this.config=t,this.$updateCursorRow(),this.$lines.pageChanged(i,t))return this.update(t);this.$lines.moveContainer(t);var c=Math.min(t.lastRow+t.gutterOffset,this.session.getLength()-1),h=this.oldLastRow;if(this.oldLastRow=c,!i||h<t.firstRow)return this.update(t);if(c<i.firstRow)return this.update(t);if(i.firstRow<t.firstRow)for(var f=this.session.getFoldedRowCount(i.firstRow,t.firstRow-1);f>0;f--)this.$lines.shift();if(h>c)for(var f=this.session.getFoldedRowCount(c+1,h);f>0;f--)this.$lines.pop();t.firstRow<i.firstRow&&this.$lines.unshift(this.$renderLines(t,t.firstRow,i.firstRow-1)),c>h&&this.$lines.push(this.$renderLines(t,h+1,c)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(t)},r.prototype.$renderLines=function(t,i,c){for(var h=[],f=i,v=this.session.getNextFoldLine(f),p=v?v.start.row:1/0;f>p&&(f=v.end.row+1,v=this.session.getNextFoldLine(f,v),p=v?v.start.row:1/0),!(f>c);){var y=this.$lines.createCell(f,t,this.session,o);this.$renderCell(y,t,v,f),h.push(y),f++}return h},r.prototype.$renderCell=function(t,i,c,h){var f=t.element,v=this.session,p=f.childNodes[0],y=f.childNodes[1],m=f.childNodes[2],$=m.firstChild,N=v.$firstLineNumber,M=v.$breakpoints,S=v.$decorations,O=v.gutterRenderer||this.$renderer,x=this.$showFoldWidgets&&v.foldWidgets,L=c?c.start.row:Number.MAX_VALUE,I=i.lineHeight+"px",w=this.$useSvgGutterIcons?"ace_gutter-cell_svg-icons ":"ace_gutter-cell ",_=this.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",T=(O?O.getText(v,h):h+N).toString();if(this.$highlightGutterLine&&(h==this.$cursorRow||c&&h<this.$cursorRow&&h>=L&&this.$cursorRow<=c.end.row)&&(w+="ace_gutter-active-line ",this.$cursorCell!=t&&(this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ","")),this.$cursorCell=t)),M[h]&&(w+=M[h]),S[h]&&(w+=S[h]),this.$annotations[h]&&h!==L&&(w+=this.$annotations[h].className),x){var k=x[h];k==null&&(k=x[h]=v.getFoldWidget(h))}if(k){var R="ace_fold-widget ace_"+k,D=k=="start"&&h==L&&h<c.end.row;if(D){R+=" ace_closed";for(var V="",B=!1,F=h+1;F<=c.end.row;F++)if(this.$annotations[F]){if(this.$annotations[F].className===" ace_error"){B=!0,V=" ace_error_fold";break}this.$annotations[F].className===" ace_security"?(B=!0,V=" ace_security_fold"):this.$annotations[F].className===" ace_warning"&&V!==" ace_security_fold"&&(B=!0,V=" ace_warning_fold")}w+=V}else R+=" ace_open";y.className!=R&&(y.className=R),b.setStyle(y.style,"height",I),b.setStyle(y.style,"display","inline-block"),y.setAttribute("role","button"),y.setAttribute("tabindex","-1");var H=v.getFoldWidgetRange(h);H?y.setAttribute("aria-label",n("gutter.code-folding.range.aria-label","Toggle code folding, rows $0 through $1",[H.start.row+1,H.end.row+1])):c?y.setAttribute("aria-label",n("gutter.code-folding.closed.aria-label","Toggle code folding, rows $0 through $1",[c.start.row+1,c.end.row+1])):y.setAttribute("aria-label",n("gutter.code-folding.open.aria-label","Toggle code folding, row $0",[h+1])),D?(y.setAttribute("aria-expanded","false"),y.setAttribute("title",n("gutter.code-folding.closed.title","Unfold code"))):(y.setAttribute("aria-expanded","true"),y.setAttribute("title",n("gutter.code-folding.open.title","Fold code")))}else y&&(b.setStyle(y.style,"display","none"),y.setAttribute("tabindex","0"),y.removeAttribute("role"),y.removeAttribute("aria-label"));if(B&&this.$showFoldedAnnotations){m.className="ace_gutter_annotation",$.className=_,$.className+=V,b.setStyle($.style,"height",I),b.setStyle(m.style,"display","block"),b.setStyle(m.style,"height",I);var U;switch(V){case" ace_error_fold":U=n("gutter.annotation.aria-label.error","Error, read annotations row $0",[T]);break;case" ace_security_fold":U=n("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[T]);break;case" ace_warning_fold":U=n("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[T]);break}m.setAttribute("aria-label",U),m.setAttribute("tabindex","-1"),m.setAttribute("role","button")}else if(this.$annotations[h]){m.className="ace_gutter_annotation",$.className=_,this.$useSvgGutterIcons?$.className+=this.$annotations[h].className:f.classList.add(this.$annotations[h].className.replace(" ","")),b.setStyle($.style,"height",I),b.setStyle(m.style,"display","block"),b.setStyle(m.style,"height",I);var U;switch(this.$annotations[h].className){case" ace_error":U=n("gutter.annotation.aria-label.error","Error, read annotations row $0",[T]);break;case" ace_security":U=n("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[T]);break;case" ace_warning":U=n("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[T]);break;case" ace_info":U=n("gutter.annotation.aria-label.info","Info, read annotations row $0",[T]);break;case" ace_hint":U=n("gutter.annotation.aria-label.hint","Suggestion, read annotations row $0",[T]);break}m.setAttribute("aria-label",U),m.setAttribute("tabindex","-1"),m.setAttribute("role","button")}else b.setStyle(m.style,"display","none"),m.removeAttribute("aria-label"),m.removeAttribute("role"),m.setAttribute("tabindex","0");return T!==p.data&&(p.data=T),f.className!=w&&(f.className=w),b.setStyle(t.element.style,"height",this.$lines.computeLineHeight(h,i,v)+"px"),b.setStyle(t.element.style,"top",this.$lines.computeLineTop(h,i,v)+"px"),t.text=T,m.style.display==="none"&&y.style.display==="none"?t.element.setAttribute("aria-hidden",!0):t.element.setAttribute("aria-hidden",!1),t},r.prototype.setHighlightGutterLine=function(t){this.$highlightGutterLine=t},r.prototype.setShowLineNumbers=function(t){this.$renderer=!t&&{getWidth:function(){return 0},getText:function(){return""}}},r.prototype.getShowLineNumbers=function(){return this.$showLineNumbers},r.prototype.setShowFoldWidgets=function(t){t?b.addCssClass(this.element,"ace_folding-enabled"):b.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=t,this.$padding=null},r.prototype.getShowFoldWidgets=function(){return this.$showFoldWidgets},r.prototype.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var t=b.computedStyle(this.element.firstChild);return this.$padding={},this.$padding.left=(parseInt(t.borderLeftWidth)||0)+(parseInt(t.paddingLeft)||0)+1,this.$padding.right=(parseInt(t.borderRightWidth)||0)+(parseInt(t.paddingRight)||0),this.$padding},r.prototype.getRegion=function(t){var i=this.$padding||this.$computePadding(),c=this.element.getBoundingClientRect();if(t.x<i.left+c.left)return"markers";if(this.$showFoldWidgets&&t.x>c.right-i.right)return"foldWidgets"},r}();s.prototype.$fixedWidth=!1,s.prototype.$highlightGutterLine=!0,s.prototype.$renderer="",s.prototype.$showLineNumbers=!0,s.prototype.$showFoldWidgets=!0,C.implement(s.prototype,a);function o(r){var t=document.createTextNode("");r.appendChild(t);var i=b.createElement("span");r.appendChild(i);var c=b.createElement("span");r.appendChild(c);var h=b.createElement("span");return c.appendChild(h),r}d.Gutter=s}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(l,d,E){var b=l("../range").Range,C=l("../lib/dom"),A=function(){function g(n){this.element=C.createElement("div"),this.element.className="ace_layer ace_marker-layer",n.appendChild(this.element)}return g.prototype.setPadding=function(n){this.$padding=n},g.prototype.setSession=function(n){this.session=n},g.prototype.setMarkers=function(n){this.markers=n},g.prototype.elt=function(n,s){var o=this.i!=-1&&this.element.childNodes[this.i];o?this.i++:(o=document.createElement("div"),this.element.appendChild(o),this.i=-1),o.style.cssText=s,o.className=n},g.prototype.update=function(n){if(n){this.config=n,this.i=0;var s;for(var o in this.markers){var r=this.markers[o];if(!r.range){r.update(s,this,this.session,n);continue}var t=r.range.clipRows(n.firstRow,n.lastRow);if(!t.isEmpty())if(t=t.toScreenRange(this.session),r.renderer){var i=this.$getTop(t.start.row,n),c=this.$padding+t.start.column*n.characterWidth;r.renderer(s,t,c,i,n)}else r.type=="fullLine"?this.drawFullLineMarker(s,t,r.clazz,n):r.type=="screenLine"?this.drawScreenLineMarker(s,t,r.clazz,n):t.isMultiLine()?r.type=="text"?this.drawTextMarker(s,t,r.clazz,n):this.drawMultiLineMarker(s,t,r.clazz,n):this.drawSingleLineMarker(s,t,r.clazz+" ace_start ace_br15",n)}if(this.i!=-1)for(;this.i<this.element.childElementCount;)this.element.removeChild(this.element.lastChild)}},g.prototype.$getTop=function(n,s){return(n-s.firstRowScreen)*s.lineHeight},g.prototype.drawTextMarker=function(n,s,o,r,t){for(var i=this.session,c=s.start.row,h=s.end.row,f=c,v=0,p=0,y=i.getScreenLastRowColumn(f),m=new b(f,s.start.column,f,p);f<=h;f++)m.start.row=m.end.row=f,m.start.column=f==c?s.start.column:i.getRowWrapIndent(f),m.end.column=y,v=p,p=y,y=f+1<h?i.getScreenLastRowColumn(f+1):f==h?0:s.end.column,this.drawSingleLineMarker(n,m,o+(f==c?" ace_start":"")+" ace_br"+a(f==c||f==c+1&&s.start.column,v<p,p>y,f==h),r,f==h?0:1,t)},g.prototype.drawMultiLineMarker=function(n,s,o,r,t){var i=this.$padding,c=r.lineHeight,h=this.$getTop(s.start.row,r),f=i+s.start.column*r.characterWidth;if(t=t||"",this.session.$bidiHandler.isBidiRow(s.start.row)){var v=s.clone();v.end.row=v.start.row,v.end.column=this.session.getLine(v.start.row).length,this.drawBidiSingleLineMarker(n,v,o+" ace_br1 ace_start",r,null,t)}else this.elt(o+" ace_br1 ace_start","height:"+c+"px;right:"+i+"px;top:"+h+"px;left:"+f+"px;"+(t||""));if(this.session.$bidiHandler.isBidiRow(s.end.row)){var v=s.clone();v.start.row=v.end.row,v.start.column=0,this.drawBidiSingleLineMarker(n,v,o+" ace_br12",r,null,t)}else{h=this.$getTop(s.end.row,r);var p=s.end.column*r.characterWidth;this.elt(o+" ace_br12","height:"+c+"px;width:"+p+"px;top:"+h+"px;left:"+i+"px;"+(t||""))}if(c=(s.end.row-s.start.row-1)*r.lineHeight,!(c<=0)){h=this.$getTop(s.start.row+1,r);var y=(s.start.column?1:0)|(s.end.column?0:8);this.elt(o+(y?" ace_br"+y:""),"height:"+c+"px;right:"+i+"px;top:"+h+"px;left:"+i+"px;"+(t||""))}},g.prototype.drawSingleLineMarker=function(n,s,o,r,t,i){if(this.session.$bidiHandler.isBidiRow(s.start.row))return this.drawBidiSingleLineMarker(n,s,o,r,t,i);var c=r.lineHeight,h=(s.end.column+(t||0)-s.start.column)*r.characterWidth,f=this.$getTop(s.start.row,r),v=this.$padding+s.start.column*r.characterWidth;this.elt(o,"height:"+c+"px;width:"+h+"px;top:"+f+"px;left:"+v+"px;"+(i||""))},g.prototype.drawBidiSingleLineMarker=function(n,s,o,r,t,i){var c=r.lineHeight,h=this.$getTop(s.start.row,r),f=this.$padding,v=this.session.$bidiHandler.getSelections(s.start.column,s.end.column);v.forEach(function(p){this.elt(o,"height:"+c+"px;width:"+(p.width+(t||0))+"px;top:"+h+"px;left:"+(f+p.left)+"px;"+(i||""))},this)},g.prototype.drawFullLineMarker=function(n,s,o,r,t){var i=this.$getTop(s.start.row,r),c=r.lineHeight;s.start.row!=s.end.row&&(c+=this.$getTop(s.end.row,r)-i),this.elt(o,"height:"+c+"px;top:"+i+"px;left:0;right:0;"+(t||""))},g.prototype.drawScreenLineMarker=function(n,s,o,r,t){var i=this.$getTop(s.start.row,r),c=r.lineHeight;this.elt(o,"height:"+c+"px;top:"+i+"px;left:0;right:0;"+(t||""))},g}();A.prototype.$padding=0;function a(g,n,s,o){return(g?1:0)|(n?2:0)|(s?4:0)|(o?8:0)}d.Marker=A}),ace.define("ace/layer/text_util",["require","exports","module"],function(l,d,E){var b=new Set(["text","rparen","lparen"]);d.isTextToken=function(C){return b.has(C)}}),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(l,d,E){var b=l("../lib/oop"),C=l("../lib/dom"),A=l("../lib/lang"),a=l("./lines").Lines,g=l("../lib/event_emitter").EventEmitter,n=l("../config").nls,s=l("./text_util").isTextToken,o=function(){function r(t){this.dom=C,this.element=this.dom.createElement("div"),this.element.className="ace_layer ace_text-layer",t.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this),this.$lines=new a(this.element)}return r.prototype.$updateEolChar=function(){var t=this.session.doc,i=t.getNewLineCharacter()==`
221
+ `&&t.getNewLineMode()!="windows",c=i?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=c)return this.EOL_CHAR=c,!0},r.prototype.setPadding=function(t){this.$padding=t,this.element.style.margin="0 "+t+"px"},r.prototype.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},r.prototype.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},r.prototype.$setFontMetrics=function(t){this.$fontMetrics=t,this.$fontMetrics.on("changeCharacterSize",(function(i){this._signal("changeCharacterSize",i)}).bind(this)),this.$pollSizeChanges()},r.prototype.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},r.prototype.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},r.prototype.setSession=function(t){this.session=t,t&&this.$computeTabString()},r.prototype.setShowInvisibles=function(t){return this.showInvisibles==t?!1:(this.showInvisibles=t,typeof t=="string"?(this.showSpaces=/tab/i.test(t),this.showTabs=/space/i.test(t),this.showEOL=/eol/i.test(t)):this.showSpaces=this.showTabs=this.showEOL=t,this.$computeTabString(),!0)},r.prototype.setDisplayIndentGuides=function(t){return this.displayIndentGuides==t?!1:(this.displayIndentGuides=t,this.$computeTabString(),!0)},r.prototype.setHighlightIndentGuides=function(t){return this.$highlightIndentGuides===t?!1:(this.$highlightIndentGuides=t,t)},r.prototype.$computeTabString=function(){var t=this.session.getTabSize();this.tabSize=t;for(var i=this.$tabStrings=[0],c=1;c<t+1;c++)if(this.showTabs){var h=this.dom.createElement("span");h.className="ace_invisible ace_invisible_tab",h.textContent=A.stringRepeat(this.TAB_CHAR,c),i.push(h)}else i.push(this.dom.createTextNode(A.stringRepeat(" ",c),this.element));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;var f="ace_indent-guide",v=this.showSpaces?" ace_invisible ace_invisible_space":"",p=this.showSpaces?A.stringRepeat(this.SPACE_CHAR,this.tabSize):A.stringRepeat(" ",this.tabSize),y=this.showTabs?" ace_invisible ace_invisible_tab":"",m=this.showTabs?A.stringRepeat(this.TAB_CHAR,this.tabSize):p,h=this.dom.createElement("span");h.className=f+v,h.textContent=p,this.$tabStrings[" "]=h;var h=this.dom.createElement("span");h.className=f+y,h.textContent=m,this.$tabStrings[" "]=h}},r.prototype.updateLines=function(t,i,c){if(this.config.lastRow!=t.lastRow||this.config.firstRow!=t.firstRow)return this.update(t);this.config=t;for(var h=Math.max(i,t.firstRow),f=Math.min(c,t.lastRow),v=this.element.childNodes,p=0,m=t.firstRow;m<h;m++){var $=this.session.getFoldLine(m);if($)if($.containsRow(h)){h=$.start.row;break}else m=$.end.row;p++}for(var y=!1,m=h,$=this.session.getNextFoldLine(m),N=$?$.start.row:1/0;m>N&&(m=$.end.row+1,$=this.session.getNextFoldLine(m,$),N=$?$.start.row:1/0),!(m>f);){var M=v[p++];if(M){this.dom.removeChildren(M),this.$renderLine(M,m,m==N?$:!1),y&&(M.style.top=this.$lines.computeLineTop(m,t,this.session)+"px");var S=t.lineHeight*this.session.getRowLength(m)+"px";M.style.height!=S&&(y=!0,M.style.height=S)}m++}if(y)for(;p<this.$lines.cells.length;){var O=this.$lines.cells[p++];O.element.style.top=this.$lines.computeLineTop(O.row,t,this.session)+"px"}},r.prototype.scrollLines=function(t){var i=this.config;if(this.config=t,this.$lines.pageChanged(i,t))return this.update(t);this.$lines.moveContainer(t);var c=t.lastRow,h=i?i.lastRow:-1;if(!i||h<t.firstRow)return this.update(t);if(c<i.firstRow)return this.update(t);if(!i||i.lastRow<t.firstRow)return this.update(t);if(t.lastRow<i.firstRow)return this.update(t);if(i.firstRow<t.firstRow)for(var f=this.session.getFoldedRowCount(i.firstRow,t.firstRow-1);f>0;f--)this.$lines.shift();if(i.lastRow>t.lastRow)for(var f=this.session.getFoldedRowCount(t.lastRow+1,i.lastRow);f>0;f--)this.$lines.pop();t.firstRow<i.firstRow&&this.$lines.unshift(this.$renderLinesFragment(t,t.firstRow,i.firstRow-1)),t.lastRow>i.lastRow&&this.$lines.push(this.$renderLinesFragment(t,i.lastRow+1,t.lastRow)),this.$highlightIndentGuide()},r.prototype.$renderLinesFragment=function(t,i,c){for(var h=[],f=i,v=this.session.getNextFoldLine(f),p=v?v.start.row:1/0;f>p&&(f=v.end.row+1,v=this.session.getNextFoldLine(f,v),p=v?v.start.row:1/0),!(f>c);){var y=this.$lines.createCell(f,t,this.session),m=y.element;this.dom.removeChildren(m),C.setStyle(m.style,"height",this.$lines.computeLineHeight(f,t,this.session)+"px"),C.setStyle(m.style,"top",this.$lines.computeLineTop(f,t,this.session)+"px"),this.$renderLine(m,f,f==p?v:!1),this.$useLineGroups()?m.className="ace_line_group":m.className="ace_line",h.push(y),f++}return h},r.prototype.update=function(t){this.$lines.moveContainer(t),this.config=t;for(var i=t.firstRow,c=t.lastRow,h=this.$lines;h.getLength();)h.pop();h.push(this.$renderLinesFragment(t,i,c))},r.prototype.$renderToken=function(t,i,c,h){for(var f=this,v=/(\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,p=this.dom.createFragment(this.element),y,m=0;y=v.exec(h);){var $=y[1],N=y[2],M=y[3],S=y[4],O=y[5];if(!(!f.showSpaces&&N)){var x=m!=y.index?h.slice(m,y.index):"";if(m=y.index+y[0].length,x&&p.appendChild(this.dom.createTextNode(x,this.element)),$){var L=f.session.getScreenTabSize(i+y.index);p.appendChild(f.$tabStrings[L].cloneNode(!0)),i+=L-1}else if(N)if(f.showSpaces){var I=this.dom.createElement("span");I.className="ace_invisible ace_invisible_space",I.textContent=A.stringRepeat(f.SPACE_CHAR,N.length),p.appendChild(I)}else p.appendChild(this.dom.createTextNode(N,this.element));else if(M){var I=this.dom.createElement("span");I.className="ace_invisible ace_invisible_space ace_invalid",I.textContent=A.stringRepeat(f.SPACE_CHAR,M.length),p.appendChild(I)}else if(S){i+=1;var I=this.dom.createElement("span");I.style.width=f.config.characterWidth*2+"px",I.className=f.showSpaces?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",I.textContent=f.showSpaces?f.SPACE_CHAR:S,p.appendChild(I)}else if(O){i+=1;var I=this.dom.createElement("span");I.style.width=f.config.characterWidth*2+"px",I.className="ace_cjk",I.textContent=O,p.appendChild(I)}}}if(p.appendChild(this.dom.createTextNode(m?h.slice(m):h,this.element)),s(c.type))t.appendChild(p);else{var w="ace_"+c.type.replace(/\./g," ace_"),I=this.dom.createElement("span");c.type=="fold"&&(I.style.width=c.value.length*this.config.characterWidth+"px",I.setAttribute("title",n("inline-fold.closed.title","Unfold code"))),I.className=w,I.appendChild(p),t.appendChild(I)}return i+h.length},r.prototype.renderIndentGuide=function(t,i,c){var h=i.search(this.$indentGuideRe);if(h<=0||h>=c)return i;if(i[0]==" "){h-=h%this.tabSize;for(var f=h/this.tabSize,v=0;v<f;v++)t.appendChild(this.$tabStrings[" "].cloneNode(!0));return this.$highlightIndentGuide(),i.substr(h)}else if(i[0]==" "){for(var v=0;v<h;v++)t.appendChild(this.$tabStrings[" "].cloneNode(!0));return this.$highlightIndentGuide(),i.substr(h)}return this.$highlightIndentGuide(),i},r.prototype.$highlightIndentGuide=function(){if(!(!this.$highlightIndentGuides||!this.displayIndentGuides)){this.$highlightIndentGuideMarker={indentLevel:void 0,start:void 0,end:void 0,dir:void 0};var t=this.session.doc.$lines;if(t){var i=this.session.selection.getCursor(),c=/^\s*/.exec(this.session.doc.getLine(i.row))[0].length,h=Math.floor(c/this.tabSize);this.$highlightIndentGuideMarker={indentLevel:h,start:i.row};var f=this.session.$bracketHighlight;if(f){for(var v=this.session.$bracketHighlight.ranges,p=0;p<v.length;p++)if(i.row!==v[p].start.row){this.$highlightIndentGuideMarker.end=v[p].start.row+1,i.row>v[p].start.row?this.$highlightIndentGuideMarker.dir=-1:this.$highlightIndentGuideMarker.dir=1;break}}if(!this.$highlightIndentGuideMarker.end&&t[i.row]!==""&&i.column===t[i.row].length){this.$highlightIndentGuideMarker.dir=1;for(var p=i.row+1;p<t.length;p++){var y=t[p],m=/^\s*/.exec(y)[0].length;if(y!==""&&(this.$highlightIndentGuideMarker.end=p,m<=c))break}}this.$renderHighlightIndentGuide()}}},r.prototype.$clearActiveIndentGuide=function(){for(var t=this.element.querySelectorAll(".ace_indent-guide-active"),i=0;i<t.length;i++)t[i].classList.remove("ace_indent-guide-active")},r.prototype.$setIndentGuideActive=function(t,i){var c=this.session.doc.getLine(t.row);if(c!==""){var h=t.element;if(t.element.classList&&t.element.classList.contains("ace_line_group"))if(t.element.childNodes.length>0)h=t.element.childNodes[0];else return;var f=h.childNodes;if(f){var v=f[i-1];v&&v.classList&&v.classList.contains("ace_indent-guide")&&v.classList.add("ace_indent-guide-active")}}},r.prototype.$renderHighlightIndentGuide=function(){if(this.$lines){var t=this.$lines.cells;this.$clearActiveIndentGuide();var i=this.$highlightIndentGuideMarker.indentLevel;if(i!==0)if(this.$highlightIndentGuideMarker.dir===1)for(var c=0;c<t.length;c++){var h=t[c];if(this.$highlightIndentGuideMarker.end&&h.row>=this.$highlightIndentGuideMarker.start+1){if(h.row>=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(h,i)}}else for(var c=t.length-1;c>=0;c--){var h=t[c];if(this.$highlightIndentGuideMarker.end&&h.row<this.$highlightIndentGuideMarker.start){if(h.row<this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(h,i)}}}},r.prototype.$createLineElement=function(t){var i=this.dom.createElement("div");return i.className="ace_line",i.style.height=this.config.lineHeight+"px",i},r.prototype.$renderWrappedLine=function(t,i,c){var h=0,f=0,v=c[0],p=0,y=this.$createLineElement();t.appendChild(y);for(var m=0;m<i.length;m++){var $=i[m],N=$.value;if(m==0&&this.displayIndentGuides){if(h=N.length,N=this.renderIndentGuide(y,N,v),!N)continue;h-=N.length}if(h+N.length<v)p=this.$renderToken(y,p,$,N),h+=N.length;else{for(;h+N.length>=v;)p=this.$renderToken(y,p,$,N.substring(0,v-h)),N=N.substring(v-h),h=v,y=this.$createLineElement(),t.appendChild(y),y.appendChild(this.dom.createTextNode(A.stringRepeat(" ",c.indent),this.element)),f++,p=0,v=c[f]||Number.MAX_VALUE;N.length!=0&&(h+=N.length,p=this.$renderToken(y,p,$,N))}}c[c.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage(y,p,null,"",!0)},r.prototype.$renderSimpleLine=function(t,i){for(var c=0,h=0;h<i.length;h++){var f=i[h],v=f.value;if(!(h==0&&this.displayIndentGuides&&(v=this.renderIndentGuide(t,v),!v))){if(c+v.length>this.MAX_LINE_LENGTH)return this.$renderOverflowMessage(t,c,f,v);c=this.$renderToken(t,c,f,v)}}},r.prototype.$renderOverflowMessage=function(t,i,c,h,f){c&&this.$renderToken(t,i,c,h.slice(0,this.MAX_LINE_LENGTH-i));var v=this.dom.createElement("span");v.className="ace_inline_button ace_keyword ace_toggle_wrap",v.textContent=f?"<hide>":"<click to see more...>",t.appendChild(v)},r.prototype.$renderLine=function(t,i,c){if(!c&&c!=!1&&(c=this.session.getFoldLine(i)),c)var h=this.$getFoldLineTokens(i,c);else var h=this.session.getTokens(i);var f=t;if(h.length){var v=this.session.getRowSplitData(i);if(v&&v.length){this.$renderWrappedLine(t,h,v);var f=t.lastChild}else{var f=t;this.$useLineGroups()&&(f=this.$createLineElement(),t.appendChild(f)),this.$renderSimpleLine(f,h)}}else this.$useLineGroups()&&(f=this.$createLineElement(),t.appendChild(f));if(this.showEOL&&f){c&&(i=c.end.row);var p=this.dom.createElement("span");p.className="ace_invisible ace_invisible_eol",p.textContent=i==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,f.appendChild(p)}},r.prototype.$getFoldLineTokens=function(t,i){var c=this.session,h=[];function f(p,y,m){for(var $=0,N=0;N+p[$].value.length<y;)if(N+=p[$].value.length,$++,$==p.length)return;if(N!=y){var M=p[$].value.substring(y-N);M.length>m-y&&(M=M.substring(0,m-y)),h.push({type:p[$].type,value:M}),N=y+M.length,$+=1}for(;N<m&&$<p.length;){var M=p[$].value;M.length+N>m?h.push({type:p[$].type,value:M.substring(0,m-N)}):h.push(p[$]),N+=M.length,$+=1}}var v=c.getTokens(t);return i.walk(function(p,y,m,$,N){p!=null?h.push({type:"fold",value:p}):(N&&(v=c.getTokens(y)),v.length&&f(v,$,m))},i.end.row,this.session.getLine(i.end.row).length),h},r.prototype.$useLineGroups=function(){return this.session.getUseWrapMode()},r}();o.prototype.EOF_CHAR="¶",o.prototype.EOL_CHAR_LF="¬",o.prototype.EOL_CHAR_CRLF="¤",o.prototype.EOL_CHAR=o.prototype.EOL_CHAR_LF,o.prototype.TAB_CHAR="—",o.prototype.SPACE_CHAR="·",o.prototype.$padding=0,o.prototype.MAX_LINE_LENGTH=1e4,o.prototype.showInvisibles=!1,o.prototype.showSpaces=!1,o.prototype.showTabs=!1,o.prototype.showEOL=!1,o.prototype.displayIndentGuides=!0,o.prototype.$highlightIndentGuides=!0,o.prototype.$tabStrings=[],o.prototype.destroy={},o.prototype.onChangeTabSize=o.prototype.$computeTabString,b.implement(o.prototype,g),d.Text=o}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(l,d,E){var b=l("../lib/dom"),C=function(){function A(a){this.element=b.createElement("div"),this.element.className="ace_layer ace_cursor-layer",a.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),b.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)}return A.prototype.$updateOpacity=function(a){for(var g=this.cursors,n=g.length;n--;)b.setStyle(g[n].style,"opacity",a?"":"0")},A.prototype.$startCssAnimation=function(){for(var a=this.cursors,g=a.length;g--;)a[g].style.animationDuration=this.blinkInterval+"ms";this.$isAnimating=!0,setTimeout((function(){this.$isAnimating&&b.addCssClass(this.element,"ace_animate-blinking")}).bind(this))},A.prototype.$stopCssAnimation=function(){this.$isAnimating=!1,b.removeCssClass(this.element,"ace_animate-blinking")},A.prototype.setPadding=function(a){this.$padding=a},A.prototype.setSession=function(a){this.session=a},A.prototype.setBlinking=function(a){a!=this.isBlinking&&(this.isBlinking=a,this.restartTimer())},A.prototype.setBlinkInterval=function(a){a!=this.blinkInterval&&(this.blinkInterval=a,this.restartTimer())},A.prototype.setSmoothBlinking=function(a){a!=this.smoothBlinking&&(this.smoothBlinking=a,b.setCssClass(this.element,"ace_smooth-blinking",a),this.$updateCursors(!0),this.restartTimer())},A.prototype.addCursor=function(){var a=b.createElement("div");return a.className="ace_cursor",this.element.appendChild(a),this.cursors.push(a),a},A.prototype.removeCursor=function(){if(this.cursors.length>1){var a=this.cursors.pop();return a.parentNode.removeChild(a),a}},A.prototype.hideCursor=function(){this.isVisible=!1,b.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},A.prototype.showCursor=function(){this.isVisible=!0,b.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},A.prototype.restartTimer=function(){var a=this.$updateCursors;if(clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&(this.$isSmoothBlinking=!1,b.removeCssClass(this.element,"ace_smooth-blinking")),a(!0),!this.isBlinking||!this.blinkInterval||!this.isVisible){this.$stopCssAnimation();return}if(this.smoothBlinking&&(this.$isSmoothBlinking=!0,setTimeout((function(){this.$isSmoothBlinking&&b.addCssClass(this.element,"ace_smooth-blinking")}).bind(this))),b.HAS_CSS_ANIMATION)this.$startCssAnimation();else{var g=(function(){this.timeoutId=setTimeout(function(){a(!1)},.6*this.blinkInterval)}).bind(this);this.intervalId=setInterval(function(){a(!0),g()},this.blinkInterval),g()}},A.prototype.getPixelPosition=function(a,g){if(!this.config||!this.session)return{left:0,top:0};a||(a=this.session.selection.getCursor());var n=this.session.documentToScreenPosition(a),s=this.$padding+(this.session.$bidiHandler.isBidiRow(n.row,a.row)?this.session.$bidiHandler.getPosLeft(n.column):n.column*this.config.characterWidth),o=(n.row-(g?this.config.firstRowScreen:0))*this.config.lineHeight;return{left:s,top:o}},A.prototype.isCursorInView=function(a,g){return a.top>=0&&a.top<g.maxHeight},A.prototype.update=function(a){this.config=a;var g=this.session.$selectionMarkers,n=0,s=0;(g===void 0||g.length===0)&&(g=[{cursor:null}]);for(var n=0,o=g.length;n<o;n++){var r=this.getPixelPosition(g[n].cursor,!0);if(!((r.top>a.height+a.offset||r.top<0)&&n>1)){var t=this.cursors[s++]||this.addCursor(),i=t.style;this.drawCursor?this.drawCursor(t,r,a,g[n],this.session):this.isCursorInView(r,a)?(b.setStyle(i,"display","block"),b.translate(t,r.left,r.top),b.setStyle(i,"width",Math.round(a.characterWidth)+"px"),b.setStyle(i,"height",a.lineHeight+"px")):b.setStyle(i,"display","none")}}for(;this.cursors.length>s;)this.removeCursor();var c=this.session.getOverwrite();this.$setOverwrite(c),this.$pixelPos=r,this.restartTimer()},A.prototype.$setOverwrite=function(a){a!=this.overwrite&&(this.overwrite=a,a?b.addCssClass(this.element,"ace_overwrite-cursors"):b.removeCssClass(this.element,"ace_overwrite-cursors"))},A.prototype.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)},A}();C.prototype.$padding=0,C.prototype.drawCursor=null,d.Cursor=C}),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(l,d,E){var b=this&&this.__extends||function(){var t=function(i,c){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,f){h.__proto__=f}||function(h,f){for(var v in f)Object.prototype.hasOwnProperty.call(f,v)&&(h[v]=f[v])},t(i,c)};return function(i,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");t(i,c);function h(){this.constructor=i}i.prototype=c===null?Object.create(c):(h.prototype=c.prototype,new h)}}(),C=l("./lib/oop"),A=l("./lib/dom"),a=l("./lib/event"),g=l("./lib/event_emitter").EventEmitter,n=32768,s=function(){function t(i,c){this.element=A.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+c,this.inner=A.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent=" ",this.element.appendChild(this.inner),i.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,a.addListener(this.element,"scroll",this.onScroll.bind(this)),a.addListener(this.element,"mousedown",a.preventDefault)}return t.prototype.setVisible=function(i){this.element.style.display=i?"":"none",this.isVisible=i,this.coeff=1},t}();C.implement(s.prototype,g);var o=function(t){b(i,t);function i(c,h){var f=t.call(this,c,"-v")||this;return f.scrollTop=0,f.scrollHeight=0,h.$scrollbarWidth=f.width=A.scrollbarWidth(c.ownerDocument),f.inner.style.width=f.element.style.width=(f.width||15)+5+"px",f.$minWidth=0,f}return i.prototype.onScroll=function(){if(!this.skipEvent){if(this.scrollTop=this.element.scrollTop,this.coeff!=1){var c=this.element.clientHeight/this.scrollHeight;this.scrollTop=this.scrollTop*(1-c)/(this.coeff-c)}this._emit("scroll",{data:this.scrollTop})}this.skipEvent=!1},i.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},i.prototype.setHeight=function(c){this.element.style.height=c+"px"},i.prototype.setScrollHeight=function(c){this.scrollHeight=c,c>n?(this.coeff=n/c,c=n):this.coeff!=1&&(this.coeff=1),this.inner.style.height=c+"px"},i.prototype.setScrollTop=function(c){this.scrollTop!=c&&(this.skipEvent=!0,this.scrollTop=c,this.element.scrollTop=c*this.coeff)},i}(s);o.prototype.setInnerHeight=o.prototype.setScrollHeight;var r=function(t){b(i,t);function i(c,h){var f=t.call(this,c,"-h")||this;return f.scrollLeft=0,f.height=h.$scrollbarWidth,f.inner.style.height=f.element.style.height=(f.height||15)+5+"px",f}return i.prototype.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},i.prototype.getHeight=function(){return this.isVisible?this.height:0},i.prototype.setWidth=function(c){this.element.style.width=c+"px"},i.prototype.setInnerWidth=function(c){this.inner.style.width=c+"px"},i.prototype.setScrollWidth=function(c){this.inner.style.width=c+"px"},i.prototype.setScrollLeft=function(c){this.scrollLeft!=c&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=c)},i}(s);d.ScrollBar=o,d.ScrollBarV=o,d.ScrollBarH=r,d.VScrollBar=o,d.HScrollBar=r}),ace.define("ace/scrollbar_custom",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(l,d,E){var b=this&&this.__extends||function(){var r=function(t,i){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,h){c.__proto__=h}||function(c,h){for(var f in h)Object.prototype.hasOwnProperty.call(h,f)&&(c[f]=h[f])},r(t,i)};return function(t,i){if(typeof i!="function"&&i!==null)throw new TypeError("Class extends value "+String(i)+" is not a constructor or null");r(t,i);function c(){this.constructor=t}t.prototype=i===null?Object.create(i):(c.prototype=i.prototype,new c)}}(),C=l("./lib/oop"),A=l("./lib/dom"),a=l("./lib/event"),g=l("./lib/event_emitter").EventEmitter;A.importCssString(`.ace_editor>.ace_sb-v div, .ace_editor>.ace_sb-h div{
222
+ position: absolute;
223
+ background: rgba(128, 128, 128, 0.6);
224
+ -moz-box-sizing: border-box;
225
+ box-sizing: border-box;
226
+ border: 1px solid #bbb;
227
+ border-radius: 2px;
228
+ z-index: 8;
229
+ }
230
+ .ace_editor>.ace_sb-v, .ace_editor>.ace_sb-h {
231
+ position: absolute;
232
+ z-index: 6;
233
+ background: none;
234
+ overflow: hidden!important;
235
+ }
236
+ .ace_editor>.ace_sb-v {
237
+ z-index: 6;
238
+ right: 0;
239
+ top: 0;
240
+ width: 12px;
241
+ }
242
+ .ace_editor>.ace_sb-v div {
243
+ z-index: 8;
244
+ right: 0;
245
+ width: 100%;
246
+ }
247
+ .ace_editor>.ace_sb-h {
248
+ bottom: 0;
249
+ left: 0;
250
+ height: 12px;
251
+ }
252
+ .ace_editor>.ace_sb-h div {
253
+ bottom: 0;
254
+ height: 100%;
255
+ }
256
+ .ace_editor>.ace_sb_grabbed {
257
+ z-index: 8;
258
+ background: #000;
259
+ }`,"ace_scrollbar.css",!1);var n=function(){function r(t,i){this.element=A.createElement("div"),this.element.className="ace_sb"+i,this.inner=A.createElement("div"),this.inner.className="",this.element.appendChild(this.inner),this.VScrollWidth=12,this.HScrollHeight=12,t.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,a.addMultiMouseDownListener(this.element,[500,300,300],this,"onMouseDown")}return r.prototype.setVisible=function(t){this.element.style.display=t?"":"none",this.isVisible=t,this.coeff=1},r}();C.implement(n.prototype,g);var s=function(r){b(t,r);function t(i,c){var h=r.call(this,i,"-v")||this;return h.scrollTop=0,h.scrollHeight=0,h.parent=i,h.width=h.VScrollWidth,h.renderer=c,h.inner.style.width=h.element.style.width=(h.width||15)+"px",h.$minWidth=0,h}return t.prototype.onMouseDown=function(i,c){if(i==="mousedown"&&!(a.getButton(c)!==0||c.detail===2)){if(c.target===this.inner){var h=this,f=c.clientY,v=function(S){f=S.clientY},p=function(){clearInterval(N)},y=c.clientY,m=this.thumbTop,$=function(){if(f!==void 0){var S=h.scrollTopFromThumbTop(m+f-y);S!==h.scrollTop&&h._emit("scroll",{data:S})}};a.capture(this.inner,v,p);var N=setInterval($,20);return a.preventDefault(c)}var M=c.clientY-this.element.getBoundingClientRect().top-this.thumbHeight/2;return this._emit("scroll",{data:this.scrollTopFromThumbTop(M)}),a.preventDefault(c)}},t.prototype.getHeight=function(){return this.height},t.prototype.scrollTopFromThumbTop=function(i){var c=i*(this.pageHeight-this.viewHeight)/(this.slideHeight-this.thumbHeight);return c=c>>0,c<0?c=0:c>this.pageHeight-this.viewHeight&&(c=this.pageHeight-this.viewHeight),c},t.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},t.prototype.setHeight=function(i){this.height=Math.max(0,i),this.slideHeight=this.height,this.viewHeight=this.height,this.setScrollHeight(this.pageHeight,!0)},t.prototype.setScrollHeight=function(i,c){this.pageHeight===i&&!c||(this.pageHeight=i,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})))},t.prototype.setScrollTop=function(i){this.scrollTop=i,i<0&&(i=0),this.thumbTop=i*(this.slideHeight-this.thumbHeight)/(this.pageHeight-this.viewHeight),this.inner.style.top=this.thumbTop+"px"},t}(n);s.prototype.setInnerHeight=s.prototype.setScrollHeight;var o=function(r){b(t,r);function t(i,c){var h=r.call(this,i,"-h")||this;return h.scrollLeft=0,h.scrollWidth=0,h.height=h.HScrollHeight,h.inner.style.height=h.element.style.height=(h.height||12)+"px",h.renderer=c,h}return t.prototype.onMouseDown=function(i,c){if(i==="mousedown"&&!(a.getButton(c)!==0||c.detail===2)){if(c.target===this.inner){var h=this,f=c.clientX,v=function(S){f=S.clientX},p=function(){clearInterval(N)},y=c.clientX,m=this.thumbLeft,$=function(){if(f!==void 0){var S=h.scrollLeftFromThumbLeft(m+f-y);S!==h.scrollLeft&&h._emit("scroll",{data:S})}};a.capture(this.inner,v,p);var N=setInterval($,20);return a.preventDefault(c)}var M=c.clientX-this.element.getBoundingClientRect().left-this.thumbWidth/2;return this._emit("scroll",{data:this.scrollLeftFromThumbLeft(M)}),a.preventDefault(c)}},t.prototype.getHeight=function(){return this.isVisible?this.height:0},t.prototype.scrollLeftFromThumbLeft=function(i){var c=i*(this.pageWidth-this.viewWidth)/(this.slideWidth-this.thumbWidth);return c=c>>0,c<0?c=0:c>this.pageWidth-this.viewWidth&&(c=this.pageWidth-this.viewWidth),c},t.prototype.setWidth=function(i){this.width=Math.max(0,i),this.element.style.width=this.width+"px",this.slideWidth=this.width,this.viewWidth=this.width,this.setScrollWidth(this.pageWidth,!0)},t.prototype.setScrollWidth=function(i,c){this.pageWidth===i&&!c||(this.pageWidth=i,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})))},t.prototype.setScrollLeft=function(i){this.scrollLeft=i,i<0&&(i=0),this.thumbLeft=i*(this.slideWidth-this.thumbWidth)/(this.pageWidth-this.viewWidth),this.inner.style.left=this.thumbLeft+"px"},t}(n);o.prototype.setInnerWidth=o.prototype.setScrollWidth,d.ScrollBar=s,d.ScrollBarV=s,d.ScrollBarH=o,d.VScrollBar=s,d.HScrollBar=o}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(l,d,E){var b=l("./lib/event"),C=function(){function A(a,g){this.onRender=a,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=g||window;var n=this;this._flush=function(s){n.pending=!1;var o=n.changes;if(o&&(b.blockIdle(100),n.changes=0,n.onRender(o)),n.changes){if(n.$recursionLimit--<0)return;n.schedule()}else n.$recursionLimit=2}}return A.prototype.schedule=function(a){this.changes=this.changes|a,this.changes&&!this.pending&&(b.nextFrame(this._flush),this.pending=!0)},A.prototype.clear=function(a){var g=this.changes;return this.changes=0,g},A}();d.RenderLoop=C}),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(l,d,E){var b=l("../lib/oop"),C=l("../lib/dom"),A=l("../lib/lang"),a=l("../lib/event"),g=l("../lib/useragent"),n=l("../lib/event_emitter").EventEmitter,s=512,o=typeof ResizeObserver=="function",r=200,t=function(){function i(c){this.el=C.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=C.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=C.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),c.appendChild(this.el),this.$measureNode.textContent=A.stringRepeat("X",s),this.$characterSize={width:0,height:0},o?this.$addObserver():this.checkForSizeChanges()}return i.prototype.$setMeasureNodeStyles=function(c,h){c.width=c.height="auto",c.left=c.top="0px",c.visibility="hidden",c.position="absolute",c.whiteSpace="pre",g.isIE<8?c["font-family"]="inherit":c.font="inherit",c.overflow=h?"hidden":"visible"},i.prototype.checkForSizeChanges=function(c){if(c===void 0&&(c=this.$measureSizes()),c&&(this.$characterSize.width!==c.width||this.$characterSize.height!==c.height)){this.$measureNode.style.fontWeight="bold";var h=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=c,this.charSizes=Object.create(null),this.allowBoldFonts=h&&h.width===c.width&&h.height===c.height,this._emit("changeCharacterSize",{data:c})}},i.prototype.$addObserver=function(){var c=this;this.$observer=new window.ResizeObserver(function(h){c.checkForSizeChanges()}),this.$observer.observe(this.$measureNode)},i.prototype.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer||this.$observer)return this.$pollSizeChangesTimer;var c=this;return this.$pollSizeChangesTimer=a.onIdle(function h(){c.checkForSizeChanges(),a.onIdle(h,500)},500)},i.prototype.setPolling=function(c){c?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},i.prototype.$measureSizes=function(c){var h={height:(c||this.$measureNode).clientHeight,width:(c||this.$measureNode).clientWidth/s};return h.width===0||h.height===0?null:h},i.prototype.$measureCharWidth=function(c){this.$main.textContent=A.stringRepeat(c,s);var h=this.$main.getBoundingClientRect();return h.width/s},i.prototype.getCharacterWidth=function(c){var h=this.charSizes[c];return h===void 0&&(h=this.charSizes[c]=this.$measureCharWidth(c)/this.$characterSize.width),h},i.prototype.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},i.prototype.$getZoom=function(c){return!c||!c.parentElement?1:(Number(window.getComputedStyle(c).zoom)||1)*this.$getZoom(c.parentElement)},i.prototype.$initTransformMeasureNodes=function(){var c=function(h,f){return["div",{style:"position: absolute;top:"+h+"px;left:"+f+"px;"}]};this.els=C.buildDom([c(0,0),c(r,0),c(0,r),c(r,r)],this.el)},i.prototype.transformCoordinates=function(c,h){if(c){var f=this.$getZoom(this.el);c=m(1/f,c)}function v(D,V,B){var F=D[1]*V[0]-D[0]*V[1];return[(-V[1]*B[0]+V[0]*B[1])/F,(+D[1]*B[0]-D[0]*B[1])/F]}function p(D,V){return[D[0]-V[0],D[1]-V[1]]}function y(D,V){return[D[0]+V[0],D[1]+V[1]]}function m(D,V){return[D*V[0],D*V[1]]}this.els||this.$initTransformMeasureNodes();function $(D){var V=D.getBoundingClientRect();return[V.left,V.top]}var N=$(this.els[0]),M=$(this.els[1]),S=$(this.els[2]),O=$(this.els[3]),x=v(p(O,M),p(O,S),p(y(M,S),y(O,N))),L=m(1+x[0],p(M,N)),I=m(1+x[1],p(S,N));if(h){var w=h,_=x[0]*w[0]/r+x[1]*w[1]/r+1,T=y(m(w[0],L),m(w[1],I));return y(m(1/_/r,T),N)}var k=p(c,N),R=v(p(L,m(x[0],k)),p(I,m(x[1],k)),k);return m(r,R)},i}();t.prototype.$characterSize={width:0,height:0},b.implement(t.prototype,n),d.FontMetrics=t}),ace.define("ace/css/editor-css",["require","exports","module"],function(l,d,E){E.exports=`
260
+ .ace_br1 {border-top-left-radius : 3px;}
261
+ .ace_br2 {border-top-right-radius : 3px;}
262
+ .ace_br3 {border-top-left-radius : 3px; border-top-right-radius: 3px;}
263
+ .ace_br4 {border-bottom-right-radius: 3px;}
264
+ .ace_br5 {border-top-left-radius : 3px; border-bottom-right-radius: 3px;}
265
+ .ace_br6 {border-top-right-radius : 3px; border-bottom-right-radius: 3px;}
266
+ .ace_br7 {border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px;}
267
+ .ace_br8 {border-bottom-left-radius : 3px;}
268
+ .ace_br9 {border-top-left-radius : 3px; border-bottom-left-radius: 3px;}
269
+ .ace_br10{border-top-right-radius : 3px; border-bottom-left-radius: 3px;}
270
+ .ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-left-radius: 3px;}
271
+ .ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
272
+ .ace_br13{border-top-left-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
273
+ .ace_br14{border-top-right-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
274
+ .ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
275
+
276
+
277
+ .ace_editor {
278
+ position: relative;
279
+ overflow: hidden;
280
+ padding: 0;
281
+ font: 12px/normal 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'Source Code Pro', 'source-code-pro', monospace;
282
+ direction: ltr;
283
+ text-align: left;
284
+ -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
285
+ forced-color-adjust: none;
286
+ }
287
+
288
+ .ace_scroller {
289
+ position: absolute;
290
+ overflow: hidden;
291
+ top: 0;
292
+ bottom: 0;
293
+ background-color: inherit;
294
+ -ms-user-select: none;
295
+ -moz-user-select: none;
296
+ -webkit-user-select: none;
297
+ user-select: none;
298
+ cursor: text;
299
+ }
300
+
301
+ .ace_content {
302
+ position: absolute;
303
+ box-sizing: border-box;
304
+ min-width: 100%;
305
+ contain: style size layout;
306
+ font-variant-ligatures: no-common-ligatures;
307
+ }
308
+ .ace_invisible {
309
+ font-variant-ligatures: none;
310
+ }
311
+
312
+ .ace_keyboard-focus:focus {
313
+ box-shadow: inset 0 0 0 2px #5E9ED6;
314
+ outline: none;
315
+ }
316
+
317
+ .ace_dragging .ace_scroller:before{
318
+ position: absolute;
319
+ top: 0;
320
+ left: 0;
321
+ right: 0;
322
+ bottom: 0;
323
+ content: '';
324
+ background: rgba(250, 250, 250, 0.01);
325
+ z-index: 1000;
326
+ }
327
+ .ace_dragging.ace_dark .ace_scroller:before{
328
+ background: rgba(0, 0, 0, 0.01);
329
+ }
330
+
331
+ .ace_gutter {
332
+ position: absolute;
333
+ overflow : hidden;
334
+ width: auto;
335
+ top: 0;
336
+ bottom: 0;
337
+ left: 0;
338
+ cursor: default;
339
+ z-index: 4;
340
+ -ms-user-select: none;
341
+ -moz-user-select: none;
342
+ -webkit-user-select: none;
343
+ user-select: none;
344
+ contain: style size layout;
345
+ }
346
+
347
+ .ace_gutter-active-line {
348
+ position: absolute;
349
+ left: 0;
350
+ right: 0;
351
+ }
352
+
353
+ .ace_scroller.ace_scroll-left:after {
354
+ content: "";
355
+ position: absolute;
356
+ top: 0;
357
+ right: 0;
358
+ bottom: 0;
359
+ left: 0;
360
+ box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;
361
+ pointer-events: none;
362
+ }
363
+
364
+ .ace_gutter-cell, .ace_gutter-cell_svg-icons {
365
+ position: absolute;
366
+ top: 0;
367
+ left: 0;
368
+ right: 0;
369
+ padding-left: 19px;
370
+ padding-right: 6px;
371
+ background-repeat: no-repeat;
372
+ }
373
+
374
+ .ace_gutter-cell_svg-icons .ace_gutter_annotation {
375
+ margin-left: -14px;
376
+ float: left;
377
+ }
378
+
379
+ .ace_gutter-cell .ace_gutter_annotation {
380
+ margin-left: -19px;
381
+ float: left;
382
+ }
383
+
384
+ .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 {
385
+ 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==");
386
+ background-repeat: no-repeat;
387
+ background-position: 2px center;
388
+ }
389
+
390
+ .ace_gutter-cell.ace_warning, .ace_icon.ace_warning, .ace_icon.ace_warning_fold {
391
+ 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==");
392
+ background-repeat: no-repeat;
393
+ background-position: 2px center;
394
+ }
395
+
396
+ .ace_gutter-cell.ace_info, .ace_icon.ace_info, .ace_gutter-cell.ace_hint, .ace_icon.ace_hint {
397
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");
398
+ background-repeat: no-repeat;
399
+ background-position: 2px center;
400
+ }
401
+
402
+ .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 {
403
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");
404
+ }
405
+
406
+ .ace_icon_svg.ace_error {
407
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJyZWQiIHNoYXBlLXJlbmRlcmluZz0iZ2VvbWV0cmljUHJlY2lzaW9uIj4KPGNpcmNsZSBmaWxsPSJub25lIiBjeD0iOCIgY3k9IjgiIHI9IjciIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPGxpbmUgeDE9IjExIiB5MT0iNSIgeDI9IjUiIHkyPSIxMSIvPgo8bGluZSB4MT0iMTEiIHkxPSIxMSIgeDI9IjUiIHkyPSI1Ii8+CjwvZz4KPC9zdmc+");
408
+ background-color: crimson;
409
+ }
410
+ .ace_icon_svg.ace_security {
411
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8ZyBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZT0iZGFya29yYW5nZSIgZmlsbD0ibm9uZSIgc2hhcGUtcmVuZGVyaW5nPSJnZW9tZXRyaWNQcmVjaXNpb24iPgogICAgICAgIDxwYXRoIGNsYXNzPSJzdHJva2UtbGluZWpvaW4tcm91bmQiIGQ9Ik04IDE0LjgzMDdDOCAxNC44MzA3IDIgMTIuOTA0NyAyIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOEM3Ljk4OTk5IDEuMzQ5MTggMTAuNjkgMy4yNjU0OCAxNCAzLjI2NTQ4VjguMDg5OTJDMTQgMTIuOTA0NyA4IDE0LjgzMDcgOCAxNC44MzA3WiIvPgogICAgICAgIDxwYXRoIGQ9Ik0yIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOCIvPgogICAgICAgIDxwYXRoIGQ9Ik0xMy45OSA4LjA4OTkyVjMuMjY1NDhDMTAuNjggMy4yNjU0OCA4IDEuMzQ5MTggOCAxLjM0OTE4Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggNFY5Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggMTBWMTIiLz4KICAgIDwvZz4KPC9zdmc+");
412
+ background-color: crimson;
413
+ }
414
+ .ace_icon_svg.ace_warning {
415
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJkYXJrb3JhbmdlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+Cjxwb2x5Z29uIHN0cm9rZS1saW5lam9pbj0icm91bmQiIGZpbGw9Im5vbmUiIHBvaW50cz0iOCAxIDE1IDE1IDEgMTUgOCAxIi8+CjxyZWN0IHg9IjgiIHk9IjEyIiB3aWR0aD0iMC4wMSIgaGVpZ2h0PSIwLjAxIi8+CjxsaW5lIHgxPSI4IiB5MT0iNiIgeDI9IjgiIHkyPSIxMCIvPgo8L2c+Cjwvc3ZnPg==");
416
+ background-color: darkorange;
417
+ }
418
+ .ace_icon_svg.ace_info {
419
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJibHVlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+CjxjaXJjbGUgZmlsbD0ibm9uZSIgY3g9IjgiIGN5PSI4IiByPSI3IiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+Cjxwb2x5bGluZSBwb2ludHM9IjggMTEgOCA4Ii8+Cjxwb2x5bGluZSBwb2ludHM9IjkgOCA2IDgiLz4KPGxpbmUgeDE9IjEwIiB5MT0iMTEiIHgyPSI2IiB5Mj0iMTEiLz4KPHJlY3QgeD0iOCIgeT0iNSIgd2lkdGg9IjAuMDEiIGhlaWdodD0iMC4wMSIvPgo8L2c+Cjwvc3ZnPg==");
420
+ background-color: royalblue;
421
+ }
422
+ .ace_icon_svg.ace_hint {
423
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8ZyBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZT0ic2lsdmVyIiBmaWxsPSJub25lIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTYgMTRIMTAiLz4KICAgICAgICA8cGF0aCBkPSJNOCAxMUg5QzkgOS40NzAwMiAxMiA4LjU0MDAyIDEyIDUuNzYwMDJDMTIuMDIgNC40MDAwMiAxMS4zOSAzLjM2MDAyIDEwLjQzIDIuNjcwMDJDOSAxLjY0MDAyIDcuMDAwMDEgMS42NDAwMiA1LjU3MDAxIDIuNjcwMDJDNC42MTAwMSAzLjM2MDAyIDMuOTggNC40MDAwMiA0IDUuNzYwMDJDNCA4LjU0MDAyIDcuMDAwMDEgOS40NzAwMiA3LjAwMDAxIDExSDhaIi8+CiAgICA8L2c+Cjwvc3ZnPg==");
424
+ background-color: silver;
425
+ }
426
+
427
+ .ace_icon_svg.ace_error_fold {
428
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiIgZmlsbD0ibm9uZSI+CiAgPHBhdGggZD0ibSAxOC45Mjk4NTEsNy44Mjk4MDc2IGMgMC4xNDYzNTMsNi4zMzc0NjA0IC02LjMyMzE0Nyw3Ljc3Nzg0NDQgLTcuNDc3OTEyLDcuNzc3ODQ0NCAtMi4xMDcyNzI2LC0wLjEyODc1IDUuMTE3Njc4LDAuMzU2MjQ5IDUuMDUxNjk4LC03Ljg3MDA2MTggLTAuNjA0NjcyLC04LjAwMzk3MzQ5IC03LjA3NzI3MDYsLTcuNTYzMTE4OSAtNC44NTczLC03LjQzMDM5NTU2IDEuNjA2LC0wLjExNTE0MjI1IDYuODk3NDg1LDEuMjYyNTQ1OTYgNy4yODM1MTQsNy41MjI2MTI5NiB6IiBmaWxsPSJjcmltc29uIiBzdHJva2Utd2lkdGg9IjIiLz4KICA8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0ibSA4LjExNDc1NjIsMi4wNTI5ODI4IGMgMy4zNDkxNjk4LDAgNi4wNjQxMzI4LDIuNjc2ODYyNyA2LjA2NDEzMjgsNS45Nzg5NTMgMCwzLjMwMjExMjIgLTIuNzE0OTYzLDUuOTc4OTIwMiAtNi4wNjQxMzI4LDUuOTc4OTIwMiAtMy4zNDkxNDczLDAgLTYuMDY0MTc3MiwtMi42NzY4MDggLTYuMDY0MTc3MiwtNS45Nzg5MjAyIDAuMDA1MzksLTMuMjk5ODg2MSAyLjcxNzI2NTYsLTUuOTczNjQwOCA2LjA2NDE3NzIsLTUuOTc4OTUzIHogbSAwLC0xLjczNTgyNzE5IGMgLTQuMzIxNDgzNiwwIC03LjgyNDc0MDM4LDMuNDU0MDE4NDkgLTcuODI0NzQwMzgsNy43MTQ3ODAxOSAwLDQuMjYwNzI4MiAzLjUwMzI1Njc4LDcuNzE0NzQ1MiA3LjgyNDc0MDM4LDcuNzE0NzQ1MiA0LjMyMTQ0OTgsMCA3LjgyNDY5OTgsLTMuNDU0MDE3IDcuODI0Njk5OCwtNy43MTQ3NDUyIDAsLTIuMDQ2MDkxNCAtMC44MjQzOTIsLTQuMDA4MzY3MiAtMi4yOTE3NTYsLTUuNDU1MTc0NiBDIDEyLjE4MDIyNSwxLjEyOTk2NDggMTAuMTkwMDEzLDAuMzE3MTU1NjEgOC4xMTQ3NTYyLDAuMzE3MTU1NjEgWiBNIDYuOTM3NDU2Myw4LjI0MDU5ODUgNC42NzE4Njg1LDEwLjQ4NTg1MiA2LjAwODY4MTQsMTEuODc2NzI4IDguMzE3MDAzNSw5LjYwMDc5MTEgMTAuNjI1MzM3LDExLjg3NjcyOCAxMS45NjIxMzgsMTAuNDg1ODUyIDkuNjk2NTUwOCw4LjI0MDU5ODUgMTEuOTYyMTM4LDYuMDA2ODA2NiAxMC41NzMyNDYsNC42Mzc0MzM1IDguMzE3MDAzNSw2Ljg3MzQyOTcgNi4wNjA3NjA3LDQuNjM3NDMzNSA0LjY3MTg2ODUsNi4wMDY4MDY2IFoiIGZpbGw9ImNyaW1zb24iIHN0cm9rZS13aWR0aD0iMiIvPgo8L3N2Zz4=");
429
+ background-color: crimson;
430
+ }
431
+ .ace_icon_svg.ace_security_fold {
432
+ -webkit-mask-image: url("data:image/svg+xml;base64,CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMTcgMTQiIGZpbGw9Im5vbmUiPgogICAgPHBhdGggZD0iTTEwLjAwMDEgMTMuNjk5MkMxMC4wMDAxIDEzLjY5OTIgMTEuOTI0MSAxMy40NzYzIDEzIDEyLjY5OTJDMTQuNDEzOSAxMS42NzgxIDE2IDEwLjUgMTYuMTI1MSA2LjgxMTI2VjIuNTg5ODdDMTYuMTI1MSAyLjU0NzY4IDE2LjEyMjEgMi41MDYxOSAxNi4xMTY0IDIuNDY1NTlWMS43MTQ4NUgxNS4yNDE0TDE1LjIzMDcgMS43MTQ4NEwxNC42MjUxIDEuNjk5MjJWNi44MTEyM0MxNC42MjUxIDguNTEwNjEgMTQuNjI1MSA5LjQ2NDYxIDEyLjc4MjQgMTEuNzIxQzEyLjE1ODYgMTIuNDg0OCAxMC4wMDAxIDEzLjY5OTIgMTAuMDAwMSAxMy42OTkyWiIgZmlsbD0iY3JpbXNvbiIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgICA8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTcuMzM2MDkgMC4zNjc0NzVDNy4wMzIxNCAwLjE1MjY1MiA2LjYyNTQ4IDAuMTUzNjE0IDYuMzIyNTMgMC4zNjk5OTdMNi4zMDg2OSAwLjM3OTU1NEM2LjI5NTUzIDAuMzg4NTg4IDYuMjczODggMC40MDMyNjYgNi4yNDQxNyAwLjQyMjc4OUM2LjE4NDcxIDAuNDYxODYgNi4wOTMyMSAwLjUyMDE3MSA1Ljk3MzEzIDAuNTkxMzczQzUuNzMyNTEgMC43MzQwNTkgNS4zNzk5IDAuOTI2ODY0IDQuOTQyNzkgMS4xMjAwOUM0LjA2MTQ0IDEuNTA5NyAyLjg3NTQxIDEuODgzNzcgMS41ODk4NCAxLjg4Mzc3SDAuNzE0ODQ0VjIuNzU4NzdWNi45ODAxNUMwLjcxNDg0NCA5LjQ5Mzc0IDIuMjg4NjYgMTEuMTk3MyAzLjcwMjU0IDEyLjIxODVDNC40MTg0NSAxMi43MzU1IDUuMTI4NzQgMTMuMTA1MyA1LjY1NzMzIDEzLjM0NTdDNS45MjI4NCAxMy40NjY0IDYuMTQ1NjYgMTMuNTU1OSA2LjMwNDY1IDEzLjYxNjFDNi4zODQyMyAxMy42NDYyIDYuNDQ4MDUgMTMuNjY5IDYuNDkzNDkgMTMuNjg0OEM2LjUxNjIyIDEzLjY5MjcgNi41MzQzOCAxMy42OTg5IDYuNTQ3NjQgMTMuNzAzM0w2LjU2MzgyIDEzLjcwODdMNi41NjkwOCAxMy43MTA0TDYuNTcwOTkgMTMuNzExTDYuODM5ODQgMTMuNzUzM0w2LjU3MjQyIDEzLjcxMTVDNi43NDYzMyAxMy43NjczIDYuOTMzMzUgMTMuNzY3MyA3LjEwNzI3IDEzLjcxMTVMNy4xMDg3IDEzLjcxMUw3LjExMDYxIDEzLjcxMDRMNy4xMTU4NyAxMy43MDg3TDcuMTMyMDUgMTMuNzAzM0M3LjE0NTMxIDEzLjY5ODkgNy4xNjM0NiAxMy42OTI3IDcuMTg2MTkgMTMuNjg0OEM3LjIzMTY0IDEzLjY2OSA3LjI5NTQ2IDEzLjY0NjIgNy4zNzUwMyAxMy42MTYxQzcuNTM0MDMgMTMuNTU1OSA3Ljc1Njg1IDEzLjQ2NjQgOC4wMjIzNiAxMy4zNDU3QzguNTUwOTUgMTMuMTA1MyA5LjI2MTIzIDEyLjczNTUgOS45NzcxNSAxMi4yMTg1QzExLjM5MSAxMS4xOTczIDEyLjk2NDggOS40OTM3NyAxMi45NjQ4IDYuOTgwMThWMi43NTg4QzEyLjk2NDggMi43MTY2IDEyLjk2MTkgMi42NzUxMSAxMi45NTYxIDIuNjM0NTFWMS44ODM3N0gxMi4wODExQzEyLjA3NzUgMS44ODM3NyAxMi4wNzQgMS44ODM3NyAxMi4wNzA0IDEuODgzNzdDMTAuNzk3OSAxLjg4MDA0IDkuNjE5NjIgMS41MTEwMiA4LjczODk0IDEuMTI0ODZDOC43MzUzNCAxLjEyMzI3IDguNzMxNzQgMS4xMjE2OCA4LjcyODE0IDEuMTIwMDlDOC4yOTEwMyAwLjkyNjg2NCA3LjkzODQyIDAuNzM0MDU5IDcuNjk3NzkgMC41OTEzNzNDNy41Nzc3MiAwLjUyMDE3MSA3LjQ4NjIyIDAuNDYxODYgNy40MjY3NiAwLjQyMjc4OUM3LjM5NzA1IDAuNDAzMjY2IDcuMzc1MzkgMC4zODg1ODggNy4zNjIyNCAwLjM3OTU1NEw3LjM0ODk2IDAuMzcwMzVDNy4zNDg5NiAwLjM3MDM1IDcuMzQ4NDcgMC4zNzAwMiA3LjM0NTYzIDAuMzc0MDU0TDcuMzM3NzkgMC4zNjg2NTlMNy4zMzYwOSAwLjM2NzQ3NVpNOC4wMzQ3MSAyLjcyNjkxQzguODYwNCAzLjA5MDYzIDkuOTYwNjYgMy40NjMwOSAxMS4yMDYxIDMuNTg5MDdWNi45ODAxNUgxMS4yMTQ4QzExLjIxNDggOC42Nzk1MyAxMC4xNjM3IDkuOTI1MDcgOC45NTI1NCAxMC43OTk4QzguMzU1OTUgMTEuMjMwNiA3Ljc1Mzc0IDExLjU0NTQgNy4yOTc5NiAxMS43NTI3QzcuMTE2NzEgMTEuODM1MSA2Ljk2MDYyIDExLjg5OTYgNi44Mzk4NCAxMS45NDY5QzYuNzE5MDYgMTEuODk5NiA2LjU2Mjk3IDExLjgzNTEgNi4zODE3MyAxMS43NTI3QzUuOTI1OTUgMTEuNTQ1NCA1LjMyMzczIDExLjIzMDYgNC43MjcxNSAxMC43OTk4QzMuNTE2MDMgOS45MjUwNyAyLjQ2NDg0IDguNjc5NTUgMi40NjQ4NCA2Ljk4MDE4VjMuNTg5MDlDMy43MTczOCAzLjQ2MjM5IDQuODIzMDggMy4wODYzOSA1LjY1MDMzIDIuNzIwNzFDNi4xNDIyOCAyLjUwMzI0IDYuNTQ0ODUgMi4yODUzNyA2LjgzMjU0IDIuMTE2MjRDNy4xMjE4MSAyLjI4NTM1IDcuNTI3IDIuNTAzNTIgOC4wMjE5NiAyLjcyMTMxQzguMDI2MiAyLjcyMzE3IDguMDMwNDUgMi43MjUwNCA4LjAzNDcxIDIuNzI2OTFaTTUuOTY0ODQgMy40MDE0N1Y3Ljc3NjQ3SDcuNzE0ODRWMy40MDE0N0g1Ljk2NDg0Wk01Ljk2NDg0IDEwLjQwMTVWOC42NTE0N0g3LjcxNDg0VjEwLjQwMTVINS45NjQ4NFoiIGZpbGw9ImNyaW1zb24iIHN0cm9rZS13aWR0aD0iMiIvPgo8L3N2Zz4=");
433
+ background-color: crimson;
434
+ }
435
+ .ace_icon_svg.ace_warning_fold {
436
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjAiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAyMCAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xNC43NzY5IDE0LjczMzdMOC42NTE5MiAyLjQ4MzY5QzguMzI5NDYgMS44Mzg3NyA3LjQwOTEzIDEuODM4NzcgNy4wODY2NyAyLjQ4MzY5TDAuOTYxNjY5IDE0LjczMzdDMC42NzA3NzUgMTUuMzE1NSAxLjA5MzgzIDE2IDEuNzQ0MjkgMTZIMTMuOTk0M0MxNC42NDQ4IDE2IDE1LjA2NzggMTUuMzE1NSAxNC43NzY5IDE0LjczMzdaTTMuMTYwMDcgMTQuMjVMNy44NjkyOSA0LjgzMTU2TDEyLjU3ODUgMTQuMjVIMy4xNjAwN1pNOC43NDQyOSAxMS42MjVWMTMuMzc1SDYuOTk0MjlWMTEuNjI1SDguNzQ0MjlaTTYuOTk0MjkgMTAuNzVWNy4yNUg4Ljc0NDI5VjEwLjc1SDYuOTk0MjlaIiBmaWxsPSIjRUM3MjExIi8+CjxwYXRoIGQ9Ik0xMS4xOTkxIDIuOTUyMzhDMTAuODgwOSAyLjMxNDY3IDEwLjM1MzcgMS44MDUyNiA5LjcwNTUgMS41MDlMMTEuMDQxIDEuMDY5NzhDMTEuNjg4MyAwLjk0OTgxNCAxMi4zMzcgMS4yNzI2MyAxMi42MzE3IDEuODYxNDFMMTcuNjEzNiAxMS44MTYxQzE4LjM1MjcgMTMuMjkyOSAxNy41OTM4IDE1LjA4MDQgMTYuMDE4IDE1LjU3NDVDMTYuNDA0NCAxNC40NTA3IDE2LjMyMzEgMTMuMjE4OCAxNS43OTI0IDEyLjE1NTVMMTEuMTk5MSAyLjk1MjM4WiIgZmlsbD0iI0VDNzIxMSIvPgo8L3N2Zz4=");
437
+ background-color: darkorange;
438
+ }
439
+
440
+ .ace_scrollbar {
441
+ contain: strict;
442
+ position: absolute;
443
+ right: 0;
444
+ bottom: 0;
445
+ z-index: 6;
446
+ }
447
+
448
+ .ace_scrollbar-inner {
449
+ position: absolute;
450
+ cursor: text;
451
+ left: 0;
452
+ top: 0;
453
+ }
454
+
455
+ .ace_scrollbar-v{
456
+ overflow-x: hidden;
457
+ overflow-y: scroll;
458
+ top: 0;
459
+ }
460
+
461
+ .ace_scrollbar-h {
462
+ overflow-x: scroll;
463
+ overflow-y: hidden;
464
+ left: 0;
465
+ }
466
+
467
+ .ace_print-margin {
468
+ position: absolute;
469
+ height: 100%;
470
+ }
471
+
472
+ .ace_text-input {
473
+ position: absolute;
474
+ z-index: 0;
475
+ width: 0.5em;
476
+ height: 1em;
477
+ opacity: 0;
478
+ background: transparent;
479
+ -moz-appearance: none;
480
+ appearance: none;
481
+ border: none;
482
+ resize: none;
483
+ outline: none;
484
+ overflow: hidden;
485
+ font: inherit;
486
+ padding: 0 1px;
487
+ margin: 0 -1px;
488
+ contain: strict;
489
+ -ms-user-select: text;
490
+ -moz-user-select: text;
491
+ -webkit-user-select: text;
492
+ user-select: text;
493
+ /*with \`pre-line\` chrome inserts &nbsp; instead of space*/
494
+ white-space: pre!important;
495
+ }
496
+ .ace_text-input.ace_composition {
497
+ background: transparent;
498
+ color: inherit;
499
+ z-index: 1000;
500
+ opacity: 1;
501
+ }
502
+ .ace_composition_placeholder { color: transparent }
503
+ .ace_composition_marker {
504
+ border-bottom: 1px solid;
505
+ position: absolute;
506
+ border-radius: 0;
507
+ margin-top: 1px;
508
+ }
509
+
510
+ [ace_nocontext=true] {
511
+ transform: none!important;
512
+ filter: none!important;
513
+ clip-path: none!important;
514
+ mask : none!important;
515
+ contain: none!important;
516
+ perspective: none!important;
517
+ mix-blend-mode: initial!important;
518
+ z-index: auto;
519
+ }
520
+
521
+ .ace_layer {
522
+ z-index: 1;
523
+ position: absolute;
524
+ overflow: hidden;
525
+ /* workaround for chrome bug https://github.com/ajaxorg/ace/issues/2312*/
526
+ word-wrap: normal;
527
+ white-space: pre;
528
+ height: 100%;
529
+ width: 100%;
530
+ box-sizing: border-box;
531
+ /* setting pointer-events: auto; on node under the mouse, which changes
532
+ during scroll, will break mouse wheel scrolling in Safari */
533
+ pointer-events: none;
534
+ }
535
+
536
+ .ace_gutter-layer {
537
+ position: relative;
538
+ width: auto;
539
+ text-align: right;
540
+ pointer-events: auto;
541
+ height: 1000000px;
542
+ contain: style size layout;
543
+ }
544
+
545
+ .ace_text-layer {
546
+ font: inherit !important;
547
+ position: absolute;
548
+ height: 1000000px;
549
+ width: 1000000px;
550
+ contain: style size layout;
551
+ }
552
+
553
+ .ace_text-layer > .ace_line, .ace_text-layer > .ace_line_group {
554
+ contain: style size layout;
555
+ position: absolute;
556
+ top: 0;
557
+ left: 0;
558
+ right: 0;
559
+ }
560
+
561
+ .ace_hidpi .ace_text-layer,
562
+ .ace_hidpi .ace_gutter-layer,
563
+ .ace_hidpi .ace_content,
564
+ .ace_hidpi .ace_gutter {
565
+ contain: strict;
566
+ }
567
+ .ace_hidpi .ace_text-layer > .ace_line,
568
+ .ace_hidpi .ace_text-layer > .ace_line_group {
569
+ contain: strict;
570
+ }
571
+
572
+ .ace_cjk {
573
+ display: inline-block;
574
+ text-align: center;
575
+ }
576
+
577
+ .ace_cursor-layer {
578
+ z-index: 4;
579
+ }
580
+
581
+ .ace_cursor {
582
+ z-index: 4;
583
+ position: absolute;
584
+ box-sizing: border-box;
585
+ border-left: 2px solid;
586
+ /* workaround for smooth cursor repaintng whole screen in chrome */
587
+ transform: translatez(0);
588
+ }
589
+
590
+ .ace_multiselect .ace_cursor {
591
+ border-left-width: 1px;
592
+ }
593
+
594
+ .ace_slim-cursors .ace_cursor {
595
+ border-left-width: 1px;
596
+ }
597
+
598
+ .ace_overwrite-cursors .ace_cursor {
599
+ border-left-width: 0;
600
+ border-bottom: 1px solid;
601
+ }
602
+
603
+ .ace_hidden-cursors .ace_cursor {
604
+ opacity: 0.2;
605
+ }
606
+
607
+ .ace_hasPlaceholder .ace_hidden-cursors .ace_cursor {
608
+ opacity: 0;
609
+ }
610
+
611
+ .ace_smooth-blinking .ace_cursor {
612
+ transition: opacity 0.18s;
613
+ }
614
+
615
+ .ace_animate-blinking .ace_cursor {
616
+ animation-duration: 1000ms;
617
+ animation-timing-function: step-end;
618
+ animation-name: blink-ace-animate;
619
+ animation-iteration-count: infinite;
620
+ }
621
+
622
+ .ace_animate-blinking.ace_smooth-blinking .ace_cursor {
623
+ animation-duration: 1000ms;
624
+ animation-timing-function: ease-in-out;
625
+ animation-name: blink-ace-animate-smooth;
626
+ }
627
+
628
+ @keyframes blink-ace-animate {
629
+ from, to { opacity: 1; }
630
+ 60% { opacity: 0; }
631
+ }
632
+
633
+ @keyframes blink-ace-animate-smooth {
634
+ from, to { opacity: 1; }
635
+ 45% { opacity: 1; }
636
+ 60% { opacity: 0; }
637
+ 85% { opacity: 0; }
638
+ }
639
+
640
+ .ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {
641
+ position: absolute;
642
+ z-index: 3;
643
+ }
644
+
645
+ .ace_marker-layer .ace_selection {
646
+ position: absolute;
647
+ z-index: 5;
648
+ }
649
+
650
+ .ace_marker-layer .ace_bracket {
651
+ position: absolute;
652
+ z-index: 6;
653
+ }
654
+
655
+ .ace_marker-layer .ace_error_bracket {
656
+ position: absolute;
657
+ border-bottom: 1px solid #DE5555;
658
+ border-radius: 0;
659
+ }
660
+
661
+ .ace_marker-layer .ace_active-line {
662
+ position: absolute;
663
+ z-index: 2;
664
+ }
665
+
666
+ .ace_marker-layer .ace_selected-word {
667
+ position: absolute;
668
+ z-index: 4;
669
+ box-sizing: border-box;
670
+ }
671
+
672
+ .ace_line .ace_fold {
673
+ box-sizing: border-box;
674
+
675
+ display: inline-block;
676
+ height: 11px;
677
+ margin-top: -2px;
678
+ vertical-align: middle;
679
+
680
+ background-image:
681
+ url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),
682
+ url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");
683
+ background-repeat: no-repeat, repeat-x;
684
+ background-position: center center, top left;
685
+ color: transparent;
686
+
687
+ border: 1px solid black;
688
+ border-radius: 2px;
689
+
690
+ cursor: pointer;
691
+ pointer-events: auto;
692
+ }
693
+
694
+ .ace_dark .ace_fold {
695
+ }
696
+
697
+ .ace_fold:hover{
698
+ background-image:
699
+ url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),
700
+ url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");
701
+ }
702
+
703
+ .ace_tooltip {
704
+ background-color: #f5f5f5;
705
+ border: 1px solid gray;
706
+ border-radius: 1px;
707
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
708
+ color: black;
709
+ padding: 3px 4px;
710
+ position: fixed;
711
+ z-index: 999999;
712
+ box-sizing: border-box;
713
+ cursor: default;
714
+ white-space: pre-wrap;
715
+ word-wrap: break-word;
716
+ line-height: normal;
717
+ font-style: normal;
718
+ font-weight: normal;
719
+ letter-spacing: normal;
720
+ pointer-events: none;
721
+ overflow: auto;
722
+ max-width: min(33em, 66vw);
723
+ overscroll-behavior: contain;
724
+ }
725
+ .ace_tooltip pre {
726
+ white-space: pre-wrap;
727
+ }
728
+
729
+ .ace_tooltip.ace_dark {
730
+ background-color: #636363;
731
+ color: #fff;
732
+ }
733
+
734
+ .ace_tooltip:focus {
735
+ outline: 1px solid #5E9ED6;
736
+ }
737
+
738
+ .ace_icon {
739
+ display: inline-block;
740
+ width: 18px;
741
+ vertical-align: top;
742
+ }
743
+
744
+ .ace_icon_svg {
745
+ display: inline-block;
746
+ width: 12px;
747
+ vertical-align: top;
748
+ -webkit-mask-repeat: no-repeat;
749
+ -webkit-mask-size: 12px;
750
+ -webkit-mask-position: center;
751
+ }
752
+
753
+ .ace_folding-enabled > .ace_gutter-cell, .ace_folding-enabled > .ace_gutter-cell_svg-icons {
754
+ padding-right: 13px;
755
+ }
756
+
757
+ .ace_fold-widget {
758
+ box-sizing: border-box;
759
+
760
+ margin: 0 -12px 0 1px;
761
+ display: none;
762
+ width: 11px;
763
+ vertical-align: top;
764
+
765
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");
766
+ background-repeat: no-repeat;
767
+ background-position: center;
768
+
769
+ border-radius: 3px;
770
+
771
+ border: 1px solid transparent;
772
+ cursor: pointer;
773
+ }
774
+
775
+ .ace_folding-enabled .ace_fold-widget {
776
+ display: inline-block;
777
+ }
778
+
779
+ .ace_fold-widget.ace_end {
780
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");
781
+ }
782
+
783
+ .ace_fold-widget.ace_closed {
784
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");
785
+ }
786
+
787
+ .ace_fold-widget:hover {
788
+ border: 1px solid rgba(0, 0, 0, 0.3);
789
+ background-color: rgba(255, 255, 255, 0.2);
790
+ box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);
791
+ }
792
+
793
+ .ace_fold-widget:active {
794
+ border: 1px solid rgba(0, 0, 0, 0.4);
795
+ background-color: rgba(0, 0, 0, 0.05);
796
+ box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);
797
+ }
798
+ /**
799
+ * Dark version for fold widgets
800
+ */
801
+ .ace_dark .ace_fold-widget {
802
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");
803
+ }
804
+ .ace_dark .ace_fold-widget.ace_end {
805
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");
806
+ }
807
+ .ace_dark .ace_fold-widget.ace_closed {
808
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");
809
+ }
810
+ .ace_dark .ace_fold-widget:hover {
811
+ box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);
812
+ background-color: rgba(255, 255, 255, 0.1);
813
+ }
814
+ .ace_dark .ace_fold-widget:active {
815
+ box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);
816
+ }
817
+
818
+ .ace_inline_button {
819
+ border: 1px solid lightgray;
820
+ display: inline-block;
821
+ margin: -1px 8px;
822
+ padding: 0 5px;
823
+ pointer-events: auto;
824
+ cursor: pointer;
825
+ }
826
+ .ace_inline_button:hover {
827
+ border-color: gray;
828
+ background: rgba(200,200,200,0.2);
829
+ display: inline-block;
830
+ pointer-events: auto;
831
+ }
832
+
833
+ .ace_fold-widget.ace_invalid {
834
+ background-color: #FFB4B4;
835
+ border-color: #DE5555;
836
+ }
837
+
838
+ .ace_fade-fold-widgets .ace_fold-widget {
839
+ transition: opacity 0.4s ease 0.05s;
840
+ opacity: 0;
841
+ }
842
+
843
+ .ace_fade-fold-widgets:hover .ace_fold-widget {
844
+ transition: opacity 0.05s ease 0.05s;
845
+ opacity:1;
846
+ }
847
+
848
+ .ace_underline {
849
+ text-decoration: underline;
850
+ }
851
+
852
+ .ace_bold {
853
+ font-weight: bold;
854
+ }
855
+
856
+ .ace_nobold .ace_bold {
857
+ font-weight: normal;
858
+ }
859
+
860
+ .ace_italic {
861
+ font-style: italic;
862
+ }
863
+
864
+
865
+ .ace_error-marker {
866
+ background-color: rgba(255, 0, 0,0.2);
867
+ position: absolute;
868
+ z-index: 9;
869
+ }
870
+
871
+ .ace_highlight-marker {
872
+ background-color: rgba(255, 255, 0,0.2);
873
+ position: absolute;
874
+ z-index: 8;
875
+ }
876
+
877
+ .ace_mobile-menu {
878
+ position: absolute;
879
+ line-height: 1.5;
880
+ border-radius: 4px;
881
+ -ms-user-select: none;
882
+ -moz-user-select: none;
883
+ -webkit-user-select: none;
884
+ user-select: none;
885
+ background: white;
886
+ box-shadow: 1px 3px 2px grey;
887
+ border: 1px solid #dcdcdc;
888
+ color: black;
889
+ }
890
+ .ace_dark > .ace_mobile-menu {
891
+ background: #333;
892
+ color: #ccc;
893
+ box-shadow: 1px 3px 2px grey;
894
+ border: 1px solid #444;
895
+
896
+ }
897
+ .ace_mobile-button {
898
+ padding: 2px;
899
+ cursor: pointer;
900
+ overflow: hidden;
901
+ }
902
+ .ace_mobile-button:hover {
903
+ background-color: #eee;
904
+ opacity:1;
905
+ }
906
+ .ace_mobile-button:active {
907
+ background-color: #ddd;
908
+ }
909
+
910
+ .ace_placeholder {
911
+ position: relative;
912
+ font-family: arial;
913
+ transform: scale(0.9);
914
+ transform-origin: left;
915
+ white-space: pre;
916
+ opacity: 0.7;
917
+ margin: 0 10px;
918
+ z-index: 1;
919
+ }
920
+
921
+ .ace_ghost_text {
922
+ opacity: 0.5;
923
+ font-style: italic;
924
+ }
925
+
926
+ .ace_ghost_text_container > div {
927
+ white-space: pre;
928
+ }
929
+
930
+ .ghost_text_line_wrapped::after {
931
+ content: "↩";
932
+ position: absolute;
933
+ }
934
+
935
+ .ace_lineWidgetContainer.ace_ghost_text {
936
+ margin: 0px 4px
937
+ }
938
+
939
+ .ace_screenreader-only {
940
+ position:absolute;
941
+ left:-10000px;
942
+ top:auto;
943
+ width:1px;
944
+ height:1px;
945
+ overflow:hidden;
946
+ }
947
+
948
+ .ace_hidden_token {
949
+ display: none;
950
+ }`}),ace.define("ace/layer/decorators",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter"],function(l,d,E){var b=l("../lib/dom"),C=l("../lib/oop"),A=l("../lib/event_emitter").EventEmitter,a=function(){function g(n,s){this.canvas=b.createElement("canvas"),this.renderer=s,this.pixelRatio=1,this.maxHeight=s.layerConfig.maxHeight,this.lineHeight=s.layerConfig.lineHeight,this.canvasHeight=n.parent.scrollHeight,this.heightRatio=this.canvasHeight/this.maxHeight,this.canvasWidth=n.width,this.minDecorationHeight=2*this.pixelRatio|0,this.halfMinDecorationHeight=this.minDecorationHeight/2|0,this.canvas.width=this.canvasWidth,this.canvas.height=this.canvasHeight,this.canvas.style.top="0px",this.canvas.style.right="0px",this.canvas.style.zIndex="7px",this.canvas.style.position="absolute",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)"},n.element.appendChild(this.canvas)}return g.prototype.$updateDecorators=function(n){var s=this.renderer.theme.isDark===!0?this.colors.dark:this.colors.light;if(n){this.maxHeight=n.maxHeight,this.lineHeight=n.lineHeight,this.canvasHeight=n.height;var o=(n.lastRow+1)*this.lineHeight;o<this.canvasHeight?this.heightRatio=1:this.heightRatio=this.canvasHeight/this.maxHeight}var r=this.canvas.getContext("2d");function t(O,x){return O.priority<x.priority?-1:O.priority>x.priority?1:0}var i=this.renderer.session.$annotations;if(r.clearRect(0,0,this.canvas.width,this.canvas.height),i){var c={info:1,warning:2,error:3};i.forEach(function(O){O.priority=c[O.type]||null}),i=i.sort(t);for(var h=this.renderer.session.$foldData,f=0;f<i.length;f++){var v=i[f].row,p=this.compensateFoldRows(v,h),y=Math.round((v-p)*this.lineHeight*this.heightRatio),m=Math.round((v-p)*this.lineHeight*this.heightRatio),$=Math.round(((v-p)*this.lineHeight+this.lineHeight)*this.heightRatio),N=$-m;if(N<this.minDecorationHeight){var M=(m+$)/2|0;M<this.halfMinDecorationHeight?M=this.halfMinDecorationHeight:M+this.halfMinDecorationHeight>this.canvasHeight&&(M=this.canvasHeight-this.halfMinDecorationHeight),m=Math.round(M-this.halfMinDecorationHeight),$=Math.round(M+this.halfMinDecorationHeight)}r.fillStyle=s[i[f].type]||null,r.fillRect(0,y,this.canvasWidth,$-m)}}var S=this.renderer.session.selection.getCursor();if(S){var p=this.compensateFoldRows(S.row,h),y=Math.round((S.row-p)*this.lineHeight*this.heightRatio);r.fillStyle="rgba(0, 0, 0, 0.5)",r.fillRect(0,y,this.canvasWidth,2)}},g.prototype.compensateFoldRows=function(n,s){var o=0;if(s&&s.length>0)for(var r=0;r<s.length;r++)n>s[r].start.row&&n<s[r].end.row?o+=n-s[r].start.row:n>=s[r].end.row&&(o+=s[r].end.row-s[r].start.row);return o},g}();C.implement(a.prototype,A),d.Decorator=a}),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(l,d,E){var b=l("./lib/oop"),C=l("./lib/dom"),A=l("./lib/lang"),a=l("./config"),g=l("./layer/gutter").Gutter,n=l("./layer/marker").Marker,s=l("./layer/text").Text,o=l("./layer/cursor").Cursor,r=l("./scrollbar").HScrollBar,t=l("./scrollbar").VScrollBar,i=l("./scrollbar_custom").HScrollBar,c=l("./scrollbar_custom").VScrollBar,h=l("./renderloop").RenderLoop,f=l("./layer/font_metrics").FontMetrics,v=l("./lib/event_emitter").EventEmitter,p=l("./css/editor-css"),y=l("./layer/decorators").Decorator,m=l("./lib/useragent"),$=l("./layer/text_util").isTextToken;C.importCssString(p,"ace_editor.css",!1);var N=function(){function M(S,O){var x=this;this.container=S||C.createElement("div"),C.addCssClass(this.container,"ace_editor"),C.HI_DPI&&C.addCssClass(this.container,"ace_hidpi"),this.setTheme(O),a.get("useStrictCSP")==null&&a.set("useStrictCSP",!1),this.$gutter=C.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.$gutter.setAttribute("aria-hidden","true"),this.scroller=C.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=C.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 n(this.content);var L=this.$textLayer=new s(this.content);this.canvas=L.element,this.$markerFront=new n(this.content),this.$cursorLayer=new o(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new t(this.container,this),this.scrollBarH=new r(this.container,this),this.scrollBarV.on("scroll",function(I){x.$scrollAnimation||x.session.setScrollTop(I.data-x.scrollMargin.top)}),this.scrollBarH.on("scroll",function(I){x.$scrollAnimation||x.session.setScrollLeft(I.data-x.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new f(this.container),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.on("changeCharacterSize",function(I){x.updateCharacterSize(),x.onResize(!0,x.gutterWidth,x.$size.width,x.$size.height),x._signal("changeCharacterSize",I)}),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=!m.isIOS,this.$loop=new h(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),this.$addResizeObserver(),a.resetOptions(this),a._signal("renderer",this)}return M.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(),C.setStyle(this.scroller.style,"line-height",this.lineHeight+"px")},M.prototype.setSession=function(S){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=S,S&&this.scrollMargin.top&&S.getScrollTop()<=0&&S.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(S),this.$markerBack.setSession(S),this.$markerFront.setSession(S),this.$gutterLayer.setSession(S),this.$textLayer.setSession(S),S&&(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))},M.prototype.updateLines=function(S,O,x){if(O===void 0&&(O=1/0),this.$changedLines?(this.$changedLines.firstRow>S&&(this.$changedLines.firstRow=S),this.$changedLines.lastRow<O&&(this.$changedLines.lastRow=O)):this.$changedLines={firstRow:S,lastRow:O},this.$changedLines.lastRow<this.layerConfig.firstRow)if(x)this.$changedLines.lastRow=this.layerConfig.lastRow;else return;this.$changedLines.firstRow>this.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)},M.prototype.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},M.prototype.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},M.prototype.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},M.prototype.updateFull=function(S){S?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},M.prototype.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},M.prototype.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},M.prototype.onResize=function(S,O,x,L){if(!(this.resizing>2)){this.resizing>0?this.resizing++:this.resizing=S?1:0;var I=this.container;L||(L=I.clientHeight||I.scrollHeight),!L&&this.$maxLines&&this.lineHeight>1&&(!I.style.height||I.style.height=="0px")&&(I.style.height="1px",L=I.clientHeight||I.scrollHeight),x||(x=I.clientWidth||I.scrollWidth);var w=this.$updateCachedSize(S,O,x,L);if(this.$resizeTimer&&this.$resizeTimer.cancel(),!this.$size.scrollerHeight||!x&&!L)return this.resizing=0;S&&(this.$gutterLayer.$padding=null),S?this.$renderChanges(w|this.$changes,!0):this.$loop.schedule(w|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.$customScrollbar&&this.$updateCustomScrollbar(!0)}},M.prototype.$updateCachedSize=function(S,O,x,L){L-=this.$extraHeight||0;var I=0,w=this.$size,_={width:w.width,height:w.height,scrollerHeight:w.scrollerHeight,scrollerWidth:w.scrollerWidth};if(L&&(S||w.height!=L)&&(w.height=L,I|=this.CHANGE_SIZE,w.scrollerHeight=w.height,this.$horizScroll&&(w.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.setHeight(w.scrollerHeight),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",I=I|this.CHANGE_SCROLL),x&&(S||w.width!=x)){I|=this.CHANGE_SIZE,w.width=x,O==null&&(O=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=O,C.setStyle(this.scrollBarH.element.style,"left",O+"px"),C.setStyle(this.scroller.style,"left",O+this.margin.left+"px"),w.scrollerWidth=Math.max(0,x-O-this.scrollBarV.getWidth()-this.margin.h),C.setStyle(this.$gutter.style,"left",this.margin.left+"px");var T=this.scrollBarV.getWidth()+"px";C.setStyle(this.scrollBarH.element.style,"right",T),C.setStyle(this.scroller.style,"right",T),C.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight()),this.scrollBarH.setWidth(w.scrollerWidth),(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||S)&&(I|=this.CHANGE_FULL)}return w.$dirty=!x||!L,I&&this._signal("resize",_),I},M.prototype.onGutterResize=function(S){var O=this.$showGutter?S:0;O!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,O,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()},M.prototype.adjustWrapLimit=function(){var S=this.$size.scrollerWidth-this.$padding*2,O=Math.floor(S/this.characterWidth);return this.session.adjustWrapLimit(O,this.$showPrintMargin&&this.$printMarginColumn)},M.prototype.setAnimatedScroll=function(S){this.setOption("animatedScroll",S)},M.prototype.getAnimatedScroll=function(){return this.$animatedScroll},M.prototype.setShowInvisibles=function(S){this.setOption("showInvisibles",S),this.session.$bidiHandler.setShowInvisibles(S)},M.prototype.getShowInvisibles=function(){return this.getOption("showInvisibles")},M.prototype.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},M.prototype.setDisplayIndentGuides=function(S){this.setOption("displayIndentGuides",S)},M.prototype.getHighlightIndentGuides=function(){return this.getOption("highlightIndentGuides")},M.prototype.setHighlightIndentGuides=function(S){this.setOption("highlightIndentGuides",S)},M.prototype.setShowPrintMargin=function(S){this.setOption("showPrintMargin",S)},M.prototype.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},M.prototype.setPrintMarginColumn=function(S){this.setOption("printMarginColumn",S)},M.prototype.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},M.prototype.getShowGutter=function(){return this.getOption("showGutter")},M.prototype.setShowGutter=function(S){return this.setOption("showGutter",S)},M.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},M.prototype.setFadeFoldWidgets=function(S){this.setOption("fadeFoldWidgets",S)},M.prototype.setHighlightGutterLine=function(S){this.setOption("highlightGutterLine",S)},M.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},M.prototype.$updatePrintMargin=function(){if(!(!this.$showPrintMargin&&!this.$printMarginEl)){if(!this.$printMarginEl){var S=C.createElement("div");S.className="ace_layer ace_print-margin-layer",this.$printMarginEl=C.createElement("div"),this.$printMarginEl.className="ace_print-margin",S.appendChild(this.$printMarginEl),this.content.insertBefore(S,this.content.firstChild)}var O=this.$printMarginEl.style;O.left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",O.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&this.session.$wrap==-1&&this.adjustWrapLimit()}},M.prototype.getContainerElement=function(){return this.container},M.prototype.getMouseEventTarget=function(){return this.scroller},M.prototype.getTextAreaContainer=function(){return this.container},M.prototype.$moveTextAreaToCursor=function(){if(!this.$isMousePressed){var S=this.textarea.style,O=this.$composition;if(!this.$keepTextAreaAtCursor&&!O){C.translate(this.textarea,-100,0);return}var x=this.$cursorLayer.$pixelPos;if(x){O&&O.markerRange&&(x=this.$cursorLayer.getPixelPosition(O.markerRange.start,!0));var L=this.layerConfig,I=x.top,w=x.left;I-=L.offset;var _=O&&O.useTextareaForIME||m.isMobile?this.lineHeight:1;if(I<0||I>L.height-_){C.translate(this.textarea,0,0);return}var T=1,k=this.$size.height-_;if(!O)I+=this.lineHeight;else if(O.useTextareaForIME){var R=this.textarea.value;T=this.characterWidth*this.session.$getStringScreenWidth(R)[0]}else I+=this.lineHeight+2;w-=this.scrollLeft,w>this.$size.scrollerWidth-T&&(w=this.$size.scrollerWidth-T),w+=this.gutterWidth+this.margin.left,C.setStyle(S,"height",_+"px"),C.setStyle(S,"width",T+"px"),C.translate(this.textarea,Math.min(w,this.$size.scrollerWidth-T),Math.min(I,k))}}},M.prototype.getFirstVisibleRow=function(){return this.layerConfig.firstRow},M.prototype.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(this.layerConfig.offset===0?0:1)},M.prototype.getLastFullyVisibleRow=function(){var S=this.layerConfig,O=S.lastRow,x=this.session.documentToScreenRow(O,0)*S.lineHeight;return x-this.session.getScrollTop()>S.height-S.lineHeight?O-1:O},M.prototype.getLastVisibleRow=function(){return this.layerConfig.lastRow},M.prototype.setPadding=function(S){this.$padding=S,this.$textLayer.setPadding(S),this.$cursorLayer.setPadding(S),this.$markerFront.setPadding(S),this.$markerBack.setPadding(S),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},M.prototype.setScrollMargin=function(S,O,x,L){var I=this.scrollMargin;I.top=S|0,I.bottom=O|0,I.right=L|0,I.left=x|0,I.v=I.top+I.bottom,I.h=I.left+I.right,I.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-I.top),this.updateFull()},M.prototype.setMargin=function(S,O,x,L){var I=this.margin;I.top=S|0,I.bottom=O|0,I.right=L|0,I.left=x|0,I.v=I.top+I.bottom,I.h=I.left+I.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},M.prototype.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},M.prototype.setHScrollBarAlwaysVisible=function(S){this.setOption("hScrollBarAlwaysVisible",S)},M.prototype.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},M.prototype.setVScrollBarAlwaysVisible=function(S){this.setOption("vScrollBarAlwaysVisible",S)},M.prototype.$updateScrollBarV=function(){var S=this.layerConfig.maxHeight,O=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(S-=(O-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>S-O&&(S=this.scrollTop+O,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(S+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},M.prototype.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},M.prototype.freeze=function(){this.$frozen=!0},M.prototype.unfreeze=function(){this.$frozen=!1},M.prototype.$renderChanges=function(S,O){if(this.$changes&&(S|=this.$changes,this.$changes=0),!this.session||!this.container.offsetWidth||this.$frozen||!S&&!O){this.$changes|=S;return}if(this.$size.$dirty)return this.$changes|=S,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",S),this.session&&this.session.$bidiHandler&&this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);var x=this.layerConfig;if(S&this.CHANGE_FULL||S&this.CHANGE_SIZE||S&this.CHANGE_TEXT||S&this.CHANGE_LINES||S&this.CHANGE_SCROLL||S&this.CHANGE_H_SCROLL){if(S|=this.$computeLayerConfig()|this.$loop.clear(),x.firstRow!=this.layerConfig.firstRow&&x.firstRowScreen==this.layerConfig.firstRowScreen){var L=this.scrollTop+(x.firstRow-Math.max(this.layerConfig.firstRow,0))*this.lineHeight;L>0&&(this.scrollTop=L,S=S|this.CHANGE_SCROLL,S|=this.$computeLayerConfig()|this.$loop.clear())}x=this.layerConfig,this.$updateScrollBarV(),S&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),C.translate(this.content,-this.scrollLeft,-x.offset);var I=x.width+2*this.$padding+"px",w=x.minHeight+"px";C.setStyle(this.content.style,"width",I),C.setStyle(this.content.style,"height",w)}if(S&this.CHANGE_H_SCROLL&&(C.translate(this.content,-this.scrollLeft,-x.offset),this.scroller.className=this.scrollLeft<=0?"ace_scroller ":"ace_scroller ace_scroll-left ",this.enableKeyboardAccessibility&&(this.scroller.className+=this.keyboardFocusClassName)),S&this.CHANGE_FULL){this.$changedLines=null,this.$textLayer.update(x),this.$showGutter&&this.$gutterLayer.update(x),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(x),this.$markerBack.update(x),this.$markerFront.update(x),this.$cursorLayer.update(x),this.$moveTextAreaToCursor(),this._signal("afterRender",S);return}if(S&this.CHANGE_SCROLL){this.$changedLines=null,S&this.CHANGE_TEXT||S&this.CHANGE_LINES?this.$textLayer.update(x):this.$textLayer.scrollLines(x),this.$showGutter&&(S&this.CHANGE_GUTTER||S&this.CHANGE_LINES?this.$gutterLayer.update(x):this.$gutterLayer.scrollLines(x)),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(x),this.$markerBack.update(x),this.$markerFront.update(x),this.$cursorLayer.update(x),this.$moveTextAreaToCursor(),this._signal("afterRender",S);return}S&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(x),this.$showGutter&&this.$gutterLayer.update(x),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(x)):S&this.CHANGE_LINES?((this.$updateLines()||S&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(x),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(x)):S&this.CHANGE_TEXT||S&this.CHANGE_GUTTER?(this.$showGutter&&this.$gutterLayer.update(x),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(x)):S&this.CHANGE_CURSOR&&(this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(x),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(x)),S&this.CHANGE_CURSOR&&(this.$cursorLayer.update(x),this.$moveTextAreaToCursor()),S&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(x),S&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(x),this._signal("afterRender",S)},M.prototype.$autosize=function(){var S=this.session.getScreenLength()*this.lineHeight,O=this.$maxLines*this.lineHeight,x=Math.min(O,Math.max((this.$minLines||1)*this.lineHeight,S))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(x+=this.scrollBarH.getHeight()),this.$maxPixelHeight&&x>this.$maxPixelHeight&&(x=this.$maxPixelHeight);var L=x<=2*this.lineHeight,I=!L&&S>O;if(x!=this.desiredHeight||this.$size.height!=this.desiredHeight||I!=this.$vScroll){I!=this.$vScroll&&(this.$vScroll=I,this.scrollBarV.setVisible(I));var w=this.container.clientWidth;this.container.style.height=x+"px",this.$updateCachedSize(!0,this.$gutterWidth,w,x),this.desiredHeight=x,this._signal("autosize")}},M.prototype.$computeLayerConfig=function(){var S=this.session,O=this.$size,x=O.height<=2*this.lineHeight,L=this.session.getScreenLength(),I=L*this.lineHeight,w=this.$getLongestLine(),_=!x&&(this.$hScrollBarAlwaysVisible||O.scrollerWidth-w-2*this.$padding<0),T=this.$horizScroll!==_;T&&(this.$horizScroll=_,this.scrollBarH.setVisible(_));var k=this.$vScroll;this.$maxLines&&this.lineHeight>1&&(this.$autosize(),x=O.height<=2*this.lineHeight);var R=O.scrollerHeight+this.lineHeight,D=!this.$maxLines&&this.$scrollPastEnd?(O.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;I+=D;var V=this.scrollMargin;this.session.setScrollTop(Math.max(-V.top,Math.min(this.scrollTop,I-O.scrollerHeight+V.bottom))),this.session.setScrollLeft(Math.max(-V.left,Math.min(this.scrollLeft,w+2*this.$padding-O.scrollerWidth+V.right)));var B=!x&&(this.$vScrollBarAlwaysVisible||O.scrollerHeight-I+D<0||this.scrollTop>V.top),F=k!==B;F&&(this.$vScroll=B,this.scrollBarV.setVisible(B));var H=this.scrollTop%this.lineHeight,U=Math.ceil(R/this.lineHeight)-1,z=Math.max(0,Math.round((this.scrollTop-H)/this.lineHeight)),K=z+U,Y,Q,J=this.lineHeight;z=S.screenToDocumentRow(z,0);var ne=S.getFoldLine(z);ne&&(z=ne.start.row),Y=S.documentToScreenRow(z,0),Q=S.getRowLength(z)*J,K=Math.min(S.screenToDocumentRow(K,0),S.getLength()-1),R=O.scrollerHeight+S.getRowLength(K)*J+Q,H=this.scrollTop-Y*J;var re=0;return(this.layerConfig.width!=w||T)&&(re=this.CHANGE_H_SCROLL),(T||F)&&(re|=this.$updateCachedSize(!0,this.gutterWidth,O.width,O.height),this._signal("scrollbarVisibilityChanged"),F&&(w=this.$getLongestLine())),this.layerConfig={width:w,padding:this.$padding,firstRow:z,firstRowScreen:Y,lastRow:K,lineHeight:J,characterWidth:this.characterWidth,minHeight:R,maxHeight:I,offset:H,gutterOffset:J?Math.max(0,Math.ceil((H+O.height-O.scrollerHeight)/J)):0,height:this.$size.scrollerHeight},this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(w-this.$padding),re},M.prototype.$updateLines=function(){if(this.$changedLines){var S=this.$changedLines.firstRow,O=this.$changedLines.lastRow;this.$changedLines=null;var x=this.layerConfig;if(!(S>x.lastRow+1)&&!(O<x.firstRow)){if(O===1/0){this.$showGutter&&this.$gutterLayer.update(x),this.$textLayer.update(x);return}return this.$textLayer.updateLines(x,S,O),!0}}},M.prototype.$getLongestLine=function(){var S=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(S+=1),this.$textLayer&&S>this.$textLayer.MAX_LINE_LENGTH&&(S=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(S*this.characterWidth))},M.prototype.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},M.prototype.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},M.prototype.addGutterDecoration=function(S,O){this.$gutterLayer.addGutterDecoration(S,O)},M.prototype.removeGutterDecoration=function(S,O){this.$gutterLayer.removeGutterDecoration(S,O)},M.prototype.updateBreakpoints=function(S){this._rows=S,this.$loop.schedule(this.CHANGE_GUTTER)},M.prototype.setAnnotations=function(S){this.$gutterLayer.setAnnotations(S),this.$loop.schedule(this.CHANGE_GUTTER)},M.prototype.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},M.prototype.hideCursor=function(){this.$cursorLayer.hideCursor()},M.prototype.showCursor=function(){this.$cursorLayer.showCursor()},M.prototype.scrollSelectionIntoView=function(S,O,x){this.scrollCursorIntoView(S,x),this.scrollCursorIntoView(O,x)},M.prototype.scrollCursorIntoView=function(S,O,x){if(this.$size.scrollerHeight!==0){var L=this.$cursorLayer.getPixelPosition(S),I=L.left,w=L.top,_=x&&x.top||0,T=x&&x.bottom||0;this.$scrollAnimation&&(this.$stopAnimation=!0);var k=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;k+_>w?(O&&k+_>w+this.lineHeight&&(w-=O*this.$size.scrollerHeight),w===0&&(w=-this.scrollMargin.top),this.session.setScrollTop(w)):k+this.$size.scrollerHeight-T<w+this.lineHeight&&(O&&k+this.$size.scrollerHeight-T<w-this.lineHeight&&(w+=O*this.$size.scrollerHeight),this.session.setScrollTop(w+this.lineHeight+T-this.$size.scrollerHeight));var R=this.scrollLeft,D=2*this.layerConfig.characterWidth;I-D<R?(I-=D,I<this.$padding+D&&(I=-this.scrollMargin.left),this.session.setScrollLeft(I)):(I+=D,R+this.$size.scrollerWidth<I+this.characterWidth?this.session.setScrollLeft(Math.round(I+this.characterWidth-this.$size.scrollerWidth)):R<=this.$padding&&I-R<this.characterWidth&&this.session.setScrollLeft(0))}},M.prototype.getScrollTop=function(){return this.session.getScrollTop()},M.prototype.getScrollLeft=function(){return this.session.getScrollLeft()},M.prototype.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},M.prototype.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},M.prototype.scrollToRow=function(S){this.session.setScrollTop(S*this.lineHeight)},M.prototype.alignCursor=function(S,O){typeof S=="number"&&(S={row:S,column:0});var x=this.$cursorLayer.getPixelPosition(S),L=this.$size.scrollerHeight-this.lineHeight,I=x.top-L*(O||0);return this.session.setScrollTop(I),I},M.prototype.$calcSteps=function(S,O){var x=0,L=this.STEPS,I=[],w=function(_,T,k){return k*(Math.pow(_-1,3)+1)+T};for(x=0;x<L;++x)I.push(w(x/this.STEPS,S,O-S));return I},M.prototype.scrollToLine=function(S,O,x,L){var I=this.$cursorLayer.getPixelPosition({row:S,column:0}),w=I.top;O&&(w-=this.$size.scrollerHeight/2);var _=this.scrollTop;this.session.setScrollTop(w),x!==!1&&this.animateScrolling(_,L)},M.prototype.animateScrolling=function(S,O){var x=this.scrollTop;if(!this.$animatedScroll)return;var L=this;if(S==x)return;if(this.$scrollAnimation){var I=this.$scrollAnimation.steps;if(I.length&&(S=I[0],S==x))return}var w=L.$calcSteps(S,x);this.$scrollAnimation={from:S,to:x,steps:w},clearInterval(this.$timer),L.session.setScrollTop(w.shift()),L.session.$scrollTop=x;function _(){L.$timer=clearInterval(L.$timer),L.$scrollAnimation=null,L.$stopAnimation=!1,O&&O()}this.$timer=setInterval(function(){if(L.$stopAnimation){_();return}if(!L.session)return clearInterval(L.$timer);w.length?(L.session.setScrollTop(w.shift()),L.session.$scrollTop=x):x!=null?(L.session.$scrollTop=-1,L.session.setScrollTop(x),x=null):_()},10)},M.prototype.scrollToY=function(S){this.scrollTop!==S&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=S)},M.prototype.scrollToX=function(S){this.scrollLeft!==S&&(this.scrollLeft=S),this.$loop.schedule(this.CHANGE_H_SCROLL)},M.prototype.scrollTo=function(S,O){this.session.setScrollTop(O),this.session.setScrollLeft(S)},M.prototype.scrollBy=function(S,O){O&&this.session.setScrollTop(this.session.getScrollTop()+O),S&&this.session.setScrollLeft(this.session.getScrollLeft()+S)},M.prototype.isScrollableBy=function(S,O){if(O<0&&this.session.getScrollTop()>=1-this.scrollMargin.top||O>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||S<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left||S>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right)return!0},M.prototype.pixelToScreenCoordinates=function(S,O){var x;if(this.$hasCssTransforms){x={top:0,left:0};var L=this.$fontMetrics.transformCoordinates([S,O]);S=L[1]-this.gutterWidth-this.margin.left,O=L[0]}else x=this.scroller.getBoundingClientRect();var I=S+this.scrollLeft-x.left-this.$padding,w=I/this.characterWidth,_=Math.floor((O+this.scrollTop-x.top)/this.lineHeight),T=this.$blockCursor?Math.floor(w):Math.round(w);return{row:_,column:T,side:w-T>0?1:-1,offsetX:I}},M.prototype.screenToTextCoordinates=function(S,O){var x;if(this.$hasCssTransforms){x={top:0,left:0};var L=this.$fontMetrics.transformCoordinates([S,O]);S=L[1]-this.gutterWidth-this.margin.left,O=L[0]}else x=this.scroller.getBoundingClientRect();var I=S+this.scrollLeft-x.left-this.$padding,w=I/this.characterWidth,_=this.$blockCursor?Math.floor(w):Math.round(w),T=Math.floor((O+this.scrollTop-x.top)/this.lineHeight);return this.session.screenToDocumentPosition(T,Math.max(_,0),I)},M.prototype.textToScreenCoordinates=function(S,O){var x=this.scroller.getBoundingClientRect(),L=this.session.documentToScreenPosition(S,O),I=this.$padding+(this.session.$bidiHandler.isBidiRow(L.row,S)?this.session.$bidiHandler.getPosLeft(L.column):Math.round(L.column*this.characterWidth)),w=L.row*this.lineHeight;return{pageX:x.left+I-this.scrollLeft,pageY:x.top+w-this.scrollTop}},M.prototype.visualizeFocus=function(){C.addCssClass(this.container,"ace_focus")},M.prototype.visualizeBlur=function(){C.removeCssClass(this.container,"ace_focus")},M.prototype.showComposition=function(S){this.$composition=S,S.cssText||(S.cssText=this.textarea.style.cssText),S.useTextareaForIME==null&&(S.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(C.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):S.markerId=this.session.addMarker(S.markerRange,"ace_composition_marker","text")},M.prototype.setCompositionText=function(S){var O=this.session.selection.cursor;this.addToken(S,"composition_placeholder",O.row,O.column),this.$moveTextAreaToCursor()},M.prototype.hideComposition=function(){if(this.$composition){this.$composition.markerId&&this.session.removeMarker(this.$composition.markerId),C.removeCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText=this.$composition.cssText;var S=this.session.selection.cursor;this.removeExtraToken(S.row,S.column),this.$composition=null,this.$cursorLayer.element.style.display=""}},M.prototype.setGhostText=function(S,O){var x=this.session.selection.cursor,L=O||{row:x.row,column:x.column};this.removeGhostText();var I=this.$calculateWrappedTextChunks(S,L);this.addToken(I[0].text,"ghost_text",L.row,L.column),this.$ghostText={text:S,position:{row:L.row,column:L.column}};var w=C.createElement("div");if(I.length>1){var _=this.hideTokensAfterPosition(L.row,L.column),T;I.slice(1).forEach(function(F){var H=C.createElement("div"),U=C.createElement("span");U.className="ace_ghost_text",F.wrapped&&(H.className="ghost_text_line_wrapped"),F.text.length===0&&(F.text=" "),U.appendChild(C.createTextNode(F.text)),H.appendChild(U),w.appendChild(H),T=H}),_.forEach(function(F){var H=C.createElement("span");$(F.type)||(H.className="ace_"+F.type.replace(/\./g," ace_")),H.appendChild(C.createTextNode(F.value)),T.appendChild(H)}),this.$ghostTextWidget={el:w,row:L.row,column:L.column,className:"ace_ghost_text_container"},this.session.widgetManager.addLineWidget(this.$ghostTextWidget);var k=this.$cursorLayer.getPixelPosition(L,!0),R=this.container,D=R.getBoundingClientRect().height,V=I.length*this.lineHeight,B=V<D-k.top;if(B)return;V<D?this.scrollBy(0,(I.length-1)*this.lineHeight):this.scrollToRow(L.row)}},M.prototype.$calculateWrappedTextChunks=function(S,O){var x=this.$size.scrollerWidth-this.$padding*2,L=Math.floor(x/this.characterWidth)-2;L=L<=0?60:L;for(var I=S.split(/\r?\n/),w=[],_=0;_<I.length;_++){var T=this.session.$getDisplayTokens(I[_],O.column),k=this.session.$computeWrapSplits(T,L,this.session.$tabSize);if(k.length>0){var R=0;k.push(I[_].length);for(var D=0;D<k.length;D++){var V=I[_].slice(R,k[D]);w.push({text:V,wrapped:!0}),R=k[D]}}else w.push({text:I[_],wrapped:!1})}return w},M.prototype.removeGhostText=function(){if(this.$ghostText){var S=this.$ghostText.position;this.removeExtraToken(S.row,S.column),this.$ghostTextWidget&&(this.session.widgetManager.removeLineWidget(this.$ghostTextWidget),this.$ghostTextWidget=null),this.$ghostText=null}},M.prototype.addToken=function(S,O,x,L){var I=this.session;I.bgTokenizer.lines[x]=null;var w={type:O,value:S},_=I.getTokens(x);if(L==null||!_.length)_.push(w);else for(var T=0,k=0;k<_.length;k++){var R=_[k];if(T+=R.value.length,L<=T){var D=R.value.length-(T-L),V=R.value.slice(0,D),B=R.value.slice(D);_.splice(k,1,{type:R.type,value:V},w,{type:R.type,value:B});break}}this.updateLines(x,x)},M.prototype.hideTokensAfterPosition=function(S,O){for(var x=this.session.getTokens(S),L=0,I=!1,w=[],_=0;_<x.length;_++){var T=x[_];if(L+=T.value.length,T.type!=="ghost_text"){if(I){w.push({type:T.type,value:T.value}),T.type="hidden_token";continue}L===O&&(I=!0)}}return this.updateLines(S,S),w},M.prototype.removeExtraToken=function(S,O){this.session.bgTokenizer.lines[S]=null,this.updateLines(S,S)},M.prototype.setTheme=function(S,O){var x=this;if(this.$themeId=S,x._dispatchEvent("themeChange",{theme:S}),!S||typeof S=="string"){var L=S||this.$options.theme.initialValue;a.loadModule(["theme",L],I)}else I(S);function I(w){if(x.$themeId!=S)return O&&O();if(!w||!w.cssClass)throw new Error("couldn't load module "+S+" or it didn't call define");w.$id&&(x.$themeId=w.$id),C.importCssString(w.cssText,w.cssClass,x.container),x.theme&&C.removeCssClass(x.container,x.theme.cssClass);var _="padding"in w?w.padding:"padding"in(x.theme||{})?4:x.$padding;x.$padding&&_!=x.$padding&&x.setPadding(_),x.$theme=w.cssClass,x.theme=w,C.addCssClass(x.container,w.cssClass),C.setCssClass(x.container,"ace_dark",w.isDark),x.$size&&(x.$size.width=0,x.$updateSizeAsync()),x._dispatchEvent("themeLoaded",{theme:w}),O&&O(),m.isSafari&&x.scroller&&(x.scroller.style.background="red",x.scroller.style.background="")}},M.prototype.getTheme=function(){return this.$themeId},M.prototype.setStyle=function(S,O){C.setCssClass(this.container,S,O!==!1)},M.prototype.unsetStyle=function(S){C.removeCssClass(this.container,S)},M.prototype.setCursorStyle=function(S){C.setStyle(this.scroller.style,"cursor",S)},M.prototype.setMouseCursor=function(S){C.setStyle(this.scroller.style,"cursor",S)},M.prototype.attachToShadowRoot=function(){C.importCssString(p,"ace_editor.css",this.container)},M.prototype.destroy=function(){this.freeze(),this.$fontMetrics.destroy(),this.$cursorLayer.destroy(),this.removeAllListeners(),this.container.textContent="",this.setOption("useResizeObserver",!1)},M.prototype.$updateCustomScrollbar=function(S){var O=this;this.$horizScroll=this.$vScroll=null,this.scrollBarV.element.remove(),this.scrollBarH.element.remove(),this.$scrollDecorator&&delete this.$scrollDecorator,S===!0?(this.scrollBarV=new c(this.container,this),this.scrollBarH=new i(this.container,this),this.scrollBarV.setHeight(this.$size.scrollerHeight),this.scrollBarH.setWidth(this.$size.scrollerWidth),this.scrollBarV.addEventListener("scroll",function(x){O.$scrollAnimation||O.session.setScrollTop(x.data-O.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(x){O.$scrollAnimation||O.session.setScrollLeft(x.data-O.scrollMargin.left)}),this.$scrollDecorator=new y(this.scrollBarV,this),this.$scrollDecorator.$updateDecorators()):(this.scrollBarV=new t(this.container,this),this.scrollBarH=new r(this.container,this),this.scrollBarV.addEventListener("scroll",function(x){O.$scrollAnimation||O.session.setScrollTop(x.data-O.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(x){O.$scrollAnimation||O.session.setScrollLeft(x.data-O.scrollMargin.left)}))},M.prototype.$addResizeObserver=function(){if(!(!window.ResizeObserver||this.$resizeObserver)){var S=this;this.$resizeTimer=A.delayedCall(function(){S.destroyed||S.onResize()},50),this.$resizeObserver=new window.ResizeObserver(function(O){var x=O[0].contentRect.width,L=O[0].contentRect.height;Math.abs(S.$size.width-x)>1||Math.abs(S.$size.height-L)>1?S.$resizeTimer.delay():S.$resizeTimer.cancel()}),this.$resizeObserver.observe(this.container)}},M}();N.prototype.CHANGE_CURSOR=1,N.prototype.CHANGE_MARKER=2,N.prototype.CHANGE_GUTTER=4,N.prototype.CHANGE_SCROLL=8,N.prototype.CHANGE_LINES=16,N.prototype.CHANGE_TEXT=32,N.prototype.CHANGE_SIZE=64,N.prototype.CHANGE_MARKER_BACK=128,N.prototype.CHANGE_MARKER_FRONT=256,N.prototype.CHANGE_FULL=512,N.prototype.CHANGE_H_SCROLL=1024,N.prototype.$changes=0,N.prototype.$padding=null,N.prototype.$frozen=!1,N.prototype.STEPS=8,b.implement(N.prototype,v),a.defineOptions(N.prototype,"renderer",{useResizeObserver:{set:function(M){!M&&this.$resizeObserver?(this.$resizeObserver.disconnect(),this.$resizeTimer.cancel(),this.$resizeTimer=this.$resizeObserver=null):M&&!this.$resizeObserver&&this.$addResizeObserver()}},animatedScroll:{initialValue:!1},showInvisibles:{set:function(M){this.$textLayer.setShowInvisibles(M)&&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(M){typeof M=="number"&&(this.$printMarginColumn=M),this.$showPrintMargin=!!M,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(M){this.$gutter.style.display=M?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},useSvgGutterIcons:{set:function(M){this.$gutterLayer.$useSvgGutterIcons=M},initialValue:!1},showFoldedAnnotations:{set:function(M){this.$gutterLayer.$showFoldedAnnotations=M},initialValue:!1},fadeFoldWidgets:{set:function(M){C.setCssClass(this.$gutter,"ace_fade-fold-widgets",M)},initialValue:!1},showFoldWidgets:{set:function(M){this.$gutterLayer.setShowFoldWidgets(M),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(M){this.$textLayer.setDisplayIndentGuides(M)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightIndentGuides:{set:function(M){this.$textLayer.setHighlightIndentGuides(M)==!0?this.$textLayer.$highlightIndentGuide():this.$textLayer.$clearActiveIndentGuide(this.$textLayer.$lines.cells)},initialValue:!0},highlightGutterLine:{set:function(M){this.$gutterLayer.setHighlightGutterLine(M),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},hScrollBarAlwaysVisible:{set:function(M){(!this.$hScrollBarAlwaysVisible||!this.$horizScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(M){(!this.$vScrollBarAlwaysVisible||!this.$vScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(M){typeof M=="number"&&(M=M+"px"),this.container.style.fontSize=M,this.updateFontSize()},initialValue:12},fontFamily:{set:function(M){this.container.style.fontFamily=M,this.updateFontSize()}},maxLines:{set:function(M){this.updateFull()}},minLines:{set:function(M){this.$minLines<562949953421311||(this.$minLines=0),this.updateFull()}},maxPixelHeight:{set:function(M){this.updateFull()},initialValue:0},scrollPastEnd:{set:function(M){M=+M||0,this.$scrollPastEnd!=M&&(this.$scrollPastEnd=M,this.$loop.schedule(this.CHANGE_SCROLL))},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(M){this.$gutterLayer.$fixedWidth=!!M,this.$loop.schedule(this.CHANGE_GUTTER)}},customScrollbar:{set:function(M){this.$updateCustomScrollbar(M)},initialValue:!1},theme:{set:function(M){this.setTheme(M)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0},hasCssTransforms:{},useTextareaForIME:{initialValue:!m.isMobile&&!m.isIE}}),d.VirtualRenderer=N}),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],function(l,d,E){var b=l("../lib/oop"),C=l("../lib/net"),A=l("../lib/event_emitter").EventEmitter,a=l("../config");function g(r){var t="importScripts('"+C.qualifyURL(r)+"');";try{return new Blob([t],{type:"application/javascript"})}catch{var i=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder,c=new i;return c.append(t),c.getBlob("application/javascript")}}function n(r){if(typeof Worker>"u")return{postMessage:function(){},terminate:function(){}};if(a.get("loadWorkerFromBlob")){var t=g(r),i=window.URL||window.webkitURL,c=i.createObjectURL(t);return new Worker(c)}return new Worker(r)}var s=function(r){r.postMessage||(r=this.$createWorkerFromOldConfig.apply(this,arguments)),this.$worker=r,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(){b.implement(this,A),this.$createWorkerFromOldConfig=function(r,t,i,c,h){if(l.nameToUrl&&!l.toUrl&&(l.toUrl=l.nameToUrl),a.get("packaged")||!l.toUrl)c=c||a.moduleUrl(t,"worker");else{var f=this.$normalizePath;c=c||f(l.toUrl("ace/worker/worker.js",null,"_"));var v={};r.forEach(function(p){v[p]=f(l.toUrl(p,null,"_").replace(/(\.js)?(\?.*)?$/,""))})}return this.$worker=n(c),h&&this.send("importScripts",h),this.$worker.postMessage({init:!0,tlns:v,module:t,classname:i}),this.$worker},this.onMessage=function(r){var t=r.data;switch(t.type){case"event":this._signal(t.name,{data:t.data});break;case"call":var i=this.callbacks[t.id];i&&(i(t.data),delete this.callbacks[t.id]);break;case"error":this.reportError(t.data);break;case"log":window.console&&console.log&&console.log.apply(console,t.data);break}},this.reportError=function(r){window.console&&console.error&&console.error(r)},this.$normalizePath=function(r){return C.qualifyURL(r)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker.onerror=function(r){r.preventDefault()},this.$worker=null,this.$doc&&this.$doc.off("change",this.changeListener),this.$doc=null},this.send=function(r,t){this.$worker.postMessage({command:r,args:t})},this.call=function(r,t,i){if(i){var c=this.callbackId++;this.callbacks[c]=i,t.push(c)}this.send(r,t)},this.emit=function(r,t){try{t.data&&t.data.err&&(t.data.err={message:t.data.err.message,stack:t.data.err.stack,code:t.data.err.code}),this.$worker&&this.$worker.postMessage({event:r,data:{data:t.data}})}catch(i){console.error(i.stack)}},this.attachToDocument=function(r){this.$doc&&this.terminate(),this.$doc=r,this.call("setValue",[r.getValue()]),r.on("change",this.changeListener,!0)},this.changeListener=function(r){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0)),r.action=="insert"?this.deltaQueue.push(r.start,r.lines):this.deltaQueue.push(r.start,r.end)},this.$sendDeltaQueue=function(){var r=this.deltaQueue;r&&(this.deltaQueue=null,r.length>50&&r.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:r}))}}).call(s.prototype);var o=function(r,t,i){var c=null,h=!1,f=Object.create(A),v=[],p=new s({messageBuffer:v,terminate:function(){},postMessage:function(m){v.push(m),c&&(h?setTimeout(y):y())}});p.setEmitSync=function(m){h=m};var y=function(){var m=v.shift();m.command?c[m.command].apply(c,m.args):m.event&&f._signal(m.event,m.data)};return f.postMessage=function(m){p.onMessage({data:m})},f.callback=function(m,$){this.postMessage({type:"call",id:$,data:m})},f.emit=function(m,$){this.postMessage({type:"event",name:m,data:$})},a.loadModule(["worker",t],function(m){for(c=new m[i](f);v.length;)y()}),p};d.UIWorkerClient=o,d.WorkerClient=s,d.createWorker=n}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(l,d,E){var b=l("./range").Range,C=l("./lib/event_emitter").EventEmitter,A=l("./lib/oop"),a=function(){function g(n,s,o,r,t,i){var c=this;this.length=s,this.session=n,this.doc=n.getDocument(),this.mainClass=t,this.othersClass=i,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate,!0),this.$others=r,this.$onCursorChange=function(){setTimeout(function(){c.onCursorChange()})},this.$pos=o;var h=n.getUndoManager().$undoStack||n.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=h.length,this.setup(),n.selection.on("changeCursor",this.$onCursorChange)}return g.prototype.setup=function(){var n=this,s=this.doc,o=this.session;this.selectionBefore=o.selection.toJSON(),o.selection.inMultiSelectMode&&o.selection.toSingleRange(),this.pos=s.createAnchor(this.$pos.row,this.$pos.column);var r=this.pos;r.$insertRight=!0,r.detach(),r.markerId=o.addMarker(new b(r.row,r.column,r.row,r.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach(function(t){var i=s.createAnchor(t.row,t.column);i.$insertRight=!0,i.detach(),n.others.push(i)}),o.setUndoSelect(!1)},g.prototype.showOtherMarkers=function(){if(!this.othersActive){var n=this.session,s=this;this.othersActive=!0,this.others.forEach(function(o){o.markerId=n.addMarker(new b(o.row,o.column,o.row,o.column+s.length),s.othersClass,null,!1)})}},g.prototype.hideOtherMarkers=function(){if(this.othersActive){this.othersActive=!1;for(var n=0;n<this.others.length;n++)this.session.removeMarker(this.others[n].markerId)}},g.prototype.onUpdate=function(n){if(this.$updating)return this.updateAnchors(n);var s=n;if(s.start.row===s.end.row&&s.start.row===this.pos.row){this.$updating=!0;var o=n.action==="insert"?s.end.column-s.start.column:s.start.column-s.end.column,r=s.start.column>=this.pos.column&&s.start.column<=this.pos.column+this.length+1,t=s.start.column-this.pos.column;if(this.updateAnchors(n),r&&(this.length+=o),r&&!this.session.$fromUndo){if(n.action==="insert")for(var i=this.others.length-1;i>=0;i--){var c=this.others[i],h={row:c.row,column:c.column+t};this.doc.insertMergedLines(h,n.lines)}else if(n.action==="remove")for(var i=this.others.length-1;i>=0;i--){var c=this.others[i],h={row:c.row,column:c.column+t};this.doc.remove(new b(h.row,h.column,h.row,h.column-o))}}this.$updating=!1,this.updateMarkers()}},g.prototype.updateAnchors=function(n){this.pos.onChange(n);for(var s=this.others.length;s--;)this.others[s].onChange(n);this.updateMarkers()},g.prototype.updateMarkers=function(){if(!this.$updating){var n=this,s=this.session,o=function(t,i){s.removeMarker(t.markerId),t.markerId=s.addMarker(new b(t.row,t.column,t.row,t.column+n.length),i,null,!1)};o(this.pos,this.mainClass);for(var r=this.others.length;r--;)o(this.others[r],this.othersClass)}},g.prototype.onCursorChange=function(n){if(!(this.$updating||!this.session)){var s=this.session.selection.getCursor();s.row===this.pos.row&&s.column>=this.pos.column&&s.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",n)):(this.hideOtherMarkers(),this._emit("cursorLeave",n))}},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 n=this.session.getUndoManager(),s=(n.$undoStack||n.$undostack).length-this.$undoStackDepth,o=0;o<s;o++)n.undo(this.session,!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}},g}();A.implement(a.prototype,C),d.PlaceHolder=a}),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(l,d,E){var b=l("../lib/event"),C=l("../lib/useragent");function A(g,n){return g.row==n.row&&g.column==n.column}function a(g){var n=g.domEvent,s=n.altKey,o=n.shiftKey,r=n.ctrlKey,t=g.getAccelKey(),i=g.getButton();if(r&&C.isMac&&(i=n.button),g.editor.inMultiSelectMode&&i==2){g.editor.textInput.onContextMenu(g.domEvent);return}if(!r&&!s&&!t){i===0&&g.editor.inMultiSelectMode&&g.editor.exitMultiSelectMode();return}if(i===0){var c=g.editor,h=c.selection,f=c.inMultiSelectMode,v=g.getDocumentPosition(),p=h.getCursor(),y=g.inSelection()||h.isEmpty()&&A(v,p),m=g.x,$=g.y,N=function(V){m=V.clientX,$=V.clientY},M=c.session,S=c.renderer.pixelToScreenCoordinates(m,$),O=S,x;if(c.$mouseHandler.$enableJumpToDef)r&&s||t&&s?x=o?"block":"add":s&&c.$blockSelectEnabled&&(x="block");else if(t&&!s){if(x="add",!f&&o)return}else s&&c.$blockSelectEnabled&&(x="block");if(x&&C.isMac&&n.ctrlKey&&c.$mouseHandler.cancelContextMenu(),x=="add"){if(!f&&y)return;if(!f){var L=h.toOrientedRange();c.addSelectionMarker(L)}var I=h.rangeList.rangeAtPoint(v);c.inVirtualSelectionMode=!0,o&&(I=null,L=h.ranges[0]||L,c.removeSelectionMarker(L)),c.once("mouseup",function(){var V=h.toOrientedRange();I&&V.isEmpty()&&A(I.cursor,V.cursor)?h.substractPoint(V.cursor):(o?h.substractPoint(L.cursor):L&&(c.removeSelectionMarker(L),h.addRange(L)),h.addRange(V)),c.inVirtualSelectionMode=!1})}else if(x=="block"){g.stop(),c.inVirtualSelectionMode=!0;var w,_=[],T=function(){var V=c.renderer.pixelToScreenCoordinates(m,$),B=M.screenToDocumentPosition(V.row,V.column,V.offsetX);A(O,V)&&A(B,h.lead)||(O=V,c.selection.moveToPosition(B),c.renderer.scrollCursorIntoView(),c.removeSelectionMarkers(_),_=h.rectangularRangeBlock(O,S),c.$mouseHandler.$clickSelection&&_.length==1&&_[0].isEmpty()&&(_[0]=c.$mouseHandler.$clickSelection.clone()),_.forEach(c.addSelectionMarker,c),c.updateSelectionMarkers())};f&&!t?h.toSingleRange():!f&&t&&(w=h.toOrientedRange(),c.addSelectionMarker(w)),o?S=M.documentToScreenPosition(h.lead):h.moveToPosition(v),O={row:-1,column:-1};var k=function(V){T(),clearInterval(D),c.removeSelectionMarkers(_),_.length||(_=[h.toOrientedRange()]),w&&(c.removeSelectionMarker(w),h.toSingleRange(w));for(var B=0;B<_.length;B++)h.addRange(_[B]);c.inVirtualSelectionMode=!1,c.$mouseHandler.$clickSelection=null},R=T;b.capture(c.container,N,k);var D=setInterval(function(){R()},20);return g.preventDefault()}}}d.onMouseDown=a}),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],function(l,d,E){d.defaultCommands=[{name:"addCursorAbove",description:"Add cursor above",exec:function(C){C.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelow",description:"Add cursor below",exec:function(C){C.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(C){C.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(C){C.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(C){C.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreAfter",description:"Select more after",exec:function(C){C.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",mac:"Ctrl-Alt-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextBefore",description:"Select next before",exec:function(C){C.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(C){C.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(C){C.multiSelect.rangeCount>1?C.multiSelect.joinSelections():C.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readOnly:!0},{name:"splitSelectionIntoLines",description:"Split into lines",exec:function(C){C.multiSelect.splitIntoLines()},readOnly:!0},{name:"alignCursors",description:"Align cursors",exec:function(C){C.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",description:"Find all",exec:function(C){C.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readOnly:!0}],d.multiSelectCommands=[{name:"singleSelection",description:"Single selection",bindKey:"esc",exec:function(C){C.exitMultiSelectMode()},scrollIntoView:"cursor",readOnly:!0,isAvailable:function(C){return C&&C.inMultiSelectMode}}];var b=l("../keyboard/hash_handler").HashHandler;d.keyboardHandler=new b(d.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(l,d,E){var b=l("./range_list").RangeList,C=l("./range").Range,A=l("./selection").Selection,a=l("./mouse/multi_select_handler").onMouseDown,g=l("./lib/event"),n=l("./lib/lang"),s=l("./commands/multi_select_commands");d.commands=s.defaultCommands.concat(s.multiSelectCommands);var o=l("./search").Search,r=new o;function t(p,y,m){return r.$options.wrap=!0,r.$options.needle=y,r.$options.backwards=m==-1,r.find(p)}var i=l("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(i.prototype),(function(){this.ranges=null,this.rangeList=null,this.addRange=function(p,y){if(p){if(!this.inMultiSelectMode&&this.rangeCount===0){var m=this.toOrientedRange();if(this.rangeList.add(m),this.rangeList.add(p),this.rangeList.ranges.length!=2)return this.rangeList.removeAll(),y||this.fromOrientedRange(p);this.rangeList.removeAll(),this.rangeList.add(m),this.$onAddRange(m)}p.cursor||(p.cursor=p.end);var $=this.rangeList.add(p);return this.$onAddRange(p),$.length&&this.$onRemoveRange($),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),y||this.fromOrientedRange(p)}},this.toSingleRange=function(p){p=p||this.ranges[0];var y=this.rangeList.removeAll();y.length&&this.$onRemoveRange(y),p&&this.fromOrientedRange(p)},this.substractPoint=function(p){var y=this.rangeList.substractPoint(p);if(y)return this.$onRemoveRange(y),y[0]},this.mergeOverlappingRanges=function(){var p=this.rangeList.merge();p.length&&this.$onRemoveRange(p)},this.$onAddRange=function(p){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(p),this._signal("addRange",{range:p})},this.$onRemoveRange=function(p){if(this.rangeCount=this.rangeList.ranges.length,this.rangeCount==1&&this.inMultiSelectMode){var y=this.rangeList.ranges.pop();p.push(y),this.rangeCount=0}for(var m=p.length;m--;){var $=this.ranges.indexOf(p[m]);this.ranges.splice($,1)}this._signal("removeRange",{ranges:p}),this.rangeCount===0&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),y=y||this.ranges[0],y&&!y.isEqual(this.getRange())&&this.fromOrientedRange(y)},this.$initRangeList=function(){this.rangeList||(this.rangeList=new b,this.ranges=[],this.rangeCount=0)},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){for(var p=this.ranges.length?this.ranges:[this.getRange()],y=[],m=0;m<p.length;m++){var $=p[m],N=$.start.row,M=$.end.row;if(N===M)y.push($.clone());else{for(y.push(new C(N,$.start.column,N,this.session.getLine(N).length));++N<M;)y.push(this.getLineRange(N,!0));y.push(new C(M,0,M,$.end.column))}m==0&&!this.isBackwards()&&(y=y.reverse())}this.toSingleRange();for(var m=y.length;m--;)this.addRange(y[m])},this.joinSelections=function(){var p=this.rangeList.ranges,y=p[p.length-1],m=C.fromPoints(p[0].start,y.end);this.toSingleRange(),this.setSelectionRange(m,y.cursor==y.start)},this.toggleBlockSelection=function(){if(this.rangeCount>1){var p=this.rangeList.ranges,y=p[p.length-1],m=C.fromPoints(p[0].start,y.end);this.toSingleRange(),this.setSelectionRange(m,y.cursor==y.start)}else{var $=this.session.documentToScreenPosition(this.cursor),N=this.session.documentToScreenPosition(this.anchor),M=this.rectangularRangeBlock($,N);M.forEach(this.addRange,this)}},this.rectangularRangeBlock=function(p,y,m){var $=[],N=p.column<y.column;if(N)var M=p.column,S=y.column,O=p.offsetX,x=y.offsetX;else var M=y.column,S=p.column,O=y.offsetX,x=p.offsetX;var L=p.row<y.row;if(L)var I=p.row,w=y.row;else var I=y.row,w=p.row;M<0&&(M=0),I<0&&(I=0),I==w&&(m=!0);for(var _,T=I;T<=w;T++){var k=C.fromPoints(this.session.screenToDocumentPosition(T,M,O),this.session.screenToDocumentPosition(T,S,x));if(k.isEmpty()){if(_&&h(k.end,_))break;_=k.end}k.cursor=N?k.start:k.end,$.push(k)}if(L&&$.reverse(),!m){for(var R=$.length-1;$[R].isEmpty()&&R>0;)R--;if(R>0)for(var D=0;$[D].isEmpty();)D++;for(var V=R;V>=D;V--)$[V].isEmpty()&&$.splice(V,1)}return $}}).call(A.prototype);var c=l("./editor").Editor;(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(p){p.cursor||(p.cursor=p.end);var y=this.getSelectionStyle();return p.marker=this.session.addMarker(p,"ace_selection",y),this.session.$selectionMarkers.push(p),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,p},this.removeSelectionMarker=function(p){if(p.marker){this.session.removeMarker(p.marker);var y=this.session.$selectionMarkers.indexOf(p);y!=-1&&this.session.$selectionMarkers.splice(y,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length}},this.removeSelectionMarkers=function(p){for(var y=this.session.$selectionMarkers,m=p.length;m--;){var $=p[m];if($.marker){this.session.removeMarker($.marker);var N=y.indexOf($);N!=-1&&y.splice(N,1)}}this.session.selectionMarkerCount=y.length},this.$onAddRange=function(p){this.addSelectionMarker(p.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(p){this.removeSelectionMarkers(p.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(p){this.inMultiSelectMode||(this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(s.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers())},this.$onSingleSelect=function(p){this.session.multiSelect.inVirtualMode||(this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(s.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection"))},this.$onMultiSelectExec=function(p){var y=p.command,m=p.editor;if(m.multiSelect){if(y.multiSelectAction)y.multiSelectAction=="forEach"?$=m.forEachSelection(y,p.args):y.multiSelectAction=="forEachLine"?$=m.forEachSelection(y,p.args,!0):y.multiSelectAction=="single"?(m.exitMultiSelectMode(),$=y.exec(m,p.args||{})):$=y.multiSelectAction(m,p.args||{});else{var $=y.exec(m,p.args||{});m.multiSelect.addRange(m.multiSelect.toOrientedRange()),m.multiSelect.mergeOverlappingRanges()}return $}},this.forEachSelection=function(p,y,m){if(!this.inVirtualSelectionMode){var $=m&&m.keepOrder,N=m==!0||m&&m.$byLines,M=this.session,S=this.selection,O=S.rangeList,x=($?S:O).ranges,L;if(!x.length)return p.exec?p.exec(this,y||{}):p(this,y||{});var I=S._eventRegistry;S._eventRegistry={};var w=new A(M);this.inVirtualSelectionMode=!0;for(var _=x.length;_--;){if(N)for(;_>0&&x[_].start.row==x[_-1].end.row;)_--;w.fromOrientedRange(x[_]),w.index=_,this.selection=M.selection=w;var T=p.exec?p.exec(this,y||{}):p(this,y||{});!L&&T!==void 0&&(L=T),w.toOrientedRange(x[_])}w.detach(),this.selection=M.selection=S,this.inVirtualSelectionMode=!1,S._eventRegistry=I,S.mergeOverlappingRanges(),S.ranges[0]&&S.fromOrientedRange(S.ranges[0]);var k=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),k&&k.from==k.to&&this.renderer.animateScrolling(k.from),L}},this.exitMultiSelectMode=function(){!this.inMultiSelectMode||this.inVirtualSelectionMode||this.multiSelect.toSingleRange()},this.getSelectedText=function(){var p="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var y=this.multiSelect.rangeList.ranges,m=[],$=0;$<y.length;$++)m.push(this.session.getTextRange(y[$]));var N=this.session.getDocument().getNewLineCharacter();p=m.join(N),p.length==(m.length-1)*N.length&&(p="")}else this.selection.isEmpty()||(p=this.session.getTextRange(this.getSelectionRange()));return p},this.$checkMultiselectChange=function(p,y){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var m=this.multiSelect.ranges[0];if(this.multiSelect.isEmpty()&&y==this.multiSelect.anchor)return;var $=y==this.multiSelect.anchor?m.cursor==m.start?m.end:m.start:m.cursor;$.row!=y.row||this.session.$clipPositionToDocument($.row,$.column).column!=y.column?this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()):this.multiSelect.mergeOverlappingRanges()}},this.findAll=function(p,y,m){if(y=y||{},y.needle=p||y.needle,y.needle==null){var $=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();y.needle=this.session.getTextRange($)}this.$search.set(y);var N=this.$search.findAll(this.session);if(!N.length)return 0;var M=this.multiSelect;m||M.toSingleRange(N[0]);for(var S=N.length;S--;)M.addRange(N[S],!0);return $&&M.rangeList.rangeAtPoint($.start)&&M.addRange($,!0),N.length},this.selectMoreLines=function(p,y){var m=this.selection.toOrientedRange(),$=m.cursor==m.end,N=this.session.documentToScreenPosition(m.cursor);this.selection.$desiredColumn&&(N.column=this.selection.$desiredColumn);var M=this.session.screenToDocumentPosition(N.row+p,N.column);if(m.isEmpty())var O=M;else var S=this.session.documentToScreenPosition($?m.end:m.start),O=this.session.screenToDocumentPosition(S.row+p,S.column);if($){var x=C.fromPoints(M,O);x.cursor=x.start}else{var x=C.fromPoints(O,M);x.cursor=x.end}if(x.desiredColumn=N.column,!this.selection.inMultiSelectMode)this.selection.addRange(m);else if(y)var L=m.cursor;this.selection.addRange(x),L&&this.selection.substractPoint(L)},this.transposeSelections=function(p){for(var y=this.session,m=y.multiSelect,$=m.ranges,N=$.length;N--;){var M=$[N];if(M.isEmpty()){var S=y.getWordRange(M.start.row,M.start.column);M.start.row=S.start.row,M.start.column=S.start.column,M.end.row=S.end.row,M.end.column=S.end.column}}m.mergeOverlappingRanges();for(var O=[],N=$.length;N--;){var M=$[N];O.unshift(y.getTextRange(M))}p<0?O.unshift(O.pop()):O.push(O.shift());for(var N=$.length;N--;){var M=$[N],x=M.clone();y.replace(M,O[N]),M.start.row=x.start.row,M.start.column=x.start.column}m.fromOrientedRange(m.ranges[0])},this.selectMore=function(p,y,m){var $=this.session,N=$.multiSelect,M=N.toOrientedRange();if(!(M.isEmpty()&&(M=$.getWordRange(M.start.row,M.start.column),M.cursor=p==-1?M.start:M.end,this.multiSelect.addRange(M),m))){var S=$.getTextRange(M),O=t($,S,p);O&&(O.cursor=p==-1?O.start:O.end,this.session.unfold(O),this.multiSelect.addRange(O),this.renderer.scrollCursorIntoView(null,.5)),y&&this.multiSelect.substractPoint(M.cursor)}},this.alignCursors=function(){var p=this.session,y=p.multiSelect,m=y.ranges,$=-1,N=m.filter(function(R){if(R.cursor.row==$)return!0;$=R.cursor.row});if(!m.length||N.length==m.length-1){var M=this.selection.getRange(),S=M.start.row,O=M.end.row,x=S==O;if(x){var L=this.session.getLength(),I;do I=this.session.getLine(O);while(/[=:]/.test(I)&&++O<L);do I=this.session.getLine(S);while(/[=:]/.test(I)&&--S>0);S<0&&(S=0),O>=L&&(O=L-1)}var w=this.session.removeFullLines(S,O);w=this.$reAlignText(w,x),this.session.insert({row:S,column:0},w.join(`
951
+ `)+`
952
+ `),x||(M.start.column=0,M.end.column=w[w.length-1].length),this.selection.setRange(M)}else{N.forEach(function(R){y.substractPoint(R.cursor)});var _=0,T=1/0,k=m.map(function(R){var D=R.cursor,V=p.getLine(D.row),B=V.substr(D.column).search(/\S/g);return B==-1&&(B=0),D.column>_&&(_=D.column),B<T&&(T=B),B});m.forEach(function(R,D){var V=R.cursor,B=_-V.column,F=k[D]-T;B>F?p.insert(V,n.stringRepeat(" ",B-F)):p.remove(new C(V.row,V.column,V.row,V.column-B+F)),R.start.column=R.end.column=_,R.start.row=R.end.row=V.row,R.cursor=R.end}),y.fromOrientedRange(m[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}},this.$reAlignText=function(p,y){var m=!0,$=!0,N,M,S;return p.map(function(w){var _=w.match(/(\s*)(.*?)(\s*)([=:].*)/);return _?N==null?(N=_[1].length,M=_[2].length,S=_[3].length,_):(N+M+S!=_[1].length+_[2].length+_[3].length&&($=!1),N!=_[1].length&&(m=!1),N>_[1].length&&(N=_[1].length),M<_[2].length&&(M=_[2].length),S>_[3].length&&(S=_[3].length),_):[w]}).map(y?x:m?$?L:x:I);function O(w){return n.stringRepeat(" ",w)}function x(w){return w[2]?O(N)+w[2]+O(M-w[2].length+S)+w[4].replace(/^([=:])\s+/,"$1 "):w[0]}function L(w){return w[2]?O(N+M-w[2].length)+w[2]+O(S)+w[4].replace(/^([=:])\s+/,"$1 "):w[0]}function I(w){return w[2]?O(N)+w[2]+O(S)+w[4].replace(/^([=:])\s+/,"$1 "):w[0]}}}).call(c.prototype);function h(p,y){return p.row==y.row&&p.column==y.column}d.onSessionChange=function(p){var y=p.session;y&&!y.multiSelect&&(y.$selectionMarkers=[],y.selection.$initRangeList(),y.multiSelect=y.selection),this.multiSelect=y&&y.multiSelect;var m=p.oldSession;m&&(m.multiSelect.off("addRange",this.$onAddRange),m.multiSelect.off("removeRange",this.$onRemoveRange),m.multiSelect.off("multiSelect",this.$onMultiSelect),m.multiSelect.off("singleSelect",this.$onSingleSelect),m.multiSelect.lead.off("change",this.$checkMultiselectChange),m.multiSelect.anchor.off("change",this.$checkMultiselectChange)),y&&(y.multiSelect.on("addRange",this.$onAddRange),y.multiSelect.on("removeRange",this.$onRemoveRange),y.multiSelect.on("multiSelect",this.$onMultiSelect),y.multiSelect.on("singleSelect",this.$onSingleSelect),y.multiSelect.lead.on("change",this.$checkMultiselectChange),y.multiSelect.anchor.on("change",this.$checkMultiselectChange)),y&&this.inMultiSelectMode!=y.selection.inMultiSelectMode&&(y.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())};function f(p){p.$multiselectOnSessionChange||(p.$onAddRange=p.$onAddRange.bind(p),p.$onRemoveRange=p.$onRemoveRange.bind(p),p.$onMultiSelect=p.$onMultiSelect.bind(p),p.$onSingleSelect=p.$onSingleSelect.bind(p),p.$multiselectOnSessionChange=d.onSessionChange.bind(p),p.$checkMultiselectChange=p.$checkMultiselectChange.bind(p),p.$multiselectOnSessionChange(p),p.on("changeSession",p.$multiselectOnSessionChange),p.on("mousedown",a),p.commands.addCommands(s.defaultCommands),v(p))}function v(p){if(!p.textInput)return;var y=p.textInput.getElement(),m=!1;g.addListener(y,"keydown",function(N){var M=N.keyCode==18&&!(N.ctrlKey||N.shiftKey||N.metaKey);p.$blockSelectEnabled&&M?m||(p.renderer.setMouseCursor("crosshair"),m=!0):m&&$()},p),g.addListener(y,"keyup",$,p),g.addListener(y,"blur",$,p);function $(N){m&&(p.renderer.setMouseCursor(""),m=!1)}}d.MultiSelect=f,l("./config").defineOptions(c.prototype,"editor",{enableMultiselect:{set:function(p){f(this),p?this.on("mousedown",a):this.off("mousedown",a)},value:!0},enableBlockSelect:{set:function(p){this.$blockSelectEnabled=p},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(l,d,E){var b=l("../../range").Range,C=d.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(A,a,g){var n=A.getLine(g);return this.foldingStartMarker.test(n)?"start":a=="markbeginend"&&this.foldingStopMarker&&this.foldingStopMarker.test(n)?"end":""},this.getFoldWidgetRange=function(A,a,g){return null},this.indentationBlock=function(A,a,g){var n=/\S/,s=A.getLine(a),o=s.search(n);if(o!=-1){for(var r=g||s.length,t=A.getLength(),i=a,c=a;++a<t;){var h=A.getLine(a).search(n);if(h!=-1){if(h<=o){var f=A.getTokenAt(a,0);if(!f||f.type!=="string")break}c=a}}if(c>i){var v=A.getLine(c).length;return new b(i,r,c,v)}}},this.openingBracketBlock=function(A,a,g,n,s){var o={row:g,column:n+1},r=A.$findClosingBracket(a,o,s);if(r){var t=A.foldWidgets[r.row];return t==null&&(t=A.getFoldWidget(r.row)),t=="start"&&r.row>o.row&&(r.row--,r.column=A.getLine(r.row).length),b.fromPoints(o,r)}},this.closingBracketBlock=function(A,a,g,n,s){var o={row:g,column:n},r=A.$findOpeningBracket(a,o);if(r)return r.column++,o.column--,b.fromPoints(r,o)}}).call(C.prototype)}),ace.define("ace/ext/error_marker",["require","exports","module","ace/lib/dom","ace/range","ace/config"],function(l,d,E){var b=l("../lib/dom"),C=l("../range").Range,A=l("../config").nls;function a(n,s,o){for(var r=0,t=n.length-1;r<=t;){var i=r+t>>1,c=o(s,n[i]);if(c>0)r=i+1;else if(c<0)t=i-1;else return i}return-(r+1)}function g(n,s,o){var r=n.getAnnotations().sort(C.comparePoints);if(r.length){var t=a(r,{row:s,column:-1},C.comparePoints);t<0&&(t=-t-1),t>=r.length?t=o>0?0:r.length-1:t===0&&o<0&&(t=r.length-1);var i=r[t];if(!(!i||!o)){if(i.row===s){do i=r[t+=o];while(i&&i.row===s);if(!i)return r.slice()}var c=[];s=i.row;do c[o<0?"unshift":"push"](i),i=r[t+=o];while(i&&i.row==s);return c.length&&c}}}d.showErrorMarker=function(n,s){var o=n.session,r=n.getCursorPosition(),t=r.row,i=o.widgetManager.getWidgetsAtRow(t).filter(function(N){return N.type=="errorMarker"})[0];i?i.destroy():t-=s;var c=g(o,t,s),h;if(c){var f=c[0];r.column=(f.pos&&typeof f.column!="number"?f.pos.sc:f.column)||0,r.row=f.row,h=n.renderer.$gutterLayer.$annotations[r.row]}else{if(i)return;h={displayText:[A("error-marker.good-state","Looks good!")],className:"ace_ok"}}n.session.unfold(r.row),n.selection.moveToPosition(r);var v={row:r.row,fixedWidth:!0,coverGutter:!0,el:b.createElement("div"),type:"errorMarker"},p=v.el.appendChild(b.createElement("div")),y=v.el.appendChild(b.createElement("div"));y.className="error_widget_arrow "+h.className;var m=n.renderer.$cursorLayer.getPixelPosition(r).left;y.style.left=m+n.renderer.gutterWidth-5+"px",v.el.className="error_widget_wrapper",p.className="error_widget "+h.className,h.displayText.forEach(function(N,M){p.appendChild(b.createTextNode(N)),M<h.displayText.length-1&&p.appendChild(b.createElement("br"))}),p.appendChild(b.createElement("div"));var $=function(N,M,S){if(M===0&&(S==="esc"||S==="return"))return v.destroy(),{command:"null"}};v.destroy=function(){n.$mouseHandler.isMousePressed||(n.keyBinding.removeKeyboardHandler($),o.widgetManager.removeLineWidget(v),n.off("changeSelection",v.destroy),n.off("changeSession",v.destroy),n.off("mouseup",v.destroy),n.off("change",v.destroy))},n.keyBinding.addKeyboardHandler($),n.on("changeSelection",v.destroy),n.on("changeSession",v.destroy),n.on("mouseup",v.destroy),n.on("change",v.destroy),n.session.widgetManager.addLineWidget(v),v.el.onmousedown=n.focus.bind(n),n.renderer.scrollCursorIntoView(null,.5,{bottom:v.el.offsetHeight})},b.importCssString(`
953
+ .error_widget_wrapper {
954
+ background: inherit;
955
+ color: inherit;
956
+ border:none
957
+ }
958
+ .error_widget {
959
+ border-top: solid 2px;
960
+ border-bottom: solid 2px;
961
+ margin: 5px 0;
962
+ padding: 10px 40px;
963
+ white-space: pre-wrap;
964
+ }
965
+ .error_widget.ace_error, .error_widget_arrow.ace_error{
966
+ border-color: #ff5a5a
967
+ }
968
+ .error_widget.ace_warning, .error_widget_arrow.ace_warning{
969
+ border-color: #F1D817
970
+ }
971
+ .error_widget.ace_info, .error_widget_arrow.ace_info{
972
+ border-color: #5a5a5a
973
+ }
974
+ .error_widget.ace_ok, .error_widget_arrow.ace_ok{
975
+ border-color: #5aaa5a
976
+ }
977
+ .error_widget_arrow {
978
+ position: absolute;
979
+ border: solid 5px;
980
+ border-top-color: transparent!important;
981
+ border-right-color: transparent!important;
982
+ border-left-color: transparent!important;
983
+ top: -5px;
984
+ }
985
+ `,"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(l,d,E){l("./loader_build")(d);var b=l("./lib/dom"),C=l("./range").Range,A=l("./editor").Editor,a=l("./edit_session").EditSession,g=l("./undomanager").UndoManager,n=l("./virtual_renderer").VirtualRenderer;l("./worker/worker_client"),l("./keyboard/hash_handler"),l("./placeholder"),l("./multi_select"),l("./mode/folding/fold_mode"),l("./theme/textmate"),l("./ext/error_marker"),d.config=l("./config"),d.edit=function(o,r){if(typeof o=="string"){var t=o;if(o=document.getElementById(t),!o)throw new Error("ace.edit can't find div #"+t)}if(o&&o.env&&o.env.editor instanceof A)return o.env.editor;var i="";if(o&&/input|textarea/i.test(o.tagName)){var c=o;i=c.value,o=b.createElement("pre"),c.parentNode.replaceChild(o,c)}else o&&(i=o.textContent,o.innerHTML="");var h=d.createEditSession(i),f=new A(new n(o),h,r),v={document:h,editor:f,onResize:f.resize.bind(f,null)};return c&&(v.textarea=c),f.on("destroy",function(){v.editor.container.env=null}),f.container.env=f.env=v,f},d.createEditSession=function(o,r){var t=new a(o,r);return t.setUndoManager(new g),t},d.Range=C,d.Editor=A,d.EditSession=a,d.UndoManager=g,d.VirtualRenderer=n;var s=d.config.version;d.version=s}),function(){ace.require(["ace/ace"],function(l){l&&(l.config.init(!0),l.define=ace.define);var d=function(){return this}();!d&&typeof window<"u"&&(d=window),!d&&typeof self<"u"&&(d=self),d.ace||(d.ace=l);for(var E in l)l.hasOwnProperty(E)&&(d.ace[E]=l[E]);d.ace.default=d.ace,e&&(e.exports=d.ace)})}()}(ace$2)),ace$2.exports}var aceExports=requireAce();const ace$1=getDefaultExportFromCjs(aceExports);var MapShim=function(){if(typeof Map<"u")return Map;function e(u,l){var d=-1;return u.some(function(E,b){return E[0]===l?(d=b,!0):!1}),d}return function(){function u(){this.__entries__=[]}return Object.defineProperty(u.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),u.prototype.get=function(l){var d=e(this.__entries__,l),E=this.__entries__[d];return E&&E[1]},u.prototype.set=function(l,d){var E=e(this.__entries__,l);~E?this.__entries__[E][1]=d:this.__entries__.push([l,d])},u.prototype.delete=function(l){var d=this.__entries__,E=e(d,l);~E&&d.splice(E,1)},u.prototype.has=function(l){return!!~e(this.__entries__,l)},u.prototype.clear=function(){this.__entries__.splice(0)},u.prototype.forEach=function(l,d){d===void 0&&(d=null);for(var E=0,b=this.__entries__;E<b.length;E++){var C=b[E];l.call(d,C[1],C[0])}},u}()}(),isBrowser=typeof window<"u"&&typeof document<"u"&&window.document===document,global$1=function(){return typeof global<"u"&&global.Math===Math?global:typeof self<"u"&&self.Math===Math?self:typeof window<"u"&&window.Math===Math?window:Function("return this")()}(),requestAnimationFrame$1=function(){return typeof requestAnimationFrame=="function"?requestAnimationFrame.bind(global$1):function(e){return setTimeout(function(){return e(Date.now())},1e3/60)}}(),trailingTimeout=2;function throttle$1(e,u){var l=!1,d=!1,E=0;function b(){l&&(l=!1,e()),d&&A()}function C(){requestAnimationFrame$1(b)}function A(){var a=Date.now();if(l){if(a-E<trailingTimeout)return;d=!0}else l=!0,d=!1,setTimeout(C,u);E=a}return A}var REFRESH_DELAY=20,transitionKeys=["top","right","bottom","left","width","height","size","weight"],mutationObserverSupported=typeof MutationObserver<"u",ResizeObserverController=function(){function e(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=throttle$1(this.refresh.bind(this),REFRESH_DELAY)}return e.prototype.addObserver=function(u){~this.observers_.indexOf(u)||this.observers_.push(u),this.connected_||this.connect_()},e.prototype.removeObserver=function(u){var l=this.observers_,d=l.indexOf(u);~d&&l.splice(d,1),!l.length&&this.connected_&&this.disconnect_()},e.prototype.refresh=function(){var u=this.updateObservers_();u&&this.refresh()},e.prototype.updateObservers_=function(){var u=this.observers_.filter(function(l){return l.gatherActive(),l.hasActive()});return u.forEach(function(l){return l.broadcastActive()}),u.length>0},e.prototype.connect_=function(){!isBrowser||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),mutationObserverSupported?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){!isBrowser||!this.connected_||(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(u){var l=u.propertyName,d=l===void 0?"":l,E=transitionKeys.some(function(b){return!!~d.indexOf(b)});E&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e}(),defineConfigurable=function(e,u){for(var l=0,d=Object.keys(u);l<d.length;l++){var E=d[l];Object.defineProperty(e,E,{value:u[E],enumerable:!1,writable:!1,configurable:!0})}return e},getWindowOf=function(e){var u=e&&e.ownerDocument&&e.ownerDocument.defaultView;return u||global$1},emptyRect=createRectInit(0,0,0,0);function toFloat(e){return parseFloat(e)||0}function getBordersSize(e){for(var u=[],l=1;l<arguments.length;l++)u[l-1]=arguments[l];return u.reduce(function(d,E){var b=e["border-"+E+"-width"];return d+toFloat(b)},0)}function getPaddings(e){for(var u=["top","right","bottom","left"],l={},d=0,E=u;d<E.length;d++){var b=E[d],C=e["padding-"+b];l[b]=toFloat(C)}return l}function getSVGContentRect(e){var u=e.getBBox();return createRectInit(0,0,u.width,u.height)}function getHTMLElementContentRect(e){var u=e.clientWidth,l=e.clientHeight;if(!u&&!l)return emptyRect;var d=getWindowOf(e).getComputedStyle(e),E=getPaddings(d),b=E.left+E.right,C=E.top+E.bottom,A=toFloat(d.width),a=toFloat(d.height);if(d.boxSizing==="border-box"&&(Math.round(A+b)!==u&&(A-=getBordersSize(d,"left","right")+b),Math.round(a+C)!==l&&(a-=getBordersSize(d,"top","bottom")+C)),!isDocumentElement(e)){var g=Math.round(A+b)-u,n=Math.round(a+C)-l;Math.abs(g)!==1&&(A-=g),Math.abs(n)!==1&&(a-=n)}return createRectInit(E.left,E.top,A,a)}var isSVGGraphicsElement=function(){return typeof SVGGraphicsElement<"u"?function(e){return e instanceof getWindowOf(e).SVGGraphicsElement}:function(e){return e instanceof getWindowOf(e).SVGElement&&typeof e.getBBox=="function"}}();function isDocumentElement(e){return e===getWindowOf(e).document.documentElement}function getContentRect(e){return isBrowser?isSVGGraphicsElement(e)?getSVGContentRect(e):getHTMLElementContentRect(e):emptyRect}function createReadOnlyRect(e){var u=e.x,l=e.y,d=e.width,E=e.height,b=typeof DOMRectReadOnly<"u"?DOMRectReadOnly:Object,C=Object.create(b.prototype);return defineConfigurable(C,{x:u,y:l,width:d,height:E,top:l,right:u+d,bottom:E+l,left:u}),C}function createRectInit(e,u,l,d){return{x:e,y:u,width:l,height:d}}var ResizeObservation=function(){function e(u){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=createRectInit(0,0,0,0),this.target=u}return e.prototype.isActive=function(){var u=getContentRect(this.target);return this.contentRect_=u,u.width!==this.broadcastWidth||u.height!==this.broadcastHeight},e.prototype.broadcastRect=function(){var u=this.contentRect_;return this.broadcastWidth=u.width,this.broadcastHeight=u.height,u},e}(),ResizeObserverEntry=function(){function e(u,l){var d=createReadOnlyRect(l);defineConfigurable(this,{target:u,contentRect:d})}return e}(),ResizeObserverSPI=function(){function e(u,l,d){if(this.activeObservations_=[],this.observations_=new MapShim,typeof u!="function")throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=u,this.controller_=l,this.callbackCtx_=d}return e.prototype.observe=function(u){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(u instanceof getWindowOf(u).Element))throw new TypeError('parameter 1 is not of type "Element".');var l=this.observations_;l.has(u)||(l.set(u,new ResizeObservation(u)),this.controller_.addObserver(this),this.controller_.refresh())}},e.prototype.unobserve=function(u){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(u instanceof getWindowOf(u).Element))throw new TypeError('parameter 1 is not of type "Element".');var l=this.observations_;l.has(u)&&(l.delete(u),l.size||this.controller_.removeObserver(this))}},e.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},e.prototype.gatherActive=function(){var u=this;this.clearActive(),this.observations_.forEach(function(l){l.isActive()&&u.activeObservations_.push(l)})},e.prototype.broadcastActive=function(){if(this.hasActive()){var u=this.callbackCtx_,l=this.activeObservations_.map(function(d){return new ResizeObserverEntry(d.target,d.broadcastRect())});this.callback_.call(u,l,u),this.clearActive()}},e.prototype.clearActive=function(){this.activeObservations_.splice(0)},e.prototype.hasActive=function(){return this.activeObservations_.length>0},e}(),observers=typeof WeakMap<"u"?new WeakMap:new MapShim,ResizeObserver$1=function(){function e(u){if(!(this instanceof e))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var l=ResizeObserverController.getInstance(),d=new ResizeObserverSPI(u,l,this);observers.set(this,d)}return e}();["observe","unobserve","disconnect"].forEach(function(e){ResizeObserver$1.prototype[e]=function(){var u;return(u=observers.get(this))[e].apply(u,arguments)}});var index$6=function(){return typeof global$1.ResizeObserver<"u"?global$1.ResizeObserver:ResizeObserver$1}();const Events=["blur","input","change","changeSelectionStyle","changeSession","copy","focus","paste"],VAceEditor=vue.defineComponent({name:"VAceEditor",props:{value:{type:String,required:!0},lang:{type:String,default:"text"},theme:{type:String,default:"chrome"},options:Object,placeholder:String,readonly:Boolean,wrap:Boolean,printMargin:{type:[Boolean,Number],default:!0},minLines:Number,maxLines:Number},emits:["update:value","init",...Events],render(){return vue.h("div")},mounted(){const e=this._editor=vue.markRaw(ace$1.edit(this.$el,{placeholder:this.placeholder,readOnly:this.readonly,value:this.value,mode:"ace/mode/"+this.lang,theme:"ace/theme/"+this.theme,wrap:this.wrap,printMargin:this.printMargin,useWorker:!1,minLines:this.minLines,maxLines:this.maxLines,...this.options}));this._contentBackup=this.value,this._isSettingContent=!1,e.on("change",()=>{if(this._isSettingContent)return;const u=e.getValue();this._contentBackup=u,this.$emit("update:value",u)}),Events.forEach(u=>{const l="on"+vue.capitalize(u);typeof this.$.vnode.props[l]=="function"&&e.on(u,this.$emit.bind(this,u))}),this._ro=new index$6(()=>e.resize()),this._ro.observe(this.$el),this.$emit("init",e)},beforeUnmount(){var e,u;(e=this._ro)===null||e===void 0||e.disconnect(),(u=this._editor)===null||u===void 0||u.destroy()},methods:{focus(){this._editor.focus()},blur(){this._editor.blur()},selectAll(){this._editor.selectAll()},getAceInstance(){return this._editor}},watch:{value(e){if(this._contentBackup!==e){try{this._isSettingContent=!0,this._editor.setValue(e,1)}finally{this._isSettingContent=!1}this._contentBackup=e}},theme(e){this._editor.setTheme("ace/theme/"+e)},options(e){this._editor.setOptions(e)},readonly(e){this._editor.setReadOnly(e)},placeholder(e){this._editor.setOption("placeholder",e)},wrap(e){this._editor.setWrapBehavioursEnabled(e)},printMargin(e){this._editor.setOption("printMargin",e)},lang(e){this._editor.setOption("mode","ace/mode/"+e)},minLines(e){this._editor.setOption("minLines",e)},maxLines(e){this._editor.setOption("maxLines",e)}}}),modeJsonUrl="data:text/javascript;base64,YWNlLmRlZmluZSgiYWNlL21vZGUvanNvbl9oaWdobGlnaHRfcnVsZXMiLFsicmVxdWlyZSIsImV4cG9ydHMiLCJtb2R1bGUiLCJhY2UvbGliL29vcCIsImFjZS9tb2RlL3RleHRfaGlnaGxpZ2h0X3J1bGVzIl0sIGZ1bmN0aW9uKHJlcXVpcmUsIGV4cG9ydHMsIG1vZHVsZSl7InVzZSBzdHJpY3QiOwp2YXIgb29wID0gcmVxdWlyZSgiLi4vbGliL29vcCIpOwp2YXIgVGV4dEhpZ2hsaWdodFJ1bGVzID0gcmVxdWlyZSgiLi90ZXh0X2hpZ2hsaWdodF9ydWxlcyIpLlRleHRIaWdobGlnaHRSdWxlczsKdmFyIEpzb25IaWdobGlnaHRSdWxlcyA9IGZ1bmN0aW9uICgpIHsKICAgIHRoaXMuJHJ1bGVzID0gewogICAgICAgICJzdGFydCI6IFsKICAgICAgICAgICAgewogICAgICAgICAgICAgICAgdG9rZW46ICJ2YXJpYWJsZSIsIC8vIHNpbmdsZSBsaW5lCiAgICAgICAgICAgICAgICByZWdleDogJ1siXSg/Oig/OlxcXFwuKXwoPzpbXiJcXFxcXSkpKj9bIl1cXHMqKD89OiknCiAgICAgICAgICAgIH0sIHsKICAgICAgICAgICAgICAgIHRva2VuOiAic3RyaW5nIiwgLy8gc2luZ2xlIGxpbmUKICAgICAgICAgICAgICAgIHJlZ2V4OiAnIicsCiAgICAgICAgICAgICAgICBuZXh0OiAic3RyaW5nIgogICAgICAgICAgICB9LCB7CiAgICAgICAgICAgICAgICB0b2tlbjogImNvbnN0YW50Lm51bWVyaWMiLCAvLyBoZXgKICAgICAgICAgICAgICAgIHJlZ2V4OiAiMFt4WF1bMC05YS1mQS1GXStcXGIiCiAgICAgICAgICAgIH0sIHsKICAgICAgICAgICAgICAgIHRva2VuOiAiY29uc3RhbnQubnVtZXJpYyIsIC8vIGZsb2F0CiAgICAgICAgICAgICAgICByZWdleDogIlsrLV0/XFxkKyg/Oig/OlxcLlxcZCopPyg/OltlRV1bKy1dP1xcZCspPyk/XFxiIgogICAgICAgICAgICB9LCB7CiAgICAgICAgICAgICAgICB0b2tlbjogImNvbnN0YW50Lmxhbmd1YWdlLmJvb2xlYW4iLAogICAgICAgICAgICAgICAgcmVnZXg6ICIoPzp0cnVlfGZhbHNlKVxcYiIKICAgICAgICAgICAgfSwgewogICAgICAgICAgICAgICAgdG9rZW46ICJ0ZXh0IiwgLy8gc2luZ2xlIHF1b3RlZCBzdHJpbmdzIGFyZSBub3QgYWxsb3dlZAogICAgICAgICAgICAgICAgcmVnZXg6ICJbJ10oPzooPzpcXFxcLil8KD86W14nXFxcXF0pKSo/WyddIgogICAgICAgICAgICB9LCB7CiAgICAgICAgICAgICAgICB0b2tlbjogImNvbW1lbnQiLCAvLyBjb21tZW50cyBhcmUgbm90IGFsbG93ZWQsIGJ1dCB3aG8gY2FyZXM/CiAgICAgICAgICAgICAgICByZWdleDogIlxcL1xcLy4qJCIKICAgICAgICAgICAgfSwgewogICAgICAgICAgICAgICAgdG9rZW46ICJjb21tZW50LnN0YXJ0IiwgLy8gY29tbWVudHMgYXJlIG5vdCBhbGxvd2VkLCBidXQgd2hvIGNhcmVzPwogICAgICAgICAgICAgICAgcmVnZXg6ICJcXC9cXCoiLAogICAgICAgICAgICAgICAgbmV4dDogImNvbW1lbnQiCiAgICAgICAgICAgIH0sIHsKICAgICAgICAgICAgICAgIHRva2VuOiAicGFyZW4ubHBhcmVuIiwKICAgICAgICAgICAgICAgIHJlZ2V4OiAiW1soe10iCiAgICAgICAgICAgIH0sIHsKICAgICAgICAgICAgICAgIHRva2VuOiAicGFyZW4ucnBhcmVuIiwKICAgICAgICAgICAgICAgIHJlZ2V4OiAiW1xcXSl9XSIKICAgICAgICAgICAgfSwgewogICAgICAgICAgICAgICAgdG9rZW46ICJwdW5jdHVhdGlvbi5vcGVyYXRvciIsCiAgICAgICAgICAgICAgICByZWdleDogL1ssXS8KICAgICAgICAgICAgfSwgewogICAgICAgICAgICAgICAgdG9rZW46ICJ0ZXh0IiwKICAgICAgICAgICAgICAgIHJlZ2V4OiAiXFxzKyIKICAgICAgICAgICAgfQogICAgICAgIF0sCiAgICAgICAgInN0cmluZyI6IFsKICAgICAgICAgICAgewogICAgICAgICAgICAgICAgdG9rZW46ICJjb25zdGFudC5sYW5ndWFnZS5lc2NhcGUiLAogICAgICAgICAgICAgICAgcmVnZXg6IC9cXCg/OnhbMC05YS1mQS1GXXsyfXx1WzAtOWEtZkEtRl17NH18WyJcXFwvYmZucnRdKS8KICAgICAgICAgICAgfSwgewogICAgICAgICAgICAgICAgdG9rZW46ICJzdHJpbmciLAogICAgICAgICAgICAgICAgcmVnZXg6ICcifCQnLAogICAgICAgICAgICAgICAgbmV4dDogInN0YXJ0IgogICAgICAgICAgICB9LCB7CiAgICAgICAgICAgICAgICBkZWZhdWx0VG9rZW46ICJzdHJpbmciCiAgICAgICAgICAgIH0KICAgICAgICBdLAogICAgICAgICJjb21tZW50IjogWwogICAgICAgICAgICB7CiAgICAgICAgICAgICAgICB0b2tlbjogImNvbW1lbnQuZW5kIiwgLy8gY29tbWVudHMgYXJlIG5vdCBhbGxvd2VkLCBidXQgd2hvIGNhcmVzPwogICAgICAgICAgICAgICAgcmVnZXg6ICJcXCpcXC8iLAogICAgICAgICAgICAgICAgbmV4dDogInN0YXJ0IgogICAgICAgICAgICB9LCB7CiAgICAgICAgICAgICAgICBkZWZhdWx0VG9rZW46ICJjb21tZW50IgogICAgICAgICAgICB9CiAgICAgICAgXQogICAgfTsKfTsKb29wLmluaGVyaXRzKEpzb25IaWdobGlnaHRSdWxlcywgVGV4dEhpZ2hsaWdodFJ1bGVzKTsKZXhwb3J0cy5Kc29uSGlnaGxpZ2h0UnVsZXMgPSBKc29uSGlnaGxpZ2h0UnVsZXM7Cgp9KTsKCmFjZS5kZWZpbmUoImFjZS9tb2RlL21hdGNoaW5nX2JyYWNlX291dGRlbnQiLFsicmVxdWlyZSIsImV4cG9ydHMiLCJtb2R1bGUiLCJhY2UvcmFuZ2UiXSwgZnVuY3Rpb24ocmVxdWlyZSwgZXhwb3J0cywgbW9kdWxlKXsidXNlIHN0cmljdCI7CnZhciBSYW5nZSA9IHJlcXVpcmUoIi4uL3JhbmdlIikuUmFuZ2U7CnZhciBNYXRjaGluZ0JyYWNlT3V0ZGVudCA9IGZ1bmN0aW9uICgpIHsgfTsKKGZ1bmN0aW9uICgpIHsKICAgIHRoaXMuY2hlY2tPdXRkZW50ID0gZnVuY3Rpb24gKGxpbmUsIGlucHV0KSB7CiAgICAgICAgaWYgKCEvXlxzKyQvLnRlc3QobGluZSkpCiAgICAgICAgICAgIHJldHVybiBmYWxzZTsKICAgICAgICByZXR1cm4gL15ccypcfS8udGVzdChpbnB1dCk7CiAgICB9OwogICAgdGhpcy5hdXRvT3V0ZGVudCA9IGZ1bmN0aW9uIChkb2MsIHJvdykgewogICAgICAgIHZhciBsaW5lID0gZG9jLmdldExpbmUocm93KTsKICAgICAgICB2YXIgbWF0Y2ggPSBsaW5lLm1hdGNoKC9eKFxzKlx9KS8pOwogICAgICAgIGlmICghbWF0Y2gpCiAgICAgICAgICAgIHJldHVybiAwOwogICAgICAgIHZhciBjb2x1bW4gPSBtYXRjaFsxXS5sZW5ndGg7CiAgICAgICAgdmFyIG9wZW5CcmFjZVBvcyA9IGRvYy5maW5kTWF0Y2hpbmdCcmFja2V0KHsgcm93OiByb3csIGNvbHVtbjogY29sdW1uIH0pOwogICAgICAgIGlmICghb3BlbkJyYWNlUG9zIHx8IG9wZW5CcmFjZVBvcy5yb3cgPT0gcm93KQogICAgICAgICAgICByZXR1cm4gMDsKICAgICAgICB2YXIgaW5kZW50ID0gdGhpcy4kZ2V0SW5kZW50KGRvYy5nZXRMaW5lKG9wZW5CcmFjZVBvcy5yb3cpKTsKICAgICAgICBkb2MucmVwbGFjZShuZXcgUmFuZ2Uocm93LCAwLCByb3csIGNvbHVtbiAtIDEpLCBpbmRlbnQpOwogICAgfTsKICAgIHRoaXMuJGdldEluZGVudCA9IGZ1bmN0aW9uIChsaW5lKSB7CiAgICAgICAgcmV0dXJuIGxpbmUubWF0Y2goL15ccyovKVswXTsKICAgIH07Cn0pLmNhbGwoTWF0Y2hpbmdCcmFjZU91dGRlbnQucHJvdG90eXBlKTsKZXhwb3J0cy5NYXRjaGluZ0JyYWNlT3V0ZGVudCA9IE1hdGNoaW5nQnJhY2VPdXRkZW50OwoKfSk7CgphY2UuZGVmaW5lKCJhY2UvbW9kZS9mb2xkaW5nL2NzdHlsZSIsWyJyZXF1aXJlIiwiZXhwb3J0cyIsIm1vZHVsZSIsImFjZS9saWIvb29wIiwiYWNlL3JhbmdlIiwiYWNlL21vZGUvZm9sZGluZy9mb2xkX21vZGUiXSwgZnVuY3Rpb24ocmVxdWlyZSwgZXhwb3J0cywgbW9kdWxlKXsidXNlIHN0cmljdCI7CnZhciBvb3AgPSByZXF1aXJlKCIuLi8uLi9saWIvb29wIik7CnZhciBSYW5nZSA9IHJlcXVpcmUoIi4uLy4uL3JhbmdlIikuUmFuZ2U7CnZhciBCYXNlRm9sZE1vZGUgPSByZXF1aXJlKCIuL2ZvbGRfbW9kZSIpLkZvbGRNb2RlOwp2YXIgRm9sZE1vZGUgPSBleHBvcnRzLkZvbGRNb2RlID0gZnVuY3Rpb24gKGNvbW1lbnRSZWdleCkgewogICAgaWYgKGNvbW1lbnRSZWdleCkgewogICAgICAgIHRoaXMuZm9sZGluZ1N0YXJ0TWFya2VyID0gbmV3IFJlZ0V4cCh0aGlzLmZvbGRpbmdTdGFydE1hcmtlci5zb3VyY2UucmVwbGFjZSgvXHxbXnxdKj8kLywgInwiICsgY29tbWVudFJlZ2V4LnN0YXJ0KSk7CiAgICAgICAgdGhpcy5mb2xkaW5nU3RvcE1hcmtlciA9IG5ldyBSZWdFeHAodGhpcy5mb2xkaW5nU3RvcE1hcmtlci5zb3VyY2UucmVwbGFjZSgvXHxbXnxdKj8kLywgInwiICsgY29tbWVudFJlZ2V4LmVuZCkpOwogICAgfQp9Owpvb3AuaW5oZXJpdHMoRm9sZE1vZGUsIEJhc2VGb2xkTW9kZSk7CihmdW5jdGlvbiAoKSB7CiAgICB0aGlzLmZvbGRpbmdTdGFydE1hcmtlciA9IC8oW1x7XFtcKF0pW15cfVxdXCldKiR8XlxzKihcL1wqKS87CiAgICB0aGlzLmZvbGRpbmdTdG9wTWFya2VyID0gL15bXlxbXHtcKF0qKFtcfVxdXCldKXxeW1xzXCpdKihcKlwvKS87CiAgICB0aGlzLnNpbmdsZUxpbmVCbG9ja0NvbW1lbnRSZSA9IC9eXHMqKFwvXCopLipcKlwvXHMqJC87CiAgICB0aGlzLnRyaXBsZVN0YXJCbG9ja0NvbW1lbnRSZSA9IC9eXHMqKFwvXCpcKlwqKS4qXCpcL1xzKiQvOwogICAgdGhpcy5zdGFydFJlZ2lvblJlID0gL15ccyooXC9cKnxcL1wvKSM/cmVnaW9uXGIvOwogICAgdGhpcy5fZ2V0Rm9sZFdpZGdldEJhc2UgPSB0aGlzLmdldEZvbGRXaWRnZXQ7CiAgICB0aGlzLmdldEZvbGRXaWRnZXQgPSBmdW5jdGlvbiAoc2Vzc2lvbiwgZm9sZFN0eWxlLCByb3cpIHsKICAgICAgICB2YXIgbGluZSA9IHNlc3Npb24uZ2V0TGluZShyb3cpOwogICAgICAgIGlmICh0aGlzLnNpbmdsZUxpbmVCbG9ja0NvbW1lbnRSZS50ZXN0KGxpbmUpKSB7CiAgICAgICAgICAgIGlmICghdGhpcy5zdGFydFJlZ2lvblJlLnRlc3QobGluZSkgJiYgIXRoaXMudHJpcGxlU3RhckJsb2NrQ29tbWVudFJlLnRlc3QobGluZSkpCiAgICAgICAgICAgICAgICByZXR1cm4gIiI7CiAgICAgICAgfQogICAgICAgIHZhciBmdyA9IHRoaXMuX2dldEZvbGRXaWRnZXRCYXNlKHNlc3Npb24sIGZvbGRTdHlsZSwgcm93KTsKICAgICAgICBpZiAoIWZ3ICYmIHRoaXMuc3RhcnRSZWdpb25SZS50ZXN0KGxpbmUpKQogICAgICAgICAgICByZXR1cm4gInN0YXJ0IjsgLy8gbGluZUNvbW1lbnRSZWdpb25TdGFydAogICAgICAgIHJldHVybiBmdzsKICAgIH07CiAgICB0aGlzLmdldEZvbGRXaWRnZXRSYW5nZSA9IGZ1bmN0aW9uIChzZXNzaW9uLCBmb2xkU3R5bGUsIHJvdywgZm9yY2VNdWx0aWxpbmUpIHsKICAgICAgICB2YXIgbGluZSA9IHNlc3Npb24uZ2V0TGluZShyb3cpOwogICAgICAgIGlmICh0aGlzLnN0YXJ0UmVnaW9uUmUudGVzdChsaW5lKSkKICAgICAgICAgICAgcmV0dXJuIHRoaXMuZ2V0Q29tbWVudFJlZ2lvbkJsb2NrKHNlc3Npb24sIGxpbmUsIHJvdyk7CiAgICAgICAgdmFyIG1hdGNoID0gbGluZS5tYXRjaCh0aGlzLmZvbGRpbmdTdGFydE1hcmtlcik7CiAgICAgICAgaWYgKG1hdGNoKSB7CiAgICAgICAgICAgIHZhciBpID0gbWF0Y2guaW5kZXg7CiAgICAgICAgICAgIGlmIChtYXRjaFsxXSkKICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLm9wZW5pbmdCcmFja2V0QmxvY2soc2Vzc2lvbiwgbWF0Y2hbMV0sIHJvdywgaSk7CiAgICAgICAgICAgIHZhciByYW5nZSA9IHNlc3Npb24uZ2V0Q29tbWVudEZvbGRSYW5nZShyb3csIGkgKyBtYXRjaFswXS5sZW5ndGgsIDEpOwogICAgICAgICAgICBpZiAocmFuZ2UgJiYgIXJhbmdlLmlzTXVsdGlMaW5lKCkpIHsKICAgICAgICAgICAgICAgIGlmIChmb3JjZU11bHRpbGluZSkgewogICAgICAgICAgICAgICAgICAgIHJhbmdlID0gdGhpcy5nZXRTZWN0aW9uUmFuZ2Uoc2Vzc2lvbiwgcm93KTsKICAgICAgICAgICAgICAgIH0KICAgICAgICAgICAgICAgIGVsc2UgaWYgKGZvbGRTdHlsZSAhPSAiYWxsIikKICAgICAgICAgICAgICAgICAgICByYW5nZSA9IG51bGw7CiAgICAgICAgICAgIH0KICAgICAgICAgICAgcmV0dXJuIHJhbmdlOwogICAgICAgIH0KICAgICAgICBpZiAoZm9sZFN0eWxlID09PSAibWFya2JlZ2luIikKICAgICAgICAgICAgcmV0dXJuOwogICAgICAgIHZhciBtYXRjaCA9IGxpbmUubWF0Y2godGhpcy5mb2xkaW5nU3RvcE1hcmtlcik7CiAgICAgICAgaWYgKG1hdGNoKSB7CiAgICAgICAgICAgIHZhciBpID0gbWF0Y2guaW5kZXggKyBtYXRjaFswXS5sZW5ndGg7CiAgICAgICAgICAgIGlmIChtYXRjaFsxXSkKICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLmNsb3NpbmdCcmFja2V0QmxvY2soc2Vzc2lvbiwgbWF0Y2hbMV0sIHJvdywgaSk7CiAgICAgICAgICAgIHJldHVybiBzZXNzaW9uLmdldENvbW1lbnRGb2xkUmFuZ2Uocm93LCBpLCAtMSk7CiAgICAgICAgfQogICAgfTsKICAgIHRoaXMuZ2V0U2VjdGlvblJhbmdlID0gZnVuY3Rpb24gKHNlc3Npb24sIHJvdykgewogICAgICAgIHZhciBsaW5lID0gc2Vzc2lvbi5nZXRMaW5lKHJvdyk7CiAgICAgICAgdmFyIHN0YXJ0SW5kZW50ID0gbGluZS5zZWFyY2goL1xTLyk7CiAgICAgICAgdmFyIHN0YXJ0Um93ID0gcm93OwogICAgICAgIHZhciBzdGFydENvbHVtbiA9IGxpbmUubGVuZ3RoOwogICAgICAgIHJvdyA9IHJvdyArIDE7CiAgICAgICAgdmFyIGVuZFJvdyA9IHJvdzsKICAgICAgICB2YXIgbWF4Um93ID0gc2Vzc2lvbi5nZXRMZW5ndGgoKTsKICAgICAgICB3aGlsZSAoKytyb3cgPCBtYXhSb3cpIHsKICAgICAgICAgICAgbGluZSA9IHNlc3Npb24uZ2V0TGluZShyb3cpOwogICAgICAgICAgICB2YXIgaW5kZW50ID0gbGluZS5zZWFyY2goL1xTLyk7CiAgICAgICAgICAgIGlmIChpbmRlbnQgPT09IC0xKQogICAgICAgICAgICAgICAgY29udGludWU7CiAgICAgICAgICAgIGlmIChzdGFydEluZGVudCA+IGluZGVudCkKICAgICAgICAgICAgICAgIGJyZWFrOwogICAgICAgICAgICB2YXIgc3ViUmFuZ2UgPSB0aGlzLmdldEZvbGRXaWRnZXRSYW5nZShzZXNzaW9uLCAiYWxsIiwgcm93KTsKICAgICAgICAgICAgaWYgKHN1YlJhbmdlKSB7CiAgICAgICAgICAgICAgICBpZiAoc3ViUmFuZ2Uuc3RhcnQucm93IDw9IHN0YXJ0Um93KSB7CiAgICAgICAgICAgICAgICAgICAgYnJlYWs7CiAgICAgICAgICAgICAgICB9CiAgICAgICAgICAgICAgICBlbHNlIGlmIChzdWJSYW5nZS5pc011bHRpTGluZSgpKSB7CiAgICAgICAgICAgICAgICAgICAgcm93ID0gc3ViUmFuZ2UuZW5kLnJvdzsKICAgICAgICAgICAgICAgIH0KICAgICAgICAgICAgICAgIGVsc2UgaWYgKHN0YXJ0SW5kZW50ID09IGluZGVudCkgewogICAgICAgICAgICAgICAgICAgIGJyZWFrOwogICAgICAgICAgICAgICAgfQogICAgICAgICAgICB9CiAgICAgICAgICAgIGVuZFJvdyA9IHJvdzsKICAgICAgICB9CiAgICAgICAgcmV0dXJuIG5ldyBSYW5nZShzdGFydFJvdywgc3RhcnRDb2x1bW4sIGVuZFJvdywgc2Vzc2lvbi5nZXRMaW5lKGVuZFJvdykubGVuZ3RoKTsKICAgIH07CiAgICB0aGlzLmdldENvbW1lbnRSZWdpb25CbG9jayA9IGZ1bmN0aW9uIChzZXNzaW9uLCBsaW5lLCByb3cpIHsKICAgICAgICB2YXIgc3RhcnRDb2x1bW4gPSBsaW5lLnNlYXJjaCgvXHMqJC8pOwogICAgICAgIHZhciBtYXhSb3cgPSBzZXNzaW9uLmdldExlbmd0aCgpOwogICAgICAgIHZhciBzdGFydFJvdyA9IHJvdzsKICAgICAgICB2YXIgcmUgPSAvXlxzKig/OlwvXCp8XC9cL3wtLSkjPyhlbmQpP3JlZ2lvblxiLzsKICAgICAgICB2YXIgZGVwdGggPSAxOwogICAgICAgIHdoaWxlICgrK3JvdyA8IG1heFJvdykgewogICAgICAgICAgICBsaW5lID0gc2Vzc2lvbi5nZXRMaW5lKHJvdyk7CiAgICAgICAgICAgIHZhciBtID0gcmUuZXhlYyhsaW5lKTsKICAgICAgICAgICAgaWYgKCFtKQogICAgICAgICAgICAgICAgY29udGludWU7CiAgICAgICAgICAgIGlmIChtWzFdKQogICAgICAgICAgICAgICAgZGVwdGgtLTsKICAgICAgICAgICAgZWxzZQogICAgICAgICAgICAgICAgZGVwdGgrKzsKICAgICAgICAgICAgaWYgKCFkZXB0aCkKICAgICAgICAgICAgICAgIGJyZWFrOwogICAgICAgIH0KICAgICAgICB2YXIgZW5kUm93ID0gcm93OwogICAgICAgIGlmIChlbmRSb3cgPiBzdGFydFJvdykgewogICAgICAgICAgICByZXR1cm4gbmV3IFJhbmdlKHN0YXJ0Um93LCBzdGFydENvbHVtbiwgZW5kUm93LCBsaW5lLmxlbmd0aCk7CiAgICAgICAgfQogICAgfTsKfSkuY2FsbChGb2xkTW9kZS5wcm90b3R5cGUpOwoKfSk7CgphY2UuZGVmaW5lKCJhY2UvbW9kZS9qc29uIixbInJlcXVpcmUiLCJleHBvcnRzIiwibW9kdWxlIiwiYWNlL2xpYi9vb3AiLCJhY2UvbW9kZS90ZXh0IiwiYWNlL21vZGUvanNvbl9oaWdobGlnaHRfcnVsZXMiLCJhY2UvbW9kZS9tYXRjaGluZ19icmFjZV9vdXRkZW50IiwiYWNlL21vZGUvZm9sZGluZy9jc3R5bGUiLCJhY2Uvd29ya2VyL3dvcmtlcl9jbGllbnQiXSwgZnVuY3Rpb24ocmVxdWlyZSwgZXhwb3J0cywgbW9kdWxlKXsidXNlIHN0cmljdCI7CnZhciBvb3AgPSByZXF1aXJlKCIuLi9saWIvb29wIik7CnZhciBUZXh0TW9kZSA9IHJlcXVpcmUoIi4vdGV4dCIpLk1vZGU7CnZhciBIaWdobGlnaHRSdWxlcyA9IHJlcXVpcmUoIi4vanNvbl9oaWdobGlnaHRfcnVsZXMiKS5Kc29uSGlnaGxpZ2h0UnVsZXM7CnZhciBNYXRjaGluZ0JyYWNlT3V0ZGVudCA9IHJlcXVpcmUoIi4vbWF0Y2hpbmdfYnJhY2Vfb3V0ZGVudCIpLk1hdGNoaW5nQnJhY2VPdXRkZW50Owp2YXIgQ1N0eWxlRm9sZE1vZGUgPSByZXF1aXJlKCIuL2ZvbGRpbmcvY3N0eWxlIikuRm9sZE1vZGU7CnZhciBXb3JrZXJDbGllbnQgPSByZXF1aXJlKCIuLi93b3JrZXIvd29ya2VyX2NsaWVudCIpLldvcmtlckNsaWVudDsKdmFyIE1vZGUgPSBmdW5jdGlvbiAoKSB7CiAgICB0aGlzLkhpZ2hsaWdodFJ1bGVzID0gSGlnaGxpZ2h0UnVsZXM7CiAgICB0aGlzLiRvdXRkZW50ID0gbmV3IE1hdGNoaW5nQnJhY2VPdXRkZW50KCk7CiAgICB0aGlzLiRiZWhhdmlvdXIgPSB0aGlzLiRkZWZhdWx0QmVoYXZpb3VyOwogICAgdGhpcy5mb2xkaW5nUnVsZXMgPSBuZXcgQ1N0eWxlRm9sZE1vZGUoKTsKfTsKb29wLmluaGVyaXRzKE1vZGUsIFRleHRNb2RlKTsKKGZ1bmN0aW9uICgpIHsKICAgIHRoaXMubGluZUNvbW1lbnRTdGFydCA9ICIvLyI7CiAgICB0aGlzLmJsb2NrQ29tbWVudCA9IHsgc3RhcnQ6ICIvKiIsIGVuZDogIiovIiB9OwogICAgdGhpcy5nZXROZXh0TGluZUluZGVudCA9IGZ1bmN0aW9uIChzdGF0ZSwgbGluZSwgdGFiKSB7CiAgICAgICAgdmFyIGluZGVudCA9IHRoaXMuJGdldEluZGVudChsaW5lKTsKICAgICAgICBpZiAoc3RhdGUgPT0gInN0YXJ0IikgewogICAgICAgICAgICB2YXIgbWF0Y2ggPSBsaW5lLm1hdGNoKC9eLipbXHtcKFxbXVxzKiQvKTsKICAgICAgICAgICAgaWYgKG1hdGNoKSB7CiAgICAgICAgICAgICAgICBpbmRlbnQgKz0gdGFiOwogICAgICAgICAgICB9CiAgICAgICAgfQogICAgICAgIHJldHVybiBpbmRlbnQ7CiAgICB9OwogICAgdGhpcy5jaGVja091dGRlbnQgPSBmdW5jdGlvbiAoc3RhdGUsIGxpbmUsIGlucHV0KSB7CiAgICAgICAgcmV0dXJuIHRoaXMuJG91dGRlbnQuY2hlY2tPdXRkZW50KGxpbmUsIGlucHV0KTsKICAgIH07CiAgICB0aGlzLmF1dG9PdXRkZW50ID0gZnVuY3Rpb24gKHN0YXRlLCBkb2MsIHJvdykgewogICAgICAgIHRoaXMuJG91dGRlbnQuYXV0b091dGRlbnQoZG9jLCByb3cpOwogICAgfTsKICAgIHRoaXMuY3JlYXRlV29ya2VyID0gZnVuY3Rpb24gKHNlc3Npb24pIHsKICAgICAgICB2YXIgd29ya2VyID0gbmV3IFdvcmtlckNsaWVudChbImFjZSJdLCAiYWNlL21vZGUvanNvbl93b3JrZXIiLCAiSnNvbldvcmtlciIpOwogICAgICAgIHdvcmtlci5hdHRhY2hUb0RvY3VtZW50KHNlc3Npb24uZ2V0RG9jdW1lbnQoKSk7CiAgICAgICAgd29ya2VyLm9uKCJhbm5vdGF0ZSIsIGZ1bmN0aW9uIChlKSB7CiAgICAgICAgICAgIHNlc3Npb24uc2V0QW5ub3RhdGlvbnMoZS5kYXRhKTsKICAgICAgICB9KTsKICAgICAgICB3b3JrZXIub24oInRlcm1pbmF0ZSIsIGZ1bmN0aW9uICgpIHsKICAgICAgICAgICAgc2Vzc2lvbi5jbGVhckFubm90YXRpb25zKCk7CiAgICAgICAgfSk7CiAgICAgICAgcmV0dXJuIHdvcmtlcjsKICAgIH07CiAgICB0aGlzLiRpZCA9ICJhY2UvbW9kZS9qc29uIjsKfSkuY2FsbChNb2RlLnByb3RvdHlwZSk7CmV4cG9ydHMuTW9kZSA9IE1vZGU7Cgp9KTsgICAgICAgICAgICAgICAgKGZ1bmN0aW9uKCkgewogICAgICAgICAgICAgICAgICAgIGFjZS5yZXF1aXJlKFsiYWNlL21vZGUvanNvbiJdLCBmdW5jdGlvbihtKSB7CiAgICAgICAgICAgICAgICAgICAgICAgIGlmICh0eXBlb2YgbW9kdWxlID09ICJvYmplY3QiICYmIHR5cGVvZiBleHBvcnRzID09ICJvYmplY3QiICYmIG1vZHVsZSkgewogICAgICAgICAgICAgICAgICAgICAgICAgICAgbW9kdWxlLmV4cG9ydHMgPSBtOwogICAgICAgICAgICAgICAgICAgICAgICB9CiAgICAgICAgICAgICAgICAgICAgfSk7CiAgICAgICAgICAgICAgICB9KSgpOwogICAgICAgICAgICA=",themeGithubUrl="data:text/javascript;base64,YWNlLmRlZmluZSgiYWNlL3RoZW1lL2dpdGh1Yi1jc3MiLFsicmVxdWlyZSIsImV4cG9ydHMiLCJtb2R1bGUiXSwgZnVuY3Rpb24ocmVxdWlyZSwgZXhwb3J0cywgbW9kdWxlKXttb2R1bGUuZXhwb3J0cyA9ICIvKiBDU1Mgc3R5bGUgY29udGVudCBmcm9tIGdpdGh1YidzIGRlZmF1bHQgcHlnbWVudHMgaGlnaGxpZ2h0ZXIgdGVtcGxhdGUuXG4gICBDdXJzb3IgYW5kIHNlbGVjdGlvbiBzdHlsZXMgZnJvbSB0ZXh0bWF0ZS5jc3MuICovXG4uYWNlLWdpdGh1YiAuYWNlX2d1dHRlciB7XG4gIGJhY2tncm91bmQ6ICNlOGU4ZTg7XG4gIGNvbG9yOiAjQUFBO1xufVxuXG4uYWNlLWdpdGh1YiAge1xuICBiYWNrZ3JvdW5kOiAjZmZmO1xuICBjb2xvcjogIzAwMDtcbn1cblxuLmFjZS1naXRodWIgLmFjZV9rZXl3b3JkIHtcbiAgZm9udC13ZWlnaHQ6IGJvbGQ7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2Vfc3RyaW5nIHtcbiAgY29sb3I6ICNEMTQ7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfdmFyaWFibGUuYWNlX2NsYXNzIHtcbiAgY29sb3I6IHRlYWw7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfY29uc3RhbnQuYWNlX251bWVyaWMge1xuICBjb2xvcjogIzA5OTtcbn1cblxuLmFjZS1naXRodWIgLmFjZV9jb25zdGFudC5hY2VfYnVpbGRpbiB7XG4gIGNvbG9yOiAjMDA4NkIzO1xufVxuXG4uYWNlLWdpdGh1YiAuYWNlX3N1cHBvcnQuYWNlX2Z1bmN0aW9uIHtcbiAgY29sb3I6ICMwMDg2QjM7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfY29tbWVudCB7XG4gIGNvbG9yOiAjOTk4O1xuICBmb250LXN0eWxlOiBpdGFsaWM7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfdmFyaWFibGUuYWNlX2xhbmd1YWdlICB7XG4gIGNvbG9yOiAjMDA4NkIzO1xufVxuXG4uYWNlLWdpdGh1YiAuYWNlX3BhcmVuIHtcbiAgZm9udC13ZWlnaHQ6IGJvbGQ7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfYm9vbGVhbiB7XG4gIGZvbnQtd2VpZ2h0OiBib2xkO1xufVxuXG4uYWNlLWdpdGh1YiAuYWNlX3N0cmluZy5hY2VfcmVnZXhwIHtcbiAgY29sb3I6ICMwMDk5MjY7XG4gIGZvbnQtd2VpZ2h0OiBub3JtYWw7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfdmFyaWFibGUuYWNlX2luc3RhbmNlIHtcbiAgY29sb3I6IHRlYWw7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfY29uc3RhbnQuYWNlX2xhbmd1YWdlIHtcbiAgZm9udC13ZWlnaHQ6IGJvbGQ7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfY3Vyc29yIHtcbiAgY29sb3I6IGJsYWNrO1xufVxuXG4uYWNlLWdpdGh1Yi5hY2VfZm9jdXMgLmFjZV9tYXJrZXItbGF5ZXIgLmFjZV9hY3RpdmUtbGluZSB7XG4gIGJhY2tncm91bmQ6IHJnYigyNTUsIDI1NSwgMjA0KTtcbn1cbi5hY2UtZ2l0aHViIC5hY2VfbWFya2VyLWxheWVyIC5hY2VfYWN0aXZlLWxpbmUge1xuICBiYWNrZ3JvdW5kOiByZ2IoMjQ1LCAyNDUsIDI0NSk7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfbWFya2VyLWxheWVyIC5hY2Vfc2VsZWN0aW9uIHtcbiAgYmFja2dyb3VuZDogcmdiKDE4MSwgMjEzLCAyNTUpO1xufVxuXG4uYWNlLWdpdGh1Yi5hY2VfbXVsdGlzZWxlY3QgLmFjZV9zZWxlY3Rpb24uYWNlX3N0YXJ0IHtcbiAgYm94LXNoYWRvdzogMCAwIDNweCAwcHggd2hpdGU7XG59XG4vKiBib2xkIGtleXdvcmRzIGNhdXNlIGN1cnNvciBpc3N1ZXMgZm9yIHNvbWUgZm9udHMgKi9cbi8qIHRoaXMgZGlzYWJsZXMgYm9sZCBzdHlsZSBmb3IgZWRpdG9yIGFuZCBrZWVwcyBmb3Igc3RhdGljIGhpZ2hsaWdodGVyICovXG4uYWNlLWdpdGh1Yi5hY2Vfbm9ib2xkIC5hY2VfbGluZSA+IHNwYW4ge1xuICAgIGZvbnQtd2VpZ2h0OiBub3JtYWwgIWltcG9ydGFudDtcbn1cblxuLmFjZS1naXRodWIgLmFjZV9tYXJrZXItbGF5ZXIgLmFjZV9zdGVwIHtcbiAgYmFja2dyb3VuZDogcmdiKDI1MiwgMjU1LCAwKTtcbn1cblxuLmFjZS1naXRodWIgLmFjZV9tYXJrZXItbGF5ZXIgLmFjZV9zdGFjayB7XG4gIGJhY2tncm91bmQ6IHJnYigxNjQsIDIyOSwgMTAxKTtcbn1cblxuLmFjZS1naXRodWIgLmFjZV9tYXJrZXItbGF5ZXIgLmFjZV9icmFja2V0IHtcbiAgbWFyZ2luOiAtMXB4IDAgMCAtMXB4O1xuICBib3JkZXI6IDFweCBzb2xpZCByZ2IoMTkyLCAxOTIsIDE5Mik7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfZ3V0dGVyLWFjdGl2ZS1saW5lIHtcbiAgICBiYWNrZ3JvdW5kLWNvbG9yIDogcmdiYSgwLCAwLCAwLCAwLjA3KTtcbn1cblxuLmFjZS1naXRodWIgLmFjZV9tYXJrZXItbGF5ZXIgLmFjZV9zZWxlY3RlZC13b3JkIHtcbiAgYmFja2dyb3VuZDogcmdiKDI1MCwgMjUwLCAyNTUpO1xuICBib3JkZXI6IDFweCBzb2xpZCByZ2IoMjAwLCAyMDAsIDI1MCk7XG59XG5cbi5hY2UtZ2l0aHViIC5hY2VfaW52aXNpYmxlIHtcbiAgY29sb3I6ICNCRkJGQkZcbn1cblxuLmFjZS1naXRodWIgLmFjZV9wcmludC1tYXJnaW4ge1xuICB3aWR0aDogMXB4O1xuICBiYWNrZ3JvdW5kOiAjZThlOGU4O1xufVxuXG4uYWNlLWdpdGh1YiAuYWNlX2luZGVudC1ndWlkZSB7XG4gIGJhY2tncm91bmQ6IHVybChcImRhdGE6aW1hZ2UvcG5nO2Jhc2U2NCxpVkJPUncwS0dnb0FBQUFOU1VoRVVnQUFBQUVBQUFBQ0NBWUFBQUNaZ2JZbkFBQUFFMGxFUVZRSW1XUDQvLy8vZjRiTGx5Ly9Cd0FtVmdkMS93MTEvZ0FBQUFCSlJVNUVya0pnZ2c9PVwiKSByaWdodCByZXBlYXQteTtcbn1cblxuLmFjZS1naXRodWIgLmFjZV9pbmRlbnQtZ3VpZGUtYWN0aXZlIHtcbiAgYmFja2dyb3VuZDogdXJsKFwiZGF0YTppbWFnZS9wbmc7YmFzZTY0LGlWQk9SdzBLR2dvQUFBQU5TVWhFVWdBQUFBRUFBQUFDQ0FZQUFBQ1pnYlluQUFBQUNYQklXWE1BQUFzVEFBQUxFd0VBbXB3WUFBQUFJR05JVWswQUFIb2xBQUNBZ3dBQStmOEFBSURwQUFCMU1BQUE2bUFBQURxWUFBQVhiNUpmeFVZQUFBQVpTVVJCVkhqYVl2ai8vLzkvaGl2S3l2OEJBQUFBLy84REFDTHFCaGJ2aysvZUFBQUFBRWxGVGtTdVFtQ0NcIikgcmlnaHQgcmVwZWF0LXk7XG59XG4iOwoKfSk7CgphY2UuZGVmaW5lKCJhY2UvdGhlbWUvZ2l0aHViIixbInJlcXVpcmUiLCJleHBvcnRzIiwibW9kdWxlIiwiYWNlL3RoZW1lL2dpdGh1Yi1jc3MiLCJhY2UvbGliL2RvbSJdLCBmdW5jdGlvbihyZXF1aXJlLCBleHBvcnRzLCBtb2R1bGUpe2V4cG9ydHMuaXNEYXJrID0gZmFsc2U7CmV4cG9ydHMuY3NzQ2xhc3MgPSAiYWNlLWdpdGh1YiI7CmV4cG9ydHMuY3NzVGV4dCA9IHJlcXVpcmUoIi4vZ2l0aHViLWNzcyIpOwp2YXIgZG9tID0gcmVxdWlyZSgiLi4vbGliL2RvbSIpOwpkb20uaW1wb3J0Q3NzU3RyaW5nKGV4cG9ydHMuY3NzVGV4dCwgZXhwb3J0cy5jc3NDbGFzcywgZmFsc2UpOwoKfSk7ICAgICAgICAgICAgICAgIChmdW5jdGlvbigpIHsKICAgICAgICAgICAgICAgICAgICBhY2UucmVxdWlyZShbImFjZS90aGVtZS9naXRodWIiXSwgZnVuY3Rpb24obSkgewogICAgICAgICAgICAgICAgICAgICAgICBpZiAodHlwZW9mIG1vZHVsZSA9PSAib2JqZWN0IiAmJiB0eXBlb2YgZXhwb3J0cyA9PSAib2JqZWN0IiAmJiBtb2R1bGUpIHsKICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1vZHVsZS5leHBvcnRzID0gbTsKICAgICAgICAgICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgICAgICAgIH0pOwogICAgICAgICAgICAgICAgfSkoKTsKICAgICAgICAgICAg",_sfc_main$7={__name:"index",props:vue.mergeModels({lang:{type:String,default:""},options:{type:Object,default:{}}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(e){ace$1.config.setModuleUrl("ace/mode/json",modeJsonUrl),ace$1.config.setModuleUrl("ace/theme/github",themeGithubUrl);const u=vue.useModel(e,"modelValue");return(l,d)=>(vue.openBlock(),vue.createBlock(vue.unref(VAceEditor),{value:u.value,"onUpdate:value":d[0]||(d[0]=E=>u.value=E),lang:e.lang,theme:"github",options:e.options,style:{height:"500px",width:"100%"}},null,8,["value","lang","options"]))}},_export_sfc=(e,u)=>{const l=e.__vccOpts||e;for(const[d,E]of u)l[d]=E;return l},_hoisted_1$6={style:{"margin-bottom":"8px"}},_hoisted_2$5={class:"condition-item"},_hoisted_3$4={style:{width:"35%"}},_hoisted_4$4={style:{width:"90px"}},_sfc_main$6={__name:"index",props:vue.mergeModels({conf:{type:Object,default:()=>{}}},{express:{default:()=>[]},expressModifiers:{}}),emits:["update:express"],setup(e){const u=vue.useModel(e,"express"),l=e,d=vue.ref([{label:"等于",value:"eq"},{label:"大于",value:"gt"},{label:"小于",value:"le"},{label:"大于等于",value:"egt"},{label:"小于等于",value:"elt"},{label:"包含",value:"in"},{label:"不包含",value:"not in"}]),E=vue.computed(()=>b(l.conf.widgetList)),b=a=>{const g=[];return a.forEach(n=>{n.type==="grid"?n.cols.forEach(s=>{g.push(...b(s.widgetList))}):n.options.hasOwnProperty("defaultValue")&&g.push(n)}),g},C=()=>{u.value.push({left:null,operator:null,right:null,relation:"and"})},A=a=>{u.value.splice(a,1)};return(a,g)=>{const n=vue.resolveComponent("el-button"),s=vue.resolveComponent("el-option"),o=vue.resolveComponent("el-select"),r=vue.resolveComponent("el-input"),t=vue.resolveComponent("el-radio-button"),i=vue.resolveComponent("el-radio-group");return vue.openBlock(),vue.createElementBlock("div",null,[vue.createElementVNode("div",_hoisted_1$6,[vue.createVNode(n,{type:"primary",onClick:C},{default:vue.withCtx(()=>g[0]||(g[0]=[vue.createTextVNode("添加条件")])),_:1})]),(vue.openBlock(!0),vue.createElementBlock(vue.Fragment,null,vue.renderList(u.value,(c,h)=>(vue.openBlock(),vue.createElementBlock("div",_hoisted_2$5,[vue.createVNode(n,{icon:"el-icon-minus",circle:"",size:"small",onClick:f=>A(h)},null,8,["onClick"]),vue.createVNode(o,{modelValue:c.left,"onUpdate:modelValue":f=>c.left=f,style:{width:"35%"}},{default:vue.withCtx(()=>[(vue.openBlock(!0),vue.createElementBlock(vue.Fragment,null,vue.renderList(E.value,f=>(vue.openBlock(),vue.createBlock(s,{key:f.options.name,value:f.options.name,label:f.options.label},null,8,["value","label"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue"]),vue.createVNode(o,{modelValue:c.operator,"onUpdate:modelValue":f=>c.operator=f,style:{width:"20%"}},{default:vue.withCtx(()=>[(vue.openBlock(!0),vue.createElementBlock(vue.Fragment,null,vue.renderList(d.value,f=>(vue.openBlock(),vue.createBlock(s,{value:f.value,label:f.label},null,8,["value","label"]))),256))]),_:2},1032,["modelValue","onUpdate:modelValue"]),vue.createElementVNode("div",_hoisted_3$4,[vue.createVNode(r,{modelValue:c.right,"onUpdate:modelValue":f=>c.right=f},null,8,["modelValue","onUpdate:modelValue"])]),vue.createElementVNode("div",_hoisted_4$4,[vue.createVNode(i,{modelValue:c.relation,"onUpdate:modelValue":f=>c.relation=f,size:"small"},{default:vue.withCtx(()=>[vue.createVNode(t,{value:"and"},{default:vue.withCtx(()=>g[1]||(g[1]=[vue.createTextVNode("且")])),_:1}),vue.createVNode(t,{value:"or"},{default:vue.withCtx(()=>g[2]||(g[2]=[vue.createTextVNode("或")])),_:1})]),_:2},1032,["modelValue","onUpdate:modelValue"])])]))),256))])}}},ConditionEditor=_export_sfc(_sfc_main$6,[["__scopeId","data-v-fee858fc"]]);function bind(e,u){return function(){return e.apply(u,arguments)}}const{toString}=Object.prototype,{getPrototypeOf}=Object,kindOf=(e=>u=>{const l=toString.call(u);return e[l]||(e[l]=l.slice(8,-1).toLowerCase())})(Object.create(null)),kindOfTest=e=>(e=e.toLowerCase(),u=>kindOf(u)===e),typeOfTest=e=>u=>typeof u===e,{isArray:isArray$1}=Array,isUndefined=typeOfTest("undefined");function isBuffer(e){return e!==null&&!isUndefined(e)&&e.constructor!==null&&!isUndefined(e.constructor)&&isFunction$1(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const isArrayBuffer=kindOfTest("ArrayBuffer");function isArrayBufferView(e){let u;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?u=ArrayBuffer.isView(e):u=e&&e.buffer&&isArrayBuffer(e.buffer),u}const isString$1=typeOfTest("string"),isFunction$1=typeOfTest("function"),isNumber$1=typeOfTest("number"),isObject$1=e=>e!==null&&typeof e=="object",isBoolean$1=e=>e===!0||e===!1,isPlainObject$1=e=>{if(kindOf(e)!=="object")return!1;const u=getPrototypeOf(e);return(u===null||u===Object.prototype||Object.getPrototypeOf(u)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},isDate$1=kindOfTest("Date"),isFile=kindOfTest("File"),isBlob=kindOfTest("Blob"),isFileList=kindOfTest("FileList"),isStream=e=>isObject$1(e)&&isFunction$1(e.pipe),isFormData=e=>{let u;return e&&(typeof FormData=="function"&&e instanceof FormData||isFunction$1(e.append)&&((u=kindOf(e))==="formdata"||u==="object"&&isFunction$1(e.toString)&&e.toString()==="[object FormData]"))},isURLSearchParams=kindOfTest("URLSearchParams"),[isReadableStream,isRequest,isResponse,isHeaders]=["ReadableStream","Request","Response","Headers"].map(kindOfTest),trim=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function forEach(e,u,{allOwnKeys:l=!1}={}){if(e===null||typeof e>"u")return;let d,E;if(typeof e!="object"&&(e=[e]),isArray$1(e))for(d=0,E=e.length;d<E;d++)u.call(null,e[d],d,e);else{const b=l?Object.getOwnPropertyNames(e):Object.keys(e),C=b.length;let A;for(d=0;d<C;d++)A=b[d],u.call(null,e[A],A,e)}}function findKey(e,u){u=u.toLowerCase();const l=Object.keys(e);let d=l.length,E;for(;d-- >0;)if(E=l[d],u===E.toLowerCase())return E;return null}const _global=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,isContextDefined=e=>!isUndefined(e)&&e!==_global;function merge(){const{caseless:e}=isContextDefined(this)&&this||{},u={},l=(d,E)=>{const b=e&&findKey(u,E)||E;isPlainObject$1(u[b])&&isPlainObject$1(d)?u[b]=merge(u[b],d):isPlainObject$1(d)?u[b]=merge({},d):isArray$1(d)?u[b]=d.slice():u[b]=d};for(let d=0,E=arguments.length;d<E;d++)arguments[d]&&forEach(arguments[d],l);return u}const extend=(e,u,l,{allOwnKeys:d}={})=>(forEach(u,(E,b)=>{l&&isFunction$1(E)?e[b]=bind(E,l):e[b]=E},{allOwnKeys:d}),e),stripBOM=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),inherits=(e,u,l,d)=>{e.prototype=Object.create(u.prototype,d),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:u.prototype}),l&&Object.assign(e.prototype,l)},toFlatObject=(e,u,l,d)=>{let E,b,C;const A={};if(u=u||{},e==null)return u;do{for(E=Object.getOwnPropertyNames(e),b=E.length;b-- >0;)C=E[b],(!d||d(C,e,u))&&!A[C]&&(u[C]=e[C],A[C]=!0);e=l!==!1&&getPrototypeOf(e)}while(e&&(!l||l(e,u))&&e!==Object.prototype);return u},endsWith=(e,u,l)=>{e=String(e),(l===void 0||l>e.length)&&(l=e.length),l-=u.length;const d=e.indexOf(u,l);return d!==-1&&d===l},toArray=e=>{if(!e)return null;if(isArray$1(e))return e;let u=e.length;if(!isNumber$1(u))return null;const l=new Array(u);for(;u-- >0;)l[u]=e[u];return l},isTypedArray=(e=>u=>e&&u instanceof e)(typeof Uint8Array<"u"&&getPrototypeOf(Uint8Array)),forEachEntry=(e,u)=>{const d=(e&&e[Symbol.iterator]).call(e);let E;for(;(E=d.next())&&!E.done;){const b=E.value;u.call(e,b[0],b[1])}},matchAll=(e,u)=>{let l;const d=[];for(;(l=e.exec(u))!==null;)d.push(l);return d},isHTMLForm=kindOfTest("HTMLFormElement"),toCamelCase=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(l,d,E){return d.toUpperCase()+E}),hasOwnProperty$1=(({hasOwnProperty:e})=>(u,l)=>e.call(u,l))(Object.prototype),isRegExp$1=kindOfTest("RegExp"),reduceDescriptors=(e,u)=>{const l=Object.getOwnPropertyDescriptors(e),d={};forEach(l,(E,b)=>{let C;(C=u(E,b,e))!==!1&&(d[b]=C||E)}),Object.defineProperties(e,d)},freezeMethods=e=>{reduceDescriptors(e,(u,l)=>{if(isFunction$1(e)&&["arguments","caller","callee"].indexOf(l)!==-1)return!1;const d=e[l];if(isFunction$1(d)){if(u.enumerable=!1,"writable"in u){u.writable=!1;return}u.set||(u.set=()=>{throw Error("Can not rewrite read-only method '"+l+"'")})}})},toObjectSet=(e,u)=>{const l={},d=E=>{E.forEach(b=>{l[b]=!0})};return isArray$1(e)?d(e):d(String(e).split(u)),l},noop=()=>{},toFiniteNumber=(e,u)=>e!=null&&Number.isFinite(e=+e)?e:u;function isSpecCompliantForm(e){return!!(e&&isFunction$1(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const toJSONObject=e=>{const u=new Array(10),l=(d,E)=>{if(isObject$1(d)){if(u.indexOf(d)>=0)return;if(!("toJSON"in d)){u[E]=d;const b=isArray$1(d)?[]:{};return forEach(d,(C,A)=>{const a=l(C,E+1);!isUndefined(a)&&(b[A]=a)}),u[E]=void 0,b}}return d};return l(e,0)},isAsyncFn=kindOfTest("AsyncFunction"),isThenable=e=>e&&(isObject$1(e)||isFunction$1(e))&&isFunction$1(e.then)&&isFunction$1(e.catch),_setImmediate=((e,u)=>e?setImmediate:u?((l,d)=>(_global.addEventListener("message",({source:E,data:b})=>{E===_global&&b===l&&d.length&&d.shift()()},!1),E=>{d.push(E),_global.postMessage(l,"*")}))(`axios@${Math.random()}`,[]):l=>setTimeout(l))(typeof setImmediate=="function",isFunction$1(_global.postMessage)),asap=typeof queueMicrotask<"u"?queueMicrotask.bind(_global):typeof process<"u"&&process.nextTick||_setImmediate,utils$1={isArray:isArray$1,isArrayBuffer,isBuffer,isFormData,isArrayBufferView,isString:isString$1,isNumber:isNumber$1,isBoolean:isBoolean$1,isObject:isObject$1,isPlainObject:isPlainObject$1,isReadableStream,isRequest,isResponse,isHeaders,isUndefined,isDate:isDate$1,isFile,isBlob,isRegExp:isRegExp$1,isFunction:isFunction$1,isStream,isURLSearchParams,isTypedArray,isFileList,forEach,merge,extend,trim,stripBOM,inherits,toFlatObject,kindOf,kindOfTest,endsWith,toArray,forEachEntry,matchAll,isHTMLForm,hasOwnProperty:hasOwnProperty$1,hasOwnProp:hasOwnProperty$1,reduceDescriptors,freezeMethods,toObjectSet,toCamelCase,noop,toFiniteNumber,findKey,global:_global,isContextDefined,isSpecCompliantForm,toJSONObject,isAsyncFn,isThenable,setImmediate:_setImmediate,asap};function AxiosError$1(e,u,l,d,E){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",u&&(this.code=u),l&&(this.config=l),d&&(this.request=d),E&&(this.response=E,this.status=E.status?E.status:null)}utils$1.inherits(AxiosError$1,Error,{toJSON:function e(){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:utils$1.toJSONObject(this.config),code:this.code,status:this.status}}});const prototype$1=AxiosError$1.prototype,descriptors={};["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(e=>{descriptors[e]={value:e}}),Object.defineProperties(AxiosError$1,descriptors),Object.defineProperty(prototype$1,"isAxiosError",{value:!0}),AxiosError$1.from=(e,u,l,d,E,b)=>{const C=Object.create(prototype$1);return utils$1.toFlatObject(e,C,function(a){return a!==Error.prototype},A=>A!=="isAxiosError"),AxiosError$1.call(C,e.message,u,l,d,E),C.cause=e,C.name=e.name,b&&Object.assign(C,b),C};const httpAdapter=null;function isVisitable(e){return utils$1.isPlainObject(e)||utils$1.isArray(e)}function removeBrackets(e){return utils$1.endsWith(e,"[]")?e.slice(0,-2):e}function renderKey(e,u,l){return e?e.concat(u).map(function(E,b){return E=removeBrackets(E),!l&&b?"["+E+"]":E}).join(l?".":""):u}function isFlatArray(e){return utils$1.isArray(e)&&!e.some(isVisitable)}const predicates=utils$1.toFlatObject(utils$1,{},null,function e(u){return/^is[A-Z]/.test(u)});function toFormData$1(e,u,l){if(!utils$1.isObject(e))throw new TypeError("target must be an object");u=u||new FormData,l=utils$1.toFlatObject(l,{metaTokens:!0,dots:!1,indexes:!1},!1,function(i,c){return!utils$1.isUndefined(c[i])});const d=l.metaTokens,E=l.visitor||n,b=l.dots,C=l.indexes,a=(l.Blob||typeof Blob<"u"&&Blob)&&utils$1.isSpecCompliantForm(u);if(!utils$1.isFunction(E))throw new TypeError("visitor must be a function");function g(t){if(t===null)return"";if(utils$1.isDate(t))return t.toISOString();if(!a&&utils$1.isBlob(t))throw new AxiosError$1("Blob is not supported. Use a Buffer instead.");return utils$1.isArrayBuffer(t)||utils$1.isTypedArray(t)?a&&typeof Blob=="function"?new Blob([t]):Buffer.from(t):t}function n(t,i,c){let h=t;if(t&&!c&&typeof t=="object"){if(utils$1.endsWith(i,"{}"))i=d?i:i.slice(0,-2),t=JSON.stringify(t);else if(utils$1.isArray(t)&&isFlatArray(t)||(utils$1.isFileList(t)||utils$1.endsWith(i,"[]"))&&(h=utils$1.toArray(t)))return i=removeBrackets(i),h.forEach(function(v,p){!(utils$1.isUndefined(v)||v===null)&&u.append(C===!0?renderKey([i],p,b):C===null?i:i+"[]",g(v))}),!1}return isVisitable(t)?!0:(u.append(renderKey(c,i,b),g(t)),!1)}const s=[],o=Object.assign(predicates,{defaultVisitor:n,convertValue:g,isVisitable});function r(t,i){if(!utils$1.isUndefined(t)){if(s.indexOf(t)!==-1)throw Error("Circular reference detected in "+i.join("."));s.push(t),utils$1.forEach(t,function(h,f){(!(utils$1.isUndefined(h)||h===null)&&E.call(u,h,utils$1.isString(f)?f.trim():f,i,o))===!0&&r(h,i?i.concat(f):[f])}),s.pop()}}if(!utils$1.isObject(e))throw new TypeError("data must be an object");return r(e),u}function encode$1(e){const u={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(d){return u[d]})}function AxiosURLSearchParams(e,u){this._pairs=[],e&&toFormData$1(e,this,u)}const prototype=AxiosURLSearchParams.prototype;prototype.append=function e(u,l){this._pairs.push([u,l])},prototype.toString=function e(u){const l=u?function(d){return u.call(this,d,encode$1)}:encode$1;return this._pairs.map(function(E){return l(E[0])+"="+l(E[1])},"").join("&")};function encode(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function buildURL(e,u,l){if(!u)return e;const d=l&&l.encode||encode;utils$1.isFunction(l)&&(l={serialize:l});const E=l&&l.serialize;let b;if(E?b=E(u,l):b=utils$1.isURLSearchParams(u)?u.toString():new AxiosURLSearchParams(u,l).toString(d),b){const C=e.indexOf("#");C!==-1&&(e=e.slice(0,C)),e+=(e.indexOf("?")===-1?"?":"&")+b}return e}class InterceptorManager{constructor(){this.handlers=[]}use(u,l,d){return this.handlers.push({fulfilled:u,rejected:l,synchronous:d?d.synchronous:!1,runWhen:d?d.runWhen:null}),this.handlers.length-1}eject(u){this.handlers[u]&&(this.handlers[u]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(u){utils$1.forEach(this.handlers,function(d){d!==null&&u(d)})}}const transitionalDefaults={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},URLSearchParams$1=typeof URLSearchParams<"u"?URLSearchParams:AxiosURLSearchParams,FormData$1=typeof FormData<"u"?FormData:null,Blob$1=typeof Blob<"u"?Blob:null,platform$1={isBrowser:!0,classes:{URLSearchParams:URLSearchParams$1,FormData:FormData$1,Blob:Blob$1},protocols:["http","https","file","blob","url","data"]},hasBrowserEnv=typeof window<"u"&&typeof document<"u",_navigator=typeof navigator=="object"&&navigator||void 0,hasStandardBrowserEnv=hasBrowserEnv&&(!_navigator||["ReactNative","NativeScript","NS"].indexOf(_navigator.product)<0),hasStandardBrowserWebWorkerEnv=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",origin=hasBrowserEnv&&window.location.href||"http://localhost",utils=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv,hasStandardBrowserEnv,hasStandardBrowserWebWorkerEnv,navigator:_navigator,origin},Symbol.toStringTag,{value:"Module"})),platform={...utils,...platform$1};function toURLEncodedForm(e,u){return toFormData$1(e,new platform.classes.URLSearchParams,Object.assign({visitor:function(l,d,E,b){return platform.isNode&&utils$1.isBuffer(l)?(this.append(d,l.toString("base64")),!1):b.defaultVisitor.apply(this,arguments)}},u))}function parsePropPath(e){return utils$1.matchAll(/\w+|\[(\w*)]/g,e).map(u=>u[0]==="[]"?"":u[1]||u[0])}function arrayToObject(e){const u={},l=Object.keys(e);let d;const E=l.length;let b;for(d=0;d<E;d++)b=l[d],u[b]=e[b];return u}function formDataToJSON(e){function u(l,d,E,b){let C=l[b++];if(C==="__proto__")return!0;const A=Number.isFinite(+C),a=b>=l.length;return C=!C&&utils$1.isArray(E)?E.length:C,a?(utils$1.hasOwnProp(E,C)?E[C]=[E[C],d]:E[C]=d,!A):((!E[C]||!utils$1.isObject(E[C]))&&(E[C]=[]),u(l,d,E[C],b)&&utils$1.isArray(E[C])&&(E[C]=arrayToObject(E[C])),!A)}if(utils$1.isFormData(e)&&utils$1.isFunction(e.entries)){const l={};return utils$1.forEachEntry(e,(d,E)=>{u(parsePropPath(d),E,l,0)}),l}return null}function stringifySafely(e,u,l){if(utils$1.isString(e))try{return(u||JSON.parse)(e),utils$1.trim(e)}catch(d){if(d.name!=="SyntaxError")throw d}return(l||JSON.stringify)(e)}const defaults={transitional:transitionalDefaults,adapter:["xhr","http","fetch"],transformRequest:[function e(u,l){const d=l.getContentType()||"",E=d.indexOf("application/json")>-1,b=utils$1.isObject(u);if(b&&utils$1.isHTMLForm(u)&&(u=new FormData(u)),utils$1.isFormData(u))return E?JSON.stringify(formDataToJSON(u)):u;if(utils$1.isArrayBuffer(u)||utils$1.isBuffer(u)||utils$1.isStream(u)||utils$1.isFile(u)||utils$1.isBlob(u)||utils$1.isReadableStream(u))return u;if(utils$1.isArrayBufferView(u))return u.buffer;if(utils$1.isURLSearchParams(u))return l.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),u.toString();let A;if(b){if(d.indexOf("application/x-www-form-urlencoded")>-1)return toURLEncodedForm(u,this.formSerializer).toString();if((A=utils$1.isFileList(u))||d.indexOf("multipart/form-data")>-1){const a=this.env&&this.env.FormData;return toFormData$1(A?{"files[]":u}:u,a&&new a,this.formSerializer)}}return b||E?(l.setContentType("application/json",!1),stringifySafely(u)):u}],transformResponse:[function e(u){const l=this.transitional||defaults.transitional,d=l&&l.forcedJSONParsing,E=this.responseType==="json";if(utils$1.isResponse(u)||utils$1.isReadableStream(u))return u;if(u&&utils$1.isString(u)&&(d&&!this.responseType||E)){const C=!(l&&l.silentJSONParsing)&&E;try{return JSON.parse(u)}catch(A){if(C)throw A.name==="SyntaxError"?AxiosError$1.from(A,AxiosError$1.ERR_BAD_RESPONSE,this,null,this.response):A}}return u}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:platform.classes.FormData,Blob:platform.classes.Blob},validateStatus:function e(u){return u>=200&&u<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};utils$1.forEach(["delete","get","head","post","put","patch"],e=>{defaults.headers[e]={}});const ignoreDuplicateOf=utils$1.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"]),parseHeaders=e=>{const u={};let l,d,E;return e&&e.split(`
986
+ `).forEach(function(C){E=C.indexOf(":"),l=C.substring(0,E).trim().toLowerCase(),d=C.substring(E+1).trim(),!(!l||u[l]&&ignoreDuplicateOf[l])&&(l==="set-cookie"?u[l]?u[l].push(d):u[l]=[d]:u[l]=u[l]?u[l]+", "+d:d)}),u},$internals=Symbol("internals");function normalizeHeader(e){return e&&String(e).trim().toLowerCase()}function normalizeValue(e){return e===!1||e==null?e:utils$1.isArray(e)?e.map(normalizeValue):String(e)}function parseTokens(e){const u=Object.create(null),l=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let d;for(;d=l.exec(e);)u[d[1]]=d[2];return u}const isValidHeaderName=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function matchHeaderValue(e,u,l,d,E){if(utils$1.isFunction(d))return d.call(this,u,l);if(E&&(u=l),!!utils$1.isString(u)){if(utils$1.isString(d))return u.indexOf(d)!==-1;if(utils$1.isRegExp(d))return d.test(u)}}function formatHeader(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(u,l,d)=>l.toUpperCase()+d)}function buildAccessors(e,u){const l=utils$1.toCamelCase(" "+u);["get","set","has"].forEach(d=>{Object.defineProperty(e,d+l,{value:function(E,b,C){return this[d].call(this,u,E,b,C)},configurable:!0})})}let AxiosHeaders$1=class{constructor(u){u&&this.set(u)}set(u,l,d){const E=this;function b(A,a,g){const n=normalizeHeader(a);if(!n)throw new Error("header name must be a non-empty string");const s=utils$1.findKey(E,n);(!s||E[s]===void 0||g===!0||g===void 0&&E[s]!==!1)&&(E[s||a]=normalizeValue(A))}const C=(A,a)=>utils$1.forEach(A,(g,n)=>b(g,n,a));if(utils$1.isPlainObject(u)||u instanceof this.constructor)C(u,l);else if(utils$1.isString(u)&&(u=u.trim())&&!isValidHeaderName(u))C(parseHeaders(u),l);else if(utils$1.isHeaders(u))for(const[A,a]of u.entries())b(a,A,d);else u!=null&&b(l,u,d);return this}get(u,l){if(u=normalizeHeader(u),u){const d=utils$1.findKey(this,u);if(d){const E=this[d];if(!l)return E;if(l===!0)return parseTokens(E);if(utils$1.isFunction(l))return l.call(this,E,d);if(utils$1.isRegExp(l))return l.exec(E);throw new TypeError("parser must be boolean|regexp|function")}}}has(u,l){if(u=normalizeHeader(u),u){const d=utils$1.findKey(this,u);return!!(d&&this[d]!==void 0&&(!l||matchHeaderValue(this,this[d],d,l)))}return!1}delete(u,l){const d=this;let E=!1;function b(C){if(C=normalizeHeader(C),C){const A=utils$1.findKey(d,C);A&&(!l||matchHeaderValue(d,d[A],A,l))&&(delete d[A],E=!0)}}return utils$1.isArray(u)?u.forEach(b):b(u),E}clear(u){const l=Object.keys(this);let d=l.length,E=!1;for(;d--;){const b=l[d];(!u||matchHeaderValue(this,this[b],b,u,!0))&&(delete this[b],E=!0)}return E}normalize(u){const l=this,d={};return utils$1.forEach(this,(E,b)=>{const C=utils$1.findKey(d,b);if(C){l[C]=normalizeValue(E),delete l[b];return}const A=u?formatHeader(b):String(b).trim();A!==b&&delete l[b],l[A]=normalizeValue(E),d[A]=!0}),this}concat(...u){return this.constructor.concat(this,...u)}toJSON(u){const l=Object.create(null);return utils$1.forEach(this,(d,E)=>{d!=null&&d!==!1&&(l[E]=u&&utils$1.isArray(d)?d.join(", "):d)}),l}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([u,l])=>u+": "+l).join(`
987
+ `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(u){return u instanceof this?u:new this(u)}static concat(u,...l){const d=new this(u);return l.forEach(E=>d.set(E)),d}static accessor(u){const d=(this[$internals]=this[$internals]={accessors:{}}).accessors,E=this.prototype;function b(C){const A=normalizeHeader(C);d[A]||(buildAccessors(E,C),d[A]=!0)}return utils$1.isArray(u)?u.forEach(b):b(u),this}};AxiosHeaders$1.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),utils$1.reduceDescriptors(AxiosHeaders$1.prototype,({value:e},u)=>{let l=u[0].toUpperCase()+u.slice(1);return{get:()=>e,set(d){this[l]=d}}}),utils$1.freezeMethods(AxiosHeaders$1);function transformData(e,u){const l=this||defaults,d=u||l,E=AxiosHeaders$1.from(d.headers);let b=d.data;return utils$1.forEach(e,function(A){b=A.call(l,b,E.normalize(),u?u.status:void 0)}),E.normalize(),b}function isCancel$1(e){return!!(e&&e.__CANCEL__)}function CanceledError$1(e,u,l){AxiosError$1.call(this,e??"canceled",AxiosError$1.ERR_CANCELED,u,l),this.name="CanceledError"}utils$1.inherits(CanceledError$1,AxiosError$1,{__CANCEL__:!0});function settle(e,u,l){const d=l.config.validateStatus;!l.status||!d||d(l.status)?e(l):u(new AxiosError$1("Request failed with status code "+l.status,[AxiosError$1.ERR_BAD_REQUEST,AxiosError$1.ERR_BAD_RESPONSE][Math.floor(l.status/100)-4],l.config,l.request,l))}function parseProtocol(e){const u=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return u&&u[1]||""}function speedometer(e,u){e=e||10;const l=new Array(e),d=new Array(e);let E=0,b=0,C;return u=u!==void 0?u:1e3,function(a){const g=Date.now(),n=d[b];C||(C=g),l[E]=a,d[E]=g;let s=b,o=0;for(;s!==E;)o+=l[s++],s=s%e;if(E=(E+1)%e,E===b&&(b=(b+1)%e),g-C<u)return;const r=n&&g-n;return r?Math.round(o*1e3/r):void 0}}function throttle(e,u){let l=0,d=1e3/u,E,b;const C=(g,n=Date.now())=>{l=n,E=null,b&&(clearTimeout(b),b=null),e.apply(null,g)};return[(...g)=>{const n=Date.now(),s=n-l;s>=d?C(g,n):(E=g,b||(b=setTimeout(()=>{b=null,C(E)},d-s)))},()=>E&&C(E)]}const progressEventReducer=(e,u,l=3)=>{let d=0;const E=speedometer(50,250);return throttle(b=>{const C=b.loaded,A=b.lengthComputable?b.total:void 0,a=C-d,g=E(a),n=C<=A;d=C;const s={loaded:C,total:A,progress:A?C/A:void 0,bytes:a,rate:g||void 0,estimated:g&&A&&n?(A-C)/g:void 0,event:b,lengthComputable:A!=null,[u?"download":"upload"]:!0};e(s)},l)},progressEventDecorator=(e,u)=>{const l=e!=null;return[d=>u[0]({lengthComputable:l,total:e,loaded:d}),u[1]]},asyncDecorator=e=>(...u)=>utils$1.asap(()=>e(...u)),isURLSameOrigin=platform.hasStandardBrowserEnv?((e,u)=>l=>(l=new URL(l,platform.origin),e.protocol===l.protocol&&e.host===l.host&&(u||e.port===l.port)))(new URL(platform.origin),platform.navigator&&/(msie|trident)/i.test(platform.navigator.userAgent)):()=>!0,cookies=platform.hasStandardBrowserEnv?{write(e,u,l,d,E,b){const C=[e+"="+encodeURIComponent(u)];utils$1.isNumber(l)&&C.push("expires="+new Date(l).toGMTString()),utils$1.isString(d)&&C.push("path="+d),utils$1.isString(E)&&C.push("domain="+E),b===!0&&C.push("secure"),document.cookie=C.join("; ")},read(e){const u=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return u?decodeURIComponent(u[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function isAbsoluteURL(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function combineURLs(e,u){return u?e.replace(/\/?\/$/,"")+"/"+u.replace(/^\/+/,""):e}function buildFullPath(e,u,l){let d=!isAbsoluteURL(u);return e&&(d||l==!1)?combineURLs(e,u):u}const headersToObject=e=>e instanceof AxiosHeaders$1?{...e}:e;function mergeConfig$1(e,u){u=u||{};const l={};function d(g,n,s,o){return utils$1.isPlainObject(g)&&utils$1.isPlainObject(n)?utils$1.merge.call({caseless:o},g,n):utils$1.isPlainObject(n)?utils$1.merge({},n):utils$1.isArray(n)?n.slice():n}function E(g,n,s,o){if(utils$1.isUndefined(n)){if(!utils$1.isUndefined(g))return d(void 0,g,s,o)}else return d(g,n,s,o)}function b(g,n){if(!utils$1.isUndefined(n))return d(void 0,n)}function C(g,n){if(utils$1.isUndefined(n)){if(!utils$1.isUndefined(g))return d(void 0,g)}else return d(void 0,n)}function A(g,n,s){if(s in u)return d(g,n);if(s in e)return d(void 0,g)}const a={url:b,method:b,data:b,baseURL:C,transformRequest:C,transformResponse:C,paramsSerializer:C,timeout:C,timeoutMessage:C,withCredentials:C,withXSRFToken:C,adapter:C,responseType:C,xsrfCookieName:C,xsrfHeaderName:C,onUploadProgress:C,onDownloadProgress:C,decompress:C,maxContentLength:C,maxBodyLength:C,beforeRedirect:C,transport:C,httpAgent:C,httpsAgent:C,cancelToken:C,socketPath:C,responseEncoding:C,validateStatus:A,headers:(g,n,s)=>E(headersToObject(g),headersToObject(n),s,!0)};return utils$1.forEach(Object.keys(Object.assign({},e,u)),function(n){const s=a[n]||E,o=s(e[n],u[n],n);utils$1.isUndefined(o)&&s!==A||(l[n]=o)}),l}const resolveConfig=e=>{const u=mergeConfig$1({},e);let{data:l,withXSRFToken:d,xsrfHeaderName:E,xsrfCookieName:b,headers:C,auth:A}=u;u.headers=C=AxiosHeaders$1.from(C),u.url=buildURL(buildFullPath(u.baseURL,u.url,u.allowAbsoluteUrls),e.params,e.paramsSerializer),A&&C.set("Authorization","Basic "+btoa((A.username||"")+":"+(A.password?unescape(encodeURIComponent(A.password)):"")));let a;if(utils$1.isFormData(l)){if(platform.hasStandardBrowserEnv||platform.hasStandardBrowserWebWorkerEnv)C.setContentType(void 0);else if((a=C.getContentType())!==!1){const[g,...n]=a?a.split(";").map(s=>s.trim()).filter(Boolean):[];C.setContentType([g||"multipart/form-data",...n].join("; "))}}if(platform.hasStandardBrowserEnv&&(d&&utils$1.isFunction(d)&&(d=d(u)),d||d!==!1&&isURLSameOrigin(u.url))){const g=E&&b&&cookies.read(b);g&&C.set(E,g)}return u},isXHRAdapterSupported=typeof XMLHttpRequest<"u",xhrAdapter=isXHRAdapterSupported&&function(e){return new Promise(function(l,d){const E=resolveConfig(e);let b=E.data;const C=AxiosHeaders$1.from(E.headers).normalize();let{responseType:A,onUploadProgress:a,onDownloadProgress:g}=E,n,s,o,r,t;function i(){r&&r(),t&&t(),E.cancelToken&&E.cancelToken.unsubscribe(n),E.signal&&E.signal.removeEventListener("abort",n)}let c=new XMLHttpRequest;c.open(E.method.toUpperCase(),E.url,!0),c.timeout=E.timeout;function h(){if(!c)return;const v=AxiosHeaders$1.from("getAllResponseHeaders"in c&&c.getAllResponseHeaders()),y={data:!A||A==="text"||A==="json"?c.responseText:c.response,status:c.status,statusText:c.statusText,headers:v,config:e,request:c};settle(function($){l($),i()},function($){d($),i()},y),c=null}"onloadend"in c?c.onloadend=h:c.onreadystatechange=function(){!c||c.readyState!==4||c.status===0&&!(c.responseURL&&c.responseURL.indexOf("file:")===0)||setTimeout(h)},c.onabort=function(){c&&(d(new AxiosError$1("Request aborted",AxiosError$1.ECONNABORTED,e,c)),c=null)},c.onerror=function(){d(new AxiosError$1("Network Error",AxiosError$1.ERR_NETWORK,e,c)),c=null},c.ontimeout=function(){let p=E.timeout?"timeout of "+E.timeout+"ms exceeded":"timeout exceeded";const y=E.transitional||transitionalDefaults;E.timeoutErrorMessage&&(p=E.timeoutErrorMessage),d(new AxiosError$1(p,y.clarifyTimeoutError?AxiosError$1.ETIMEDOUT:AxiosError$1.ECONNABORTED,e,c)),c=null},b===void 0&&C.setContentType(null),"setRequestHeader"in c&&utils$1.forEach(C.toJSON(),function(p,y){c.setRequestHeader(y,p)}),utils$1.isUndefined(E.withCredentials)||(c.withCredentials=!!E.withCredentials),A&&A!=="json"&&(c.responseType=E.responseType),g&&([o,t]=progressEventReducer(g,!0),c.addEventListener("progress",o)),a&&c.upload&&([s,r]=progressEventReducer(a),c.upload.addEventListener("progress",s),c.upload.addEventListener("loadend",r)),(E.cancelToken||E.signal)&&(n=v=>{c&&(d(!v||v.type?new CanceledError$1(null,e,c):v),c.abort(),c=null)},E.cancelToken&&E.cancelToken.subscribe(n),E.signal&&(E.signal.aborted?n():E.signal.addEventListener("abort",n)));const f=parseProtocol(E.url);if(f&&platform.protocols.indexOf(f)===-1){d(new AxiosError$1("Unsupported protocol "+f+":",AxiosError$1.ERR_BAD_REQUEST,e));return}c.send(b||null)})},composeSignals=(e,u)=>{const{length:l}=e=e?e.filter(Boolean):[];if(u||l){let d=new AbortController,E;const b=function(g){if(!E){E=!0,A();const n=g instanceof Error?g:this.reason;d.abort(n instanceof AxiosError$1?n:new CanceledError$1(n instanceof Error?n.message:n))}};let C=u&&setTimeout(()=>{C=null,b(new AxiosError$1(`timeout ${u} of ms exceeded`,AxiosError$1.ETIMEDOUT))},u);const A=()=>{e&&(C&&clearTimeout(C),C=null,e.forEach(g=>{g.unsubscribe?g.unsubscribe(b):g.removeEventListener("abort",b)}),e=null)};e.forEach(g=>g.addEventListener("abort",b));const{signal:a}=d;return a.unsubscribe=()=>utils$1.asap(A),a}},streamChunk=function*(e,u){let l=e.byteLength;if(l<u){yield e;return}let d=0,E;for(;d<l;)E=d+u,yield e.slice(d,E),d=E},readBytes=async function*(e,u){for await(const l of readStream(e))yield*streamChunk(l,u)},readStream=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const u=e.getReader();try{for(;;){const{done:l,value:d}=await u.read();if(l)break;yield d}}finally{await u.cancel()}},trackStream=(e,u,l,d)=>{const E=readBytes(e,u);let b=0,C,A=a=>{C||(C=!0,d&&d(a))};return new ReadableStream({async pull(a){try{const{done:g,value:n}=await E.next();if(g){A(),a.close();return}let s=n.byteLength;if(l){let o=b+=s;l(o)}a.enqueue(new Uint8Array(n))}catch(g){throw A(g),g}},cancel(a){return A(a),E.return()}},{highWaterMark:2})},isFetchSupported=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",isReadableStreamSupported=isFetchSupported&&typeof ReadableStream=="function",encodeText=isFetchSupported&&(typeof TextEncoder=="function"?(e=>u=>e.encode(u))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),test=(e,...u)=>{try{return!!e(...u)}catch{return!1}},supportsRequestStream=isReadableStreamSupported&&test(()=>{let e=!1;const u=new Request(platform.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!u}),DEFAULT_CHUNK_SIZE=64*1024,supportsResponseStream=isReadableStreamSupported&&test(()=>utils$1.isReadableStream(new Response("").body)),resolvers={stream:supportsResponseStream&&(e=>e.body)};isFetchSupported&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(u=>{!resolvers[u]&&(resolvers[u]=utils$1.isFunction(e[u])?l=>l[u]():(l,d)=>{throw new AxiosError$1(`Response type '${u}' is not supported`,AxiosError$1.ERR_NOT_SUPPORT,d)})})})(new Response);const getBodyLength=async e=>{if(e==null)return 0;if(utils$1.isBlob(e))return e.size;if(utils$1.isSpecCompliantForm(e))return(await new Request(platform.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(utils$1.isArrayBufferView(e)||utils$1.isArrayBuffer(e))return e.byteLength;if(utils$1.isURLSearchParams(e)&&(e=e+""),utils$1.isString(e))return(await encodeText(e)).byteLength},resolveBodyLength=async(e,u)=>{const l=utils$1.toFiniteNumber(e.getContentLength());return l??getBodyLength(u)},fetchAdapter=isFetchSupported&&(async e=>{let{url:u,method:l,data:d,signal:E,cancelToken:b,timeout:C,onDownloadProgress:A,onUploadProgress:a,responseType:g,headers:n,withCredentials:s="same-origin",fetchOptions:o}=resolveConfig(e);g=g?(g+"").toLowerCase():"text";let r=composeSignals([E,b&&b.toAbortSignal()],C),t;const i=r&&r.unsubscribe&&(()=>{r.unsubscribe()});let c;try{if(a&&supportsRequestStream&&l!=="get"&&l!=="head"&&(c=await resolveBodyLength(n,d))!==0){let y=new Request(u,{method:"POST",body:d,duplex:"half"}),m;if(utils$1.isFormData(d)&&(m=y.headers.get("content-type"))&&n.setContentType(m),y.body){const[$,N]=progressEventDecorator(c,progressEventReducer(asyncDecorator(a)));d=trackStream(y.body,DEFAULT_CHUNK_SIZE,$,N)}}utils$1.isString(s)||(s=s?"include":"omit");const h="credentials"in Request.prototype;t=new Request(u,{...o,signal:r,method:l.toUpperCase(),headers:n.normalize().toJSON(),body:d,duplex:"half",credentials:h?s:void 0});let f=await fetch(t);const v=supportsResponseStream&&(g==="stream"||g==="response");if(supportsResponseStream&&(A||v&&i)){const y={};["status","statusText","headers"].forEach(M=>{y[M]=f[M]});const m=utils$1.toFiniteNumber(f.headers.get("content-length")),[$,N]=A&&progressEventDecorator(m,progressEventReducer(asyncDecorator(A),!0))||[];f=new Response(trackStream(f.body,DEFAULT_CHUNK_SIZE,$,()=>{N&&N(),i&&i()}),y)}g=g||"text";let p=await resolvers[utils$1.findKey(resolvers,g)||"text"](f,e);return!v&&i&&i(),await new Promise((y,m)=>{settle(y,m,{data:p,headers:AxiosHeaders$1.from(f.headers),status:f.status,statusText:f.statusText,config:e,request:t})})}catch(h){throw i&&i(),h&&h.name==="TypeError"&&/fetch/i.test(h.message)?Object.assign(new AxiosError$1("Network Error",AxiosError$1.ERR_NETWORK,e,t),{cause:h.cause||h}):AxiosError$1.from(h,h&&h.code,e,t)}}),knownAdapters={http:httpAdapter,xhr:xhrAdapter,fetch:fetchAdapter};utils$1.forEach(knownAdapters,(e,u)=>{if(e){try{Object.defineProperty(e,"name",{value:u})}catch{}Object.defineProperty(e,"adapterName",{value:u})}});const renderReason=e=>`- ${e}`,isResolvedHandle=e=>utils$1.isFunction(e)||e===null||e===!1,adapters={getAdapter:e=>{e=utils$1.isArray(e)?e:[e];const{length:u}=e;let l,d;const E={};for(let b=0;b<u;b++){l=e[b];let C;if(d=l,!isResolvedHandle(l)&&(d=knownAdapters[(C=String(l)).toLowerCase()],d===void 0))throw new AxiosError$1(`Unknown adapter '${C}'`);if(d)break;E[C||"#"+b]=d}if(!d){const b=Object.entries(E).map(([A,a])=>`adapter ${A} `+(a===!1?"is not supported by the environment":"is not available in the build"));let C=u?b.length>1?`since :
988
+ `+b.map(renderReason).join(`
989
+ `):" "+renderReason(b[0]):"as no adapter specified";throw new AxiosError$1("There is no suitable adapter to dispatch the request "+C,"ERR_NOT_SUPPORT")}return d},adapters:knownAdapters};function throwIfCancellationRequested(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new CanceledError$1(null,e)}function dispatchRequest(e){return throwIfCancellationRequested(e),e.headers=AxiosHeaders$1.from(e.headers),e.data=transformData.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),adapters.getAdapter(e.adapter||defaults.adapter)(e).then(function(d){return throwIfCancellationRequested(e),d.data=transformData.call(e,e.transformResponse,d),d.headers=AxiosHeaders$1.from(d.headers),d},function(d){return isCancel$1(d)||(throwIfCancellationRequested(e),d&&d.response&&(d.response.data=transformData.call(e,e.transformResponse,d.response),d.response.headers=AxiosHeaders$1.from(d.response.headers))),Promise.reject(d)})}const VERSION$3="1.8.4",validators$1={};["object","boolean","number","function","string","symbol"].forEach((e,u)=>{validators$1[e]=function(d){return typeof d===e||"a"+(u<1?"n ":" ")+e}});const deprecatedWarnings={};validators$1.transitional=function e(u,l,d){function E(b,C){return"[Axios v"+VERSION$3+"] Transitional option '"+b+"'"+C+(d?". "+d:"")}return(b,C,A)=>{if(u===!1)throw new AxiosError$1(E(C," has been removed"+(l?" in "+l:"")),AxiosError$1.ERR_DEPRECATED);return l&&!deprecatedWarnings[C]&&(deprecatedWarnings[C]=!0,console.warn(E(C," has been deprecated since v"+l+" and will be removed in the near future"))),u?u(b,C,A):!0}},validators$1.spelling=function e(u){return(l,d)=>(console.warn(`${d} is likely a misspelling of ${u}`),!0)};function assertOptions(e,u,l){if(typeof e!="object")throw new AxiosError$1("options must be an object",AxiosError$1.ERR_BAD_OPTION_VALUE);const d=Object.keys(e);let E=d.length;for(;E-- >0;){const b=d[E],C=u[b];if(C){const A=e[b],a=A===void 0||C(A,b,e);if(a!==!0)throw new AxiosError$1("option "+b+" must be "+a,AxiosError$1.ERR_BAD_OPTION_VALUE);continue}if(l!==!0)throw new AxiosError$1("Unknown option "+b,AxiosError$1.ERR_BAD_OPTION)}}const validator={assertOptions,validators:validators$1},validators=validator.validators;let Axios$1=class{constructor(u){this.defaults=u,this.interceptors={request:new InterceptorManager,response:new InterceptorManager}}async request(u,l){try{return await this._request(u,l)}catch(d){if(d instanceof Error){let E={};Error.captureStackTrace?Error.captureStackTrace(E):E=new Error;const b=E.stack?E.stack.replace(/^.+\n/,""):"";try{d.stack?b&&!String(d.stack).endsWith(b.replace(/^.+\n.+\n/,""))&&(d.stack+=`
990
+ `+b):d.stack=b}catch{}}throw d}}_request(u,l){typeof u=="string"?(l=l||{},l.url=u):l=u||{},l=mergeConfig$1(this.defaults,l);const{transitional:d,paramsSerializer:E,headers:b}=l;d!==void 0&&validator.assertOptions(d,{silentJSONParsing:validators.transitional(validators.boolean),forcedJSONParsing:validators.transitional(validators.boolean),clarifyTimeoutError:validators.transitional(validators.boolean)},!1),E!=null&&(utils$1.isFunction(E)?l.paramsSerializer={serialize:E}:validator.assertOptions(E,{encode:validators.function,serialize:validators.function},!0)),l.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?l.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:l.allowAbsoluteUrls=!0),validator.assertOptions(l,{baseUrl:validators.spelling("baseURL"),withXsrfToken:validators.spelling("withXSRFToken")},!0),l.method=(l.method||this.defaults.method||"get").toLowerCase();let C=b&&utils$1.merge(b.common,b[l.method]);b&&utils$1.forEach(["delete","get","head","post","put","patch","common"],t=>{delete b[t]}),l.headers=AxiosHeaders$1.concat(C,b);const A=[];let a=!0;this.interceptors.request.forEach(function(i){typeof i.runWhen=="function"&&i.runWhen(l)===!1||(a=a&&i.synchronous,A.unshift(i.fulfilled,i.rejected))});const g=[];this.interceptors.response.forEach(function(i){g.push(i.fulfilled,i.rejected)});let n,s=0,o;if(!a){const t=[dispatchRequest.bind(this),void 0];for(t.unshift.apply(t,A),t.push.apply(t,g),o=t.length,n=Promise.resolve(l);s<o;)n=n.then(t[s++],t[s++]);return n}o=A.length;let r=l;for(s=0;s<o;){const t=A[s++],i=A[s++];try{r=t(r)}catch(c){i.call(this,c);break}}try{n=dispatchRequest.call(this,r)}catch(t){return Promise.reject(t)}for(s=0,o=g.length;s<o;)n=n.then(g[s++],g[s++]);return n}getUri(u){u=mergeConfig$1(this.defaults,u);const l=buildFullPath(u.baseURL,u.url,u.allowAbsoluteUrls);return buildURL(l,u.params,u.paramsSerializer)}};utils$1.forEach(["delete","get","head","options"],function e(u){Axios$1.prototype[u]=function(l,d){return this.request(mergeConfig$1(d||{},{method:u,url:l,data:(d||{}).data}))}}),utils$1.forEach(["post","put","patch"],function e(u){function l(d){return function(b,C,A){return this.request(mergeConfig$1(A||{},{method:u,headers:d?{"Content-Type":"multipart/form-data"}:{},url:b,data:C}))}}Axios$1.prototype[u]=l(),Axios$1.prototype[u+"Form"]=l(!0)});let CancelToken$1=class we{constructor(u){if(typeof u!="function")throw new TypeError("executor must be a function.");let l;this.promise=new Promise(function(b){l=b});const d=this;this.promise.then(E=>{if(!d._listeners)return;let b=d._listeners.length;for(;b-- >0;)d._listeners[b](E);d._listeners=null}),this.promise.then=E=>{let b;const C=new Promise(A=>{d.subscribe(A),b=A}).then(E);return C.cancel=function(){d.unsubscribe(b)},C},u(function(b,C,A){d.reason||(d.reason=new CanceledError$1(b,C,A),l(d.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(u){if(this.reason){u(this.reason);return}this._listeners?this._listeners.push(u):this._listeners=[u]}unsubscribe(u){if(!this._listeners)return;const l=this._listeners.indexOf(u);l!==-1&&this._listeners.splice(l,1)}toAbortSignal(){const u=new AbortController,l=d=>{u.abort(d)};return this.subscribe(l),u.signal.unsubscribe=()=>this.unsubscribe(l),u.signal}static source(){let u;return{token:new we(function(E){u=E}),cancel:u}}};function spread$1(e){return function(l){return e.apply(null,l)}}function isAxiosError$1(e){return utils$1.isObject(e)&&e.isAxiosError===!0}const HttpStatusCode$1={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};Object.entries(HttpStatusCode$1).forEach(([e,u])=>{HttpStatusCode$1[u]=e});function createInstance(e){const u=new Axios$1(e),l=bind(Axios$1.prototype.request,u);return utils$1.extend(l,Axios$1.prototype,u,{allOwnKeys:!0}),utils$1.extend(l,u,null,{allOwnKeys:!0}),l.create=function(E){return createInstance(mergeConfig$1(e,E))},l}const axios=createInstance(defaults);axios.Axios=Axios$1,axios.CanceledError=CanceledError$1,axios.CancelToken=CancelToken$1,axios.isCancel=isCancel$1,axios.VERSION=VERSION$3,axios.toFormData=toFormData$1,axios.AxiosError=AxiosError$1,axios.Cancel=axios.CanceledError,axios.all=function e(u){return Promise.all(u)},axios.spread=spread$1,axios.isAxiosError=isAxiosError$1,axios.mergeConfig=mergeConfig$1,axios.AxiosHeaders=AxiosHeaders$1,axios.formToJSON=e=>formDataToJSON(utils$1.isHTMLForm(e)?new FormData(e):e),axios.getAdapter=adapters.getAdapter,axios.HttpStatusCode=HttpStatusCode$1,axios.default=axios;const{Axios,AxiosError,CanceledError,isCancel,CancelToken,VERSION:VERSION$2,all,Cancel,isAxiosError,spread,toFormData,AxiosHeaders,HttpStatusCode,formToJSON,getAdapter,mergeConfig}=axios,components=[{name:"容器",components:[{key:10001,type:"grid",category:"container",icon:"grid",cols:[{key:10002},{key:10002}],options:{name:"",hidden:!1,gutter:12,colHeight:null,customClass:[]},id:""},{key:10002,display:!1,type:"grid-col",category:"container",icon:"grid-col",internal:!0,widgetList:[],options:{name:"",hidden:!1,span:12,offset:0,push:0,pull:0,responsive:!1,md:12,sm:12,xs:12,customClass:[]},id:""}]},{name:"基础字段",components:[{key:20001,type:"input",icon:"text-field",formItemFlag:!0,options:{name:"",label:"input",labelAlign:"",type:"text",defaultValue:"",submitType:"",placeholder:"",columnWidth:"200px",size:"",labelWidth:null,labelHidden:!1,readonly:!1,disabled:!1,hidden:!1,clearable:!0,showPassword:!1,required:!1,requiredHint:"",validation:"",validationHint:"",customClass:[],labelIconClass:null,labelIconPosition:"rear",labelTooltip:null,minLength:null,maxLength:null,showWordLimit:!1,prefixIcon:"",suffixIcon:"",appendButton:!1,appendButtonDisabled:!1,buttonIcon:"custom-search",onCreated:"",onMounted:"",onInput:"",onChange:"",onFocus:"",onBlur:"",onValidate:"",onAppendButtonClick:""},id:""},{key:20002,type:"textarea",icon:"textarea-field",formItemFlag:!0,options:{name:"",label:"textarea",labelAlign:"",rows:3,defaultValue:"",submitType:"",placeholder:"",columnWidth:"200px",size:"",labelWidth:null,labelHidden:!1,readonly:!1,disabled:!1,hidden:!1,required:!1,requiredHint:"",validation:"",validationHint:"",customClass:[],labelIconClass:null,labelIconPosition:"rear",labelTooltip:null,minLength:null,maxLength:null,showWordLimit:!1,onCreated:"",onMounted:"",onInput:"",onChange:"",onFocus:"",onBlur:"",onValidate:""},id:""},{key:20003,type:"radio",icon:"radio-field",formItemFlag:!0,options:{name:"",label:"radio",labelAlign:"",defaultValue:null,submitType:"",columnWidth:"200px",size:"",displayStyle:"inline",buttonStyle:!1,border:!1,labelWidth:null,labelHidden:!1,disabled:!1,hidden:!1,optionItems:[{label:"radio 1",value:1},{label:"radio 2",value:2},{label:"radio 3",value:3}],required:!1,requiredHint:"",validation:"",validationHint:"",customClass:"",labelIconClass:null,labelIconPosition:"rear",labelTooltip:null,onCreated:"",onMounted:"",onChange:"",onValidate:""},id:""},{key:20004,type:"checkbox",icon:"checkbox-field",formItemFlag:!0,options:{name:"",label:"checkbox",labelAlign:"",defaultValue:[],submitType:"",columnWidth:"200px",size:"",displayStyle:"inline",buttonStyle:!1,border:!1,labelWidth:null,labelHidden:!1,disabled:!1,hidden:!1,optionItems:[{label:"check 1",value:1},{label:"check 2",value:2},{label:"check 3",value:3}],required:!1,requiredHint:"",validation:"",validationHint:"",customClass:[],labelIconClass:null,labelIconPosition:"rear",labelTooltip:null,onCreated:"",onMounted:"",onChange:"",onValidate:""},id:""},{key:20005,type:"select",icon:"select-field",formItemFlag:!0,options:{name:"",label:"select",labelAlign:"",defaultValue:"",submitType:"",placeholder:"",columnWidth:"200px",size:"",labelWidth:null,labelHidden:!1,disabled:!1,hidden:!1,clearable:!0,filterable:!1,allowCreate:!1,remote:!1,automaticDropdown:!1,multiple:!1,multipleLimit:0,optionItems:[{label:"select 1",value:1},{label:"select 2",value:2},{label:"select 3",value:3}],required:!1,requiredHint:"",validation:"",validationHint:"",customClass:"",labelIconClass:null,labelIconPosition:"rear",labelTooltip:null,onCreated:"",onMounted:"",onRemoteQuery:"",onChange:"",onFocus:"",onBlur:"",onValidate:""},id:""},{key:20006,type:"static-title",icon:"static-text",formItemFlag:!1,options:{name:"",titleLevel:1,columnWidth:"200px",hidden:!1,textContent:"static text",textAlign:"center",fontSize:"13px",preWrap:!1,customClass:"",onCreated:"",onMounted:"",label:"static title"},id:""}]},{name:"高级字段",components:[{key:30001,type:"picture-upload",icon:"picture-upload-field",formItemFlag:!0,options:{name:"",label:"picture-upload",labelAlign:"",defaultBg:"",labelWidth:null,labelHidden:!1,columnWidth:"200px",disabled:!1,hidden:!1,required:!1,requiredHint:"",customRule:"",customRuleHint:"",uploadURL:"",isShowTip:!1,uploadTip:"",withCredentials:!1,multipleSelect:!1,showFileList:!0,limit:3,fileMaxSize:5,fileTypes:["jpg","jpeg","png"],customClass:"",labelIconClass:null,labelIconPosition:"rear",labelTooltip:null,signatureUrl:"",requireMd5:!1,queryFileMd5Url:"",addFileMd5Url:"",onCreated:"",onMounted:"",onBeforeUpload:"",onUploadSuccess:"",onUploadError:"",onFileRemove:"",onValidate:""},id:""}]}];function generateId(e){return e+(Date.parse(new Date)+Math.floor(Math.random()*9e4+1e4))}function idToName(e){return e.split("-").map((l,d)=>d==0?l:l.substr(0,1).toUpperCase()+l.substr(1)).join("")}function useComponentUtils(){const e=JSON.parse(JSON.stringify(components)),u=vue.ref(e),l=vue.ref({});l.value=e.reduce((b,C)=>(C.components.map(A=>{b[A.key]=A}),b),{});const d=b=>{if(!b.options){const C=JSON.parse(JSON.stringify(l.value[b.key]));Object.assign(b,C)}b.id=generateId(b.type),b.options.name=idToName(b.id),b.category=="container"&&(b.type=="grid"?b.cols.forEach(C=>{d(C)}):b.type=="grid-col"&&b.widgetList.forEach(C=>{d(C)}))};return{initComp:d,cloneItem:b=>{const C=JSON.parse(JSON.stringify(b));return d(C),C},allComponents:u,componentsMap:l}}/*!
991
+ * shared v11.1.2
992
+ * (c) 2025 kazuya kawaguchi
993
+ * Released under the MIT License.
994
+ */const inBrowser=typeof window<"u";let mark,measure;if(process.env.NODE_ENV!=="production"){const e=inBrowser&&window.performance;e&&e.mark&&e.measure&&e.clearMarks&&e.clearMeasures&&(mark=u=>{e.mark(u)},measure=(u,l,d)=>{e.measure(u,l,d),e.clearMarks(l),e.clearMarks(d)})}const RE_ARGS=/\{([0-9a-zA-Z]+)\}/g;function format$1(e,...u){return u.length===1&&isObject(u[0])&&(u=u[0]),(!u||!u.hasOwnProperty)&&(u={}),e.replace(RE_ARGS,(l,d)=>u.hasOwnProperty(d)?u[d]:"")}const makeSymbol=(e,u=!1)=>u?Symbol.for(e):Symbol(e),generateFormatCacheKey=(e,u,l)=>friendlyJSONstringify({l:e,k:u,s:l}),friendlyJSONstringify=e=>JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029").replace(/\u0027/g,"\\u0027"),isNumber=e=>typeof e=="number"&&isFinite(e),isDate=e=>toTypeString(e)==="[object Date]",isRegExp=e=>toTypeString(e)==="[object RegExp]",isEmptyObject=e=>isPlainObject(e)&&Object.keys(e).length===0,assign=Object.assign,_create=Object.create,create=(e=null)=>_create(e);let _globalThis;const getGlobalThis=()=>_globalThis||(_globalThis=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:create());function escapeHtml(e){return e.replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")}const hasOwnProperty=Object.prototype.hasOwnProperty;function hasOwn(e,u){return hasOwnProperty.call(e,u)}const isArray=Array.isArray,isFunction=e=>typeof e=="function",isString=e=>typeof e=="string",isBoolean=e=>typeof e=="boolean",isObject=e=>e!==null&&typeof e=="object",isPromise=e=>isObject(e)&&isFunction(e.then)&&isFunction(e.catch),objectToString=Object.prototype.toString,toTypeString=e=>objectToString.call(e),isPlainObject=e=>toTypeString(e)==="[object Object]",toDisplayString=e=>e==null?"":isArray(e)||isPlainObject(e)&&e.toString===objectToString?JSON.stringify(e,null,2):String(e);function join(e,u=""){return e.reduce((l,d,E)=>E===0?l+d:l+u+d,"")}const RANGE=2;function generateCodeFrame(e,u=0,l=e.length){const d=e.split(/\r?\n/);let E=0;const b=[];for(let C=0;C<d.length;C++)if(E+=d[C].length+1,E>=u){for(let A=C-RANGE;A<=C+RANGE||l>E;A++){if(A<0||A>=d.length)continue;const a=A+1;b.push(`${a}${" ".repeat(3-String(a).length)}| ${d[A]}`);const g=d[A].length;if(A===C){const n=u-(E-g)+1,s=Math.max(1,l>E?g-n:l-u);b.push(" | "+" ".repeat(n)+"^".repeat(s))}else if(A>C){if(l>E){const n=Math.max(Math.min(l-E,g),1);b.push(" | "+"^".repeat(n))}E+=g+1}}break}return b.join(`
995
+ `)}function warn(e,u){typeof console<"u"&&(console.warn("[intlify] "+e),u&&console.warn(u.stack))}const hasWarned={};function warnOnce(e){hasWarned[e]||(hasWarned[e]=!0,warn(e))}function createEmitter(){const e=new Map;return{events:e,on(l,d){const E=e.get(l);E&&E.push(d)||e.set(l,[d])},off(l,d){const E=e.get(l);E&&E.splice(E.indexOf(d)>>>0,1)},emit(l,d){(e.get(l)||[]).slice().map(E=>E(d)),(e.get("*")||[]).slice().map(E=>E(l,d))}}}const isNotObjectOrIsArray=e=>!isObject(e)||isArray(e);function deepCopy(e,u){if(isNotObjectOrIsArray(e)||isNotObjectOrIsArray(u))throw new Error("Invalid value");const l=[{src:e,des:u}];for(;l.length;){const{src:d,des:E}=l.pop();Object.keys(d).forEach(b=>{b!=="__proto__"&&(isObject(d[b])&&!isObject(E[b])&&(E[b]=Array.isArray(d[b])?[]:create()),isNotObjectOrIsArray(E[b])||isNotObjectOrIsArray(d[b])?E[b]=d[b]:l.push({src:d[b],des:E[b]}))})}}/*!
996
+ * message-compiler v11.1.2
997
+ * (c) 2025 kazuya kawaguchi
998
+ * Released under the MIT License.
999
+ */function createPosition(e,u,l){return{line:e,column:u,offset:l}}function createLocation(e,u,l){return{start:e,end:u}}const CompileErrorCodes={EXPECTED_TOKEN:1,INVALID_TOKEN_IN_PLACEHOLDER:2,UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER:3,UNKNOWN_ESCAPE_SEQUENCE:4,INVALID_UNICODE_ESCAPE_SEQUENCE:5,UNBALANCED_CLOSING_BRACE:6,UNTERMINATED_CLOSING_BRACE:7,EMPTY_PLACEHOLDER:8,NOT_ALLOW_NEST_PLACEHOLDER:9,INVALID_LINKED_FORMAT:10,MUST_HAVE_MESSAGES_IN_PLURAL:11,UNEXPECTED_EMPTY_LINKED_MODIFIER:12,UNEXPECTED_EMPTY_LINKED_KEY:13,UNEXPECTED_LEXICAL_ANALYSIS:14,UNHANDLED_CODEGEN_NODE_TYPE:15,UNHANDLED_MINIFIER_NODE_TYPE:16},COMPILE_ERROR_CODES_EXTEND_POINT=17,errorMessages$2={[CompileErrorCodes.EXPECTED_TOKEN]:"Expected token: '{0}'",[CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER]:"Invalid token in placeholder: '{0}'",[CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER]:"Unterminated single quote in placeholder",[CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE]:"Unknown escape sequence: \\{0}",[CompileErrorCodes.INVALID_UNICODE_ESCAPE_SEQUENCE]:"Invalid unicode escape sequence: {0}",[CompileErrorCodes.UNBALANCED_CLOSING_BRACE]:"Unbalanced closing brace",[CompileErrorCodes.UNTERMINATED_CLOSING_BRACE]:"Unterminated closing brace",[CompileErrorCodes.EMPTY_PLACEHOLDER]:"Empty placeholder",[CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER]:"Not allowed nest placeholder",[CompileErrorCodes.INVALID_LINKED_FORMAT]:"Invalid linked format",[CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL]:"Plural must have messages",[CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER]:"Unexpected empty linked modifier",[CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY]:"Unexpected empty linked key",[CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS]:"Unexpected lexical analysis in token: '{0}'",[CompileErrorCodes.UNHANDLED_CODEGEN_NODE_TYPE]:"unhandled codegen node type: '{0}'",[CompileErrorCodes.UNHANDLED_MINIFIER_NODE_TYPE]:"unhandled mimifier node type: '{0}'"};function createCompileError(e,u,l={}){const{domain:d,messages:E,args:b}=l,C=process.env.NODE_ENV!=="production"?format$1((E||errorMessages$2)[e]||"",...b||[]):e,A=new SyntaxError(String(C));return A.code=e,u&&(A.location=u),A.domain=d,A}function defaultOnError(e){throw e}const RE_HTML_TAG=/<\/?[\w\s="/.':;#-\/]+>/,detectHtmlTag=e=>RE_HTML_TAG.test(e),CHAR_SP=" ",CHAR_CR="\r",CHAR_LF=`
1000
+ `,CHAR_LS="\u2028",CHAR_PS="\u2029";function createScanner(e){const u=e;let l=0,d=1,E=1,b=0;const C=$=>u[$]===CHAR_CR&&u[$+1]===CHAR_LF,A=$=>u[$]===CHAR_LF,a=$=>u[$]===CHAR_PS,g=$=>u[$]===CHAR_LS,n=$=>C($)||A($)||a($)||g($),s=()=>l,o=()=>d,r=()=>E,t=()=>b,i=$=>C($)||a($)||g($)?CHAR_LF:u[$],c=()=>i(l),h=()=>i(l+b);function f(){return b=0,n(l)&&(d++,E=0),C(l)&&l++,l++,E++,u[l]}function v(){return C(l+b)&&b++,b++,u[l+b]}function p(){l=0,d=1,E=1,b=0}function y($=0){b=$}function m(){const $=l+b;for(;$!==l;)f();b=0}return{index:s,line:o,column:r,peekOffset:t,charAt:i,currentChar:c,currentPeek:h,next:f,peek:v,reset:p,resetPeek:y,skipToPeek:m}}const EOF=void 0,DOT=".",LITERAL_DELIMITER="'",ERROR_DOMAIN$3="tokenizer";function createTokenizer(e,u={}){const l=u.location!==!1,d=createScanner(e),E=()=>d.index(),b=()=>createPosition(d.line(),d.column(),d.index()),C=b(),A=E(),a={currentType:13,offset:A,startLoc:C,endLoc:C,lastType:13,lastOffset:A,lastStartLoc:C,lastEndLoc:C,braceNest:0,inLinked:!1,text:""},g=()=>a,{onError:n}=u;function s(W,G,X,...te){const ge=g();if(G.column+=X,G.offset+=X,n){const fe=l?createLocation(ge.startLoc,G):null,oe=createCompileError(W,fe,{domain:ERROR_DOMAIN$3,args:te});n(oe)}}function o(W,G,X){W.endLoc=b(),W.currentType=G;const te={type:G};return l&&(te.loc=createLocation(W.startLoc,W.endLoc)),X!=null&&(te.value=X),te}const r=W=>o(W,13);function t(W,G){return W.currentChar()===G?(W.next(),G):(s(CompileErrorCodes.EXPECTED_TOKEN,b(),0,G),"")}function i(W){let G="";for(;W.currentPeek()===CHAR_SP||W.currentPeek()===CHAR_LF;)G+=W.currentPeek(),W.peek();return G}function c(W){const G=i(W);return W.skipToPeek(),G}function h(W){if(W===EOF)return!1;const G=W.charCodeAt(0);return G>=97&&G<=122||G>=65&&G<=90||G===95}function f(W){if(W===EOF)return!1;const G=W.charCodeAt(0);return G>=48&&G<=57}function v(W,G){const{currentType:X}=G;if(X!==2)return!1;i(W);const te=h(W.currentPeek());return W.resetPeek(),te}function p(W,G){const{currentType:X}=G;if(X!==2)return!1;i(W);const te=W.currentPeek()==="-"?W.peek():W.currentPeek(),ge=f(te);return W.resetPeek(),ge}function y(W,G){const{currentType:X}=G;if(X!==2)return!1;i(W);const te=W.currentPeek()===LITERAL_DELIMITER;return W.resetPeek(),te}function m(W,G){const{currentType:X}=G;if(X!==7)return!1;i(W);const te=W.currentPeek()===".";return W.resetPeek(),te}function $(W,G){const{currentType:X}=G;if(X!==8)return!1;i(W);const te=h(W.currentPeek());return W.resetPeek(),te}function N(W,G){const{currentType:X}=G;if(!(X===7||X===11))return!1;i(W);const te=W.currentPeek()===":";return W.resetPeek(),te}function M(W,G){const{currentType:X}=G;if(X!==9)return!1;const te=()=>{const fe=W.currentPeek();return fe==="{"?h(W.peek()):fe==="@"||fe==="|"||fe===":"||fe==="."||fe===CHAR_SP||!fe?!1:fe===CHAR_LF?(W.peek(),te()):O(W,!1)},ge=te();return W.resetPeek(),ge}function S(W){i(W);const G=W.currentPeek()==="|";return W.resetPeek(),G}function O(W,G=!0){const X=(ge=!1,fe="")=>{const oe=W.currentPeek();return oe==="{"||oe==="@"||!oe?ge:oe==="|"?!(fe===CHAR_SP||fe===CHAR_LF):oe===CHAR_SP?(W.peek(),X(!0,CHAR_SP)):oe===CHAR_LF?(W.peek(),X(!0,CHAR_LF)):!0},te=X();return G&&W.resetPeek(),te}function x(W,G){const X=W.currentChar();return X===EOF?EOF:G(X)?(W.next(),X):null}function L(W){const G=W.charCodeAt(0);return G>=97&&G<=122||G>=65&&G<=90||G>=48&&G<=57||G===95||G===36}function I(W){return x(W,L)}function w(W){const G=W.charCodeAt(0);return G>=97&&G<=122||G>=65&&G<=90||G>=48&&G<=57||G===95||G===36||G===45}function _(W){return x(W,w)}function T(W){const G=W.charCodeAt(0);return G>=48&&G<=57}function k(W){return x(W,T)}function R(W){const G=W.charCodeAt(0);return G>=48&&G<=57||G>=65&&G<=70||G>=97&&G<=102}function D(W){return x(W,R)}function V(W){let G="",X="";for(;G=k(W);)X+=G;return X}function B(W){let G="";for(;;){const X=W.currentChar();if(X==="{"||X==="}"||X==="@"||X==="|"||!X)break;if(X===CHAR_SP||X===CHAR_LF)if(O(W))G+=X,W.next();else{if(S(W))break;G+=X,W.next()}else G+=X,W.next()}return G}function F(W){c(W);let G="",X="";for(;G=_(W);)X+=G;return W.currentChar()===EOF&&s(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,b(),0),X}function H(W){c(W);let G="";return W.currentChar()==="-"?(W.next(),G+=`-${V(W)}`):G+=V(W),W.currentChar()===EOF&&s(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,b(),0),G}function U(W){return W!==LITERAL_DELIMITER&&W!==CHAR_LF}function z(W){c(W),t(W,"'");let G="",X="";for(;G=x(W,U);)G==="\\"?X+=K(W):X+=G;const te=W.currentChar();return te===CHAR_LF||te===EOF?(s(CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,b(),0),te===CHAR_LF&&(W.next(),t(W,"'")),X):(t(W,"'"),X)}function K(W){const G=W.currentChar();switch(G){case"\\":case"'":return W.next(),`\\${G}`;case"u":return Y(W,G,4);case"U":return Y(W,G,6);default:return s(CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE,b(),0,G),""}}function Y(W,G,X){t(W,G);let te="";for(let ge=0;ge<X;ge++){const fe=D(W);if(!fe){s(CompileErrorCodes.INVALID_UNICODE_ESCAPE_SEQUENCE,b(),0,`\\${G}${te}${W.currentChar()}`);break}te+=fe}return`\\${G}${te}`}function Q(W){return W!=="{"&&W!=="}"&&W!==CHAR_SP&&W!==CHAR_LF}function J(W){c(W);let G="",X="";for(;G=x(W,Q);)X+=G;return X}function ne(W){let G="",X="";for(;G=I(W);)X+=G;return X}function re(W){const G=X=>{const te=W.currentChar();return te==="{"||te==="@"||te==="|"||te==="("||te===")"||!te||te===CHAR_SP?X:(X+=te,W.next(),G(X))};return G("")}function j(W){c(W);const G=t(W,"|");return c(W),G}function se(W,G){let X=null;switch(W.currentChar()){case"{":return G.braceNest>=1&&s(CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER,b(),0),W.next(),X=o(G,2,"{"),c(W),G.braceNest++,X;case"}":return G.braceNest>0&&G.currentType===2&&s(CompileErrorCodes.EMPTY_PLACEHOLDER,b(),0),W.next(),X=o(G,3,"}"),G.braceNest--,G.braceNest>0&&c(W),G.inLinked&&G.braceNest===0&&(G.inLinked=!1),X;case"@":return G.braceNest>0&&s(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,b(),0),X=ae(W,G)||r(G),G.braceNest=0,X;default:{let ge=!0,fe=!0,oe=!0;if(S(W))return G.braceNest>0&&s(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,b(),0),X=o(G,1,j(W)),G.braceNest=0,G.inLinked=!1,X;if(G.braceNest>0&&(G.currentType===4||G.currentType===5||G.currentType===6))return s(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE,b(),0),G.braceNest=0,me(W,G);if(ge=v(W,G))return X=o(G,4,F(W)),c(W),X;if(fe=p(W,G))return X=o(G,5,H(W)),c(W),X;if(oe=y(W,G))return X=o(G,6,z(W)),c(W),X;if(!ge&&!fe&&!oe)return X=o(G,12,J(W)),s(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER,b(),0,X.value),c(W),X;break}}return X}function ae(W,G){const{currentType:X}=G;let te=null;const ge=W.currentChar();switch((X===7||X===8||X===11||X===9)&&(ge===CHAR_LF||ge===CHAR_SP)&&s(CompileErrorCodes.INVALID_LINKED_FORMAT,b(),0),ge){case"@":return W.next(),te=o(G,7,"@"),G.inLinked=!0,te;case".":return c(W),W.next(),o(G,8,".");case":":return c(W),W.next(),o(G,9,":");default:return S(W)?(te=o(G,1,j(W)),G.braceNest=0,G.inLinked=!1,te):m(W,G)||N(W,G)?(c(W),ae(W,G)):$(W,G)?(c(W),o(G,11,ne(W))):M(W,G)?(c(W),ge==="{"?se(W,G)||te:o(G,10,re(W))):(X===7&&s(CompileErrorCodes.INVALID_LINKED_FORMAT,b(),0),G.braceNest=0,G.inLinked=!1,me(W,G))}}function me(W,G){let X={type:13};if(G.braceNest>0)return se(W,G)||r(G);if(G.inLinked)return ae(W,G)||r(G);switch(W.currentChar()){case"{":return se(W,G)||r(G);case"}":return s(CompileErrorCodes.UNBALANCED_CLOSING_BRACE,b(),0),W.next(),o(G,3,"}");case"@":return ae(W,G)||r(G);default:{if(S(W))return X=o(G,1,j(W)),G.braceNest=0,G.inLinked=!1,X;if(O(W))return o(G,0,B(W));break}}return X}function ye(){const{currentType:W,offset:G,startLoc:X,endLoc:te}=a;return a.lastType=W,a.lastOffset=G,a.lastStartLoc=X,a.lastEndLoc=te,a.offset=E(),a.startLoc=b(),d.currentChar()===EOF?o(a,13):me(d,a)}return{nextToken:ye,currentOffset:E,currentPosition:b,context:g}}const ERROR_DOMAIN$2="parser",KNOWN_ESCAPES=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function fromEscapeSequence(e,u,l){switch(e){case"\\\\":return"\\";case"\\'":return"'";default:{const d=parseInt(u||l,16);return d<=55295||d>=57344?String.fromCodePoint(d):"�"}}}function createParser(e={}){const u=e.location!==!1,{onError:l}=e;function d(h,f,v,p,...y){const m=h.currentPosition();if(m.offset+=p,m.column+=p,l){const $=u?createLocation(v,m):null,N=createCompileError(f,$,{domain:ERROR_DOMAIN$2,args:y});l(N)}}function E(h,f,v){const p={type:h};return u&&(p.start=f,p.end=f,p.loc={start:v,end:v}),p}function b(h,f,v,p){u&&(h.end=f,h.loc&&(h.loc.end=v))}function C(h,f){const v=h.context(),p=E(3,v.offset,v.startLoc);return p.value=f,b(p,h.currentOffset(),h.currentPosition()),p}function A(h,f){const v=h.context(),{lastOffset:p,lastStartLoc:y}=v,m=E(5,p,y);return m.index=parseInt(f,10),h.nextToken(),b(m,h.currentOffset(),h.currentPosition()),m}function a(h,f){const v=h.context(),{lastOffset:p,lastStartLoc:y}=v,m=E(4,p,y);return m.key=f,h.nextToken(),b(m,h.currentOffset(),h.currentPosition()),m}function g(h,f){const v=h.context(),{lastOffset:p,lastStartLoc:y}=v,m=E(9,p,y);return m.value=f.replace(KNOWN_ESCAPES,fromEscapeSequence),h.nextToken(),b(m,h.currentOffset(),h.currentPosition()),m}function n(h){const f=h.nextToken(),v=h.context(),{lastOffset:p,lastStartLoc:y}=v,m=E(8,p,y);return f.type!==11?(d(h,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER,v.lastStartLoc,0),m.value="",b(m,p,y),{nextConsumeToken:f,node:m}):(f.value==null&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,getTokenCaption(f)),m.value=f.value||"",b(m,h.currentOffset(),h.currentPosition()),{node:m})}function s(h,f){const v=h.context(),p=E(7,v.offset,v.startLoc);return p.value=f,b(p,h.currentOffset(),h.currentPosition()),p}function o(h){const f=h.context(),v=E(6,f.offset,f.startLoc);let p=h.nextToken();if(p.type===8){const y=n(h);v.modifier=y.node,p=y.nextConsumeToken||h.nextToken()}switch(p.type!==9&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,f.lastStartLoc,0,getTokenCaption(p)),p=h.nextToken(),p.type===2&&(p=h.nextToken()),p.type){case 10:p.value==null&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,f.lastStartLoc,0,getTokenCaption(p)),v.key=s(h,p.value||"");break;case 4:p.value==null&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,f.lastStartLoc,0,getTokenCaption(p)),v.key=a(h,p.value||"");break;case 5:p.value==null&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,f.lastStartLoc,0,getTokenCaption(p)),v.key=A(h,p.value||"");break;case 6:p.value==null&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,f.lastStartLoc,0,getTokenCaption(p)),v.key=g(h,p.value||"");break;default:{d(h,CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY,f.lastStartLoc,0);const y=h.context(),m=E(7,y.offset,y.startLoc);return m.value="",b(m,y.offset,y.startLoc),v.key=m,b(v,y.offset,y.startLoc),{nextConsumeToken:p,node:v}}}return b(v,h.currentOffset(),h.currentPosition()),{node:v}}function r(h){const f=h.context(),v=f.currentType===1?h.currentOffset():f.offset,p=f.currentType===1?f.endLoc:f.startLoc,y=E(2,v,p);y.items=[];let m=null;do{const M=m||h.nextToken();switch(m=null,M.type){case 0:M.value==null&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,f.lastStartLoc,0,getTokenCaption(M)),y.items.push(C(h,M.value||""));break;case 5:M.value==null&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,f.lastStartLoc,0,getTokenCaption(M)),y.items.push(A(h,M.value||""));break;case 4:M.value==null&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,f.lastStartLoc,0,getTokenCaption(M)),y.items.push(a(h,M.value||""));break;case 6:M.value==null&&d(h,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,f.lastStartLoc,0,getTokenCaption(M)),y.items.push(g(h,M.value||""));break;case 7:{const S=o(h);y.items.push(S.node),m=S.nextConsumeToken||null;break}}}while(f.currentType!==13&&f.currentType!==1);const $=f.currentType===1?f.lastOffset:h.currentOffset(),N=f.currentType===1?f.lastEndLoc:h.currentPosition();return b(y,$,N),y}function t(h,f,v,p){const y=h.context();let m=p.items.length===0;const $=E(1,f,v);$.cases=[],$.cases.push(p);do{const N=r(h);m||(m=N.items.length===0),$.cases.push(N)}while(y.currentType!==13);return m&&d(h,CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL,v,0),b($,h.currentOffset(),h.currentPosition()),$}function i(h){const f=h.context(),{offset:v,startLoc:p}=f,y=r(h);return f.currentType===13?y:t(h,v,p,y)}function c(h){const f=createTokenizer(h,assign({},e)),v=f.context(),p=E(0,v.offset,v.startLoc);return u&&p.loc&&(p.loc.source=h),p.body=i(f),e.onCacheKey&&(p.cacheKey=e.onCacheKey(h)),v.currentType!==13&&d(f,CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,h[v.offset]||""),b(p,f.currentOffset(),f.currentPosition()),p}return{parse:c}}function getTokenCaption(e){if(e.type===13)return"EOF";const u=(e.value||"").replace(/\r?\n/gu,"\\n");return u.length>10?u.slice(0,9)+"…":u}function createTransformer(e,u={}){const l={ast:e,helpers:new Set};return{context:()=>l,helper:b=>(l.helpers.add(b),b)}}function traverseNodes(e,u){for(let l=0;l<e.length;l++)traverseNode(e[l],u)}function traverseNode(e,u){switch(e.type){case 1:traverseNodes(e.cases,u),u.helper("plural");break;case 2:traverseNodes(e.items,u);break;case 6:{traverseNode(e.key,u),u.helper("linked"),u.helper("type");break}case 5:u.helper("interpolate"),u.helper("list");break;case 4:u.helper("interpolate"),u.helper("named");break}}function transform(e,u={}){const l=createTransformer(e);l.helper("normalize"),e.body&&traverseNode(e.body,l);const d=l.context();e.helpers=Array.from(d.helpers)}function optimize(e){const u=e.body;return u.type===2?optimizeMessageNode(u):u.cases.forEach(l=>optimizeMessageNode(l)),e}function optimizeMessageNode(e){if(e.items.length===1){const u=e.items[0];(u.type===3||u.type===9)&&(e.static=u.value,delete u.value)}else{const u=[];for(let l=0;l<e.items.length;l++){const d=e.items[l];if(!(d.type===3||d.type===9)||d.value==null)break;u.push(d.value)}if(u.length===e.items.length){e.static=join(u);for(let l=0;l<e.items.length;l++){const d=e.items[l];(d.type===3||d.type===9)&&delete d.value}}}}const ERROR_DOMAIN$1="minifier";function minify(e){switch(e.t=e.type,e.type){case 0:{const u=e;minify(u.body),u.b=u.body,delete u.body;break}case 1:{const u=e,l=u.cases;for(let d=0;d<l.length;d++)minify(l[d]);u.c=l,delete u.cases;break}case 2:{const u=e,l=u.items;for(let d=0;d<l.length;d++)minify(l[d]);u.i=l,delete u.items,u.static&&(u.s=u.static,delete u.static);break}case 3:case 9:case 8:case 7:{const u=e;u.value&&(u.v=u.value,delete u.value);break}case 6:{const u=e;minify(u.key),u.k=u.key,delete u.key,u.modifier&&(minify(u.modifier),u.m=u.modifier,delete u.modifier);break}case 5:{const u=e;u.i=u.index,delete u.index;break}case 4:{const u=e;u.k=u.key,delete u.key;break}default:if(process.env.NODE_ENV!=="production")throw createCompileError(CompileErrorCodes.UNHANDLED_MINIFIER_NODE_TYPE,null,{domain:ERROR_DOMAIN$1,args:[e.type]})}delete e.type}const ERROR_DOMAIN="parser";function createCodeGenerator(e,u){const{filename:l,breakLineCode:d,needIndent:E}=u,b=u.location!==!1,C={filename:l,code:"",column:1,line:1,offset:0,map:void 0,breakLineCode:d,needIndent:E,indentLevel:0};b&&e.loc&&(C.source=e.loc.source);const A=()=>C;function a(i,c){C.code+=i}function g(i,c=!0){const h=c?d:"";a(E?h+" ".repeat(i):h)}function n(i=!0){const c=++C.indentLevel;i&&g(c)}function s(i=!0){const c=--C.indentLevel;i&&g(c)}function o(){g(C.indentLevel)}return{context:A,push:a,indent:n,deindent:s,newline:o,helper:i=>`_${i}`,needIndent:()=>C.needIndent}}function generateLinkedNode(e,u){const{helper:l}=e;e.push(`${l("linked")}(`),generateNode(e,u.key),u.modifier?(e.push(", "),generateNode(e,u.modifier),e.push(", _type")):e.push(", undefined, _type"),e.push(")")}function generateMessageNode(e,u){const{helper:l,needIndent:d}=e;e.push(`${l("normalize")}([`),e.indent(d());const E=u.items.length;for(let b=0;b<E&&(generateNode(e,u.items[b]),b!==E-1);b++)e.push(", ");e.deindent(d()),e.push("])")}function generatePluralNode(e,u){const{helper:l,needIndent:d}=e;if(u.cases.length>1){e.push(`${l("plural")}([`),e.indent(d());const E=u.cases.length;for(let b=0;b<E&&(generateNode(e,u.cases[b]),b!==E-1);b++)e.push(", ");e.deindent(d()),e.push("])")}}function generateResource(e,u){u.body?generateNode(e,u.body):e.push("null")}function generateNode(e,u){const{helper:l}=e;switch(u.type){case 0:generateResource(e,u);break;case 1:generatePluralNode(e,u);break;case 2:generateMessageNode(e,u);break;case 6:generateLinkedNode(e,u);break;case 8:e.push(JSON.stringify(u.value),u);break;case 7:e.push(JSON.stringify(u.value),u);break;case 5:e.push(`${l("interpolate")}(${l("list")}(${u.index}))`,u);break;case 4:e.push(`${l("interpolate")}(${l("named")}(${JSON.stringify(u.key)}))`,u);break;case 9:e.push(JSON.stringify(u.value),u);break;case 3:e.push(JSON.stringify(u.value),u);break;default:if(process.env.NODE_ENV!=="production")throw createCompileError(CompileErrorCodes.UNHANDLED_CODEGEN_NODE_TYPE,null,{domain:ERROR_DOMAIN,args:[u.type]})}}const generate=(e,u={})=>{const l=isString(u.mode)?u.mode:"normal",d=isString(u.filename)?u.filename:"message.intl";u.sourceMap;const E=u.breakLineCode!=null?u.breakLineCode:l==="arrow"?";":`
1001
+ `,b=u.needIndent?u.needIndent:l!=="arrow",C=e.helpers||[],A=createCodeGenerator(e,{filename:d,breakLineCode:E,needIndent:b});A.push(l==="normal"?"function __msg__ (ctx) {":"(ctx) => {"),A.indent(b),C.length>0&&(A.push(`const { ${join(C.map(n=>`${n}: _${n}`),", ")} } = ctx`),A.newline()),A.push("return "),generateNode(A,e),A.deindent(b),A.push("}"),delete e.helpers;const{code:a,map:g}=A.context();return{ast:e,code:a,map:g?g.toJSON():void 0}};function baseCompile$1(e,u={}){const l=assign({},u),d=!!l.jit,E=!!l.minify,b=l.optimize==null?!0:l.optimize,A=createParser(l).parse(e);return d?(b&&optimize(A),E&&minify(A),{ast:A,code:""}):(transform(A,l),generate(A,l))}/*!
1002
+ * core-base v11.1.2
1003
+ * (c) 2025 kazuya kawaguchi
1004
+ * Released under the MIT License.
1005
+ */function initFeatureFlags$1(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function format(e){return l=>formatParts(l,e)}function formatParts(e,u){const l=resolveBody(u);if(l==null)throw createUnhandleNodeError(0);if(resolveType(l)===1){const b=resolveCases(l);return e.plural(b.reduce((C,A)=>[...C,formatMessageParts(e,A)],[]))}else return formatMessageParts(e,l)}const PROPS_BODY=["b","body"];function resolveBody(e){return resolveProps(e,PROPS_BODY)}const PROPS_CASES=["c","cases"];function resolveCases(e){return resolveProps(e,PROPS_CASES,[])}function formatMessageParts(e,u){const l=resolveStatic(u);if(l!=null)return e.type==="text"?l:e.normalize([l]);{const d=resolveItems(u).reduce((E,b)=>[...E,formatMessagePart(e,b)],[]);return e.normalize(d)}}const PROPS_STATIC=["s","static"];function resolveStatic(e){return resolveProps(e,PROPS_STATIC)}const PROPS_ITEMS=["i","items"];function resolveItems(e){return resolveProps(e,PROPS_ITEMS,[])}function formatMessagePart(e,u){const l=resolveType(u);switch(l){case 3:return resolveValue$1(u,l);case 9:return resolveValue$1(u,l);case 4:{const d=u;if(hasOwn(d,"k")&&d.k)return e.interpolate(e.named(d.k));if(hasOwn(d,"key")&&d.key)return e.interpolate(e.named(d.key));throw createUnhandleNodeError(l)}case 5:{const d=u;if(hasOwn(d,"i")&&isNumber(d.i))return e.interpolate(e.list(d.i));if(hasOwn(d,"index")&&isNumber(d.index))return e.interpolate(e.list(d.index));throw createUnhandleNodeError(l)}case 6:{const d=u,E=resolveLinkedModifier(d),b=resolveLinkedKey(d);return e.linked(formatMessagePart(e,b),E?formatMessagePart(e,E):void 0,e.type)}case 7:return resolveValue$1(u,l);case 8:return resolveValue$1(u,l);default:throw new Error(`unhandled node on format message part: ${l}`)}}const PROPS_TYPE=["t","type"];function resolveType(e){return resolveProps(e,PROPS_TYPE)}const PROPS_VALUE=["v","value"];function resolveValue$1(e,u){const l=resolveProps(e,PROPS_VALUE);if(l)return l;throw createUnhandleNodeError(u)}const PROPS_MODIFIER=["m","modifier"];function resolveLinkedModifier(e){return resolveProps(e,PROPS_MODIFIER)}const PROPS_KEY=["k","key"];function resolveLinkedKey(e){const u=resolveProps(e,PROPS_KEY);if(u)return u;throw createUnhandleNodeError(6)}function resolveProps(e,u,l){for(let d=0;d<u.length;d++){const E=u[d];if(hasOwn(e,E)&&e[E]!=null)return e[E]}return l}function createUnhandleNodeError(e){return new Error(`unhandled node type: ${e}`)}const WARN_MESSAGE="Detected HTML in '{source}' message. Recommend not using HTML messages to avoid XSS.";function checkHtmlMessage(e,u){u&&detectHtmlTag(e)&&warn(format$1(WARN_MESSAGE,{source:e}))}const defaultOnCacheKey=e=>e;let compileCache=create();function isMessageAST(e){return isObject(e)&&resolveType(e)===0&&(hasOwn(e,"b")||hasOwn(e,"body"))}function baseCompile(e,u={}){let l=!1;const d=u.onError||defaultOnError;return u.onError=E=>{l=!0,d(E)},{...baseCompile$1(e,u),detectError:l}}function compile(e,u){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&isString(e)){const l=isBoolean(u.warnHtmlMessage)?u.warnHtmlMessage:!0;process.env.NODE_ENV!=="production"&&checkHtmlMessage(e,l);const E=(u.onCacheKey||defaultOnCacheKey)(e),b=compileCache[E];if(b)return b;const{ast:C,detectError:A}=baseCompile(e,{...u,location:process.env.NODE_ENV!=="production",jit:!0}),a=format(C);return A?a:compileCache[E]=a}else{if(process.env.NODE_ENV!=="production"&&!isMessageAST(e))return warn(`the message that is resolve with key '${u.key}' is not supported for jit compilation`),()=>e;const l=e.cacheKey;if(l){const d=compileCache[l];return d||(compileCache[l]=format(e))}else return format(e)}}let devtools=null;function setDevToolsHook(e){devtools=e}function initI18nDevTools(e,u,l){devtools&&devtools.emit("i18n:init",{timestamp:Date.now(),i18n:e,version:u,meta:l})}const translateDevTools=createDevToolsHook("function:translate");function createDevToolsHook(e){return u=>devtools&&devtools.emit(e,u)}const CoreErrorCodes={INVALID_ARGUMENT:COMPILE_ERROR_CODES_EXTEND_POINT,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},CORE_ERROR_CODES_EXTEND_POINT=24;function createCoreError(e){return createCompileError(e,null,process.env.NODE_ENV!=="production"?{messages:errorMessages$1}:void 0)}const errorMessages$1={[CoreErrorCodes.INVALID_ARGUMENT]:"Invalid arguments",[CoreErrorCodes.INVALID_DATE_ARGUMENT]:"The date provided is an invalid Date object.Make sure your Date represents a valid date.",[CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT]:"The argument provided is not a valid ISO date string",[CoreErrorCodes.NOT_SUPPORT_NON_STRING_MESSAGE]:"Not support non-string message",[CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE]:"cannot support promise value",[CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION]:"cannot support async function",[CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE]:"cannot support locale type"};function getLocale(e,u){return u.locale!=null?resolveLocale(u.locale):resolveLocale(e.locale)}let _resolveLocale;function resolveLocale(e){if(isString(e))return e;if(isFunction(e)){if(e.resolvedOnce&&_resolveLocale!=null)return _resolveLocale;if(e.constructor.name==="Function"){const u=e();if(isPromise(u))throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return _resolveLocale=u}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw createCoreError(CoreErrorCodes.NOT_SUPPORT_LOCALE_TYPE)}function fallbackWithSimple(e,u,l){return[...new Set([l,...isArray(u)?u:isObject(u)?Object.keys(u):isString(u)?[u]:[l]])]}function fallbackWithLocaleChain(e,u,l){const d=isString(l)?l:DEFAULT_LOCALE,E=e;E.__localeChainCache||(E.__localeChainCache=new Map);let b=E.__localeChainCache.get(d);if(!b){b=[];let C=[l];for(;isArray(C);)C=appendBlockToChain(b,C,u);const A=isArray(u)||!isPlainObject(u)?u:u.default?u.default:null;C=isString(A)?[A]:A,isArray(C)&&appendBlockToChain(b,C,!1),E.__localeChainCache.set(d,b)}return b}function appendBlockToChain(e,u,l){let d=!0;for(let E=0;E<u.length&&isBoolean(d);E++){const b=u[E];isString(b)&&(d=appendLocaleToChain(e,u[E],l))}return d}function appendLocaleToChain(e,u,l){let d;const E=u.split("-");do{const b=E.join("-");d=appendItemToChain(e,b,l),E.splice(-1,1)}while(E.length&&d===!0);return d}function appendItemToChain(e,u,l){let d=!1;if(!e.includes(u)&&(d=!0,u)){d=u[u.length-1]!=="!";const E=u.replace(/!/g,"");e.push(E),(isArray(l)||isPlainObject(l))&&l[E]&&(d=l[E])}return d}const pathStateMachine=[];pathStateMachine[0]={w:[0],i:[3,0],"[":[4],o:[7]},pathStateMachine[1]={w:[1],".":[2],"[":[4],o:[7]},pathStateMachine[2]={w:[2],i:[3,0],0:[3,0]},pathStateMachine[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]},pathStateMachine[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]},pathStateMachine[5]={"'":[4,0],o:8,l:[5,0]},pathStateMachine[6]={'"':[4,0],o:8,l:[6,0]};const literalValueRE=/^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;function isLiteral(e){return literalValueRE.test(e)}function stripQuotes(e){const u=e.charCodeAt(0),l=e.charCodeAt(e.length-1);return u===l&&(u===34||u===39)?e.slice(1,-1):e}function getPathCharType(e){if(e==null)return"o";switch(e.charCodeAt(0)){case 91:case 93:case 46:case 34:case 39:return e;case 95:case 36:case 45:return"i";case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"w"}return"i"}function formatSubPath(e){const u=e.trim();return e.charAt(0)==="0"&&isNaN(parseInt(e))?!1:isLiteral(u)?stripQuotes(u):"*"+u}function parse(e){const u=[];let l=-1,d=0,E=0,b,C,A,a,g,n,s;const o=[];o[0]=()=>{C===void 0?C=A:C+=A},o[1]=()=>{C!==void 0&&(u.push(C),C=void 0)},o[2]=()=>{o[0](),E++},o[3]=()=>{if(E>0)E--,d=4,o[0]();else{if(E=0,C===void 0||(C=formatSubPath(C),C===!1))return!1;o[1]()}};function r(){const t=e[l+1];if(d===5&&t==="'"||d===6&&t==='"')return l++,A="\\"+t,o[0](),!0}for(;d!==null;)if(l++,b=e[l],!(b==="\\"&&r())){if(a=getPathCharType(b),s=pathStateMachine[d],g=s[a]||s.l||8,g===8||(d=g[0],g[1]!==void 0&&(n=o[g[1]],n&&(A=b,n()===!1))))return;if(d===7)return u}}const cache=new Map;function resolveWithKeyValue(e,u){return isObject(e)?e[u]:null}function resolveValue(e,u){if(!isObject(e))return null;let l=cache.get(u);if(l||(l=parse(u),l&&cache.set(u,l)),!l)return null;const d=l.length;let E=e,b=0;for(;b<d;){const C=E[l[b]];if(C===void 0||isFunction(E))return null;E=C,b++}return E}const CoreWarnCodes={NOT_FOUND_KEY:1,FALLBACK_TO_TRANSLATE:2,CANNOT_FORMAT_NUMBER:3,FALLBACK_TO_NUMBER_FORMAT:4,CANNOT_FORMAT_DATE:5,FALLBACK_TO_DATE_FORMAT:6,EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:7},CORE_WARN_CODES_EXTEND_POINT=8,warnMessages$1={[CoreWarnCodes.NOT_FOUND_KEY]:"Not found '{key}' key in '{locale}' locale messages.",[CoreWarnCodes.FALLBACK_TO_TRANSLATE]:"Fall back to translate '{key}' key with '{target}' locale.",[CoreWarnCodes.CANNOT_FORMAT_NUMBER]:"Cannot format a number value due to not supported Intl.NumberFormat.",[CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT]:"Fall back to number format '{key}' key with '{target}' locale.",[CoreWarnCodes.CANNOT_FORMAT_DATE]:"Cannot format a date value due to not supported Intl.DateTimeFormat.",[CoreWarnCodes.FALLBACK_TO_DATE_FORMAT]:"Fall back to datetime format '{key}' key with '{target}' locale.",[CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]:"This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future."};function getWarnMessage$1(e,...u){return format$1(warnMessages$1[e],...u)}const VERSION$1="11.1.2",NOT_REOSLVED=-1,DEFAULT_LOCALE="en-US",MISSING_RESOLVE_VALUE="",capitalize=e=>`${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;function getDefaultLinkedModifiers(){return{upper:(e,u)=>u==="text"&&isString(e)?e.toUpperCase():u==="vnode"&&isObject(e)&&"__v_isVNode"in e?e.children.toUpperCase():e,lower:(e,u)=>u==="text"&&isString(e)?e.toLowerCase():u==="vnode"&&isObject(e)&&"__v_isVNode"in e?e.children.toLowerCase():e,capitalize:(e,u)=>u==="text"&&isString(e)?capitalize(e):u==="vnode"&&isObject(e)&&"__v_isVNode"in e?capitalize(e.children):e}}let _compiler;function registerMessageCompiler(e){_compiler=e}let _resolver;function registerMessageResolver(e){_resolver=e}let _fallbacker;function registerLocaleFallbacker(e){_fallbacker=e}let _additionalMeta=null;const setAdditionalMeta=e=>{_additionalMeta=e},getAdditionalMeta=()=>_additionalMeta;let _fallbackContext=null;const setFallbackContext=e=>{_fallbackContext=e},getFallbackContext=()=>_fallbackContext;let _cid=0;function createCoreContext(e={}){const u=isFunction(e.onWarn)?e.onWarn:warn,l=isString(e.version)?e.version:VERSION$1,d=isString(e.locale)||isFunction(e.locale)?e.locale:DEFAULT_LOCALE,E=isFunction(d)?DEFAULT_LOCALE:d,b=isArray(e.fallbackLocale)||isPlainObject(e.fallbackLocale)||isString(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:E,C=isPlainObject(e.messages)?e.messages:createResources(E),A=isPlainObject(e.datetimeFormats)?e.datetimeFormats:createResources(E),a=isPlainObject(e.numberFormats)?e.numberFormats:createResources(E),g=assign(create(),e.modifiers,getDefaultLinkedModifiers()),n=e.pluralRules||create(),s=isFunction(e.missing)?e.missing:null,o=isBoolean(e.missingWarn)||isRegExp(e.missingWarn)?e.missingWarn:!0,r=isBoolean(e.fallbackWarn)||isRegExp(e.fallbackWarn)?e.fallbackWarn:!0,t=!!e.fallbackFormat,i=!!e.unresolving,c=isFunction(e.postTranslation)?e.postTranslation:null,h=isPlainObject(e.processor)?e.processor:null,f=isBoolean(e.warnHtmlMessage)?e.warnHtmlMessage:!0,v=!!e.escapeParameter,p=isFunction(e.messageCompiler)?e.messageCompiler:_compiler;process.env.NODE_ENV!=="production"&&isFunction(e.messageCompiler)&&warnOnce(getWarnMessage$1(CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER));const y=isFunction(e.messageResolver)?e.messageResolver:_resolver||resolveWithKeyValue,m=isFunction(e.localeFallbacker)?e.localeFallbacker:_fallbacker||fallbackWithSimple,$=isObject(e.fallbackContext)?e.fallbackContext:void 0,N=e,M=isObject(N.__datetimeFormatters)?N.__datetimeFormatters:new Map,S=isObject(N.__numberFormatters)?N.__numberFormatters:new Map,O=isObject(N.__meta)?N.__meta:{};_cid++;const x={version:l,cid:_cid,locale:d,fallbackLocale:b,messages:C,modifiers:g,pluralRules:n,missing:s,missingWarn:o,fallbackWarn:r,fallbackFormat:t,unresolving:i,postTranslation:c,processor:h,warnHtmlMessage:f,escapeParameter:v,messageCompiler:p,messageResolver:y,localeFallbacker:m,fallbackContext:$,onWarn:u,__meta:O};return x.datetimeFormats=A,x.numberFormats=a,x.__datetimeFormatters=M,x.__numberFormatters=S,process.env.NODE_ENV!=="production"&&(x.__v_emitter=N.__v_emitter!=null?N.__v_emitter:void 0),(process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__)&&initI18nDevTools(x,l,O),x}const createResources=e=>({[e]:create()});function isTranslateFallbackWarn(e,u){return e instanceof RegExp?e.test(u):e}function isTranslateMissingWarn(e,u){return e instanceof RegExp?e.test(u):e}function handleMissing(e,u,l,d,E){const{missing:b,onWarn:C}=e;if(process.env.NODE_ENV!=="production"){const A=e.__v_emitter;A&&A.emit("missing",{locale:l,key:u,type:E,groupId:`${E}:${u}`})}if(b!==null){const A=b(e,l,u,E);return isString(A)?A:u}else return process.env.NODE_ENV!=="production"&&isTranslateMissingWarn(d,u)&&C(getWarnMessage$1(CoreWarnCodes.NOT_FOUND_KEY,{key:u,locale:l})),u}function updateFallbackLocale(e,u,l){const d=e;d.__localeChainCache=new Map,e.localeFallbacker(e,l,u)}function isAlmostSameLocale(e,u){return e===u?!1:e.split("-")[0]===u.split("-")[0]}function isImplicitFallback(e,u){const l=u.indexOf(e);if(l===-1)return!1;for(let d=l+1;d<u.length;d++)if(isAlmostSameLocale(e,u[d]))return!0;return!1}const intlDefined=typeof Intl<"u",Availabilities={dateTimeFormat:intlDefined&&typeof Intl.DateTimeFormat<"u",numberFormat:intlDefined&&typeof Intl.NumberFormat<"u"};function datetime(e,...u){const{datetimeFormats:l,unresolving:d,fallbackLocale:E,onWarn:b,localeFallbacker:C}=e,{__datetimeFormatters:A}=e;if(process.env.NODE_ENV!=="production"&&!Availabilities.dateTimeFormat)return b(getWarnMessage$1(CoreWarnCodes.CANNOT_FORMAT_DATE)),MISSING_RESOLVE_VALUE;const[a,g,n,s]=parseDateTimeArgs(...u),o=isBoolean(n.missingWarn)?n.missingWarn:e.missingWarn,r=isBoolean(n.fallbackWarn)?n.fallbackWarn:e.fallbackWarn,t=!!n.part,i=getLocale(e,n),c=C(e,E,i);if(!isString(a)||a==="")return new Intl.DateTimeFormat(i,s).format(g);let h={},f,v=null,p=i,y=null;const m="datetime format";for(let M=0;M<c.length;M++){if(f=y=c[M],process.env.NODE_ENV!=="production"&&i!==f&&isTranslateFallbackWarn(r,a)&&b(getWarnMessage$1(CoreWarnCodes.FALLBACK_TO_DATE_FORMAT,{key:a,target:f})),process.env.NODE_ENV!=="production"&&i!==f){const S=e.__v_emitter;S&&S.emit("fallback",{type:m,key:a,from:p,to:y,groupId:`${m}:${a}`})}if(h=l[f]||{},v=h[a],isPlainObject(v))break;handleMissing(e,a,f,o,m),p=y}if(!isPlainObject(v)||!isString(f))return d?NOT_REOSLVED:a;let $=`${f}__${a}`;isEmptyObject(s)||($=`${$}__${JSON.stringify(s)}`);let N=A.get($);return N||(N=new Intl.DateTimeFormat(f,assign({},v,s)),A.set($,N)),t?N.formatToParts(g):N.format(g)}const DATETIME_FORMAT_OPTIONS_KEYS=["localeMatcher","weekday","era","year","month","day","hour","minute","second","timeZoneName","formatMatcher","hour12","timeZone","dateStyle","timeStyle","calendar","dayPeriod","numberingSystem","hourCycle","fractionalSecondDigits"];function parseDateTimeArgs(...e){const[u,l,d,E]=e,b=create();let C=create(),A;if(isString(u)){const a=u.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);if(!a)throw createCoreError(CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT);const g=a[3]?a[3].trim().startsWith("T")?`${a[1].trim()}${a[3].trim()}`:`${a[1].trim()}T${a[3].trim()}`:a[1].trim();A=new Date(g);try{A.toISOString()}catch{throw createCoreError(CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT)}}else if(isDate(u)){if(isNaN(u.getTime()))throw createCoreError(CoreErrorCodes.INVALID_DATE_ARGUMENT);A=u}else if(isNumber(u))A=u;else throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);return isString(l)?b.key=l:isPlainObject(l)&&Object.keys(l).forEach(a=>{DATETIME_FORMAT_OPTIONS_KEYS.includes(a)?C[a]=l[a]:b[a]=l[a]}),isString(d)?b.locale=d:isPlainObject(d)&&(C=d),isPlainObject(E)&&(C=E),[b.key||"",A,b,C]}function clearDateTimeFormat(e,u,l){const d=e;for(const E in l){const b=`${u}__${E}`;d.__datetimeFormatters.has(b)&&d.__datetimeFormatters.delete(b)}}function number(e,...u){const{numberFormats:l,unresolving:d,fallbackLocale:E,onWarn:b,localeFallbacker:C}=e,{__numberFormatters:A}=e;if(process.env.NODE_ENV!=="production"&&!Availabilities.numberFormat)return b(getWarnMessage$1(CoreWarnCodes.CANNOT_FORMAT_NUMBER)),MISSING_RESOLVE_VALUE;const[a,g,n,s]=parseNumberArgs(...u),o=isBoolean(n.missingWarn)?n.missingWarn:e.missingWarn,r=isBoolean(n.fallbackWarn)?n.fallbackWarn:e.fallbackWarn,t=!!n.part,i=getLocale(e,n),c=C(e,E,i);if(!isString(a)||a==="")return new Intl.NumberFormat(i,s).format(g);let h={},f,v=null,p=i,y=null;const m="number format";for(let M=0;M<c.length;M++){if(f=y=c[M],process.env.NODE_ENV!=="production"&&i!==f&&isTranslateFallbackWarn(r,a)&&b(getWarnMessage$1(CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT,{key:a,target:f})),process.env.NODE_ENV!=="production"&&i!==f){const S=e.__v_emitter;S&&S.emit("fallback",{type:m,key:a,from:p,to:y,groupId:`${m}:${a}`})}if(h=l[f]||{},v=h[a],isPlainObject(v))break;handleMissing(e,a,f,o,m),p=y}if(!isPlainObject(v)||!isString(f))return d?NOT_REOSLVED:a;let $=`${f}__${a}`;isEmptyObject(s)||($=`${$}__${JSON.stringify(s)}`);let N=A.get($);return N||(N=new Intl.NumberFormat(f,assign({},v,s)),A.set($,N)),t?N.formatToParts(g):N.format(g)}const NUMBER_FORMAT_OPTIONS_KEYS=["localeMatcher","style","currency","currencyDisplay","currencySign","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","notation","signDisplay","unit","unitDisplay","roundingMode","roundingPriority","roundingIncrement","trailingZeroDisplay"];function parseNumberArgs(...e){const[u,l,d,E]=e,b=create();let C=create();if(!isNumber(u))throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);const A=u;return isString(l)?b.key=l:isPlainObject(l)&&Object.keys(l).forEach(a=>{NUMBER_FORMAT_OPTIONS_KEYS.includes(a)?C[a]=l[a]:b[a]=l[a]}),isString(d)?b.locale=d:isPlainObject(d)&&(C=d),isPlainObject(E)&&(C=E),[b.key||"",A,b,C]}function clearNumberFormat(e,u,l){const d=e;for(const E in l){const b=`${u}__${E}`;d.__numberFormatters.has(b)&&d.__numberFormatters.delete(b)}}const DEFAULT_MODIFIER=e=>e,DEFAULT_MESSAGE=e=>"",DEFAULT_MESSAGE_DATA_TYPE="text",DEFAULT_NORMALIZE=e=>e.length===0?"":join(e),DEFAULT_INTERPOLATE=toDisplayString;function pluralDefault(e,u){return e=Math.abs(e),u===2?e?e>1?1:0:1:e?Math.min(e,2):0}function getPluralIndex(e){const u=isNumber(e.pluralIndex)?e.pluralIndex:-1;return e.named&&(isNumber(e.named.count)||isNumber(e.named.n))?isNumber(e.named.count)?e.named.count:isNumber(e.named.n)?e.named.n:u:u}function normalizeNamed(e,u){u.count||(u.count=e),u.n||(u.n=e)}function createMessageContext(e={}){const u=e.locale,l=getPluralIndex(e),d=isObject(e.pluralRules)&&isString(u)&&isFunction(e.pluralRules[u])?e.pluralRules[u]:pluralDefault,E=isObject(e.pluralRules)&&isString(u)&&isFunction(e.pluralRules[u])?pluralDefault:void 0,b=h=>h[d(l,h.length,E)],C=e.list||[],A=h=>C[h],a=e.named||create();isNumber(e.pluralIndex)&&normalizeNamed(l,a);const g=h=>a[h];function n(h,f){const v=isFunction(e.messages)?e.messages(h,!!f):isObject(e.messages)?e.messages[h]:!1;return v||(e.parent?e.parent.message(h):DEFAULT_MESSAGE)}const s=h=>e.modifiers?e.modifiers[h]:DEFAULT_MODIFIER,o=isPlainObject(e.processor)&&isFunction(e.processor.normalize)?e.processor.normalize:DEFAULT_NORMALIZE,r=isPlainObject(e.processor)&&isFunction(e.processor.interpolate)?e.processor.interpolate:DEFAULT_INTERPOLATE,t=isPlainObject(e.processor)&&isString(e.processor.type)?e.processor.type:DEFAULT_MESSAGE_DATA_TYPE,c={list:A,named:g,plural:b,linked:(h,...f)=>{const[v,p]=f;let y="text",m="";f.length===1?isObject(v)?(m=v.modifier||m,y=v.type||y):isString(v)&&(m=v||m):f.length===2&&(isString(v)&&(m=v||m),isString(p)&&(y=p||y));const $=n(h,!0)(c),N=y==="vnode"&&isArray($)&&m?$[0]:$;return m?s(m)(N,y):N},message:n,type:t,interpolate:r,normalize:o,values:assign(create(),C,a)};return c}const NOOP_MESSAGE_FUNCTION=()=>"",isMessageFunction=e=>isFunction(e);function translate(e,...u){const{fallbackFormat:l,postTranslation:d,unresolving:E,messageCompiler:b,fallbackLocale:C,messages:A}=e,[a,g]=parseTranslateArgs(...u),n=isBoolean(g.missingWarn)?g.missingWarn:e.missingWarn,s=isBoolean(g.fallbackWarn)?g.fallbackWarn:e.fallbackWarn,o=isBoolean(g.escapeParameter)?g.escapeParameter:e.escapeParameter,r=!!g.resolvedMessage,t=isString(g.default)||isBoolean(g.default)?isBoolean(g.default)?b?a:()=>a:g.default:l?b?a:()=>a:null,i=l||t!=null&&(isString(t)||isFunction(t)),c=getLocale(e,g);o&&escapeParams(g);let[h,f,v]=r?[a,c,A[c]||create()]:resolveMessageFormat(e,a,c,C,s,n),p=h,y=a;if(!r&&!(isString(p)||isMessageAST(p)||isMessageFunction(p))&&i&&(p=t,y=p),!r&&(!(isString(p)||isMessageAST(p)||isMessageFunction(p))||!isString(f)))return E?NOT_REOSLVED:a;if(process.env.NODE_ENV!=="production"&&isString(p)&&e.messageCompiler==null)return warn(`The message format compilation is not supported in this build. Because message compiler isn't included. You need to pre-compilation all message format. So translate function return '${a}'.`),a;let m=!1;const $=()=>{m=!0},N=isMessageFunction(p)?p:compileMessageFormat(e,a,f,p,y,$);if(m)return p;const M=getMessageContextOptions(e,f,v,g),S=createMessageContext(M),O=evaluateMessage(e,N,S),x=d?d(O,a):O;if(process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__){const L={timestamp:Date.now(),key:isString(a)?a:isMessageFunction(p)?p.key:"",locale:f||(isMessageFunction(p)?p.locale:""),format:isString(p)?p:isMessageFunction(p)?p.source:"",message:x};L.meta=assign({},e.__meta,getAdditionalMeta()||{}),translateDevTools(L)}return x}function escapeParams(e){isArray(e.list)?e.list=e.list.map(u=>isString(u)?escapeHtml(u):u):isObject(e.named)&&Object.keys(e.named).forEach(u=>{isString(e.named[u])&&(e.named[u]=escapeHtml(e.named[u]))})}function resolveMessageFormat(e,u,l,d,E,b){const{messages:C,onWarn:A,messageResolver:a,localeFallbacker:g}=e,n=g(e,d,l);let s=create(),o,r=null,t=l,i=null;const c="translate";for(let h=0;h<n.length;h++){if(o=i=n[h],process.env.NODE_ENV!=="production"&&l!==o&&!isAlmostSameLocale(l,o)&&isTranslateFallbackWarn(E,u)&&A(getWarnMessage$1(CoreWarnCodes.FALLBACK_TO_TRANSLATE,{key:u,target:o})),process.env.NODE_ENV!=="production"&&l!==o){const y=e.__v_emitter;y&&y.emit("fallback",{type:c,key:u,from:t,to:i,groupId:`${c}:${u}`})}s=C[o]||create();let f=null,v,p;if(process.env.NODE_ENV!=="production"&&inBrowser&&(f=window.performance.now(),v="intlify-message-resolve-start",p="intlify-message-resolve-end",mark&&mark(v)),(r=a(s,u))===null&&(r=s[u]),process.env.NODE_ENV!=="production"&&inBrowser){const y=window.performance.now(),m=e.__v_emitter;m&&f&&r&&m.emit("message-resolve",{type:"message-resolve",key:u,message:r,time:y-f,groupId:`${c}:${u}`}),v&&p&&mark&&measure&&(mark(p),measure("intlify message resolve",v,p))}if(isString(r)||isMessageAST(r)||isMessageFunction(r))break;if(!isImplicitFallback(o,n)){const y=handleMissing(e,u,o,b,c);y!==u&&(r=y)}t=i}return[r,o,s]}function compileMessageFormat(e,u,l,d,E,b){const{messageCompiler:C,warnHtmlMessage:A}=e;if(isMessageFunction(d)){const o=d;return o.locale=o.locale||l,o.key=o.key||u,o}if(C==null){const o=()=>d;return o.locale=l,o.key=u,o}let a=null,g,n;process.env.NODE_ENV!=="production"&&inBrowser&&(a=window.performance.now(),g="intlify-message-compilation-start",n="intlify-message-compilation-end",mark&&mark(g));const s=C(d,getCompileContext(e,l,E,d,A,b));if(process.env.NODE_ENV!=="production"&&inBrowser){const o=window.performance.now(),r=e.__v_emitter;r&&a&&r.emit("message-compilation",{type:"message-compilation",message:d,time:o-a,groupId:`translate:${u}`}),g&&n&&mark&&measure&&(mark(n),measure("intlify message compilation",g,n))}return s.locale=l,s.key=u,s.source=d,s}function evaluateMessage(e,u,l){let d=null,E,b;process.env.NODE_ENV!=="production"&&inBrowser&&(d=window.performance.now(),E="intlify-message-evaluation-start",b="intlify-message-evaluation-end",mark&&mark(E));const C=u(l);if(process.env.NODE_ENV!=="production"&&inBrowser){const A=window.performance.now(),a=e.__v_emitter;a&&d&&a.emit("message-evaluation",{type:"message-evaluation",value:C,time:A-d,groupId:`translate:${u.key}`}),E&&b&&mark&&measure&&(mark(b),measure("intlify message evaluation",E,b))}return C}function parseTranslateArgs(...e){const[u,l,d]=e,E=create();if(!isString(u)&&!isNumber(u)&&!isMessageFunction(u)&&!isMessageAST(u))throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);const b=isNumber(u)?String(u):(isMessageFunction(u),u);return isNumber(l)?E.plural=l:isString(l)?E.default=l:isPlainObject(l)&&!isEmptyObject(l)?E.named=l:isArray(l)&&(E.list=l),isNumber(d)?E.plural=d:isString(d)?E.default=d:isPlainObject(d)&&assign(E,d),[b,E]}function getCompileContext(e,u,l,d,E,b){return{locale:u,key:l,warnHtmlMessage:E,onError:C=>{if(b&&b(C),process.env.NODE_ENV!=="production"){const A=getSourceForCodeFrame(d),a=`Message compilation error: ${C.message}`,g=C.location&&A&&generateCodeFrame(A,C.location.start.offset,C.location.end.offset),n=e.__v_emitter;n&&A&&n.emit("compile-error",{message:A,error:C.message,start:C.location&&C.location.start.offset,end:C.location&&C.location.end.offset,groupId:`translate:${l}`}),console.error(g?`${a}
1006
+ ${g}`:a)}else throw C},onCacheKey:C=>generateFormatCacheKey(u,l,C)}}function getSourceForCodeFrame(e){if(isString(e))return e;if(e.loc&&e.loc.source)return e.loc.source}function getMessageContextOptions(e,u,l,d){const{modifiers:E,pluralRules:b,messageResolver:C,fallbackLocale:A,fallbackWarn:a,missingWarn:g,fallbackContext:n}=e,o={locale:u,modifiers:E,pluralRules:b,messages:(r,t)=>{let i=C(l,r);if(i==null&&(n||t)){const[,,c]=resolveMessageFormat(n||e,r,u,A,a,g);i=C(c,r)}if(isString(i)||isMessageAST(i)){let c=!1;const f=compileMessageFormat(e,r,u,i,r,()=>{c=!0});return c?NOOP_MESSAGE_FUNCTION:f}else return isMessageFunction(i)?i:NOOP_MESSAGE_FUNCTION}};return e.processor&&(o.processor=e.processor),d.list&&(o.list=d.list),d.named&&(o.named=d.named),isNumber(d.plural)&&(o.pluralIndex=d.plural),o}initFeatureFlags$1();/*!
1007
+ * vue-i18n v11.1.2
1008
+ * (c) 2025 kazuya kawaguchi
1009
+ * Released under the MIT License.
1010
+ */const VERSION="11.1.2";function initFeatureFlags(){typeof __VUE_I18N_FULL_INSTALL__!="boolean"&&(getGlobalThis().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!="boolean"&&(getGlobalThis().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(getGlobalThis().__INTLIFY_PROD_DEVTOOLS__=!1)}const I18nErrorCodes={UNEXPECTED_RETURN_TYPE:CORE_ERROR_CODES_EXTEND_POINT,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function createI18nError(e,...u){return createCompileError(e,null,process.env.NODE_ENV!=="production"?{messages:errorMessages,args:u}:void 0)}const errorMessages={[I18nErrorCodes.UNEXPECTED_RETURN_TYPE]:"Unexpected return type in composer",[I18nErrorCodes.INVALID_ARGUMENT]:"Invalid argument",[I18nErrorCodes.MUST_BE_CALL_SETUP_TOP]:"Must be called at the top of a `setup` function",[I18nErrorCodes.NOT_INSTALLED]:"Need to install with `app.use` function",[I18nErrorCodes.UNEXPECTED_ERROR]:"Unexpected error",[I18nErrorCodes.REQUIRED_VALUE]:"Required in value: {0}",[I18nErrorCodes.INVALID_VALUE]:"Invalid value",[I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN]:"Cannot setup vue-devtools plugin",[I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE]:"Need to install with `provide` function",[I18nErrorCodes.NOT_COMPATIBLE_LEGACY_VUE_I18N]:"Not compatible legacy VueI18n.",[I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY]:"Not available Compostion API in Legacy API mode. Please make sure that the legacy API mode is working properly"},TranslateVNodeSymbol=makeSymbol("__translateVNode"),DatetimePartsSymbol=makeSymbol("__datetimeParts"),NumberPartsSymbol=makeSymbol("__numberParts"),EnableEmitter=makeSymbol("__enableEmitter"),DisableEmitter=makeSymbol("__disableEmitter"),SetPluralRulesSymbol=makeSymbol("__setPluralRules"),InejctWithOptionSymbol=makeSymbol("__injectWithOption"),DisposeSymbol=makeSymbol("__dispose"),I18nWarnCodes={FALLBACK_TO_ROOT:CORE_WARN_CODES_EXTEND_POINT,NOT_FOUND_PARENT_SCOPE:9,IGNORE_OBJ_FLATTEN:10,DEPRECATE_LEGACY_MODE:11,DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE:12},warnMessages={[I18nWarnCodes.FALLBACK_TO_ROOT]:"Fall back to {type} '{key}' with root locale.",[I18nWarnCodes.NOT_FOUND_PARENT_SCOPE]:"Not found parent scope. use the global scope.",[I18nWarnCodes.IGNORE_OBJ_FLATTEN]:"Ignore object flatten: '{key}' key has an string value",[I18nWarnCodes.DEPRECATE_LEGACY_MODE]:`Legacy API mode has been deprecated in v11. Use Composition API mode instead.
1011
+ About how to use the Composition API mode, see https://vue-i18n.intlify.dev/guide/advanced/composition.html`,[I18nWarnCodes.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE]:"'v-t' has been deprecated in v11. Use translate APIs ('t' or '$t') instead."};function getWarnMessage(e,...u){return format$1(warnMessages[e],...u)}function handleFlatJson(e){if(!isObject(e))return e;for(const u in e)if(hasOwn(e,u))if(!u.includes("."))isObject(e[u])&&handleFlatJson(e[u]);else{const l=u.split("."),d=l.length-1;let E=e,b=!1;for(let C=0;C<d;C++){if(l[C]==="__proto__")throw new Error(`unsafe key: ${l[C]}`);if(l[C]in E||(E[l[C]]=create()),!isObject(E[l[C]])){process.env.NODE_ENV!=="production"&&warn(getWarnMessage(I18nWarnCodes.IGNORE_OBJ_FLATTEN,{key:l[C]})),b=!0;break}E=E[l[C]]}b||(E[l[d]]=e[u],delete e[u]),isObject(E[l[d]])&&handleFlatJson(E[l[d]])}return e}function getLocaleMessages(e,u){const{messages:l,__i18n:d,messageResolver:E,flatJson:b}=u,C=isPlainObject(l)?l:isArray(d)?create():{[e]:create()};if(isArray(d)&&d.forEach(A=>{if("locale"in A&&"resource"in A){const{locale:a,resource:g}=A;a?(C[a]=C[a]||create(),deepCopy(g,C[a])):deepCopy(g,C)}else isString(A)&&deepCopy(JSON.parse(A),C)}),E==null&&b)for(const A in C)hasOwn(C,A)&&handleFlatJson(C[A]);return C}function getComponentOptions(e){return e.type}function adjustI18nResources(e,u,l){let d=isObject(u.messages)?u.messages:create();"__i18nGlobal"in l&&(d=getLocaleMessages(e.locale.value,{messages:d,__i18n:l.__i18nGlobal}));const E=Object.keys(d);E.length&&E.forEach(b=>{e.mergeLocaleMessage(b,d[b])});{if(isObject(u.datetimeFormats)){const b=Object.keys(u.datetimeFormats);b.length&&b.forEach(C=>{e.mergeDateTimeFormat(C,u.datetimeFormats[C])})}if(isObject(u.numberFormats)){const b=Object.keys(u.numberFormats);b.length&&b.forEach(C=>{e.mergeNumberFormat(C,u.numberFormats[C])})}}}function createTextNode(e){return vue.createVNode(vue.Text,null,e,0)}const DEVTOOLS_META="__INTLIFY_META__",NOOP_RETURN_ARRAY=()=>[],NOOP_RETURN_FALSE=()=>!1;let composerID=0;function defineCoreMissingHandler(e){return(u,l,d,E)=>e(l,d,vue.getCurrentInstance()||void 0,E)}const getMetaInfo=()=>{const e=vue.getCurrentInstance();let u=null;return e&&(u=getComponentOptions(e)[DEVTOOLS_META])?{[DEVTOOLS_META]:u}:null};function createComposer(e={}){const{__root:u,__injectWithOption:l}=e,d=u===void 0,E=e.flatJson,b=inBrowser?vue.ref:vue.shallowRef;let C=isBoolean(e.inheritLocale)?e.inheritLocale:!0;const A=b(u&&C?u.locale.value:isString(e.locale)?e.locale:DEFAULT_LOCALE),a=b(u&&C?u.fallbackLocale.value:isString(e.fallbackLocale)||isArray(e.fallbackLocale)||isPlainObject(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:A.value),g=b(getLocaleMessages(A.value,e)),n=b(isPlainObject(e.datetimeFormats)?e.datetimeFormats:{[A.value]:{}}),s=b(isPlainObject(e.numberFormats)?e.numberFormats:{[A.value]:{}});let o=u?u.missingWarn:isBoolean(e.missingWarn)||isRegExp(e.missingWarn)?e.missingWarn:!0,r=u?u.fallbackWarn:isBoolean(e.fallbackWarn)||isRegExp(e.fallbackWarn)?e.fallbackWarn:!0,t=u?u.fallbackRoot:isBoolean(e.fallbackRoot)?e.fallbackRoot:!0,i=!!e.fallbackFormat,c=isFunction(e.missing)?e.missing:null,h=isFunction(e.missing)?defineCoreMissingHandler(e.missing):null,f=isFunction(e.postTranslation)?e.postTranslation:null,v=u?u.warnHtmlMessage:isBoolean(e.warnHtmlMessage)?e.warnHtmlMessage:!0,p=!!e.escapeParameter;const y=u?u.modifiers:isPlainObject(e.modifiers)?e.modifiers:{};let m=e.pluralRules||u&&u.pluralRules,$;$=(()=>{d&&setFallbackContext(null);const Z={version:VERSION,locale:A.value,fallbackLocale:a.value,messages:g.value,modifiers:y,pluralRules:m,missing:h===null?void 0:h,missingWarn:o,fallbackWarn:r,fallbackFormat:i,unresolving:!0,postTranslation:f===null?void 0:f,warnHtmlMessage:v,escapeParameter:p,messageResolver:e.messageResolver,messageCompiler:e.messageCompiler,__meta:{framework:"vue"}};Z.datetimeFormats=n.value,Z.numberFormats=s.value,Z.__datetimeFormatters=isPlainObject($)?$.__datetimeFormatters:void 0,Z.__numberFormatters=isPlainObject($)?$.__numberFormatters:void 0,process.env.NODE_ENV!=="production"&&(Z.__v_emitter=isPlainObject($)?$.__v_emitter:void 0);const P=createCoreContext(Z);return d&&setFallbackContext(P),P})(),updateFallbackLocale($,A.value,a.value);function M(){return[A.value,a.value,g.value,n.value,s.value]}const S=vue.computed({get:()=>A.value,set:Z=>{$.locale=Z,A.value=Z}}),O=vue.computed({get:()=>a.value,set:Z=>{$.fallbackLocale=Z,a.value=Z,updateFallbackLocale($,A.value,Z)}}),x=vue.computed(()=>g.value),L=vue.computed(()=>n.value),I=vue.computed(()=>s.value);function w(){return isFunction(f)?f:null}function _(Z){f=Z,$.postTranslation=Z}function T(){return c}function k(Z){Z!==null&&(h=defineCoreMissingHandler(Z)),c=Z,$.missing=h}function R(Z,P){return Z!=="translate"||!P.resolvedMessage}const D=(Z,P,q,ee,ie,le)=>{M();let ue;try{process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__,d||($.fallbackContext=u?getFallbackContext():void 0),ue=Z($)}finally{process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__,d||($.fallbackContext=void 0)}if(q!=="translate exists"&&isNumber(ue)&&ue===NOT_REOSLVED||q==="translate exists"&&!ue){const[de,pe]=P();if(process.env.NODE_ENV!=="production"&&u&&isString(de)&&R(q,pe)&&(t&&(isTranslateFallbackWarn(r,de)||isTranslateMissingWarn(o,de))&&warn(getWarnMessage(I18nWarnCodes.FALLBACK_TO_ROOT,{key:de,type:q})),process.env.NODE_ENV!=="production")){const{__v_emitter:he}=$;he&&t&&he.emit("fallback",{type:q,key:de,to:"global",groupId:`${q}:${de}`})}return u&&t?ee(u):ie(de)}else{if(le(ue))return ue;throw createI18nError(I18nErrorCodes.UNEXPECTED_RETURN_TYPE)}};function V(...Z){return D(P=>Reflect.apply(translate,null,[P,...Z]),()=>parseTranslateArgs(...Z),"translate",P=>Reflect.apply(P.t,P,[...Z]),P=>P,P=>isString(P))}function B(...Z){const[P,q,ee]=Z;if(ee&&!isObject(ee))throw createI18nError(I18nErrorCodes.INVALID_ARGUMENT);return V(P,q,assign({resolvedMessage:!0},ee||{}))}function F(...Z){return D(P=>Reflect.apply(datetime,null,[P,...Z]),()=>parseDateTimeArgs(...Z),"datetime format",P=>Reflect.apply(P.d,P,[...Z]),()=>MISSING_RESOLVE_VALUE,P=>isString(P))}function H(...Z){return D(P=>Reflect.apply(number,null,[P,...Z]),()=>parseNumberArgs(...Z),"number format",P=>Reflect.apply(P.n,P,[...Z]),()=>MISSING_RESOLVE_VALUE,P=>isString(P))}function U(Z){return Z.map(P=>isString(P)||isNumber(P)||isBoolean(P)?createTextNode(String(P)):P)}const K={normalize:U,interpolate:Z=>Z,type:"vnode"};function Y(...Z){return D(P=>{let q;const ee=P;try{ee.processor=K,q=Reflect.apply(translate,null,[ee,...Z])}finally{ee.processor=null}return q},()=>parseTranslateArgs(...Z),"translate",P=>P[TranslateVNodeSymbol](...Z),P=>[createTextNode(P)],P=>isArray(P))}function Q(...Z){return D(P=>Reflect.apply(number,null,[P,...Z]),()=>parseNumberArgs(...Z),"number format",P=>P[NumberPartsSymbol](...Z),NOOP_RETURN_ARRAY,P=>isString(P)||isArray(P))}function J(...Z){return D(P=>Reflect.apply(datetime,null,[P,...Z]),()=>parseDateTimeArgs(...Z),"datetime format",P=>P[DatetimePartsSymbol](...Z),NOOP_RETURN_ARRAY,P=>isString(P)||isArray(P))}function ne(Z){m=Z,$.pluralRules=m}function re(Z,P){return D(()=>{if(!Z)return!1;const q=isString(P)?P:A.value,ee=ae(q),ie=$.messageResolver(ee,Z);return isMessageAST(ie)||isMessageFunction(ie)||isString(ie)},()=>[Z],"translate exists",q=>Reflect.apply(q.te,q,[Z,P]),NOOP_RETURN_FALSE,q=>isBoolean(q))}function j(Z){let P=null;const q=fallbackWithLocaleChain($,a.value,A.value);for(let ee=0;ee<q.length;ee++){const ie=g.value[q[ee]]||{},le=$.messageResolver(ie,Z);if(le!=null){P=le;break}}return P}function se(Z){const P=j(Z);return P??(u?u.tm(Z)||{}:{})}function ae(Z){return g.value[Z]||{}}function me(Z,P){if(E){const q={[Z]:P};for(const ee in q)hasOwn(q,ee)&&handleFlatJson(q[ee]);P=q[Z]}g.value[Z]=P,$.messages=g.value}function ye(Z,P){g.value[Z]=g.value[Z]||{};const q={[Z]:P};if(E)for(const ee in q)hasOwn(q,ee)&&handleFlatJson(q[ee]);P=q[Z],deepCopy(P,g.value[Z]),$.messages=g.value}function W(Z){return n.value[Z]||{}}function G(Z,P){n.value[Z]=P,$.datetimeFormats=n.value,clearDateTimeFormat($,Z,P)}function X(Z,P){n.value[Z]=assign(n.value[Z]||{},P),$.datetimeFormats=n.value,clearDateTimeFormat($,Z,P)}function te(Z){return s.value[Z]||{}}function ge(Z,P){s.value[Z]=P,$.numberFormats=s.value,clearNumberFormat($,Z,P)}function fe(Z,P){s.value[Z]=assign(s.value[Z]||{},P),$.numberFormats=s.value,clearNumberFormat($,Z,P)}composerID++,u&&inBrowser&&(vue.watch(u.locale,Z=>{C&&(A.value=Z,$.locale=Z,updateFallbackLocale($,A.value,a.value))}),vue.watch(u.fallbackLocale,Z=>{C&&(a.value=Z,$.fallbackLocale=Z,updateFallbackLocale($,A.value,a.value))}));const oe={id:composerID,locale:S,fallbackLocale:O,get inheritLocale(){return C},set inheritLocale(Z){C=Z,Z&&u&&(A.value=u.locale.value,a.value=u.fallbackLocale.value,updateFallbackLocale($,A.value,a.value))},get availableLocales(){return Object.keys(g.value).sort()},messages:x,get modifiers(){return y},get pluralRules(){return m||{}},get isGlobal(){return d},get missingWarn(){return o},set missingWarn(Z){o=Z,$.missingWarn=o},get fallbackWarn(){return r},set fallbackWarn(Z){r=Z,$.fallbackWarn=r},get fallbackRoot(){return t},set fallbackRoot(Z){t=Z},get fallbackFormat(){return i},set fallbackFormat(Z){i=Z,$.fallbackFormat=i},get warnHtmlMessage(){return v},set warnHtmlMessage(Z){v=Z,$.warnHtmlMessage=Z},get escapeParameter(){return p},set escapeParameter(Z){p=Z,$.escapeParameter=Z},t:V,getLocaleMessage:ae,setLocaleMessage:me,mergeLocaleMessage:ye,getPostTranslationHandler:w,setPostTranslationHandler:_,getMissingHandler:T,setMissingHandler:k,[SetPluralRulesSymbol]:ne};return oe.datetimeFormats=L,oe.numberFormats=I,oe.rt=B,oe.te=re,oe.tm=se,oe.d=F,oe.n=H,oe.getDateTimeFormat=W,oe.setDateTimeFormat=G,oe.mergeDateTimeFormat=X,oe.getNumberFormat=te,oe.setNumberFormat=ge,oe.mergeNumberFormat=fe,oe[InejctWithOptionSymbol]=l,oe[TranslateVNodeSymbol]=Y,oe[DatetimePartsSymbol]=J,oe[NumberPartsSymbol]=Q,process.env.NODE_ENV!=="production"&&(oe[EnableEmitter]=Z=>{$.__v_emitter=Z},oe[DisableEmitter]=()=>{$.__v_emitter=void 0}),oe}function addTimelineEvent(e,u){}const baseFormatProps={tag:{type:[String,Object]},locale:{type:String},scope:{type:String,validator:e=>e==="parent"||e==="global",default:"parent"},i18n:{type:Object}};function getInterpolateArg({slots:e},u){return u.length===1&&u[0]==="default"?(e.default?e.default():[]).reduce((d,E)=>[...d,...E.type===vue.Fragment?E.children:[E]],[]):u.reduce((l,d)=>{const E=e[d];return E&&(l[d]=E()),l},create())}function getFragmentableTag(){return vue.Fragment}assign({keypath:{type:String,required:!0},plural:{type:[Number,String],validator:e=>isNumber(e)||!isNaN(e)}},baseFormatProps);function isVNode(e){return isArray(e)&&!isString(e[0])}function renderFormatter(e,u,l,d){const{slots:E,attrs:b}=u;return()=>{const C={part:!0};let A=create();e.locale&&(C.locale=e.locale),isString(e.format)?C.key=e.format:isObject(e.format)&&(isString(e.format.key)&&(C.key=e.format.key),A=Object.keys(e.format).reduce((o,r)=>l.includes(r)?assign(create(),o,{[r]:e.format[r]}):o,create()));const a=d(e.value,C,A);let g=[C.key];isArray(a)?g=a.map((o,r)=>{const t=E[o.type],i=t?t({[o.type]:o.value,index:r,parts:a}):[o.value];return isVNode(i)&&(i[0].key=`${o.type}-${r}`),i}):isString(a)&&(g=[a]);const n=assign(create(),b),s=isString(e.tag)||isObject(e.tag)?e.tag:getFragmentableTag();return vue.h(s,n,g)}}assign({value:{type:Number,required:!0},format:{type:[String,Object]}},baseFormatProps);const I18nInjectionKey=makeSymbol("global-vue-i18n");function useI18n(e={}){const u=vue.getCurrentInstance();if(u==null)throw createI18nError(I18nErrorCodes.MUST_BE_CALL_SETUP_TOP);if(!u.isCE&&u.appContext.app!=null&&!u.appContext.app.__VUE_I18N_SYMBOL__)throw createI18nError(I18nErrorCodes.NOT_INSTALLED);const l=getI18nInstance(u),d=getGlobalComposer(l),E=getComponentOptions(u),b=getScope(e,E);if(b==="global")return adjustI18nResources(d,e,E),d;if(b==="parent"){let a=getComposer(l,u,e.__useComponent);return a==null&&(process.env.NODE_ENV!=="production"&&warn(getWarnMessage(I18nWarnCodes.NOT_FOUND_PARENT_SCOPE)),a=d),a}const C=l;let A=C.__getInstance(u);if(A==null){const a=assign({},e);"__i18n"in E&&(a.__i18n=E.__i18n),d&&(a.__root=d),A=createComposer(a),C.__composerExtend&&(A[DisposeSymbol]=C.__composerExtend(A)),setupLifeCycle(C,u,A),C.__setInstance(u,A)}return A}function getI18nInstance(e){const u=vue.inject(e.isCE?I18nInjectionKey:e.appContext.app.__VUE_I18N_SYMBOL__);if(!u)throw createI18nError(e.isCE?I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE:I18nErrorCodes.UNEXPECTED_ERROR);return u}function getScope(e,u){return isEmptyObject(e)?"__i18n"in u?"local":"global":e.useScope?e.useScope:"local"}function getGlobalComposer(e){return e.mode==="composition"?e.global:e.global.__composer}function getComposer(e,u,l=!1){let d=null;const E=u.root;let b=getParentComponentInstance(u,l);for(;b!=null;){const C=e;if(e.mode==="composition")d=C.__getInstance(b);else if(__VUE_I18N_LEGACY_API__){const A=C.__getInstance(b);A!=null&&(d=A.__composer,l&&d&&!d[InejctWithOptionSymbol]&&(d=null))}if(d!=null||E===b)break;b=b.parent}return d}function getParentComponentInstance(e,u=!1){return e==null?null:u&&e.vnode.ctx||e.parent}function setupLifeCycle(e,u,l){let d=null;vue.onMounted(()=>{if(process.env.NODE_ENV!=="production"&&u.vnode.el){u.vnode.el.__VUE_I18N__=l,d=createEmitter();const E=l;E[EnableEmitter]&&E[EnableEmitter](d),d.on("*",addTimelineEvent)}},u),vue.onUnmounted(()=>{const E=l;process.env.NODE_ENV!=="production"&&u.vnode.el&&u.vnode.el.__VUE_I18N__&&(d&&d.off("*",addTimelineEvent),E[DisableEmitter]&&E[DisableEmitter](),delete u.vnode.el.__VUE_I18N__),e.__deleteInstance(u);const b=E[DisposeSymbol];b&&(b(),delete E[DisposeSymbol])},u)}if(assign({value:{type:[Number,Date],required:!0},format:{type:[String,Object]}},baseFormatProps),initFeatureFlags(),registerMessageCompiler(compile),registerMessageResolver(resolveValue),registerLocaleFallbacker(fallbackWithLocaleChain),process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__){const e=getGlobalThis();e.__INTLIFY__=!0,setDevToolsHook(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}process.env.NODE_ENV;const _hoisted_1$5={style:{}},_hoisted_2$4={style:{}},_hoisted_3$3={style:{}},_hoisted_4$3={key:0},_hoisted_5$3={class:"dialog-footer"},_hoisted_6$1={key:1},_hoisted_7$1={class:"dialog-footer"},_sfc_main$5={__name:"settings",props:vue.mergeModels({},{conf:{},confModifiers:{},form:{},formModifiers:{}}),emits:["update:conf","update:form"],setup(e){const{cloneItem:u}=useComponentUtils(),{t:l,locale:d}=useI18n(),E=vue.inject("designerRender"),b=vue.inject("renderConf"),C=vue.ref("itemConfig"),A=vue.ref(["base"]),a=vue.useModel(e,"conf"),g=vue.useModel(e,"form"),n=()=>{const M=a.value.options.optionItems.length+1;a.value.options.optionItems.push({label:a.value.type+" "+M,value:M})},s=()=>{a.value.cols.push(u({key:10002}))},o=(M,S)=>{a.value.cols.splice(S,1)},r=(M,S)=>{a.value.options[S]!==null&&a.value.options[S]==M&&setTimeout(()=>{a.value.options[S]=null})},t=M=>{if(!E)return;let S=N.value;if(E.value.getWidgetRef(M)){console.error("duplicateN name"),a.value.options.name=S;return}let x=E.value.getWidgetRef(S);x&&x.registerRef&&(x.removeRef(S),x.registerRef())},i=vue.ref([]),c=vue.ref(!1),h=()=>{c.value=!0,i.value=JSON.parse(JSON.stringify(a.value.options.showCondition||[{relation:"and"}]))},f=()=>{a.value.options.showCondition=i.value,c.value=!1},v=vue.ref(""),p=vue.ref(""),y=vue.ref(!1),m=(M,S)=>{v.value=M,p.value=a.value.options[M]||"",y.value=!0},$=()=>{a.value.options[v.value]=p.value,y.value=!1},N=vue.ref(null);return vue.watch(()=>{var M;return(M=a.value)==null?void 0:M.id},(M,S)=>{N.value=a.value.options.name}),(M,S)=>{const O=vue.resolveComponent("el-input"),x=vue.resolveComponent("el-form-item"),L=vue.resolveComponent("el-option"),I=vue.resolveComponent("el-select"),w=vue.resolveComponent("el-input-number"),_=vue.resolveComponent("el-radio-button"),T=vue.resolveComponent("el-radio-group"),k=vue.resolveComponent("el-switch"),R=vue.resolveComponent("el-radio"),D=vue.resolveComponent("el-button"),V=vue.resolveComponent("el-divider"),B=vue.resolveComponent("el-col"),F=vue.resolveComponent("el-row"),H=vue.resolveComponent("el-checkbox"),U=vue.resolveComponent("el-checkbox-group"),z=vue.resolveComponent("el-collapse-item"),K=vue.resolveComponent("el-collapse"),Y=vue.resolveComponent("el-form"),Q=vue.resolveComponent("el-tab-pane"),J=vue.resolveComponent("el-tabs"),ne=vue.resolveComponent("el-dialog"),re=vue.resolveComponent("el-container");return vue.openBlock(),vue.createBlock(re,{class:"panel-container",direction:"vertical"},{default:vue.withCtx(()=>[vue.createVNode(J,{modelValue:C.value,"onUpdate:modelValue":S[42]||(S[42]=j=>C.value=j),class:"demo-tabs",style:{padding:"4px 0 0 0"}},{default:vue.withCtx(()=>[vue.createVNode(Q,{label:"组件设置",name:"itemConfig"},{default:vue.withCtx(()=>[a.value?(vue.openBlock(),vue.createBlock(Y,{key:0,size:"small",model:a.value,labelWidth:"110","label-position":"left"},{default:vue.withCtx(()=>[vue.createVNode(K,{modelValue:A.value,"onUpdate:modelValue":S[38]||(S[38]=j=>A.value=j)},{default:vue.withCtx(()=>[vue.createVNode(z,{title:"常规属性",name:"base"},{default:vue.withCtx(()=>[vue.createVNode(x,{label:"唯一名称",prop:"options.name",rules:[{message:"英文名称必填",required:!0,trigger:"blur"}]},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.name,"onUpdate:modelValue":S[0]||(S[0]=j=>a.value.options.name=j),onChange:t},null,8,["modelValue"])]),_:1}),a.value.type in{input:!0,textarea:!0,radio:!0,checkbox:!0,select:!0,"picture-upload":!0}?(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:0},[vue.createVNode(x,{label:"标签",prop:"options.label"},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.label,"onUpdate:modelValue":S[1]||(S[1]=j=>a.value.options.label=j)},null,8,["modelValue"])]),_:1}),a.value.type in{input:!0,textarea:!0}?(vue.openBlock(),vue.createBlock(x,{key:0,label:"默认值",prop:"options.defaultValue"},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.defaultValue,"onUpdate:modelValue":S[2]||(S[2]=j=>a.value.options.defaultValue=j)},null,8,["modelValue"])]),_:1})):vue.createCommentVNode("",!0),vue.createVNode(x,{label:"提交类型",prop:"options.submitType"},{default:vue.withCtx(()=>[vue.createVNode(I,{modelValue:a.value.options.submitType,"onUpdate:modelValue":S[3]||(S[3]=j=>a.value.options.submitType=j),filterable:"","default-first-option":"","reserve-keyword":!1,style:{width:"240px"}},{default:vue.withCtx(()=>[(vue.openBlock(),vue.createElementBlock(vue.Fragment,null,vue.renderList([{value:"string",label:"文本"},{value:"number",label:"数字"},{value:"boolean",label:"布尔"},{value:"array",label:"数组"},{value:"object",label:"对象"}],j=>vue.createVNode(L,{key:j.value,label:j.label,value:j.value},null,8,["label","value"])),64))]),_:1},8,["modelValue"])]),_:1}),a.value.type in{input:!0,textarea:!0}?(vue.openBlock(),vue.createBlock(x,{key:1,label:"占位内容",prop:"options.placeholder"},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.placeholder,"onUpdate:modelValue":S[4]||(S[4]=j=>a.value.options.placeholder=j)},null,8,["modelValue"])]),_:1})):vue.createCommentVNode("",!0),vue.createVNode(x,{label:"标签宽度",prop:"options.labelWidth"},{default:vue.withCtx(()=>[vue.createVNode(w,{modelValue:a.value.options.labelWidth,"onUpdate:modelValue":S[5]||(S[5]=j=>a.value.options.labelWidth=j),min:0,max:100},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"字段标签对齐",prop:"options.labelAlign"},{default:vue.withCtx(()=>[vue.createVNode(T,{modelValue:a.value.options.labelAlign,"onUpdate:modelValue":S[9]||(S[9]=j=>a.value.options.labelAlign=j),size:"small"},{default:vue.withCtx(()=>[vue.createVNode(_,{label:"居左",value:"label-item-left-align",onClick:S[6]||(S[6]=j=>r("label-item-left-align","labelAlign"))}),vue.createVNode(_,{label:"居中",value:"label-item-center-align",onClick:S[7]||(S[7]=j=>r("label-item-center-align","labelAlign"))}),vue.createVNode(_,{label:"居右",value:"label-item-right-align",onClick:S[8]||(S[8]=j=>r("label-item-right-align","labelAlign"))})]),_:1},8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"隐藏字段标签",prop:"options.labelHidden"},{default:vue.withCtx(()=>[vue.createVNode(k,{modelValue:a.value.options.labelHidden,"onUpdate:modelValue":S[10]||(S[10]=j=>a.value.options.labelHidden=j)},null,8,["modelValue"])]),_:1}),a.value.type in{textarea:!0}?(vue.openBlock(),vue.createBlock(x,{key:2,label:"行数",prop:"options.rows"},{default:vue.withCtx(()=>[vue.createVNode(w,{modelValue:a.value.options.rows,"onUpdate:modelValue":S[11]||(S[11]=j=>a.value.options.rows=j),min:3},null,8,["modelValue"])]),_:1})):vue.createCommentVNode("",!0),a.value.type in{radio:!0,checkbox:!0}?(vue.openBlock(),vue.createBlock(x,{key:3,label:"显示样式",prop:"options.displayStyle"},{default:vue.withCtx(()=>[vue.createVNode(T,{modelValue:a.value.options.displayStyle,"onUpdate:modelValue":S[12]||(S[12]=j=>a.value.options.displayStyle=j),size:"small"},{default:vue.withCtx(()=>[vue.createVNode(R,{label:"行内",value:"inline"}),vue.createVNode(R,{label:"块",value:"block"})]),_:1},8,["modelValue"])]),_:1})):vue.createCommentVNode("",!0),a.value.type in{input:!0,select:!0}?(vue.openBlock(),vue.createBlock(x,{key:4,label:"可清除",prop:"clearable"},{default:vue.withCtx(()=>[vue.createVNode(k,{modelValue:a.value.options.clearable,"onUpdate:modelValue":S[13]||(S[13]=j=>a.value.options.clearable=j)},null,8,["modelValue"])]),_:1})):vue.createCommentVNode("",!0),vue.createVNode(x,{label:"必填字段",prop:"options.required"},{default:vue.withCtx(()=>[vue.createVNode(k,{modelValue:a.value.options.required,"onUpdate:modelValue":S[14]||(S[14]=j=>a.value.options.required=j)},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"必填提示",prop:"options.requiredHint"},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.requiredHint,"onUpdate:modelValue":S[15]||(S[15]=j=>a.value.options.requiredHint=j)},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"校验规则",prop:"options.validation"},{default:vue.withCtx(()=>[vue.createVNode(I,{modelValue:a.value.options.validation,"onUpdate:modelValue":S[16]||(S[16]=j=>a.value.options.validation=j),filterable:"","allow-create":"","default-first-option":"","reserve-keyword":!1,style:{width:"240px"},clearable:""},{default:vue.withCtx(()=>[(vue.openBlock(!0),vue.createElementBlock(vue.Fragment,null,vue.renderList([{value:"number",label:vue.unref(l)("settings.hint.numberValidator")},{value:"letter",label:vue.unref(l)("settings.hint.letterValidator")},{value:"letterAndNumber",label:vue.unref(l)("settings.hint.letterAndNumberValidator")},{value:"mobilePhone",label:vue.unref(l)("settings.hint.mobilePhoneValidator")},{value:"email",label:vue.unref(l)("settings.hint.emailValidator")},{value:"url",label:vue.unref(l)("settings.hint.urlValidator")},{value:"noChinese",label:vue.unref(l)("settings.hint.noChineseValidator")},{value:"chinese",label:vue.unref(l)("settings.hint.chineseValidator")}],j=>(vue.openBlock(),vue.createBlock(L,{key:j.value,label:j.label,value:j.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"校验提示",prop:"options.validationHint"},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.validationHint,"onUpdate:modelValue":S[17]||(S[17]=j=>a.value.options.validationHint=j)},null,8,["modelValue"])]),_:1})],64)):vue.createCommentVNode("",!0),vue.createVNode(x,{label:"隐藏",prop:"options.hidden"},{default:vue.withCtx(()=>[vue.createVNode(k,{modelValue:a.value.options.hidden,"onUpdate:modelValue":S[18]||(S[18]=j=>a.value.options.hidden=j)},null,8,["modelValue"])]),_:1}),a.value.options.hidden?(vue.openBlock(),vue.createBlock(x,{key:1,label:"显示条件",prop:"options.showCondition"},{default:vue.withCtx(()=>[vue.createVNode(D,{type:"primary",icon:"el-icon-edit",onClick:h},{default:vue.withCtx(()=>S[48]||(S[48]=[vue.createTextVNode("编辑条件")])),_:1})]),_:1})):vue.createCommentVNode("",!0),a.value.type in{radio:!0,checkbox:!0,select:!0}?(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:2},[vue.createVNode(V,null,{default:vue.withCtx(()=>S[49]||(S[49]=[vue.createTextVNode(" 选项配置 ")])),_:1}),a.value.type=="radio"||a.value.type=="select"?(vue.openBlock(),vue.createBlock(T,{key:0,modelValue:a.value.options.defaultValue,"onUpdate:modelValue":S[19]||(S[19]=j=>a.value.options.defaultValue=j),size:"small"},{default:vue.withCtx(()=>[vue.createVNode(vue.unref(draggable),vue.mergeProps({tag:"div",list:a.value.options.optionItems},{group:{name:"options"},ghostClass:"ghost",handle:".drag-item"},{"item-key":"value"}),{item:vue.withCtx(({element:j})=>[vue.createVNode(F,{gutter:6,style:{"margin-top":"2px"}},{default:vue.withCtx(()=>[vue.createVNode(B,{span:3},{default:vue.withCtx(()=>[vue.createVNode(R,{value:j.value},null,8,["value"])]),_:2},1024),vue.createVNode(B,{span:5},{default:vue.withCtx(()=>[vue.createVNode(O,{style:{width:"100%"},modelValue:j.value,"onUpdate:modelValue":se=>j.value=se},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),vue.createVNode(B,{span:8},{default:vue.withCtx(()=>[vue.createVNode(O,{style:{width:"100%"},modelValue:j.label,"onUpdate:modelValue":se=>j.label=se},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),vue.createVNode(B,{span:3,style:{"font-size":"16px"}},{default:vue.withCtx(()=>S[50]||(S[50]=[vue.createElementVNode("svg",{class:"svg-icon drag-item","aria-hidden":"true"},[vue.createElementVNode("use",{"xlink:href":"#icon-el-drag-move"})],-1)])),_:1}),vue.createVNode(B,{span:5},{default:vue.withCtx(()=>[vue.createVNode(D,{type:"danger",icon:"el-icon-delete",circle:""})]),_:1})]),_:2},1024)]),_:1},16,["list"]),vue.createElementVNode("div",_hoisted_1$5,[vue.createVNode(D,{text:"",type:"primary",icon:"el-icon-plus",style:{"margin-top":"4px",padding:"2px"},onClick:n},{default:vue.withCtx(()=>S[51]||(S[51]=[vue.createTextVNode("添加选项")])),_:1})])]),_:1},8,["modelValue"])):a.value.type=="checkbox"?(vue.openBlock(),vue.createBlock(U,{key:1,modelValue:a.value.options.defaultValue,"onUpdate:modelValue":S[20]||(S[20]=j=>a.value.options.defaultValue=j),size:"small"},{default:vue.withCtx(()=>[vue.createVNode(vue.unref(draggable),vue.mergeProps({tag:"div",list:a.value.options.optionItems},{group:{name:"options"},ghostClass:"ghost",handle:".drag-item"},{"item-key":"value"}),{item:vue.withCtx(({element:j})=>[vue.createVNode(F,{gutter:6,style:{"margin-top":"2px"}},{default:vue.withCtx(()=>[vue.createVNode(B,{span:3},{default:vue.withCtx(()=>[vue.createVNode(H,{value:j.value},null,8,["value"])]),_:2},1024),vue.createVNode(B,{span:5},{default:vue.withCtx(()=>[vue.createVNode(O,{style:{width:"100%"},modelValue:j.value,"onUpdate:modelValue":se=>j.value=se},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),vue.createVNode(B,{span:8},{default:vue.withCtx(()=>[vue.createVNode(O,{style:{width:"100%"},modelValue:j.label,"onUpdate:modelValue":se=>j.label=se},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),vue.createVNode(B,{span:3,style:{"font-size":"16px"}},{default:vue.withCtx(()=>S[52]||(S[52]=[vue.createElementVNode("svg",{class:"svg-icon drag-item","aria-hidden":"true"},[vue.createElementVNode("use",{"xlink:href":"#icon-el-drag-move"})],-1)])),_:1}),vue.createVNode(B,{span:5},{default:vue.withCtx(()=>[vue.createVNode(D,{type:"danger",icon:"el-icon-delete",circle:""})]),_:1})]),_:2},1024)]),_:1},16,["list"]),vue.createElementVNode("div",_hoisted_2$4,[vue.createVNode(D,{text:"",type:"primary",icon:"el-icon-plus",style:{"margin-top":"4px",padding:"2px"},onClick:n},{default:vue.withCtx(()=>S[53]||(S[53]=[vue.createTextVNode("添加选项")])),_:1})])]),_:1},8,["modelValue"])):vue.createCommentVNode("",!0)],64)):vue.createCommentVNode("",!0),a.value.type=="static-title"?(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:3},[vue.createVNode(x,{label:"静态文字",prop:"options.textContent"},{default:vue.withCtx(()=>[vue.createVNode(O,{type:"textarea",modelValue:a.value.options.textContent,"onUpdate:modelValue":S[21]||(S[21]=j=>a.value.options.textContent=j)},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"对齐方式"},{default:vue.withCtx(()=>[vue.createVNode(T,{modelValue:a.value.options.textAlign,"onUpdate:modelValue":S[22]||(S[22]=j=>a.value.options.textAlign=j)},{default:vue.withCtx(()=>[vue.createVNode(_,{value:"left"},{default:vue.withCtx(()=>S[54]||(S[54]=[vue.createTextVNode("左对齐")])),_:1}),vue.createVNode(_,{value:"center"},{default:vue.withCtx(()=>S[55]||(S[55]=[vue.createTextVNode("居中")])),_:1}),vue.createVNode(_,{value:"right"},{default:vue.withCtx(()=>S[56]||(S[56]=[vue.createTextVNode("右对齐")])),_:1})]),_:1},8,["modelValue"])]),_:1}),a.value.type=="static-title"?(vue.openBlock(),vue.createBlock(x,{key:0,label:"级别",prop:"options.titleLevel"},{default:vue.withCtx(()=>[vue.createVNode(I,{modelValue:a.value.options.titleLevel,"onUpdate:modelValue":S[23]||(S[23]=j=>a.value.options.titleLevel=j),filterable:"","allow-create":"","default-first-option":"","reserve-keyword":!1,style:{width:"240px"}},{default:vue.withCtx(()=>[(vue.openBlock(),vue.createElementBlock(vue.Fragment,null,vue.renderList([{value:1,label:"一级标题"},{value:2,label:"二级标题"},{value:3,label:"三级标题"}],j=>vue.createVNode(L,{key:j.value,label:j.label,value:j.value},null,8,["label","value"])),64))]),_:1},8,["modelValue"])]),_:1})):vue.createCommentVNode("",!0)],64)):vue.createCommentVNode("",!0),a.value.type=="grid"?(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:4},[vue.createVNode(V,null,{default:vue.withCtx(()=>S[57]||(S[57]=[vue.createTextVNode(" 栅格属性设置 ")])),_:1}),vue.createVNode(x,{label:"栅格间隔(px)",prop:"gutter"},{default:vue.withCtx(()=>[vue.createVNode(w,{modelValue:a.value.options.gutter,"onUpdate:modelValue":S[24]||(S[24]=j=>a.value.options.gutter=j),min:0,max:100},null,8,["modelValue"])]),_:1}),vue.createElementVNode("div",null,[S[59]||(S[59]=vue.createElementVNode("div",null,"当前栅格列:",-1)),(vue.openBlock(!0),vue.createElementBlock(vue.Fragment,null,vue.renderList(a.value.cols,(j,se)=>(vue.openBlock(),vue.createBlock(F,{key:j.id,gutter:6,style:{"margin-top":"2px"}},{default:vue.withCtx(()=>[vue.createVNode(B,{span:8},{default:vue.withCtx(()=>[vue.createTextVNode("栅格"+vue.toDisplayString(se+1)+"宽度",1)]),_:2},1024),vue.createVNode(B,{span:8},{default:vue.withCtx(()=>[vue.createVNode(w,{style:{width:"100%"},modelValue:j.options.span,"onUpdate:modelValue":ae=>j.options.span=ae,min:0,max:24},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),vue.createVNode(B,{span:8},{default:vue.withCtx(()=>[vue.createVNode(D,{type:"danger",icon:"el-icon-delete",circle:"",onClick:ae=>o(j,se)},null,8,["onClick"])]),_:2},1024)]),_:2},1024))),128)),vue.createElementVNode("div",_hoisted_3$3,[vue.createVNode(D,{text:"",type:"primary",icon:"el-icon-plus",style:{"margin-top":"4px",padding:"2px"},onClick:s},{default:vue.withCtx(()=>S[58]||(S[58]=[vue.createTextVNode("添加栅格")])),_:1})])])],64)):vue.createCommentVNode("",!0),a.value.type=="picture-upload"?(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:5},[vue.createVNode(V,null,{default:vue.withCtx(()=>S[60]||(S[60]=[vue.createTextVNode(" 上传参数设置 ")])),_:1}),vue.createVNode(x,{label:"签名地址",prop:"options.signatureUrl"},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.signatureUrl,"onUpdate:modelValue":S[25]||(S[25]=j=>a.value.options.signatureUrl=j)},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"需要md5",prop:"options.requireMd5"},{default:vue.withCtx(()=>[vue.createVNode(k,{modelValue:a.value.options.requireMd5,"onUpdate:modelValue":S[26]||(S[26]=j=>a.value.options.requireMd5=j)},null,8,["modelValue"])]),_:1}),a.value.options.requireMd5?(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:0},[vue.createVNode(x,{label:"md5查询地址",prop:"options.queryFileMd5Url"},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.queryFileMd5Url,"onUpdate:modelValue":S[27]||(S[27]=j=>a.value.options.queryFileMd5Url=j)},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"添加md5地址",prop:"options.addFileMd5Url"},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.addFileMd5Url,"onUpdate:modelValue":S[28]||(S[28]=j=>a.value.options.addFileMd5Url=j)},null,8,["modelValue"])]),_:1})],64)):vue.createCommentVNode("",!0),vue.createVNode(x,{label:"占位图片",prop:"options.defaultBg"},{default:vue.withCtx(()=>[vue.createVNode(O,{modelValue:a.value.options.defaultBg,"onUpdate:modelValue":S[29]||(S[29]=j=>a.value.options.defaultBg=j)},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"显示提示语",prop:"options.isShowTip"},{default:vue.withCtx(()=>[vue.createVNode(k,{modelValue:a.value.options.isShowTip,"onUpdate:modelValue":S[30]||(S[30]=j=>a.value.options.isShowTip=j)},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"上传文件类型",prop:"options.fileTypes"},{default:vue.withCtx(()=>[vue.createVNode(I,{modelValue:a.value.options.fileTypes,"onUpdate:modelValue":S[31]||(S[31]=j=>a.value.options.fileTypes=j),multiple:"",filterable:"","allow-create":"","default-first-option":"","reserve-keyword":!1,style:{width:"240px"}},{default:vue.withCtx(()=>[(vue.openBlock(),vue.createElementBlock(vue.Fragment,null,vue.renderList([{value:"jpg",label:"jpg"},{value:"jpeg",label:"jpeg"},{value:"png",label:"png"},{value:"gif",label:"gif"}],j=>vue.createVNode(L,{key:j.value,label:j.label,value:j.value},null,8,["label","value"])),64))]),_:1},8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"文件可多选",prop:"options.multipleSelect"},{default:vue.withCtx(()=>[vue.createVNode(k,{modelValue:a.value.options.multipleSelect,"onUpdate:modelValue":S[32]||(S[32]=j=>a.value.options.multipleSelect=j)},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"最大上传数量",prop:"options.limit"},{default:vue.withCtx(()=>[vue.createVNode(w,{modelValue:a.value.options.limit,"onUpdate:modelValue":S[33]||(S[33]=j=>a.value.options.limit=j),min:1},null,8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"文件大小限制(MB)",prop:"options.fileMaxSize"},{default:vue.withCtx(()=>[vue.createVNode(w,{modelValue:a.value.options.fileMaxSize,"onUpdate:modelValue":S[34]||(S[34]=j=>a.value.options.fileMaxSize=j),min:1},null,8,["modelValue"])]),_:1})],64)):vue.createCommentVNode("",!0)]),_:1}),vue.createVNode(z,{title:"事件",name:"event"},{default:vue.withCtx(()=>[vue.createVNode(x,{label:"onCreated",prop:"options.onCreated","label-width":"150px"},{default:vue.withCtx(()=>[vue.createVNode(D,{type:"info",icon:"el-icon-edit",plain:"",round:"",onClick:S[35]||(S[35]=j=>m("onCreated"))},{default:vue.withCtx(()=>S[61]||(S[61]=[vue.createTextVNode("编写代码")])),_:1})]),_:1}),vue.createVNode(x,{label:"onMounted",prop:"options.onMounted","label-width":"150px"},{default:vue.withCtx(()=>[vue.createVNode(D,{type:"info",icon:"el-icon-edit",plain:"",round:"",onClick:S[36]||(S[36]=j=>m("onMounted"))},{default:vue.withCtx(()=>S[62]||(S[62]=[vue.createTextVNode("编写代码")])),_:1})]),_:1}),a.value.options.hasOwnProperty("onChange")?(vue.openBlock(),vue.createBlock(x,{key:0,label:"onChange",prop:"options.onChange","label-width":"150px"},{default:vue.withCtx(()=>[vue.createVNode(D,{type:"info",icon:"el-icon-edit",plain:"",round:"",onClick:S[37]||(S[37]=j=>m("onChange"))},{default:vue.withCtx(()=>S[63]||(S[63]=[vue.createTextVNode("编写代码")])),_:1})]),_:1})):vue.createCommentVNode("",!0)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["model"])):vue.createCommentVNode("",!0)]),_:1}),vue.createVNode(Q,{label:"表单设置",name:"formConfig"},{default:vue.withCtx(()=>[g.value?(vue.openBlock(),vue.createBlock(Y,{key:0,size:"small",model:g.value,"label-width":"110","label-position":"left"},{default:vue.withCtx(()=>[vue.createVNode(x,{label:"标签位置",prop:"labelPosition"},{default:vue.withCtx(()=>[vue.createVNode(T,{modelValue:g.value.labelPosition,"onUpdate:modelValue":S[39]||(S[39]=j=>g.value.labelPosition=j),size:"small"},{default:vue.withCtx(()=>[vue.createVNode(_,{label:"左边",value:"left"}),vue.createVNode(_,{label:"顶部",value:"top"})]),_:1},8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"字段标签对齐",prop:"labelAlign"},{default:vue.withCtx(()=>[vue.createVNode(T,{modelValue:g.value.labelAlign,"onUpdate:modelValue":S[40]||(S[40]=j=>g.value.labelAlign=j),size:"small"},{default:vue.withCtx(()=>[vue.createVNode(_,{label:"居左",value:"label-left-align"}),vue.createVNode(_,{label:"居中",value:"label-center-align"}),vue.createVNode(_,{label:"居右",value:"label-right-align"})]),_:1},8,["modelValue"])]),_:1}),vue.createVNode(x,{label:"标签宽度",prop:"labelWidth"},{default:vue.withCtx(()=>[vue.createVNode(w,{modelValue:g.value.labelWidth,"onUpdate:modelValue":S[41]||(S[41]=j=>g.value.labelWidth=j),min:0,max:100},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])):vue.createCommentVNode("",!0)]),_:1})]),_:1},8,["modelValue"]),y.value?(vue.openBlock(),vue.createElementBlock("div",_hoisted_4$3,[vue.createVNode(ne,{title:"编辑代码",modelValue:y.value,"onUpdate:modelValue":S[45]||(S[45]=j=>y.value=j)},{footer:vue.withCtx(()=>[vue.createElementVNode("div",_hoisted_5$3,[vue.createVNode(D,{onClick:S[44]||(S[44]=j=>y.value=!1)},{default:vue.withCtx(()=>S[64]||(S[64]=[vue.createTextVNode("取消")])),_:1}),vue.createVNode(D,{type:"primary",onClick:$},{default:vue.withCtx(()=>S[65]||(S[65]=[vue.createTextVNode("确定")])),_:1})])]),default:vue.withCtx(()=>[vue.createVNode(_sfc_main$7,{mode:"javascript",readonly:!1,modelValue:p.value,"onUpdate:modelValue":S[43]||(S[43]=j=>p.value=j),ref:"ecEditor"},null,8,["modelValue"])]),_:1},8,["modelValue"])])):vue.createCommentVNode("",!0),c.value?(vue.openBlock(),vue.createElementBlock("div",_hoisted_6$1,[vue.createVNode(ne,{title:"条件显示",modelValue:c.value,"onUpdate:modelValue":S[47]||(S[47]=j=>c.value=j)},{footer:vue.withCtx(()=>[vue.createElementVNode("div",_hoisted_7$1,[vue.createVNode(D,{onClick:S[46]||(S[46]=j=>c.value=!1)},{default:vue.withCtx(()=>S[66]||(S[66]=[vue.createTextVNode("取消")])),_:1}),vue.createVNode(D,{type:"primary",onClick:f},{default:vue.withCtx(()=>S[67]||(S[67]=[vue.createTextVNode("确定")])),_:1})])]),default:vue.withCtx(()=>[vue.createVNode(ConditionEditor,{conf:vue.unref(b),express:i.value},null,8,["conf","express"])]),_:1},8,["modelValue"])])):vue.createCommentVNode("",!0)]),_:1})}}},Settings=_export_sfc(_sfc_main$5,[["__scopeId","data-v-41cf92c7"]]),settings=Object.freeze(Object.defineProperty({__proto__:null,default:Settings},Symbol.toStringTag,{value:"Module"})),_hoisted_1$4=["title"],_sfc_main$4={__name:"widgets",setup(e){const{t:u,locale:l}=useI18n(),{cloneItem:d,allComponents:E}=useComponentUtils(),b=vue.ref("base"),C=(A,a,g)=>{};return(A,a)=>{const g=vue.resolveComponent("sy-svg-icon"),n=vue.resolveComponent("el-collapse-item"),s=vue.resolveComponent("el-collapse"),o=vue.resolveComponent("el-scrollbar"),r=vue.resolveComponent("el-tab-pane"),t=vue.resolveComponent("el-tabs");return vue.openBlock(),vue.createBlock(t,{modelValue:b.value,"onUpdate:modelValue":a[0]||(a[0]=i=>b.value=i),style:{padding:"4px"}},{default:vue.withCtx(()=>[vue.createVNode(r,{label:"基础组件库",name:"base"},{default:vue.withCtx(()=>[vue.createVNode(o,{style:{flex:"1"}},{default:vue.withCtx(()=>[vue.createVNode(s,{class:"widget-collapse"},{default:vue.withCtx(()=>[(vue.openBlock(!0),vue.createElementBlock(vue.Fragment,null,vue.renderList(vue.unref(E),(i,c)=>(vue.openBlock(),vue.createBlock(n,{title:i.name,name:i.name},{default:vue.withCtx(()=>[vue.createVNode(vue.unref(draggable),vue.mergeProps({tag:"ul",list:i.components,ref_for:!0},{group:{name:"people",pull:"clone",put:!1},sort:!1},{"item-key":"key",onStart:h=>C(),clone:vue.unref(d)}),{item:vue.withCtx(({element:h})=>[h.display!==!1?(vue.openBlock(),vue.createElementBlock("li",{key:0,class:"widget-item",title:vue.unref(u)("components.fields."+h.type),"data-draggable":"true",draggable:"false",style:{}},[vue.createElementVNode("span",null,[vue.createVNode(g,{"icon-class":h.icon,"class-name":"color-svg-icon"},null,8,["icon-class"]),vue.createTextVNode(" "+vue.toDisplayString(vue.unref(u)("components.fields."+h.type)),1)])],8,_hoisted_1$4)):vue.createCommentVNode("",!0)]),_:2},1040,["list","onStart","clone"])]),_:2},1032,["title","name"]))),256))]),_:1})]),_:1})]),_:1}),vue.createVNode(r,{label:"系统组件库",name:"system"},{default:vue.withCtx(()=>[vue.createVNode(o,{style:{flex:"1"}})]),_:1})]),_:1},8,["modelValue"])}}},widgets=_export_sfc(_sfc_main$4,[["__scopeId","data-v-f61b845f"]]),widgets$1=Object.freeze(Object.defineProperty({__proto__:null,default:widgets},Symbol.toStringTag,{value:"Module"})),_hoisted_1$3={class:"form-designer"},_hoisted_2$3={class:"toolbar-container"},_hoisted_3$2={class:"right-toolbar",style:{float:"right",display:"flex","line-height":"42px"}},_hoisted_4$2={class:"right-toolbar-con"},_hoisted_5$2={class:"dialog-footer"},_sfc_main$3={__name:"designer",props:vue.mergeModels({mode:{type:String,default:()=>"edit"}},{conf:{type:Object,default:()=>{}},confModifiers:{}}),emits:["update:conf"],setup(e){const u=vue.useModel(e,"conf"),l=vue.ref(null),d=vue.ref(null),E=vue.ref(""),b=vue.ref({fontSize:"14px",showPrintMargin:!1,enableLiveAutocompletion:!0}),C=vue.ref(!1),A=()=>{E.value=JSON.stringify(u.value,null,2),C.value=!0},a=()=>{u.value=JSON.parse(E.value),C.value=!1},g=vue.ref({}),n=vue.ref(!1),s=()=>{g.value=JSON.parse(JSON.stringify(u.value)),n.value=!0};return vue.onMounted(()=>{}),vue.provide("renderConf",u),vue.provide("designerRender",d),(o,r)=>{const t=vue.resolveComponent("sy-widgets"),i=vue.resolveComponent("el-aside"),c=vue.resolveComponent("el-button"),h=vue.resolveComponent("el-button-group"),f=vue.resolveComponent("el-header"),v=vue.resolveComponent("sy-render"),p=vue.resolveComponent("el-scrollbar"),y=vue.resolveComponent("el-main"),m=vue.resolveComponent("el-container"),$=vue.resolveComponent("el-dialog");return vue.openBlock(),vue.createElementBlock("div",_hoisted_1$3,[vue.createVNode(m,null,{default:vue.withCtx(()=>[vue.createVNode(i,{class:"aside-component",style:{display:"flex","flex-direction":"column"}},{default:vue.withCtx(()=>[vue.createVNode(t)]),_:1}),vue.createVNode(m,{direction:"vertical",style:{"min-width":"500px"}},{default:vue.withCtx(()=>[vue.createVNode(f,{style:{height:"42px",padding:"0 8px"}},{default:vue.withCtx(()=>[vue.createElementVNode("div",_hoisted_2$3,[vue.createElementVNode("div",_hoisted_3$2,[vue.createElementVNode("div",_hoisted_4$2,[vue.createVNode(h,{style:{"margin-right":"4px"}},{default:vue.withCtx(()=>[vue.createVNode(c,{type:"primary",icon:"el-icon-edit",onClick:A},{default:vue.withCtx(()=>r[7]||(r[7]=[vue.createTextVNode("编辑JSON")])),_:1}),vue.createVNode(c,{type:"primary",icon:"el-icon-edit",onClick:s},{default:vue.withCtx(()=>r[8]||(r[8]=[vue.createTextVNode("预览")])),_:1})]),_:1}),vue.createVNode(h,null,{default:vue.withCtx(()=>[vue.createVNode(c,{type:"primary",icon:"el-icon-delete"},{default:vue.withCtx(()=>r[9]||(r[9]=[vue.createTextVNode("清空")])),_:1})]),_:1})])])])]),_:1}),vue.createVNode(y,{style:{padding:"0px"}},{default:vue.withCtx(()=>[vue.createVNode(p,null,{default:vue.withCtx(()=>[vue.createVNode(v,{ref_key:"designerRender",ref:d,conf:u.value,mode:e.mode,active:l.value,"onUpdate:active":r[0]||(r[0]=N=>l.value=N)},null,8,["conf","mode","active"])]),_:1})]),_:1})]),_:1}),vue.createVNode(i,null,{default:vue.withCtx(()=>[vue.createVNode(Settings,{conf:l.value,"onUpdate:conf":r[1]||(r[1]=N=>l.value=N),form:u.value.formConfig,"onUpdate:form":r[2]||(r[2]=N=>u.value.formConfig=N)},null,8,["conf","form"])]),_:1})]),_:1}),vue.createVNode($,{title:"编辑JSON",modelValue:C.value,"onUpdate:modelValue":r[5]||(r[5]=N=>C.value=N)},{footer:vue.withCtx(()=>[vue.createElementVNode("div",_hoisted_5$2,[vue.createVNode(c,{onClick:r[4]||(r[4]=N=>C.value=!1)},{default:vue.withCtx(()=>r[10]||(r[10]=[vue.createTextVNode("取消")])),_:1}),vue.createVNode(c,{type:"primary",onClick:a},{default:vue.withCtx(()=>r[11]||(r[11]=[vue.createTextVNode("确定")])),_:1})])]),default:vue.withCtx(()=>[vue.createVNode(_sfc_main$7,{lang:"json",options:b.value,modelValue:E.value,"onUpdate:modelValue":r[3]||(r[3]=N=>E.value=N)},null,8,["options","modelValue"])]),_:1},8,["modelValue"]),vue.createVNode($,{title:"表单预览",modelValue:n.value,"onUpdate:modelValue":r[6]||(r[6]=N=>n.value=N)},{default:vue.withCtx(()=>[n.value?(vue.openBlock(),vue.createBlock(v,{key:0,conf:g.value,mode:"view"},null,8,["conf"])):vue.createCommentVNode("",!0)]),_:1},8,["modelValue"])])}}},designer=Object.freeze(Object.defineProperty({__proto__:null,default:_sfc_main$3},Symbol.toStringTag,{value:"Module"})),Mode={CONTAIN:{name:"contain",icon:"FullScreen"},ORIGINAL:{name:"original",icon:"ScaleToOriginal"}},_hoisted_1$2={class:"x-image-viewer__wrapper"},_hoisted_2$2={key:1,class:"x-image-viewer__btn x-image-viewer__desc"},_hoisted_3$1={class:"x-image-viewer__btn x-image-viewer__actions"},_hoisted_4$1={class:"x-image-viewer__actions__inner"},_hoisted_5$1=["src"],mousewheelEventName="mousewheel",_sfc_main$2={__name:"index",props:{urls:{type:Array,default:()=>[]},zIndex:{type:Number,default:9e3},initialIndex:{type:Number,default:0},infinite:{type:Boolean,default:!0},hideOnClickModal:{type:Boolean,default:!1},animateClass:{type:String,default:"fadeInDown"}},emits:["close","change"],setup(e,{emit:u}){const l=e,d=u;let E=null;const b=vue.ref(!0),C=vue.ref(!1),A=vue.ref(l.initialIndex),a=vue.ref(null),g=vue.ref(Mode.CONTAIN),n=vue.ref({scale:1,deg:0,offsetX:0,offsetY:0,rotateX:0,rotateY:0,enableTransition:!1}),s=vue.computed(()=>{const{urls:_}=l;return _.length<=1}),o=vue.computed(()=>A.value===0),r=vue.computed(()=>A.value===0),t=vue.computed(()=>l.urls[A.value]),i=vue.computed(()=>{const{scale:_,deg:T,offsetX:k,offsetY:R,rotateX:D,rotateY:V,enableTransition:B}=n.value,F={transform:`scale(${_}) rotate(${T}deg) rotateX(${D}deg) rotateY(${V}deg)`,transition:B?"transform .3s":"",marginLeft:`${k}px`,marginTop:`${R}px`};return g.value.name===Mode.CONTAIN.name&&(F.maxWidth="100%",F.maxHeight="100%"),F});function c(){d("close")}function h(){b.value=!1,C.value=!0}function f(){b.value=!1}function v(_){let T=!1;return function(...k){T||(T=!0,window.requestAnimationFrame(()=>{_.apply(this,k),T=!1}))}}const p=function(_,T,k,R=!1){_&&T&&k&&_.addEventListener(T,k,R)},y=function(_,T,k,R=!1){_&&T&&k&&_.removeEventListener(T,k,R)};function m(_){if(b.value||_.button!==0)return;const{offsetX:T,offsetY:k}=n.value,R=_.pageX,D=_.pageY;E=v(V=>{n.value={...n.value,offsetX:T+V.pageX-R,offsetY:k+V.pageY-D}}),p(document,"mousemove",E),p(document,"mouseup",()=>{y(document,"mousemove",E)}),_.preventDefault()}function $(){n.value={scale:1,deg:0,offsetX:0,offsetY:0,enableTransition:!1,rotateX:0,rotateY:0}}function N(_,T={}){if(b.value)return;const{zoomRate:k,rotateDeg:R,rotateXDeg:D,rotateYDeg:V,enableTransition:B}={zoomRate:.2,rotateDeg:90,rotateXDeg:180,rotateYDeg:180,enableTransition:!0,...T};if(_==="zoomOut")n.value.scale>.2&&(n.value.scale=parseFloat((n.value.scale-k).toFixed(3)));else if(_==="zoomIn")n.value.scale=parseFloat((n.value.scale+k).toFixed(3));else if(_==="clocelise")n.value.deg+=R;else if(_==="anticlocelise")n.value.deg-=R;else if(_==="fliphorizontal"){let F=n.value.deg!=0&&Math.abs(n.value.deg)/R%2!=0?"rotateX":"rotateY";n.value[F]=n.value[F]?0:V}else if(_==="flipvertical"){let F=n.value.deg!=0&&Math.abs(n.value.deg)/R%2!=0?"rotateY":"rotateX";n.value[F]=n.value[F]?0:D}n.value.enableTransition=B}function M(){if(b.value)return;const _=Object.keys(Mode),T=Object.values(Mode),k=g.value.name,D=(T.findIndex(V=>V.name===k)+1)%_.length;g.value=Mode[_[D]],$()}function S(){if(o.value&&!l.infinite)return;const _=l.urls.length;A.value=(A.value-1+_)%_,C.value=!1}function O(){if(r.value&&!l.infinite)return;const _=l.urls.length;A.value=(A.value+1)%_,C.value=!1}let x=null,L=null;const I=()=>{x=v(T=>{switch(T.keyCode){case 27:c();break;case 32:M();break;case 37:this.prev();break;case 38:N("zoomIn");break;case 39:this.next();break;case 40:N("zoomOut");break}});let _=v(T=>{(T.wheelDelta?T.wheelDelta:-T.detail)>0?N("zoomIn",{zoomRate:.09,enableTransition:!1}):N("zoomOut",{zoomRate:.09,enableTransition:!1})});p(document,"keydown",x),p(document,mousewheelEventName,_)},w=()=>{y(document,"keydown",x),y(document,mousewheelEventName,L),x=null,L=null};return vue.watch(t,()=>{vue.nextTick(()=>{a.value.complete||(b.value=!0)})}),vue.watch(A,_=>{$(),d("change",_)}),vue.onMounted(()=>{vue.nextTick(()=>{const _=document.querySelector("body");_.append?_.append(document.getElementById("x-image-viewer")):_.appendChild(document.getElementById("x-image-viewer")),I()})}),vue.onUnmounted(()=>{document.querySelector("body").removeChild(document.getElementById("x-image-viewer")),w()}),(_,T)=>{const k=vue.resolveComponent("Close"),R=vue.resolveComponent("el-icon"),D=vue.resolveComponent("ZoomOut"),V=vue.resolveComponent("ZoomIn"),B=vue.resolveComponent("RefreshLeft"),F=vue.resolveComponent("RefreshRight"),H=vue.resolveComponent("Switch"),U=vue.resolveComponent("Sort");return vue.openBlock(),vue.createElementBlock("template",null,[vue.createElementVNode("div",{id:"x-image-viewer",class:"x-image-viewer",style:vue.normalizeStyle({zIndex:e.zIndex})},[vue.createElementVNode("div",_hoisted_1$2,[vue.createElementVNode("div",{class:"x-image-viewer__mask",onClick:T[0]||(T[0]=vue.withModifiers(z=>e.hideOnClickModal&&c(),["self"]))}),vue.createElementVNode("span",{class:"x-image-viewer__btn x-image-viewer__close",onClick:c},[vue.createVNode(R,null,{default:vue.withCtx(()=>[vue.createVNode(k)]),_:1})]),s.value?vue.createCommentVNode("",!0):(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:0},[vue.createElementVNode("span",{class:vue.normalizeClass(["x-image-viewer__btn x-image-viewer__prev",{"is-disabled":!e.infinite&&o.value}]),onClick:S},T[7]||(T[7]=[vue.createElementVNode("i",{class:"el-icon-arrow-left"},null,-1)]),2),vue.createElementVNode("span",{class:vue.normalizeClass(["x-image-viewer__btn x-image-viewer__next",{"is-disabled":!e.infinite&&r.value}]),onClick:O},T[8]||(T[8]=[vue.createElementVNode("i",{class:"el-icon-arrow-right"},null,-1)]),2)],64)),t.value.desc?(vue.openBlock(),vue.createElementBlock("div",_hoisted_2$2,vue.toDisplayString(t.value.desc),1)):vue.createCommentVNode("",!0),vue.createElementVNode("div",_hoisted_3$1,[vue.createElementVNode("div",_hoisted_4$1,[vue.createVNode(R,{onClick:T[1]||(T[1]=z=>N("zoomOut"))},{default:vue.withCtx(()=>[vue.createVNode(D)]),_:1}),vue.createVNode(R,{onClick:T[2]||(T[2]=z=>N("zoomIn"))},{default:vue.withCtx(()=>[vue.createVNode(V)]),_:1}),T[9]||(T[9]=vue.createElementVNode("i",{class:"x-image-viewer__actions__divider"},null,-1)),vue.createVNode(R,{onClick:M},{default:vue.withCtx(()=>[(vue.openBlock(),vue.createBlock(vue.resolveDynamicComponent(g.value.icon)))]),_:1}),T[10]||(T[10]=vue.createElementVNode("i",{class:"x-image-viewer__actions__divider"},null,-1)),vue.createVNode(R,{onClick:T[3]||(T[3]=z=>N("anticlocelise"))},{default:vue.withCtx(()=>[vue.createVNode(B)]),_:1}),vue.createVNode(R,{onClick:T[4]||(T[4]=z=>N("clocelise"))},{default:vue.withCtx(()=>[vue.createVNode(F)]),_:1}),vue.createVNode(R,{onClick:T[5]||(T[5]=z=>N("fliphorizontal"))},{default:vue.withCtx(()=>[vue.createVNode(H)]),_:1}),vue.createVNode(R,{onClick:T[6]||(T[6]=z=>N("flipvertical"))},{default:vue.withCtx(()=>[vue.createVNode(U)]),_:1})])]),vue.createElementVNode("div",{class:vue.normalizeClass(["x-image-viewer__canvas opacity-hide",[C.value===!0?"opacity-show animated "+e.animateClass:""]])},[(vue.openBlock(!0),vue.createElementBlock(vue.Fragment,null,vue.renderList(e.urls,(z,K)=>vue.withDirectives((vue.openBlock(),vue.createElementBlock("img",{ref_for:!0,ref_key:"img",ref:a,key:z,src:t.value.src,style:vue.normalizeStyle(i.value),class:"x-image-viewer__img",onLoad:h,onError:f,onMousedown:m},null,44,_hoisted_5$1)),[[vue.vShow,K===A.value]])),128))],2)])],4)])}}},index$4=_export_sfc(_sfc_main$2,[["__scopeId","data-v-1a9d3431"]]),index$5=Object.freeze(Object.defineProperty({__proto__:null,default:index$4},Symbol.toStringTag,{value:"Module"}));var sparkMd5={exports:{}},hasRequiredSparkMd5;function requireSparkMd5(){return hasRequiredSparkMd5||(hasRequiredSparkMd5=1,function(e,u){(function(l){e.exports=l()})(function(l){var d=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"];function E(h,f){var v=h[0],p=h[1],y=h[2],m=h[3];v+=(p&y|~p&m)+f[0]-680876936|0,v=(v<<7|v>>>25)+p|0,m+=(v&p|~v&y)+f[1]-389564586|0,m=(m<<12|m>>>20)+v|0,y+=(m&v|~m&p)+f[2]+606105819|0,y=(y<<17|y>>>15)+m|0,p+=(y&m|~y&v)+f[3]-1044525330|0,p=(p<<22|p>>>10)+y|0,v+=(p&y|~p&m)+f[4]-176418897|0,v=(v<<7|v>>>25)+p|0,m+=(v&p|~v&y)+f[5]+1200080426|0,m=(m<<12|m>>>20)+v|0,y+=(m&v|~m&p)+f[6]-1473231341|0,y=(y<<17|y>>>15)+m|0,p+=(y&m|~y&v)+f[7]-45705983|0,p=(p<<22|p>>>10)+y|0,v+=(p&y|~p&m)+f[8]+1770035416|0,v=(v<<7|v>>>25)+p|0,m+=(v&p|~v&y)+f[9]-1958414417|0,m=(m<<12|m>>>20)+v|0,y+=(m&v|~m&p)+f[10]-42063|0,y=(y<<17|y>>>15)+m|0,p+=(y&m|~y&v)+f[11]-1990404162|0,p=(p<<22|p>>>10)+y|0,v+=(p&y|~p&m)+f[12]+1804603682|0,v=(v<<7|v>>>25)+p|0,m+=(v&p|~v&y)+f[13]-40341101|0,m=(m<<12|m>>>20)+v|0,y+=(m&v|~m&p)+f[14]-1502002290|0,y=(y<<17|y>>>15)+m|0,p+=(y&m|~y&v)+f[15]+1236535329|0,p=(p<<22|p>>>10)+y|0,v+=(p&m|y&~m)+f[1]-165796510|0,v=(v<<5|v>>>27)+p|0,m+=(v&y|p&~y)+f[6]-1069501632|0,m=(m<<9|m>>>23)+v|0,y+=(m&p|v&~p)+f[11]+643717713|0,y=(y<<14|y>>>18)+m|0,p+=(y&v|m&~v)+f[0]-373897302|0,p=(p<<20|p>>>12)+y|0,v+=(p&m|y&~m)+f[5]-701558691|0,v=(v<<5|v>>>27)+p|0,m+=(v&y|p&~y)+f[10]+38016083|0,m=(m<<9|m>>>23)+v|0,y+=(m&p|v&~p)+f[15]-660478335|0,y=(y<<14|y>>>18)+m|0,p+=(y&v|m&~v)+f[4]-405537848|0,p=(p<<20|p>>>12)+y|0,v+=(p&m|y&~m)+f[9]+568446438|0,v=(v<<5|v>>>27)+p|0,m+=(v&y|p&~y)+f[14]-1019803690|0,m=(m<<9|m>>>23)+v|0,y+=(m&p|v&~p)+f[3]-187363961|0,y=(y<<14|y>>>18)+m|0,p+=(y&v|m&~v)+f[8]+1163531501|0,p=(p<<20|p>>>12)+y|0,v+=(p&m|y&~m)+f[13]-1444681467|0,v=(v<<5|v>>>27)+p|0,m+=(v&y|p&~y)+f[2]-51403784|0,m=(m<<9|m>>>23)+v|0,y+=(m&p|v&~p)+f[7]+1735328473|0,y=(y<<14|y>>>18)+m|0,p+=(y&v|m&~v)+f[12]-1926607734|0,p=(p<<20|p>>>12)+y|0,v+=(p^y^m)+f[5]-378558|0,v=(v<<4|v>>>28)+p|0,m+=(v^p^y)+f[8]-2022574463|0,m=(m<<11|m>>>21)+v|0,y+=(m^v^p)+f[11]+1839030562|0,y=(y<<16|y>>>16)+m|0,p+=(y^m^v)+f[14]-35309556|0,p=(p<<23|p>>>9)+y|0,v+=(p^y^m)+f[1]-1530992060|0,v=(v<<4|v>>>28)+p|0,m+=(v^p^y)+f[4]+1272893353|0,m=(m<<11|m>>>21)+v|0,y+=(m^v^p)+f[7]-155497632|0,y=(y<<16|y>>>16)+m|0,p+=(y^m^v)+f[10]-1094730640|0,p=(p<<23|p>>>9)+y|0,v+=(p^y^m)+f[13]+681279174|0,v=(v<<4|v>>>28)+p|0,m+=(v^p^y)+f[0]-358537222|0,m=(m<<11|m>>>21)+v|0,y+=(m^v^p)+f[3]-722521979|0,y=(y<<16|y>>>16)+m|0,p+=(y^m^v)+f[6]+76029189|0,p=(p<<23|p>>>9)+y|0,v+=(p^y^m)+f[9]-640364487|0,v=(v<<4|v>>>28)+p|0,m+=(v^p^y)+f[12]-421815835|0,m=(m<<11|m>>>21)+v|0,y+=(m^v^p)+f[15]+530742520|0,y=(y<<16|y>>>16)+m|0,p+=(y^m^v)+f[2]-995338651|0,p=(p<<23|p>>>9)+y|0,v+=(y^(p|~m))+f[0]-198630844|0,v=(v<<6|v>>>26)+p|0,m+=(p^(v|~y))+f[7]+1126891415|0,m=(m<<10|m>>>22)+v|0,y+=(v^(m|~p))+f[14]-1416354905|0,y=(y<<15|y>>>17)+m|0,p+=(m^(y|~v))+f[5]-57434055|0,p=(p<<21|p>>>11)+y|0,v+=(y^(p|~m))+f[12]+1700485571|0,v=(v<<6|v>>>26)+p|0,m+=(p^(v|~y))+f[3]-1894986606|0,m=(m<<10|m>>>22)+v|0,y+=(v^(m|~p))+f[10]-1051523|0,y=(y<<15|y>>>17)+m|0,p+=(m^(y|~v))+f[1]-2054922799|0,p=(p<<21|p>>>11)+y|0,v+=(y^(p|~m))+f[8]+1873313359|0,v=(v<<6|v>>>26)+p|0,m+=(p^(v|~y))+f[15]-30611744|0,m=(m<<10|m>>>22)+v|0,y+=(v^(m|~p))+f[6]-1560198380|0,y=(y<<15|y>>>17)+m|0,p+=(m^(y|~v))+f[13]+1309151649|0,p=(p<<21|p>>>11)+y|0,v+=(y^(p|~m))+f[4]-145523070|0,v=(v<<6|v>>>26)+p|0,m+=(p^(v|~y))+f[11]-1120210379|0,m=(m<<10|m>>>22)+v|0,y+=(v^(m|~p))+f[2]+718787259|0,y=(y<<15|y>>>17)+m|0,p+=(m^(y|~v))+f[9]-343485551|0,p=(p<<21|p>>>11)+y|0,h[0]=v+h[0]|0,h[1]=p+h[1]|0,h[2]=y+h[2]|0,h[3]=m+h[3]|0}function b(h){var f=[],v;for(v=0;v<64;v+=4)f[v>>2]=h.charCodeAt(v)+(h.charCodeAt(v+1)<<8)+(h.charCodeAt(v+2)<<16)+(h.charCodeAt(v+3)<<24);return f}function C(h){var f=[],v;for(v=0;v<64;v+=4)f[v>>2]=h[v]+(h[v+1]<<8)+(h[v+2]<<16)+(h[v+3]<<24);return f}function A(h){var f=h.length,v=[1732584193,-271733879,-1732584194,271733878],p,y,m,$,N,M;for(p=64;p<=f;p+=64)E(v,b(h.substring(p-64,p)));for(h=h.substring(p-64),y=h.length,m=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],p=0;p<y;p+=1)m[p>>2]|=h.charCodeAt(p)<<(p%4<<3);if(m[p>>2]|=128<<(p%4<<3),p>55)for(E(v,m),p=0;p<16;p+=1)m[p]=0;return $=f*8,$=$.toString(16).match(/(.*?)(.{0,8})$/),N=parseInt($[2],16),M=parseInt($[1],16)||0,m[14]=N,m[15]=M,E(v,m),v}function a(h){var f=h.length,v=[1732584193,-271733879,-1732584194,271733878],p,y,m,$,N,M;for(p=64;p<=f;p+=64)E(v,C(h.subarray(p-64,p)));for(h=p-64<f?h.subarray(p-64):new Uint8Array(0),y=h.length,m=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],p=0;p<y;p+=1)m[p>>2]|=h[p]<<(p%4<<3);if(m[p>>2]|=128<<(p%4<<3),p>55)for(E(v,m),p=0;p<16;p+=1)m[p]=0;return $=f*8,$=$.toString(16).match(/(.*?)(.{0,8})$/),N=parseInt($[2],16),M=parseInt($[1],16)||0,m[14]=N,m[15]=M,E(v,m),v}function g(h){var f="",v;for(v=0;v<4;v+=1)f+=d[h>>v*8+4&15]+d[h>>v*8&15];return f}function n(h){var f;for(f=0;f<h.length;f+=1)h[f]=g(h[f]);return h.join("")}n(A("hello")),typeof ArrayBuffer<"u"&&!ArrayBuffer.prototype.slice&&function(){function h(f,v){return f=f|0||0,f<0?Math.max(f+v,0):Math.min(f,v)}ArrayBuffer.prototype.slice=function(f,v){var p=this.byteLength,y=h(f,p),m=p,$,N,M,S;return v!==l&&(m=h(v,p)),y>m?new ArrayBuffer(0):($=m-y,N=new ArrayBuffer($),M=new Uint8Array(N),S=new Uint8Array(this,y,$),M.set(S),N)}}();function s(h){return/[\u0080-\uFFFF]/.test(h)&&(h=unescape(encodeURIComponent(h))),h}function o(h,f){var v=h.length,p=new ArrayBuffer(v),y=new Uint8Array(p),m;for(m=0;m<v;m+=1)y[m]=h.charCodeAt(m);return f?y:p}function r(h){return String.fromCharCode.apply(null,new Uint8Array(h))}function t(h,f,v){var p=new Uint8Array(h.byteLength+f.byteLength);return p.set(new Uint8Array(h)),p.set(new Uint8Array(f),h.byteLength),p}function i(h){var f=[],v=h.length,p;for(p=0;p<v-1;p+=2)f.push(parseInt(h.substr(p,2),16));return String.fromCharCode.apply(String,f)}function c(){this.reset()}return c.prototype.append=function(h){return this.appendBinary(s(h)),this},c.prototype.appendBinary=function(h){this._buff+=h,this._length+=h.length;var f=this._buff.length,v;for(v=64;v<=f;v+=64)E(this._hash,b(this._buff.substring(v-64,v)));return this._buff=this._buff.substring(v-64),this},c.prototype.end=function(h){var f=this._buff,v=f.length,p,y=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],m;for(p=0;p<v;p+=1)y[p>>2]|=f.charCodeAt(p)<<(p%4<<3);return this._finish(y,v),m=n(this._hash),h&&(m=i(m)),this.reset(),m},c.prototype.reset=function(){return this._buff="",this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},c.prototype.getState=function(){return{buff:this._buff,length:this._length,hash:this._hash.slice()}},c.prototype.setState=function(h){return this._buff=h.buff,this._length=h.length,this._hash=h.hash,this},c.prototype.destroy=function(){delete this._hash,delete this._buff,delete this._length},c.prototype._finish=function(h,f){var v=f,p,y,m;if(h[v>>2]|=128<<(v%4<<3),v>55)for(E(this._hash,h),v=0;v<16;v+=1)h[v]=0;p=this._length*8,p=p.toString(16).match(/(.*?)(.{0,8})$/),y=parseInt(p[2],16),m=parseInt(p[1],16)||0,h[14]=y,h[15]=m,E(this._hash,h)},c.hash=function(h,f){return c.hashBinary(s(h),f)},c.hashBinary=function(h,f){var v=A(h),p=n(v);return f?i(p):p},c.ArrayBuffer=function(){this.reset()},c.ArrayBuffer.prototype.append=function(h){var f=t(this._buff.buffer,h),v=f.length,p;for(this._length+=h.byteLength,p=64;p<=v;p+=64)E(this._hash,C(f.subarray(p-64,p)));return this._buff=p-64<v?new Uint8Array(f.buffer.slice(p-64)):new Uint8Array(0),this},c.ArrayBuffer.prototype.end=function(h){var f=this._buff,v=f.length,p=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],y,m;for(y=0;y<v;y+=1)p[y>>2]|=f[y]<<(y%4<<3);return this._finish(p,v),m=n(this._hash),h&&(m=i(m)),this.reset(),m},c.ArrayBuffer.prototype.reset=function(){return this._buff=new Uint8Array(0),this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},c.ArrayBuffer.prototype.getState=function(){var h=c.prototype.getState.call(this);return h.buff=r(h.buff),h},c.ArrayBuffer.prototype.setState=function(h){return h.buff=o(h.buff,!0),c.prototype.setState.call(this,h)},c.ArrayBuffer.prototype.destroy=c.prototype.destroy,c.ArrayBuffer.prototype._finish=c.prototype._finish,c.ArrayBuffer.hash=function(h,f){var v=a(new Uint8Array(h)),p=n(v);return f?i(p):p},c})}(sparkMd5)),sparkMd5.exports}var sparkMd5Exports=requireSparkMd5();const SparkMD5=getDefaultExportFromCjs(sparkMd5Exports);function getBase64ImageSize(e){const u=e.indexOf("base64,");return u<0?-1:(e.substr(u+6).length*.75).toFixed(2)}function base64toFile(e,u,l){let d=atob(e),E=d.length,b=new Uint8Array(E);for(;E--;)b[E]=d.charCodeAt(E);return new File([b],u,{type:l})}function compressedImage(e,u,l,d,E=0,b=null,C=null){let A=new Image;A.src=e,A.onload=function(){const a=this;let g=a.width*((u==null?void 0:u.ratio)||1),n=a.height*((u==null?void 0:u.ratio)||1),s=g/n;g=u.width||g,n=u.height&&u.height*(g/s)||n;let o=document.createElement("canvas"),r=o.getContext("2d");o.width=g,o.height=n,r.drawImage(a,0,0,g,n);let t=.9;u.quality&&u.quality>0&&u.quality<=1&&(t=u.quality);let i=o.toDataURL("image/jpeg",t),c=getBase64ImageSize(i);if(console.log(c),E<=b){C===null&&(C=t);const h=[],f=.01;for(let p=f;p<=C;p+=f)h.push(parseFloat(p));b===null&&(b=h.length);const v=Math.floor((E+b)/2);c>l?compressedImage(e,{quality:h[v],ratio:.5},l,d,E,v-1,C):compressedImage(e,{quality:h[v],ratio:1},l,d,v+1,b,C);return}d&&d(base64toFile(i.split(",")[1],"compress.jpg","image/jpeg"))}}function useOssUploader(e,u,l={fileType:[],requireMd5:!1,request:null,signatureUrl:"",addFileMd5Url:"",queryFileMd5Url:""}){let d=1;const E=async function(g){let n=g.url;if(g.objUrl)return g.objUrl;if(!g.loading)return g.loading=!0,await axios({method:"GET",url:n,responseType:"blob",onDownloadProgress:s=>{let o=s.total>0?s.loaded/s.total*100:0;g.loadingPercent=isNaN(o)?0:o}}).then(s=>{const{data:o,headers:r}=s;g.objUrl=URL.createObjectURL(o);let t=new Image;t.src=g.objUrl,t.onload=()=>{g.width=t.width,g.height=t.height,g.viewBox=[0,0,g.width,g.height],g.matrix=[[1,0],[0,1],[0,0]],g.loading=!1}}).catch(()=>{g.loading=!1})},b=async function(g){return await l.request({method:"GET",url:`${l.signatureUrl}${g}`})},C=async function(g){return await l.request({method:"POST",url:`${l.addFileMd5Url}`,data:g})},A=async function(g){return await l.request({method:"GET",url:`${l.queryFileMd5Url}`,params:g})};let a=vue.reactive({fileList:u||[],onHttpRequest:async g=>{const{action:n,file:s,onProgress:o,onSuccess:r,onError:t}=g;let i=await b(s.name);if(i.code!==200)throw new Error("Get signature error");const c=i.data,{accessid:h,policy:f,signature:v,dir:p,host:y}=c;let m=new FormData;return m.append("key",p),m.append("policy",f),m.append("OSSAccessKeyId",h),m.append("success_action_status","200"),m.append("signature",v),m.append("file",s),await axios.create({onUploadProgress:N=>{N.percent=N.total>0?N.loaded/N.total*100:0,o(N)}}).post(y,m,{headers:{"Content-Type":"multipart/form-data"}}).then(N=>({code:200,fileName:y+p}))},onBeforeUpload:g=>new Promise((n,s)=>{let o=new Promise(r=>{r(!0)});o=o.then(r=>new Promise(t=>{a.md5({raw:g}).then(i=>{t(i)})})),l.requireMd5&&(o=o.then(r=>A({mdaValue:r}).then(t=>{if(t.rows.length){let i={name:t.rows[0].filePath,url:t.rows[0].filePath};throw i.uid=i.uid||d++,i.status="success",a.fileList.push(i),a.fileList.map(c=>{E(c)}),new Error("文件已存在")}else return g.md5=r,!0}))),o=o.then(r=>/^image\/\w+/.test(g.type)?new Promise((t,i)=>{compressedImage(URL.createObjectURL(g),{},1*1024*1024,c=>{let h=a.fileList.filter(f=>f.raw&&f.raw==g)[0];h?(c.md5=h.raw.md5||null,h.raw=c,t(h.raw)):i()})}):!0),o.then(r=>{n(r)}).catch(r=>{s(!1)})}),onChange:(g,n)=>{if(console.log("onChange:"+g.status),g.status=="ready"){if(l.fileType&&l.fileType.length>0&&l.fileType.indexOf(g.name.split(".").pop().toLocaleLowerCase())==-1)throw n.splice(n.indexOf(g),1),ElMessage.error(`文件格式不正确, 请上传${l.fileType.join("/")}格式文件!`),new Error("文件格式不正确");g.uid=g.uid||d++}else g.status=="success"&&(g.url=g.response.fileName,E(g),l.requireMd5&&C({filePath:g.url,mdaValue:g.raw.md5}))},init:function(g){g=g||"",a.fileList=(Array.isArray(g)?g:g.length?g.split(","):[]).map(n=>(typeof n=="string"&&(n={name:n,url:n}),n.uid=n.uid||new Date().getTime()+d++,n.status="success",n)),a.fileList.map(n=>{E(n)})},md5(g){return new Promise((n,s)=>{const o=g.raw,t=Math.ceil(o.size/10),i=new FileReader,c=new SparkMD5;let h=0;const f=()=>{const v=o.slice(h,h+t);i.readAsBinaryString(v)};i.onload=v=>{c.appendBinary(v.target.result),h<o.size?(h+=t,f()):n(c.end())},f()})},previewDownload:g=>{let n=document.createElement("a");n.download=g.name,n.href=g.url,n.click(),window.URL.revokeObjectURL(n.href)}});return a.init(e),[a]}const _hoisted_1$1={class:"component-upload-image"},_hoisted_2$1={style:{display:"flex",width:"100%"}},_hoisted_3={key:0,class:"relative rounded overflow-hidden flex justify-center items-center",style:{width:"120px",height:"96px","margin-top":"8px"}},_hoisted_4={key:0,class:"absolute"},_hoisted_5={key:1,class:"absolute"},_hoisted_6=["onClick"],_hoisted_7={class:"relative overflow-hidden flex flex-col justify-center items-center w-full h-full select-none outline-none"},_hoisted_8=["src"],_hoisted_9=["viewBox"],_hoisted_10=["transform"],_hoisted_11=["xlink:href","width","height"],_hoisted_12={class:"photo-operations"},_hoisted_13={class:"absolute top-0 right-0 w-full flex justify-end gap-1"},_hoisted_14={class:"opacity-[0.7] hover:opacity-[1] rounded-1/2"},_hoisted_15={class:"opacity-[0.7] hover:opacity-[1] rounded-1/2"},_hoisted_16={class:"absolute bottom-0 w-full flex justify-center gap-1"},_hoisted_17={class:"opacity-[0.7] hover:opacity-[1] rounded-1/2"},_hoisted_18={class:"opacity-[0.7] hover:opacity-[1] rounded-1/2"},_hoisted_19={key:0,class:"el-upload__tip"},_hoisted_20={style:{color:"#f56c6c"}},_hoisted_21={style:{color:"#f56c6c"}},_hoisted_22=["src"],_sfc_main$1={__name:"index",props:{modelValue:[String,Object,Array],multipleSelect:{type:Boolean,default:!0},limit:{type:Number,default:5},fileMaxSize:{type:Number,default:5},fileType:{type:Array,default:()=>["png","jpg","jpeg","raw","tiff","jfif"]},isShowTip:{type:Boolean,default:!0},onDrop:{default:e=>{}},onBackPool:{default:e=>{}},defaultBg:String,disabled:{default:!1},size:{default:()=>({width:"148px",height:"148px"})},view:{type:String,default:null},operations:{default:()=>({back:!1,close:!1,rotateLeft:!1,rotateRight:!1})},md5:{type:Object,default:()=>({requireMd5:!1,addFileMd5Url:"",queryFileMd5Url:""})},oss:{type:Object,default:()=>({signatureUrl:""})}},setup(e,{expose:u,emit:l}){const d=e,E=vue.useAttrs(),b=l;vue.ref(0),vue.ref([]);const C=vue.ref(""),A=vue.ref(!1),a=vue.ref([]),g=vue.computed(()=>d.isShowTip&&(d.fileType||d.fileMaxSize)),n=vue.inject("request"),[s]=useOssUploader("",a,{request:n,fileType:d.fileType,signatureUrl:d.oss.signatureUrl,requireMd5:d.md5.requireMd5,addFileMd5Url:d.md5.addFileMd5Url,queryFileMd5Url:d.md5.queryFileMd5Url}),o=vue.ref(!1),r=vue.ref([]),t=()=>{o.value=!1};function i(){ElMessage.error(`上传文件数量不能超过 ${d.limit} 个!`)}function c(){ElMessage.error("上传图片失败")}function h(w,_){let T="";_=_||",";for(let k in w)w[k].url!==void 0&&w[k].url.indexOf("blob:")!==0&&(T+=w[k].url+_);return T!=""?T.substr(0,T.length-1):""}function f(w){console.log("enter"),w.preventDefault()}function v(w){console.log("over"),w.preventDefault(),setTimeout(()=>{w.target.classList.add("over")},0)}function p(w){console.log("drop"),w.preventDefault(),d.onDrop&&d.onDrop(w)}function y(w){d.onBackPool&&d.onBackPool(w)}function m(w){x(w)}function $(w){r.value=[],r.value.push({src:w.url,desc:""}),o.value=!0}function N(w,_){let T=[];for(let k=0;k<w.length;k++){T[k]=[];for(let R=0;R<_[0].length;R++){let D=0;for(let V=0;V<w[0].length;V++)D+=w[k][V]*_[V][R];T[k][R]=D}}return T}function M(w,_){let T=w.hd=w.hd||0,k=w.vd=w.vd||0,R=w.deg=w.deg||0,D=w.viewBox,V=w.matrix;if(_=="rotateleft"){R+=90;let B=[[Math.cos(90*(Math.PI/180)),-Math.sin(90*(Math.PI/180))],[Math.sin(90*(Math.PI/180)),Math.cos(90*(Math.PI/180))],[0,0]];V=N(V,B),w.viewBox=S(w.hd!=T,w.vd!=k,90,D)}else if(_=="rotateright"){R-=90;let B=[[Math.cos(-90*(Math.PI/180)),-Math.sin(-90*(Math.PI/180))],[Math.sin(-90*(Math.PI/180)),Math.cos(-90*(Math.PI/180))],[0,0]];V=N(V,B),w.viewBox=S(w.hd!=T,w.vd!=k,-90,D)}else _=="fliphorizontal"?(T=T?0:1,V=N(V,[[-1,0],[0,1],[0,0]])):_=="flipvertical"&&(k=k?0:1,V=N(V,[[1,0],[0,-1],[0,0]]));w.matrix=V,w.deg=R,w.hd=T,w.vd=k}function S(w,_,T,k){let R=JSON.parse(JSON.stringify(k));const[D,V,B,F]=k;if(w==!0&&(R[0]=R[0]==0-B?0:0-B),_==!0&&(R[1]=R[1]==0-F?0:0-F),T){let H=T/90%4;for(let U=0;U<Math.abs(H);U++)if(R[2]=F,R[3]=B,T>0){let z=R[1];R[1]=R[0]==0-B?0:0-B,R[0]=z}else{let z=R[1];R[1]=R[0],R[0]=z==0-F?0:0-F}}return R}const O=w=>{a.value.push(w)},x=w=>{a.value.indexOf(w)!=-1&&a.value.splice(a.value.indexOf(w),1)},L=()=>{(a.value.length==0||a.value.every(w=>w.status=="success"))&&b("update:modelValue",Array.isArray(d.modelValue)?a.value:h(a.value))};function I(w,_,T){L()}return vue.watch(()=>d.modelValue,w=>{if(w)s.init(w);else return a.value=[]},{deep:!0,immediate:!0}),vue.watch(()=>a.value.length,()=>{console.log("imageupload filelist changed....."),L()}),u({pushFile:O,removeFile:x}),(w,_)=>{const T=vue.resolveComponent("el-icon"),k=vue.resolveComponent("el-upload"),R=vue.resolveComponent("sy-svg-icon"),D=vue.resolveComponent("el-dialog"),V=vue.resolveComponent("sy-image-view");return vue.openBlock(),vue.createElementBlock("div",_hoisted_1$1,[vue.createElementVNode("div",_hoisted_2$1,[vue.createVNode(k,vue.mergeProps({multiple:e.multipleSelect,ref:"imageUpload","show-file-list":!1,"file-list":a.value,"onUpdate:fileList":_[0]||(_[0]=B=>a.value=B),"http-request":vue.unref(s).onHttpRequest,"list-type":"picture-card",limit:e.limit,"on-success":I,"on-change":vue.unref(s).onChange,"before-upload":vue.unref(s).onBeforeUpload,"on-error":c,"on-exceed":i,class:{hide:a.value.length>=e.limit,disabled:e.disabled},style:"width:"+(a.value.length>=e.limit?"auto":e.size.width)+";height:"+(a.value.length>=e.limit?"auto":e.size.height)+";"},vue.unref(E),{onDragenter:f,onDragover:v,onDrop:p,"auto-upload":!0,disabled:e.disabled}),{default:vue.withCtx(()=>[vue.createElementVNode("div",{style:vue.normalizeStyle([{"background-position":"center","background-repeat":"no-repeat",width:"100%",height:"100%",display:"flex","justify-content":"center","align-items":"center"},e.defaultBg&&e.defaultBg!=""?"background-image:url("+e.defaultBg+");":""])},[!e.defaultBg||e.defaultBg==""?(vue.openBlock(),vue.createBlock(T,{key:0,class:"avatar-uploader-icon"},{default:vue.withCtx(()=>[vue.createVNode(vue.unref(plus_default))]),_:1})):vue.createCommentVNode("",!0)],4)]),_:1},16,["multiple","file-list","http-request","limit","on-change","before-upload","class","style","disabled"]),a.value.length>0?(vue.openBlock(),vue.createElementBlock("div",{key:0,class:vue.normalizeClass(["flex gap-2",{disabled:e.disabled,"ml-2":a.value.length<e.limit}])},[(vue.openBlock(!0),vue.createElementBlock(vue.Fragment,null,vue.renderList(a.value,B=>(vue.openBlock(),vue.createElementBlock("div",{key:B.uid,class:"el-upload--picture-card",style:vue.normalizeStyle("width:"+e.size.width+";height:"+e.size.height+";")},[B.status=="ready"||B.status=="uploading"||B.loading?(vue.openBlock(),vue.createElementBlock("div",_hoisted_3,[vue.createVNode(R,{"class-name":"icon-down","icon-class":"down"}),B.loading?(vue.openBlock(),vue.createElementBlock("div",_hoisted_4,vue.toDisplayString(parseInt(B.loadingPercent||0))+"%",1)):vue.createCommentVNode("",!0),B.status=="uploading"?(vue.openBlock(),vue.createElementBlock("div",_hoisted_5,vue.toDisplayString(parseInt(B.percentage||0))+"%",1)):vue.createCommentVNode("",!0)])):vue.createCommentVNode("",!0),B.status=="success"&&!B.loading?(vue.openBlock(),vue.createElementBlock("div",{key:1,onClick:F=>$(B),class:"w-full h-full relative rounded overflow-hidden file-item"},[vue.createElementVNode("div",_hoisted_7,[e.view=="img"?(vue.openBlock(),vue.createElementBlock("img",{key:0,style:{width:"100%"},src:B.objUrl,fit:"contain"},null,8,_hoisted_8)):(vue.openBlock(),vue.createElementBlock("svg",{key:1,preserveAspectRatio:"xMidYMid meet",width:"100%",height:"100%",viewBox:B.viewBox.join(" "),xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink"},[vue.createElementVNode("g",{class:"origin-top-left preserve-3d",transform:"matrix("+B.matrix.join(",")+")"},[vue.createElementVNode("image",{"xlink:href":B.objUrl,x:"0",y:"0",width:B.width,height:B.height},null,8,_hoisted_11)],8,_hoisted_10)],8,_hoisted_9))]),vue.createElementVNode("div",_hoisted_12,[vue.createElementVNode("div",_hoisted_13,[vue.withDirectives(vue.createElementVNode("div",_hoisted_14,[vue.createVNode(R,{"class-name":"icon-photo","icon-class":"right-arrow",onClick:vue.withModifiers(F=>y(B),["stop"])},null,8,["onClick"])],512),[[vue.vShow,e.operations.back]]),vue.withDirectives(vue.createElementVNode("div",_hoisted_15,[vue.createVNode(R,{"class-name":"icon-photo ","icon-class":"close",onClick:vue.withModifiers(F=>m(B),["stop"])},null,8,["onClick"])],512),[[vue.vShow,e.operations.close]])]),vue.createElementVNode("div",_hoisted_16,[vue.withDirectives(vue.createElementVNode("div",_hoisted_17,[vue.createVNode(R,{"class-name":"icon-photo","icon-class":"right-arrow",onClick:vue.withModifiers(F=>M(B,"rotateleft"),["stop"])},null,8,["onClick"])],512),[[vue.vShow,e.operations.rotateLeft]]),vue.withDirectives(vue.createElementVNode("div",_hoisted_18,[vue.createVNode(R,{"class-name":"icon-photo","icon-class":"right-arrow",onClick:vue.withModifiers(F=>M(B,"rotateright"),["stop"])},null,8,["onClick"])],512),[[vue.vShow,e.operations.rotateRight]])])])],8,_hoisted_6)):vue.createCommentVNode("",!0)],4))),128))],2)):vue.createCommentVNode("",!0)]),g.value?(vue.openBlock(),vue.createElementBlock("div",_hoisted_19,[_[4]||(_[4]=vue.createTextVNode(" 请上传 ")),e.fileMaxSize?(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:0},[_[2]||(_[2]=vue.createTextVNode(" 大小不超过 ")),vue.createElementVNode("b",_hoisted_20,vue.toDisplayString(e.fileMaxSize)+"MB",1)],64)):vue.createCommentVNode("",!0),e.fileType?(vue.openBlock(),vue.createElementBlock(vue.Fragment,{key:1},[_[3]||(_[3]=vue.createTextVNode(" 格式为 ")),vue.createElementVNode("b",_hoisted_21,vue.toDisplayString(e.fileType.join("/")),1)],64)):vue.createCommentVNode("",!0),_[5]||(_[5]=vue.createTextVNode(" 的文件 "))])):vue.createCommentVNode("",!0),vue.createVNode(D,{modelValue:A.value,"onUpdate:modelValue":_[1]||(_[1]=B=>A.value=B),title:"预览",width:"800px","append-to-body":""},{default:vue.withCtx(()=>[vue.createElementVNode("img",{src:C.value,style:{display:"block","max-width":"100%",margin:"0 auto"}},null,8,_hoisted_22)]),_:1},8,["modelValue"]),o.value?(vue.openBlock(),vue.createBlock(V,{key:1,urls:r.value,onClose:t},null,8,["urls"])):vue.createCommentVNode("",!0)])}}},index$2=_export_sfc(_sfc_main$1,[["__scopeId","data-v-b4384b7f"]]),index$3=Object.freeze(Object.defineProperty({__proto__:null,default:index$2},Symbol.toStringTag,{value:"Module"})),_sfc_main={name:"SvgIcon",props:{iconClass:{type:String,required:!0},className:{type:String},title:{type:String,default:""}},computed:{iconName(){return`#icon-${this.iconClass}`},svgClass(){return this.className?"svg-icon "+this.className:"svg-icon"}}},_hoisted_1=["xlink:href"],_hoisted_2={key:0};function _sfc_render(e,u,l,d,E,b){return vue.openBlock(),vue.createElementBlock("svg",{class:vue.normalizeClass(b.svgClass),"aria-hidden":"true"},[vue.createElementVNode("use",{"xlink:href":b.iconName},null,8,_hoisted_1),l.title?(vue.openBlock(),vue.createElementBlock("title",_hoisted_2,vue.toDisplayString(l.title),1)):vue.createCommentVNode("",!0)],2)}const index=_export_sfc(_sfc_main,[["render",_sfc_render],["__scopeId","data-v-f0bfb888"]]),index$1=Object.freeze(Object.defineProperty({__proto__:null,default:index},Symbol.toStringTag,{value:"Module"}));return index$7});