openc3-cosmos-tool-dataextractor 7.1.0 → 7.2.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.
Files changed (108) hide show
  1. checksums.yaml +4 -4
  2. data/tools/dataextractor/ArrayWidget-D1PArcGr-c8c751af5b0b3e9d923d.js +2 -0
  3. data/tools/dataextractor/{ArrayplotWidget-DGJEXAY0-2638e110104829429b7e.js → ArrayplotWidget-DPUPy0qM-b7c3bff83bf418fe0a6f.js} +1 -1
  4. data/tools/dataextractor/{BarColumn-DwZmAe8g-87b5d97eefa9dd364079.js → BarColumn-BpdscDQf-fbde67bf62fa06314272.js} +1 -1
  5. data/tools/dataextractor/{BlockWidget-BHtugveV-3a86c79f29993edbe557.js → BlockWidget-_VUsK5T9-e9ea12442411c894a337.js} +2 -2
  6. data/tools/dataextractor/ButtonWidget-DE41o-cg-c0cf6714bdd559938c90.js +2 -0
  7. data/tools/dataextractor/CanvasWidget-BEi8h3Mq-93b602cbc1f1c3f8a989.js +1 -0
  8. data/tools/dataextractor/CanvasdotWidget-eZuMgkhL-d2239b9c5db9ac121539.js +1 -0
  9. data/tools/dataextractor/{CanvasimageWidget-BpM05v_m-6263bd6847c2e58b6b84.js → CanvasimageWidget-COv_Qnc8-b3b91fba8876839ea74b.js} +1 -1
  10. data/tools/dataextractor/{CanvasimagevalueWidget-E6G93iGc-49d367288d7991a84f17.js → CanvasimagevalueWidget-BhuUqLOo-6673175b5d15945d1698.js} +1 -1
  11. data/tools/dataextractor/CanvaslabelWidget-DtvbgeYH-65b35c16cb83363efca3.js +1 -0
  12. data/tools/dataextractor/{CanvaslabelvalueWidget-B0nJeS4X-b4d8b3e018abcec044ee.js → CanvaslabelvalueWidget-C_FRIeNb-127a95383fbb9d362d05.js} +1 -1
  13. data/tools/dataextractor/CanvaslineWidget-D1K_6mAY-aaa1cc8b5c1e016e8324.js +1 -0
  14. data/tools/dataextractor/{CanvaslinevalueWidget-BwfFyCwH-7997bd44b424ae4b1561.js → CanvaslinevalueWidget-D4eaxWhR-363e4bb482ba7a73ba6a.js} +1 -1
  15. data/tools/dataextractor/CheckbuttonWidget-ByxMDkiS-1d4c199071fc6e719a35.js +1 -0
  16. data/tools/dataextractor/ComboboxWidget-CAGxGv2r-770ba10af28e2ff80127.js +1 -0
  17. data/tools/dataextractor/DataExtractor-2097e7e5aaf43aad6f8b.js +14 -0
  18. data/tools/dataextractor/{DateWidget-CAiG2FIl-c146fb495ef13560c452.js → DateWidget-DkNWx28s-b13f63213d6b9fcb175d.js} +1 -1
  19. data/tools/dataextractor/{DetailsDialog-q5SDzw3R-7c15f8bc9d13be343b4a.js → DetailsDialog-F4KgYM6m-127f043574676725c73b.js} +1 -1
  20. data/tools/dataextractor/{DynamicWidget-BuSbQVhf-86285e64782585bb8284.js → DynamicWidget-BuSbQVhf-55ea1ee13a3afafb3570.js} +1 -1
  21. data/tools/dataextractor/{FilechecksumWidget-DeW9wy5d-248571c63dba27319b36.js → FilechecksumWidget-DSfNEnDJ-4e730e295b0b0aa7d9ad.js} +1 -1
  22. data/tools/dataextractor/{FiledisplayWidget-C_zPFu2E-2d17e2f1448559a44f05.js → FiledisplayWidget-D2cxMmrP-a05420f106f98fc9a1c3.js} +1 -1
  23. data/tools/dataextractor/{FormatvalueWidget-BrvPWwfN-e050d5adc896a68175ca.js → FormatvalueWidget-6-bj_PJO-19133d9392f2b921ec6c.js} +1 -1
  24. data/tools/dataextractor/Graph-Cz0Ns1FD-6ad9d5afe0b9679348e6.js +1 -0
  25. data/tools/dataextractor/{GraphWidget-QS-VJoes-2024d5d6197b125514ef.js → GraphWidget-COXK3Dab-68ed5db39c484c79cd9a.js} +1 -1
  26. data/tools/dataextractor/{HorizontalWidget-cFSsdChw-d979f75547fda5fa7327.js → HorizontalWidget-C9UFBPsk-0c0dd37a884935f911ad.js} +1 -1
  27. data/tools/dataextractor/HorizontalboxWidget-CWLfmRtr-37ef9ec7d67d226af1c4.js +1 -0
  28. data/tools/dataextractor/{HorizontallineWidget-BqbLK0zc-032877ba9a30de523df1.js → HorizontallineWidget-DeFkOaYO-4210d0981cf03ed31819.js} +1 -1
  29. data/tools/dataextractor/{IframeWidget-CITX8Es1-f88b11b4cb0abe9013a6.js → IframeWidget-Bn9eGzrq-4d363d16eda9121de56f.js} +1 -1
  30. data/tools/dataextractor/{ImageLoader-DQV_11Vd-6bd51c2e0e35e48f84d3.js → ImageLoader-_gAudhVo-3d11a63f5ef7091755dc.js} +1 -1
  31. data/tools/dataextractor/{ImageviewerWidget-BIsSA7KD-27ebd6d54624aecc85c5.js → ImageviewerWidget-BUWhF32Z-8968c211affb8ae31358.js} +1 -1
  32. data/tools/dataextractor/{LabelWidget-FQI-cH_A-6ba874245f82dee1b5b4.js → LabelWidget-BhzkN06D-82e78a304e7976c050e7.js} +1 -1
  33. data/tools/dataextractor/{LabelledWidget-KGXtQ4Zb-fd5dd58e0de56789b7b2.js → LabelledWidget-vx8NvW1b-2f85e885d9b34bfa9b83.js} +1 -1
  34. data/tools/dataextractor/LabelprogressbarWidget-t5PvKuS4-5368a53a7909f0a6a0ca.js +1 -0
  35. data/tools/dataextractor/LabelsparklineWidget-CebbEH-j-967cb6f44c6c55eaf6e2.js +1 -0
  36. data/tools/dataextractor/LabelvalueWidget-Cbs1DBK2-37a6959ba720e2fb2607.js +1 -0
  37. data/tools/dataextractor/{LabelvaluedescWidget-BppM5vGp-e2eb8f62ec8b1edab5c7.js → LabelvaluedescWidget-B7OIOGc0-4e187a1ca9ccebd898ec.js} +1 -1
  38. data/tools/dataextractor/LabelvaluelimitsbarWidget-C57kf-oQ-91c29b441f80779ffdf4.js +1 -0
  39. data/tools/dataextractor/LabelvaluelimitscolumnWidget-BRlNDEqp-4560f2046838b297f8b9.js +1 -0
  40. data/tools/dataextractor/LabelvaluerangebarWidget-Pt_evm3v-7cff22dc6c8171a0737f.js +1 -0
  41. data/tools/dataextractor/{Layout-d-vb0okO-5143877d6be73c3e6315.js → Layout-CKmC50QZ-7c09657f848d6bec97ad.js} +1 -1
  42. data/tools/dataextractor/{LedWidget-Cmr6eVG2-aa2c79bda6817327a734.js → LedWidget-D1lmNXpi-c9ddb6bb20c6b65e8752.js} +1 -1
  43. data/tools/dataextractor/{LimitsBar-qMynDHYT-9ef33b1b3b889d3fab97.js → LimitsBar-D5IZu7eX-f245aa3388489b985719.js} +1 -1
  44. data/tools/dataextractor/{LimitsbarWidget-CMvcwa-m-d060dbaa92ea217695a7.js → LimitsbarWidget-VpxQXE-e-92655885f9c8ff8dd67a.js} +1 -1
  45. data/tools/dataextractor/{LimitscolorWidget-CZ9wMtcI-600a0d33cfdac9e606c6.js → LimitscolorWidget-79P41CX7-17bfc98cd285ef8d5cf0.js} +1 -1
  46. data/tools/dataextractor/{LimitscolumnWidget-r84KJGU--63f1ce2e287b7e068fe3.js → LimitscolumnWidget-BFDXhJeZ-543fc43f72002343d7bb.js} +1 -1
  47. data/tools/dataextractor/LinegraphWidget-VqkpOlws-1b6eb0d902a3b0577bb7.js +1 -0
  48. data/tools/dataextractor/{MatrixbycolumnsWidget-Dx2iz0YF-999d3afe43e2aa9db87e.js → MatrixbycolumnsWidget--ihvirDP-8fe2c21364aff79528e9.js} +1 -1
  49. data/tools/dataextractor/OpenC3TimePicker-B0lAIU91-dbee395a71067b34188a.js +1 -0
  50. data/tools/dataextractor/{ProgressbarWidget-DPbAVjdC-2981b1af8af4da20b6d1.js → ProgressbarWidget-BIB3r9SL-04bfb4d921751b068806.js} +1 -1
  51. data/tools/dataextractor/RadiobuttonWidget-C5rxLM7K-41dd5ecc6efc1f7ec023.js +1 -0
  52. data/tools/dataextractor/{RadiogroupWidget-CMM_p1eA-1a39ed7902af769f50d0.js → RadiogroupWidget-CciTCv1U-5447f0a20fd31cb84781.js} +1 -1
  53. data/tools/dataextractor/{RangebarWidget-DJXGUHAc-63d6cdc08c070ce2280c.js → RangebarWidget-MPQYi2Km-2d0bc2f6ae59f1fc6cb2.js} +1 -1
  54. data/tools/dataextractor/{RollupWidget-BbWLSsTT-f862029486671e1966d7.js → RollupWidget-CfjGAhzg-d61d2e69d0dfb53f8d5a.js} +1 -1
  55. data/tools/dataextractor/ScrollwindowWidget-CupaygNN-f0bc8971fbeb2f3b7ac6.js +1 -0
  56. data/tools/dataextractor/{SignalWidget-65q0tiuo-52c981c4470bf5006886.js → SignalWidget-C-qecoTO-ac5acb141c44fbe8bd3b.js} +1 -1
  57. data/tools/dataextractor/{SpacerWidget-DFzbojmX-55a4d9330581f9b7285d.js → SpacerWidget-VVkOCb6N-ec90981ae0ee78718da0.js} +1 -1
  58. data/tools/dataextractor/SparklineWidget-Dsmn38z_-0e974d1a6820c9766d5e.js +1 -0
  59. data/tools/dataextractor/TabbookWidget-CXklff-l-f8d84ac5de477b47cc89.js +1 -0
  60. data/tools/dataextractor/{TargetPacketItemChooser-BOdVLVbe-d94873f0ee88694988de.js → TargetPacketItemChooser-DDHuygCl-d58eaf885223711090d4.js} +1 -1
  61. data/tools/dataextractor/TextboxWidget-CHs2VYIv-0afd03dec5b9e1bcf5d5.js +1 -0
  62. data/tools/dataextractor/TextfieldWidget-CdANAW-6-abb82a45c67e54365c38.js +1 -0
  63. data/tools/dataextractor/TimeWidget-D0xT1wXR-42543ac5f61f9caf689c.js +1 -0
  64. data/tools/dataextractor/TitleWidget-68NWCcXB-f800dbc154a0b790db80.js +1 -0
  65. data/tools/dataextractor/{VWidget-BDy0211S-1ff9c9310d5fdbf00390.js → VWidget-oMbywhLA-48cc5e9eee33d428a035.js} +1 -1
  66. data/tools/dataextractor/ValueWidget-B1aGUBP7-09e3a422caa4029a7a89.js +1 -0
  67. data/tools/dataextractor/ValuelimitsbarWidget-B7KcRjLS-89060ce240e589231a32.js +1 -0
  68. data/tools/dataextractor/{ValuelimitscolumnWidget-7DXCsVW_-86690696d7ef52117561.js → ValuelimitscolumnWidget-BVt6nLXq-c3953d4f07717ac68634.js} +1 -1
  69. data/tools/dataextractor/ValuerangebarWidget-uVZEI32U-2e888511354ce5936843.js +1 -0
  70. data/tools/dataextractor/VerticalWidget-DlftYBjH-6dab9f0f52b2711f6b3f.js +1 -0
  71. data/tools/dataextractor/VerticalboxWidget-C7RrkfY0-2a1e515b69dfc37fd4b3.js +1 -0
  72. data/tools/dataextractor/{Widget-BDsgRxuV-660e8eb4690c2793e6b6.js → Widget-D_HaosJK-3aa019608f819cd93c9a.js} +1 -1
  73. data/tools/dataextractor/main-07b38629281328ace40e.js +1497 -0
  74. data/tools/dataextractor/main.js +1 -1
  75. metadata +73 -73
  76. data/tools/dataextractor/ArrayWidget-CcQFJGCA-f76220cc11a39cef93d3.js +0 -2
  77. data/tools/dataextractor/ButtonWidget-Cc9cYsg8-fa11db39baed1ca10dd9.js +0 -2
  78. data/tools/dataextractor/CanvasWidget-Bn70gBcc-9779d7c4a0937c4e2f70.js +0 -1
  79. data/tools/dataextractor/CanvasdotWidget-CMROfW3O-f502b2d25ac1e3251128.js +0 -1
  80. data/tools/dataextractor/CanvaslabelWidget-C074R2Fy-8fa147b0578e1ddd8e31.js +0 -1
  81. data/tools/dataextractor/CanvaslineWidget-CxnNAqOX-d042686da706d5408c3e.js +0 -1
  82. data/tools/dataextractor/CheckbuttonWidget-yAm10oX0-e8125b88e4be2fc48dbf.js +0 -1
  83. data/tools/dataextractor/ComboboxWidget-BnWksnnp-c1d54211236c9e26a34b.js +0 -1
  84. data/tools/dataextractor/DataExtractor-4fdb57d1945b0887db0f.js +0 -14
  85. data/tools/dataextractor/Graph-BCvaO4yI-a403dbd09e8a3025cceb.js +0 -1
  86. data/tools/dataextractor/HorizontalboxWidget-CKA7rLGd-9f624ef7e0a8f5e8341a.js +0 -1
  87. data/tools/dataextractor/LabelprogressbarWidget-72WyzD_Q-0c61a376a160ac8eabc1.js +0 -1
  88. data/tools/dataextractor/LabelsparklineWidget-DtWNf4mK-49ac92040f51acb6ad41.js +0 -1
  89. data/tools/dataextractor/LabelvalueWidget-D_JLdY7r-95bd967c8c4f6cb0fb1c.js +0 -1
  90. data/tools/dataextractor/LabelvaluelimitsbarWidget-B69ogLif-bfa23b96929cba8117ff.js +0 -1
  91. data/tools/dataextractor/LabelvaluelimitscolumnWidget-DPYwFdgq-2159672e62922d671ff6.js +0 -1
  92. data/tools/dataextractor/LabelvaluerangebarWidget-BT0BcOoK-db30aa4c4f1abbb71f06.js +0 -1
  93. data/tools/dataextractor/LinegraphWidget-COGBGOjF-5c8d32bb60f274b053cd.js +0 -1
  94. data/tools/dataextractor/OpenC3TimePicker-C3vCnk72-b6adff64018a7923eb93.js +0 -1
  95. data/tools/dataextractor/RadiobuttonWidget-iXI9yCDk-59f850a8bd9d843024e5.js +0 -1
  96. data/tools/dataextractor/ScrollwindowWidget-Dxhp7yKn-8b0ba7315cde67bcc9f6.js +0 -1
  97. data/tools/dataextractor/SparklineWidget-Bu4I8zY0-d05e82f937b095333a15.js +0 -1
  98. data/tools/dataextractor/TabbookWidget-CELMWyx7-1d7b6a3a541b8b6cffb3.js +0 -1
  99. data/tools/dataextractor/TextboxWidget-DYsqXntS-d477d1867f2a65ae0699.js +0 -1
  100. data/tools/dataextractor/TextfieldWidget-BIUgV9Q4-7664df7a16deff334036.js +0 -1
  101. data/tools/dataextractor/TimeWidget-BPXcY1Wy-61008f558728b5f906d7.js +0 -1
  102. data/tools/dataextractor/TitleWidget-DJ9mHRLE-52e464994c49c45eae92.js +0 -1
  103. data/tools/dataextractor/ValueWidget-DzOSy7lp-92479ffa8015859984c7.js +0 -1
  104. data/tools/dataextractor/ValuelimitsbarWidget-D5dSlW6D-cae311a05073ff60ddb1.js +0 -1
  105. data/tools/dataextractor/ValuerangebarWidget-BWjnpmyy-ef11d2ea672f2dbd1a8a.js +0 -1
  106. data/tools/dataextractor/VerticalWidget-BOtXAhxt-19d6adff2d379742f886.js +0 -1
  107. data/tools/dataextractor/VerticalboxWidget-RAsXfGdI-c0d18d921ac32d9c3bbe.js +0 -1
  108. data/tools/dataextractor/main-cb94da8783ff5b6915d8.js +0 -1496
@@ -0,0 +1,1497 @@
1
+ System.register(["vue","vue-router","pinia","single-spa","vuetify"],(function(On,rt){"use strict";var St,Nn,co,Pt,dt,ti,mr,_f,kf,Us,Ia,kl,Er,ni,So,Sl,Vs,$l,Rl,Sf,$f,Rf,cu,Ef,Tf,Mf,If,Lf,uu,Of,Nf,Df,Pf,Ff,hu,zf;return{setters:[Et=>{St=Et.resolveComponent,Nn=Et.openBlock,co=Et.createBlock,Pt=Et.withCtx,dt=Et.createVNode,ti=Et.createElementBlock,mr=Et.createElementVNode,_f=Et.useCssVars,kf=Et.defineAsyncComponent,Us=Et.h,Ia=Et.normalizeStyle,kl=Et.Fragment,Er=Et.createTextVNode,ni=Et.toDisplayString,So=Et.createCommentVNode,Sl=Et.withKeys,Vs=Et.withModifiers,$l=Et.withDirectives,Rl=Et.vShow,Sf=Et.defineComponent,$f=Et.warn,Rf=Et.inject,cu=Et.computed,Ef=Et.shallowRef,Tf=Et.watchEffect,Mf=Et.normalizeClass,If=Et.getCurrentInstance,Lf=Et.provide,uu=Et.createApp,Of=Et.mergeProps},Et=>{Nf=Et.createRouter,Df=Et.createWebHistory},Et=>{Pf=Et.defineStore,Ff=Et.createPinia},Et=>{hu=Et.getMountedApps},Et=>{zf=Et.createVuetify}],execute:(function(){On({B:Hr,D:zu,F:rg,G:uo,J:Pu,L:og,U:Ha,V:Js,a:ig,c:Zp,i:Jp,o:my,p:Mr,v:Zs,z:Yp});var Et=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Bf(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);n&&(r=r.filter((function(m){return Object.getOwnPropertyDescriptor(t,m).enumerable}))),e.push.apply(e,r)}return e}function us(t){for(var n=1;n<arguments.length;n++){var e=arguments[n]!=null?arguments[n]:{};n%2?Bf(Object(e),!0).forEach((function(r){tw(t,r,e[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):Bf(Object(e)).forEach((function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r))}))}return t}function tw(t,n,e){return(n=(function(r){var m=(function(f,g){if(hs(f)!=="object"||f===null)return f;var w=f[Symbol.toPrimitive];if(w!==void 0){var u=w.call(f,g);if(hs(u)!=="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return(g==="string"?String:Number)(f)})(r,"string");return hs(m)==="symbol"?m:String(m)})(n))in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}function hs(t){return hs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},hs(t)}(function(t){if(t.CSS&&t.CSS.escape)return t.CSS.escape;var n=function(e){if(arguments.length==0)throw new TypeError("`CSS.escape` requires an argument.");for(var r,m=String(e),f=m.length,g=-1,w="",u=m.charCodeAt(0);++g<f;)(r=m.charCodeAt(g))!=0?w+=r>=1&&r<=31||r==127||g==0&&r>=48&&r<=57||g==1&&r>=48&&r<=57&&u==45?"\\"+r.toString(16)+" ":g==0&&f==1&&r==45||!(r>=128||r==45||r==95||r>=48&&r<=57||r>=65&&r<=90||r>=97&&r<=122)?"\\"+m.charAt(g):m.charAt(g):w+="�";return w};t.CSS||(t.CSS={}),t.CSS.escape=n})(Et);var nw={appOptions:null,template:null,Vue:null,createApp:null,handleInstance:null};function rw(t){if(hs(t)!=="object")throw new Error("single-spa-vue requires a configuration object");var n=us(us({},nw),t);if(!n.Vue&&!n.createApp)throw Error("single-spa-vue must be passed opts.Vue or opts.createApp");if(!n.appOptions)throw Error("single-spa-vue must be passed opts.appOptions");if(n.appOptions.el&&typeof n.appOptions.el!="string"&&!(n.appOptions.el instanceof HTMLElement))throw Error("single-spa-vue: appOptions.el must be a string CSS selector, an HTMLElement, or not provided at all. Was given ".concat(hs(n.appOptions.el)));n.createApp=n.createApp||n.Vue&&n.Vue.createApp;var e={};return{bootstrap:iw.bind(null,n,e),mount:ow.bind(null,n,e),unmount:aw.bind(null,n,e),update:sw.bind(null,n,e)}}function iw(t){return t.loadRootComponent?t.loadRootComponent().then((function(n){return t.rootComponent=n})):Promise.resolve()}function ow(t,n,e){var r={};return Promise.resolve().then((function(){return(function(m,f){return typeof m.appOptions=="function"?m.appOptions(f):Promise.resolve(us({},m.appOptions))})(t,e).then((function(m){var f;if(e.domElement&&!m.el&&(m.el=e.domElement),m.el)if(typeof m.el=="string"){if(!(f=document.querySelector(m.el)))throw Error("If appOptions.el is provided to single-spa-vue, the dom element must exist in the dom. Was provided as ".concat(m.el))}else(f=m.el).id||(f.id="single-spa-application:".concat(e.name)),m.el="#".concat(CSS.escape(f.id));else{var g="single-spa-application:".concat(e.name);m.el="#".concat(CSS.escape(g)),(f=document.getElementById(g))||((f=document.createElement("div")).id=g,document.body.appendChild(f))}if(!t.replaceMode&&(m.el=m.el+" .single-spa-container",!f.querySelector(".single-spa-container"))){var w=document.createElement("div");w.className="single-spa-container",f.appendChild(w)}r.domEl=f,m.render||m.template||!t.rootComponent||(m.render=function(d){return d(t.rootComponent)}),m.data||(m.data={});var u=m.data;if(m.data=function(){return us(us({},typeof u=="function"?u.call(this,this):u),e)},t.createApp){if(r.vueInstance=t.createApp(m),t.handleInstance)return Promise.resolve(t.handleInstance(r.vueInstance,e)).then((function(){return r.root=r.vueInstance.mount(m.el),n[e.name]=r,r.vueInstance}));r.root=r.vueInstance.mount(m.el)}else if(r.vueInstance=new t.Vue(m),r.vueInstance.bind&&(r.vueInstance=r.vueInstance.bind(r.vueInstance)),t.handleInstance)return Promise.resolve(t.handleInstance(r.vueInstance,e)).then((function(){return n[e.name]=r,r.vueInstance}));return n[e.name]=r,r.vueInstance}))}))}function sw(t,n,e){return Promise.resolve().then((function(){var r=n[e.name],m=us(us({},t.appOptions.data||{}),e),f=r.root||r.vueInstance;for(var g in m)f[g]=m[g]}))}function aw(t,n,e){return Promise.resolve().then((function(){var r=n[e.name];t.createApp?r.vueInstance.unmount(r.domEl):(r.vueInstance.$destroy(),r.vueInstance.$el.innerHTML=""),delete r.vueInstance,r.domEl&&(r.domEl.innerHTML="",delete r.domEl)}))}const lw=On("_",(t,n)=>{const e=t.__vccOpts||t;for(const[r,m]of n)e[r]=m;return e}),cw={};function uw(t,n){const e=St("router-view"),r=St("v-app");return Nn(),co(r,{id:"innerapp"},{default:Pt(()=>[dt(e)]),_:1})}const hw=lw(cw,[["render",uw]]),T2="modulepreload",M2=function(t){return"/"+t},I2={},it=function(n,e,r){let m=Promise.resolve();function f(g){const w=new Event("vite:preloadError",{cancelable:!0});if(w.payload=g,window.dispatchEvent(w),!w.defaultPrevented)throw g}return m.then(g=>{for(const w of g||[])w.status==="rejected"&&f(w.reason);return n().catch(f)})},Wf=function(t){!t.name!=="NotFound"&&(t.path=`/tools/dataextractor/${t.path.replace(/^\//,"")}`),t.children?.forEach(Wf)},Vo=On("f",(t,n)=>{const e=t.__vccOpts||t;for(const[r,m]of n)e[r]=m;return e}),dw="/icons/customIcons.svg",du={props:{icon:{type:String,default:null},size:{type:String,default:"small"},color:{type:String,default:"white"}},computed:{iconSrc:function(){return dw+"#"+this.icon}}},jf=()=>{_f(t=>({v4ccb3d08:t.color}))},Hf=du.setup;du.setup=Hf?(t,n)=>(jf(),Hf(t,n)):jf;const fw={class:"cosmos-custom-icon"},pw={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",preserveAspectRatio:"xMidYMid meet",focusable:"false"},gw=["href"];function mw(t,n,e,r,m,f){return Nn(),ti("span",fw,[(Nn(),ti("svg",pw,[mr("use",{href:f.iconSrc},null,8,gw)]))])}const vw=Vo(du,[["render",mw],["__scopeId","data-v-54b83b01"]]);function Uf(t,n){return function(){return t.apply(n,arguments)}}const{toString:yw}=Object.prototype,{getPrototypeOf:El}=Object,{iterator:Tl,toStringTag:Vf}=Symbol,Ml=(t=>n=>{const e=yw.call(n);return t[e]||(t[e]=e.slice(8,-1).toLowerCase())})(Object.create(null)),qi=t=>(t=t.toLowerCase(),n=>Ml(n)===t),Il=t=>n=>typeof n===t,{isArray:qs}=Array,Gs=Il("undefined");function La(t){return t!==null&&!Gs(t)&&t.constructor!==null&&!Gs(t.constructor)&&ri(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const qf=qi("ArrayBuffer");function bw(t){let n;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?n=ArrayBuffer.isView(t):n=t&&t.buffer&&qf(t.buffer),n}const ww=Il("string"),ri=Il("function"),Gf=Il("number"),Oa=t=>t!==null&&typeof t=="object",xw=t=>t===!0||t===!1,Ll=t=>{if(Ml(t)!=="object")return!1;const n=El(t);return(n===null||n===Object.prototype||Object.getPrototypeOf(n)===null)&&!(Vf in t)&&!(Tl in t)},Cw=t=>{if(!Oa(t)||La(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},Aw=qi("Date"),_w=qi("File"),kw=t=>!!(t&&typeof t.uri<"u"),Sw=t=>t&&typeof t.getParts<"u",$w=qi("Blob"),Rw=qi("FileList"),Ew=t=>Oa(t)&&ri(t.pipe);function Tw(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}const Kf=Tw(),Yf=typeof Kf.FormData<"u"?Kf.FormData:void 0,Mw=t=>{if(!t)return!1;if(Yf&&t instanceof Yf)return!0;const n=El(t);if(!n||n===Object.prototype||!ri(t.append))return!1;const e=Ml(t);return e==="formdata"||e==="object"&&ri(t.toString)&&t.toString()==="[object FormData]"},Iw=qi("URLSearchParams"),[Lw,Ow,Nw,Dw]=["ReadableStream","Request","Response","Headers"].map(qi),Pw=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Na(t,n,{allOwnKeys:e=!1}={}){if(t===null||typeof t>"u")return;let r,m;if(typeof t!="object"&&(t=[t]),qs(t))for(r=0,m=t.length;r<m;r++)n.call(null,t[r],r,t);else{if(La(t))return;const f=e?Object.getOwnPropertyNames(t):Object.keys(t),g=f.length;let w;for(r=0;r<g;r++)w=f[r],n.call(null,t[w],w,t)}}function Jf(t,n){if(La(t))return null;n=n.toLowerCase();const e=Object.keys(t);let r=e.length,m;for(;r-- >0;)if(m=e[r],n===m.toLowerCase())return m;return null}const ds=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Zf=t=>!Gs(t)&&t!==ds;function fu(...t){const{caseless:n,skipUndefined:e}=Zf(this)&&this||{},r={},m=(f,g)=>{if(g==="__proto__"||g==="constructor"||g==="prototype")return;const w=n&&Jf(r,g)||g,u=pu(r,w)?r[w]:void 0;Ll(u)&&Ll(f)?r[w]=fu(u,f):Ll(f)?r[w]=fu({},f):qs(f)?r[w]=f.slice():(!e||!Gs(f))&&(r[w]=f)};for(let f=0,g=t.length;f<g;f++)t[f]&&Na(t[f],m);return r}const Fw=(t,n,e,{allOwnKeys:r}={})=>(Na(n,(m,f)=>{e&&ri(m)?Object.defineProperty(t,f,{__proto__:null,value:Uf(m,e),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(t,f,{__proto__:null,value:m,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),t),zw=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),Bw=(t,n,e,r)=>{t.prototype=Object.create(n.prototype,r),Object.defineProperty(t.prototype,"constructor",{__proto__:null,value:t,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(t,"super",{__proto__:null,value:n.prototype}),e&&Object.assign(t.prototype,e)},Ww=(t,n,e,r)=>{let m,f,g;const w={};if(n=n||{},t==null)return n;do{for(m=Object.getOwnPropertyNames(t),f=m.length;f-- >0;)g=m[f],(!r||r(g,t,n))&&!w[g]&&(n[g]=t[g],w[g]=!0);t=e!==!1&&El(t)}while(t&&(!e||e(t,n))&&t!==Object.prototype);return n},jw=(t,n,e)=>{t=String(t),(e===void 0||e>t.length)&&(e=t.length),e-=n.length;const r=t.indexOf(n,e);return r!==-1&&r===e},Hw=t=>{if(!t)return null;if(qs(t))return t;let n=t.length;if(!Gf(n))return null;const e=new Array(n);for(;n-- >0;)e[n]=t[n];return e},Uw=(t=>n=>t&&n instanceof t)(typeof Uint8Array<"u"&&El(Uint8Array)),Vw=(t,n)=>{const e=(t&&t[Tl]).call(t);let r;for(;(r=e.next())&&!r.done;){const m=r.value;n.call(t,m[0],m[1])}},qw=(t,n)=>{let e;const r=[];for(;(e=t.exec(n))!==null;)r.push(e);return r},Gw=qi("HTMLFormElement"),Kw=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,e,r){return e.toUpperCase()+r}),pu=(({hasOwnProperty:t})=>(n,e)=>t.call(n,e))(Object.prototype),Yw=qi("RegExp"),Xf=(t,n)=>{const e=Object.getOwnPropertyDescriptors(t),r={};Na(e,(m,f)=>{let g;(g=n(m,f,t))!==!1&&(r[f]=g||m)}),Object.defineProperties(t,r)},Jw=t=>{Xf(t,(n,e)=>{if(ri(t)&&["arguments","caller","callee"].includes(e))return!1;const r=t[e];if(ri(r)){if(n.enumerable=!1,"writable"in n){n.writable=!1;return}n.set||(n.set=()=>{throw Error("Can not rewrite read-only method '"+e+"'")})}})},Zw=(t,n)=>{const e={},r=m=>{m.forEach(f=>{e[f]=!0})};return qs(t)?r(t):r(String(t).split(n)),e},Xw=()=>{},Qw=(t,n)=>t!=null&&Number.isFinite(t=+t)?t:n;function ex(t){return!!(t&&ri(t.append)&&t[Vf]==="FormData"&&t[Tl])}const tx=t=>{const n=new WeakSet,e=r=>{if(Oa(r)){if(n.has(r))return;if(La(r))return r;if(!("toJSON"in r)){n.add(r);const m=qs(r)?[]:{};return Na(r,(f,g)=>{const w=e(f);!Gs(w)&&(m[g]=w)}),n.delete(r),m}}return r};return e(t)},nx=qi("AsyncFunction"),rx=t=>t&&(Oa(t)||ri(t))&&ri(t.then)&&ri(t.catch),Qf=((t,n)=>t?setImmediate:n?((e,r)=>(ds.addEventListener("message",({source:m,data:f})=>{m===ds&&f===e&&r.length&&r.shift()()},!1),m=>{r.push(m),ds.postMessage(e,"*")}))(`axios@${Math.random()}`,[]):e=>setTimeout(e))(typeof setImmediate=="function",ri(ds.postMessage)),ix=typeof queueMicrotask<"u"?queueMicrotask.bind(ds):typeof process<"u"&&process.nextTick||Qf,ox=t=>t!=null&&ri(t[Tl]),xe={isArray:qs,isArrayBuffer:qf,isBuffer:La,isFormData:Mw,isArrayBufferView:bw,isString:ww,isNumber:Gf,isBoolean:xw,isObject:Oa,isPlainObject:Ll,isEmptyObject:Cw,isReadableStream:Lw,isRequest:Ow,isResponse:Nw,isHeaders:Dw,isUndefined:Gs,isDate:Aw,isFile:_w,isReactNativeBlob:kw,isReactNative:Sw,isBlob:$w,isRegExp:Yw,isFunction:ri,isStream:Ew,isURLSearchParams:Iw,isTypedArray:Uw,isFileList:Rw,forEach:Na,merge:fu,extend:Fw,trim:Pw,stripBOM:zw,inherits:Bw,toFlatObject:Ww,kindOf:Ml,kindOfTest:qi,endsWith:jw,toArray:Hw,forEachEntry:Vw,matchAll:qw,isHTMLForm:Gw,hasOwnProperty:pu,hasOwnProp:pu,reduceDescriptors:Xf,freezeMethods:Jw,toObjectSet:Zw,toCamelCase:Kw,noop:Xw,toFiniteNumber:Qw,findKey:Jf,global:ds,isContextDefined:Zf,isSpecCompliantForm:ex,toJSONObject:tx,isAsyncFn:nx,isThenable:rx,setImmediate:Qf,asap:ix,isIterable:ox},sx=xe.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"]),ax=t=>{const n={};let e,r,m;return t&&t.split(`
2
+ `).forEach(function(f){m=f.indexOf(":"),e=f.substring(0,m).trim().toLowerCase(),r=f.substring(m+1).trim(),!(!e||n[e]&&sx[e])&&(e==="set-cookie"?n[e]?n[e].push(r):n[e]=[r]:n[e]=n[e]?n[e]+", "+r:r)}),n};function lx(t){let n=0,e=t.length;for(;n<e;){const r=t.charCodeAt(n);if(r!==9&&r!==32)break;n+=1}for(;e>n;){const r=t.charCodeAt(e-1);if(r!==9&&r!==32)break;e-=1}return n===0&&e===t.length?t:t.slice(n,e)}const cx=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),ux=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function gu(t,n){return xe.isArray(t)?t.map(e=>gu(e,n)):lx(String(t).replace(n,""))}const hx=t=>gu(t,cx),dx=t=>gu(t,ux);function ep(t){const n=Object.create(null);return xe.forEach(t.toJSON(),(e,r)=>{n[r]=dx(e)}),n}const tp=Symbol("internals");function Da(t){return t&&String(t).trim().toLowerCase()}function Ol(t){return t===!1||t==null?t:xe.isArray(t)?t.map(Ol):hx(String(t))}function fx(t){const n=Object.create(null),e=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=e.exec(t);)n[r[1]]=r[2];return n}const px=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function mu(t,n,e,r,m){if(xe.isFunction(r))return r.call(this,n,e);if(m&&(n=e),!!xe.isString(n)){if(xe.isString(r))return n.indexOf(r)!==-1;if(xe.isRegExp(r))return r.test(n)}}function gx(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(n,e,r)=>e.toUpperCase()+r)}function mx(t,n){const e=xe.toCamelCase(" "+n);["get","set","has"].forEach(r=>{Object.defineProperty(t,r+e,{__proto__:null,value:function(m,f,g){return this[r].call(this,n,m,f,g)},configurable:!0})})}let jr=class{constructor(n){n&&this.set(n)}set(n,e,r){const m=this;function f(w,u,d){const a=Da(u);if(!a)throw new Error("header name must be a non-empty string");const l=xe.findKey(m,a);(!l||m[l]===void 0||d===!0||d===void 0&&m[l]!==!1)&&(m[l||u]=Ol(w))}const g=(w,u)=>xe.forEach(w,(d,a)=>f(d,a,u));if(xe.isPlainObject(n)||n instanceof this.constructor)g(n,e);else if(xe.isString(n)&&(n=n.trim())&&!px(n))g(ax(n),e);else if(xe.isObject(n)&&xe.isIterable(n)){let w={},u,d;for(const a of n){if(!xe.isArray(a))throw TypeError("Object iterator must return a key-value pair");w[d=a[0]]=(u=w[d])?xe.isArray(u)?[...u,a[1]]:[u,a[1]]:a[1]}g(w,e)}else n!=null&&f(e,n,r);return this}get(n,e){if(n=Da(n),n){const r=xe.findKey(this,n);if(r){const m=this[r];if(!e)return m;if(e===!0)return fx(m);if(xe.isFunction(e))return e.call(this,m,r);if(xe.isRegExp(e))return e.exec(m);throw new TypeError("parser must be boolean|regexp|function")}}}has(n,e){if(n=Da(n),n){const r=xe.findKey(this,n);return!!(r&&this[r]!==void 0&&(!e||mu(this,this[r],r,e)))}return!1}delete(n,e){const r=this;let m=!1;function f(g){if(g=Da(g),g){const w=xe.findKey(r,g);w&&(!e||mu(r,r[w],w,e))&&(delete r[w],m=!0)}}return xe.isArray(n)?n.forEach(f):f(n),m}clear(n){const e=Object.keys(this);let r=e.length,m=!1;for(;r--;){const f=e[r];(!n||mu(this,this[f],f,n,!0))&&(delete this[f],m=!0)}return m}normalize(n){const e=this,r={};return xe.forEach(this,(m,f)=>{const g=xe.findKey(r,f);if(g){e[g]=Ol(m),delete e[f];return}const w=n?gx(f):String(f).trim();w!==f&&delete e[f],e[w]=Ol(m),r[w]=!0}),this}concat(...n){return this.constructor.concat(this,...n)}toJSON(n){const e=Object.create(null);return xe.forEach(this,(r,m)=>{r!=null&&r!==!1&&(e[m]=n&&xe.isArray(r)?r.join(", "):r)}),e}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([n,e])=>n+": "+e).join(`
3
+ `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(n){return n instanceof this?n:new this(n)}static concat(n,...e){const r=new this(n);return e.forEach(m=>r.set(m)),r}static accessor(n){const e=(this[tp]=this[tp]={accessors:{}}).accessors,r=this.prototype;function m(f){const g=Da(f);e[g]||(mx(r,f),e[g]=!0)}return xe.isArray(n)?n.forEach(m):m(n),this}};jr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),xe.reduceDescriptors(jr.prototype,({value:t},n)=>{let e=n[0].toUpperCase()+n.slice(1);return{get:()=>t,set(r){this[e]=r}}}),xe.freezeMethods(jr);const vx="[REDACTED ****]";function yx(t){if(xe.hasOwnProp(t,"toJSON"))return!0;let n=Object.getPrototypeOf(t);for(;n&&n!==Object.prototype;){if(xe.hasOwnProp(n,"toJSON"))return!0;n=Object.getPrototypeOf(n)}return!1}function bx(t,n){const e=new Set(n.map(f=>String(f).toLowerCase())),r=[],m=f=>{if(f===null||typeof f!="object"||xe.isBuffer(f))return f;if(r.indexOf(f)!==-1)return;f instanceof jr&&(f=f.toJSON()),r.push(f);let g;if(xe.isArray(f))g=[],f.forEach((w,u)=>{const d=m(w);xe.isUndefined(d)||(g[u]=d)});else{if(!xe.isPlainObject(f)&&yx(f))return r.pop(),f;g=Object.create(null);for(const[w,u]of Object.entries(f)){const d=e.has(w.toLowerCase())?vx:m(u);xe.isUndefined(d)||(g[w]=d)}}return r.pop(),g};return m(t)}let tt=class Z0 extends Error{static from(n,e,r,m,f,g){const w=new Z0(n.message,e||n.code,r,m,f);return w.cause=n,w.name=n.name,n.status!=null&&w.status==null&&(w.status=n.status),g&&Object.assign(w,g),w}constructor(n,e,r,m,f){super(n),Object.defineProperty(this,"message",{__proto__:null,value:n,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,e&&(this.code=e),r&&(this.config=r),m&&(this.request=m),f&&(this.response=f,this.status=f.status)}toJSON(){const n=this.config,e=n&&xe.hasOwnProp(n,"redact")?n.redact:void 0,r=xe.isArray(e)&&e.length>0?bx(n,e):xe.toJSONObject(n);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:r,code:this.code,status:this.status}}};tt.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",tt.ERR_BAD_OPTION="ERR_BAD_OPTION",tt.ECONNABORTED="ECONNABORTED",tt.ETIMEDOUT="ETIMEDOUT",tt.ECONNREFUSED="ECONNREFUSED",tt.ERR_NETWORK="ERR_NETWORK",tt.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",tt.ERR_DEPRECATED="ERR_DEPRECATED",tt.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",tt.ERR_BAD_REQUEST="ERR_BAD_REQUEST",tt.ERR_CANCELED="ERR_CANCELED",tt.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",tt.ERR_INVALID_URL="ERR_INVALID_URL",tt.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const wx=null;function vu(t){return xe.isPlainObject(t)||xe.isArray(t)}function np(t){return xe.endsWith(t,"[]")?t.slice(0,-2):t}function yu(t,n,e){return t?t.concat(n).map(function(r,m){return r=np(r),!e&&m?"["+r+"]":r}).join(e?".":""):n}function xx(t){return xe.isArray(t)&&!t.some(vu)}const Cx=xe.toFlatObject(xe,{},null,function(t){return/^is[A-Z]/.test(t)});function Nl(t,n,e){if(!xe.isObject(t))throw new TypeError("target must be an object");n=n||new FormData,e=xe.toFlatObject(e,{metaTokens:!0,dots:!1,indexes:!1},!1,function(s,p){return!xe.isUndefined(p[s])});const r=e.metaTokens,m=e.visitor||l,f=e.dots,g=e.indexes,w=e.Blob||typeof Blob<"u"&&Blob,u=e.maxDepth===void 0?100:e.maxDepth,d=w&&xe.isSpecCompliantForm(n);if(!xe.isFunction(m))throw new TypeError("visitor must be a function");function a(s){if(s===null)return"";if(xe.isDate(s))return s.toISOString();if(xe.isBoolean(s))return s.toString();if(!d&&xe.isBlob(s))throw new tt("Blob is not supported. Use a Buffer instead.");return xe.isArrayBuffer(s)||xe.isTypedArray(s)?d&&typeof Blob=="function"?new Blob([s]):Buffer.from(s):s}function l(s,p,b){let x=s;if(xe.isReactNative(n)&&xe.isReactNativeBlob(s))return n.append(yu(b,p,f),a(s)),!1;if(s&&!b&&typeof s=="object"){if(xe.endsWith(p,"{}"))p=r?p:p.slice(0,-2),s=JSON.stringify(s);else if(xe.isArray(s)&&xx(s)||(xe.isFileList(s)||xe.endsWith(p,"[]"))&&(x=xe.toArray(s)))return p=np(p),x.forEach(function(M,R){!(xe.isUndefined(M)||M===null)&&n.append(g===!0?yu([p],R,f):g===null?p:p+"[]",a(M))}),!1}return vu(s)?!0:(n.append(yu(b,p,f),a(s)),!1)}const c=[],h=Object.assign(Cx,{defaultVisitor:l,convertValue:a,isVisitable:vu});function o(s,p,b=0){if(!xe.isUndefined(s)){if(b>u)throw new tt("Object is too deeply nested ("+b+" levels). Max depth: "+u,tt.ERR_FORM_DATA_DEPTH_EXCEEDED);if(c.indexOf(s)!==-1)throw Error("Circular reference detected in "+p.join("."));c.push(s),xe.forEach(s,function(x,M){(!(xe.isUndefined(x)||x===null)&&m.call(n,x,xe.isString(M)?M.trim():M,p,h))===!0&&o(x,p?p.concat(M):[M],b+1)}),c.pop()}}if(!xe.isObject(t))throw new TypeError("data must be an object");return o(t),n}function rp(t){const n={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(t).replace(/[!'()~]|%20/g,function(e){return n[e]})}function bu(t,n){this._pairs=[],t&&Nl(t,this,n)}const ip=bu.prototype;ip.append=function(t,n){this._pairs.push([t,n])},ip.toString=function(t){const n=t?function(e){return t.call(this,e,rp)}:rp;return this._pairs.map(function(e){return n(e[0])+"="+n(e[1])},"").join("&")};function Ax(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function op(t,n,e){if(!n)return t;const r=e&&e.encode||Ax,m=xe.isFunction(e)?{serialize:e}:e,f=m&&m.serialize;let g;if(f?g=f(n,m):g=xe.isURLSearchParams(n)?n.toString():new bu(n,m).toString(r),g){const w=t.indexOf("#");w!==-1&&(t=t.slice(0,w)),t+=(t.indexOf("?")===-1?"?":"&")+g}return t}let sp=class{constructor(){this.handlers=[]}use(n,e,r){return this.handlers.push({fulfilled:n,rejected:e,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(n){this.handlers[n]&&(this.handlers[n]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(n){xe.forEach(this.handlers,function(e){e!==null&&n(e)})}};const wu={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},_x=typeof URLSearchParams<"u"?URLSearchParams:bu,kx=typeof FormData<"u"?FormData:null,Sx=typeof Blob<"u"?Blob:null,$x={isBrowser:!0,classes:{URLSearchParams:_x,FormData:kx,Blob:Sx},protocols:["http","https","file","blob","url","data"]},xu=typeof window<"u"&&typeof document<"u",Cu=typeof navigator=="object"&&navigator||void 0,Rx=xu&&(!Cu||["ReactNative","NativeScript","NS"].indexOf(Cu.product)<0),Ex=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Tx=xu&&window.location.href||"http://localhost",Mx=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:xu,hasStandardBrowserEnv:Rx,hasStandardBrowserWebWorkerEnv:Ex,navigator:Cu,origin:Tx},Symbol.toStringTag,{value:"Module"})),Tr={...Mx,...$x};function Ix(t,n){return Nl(t,new Tr.classes.URLSearchParams,{visitor:function(e,r,m,f){return Tr.isNode&&xe.isBuffer(e)?(this.append(r,e.toString("base64")),!1):f.defaultVisitor.apply(this,arguments)},...n})}function Lx(t){return xe.matchAll(/\w+|\[(\w*)]/g,t).map(n=>n[0]==="[]"?"":n[1]||n[0])}function Ox(t){const n={},e=Object.keys(t);let r;const m=e.length;let f;for(r=0;r<m;r++)f=e[r],n[f]=t[f];return n}function ap(t){function n(e,r,m,f){let g=e[f++];if(g==="__proto__")return!0;const w=Number.isFinite(+g),u=f>=e.length;return g=!g&&xe.isArray(m)?m.length:g,u?(xe.hasOwnProp(m,g)?m[g]=xe.isArray(m[g])?m[g].concat(r):[m[g],r]:m[g]=r,!w):((!xe.hasOwnProp(m,g)||!xe.isObject(m[g]))&&(m[g]=[]),n(e,r,m[g],f)&&xe.isArray(m[g])&&(m[g]=Ox(m[g])),!w)}if(xe.isFormData(t)&&xe.isFunction(t.entries)){const e={};return xe.forEachEntry(t,(r,m)=>{n(Lx(r),m,e,0)}),e}return null}const Ks=(t,n)=>t!=null&&xe.hasOwnProp(t,n)?t[n]:void 0;function Nx(t,n,e){if(xe.isString(t))try{return(n||JSON.parse)(t),xe.trim(t)}catch(r){if(r.name!=="SyntaxError")throw r}return(e||JSON.stringify)(t)}const Pa={transitional:wu,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const e=n.getContentType()||"",r=e.indexOf("application/json")>-1,m=xe.isObject(t);if(m&&xe.isHTMLForm(t)&&(t=new FormData(t)),xe.isFormData(t))return r?JSON.stringify(ap(t)):t;if(xe.isArrayBuffer(t)||xe.isBuffer(t)||xe.isStream(t)||xe.isFile(t)||xe.isBlob(t)||xe.isReadableStream(t))return t;if(xe.isArrayBufferView(t))return t.buffer;if(xe.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let f;if(m){const g=Ks(this,"formSerializer");if(e.indexOf("application/x-www-form-urlencoded")>-1)return Ix(t,g).toString();if((f=xe.isFileList(t))||e.indexOf("multipart/form-data")>-1){const w=Ks(this,"env"),u=w&&w.FormData;return Nl(f?{"files[]":t}:t,u&&new u,g)}}return m||r?(n.setContentType("application/json",!1),Nx(t)):t}],transformResponse:[function(t){const n=Ks(this,"transitional")||Pa.transitional,e=n&&n.forcedJSONParsing,r=Ks(this,"responseType"),m=r==="json";if(xe.isResponse(t)||xe.isReadableStream(t))return t;if(t&&xe.isString(t)&&(e&&!r||m)){const f=!(n&&n.silentJSONParsing)&&m;try{return JSON.parse(t,Ks(this,"parseReviver"))}catch(g){if(f)throw g.name==="SyntaxError"?tt.from(g,tt.ERR_BAD_RESPONSE,this,null,Ks(this,"response")):g}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Tr.classes.FormData,Blob:Tr.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};xe.forEach(["delete","get","head","post","put","patch","query"],t=>{Pa.headers[t]={}});function Au(t,n){const e=this||Pa,r=n||e,m=jr.from(r.headers);let f=r.data;return xe.forEach(t,function(g){f=g.call(e,f,m.normalize(),n?n.status:void 0)}),m.normalize(),f}function lp(t){return!!(t&&t.__CANCEL__)}let Fa=class extends tt{constructor(n,e,r){super(n??"canceled",tt.ERR_CANCELED,e,r),this.name="CanceledError",this.__CANCEL__=!0}};function cp(t,n,e){const r=e.config.validateStatus;!e.status||!r||r(e.status)?t(e):n(new tt("Request failed with status code "+e.status,e.status>=400&&e.status<500?tt.ERR_BAD_REQUEST:tt.ERR_BAD_RESPONSE,e.config,e.request,e))}function Dx(t){const n=/^([-+\w]{1,25}):(?:\/\/)?/.exec(t);return n&&n[1]||""}function Px(t,n){t=t||10;const e=new Array(t),r=new Array(t);let m=0,f=0,g;return n=n!==void 0?n:1e3,function(w){const u=Date.now(),d=r[f];g||(g=u),e[m]=w,r[m]=u;let a=f,l=0;for(;a!==m;)l+=e[a++],a=a%t;if(m=(m+1)%t,m===f&&(f=(f+1)%t),u-g<n)return;const c=d&&u-d;return c?Math.round(l*1e3/c):void 0}}function Fx(t,n){let e=0,r=1e3/n,m,f;const g=(w,u=Date.now())=>{e=u,m=null,f&&(clearTimeout(f),f=null),t(...w)};return[(...w)=>{const u=Date.now(),d=u-e;d>=r?g(w,u):(m=w,f||(f=setTimeout(()=>{f=null,g(m)},r-d)))},()=>m&&g(m)]}const Dl=(t,n,e=3)=>{let r=0;const m=Px(50,250);return Fx(f=>{if(!f||typeof f.loaded!="number")return;const g=f.loaded,w=f.lengthComputable?f.total:void 0,u=w!=null?Math.min(g,w):g,d=Math.max(0,u-r),a=m(d);r=Math.max(r,u);const l={loaded:u,total:w,progress:w?u/w:void 0,bytes:d,rate:a||void 0,estimated:a&&w?(w-u)/a:void 0,event:f,lengthComputable:w!=null,[n?"download":"upload"]:!0};t(l)},e)},up=(t,n)=>{const e=t!=null;return[r=>n[0]({lengthComputable:e,total:t,loaded:r}),n[1]]},hp=t=>(...n)=>xe.asap(()=>t(...n)),zx=Tr.hasStandardBrowserEnv?((t,n)=>e=>(e=new URL(e,Tr.origin),t.protocol===e.protocol&&t.host===e.host&&(n||t.port===e.port)))(new URL(Tr.origin),Tr.navigator&&/(msie|trident)/i.test(Tr.navigator.userAgent)):()=>!0,Bx=Tr.hasStandardBrowserEnv?{write(t,n,e,r,m,f,g){if(typeof document>"u")return;const w=[`${t}=${encodeURIComponent(n)}`];xe.isNumber(e)&&w.push(`expires=${new Date(e).toUTCString()}`),xe.isString(r)&&w.push(`path=${r}`),xe.isString(m)&&w.push(`domain=${m}`),f===!0&&w.push("secure"),xe.isString(g)&&w.push(`SameSite=${g}`),document.cookie=w.join("; ")},read(t){if(typeof document>"u")return null;const n=document.cookie.split(";");for(let e=0;e<n.length;e++){const r=n[e].replace(/^\s+/,""),m=r.indexOf("=");if(m!==-1&&r.slice(0,m)===t)return decodeURIComponent(r.slice(m+1))}return null},remove(t){this.write(t,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function Wx(t){return typeof t!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function jx(t,n){return n?t.replace(/\/?\/$/,"")+"/"+n.replace(/^\/+/,""):t}function dp(t,n,e){let r=!Wx(n);return t&&(r||e===!1)?jx(t,n):n}const fp=t=>t instanceof jr?{...t}:t;function fs(t,n){n=n||{};const e=Object.create(null);Object.defineProperty(e,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function r(d,a,l,c){return xe.isPlainObject(d)&&xe.isPlainObject(a)?xe.merge.call({caseless:c},d,a):xe.isPlainObject(a)?xe.merge({},a):xe.isArray(a)?a.slice():a}function m(d,a,l,c){if(xe.isUndefined(a)){if(!xe.isUndefined(d))return r(void 0,d,l,c)}else return r(d,a,l,c)}function f(d,a){if(!xe.isUndefined(a))return r(void 0,a)}function g(d,a){if(xe.isUndefined(a)){if(!xe.isUndefined(d))return r(void 0,d)}else return r(void 0,a)}function w(d,a,l){if(xe.hasOwnProp(n,l))return r(d,a);if(xe.hasOwnProp(t,l))return r(void 0,d)}const u={url:f,method:f,data:f,baseURL:g,transformRequest:g,transformResponse:g,paramsSerializer:g,timeout:g,timeoutMessage:g,withCredentials:g,withXSRFToken:g,adapter:g,responseType:g,xsrfCookieName:g,xsrfHeaderName:g,onUploadProgress:g,onDownloadProgress:g,decompress:g,maxContentLength:g,maxBodyLength:g,beforeRedirect:g,transport:g,httpAgent:g,httpsAgent:g,cancelToken:g,socketPath:g,allowedSocketPaths:g,responseEncoding:g,validateStatus:w,headers:(d,a,l)=>m(fp(d),fp(a),l,!0)};return xe.forEach(Object.keys({...t,...n}),function(d){if(d==="__proto__"||d==="constructor"||d==="prototype")return;const a=xe.hasOwnProp(u,d)?u[d]:m,l=xe.hasOwnProp(t,d)?t[d]:void 0,c=xe.hasOwnProp(n,d)?n[d]:void 0,h=a(l,c,d);xe.isUndefined(h)&&a!==w||(e[d]=h)}),e}const Hx=["content-type","content-length"];function Ux(t,n,e){if(e!=="content-only"){t.set(n);return}Object.entries(n).forEach(([r,m])=>{Hx.includes(r.toLowerCase())&&t.set(r,m)})}const Vx=t=>encodeURIComponent(t).replace(/%([0-9A-F]{2})/gi,(n,e)=>String.fromCharCode(parseInt(e,16))),pp=t=>{const n=fs({},t),e=c=>xe.hasOwnProp(n,c)?n[c]:void 0,r=e("data");let m=e("withXSRFToken");const f=e("xsrfHeaderName"),g=e("xsrfCookieName");let w=e("headers");const u=e("auth"),d=e("baseURL"),a=e("allowAbsoluteUrls"),l=e("url");if(n.headers=w=jr.from(w),n.url=op(dp(d,l,a),t.params,t.paramsSerializer),u&&w.set("Authorization","Basic "+btoa((u.username||"")+":"+(u.password?Vx(u.password):""))),xe.isFormData(r)&&(Tr.hasStandardBrowserEnv||Tr.hasStandardBrowserWebWorkerEnv?w.setContentType(void 0):xe.isFunction(r.getHeaders)&&Ux(w,r.getHeaders(),e("formDataHeaderPolicy"))),Tr.hasStandardBrowserEnv&&(xe.isFunction(m)&&(m=m(n)),m===!0||m==null&&zx(n.url))){const c=f&&g&&Bx.read(g);c&&w.set(f,c)}return n},qx=typeof XMLHttpRequest<"u",Gx=qx&&function(t){return new Promise(function(n,e){const r=pp(t);let m=r.data;const f=jr.from(r.headers).normalize();let{responseType:g,onUploadProgress:w,onDownloadProgress:u}=r,d,a,l,c,h;function o(){c&&c(),h&&h(),r.cancelToken&&r.cancelToken.unsubscribe(d),r.signal&&r.signal.removeEventListener("abort",d)}let s=new XMLHttpRequest;s.open(r.method.toUpperCase(),r.url,!0),s.timeout=r.timeout;function p(){if(!s)return;const x=jr.from("getAllResponseHeaders"in s&&s.getAllResponseHeaders()),M={data:!g||g==="text"||g==="json"?s.responseText:s.response,status:s.status,statusText:s.statusText,headers:x,config:t,request:s};cp(function(R){n(R),o()},function(R){e(R),o()},M),s=null}"onloadend"in s?s.onloadend=p:s.onreadystatechange=function(){!s||s.readyState!==4||s.status===0&&!(s.responseURL&&s.responseURL.startsWith("file:"))||setTimeout(p)},s.onabort=function(){s&&(e(new tt("Request aborted",tt.ECONNABORTED,t,s)),o(),s=null)},s.onerror=function(x){const M=x&&x.message?x.message:"Network Error",R=new tt(M,tt.ERR_NETWORK,t,s);R.event=x||null,e(R),o(),s=null},s.ontimeout=function(){let x=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const M=r.transitional||wu;r.timeoutErrorMessage&&(x=r.timeoutErrorMessage),e(new tt(x,M.clarifyTimeoutError?tt.ETIMEDOUT:tt.ECONNABORTED,t,s)),o(),s=null},m===void 0&&f.setContentType(null),"setRequestHeader"in s&&xe.forEach(ep(f),function(x,M){s.setRequestHeader(M,x)}),xe.isUndefined(r.withCredentials)||(s.withCredentials=!!r.withCredentials),g&&g!=="json"&&(s.responseType=r.responseType),u&&([l,h]=Dl(u,!0),s.addEventListener("progress",l)),w&&s.upload&&([a,c]=Dl(w),s.upload.addEventListener("progress",a),s.upload.addEventListener("loadend",c)),(r.cancelToken||r.signal)&&(d=x=>{s&&(e(!x||x.type?new Fa(null,t,s):x),s.abort(),o(),s=null)},r.cancelToken&&r.cancelToken.subscribe(d),r.signal&&(r.signal.aborted?d():r.signal.addEventListener("abort",d)));const b=Dx(r.url);if(b&&!Tr.protocols.includes(b)){e(new tt("Unsupported protocol "+b+":",tt.ERR_BAD_REQUEST,t));return}s.send(m||null)})},Kx=(t,n)=>{if(t=t?t.filter(Boolean):[],!n&&!t.length)return;const e=new AbortController;let r=!1;const m=function(u){if(!r){r=!0,g();const d=u instanceof Error?u:this.reason;e.abort(d instanceof tt?d:new Fa(d instanceof Error?d.message:d))}};let f=n&&setTimeout(()=>{f=null,m(new tt(`timeout of ${n}ms exceeded`,tt.ETIMEDOUT))},n);const g=()=>{t&&(f&&clearTimeout(f),f=null,t.forEach(u=>{u.unsubscribe?u.unsubscribe(m):u.removeEventListener("abort",m)}),t=null)};t.forEach(u=>u.addEventListener("abort",m));const{signal:w}=e;return w.unsubscribe=()=>xe.asap(g),w},Yx=function*(t,n){let e=t.byteLength;if(e<n){yield t;return}let r=0,m;for(;r<e;)m=r+n,yield t.slice(r,m),r=m},Jx=async function*(t,n){for await(const e of Zx(t))yield*Yx(e,n)},Zx=async function*(t){if(t[Symbol.asyncIterator]){yield*t;return}const n=t.getReader();try{for(;;){const{done:e,value:r}=await n.read();if(e)break;yield r}}finally{await n.cancel()}},gp=(t,n,e,r)=>{const m=Jx(t,n);let f=0,g,w=u=>{g||(g=!0,r&&r(u))};return new ReadableStream({async pull(u){try{const{done:d,value:a}=await m.next();if(d){w(),u.close();return}let l=a.byteLength;if(e){let c=f+=l;e(c)}u.enqueue(new Uint8Array(a))}catch(d){throw w(d),d}},cancel(u){return w(u),m.return()}},{highWaterMark:2})};function Xx(t){if(!t||typeof t!="string"||!t.startsWith("data:"))return 0;const n=t.indexOf(",");if(n<0)return 0;const e=t.slice(5,n),r=t.slice(n+1);if(/;base64/i.test(e)){let f=r.length;const g=r.length;for(let l=0;l<g;l++)if(r.charCodeAt(l)===37&&l+2<g){const c=r.charCodeAt(l+1),h=r.charCodeAt(l+2);(c>=48&&c<=57||c>=65&&c<=70||c>=97&&c<=102)&&(h>=48&&h<=57||h>=65&&h<=70||h>=97&&h<=102)&&(f-=2,l+=2)}let w=0,u=g-1;const d=l=>l>=2&&r.charCodeAt(l-2)===37&&r.charCodeAt(l-1)===51&&(r.charCodeAt(l)===68||r.charCodeAt(l)===100);u>=0&&(r.charCodeAt(u)===61?(w++,u--):d(u)&&(w++,u-=3)),w===1&&u>=0&&(r.charCodeAt(u)===61||d(u))&&w++;const a=Math.floor(f/4)*3-(w||0);return a>0?a:0}if(typeof Buffer<"u"&&typeof Buffer.byteLength=="function")return Buffer.byteLength(r,"utf8");let m=0;for(let f=0,g=r.length;f<g;f++){const w=r.charCodeAt(f);if(w<128)m+=1;else if(w<2048)m+=2;else if(w>=55296&&w<=56319&&f+1<g){const u=r.charCodeAt(f+1);u>=56320&&u<=57343?(m+=4,f++):m+=3}else m+=3}return m}const _u="1.16.1",mp=64*1024,{isFunction:Pl}=xe,vp=(t,...n)=>{try{return!!t(...n)}catch{return!1}},Qx=t=>{const n=xe.global!==void 0&&xe.global!==null?xe.global:globalThis,{ReadableStream:e,TextEncoder:r}=n;t=xe.merge.call({skipUndefined:!0},{Request:n.Request,Response:n.Response},t);const{fetch:m,Request:f,Response:g}=t,w=m?Pl(m):typeof fetch=="function",u=Pl(f),d=Pl(g);if(!w)return!1;const a=w&&Pl(e),l=w&&(typeof r=="function"?(b=>x=>b.encode(x))(new r):async b=>new Uint8Array(await new f(b).arrayBuffer())),c=u&&a&&vp(()=>{let b=!1;const x=new f(Tr.origin,{body:new e,method:"POST",get duplex(){return b=!0,"half"}}),M=x.headers.has("Content-Type");return x.body!=null&&x.body.cancel(),b&&!M}),h=d&&a&&vp(()=>xe.isReadableStream(new g("").body)),o={stream:h&&(b=>b.body)};w&&["text","arrayBuffer","blob","formData","stream"].forEach(b=>{!o[b]&&(o[b]=(x,M)=>{let R=x&&x[b];if(R)return R.call(x);throw new tt(`Response type '${b}' is not supported`,tt.ERR_NOT_SUPPORT,M)})});const s=async b=>{if(b==null)return 0;if(xe.isBlob(b))return b.size;if(xe.isSpecCompliantForm(b))return(await new f(Tr.origin,{method:"POST",body:b}).arrayBuffer()).byteLength;if(xe.isArrayBufferView(b)||xe.isArrayBuffer(b))return b.byteLength;if(xe.isURLSearchParams(b)&&(b=b+""),xe.isString(b))return(await l(b)).byteLength},p=async(b,x)=>xe.toFiniteNumber(b.getContentLength())??s(x);return async b=>{let{url:x,method:M,data:R,signal:k,cancelToken:C,timeout:L,onDownloadProgress:D,onUploadProgress:I,responseType:T,headers:W,withCredentials:F="same-origin",fetchOptions:O,maxContentLength:S,maxBodyLength:A}=pp(b);const N=xe.isNumber(S)&&S>-1,B=xe.isNumber(A)&&A>-1;let U=m||fetch;T=T?(T+"").toLowerCase():"text";let G=Kx([k,C&&C.toAbortSignal()],L),J=null;const ne=G&&G.unsubscribe&&(()=>{G.unsubscribe()});let de;try{if(N&&typeof x=="string"&&x.startsWith("data:")&&Xx(x)>S)throw new tt("maxContentLength size of "+S+" exceeded",tt.ERR_BAD_RESPONSE,b,J);if(B&&M!=="get"&&M!=="head"){const me=await p(W,R);if(typeof me=="number"&&isFinite(me)&&me>A)throw new tt("Request body larger than maxBodyLength limit",tt.ERR_BAD_REQUEST,b,J)}if(I&&c&&M!=="get"&&M!=="head"&&(de=await p(W,R))!==0){let me=new f(x,{method:"POST",body:R,duplex:"half"}),$e;if(xe.isFormData(R)&&($e=me.headers.get("content-type"))&&W.setContentType($e),me.body){const[Ee,He]=up(de,Dl(hp(I)));R=gp(me.body,mp,Ee,He)}}xe.isString(F)||(F=F?"include":"omit");const ee=u&&"credentials"in f.prototype;if(xe.isFormData(R)){const me=W.getContentType();me&&/^multipart\/form-data/i.test(me)&&!/boundary=/i.test(me)&&W.delete("content-type")}W.set("User-Agent","axios/"+_u,!1);const se={...O,signal:G,method:M.toUpperCase(),headers:ep(W.normalize()),body:R,duplex:"half",credentials:ee?F:void 0};J=u&&new f(x,se);let ce=await(u?U(J,O):U(x,se));if(N){const me=xe.toFiniteNumber(ce.headers.get("content-length"));if(me!=null&&me>S)throw new tt("maxContentLength size of "+S+" exceeded",tt.ERR_BAD_RESPONSE,b,J)}const le=h&&(T==="stream"||T==="response");if(h&&ce.body&&(D||N||le&&ne)){const me={};["status","statusText","headers"].forEach(Qe=>{me[Qe]=ce[Qe]});const $e=xe.toFiniteNumber(ce.headers.get("content-length")),[Ee,He]=D&&up($e,Dl(hp(D),!0))||[];let Ue=0;const ot=Qe=>{if(N&&(Ue=Qe,Ue>S))throw new tt("maxContentLength size of "+S+" exceeded",tt.ERR_BAD_RESPONSE,b,J);Ee&&Ee(Qe)};ce=new g(gp(ce.body,mp,ot,()=>{He&&He(),ne&&ne()}),me)}T=T||"text";let pe=await o[xe.findKey(o,T)||"text"](ce,b);if(N&&!h&&!le){let me;if(pe!=null&&(typeof pe.byteLength=="number"?me=pe.byteLength:typeof pe.size=="number"?me=pe.size:typeof pe=="string"&&(me=typeof r=="function"?new r().encode(pe).byteLength:pe.length)),typeof me=="number"&&me>S)throw new tt("maxContentLength size of "+S+" exceeded",tt.ERR_BAD_RESPONSE,b,J)}return!le&&ne&&ne(),await new Promise((me,$e)=>{cp(me,$e,{data:pe,headers:jr.from(ce.headers),status:ce.status,statusText:ce.statusText,config:b,request:J})})}catch(ee){if(ne&&ne(),G&&G.aborted&&G.reason instanceof tt){const se=G.reason;throw se.config=b,J&&(se.request=J),ee!==se&&(se.cause=ee),se}throw ee&&ee.name==="TypeError"&&/Load failed|fetch/i.test(ee.message)?Object.assign(new tt("Network Error",tt.ERR_NETWORK,b,J,ee&&ee.response),{cause:ee.cause||ee}):tt.from(ee,ee&&ee.code,b,J,ee&&ee.response)}}},e1=new Map,yp=t=>{let n=t&&t.env||{};const{fetch:e,Request:r,Response:m}=n,f=[r,m,e];let g=f.length,w=g,u,d,a=e1;for(;w--;)u=f[w],d=a.get(u),d===void 0&&a.set(u,d=w?new Map:Qx(n)),a=d;return d};yp();const ku={http:wx,xhr:Gx,fetch:{get:yp}};xe.forEach(ku,(t,n)=>{if(t){try{Object.defineProperty(t,"name",{__proto__:null,value:n})}catch{}Object.defineProperty(t,"adapterName",{__proto__:null,value:n})}});const bp=t=>`- ${t}`,t1=t=>xe.isFunction(t)||t===null||t===!1;function n1(t,n){t=xe.isArray(t)?t:[t];const{length:e}=t;let r,m;const f={};for(let g=0;g<e;g++){r=t[g];let w;if(m=r,!t1(r)&&(m=ku[(w=String(r)).toLowerCase()],m===void 0))throw new tt(`Unknown adapter '${w}'`);if(m&&(xe.isFunction(m)||(m=m.get(n))))break;f[w||"#"+g]=m}if(!m){const g=Object.entries(f).map(([u,d])=>`adapter ${u} `+(d===!1?"is not supported by the environment":"is not available in the build"));let w=e?g.length>1?`since :
4
+ `+g.map(bp).join(`
5
+ `):" "+bp(g[0]):"as no adapter specified";throw new tt("There is no suitable adapter to dispatch the request "+w,"ERR_NOT_SUPPORT")}return m}const wp={getAdapter:n1,adapters:ku};function Su(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new Fa(null,t)}function xp(t){return Su(t),t.headers=jr.from(t.headers),t.data=Au.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),wp.getAdapter(t.adapter||Pa.adapter,t)(t).then(function(n){Su(t),t.response=n;try{n.data=Au.call(t,t.transformResponse,n)}finally{delete t.response}return n.headers=jr.from(n.headers),n},function(n){if(!lp(n)&&(Su(t),n&&n.response)){t.response=n.response;try{n.response.data=Au.call(t,t.transformResponse,n.response)}finally{delete t.response}n.response.headers=jr.from(n.response.headers)}return Promise.reject(n)})}const Fl={};["object","boolean","number","function","string","symbol"].forEach((t,n)=>{Fl[t]=function(e){return typeof e===t||"a"+(n<1?"n ":" ")+t}});const Cp={};Fl.transitional=function(t,n,e){function r(m,f){return"[Axios v"+_u+"] Transitional option '"+m+"'"+f+(e?". "+e:"")}return(m,f,g)=>{if(t===!1)throw new tt(r(f," has been removed"+(n?" in "+n:"")),tt.ERR_DEPRECATED);return n&&!Cp[f]&&(Cp[f]=!0,console.warn(r(f," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(m,f,g):!0}},Fl.spelling=function(t){return(n,e)=>(console.warn(`${e} is likely a misspelling of ${t}`),!0)};function r1(t,n,e){if(typeof t!="object")throw new tt("options must be an object",tt.ERR_BAD_OPTION_VALUE);const r=Object.keys(t);let m=r.length;for(;m-- >0;){const f=r[m],g=Object.prototype.hasOwnProperty.call(n,f)?n[f]:void 0;if(g){const w=t[f],u=w===void 0||g(w,f,t);if(u!==!0)throw new tt("option "+f+" must be "+u,tt.ERR_BAD_OPTION_VALUE);continue}if(e!==!0)throw new tt("Unknown option "+f,tt.ERR_BAD_OPTION)}}const zl={assertOptions:r1,validators:Fl},Ti=zl.validators;let ps=class{constructor(n){this.defaults=n||{},this.interceptors={request:new sp,response:new sp}}async request(n,e){try{return await this._request(n,e)}catch(r){if(r instanceof Error){let m={};Error.captureStackTrace?Error.captureStackTrace(m):m=new Error;const f=(()=>{if(!m.stack)return"";const g=m.stack.indexOf(`
6
+ `);return g===-1?"":m.stack.slice(g+1)})();try{if(!r.stack)r.stack=f;else if(f){const g=f.indexOf(`
7
+ `),w=g===-1?-1:f.indexOf(`
8
+ `,g+1),u=w===-1?"":f.slice(w+1);String(r.stack).endsWith(u)||(r.stack+=`
9
+ `+f)}}catch{}}throw r}}_request(n,e){typeof n=="string"?(e=e||{},e.url=n):e=n||{},e=fs(this.defaults,e);const{transitional:r,paramsSerializer:m,headers:f}=e;r!==void 0&&zl.assertOptions(r,{silentJSONParsing:Ti.transitional(Ti.boolean),forcedJSONParsing:Ti.transitional(Ti.boolean),clarifyTimeoutError:Ti.transitional(Ti.boolean),legacyInterceptorReqResOrdering:Ti.transitional(Ti.boolean)},!1),m!=null&&(xe.isFunction(m)?e.paramsSerializer={serialize:m}:zl.assertOptions(m,{encode:Ti.function,serialize:Ti.function},!0)),e.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?e.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:e.allowAbsoluteUrls=!0),zl.assertOptions(e,{baseUrl:Ti.spelling("baseURL"),withXsrfToken:Ti.spelling("withXSRFToken")},!0),e.method=(e.method||this.defaults.method||"get").toLowerCase();let g=f&&xe.merge(f.common,f[e.method]);f&&xe.forEach(["delete","get","head","post","put","patch","query","common"],o=>{delete f[o]}),e.headers=jr.concat(g,f);const w=[];let u=!0;this.interceptors.request.forEach(function(o){if(typeof o.runWhen=="function"&&o.runWhen(e)===!1)return;u=u&&o.synchronous;const s=e.transitional||wu;s&&s.legacyInterceptorReqResOrdering?w.unshift(o.fulfilled,o.rejected):w.push(o.fulfilled,o.rejected)});const d=[];this.interceptors.response.forEach(function(o){d.push(o.fulfilled,o.rejected)});let a,l=0,c;if(!u){const o=[xp.bind(this),void 0];for(o.unshift(...w),o.push(...d),c=o.length,a=Promise.resolve(e);l<c;)a=a.then(o[l++],o[l++]);return a}c=w.length;let h=e;for(;l<c;){const o=w[l++],s=w[l++];try{h=o(h)}catch(p){s.call(this,p);break}}try{a=xp.call(this,h)}catch(o){return Promise.reject(o)}for(l=0,c=d.length;l<c;)a=a.then(d[l++],d[l++]);return a}getUri(n){n=fs(this.defaults,n);const e=dp(n.baseURL,n.url,n.allowAbsoluteUrls);return op(e,n.params,n.paramsSerializer)}};xe.forEach(["delete","get","head","options"],function(t){ps.prototype[t]=function(n,e){return this.request(fs(e||{},{method:t,url:n,data:(e||{}).data}))}}),xe.forEach(["post","put","patch","query"],function(t){function n(e){return function(r,m,f){return this.request(fs(f||{},{method:t,headers:e?{"Content-Type":"multipart/form-data"}:{},url:r,data:m}))}}ps.prototype[t]=n(),t!=="query"&&(ps.prototype[t+"Form"]=n(!0))});let i1=class X0{constructor(n){if(typeof n!="function")throw new TypeError("executor must be a function.");let e;this.promise=new Promise(function(m){e=m});const r=this;this.promise.then(m=>{if(!r._listeners)return;let f=r._listeners.length;for(;f-- >0;)r._listeners[f](m);r._listeners=null}),this.promise.then=m=>{let f;const g=new Promise(w=>{r.subscribe(w),f=w}).then(m);return g.cancel=function(){r.unsubscribe(f)},g},n(function(m,f,g){r.reason||(r.reason=new Fa(m,f,g),e(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(n){if(this.reason){n(this.reason);return}this._listeners?this._listeners.push(n):this._listeners=[n]}unsubscribe(n){if(!this._listeners)return;const e=this._listeners.indexOf(n);e!==-1&&this._listeners.splice(e,1)}toAbortSignal(){const n=new AbortController,e=r=>{n.abort(r)};return this.subscribe(e),n.signal.unsubscribe=()=>this.unsubscribe(e),n.signal}static source(){let n;return{token:new X0(function(e){n=e}),cancel:n}}};function o1(t){return function(n){return t.apply(null,n)}}function s1(t){return xe.isObject(t)&&t.isAxiosError===!0}const $u={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries($u).forEach(([t,n])=>{$u[n]=t});function Ap(t){const n=new ps(t),e=Uf(ps.prototype.request,n);return xe.extend(e,ps.prototype,n,{allOwnKeys:!0}),xe.extend(e,n,null,{allOwnKeys:!0}),e.create=function(r){return Ap(fs(t,r))},e}const Gn=Ap(Pa);Gn.Axios=ps,Gn.CanceledError=Fa,Gn.CancelToken=i1,Gn.isCancel=lp,Gn.VERSION=_u,Gn.toFormData=Nl,Gn.AxiosError=tt,Gn.Cancel=Gn.CanceledError,Gn.all=function(t){return Promise.all(t)},Gn.spread=o1,Gn.isAxiosError=s1,Gn.mergeConfig=fs,Gn.AxiosHeaders=jr,Gn.formToJSON=t=>ap(xe.isHTMLForm(t)?new FormData(t):t),Gn.getAdapter=wp.getAdapter,Gn.HttpStatusCode=$u,Gn.default=Gn;const{Axios:L2,AxiosError:O2,CanceledError:N2,isCancel:D2,CancelToken:P2,VERSION:F2,all:z2,Cancel:B2,isAxiosError:W2,spread:j2,toFormData:H2,AxiosHeaders:U2,HttpStatusCode:V2,formToJSON:q2,getAdapter:G2,mergeConfig:K2,create:Y2}=Gn,Ru=Gn.create({baseURL:location.origin,timeout:6e4,params:{}});Ru.interceptors.response.use(t=>t,t=>{if(t.response){if(t.response.status===401&&OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity,!0).then(function(r){r&&OpenC3Auth.setTokens()}),t.response.config.headers["Ignore-Errors"]&&t.response.config.headers["Ignore-Errors"].includes(t.response.status.toString()))return Promise.reject(t);let n=`HTTP ${t.response.status} - `;t.response?.statusText&&(n+=`${t.response.statusText} `),t.response?.config?.data&&(n+=`${t.response.config.data} `),t.response?.data?.message?n+=`${t.response.data.message}`:t.response?.data?.exception?n+=`${t.response.data.exception}`:t.response?.data?.error?.message?(t.response.data.error.class&&(n+=`${t.response.data.error.class} `),n+=`${t.response.data.error.message}`):n+=`${t.response?.data}`;const{$cosmosNotify:e}=window;throw e&&e.serious({title:"Network error",body:n}),t}else throw t});const Bl=async function(t,n,{data:e,params:r={},headers:m,noAuth:f=!1,noScope:g=!1,onUploadProgress:w=!1}={}){if(!f){try{await OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity)&&OpenC3Auth.setTokens()}catch{OpenC3Auth.login()}m.Authorization=localStorage.openc3Token}return m.manual=!0,!g&&!r.scope&&(r.scope=window.openc3Scope),Ru({method:t,url:n,data:e,params:r,headers:m,onUploadProgress:w})},Eu={Accept:"application/json"},_p={...Eu,"Content-Type":"application/json"},J2=On("u",{get:function(t,{params:n,headers:e=Eu,noScope:r,noAuth:m,onUploadProgress:f}={}){return Bl("get",t,{params:n,headers:e,noScope:r,noAuth:m,onUploadProgress:f})},put:function(t,{data:n,params:e,headers:r=_p,noScope:m,noAuth:f,onUploadProgress:g}={}){return Bl("put",t,{data:n,params:e,headers:r,noScope:m,noAuth:f,onUploadProgress:g})},post:function(t,{data:n,params:e,headers:r=_p,noScope:m,noAuth:f,onUploadProgress:g}={}){return Bl("post",t,{data:n,params:e,headers:r,noScope:m,noAuth:f,onUploadProgress:g})},delete:function(t,{params:n,headers:e=Eu,noScope:r,noAuth:m,onUploadProgress:f}={}){return Bl("delete",t,{params:n,headers:e,noScope:r,noAuth:m,onUploadProgress:f})}});let Wl=()=>({emit(t,...n){for(let e=this.events[t]||[],r=0,m=e.length;r<m;r++)e[r](...n)},events:{},on(t,n){return(this.events[t]||=[]).push(n),()=>{this.events[t]=this.events[t]?.filter(e=>n!==e)}}}),za=class extends Error{constructor(n,e){n instanceof Error?(super(n.message),this.cause=n):super(n),this.reason=e,this.name="ReasonError"}},Tu=class extends za{constructor(n){super("Rejected",n),this.name="SubscriptionRejectedError"}};class a1 extends za{constructor(n){super(n||"Timed out to receive subscription ack"),this.name="SubscriptionTimeoutError"}}let Gi=class extends za{constructor(n,e){e?super(n,e):super("Disconnected",n),this.name="DisconnectedError"}};class l1 extends Gi{constructor(n){super(n,"stale_connection"),this.name="StaleConnectionError"}}function kp(t){return t?`{${Object.keys(t).sort().filter(n=>t[n]!==void 0).map(n=>{let e=JSON.stringify(t[n]);return`${JSON.stringify(n)}:${e}`}).join(",")}}`:""}let c1=class{constructor(n){this.channel=n,this.listeners=[]}watch(){this.listeners.push(this.channel.on("presence",n=>{if(n.type==="info"){this._state||(this._state=this.stateFromInfo(n));return}this._state&&(n.type==="join"?this._state[n.id]=n.info:n.type==="leave"&&delete this._state[n.id])}))}reset(){delete this._state}dispose(){delete this._info,delete this._state,this.listeners.forEach(n=>n()),this.listeners.length=0}async join(n,e){if(!this._info)return this._info={id:String(n),info:e},this.channel.perform("$presence:join",this._info)}async leave(){if(!this._info)return;let n=await this.channel.perform("$presence:leave");return delete this._info,n}async info(){return this._state?this._state:(this._promise||(this._promise=this._sync()),await this._promise,this._state)}async _sync(){this.watch();try{let n=await this.channel.perform("$presence:info",{});return this._state=this.stateFromInfo(n),this._state}finally{delete this._promise}}stateFromInfo(n){return n.records.reduce((e,{id:r,info:m})=>(e[r]=m,e),{})}};const gs=Symbol("state");let Sp=class{constructor(n={}){this.emitter=Wl(),this.params=Object.freeze(n),this.presence=new c1(this),this.initialConnect=!0,this[gs]="idle"}get identifier(){return this._identifier?this._identifier:(this._identifier=kp({channel:this.channelId,...this.params}),this._identifier)}get channelId(){return this.constructor.identifier}get state(){return this[gs]}attached(n){if(this.receiver){if(this.receiver!==n)throw Error("Already connected to a different receiver");return!1}return this.receiver=n,!0}connecting(){this[gs]="connecting"}connected(){if(this.state==="connected"||this.state==="closed")return;this[gs]="connected";let n=!1;this.initialConnect?(this.initialConnect=!1,this.emit("connect",{reconnect:!1,restored:n})):this.emit("connect",{reconnect:!0,restored:n})}restored(){if(this.state==="connected")throw Error("Already connected");this[gs]="connected";let n=!0,e=!0;this.initialConnect=!1,this.emit("connect",{reconnect:e,restored:n})}disconnected(n){this.state==="disconnected"||this.state==="closed"||(this[gs]="disconnected",this.presence.reset(),this.emit("disconnect",n))}closed(n){this.state!=="closed"&&(this[gs]="closed",delete this.receiver,this.initialConnect=!0,this.presence.dispose(),this.emit("close",n))}disconnect(){this.state==="idle"||this.state==="closed"||this.receiver.unsubscribe(this)}async perform(n,e){if(this.state==="idle"||this.state==="closed")throw Error("Channel is not subscribed");return this.receiver.perform(this.identifier,n,e)}async send(n){return this.perform(void 0,n)}async whisper(n){try{await this.perform("$whisper",n)}catch(e){let r=this.receiver?this.receiver.logger:null;r&&r.warn("whisper failed: ",e)}}receive(n,e){this.emit("message",n,e)}on(n,e){return this.emitter.on(n,e)}once(n,e){let r=this.emitter.on(n,(...m)=>{r(),e(...m)});return r}emit(n,...e){return this.emitter.emit(n,...e)}ensureSubscribed(){return this.state==="connected"?Promise.resolve():this.state==="closed"?Promise.reject(Error("Channel is unsubscribed")):this.pendingSubscribe()}pendingSubscribe(){return this._pendingSubscribe?this._pendingSubscribe:(this._pendingSubscribe=new Promise((n,e)=>{let r=[()=>delete this._pendingSubscribe];r.push(this.on("connect",()=>{r.forEach(m=>m()),n()})),r.push(this.on("close",m=>{r.forEach(f=>f()),e(m||new za("Channel was disconnected before subscribing","canceled"))}))}),this._pendingSubscribe)}},u1=class{constructor(n){this.id=n,this.intent="unsubscribed",this.state="idle",this.channels=[],this.disposed=!1,this._pendings=[]}add(n){this.channels.includes(n)||this.channels.push(n)}remove(n){let e=this.channels.indexOf(n);e>-1&&this.channels.splice(e,1)}notify(n,...e){this.state=n==="restored"?"connected":n,e.length===1?this.channels.forEach(r=>r[n](e[0])):this.channels.forEach(r=>r[n]())}pending(n){this._checkIntent(n);let e=this._pendings[0];return!e||e.intent!==n?Promise.resolve():e.promise}ensureResubscribed(){this.disposed||(this.intent=void 0,this.ensureSubscribed())}ensureSubscribed(){if(this.intent!=="subscribed"){if(this.disposed)throw Error("Subscription is disposed");this.intent="subscribed",!this._mergeWithPending("unsubscribed")&&this.subscriber(this)}}maybeUnsubscribe(){this.disposed||this.intent==="unsubscribed"||this.channels.length>0||(this.intent="unsubscribed",this._mergeWithPending("subscribed"))||this.unsubscriber(this)}async acquire(n){this._checkIntent(n);let e,r={promise:new Promise(f=>{e=f}),intent:n,release:()=>{this._pendings.splice(this._pendings.indexOf(r),1),e(r)},canceled:!1,acquired:!1},m=this._pendingTop;return this._pendings.push(r),m&&await m.promise,this.gvl&&await this.gvl.acquire(r,n),r.acquired=!0,r}close(n){this.disposed=!0,this.intent=void 0,this.notify("closed",n)}_checkIntent(n){if(!(n==="unsubscribed"||n==="subscribed"))throw Error(`Unknown subscription intent: ${n}`)}get _pendingTop(){return this._pendings.length?this._pendings[this._pendings.length-1]:void 0}_mergeWithPending(n){let e=this._pendingTop;return!e||e.acquired||e.intent!==n?!1:(this._pendings.pop(),e.canceled=!0,!0)}};class h1{constructor(){this.queue=[]}async acquire(n,e){e==="subscribed"&&(this.queue.push(n.promise.then(()=>{this.queue.splice(this.queue.indexOf(n),1)})),this.queue.length>1&&await this.queue[this.queue.length-2])}}class d1{constructor(n){n.concurrentSubscribes===!1&&(this.glv=new h1),this._subscriptions={},this._localToRemote={}}all(){return Object.values(this._subscriptions)}get(n){return this._subscriptions[n]}create(n,{subscribe:e,unsubscribe:r}){let m=this._subscriptions[n]=new u1(n);return m.remoteId=this._localToRemote[n],m.subscriber=e,m.unsubscriber=r,m.gvl=this.glv,m}remove(n){delete this._subscriptions[n],delete this._localToRemote[n]}storeRemoteId(n,e){this._localToRemote[n]=e;let r=this.get(n);r&&(r.remoteId=e)}}class f1{constructor(n={}){this.subscriptions=new d1(n),this._pendingMessages=[],this._remoteToLocal={}}subscribe(n,e){this._remoteToLocal[e]=n,this.subscriptions.storeRemoteId(n,e),this.flush(e)}unsubscribe(n){let e=this.subscriptions.get(n);if(!e)return;let r=e.remoteId;r&&delete this._remoteToLocal[r],this.subscriptions.remove(n)}transmit(n,e,r){let m=this._remoteToLocal[n];if(!m){this._pendingMessages.push([n,e,r]);return}let f=this.subscriptions.get(m);f&&f.channels.forEach(g=>{g.receive(e,r)})}notify(n,e,r){let m=this._remoteToLocal[n];if(!m)return;let f=this.subscriptions.get(m);f&&f.channels.forEach(g=>g.emit(e,r))}close(){this._pendingMessages.length=0}get size(){return this.channels.length}get channels(){return this.subscriptions.all().flatMap(n=>n.channels)}flush(n){let e=[];for(let r of this._pendingMessages)r[0]===n?this.transmit(r[0],r[1],r[2]):e.push(r);this._pendingMessages=e}}const $p={debug:0,info:1,warn:2,error:3};let Rp=class{constructor(n){this.level=n||"warn"}log(n,e,r){$p[n]<$p[this.level]||this.writeLogEntry(n,e,r)}writeLogEntry(){throw Error("Not implemented")}debug(n,e){this.log("debug",n,e)}info(n,e){this.log("info",n,e)}warn(n,e){this.log("warn",n,e)}error(n,e){this.log("error",n,e)}},Ba=class extends Rp{writeLogEntry(){}};class p1{encode(n){return JSON.stringify(n)}decode(n){try{return JSON.parse(n)}catch{}}}let g1=0,Ep=class{constructor(n={}){let{logger:e}=n;this.logger=e||new Ba,this.pendingSubscriptions={},this.pendingUnsubscriptions={},this.subscribeCooldownInterval=n.subscribeCooldownInterval||250,this.subscribeRetryInterval=n.subscribeRetryInterval||5e3}attached(n){this.cable=n}subscribe(n,e){let r={channel:n};e&&Object.assign(r,e);let m=kp(r);if(this.pendingUnsubscriptions[m]){let g=this.subscribeCooldownInterval*1.5;return this.logger.debug(`unsubscribed recently, cooldown for ${g}`,m),new Promise(w=>{setTimeout(()=>{w(this.subscribe(n,e))},g)})}if(this.pendingSubscriptions[m])return this.logger.warn("subscription is already pending, skipping",m),Promise.reject(Error("Already subscribing"));let f=this.subscribeRetryInterval;return new Promise((g,w)=>{let u=++g1;this.pendingSubscriptions[m]={resolve:g,reject:w,id:u},this.cable.send(this.buildSubscribeRequest(m)),this.maybeRetrySubscribe(u,m,f)})}buildSubscribeRequest(n){return{command:"subscribe",identifier:n}}maybeRetrySubscribe(n,e,r){setTimeout(()=>{let m=this.pendingSubscriptions[e];m&&m.id===n&&(this.logger.warn(`no subscription ack received in ${r}ms, retrying subscribe`,e),this.cable.send(this.buildSubscribeRequest(e)),this.maybeExpireSubscribe(n,e,r))},r)}maybeExpireSubscribe(n,e,r){setTimeout(()=>{let m=this.pendingSubscriptions[e];m&&m.id===n&&(delete this.pendingSubscriptions[e],m.reject(new a1(`Haven't received subscription ack in ${r*2}ms for ${e}`)))},r)}unsubscribe(n){return this.cable.send({command:"unsubscribe",identifier:n}),this.pendingUnsubscriptions[n]=!0,setTimeout(()=>{delete this.pendingUnsubscriptions[n]},this.subscribeCooldownInterval),Promise.resolve()}perform(n,e,r){return e==="$whisper"?this.whisper(n,r):(r||(r={}),r.action||=e,this.cable.send({command:"message",identifier:n,data:JSON.stringify(r)}),Promise.resolve())}whisper(n,e){return this.cable.send({command:"whisper",identifier:n,data:e}),Promise.resolve()}receive(n){if(typeof n!="object"){this.logger.error("unsupported message format",{message:n});return}let{type:e,identifier:r,message:m,reason:f,reconnect:g}=n;if(e==="ping")return this.cable.keepalive(n.message);if(this.cable.keepalive(),e==="welcome"){let w=n.sid;return w&&this.cable.setSessionId(w),this.cable.connected()}if(e==="disconnect"){let w=new Gi(f);this.reset(w),g===!1?this.cable.closed(w):this.cable.disconnected(w);return}if(e==="confirm_subscription"){let w=this.pendingSubscriptions[r];if(!w){this.logger.error("subscription not found, unsubscribing",{type:e,identifier:r}),this.unsubscribe(r);return}return delete this.pendingSubscriptions[r],w.resolve(r)}if(e==="reject_subscription"){let w=this.pendingSubscriptions[r];return w?(delete this.pendingSubscriptions[r],w.reject(new Tu)):this.logger.error("subscription not found",{type:e,identifier:r})}if(m)return{identifier:r,message:m};this.logger.warn(`unknown message type: ${e}`,{message:n})}reset(n){for(let e in this.pendingSubscriptions)this.pendingSubscriptions[e].reject(n);this.pendingSubscriptions={}}recoverableClosure(){return!1}};const Tp=()=>Date.now()/1e3|0;class m1 extends Ep{constructor(n={}){super(n),this.streamsPositions={},this.subscriptionStreams={},this.pendingHistory={},this.pendingPresence={},this.presenceInfo={},this.restoreSince=n.historyTimestamp,this.disableSessionRecovery=n.disableSessionRecovery,this.restoreSince===void 0&&(this.restoreSince=Tp()),this.sessionId=void 0,this.sendPongs=n.pongs}reset(n){for(let e in this.pendingPresence)this.pendingPresence[e].reject(n);return this.pendingPresence={},super.reset()}receive(n){if(typeof n!="object"){this.logger.error("unsupported message format",{message:n});return}let{type:e,identifier:r,message:m}=n;if(e==="disconnect")return delete this.sessionId,this.cable.setSessionId(""),super.receive(n);if(e==="reject_subscription")return super.receive(n);if(e==="confirm_subscription")return this.subscriptionStreams[r]||(this.subscriptionStreams[r]=new Set),super.receive(n);if(e==="ping")return this.restoreSince&&(this.restoreSince=Tp()),this.sendPongs&&this.sendPong(),this.cable.keepalive(n.message);if(this.cable.keepalive(),e==="confirm_history"){this.logger.debug("history result received",n),this.cable.notify("history_received",r);return}if(e==="reject_history"){this.logger.warn("failed to retrieve history",n),this.cable.notify("history_not_found",r);return}if(e==="welcome"){if(this.disableSessionRecovery||(this.sessionId=n.sid,this.sessionId&&this.cable.setSessionId(this.sessionId)),n.restored){let f=n.restored_ids||Object.keys(this.subscriptionStreams);for(let g of f)this.cable.send({identifier:g,command:"history",history:this.historyRequestFor(g)}),this.presenceInfo[g]&&this.cable.send({identifier:g,command:"join",presence:this.presenceInfo[g]});return this.cable.restored(f)}return this.cable.connected(this.sessionId)}if(e==="presence"){let f=m.type;if(f==="info"){let g=this.pendingPresence[r];g&&(delete this.pendingPresence[r],g.resolve(m))}else if(f==="error"){let g=this.pendingPresence[r];g&&(delete this.pendingPresence[r],g.reject(new Error("failed to retrieve presence")))}return{type:e,identifier:r,message:m}}if(m){let f=this.trackStreamPosition(r,n.stream_id,n.epoch,n.offset);return{identifier:r,message:m,meta:f}}this.logger.warn(`unknown message type: ${e}`,{message:n})}perform(n,e,r){switch(e){case"$presence:join":return this.join(n,r);case"$presence:leave":return this.leave(n,r);case"$presence:info":return this.presence(n,r)}return super.perform(n,e,r)}unsubscribe(n){return delete this.presenceInfo[n],super.unsubscribe(n)}buildSubscribeRequest(n){let e=super.buildSubscribeRequest(n),r=this.historyRequestFor(n);r&&(e.history=r,this.pendingHistory[n]=!0);let m=this.presenceInfo[n];return m&&(e.presence=m),e}recoverableClosure(){return!!this.sessionId}historyRequestFor(n){let e={},r=!1;if(this.subscriptionStreams[n])for(let m of this.subscriptionStreams[n]){let f=this.streamsPositions[m];f&&(r=!0,e[m]=f)}if(!(!r&&!this.restoreSince))return{since:this.restoreSince,streams:e}}trackStreamPosition(n,e,r,m){if(!(!e||!r))return this.subscriptionStreams[n]||(this.subscriptionStreams[n]=new Set),this.subscriptionStreams[n].add(e),this.streamsPositions[e]={epoch:r,offset:m},{stream:e,epoch:r,offset:m}}async sendPong(){await new Promise(n=>setTimeout(n,0)),this.cable.state==="connected"&&this.cable.send({command:"pong"})}async join(n,e){return this.presenceInfo[n]=e,this.cable.send({command:"join",identifier:n,presence:e}),Promise.resolve()}async leave(n,e){return delete this.presenceInfo[n],this.cable.send({command:"leave",identifier:n,presence:e}),Promise.resolve()}presence(n,e){return this.pendingPresence[n]?(this.logger.warn("presence is already pending, skipping",n),Promise.reject(Error("presence request is already pending"))):new Promise((r,m)=>{this.pendingPresence[n]={resolve:r,reject:m},this.cable.send({command:"presence",identifier:n,data:e})})}}let v1=class extends za{constructor(){super("No connection","closed"),this.name="NoConnectionError"}},Mp=class extends Sp{static identifier="__ghost__";constructor(n,e){super(e),this.channelId=n}set channelId(n){this._channelId=n}get channelId(){return this._channelId}};const y1="$pubsub";let Ip=class extends Sp{static identifier=y1;async perform(n,e){if(n.startsWith("$"))return super.perform(n,e);throw Error("not implemented")}};const ms=Symbol("state");let b1=class{constructor({transport:t,protocol:n,encoder:e,logger:r,lazy:m,hubOptions:f,performFailures:g,transportConfigurator:w}){this.emitter=Wl(),this.transport=t,this.encoder=e,this.logger=r||new Ba,this.protocol=n,this.performFailures=g||"throw",this.protocol.attached(this),this.hub=new f1(f||{}),this[ms]="idle",this.handleClose=this.handleClose.bind(this),this.handleIncoming=this.handleIncoming.bind(this),this.transportConfigurator=w,this.transport.on("close",this.handleClose),this.transport.on("data",this.handleIncoming),this.initialConnect=!0,this.recovering=!1,m===!1&&this.connect().catch(()=>{})}get state(){return this[ms]}async connect(){if(this.state==="connected")return Promise.resolve();if(this.state==="connecting")return this.pendingConnect();let t=this.state==="idle";this[ms]="connecting";let n=this.pendingConnect();this.logger.debug("connecting");try{this.transportConfigurator&&await this.transportConfigurator(this.transport,{initial:t}),await this.transport.open()}catch(e){this.handleClose(e)}return n}setSessionId(t){this.sessionId=t,this.transport.setParam("sid",t)}connected(){if(this.state==="connected")return;this.logger.info("connected"),this[ms]="connected",this.recovering&&this.hub.subscriptions.all().forEach(n=>n.notify("disconnected",new Gi("recovery_failed"))),this.hub.subscriptions.all().forEach(n=>this._resubscribe(n));let t=!1;this.recovering=!1,this.initialConnect?(this.initialConnect=!1,this.emit("connect",{reconnect:!1,restored:t})):this.emit("connect",{reconnect:!0,restored:t})}restored(t){this.logger.info("connection recovered",{remoteIds:t}),this[ms]="connected",this.hub.subscriptions.all().forEach(r=>{t&&r.remoteId&&t.includes(r.remoteId)?r.notify("restored"):(r.notify("disconnected",new Gi("recovery_failed")),this._resubscribe(r))});let n=!this.initialConnect,e=!0;this.recovering=!1,this.initialConnect=!1,this.emit("connect",{reconnect:n,restored:e})}notify(t,n,e){n&&typeof n!="string"&&(e=n,n=void 0),n?this.hub.notify(n,"info",{type:t,data:e}):this.emit("info",{type:t,data:e})}handleClose(t){this.logger.debug("transport closed",{error:t}),this.disconnected(new Gi(t,"transport_closed"))}disconnected(t){(this.state==="connected"||this.state==="connecting")&&(this.logger.info("disconnected",{reason:t}),this[ms]="disconnected",this.recovering=this.protocol.recoverableClosure(t),this.recovering?this.hub.subscriptions.all().forEach(n=>n.notify("connecting")):this.hub.subscriptions.all().forEach(n=>{n.notify("disconnected",t)}),this.protocol.reset(t),this.hub.close(),this.transport.close(),this.emit("disconnect",t))}closed(t){if(this.state==="closed"||this.state==="idle")return;let n;t&&(n=t instanceof Gi?t:new Gi(t,void 0)),this.logger.info("closed",{reason:t||"user"}),this[ms]="closed";let e=n||new Gi("cable_closed");this.hub.subscriptions.all().forEach(r=>r.notify("disconnected",e)),this.hub.close(),this.protocol.reset(),this.transport.close(),this.initialConnect=!0,this.emit("close",n)}disconnect(){this.closed()}handleIncoming(t){if(this.state==="closed"||this.state==="idle")return;let n=this.encoder.decode(t);if(n===void 0){this.logger.error("failed to decode message",{message:t});return}this.logger.debug("incoming data",n);let e=this.protocol.receive(n);if(e){this.logger.debug("processed incoming message",e);let{type:r,identifier:m,message:f,meta:g}=e;r?this.hub.notify(m,r,f):this.hub.transmit(m,f,g)}}send(t){if(this.state==="closed")throw Error("Cable is closed");let n=this.encoder.encode(t);if(n===void 0){this.logger.error("failed to encode message",{message:t});return}this.logger.debug("outgoing message",t),this.transport.send(n)}keepalive(t){this.emit("keepalive",t)}streamFrom(t){let n=new Ip({stream_name:t});return this.subscribe(n)}streamFromSigned(t){let n=new Ip({signed_stream_name:t});return this.subscribe(n)}subscribeTo(t,n){let e,r;return typeof t=="string"&&(r=t,t=Mp),e=r?new t(r,n):new t(n),this.subscribe(e)}subscribe(t){if(!t.attached(this))return t;let n=t.identifier;t.connecting();let e=this.hub.subscriptions.get(n)||this.hub.subscriptions.create(n,{subscribe:r=>this._subscribe(r,t.channelId,t.params),unsubscribe:r=>this._unsubscribe(r)});return e.add(t),e.intent==="subscribed"&&e.state==="connected"&&t.connected(),e.ensureSubscribed(),t}async _resubscribe(t){t.intent!=="subscribed"||!t.channels[0]||(t.notify("connecting"),t.ensureResubscribed())}async _subscribe(t,n,e){let r=t.id;if(this.state==="idle"&&this.connect().catch(()=>{}),this.state!=="connected"){this.logger.debug("cancel subscribe, no connection",{identifier:r});return}this.logger.debug("acquiring subscribe lock",{identifier:r});let m=await t.acquire("subscribed");if(m.canceled){this.logger.debug("subscribe lock has been canceled",{identifier:r}),m.release();return}if(this.logger.debug("subscribe lock has been acquired",{identifier:r}),t.intent!=="subscribed"){this.logger.debug("cancel subscribe request, already unsubscribed"),m.release();return}if(this.state!=="connected"){this.logger.debug("cancel subscribe, no connection",{identifier:r}),m.release();return}if(t.state==="connected"){this.logger.debug("already connected, skip subscribe command",{identifier:r}),t.notify("connected"),m.release();return}let f={identifier:n,params:e};this.logger.debug("subscribing",f);try{let g=await this.protocol.subscribe(n,e);this.hub.subscribe(r,g),this.logger.debug("subscribed",{...f,remoteId:g}),t.notify("connected")}catch(g){if(g){if(g instanceof Tu&&this.logger.warn("rejected",f),g instanceof Gi){this.logger.debug("disconnected during subscription; will retry on connect",f),m.release();return}this.logger.error("failed to subscribe",{error:g,...f})}t.close(g),this.hub.unsubscribe(r)}m.release()}unsubscribe(t){let n=t.identifier,e=this.hub.subscriptions.get(n);if(!e)throw Error(`Subscription not found: ${n}`);e.remove(t),t.closed(),e.maybeUnsubscribe()}async _unsubscribe(t){let n=t.id;this.logger.debug("acquiring unsubscribe lock",{identifier:n});let e=await t.acquire("unsubscribed");if(e.canceled){this.logger.debug("unsubscribe lock has been canceled",{identifier:n}),e.release();return}if(this.logger.debug("unsubscribe lock has been acquired",{identifier:n}),t.intent!=="unsubscribed"){this.logger.debug("cancel unsubscribe, no longer needed",{identifier:n,intent:t.intent}),e.release();return}if(t.state==="disconnected"||t.state==="closed"){this.logger.debug(`already ${t.state} connected, skip unsubscribe command`,{identifier:n}),e.release();return}let r=t.remoteId;if(this.logger.debug("unsubscribing...",{remoteId:r}),this.state!=="connected"){this.logger.debug("unsubscribe skipped (cable is not connected)",{id:n}),t.close(),this.hub.unsubscribe(n),e.release();return}try{await this.protocol.unsubscribe(r),this.logger.debug("unsubscribed remotely",{id:n})}catch(m){m&&(m instanceof Gi?this.logger.debug("cable disconnected during the unsubscribe command execution",{id:n,error:m}):this.logger.error("unsubscribe failed",{id:n,error:m}))}t.intent==="unsubscribed"?(t.close(),this.hub.unsubscribe(n)):t.state="closed",e.release()}async perform(t,n,e){if(this.performFailures==="throw")return this._perform(t,n,e);try{return await this._perform(t,n,e)}catch(r){this.performFailures==="warn"&&this.logger.warn("perform failed",{error:r});return}}async _perform(t,n,e){if(this.state==="connecting"&&await this.pendingConnect(),this.state==="closed"||this.state==="disconnected")throw new v1;let r=this.hub.subscriptions.get(t);if(!r)throw Error(`Subscription not found: ${t}`);if(await r.pending("subscribed"),r.intent!=="subscribed")throw Error(`Subscription is closed: ${t}`);let m=r.remoteId,f={id:m,action:n,payload:e};this.logger.debug("perform",f);try{let g=await this.protocol.perform(m,n,e);return g&&this.logger.debug("perform result",{message:g,request:f}),g}catch(g){throw this.logger.error("perform failed",{error:g,request:f}),g}}on(t,n){return this.emitter.on(t,n)}once(t,n){let e=this.emitter.on(t,(...r)=>{e(),n(...r)});return e}emit(t,...n){return this.emitter.emit(t,...n)}pendingConnect(){return this._pendingConnect?this._pendingConnect:(this._pendingConnect=new Promise((t,n)=>{let e=[()=>delete this._pendingConnect];e.push(this.on("connect",()=>{e.forEach(r=>r()),t()})),e.push(this.on("close",r=>{e.forEach(m=>m()),n(r)})),e.push(this.on("disconnect",r=>{e.forEach(m=>m()),n(r)}))}),this._pendingConnect)}};const w1={maxMissingPings:2,maxReconnectAttempts:1/0},Ys=()=>Date.now(),Lp=(t,n)=>{n=n||{};let{backoffRate:e,jitterRatio:r,maxInterval:m}=n;return e=e||2,r===void 0&&(r=.5),f=>{let g=t*e**f,w=g*e,u=g+(w-g)*Math.random(),d=2*(Math.random()-.5)*r;return u=u*(1+d),m&&m<u&&(u=m),u}};let Op=class{constructor({pingInterval:n,...e}){if(this.pingInterval=n,!this.pingInterval)throw Error(`Incorrect pingInterval is provided: ${n}`);if(e=Object.assign({},w1,e),this.strategy=e.reconnectStrategy,!this.strategy)throw Error("Reconnect strategy must be provided");this.maxMissingPings=e.maxMissingPings,this.maxReconnectAttempts=e.maxReconnectAttempts,this.logger=e.logger||new Ba,this.state="pending_connect",this.attempts=0,this.disconnectedAt=Ys()}watch(n){this.target=n,this.initListeners()}reconnectNow(){return this.state==="connected"||this.state==="pending_connect"||this.state==="closed"?!1:(this.cancelReconnect(),this.state="pending_connect",this.target.connect().catch(n=>{this.logger.info("Failed at reconnecting: "+n)}),!0)}initListeners(){this.unbind=[],this.unbind.push(this.target.on("connect",()=>{this.attempts=0,this.pingedAt=Ys(),this.state="connected",this.cancelReconnect(),this.startPolling()})),this.unbind.push(this.target.on("disconnect",()=>{this.disconnectedAt=Ys(),this.state="disconnected",this.stopPolling(),this.scheduleReconnect()})),this.unbind.push(this.target.on("close",()=>{this.disconnectedAt=Ys(),this.state="closed",this.cancelReconnect(),this.stopPolling()})),this.unbind.push(this.target.on("keepalive",()=>{this.pingedAt=Ys()})),this.unbind.push(()=>{this.cancelReconnect(),this.stopPolling()})}dispose(){delete this.target,this.unbind&&this.unbind.forEach(n=>n()),delete this.unbind}startPolling(){this.pollId&&clearTimeout(this.pollId);let n=this.pingInterval+(Math.random()-.5)*this.pingInterval*.5;this.pollId=setTimeout(()=>{this.checkStale(),this.state==="connected"&&this.startPolling()},n)}stopPolling(){this.pollId&&clearTimeout(this.pollId)}checkStale(){let n=Ys()-this.pingedAt;n>this.maxMissingPings*this.pingInterval&&(this.logger.warn(`Stale connection: ${n}ms without pings`),this.state="pending_disconnect",this.target.disconnected(new l1))}scheduleReconnect(){if(this.attempts>=this.maxReconnectAttempts){this.target.close();return}let n=this.strategy(this.attempts);this.attempts++,this.logger.info(`Reconnecting in ${n}ms (${this.attempts} attempt)`),this.state="pending_reconnect",this.reconnnectId=setTimeout(()=>this.reconnectNow(),n)}cancelReconnect(){this.reconnnectId&&(clearTimeout(this.reconnnectId),delete this.reconnnectId)}},x1=class{constructor(n,e={}){this.transports=n,this.transport=null,this.emitter=Wl(),this.unbind=[],this.logger=e.logger||new Ba}displayName(){return"fallbacked transport"}async open(){for(let n=0;n<this.transports.length;n++){let e=this.transports[n];try{this.transport=e,this.resetListeners(),this.logger.debug(`Trying to connect via ${e.displayName()}`),await e.open(),this.logger.debug(`Connected via ${e.displayName()}`);return}catch(r){this.logger.debug(`Failed to connect via ${e.displayName()}: ${r.message}`)}}throw this.transport=null,this.resetListeners(),new Error("Couldn't connect via any available transport")}send(n){if(!this.transport)throw new Error("No transport is open");this.transport.send(n)}async close(){if(!this.transport)throw new Error("No transport is open");await this.transport.close(),this.transport=null}setURL(){throw new Error("Not implemented. Set URL for each transport separately")}setParam(n,e){this.transports.forEach(r=>{r.setParam(n,e)})}setToken(n,e){this.transports.forEach(r=>{r.setToken(n,e)})}on(n,e){return this.emitter.on(n,e)}once(n,e){let r=this.emitter.on(n,(...m)=>{r(),e(...m)});return r}get url(){return this.transport?this.transport.url:""}resetListeners(){this.unbind.forEach(n=>n()),this.unbind.length=0,this.transport&&this.unbind.push(this.transport.on("open",()=>{this.emitter.emit("open")}),this.transport.on("data",n=>{this.emitter.emit("data",n)}),this.transport.on("close",n=>{this.emitter.emit("close",n)}),this.transport.on("error",n=>{this.emitter.emit("error",n)}))}};class C1{constructor(n,e={}){this.url=n;let r=e.websocketImplementation;if(r)this.Impl=r;else if(typeof WebSocket<"u")this.Impl=WebSocket;else throw new Error("No WebSocket support");this.connected=!1,this.emitter=Wl();let{format:m,subprotocol:f,authStrategy:g}=e;this.format=m||"text",this.connectionOptions=e.websocketOptions,this.authStrategy=g||"param",this.authProtocol="",this.subprotocol=f}displayName(){return"WebSocket("+this.url+")"}open(){let n=this.subprotocol;return this.authStrategy==="sub-protocol"&&(n=[this.subprotocol,this.authProtocol]),this.connectionOptions?this.ws=new this.Impl(this.url,n,this.connectionOptions):this.ws=new this.Impl(this.url,n),this.ws.binaryType="arraybuffer",this.initListeners(),new Promise((e,r)=>{let m=[];m.push(this.once("open",()=>{m.forEach(f=>f()),e()})),m.push(this.once("close",()=>{m.forEach(f=>f()),r(Error("WS connection closed"))}))})}setURL(n){this.url=n}setParam(n,e){let r=new URL(this.url);r.searchParams.set(n,e);let m=`${r.protocol}//${r.host}${r.pathname}?${r.searchParams}`;this.setURL(m)}setToken(n,e="jid"){if(this.authStrategy==="param")this.setParam(e,n);else if(this.authStrategy==="header"){this.connectionOptions=this.connectionOptions||{},this.connectionOptions.headers=this.connectionOptions.headers||{};let r=`x-${e}`.toLowerCase();r=Object.keys(this.connectionOptions.headers).find(m=>m.toLowerCase()===r)||r,this.connectionOptions.headers[r]=n}else if(this.authStrategy==="sub-protocol")this.authProtocol=`anycable-token.${n}`;else throw new Error("Unknown auth strategy: "+this.authStrategy)}send(n){if(!this.ws||!this.connected)throw Error("WebSocket is not connected");this.ws.send(n)}close(){this.ws?this.onclose():this.connected=!1}on(n,e){return this.emitter.on(n,e)}once(n,e){let r=this.emitter.on(n,(...m)=>{r(),e(...m)});return r}initListeners(){this.ws.onerror=n=>{this.connected&&this.emitter.emit("error",n.error||new Error("WS Error"))},this.ws.onclose=()=>{this.onclose()},this.ws.onmessage=n=>{let e=n.data;this.format==="binary"&&(e=new Uint8Array(e)),this.emitter.emit("data",e)},this.ws.onopen=()=>{this.connected=!0,this.emitter.emit("open")}}onclose(){this.ws.onclose=void 0,this.ws.onmessage=void 0,this.ws.onopen=void 0,this.ws.close(),delete this.ws,this.connected=!1,this.emitter.emit("close")}}class A1{constructor(n){this.channel=n}notify(n,...e){typeof this[n]=="function"&&this[n](...e)}perform(n,e={}){this.channel.perform(n,e)}send(n){this.channel.send(n)}whisper(n){return this.channel.whisper(n)}get identifier(){return this.channel.identifier}unsubscribe(){return this.channel.disconnect()}}class _1 extends Mp{constructor(n,e,r){super(n,e),this.subscription=new A1(this),Object.assign(this.subscription,r),this.on("connect",({reconnect:m})=>this.subscription.notify("connected",{reconnected:m})),this.on("disconnect",()=>this.subscription.notify("disconnected",{allowReconnect:!0})),this.on("message",m=>this.subscription.notify("received",m)),this.on("close",m=>{m&&m instanceof Tu?this.subscription.notify("rejected"):this.subscription.notify("disconnected",{allowReconnect:!1})})}}class k1{constructor(n){this.cable=n}create(n,e){let r,m;typeof n=="object"?(r=n.channel,delete n.channel,m=n):(r=n,m={});let f=new _1(r,m,e);return f.subscription.notify("initialized"),this.cable.subscribe(f),f.subscription}findAll(n){return this.cable.hub.channels.filter(e=>e.identifier===n).map(e=>e.subscription)}}class S1{constructor(n){this.cable=n,this.subscriptions=new k1(n)}send(n){return this.cable.send(n)}connect(){return this.cable.connect()}disconnect(){return this.cable.disconnect()}ensureActiveConnection(){return this.cable.connect()}}const Np={protocol:"actioncable-v1-json",pingInterval:3e3,maxReconnectAttempts:1/0,maxMissingPings:2,logLevel:"warn",lazy:!0};function $1(t,n){if(typeof t=="object"&&typeof n>"u"&&(n=t,t=void 0),n=n||{},!t&&!n.transport)throw Error("URL or transport must be specified");n=Object.assign({},Np,n);let{protocol:e,websocketImplementation:r,websocketFormat:m,websocketOptions:f,websocketAuthStrategy:g,fallbacks:w,logLevel:u,logger:d,transport:a,encoder:l,lazy:c,monitor:h,pingInterval:o,reconnectStrategy:s,maxMissingPings:p,maxReconnectAttempts:b,subprotocol:x,tokenRefresher:M,historyTimestamp:R,protocolOptions:k,concurrentSubscribes:C,performFailures:L,transportConfigurator:D,auth:I}=n;if(d=d||new Ba(u),typeof e=="string"){x=x||e;let F=e.substring(0,e.lastIndexOf("-")),O=e.substring(e.lastIndexOf("-")+1);if(k=k||{},F==="actioncable-v1")e=new Ep({logger:d,...k});else if(F==="actioncable-v1-ext")e=new m1({logger:d,historyTimestamp:R,...k});else throw Error(`Protocol is not supported yet: ${e}`);if(O==="json")l=l||new p1,m=m||"text";else if(O==="msgpack"){if(m="binary",!l)throw Error("Msgpack encoder must be specified explicitly. Use `@anycable/msgpack-encoder` package or build your own")}else if(O==="protobuf"){if(m=m||"binary",!l)throw Error("Protobuf encoder must be specified explicitly. Use `@anycable/protobuf-encoder` package or build your own")}else throw Error(`Protocol is not supported yet: ${e}`)}if(!e)throw Error("Protocol must be specified");a=a||new C1(t,{websocketImplementation:r,websocketOptions:f,subprotocol:x,authStrategy:g,format:m}),w&&(a=new x1([a,...w],{logger:d})),I&&I.token&&a.setToken(I.token,I.param||"jid"),s=s||Lp(o),h!==!1&&(h=h||new Op({pingInterval:o,reconnectStrategy:s,maxMissingPings:p,maxReconnectAttempts:b,logger:d}));let T={concurrentSubscribes:C},W=new b1({protocol:e,transport:a,encoder:l,logger:d,lazy:c,hubOptions:T,performFailures:L,transportConfigurator:D});return h&&(h.watch(W),W.monitor=h),M&&R1(W,async()=>{try{await M(a)}catch(F){return d.error("Failed to refresh authentication token: "+F),!1}return W.connect().catch(()=>{}),!0}),W}function R1(t,n){let e=!1;t.on("connect",()=>e=!1),t.on("close",async r=>{if(r){if(e){t.logger.warn("Token auto-refresh is disabled",r);return}r.reason==="token_expired"&&(e=!0,await n())}})}class E1 extends Rp{writeLogEntry(n,e,r){r?console[n](e,r):console[n](e)}}class T1 extends Op{watch(n){super.watch(n),this.initActivityListeners()}initActivityListeners(){if(typeof document<"u"&&typeof window<"u"&&document.addEventListener&&window.addEventListener){let n=()=>{document.hidden||this.reconnectNow()&&this.logger.debug("Trigger reconnect due to visibility change")},e=m=>{this.reconnectNow()&&this.logger.debug("Trigger reconnect",{event:m})},r=()=>this.disconnect(new Gi("page_frozen"));document.addEventListener("visibilitychange",n,!1),window.addEventListener("focus",e,!1),window.addEventListener("online",e,!1),window.addEventListener("resume",e,!1),window.addEventListener("freeze",r,!1),this.unbind.push(()=>{document.removeEventListener("visibilitychange",n,!1),window.removeEventListener("focus",e,!1),window.removeEventListener("online",e,!1),window.removeEventListener("resume",e,!1),window.removeEventListener("freeze",r,!1)})}}disconnect(n){this.state==="disconnected"||this.state==="closed"||(this.logger.info("Disconnecting",{reason:n.message}),this.cancelReconnect(),this.stopPolling(),this.state="pending_disconnect",this.target.disconnected(n))}}const M1=["cable","action-cable"],I1="/cable",jl=(t,n)=>{for(let e of M1){let r=t.head.querySelector(`meta[name='${e}-${n}']`);if(r)return r.getAttribute("content")}},Dp=t=>t.match(/wss?:\/\//)?t:typeof window<"u"?`${window.location.protocol.replace("http","ws")}//${window.location.host}${t}`:t,L1=()=>{if(typeof document<"u"&&document.head){let t=jl(document,"url");if(t)return Dp(t)}return Dp(I1)},O1=()=>{if(typeof document<"u"&&document.head){let t=jl(document,"history-timestamp");if(t)return t|0}},N1=()=>{if(typeof document<"u"&&document.head)return jl(document,"token")},D1=()=>{if(typeof document<"u"&&document.head)return jl(document,"token-param")};function P1(t,n){typeof t=="object"&&typeof n>"u"&&(n=t,t=void 0),t=t||L1(),n=n||{},n.historyTimestamp||=O1();let e=N1();if(e){let d=D1();n.auth=Object.assign({token:e,param:d},n.auth||{})}n=Object.assign({},Np,n);let{logLevel:r,logger:m,pingInterval:f,reconnectStrategy:g,maxMissingPings:w,maxReconnectAttempts:u}=n;return m=n.logger=n.logger||new E1(r),g=n.reconnectStrategy=n.reconnectStrategy||Lp(f),n.monitor!==!1&&(n.monitor=n.monitor||new T1({pingInterval:f,reconnectStrategy:g,maxMissingPings:w,maxReconnectAttempts:u,logger:m})),$1(t,n)}function F1(t,n){let e=P1(t,n);return new S1(e)}class z1{constructor(n="/openc3-api/cable"){this._cable=null,this._url=n}disconnect(){this._cable&&(this._cable.cable.disconnect(),this._cable=null)}createSubscription(n,e,r={},m={}){return OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity).then(f=>{if(f&&OpenC3Auth.setTokens(),this._cable==null){const g=new URL(this._url,document.baseURI);g.searchParams.set("scope",e),this._cable=F1(g.href)}return this._cable.subscriptions.create({channel:n,token:localStorage.openc3Token,...m},r)})}recordPing(){}}On("l",z1),On("r",class{constructor(n,e,r="",m=""){this.keyword=n.keyword,this.parameters=n.parameters,this.filename=n.filename,this.line=n.line,this.lineNumber=n.lineNumber,this.message=e,this.usage=r,this.url=m}});function Wa(t){return B1.test(t)}const B1=/^-?[0-9]+$/;function Pp(t){return W1.test(t)}const W1=/^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?$/;function Fp(t,n){if(Wa(t))return Number.isSafeInteger(Number.parseInt(t,10));const e=Number.parseFloat(t),r=String(e);if(t===r)return!0;const m=zp(t),f=zp(r);return!!(m===f||n?.approx===!0&&!Wa(t)&&f.length>=14&&m.startsWith(f.substring(0,14)))}let ja=(function(t){return t.underflow="underflow",t.overflow="overflow",t.truncate_integer="truncate_integer",t.truncate_float="truncate_float",t})({});function j1(t){if(Fp(t,{approx:!1}))return;if(Wa(t))return ja.truncate_integer;const n=Number.parseFloat(t);return Number.isFinite(n)?n===0?ja.underflow:ja.truncate_float:ja.overflow}function zp(t){const{start:n,end:e}=H1(t),r=t.substring(n,e),m=r.indexOf(".");return m===-1?r:r.substring(0,m)+r.substring(m+1)}function H1(t){let n=0;for(t[0]==="-"&&n++;t[n]==="0"||t[n]===".";)n++;let e=t.lastIndexOf("e");for(e===-1&&(e=t.lastIndexOf("E")),e===-1&&(e=t.length);(t[e-1]==="0"||t[e-1]===".")&&e>n;)e--;return{start:n,end:e}}class U1{isLosslessNumber=!0;constructor(n){if(!Pp(n))throw new Error(`Invalid number (value: "${n}")`);this.value=n}valueOf(){const n=j1(this.value);if(n===void 0||n===ja.truncate_float)return Number.parseFloat(this.value);if(Wa(this.value))return BigInt(this.value);throw new Error(`Cannot safely convert to number: the value '${this.value}' would ${n} and become ${Number.parseFloat(this.value)}`)}toString(){return this.value}}function V1(t){return t&&typeof t=="object"&&t.isLosslessNumber||!1}function q1(t){return new U1(t)}function G1(t,n){return Mu({"":t},"",t,n)}function Mu(t,n,e,r){return Array.isArray(e)?r.call(t,n,Y1(e,r)):e&&typeof e=="object"&&!V1(e)?r.call(t,n,K1(e,r)):r.call(t,n,e)}function K1(t,n){for(const e of Object.keys(t)){const r=Mu(t,e,t[e],n);r!==void 0?t[e]=r:delete t[e]}return t}function Y1(t,n){for(let e=0;e<t.length;e++)t[e]=Mu(t,String(e),t[e],n);return t}function J1(t,n,e){const r=typeof e=="function"?{parseNumber:e}:e,m=r?.parseNumber??q1,f=r?.onDuplicateKey??L;let g=0;const w=a();return b(w),M(),n?G1(w,n):w;function u(){if(t.charCodeAt(g)===nC){g++,c();const B={};let U=!0;for(;g<t.length&&t.charCodeAt(g)!==Wp;){U?U=!1:(s(),c());const G=g,J=h();if(J===void 0){C();return}c(),p();const ne=a();if(ne===void 0){F();return}if(Object.prototype.hasOwnProperty.call(B,J)&&!Iu(ne,B[J])){const de=f({key:J,position:G+1,oldValue:B[J],newValue:ne});de!==void 0&&(B[J]=de)}else B[J]=ne}return t.charCodeAt(g)!==Wp&&D(),g++,B}}function d(){if(t.charCodeAt(g)===rC){g++,c();const B=[];let U=!0;for(;g<t.length&&t.charCodeAt(g)!==jp;){U?U=!1:s();const G=a();x(G),B.push(G)}return t.charCodeAt(g)!==jp&&I(),g++,B}}function a(){c();const B=h()??o()??u()??d()??l("true",!0)??l("false",!1)??l("null",null);return c(),B}function l(B,U){if(t.slice(g,g+B.length)===B)return g+=B.length,U}function c(){for(;Z1(t.charCodeAt(g));)g++}function h(){if(t.charCodeAt(g)===Lu){g++;let B="";for(;g<t.length&&t.charCodeAt(g)!==Lu;){if(t.charCodeAt(g)===tC){const U=t[g+1],G=eC[U];G!==void 0?(B+=G,g++):U==="u"?Hl(t.charCodeAt(g+2))&&Hl(t.charCodeAt(g+3))&&Hl(t.charCodeAt(g+4))&&Hl(t.charCodeAt(g+5))?(B+=String.fromCharCode(Number.parseInt(t.slice(g+2,g+6),16)),g+=5):O(g):W(g)}else Q1(t.charCodeAt(g))?B+=t[g]:T(t[g]);g++}return k(),g++,B}}function o(){const B=g;if(t.charCodeAt(g)===Hp&&(g++,R(B)),t.charCodeAt(g)===Ou)g++;else if(X1(t.charCodeAt(g)))for(g++;Ul(t.charCodeAt(g));)g++;if(t.charCodeAt(g)===hC)for(g++,R(B);Ul(t.charCodeAt(g));)g++;if(t.charCodeAt(g)===mC||t.charCodeAt(g)===gC)for(g++,(t.charCodeAt(g)===Hp||t.charCodeAt(g)===lC)&&g++,R(B);Ul(t.charCodeAt(g));)g++;if(g>B)return m(t.slice(B,g))}function s(){if(t.charCodeAt(g)!==uC)throw new SyntaxError(`Comma ',' expected after value ${N()}`);g++}function p(){if(t.charCodeAt(g)!==dC)throw new SyntaxError(`Colon ':' expected after property name ${N()}`);g++}function b(B){if(B===void 0)throw new SyntaxError(`JSON value expected ${N()}`)}function x(B){if(B===void 0)throw new SyntaxError(`Array item expected ${N()}`)}function M(){if(g<t.length)throw new SyntaxError(`Expected end of input ${N()}`)}function R(B){if(!Ul(t.charCodeAt(g))){const U=t.slice(B,g);throw new SyntaxError(`Invalid number '${U}', expecting a digit ${N()}`)}}function k(){if(t.charCodeAt(g)!==Lu)throw new SyntaxError(`End of string '"' expected ${N()}`)}function C(){throw new SyntaxError(`Quoted object key expected ${N()}`)}function L(B){let{key:U,position:G}=B;throw new SyntaxError(`Duplicate key '${U}' encountered at position ${G}`)}function D(){throw new SyntaxError(`Quoted object key or end of object '}' expected ${N()}`)}function I(){throw new SyntaxError(`Array item or end of array ']' expected ${N()}`)}function T(B){throw new SyntaxError(`Invalid character '${B}' ${S()}`)}function W(B){const U=t.slice(B,B+2);throw new SyntaxError(`Invalid escape character '${U}' ${S()}`)}function F(){throw new SyntaxError(`Object value expected after ':' ${S()}`)}function O(B){const U=t.slice(B,B+6);throw new SyntaxError(`Invalid unicode character '${U}' ${S()}`)}function S(){return`at position ${g}`}function A(){return g<t.length?`but got '${t[g]}'`:"but reached end of input"}function N(){return`${A()} ${S()}`}}function Z1(t){return t===iC||t===oC||t===sC||t===aC}function Hl(t){return t>=Ou&&t<=Nu||t>=fC&&t<=vC||t>=pC&&t<=yC}function Ul(t){return t>=Ou&&t<=Nu}function X1(t){return t>=cC&&t<=Nu}function Q1(t){return t>=32&&t<=1114111}function Iu(t,n){return t===n?!0:Array.isArray(t)&&Array.isArray(n)?t.length===n.length&&t.every((e,r)=>Iu(e,n[r])):Bp(t)&&Bp(n)?[...new Set([...Object.keys(t),...Object.keys(n)])].every(e=>Iu(t[e],n[e])):!1}function Bp(t){return typeof t=="object"&&t!==null}const eC={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:`
10
+ `,r:"\r",t:" "},tC=92,nC=123,Wp=125,rC=91,jp=93,iC=32,oC=10,sC=9,aC=13,Lu=34,lC=43,Hp=45,Ou=48,cC=49,Nu=57,uC=44,hC=46,dC=58,fC=65,pC=97,gC=69,mC=101,vC=70,yC=102;function Up(t,n,e,r){return m(t);function m(u,d){if(Array.isArray(r)){const a=r.find(l=>l.test(u));if(a){const l=a.stringify(u);if(typeof l!="string"||!Pp(l))throw new Error(`Invalid JSON number: output of a number stringifier must be a string containing a JSON number (output: ${l})`);return l}}if(typeof u=="boolean"||typeof u=="number"||typeof u=="string"||u===null||u instanceof Date||u instanceof Boolean||u instanceof Number||u instanceof String)return JSON.stringify(u);if(u?.isLosslessNumber||typeof u=="bigint")return u.toString();if(Array.isArray(u))return f(u);if(u&&typeof u=="object")return g(u)}function f(u,d){if(u.length===0)return"[]";let a="[";for(let l=0;l<u.length;l++){const c=u[l];typeof c<"u"&&typeof c!="function"?a+=m(c):a+="null",l<u.length-1&&(a+=",")}return a+="]",a}function g(u,d){if(typeof u.toJSON=="function")return Up(u.toJSON(),n,e,void 0);const a=Array.isArray(n)?n.map(String):Object.keys(u);if(a.length===0)return"{}";let l=!0,c="{";for(const h of a){const o=u[h];if(w(h,o)){l?l=!1:c+=",";const s=JSON.stringify(h);c+=`${s}:`,c+=m(o)}}return c+="}",c}function w(u,d){return typeof d<"u"&&typeof d!="function"&&typeof d!="symbol"}}function bC(t){return Wa(t)&&!Fp(t)?BigInt(t):parseFloat(t)}class vs{id=1;constructor(){}async exec(n,e,r={},m={},f=6e4){try{await OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity)&&OpenC3Auth.setTokens()}catch{OpenC3Auth.login()}this.id=this.id+1;try{return r.scope=window.openc3Scope,m.manual=!0,(await Ru.post("/openc3-api/api",{jsonrpc:"2.0",method:n,params:e,id:this.id,keyword_params:r},{headers:{Authorization:localStorage.openc3Token,"Content-Type":"application/json-rpc",...m},timeout:f,transformRequest:[(g,w)=>Up(g)],transformResponse:[g=>{try{return J1(g,void 0,bC)}catch{const w=typeof g=="string"?g.substring(0,200):String(g),u=new Error(`Server returned non-JSON response: ${w}`);throw u.name="ServerError",u}}]})).data.result}catch(g){let w=new Error;throw g.response?(w.name=g.response.data.error.data.class,w.message=g.response.data.error.data.message,w.object=g.response.data.error):g.request?(w.name="Request error",w.message="Request error, no response received"):w=g,w}}decode_openc3_type(n){if(n!==null&&typeof n=="object"&&n.json_class=="Float"&&n.raw){if(n.raw=="NaN")return NaN;if(n.raw=="Infinity")return 1/0;if(n.raw=="-Infinity")return-1/0}return null}encode_openc3_type(n){return Number.isNaN(n)?{json_class:"Float",raw:"NaN"}:n==Number.POSITIVE_INFINITY?{json_class:"Float",raw:"Infinity"}:n==Number.NEGATIVE_INFINITY?{json_class:"Float",raw:"-Infinity"}:null}ensure_offline_access(){this.offline_access_needed().then(n=>{n&&(localStorage.openc3OfflineToken?this.set_offline_access(localStorage.openc3OfflineToken).then(()=>{delete localStorage.openc3OfflineToken}):OpenC3Auth.getOfflineAccess())})}offline_access_needed(){return this.exec("offline_access_needed",[])}set_offline_access(n){return this.exec("set_offline_access",[n])}get_all_interface_info(){return this.exec("get_all_interface_info",[])}map_target_to_interface(n,e,r,m,f){return this.exec("map_target_to_interface",[n,e],{cmd_only:r,tlm_only:m,unmap_old:f})}unmap_target_from_interface(n,e,r,m){return this.exec("unmap_target_from_interface",[n,e],{cmd_only:r,tlm_only:m})}connect_interface(n,...e){return e.length>0?this.exec("connect_interface",[n,...e]):this.exec("connect_interface",[n])}disconnect_interface(n){return this.exec("disconnect_interface",[n])}interface_cmd(n,e,...r){return this.exec("interface_cmd",[n,e,...r])}interface_target_enable(n,e,r=!1,m=!1){return this.exec("interface_target_enable",[n,e],{cmd_only:r,tlm_only:m})}interface_target_disable(n,e,r=!1,m=!1){return this.exec("interface_target_disable",[n,e],{cmd_only:r,tlm_only:m})}interface_details(n){return this.exec("interface_details",[n])}get_all_router_info(){return this.exec("get_all_router_info",[])}map_target_to_router(n,e,r,m,f){return this.exec("map_target_to_router",[n,e],{cmd_only:r,tlm_only:m,unmap_old:f})}unmap_target_from_router(n,e,r,m){return this.exec("unmap_target_from_router",[n,e],{cmd_only:r,tlm_only:m})}connect_router(n){return this.exec("connect_router",[n])}disconnect_router(n){return this.exec("disconnect_router",[n])}router_target_enable(n,e,r=!1,m=!1){return this.exec("router_target_enable",[n,e],{cmd_only:r,tlm_only:m})}router_target_disable(n,e,r=!1,m=!1){return this.exec("router_target_disable",[n,e],{cmd_only:r,tlm_only:m})}router_details(n){return this.exec("router_details",[n])}get_target_interfaces(){return this.exec("get_target_interfaces",[])}get_tlm_cnts(n){return this.exec("get_tlm_cnts",[n])}get_item(n,e,r){return this.exec("get_item",[n,e,r])}get_param(n,e,r){return this.exec("get_param",[n,e,r])}get_parameter(n,e,r){return this.exec("get_param",[n,e,r])}get_limits_sets(){return this.exec("get_limits_sets",[])}get_limits_set(){return this.exec("get_limits_set",[])}set_limits_set(n){return this.exec("set_limits_set",[n])}get_target(n){return this.exec("get_target",[n])}get_target_names(){return this.exec("get_target_names",[])}get_target_list(){return this.exec("get_target_names",[])}get_tlm(n,e){return this.exec("get_tlm",[n,e])}get_telemetry(n,e){return this.exec("get_tlm",[n,e])}get_all_tlm(n){return this.exec("get_all_tlm",[n])}get_all_telemetry(n){return this.exec("get_all_tlm",[n])}get_all_tlm_names(n,e=!1){return this.exec("get_all_tlm_names",[n],{hidden:e})}get_all_telemetry_names(n){return this.exec("get_all_tlm_names",[n])}get_all_tlm_item_names(n){return this.exec("get_all_tlm_item_names",[n])}async get_tlm_packet(n,e,r,m=30){const f=await this.exec("get_tlm_packet",[n,e],{type:r,stale_time:m});if(f!=null){let g=f.length,w=null;for(let u=0;u<g;u++)w=this.decode_openc3_type(f[u][1]),w!==null&&(f[u][1]=w)}return f}get_packet_derived_items(n,e){return this.exec("get_packet_derived_items",[n,e])}get_tlm_buffer(n,e){return this.exec("get_tlm_buffer",[n,e])}get_tlm_available(n){return this.exec("get_tlm_available",[n])}async get_tlm_values(n,e=30,r=null,m=null,f=null){let g={stale_time:e};r!==null&&(g.cache_timeout=r),m!==null&&(g.start_time=m.toISOString()),f!==null&&(g.end_time=f.toISOString());const w=await this.exec("get_tlm_values",[n],g,{},1e4);if(w&&w.length>0){let u=w.length,d=null;for(let a=0;a<u;a++)d=this.decode_openc3_type(w[a][0]),d!==null&&(w[a][0]=d)}return w}get_limits(n,e,r){return this.exec("get_limits",[n,e,r])}async tlm(n,e,r,m="CONVERTED"){let f=null;if(e===void 0)f=await this.exec("tlm",[n]);else if(r===void 0)if(["RAW","CONVERTED","FORMATTED"].includes(e))f=await this.exec("tlm",[n],{type:e});else{let w=new Error;throw w.name="TypeError",w.message=`Invalid data type ${e}. Valid options are RAW, CONVERTED or FORMATTED.`,w}else f=await this.exec("tlm",[n,e,r],{type:m});let g=this.decode_openc3_type(f);return g!==null&&(f=g),f}async inject_tlm(n,e,r=null,m="CONVERTED",f=!1){await this.exec("inject_tlm",[n,e,r],{type:m,stored:f})}set_tlm(n,e,r,m){return this.exec("set_tlm",[n,e,r],{type:m})}override_tlm(n,e,r,m){return this.exec("override_tlm",[n,e,r],{type:m})}get_overrides(){return this.exec("get_overrides")}normalize_tlm(n,e,r,m){return this.exec("normalize_tlm",[n,e,r],{type:m})}get_all_cmds(n){return this.exec("get_all_cmds",[n])}get_all_commands(n){return this.exec("get_all_cmds",[n])}get_all_cmd_names(n,e=!1){return this.exec("get_all_cmd_names",[n],{hidden:e})}get_all_command_names(n){return this.exec("get_all_cmd_names",[n])}get_cmd(n,e){return this.exec("get_cmd",[n,e])}get_command(n,e){return this.exec("get_cmd",[n,e])}get_cmd_cnts(n){return this.exec("get_cmd_cnts",[n])}get_cmd_value(n,e,r,m="CONVERTED"){return this.exec("get_cmd_value",[n,e,r,m])}get_cmd_buffer(n,e){return this.exec("get_cmd_buffer",[n,e])}_cmd(n,e,r,m,f,g={}){let w=null;for(let u in m)Object.prototype.hasOwnProperty.call(m,u)&&(w=this.encode_openc3_type(m[u]),w!==null&&(m[u]=w));return this.exec(n,[e,r,m],g,f)}get_cmd_hazardous(n,e,r,m={}){return e===void 0?this.exec("get_cmd_hazardous",n,{},m):this._cmd("get_cmd_hazardous",n,e,r,m)}cmd(n,e,r,m={},f={}){return e===void 0?this.exec("cmd",n,f,m):this._cmd("cmd",n,e,r,m,f)}cmd_no_range_check(n,e,r,m={},f={}){return e===void 0?this.exec("cmd_no_range_check",n,f,m):this._cmd("cmd_no_range_check",n,e,r,m,f)}cmd_raw(n,e,r,m={},f={}){return e===void 0?this.exec("cmd_raw",n,f,m):this._cmd("cmd_raw",n,e,r,m,f)}cmd_raw_no_range_check(n,e,r,m={},f={}){return e===void 0?this.exec("cmd_raw_no_range_check",n,f,m):this._cmd("cmd_raw_no_range_check",n,e,r,m,f)}cmd_no_hazardous_check(n,e,r,m={},f={}){return e===void 0?this.exec("cmd_no_hazardous_check",n,f,m):this._cmd("cmd_no_hazardous_check",n,e,r,m,f)}cmd_no_checks(n,e,r,m={},f={}){return e===void 0?this.exec("cmd_no_checks",n,f,m):this._cmd("cmd_no_checks",n,e,r,m,f)}cmd_raw_no_hazardous_check(n,e,r,m={},f={}){return e===void 0?this.exec("cmd_raw_no_hazardous_check",n,f,m):this._cmd("cmd_raw_no_hazardous_check",n,e,r,m,f)}cmd_raw_no_checks(n,e,r,m={},f={}){return e===void 0?this.exec("cmd_raw_no_checks",n,f,m):this._cmd("cmd_raw_no_checks",n,e,r,m,f)}build_cmd(n,e,r,m={},f={}){return e===void 0?this.exec("build_cmd",n,f,m):this._cmd("build_cmd",n,e,r,m,f)}build_command(n,e,r,m={},f={}){return e===void 0?this.exec("build_cmd",n,f,m):this._cmd("build_cmd",n,e,r,m,f)}get_interface_names(){return this.exec("get_interface_names",[])}get_router_names(){return this.exec("get_router_names",[])}send_raw(n,e){return this.exec("send_raw",[n,e])}list_configs(n){return this.exec("list_configs",[n])}load_config(n,e){return this.exec("load_config",[n,e])}save_config(n,e,r){return this.exec("save_config",[n,e,r])}delete_config(n,e){return this.exec("delete_config",[n,e])}enable_limits(n,e,r){return this.exec("enable_limits",[n,e,r])}disable_limits(n,e,r){return this.exec("disable_limits",[n,e,r])}get_out_of_limits(){return this.exec("get_out_of_limits",[])}get_overall_limits_state(n){return this.exec("get_overall_limits_state",[n])}list_settings(){return this.exec("list_settings",[])}get_all_settings(){return this.exec("get_all_settings",[])}get_setting(n,e){return this.exec("get_setting",[n],e)}get_settings(n,e){return this.exec("get_settings",n,e)}set_setting(n,e){return this.exec("set_setting",[n,e])}update_news(){return this.exec("update_news",[])}update_plugin_store(){return this.exec("update_plugin_store",[])}save_setting(n,e){return this.exec("set_setting",[n,e])}get_metrics(){return this.exec("get_metrics",[])}open_tab(n){window.open(n,"_blank")}async hashString(n){if(window.isSecureContext){const e=new TextEncoder().encode(n),r=await crypto.subtle.digest("SHA-256",e),m=new Uint8Array(r);return Array.from(m).map(f=>f.toString(16).padStart(2,"0")).join("")}}}On("g",vs);const Vp=6048e5,wC=864e5,Vl=6e4,Du=36e5,xC=1e3,qp=Symbol.for("constructDateFrom");On({h:Vl,j:Du,q:xC});function uo(t,n){return typeof t=="function"?t(n):t&&typeof t=="object"&&qp in t?t[qp](n):t instanceof Date?new t.constructor(n):new Date(n)}function Hr(t,n){return uo(n||t,t)}let CC={};function Js(){return CC}function Zs(t,n){const e=Js(),r=n?.weekStartsOn??n?.locale?.options?.weekStartsOn??e.weekStartsOn??e.locale?.options?.weekStartsOn??0,m=Hr(t,n?.in),f=m.getDay(),g=(f<r?7:0)+f-r;return m.setDate(m.getDate()-g),m.setHours(0,0,0,0),m}function Ha(t,n){return Zs(t,{...n,weekStartsOn:1})}function Gp(t,n){const e=Hr(t,n?.in),r=e.getFullYear(),m=uo(e,0);m.setFullYear(r+1,0,4),m.setHours(0,0,0,0);const f=Ha(m),g=uo(e,0);g.setFullYear(r,0,4),g.setHours(0,0,0,0);const w=Ha(g);return e.getTime()>=f.getTime()?r+1:e.getTime()>=w.getTime()?r:r-1}function Pu(t){const n=Hr(t),e=new Date(Date.UTC(n.getFullYear(),n.getMonth(),n.getDate(),n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds()));return e.setUTCFullYear(n.getFullYear()),+t-+e}function AC(t,...n){const e=uo.bind(null,n.find(r=>typeof r=="object"));return n.map(e)}function Kp(t,n){const e=Hr(t,n?.in);return e.setHours(0,0,0,0),e}function _C(t,n,e){const[r,m]=AC(e?.in,t,n),f=Kp(r),g=Kp(m),w=+f-Pu(f),u=+g-Pu(g);return Math.round((w-u)/wC)}function kC(t,n){const e=Gp(t,n),r=uo(t,0);return r.setFullYear(e,0,4),r.setHours(0,0,0,0),Ha(r)}function SC(t){return t instanceof Date||typeof t=="object"&&Object.prototype.toString.call(t)==="[object Date]"}function Yp(t){return!(!SC(t)&&typeof t!="number"||isNaN(+Hr(t)))}function $C(t,n){const e=Hr(t,n?.in);return e.setFullYear(e.getFullYear(),0,1),e.setHours(0,0,0,0),e}const RC={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},EC=(t,n,e)=>{let r;const m=RC[t];return typeof m=="string"?r=m:n===1?r=m.one:r=m.other.replace("{{count}}",n.toString()),e?.addSuffix?e.comparison&&e.comparison>0?"in "+r:r+" ago":r};function Fu(t){return(n={})=>{const e=n.width?String(n.width):t.defaultWidth;return t.formats[e]||t.formats[t.defaultWidth]}}const TC={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},MC={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},IC={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},LC={date:Fu({formats:TC,defaultWidth:"full"}),time:Fu({formats:MC,defaultWidth:"full"}),dateTime:Fu({formats:IC,defaultWidth:"full"})},OC={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},NC=(t,n,e,r)=>OC[t];function Ua(t){return(n,e)=>{const r=e?.context?String(e.context):"standalone";let m;if(r==="formatting"&&t.formattingValues){const g=t.defaultFormattingWidth||t.defaultWidth,w=e?.width?String(e.width):g;m=t.formattingValues[w]||t.formattingValues[g]}else{const g=t.defaultWidth,w=e?.width?String(e.width):t.defaultWidth;m=t.values[w]||t.values[g]}const f=t.argumentCallback?t.argumentCallback(n):n;return m[f]}}const DC={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},PC={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},FC={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},zC={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},BC={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},WC={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},jC=(t,n)=>{const e=Number(t),r=e%100;if(r>20||r<10)switch(r%10){case 1:return e+"st";case 2:return e+"nd";case 3:return e+"rd"}return e+"th"},HC={ordinalNumber:jC,era:Ua({values:DC,defaultWidth:"wide"}),quarter:Ua({values:PC,defaultWidth:"wide",argumentCallback:t=>t-1}),month:Ua({values:FC,defaultWidth:"wide"}),day:Ua({values:zC,defaultWidth:"wide"}),dayPeriod:Ua({values:BC,defaultWidth:"wide",formattingValues:WC,defaultFormattingWidth:"wide"})};function Va(t){return(n,e={})=>{const r=e.width,m=r&&t.matchPatterns[r]||t.matchPatterns[t.defaultMatchWidth],f=n.match(m);if(!f)return null;const g=f[0],w=r&&t.parsePatterns[r]||t.parsePatterns[t.defaultParseWidth],u=Array.isArray(w)?VC(w,l=>l.test(g)):UC(w,l=>l.test(g));let d;d=t.valueCallback?t.valueCallback(u):u,d=e.valueCallback?e.valueCallback(d):d;const a=n.slice(g.length);return{value:d,rest:a}}}function UC(t,n){for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e)&&n(t[e]))return e}function VC(t,n){for(let e=0;e<t.length;e++)if(n(t[e]))return e}function qC(t){return(n,e={})=>{const r=n.match(t.matchPattern);if(!r)return null;const m=r[0],f=n.match(t.parsePattern);if(!f)return null;let g=t.valueCallback?t.valueCallback(f[0]):f[0];g=e.valueCallback?e.valueCallback(g):g;const w=n.slice(m.length);return{value:g,rest:w}}}const GC=/^(\d+)(th|st|nd|rd)?/i,KC=/\d+/i,YC={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},JC={any:[/^b/i,/^(a|c)/i]},ZC={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},XC={any:[/1/i,/2/i,/3/i,/4/i]},QC={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},eA={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},tA={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},nA={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},rA={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},iA={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},oA={ordinalNumber:qC({matchPattern:GC,parsePattern:KC,valueCallback:t=>parseInt(t,10)}),era:Va({matchPatterns:YC,defaultMatchWidth:"wide",parsePatterns:JC,defaultParseWidth:"any"}),quarter:Va({matchPatterns:ZC,defaultMatchWidth:"wide",parsePatterns:XC,defaultParseWidth:"any",valueCallback:t=>t+1}),month:Va({matchPatterns:QC,defaultMatchWidth:"wide",parsePatterns:eA,defaultParseWidth:"any"}),day:Va({matchPatterns:tA,defaultMatchWidth:"wide",parsePatterns:nA,defaultParseWidth:"any"}),dayPeriod:Va({matchPatterns:rA,defaultMatchWidth:"any",parsePatterns:iA,defaultParseWidth:"any"})},sA=On("b",{code:"en-US",formatDistance:EC,formatLong:LC,formatRelative:NC,localize:HC,match:oA,options:{weekStartsOn:0,firstWeekContainsDate:1}});function aA(t,n){const e=Hr(t,n?.in);return _C(e,$C(e))+1}function Jp(t,n){const e=Hr(t,n?.in),r=+Ha(e)-+kC(e);return Math.round(r/Vp)+1}function zu(t,n){const e=Hr(t,n?.in),r=e.getFullYear(),m=Js(),f=n?.firstWeekContainsDate??n?.locale?.options?.firstWeekContainsDate??m.firstWeekContainsDate??m.locale?.options?.firstWeekContainsDate??1,g=uo(n?.in||t,0);g.setFullYear(r+1,0,f),g.setHours(0,0,0,0);const w=Zs(g,n),u=uo(n?.in||t,0);u.setFullYear(r,0,f),u.setHours(0,0,0,0);const d=Zs(u,n);return+e>=+w?r+1:+e>=+d?r:r-1}function lA(t,n){const e=Js(),r=n?.firstWeekContainsDate??n?.locale?.options?.firstWeekContainsDate??e.firstWeekContainsDate??e.locale?.options?.firstWeekContainsDate??1,m=zu(t,n),f=uo(n?.in||t,0);return f.setFullYear(m,0,r),f.setHours(0,0,0,0),Zs(f,n)}function Zp(t,n){const e=Hr(t,n?.in),r=+Zs(e,n)-+lA(e,n);return Math.round(r/Vp)+1}function cn(t,n){const e=t<0?"-":"",r=Math.abs(t).toString().padStart(n,"0");return e+r}const qo={y(t,n){const e=t.getFullYear(),r=e>0?e:1-e;return cn(n==="yy"?r%100:r,n.length)},M(t,n){const e=t.getMonth();return n==="M"?String(e+1):cn(e+1,2)},d(t,n){return cn(t.getDate(),n.length)},a(t,n){const e=t.getHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return e.toUpperCase();case"aaa":return e;case"aaaaa":return e[0];default:return e==="am"?"a.m.":"p.m."}},h(t,n){return cn(t.getHours()%12||12,n.length)},H(t,n){return cn(t.getHours(),n.length)},m(t,n){return cn(t.getMinutes(),n.length)},s(t,n){return cn(t.getSeconds(),n.length)},S(t,n){const e=n.length,r=t.getMilliseconds(),m=Math.trunc(r*Math.pow(10,e-3));return cn(m,n.length)}},Xs={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Xp={G:function(t,n,e){const r=t.getFullYear()>0?1:0;switch(n){case"G":case"GG":case"GGG":return e.era(r,{width:"abbreviated"});case"GGGGG":return e.era(r,{width:"narrow"});default:return e.era(r,{width:"wide"})}},y:function(t,n,e){if(n==="yo"){const r=t.getFullYear(),m=r>0?r:1-r;return e.ordinalNumber(m,{unit:"year"})}return qo.y(t,n)},Y:function(t,n,e,r){const m=zu(t,r),f=m>0?m:1-m;if(n==="YY"){const g=f%100;return cn(g,2)}return n==="Yo"?e.ordinalNumber(f,{unit:"year"}):cn(f,n.length)},R:function(t,n){const e=Gp(t);return cn(e,n.length)},u:function(t,n){const e=t.getFullYear();return cn(e,n.length)},Q:function(t,n,e){const r=Math.ceil((t.getMonth()+1)/3);switch(n){case"Q":return String(r);case"QQ":return cn(r,2);case"Qo":return e.ordinalNumber(r,{unit:"quarter"});case"QQQ":return e.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return e.quarter(r,{width:"narrow",context:"formatting"});default:return e.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,n,e){const r=Math.ceil((t.getMonth()+1)/3);switch(n){case"q":return String(r);case"qq":return cn(r,2);case"qo":return e.ordinalNumber(r,{unit:"quarter"});case"qqq":return e.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return e.quarter(r,{width:"narrow",context:"standalone"});default:return e.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,n,e){const r=t.getMonth();switch(n){case"M":case"MM":return qo.M(t,n);case"Mo":return e.ordinalNumber(r+1,{unit:"month"});case"MMM":return e.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return e.month(r,{width:"narrow",context:"formatting"});default:return e.month(r,{width:"wide",context:"formatting"})}},L:function(t,n,e){const r=t.getMonth();switch(n){case"L":return String(r+1);case"LL":return cn(r+1,2);case"Lo":return e.ordinalNumber(r+1,{unit:"month"});case"LLL":return e.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return e.month(r,{width:"narrow",context:"standalone"});default:return e.month(r,{width:"wide",context:"standalone"})}},w:function(t,n,e,r){const m=Zp(t,r);return n==="wo"?e.ordinalNumber(m,{unit:"week"}):cn(m,n.length)},I:function(t,n,e){const r=Jp(t);return n==="Io"?e.ordinalNumber(r,{unit:"week"}):cn(r,n.length)},d:function(t,n,e){return n==="do"?e.ordinalNumber(t.getDate(),{unit:"date"}):qo.d(t,n)},D:function(t,n,e){const r=aA(t);return n==="Do"?e.ordinalNumber(r,{unit:"dayOfYear"}):cn(r,n.length)},E:function(t,n,e){const r=t.getDay();switch(n){case"E":case"EE":case"EEE":return e.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return e.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return e.day(r,{width:"short",context:"formatting"});default:return e.day(r,{width:"wide",context:"formatting"})}},e:function(t,n,e,r){const m=t.getDay(),f=(m-r.weekStartsOn+8)%7||7;switch(n){case"e":return String(f);case"ee":return cn(f,2);case"eo":return e.ordinalNumber(f,{unit:"day"});case"eee":return e.day(m,{width:"abbreviated",context:"formatting"});case"eeeee":return e.day(m,{width:"narrow",context:"formatting"});case"eeeeee":return e.day(m,{width:"short",context:"formatting"});default:return e.day(m,{width:"wide",context:"formatting"})}},c:function(t,n,e,r){const m=t.getDay(),f=(m-r.weekStartsOn+8)%7||7;switch(n){case"c":return String(f);case"cc":return cn(f,n.length);case"co":return e.ordinalNumber(f,{unit:"day"});case"ccc":return e.day(m,{width:"abbreviated",context:"standalone"});case"ccccc":return e.day(m,{width:"narrow",context:"standalone"});case"cccccc":return e.day(m,{width:"short",context:"standalone"});default:return e.day(m,{width:"wide",context:"standalone"})}},i:function(t,n,e){const r=t.getDay(),m=r===0?7:r;switch(n){case"i":return String(m);case"ii":return cn(m,n.length);case"io":return e.ordinalNumber(m,{unit:"day"});case"iii":return e.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return e.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return e.day(r,{width:"short",context:"formatting"});default:return e.day(r,{width:"wide",context:"formatting"})}},a:function(t,n,e){const r=t.getHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return e.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return e.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return e.dayPeriod(r,{width:"narrow",context:"formatting"});default:return e.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(t,n,e){const r=t.getHours();let m;switch(r===12?m=Xs.noon:r===0?m=Xs.midnight:m=r/12>=1?"pm":"am",n){case"b":case"bb":return e.dayPeriod(m,{width:"abbreviated",context:"formatting"});case"bbb":return e.dayPeriod(m,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return e.dayPeriod(m,{width:"narrow",context:"formatting"});default:return e.dayPeriod(m,{width:"wide",context:"formatting"})}},B:function(t,n,e){const r=t.getHours();let m;switch(r>=17?m=Xs.evening:r>=12?m=Xs.afternoon:r>=4?m=Xs.morning:m=Xs.night,n){case"B":case"BB":case"BBB":return e.dayPeriod(m,{width:"abbreviated",context:"formatting"});case"BBBBB":return e.dayPeriod(m,{width:"narrow",context:"formatting"});default:return e.dayPeriod(m,{width:"wide",context:"formatting"})}},h:function(t,n,e){if(n==="ho"){let r=t.getHours()%12;return r===0&&(r=12),e.ordinalNumber(r,{unit:"hour"})}return qo.h(t,n)},H:function(t,n,e){return n==="Ho"?e.ordinalNumber(t.getHours(),{unit:"hour"}):qo.H(t,n)},K:function(t,n,e){const r=t.getHours()%12;return n==="Ko"?e.ordinalNumber(r,{unit:"hour"}):cn(r,n.length)},k:function(t,n,e){let r=t.getHours();return r===0&&(r=24),n==="ko"?e.ordinalNumber(r,{unit:"hour"}):cn(r,n.length)},m:function(t,n,e){return n==="mo"?e.ordinalNumber(t.getMinutes(),{unit:"minute"}):qo.m(t,n)},s:function(t,n,e){return n==="so"?e.ordinalNumber(t.getSeconds(),{unit:"second"}):qo.s(t,n)},S:function(t,n){return qo.S(t,n)},X:function(t,n,e){const r=t.getTimezoneOffset();if(r===0)return"Z";switch(n){case"X":return eg(r);case"XXXX":case"XX":return ys(r);default:return ys(r,":")}},x:function(t,n,e){const r=t.getTimezoneOffset();switch(n){case"x":return eg(r);case"xxxx":case"xx":return ys(r);default:return ys(r,":")}},O:function(t,n,e){const r=t.getTimezoneOffset();switch(n){case"O":case"OO":case"OOO":return"GMT"+Qp(r,":");default:return"GMT"+ys(r,":")}},z:function(t,n,e){const r=t.getTimezoneOffset();switch(n){case"z":case"zz":case"zzz":return"GMT"+Qp(r,":");default:return"GMT"+ys(r,":")}},t:function(t,n,e){const r=Math.trunc(+t/1e3);return cn(r,n.length)},T:function(t,n,e){return cn(+t,n.length)}};function Qp(t,n=""){const e=t>0?"-":"+",r=Math.abs(t),m=Math.trunc(r/60),f=r%60;return f===0?e+String(m):e+String(m)+n+cn(f,2)}function eg(t,n){return t%60===0?(t>0?"-":"+")+cn(Math.abs(t)/60,2):ys(t,n)}function ys(t,n=""){const e=t>0?"-":"+",r=Math.abs(t),m=cn(Math.trunc(r/60),2),f=cn(r%60,2);return e+m+n+f}const tg=(t,n)=>{switch(t){case"P":return n.date({width:"short"});case"PP":return n.date({width:"medium"});case"PPP":return n.date({width:"long"});default:return n.date({width:"full"})}},ng=(t,n)=>{switch(t){case"p":return n.time({width:"short"});case"pp":return n.time({width:"medium"});case"ppp":return n.time({width:"long"});default:return n.time({width:"full"})}},cA=(t,n)=>{const e=t.match(/(P+)(p+)?/)||[],r=e[1],m=e[2];if(!m)return tg(t,n);let f;switch(r){case"P":f=n.dateTime({width:"short"});break;case"PP":f=n.dateTime({width:"medium"});break;case"PPP":f=n.dateTime({width:"long"});break;default:f=n.dateTime({width:"full"});break}return f.replace("{{date}}",tg(r,n)).replace("{{time}}",ng(m,n))},uA=On("N",{p:ng,P:cA}),hA=/^D+$/,dA=/^Y+$/,fA=["D","DD","YY","YYYY"];function rg(t){return hA.test(t)}function ig(t){return dA.test(t)}function og(t,n,e){const r=pA(t,n,e);if(console.warn(r),fA.includes(t))throw new RangeError(r)}function pA(t,n,e){const r=t[0]==="Y"?"years":"days of the month";return`Use \`${t.toLowerCase()}\` instead of \`${t}\` (in \`${n}\`) for formatting ${r} to the input \`${e}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const gA=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,mA=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,vA=/^'([^]*?)'?$/,yA=/''/g,bA=/[a-zA-Z]/;function bs(t,n,e){const r=Js(),m=e?.locale??r.locale??sA,f=e?.firstWeekContainsDate??e?.locale?.options?.firstWeekContainsDate??r.firstWeekContainsDate??r.locale?.options?.firstWeekContainsDate??1,g=e?.weekStartsOn??e?.locale?.options?.weekStartsOn??r.weekStartsOn??r.locale?.options?.weekStartsOn??0,w=Hr(t,e?.in);if(!Yp(w))throw new RangeError("Invalid time value");let u=n.match(mA).map(a=>{const l=a[0];if(l==="p"||l==="P"){const c=uA[l];return c(a,m.formatLong)}return a}).join("").match(gA).map(a=>{if(a==="''")return{isToken:!1,value:"'"};const l=a[0];if(l==="'")return{isToken:!1,value:wA(a)};if(Xp[l])return{isToken:!0,value:a};if(l.match(bA))throw new RangeError("Format string contains an unescaped latin alphabet character `"+l+"`");return{isToken:!1,value:a}});m.localize.preprocessor&&(u=m.localize.preprocessor(w,u));const d={firstWeekContainsDate:f,weekStartsOn:g,locale:m};return u.map(a=>{if(!a.isToken)return a.value;const l=a.value;(!e?.useAdditionalWeekYearTokens&&ig(l)||!e?.useAdditionalDayOfYearTokens&&rg(l))&&og(l,n,String(t));const c=Xp[l[0]];return c(w,l,m.localize,d)}).join("")}function wA(t){const n=t.match(vA);return n?n[1].replace(yA,"'"):t}var Go=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ql(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var sg={exports:{}},ag;function xA(){return ag||(ag=1,(function(t,n){(function(){var e="ace",r=(function(){return this})();!r&&typeof window<"u"&&(r=window);var m=function(a,l,c){if(typeof a!="string"){m.original?m.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace());return}arguments.length==2&&(c=l),m.modules[a]||(m.payloads[a]=c,m.modules[a]=null)};m.modules={},m.payloads={};var f=function(a,l,c){if(typeof l=="string"){var h=u(a,l);if(h!=null)return c&&c(),h}else if(Object.prototype.toString.call(l)==="[object Array]"){for(var o=[],s=0,p=l.length;s<p;++s){var b=u(a,l[s]);if(b==null&&g.original)return;o.push(b)}return c&&c.apply(null,o)||!0}},g=function(a,l){var c=f("",a,l);return c==null&&g.original?g.original.apply(this,arguments):c},w=function(a,l){if(l.indexOf("!")!==-1){var c=l.split("!");return w(a,c[0])+"!"+w(a,c[1])}if(l.charAt(0)=="."){var h=a.split("/").slice(0,-1).join("/");for(l=h+"/"+l;l.indexOf(".")!==-1&&o!=l;){var o=l;l=l.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return l},u=function(a,l){l=w(a,l);var c=m.modules[l];if(!c){if(c=m.payloads[l],typeof c=="function"){var h={},o={id:l,uri:"",exports:h,packaged:!0},s=function(b,x){return f(l,b,x)},p=c(s,h,o);h=p||o.exports,m.modules[l]=h,delete m.payloads[l]}c=m.modules[l]=h||c}return c};function d(a){var l=r;r[a]||(r[a]={}),l=r[a],(!l.define||!l.define.packaged)&&(m.original=l.define,l.define=m,l.define.packaged=!0),(!l.require||!l.require.packaged)&&(g.original=l.require,l.require=g,l.require.packaged=!0)}d(e)})(),ace.define("ace/lib/es6-shim",["require","exports","module"],function(e,r,m){function f(g,w,u){Object.defineProperty(g,w,{value:u,enumerable:!1,writable:!0,configurable:!0})}String.prototype.startsWith||f(String.prototype,"startsWith",function(g,w){return w=w||0,this.lastIndexOf(g,w)===w}),String.prototype.endsWith||f(String.prototype,"endsWith",function(g,w){var u=this;(w===void 0||w>u.length)&&(w=u.length),w-=g.length;var d=u.indexOf(g,w);return d!==-1&&d===w}),String.prototype.repeat||f(String.prototype,"repeat",function(g){for(var w="",u=this;g>0;)g&1&&(w+=u),(g>>=1)&&(u+=u);return w}),String.prototype.includes||f(String.prototype,"includes",function(g,w){return this.indexOf(g,w)!=-1}),Object.assign||(Object.assign=function(g){if(g==null)throw new TypeError("Cannot convert undefined or null to object");for(var w=Object(g),u=1;u<arguments.length;u++){var d=arguments[u];d!=null&&Object.keys(d).forEach(function(a){w[a]=d[a]})}return w}),Object.values||(Object.values=function(g){return Object.keys(g).map(function(w){return g[w]})}),Array.prototype.find||f(Array.prototype,"find",function(g){for(var w=this.length,u=arguments[1],d=0;d<w;d++){var a=this[d];if(g.call(u,a,d,this))return a}}),Array.prototype.findIndex||f(Array.prototype,"findIndex",function(g){for(var w=this.length,u=arguments[1],d=0;d<w;d++){var a=this[d];if(g.call(u,a,d,this))return d}}),Array.prototype.includes||f(Array.prototype,"includes",function(g,w){return this.indexOf(g,w)!=-1}),Array.prototype.fill||f(Array.prototype,"fill",function(g){for(var w=this,u=w.length>>>0,d=arguments[1],a=d>>0,l=a<0?Math.max(u+a,0):Math.min(a,u),c=arguments[2],h=c===void 0?u:c>>0,o=h<0?Math.max(u+h,0):Math.min(h,u);l<o;)w[l]=g,l++;return w}),Array.of||f(Array,"of",function(){return Array.prototype.slice.call(arguments)})}),ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/es6-shim"],function(e,r,m){e("./es6-shim")}),ace.define("ace/lib/deep_copy",["require","exports","module"],function(e,r,m){r.deepCopy=function f(g){if(typeof g!="object"||!g)return g;var w;if(Array.isArray(g)){w=[];for(var u=0;u<g.length;u++)w[u]=f(g[u]);return w}if(Object.prototype.toString.call(g)!=="[object Object]")return g;w={};for(var u in g)w[u]=f(g[u]);return w}}),ace.define("ace/lib/lang",["require","exports","module","ace/lib/deep_copy"],function(e,r,m){r.last=function(w){return w[w.length-1]},r.stringReverse=function(w){return w.split("").reverse().join("")},r.stringRepeat=function(w,u){for(var d="";u>0;)u&1&&(d+=w),(u>>=1)&&(w+=w);return d};var f=/^\s\s*/,g=/\s\s*$/;r.stringTrimLeft=function(w){return w.replace(f,"")},r.stringTrimRight=function(w){return w.replace(g,"")},r.copyObject=function(w){var u={};for(var d in w)u[d]=w[d];return u},r.copyArray=function(w){for(var u=[],d=0,a=w.length;d<a;d++)w[d]&&typeof w[d]=="object"?u[d]=this.copyObject(w[d]):u[d]=w[d];return u},r.deepCopy=e("./deep_copy").deepCopy,r.arrayToMap=function(w){for(var u={},d=0;d<w.length;d++)u[w[d]]=1;return u},r.createMap=function(w){var u=Object.create(null);for(var d in w)u[d]=w[d];return u},r.arrayRemove=function(w,u){for(var d=0;d<=w.length;d++)u===w[d]&&w.splice(d,1)},r.escapeRegExp=function(w){return w.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},r.escapeHTML=function(w){return(""+w).replace(/&/g,"&#38;").replace(/"/g,"&#34;").replace(/'/g,"&#39;").replace(/</g,"&#60;")},r.getMatchOffsets=function(w,u){var d=[];return w.replace(u,function(a){d.push({offset:arguments[arguments.length-2],length:a.length})}),d},r.deferredCall=function(w){var u=null,d=function(){u=null,w()},a=function(l){return a.cancel(),u=setTimeout(d,l||0),a};return a.schedule=a,a.call=function(){return this.cancel(),w(),a},a.cancel=function(){return clearTimeout(u),u=null,a},a.isPending=function(){return u},a},r.delayedCall=function(w,u){var d=null,a=function(){d=null,w()},l=function(c){d==null&&(d=setTimeout(a,c||u))};return l.delay=function(c){d&&clearTimeout(d),d=setTimeout(a,c||u)},l.schedule=l,l.call=function(){this.cancel(),w()},l.cancel=function(){d&&clearTimeout(d),d=null},l.isPending=function(){return d},l},r.sleep=function(w){return new Promise(function(u){setTimeout(u,w)})},r.supportsLookbehind=function(){try{new RegExp("(?<=.)")}catch{return!1}return!0},r.skipEmptyMatch=function(w,u,d){return d&&w.codePointAt(u)>65535?2:1}}),ace.define("ace/lib/useragent",["require","exports","module"],function(e,r,m){r.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},r.getOS=function(){return r.isMac?r.OS.MAC:r.isLinux?r.OS.LINUX:r.OS.WINDOWS};var f=typeof navigator=="object"?navigator:{},g=(/mac|win|linux/i.exec(f.platform)||["other"])[0].toLowerCase(),w=f.userAgent||"",u=f.appName||"";r.isWin=g=="win",r.isMac=g=="mac",r.isLinux=g=="linux",r.isIE=u=="Microsoft Internet Explorer"||u.indexOf("MSAppHost")>=0?parseFloat((w.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((w.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),r.isOldIE=r.isIE&&r.isIE<9,r.isGecko=r.isMozilla=w.match(/ Gecko\/\d+/),r.isOpera=typeof opera=="object"&&Object.prototype.toString.call(window.opera)=="[object Opera]",r.isWebKit=parseFloat(w.split("WebKit/")[1])||void 0,r.isChrome=parseFloat(w.split(" Chrome/")[1])||void 0,r.isSafari=parseFloat(w.split(" Safari/")[1])&&!r.isChrome||void 0,r.isEdge=parseFloat(w.split(" Edge/")[1])||void 0,r.isAIR=w.indexOf("AdobeAIR")>=0,r.isAndroid=w.indexOf("Android")>=0,r.isChromeOS=w.indexOf(" CrOS ")>=0,r.isIOS=/iPad|iPhone|iPod/.test(w)&&!window.MSStream,r.isIOS&&(r.isMac=!0),r.isMobile=r.isIOS||r.isAndroid}),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],function(e,r,m){var f=e("./useragent"),g="http://www.w3.org/1999/xhtml";r.buildDom=function c(h,o,s){if(typeof h=="string"&&h){var p=document.createTextNode(h);return o&&o.appendChild(p),p}if(!Array.isArray(h))return h&&h.appendChild&&o&&o.appendChild(h),h;if(typeof h[0]!="string"||!h[0]){for(var b=[],x=0;x<h.length;x++){var M=c(h[x],o,s);M&&b.push(M)}return b}var R=document.createElement(h[0]),k=h[1],C=1;k&&typeof k=="object"&&!Array.isArray(k)&&(C=2);for(var x=C;x<h.length;x++)c(h[x],R,s);return C==2&&Object.keys(k).forEach(function(L){var D=k[L];L==="class"?R.className=Array.isArray(D)?D.join(" "):D:typeof D=="function"||L=="value"||L[0]=="$"?R[L]=D:L==="ref"?s&&(s[D]=R):L==="style"?typeof D=="string"&&(R.style.cssText=D):D!=null&&R.setAttribute(L,D)}),o&&o.appendChild(R),R},r.getDocumentHead=function(c){return c||(c=document),c.head||c.getElementsByTagName("head")[0]||c.documentElement},r.createElement=function(c,h){return document.createElementNS?document.createElementNS(h||g,c):document.createElement(c)},r.removeChildren=function(c){c.innerHTML=""},r.createTextNode=function(c,h){var o=h?h.ownerDocument:document;return o.createTextNode(c)},r.createFragment=function(c){var h=c?c.ownerDocument:document;return h.createDocumentFragment()},r.hasCssClass=function(c,h){var o=(c.className+"").split(/\s+/g);return o.indexOf(h)!==-1},r.addCssClass=function(c,h){r.hasCssClass(c,h)||(c.className+=" "+h)},r.removeCssClass=function(c,h){for(var o=c.className.split(/\s+/g);;){var s=o.indexOf(h);if(s==-1)break;o.splice(s,1)}c.className=o.join(" ")},r.toggleCssClass=function(c,h){for(var o=c.className.split(/\s+/g),s=!0;;){var p=o.indexOf(h);if(p==-1)break;s=!1,o.splice(p,1)}return s&&o.push(h),c.className=o.join(" "),s},r.setCssClass=function(c,h,o){o?r.addCssClass(c,h):r.removeCssClass(c,h)},r.hasCssString=function(c,h){var o=0,s;if(h=h||document,s=h.querySelectorAll("style")){for(;o<s.length;)if(s[o++].id===c)return!0}},r.removeElementById=function(c,h){h=h||document,h.getElementById(c)&&h.getElementById(c).remove()};var w,u=[];r.useStrictCSP=function(c){w=c,c==!1?d():u||(u=[])};function d(){var c=u;u=null,c&&c.forEach(function(h){a(h[0],h[1])})}function a(c,h,o){if(!(typeof document>"u")){if(u){if(o)d();else if(o===!1)return u.push([c,h])}if(!w){var s=o;!o||!o.getRootNode?s=document:(s=o.getRootNode(),(!s||s==o)&&(s=document));var p=s.ownerDocument||s;if(h&&r.hasCssString(h,s))return null;h&&(c+=`
11
+ /*# sourceURL=ace/css/`+h+" */");var b=r.createElement("style");b.appendChild(p.createTextNode(c)),h&&(b.id=h),s==p&&(s=r.getDocumentHead(p)),s.insertBefore(b,s.firstChild)}}}if(r.importCssString=a,r.importCssStylsheet=function(c,h){r.buildDom(["link",{rel:"stylesheet",href:c}],r.getDocumentHead(h))},r.$fixPositionBug=function(c){var h=c.getBoundingClientRect();if(c.style.left){var o=parseFloat(c.style.left),s=+h.left;Math.abs(o-s)>1&&(c.style.left=2*o-s+"px")}if(c.style.right){var o=parseFloat(c.style.right),s=window.innerWidth-h.right;Math.abs(o-s)>1&&(c.style.right=2*o-s+"px")}if(c.style.top){var o=parseFloat(c.style.top),s=+h.top;Math.abs(o-s)>1&&(c.style.top=2*o-s+"px")}if(c.style.bottom){var o=parseFloat(c.style.bottom),s=window.innerHeight-h.bottom;Math.abs(o-s)>1&&(c.style.bottom=2*o-s+"px")}},r.scrollbarWidth=function(c){var h=r.createElement("ace_inner");h.style.width="100%",h.style.minWidth="0px",h.style.height="200px",h.style.display="block";var o=r.createElement("ace_outer"),s=o.style;s.position="absolute",s.left="-10000px",s.overflow="hidden",s.width="200px",s.minWidth="0px",s.height="150px",s.display="block",o.appendChild(h);var p=c&&c.documentElement||document&&document.documentElement;if(!p)return 0;p.appendChild(o);var b=h.offsetWidth;s.overflow="scroll";var x=h.offsetWidth;return b===x&&(x=o.clientWidth),p.removeChild(o),b-x},r.computedStyle=function(c,h){return window.getComputedStyle(c,"")||{}},r.setStyle=function(c,h,o){c[h]!==o&&(c[h]=o)},r.HAS_CSS_ANIMATION=!1,r.HAS_CSS_TRANSFORMS=!1,r.HI_DPI=f.isWin?typeof window<"u"&&window.devicePixelRatio>=1.5:!0,f.isChromeOS&&(r.HI_DPI=!1),typeof document<"u"){var l=document.createElement("div");r.HI_DPI&&l.style.transform!==void 0&&(r.HAS_CSS_TRANSFORMS=!0),!f.isEdge&&typeof l.style.animationName<"u"&&(r.HAS_CSS_ANIMATION=!0),l=null}r.HAS_CSS_TRANSFORMS?r.translate=function(c,h,o){c.style.transform="translate("+Math.round(h)+"px, "+Math.round(o)+"px)"}:r.translate=function(c,h,o){c.style.top=Math.round(o)+"px",c.style.left=Math.round(h)+"px"}}),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(e,r,m){var f=e("./dom");r.get=function(g,w){var u=new XMLHttpRequest;u.open("GET",g,!0),u.onreadystatechange=function(){u.readyState===4&&w(u.responseText)},u.send(null)},r.loadScript=function(g,w){var u=f.getDocumentHead(),d=document.createElement("script");d.src=g,u.appendChild(d),d.onload=d.onreadystatechange=function(a,l){(l||!d.readyState||d.readyState=="loaded"||d.readyState=="complete")&&(d=d.onload=d.onreadystatechange=null,l||w())}},r.qualifyURL=function(g){var w=document.createElement("a");return w.href=g,w.href}}),ace.define("ace/lib/oop",["require","exports","module"],function(e,r,m){r.inherits=function(f,g){f.super_=g,f.prototype=Object.create(g.prototype,{constructor:{value:f,enumerable:!1,writable:!0,configurable:!0}})},r.mixin=function(f,g){for(var w in g)f[w]=g[w];return f},r.implement=function(f,g){r.mixin(f,g)}}),ace.define("ace/lib/event_emitter",["require","exports","module"],function(e,r,m){var f={},g=function(){this.propagationStopped=!0},w=function(){this.defaultPrevented=!0};f._emit=f._dispatchEvent=function(u,d){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var a=this._eventRegistry[u]||[],l=this._defaultHandlers[u];if(!(!a.length&&!l)){(typeof d!="object"||!d)&&(d={}),d.type||(d.type=u),d.stopPropagation||(d.stopPropagation=g),d.preventDefault||(d.preventDefault=w),a=a.slice();for(var c=0;c<a.length&&(a[c](d,this),!d.propagationStopped);c++);if(l&&!d.defaultPrevented)return l(d,this)}},f._signal=function(u,d){var a=(this._eventRegistry||{})[u];if(a){a=a.slice();for(var l=0;l<a.length;l++)a[l](d,this)}},f.once=function(u,d){var a=this;if(this.on(u,function l(){a.off(u,l),d.apply(null,arguments)}),!d)return new Promise(function(l){d=l})},f.setDefaultHandler=function(u,d){var a=this._defaultHandlers;if(a||(a=this._defaultHandlers={_disabled_:{}}),a[u]){var l=a[u],c=a._disabled_[u];c||(a._disabled_[u]=c=[]),c.push(l);var h=c.indexOf(d);h!=-1&&c.splice(h,1)}a[u]=d},f.removeDefaultHandler=function(u,d){var a=this._defaultHandlers;if(a){var l=a._disabled_[u];if(a[u]==d)l&&this.setDefaultHandler(u,l.pop());else if(l){var c=l.indexOf(d);c!=-1&&l.splice(c,1)}}},f.on=f.addEventListener=function(u,d,a){this._eventRegistry=this._eventRegistry||{};var l=this._eventRegistry[u];return l||(l=this._eventRegistry[u]=[]),l.indexOf(d)==-1&&l[a?"unshift":"push"](d),d},f.off=f.removeListener=f.removeEventListener=function(u,d){this._eventRegistry=this._eventRegistry||{};var a=this._eventRegistry[u];if(a){var l=a.indexOf(d);l!==-1&&a.splice(l,1)}},f.removeAllListeners=function(u){u||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[u]=void 0),this._defaultHandlers&&(this._defaultHandlers[u]=void 0)},r.EventEmitter=f}),ace.define("ace/lib/report_error",["require","exports","module"],function(e,r,m){r.reportError=function(f,g){var w=new Error(f);w.data=g,typeof console=="object"&&console.error&&console.error(w),setTimeout(function(){throw w})}}),ace.define("ace/lib/default_english_messages",["require","exports","module"],function(e,r,m){var f={"autocomplete.popup.aria-roledescription":"Autocomplete suggestions","autocomplete.popup.aria-label":"Autocomplete suggestions","autocomplete.popup.item.aria-roledescription":"item","autocomplete.loading":"Loading...","editor.scroller.aria-roledescription":"editor","editor.scroller.aria-label":"Editor content, press Enter to start editing, press Escape to exit","editor.gutter.aria-roledescription":"editor gutter","editor.gutter.aria-label":"Editor gutter, press Enter to interact with controls using arrow keys, press Escape to exit","error-marker.good-state":"Looks good!","prompt.recently-used":"Recently used","prompt.other-commands":"Other commands","prompt.no-matching-commands":"No matching commands","search-box.find.placeholder":"Search for","search-box.find-all.text":"All","search-box.replace.placeholder":"Replace with","search-box.replace-next.text":"Replace","search-box.replace-all.text":"All","search-box.toggle-replace.title":"Toggle Replace mode","search-box.toggle-regexp.title":"RegExp Search","search-box.toggle-case.title":"CaseSensitive Search","search-box.toggle-whole-word.title":"Whole Word Search","search-box.toggle-in-selection.title":"Search In Selection","search-box.search-counter":"$0 of $1","text-input.aria-roledescription":"editor","text-input.aria-label":"Cursor at row $0","gutter.code-folding.range.aria-label":"Toggle code folding, rows $0 through $1","gutter.code-folding.closed.aria-label":"Toggle code folding, rows $0 through $1","gutter.code-folding.open.aria-label":"Toggle code folding, row $0","gutter.code-folding.closed.title":"Unfold code","gutter.code-folding.open.title":"Fold code","gutter.annotation.aria-label.error":"Error, read annotations row $0","gutter.annotation.aria-label.warning":"Warning, read annotations row $0","gutter.annotation.aria-label.info":"Info, read annotations row $0","inline-fold.closed.title":"Unfold code","gutter-tooltip.aria-label.error.singular":"error","gutter-tooltip.aria-label.error.plural":"errors","gutter-tooltip.aria-label.warning.singular":"warning","gutter-tooltip.aria-label.warning.plural":"warnings","gutter-tooltip.aria-label.info.singular":"information message","gutter-tooltip.aria-label.info.plural":"information messages","gutter.annotation.aria-label.security":"Security finding, read annotations row $0","gutter.annotation.aria-label.hint":"Suggestion, read annotations row $0","gutter-tooltip.aria-label.security.singular":"security finding","gutter-tooltip.aria-label.security.plural":"security findings","gutter-tooltip.aria-label.hint.singular":"suggestion","gutter-tooltip.aria-label.hint.plural":"suggestions","editor.tooltip.disable-editing":"Editing is disabled"};r.defaultEnglishMessages=f}),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(e,r,m){"no use strict";var f=e("./oop"),g=e("./event_emitter").EventEmitter,w=e("./report_error").reportError,u=e("./default_english_messages").defaultEnglishMessages,d={setOptions:function(o){Object.keys(o).forEach(function(s){this.setOption(s,o[s])},this)},getOptions:function(o){var s={};if(o)Array.isArray(o)||(o=Object.keys(o));else{var p=this.$options;o=Object.keys(p).filter(function(b){return!p[b].hidden})}return o.forEach(function(b){s[b]=this.getOption(b)},this),s},setOption:function(o,s){if(this["$"+o]!==s){var p=this.$options[o];if(!p)return a('misspelled option "'+o+'"');if(p.forwardTo)return this[p.forwardTo]&&this[p.forwardTo].setOption(o,s);p.handlesSet||(this["$"+o]=s),p&&p.set&&p.set.call(this,s)}},getOption:function(o){var s=this.$options[o];return s?s.forwardTo?this[s.forwardTo]&&this[s.forwardTo].getOption(o):s&&s.get?s.get.call(this):this["$"+o]:a('misspelled option "'+o+'"')}};function a(o){typeof console<"u"&&console.warn&&console.warn.apply(console,arguments)}var l,c,h=(function(){function o(){this.$defaultOptions={},l=u,c="dollarSigns"}return o.prototype.defineOptions=function(s,p,b){return s.$options||(this.$defaultOptions[p]=s.$options={}),Object.keys(b).forEach(function(x){var M=b[x];typeof M=="string"&&(M={forwardTo:M}),M.name||(M.name=x),s.$options[M.name]=M,"initialValue"in M&&(s["$"+M.name]=M.initialValue)}),f.implement(s,d),this},o.prototype.resetOptions=function(s){Object.keys(s.$options).forEach(function(p){var b=s.$options[p];"value"in b&&s.setOption(p,b.value)})},o.prototype.setDefaultValue=function(s,p,b){if(!s){for(s in this.$defaultOptions)if(this.$defaultOptions[s][p])break;if(!this.$defaultOptions[s][p])return!1}var x=this.$defaultOptions[s]||(this.$defaultOptions[s]={});x[p]&&(x.forwardTo?this.setDefaultValue(x.forwardTo,p,b):x[p].value=b)},o.prototype.setDefaultValues=function(s,p){Object.keys(p).forEach(function(b){this.setDefaultValue(s,b,p[b])},this)},o.prototype.setMessages=function(s,p){l=s,p&&p.placeholders&&(c=p.placeholders)},o.prototype.nls=function(s,p,b){l[s]||(a("No message found for the key '"+s+"' in messages with id "+l.$id+", trying to find a translation for the default string '"+p+"'."),l[p]||a("No message found for the default string '"+p+"' in the provided messages. Falling back to the default English message."));var x=l[s]||l[p]||p;return b&&(c==="dollarSigns"&&(x=x.replace(/\$(\$|[\d]+)/g,function(M,R){return R=="$"?"$":b[R]})),c==="curlyBrackets"&&(x=x.replace(/\{([^\}]+)\}/g,function(M,R){return b[R]}))),x},o})();h.prototype.warn=a,h.prototype.reportError=w,f.implement(h.prototype,g),r.AppConfig=h}),ace.define("ace/theme/textmate-css",["require","exports","module"],function(e,r,m){m.exports=`.ace-tm .ace_gutter {
12
+ background: #f0f0f0;
13
+ color: #333;
14
+ }
15
+
16
+ .ace-tm .ace_print-margin {
17
+ width: 1px;
18
+ background: #e8e8e8;
19
+ }
20
+
21
+ .ace-tm .ace_fold {
22
+ background-color: #6B72E6;
23
+ }
24
+
25
+ .ace-tm {
26
+ background-color: #FFFFFF;
27
+ color: black;
28
+ }
29
+
30
+ .ace-tm .ace_cursor {
31
+ color: black;
32
+ }
33
+
34
+ .ace-tm .ace_invisible {
35
+ color: rgb(191, 191, 191);
36
+ }
37
+
38
+ .ace-tm .ace_storage,
39
+ .ace-tm .ace_keyword {
40
+ color: blue;
41
+ }
42
+
43
+ .ace-tm .ace_constant {
44
+ color: rgb(197, 6, 11);
45
+ }
46
+
47
+ .ace-tm .ace_constant.ace_buildin {
48
+ color: rgb(88, 72, 246);
49
+ }
50
+
51
+ .ace-tm .ace_constant.ace_language {
52
+ color: rgb(88, 92, 246);
53
+ }
54
+
55
+ .ace-tm .ace_constant.ace_library {
56
+ color: rgb(6, 150, 14);
57
+ }
58
+
59
+ .ace-tm .ace_invalid {
60
+ background-color: rgba(255, 0, 0, 0.1);
61
+ color: red;
62
+ }
63
+
64
+ .ace-tm .ace_support.ace_function {
65
+ color: rgb(60, 76, 114);
66
+ }
67
+
68
+ .ace-tm .ace_support.ace_constant {
69
+ color: rgb(6, 150, 14);
70
+ }
71
+
72
+ .ace-tm .ace_support.ace_type,
73
+ .ace-tm .ace_support.ace_class {
74
+ color: rgb(109, 121, 222);
75
+ }
76
+
77
+ .ace-tm .ace_keyword.ace_operator {
78
+ color: rgb(104, 118, 135);
79
+ }
80
+
81
+ .ace-tm .ace_string {
82
+ color: rgb(3, 106, 7);
83
+ }
84
+
85
+ .ace-tm .ace_comment {
86
+ color: rgb(76, 136, 107);
87
+ }
88
+
89
+ .ace-tm .ace_comment.ace_doc {
90
+ color: rgb(0, 102, 255);
91
+ }
92
+
93
+ .ace-tm .ace_comment.ace_doc.ace_tag {
94
+ color: rgb(128, 159, 191);
95
+ }
96
+
97
+ .ace-tm .ace_constant.ace_numeric {
98
+ color: rgb(0, 0, 205);
99
+ }
100
+
101
+ .ace-tm .ace_variable {
102
+ color: rgb(49, 132, 149);
103
+ }
104
+
105
+ .ace-tm .ace_xml-pe {
106
+ color: rgb(104, 104, 91);
107
+ }
108
+
109
+ .ace-tm .ace_entity.ace_name.ace_function {
110
+ color: #0000A2;
111
+ }
112
+
113
+
114
+ .ace-tm .ace_heading {
115
+ color: rgb(12, 7, 255);
116
+ }
117
+
118
+ .ace-tm .ace_list {
119
+ color:rgb(185, 6, 144);
120
+ }
121
+
122
+ .ace-tm .ace_meta.ace_tag {
123
+ color:rgb(0, 22, 142);
124
+ }
125
+
126
+ .ace-tm .ace_string.ace_regex {
127
+ color: rgb(255, 0, 0)
128
+ }
129
+
130
+ .ace-tm .ace_marker-layer .ace_selection {
131
+ background: rgb(181, 213, 255);
132
+ }
133
+ .ace-tm.ace_multiselect .ace_selection.ace_start {
134
+ box-shadow: 0 0 3px 0px white;
135
+ }
136
+ .ace-tm .ace_marker-layer .ace_step {
137
+ background: rgb(252, 255, 0);
138
+ }
139
+
140
+ .ace-tm .ace_marker-layer .ace_stack {
141
+ background: rgb(164, 229, 101);
142
+ }
143
+
144
+ .ace-tm .ace_marker-layer .ace_bracket {
145
+ margin: -1px 0 0 -1px;
146
+ border: 1px solid rgb(192, 192, 192);
147
+ }
148
+
149
+ .ace-tm .ace_marker-layer .ace_active-line {
150
+ background: rgba(0, 0, 0, 0.07);
151
+ }
152
+
153
+ .ace-tm .ace_gutter-active-line {
154
+ background-color : #dcdcdc;
155
+ }
156
+
157
+ .ace-tm .ace_marker-layer .ace_selected-word {
158
+ background: rgb(250, 250, 255);
159
+ border: 1px solid rgb(200, 200, 250);
160
+ }
161
+
162
+ .ace-tm .ace_indent-guide {
163
+ background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;
164
+ }
165
+
166
+ .ace-tm .ace_indent-guide-active {
167
+ background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAAZSURBVHjaYvj///9/hivKyv8BAAAA//8DACLqBhbvk+/eAAAAAElFTkSuQmCC") right repeat-y;
168
+ }
169
+ `}),ace.define("ace/theme/textmate",["require","exports","module","ace/theme/textmate-css","ace/lib/dom"],function(e,r,m){r.isDark=!1,r.cssClass="ace-tm",r.cssText=e("./textmate-css"),r.$id="ace/theme/textmate";var f=e("../lib/dom");f.importCssString(r.cssText,r.cssClass,!1)}),ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/net","ace/lib/dom","ace/lib/app_config","ace/theme/textmate"],function(e,r,m){"no use strict";var f=e("./lib/lang"),g=e("./lib/net"),w=e("./lib/dom"),u=e("./lib/app_config").AppConfig;m.exports=r=new u;var d={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{},loadWorkerFromBlob:!0,sharedPopups:!1,useStrictCSP:null};r.get=function(h){if(!d.hasOwnProperty(h))throw new Error("Unknown config key: "+h);return d[h]},r.set=function(h,o){if(d.hasOwnProperty(h))d[h]=o;else if(this.setDefaultValue("",h,o)==!1)throw new Error("Unknown config key: "+h);h=="useStrictCSP"&&w.useStrictCSP(o)},r.all=function(){return f.copyObject(d)},r.$modes={},r.moduleUrl=function(h,o){if(d.$moduleUrls[h])return d.$moduleUrls[h];var s=h.split("/");o=o||s[s.length-2]||"";var p=o=="snippets"?"/":"-",b=s[s.length-1];if(o=="worker"&&p=="-"){var x=new RegExp("^"+o+"[\\-_]|[\\-_]"+o+"$","g");b=b.replace(x,"")}(!b||b==o)&&s.length>1&&(b=s[s.length-2]);var M=d[o+"Path"];return M==null?M=d.basePath:p=="/"&&(o=p=""),M&&M.slice(-1)!="/"&&(M+="/"),M+o+p+b+this.get("suffix")},r.setModuleUrl=function(h,o){return d.$moduleUrls[h]=o};var a=function(h,o){if(h==="ace/theme/textmate"||h==="./theme/textmate")return o(null,e("./theme/textmate"));if(l)return l(h,o);console.error("loader is not configured")},l;r.setLoader=function(h){l=h},r.dynamicModules=Object.create(null),r.$loading={},r.$loaded={},r.loadModule=function(h,o){var s;if(Array.isArray(h))var p=h[0],b=h[1];else if(typeof h=="string")var b=h;var x=function(M){if(M&&!r.$loading[b])return o&&o(M);if(r.$loading[b]||(r.$loading[b]=[]),r.$loading[b].push(o),!(r.$loading[b].length>1)){var R=function(){a(b,function(k,C){C&&(r.$loaded[b]=C),r._emit("load.module",{name:b,module:C});var L=r.$loading[b];r.$loading[b]=null,L.forEach(function(D){D&&D(C)})})};if(!r.get("packaged"))return R();g.loadScript(r.moduleUrl(b,p),R),c()}};if(r.dynamicModules[b])r.dynamicModules[b]().then(function(M){M.default?x(M.default):x(M)});else{try{s=this.$require(b)}catch{}x(s||r.$loaded[b])}},r.$require=function(h){if(typeof m.require=="function"){var o="require";return m[o](h)}},r.setModuleLoader=function(h,o){r.dynamicModules[h]=o};var c=function(){!d.basePath&&!d.workerPath&&!d.modePath&&!d.themePath&&!Object.keys(d.$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"),c=function(){})};r.version="1.44.0"}),ace.define("ace/loader_build",["require","exports","module","ace/lib/fixoldbrowsers","ace/config"],function(e,r,m){e("./lib/fixoldbrowsers");var f=e("./config");f.setLoader(function(d,a){e([d],function(l){a(null,l)})});var g=(function(){return this||typeof window<"u"&&window})();m.exports=function(d){f.init=w,f.$require=e,d.require=e},w(!0);function w(d){if(!(!g||!g.document)){f.set("packaged",d||e.packaged||m.packaged||g.define&&(void 0).packaged);var a={},l="",c=document.currentScript||document._currentScript,h=c&&c.ownerDocument||document;c&&c.src&&(l=c.src.split(/[?#]/)[0].split("/").slice(0,-1).join("/")||"");for(var o=h.getElementsByTagName("script"),s=0;s<o.length;s++){var p=o[s],b=p.src||p.getAttribute("src");if(b){for(var x=p.attributes,M=0,R=x.length;M<R;M++){var k=x[M];k.name.indexOf("data-ace-")===0&&(a[u(k.name.replace(/^data-ace-/,""))]=k.value)}var C=b.match(/^(.*)\/ace([\-.]\w+)?\.js(\?|$)/);C&&(l=C[1])}}l&&(a.base=a.base||l,a.packaged=!0),a.basePath=a.base,a.workerPath=a.workerPath||a.base,a.modePath=a.modePath||a.base,a.themePath=a.themePath||a.base,delete a.base;for(var L in a)typeof a[L]<"u"&&f.set(L,a[L])}}function u(d){return d.replace(/-(.)/g,function(a,l){return l.toUpperCase()})}}),ace.define("ace/range",["require","exports","module"],function(e,r,m){var f=(function(){function g(w,u,d,a){this.start={row:w,column:u},this.end={row:d,column:a}}return g.prototype.isEqual=function(w){return this.start.row===w.start.row&&this.end.row===w.end.row&&this.start.column===w.start.column&&this.end.column===w.end.column},g.prototype.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},g.prototype.contains=function(w,u){return this.compare(w,u)==0},g.prototype.compareRange=function(w){var u,d=w.end,a=w.start;return u=this.compare(d.row,d.column),u==1?(u=this.compare(a.row,a.column),u==1?2:u==0?1:0):u==-1?-2:(u=this.compare(a.row,a.column),u==-1?-1:u==1?42:0)},g.prototype.comparePoint=function(w){return this.compare(w.row,w.column)},g.prototype.containsRange=function(w){return this.comparePoint(w.start)==0&&this.comparePoint(w.end)==0},g.prototype.intersects=function(w){var u=this.compareRange(w);return u==-1||u==0||u==1},g.prototype.isEnd=function(w,u){return this.end.row==w&&this.end.column==u},g.prototype.isStart=function(w,u){return this.start.row==w&&this.start.column==u},g.prototype.setStart=function(w,u){typeof w=="object"?(this.start.column=w.column,this.start.row=w.row):(this.start.row=w,this.start.column=u)},g.prototype.setEnd=function(w,u){typeof w=="object"?(this.end.column=w.column,this.end.row=w.row):(this.end.row=w,this.end.column=u)},g.prototype.inside=function(w,u){return this.compare(w,u)==0?!(this.isEnd(w,u)||this.isStart(w,u)):!1},g.prototype.insideStart=function(w,u){return this.compare(w,u)==0?!this.isEnd(w,u):!1},g.prototype.insideEnd=function(w,u){return this.compare(w,u)==0?!this.isStart(w,u):!1},g.prototype.compare=function(w,u){return!this.isMultiLine()&&w===this.start.row?u<this.start.column?-1:u>this.end.column?1:0:w<this.start.row?-1:w>this.end.row?1:this.start.row===w?u>=this.start.column?0:-1:this.end.row===w?u<=this.end.column?0:1:0},g.prototype.compareStart=function(w,u){return this.start.row==w&&this.start.column==u?-1:this.compare(w,u)},g.prototype.compareEnd=function(w,u){return this.end.row==w&&this.end.column==u?1:this.compare(w,u)},g.prototype.compareInside=function(w,u){return this.end.row==w&&this.end.column==u?1:this.start.row==w&&this.start.column==u?-1:this.compare(w,u)},g.prototype.clipRows=function(w,u){if(this.end.row>u)var d={row:u+1,column:0};else if(this.end.row<w)var d={row:w,column:0};if(this.start.row>u)var a={row:u+1,column:0};else if(this.start.row<w)var a={row:w,column:0};return g.fromPoints(a||this.start,d||this.end)},g.prototype.extend=function(w,u){var d=this.compare(w,u);if(d==0)return this;if(d==-1)var a={row:w,column:u};else var l={row:w,column:u};return g.fromPoints(a||this.start,l||this.end)},g.prototype.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},g.prototype.isMultiLine=function(){return this.start.row!==this.end.row},g.prototype.clone=function(){return g.fromPoints(this.start,this.end)},g.prototype.collapseRows=function(){return this.end.column==0?new g(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new g(this.start.row,0,this.end.row,0)},g.prototype.toScreenRange=function(w){var u=w.documentToScreenPosition(this.start),d=w.documentToScreenPosition(this.end);return new g(u.row,u.column,d.row,d.column)},g.prototype.moveBy=function(w,u){this.start.row+=w,this.start.column+=u,this.end.row+=w,this.end.column+=u},g})();f.fromPoints=function(g,w){return new f(g.row,g.column,w.row,w.column)},f.comparePoints=function(g,w){return g.row-w.row||g.column-w.column},r.Range=f}),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],function(e,r,m){for(var f=e("./oop"),g={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:"*"}},w={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},u=0;u<10;u++)w["Digit"+u]=48+u,w["Numpad"+u]=96+u,g.PRINTABLE_KEYS[48+u]=""+u,g.FUNCTION_KEYS[96+u]="Numpad"+u;for(var u=65;u<91;u++){var d=String.fromCharCode(u+32);w["Key"+d.toUpperCase()]=u,g.PRINTABLE_KEYS[u]=d}for(var u=1;u<13;u++)w["F"+u]=111+u,g.FUNCTION_KEYS[111+u]="F"+u;var a={Shift:16,Control:17,Alt:18,Meta:224};for(var l in a)w[l]=w[l+"Left"]=w[l+"Right"]=a[l];r.$codeToKeyCode=w,g.PRINTABLE_KEYS[173]="-";for(var c in g.FUNCTION_KEYS){var h=g.FUNCTION_KEYS[c].toLowerCase();g[h]=parseInt(c,10)}for(var c in g.PRINTABLE_KEYS){var h=g.PRINTABLE_KEYS[c].toLowerCase();g[h]=parseInt(c,10)}f.mixin(g,g.MODIFIER_KEYS),f.mixin(g,g.PRINTABLE_KEYS),f.mixin(g,g.FUNCTION_KEYS),g.enter=g.return,g.escape=g.esc,g.del=g.delete,(function(){for(var o=["cmd","ctrl","alt","shift"],s=Math.pow(2,o.length);s--;)g.KEY_MODS[s]=o.filter(function(p){return s&g.KEY_MODS[p]}).join("-")+"-"})(),g.KEY_MODS[0]="",g.KEY_MODS[-1]="input-",f.mixin(r,g),r.default=r,r.keyCodeToString=function(o){var s=g[o];return typeof s!="string"&&(s=String.fromCharCode(o)),s.toLowerCase()}}),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,r,m){var f=e("./keys"),g=e("./useragent"),w=null,u=0,d;function a(){d=!1;try{document.createComment("").addEventListener("test",function(){},{get passive(){return d={passive:!1},!0}})}catch{}}function l(){return d==null&&a(),d}function c(M,R,k){this.elem=M,this.type=R,this.callback=k}c.prototype.destroy=function(){o(this.elem,this.type,this.callback),this.elem=this.type=this.callback=void 0};var h=r.addListener=function(M,R,k,C){M.addEventListener(R,k,l()),C&&C.$toDestroy.push(new c(M,R,k))},o=r.removeListener=function(M,R,k){M.removeEventListener(R,k,l())};r.stopEvent=function(M){return r.stopPropagation(M),r.preventDefault(M),!1},r.stopPropagation=function(M){M.stopPropagation&&M.stopPropagation()},r.preventDefault=function(M){M.preventDefault&&M.preventDefault()},r.getButton=function(M){return M.type=="dblclick"?0:M.type=="contextmenu"||g.isMac&&M.ctrlKey&&!M.altKey&&!M.shiftKey?2:M.button},r.capture=function(M,R,k){var C=M&&M.ownerDocument||document;function L(D){R&&R(D),k&&k(D),o(C,"mousemove",R),o(C,"mouseup",L),o(C,"dragstart",L)}return h(C,"mousemove",R),h(C,"mouseup",L),h(C,"dragstart",L),L},r.addMouseWheelListener=function(M,R,k){h(M,"wheel",function(C){var L=.15,D=C.deltaX||0,I=C.deltaY||0;switch(C.deltaMode){case C.DOM_DELTA_PIXEL:C.wheelX=D*L,C.wheelY=I*L;break;case C.DOM_DELTA_LINE:var T=15;C.wheelX=D*T,C.wheelY=I*T;break;case C.DOM_DELTA_PAGE:var W=150;C.wheelX=D*W,C.wheelY=I*W;break}R(C)},k)},r.addMultiMouseDownListener=function(M,R,k,C,L){var D=0,I,T,W,F={2:"dblclick",3:"tripleclick",4:"quadclick"};function O(S){if(r.getButton(S)!==0?D=0:S.detail>1?(D++,D>4&&(D=1)):D=1,g.isIE){var A=Math.abs(S.clientX-I)>5||Math.abs(S.clientY-T)>5;(!W||A)&&(D=1),W&&clearTimeout(W),W=setTimeout(function(){W=null},R[D-1]||600),D==1&&(I=S.clientX,T=S.clientY)}if(S._clicks=D,k[C]("mousedown",S),D>4)D=0;else if(D>1)return k[C](F[D],S)}Array.isArray(M)||(M=[M]),M.forEach(function(S){h(S,"mousedown",O,L)})};function s(M){return 0|(M.ctrlKey?1:0)|(M.altKey?2:0)|(M.shiftKey?4:0)|(M.metaKey?8:0)}r.getModifierString=function(M){return f.KEY_MODS[s(M)]};function p(M,R,k){var C=s(R);if(!k&&R.code&&(k=f.$codeToKeyCode[R.code]||k),!g.isMac&&w){if(R.getModifierState&&(R.getModifierState("OS")||R.getModifierState("Win"))&&(C|=8),w.altGr)if((3&C)!=3)w.altGr=0;else return;if(k===18||k===17){var L=R.location;if(k===17&&L===1)w[k]==1&&(u=R.timeStamp);else if(k===18&&C===3&&L===2){var D=R.timeStamp-u;D<50&&(w.altGr=!0)}}}if(k in f.MODIFIER_KEYS&&(k=-1),!(!C&&k===13&&R.location===3&&(M(R,C,-k),R.defaultPrevented))){if(g.isChromeOS&&C&8){if(M(R,C,k),R.defaultPrevented)return;C&=-9}return!C&&!(k in f.FUNCTION_KEYS)&&!(k in f.PRINTABLE_KEYS)?!1:M(R,C,k)}}r.addCommandKeyListener=function(M,R,k){var C=null;h(M,"keydown",function(L){w[L.keyCode]=(w[L.keyCode]||0)+1;var D=p(R,L,L.keyCode);return C=L.defaultPrevented,D},k),h(M,"keypress",function(L){C&&(L.ctrlKey||L.altKey||L.shiftKey||L.metaKey)&&(r.stopEvent(L),C=null)},k),h(M,"keyup",function(L){w[L.keyCode]=null},k),w||(b(),h(window,"focus",b))};function b(){w=Object.create(null)}if(typeof window=="object"&&window.postMessage&&!g.isOldIE){var x=1;r.nextTick=function(M,R){R=R||window;var k="zero-timeout-message-"+x++,C=function(L){L.data==k&&(r.stopPropagation(L),o(R,"message",C),M())};h(R,"message",C),R.postMessage(k,"*")}}r.$idleBlocked=!1,r.onIdle=function(M,R){return setTimeout(function k(){r.$idleBlocked?setTimeout(k,100):M()},R)},r.$idleBlockId=null,r.blockIdle=function(M){r.$idleBlockId&&clearTimeout(r.$idleBlockId),r.$idleBlocked=!0,r.$idleBlockId=setTimeout(function(){r.$idleBlocked=!1},M||100)},r.nextFrame=typeof window=="object"&&(window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame),r.nextFrame?r.nextFrame=r.nextFrame.bind(window):r.nextFrame=function(M){setTimeout(M,17)}}),ace.define("ace/clipboard",["require","exports","module"],function(e,r,m){var f;m.exports={lineMode:!1,pasteCancelled:function(){return f&&f>Date.now()-50?!0:f=!1},cancel:function(){f=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(e,r,m){var f=e("../lib/event"),g=e("../config").nls,w=e("../lib/useragent"),u=e("../lib/dom"),d=e("../lib/lang"),a=e("../clipboard"),l=w.isChrome<18,c=w.isIE,h=w.isChrome>63,o=400,s=e("../lib/keys"),p=s.KEY_MODS,b=w.isIOS,x=b?/\s/:/\n/,M=w.isMobile,R=(function(){function k(C,L){var D=this;this.host=L,this.text=u.createElement("textarea"),this.text.className="ace_text-input",this.text.setAttribute("wrap","off"),this.text.setAttribute("autocomplete","off"),this.text.setAttribute("autocorrect","off"),this.text.setAttribute("autocapitalize","off"),this.text.setAttribute("spellcheck","false"),this.text.style.opacity="0",C.insertBefore(this.text,C.firstChild),this.copied=!1,this.pasted=!1,this.inComposition=!1,this.sendingText=!1,this.tempStyle="",M||(this.text.style.fontSize="1px"),this.commandMode=!1,this.ignoreFocusEvents=!1,this.lastValue="",this.lastSelectionStart=0,this.lastSelectionEnd=0,this.lastRestoreEnd=0,this.rowStart=Number.MAX_SAFE_INTEGER,this.rowEnd=Number.MIN_SAFE_INTEGER,this.numberOfExtraLines=0;try{this.$isFocused=document.activeElement===this.text}catch{}this.cancelComposition=this.cancelComposition.bind(this),this.setAriaOptions({role:"textbox"}),f.addListener(this.text,"blur",function(I){D.ignoreFocusEvents||(L.onBlur(I),D.$isFocused=!1)},L),f.addListener(this.text,"focus",function(I){if(!D.ignoreFocusEvents){if(D.$isFocused=!0,w.isEdge)try{if(!document.hasFocus())return}catch{}L.onFocus(I),w.isEdge?setTimeout(D.resetSelection.bind(D)):D.resetSelection()}},L),this.$focusScroll=!1,L.on("beforeEndOperation",function(){var I=L.curOp,T=I&&I.command&&I.command.name;if(T!="insertstring"){var W=T&&(I.docChanged||I.selectionChanged);D.inComposition&&W&&(D.lastValue=D.text.value="",D.onCompositionEnd()),D.resetSelection()}}),L.on("changeSelection",this.setAriaLabel.bind(this)),this.resetSelection=b?this.$resetSelectionIOS:this.$resetSelection,this.$isFocused&&L.onFocus(),this.inputHandler=null,this.afterContextMenu=!1,f.addCommandKeyListener(this.text,function(I,T,W){if(!D.inComposition)return L.onCommandKey(I,T,W)},L),f.addListener(this.text,"select",this.onSelect.bind(this),L),f.addListener(this.text,"input",this.onInput.bind(this),L),f.addListener(this.text,"cut",this.onCut.bind(this),L),f.addListener(this.text,"copy",this.onCopy.bind(this),L),f.addListener(this.text,"paste",this.onPaste.bind(this),L),(!("oncut"in this.text)||!("oncopy"in this.text)||!("onpaste"in this.text))&&f.addListener(C,"keydown",function(I){if(!(w.isMac&&!I.metaKey||!I.ctrlKey))switch(I.keyCode){case 67:D.onCopy(I);break;case 86:D.onPaste(I);break;case 88:D.onCut(I);break}},L),this.syncComposition=d.delayedCall(this.onCompositionUpdate.bind(this),50).schedule.bind(null,null),f.addListener(this.text,"compositionstart",this.onCompositionStart.bind(this),L),f.addListener(this.text,"compositionupdate",this.onCompositionUpdate.bind(this),L),f.addListener(this.text,"keyup",this.onKeyup.bind(this),L),f.addListener(this.text,"keydown",this.syncComposition.bind(this),L),f.addListener(this.text,"compositionend",this.onCompositionEnd.bind(this),L),this.closeTimeout,f.addListener(this.text,"mouseup",this.$onContextMenu.bind(this),L),f.addListener(this.text,"mousedown",function(I){I.preventDefault(),D.onContextMenuClose()},L),f.addListener(L.renderer.scroller,"contextmenu",this.$onContextMenu.bind(this),L),f.addListener(this.text,"contextmenu",this.$onContextMenu.bind(this),L),b&&this.addIosSelectionHandler(C,L,this.text)}return k.prototype.addIosSelectionHandler=function(C,L,D){var I=this,T=null,W=!1;D.addEventListener("keydown",function(O){T&&clearTimeout(T),W=!0},!0),D.addEventListener("keyup",function(O){T=setTimeout(function(){W=!1},100)},!0);var F=function(O){if(document.activeElement===D&&!(W||I.inComposition||L.$mouseHandler.isMousePressed)&&!I.copied){var S=D.selectionStart,A=D.selectionEnd,N=null,B=0;if(S==0?N=s.up:S==1?N=s.home:A>I.lastSelectionEnd&&I.lastValue[A]==`
170
+ `?N=s.end:S<I.lastSelectionStart&&I.lastValue[S-1]==" "?(N=s.left,B=p.option):S<I.lastSelectionStart||S==I.lastSelectionStart&&I.lastSelectionEnd!=I.lastSelectionStart&&S==A?N=s.left:A>I.lastSelectionEnd&&I.lastValue.slice(0,A).split(`
171
+ `).length>2?N=s.down:A>I.lastSelectionEnd&&I.lastValue[A-1]==" "?(N=s.right,B=p.option):(A>I.lastSelectionEnd||A==I.lastSelectionEnd&&I.lastSelectionEnd!=I.lastSelectionStart&&S==A)&&(N=s.right),S!==A&&(B|=p.shift),N){var U=L.onCommandKey({},B,N);if(!U&&L.commands){N=s.keyCodeToString(N);var G=L.commands.findKeyCommand(B,N);G&&L.execCommand(G)}I.lastSelectionStart=S,I.lastSelectionEnd=A,I.resetSelection("")}}};document.addEventListener("selectionchange",F),L.on("destroy",function(){document.removeEventListener("selectionchange",F)})},k.prototype.onContextMenuClose=function(){var C=this;clearTimeout(this.closeTimeout),this.closeTimeout=setTimeout(function(){C.tempStyle&&(C.text.style.cssText=C.tempStyle,C.tempStyle=""),C.host.renderer.$isMousePressed=!1,C.host.renderer.$keepTextAreaAtCursor&&C.host.renderer.$moveTextAreaToCursor()},0)},k.prototype.$onContextMenu=function(C){this.host.textInput.onContextMenu(C),this.onContextMenuClose()},k.prototype.onKeyup=function(C){C.keyCode==27&&this.text.value.length<this.text.selectionStart&&(this.inComposition||(this.lastValue=this.text.value),this.lastSelectionStart=this.lastSelectionEnd=-1,this.resetSelection()),this.syncComposition()},k.prototype.cancelComposition=function(){this.ignoreFocusEvents=!0,this.text.blur(),this.text.focus(),this.ignoreFocusEvents=!1},k.prototype.onCompositionStart=function(C){if(!(this.inComposition||!this.host.onCompositionStart||this.host.$readOnly)&&(this.inComposition={},!this.commandMode)){C.data&&(this.inComposition.useTextareaForIME=!1),setTimeout(this.onCompositionUpdate.bind(this),0),this.host._signal("compositionStart"),this.host.on("mousedown",this.cancelComposition);var L=this.host.getSelectionRange();L.end.row=L.start.row,L.end.column=L.start.column,this.inComposition.markerRange=L,this.inComposition.selectionStart=this.lastSelectionStart,this.host.onCompositionStart(this.inComposition),this.inComposition.useTextareaForIME?(this.lastValue=this.text.value="",this.lastSelectionStart=0,this.lastSelectionEnd=0):(this.text.msGetInputContext&&(this.inComposition.context=this.text.msGetInputContext()),this.text.getInputContext&&(this.inComposition.context=this.text.getInputContext()))}},k.prototype.onCompositionUpdate=function(){if(!(!this.inComposition||!this.host.onCompositionUpdate||this.host.$readOnly)){if(this.commandMode)return this.cancelComposition();if(this.inComposition.useTextareaForIME)this.host.onCompositionUpdate(this.text.value);else{var C=this.text.value;this.sendText(C),this.inComposition.markerRange&&(this.inComposition.context&&(this.inComposition.markerRange.start.column=this.inComposition.selectionStart=this.inComposition.context.compositionStartOffset),this.inComposition.markerRange.end.column=this.inComposition.markerRange.start.column+this.lastSelectionEnd-this.inComposition.selectionStart+this.lastRestoreEnd)}}},k.prototype.onCompositionEnd=function(C){!this.host.onCompositionEnd||this.host.$readOnly||(this.inComposition=!1,this.host.onCompositionEnd(),this.host.off("mousedown",this.cancelComposition),C&&this.onInput())},k.prototype.onCut=function(C){this.doCopy(C,!0)},k.prototype.onCopy=function(C){this.doCopy(C,!1)},k.prototype.onPaste=function(C){var L=this.handleClipboardData(C);a.pasteCancelled()||(typeof L=="string"?(L&&this.host.onPaste(L,C),w.isIE&&setTimeout(this.resetSelection),f.preventDefault(C)):(this.text.value="",this.pasted=!0))},k.prototype.doCopy=function(C,L){var D=this,I=this.host.getCopyText();if(!I)return f.preventDefault(C);this.handleClipboardData(C,I)?(b&&(this.resetSelection(I),this.copied=I,setTimeout(function(){D.copied=!1},10)),L?this.host.onCut():this.host.onCopy(),f.preventDefault(C)):(this.copied=!0,this.text.value=I,this.text.select(),setTimeout(function(){D.copied=!1,D.resetSelection(),L?D.host.onCut():D.host.onCopy()}))},k.prototype.handleClipboardData=function(C,L,D){var I=C.clipboardData||window.clipboardData;if(!(!I||l)){var T=c||D?"Text":"text/plain";try{return L?I.setData(T,L)!==!1:I.getData(T)}catch(W){if(!D)return this.handleClipboardData(W,L,!0)}}},k.prototype.onInput=function(C){if(this.inComposition)return this.onCompositionUpdate();if(C&&C.inputType){if(C.inputType=="historyUndo")return this.host.execCommand("undo");if(C.inputType=="historyRedo")return this.host.execCommand("redo")}var L=this.text.value,D=this.sendText(L,!0);(L.length>o+100||x.test(D)||M&&this.lastSelectionStart<1&&this.lastSelectionStart==this.lastSelectionEnd)&&this.resetSelection()},k.prototype.sendText=function(C,L){if(this.afterContextMenu&&(this.afterContextMenu=!1),this.pasted)return this.resetSelection(),C&&this.host.onPaste(C),this.pasted=!1,"";for(var D=this.text.selectionStart,I=this.text.selectionEnd,T=this.lastSelectionStart,W=this.lastValue.length-this.lastSelectionEnd,F=C,O=C.length-D,S=C.length-I,A=0;T>0&&this.lastValue[A]==C[A];)A++,T--;for(F=F.slice(A),A=1;W>0&&this.lastValue.length-A>this.lastSelectionStart-1&&this.lastValue[this.lastValue.length-A]==C[C.length-A];)A++,W--;O-=A-1,S-=A-1;var N=F.length-A+1;if(N<0&&(T=-N,N=0),F=F.slice(0,N),!L&&!F&&!O&&!T&&!W&&!S)return"";this.sendingText=!0;var B=!1;return w.isAndroid&&F==". "&&(F=" ",B=!0),F&&!T&&!W&&!O&&!S||this.commandMode?this.host.onTextInput(F):this.host.onTextInput(F,{extendLeft:T,extendRight:W,restoreStart:O,restoreEnd:S}),this.sendingText=!1,this.lastValue=C,this.lastSelectionStart=D,this.lastSelectionEnd=I,this.lastRestoreEnd=S,B?`
172
+ `:F},k.prototype.onSelect=function(C){var L=this;if(!this.inComposition){var D=function(I){return I.selectionStart===0&&I.selectionEnd>=L.lastValue.length&&I.value===L.lastValue&&L.lastValue&&I.selectionEnd!==L.lastSelectionEnd};this.copied?this.copied=!1:D(this.text)?(this.host.selectAll(),this.resetSelection()):M&&this.text.selectionStart!=this.lastSelectionStart&&this.resetSelection()}},k.prototype.$resetSelectionIOS=function(C){if(!(!this.$isFocused||this.copied&&!C||this.sendingText)){C||(C="");var L=`
173
+ ab`+C+`cde fg
174
+ `;L!=this.text.value&&(this.text.value=this.lastValue=L);var D=4,I=4+(C.length||(this.host.selection.isEmpty()?0:1));(this.lastSelectionStart!=D||this.lastSelectionEnd!=I)&&this.text.setSelectionRange(D,I),this.lastSelectionStart=D,this.lastSelectionEnd=I}},k.prototype.$resetSelection=function(){var C=this;if(!(this.inComposition||this.sendingText)&&!(!this.$isFocused&&!this.afterContextMenu)){this.inComposition=!0;var L=0,D=0,I="",T=function(G,J){for(var ne=J,de=1;de<=G-C.rowStart&&de<2*C.numberOfExtraLines+1;de++)ne+=C.host.session.getLine(G-de).length+1;return ne};if(this.host.session){var W=this.host.selection,F=W.getRange(),O=W.cursor.row;O===this.rowEnd+1?(this.rowStart=this.rowEnd+1,this.rowEnd=this.rowStart+2*this.numberOfExtraLines):O===this.rowStart-1?(this.rowEnd=this.rowStart-1,this.rowStart=this.rowEnd-2*this.numberOfExtraLines):(O<this.rowStart-1||O>this.rowEnd+1)&&(this.rowStart=O>this.numberOfExtraLines?O-this.numberOfExtraLines:0,this.rowEnd=O>this.numberOfExtraLines?O+this.numberOfExtraLines:2*this.numberOfExtraLines);for(var S=[],A=this.rowStart;A<=this.rowEnd;A++)S.push(this.host.session.getLine(A));if(I=S.join(`
175
+ `),L=T(F.start.row,F.start.column),D=T(F.end.row,F.end.column),F.start.row<this.rowStart){var N=this.host.session.getLine(this.rowStart-1);L=F.start.row<this.rowStart-1?0:L,D+=N.length+1,I=N+`
176
+ `+I}else if(F.end.row>this.rowEnd){var B=this.host.session.getLine(this.rowEnd+1);D=F.end.row>this.rowEnd+1?B.length:F.end.column,D+=I.length+1,I=I+`
177
+ `+B}else M&&O>0&&(I=`
178
+ `+I,D+=1,L+=1);I.length>o&&(L<o&&D<o?I=I.slice(0,o):(I=`
179
+ `,L==D?L=D=0:(L=0,D=1)));var U=I+`
180
+
181
+ `;U!=this.lastValue&&(this.text.value=this.lastValue=U,this.lastSelectionStart=this.lastSelectionEnd=U.length)}if(this.afterContextMenu&&(this.lastSelectionStart=this.text.selectionStart,this.lastSelectionEnd=this.text.selectionEnd),this.lastSelectionEnd!=D||this.lastSelectionStart!=L||this.text.selectionEnd!=this.lastSelectionEnd)try{this.text.setSelectionRange(L,D),this.lastSelectionStart=L,this.lastSelectionEnd=D}catch{}this.inComposition=!1}},k.prototype.setHost=function(C){this.host=C},k.prototype.setNumberOfExtraLines=function(C){if(this.rowStart=Number.MAX_SAFE_INTEGER,this.rowEnd=Number.MIN_SAFE_INTEGER,C<0){this.numberOfExtraLines=0;return}this.numberOfExtraLines=C},k.prototype.setAriaLabel=function(){var C="";if(this.host.$textInputAriaLabel&&(C+="".concat(this.host.$textInputAriaLabel,", ")),this.host.session){var L=this.host.session.selection.cursor.row;C+=g("text-input.aria-label","Cursor at row $0",[L+1])}this.text.setAttribute("aria-label",C)},k.prototype.setAriaOptions=function(C){C.activeDescendant?(this.text.setAttribute("aria-haspopup","true"),this.text.setAttribute("aria-autocomplete",C.inline?"both":"list"),this.text.setAttribute("aria-activedescendant",C.activeDescendant)):(this.text.setAttribute("aria-haspopup","false"),this.text.setAttribute("aria-autocomplete","both"),this.text.removeAttribute("aria-activedescendant")),C.role&&this.text.setAttribute("role",C.role),C.setLabel&&(this.text.setAttribute("aria-roledescription",g("text-input.aria-roledescription","editor")),this.setAriaLabel())},k.prototype.focus=function(){var C=this;if(this.setAriaOptions({setLabel:this.host.renderer.enableKeyboardAccessibility}),this.tempStyle||h||this.$focusScroll=="browser")return this.text.focus({preventScroll:!0});var L=this.text.style.top;this.text.style.position="fixed",this.text.style.top="0px";try{var D=this.text.getBoundingClientRect().top!=0}catch{return}var I=[];if(D)for(var T=this.text.parentElement;T&&T.nodeType==1;)I.push(T),T.setAttribute("ace_nocontext","true"),!T.parentElement&&T.getRootNode?T=T.getRootNode().host:T=T.parentElement;this.text.focus({preventScroll:!0}),D&&I.forEach(function(W){W.removeAttribute("ace_nocontext")}),setTimeout(function(){C.text.style.position="",C.text.style.top=="0px"&&(C.text.style.top=L)},0)},k.prototype.blur=function(){this.text.blur()},k.prototype.isFocused=function(){return this.$isFocused},k.prototype.setInputHandler=function(C){this.inputHandler=C},k.prototype.getInputHandler=function(){return this.inputHandler},k.prototype.getElement=function(){return this.text},k.prototype.setCommandMode=function(C){this.commandMode=C,this.text.readOnly=!1},k.prototype.setReadOnly=function(C){this.commandMode||(this.text.readOnly=C)},k.prototype.setCopyWithEmptySelection=function(C){},k.prototype.onContextMenu=function(C){this.afterContextMenu=!0,this.resetSelection(),this.host._emit("nativecontextmenu",{target:this.host,domEvent:C}),this.moveToMouse(C,!0)},k.prototype.moveToMouse=function(C,L){var D=this;this.tempStyle||(this.tempStyle=this.text.style.cssText),this.text.style.cssText=(L?"z-index:100000;":"")+(w.isIE?"opacity:0.1;":"")+"text-indent: -"+(this.lastSelectionStart+this.lastSelectionEnd)*this.host.renderer.characterWidth*.5+"px;";var I=this.host.container.getBoundingClientRect(),T=u.computedStyle(this.host.container),W=I.top+(parseInt(T.borderTopWidth)||0),F=I.left+(parseInt(T.borderLeftWidth)||0),O=I.bottom-W-this.text.clientHeight-2,S=function(A){u.translate(D.text,A.clientX-F-2,Math.min(A.clientY-W-2,O))};S(C),C.type=="mousedown"&&(this.host.renderer.$isMousePressed=!0,clearTimeout(this.closeTimeout),w.isWin&&f.capture(this.host.container,S,this.onContextMenuClose.bind(this)))},k.prototype.destroy=function(){this.text.parentElement&&this.text.parentElement.removeChild(this.text)},k})();r.TextInput=R,r.$setUserAgentForTests=function(k,C){M=k,b=C}}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],function(e,r,m){var f=e("../lib/useragent"),g=0,w=550,u=(function(){function l(c){c.$clickSelection=null;var h=c.editor;h.setDefaultHandler("mousedown",this.onMouseDown.bind(c)),h.setDefaultHandler("dblclick",this.onDoubleClick.bind(c)),h.setDefaultHandler("tripleclick",this.onTripleClick.bind(c)),h.setDefaultHandler("quadclick",this.onQuadClick.bind(c)),h.setDefaultHandler("mousewheel",this.onMouseWheel.bind(c));var o=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];o.forEach(function(s){c[s]=this[s]},this),c.selectByLines=this.extendSelectionBy.bind(c,"getLineRange"),c.selectByWords=this.extendSelectionBy.bind(c,"getWordRange")}return l.prototype.onMouseDown=function(c){var h=c.inSelection(),o=c.getDocumentPosition();this.mousedownEvent=c;var s=this.editor,p=c.getButton();if(p!==0){var b=s.getSelectionRange(),x=b.isEmpty();(x||p==1)&&s.selection.moveToPosition(o),p==2&&(s.textInput.onContextMenu(c.domEvent),f.isMozilla||c.preventDefault());return}if(this.mousedownEvent.time=Date.now(),h&&!s.isFocused()&&(s.focus(),this.$focusTimeout&&!this.$clickSelection&&!s.inMultiSelectMode)){this.setState("focusWait"),this.captureMouse(c);return}return this.captureMouse(c),this.startSelect(o,c.domEvent._clicks>1),c.preventDefault()},l.prototype.startSelect=function(c,h){c=c||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var o=this.editor;this.mousedownEvent&&(this.mousedownEvent.getShiftKey()?o.selection.selectToPosition(c):h||o.selection.moveToPosition(c),h||this.select(),o.setStyle("ace_selecting"),this.setState("select"))},l.prototype.select=function(){var c,h=this.editor,o=h.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var s=this.$clickSelection.comparePoint(o);if(s==-1)c=this.$clickSelection.end;else if(s==1)c=this.$clickSelection.start;else{var p=a(this.$clickSelection,o,h.session);o=p.cursor,c=p.anchor}h.selection.setSelectionAnchor(c.row,c.column)}h.selection.selectToPosition(o),h.renderer.scrollCursorIntoView()},l.prototype.extendSelectionBy=function(c){var h,o=this.editor,s=o.renderer.screenToTextCoordinates(this.x,this.y),p=o.selection[c](s.row,s.column);if(this.$clickSelection){var b=this.$clickSelection.comparePoint(p.start),x=this.$clickSelection.comparePoint(p.end);if(b==-1&&x<=0)h=this.$clickSelection.end,(p.end.row!=s.row||p.end.column!=s.column)&&(s=p.start);else if(x==1&&b>=0)h=this.$clickSelection.start,(p.start.row!=s.row||p.start.column!=s.column)&&(s=p.end);else if(b==-1&&x==1)s=p.end,h=p.start;else{var M=a(this.$clickSelection,s,o.session);s=M.cursor,h=M.anchor}o.selection.setSelectionAnchor(h.row,h.column)}o.selection.selectToPosition(s),o.renderer.scrollCursorIntoView()},l.prototype.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting")},l.prototype.focusWait=function(){var c=d(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),h=Date.now();(c>g||h-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},l.prototype.onDoubleClick=function(c){var h=c.getDocumentPosition(),o=this.editor,s=o.session,p=s.getBracketRange(h);p?(p.isEmpty()&&(p.start.column--,p.end.column++),this.setState("select")):(p=o.selection.getWordRange(h.row,h.column),this.setState("selectByWords")),this.$clickSelection=p,this.select()},l.prototype.onTripleClick=function(c){var h=c.getDocumentPosition(),o=this.editor;this.setState("selectByLines");var s=o.getSelectionRange();s.isMultiLine()&&s.contains(h.row,h.column)?(this.$clickSelection=o.selection.getLineRange(s.start.row),this.$clickSelection.end=o.selection.getLineRange(s.end.row).end):this.$clickSelection=o.selection.getLineRange(h.row),this.select()},l.prototype.onQuadClick=function(c){var h=this.editor;h.selectAll(),this.$clickSelection=h.getSelectionRange(),this.setState("selectAll")},l.prototype.onMouseWheel=function(c){if(!c.getAccelKey()){c.getShiftKey()&&c.wheelY&&!c.wheelX&&(c.wheelX=c.wheelY,c.wheelY=0);var h=this.editor;this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0});var o=this.$lastScroll,s=c.domEvent.timeStamp,p=s-o.t,b=p?c.wheelX/p:o.vx,x=p?c.wheelY/p:o.vy;p<w&&(b=(b+o.vx)/2,x=(x+o.vy)/2);var M=Math.abs(b/x),R=!1;if(M>=1&&h.renderer.isScrollableBy(c.wheelX*c.speed,0)&&(R=!0),M<=1&&h.renderer.isScrollableBy(0,c.wheelY*c.speed)&&(R=!0),R)o.allowed=s;else if(s-o.allowed<w){var k=Math.abs(b)<=1.5*Math.abs(o.vx)&&Math.abs(x)<=1.5*Math.abs(o.vy);k?(R=!0,o.allowed=s):o.allowed=0}if(o.t=s,o.vx=b,o.vy=x,R)return h.renderer.scrollBy(c.wheelX*c.speed,c.wheelY*c.speed),c.stop()}},l})();u.prototype.selectEnd=u.prototype.selectByLinesEnd,u.prototype.selectAllEnd=u.prototype.selectByLinesEnd,u.prototype.selectByWordsEnd=u.prototype.selectByLinesEnd,r.DefaultHandlers=u;function d(l,c,h,o){return Math.sqrt(Math.pow(h-l,2)+Math.pow(o-c,2))}function a(l,c,h){if(l.start.row==l.end.row)var o=2*c.column-l.start.column-l.end.column;else if(l.start.row==l.end.row-1&&!l.start.column&&!l.end.column)var o=3*c.column-2*h.getLine(l.start.row).length;else var o=2*c.row-l.start.row-l.end.row;return o<0?{cursor:l.start,anchor:l.end}:{cursor:l.end,anchor:l.start}}}),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(e,r,m){var f=e("../lib/event"),g=e("../lib/useragent"),w=(function(){function u(d,a){this.speed,this.wheelX,this.wheelY,this.domEvent=d,this.editor=a,this.x=this.clientX=d.clientX,this.y=this.clientY=d.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1}return u.prototype.stopPropagation=function(){f.stopPropagation(this.domEvent),this.propagationStopped=!0},u.prototype.preventDefault=function(){f.preventDefault(this.domEvent),this.defaultPrevented=!0},u.prototype.stop=function(){this.stopPropagation(),this.preventDefault()},u.prototype.getDocumentPosition=function(){return this.$pos?this.$pos:(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY),this.$pos)},u.prototype.getGutterRow=function(){var d=this.getDocumentPosition().row,a=this.editor.session.documentToScreenRow(d,0),l=this.editor.session.documentToScreenRow(this.editor.renderer.$gutterLayer.$lines.get(0).row,0);return a-l},u.prototype.inSelection=function(){if(this.$inSelection!==null)return this.$inSelection;var d=this.editor,a=d.getSelectionRange();if(a.isEmpty())this.$inSelection=!1;else{var l=this.getDocumentPosition();this.$inSelection=a.contains(l.row,l.column)}return this.$inSelection},u.prototype.getButton=function(){return f.getButton(this.domEvent)},u.prototype.getShiftKey=function(){return this.domEvent.shiftKey},u.prototype.getAccelKey=function(){return g.isMac?this.domEvent.metaKey:this.domEvent.ctrlKey},u})();r.MouseEvent=w}),ace.define("ace/lib/scroll",["require","exports","module"],function(e,r,m){r.preventParentScroll=function(f){f.stopPropagation();var g=f.currentTarget,w=g.scrollHeight>g.clientHeight;w||f.preventDefault()}}),ace.define("ace/tooltip",["require","exports","module","ace/lib/dom","ace/lib/event","ace/range","ace/lib/scroll"],function(e,r,m){var f=this&&this.__extends||(function(){var s=function(p,b){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,M){x.__proto__=M}||function(x,M){for(var R in M)Object.prototype.hasOwnProperty.call(M,R)&&(x[R]=M[R])},s(p,b)};return function(p,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");s(p,b);function x(){this.constructor=p}p.prototype=b===null?Object.create(b):(x.prototype=b.prototype,new x)}})(),g=this&&this.__values||function(s){var p=typeof Symbol=="function"&&Symbol.iterator,b=p&&s[p],x=0;if(b)return b.call(s);if(s&&typeof s.length=="number")return{next:function(){return s&&x>=s.length&&(s=void 0),{value:s&&s[x++],done:!s}}};throw new TypeError(p?"Object is not iterable.":"Symbol.iterator is not defined.")},w=e("./lib/dom");e("./lib/event");var u=e("./range").Range,d=e("./lib/scroll").preventParentScroll,a="ace_tooltip",l=(function(){function s(p){this.isOpen=!1,this.$element=null,this.$parentNode=p}return s.prototype.$init=function(){return this.$element=w.createElement("div"),this.$element.className=a,this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},s.prototype.getElement=function(){return this.$element||this.$init()},s.prototype.setText=function(p){this.getElement().textContent=p},s.prototype.setHtml=function(p){this.getElement().innerHTML=p},s.prototype.setPosition=function(p,b){this.getElement().style.left=p+"px",this.getElement().style.top=b+"px"},s.prototype.setClassName=function(p){w.addCssClass(this.getElement(),p)},s.prototype.setTheme=function(p){this.theme&&(this.theme.isDark&&w.removeCssClass(this.getElement(),"ace_dark"),this.theme.cssClass&&w.removeCssClass(this.getElement(),this.theme.cssClass)),p.isDark&&w.addCssClass(this.getElement(),"ace_dark"),p.cssClass&&w.addCssClass(this.getElement(),p.cssClass),this.theme={isDark:p.isDark,cssClass:p.cssClass}},s.prototype.show=function(p,b,x){p!=null&&this.setText(p),b!=null&&x!=null&&this.setPosition(b,x),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},s.prototype.hide=function(p){this.isOpen&&(this.getElement().style.display="none",this.getElement().className=a,this.isOpen=!1)},s.prototype.getHeight=function(){return this.getElement().offsetHeight},s.prototype.getWidth=function(){return this.getElement().offsetWidth},s.prototype.destroy=function(){this.isOpen=!1,this.$element&&this.$element.parentNode&&this.$element.parentNode.removeChild(this.$element)},s})(),c=(function(){function s(){this.popups=[]}return s.prototype.addPopup=function(p){this.popups.push(p),this.updatePopups()},s.prototype.removePopup=function(p){var b=this.popups.indexOf(p);b!==-1&&(this.popups.splice(b,1),this.updatePopups())},s.prototype.updatePopups=function(){var p,b,x,M;this.popups.sort(function(F,O){return O.priority-F.priority});var R=[];try{for(var k=g(this.popups),C=k.next();!C.done;C=k.next()){var L=C.value,D=!0;try{for(var I=(x=void 0,g(R)),T=I.next();!T.done;T=I.next()){var W=T.value;if(this.doPopupsOverlap(W,L)){D=!1;break}}}catch(F){x={error:F}}finally{try{T&&!T.done&&(M=I.return)&&M.call(I)}finally{if(x)throw x.error}}D?R.push(L):L.hide()}}catch(F){p={error:F}}finally{try{C&&!C.done&&(b=k.return)&&b.call(k)}finally{if(p)throw p.error}}},s.prototype.doPopupsOverlap=function(p,b){var x=p.getElement().getBoundingClientRect(),M=b.getElement().getBoundingClientRect();return x.left<M.right&&x.right>M.left&&x.top<M.bottom&&x.bottom>M.top},s})(),h=new c;r.popupManager=h,r.Tooltip=l;var o=(function(s){f(p,s);function p(b){b===void 0&&(b=document.body);var x=s.call(this,b)||this;x.timeout=void 0,x.lastT=0,x.idleTime=350,x.lastEvent=void 0,x.onMouseOut=x.onMouseOut.bind(x),x.onMouseMove=x.onMouseMove.bind(x),x.waitForHover=x.waitForHover.bind(x),x.hide=x.hide.bind(x);var M=x.getElement();return M.style.whiteSpace="pre-wrap",M.style.pointerEvents="auto",M.addEventListener("mouseout",x.onMouseOut),M.tabIndex=-1,M.addEventListener("blur",(function(){M.contains(document.activeElement)||this.hide()}).bind(x)),M.addEventListener("wheel",d),x}return p.prototype.addToEditor=function(b){b.on("mousemove",this.onMouseMove),b.on("mousedown",this.hide);var x=b.renderer.getMouseEventTarget();x&&typeof x.removeEventListener=="function"&&x.addEventListener("mouseout",this.onMouseOut,!0)},p.prototype.removeFromEditor=function(b){b.off("mousemove",this.onMouseMove),b.off("mousedown",this.hide);var x=b.renderer.getMouseEventTarget();x&&typeof x.removeEventListener=="function"&&x.removeEventListener("mouseout",this.onMouseOut,!0),this.timeout&&(clearTimeout(this.timeout),this.timeout=null)},p.prototype.onMouseMove=function(b,x){this.lastEvent=b,this.lastT=Date.now();var M=x.$mouseHandler.isMousePressed;if(this.isOpen){var R=this.lastEvent&&this.lastEvent.getDocumentPosition();(!this.range||!this.range.contains(R.row,R.column)||M||this.isOutsideOfText(this.lastEvent))&&this.hide()}this.timeout||M||(this.lastEvent=b,this.timeout=setTimeout(this.waitForHover,this.idleTime))},p.prototype.waitForHover=function(){this.timeout&&clearTimeout(this.timeout);var b=Date.now()-this.lastT;if(this.idleTime-b>10){this.timeout=setTimeout(this.waitForHover,this.idleTime-b);return}this.timeout=null,this.lastEvent&&!this.isOutsideOfText(this.lastEvent)&&this.$gatherData(this.lastEvent,this.lastEvent.editor)},p.prototype.isOutsideOfText=function(b){var x=b.editor,M=b.getDocumentPosition(),R=x.session.getLine(M.row);if(M.column==R.length){var k=x.renderer.pixelToScreenCoordinates(b.clientX,b.clientY),C=x.session.documentToScreenPosition(M.row,M.column);if(C.column!=k.column||C.row!=k.row)return!0}return!1},p.prototype.setDataProvider=function(b){this.$gatherData=b},p.prototype.showForRange=function(b,x,M,R){if(!(R&&R!=this.lastEvent)&&!(this.isOpen&&document.activeElement==this.getElement())){var k=b.renderer;this.isOpen||(h.addPopup(this),this.$registerCloseEvents(),this.setTheme(k.theme)),this.isOpen=!0,this.range=u.fromPoints(x.start,x.end);var C=k.textToScreenCoordinates(x.start.row,x.start.column),L=k.scroller.getBoundingClientRect();C.pageX<L.left&&(C.pageX=L.left);var D=this.getElement();D.innerHTML="",D.appendChild(M),D.style.maxHeight="",D.style.display="block",this.$setPosition(b,C,!0,x),w.$fixPositionBug(D)}},p.prototype.$setPosition=function(b,x,M,R){var k=10;M&&this.addMarker(R,b.session);var C=b.renderer,L=this.getElement(),D=L.offsetHeight,I=L.offsetWidth,T=x.pageY,W=x.pageX,F=window.innerHeight-T-C.lineHeight,O=this.$shouldPlaceAbove(D,T,F-k);L.style.maxHeight=(O?T:F)-k+"px",L.style.top=O?"":T+C.lineHeight+"px",L.style.bottom=O?window.innerHeight-T+"px":"",L.style.left=Math.min(W,window.innerWidth-I-k)+"px"},p.prototype.$shouldPlaceAbove=function(b,x,M){return!(x-b<0&&x<M)},p.prototype.addMarker=function(b,x){this.marker&&this.$markerSession.removeMarker(this.marker),this.$markerSession=x,this.marker=x&&x.addMarker(b,"ace_highlight-marker","text")},p.prototype.hide=function(b){b&&this.$fromKeyboard&&b.type=="keydown"&&b.code=="Escape"||!b&&document.activeElement==this.getElement()||b&&b.target&&(b.type!="keydown"||b.ctrlKey||b.metaKey)&&this.$element.contains(b.target)||(this.lastEvent=null,this.timeout&&clearTimeout(this.timeout),this.timeout=null,this.addMarker(null),this.isOpen&&(this.$fromKeyboard=!1,this.$removeCloseEvents(),this.getElement().style.display="none",this.isOpen=!1,h.removePopup(this)))},p.prototype.$registerCloseEvents=function(){window.addEventListener("keydown",this.hide,!0),window.addEventListener("wheel",this.hide,!0),window.addEventListener("mousedown",this.hide,!0)},p.prototype.$removeCloseEvents=function(){window.removeEventListener("keydown",this.hide,!0),window.removeEventListener("wheel",this.hide,!0),window.removeEventListener("mousedown",this.hide,!0)},p.prototype.onMouseOut=function(b){this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.lastEvent=null,this.isOpen&&(!b.relatedTarget||this.getElement().contains(b.relatedTarget)||b&&b.currentTarget.contains(b.relatedTarget)||b.relatedTarget.classList.contains("ace_content")||this.hide())},p})(l);r.HoverTooltip=o}),ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/mouse/mouse_event","ace/tooltip","ace/config","ace/range"],function(e,r,m){var f=this&&this.__extends||(function(){var o=function(s,p){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,x){b.__proto__=x}||function(b,x){for(var M in x)Object.prototype.hasOwnProperty.call(x,M)&&(b[M]=x[M])},o(s,p)};return function(s,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");o(s,p);function b(){this.constructor=s}s.prototype=p===null?Object.create(p):(b.prototype=p.prototype,new b)}})(),g=this&&this.__values||function(o){var s=typeof Symbol=="function"&&Symbol.iterator,p=s&&o[s],b=0;if(p)return p.call(o);if(o&&typeof o.length=="number")return{next:function(){return o&&b>=o.length&&(o=void 0),{value:o&&o[b++],done:!o}}};throw new TypeError(s?"Object is not iterable.":"Symbol.iterator is not defined.")},w=e("../lib/dom"),u=e("./mouse_event").MouseEvent,d=e("../tooltip").HoverTooltip,a=e("../config").nls,l=e("../range").Range;function c(o){var s=o.editor,p=s.renderer.$gutterLayer;o.$tooltip=new h(s),o.$tooltip.addToEditor(s),o.$tooltip.setDataProvider(function(b,x){var M=b.getDocumentPosition().row;o.$tooltip.showTooltip(M)}),o.editor.setDefaultHandler("guttermousedown",function(b){if(!(!s.isFocused()||b.getButton()!=0)){var x=p.getRegion(b);if(x!="foldWidgets"){var M=b.getDocumentPosition().row,R=s.session.selection;if(b.getShiftKey())R.selectTo(M,0);else{if(b.domEvent.detail==2)return s.selectAll(),b.preventDefault();o.$clickSelection=s.selection.getLineRange(M)}return o.setState("selectByLines"),o.captureMouse(b),b.preventDefault()}}})}r.GutterHandler=c;var h=(function(o){f(s,o);function s(p){var b=o.call(this,p.container)||this;b.id="gt"+ ++s.$uid,b.editor=p,b.visibleTooltipRow;var x=b.getElement();return x.setAttribute("role","tooltip"),x.setAttribute("id",b.id),x.style.pointerEvents="auto",b.idleTime=50,b.onDomMouseMove=b.onDomMouseMove.bind(b),b.onDomMouseOut=b.onDomMouseOut.bind(b),b.setClassName("ace_gutter-tooltip"),b}return s.prototype.onDomMouseMove=function(p){var b=new u(p,this.editor);this.onMouseMove(b,this.editor)},s.prototype.onDomMouseOut=function(p){var b=new u(p,this.editor);this.onMouseOut(b)},s.prototype.addToEditor=function(p){var b=p.renderer.$gutter;b.addEventListener("mousemove",this.onDomMouseMove),b.addEventListener("mouseout",this.onDomMouseOut),o.prototype.addToEditor.call(this,p)},s.prototype.removeFromEditor=function(p){var b=p.renderer.$gutter;b.removeEventListener("mousemove",this.onDomMouseMove),b.removeEventListener("mouseout",this.onDomMouseOut),o.prototype.removeFromEditor.call(this,p)},s.prototype.destroy=function(){this.editor&&this.removeFromEditor(this.editor),o.prototype.destroy.call(this)},Object.defineProperty(s,"annotationLabels",{get:function(){return{error:{singular:a("gutter-tooltip.aria-label.error.singular","error"),plural:a("gutter-tooltip.aria-label.error.plural","errors")},security:{singular:a("gutter-tooltip.aria-label.security.singular","security finding"),plural:a("gutter-tooltip.aria-label.security.plural","security findings")},warning:{singular:a("gutter-tooltip.aria-label.warning.singular","warning"),plural:a("gutter-tooltip.aria-label.warning.plural","warnings")},info:{singular:a("gutter-tooltip.aria-label.info.singular","information message"),plural:a("gutter-tooltip.aria-label.info.plural","information messages")},hint:{singular:a("gutter-tooltip.aria-label.hint.singular","suggestion"),plural:a("gutter-tooltip.aria-label.hint.plural","suggestions")}}},enumerable:!1,configurable:!0}),s.prototype.showTooltip=function(p){var b,x=this.editor.renderer.$gutterLayer,M=x.$annotations[p],R;M?R={displayText:Array.from(M.displayText),type:Array.from(M.type)}:R={displayText:[],type:[]};var k=x.session.getFoldLine(p);if(k&&x.$showFoldedAnnotations){for(var C={error:[],security:[],warning:[],info:[],hint:[]},L={error:1,security:2,warning:3,info:4,hint:5},D,I=p+1;I<=k.end.row;I++)if(x.$annotations[I])for(var T=0;T<x.$annotations[I].text.length;T++){var W=x.$annotations[I].type[T];C[W].push(x.$annotations[I].text[T]),(!D||L[W]<L[D])&&(D=W)}if(["error","security","warning"].includes(D)){var F="".concat(s.annotationsToSummaryString(C)," in folded code.");R.displayText.push(F),R.type.push(D+"_fold")}}if(R.displayText.length===0)return this.hide();for(var O={error:[],security:[],warning:[],info:[],hint:[]},S=x.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",I=0;I<R.displayText.length;I++){var A=w.createElement("span"),N=w.createElement("span");(b=N.classList).add.apply(b,["ace_".concat(R.type[I]),S]),N.setAttribute("aria-label","".concat(s.annotationLabels[R.type[I].replace("_fold","")].singular)),N.setAttribute("role","img"),N.appendChild(w.createTextNode(" ")),A.appendChild(N),A.appendChild(w.createTextNode(R.displayText[I])),A.appendChild(w.createElement("br")),O[R.type[I].replace("_fold","")].push(A)}var B=w.createElement("span");O.error.forEach(function(J){return B.appendChild(J)}),O.security.forEach(function(J){return B.appendChild(J)}),O.warning.forEach(function(J){return B.appendChild(J)}),O.info.forEach(function(J){return B.appendChild(J)}),O.hint.forEach(function(J){return B.appendChild(J)}),B.setAttribute("aria-live","polite");var U=this.$findLinkedAnnotationNode(p);U&&U.setAttribute("aria-describedby",this.id);var G=l.fromPoints({row:p,column:0},{row:p,column:0});this.showForRange(this.editor,G,B),this.visibleTooltipRow=p,this.editor._signal("showGutterTooltip",this)},s.prototype.$setPosition=function(p,b,x,M){var R=this.$findCellByRow(M.start.row);if(R){var k=R&&R.element,C=k&&k.querySelector(".ace_gutter_annotation");if(C){var L=C.getBoundingClientRect();if(L){var D={pageX:L.right,pageY:L.top};return o.prototype.$setPosition.call(this,p,D,!1,M)}}}},s.prototype.$shouldPlaceAbove=function(p,b,x){return x<p},s.prototype.$findLinkedAnnotationNode=function(p){var b=this.$findCellByRow(p);if(b){var x=b.element;if(x.childNodes.length>2)return x.childNodes[2]}},s.prototype.$findCellByRow=function(p){return this.editor.renderer.$gutterLayer.$lines.cells.find(function(b){return b.row===p})},s.prototype.hide=function(p){if(this.isOpen){if(this.$element.removeAttribute("aria-live"),this.visibleTooltipRow!=null){var b=this.$findLinkedAnnotationNode(this.visibleTooltipRow);b&&b.removeAttribute("aria-describedby")}this.visibleTooltipRow=void 0,this.editor._signal("hideGutterTooltip",this),o.prototype.hide.call(this,p)}},s.annotationsToSummaryString=function(p){var b,x,M=[],R=["error","security","warning","info","hint"];try{for(var k=g(R),C=k.next();!C.done;C=k.next()){var L=C.value;if(p[L].length){var D=p[L].length===1?s.annotationLabels[L].singular:s.annotationLabels[L].plural;M.push("".concat(p[L].length," ").concat(D))}}}catch(I){b={error:I}}finally{try{C&&!C.done&&(x=k.return)&&x.call(k)}finally{if(b)throw b.error}}return M.join(", ")},s.prototype.isOutsideOfText=function(p){var b=p.editor,x=b.renderer.$gutter.getBoundingClientRect();return!(p.clientX>=x.left&&p.clientX<=x.right&&p.clientY>=x.top&&p.clientY<=x.bottom)},s})(d);h.$uid=0,r.GutterTooltip=h}),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(e,r,m){var f=e("../lib/dom"),g=e("../lib/event"),w=e("../lib/useragent"),u=200,d=200,a=5;function l(h){var o=h.editor,s=f.createElement("div");s.style.cssText="top:-100px;position:absolute;z-index:2147483647;opacity:0.5",s.textContent=" ";var p=["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"];p.forEach(function(ee){h[ee]=this[ee]},this),o.on("mousedown",this.onMouseDown.bind(h));var b=o.container,x,M,R,k,C,L,D=0,I,T,W,F,O;this.onDragStart=function(ee){if(this.cancelDrag||!b.draggable){var se=this;return setTimeout(function(){se.startSelect(),se.captureMouse(ee)},0),ee.preventDefault()}C=o.getSelectionRange();var ce=ee.dataTransfer;ce.effectAllowed=o.getReadOnly()?"copy":"copyMove",o.container.appendChild(s),ce.setDragImage&&ce.setDragImage(s,0,0),setTimeout(function(){o.container.removeChild(s)}),ce.clearData(),ce.setData("Text",o.session.getTextRange()),T=!0,this.setState("drag")},this.onDragEnd=function(ee){if(b.draggable=!1,T=!1,this.setState(null),!o.getReadOnly()){var se=ee.dataTransfer.dropEffect;!I&&se=="move"&&o.session.remove(o.getSelectionRange()),o.$resetCursorStyle()}this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(ee){if(!(o.getReadOnly()||!ne(ee.dataTransfer)))return M=ee.clientX,R=ee.clientY,x||B(),D++,ee.dataTransfer.dropEffect=I=de(ee),g.preventDefault(ee)},this.onDragOver=function(ee){if(!(o.getReadOnly()||!ne(ee.dataTransfer)))return M=ee.clientX,R=ee.clientY,x||(B(),D++),G!==null&&(G=null),ee.dataTransfer.dropEffect=I=de(ee),g.preventDefault(ee)},this.onDragLeave=function(ee){if(D--,D<=0&&x)return U(),I=null,g.preventDefault(ee)},this.onDrop=function(ee){if(L){var se=ee.dataTransfer;if(T)switch(I){case"move":C.contains(L.row,L.column)?C={start:L,end:L}:C=o.moveText(C,L);break;case"copy":C=o.moveText(C,L,!0);break}else{var ce=se.getData("Text");C={start:L,end:o.session.insert(L,ce)},o.focus(),I=null}return U(),g.preventDefault(ee)}},g.addListener(b,"dragstart",this.onDragStart.bind(h),o),g.addListener(b,"dragend",this.onDragEnd.bind(h),o),g.addListener(b,"dragenter",this.onDragEnter.bind(h),o),g.addListener(b,"dragover",this.onDragOver.bind(h),o),g.addListener(b,"dragleave",this.onDragLeave.bind(h),o),g.addListener(b,"drop",this.onDrop.bind(h),o);function S(ee,se){var ce=Date.now(),le=!se||ee.row!=se.row,pe=!se||ee.column!=se.column;if(!F||le||pe)o.moveCursorToPosition(ee),F=ce,O={x:M,y:R};else{var me=c(O.x,O.y,M,R);me>a?F=null:ce-F>=d&&(o.renderer.scrollCursorIntoView(),F=null)}}function A(ee,se){var ce=Date.now(),le=o.renderer.layerConfig.lineHeight,pe=o.renderer.layerConfig.characterWidth,me=o.renderer.scroller.getBoundingClientRect(),$e={x:{left:M-me.left,right:me.right-M},y:{top:R-me.top,bottom:me.bottom-R}},Ee=Math.min($e.x.left,$e.x.right),He=Math.min($e.y.top,$e.y.bottom),Ue={row:ee.row,column:ee.column};Ee/pe<=2&&(Ue.column+=$e.x.left<$e.x.right?-3:2),He/le<=1&&(Ue.row+=$e.y.top<$e.y.bottom?-1:1);var ot=ee.row!=Ue.row,Qe=ee.column!=Ue.column,lt=!se||ee.row!=se.row;ot||Qe&&!lt?W?ce-W>=u&&o.renderer.scrollCursorIntoView(Ue):W=ce:W=null}function N(){var ee=L;L=o.renderer.screenToTextCoordinates(M,R),S(L,ee),A(L,ee)}function B(){C=o.selection.toOrientedRange(),x=o.session.addMarker(C,"ace_selection",o.getSelectionStyle()),o.clearSelection(),o.isFocused()&&o.renderer.$cursorLayer.setBlinking(!1),clearInterval(k),N(),k=setInterval(N,20),D=0,g.addListener(document,"mousemove",J)}function U(){clearInterval(k),o.session.removeMarker(x),x=null,o.selection.fromOrientedRange(C),o.isFocused()&&!T&&o.$resetCursorStyle(),C=null,L=null,D=0,W=null,F=null,g.removeListener(document,"mousemove",J)}var G=null;function J(){G==null&&(G=setTimeout(function(){G!=null&&x&&U()},20))}function ne(ee){var se=ee.types;return!se||Array.prototype.some.call(se,function(ce){return ce=="text/plain"||ce=="Text"})}function de(ee){var se=["copy","copymove","all","uninitialized"],ce=["move","copymove","linkmove","all","uninitialized"],le=w.isMac?ee.altKey:ee.ctrlKey,pe="uninitialized";try{pe=ee.dataTransfer.effectAllowed.toLowerCase()}catch{}var me="none";return le&&se.indexOf(pe)>=0?me="copy":ce.indexOf(pe)>=0?me="move":se.indexOf(pe)>=0&&(me="copy"),me}}(function(){this.dragWait=function(){var h=Date.now()-this.mousedownEvent.time;h>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var h=this.editor.container;h.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(h){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var h=this.editor,o=h.container;o.draggable=!0,h.renderer.$cursorLayer.setBlinking(!1),h.setStyle("ace_dragging");var s=w.isWin?"default":"move";h.renderer.setCursorStyle(s),this.setState("dragReady")},this.onMouseDrag=function(h){var o=this.editor.container;if(w.isIE&&this.state=="dragReady"){var s=c(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);s>3&&o.dragDrop()}if(this.state==="dragWait"){var s=c(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);s>0&&(o.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(h){if(this.$dragEnabled){this.mousedownEvent=h;var o=this.editor,s=h.inSelection(),p=h.getButton(),b=h.domEvent.detail||1;if(b===1&&p===0&&s){if(h.editor.inMultiSelectMode&&(h.getAccelKey()||h.getShiftKey()))return;this.mousedownEvent.time=Date.now();var x=h.domEvent.target||h.domEvent.srcElement;if("unselectable"in x&&(x.unselectable="on"),o.getDragDelay()){if(w.isWebKit){this.cancelDrag=!0;var M=o.container;M.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(h,this.onMouseDrag.bind(this)),h.defaultPrevented=!0}}}}).call(l.prototype);function c(h,o,s,p){return Math.sqrt(Math.pow(s-h,2)+Math.pow(p-o,2))}r.DragdropHandler=l}),ace.define("ace/mouse/touch_handler",["require","exports","module","ace/mouse/mouse_event","ace/lib/event","ace/lib/dom"],function(e,r,m){var f=e("./mouse_event").MouseEvent,g=e("../lib/event"),w=e("../lib/dom");r.addTouchListeners=function(u,d){var a="scroll",l,c,h,o,s,p,b=0,x,M=0,R=0,k=0,C,L;function D(){var S=window.navigator&&window.navigator.clipboard,A=!1,N=function(){var G=d.getCopyText(),J=d.session.getUndoManager().hasUndo();L.replaceChild(w.buildDom(A?["span",!G&&B("selectall")&&["span",{class:"ace_mobile-button",action:"selectall"},"Select All"],G&&B("copy")&&["span",{class:"ace_mobile-button",action:"copy"},"Copy"],G&&B("cut")&&["span",{class:"ace_mobile-button",action:"cut"},"Cut"],S&&B("paste")&&["span",{class:"ace_mobile-button",action:"paste"},"Paste"],J&&B("undo")&&["span",{class:"ace_mobile-button",action:"undo"},"Undo"],B("find")&&["span",{class:"ace_mobile-button",action:"find"},"Find"],B("openCommandPalette")&&["span",{class:"ace_mobile-button",action:"openCommandPalette"},"Palette"]]:["span"]),L.firstChild)},B=function(G){return d.commands.canExecute(G,d)},U=function(G){var J=G.target.getAttribute("action");if(J=="more"||!A)return A=!A,N();J=="paste"?S.readText().then(function(ne){d.execCommand(J,ne)}):J&&((J=="cut"||J=="copy")&&(S?S.writeText(d.getCopyText()):document.execCommand("copy")),d.execCommand(J)),L.firstChild.style.display="none",A=!1,J!="openCommandPalette"&&d.focus()};L=w.buildDom(["div",{class:"ace_mobile-menu",onclick:U},["span"],["span",{class:"ace_mobile-button",action:"more"},"..."]],d.container),L.addEventListener("touchstart",function(G){a="menu",G.stopPropagation(),G.preventDefault(),d.textInput.focus()}),L.addEventListener("touchend",function(G){G.stopPropagation(),G.preventDefault(),U(G)})}function I(){if(!d.getOption("enableMobileMenu")){L&&T();return}L||D();var S=d.selection.cursor,A=d.renderer.textToScreenCoordinates(S.row,S.column),N=d.renderer.textToScreenCoordinates(0,0).pageX,B=d.renderer.scrollLeft,U=d.container.getBoundingClientRect();L.style.top=A.pageY-U.top-3+"px",A.pageX-U.left<U.width-70?(L.style.left="",L.style.right="10px"):(L.style.right="",L.style.left=N+B-U.left+"px"),L.style.display="",L.firstChild.style.display="none",d.on("input",T)}function T(S){L&&(L.style.display="none"),d.off("input",T)}function W(){s=null,clearTimeout(s);var S=d.selection.getRange(),A=S.contains(x.row,x.column);(S.isEmpty()||!A)&&(d.selection.moveToPosition(x),d.selection.selectWord()),a="wait",I()}function F(){s=null,clearTimeout(s),d.selection.moveToPosition(x);var S=M>=2?d.selection.getLineRange(x.row):d.session.getBracketRange(x);S&&!S.isEmpty()?d.selection.setRange(S):d.selection.selectWord(),a="wait"}g.addListener(u,"contextmenu",function(S){if(C){var A=d.textInput.getElement();A.focus()}},d),g.addListener(u,"touchstart",function(S){var A=S.touches;if(s||A.length>1){clearTimeout(s),s=null,h=-1,a="zoom";return}C=d.$mouseHandler.isMousePressed=!0;var N=d.renderer.layerConfig.lineHeight,B=d.renderer.layerConfig.lineHeight,U=S.timeStamp;o=U;var G=A[0],J=G.clientX,ne=G.clientY;Math.abs(l-J)+Math.abs(c-ne)>N&&(h=-1),l=S.clientX=J,c=S.clientY=ne,R=k=0;var de=new f(S,d);if(x=de.getDocumentPosition(),U-h<500&&A.length==1&&!b)M++,S.preventDefault(),S.button=0,F();else{M=0;var ee=d.selection.cursor,se=d.selection.isEmpty()?ee:d.selection.anchor,ce=d.renderer.$cursorLayer.getPixelPosition(ee,!0),le=d.renderer.$cursorLayer.getPixelPosition(se,!0),pe=d.renderer.scroller.getBoundingClientRect(),me=d.renderer.layerConfig.offset,$e=d.renderer.scrollLeft,Ee=function(ot,Qe){return ot=ot/B,Qe=Qe/N-.75,ot*ot+Qe*Qe};if(S.clientX<pe.left){a="zoom";return}var He=Ee(S.clientX-pe.left-ce.left+$e,S.clientY-pe.top-ce.top+me),Ue=Ee(S.clientX-pe.left-le.left+$e,S.clientY-pe.top-le.top+me);He<3.5&&Ue<3.5&&(a=He>Ue?"cursor":"anchor"),Ue<3.5?a="anchor":He<3.5?a="cursor":a="scroll",s=setTimeout(W,450)}h=U},d),g.addListener(u,"touchend",function(S){C=d.$mouseHandler.isMousePressed=!1,p&&clearInterval(p),a=="zoom"?(a="",b=0):s?(d.selection.moveToPosition(x),b=0,I()):a=="scroll"?(O(),T()):I(),clearTimeout(s),s=null},d),g.addListener(u,"touchmove",function(S){s&&(clearTimeout(s),s=null);var A=S.touches;if(!(A.length>1||a=="zoom")){var N=A[0],B=l-N.clientX,U=c-N.clientY;if(a=="wait")if(B*B+U*U>4)a="cursor";else return S.preventDefault();l=N.clientX,c=N.clientY,S.clientX=N.clientX,S.clientY=N.clientY;var G=S.timeStamp,J=G-o;if(o=G,a=="scroll"){var ne=new f(S,d);ne.speed=1,ne.wheelX=B,ne.wheelY=U,10*Math.abs(B)<Math.abs(U)&&(B=0),10*Math.abs(U)<Math.abs(B)&&(U=0),J!=0&&(R=B/J,k=U/J),d._emit("mousewheel",ne),ne.propagationStopped||(R=k=0)}else{var de=new f(S,d),ee=de.getDocumentPosition();a=="cursor"?d.selection.moveCursorToPosition(ee):a=="anchor"&&d.selection.setSelectionAnchor(ee.row,ee.column),d.renderer.scrollCursorIntoView(ee),S.preventDefault()}}},d);function O(){b+=60,p=setInterval(function(){b--<=0&&(clearInterval(p),p=null),Math.abs(R)<.01&&(R=0),Math.abs(k)<.01&&(k=0),b<20&&(R=.9*R),b<20&&(k=.9*k);var S=d.session.getScrollTop();d.renderer.scrollBy(10*R,10*k),S==d.session.getScrollTop()&&(b=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(e,r,m){var f=e("../lib/event"),g=e("../lib/useragent"),w=e("./default_handlers").DefaultHandlers,u=e("./default_gutter_handler").GutterHandler,d=e("./mouse_event").MouseEvent,a=e("./dragdrop_handler").DragdropHandler,l=e("./touch_handler").addTouchListeners,c=e("../config"),h=(function(){function o(s){this.$dragDelay,this.$dragEnabled,this.$mouseMoved,this.mouseEvent,this.$focusTimeout;var p=this;this.editor=s,new w(this),new u(this),new a(this);var b=function(R){var k=!document.hasFocus||!document.hasFocus()||!s.isFocused()&&document.activeElement==(s.textInput&&s.textInput.getElement());k&&window.focus(),s.focus(),setTimeout(function(){s.isFocused()||s.focus()})},x=s.renderer.getMouseEventTarget();f.addListener(x,"click",this.onMouseEvent.bind(this,"click"),s),f.addListener(x,"mousemove",this.onMouseMove.bind(this,"mousemove"),s),f.addMultiMouseDownListener([x,s.renderer.scrollBarV&&s.renderer.scrollBarV.inner,s.renderer.scrollBarH&&s.renderer.scrollBarH.inner,s.textInput&&s.textInput.getElement()].filter(Boolean),[400,300,250],this,"onMouseEvent",s),f.addMouseWheelListener(s.container,this.onMouseWheel.bind(this,"mousewheel"),s),l(s.container,s);var M=s.renderer.$gutter;f.addListener(M,"mousedown",this.onMouseEvent.bind(this,"guttermousedown"),s),f.addListener(M,"click",this.onMouseEvent.bind(this,"gutterclick"),s),f.addListener(M,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick"),s),f.addListener(M,"mousemove",this.onMouseEvent.bind(this,"guttermousemove"),s),f.addListener(x,"mousedown",b,s),f.addListener(M,"mousedown",b,s),g.isIE&&s.renderer.scrollBarV&&(f.addListener(s.renderer.scrollBarV.element,"mousedown",b,s),f.addListener(s.renderer.scrollBarH.element,"mousedown",b,s)),s.on("mousemove",function(R){if(!(p.state||p.$dragDelay||!p.$dragEnabled)){var k=s.renderer.screenToTextCoordinates(R.x,R.y),C=s.session.selection.getRange(),L=s.renderer;!C.isEmpty()&&C.insideStart(k.row,k.column)?L.setCursorStyle("default"):L.setCursorStyle("")}},s)}return o.prototype.onMouseEvent=function(s,p){this.editor.session&&this.editor._emit(s,new d(p,this.editor))},o.prototype.onMouseMove=function(s,p){var b=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;!b||!b.length||this.editor._emit(s,new d(p,this.editor))},o.prototype.onMouseWheel=function(s,p){var b=new d(p,this.editor);b.speed=this.$scrollSpeed*2,b.wheelX=p.wheelX,b.wheelY=p.wheelY,this.editor._emit(s,b)},o.prototype.setState=function(s){this.state=s},o.prototype.captureMouse=function(s,p){this.x=s.x,this.y=s.y,this.isMousePressed=!0;var b=this.editor,x=this.editor.renderer;x.$isMousePressed=!0;var M=this,R=!0,k=function(T){if(T){if(g.isWebKit&&!T.which&&M.releaseMouse)return M.releaseMouse();M.x=T.clientX,M.y=T.clientY,p&&p(T),M.mouseEvent=new d(T,M.editor),M.$mouseMoved=!0}},C=function(T){b.off("beforeEndOperation",I),R=!1,b.session&&L(),M[M.state+"End"]&&M[M.state+"End"](T),M.state="",M.isMousePressed=x.$isMousePressed=!1,x.$keepTextAreaAtCursor&&x.$moveTextAreaToCursor(),M.$onCaptureMouseMove=M.releaseMouse=null,T&&M.onMouseEvent("mouseup",T),b.endOperation()},L=function(){M[M.state]&&M[M.state](),M.$mouseMoved=!1},D=function(){R&&(L(),f.nextFrame(D))};if(g.isOldIE&&s.domEvent.type=="dblclick")return setTimeout(function(){C(s)});var I=function(T){M.releaseMouse&&b.curOp.command.name&&b.curOp.selectionChanged&&(M[M.state+"End"]&&M[M.state+"End"](),M.state="",M.releaseMouse())};b.on("beforeEndOperation",I),b.startOperation({command:{name:"mouse"}}),M.$onCaptureMouseMove=k,M.releaseMouse=f.capture(this.editor.container,k,C),D()},o.prototype.cancelContextMenu=function(){var s=(function(p){p&&p.domEvent&&p.domEvent.type!="contextmenu"||(this.editor.off("nativecontextmenu",s),p&&p.domEvent&&f.stopEvent(p.domEvent))}).bind(this);setTimeout(s,10),this.editor.on("nativecontextmenu",s)},o.prototype.destroy=function(){this.releaseMouse&&this.releaseMouse(),this.$tooltip&&this.$tooltip.destroy()},o})();h.prototype.releaseMouse=null,c.defineOptions(h.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:g.isMac?150:0},dragEnabled:{initialValue:!0},focusTimeout:{initialValue:0}}),r.MouseHandler=h}),ace.define("ace/mouse/fold_handler",["require","exports","module","ace/lib/dom"],function(e,r,m){var f=e("../lib/dom"),g=(function(){function w(u){u.on("click",function(d){var a=d.getDocumentPosition(),l=u.session,c=l.getFoldAt(a.row,a.column,1);c&&(d.getAccelKey()?l.removeFold(c):l.expandFold(c),d.stop());var h=d.domEvent&&d.domEvent.target;h&&f.hasCssClass(h,"ace_inline_button")&&f.hasCssClass(h,"ace_toggle_wrap")&&(l.setOption("wrap",!l.getUseWrapMode()),u.renderer.scrollCursorIntoView())}),u.on("gutterclick",function(d){var a=u.renderer.$gutterLayer.getRegion(d);if(a=="foldWidgets"){var l=d.getDocumentPosition().row,c=u.session;c.foldWidgets&&c.foldWidgets[l]&&u.session.onFoldWidgetClick(l,d),u.isFocused()||u.focus(),d.stop()}}),u.on("gutterdblclick",function(d){var a=u.renderer.$gutterLayer.getRegion(d);if(a=="foldWidgets"){var l=d.getDocumentPosition().row,c=u.session,h=c.getParentFoldRangeData(l,!0),o=h.range||h.firstRange;if(o){l=o.start.row;var s=c.getFoldAt(l,c.getLine(l).length,1);s?c.removeFold(s):(c.addFold("...",o),u.renderer.scrollCursorIntoView({row:o.start.row,column:0}))}d.stop()}})}return w})();r.FoldHandler=g}),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],function(e,r,m){var f=e("../lib/keys"),g=e("../lib/event"),w=(function(){function u(d){this.$editor=d,this.$data={editor:d},this.$handlers=[],this.setDefaultHandler(d.commands)}return u.prototype.setDefaultHandler=function(d){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=d,this.addKeyboardHandler(d,0)},u.prototype.setKeyboardHandler=function(d){var a=this.$handlers;if(a[a.length-1]!=d){for(;a[a.length-1]&&a[a.length-1]!=this.$defaultHandler;)this.removeKeyboardHandler(a[a.length-1]);this.addKeyboardHandler(d,1)}},u.prototype.addKeyboardHandler=function(d,a){if(d){typeof d=="function"&&!d.handleKeyboard&&(d.handleKeyboard=d);var l=this.$handlers.indexOf(d);l!=-1&&this.$handlers.splice(l,1),a==null?this.$handlers.push(d):this.$handlers.splice(a,0,d),l==-1&&d.attach&&d.attach(this.$editor)}},u.prototype.removeKeyboardHandler=function(d){var a=this.$handlers.indexOf(d);return a==-1?!1:(this.$handlers.splice(a,1),d.detach&&d.detach(this.$editor),!0)},u.prototype.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},u.prototype.getStatusText=function(){var d=this.$data,a=d.editor;return this.$handlers.map(function(l){return l.getStatusText&&l.getStatusText(a,d)||""}).filter(Boolean).join(" ")},u.prototype.$callKeyboardHandlers=function(d,a,l,c){for(var h,o=!1,s=this.$editor.commands,p=this.$handlers.length;p--&&(h=this.$handlers[p].handleKeyboard(this.$data,d,a,l,c),!(!(!h||!h.command)&&(h.command=="null"?o=!0:o=s.exec(h.command,this.$editor,h.args,c),o&&c&&d!=-1&&h.passEvent!=!0&&h.command.passEvent!=!0&&g.stopEvent(c),o))););return!o&&d==-1&&(h={command:"insertstring"},o=s.exec("insertstring",this.$editor,a)),o&&this.$editor._signal&&this.$editor._signal("keyboardActivity",h),o},u.prototype.onCommandKey=function(d,a,l){var c=f.keyCodeToString(l);return this.$callKeyboardHandlers(a,c,l,d)},u.prototype.onTextInput=function(d){return this.$callKeyboardHandlers(-1,d)},u})();r.KeyBinding=w}),ace.define("ace/lib/bidiutil",["require","exports","module"],function(e,r,m){var f=0,g=0,w=!1,u=!1,d=!1,a=[[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]],l=[[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]],c=0,h=1,o=0,s=1,p=2,b=3,x=4,M=5,R=6,k=7,C=8,L=9,D=10,I=11,T=12,W=13,F=14,O=15,S=16,A=17,N=18,B=[N,N,N,N,N,N,N,N,N,R,M,R,C,M,N,N,N,N,N,N,N,N,N,N,N,N,N,N,M,M,M,R,C,x,x,I,I,I,x,x,x,x,x,D,L,D,L,L,p,p,p,p,p,p,p,p,p,p,L,x,x,x,x,x,x,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,x,x,x,x,x,x,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,x,x,x,x,N,N,N,N,N,N,M,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,L,x,I,I,I,I,x,x,x,x,o,x,x,N,x,x,I,I,p,p,x,o,x,x,x,p,o,x,x,x,x,x],U=[C,C,C,C,C,C,C,C,C,C,C,N,N,N,o,s,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,C,M,W,F,O,S,A,L,I,I,I,I,I,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,L,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,C];function G(ee,se,ce,le){var pe=f?l:a,me=null,$e=null,Ee=null,He=0,Ue=null,ot=null,Qe=-1,lt=null,Tt=null,ur=[];if(!le)for(lt=0,le=[];lt<ce;lt++)le[lt]=de(ee[lt]);for(g=f,w=!1,u=!1,d=!1,Tt=0;Tt<ce;Tt++){if(me=He,ur[Tt]=$e=ne(ee,le,ur,Tt),He=pe[me][$e],Ue=He&240,He&=15,se[Tt]=Ee=pe[He][5],Ue>0)if(Ue==16){for(lt=Qe;lt<Tt;lt++)se[lt]=1;Qe=-1}else Qe=-1;if(ot=pe[He][6],ot)Qe==-1&&(Qe=Tt);else if(Qe>-1){for(lt=Qe;lt<Tt;lt++)se[lt]=Ee;Qe=-1}le[Tt]==M&&(se[Tt]=0),g|=Ee}if(d){for(lt=0;lt<ce;lt++)if(le[lt]==R){se[lt]=f;for(var At=lt-1;At>=0&&le[At]==C;At--)se[At]=f}}}function J(ee,se,ce){if(!(g<ee)){if(ee==1&&f==h&&!u){ce.reverse();return}for(var le=ce.length,pe=0,me,$e,Ee,He;pe<le;){if(se[pe]>=ee){for(me=pe+1;me<le&&se[me]>=ee;)me++;for($e=pe,Ee=me-1;$e<Ee;$e++,Ee--)He=ce[$e],ce[$e]=ce[Ee],ce[Ee]=He;pe=me}pe++}}}function ne(ee,se,ce,le){var pe=se[le],me,$e,Ee,He;switch(pe){case o:case s:w=!1;case x:case b:return pe;case p:return w?b:p;case k:return w=!0,s;case C:return x;case L:return le<1||le+1>=se.length||(me=ce[le-1])!=p&&me!=b||($e=se[le+1])!=p&&$e!=b?x:(w&&($e=b),$e==me?$e:x);case D:return me=le>0?ce[le-1]:M,me==p&&le+1<se.length&&se[le+1]==p?p:x;case I:if(le>0&&ce[le-1]==p)return p;if(w)return x;for(He=le+1,Ee=se.length;He<Ee&&se[He]==I;)He++;return He<Ee&&se[He]==p?p:x;case T:for(Ee=se.length,He=le+1;He<Ee&&se[He]==T;)He++;if(He<Ee){var Ue=ee[le],ot=Ue>=1425&&Ue<=2303||Ue==64286;if(me=se[He],ot&&(me==s||me==k))return s}return le<1||(me=se[le-1])==M?x:ce[le-1];case M:return w=!1,u=!0,f;case R:return d=!0,x;case W:case F:case S:case A:case O:w=!1;case N:return x}}function de(ee){var se=ee.charCodeAt(0),ce=se>>8;return ce==0?se>191?o:B[se]:ce==5?/[\u0591-\u05f4]/.test(ee)?s:o:ce==6?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(ee)?T:/[\u0660-\u0669\u066b-\u066c]/.test(ee)?b:se==1642?I:/[\u06f0-\u06f9]/.test(ee)?p:k:ce==32&&se<=8287?U[se&255]:ce==254&&se>=65136?k:x}r.L=o,r.R=s,r.EN=p,r.ON_R=3,r.AN=4,r.R_H=5,r.B=6,r.RLE=7,r.DOT="·",r.doBidiReorder=function(ee,se,ce){if(ee.length<2)return{};var le=ee.split(""),pe=new Array(le.length),me=new Array(le.length),$e=[];f=ce?h:c,G(le,$e,le.length,se);for(var Ee=0;Ee<pe.length;pe[Ee]=Ee,Ee++);J(2,$e,pe),J(1,$e,pe);for(var Ee=0;Ee<pe.length-1;Ee++)se[Ee]===b?$e[Ee]=r.AN:$e[Ee]===s&&(se[Ee]>k&&se[Ee]<W||se[Ee]===x||se[Ee]===N)?$e[Ee]=r.ON_R:Ee>0&&le[Ee-1]==="ل"&&/\u0622|\u0623|\u0625|\u0627/.test(le[Ee])&&($e[Ee-1]=$e[Ee]=r.R_H,Ee++);le[le.length-1]===r.DOT&&($e[le.length-1]=r.B),le[0]==="‫"&&($e[0]=r.RLE);for(var Ee=0;Ee<pe.length;Ee++)me[Ee]=$e[pe[Ee]];return{logicalFromVisual:pe,bidiLevels:me}},r.hasBidiCharacters=function(ee,se){for(var ce=!1,le=0;le<ee.length;le++)se[le]=de(ee.charAt(le)),!ce&&(se[le]==s||se[le]==k||se[le]==b)&&(ce=!0);return ce},r.getVisualFromLogicalIdx=function(ee,se){for(var ce=0;ce<se.logicalFromVisual.length;ce++)if(se.logicalFromVisual[ce]==ee)return ce;return 0}}),ace.define("ace/bidihandler",["require","exports","module","ace/lib/bidiutil","ace/lib/lang"],function(e,r,m){var f=e("./lib/bidiutil"),g=e("./lib/lang"),w=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\u202B]/,u=(function(){function d(a){this.session=a,this.bidiMap={},this.currentRow=null,this.bidiUtil=f,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=w.test(a.getValue())}return d.prototype.isBidiRow=function(a,l,c){return this.seenBidi?(a!==this.currentRow&&(this.currentRow=a,this.updateRowLine(l,c),this.updateBidiMap()),this.bidiMap.bidiLevels):!1},d.prototype.onChange=function(a){this.seenBidi?this.currentRow=null:a.action=="insert"&&w.test(a.lines.join(`
182
+ `))&&(this.seenBidi=!0,this.currentRow=null)},d.prototype.getDocumentRow=function(){var a=0,l=this.session.$screenRowCache;if(l.length){var c=this.session.$getRowCacheIndex(l,this.currentRow);c>=0&&(a=this.session.$docRowCache[c])}return a},d.prototype.getSplitIndex=function(){var a=0,l=this.session.$screenRowCache;if(l.length)for(var c,h=this.session.$getRowCacheIndex(l,this.currentRow);this.currentRow-a>0&&(c=this.session.$getRowCacheIndex(l,this.currentRow-a-1),c===h);)h=c,a++;else a=this.currentRow;return a},d.prototype.updateRowLine=function(a,l){a===void 0&&(a=this.getDocumentRow());var c=a===this.session.getLength()-1,h=c?this.EOF:this.EOL;if(this.wrapIndent=0,this.line=this.session.getLine(a),this.isRtlDir=this.$isRtl||this.line.charAt(0)===this.RLE,this.session.$useWrapMode){var o=this.session.$wrapData[a];o&&(l===void 0&&(l=this.getSplitIndex()),l>0&&o.length?(this.wrapIndent=o.indent,this.wrapOffset=this.wrapIndent*this.charWidths[f.L],this.line=l<o.length?this.line.substring(o[l-1],o[l]):this.line.substring(o[o.length-1])):this.line=this.line.substring(0,o[l]),l==o.length&&(this.line+=this.showInvisibles?h:f.DOT))}else this.line+=this.showInvisibles?h:f.DOT;var s=this.session,p=0,b;this.line=this.line.replace(/\t|[\u1100-\u2029, \u202F-\uFFE6]/g,function(x,M){return x===" "||s.isFullWidth(x.charCodeAt(0))?(b=x===" "?s.getScreenTabSize(M+p):2,p+=b-1,g.stringRepeat(f.DOT,b)):x}),this.isRtlDir&&(this.fontMetrics.$main.textContent=this.line.charAt(this.line.length-1)==f.DOT?this.line.substr(0,this.line.length-1):this.line,this.rtlLineOffset=this.contentWidth-this.fontMetrics.$main.getBoundingClientRect().width)},d.prototype.updateBidiMap=function(){var a=[];f.hasBidiCharacters(this.line,a)||this.isRtlDir?this.bidiMap=f.doBidiReorder(this.line,a,this.isRtlDir):this.bidiMap={}},d.prototype.markAsDirty=function(){this.currentRow=null},d.prototype.updateCharacterWidths=function(a){if(this.characterWidth!==a.$characterSize.width){this.fontMetrics=a;var l=this.characterWidth=a.$characterSize.width,c=a.$measureCharWidth("ה");this.charWidths[f.L]=this.charWidths[f.EN]=this.charWidths[f.ON_R]=l,this.charWidths[f.R]=this.charWidths[f.AN]=c,this.charWidths[f.R_H]=c*.45,this.charWidths[f.B]=this.charWidths[f.RLE]=0,this.currentRow=null}},d.prototype.setShowInvisibles=function(a){this.showInvisibles=a,this.currentRow=null},d.prototype.setEolChar=function(a){this.EOL=a},d.prototype.setContentWidth=function(a){this.contentWidth=a},d.prototype.isRtlLine=function(a){return this.$isRtl?!0:a!=null?this.session.getLine(a).charAt(0)==this.RLE:this.isRtlDir},d.prototype.setRtlDirection=function(a,l){for(var c=a.getCursorPosition(),h=a.selection.getSelectionAnchor().row;h<=c.row;h++)!l&&a.session.getLine(h).charAt(0)===a.session.$bidiHandler.RLE?a.session.doc.removeInLine(h,0,1):l&&a.session.getLine(h).charAt(0)!==a.session.$bidiHandler.RLE&&a.session.doc.insert({column:0,row:h},a.session.$bidiHandler.RLE)},d.prototype.getPosLeft=function(a){a-=this.wrapIndent;var l=this.line.charAt(0)===this.RLE?1:0,c=a>l?this.session.getOverwrite()?a:a-1:l,h=f.getVisualFromLogicalIdx(c,this.bidiMap),o=this.bidiMap.bidiLevels,s=0;!this.session.getOverwrite()&&a<=l&&o[h]%2!==0&&h++;for(var p=0;p<h;p++)s+=this.charWidths[o[p]];return!this.session.getOverwrite()&&a>l&&o[h]%2===0&&(s+=this.charWidths[o[h]]),this.wrapIndent&&(s+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset),this.isRtlDir&&(s+=this.rtlLineOffset),s},d.prototype.getSelections=function(a,l){var c=this.bidiMap,h=c.bidiLevels,o,s=[],p=0,b=Math.min(a,l)-this.wrapIndent,x=Math.max(a,l)-this.wrapIndent,M=!1,R=!1,k=0;this.wrapIndent&&(p+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);for(var C,L=0;L<h.length;L++)C=c.logicalFromVisual[L],o=h[L],M=C>=b&&C<x,M&&!R?k=p:!M&&R&&s.push({left:k,width:p-k}),p+=this.charWidths[o],R=M;if(M&&L===h.length&&s.push({left:k,width:p-k}),this.isRtlDir)for(var D=0;D<s.length;D++)s[D].left+=this.rtlLineOffset;return s},d.prototype.offsetToCol=function(c){this.isRtlDir&&(c-=this.rtlLineOffset);var l=0,c=Math.max(c,0),h=0,o=0,s=this.bidiMap.bidiLevels,p=this.charWidths[s[o]];for(this.wrapIndent&&(c-=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);c>h+p/2;){if(h+=p,o===s.length-1){p=0;break}p=this.charWidths[s[++o]]}return o>0&&s[o-1]%2!==0&&s[o]%2===0?(c<h&&o--,l=this.bidiMap.logicalFromVisual[o]):o>0&&s[o-1]%2===0&&s[o]%2!==0?l=1+(c>h?this.bidiMap.logicalFromVisual[o]:this.bidiMap.logicalFromVisual[o-1]):this.isRtlDir&&o===s.length-1&&p===0&&s[o-1]%2===0||!this.isRtlDir&&o===0&&s[o]%2!==0?l=1+this.bidiMap.logicalFromVisual[o]:(o>0&&s[o-1]%2!==0&&p!==0&&o--,l=this.bidiMap.logicalFromVisual[o]),l===0&&this.isRtlDir&&l++,l+this.wrapIndent},d})();r.BidiHandler=u}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(e,r,m){var f=e("./lib/oop"),g=e("./lib/lang"),w=e("./lib/event_emitter").EventEmitter,u=e("./range").Range,d=(function(){function a(l){this.session=l,this.doc=l.getDocument(),this.clearSelection(),this.cursor=this.lead=this.doc.createAnchor(0,0),this.anchor=this.doc.createAnchor(0,0),this.$silent=!1;var c=this;this.cursor.on("change",function(h){c.$cursorChanged=!0,c.$silent||c._emit("changeCursor"),!c.$isEmpty&&!c.$silent&&c._emit("changeSelection"),!c.$keepDesiredColumnOnChange&&h.old.column!=h.value.column&&(c.$desiredColumn=null)}),this.anchor.on("change",function(){c.$anchorChanged=!0,!c.$isEmpty&&!c.$silent&&c._emit("changeSelection")})}return a.prototype.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},a.prototype.isMultiLine=function(){return!this.$isEmpty&&this.anchor.row!=this.cursor.row},a.prototype.getCursor=function(){return this.lead.getPosition()},a.prototype.setAnchor=function(l,c){this.$isEmpty=!1,this.anchor.setPosition(l,c)},a.prototype.getAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},a.prototype.getSelectionLead=function(){return this.lead.getPosition()},a.prototype.isBackwards=function(){var l=this.anchor,c=this.lead;return l.row>c.row||l.row==c.row&&l.column>c.column},a.prototype.getRange=function(){var l=this.anchor,c=this.lead;return this.$isEmpty?u.fromPoints(c,c):this.isBackwards()?u.fromPoints(c,l):u.fromPoints(l,c)},a.prototype.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},a.prototype.selectAll=function(){this.$setSelection(0,0,Number.MAX_VALUE,Number.MAX_VALUE)},a.prototype.setRange=function(l,c){var h=c?l.end:l.start,o=c?l.start:l.end;this.$setSelection(h.row,h.column,o.row,o.column)},a.prototype.$setSelection=function(l,c,h,o){if(!this.$silent){var s=this.$isEmpty,p=this.inMultiSelectMode;this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(l,c),this.cursor.setPosition(h,o),this.$isEmpty=!u.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||s!=this.$isEmpty||p)&&this._emit("changeSelection")}},a.prototype.$moveSelection=function(l){var c=this.lead;this.$isEmpty&&this.setSelectionAnchor(c.row,c.column),l.call(this)},a.prototype.selectTo=function(l,c){this.$moveSelection(function(){this.moveCursorTo(l,c)})},a.prototype.selectToPosition=function(l){this.$moveSelection(function(){this.moveCursorToPosition(l)})},a.prototype.moveTo=function(l,c){this.clearSelection(),this.moveCursorTo(l,c)},a.prototype.moveToPosition=function(l){this.clearSelection(),this.moveCursorToPosition(l)},a.prototype.selectUp=function(){this.$moveSelection(this.moveCursorUp)},a.prototype.selectDown=function(){this.$moveSelection(this.moveCursorDown)},a.prototype.selectRight=function(){this.$moveSelection(this.moveCursorRight)},a.prototype.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},a.prototype.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},a.prototype.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},a.prototype.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},a.prototype.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},a.prototype.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},a.prototype.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},a.prototype.getWordRange=function(l,c){if(typeof c>"u"){var h=l||this.lead;l=h.row,c=h.column}return this.session.getWordRange(l,c)},a.prototype.selectWord=function(){this.setSelectionRange(this.getWordRange())},a.prototype.selectAWord=function(){var l=this.getCursor(),c=this.session.getAWordRange(l.row,l.column);this.setSelectionRange(c)},a.prototype.getLineRange=function(l,c){var h=typeof l=="number"?l:this.lead.row,o,s=this.session.getFoldLine(h);return s?(h=s.start.row,o=s.end.row):o=h,c===!0?new u(h,0,o,this.session.getLine(o).length):new u(h,0,o+1,0)},a.prototype.selectLine=function(){this.setSelectionRange(this.getLineRange())},a.prototype.moveCursorUp=function(){this.moveCursorBy(-1,0)},a.prototype.moveCursorDown=function(){this.moveCursorBy(1,0)},a.prototype.wouldMoveIntoSoftTab=function(l,c,h){var o=l.column,s=l.column+c;return h<0&&(o=l.column-c,s=l.column),this.session.isTabStop(l)&&this.doc.getLine(l.row).slice(o,s).split(" ").length-1==c},a.prototype.moveCursorLeft=function(){var l=this.lead.getPosition(),c;if(c=this.session.getFoldAt(l.row,l.column,-1))this.moveCursorTo(c.start.row,c.start.column);else if(l.column===0)l.row>0&&this.moveCursorTo(l.row-1,this.doc.getLine(l.row-1).length);else{var h=this.session.getTabSize();this.wouldMoveIntoSoftTab(l,h,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-h):this.moveCursorBy(0,-1)}},a.prototype.moveCursorRight=function(){var l=this.lead.getPosition(),c;if(c=this.session.getFoldAt(l.row,l.column,1))this.moveCursorTo(c.end.row,c.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 h=this.session.getTabSize(),l=this.lead;this.wouldMoveIntoSoftTab(l,h,1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,h):this.moveCursorBy(0,1)}},a.prototype.moveCursorLineStart=function(){var l=this.lead.row,c=this.lead.column,h=this.session.documentToScreenRow(l,c),o=this.session.screenToDocumentPosition(h,0),s=this.session.getDisplayLine(l,null,o.row,o.column),p=s.match(/^\s*/);p[0].length!=c&&!this.session.$useEmacsStyleLineStart&&(o.column+=p[0].length),this.moveCursorToPosition(o)},a.prototype.moveCursorLineEnd=function(){var l=this.lead,c=this.session.getDocumentLastRowColumnPosition(l.row,l.column);if(this.lead.column==c.column){var h=this.session.getLine(c.row);if(c.column==h.length){var o=h.search(/\s+$/);o>0&&(c.column=o)}}this.moveCursorTo(c.row,c.column)},a.prototype.moveCursorFileEnd=function(){var l=this.doc.getLength()-1,c=this.doc.getLine(l).length;this.moveCursorTo(l,c)},a.prototype.moveCursorFileStart=function(){this.moveCursorTo(0,0)},a.prototype.moveCursorLongWordRight=function(){var l=this.lead.row,c=this.lead.column,h=this.doc.getLine(l),o=h.substring(c);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var s=this.session.getFoldAt(l,c,1);if(s){this.moveCursorTo(s.end.row,s.end.column);return}if(this.session.nonTokenRe.exec(o)&&(c+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,o=h.substring(c)),c>=h.length){this.moveCursorTo(l,h.length),this.moveCursorRight(),l<this.doc.getLength()-1&&this.moveCursorWordRight();return}this.session.tokenRe.exec(o)&&(c+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(l,c)},a.prototype.moveCursorLongWordLeft=function(){var l=this.lead.row,c=this.lead.column,h;if(h=this.session.getFoldAt(l,c,-1)){this.moveCursorTo(h.start.row,h.start.column);return}var o=this.session.getFoldStringAt(l,c,-1);o==null&&(o=this.doc.getLine(l).substring(0,c));var s=g.stringReverse(o);if(this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.nonTokenRe.exec(s)&&(c-=this.session.nonTokenRe.lastIndex,s=s.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0),c<=0){this.moveCursorTo(l,0),this.moveCursorLeft(),l>0&&this.moveCursorWordLeft();return}this.session.tokenRe.exec(s)&&(c-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(l,c)},a.prototype.$shortWordEndIndex=function(l){var c=0,h,o=/\s/,s=this.session.tokenRe;if(s.lastIndex=0,this.session.tokenRe.exec(l))c=this.session.tokenRe.lastIndex;else{for(;(h=l[c])&&o.test(h);)c++;if(c<1){for(s.lastIndex=0;(h=l[c])&&!s.test(h);)if(s.lastIndex=0,c++,o.test(h))if(c>2){c--;break}else{for(;(h=l[c])&&o.test(h);)c++;if(c>2)break}}}return s.lastIndex=0,c},a.prototype.moveCursorShortWordRight=function(){var l=this.lead.row,c=this.lead.column,h=this.doc.getLine(l),o=h.substring(c),s=this.session.getFoldAt(l,c,1);if(s)return this.moveCursorTo(s.end.row,s.end.column);if(c==h.length){var p=this.doc.getLength();do l++,o=this.doc.getLine(l);while(l<p&&/^\s*$/.test(o));/^\s+/.test(o)||(o=""),c=0}var b=this.$shortWordEndIndex(o);this.moveCursorTo(l,c+b)},a.prototype.moveCursorShortWordLeft=function(){var l=this.lead.row,c=this.lead.column,h;if(h=this.session.getFoldAt(l,c,-1))return this.moveCursorTo(h.start.row,h.start.column);var o=this.session.getLine(l).substring(0,c);if(c===0){do l--,o=this.doc.getLine(l);while(l>0&&/^\s*$/.test(o));c=o.length,/\s+$/.test(o)||(o="")}var s=g.stringReverse(o),p=this.$shortWordEndIndex(s);return this.moveCursorTo(l,c-p)},a.prototype.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},a.prototype.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},a.prototype.moveCursorBy=function(l,c){var h=this.session.documentToScreenPosition(this.lead.row,this.lead.column),o;if(c===0&&(l!==0&&(this.session.$bidiHandler.isBidiRow(h.row,this.lead.row)?(o=this.session.$bidiHandler.getPosLeft(h.column),h.column=Math.round(o/this.session.$bidiHandler.charWidths[0])):o=h.column*this.session.$bidiHandler.charWidths[0]),this.$desiredColumn?h.column=this.$desiredColumn:this.$desiredColumn=h.column),l!=0&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]){var s=this.session.lineWidgets[this.lead.row];l<0?l-=s.rowsAbove||0:l>0&&(l+=s.rowCount-(s.rowsAbove||0))}var p=this.session.screenToDocumentPosition(h.row+l,h.column,o);l!==0&&c===0&&p.row===this.lead.row&&(p.column,this.lead.column),this.moveCursorTo(p.row,p.column+c,c===0)},a.prototype.moveCursorToPosition=function(l){this.moveCursorTo(l.row,l.column)},a.prototype.moveCursorTo=function(l,c,h){var o=this.session.getFoldAt(l,c,1);o&&(l=o.start.row,c=o.start.column),this.$keepDesiredColumnOnChange=!0;var s=this.session.getLine(l);/[\uDC00-\uDFFF]/.test(s.charAt(c))&&s.charAt(c-1)&&(this.lead.row==l&&this.lead.column==c+1?c=c-1:c=c+1),this.lead.setPosition(l,c),this.$keepDesiredColumnOnChange=!1,h||(this.$desiredColumn=null)},a.prototype.moveCursorToScreen=function(l,c,h){var o=this.session.screenToDocumentPosition(l,c);this.moveCursorTo(o.row,o.column,h)},a.prototype.detach=function(){this.lead.detach(),this.anchor.detach()},a.prototype.fromOrientedRange=function(l){this.setSelectionRange(l,l.cursor==l.start),this.$desiredColumn=l.desiredColumn||this.$desiredColumn},a.prototype.toOrientedRange=function(l){var c=this.getRange();return l?(l.start.column=c.start.column,l.start.row=c.start.row,l.end.column=c.end.column,l.end.row=c.end.row):l=c,l.cursor=this.isBackwards()?l.start:l.end,l.desiredColumn=this.$desiredColumn,l},a.prototype.getRangeOfMovements=function(l){var c=this.getCursor();try{l(this);var h=this.getCursor();return u.fromPoints(c,h)}catch{return u.fromPoints(c,c)}finally{this.moveCursorToPosition(c)}},a.prototype.toJSON=function(){if(this.rangeCount)var l=this.ranges.map(function(c){var h=c.clone();return h.isBackwards=c.cursor==c.start,h});else{var l=this.getRange();l.isBackwards=this.isBackwards()}return l},a.prototype.fromJSON=function(l){if(l.start==null)if(this.rangeList&&l.length>1){this.toSingleRange(l[0]);for(var c=l.length;c--;){var h=u.fromPoints(l[c].start,l[c].end);l[c].isBackwards&&(h.cursor=h.start),this.addRange(h,!0)}return}else l=l[0];this.rangeList&&this.toSingleRange(l),this.setSelectionRange(l,l.isBackwards)},a.prototype.isEqual=function(l){if((l.length||this.rangeCount)&&l.length!=this.rangeCount)return!1;if(!l.length||!this.ranges)return this.getRange().isEqual(l);for(var c=this.ranges.length;c--;)if(!this.ranges[c].isEqual(l[c]))return!1;return!0},a})();d.prototype.setSelectionAnchor=d.prototype.setAnchor,d.prototype.getSelectionAnchor=d.prototype.getAnchor,d.prototype.setSelectionRange=d.prototype.setRange,f.implement(d.prototype,w),r.Selection=d}),ace.define("ace/tokenizer",["require","exports","module","ace/lib/report_error"],function(e,r,m){var f=e("./lib/report_error").reportError,g=2e3,w=(function(){function u(d){this.splitRegex,this.states=d,this.regExps={},this.matchMappings={};for(var a in this.states){for(var l=this.states[a],c=[],h=0,o=this.matchMappings[a]={defaultToken:"text"},s="g",p=[],b=0;b<l.length;b++){var x=l[b];if(x.defaultToken&&(o.defaultToken=x.defaultToken),x.caseInsensitive&&s.indexOf("i")===-1&&(s+="i"),x.unicode&&s.indexOf("u")===-1&&(s+="u"),x.regex!=null){x.regex instanceof RegExp&&(x.regex=x.regex.toString().slice(1,-1));var M=x.regex,R=new RegExp("(?:("+M+")|(.))").exec("a").length-2;Array.isArray(x.token)?x.token.length==1||R==1?x.token=x.token[0]:R-1!=x.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:x,groupCount:R-1}),x.token=x.token[0]):(x.tokenArray=x.token,x.token=null,x.onMatch=this.$arrayTokens):typeof x.token=="function"&&!x.onMatch&&(R>1?x.onMatch=this.$applyToken:x.onMatch=x.token),R>1&&(/\\\d/.test(x.regex)?M=x.regex.replace(/\\([0-9]+)/g,function(k,C){return"\\"+(parseInt(C,10)+h+1)}):(R=1,M=this.removeCapturingGroups(x.regex)),!x.splitRegex&&typeof x.token!="string"&&p.push(x)),o[h]=b,h+=R,c.push(M),x.onMatch||(x.onMatch=null)}}c.length||(o[0]=0,c.push("$")),p.forEach(function(k){k.splitRegex=this.createSplitterRegexp(k.regex,s)},this),this.regExps[a]=new RegExp("("+c.join(")|(")+")|($)",s)}}return u.prototype.$setMaxTokenCount=function(d){g=d|0},u.prototype.$applyToken=function(d){var a=this.splitRegex.exec(d).slice(1),l=this.token.apply(this,a);if(typeof l=="string")return[{type:l,value:d}];for(var c=[],h=0,o=l.length;h<o;h++)a[h]&&(c[c.length]={type:l[h],value:a[h]});return c},u.prototype.$arrayTokens=function(d){if(!d)return[];var a=this.splitRegex.exec(d);if(!a)return"text";for(var l=[],c=this.tokenArray,h=0,o=c.length;h<o;h++)a[h+1]&&(l[l.length]={type:c[h],value:a[h+1]});return l},u.prototype.removeCapturingGroups=function(d){var a=d.replace(/\\.|\[(?:\\.|[^\\\]])*|\(\?[:=!<]|(\()/g,function(l,c){return c?"(?:":l});return a},u.prototype.createSplitterRegexp=function(d,a){if(d.indexOf("(?=")!=-1){var l=0,c=!1,h={};d.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,function(o,s,p,b,x,M){return c?c=x!="]":x?c=!0:b?(l==h.stack&&(h.end=M+1,h.stack=-1),l--):p&&(l++,p.length!=1&&(h.stack=l,h.start=M)),o}),h.end!=null&&/^\)*$/.test(d.substr(h.end))&&(d=d.substring(0,h.start)+d.substr(h.end))}return d.charAt(0)!="^"&&(d="^"+d),d.charAt(d.length-1)!="$"&&(d+="$"),new RegExp(d,(a||"").replace("g",""))},u.prototype.getLineTokens=function(d,a){if(a&&typeof a!="string"){var l=a.slice(0);a=l[0],a==="#tmp"&&(l.shift(),a=l.shift())}else var l=[];var c=a||"start",h=this.states[c];h||(c="start",h=this.states[c]);var o=this.matchMappings[c],s=this.regExps[c];s.lastIndex=0;for(var p,b=[],x=0,M=0,R={type:null,value:""};p=s.exec(d);){var k=o.defaultToken,C=null,L=p[0],D=s.lastIndex;if(D-L.length>x){var I=d.substring(x,D-L.length);R.type==k?R.value+=I:(R.type&&b.push(R),R={type:k,value:I})}for(var T=0;T<p.length-2;T++)if(p[T+1]!==void 0){C=h[o[T]],C.onMatch?k=C.onMatch(L,c,l,d):k=C.token,C.next&&(typeof C.next=="string"?c=C.next:c=C.next(c,l),h=this.states[c],h||(this.reportError("state doesn't exist",c),c="start",h=this.states[c]),o=this.matchMappings[c],x=D,s=this.regExps[c],s.lastIndex=D),C.consumeLineEnd&&(x=D);break}if(L){if(typeof k=="string")(!C||C.merge!==!1)&&R.type===k?R.value+=L:(R.type&&b.push(R),R={type:k,value:L});else if(k){R.type&&b.push(R),R={type:null,value:""};for(var T=0;T<k.length;T++)b.push(k[T])}}if(x==d.length)break;if(x=D,M++>g){for(M>2*d.length&&this.reportError("infinite loop with in ace tokenizer",{startState:a,line:d});x<d.length;)R.type&&b.push(R),R={value:d.substring(x,x+=500),type:"overflow"};c="start",l=[];break}}return R.type&&b.push(R),l.length>1&&l[0]!==c&&l.unshift("#tmp",c),{tokens:b,state:l.length?l:c}},u})();w.prototype.reportError=f,r.Tokenizer=w}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/deep_copy"],function(e,r,m){var f=e("../lib/deep_copy").deepCopy,g;g=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}},(function(){this.addRules=function(d,a){if(!a){for(var l in d)this.$rules[l]=d[l];return}for(var l in d){for(var c=d[l],h=0;h<c.length;h++){var o=c[h];(o.next||o.onMatch)&&(typeof o.next=="string"&&o.next.indexOf(a)!==0&&(o.next=a+o.next),o.nextState&&o.nextState.indexOf(a)!==0&&(o.nextState=a+o.nextState))}this.$rules[a+l]=c}},this.getRules=function(){return this.$rules},this.embedRules=function(d,a,l,c,h){var o=typeof d=="function"?new d().getRules():d;if(c)for(var s=0;s<c.length;s++)c[s]=a+c[s];else{c=[];for(var p in o)c.push(a+p)}if(this.addRules(o,a),l)for(var b=Array.prototype[h?"push":"unshift"],s=0;s<c.length;s++)b.apply(this.$rules[c[s]],f(l));this.$embeds||(this.$embeds=[]),this.$embeds.push(a)},this.getEmbeds=function(){return this.$embeds};var w=function(d,a){return(d!="start"||a.length)&&a.unshift(this.nextState,d),this.nextState},u=function(d,a){return a.shift(),a.shift()||"start"};this.normalizeRules=function(){var d=0,a=this.$rules;function l(c){var h=a[c];h.processed=!0;for(var o=0;o<h.length;o++){var s=h[o],p=null;Array.isArray(s)&&(p=s,s={}),!s.regex&&s.start&&(s.regex=s.start,s.next||(s.next=[]),s.next.push({defaultToken:s.token},{token:s.token+".end",regex:s.end||s.start,next:"pop"}),s.token=s.token+".start",s.push=!0);var b=s.next||s.push;if(b&&Array.isArray(b)){var x=s.stateName;x||(x=s.token,typeof x!="string"&&(x=x[0]||""),a[x]&&(x+=d++)),a[x]=b,s.next=x,l(x)}else b=="pop"&&(s.next=u);if(s.push&&(s.nextState=s.next||s.push,s.next=w,delete s.push),s.rules)for(var M in s.rules)a[M]?a[M].push&&a[M].push.apply(a[M],s.rules[M]):a[M]=s.rules[M];var R=typeof s=="string"?s:s.include;if(R&&(R==="$self"&&(R="start"),Array.isArray(R)?p=R.map(function(C){return a[C]}):p=a[R]),p){var k=[o,1].concat(p);s.noEscape&&(k=k.filter(function(C){return!C.next})),h.splice.apply(h,k),o--}s.keywordMap&&(s.token=this.createKeywordMapper(s.keywordMap,s.defaultToken||"text",s.caseInsensitive),delete s.defaultToken)}}Object.keys(a).forEach(l,this)},this.createKeywordMapper=function(d,a,l,c){var h=Object.create(null);return this.$keywordList=[],Object.keys(d).forEach(function(o){for(var s=d[o],p=s.split(c||"|"),b=p.length;b--;){var x=p[b];this.$keywordList.push(x),l&&(x=x.toLowerCase()),h[x]=o}},this),d=null,l?function(o){return h[o.toLowerCase()]||a}:function(o){return h[o]||a}},this.getKeywords=function(){return this.$keywords}}).call(g.prototype),r.TextHighlightRules=g}),ace.define("ace/mode/behaviour",["require","exports","module"],function(e,r,m){var f;f=function(){this.$behaviours={}},(function(){this.add=function(g,w,u){switch(void 0){case this.$behaviours:this.$behaviours={};case this.$behaviours[g]:this.$behaviours[g]={}}this.$behaviours[g][w]=u},this.addBehaviours=function(g){for(var w in g)for(var u in g[w])this.add(w,u,g[w][u])},this.remove=function(g){this.$behaviours&&this.$behaviours[g]&&delete this.$behaviours[g]},this.inherit=function(g,w){if(typeof g=="function")var u=new g().getBehaviours(w);else var u=g.getBehaviours(w);this.addBehaviours(u)},this.getBehaviours=function(g){if(g){for(var w={},u=0;u<g.length;u++)this.$behaviours[g[u]]&&(w[g[u]]=this.$behaviours[g[u]]);return w}else return this.$behaviours}}).call(f.prototype),r.Behaviour=f}),ace.define("ace/token_iterator",["require","exports","module","ace/range"],function(e,r,m){var f=e("./range").Range,g=(function(){function w(u,d,a){this.$session=u,this.$row=d,this.$rowTokens=u.getTokens(d);var l=u.getTokenAt(d,a);this.$tokenIndex=l?l.index:-1}return w.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]},w.prototype.stepForward=function(){this.$tokenIndex+=1;for(var u;this.$tokenIndex>=this.$rowTokens.length;){if(this.$row+=1,u||(u=this.$session.getLength()),this.$row>=u)return this.$row=u-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},w.prototype.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},w.prototype.getCurrentTokenRow=function(){return this.$row},w.prototype.getCurrentTokenColumn=function(){var u=this.$rowTokens,d=this.$tokenIndex,a=u[d].start;if(a!==void 0)return a;for(a=0;d>0;)d-=1,a+=u[d].value.length;return a},w.prototype.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},w.prototype.getCurrentTokenRange=function(){var u=this.$rowTokens[this.$tokenIndex],d=this.getCurrentTokenColumn();return new f(this.$row,d,this.$row,d+u.value.length)},w})();r.TokenIterator=g}),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],function(e,r,m){var f=e("../../lib/oop"),g=e("../behaviour").Behaviour,w=e("../../token_iterator").TokenIterator,u=e("../../lib/lang"),d=["text","paren.rparen","rparen","paren","punctuation.operator"],a=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],l,c={},h={'"':'"',"'":"'"},o=function(b){var x=-1;if(b.multiSelect&&(x=b.selection.index,c.rangeCount!=b.multiSelect.rangeCount&&(c={rangeCount:b.multiSelect.rangeCount})),c[x])return l=c[x];l=c[x]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},s=function(b,x,M,R){var k=b.end.row-b.start.row;return{text:M+x+R,selection:[0,b.start.column+1,k,b.end.column+(k?0:1)]}},p;p=function(b){b=b||{},this.add("braces","insertion",function(x,M,R,k,C){var L=R.getCursorPosition(),D=k.doc.getLine(L.row);if(C=="{"){o(R);var I=R.getSelectionRange(),T=k.doc.getTextRange(I),W=k.getTokenAt(L.row,L.column);if(T!==""&&T!=="{"&&R.getWrapBehavioursEnabled())return s(I,T,"{","}");if(W&&/(?:string)\.quasi|\.xml/.test(W.type)){var F=[/tag\-(?:open|name)/,/attribute\-name/];return F.some(function(G){return G.test(W.type)})||/(string)\.quasi/.test(W.type)&&W.value[L.column-W.start-1]!=="$"?void 0:(p.recordAutoInsert(R,k,"}"),{text:"{}",selection:[1,1]})}else if(p.isSaneInsertion(R,k))return/[\]\}\)]/.test(D[L.column])||R.inMultiSelectMode||b.braces?(p.recordAutoInsert(R,k,"}"),{text:"{}",selection:[1,1]}):(p.recordMaybeInsert(R,k,"{"),{text:"{",selection:[1,1]})}else if(C=="}"){o(R);var O=D.substring(L.column,L.column+1);if(O=="}"){var S=k.$findOpeningBracket("}",{column:L.column+1,row:L.row});if(S!==null&&p.isAutoInsertedClosing(L,D,C))return p.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}else if(C==`
183
+ `||C==`\r
184
+ `){o(R);var A="";p.isMaybeInsertedClosing(L,D)&&(A=u.stringRepeat("}",l.maybeInsertedBrackets),p.clearMaybeInsertedClosing());var O=D.substring(L.column,L.column+1);if(O==="}"){var N=k.findMatchingBracket({row:L.row,column:L.column+1},"}");if(!N)return null;var B=this.$getIndent(k.getLine(N.row))}else if(A)var B=this.$getIndent(D);else{p.clearMaybeInsertedClosing();return}var U=B+k.getTabString();return{text:`
185
+ `+U+`
186
+ `+B+A,selection:[1,U.length,1,U.length]}}else p.clearMaybeInsertedClosing()}),this.add("braces","deletion",function(x,M,R,k,C){var L=k.doc.getTextRange(C);if(!C.isMultiLine()&&L=="{"){o(R);var D=k.doc.getLine(C.start.row),I=D.substring(C.end.column,C.end.column+1);if(I=="}")return C.end.column++,C;l.maybeInsertedBrackets--}}),this.add("parens","insertion",function(x,M,R,k,C){if(C=="("){o(R);var L=R.getSelectionRange(),D=k.doc.getTextRange(L);if(D!==""&&R.getWrapBehavioursEnabled())return s(L,D,"(",")");if(p.isSaneInsertion(R,k))return p.recordAutoInsert(R,k,")"),{text:"()",selection:[1,1]}}else if(C==")"){o(R);var I=R.getCursorPosition(),T=k.doc.getLine(I.row),W=T.substring(I.column,I.column+1);if(W==")"){var F=k.$findOpeningBracket(")",{column:I.column+1,row:I.row});if(F!==null&&p.isAutoInsertedClosing(I,T,C))return p.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("parens","deletion",function(x,M,R,k,C){var L=k.doc.getTextRange(C);if(!C.isMultiLine()&&L=="("){o(R);var D=k.doc.getLine(C.start.row),I=D.substring(C.start.column+1,C.start.column+2);if(I==")")return C.end.column++,C}}),this.add("brackets","insertion",function(x,M,R,k,C){if(C=="["){o(R);var L=R.getSelectionRange(),D=k.doc.getTextRange(L);if(D!==""&&R.getWrapBehavioursEnabled())return s(L,D,"[","]");if(p.isSaneInsertion(R,k))return p.recordAutoInsert(R,k,"]"),{text:"[]",selection:[1,1]}}else if(C=="]"){o(R);var I=R.getCursorPosition(),T=k.doc.getLine(I.row),W=T.substring(I.column,I.column+1);if(W=="]"){var F=k.$findOpeningBracket("]",{column:I.column+1,row:I.row});if(F!==null&&p.isAutoInsertedClosing(I,T,C))return p.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("brackets","deletion",function(x,M,R,k,C){var L=k.doc.getTextRange(C);if(!C.isMultiLine()&&L=="["){o(R);var D=k.doc.getLine(C.start.row),I=D.substring(C.start.column+1,C.start.column+2);if(I=="]")return C.end.column++,C}}),this.add("string_dquotes","insertion",function(x,M,R,k,C){var L=k.$mode.$quotes||h;if(C.length==1&&L[C]){if(this.lineCommentStart&&this.lineCommentStart.indexOf(C)!=-1)return;o(R);var D=C,I=R.getSelectionRange(),T=k.doc.getTextRange(I);if(T!==""&&(T.length!=1||!L[T])&&R.getWrapBehavioursEnabled())return s(I,T,D,D);if(!T){var W=R.getCursorPosition(),F=k.doc.getLine(W.row),O=F.substring(W.column-1,W.column),S=F.substring(W.column,W.column+1),A=k.getTokenAt(W.row,W.column),N=k.getTokenAt(W.row,W.column+1);if(O=="\\"&&A&&/escape/.test(A.type))return null;var B=A&&/string|escape/.test(A.type),U=!N||/string|escape/.test(N.type),G;if(S==D)G=B!==U,G&&/string\.end/.test(N.type)&&(G=!1);else{if(B&&!U||B&&U)return null;var J=k.$mode.tokenRe;J.lastIndex=0;var ne=J.test(O);J.lastIndex=0;var de=J.test(S),ee=k.$mode.$pairQuotesAfter,se=ee&&ee[D]&&ee[D].test(O);if(!se&&ne||de||S&&!/[\s;,.})\]\\]/.test(S))return null;var ce=F[W.column-2];if(O==D&&(ce==D||J.test(ce)))return null;G=!0}return{text:G?D+D:"",selection:[1,1]}}}}),this.add("string_dquotes","deletion",function(x,M,R,k,C){var L=k.$mode.$quotes||h,D=k.doc.getTextRange(C);if(!C.isMultiLine()&&L.hasOwnProperty(D)){o(R);var I=k.doc.getLine(C.start.row),T=I.substring(C.start.column+1,C.start.column+2);if(T==D)return C.end.column++,C}}),b.closeDocComment!==!1&&this.add("doc comment end","insertion",function(x,M,R,k,C){if(x==="doc-start"&&(C===`
187
+ `||C===`\r
188
+ `)&&R.selection.isEmpty()){var L=R.getCursorPosition();if(L.column===0)return;for(var D=k.doc.getLine(L.row),I=k.doc.getLine(L.row+1),T=k.getTokens(L.row),W=0,F=0;F<T.length;F++){W+=T[F].value.length;var O=T[F];if(W>=L.column){if(W===L.column){if(!/\.doc/.test(O.type))return;if(/\*\//.test(O.value)){var S=T[F+1];if(!S||!/\.doc/.test(S.type))return}}var A=L.column-(W-O.value.length),N=O.value.indexOf("*/"),B=O.value.indexOf("/**",N>-1?N+2:0);if(B!==-1&&A>B&&A<B+3||N!==-1&&B!==-1&&A>=N&&A<=B||!/\.doc/.test(O.type))return;break}}var U=this.$getIndent(D);if(/\s*\*/.test(I))return/^\s*\*/.test(D)?{text:C+U+"* ",selection:[1,2+U.length,1,2+U.length]}:{text:C+U+" * ",selection:[1,3+U.length,1,3+U.length]};if(/\/\*\*/.test(D.substring(0,L.column)))return{text:C+U+" * "+C+" "+U+"*/",selection:[1,4+U.length,1,4+U.length]}}})},p.isSaneInsertion=function(b,x){var M=b.getCursorPosition(),R=new w(x,M.row,M.column);if(!this.$matchTokenType(R.getCurrentToken()||"text",d)){if(/[)}\]]/.test(b.session.getLine(M.row)[M.column]))return!0;var k=new w(x,M.row,M.column+1);if(!this.$matchTokenType(k.getCurrentToken()||"text",d))return!1}return R.stepForward(),R.getCurrentTokenRow()!==M.row||this.$matchTokenType(R.getCurrentToken()||"text",a)},p.$matchTokenType=function(b,x){return x.indexOf(b.type||b)>-1},p.recordAutoInsert=function(b,x,M){var R=b.getCursorPosition(),k=x.doc.getLine(R.row);this.isAutoInsertedClosing(R,k,l.autoInsertedLineEnd[0])||(l.autoInsertedBrackets=0),l.autoInsertedRow=R.row,l.autoInsertedLineEnd=M+k.substr(R.column),l.autoInsertedBrackets++},p.recordMaybeInsert=function(b,x,M){var R=b.getCursorPosition(),k=x.doc.getLine(R.row);this.isMaybeInsertedClosing(R,k)||(l.maybeInsertedBrackets=0),l.maybeInsertedRow=R.row,l.maybeInsertedLineStart=k.substr(0,R.column)+M,l.maybeInsertedLineEnd=k.substr(R.column),l.maybeInsertedBrackets++},p.isAutoInsertedClosing=function(b,x,M){return l.autoInsertedBrackets>0&&b.row===l.autoInsertedRow&&M===l.autoInsertedLineEnd[0]&&x.substr(b.column)===l.autoInsertedLineEnd},p.isMaybeInsertedClosing=function(b,x){return l.maybeInsertedBrackets>0&&b.row===l.maybeInsertedRow&&x.substr(b.column)===l.maybeInsertedLineEnd&&x.substr(0,b.column)==l.maybeInsertedLineStart},p.popAutoInsertedClosing=function(){l.autoInsertedLineEnd=l.autoInsertedLineEnd.substr(1),l.autoInsertedBrackets--},p.clearMaybeInsertedClosing=function(){l&&(l.maybeInsertedBrackets=0,l.maybeInsertedRow=-1)},f.inherits(p,g),r.CstyleBehaviour=p}),ace.define("ace/unicode",["require","exports","module"],function(e,r,m){for(var f=[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],g=0,w=[],u=0;u<f.length;u+=2)w.push(g+=f[u]),f[u+1]&&w.push(45,g+=f[u+1]);r.wordChars=String.fromCharCode.apply(null,w)}),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(e,r,m){var f=e("../config"),g=e("../tokenizer").Tokenizer,w=e("./text_highlight_rules").TextHighlightRules,u=e("./behaviour/cstyle").CstyleBehaviour,d=e("../unicode"),a=e("../lib/lang"),l=e("../token_iterator").TokenIterator,c=e("../range").Range,h;h=function(){this.HighlightRules=w},(function(){this.$defaultBehaviour=new u,this.tokenRe=new RegExp("^["+d.wordChars+"\\$_]+","g"),this.nonTokenRe=new RegExp("^(?:[^"+d.wordChars+"\\$_]|\\s])+","g"),this.getTokenizer=function(){return this.$tokenizer||(this.$highlightRules=this.$highlightRules||new this.HighlightRules(this.$highlightRuleConfig),this.$tokenizer=new g(this.$highlightRules.getRules())),this.$tokenizer},this.lineCommentStart="",this.blockComment="",this.toggleCommentLines=function(o,s,p,b){var x=s.doc,M=!0,R=!0,k=1/0,C=s.getTabSize(),L=!1;if(this.lineCommentStart){if(Array.isArray(this.lineCommentStart))var D=this.lineCommentStart.map(a.escapeRegExp).join("|"),I=this.lineCommentStart[0];else var D=a.escapeRegExp(this.lineCommentStart),I=this.lineCommentStart;D=new RegExp("^(\\s*)(?:"+D+") ?"),L=s.getUseSoftTabs();var T=function(G,J){var ne=G.match(D);if(ne){var de=ne[1].length,ee=ne[0].length;!S(G,de,ee)&&ne[0][ee-1]==" "&&ee--,x.removeInLine(J,de,ee)}},W=I+" ",F=function(G,J){(!M||/\S/.test(G))&&(S(G,k,k)?x.insertInLine({row:J,column:k},W):x.insertInLine({row:J,column:k},I))},O=function(G,J){return D.test(G)},S=function(G,J,ne){for(var de=0;J--&&G.charAt(J)==" ";)de++;if(de%C!=0)return!1;for(var de=0;G.charAt(ne++)==" ";)de++;return C>2?de%C!=C-1:de%C==0}}else{if(!this.blockComment)return!1;var I=this.blockComment.start,A=this.blockComment.end,D=new RegExp("^(\\s*)(?:"+a.escapeRegExp(I)+")"),N=new RegExp("(?:"+a.escapeRegExp(A)+")\\s*$"),F=function(se,ce){O(se,ce)||(!M||/\S/.test(se))&&(x.insertInLine({row:ce,column:se.length},A),x.insertInLine({row:ce,column:k},I))},T=function(se,ce){var le;(le=se.match(N))&&x.removeInLine(ce,se.length-le[0].length,se.length),(le=se.match(D))&&x.removeInLine(ce,le[1].length,le[0].length)},O=function(se,ce){if(D.test(se))return!0;for(var le=s.getTokens(ce),pe=0;pe<le.length;pe++)if(le[pe].type==="comment")return!0}}function B(G){for(var J=p;J<=b;J++)G(x.getLine(J),J)}var U=1/0;B(function(G,J){var ne=G.search(/\S/);ne!==-1?(ne<k&&(k=ne),R&&!O(G,J)&&(R=!1)):U>G.length&&(U=G.length)}),k==1/0&&(k=U,M=!1,R=!1),L&&k%C!=0&&(k=Math.floor(k/C)*C),B(R?T:F)},this.toggleBlockComment=function(o,s,p,b){var x=this.blockComment;if(x){!x.start&&x[0]&&(x=x[0]);var M=new l(s,b.row,b.column),R=M.getCurrentToken();s.selection;var k=s.selection.toOrientedRange(),C,L;if(R&&/comment/.test(R.type)){for(var D,I;R&&/comment/.test(R.type);){var T=R.value.indexOf(x.start);if(T!=-1){var W=M.getCurrentTokenRow(),F=M.getCurrentTokenColumn()+T;D=new c(W,F,W,F+x.start.length);break}R=M.stepBackward()}for(var M=new l(s,b.row,b.column),R=M.getCurrentToken();R&&/comment/.test(R.type);){var T=R.value.indexOf(x.end);if(T!=-1){var W=M.getCurrentTokenRow(),F=M.getCurrentTokenColumn()+T;I=new c(W,F,W,F+x.end.length);break}R=M.stepForward()}I&&s.remove(I),D&&(s.remove(D),C=D.start.row,L=-x.start.length)}else L=x.start.length,C=p.start.row,s.insert(p.end,x.end),s.insert(p.start,x.start);k.start.row==C&&(k.start.column+=L),k.end.row==C&&(k.end.column+=L),s.selection.fromOrientedRange(k)}},this.getNextLineIndent=function(o,s,p){return this.$getIndent(s)},this.checkOutdent=function(o,s,p){return!1},this.autoOutdent=function(o,s,p){},this.$getIndent=function(o){return o.match(/^\s*/)[0]},this.createWorker=function(o){return null},this.createModeDelegates=function(o){this.$embeds=[],this.$modes={};for(var s in o)if(o[s]){var p=o[s],b=p.prototype.$id,x=f.$modes[b];x||(f.$modes[b]=x=new p),f.$modes[s]||(f.$modes[s]=x),this.$embeds.push(s),this.$modes[s]=x}for(var M=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"],R=function(L){(function(D){var I=M[L],T=D[I];D[M[L]]=function(){return this.$delegator(I,arguments,T)}})(k)},k=this,s=0;s<M.length;s++)R(s)},this.$delegator=function(o,s,p){var b=s[0]||"start";if(typeof b!="string"){if(Array.isArray(b[2])){var x=b[2][b[2].length-1],M=this.$modes[x];if(M)return M[o].apply(M,[b[1]].concat([].slice.call(s,1)))}b=b[0]||"start"}for(var R=0;R<this.$embeds.length;R++)if(this.$modes[this.$embeds[R]]){var k=b.split(this.$embeds[R]);if(!k[0]&&k[1]){s[0]=k[1];var M=this.$modes[this.$embeds[R]];return M[o].apply(M,s)}}var C=p.apply(this,s);return p?C:void 0},this.transformAction=function(o,s,p,b,x){if(this.$behaviour){var M=this.$behaviour.getBehaviours();for(var R in M)if(M[R][s]){var k=M[R][s].apply(this,arguments);if(k)return k}}},this.getKeywords=function(o){if(!this.completionKeywords){var s=this.$tokenizer.rules,p=[];for(var b in s)for(var x=s[b],M=0,R=x.length;M<R;M++)if(typeof x[M].token=="string")/keyword|support|storage/.test(x[M].token)&&p.push(x[M].regex);else if(typeof x[M].token=="object"){for(var k=0,C=x[M].token.length;k<C;k++)if(/keyword|support|storage/.test(x[M].token[k])){var b=x[M].regex.match(/\(.+?\)/g)[k];p.push(b.substr(1,b.length-2))}}this.completionKeywords=p}return o?p.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(o,s,p,b){var x=this.$keywordList||this.$createKeywordList();return x.map(function(M){return{name:M,value:M,score:0,meta:"keyword"}})},this.$id="ace/mode/text"}).call(h.prototype),r.Mode=h}),ace.define("ace/line_widgets",["require","exports","module","ace/lib/dom"],function(e,r,m){var f=e("./lib/dom"),g=(function(){function w(u){this.session=u,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 w.prototype.getRowLength=function(u){var d;return this.lineWidgets?d=this.lineWidgets[u]&&this.lineWidgets[u].rowCount||0:d=0,!this.$useWrapMode||!this.$wrapData[u]?1+d:this.$wrapData[u].length+1+d},w.prototype.$getWidgetScreenLength=function(){var u=0;return this.lineWidgets.forEach(function(d){d&&d.rowCount&&!d.hidden&&(u+=d.rowCount)}),u},w.prototype.$onChangeEditor=function(u){this.attach(u.editor)},w.prototype.attach=function(u){u&&u.widgetManager&&u.widgetManager!=this&&u.widgetManager.detach(),this.editor!=u&&(this.detach(),this.editor=u,u&&(u.widgetManager=this,u.renderer.on("beforeRender",this.measureWidgets),u.renderer.on("afterRender",this.renderWidgets)))},w.prototype.detach=function(u){var d=this.editor;if(d){this.editor=null,d.widgetManager=null,d.renderer.off("beforeRender",this.measureWidgets),d.renderer.off("afterRender",this.renderWidgets);var a=this.session.lineWidgets;a&&a.forEach(function(l){l&&l.el&&l.el.parentNode&&(l._inDocument=!1,l.el.parentNode.removeChild(l.el))})}},w.prototype.updateOnFold=function(u,d){var a=d.lineWidgets;if(!(!a||!u.action)){for(var l=u.data,c=l.start.row,h=l.end.row,o=u.action=="add",s=c+1;s<h;s++)a[s]&&(a[s].hidden=o);a[h]&&(o?a[c]?a[h].hidden=o:a[c]=a[h]:(a[c]==a[h]&&(a[c]=void 0),a[h].hidden=o))}},w.prototype.updateOnChange=function(u){var d=this.session.lineWidgets;if(d){var a=u.start.row,l=u.end.row-a;if(l!==0)if(u.action=="remove"){var c=d.splice(a+1,l);!d[a]&&c[c.length-1]&&(d[a]=c.pop()),c.forEach(function(o){o&&this.removeLineWidget(o)},this),this.$updateRows()}else{var h=new Array(l);d[a]&&d[a].column!=null&&u.start.column>d[a].column&&a++,h.unshift(a,0),d.splice.apply(d,h),this.$updateRows()}}},w.prototype.$updateRows=function(){var u=this.session.lineWidgets;if(u){var d=!0;u.forEach(function(a,l){if(a)for(d=!1,a.row=l;a.$oldWidget;)a.$oldWidget.row=l,a=a.$oldWidget}),d&&(this.session.lineWidgets=null)}},w.prototype.$registerLineWidget=function(u){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var d=this.session.lineWidgets[u.row];return d&&(u.$oldWidget=d,d.el&&d.el.parentNode&&(d.el.parentNode.removeChild(d.el),d._inDocument=!1)),this.session.lineWidgets[u.row]=u,u},w.prototype.addLineWidget=function(u){if(this.$registerLineWidget(u),u.session=this.session,!this.editor)return u;var d=this.editor.renderer;u.html&&!u.el&&(u.el=f.createElement("div"),u.el.innerHTML=u.html),u.text&&!u.el&&(u.el=f.createElement("div"),u.el.textContent=u.text),u.el&&(f.addCssClass(u.el,"ace_lineWidgetContainer"),u.className&&f.addCssClass(u.el,u.className),u.el.style.position="absolute",u.el.style.zIndex="5",d.container.appendChild(u.el),u._inDocument=!0,u.coverGutter||(u.el.style.zIndex="3"),u.pixelHeight==null&&(u.pixelHeight=u.el.offsetHeight)),u.rowCount==null&&(u.rowCount=u.pixelHeight/d.layerConfig.lineHeight);var a=this.session.getFoldAt(u.row,0);if(u.$fold=a,a){var l=this.session.lineWidgets;u.row==a.end.row&&!l[a.start.row]?l[a.start.row]=u:u.hidden=!0}return this.session._emit("changeFold",{data:{start:{row:u.row}}}),this.$updateRows(),this.renderWidgets(null,d),this.onWidgetChanged(u),u},w.prototype.removeLineWidget=function(u){if(u._inDocument=!1,u.session=null,u.el&&u.el.parentNode&&u.el.parentNode.removeChild(u.el),u.editor&&u.editor.destroy)try{u.editor.destroy()}catch{}if(this.session.lineWidgets){var d=this.session.lineWidgets[u.row];if(d==u)this.session.lineWidgets[u.row]=u.$oldWidget,u.$oldWidget&&this.onWidgetChanged(u.$oldWidget);else for(;d;){if(d.$oldWidget==u){d.$oldWidget=u.$oldWidget;break}d=d.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:u.row}}}),this.$updateRows()},w.prototype.getWidgetsAtRow=function(u){for(var d=this.session.lineWidgets,a=d&&d[u],l=[];a;)l.push(a),a=a.$oldWidget;return l},w.prototype.onWidgetChanged=function(u){this.session._changedWidgets.push(u),this.editor&&this.editor.renderer.updateFull()},w.prototype.measureWidgets=function(u,d){var a=this.session._changedWidgets,l=d.layerConfig;if(!(!a||!a.length)){for(var c=1/0,h=0;h<a.length;h++){var o=a[h];if(!(!o||!o.el)&&o.session==this.session){if(!o._inDocument){if(this.session.lineWidgets[o.row]!=o)continue;o._inDocument=!0,d.container.appendChild(o.el)}o.h=o.el.offsetHeight,o.fixedWidth||(o.w=o.el.offsetWidth,o.screenWidth=Math.ceil(o.w/l.characterWidth));var s=o.h/l.lineHeight;o.coverLine&&(s-=this.session.getRowLineCount(o.row),s<0&&(s=0)),o.rowCount!=s&&(o.rowCount=s,o.row<c&&(c=o.row))}}c!=1/0&&(this.session._emit("changeFold",{data:{start:{row:c}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]}},w.prototype.renderWidgets=function(u,d){var a=d.layerConfig,l=this.session.lineWidgets;if(l){for(var c=Math.min(this.firstRow,a.firstRow),h=Math.max(this.lastRow,a.lastRow,l.length);c>0&&!l[c];)c--;this.firstRow=a.firstRow,this.lastRow=a.lastRow,d.$cursorLayer.config=a;for(var o=c;o<=h;o++){var s=l[o];if(!(!s||!s.el)){if(s.hidden){s.el.style.top=-100-(s.pixelHeight||0)+"px";continue}s._inDocument||(s._inDocument=!0,d.container.appendChild(s.el));var p=d.$cursorLayer.getPixelPosition({row:o,column:0},!0).top;s.coverLine||(p+=a.lineHeight*this.session.getRowLineCount(s.row)),s.el.style.top=p-a.offset+"px";var b=s.coverGutter?0:d.gutterWidth;s.fixedWidth||(b-=d.scrollLeft),s.el.style.left=b+"px",s.fullWidth&&s.screenWidth&&(s.el.style.minWidth=a.width+2*a.padding+"px"),s.fixedWidth?s.el.style.right=d.scrollBar.getWidth()+"px":s.el.style.right=""}}}},w})();r.LineWidgets=g}),ace.define("ace/apply_delta",["require","exports","module"],function(e,r,m){r.applyDelta=function(f,g,w){var u=g.start.row,d=g.start.column,a=f[u]||"";switch(g.action){case"insert":var l=g.lines;if(l.length===1)f[u]=a.substring(0,d)+g.lines[0]+a.substring(d);else{var c=[u,1].concat(g.lines);f.splice.apply(f,c),f[u]=a.substring(0,d)+f[u],f[u+g.lines.length-1]+=a.substring(d)}break;case"remove":var h=g.end.column,o=g.end.row;u===o?f[u]=a.substring(0,d)+a.substring(h):f.splice(u,o-u+1,a.substring(0,d)+f[o].substring(h));break}}}),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,r,m){var f=e("./lib/oop"),g=e("./lib/event_emitter").EventEmitter,w=(function(){function a(l,c,h){this.$onChange=this.onChange.bind(this),this.attach(l),typeof c!="number"?this.setPosition(c.row,c.column):this.setPosition(c,h)}return a.prototype.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},a.prototype.getDocument=function(){return this.document},a.prototype.onChange=function(l){if(!(l.start.row==l.end.row&&l.start.row!=this.row)&&!(l.start.row>this.row)){var c=d(l,{row:this.row,column:this.column},this.$insertRight);this.setPosition(c.row,c.column,!0)}},a.prototype.setPosition=function(l,c,h){var o;if(h?o={row:l,column:c}:o=this.$clipPositionToDocument(l,c),!(this.row==o.row&&this.column==o.column)){var s={row:this.row,column:this.column};this.row=o.row,this.column=o.column,this._signal("change",{old:s,value:o})}},a.prototype.detach=function(){this.document.off("change",this.$onChange)},a.prototype.attach=function(l){this.document=l||this.document,this.document.on("change",this.$onChange)},a.prototype.$clipPositionToDocument=function(l,c){var h={};return l>=this.document.getLength()?(h.row=Math.max(0,this.document.getLength()-1),h.column=this.document.getLine(h.row).length):l<0?(h.row=0,h.column=0):(h.row=l,h.column=Math.min(this.document.getLine(h.row).length,Math.max(0,c))),c<0&&(h.column=0),h},a})();w.prototype.$insertRight=!1,f.implement(w.prototype,g);function u(a,l,c){var h=c?a.column<=l.column:a.column<l.column;return a.row<l.row||a.row==l.row&&h}function d(a,l,c){var h=a.action=="insert",o=(h?1:-1)*(a.end.row-a.start.row),s=(h?1:-1)*(a.end.column-a.start.column),p=a.start,b=h?p:a.end;return u(l,p,c)?{row:l.row,column:l.column}:u(b,l,!c)?{row:l.row+o,column:l.column+(l.row==b.row?s:0)}:{row:p.row,column:p.column}}r.Anchor=w}),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"],function(e,r,m){var f=e("./lib/oop"),g=e("./apply_delta").applyDelta,w=e("./lib/event_emitter").EventEmitter,u=e("./range").Range,d=e("./anchor").Anchor,a=(function(){function l(c){this.$lines=[""],c.length===0?this.$lines=[""]:Array.isArray(c)?this.insertMergedLines({row:0,column:0},c):this.insert({row:0,column:0},c)}return l.prototype.setValue=function(c){var h=this.getLength()-1;this.remove(new u(0,0,h,this.getLine(h).length)),this.insert({row:0,column:0},c||"")},l.prototype.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},l.prototype.createAnchor=function(c,h){return new d(this,c,h)},l.prototype.$detectNewLine=function(c){var h=c.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=h?h[1]:`
189
+ `,this._signal("changeNewLineMode")},l.prototype.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return`\r
190
+ `;case"unix":return`
191
+ `;default:return this.$autoNewLine||`
192
+ `}},l.prototype.setNewLineMode=function(c){this.$newLineMode!==c&&(this.$newLineMode=c,this._signal("changeNewLineMode"))},l.prototype.getNewLineMode=function(){return this.$newLineMode},l.prototype.isNewLine=function(c){return c==`\r
193
+ `||c=="\r"||c==`
194
+ `},l.prototype.getLine=function(c){return this.$lines[c]||""},l.prototype.getLines=function(c,h){return this.$lines.slice(c,h+1)},l.prototype.getAllLines=function(){return this.getLines(0,this.getLength())},l.prototype.getLength=function(){return this.$lines.length},l.prototype.getTextRange=function(c){return this.getLinesForRange(c).join(this.getNewLineCharacter())},l.prototype.getLinesForRange=function(c){var h;if(c.start.row===c.end.row)h=[this.getLine(c.start.row).substring(c.start.column,c.end.column)];else{h=this.getLines(c.start.row,c.end.row),h[0]=(h[0]||"").substring(c.start.column);var o=h.length-1;c.end.row-c.start.row==o&&(h[o]=h[o].substring(0,c.end.column))}return h},l.prototype.insertLines=function(c,h){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(c,h)},l.prototype.removeLines=function(c,h){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(c,h)},l.prototype.insertNewLine=function(c){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(c,["",""])},l.prototype.insert=function(c,h){return this.getLength()<=1&&this.$detectNewLine(h),this.insertMergedLines(c,this.$split(h))},l.prototype.insertInLine=function(c,h){var o=this.clippedPos(c.row,c.column),s=this.pos(c.row,c.column+h.length);return this.applyDelta({start:o,end:s,action:"insert",lines:[h]},!0),this.clonePos(s)},l.prototype.clippedPos=function(c,h){var o=this.getLength();c===void 0?c=o:c<0?c=0:c>=o&&(c=o-1,h=void 0);var s=this.getLine(c);return h==null&&(h=s.length),h=Math.min(Math.max(h,0),s.length),{row:c,column:h}},l.prototype.clonePos=function(c){return{row:c.row,column:c.column}},l.prototype.pos=function(c,h){return{row:c,column:h}},l.prototype.$clipPosition=function(c){var h=this.getLength();return c.row>=h?(c.row=Math.max(0,h-1),c.column=this.getLine(h-1).length):(c.row=Math.max(0,c.row),c.column=Math.min(Math.max(c.column,0),this.getLine(c.row).length)),c},l.prototype.insertFullLines=function(c,h){c=Math.min(Math.max(c,0),this.getLength());var o=0;c<this.getLength()?(h=h.concat([""]),o=0):(h=[""].concat(h),c--,o=this.$lines[c].length),this.insertMergedLines({row:c,column:o},h)},l.prototype.insertMergedLines=function(c,h){var o=this.clippedPos(c.row,c.column),s={row:o.row+h.length-1,column:(h.length==1?o.column:0)+h[h.length-1].length};return this.applyDelta({start:o,end:s,action:"insert",lines:h}),this.clonePos(s)},l.prototype.remove=function(c){var h=this.clippedPos(c.start.row,c.start.column),o=this.clippedPos(c.end.row,c.end.column);return this.applyDelta({start:h,end:o,action:"remove",lines:this.getLinesForRange({start:h,end:o})}),this.clonePos(h)},l.prototype.removeInLine=function(c,h,o){var s=this.clippedPos(c,h),p=this.clippedPos(c,o);return this.applyDelta({start:s,end:p,action:"remove",lines:this.getLinesForRange({start:s,end:p})},!0),this.clonePos(s)},l.prototype.removeFullLines=function(c,h){c=Math.min(Math.max(0,c),this.getLength()-1),h=Math.min(Math.max(0,h),this.getLength()-1);var o=h==this.getLength()-1&&c>0,s=h<this.getLength()-1,p=o?c-1:c,b=o?this.getLine(p).length:0,x=s?h+1:h,M=s?0:this.getLine(x).length,R=new u(p,b,x,M),k=this.$lines.slice(c,h+1);return this.applyDelta({start:R.start,end:R.end,action:"remove",lines:this.getLinesForRange(R)}),k},l.prototype.removeNewLine=function(c){c<this.getLength()-1&&c>=0&&this.applyDelta({start:this.pos(c,this.getLine(c).length),end:this.pos(c+1,0),action:"remove",lines:["",""]})},l.prototype.replace=function(c,h){if(c instanceof u||(c=u.fromPoints(c.start,c.end)),h.length===0&&c.isEmpty())return c.start;if(h==this.getTextRange(c))return c.end;this.remove(c);var o;return h?o=this.insert(c.start,h):o=c.start,o},l.prototype.applyDeltas=function(c){for(var h=0;h<c.length;h++)this.applyDelta(c[h])},l.prototype.revertDeltas=function(c){for(var h=c.length-1;h>=0;h--)this.revertDelta(c[h])},l.prototype.applyDelta=function(c,h){var o=c.action=="insert";(o?c.lines.length<=1&&!c.lines[0]:!u.comparePoints(c.start,c.end))||(o&&c.lines.length>2e4?this.$splitAndapplyLargeDelta(c,2e4):(g(this.$lines,c,h),this._signal("change",c)))},l.prototype.$safeApplyDelta=function(c){var h=this.$lines.length;(c.action=="remove"&&c.start.row<h&&c.end.row<h||c.action=="insert"&&c.start.row<=h)&&this.applyDelta(c)},l.prototype.$splitAndapplyLargeDelta=function(c,h){for(var o=c.lines,s=o.length-h+1,p=c.start.row,b=c.start.column,x=0,M=0;x<s;x=M){M+=h-1;var R=o.slice(x,M);R.push(""),this.applyDelta({start:this.pos(p+x,b),end:this.pos(p+M,b=0),action:c.action,lines:R},!0)}c.lines=o.slice(x),c.start.row=p+x,c.start.column=b,this.applyDelta(c,!0)},l.prototype.revertDelta=function(c){this.$safeApplyDelta({start:this.clonePos(c.start),end:this.clonePos(c.end),action:c.action=="insert"?"remove":"insert",lines:c.lines.slice()})},l.prototype.indexToPosition=function(c,h){for(var o=this.$lines||this.getAllLines(),s=this.getNewLineCharacter().length,p=h||0,b=o.length;p<b;p++)if(c-=o[p].length+s,c<0)return{row:p,column:c+o[p].length+s};return{row:b-1,column:c+o[b-1].length+s}},l.prototype.positionToIndex=function(c,h){for(var o=this.$lines||this.getAllLines(),s=this.getNewLineCharacter().length,p=0,b=Math.min(c.row,o.length),x=h||0;x<b;++x)p+=o[x].length+s;return p+c.column},l.prototype.$split=function(c){return c.split(/\r\n|\r|\n/)},l})();a.prototype.$autoNewLine="",a.prototype.$newLineMode="auto",f.implement(a.prototype,w),r.Document=a}),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,r,m){var f=e("./lib/oop"),g=e("./lib/event_emitter").EventEmitter,w=(function(){function u(d,a){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=d;var l=this;this.$worker=function(){if(l.running){for(var c=new Date,h=l.currentLine,o=-1,s=l.doc,p=h;l.lines[h];)h++;var b=s.getLength(),x=0;for(l.running=!1;h<b;){l.$tokenizeRow(h),o=h;do h++;while(l.lines[h]);if(x++,x%5===0&&new Date-c>20){l.running=setTimeout(l.$worker,20);break}}l.currentLine=h,o==-1&&(o=h),p<=o&&l.fireUpdateEvent(p,o)}}}return u.prototype.setTokenizer=function(d){this.tokenizer=d,this.lines=[],this.states=[],this.start(0)},u.prototype.setDocument=function(d){this.doc=d,this.lines=[],this.states=[],this.stop()},u.prototype.fireUpdateEvent=function(d,a){var l={first:d,last:a};this._signal("update",{data:l})},u.prototype.start=function(d){this.currentLine=Math.min(d||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)},u.prototype.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},u.prototype.$updateOnChange=function(d){var a=d.start.row,l=d.end.row-a;if(l===0)this.lines[a]=null;else if(d.action=="remove")this.lines.splice(a,l+1,null),this.states.splice(a,l+1,null);else{var c=Array(l+1);c.unshift(a,1),this.lines.splice.apply(this.lines,c),this.states.splice.apply(this.states,c)}this.currentLine=Math.min(a,this.currentLine,this.doc.getLength()),this.stop()},u.prototype.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},u.prototype.getTokens=function(d){return this.lines[d]||this.$tokenizeRow(d)},u.prototype.getState=function(d){return this.currentLine==d&&this.$tokenizeRow(d),this.states[d]||"start"},u.prototype.$tokenizeRow=function(d){var a=this.doc.getLine(d),l=this.states[d-1],c=this.tokenizer.getLineTokens(a,l,d);return this.states[d]+""!=c.state+""?(this.states[d]=c.state,this.lines[d+1]=null,this.currentLine>d+1&&(this.currentLine=d+1)):this.currentLine==d&&(this.currentLine=d+1),this.lines[d]=c.tokens},u.prototype.cleanup=function(){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.removeAllListeners()},u})();f.implement(w.prototype,g),r.BackgroundTokenizer=w}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/range"],function(e,r,m){var f=e("./lib/lang"),g=e("./range").Range,w=(function(){function u(d,a,l){l===void 0&&(l="text"),this.setRegexp(d),this.clazz=a,this.type=l,this.docLen=0}return u.prototype.setRegexp=function(d){this.regExp+""!=d+""&&(this.regExp=d,this.cache=[])},u.prototype.update=function(d,a,l,c){if(this.regExp){for(var h=c.firstRow,o=c.lastRow,s={},p=l.$editor&&l.$editor.$search,b=p&&p.$isMultilineSearch(l.$editor.getLastSearchOptions()),x=h;x<=o;x++){var M=this.cache[x];if(M==null||l.getValue().length!=this.docLen){if(b){M=[];var R=p.$multiLineForward(l,this.regExp,x,o);if(R){var k=R.endRow<=o?R.endRow-1:o;k>x&&(x=k),M.push(new g(R.startRow,R.startCol,R.endRow,R.endCol))}M.length>this.MAX_RANGES&&(M=M.slice(0,this.MAX_RANGES))}else M=f.getMatchOffsets(l.getLine(x),this.regExp),M.length>this.MAX_RANGES&&(M=M.slice(0,this.MAX_RANGES)),M=M.map(function(I){return new g(x,I.offset,x,I.offset+I.length)});this.cache[x]=M.length?M:""}if(M.length!==0)for(var C=M.length;C--;){var L=M[C].toScreenRange(l),D=L.toString();s[D]||(s[D]=!0,a.drawSingleLineMarker(d,L,this.clazz,c))}}this.docLen=l.getValue().length}},u})();w.prototype.MAX_RANGES=500,r.SearchHighlight=w}),ace.define("ace/undomanager",["require","exports","module","ace/range"],function(e,r,m){var f=(function(){function k(){this.$keepRedoStack,this.$maxRev=0,this.$fromUndo=!1,this.$undoDepth=1/0,this.reset()}return k.prototype.addSession=function(C){this.$session=C},k.prototype.add=function(C,L,D){if(!this.$fromUndo&&C!=this.$lastDelta){if(this.$keepRedoStack||(this.$redoStack.length=0),L===!1||!this.lastDeltas){this.lastDeltas=[];var I=this.$undoStack.length;I>this.$undoDepth-1&&this.$undoStack.splice(0,I-this.$undoDepth+1),this.$undoStack.push(this.lastDeltas),C.id=this.$rev=++this.$maxRev}(C.action=="remove"||C.action=="insert")&&(this.$lastDelta=C),this.lastDeltas.push(C)}},k.prototype.addSelection=function(C,L){this.selections.push({value:C,rev:L||this.$rev})},k.prototype.startNewGroup=function(){return this.lastDeltas=null,this.$rev},k.prototype.markIgnored=function(C,L){L==null&&(L=this.$rev+1);for(var D=this.$undoStack,I=D.length;I--;){var T=D[I][0];if(T.id<=C)break;T.id<L&&(T.ignore=!0)}this.lastDeltas=null},k.prototype.getSelection=function(C,L){for(var D=this.selections,I=D.length;I--;){var T=D[I];if(T.rev<C)return L&&(T=D[I+1]),T}},k.prototype.getRevision=function(){return this.$rev},k.prototype.getDeltas=function(C,L){L==null&&(L=this.$rev+1);for(var D=this.$undoStack,I=null,T=0,W=D.length;W--;){var F=D[W][0];if(F.id<L&&!I&&(I=W+1),F.id<=C){T=W+1;break}}return D.slice(T,I)},k.prototype.getChangedRanges=function(C,L){L==null&&(L=this.$rev+1)},k.prototype.getChangedLines=function(C,L){L==null&&(L=this.$rev+1)},k.prototype.undo=function(C,L){this.lastDeltas=null;var D=this.$undoStack;if(g(D,D.length)){C||(C=this.$session),this.$redoStackBaseRev!==this.$rev&&this.$redoStack.length&&(this.$redoStack=[]),this.$fromUndo=!0;var I=D.pop(),T=null;return I&&(T=C.undoChanges(I,L),this.$redoStack.push(I),this.$syncRev()),this.$fromUndo=!1,T}},k.prototype.redo=function(C,L){if(this.lastDeltas=null,C||(C=this.$session),this.$fromUndo=!0,this.$redoStackBaseRev!=this.$rev){var D=this.getDeltas(this.$redoStackBaseRev,this.$rev+1);R(this.$redoStack,D),this.$redoStackBaseRev=this.$rev,this.$redoStack.forEach(function(W){W[0].id=++this.$maxRev},this)}var I=this.$redoStack.pop(),T=null;return I&&(T=C.redoChanges(I,L),this.$undoStack.push(I),this.$syncRev()),this.$fromUndo=!1,T},k.prototype.$syncRev=function(){var C=this.$undoStack,L=C[C.length-1],D=L&&L[0].id||0;this.$redoStackBaseRev=D,this.$rev=D},k.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=[]},k.prototype.canUndo=function(){return this.$undoStack.length>0},k.prototype.canRedo=function(){return this.$redoStack.length>0},k.prototype.bookmark=function(C){C==null&&(C=this.$rev),this.mark=C},k.prototype.isAtBookmark=function(){return this.$rev===this.mark},k.prototype.toJSON=function(){return{$redoStack:this.$redoStack,$undoStack:this.$undoStack}},k.prototype.fromJSON=function(C){this.reset(),this.$undoStack=C.$undoStack,this.$redoStack=C.$redoStack},k.prototype.$prettyPrint=function(C){return C?l(C):l(this.$undoStack)+`
195
+ ---
196
+ `+l(this.$redoStack)},k})();f.prototype.hasUndo=f.prototype.canUndo,f.prototype.hasRedo=f.prototype.canRedo,f.prototype.isClean=f.prototype.isAtBookmark,f.prototype.markClean=f.prototype.bookmark;function g(k,C){for(var L=C;L--;){var D=k[L];if(D&&!D[0].ignore){for(;L<C-1;){var I=o(k[L],k[L+1]);k[L]=I[0],k[L+1]=I[1],L++}return!0}}}var w=e("./range").Range,u=w.comparePoints;w.comparePoints;function d(k){return{row:k.row,column:k.column}}function a(k){return{start:d(k.start),end:d(k.end),action:k.action,lines:k.lines.slice()}}function l(k){if(k=k||this,Array.isArray(k))return k.map(l).join(`
197
+ `);var C="";return k.action?(C=k.action=="insert"?"+":"-",C+="["+k.lines+"]"):k.value&&(Array.isArray(k.value)?C=k.value.map(c).join(`
198
+ `):C=c(k.value)),k.start&&(C+=c(k)),(k.id||k.rev)&&(C+=" ("+(k.id||k.rev)+")"),C}function c(k){return k.start.row+":"+k.start.column+"=>"+k.end.row+":"+k.end.column}function h(k,C){var L=k.action=="insert",D=C.action=="insert";if(L&&D)if(u(C.start,k.end)>=0)p(C,k,-1);else if(u(C.start,k.start)<=0)p(k,C,1);else return null;else if(L&&!D)if(u(C.start,k.end)>=0)p(C,k,-1);else if(u(C.end,k.start)<=0)p(k,C,-1);else return null;else if(!L&&D)if(u(C.start,k.start)>=0)p(C,k,1);else if(u(C.start,k.start)<=0)p(k,C,1);else return null;else if(!L&&!D)if(u(C.start,k.start)>=0)p(C,k,1);else if(u(C.end,k.start)<=0)p(k,C,-1);else return null;return[C,k]}function o(k,C){for(var L=k.length;L--;)for(var D=0;D<C.length;D++)if(!h(k[L],C[D])){for(;L<k.length;){for(;D--;)h(C[D],k[L]);D=C.length,L++}return[k,C]}return k.selectionBefore=C.selectionBefore=k.selectionAfter=C.selectionAfter=null,[C,k]}function s(k,C){var L=k.action=="insert",D=C.action=="insert";if(L&&D)u(k.start,C.start)<0?p(C,k,1):p(k,C,1);else if(L&&!D)u(k.start,C.end)>=0?p(k,C,-1):(u(k.start,C.start)<=0||p(k,w.fromPoints(C.start,k.start),-1),p(C,k,1));else if(!L&&D)u(C.start,k.end)>=0?p(C,k,-1):(u(C.start,k.start)<=0||p(C,w.fromPoints(k.start,C.start),-1),p(k,C,1));else if(!L&&!D)if(u(C.start,k.end)>=0)p(C,k,-1);else if(u(C.end,k.start)<=0)p(k,C,-1);else{var I,T;return u(k.start,C.start)<0&&(I=k,k=x(k,C.start)),u(k.end,C.end)>0&&(T=x(k,C.end)),b(C.end,k.start,k.end,-1),T&&!I&&(k.lines=T.lines,k.start=T.start,k.end=T.end,T=k),[C,I,T].filter(Boolean)}return[C,k]}function p(k,C,L){b(k.start,C.start,C.end,L),b(k.end,C.start,C.end,L)}function b(k,C,L,D){k.row==(D==1?C:L).row&&(k.column+=D*(L.column-C.column)),k.row+=D*(L.row-C.row)}function x(k,C){var L=k.lines,D=k.end;k.end=d(C);var I=k.end.row-k.start.row,T=L.splice(I,L.length),W=I?C.column:C.column-k.start.column;L.push(T[0].substring(0,W)),T[0]=T[0].substr(W);var F={start:d(C),end:D,lines:T,action:k.action};return F}function M(k,C){C=a(C);for(var L=k.length;L--;){for(var D=k[L],I=0;I<D.length;I++){var T=D[I],W=s(T,C);C=W[0],W.length!=2&&(W[2]?(D.splice(I+1,1,W[1],W[2]),I++):W[1]||(D.splice(I,1),I--))}D.length||k.splice(L,1)}return k}function R(k,C){for(var L=0;L<C.length;L++)for(var D=C[L],I=0;I<D.length;I++)M(k,D[I])}r.UndoManager=f}),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(e,r,m){var f=e("../range").Range,g=(function(){function w(u,d){this.foldData=u,Array.isArray(d)?this.folds=d:d=this.folds=[d];var a=d[d.length-1];this.range=new f(d[0].start.row,d[0].start.column,a.end.row,a.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach(function(l){l.setFoldLine(this)},this)}return w.prototype.shiftRow=function(u){this.start.row+=u,this.end.row+=u,this.folds.forEach(function(d){d.start.row+=u,d.end.row+=u})},w.prototype.addFold=function(u){if(u.sameRow){if(u.start.row<this.startRow||u.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(u),this.folds.sort(function(d,a){return-d.range.compareEnd(a.start.row,a.start.column)}),this.range.compareEnd(u.start.row,u.start.column)>0?(this.end.row=u.end.row,this.end.column=u.end.column):this.range.compareStart(u.end.row,u.end.column)<0&&(this.start.row=u.start.row,this.start.column=u.start.column)}else if(u.start.row==this.end.row)this.folds.push(u),this.end.row=u.end.row,this.end.column=u.end.column;else if(u.end.row==this.start.row)this.folds.unshift(u),this.start.row=u.start.row,this.start.column=u.start.column;else throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");u.foldLine=this},w.prototype.containsRow=function(u){return u>=this.start.row&&u<=this.end.row},w.prototype.walk=function(u,d,a){var l=0,c=this.folds,h,o,s,p=!0;d==null&&(d=this.end.row,a=this.end.column);for(var b=0;b<c.length;b++){if(h=c[b],o=h.range.compareStart(d,a),o==-1){u(null,d,a,l,p);return}if(s=u(null,h.start.row,h.start.column,l,p),s=!s&&u(h.placeholder,h.start.row,h.start.column,l),s||o===0)return;p=!h.sameRow,l=h.end.column}u(null,d,a,l,p)},w.prototype.getNextFoldTo=function(u,d){for(var a,l,c=0;c<this.folds.length;c++){if(a=this.folds[c],l=a.range.compareEnd(u,d),l==-1)return{fold:a,kind:"after"};if(l===0)return{fold:a,kind:"inside"}}return null},w.prototype.addRemoveChars=function(u,d,a){var l=this.getNextFoldTo(u,d),c,h;if(l){if(c=l.fold,l.kind=="inside"&&c.start.column!=d&&c.start.row!=u)window.console&&window.console.log(u,d,c);else if(c.start.row==u){h=this.folds;var o=h.indexOf(c);for(o===0&&(this.start.column+=a),o;o<h.length;o++){if(c=h[o],c.start.column+=a,!c.sameRow)return;c.end.column+=a}this.end.column+=a}}},w.prototype.split=function(u,d){var a=this.getNextFoldTo(u,d);if(!a||a.kind=="inside")return null;var l=a.fold,c=this.folds,h=this.foldData,o=c.indexOf(l),s=c[o-1];this.end.row=s.end.row,this.end.column=s.end.column,c=c.splice(o,c.length-o);var p=new w(h,c);return h.splice(h.indexOf(this)+1,0,p),p},w.prototype.merge=function(u){for(var d=u.folds,a=0;a<d.length;a++)this.addFold(d[a]);var l=this.foldData;l.splice(l.indexOf(u),1)},w.prototype.toString=function(){var u=[this.range.toString()+": ["];return this.folds.forEach(function(d){u.push(" "+d.toString())}),u.push("]"),u.join(`
199
+ `)},w.prototype.idxToPosition=function(u){for(var d=0,a=0;a<this.folds.length;a++){var l=this.folds[a];if(u-=l.start.column-d,u<0)return{row:l.start.row,column:l.start.column+u};if(u-=l.placeholder.length,u<0)return l.start;d=l.end.column}return{row:this.end.row,column:this.end.column+u}},w})();r.FoldLine=g}),ace.define("ace/range_list",["require","exports","module","ace/range"],function(e,r,m){var f=e("./range").Range,g=f.comparePoints,w=(function(){function u(){this.ranges=[],this.$bias=1}return u.prototype.pointIndex=function(d,a,l){for(var c=this.ranges,h=l||0;h<c.length;h++){var o=c[h],s=g(d,o.end);if(!(s>0)){var p=g(d,o.start);return s===0?a&&p!==0?-h-2:h:p>0||p===0&&!a?h:-h-1}}return-h-1},u.prototype.add=function(d){var a=!d.isEmpty(),l=this.pointIndex(d.start,a);l<0&&(l=-l-1);var c=this.pointIndex(d.end,a,l);return c<0?c=-c-1:c++,this.ranges.splice(l,c-l,d)},u.prototype.addList=function(d){for(var a=[],l=d.length;l--;)a.push.apply(a,this.add(d[l]));return a},u.prototype.substractPoint=function(d){var a=this.pointIndex(d);if(a>=0)return this.ranges.splice(a,1)},u.prototype.merge=function(){var d=[],a=this.ranges;a=a.sort(function(s,p){return g(s.start,p.start)});for(var l=a[0],c,h=1;h<a.length;h++){c=l,l=a[h];var o=g(c.end,l.start);o<0||o==0&&!c.isEmpty()&&!l.isEmpty()||(g(c.end,l.end)<0&&(c.end.row=l.end.row,c.end.column=l.end.column),a.splice(h,1),d.push(l),l=c,h--)}return this.ranges=a,d},u.prototype.contains=function(d,a){return this.pointIndex({row:d,column:a})>=0},u.prototype.containsPoint=function(d){return this.pointIndex(d)>=0},u.prototype.rangeAtPoint=function(d){var a=this.pointIndex(d);if(a>=0)return this.ranges[a]},u.prototype.clipRows=function(d,a){var l=this.ranges;if(l[0].start.row>a||l[l.length-1].start.row<d)return[];var c=this.pointIndex({row:d,column:0});c<0&&(c=-c-1);var h=this.pointIndex({row:a,column:0},c);h<0&&(h=-h-1);for(var o=[],s=c;s<h;s++)o.push(l[s]);return o},u.prototype.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},u.prototype.attach=function(d){this.session&&this.detach(),this.session=d,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},u.prototype.detach=function(){this.session&&(this.session.removeListener("change",this.onChange),this.session=null)},u.prototype.$onChange=function(d){for(var a=d.start,l=d.end,c=a.row,h=l.row,o=this.ranges,s=0,p=o.length;s<p;s++){var b=o[s];if(b.end.row>=c)break}if(d.action=="insert")for(var x=h-c,M=-a.column+l.column;s<p;s++){var b=o[s];if(b.start.row>c)break;if(b.start.row==c&&b.start.column>=a.column&&(b.start.column==a.column&&this.$bias<=0||(b.start.column+=M,b.start.row+=x)),b.end.row==c&&b.end.column>=a.column){if(b.end.column==a.column&&this.$bias<0)continue;b.end.column==a.column&&M>0&&s<p-1&&b.end.column>b.start.column&&b.end.column==o[s+1].start.column&&(b.end.column-=M),b.end.column+=M,b.end.row+=x}}else for(var x=c-h,M=a.column-l.column;s<p;s++){var b=o[s];if(b.start.row>h)break;b.end.row<h&&(c<b.end.row||c==b.end.row&&a.column<b.end.column)?(b.end.row=c,b.end.column=a.column):b.end.row==h?b.end.column<=l.column?(x||b.end.column>a.column)&&(b.end.column=a.column,b.end.row=a.row):(b.end.column+=M,b.end.row+=x):b.end.row>h&&(b.end.row+=x),b.start.row<h&&(c<b.start.row||c==b.start.row&&a.column<b.start.column)?(b.start.row=c,b.start.column=a.column):b.start.row==h?b.start.column<=l.column?(x||b.start.column>a.column)&&(b.start.column=a.column,b.start.row=a.row):(b.start.column+=M,b.start.row+=x):b.start.row>h&&(b.start.row+=x)}if(x!=0&&s<p)for(;s<p;s++){var b=o[s];b.start.row+=x,b.end.row+=x}},u})();w.prototype.comparePoints=g,r.RangeList=w}),ace.define("ace/edit_session/fold",["require","exports","module","ace/range_list"],function(e,r,m){var f=this&&this.__extends||(function(){var c=function(h,o){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,p){s.__proto__=p}||function(s,p){for(var b in p)Object.prototype.hasOwnProperty.call(p,b)&&(s[b]=p[b])},c(h,o)};return function(h,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");c(h,o);function s(){this.constructor=h}h.prototype=o===null?Object.create(o):(s.prototype=o.prototype,new s)}})(),g=e("../range_list").RangeList,w=(function(c){f(h,c);function h(o,s){var p=c.call(this)||this;return p.foldLine=null,p.placeholder=s,p.range=o,p.start=o.start,p.end=o.end,p.sameRow=o.start.row==o.end.row,p.subFolds=p.ranges=[],p}return h.prototype.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},h.prototype.setFoldLine=function(o){this.foldLine=o,this.subFolds.forEach(function(s){s.setFoldLine(o)})},h.prototype.clone=function(){var o=this.range.clone(),s=new h(o,this.placeholder);return this.subFolds.forEach(function(p){s.subFolds.push(p.clone())}),s.collapseChildren=this.collapseChildren,s},h.prototype.addSubFold=function(o){if(!this.range.isEqual(o)){d(o,this.start);for(var s=o.start.row,p=o.start.column,b=0,x=-1;b<this.subFolds.length&&(x=this.subFolds[b].range.compare(s,p),x==1);b++);var M=this.subFolds[b],R=0;if(x==0){if(M.range.containsRange(o))return M.addSubFold(o);R=1}for(var s=o.range.end.row,p=o.range.end.column,k=b,x=-1;k<this.subFolds.length&&(x=this.subFolds[k].range.compare(s,p),x==1);k++);x==0&&k++;for(var C=this.subFolds.splice(b,k-b,o),L=x==0?C.length-1:C.length,D=R;D<L;D++)o.addSubFold(C[D]);return o.setFoldLine(this.foldLine),o}},h.prototype.restoreRange=function(o){return l(o,this.start)},h})(g);function u(c,h){c.row-=h.row,c.row==0&&(c.column-=h.column)}function d(c,h){u(c.start,h),u(c.end,h)}function a(c,h){c.row==0&&(c.column+=h.column),c.row+=h.row}function l(c,h){a(c.start,h),a(c.end,h)}r.Fold=w}),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(e,r,m){var f=e("../range").Range,g=e("./fold_line").FoldLine,w=e("./fold").Fold,u=e("../token_iterator").TokenIterator,d=e("../mouse/mouse_event").MouseEvent;function a(){this.getFoldAt=function(l,c,h){var o=this.getFoldLine(l);if(!o)return null;for(var s=o.folds,p=0;p<s.length;p++){var b=s[p].range;if(b.contains(l,c)){if(h==1&&b.isEnd(l,c)&&!b.isEmpty()||h==-1&&b.isStart(l,c)&&!b.isEmpty())continue;return s[p]}}},this.getFoldsInRange=function(l){var c=l.start,h=l.end,o=this.$foldData,s=[];c.column+=1,h.column-=1;for(var p=0;p<o.length;p++){var b=o[p].range.compareRange(l);if(b!=2){if(b==-2)break;for(var x=o[p].folds,M=0;M<x.length;M++){var R=x[M];if(b=R.range.compareRange(l),b==-2)break;if(b!=2){if(b==42)break;s.push(R)}}}}return c.column-=1,h.column+=1,s},this.getFoldsInRangeList=function(l){if(Array.isArray(l)){var c=[];l.forEach(function(o){c=c.concat(this.getFoldsInRange(o))},this)}else var c=this.getFoldsInRange(l);return c},this.getAllFolds=function(){for(var l=[],c=this.$foldData,h=0;h<c.length;h++)for(var o=0;o<c[h].folds.length;o++)l.push(c[h].folds[o]);return l},this.getFoldStringAt=function(l,c,h,o){if(o=o||this.getFoldLine(l),!o)return null;for(var s={end:{column:0}},p,b,x=0;x<o.folds.length;x++){b=o.folds[x];var M=b.range.compareEnd(l,c);if(M==-1){p=this.getLine(b.start.row).substring(s.end.column,b.start.column);break}else if(M===0)return null;s=b}return p||(p=this.getLine(b.start.row).substring(s.end.column)),h==-1?p.substring(0,c-s.end.column):h==1?p.substring(c-s.end.column):p},this.getFoldLine=function(l,c){var h=this.$foldData,o=0;for(c&&(o=h.indexOf(c)),o==-1&&(o=0),o;o<h.length;o++){var s=h[o];if(s.start.row<=l&&s.end.row>=l)return s;if(s.end.row>l)return null}return null},this.getNextFoldLine=function(l,c){var h=this.$foldData,o=0;for(c&&(o=h.indexOf(c)),o==-1&&(o=0),o;o<h.length;o++){var s=h[o];if(s.end.row>=l)return s}return null},this.getFoldedRowCount=function(l,c){for(var h=this.$foldData,o=c-l+1,s=0;s<h.length;s++){var p=h[s],b=p.end.row,x=p.start.row;if(b>=c){x<c&&(x>=l?o-=c-x:o=0);break}else b>=l&&(x>=l?o-=b-x:o-=b-l+1)}return o},this.$addFoldLine=function(l){return this.$foldData.push(l),this.$foldData.sort(function(c,h){return c.start.row-h.start.row}),l},this.addFold=function(l,c){var h=this.$foldData,o=!1,s;l instanceof w?s=l:(s=new w(c,l),s.collapseChildren=c.collapseChildren),this.$clipRangeToDocument(s.range);var p=s.start.row,b=s.start.column,x=s.end.row,M=s.end.column,R=this.getFoldAt(p,b,1),k=this.getFoldAt(x,M,-1);if(R&&k==R)return R.addSubFold(s);R&&!R.range.isStart(p,b)&&this.removeFold(R),k&&!k.range.isEnd(x,M)&&this.removeFold(k);var C=this.getFoldsInRange(s.range);C.length>0&&(this.removeFolds(C),s.collapseChildren||C.forEach(function(T){s.addSubFold(T)}));for(var L=0;L<h.length;L++){var D=h[L];if(x==D.start.row){D.addFold(s),o=!0;break}else if(p==D.end.row){if(D.addFold(s),o=!0,!s.sameRow){var I=h[L+1];if(I&&I.start.row==x){D.merge(I);break}}break}else if(x<=D.start.row)break}return o||(D=this.$addFoldLine(new g(this.$foldData,s))),this.$useWrapMode?this.$updateWrapData(D.start.row,D.start.row):this.$updateRowLengthCache(D.start.row,D.start.row),this.$modified=!0,this._signal("changeFold",{data:s,action:"add"}),s},this.addFolds=function(l){l.forEach(function(c){this.addFold(c)},this)},this.removeFold=function(l){var c=l.foldLine,h=c.start.row,o=c.end.row,s=this.$foldData,p=c.folds;if(p.length==1)s.splice(s.indexOf(c),1);else if(c.range.isEnd(l.end.row,l.end.column))p.pop(),c.end.row=p[p.length-1].end.row,c.end.column=p[p.length-1].end.column;else if(c.range.isStart(l.start.row,l.start.column))p.shift(),c.start.row=p[0].start.row,c.start.column=p[0].start.column;else if(l.sameRow)p.splice(p.indexOf(l),1);else{var b=c.split(l.start.row,l.start.column);p=b.folds,p.shift(),b.start.row=p[0].start.row,b.start.column=p[0].start.column}this.$updating||(this.$useWrapMode?this.$updateWrapData(h,o):this.$updateRowLengthCache(h,o)),this.$modified=!0,this._signal("changeFold",{data:l,action:"remove"})},this.removeFolds=function(l){for(var c=[],h=0;h<l.length;h++)c.push(l[h]);c.forEach(function(o){this.removeFold(o)},this),this.$modified=!0},this.expandFold=function(l){this.removeFold(l),l.subFolds.forEach(function(c){l.restoreRange(c),this.addFold(c)},this),l.collapseChildren>0&&this.foldAll(l.start.row+1,l.end.row,l.collapseChildren-1),l.subFolds=[]},this.expandFolds=function(l){l.forEach(function(c){this.expandFold(c)},this)},this.unfold=function(l,c){var h,o;if(l==null)h=new f(0,0,this.getLength(),0),c==null&&(c=!0);else if(typeof l=="number")h=new f(l,0,l,this.getLine(l).length);else if("row"in l)h=f.fromPoints(l,l);else{if(Array.isArray(l))return o=[],l.forEach(function(p){o=o.concat(this.unfold(p))},this),o;h=l}o=this.getFoldsInRangeList(h);for(var s=o;o.length==1&&f.comparePoints(o[0].start,h.start)<0&&f.comparePoints(o[0].end,h.end)>0;)this.expandFolds(o),o=this.getFoldsInRangeList(h);if(c!=!1?this.removeFolds(o):this.expandFolds(o),s.length)return s},this.isRowFolded=function(l,c){return!!this.getFoldLine(l,c)},this.getRowFoldEnd=function(l,c){var h=this.getFoldLine(l,c);return h?h.end.row:l},this.getRowFoldStart=function(l,c){var h=this.getFoldLine(l,c);return h?h.start.row:l},this.getFoldDisplayLine=function(l,c,h,o,s){o==null&&(o=l.start.row),s==null&&(s=0),c==null&&(c=l.end.row),h==null&&(h=this.getLine(c).length);var p=this.doc,b="";return l.walk(function(x,M,R,k){if(!(M<o)){if(M==o){if(R<s)return;k=Math.max(s,k)}x!=null?b+=x:b+=p.getLine(M).substring(k,R)}},c,h),b},this.getDisplayLine=function(l,c,h,o){var s=this.getFoldLine(l);if(s)return this.getFoldDisplayLine(s,l,c,h,o);var p;return p=this.doc.getLine(l),p.substring(o||0,c||p.length)},this.$cloneFoldData=function(){var l=[];return l=this.$foldData.map(function(c){var h=c.folds.map(function(o){return o.clone()});return new g(l,h)}),l},this.toggleFold=function(l){var c=this.selection,h=c.getRange(),o,s;if(h.isEmpty()){var p=h.start;if(o=this.getFoldAt(p.row,p.column),o){this.expandFold(o);return}else if(l){var b=this.getFoldLine(p.row);b&&this.expandFolds(b.folds);return}else(s=this.findMatchingBracket(p))?h.comparePoint(s)==1?h.end=s:(h.start=s,h.start.column++,h.end.column--):(s=this.findMatchingBracket({row:p.row,column:p.column+1}))?(h.comparePoint(s)==1?h.end=s:h.start=s,h.start.column++):h=this.getCommentFoldRange(p.row,p.column)||h}else{var x=this.getFoldsInRange(h);if(l&&x.length){this.expandFolds(x);return}else x.length==1&&(o=x[0])}if(o||(o=this.getFoldAt(h.start.row,h.start.column)),o&&o.range.toString()==h.toString()){this.expandFold(o);return}var M="...";if(!h.isMultiLine()){if(M=this.getTextRange(h),M.length<4)return;M=M.trim().substring(0,2)+".."}this.addFold(M,h)},this.getCommentFoldRange=function(l,c,h){var o=new u(this,l,c),s=o.getCurrentToken(),p=s&&s.type;if(s&&/^comment|string/.test(p)){p=p.match(/comment|string/)[0],p=="comment"&&(p+="|doc-start|\\.doc");var b=new RegExp(p),x=new f;if(h!=1){do s=o.stepBackward();while(s&&b.test(s.type));s=o.stepForward()}x.start.row=o.getCurrentTokenRow(),x.start.column=o.getCurrentTokenColumn()+s.value.length,o=new u(this,l,c);var M=this.getState(o.$row);if(h!=-1){var R=-1;do if(s=o.stepForward(),R==-1){var k=this.getState(o.$row);M.toString()!==k.toString()&&(R=o.$row)}else if(o.$row>R)break;while(s&&b.test(s.type));s=o.stepBackward()}else s=o.getCurrentToken();return x.end.row=o.getCurrentTokenRow(),x.end.column=o.getCurrentTokenColumn(),x.start.row==x.end.row&&x.start.column>x.end.column?void 0:x}},this.foldAll=function(l,c,h,o){h==null&&(h=1e5);var s=this.foldWidgets;if(s){c=c||this.getLength(),l=l||0;for(var p=l;p<c;p++)if(s[p]==null&&(s[p]=this.getFoldWidget(p)),s[p]=="start"&&!(o&&!o(p))){var b=this.getFoldWidgetRange(p);b&&b.isMultiLine()&&b.end.row<=c&&b.start.row>=l&&(p=b.end.row,b.collapseChildren=h,this.addFold("...",b))}}},this.foldToLevel=function(l){for(this.foldAll();l-- >0;)this.unfold(null,!1)},this.foldAllComments=function(){var l=this;this.foldAll(null,null,null,function(c){for(var h=l.getTokens(c),o=0;o<h.length;o++){var s=h[o];if(!(s.type=="text"&&/^\s+$/.test(s.value)))return!!/comment/.test(s.type)}})},this.$foldStyles={manual:1,markbegin:1,markbeginend:1},this.$foldStyle="markbegin",this.setFoldStyle=function(l){if(!this.$foldStyles[l])throw new Error("invalid fold style: "+l+"["+Object.keys(this.$foldStyles).join(", ")+"]");if(this.$foldStyle!=l){this.$foldStyle=l,l=="manual"&&this.unfold();var c=this.$foldMode;this.$setFolding(null),this.$setFolding(c)}},this.$setFolding=function(l){if(this.$foldMode!=l){if(this.$foldMode=l,this.off("change",this.$updateFoldWidgets),this.off("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets),this._signal("changeAnnotation"),!l||this.$foldStyle=="manual"){this.foldWidgets=null;return}this.foldWidgets=[],this.getFoldWidget=l.getFoldWidget.bind(l,this,this.$foldStyle),this.getFoldWidgetRange=l.getFoldWidgetRange.bind(l,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(l,c){var h=this.foldWidgets;if(!h||c&&h[l])return{};for(var o=l-1,s;o>=0;){var p=h[o];if(p==null&&(p=h[o]=this.getFoldWidget(o)),p=="start"){var b=this.getFoldWidgetRange(o);if(s||(s=b),b&&b.end.row>=l)break}o--}return{range:o!==-1&&b,firstRange:s}},this.onFoldWidgetClick=function(l,c){c instanceof d&&(c=c.domEvent);var h={children:c.shiftKey,all:c.ctrlKey||c.metaKey,siblings:c.altKey},o=this.$toggleFoldWidget(l,h);if(!o){var s=c.target||c.srcElement;s&&/ace_fold-widget/.test(s.className)&&(s.className+=" ace_invalid")}},this.$toggleFoldWidget=function(l,c){if(this.getFoldWidget){var h=this.getFoldWidget(l),o=this.getLine(l),s=h==="end"?-1:1,p=this.getFoldAt(l,s===-1?0:o.length,s);if(p)return c.children||c.all?this.removeFold(p):this.expandFold(p),p;var b=this.getFoldWidgetRange(l,!0);if(b&&!b.isMultiLine()&&(p=this.getFoldAt(b.start.row,b.start.column,1),p&&b.isEqual(p.range)))return this.removeFold(p),p;if(c.siblings){var x=this.getParentFoldRangeData(l);if(x.range)var M=x.range.start.row+1,R=x.range.end.row;this.foldAll(M,R,c.all?1e4:0)}else c.children?(R=b?b.end.row:this.getLength(),this.foldAll(l+1,R,c.all?1e4:0)):b&&(c.all&&(b.collapseChildren=1e4),this.addFold("...",b));return b}},this.toggleFoldWidget=function(l){var c=this.selection.getCursor().row;c=this.getRowFoldStart(c);var h=this.$toggleFoldWidget(c,{});if(!h){var o=this.getParentFoldRangeData(c,!0);if(h=o.range||o.firstRange,h){c=h.start.row;var s=this.getFoldAt(c,this.getLine(c).length,1);s?this.removeFold(s):this.addFold("...",h)}}},this.updateFoldWidgets=function(l){var c=l.start.row,h=l.end.row-c;if(h===0)this.foldWidgets[c]=null;else if(l.action=="remove")this.foldWidgets.splice(c,h+1,null);else{var o=Array(h+1);o.unshift(c,1),this.foldWidgets.splice.apply(this.foldWidgets,o)}},this.tokenizerUpdateFoldWidgets=function(l){var c=l.data;c.first!=c.last&&this.foldWidgets.length>c.first&&this.foldWidgets.splice(c.first,this.foldWidgets.length)}}r.Folding=a}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(e,r,m){var f=e("../token_iterator").TokenIterator,g=e("../range").Range;function w(){this.findMatchingBracket=function(u,d){if(u.column==0)return null;var a=d||this.getLine(u.row).charAt(u.column-1);if(a=="")return null;var l=a.match(/([\(\[\{])|([\)\]\}])/);return l?l[1]?this.$findClosingBracket(l[1],u):this.$findOpeningBracket(l[2],u):null},this.getBracketRange=function(u){var d=this.getLine(u.row),a=!0,l,c=d.charAt(u.column-1),h=c&&c.match(/([\(\[\{])|([\)\]\}])/);if(h||(c=d.charAt(u.column),u={row:u.row,column:u.column+1},h=c&&c.match(/([\(\[\{])|([\)\]\}])/),a=!1),!h)return null;if(h[1]){var o=this.$findClosingBracket(h[1],u);if(!o)return null;l=g.fromPoints(u,o),a||(l.end.column++,l.start.column--),l.cursor=l.end}else{var o=this.$findOpeningBracket(h[2],u);if(!o)return null;l=g.fromPoints(o,u),a||(l.start.column++,l.end.column--),l.cursor=l.start}return l},this.getMatchingBracketRanges=function(u,d){var a=this.getLine(u.row),l=/([\(\[\{])|([\)\]\}])/,c=!d&&a.charAt(u.column-1),h=c&&c.match(l);if(h||(c=(d===void 0||d)&&a.charAt(u.column),u={row:u.row,column:u.column+1},h=c&&c.match(l)),!h)return null;var o=new g(u.row,u.column-1,u.row,u.column),s=h[1]?this.$findClosingBracket(h[1],u):this.$findOpeningBracket(h[2],u);if(!s)return[o];var p=new g(s.row,s.column,s.row,s.column+1);return[o,p]},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(u,d,a){var l=this.$brackets[u],c=1,h=new f(this,d.row,d.column),o=h.getCurrentToken();if(o||(o=h.stepForward()),!!o){a||(a=new RegExp("(\\.?"+o.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)").replace(/-close\b/,"-(close|open)")+")+"));for(var s=d.column-h.getCurrentTokenColumn()-2,p=o.value;;){for(;s>=0;){var b=p.charAt(s);if(b==l){if(c-=1,c==0)return{row:h.getCurrentTokenRow(),column:s+h.getCurrentTokenColumn()}}else b==u&&(c+=1);s-=1}do o=h.stepBackward();while(o&&!a.test(o.type));if(o==null)break;p=o.value,s=p.length-1}return null}},this.$findClosingBracket=function(u,d,a){var l=this.$brackets[u],c=1,h=new f(this,d.row,d.column),o=h.getCurrentToken();if(o||(o=h.stepForward()),!!o){a||(a=new RegExp("(\\.?"+o.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)").replace(/-open\b/,"-(close|open)")+")+"));for(var s=d.column-h.getCurrentTokenColumn();;){for(var p=o.value,b=p.length;s<b;){var x=p.charAt(s);if(x==l){if(c-=1,c==0)return{row:h.getCurrentTokenRow(),column:s+h.getCurrentTokenColumn()}}else x==u&&(c+=1);s+=1}do o=h.stepForward();while(o&&!a.test(o.type));if(o==null)break;s=0}return null}},this.getMatchingTags=function(u){var d=new f(this,u.row,u.column),a=this.$findTagName(d);if(a){var l=d.stepBackward();return l.value==="<"?this.$findClosingTag(d,a):this.$findOpeningTag(d,a)}},this.$findTagName=function(u){var d=u.getCurrentToken(),a=!1,l=!1;if(d&&d.type.indexOf("tag-name")===-1)do l?d=u.stepBackward():d=u.stepForward(),d&&(d.value==="/>"?l=!0:d.type.indexOf("tag-name")!==-1&&(a=!0));while(d&&!a);return d},this.$findClosingTag=function(u,d){var a,l=d.value,c=d.value,h=0,o=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+1);d=u.stepForward();var s=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+d.value.length),p=!1;do{if(a=d,a.type.indexOf("tag-close")!==-1&&!p){var b=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+1);p=!0}if(d=u.stepForward(),d){if(d.value===">"&&!p){var b=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+1);p=!0}if(d.type.indexOf("tag-name")!==-1){if(l=d.value,c===l){if(a.value==="<")h++;else if(a.value==="</"&&(h--,h<0)){u.stepBackward();var x=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+2);d=u.stepForward();var M=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+d.value.length);if(d.type.indexOf("tag-close")===-1&&(d=u.stepForward()),d&&d.value===">")var R=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+1);else return}}}else if(c===l&&d.value==="/>"&&(h--,h<0))var x=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+2),M=x,R=M,b=new g(s.end.row,s.end.column,s.end.row,s.end.column+1)}}while(d&&h>=0);if(o&&b&&x&&R&&s&&M)return{openTag:new g(o.start.row,o.start.column,b.end.row,b.end.column),closeTag:new g(x.start.row,x.start.column,R.end.row,R.end.column),openTagName:s,closeTagName:M}},this.$findOpeningTag=function(u,d){var a=u.getCurrentToken(),l=d.value,c=0,h=u.getCurrentTokenRow(),o=u.getCurrentTokenColumn(),s=o+2,p=new g(h,o,h,s);u.stepForward();var b=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+d.value.length);if(d.type.indexOf("tag-close")===-1&&(d=u.stepForward()),!(!d||d.value!==">")){var x=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+1);u.stepBackward(),u.stepBackward();do if(d=a,h=u.getCurrentTokenRow(),o=u.getCurrentTokenColumn(),s=o+d.value.length,a=u.stepBackward(),d){if(d.type.indexOf("tag-name")!==-1){if(l===d.value)if(a.value==="<"){if(c++,c>0){var M=new g(h,o,h,s),R=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+1);do d=u.stepForward();while(d&&d.value!==">");var k=new g(u.getCurrentTokenRow(),u.getCurrentTokenColumn(),u.getCurrentTokenRow(),u.getCurrentTokenColumn()+1)}}else a.value==="</"&&c--}else if(d.value==="/>"){for(var C=0,L=a;L;){if(L.type.indexOf("tag-name")!==-1&&L.value===l){c--;break}else if(L.value==="<")break;L=u.stepBackward(),C++}for(var D=0;D<C;D++)u.stepForward()}}while(a&&c<=0);if(R&&k&&p&&x&&M&&b)return{openTag:new g(R.start.row,R.start.column,k.end.row,k.end.column),closeTag:new g(p.start.row,p.start.column,x.end.row,x.end.column),openTagName:M,closeTagName:b}}}}r.BracketMatch=w}),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(e,r,m){var f=e("./lib/oop"),g=e("./lib/lang"),w=e("./bidihandler").BidiHandler,u=e("./config"),d=e("./lib/event_emitter").EventEmitter,a=e("./selection").Selection,l=e("./mode/text").Mode,c=e("./range").Range,h=e("./line_widgets").LineWidgets,o=e("./document").Document,s=e("./background_tokenizer").BackgroundTokenizer,p=e("./search_highlight").SearchHighlight,b=e("./undomanager").UndoManager,x=(function(){function F(O,S){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"+ ++F.$uid,this.$foldData.toString=function(){return this.join(`
200
+ `)},this.$gutterCustomWidgets={},this.bgTokenizer=new s(new l().getTokenizer(),this);var A=this;this.bgTokenizer.on("update",function(N){A._signal("tokenizerUpdate",N)}),this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this),(typeof O!="object"||!O.getLine)&&(O=new o(O)),this.setDocument(O),this.selection=new a(this),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.selection.on("changeCursor",this.$onSelectionChange),this.$bidiHandler=new w(this),u.resetOptions(this),this.setMode(S),u._signal("session",this),this.destroyed=!1,this.$initOperationListeners()}return F.prototype.$initOperationListeners=function(){var O=this;this.curOp=null,this.on("change",function(){O.curOp||(O.startOperation(),O.curOp.selectionBefore=O.$lastSel),O.curOp.docChanged=!0},!0),this.on("changeSelection",function(){O.curOp||(O.startOperation(),O.curOp.selectionBefore=O.$lastSel),O.curOp.selectionChanged=!0},!0),this.$operationResetTimer=g.delayedCall(this.endOperation.bind(this,!0))},F.prototype.startOperation=function(O){if(this.curOp){if(!O||this.curOp.command)return;this.prevOp=this.curOp}O||(O={}),this.$operationResetTimer.schedule(),this.curOp={command:O.command||{},args:O.args},this.curOp.selectionBefore=this.selection.toJSON(),this._signal("startOperation",O)},F.prototype.endOperation=function(O){if(this.curOp){if(O&&O.returnValue===!1){this.curOp=null,this._signal("endOperation",O);return}if(O==!0&&this.curOp.command&&this.curOp.command.name=="mouse")return;var S=this.selection.toJSON();this.curOp.selectionAfter=S,this.$lastSel=this.selection.toJSON(),this.getUndoManager().addSelection(S),this._signal("beforeEndOperation"),this.prevOp=this.curOp,this.curOp=null,this._signal("endOperation",O)}},F.prototype.setDocument=function(O){this.doc&&this.doc.off("change",this.$onChange),this.doc=O,O.on("change",this.$onChange,!0),this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},F.prototype.getDocument=function(){return this.doc},Object.defineProperty(F.prototype,"widgetManager",{get:function(){var O=new h(this);return this.widgetManager=O,this.$editor&&O.attach(this.$editor),O},set:function(O){Object.defineProperty(this,"widgetManager",{writable:!0,enumerable:!0,configurable:!0,value:O})},enumerable:!1,configurable:!0}),F.prototype.$resetRowCache=function(O){if(!O){this.$docRowCache=[],this.$screenRowCache=[];return}var S=this.$docRowCache.length,A=this.$getRowCacheIndex(this.$docRowCache,O)+1;S>A&&(this.$docRowCache.splice(A,S),this.$screenRowCache.splice(A,S))},F.prototype.$getRowCacheIndex=function(O,S){for(var A=0,N=O.length-1;A<=N;){var B=A+N>>1,U=O[B];if(S>U)A=B+1;else if(S<U)N=B-1;else return B}return A-1},F.prototype.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.destroyed||this.bgTokenizer.start(0)},F.prototype.onChangeFold=function(O){var S=O.data;this.$resetRowCache(S.start.row)},F.prototype.onChange=function(O){this.$modified=!0,this.$bidiHandler.onChange(O),this.$resetRowCache(O.start.row);var S=this.$updateInternalDataOnChange(O);!this.$fromUndo&&this.$undoManager&&(S&&S.length&&(this.$undoManager.add({action:"removeFolds",folds:S},this.mergeUndoDeltas),this.mergeUndoDeltas=!0),this.$undoManager.add(O,this.mergeUndoDeltas),this.mergeUndoDeltas=!0,this.$informUndoManager.schedule()),this.bgTokenizer.$updateOnChange(O),this._signal("change",O)},F.prototype.onSelectionChange=function(){this._signal("changeSelection")},F.prototype.setValue=function(O){this.doc.setValue(O),this.selection.moveTo(0,0),this.$resetRowCache(0),this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},F.fromJSON=function(O){typeof O=="string"&&(O=JSON.parse(O));var S=new b;S.$undoStack=O.history.$undoStack,S.$redoStack=O.history.$redoStack,S.mark=O.history.mark,S.$rev=O.history.rev;var A=new F(O.value);return O.folds.forEach(function(N){A.addFold("...",c.fromPoints(N.start,N.end))}),A.setAnnotations(O.annotations),A.setBreakpoints(O.breakpoints),A.setMode(O.mode),A.setScrollLeft(O.scrollLeft),A.setScrollTop(O.scrollTop),A.setUndoManager(S),A.selection.fromJSON(O.selection),A},F.prototype.toJSON=function(){return{annotations:this.$annotations,breakpoints:this.$breakpoints,folds:this.getAllFolds().map(function(O){return O.range}),history:this.getUndoManager(),mode:this.$mode.$id,scrollLeft:this.$scrollLeft,scrollTop:this.$scrollTop,selection:this.selection.toJSON(),value:this.doc.getValue()}},F.prototype.toString=function(){return this.doc.getValue()},F.prototype.getSelection=function(){return this.selection},F.prototype.getState=function(O){return this.bgTokenizer.getState(O)},F.prototype.getTokens=function(O){return this.bgTokenizer.getTokens(O)},F.prototype.getTokenAt=function(O,S){var A=this.bgTokenizer.getTokens(O),N,B=0;if(S==null){var U=A.length-1;B=this.getLine(O).length}else for(var U=0;U<A.length&&(B+=A[U].value.length,!(B>=S));U++);return N=A[U],N?(N.index=U,N.start=B-N.value.length,N):null},F.prototype.setUndoManager=function(O){if(this.$undoManager=O,this.$informUndoManager&&this.$informUndoManager.cancel(),O){var S=this;O.addSession(this),this.$syncInformUndoManager=function(){S.$informUndoManager.cancel(),S.mergeUndoDeltas=!1},this.$informUndoManager=g.delayedCall(this.$syncInformUndoManager)}else this.$syncInformUndoManager=function(){}},F.prototype.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},F.prototype.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},F.prototype.getTabString=function(){return this.getUseSoftTabs()?g.stringRepeat(" ",this.getTabSize()):" "},F.prototype.setUseSoftTabs=function(O){this.setOption("useSoftTabs",O)},F.prototype.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},F.prototype.setTabSize=function(O){this.setOption("tabSize",O)},F.prototype.getTabSize=function(){return this.$tabSize},F.prototype.isTabStop=function(O){return this.$useSoftTabs&&O.column%this.$tabSize===0},F.prototype.setNavigateWithinSoftTabs=function(O){this.setOption("navigateWithinSoftTabs",O)},F.prototype.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},F.prototype.setOverwrite=function(O){this.setOption("overwrite",O)},F.prototype.getOverwrite=function(){return this.$overwrite},F.prototype.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},F.prototype.addGutterDecoration=function(O,S){this.$decorations[O]||(this.$decorations[O]=""),this.$decorations[O]+=" "+S,this._signal("changeBreakpoint",{})},F.prototype.removeGutterCustomWidget=function(O){this.$editor&&this.$editor.renderer.$gutterLayer.$removeCustomWidget(O)},F.prototype.addGutterCustomWidget=function(O,S){this.$editor&&this.$editor.renderer.$gutterLayer.$addCustomWidget(O,S)},F.prototype.removeGutterDecoration=function(O,S){this.$decorations[O]=(this.$decorations[O]||"").replace(" "+S,""),this._signal("changeBreakpoint",{})},F.prototype.getBreakpoints=function(){return this.$breakpoints},F.prototype.setBreakpoints=function(O){this.$breakpoints=[];for(var S=0;S<O.length;S++)this.$breakpoints[O[S]]="ace_breakpoint";this._signal("changeBreakpoint",{})},F.prototype.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},F.prototype.setBreakpoint=function(O,S){S===void 0&&(S="ace_breakpoint"),S?this.$breakpoints[O]=S:delete this.$breakpoints[O],this._signal("changeBreakpoint",{})},F.prototype.clearBreakpoint=function(O){delete this.$breakpoints[O],this._signal("changeBreakpoint",{})},F.prototype.addMarker=function(O,S,A,N){var B=this.$markerId++,U={range:O,type:A||"line",renderer:typeof A=="function"?A:null,clazz:S,inFront:!!N,id:B};return N?(this.$frontMarkers[B]=U,this._signal("changeFrontMarker")):(this.$backMarkers[B]=U,this._signal("changeBackMarker")),B},F.prototype.addDynamicMarker=function(O,S){if(O.update){var A=this.$markerId++;return O.id=A,O.inFront=!!S,S?(this.$frontMarkers[A]=O,this._signal("changeFrontMarker")):(this.$backMarkers[A]=O,this._signal("changeBackMarker")),O}},F.prototype.removeMarker=function(O){var S=this.$frontMarkers[O]||this.$backMarkers[O];if(S){var A=S.inFront?this.$frontMarkers:this.$backMarkers;delete A[O],this._signal(S.inFront?"changeFrontMarker":"changeBackMarker")}},F.prototype.getMarkers=function(O){return O?this.$frontMarkers:this.$backMarkers},F.prototype.highlight=function(O){if(!this.$searchHighlight){var S=new p(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker(S)}this.$searchHighlight.setRegexp(O)},F.prototype.highlightLines=function(O,S,A,N){typeof S!="number"&&(A=S,S=O),A||(A="ace_step");var B=new c(O,0,S,1/0);return B.id=this.addMarker(B,A,"fullLine",N),B},F.prototype.setAnnotations=function(O){this.$annotations=O,this._signal("changeAnnotation",{})},F.prototype.getAnnotations=function(){return this.$annotations||[]},F.prototype.clearAnnotations=function(){this.setAnnotations([])},F.prototype.$detectNewLine=function(O){var S=O.match(/^.*?(\r?\n)/m);S?this.$autoNewLine=S[1]:this.$autoNewLine=`
201
+ `},F.prototype.getWordRange=function(O,S){var A=this.getLine(O),N=!1;if(S>0&&(N=!!A.charAt(S-1).match(this.tokenRe)),N||(N=!!A.charAt(S).match(this.tokenRe)),N)var B=this.tokenRe;else if(/^\s+$/.test(A.slice(S-1,S+1)))var B=/\s/;else var B=this.nonTokenRe;var U=S;if(U>0){do U--;while(U>=0&&A.charAt(U).match(B));U++}for(var G=S;G<A.length&&A.charAt(G).match(B);)G++;return new c(O,U,O,G)},F.prototype.getAWordRange=function(O,S){for(var A=this.getWordRange(O,S),N=this.getLine(A.end.row);N.charAt(A.end.column).match(/[ \t]/);)A.end.column+=1;return A},F.prototype.setNewLineMode=function(O){this.doc.setNewLineMode(O)},F.prototype.getNewLineMode=function(){return this.doc.getNewLineMode()},F.prototype.setUseWorker=function(O){this.setOption("useWorker",O)},F.prototype.getUseWorker=function(){return this.$useWorker},F.prototype.onReloadTokenizer=function(O){var S=O.data;this.bgTokenizer.start(S.first),this._signal("tokenizerUpdate",O)},F.prototype.setMode=function(O,S){if(O&&typeof O=="object"){if(O.getTokenizer)return this.$onChangeMode(O);var A=O,N=A.path}else N=O||"ace/mode/text";if(this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new l),this.$modes[N]&&!A){this.$onChangeMode(this.$modes[N]),S&&S();return}this.$modeId=N,u.loadModule(["mode",N],(function(B){if(!this.destroyed){if(this.$modeId!==N)return S&&S();this.$modes[N]&&!A?this.$onChangeMode(this.$modes[N]):B&&B.Mode&&(B=new B.Mode(A),A||(this.$modes[N]=B,B.$id=N),this.$onChangeMode(B)),S&&S()}}).bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0)},F.prototype.$onChangeMode=function(O,S){if(S||(this.$modeId=O.$id),this.$mode!==O){var A=this.$mode;this.$mode=O,this.$stopWorker(),this.$useWorker&&this.$startWorker();var N=O.getTokenizer();if(N.on!==void 0){var B=this.onReloadTokenizer.bind(this);N.on("update",B)}this.bgTokenizer.setTokenizer(N),this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=O.tokenRe,this.nonTokenRe=O.nonTokenRe,S||(O.attachToSession&&O.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(O.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode",{oldMode:A,mode:O}))}},F.prototype.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},F.prototype.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(O){u.warn("Could not load worker",O),this.$worker=null}},F.prototype.getMode=function(){return this.$mode},F.prototype.setScrollTop=function(O){this.$scrollTop===O||isNaN(O)||(this.$scrollTop=O,this._signal("changeScrollTop",O))},F.prototype.getScrollTop=function(){return this.$scrollTop},F.prototype.setScrollLeft=function(O){this.$scrollLeft===O||isNaN(O)||(this.$scrollLeft=O,this._signal("changeScrollLeft",O))},F.prototype.getScrollLeft=function(){return this.$scrollLeft},F.prototype.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},F.prototype.getLineWidgetMaxWidth=function(){if(this.lineWidgetsWidth!=null)return this.lineWidgetsWidth;var O=0;return this.lineWidgets.forEach(function(S){S&&S.screenWidth>O&&(O=S.screenWidth)}),this.lineWidgetWidth=O},F.prototype.$computeWidth=function(O){if(this.$modified||O){if(this.$modified=!1,this.$useWrapMode)return this.screenWidth=this.$wrapLimit;for(var S=this.doc.getAllLines(),A=this.$rowLengthCache,N=0,B=0,U=this.$foldData[B],G=U?U.start.row:1/0,J=S.length,ne=0;ne<J;ne++){if(ne>G){if(ne=U.end.row+1,ne>=J)break;U=this.$foldData[B++],G=U?U.start.row:1/0}A[ne]==null&&(A[ne]=this.$getStringScreenWidth(S[ne])[0]),A[ne]>N&&(N=A[ne])}this.screenWidth=N}},F.prototype.getLine=function(O){return this.doc.getLine(O)},F.prototype.getLines=function(O,S){return this.doc.getLines(O,S)},F.prototype.getLength=function(){return this.doc.getLength()},F.prototype.getTextRange=function(O){return this.doc.getTextRange(O||this.selection.getRange())},F.prototype.insert=function(O,S){return this.doc.insert(O,S)},F.prototype.remove=function(O){return this.doc.remove(O)},F.prototype.removeFullLines=function(O,S){return this.doc.removeFullLines(O,S)},F.prototype.undoChanges=function(O,S){if(O.length){this.$fromUndo=!0;for(var A=O.length-1;A!=-1;A--){var N=O[A];N.action=="insert"||N.action=="remove"?this.doc.revertDelta(N):N.folds&&this.addFolds(N.folds)}!S&&this.$undoSelect&&(O.selectionBefore?this.selection.fromJSON(O.selectionBefore):this.selection.setRange(this.$getUndoSelection(O,!0))),this.$fromUndo=!1}},F.prototype.redoChanges=function(O,S){if(O.length){this.$fromUndo=!0;for(var A=0;A<O.length;A++){var N=O[A];(N.action=="insert"||N.action=="remove")&&this.doc.$safeApplyDelta(N)}!S&&this.$undoSelect&&(O.selectionAfter?this.selection.fromJSON(O.selectionAfter):this.selection.setRange(this.$getUndoSelection(O,!1))),this.$fromUndo=!1}},F.prototype.setUndoSelect=function(O){this.$undoSelect=O},F.prototype.$getUndoSelection=function(O,S){function A(J){return S?J.action!=="insert":J.action==="insert"}for(var N,B,U=0;U<O.length;U++){var G=O[U];if(G.start){if(!N){A(G)?N=c.fromPoints(G.start,G.end):N=c.fromPoints(G.start,G.start);continue}A(G)?(B=G.start,N.compare(B.row,B.column)==-1&&N.setStart(B),B=G.end,N.compare(B.row,B.column)==1&&N.setEnd(B)):(B=G.start,N.compare(B.row,B.column)==-1&&(N=c.fromPoints(G.start,G.start)))}}return N},F.prototype.replace=function(O,S){return this.doc.replace(O,S)},F.prototype.moveText=function(O,S,A){var N=this.getTextRange(O),B=this.getFoldsInRange(O),U=c.fromPoints(S,S);if(!A){this.remove(O);var G=O.start.row-O.end.row,J=G?-O.end.column:O.start.column-O.end.column;J&&(U.start.row==O.end.row&&U.start.column>O.end.column&&(U.start.column+=J),U.end.row==O.end.row&&U.end.column>O.end.column&&(U.end.column+=J)),G&&U.start.row>=O.end.row&&(U.start.row+=G,U.end.row+=G)}if(U.end=this.insert(U.start,N),B.length){var ne=O.start,de=U.start,G=de.row-ne.row,J=de.column-ne.column;this.addFolds(B.map(function(ce){return ce=ce.clone(),ce.start.row==ne.row&&(ce.start.column+=J),ce.end.row==ne.row&&(ce.end.column+=J),ce.start.row+=G,ce.end.row+=G,ce}))}return U},F.prototype.indentRows=function(O,S,A){A=A.replace(/\t/g,this.getTabString());for(var N=O;N<=S;N++)this.doc.insertInLine({row:N,column:0},A)},F.prototype.outdentRows=function(O){for(var S=O.collapseRows(),A=new c(0,0,0,0),N=this.getTabSize(),B=S.start.row;B<=S.end.row;++B){var U=this.getLine(B);A.start.row=B,A.end.row=B;for(var G=0;G<N&&U.charAt(G)==" ";++G);G<N&&U.charAt(G)==" "?(A.start.column=G,A.end.column=G+1):(A.start.column=0,A.end.column=G),this.remove(A)}},F.prototype.$moveLines=function(O,S,A){if(O=this.getRowFoldStart(O),S=this.getRowFoldEnd(S),A<0){var N=this.getRowFoldStart(O+A);if(N<0)return 0;var B=N-O}else if(A>0){var N=this.getRowFoldEnd(S+A);if(N>this.doc.getLength()-1)return 0;var B=N-S}else{O=this.$clipRowToDocument(O),S=this.$clipRowToDocument(S);var B=S-O+1}var U=new c(O,0,S,Number.MAX_VALUE),G=this.getFoldsInRange(U).map(function(ne){return ne=ne.clone(),ne.start.row+=B,ne.end.row+=B,ne}),J=A==0?this.doc.getLines(O,S):this.doc.removeFullLines(O,S);return this.doc.insertFullLines(O+B,J),G.length&&this.addFolds(G),B},F.prototype.moveLinesUp=function(O,S){return this.$moveLines(O,S,-1)},F.prototype.moveLinesDown=function(O,S){return this.$moveLines(O,S,1)},F.prototype.duplicateLines=function(O,S){return this.$moveLines(O,S,0)},F.prototype.$clipRowToDocument=function(O){return Math.max(0,Math.min(O,this.doc.getLength()-1))},F.prototype.$clipColumnToRow=function(O,S){return S<0?0:Math.min(this.doc.getLine(O).length,S)},F.prototype.$clipPositionToDocument=function(O,S){if(S=Math.max(0,S),O<0)O=0,S=0;else{var A=this.doc.getLength();O>=A?(O=A-1,S=this.doc.getLine(A-1).length):S=Math.min(this.doc.getLine(O).length,S)}return{row:O,column:S}},F.prototype.$clipRangeToDocument=function(O){O.start.row<0?(O.start.row=0,O.start.column=0):O.start.column=this.$clipColumnToRow(O.start.row,O.start.column);var S=this.doc.getLength()-1;return O.end.row>S?(O.end.row=S,O.end.column=this.doc.getLine(S).length):O.end.column=this.$clipColumnToRow(O.end.row,O.end.column),O},F.prototype.setUseWrapMode=function(O){if(O!=this.$useWrapMode){if(this.$useWrapMode=O,this.$modified=!0,this.$resetRowCache(0),O){var S=this.getLength();this.$wrapData=Array(S),this.$updateWrapData(0,S-1)}this._signal("changeWrapMode")}},F.prototype.getUseWrapMode=function(){return this.$useWrapMode},F.prototype.setWrapLimitRange=function(O,S){(this.$wrapLimitRange.min!==O||this.$wrapLimitRange.max!==S)&&(this.$wrapLimitRange={min:O,max:S},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode"))},F.prototype.adjustWrapLimit=function(O,S){var A=this.$wrapLimitRange;A.max<0&&(A={min:S,max:S});var N=this.$constrainWrapLimit(O,A.min,A.max);return N!=this.$wrapLimit&&N>1?(this.$wrapLimit=N,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0):!1},F.prototype.$constrainWrapLimit=function(O,S,A){return S&&(O=Math.max(S,O)),A&&(O=Math.min(A,O)),O},F.prototype.getWrapLimit=function(){return this.$wrapLimit},F.prototype.setWrapLimit=function(O){this.setWrapLimitRange(O,O)},F.prototype.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},F.prototype.$updateInternalDataOnChange=function(O){var S=this.$useWrapMode,A=O.action,N=O.start,B=O.end,U=N.row,G=B.row,J=G-U,ne=null;if(this.$updating=!0,J!=0)if(A==="remove"){this[S?"$wrapData":"$rowLengthCache"].splice(U,J);var de=this.$foldData;ne=this.getFoldsInRange(O),this.removeFolds(ne);var ee=this.getFoldLine(B.row),se=0;if(ee){ee.addRemoveChars(B.row,B.column,N.column-B.column),ee.shiftRow(-J);var ce=this.getFoldLine(U);ce&&ce!==ee&&(ce.merge(ee),ee=ce),se=de.indexOf(ee)+1}for(se;se<de.length;se++){var ee=de[se];ee.start.row>=B.row&&ee.shiftRow(-J)}G=U}else{var le=Array(J);le.unshift(U,0);var pe=S?this.$wrapData:this.$rowLengthCache;pe.splice.apply(pe,le);var de=this.$foldData,ee=this.getFoldLine(U),se=0;if(ee){var me=ee.range.compareInside(N.row,N.column);me==0?(ee=ee.split(N.row,N.column),ee&&(ee.shiftRow(J),ee.addRemoveChars(G,0,B.column-N.column))):me==-1&&(ee.addRemoveChars(U,0,B.column-N.column),ee.shiftRow(J)),se=de.indexOf(ee)+1}for(se;se<de.length;se++){var ee=de[se];ee.start.row>=U&&ee.shiftRow(J)}}else{J=Math.abs(O.start.column-O.end.column),A==="remove"&&(ne=this.getFoldsInRange(O),this.removeFolds(ne),J=-J);var ee=this.getFoldLine(U);ee&&ee.addRemoveChars(U,N.column,J)}return S&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,S?this.$updateWrapData(U,G):this.$updateRowLengthCache(U,G),ne},F.prototype.$updateRowLengthCache=function(O,S){this.$rowLengthCache[O]=null,this.$rowLengthCache[S]=null},F.prototype.$updateWrapData=function(O,S){var A=this.doc.getAllLines(),N=this.getTabSize(),B=this.$wrapData,U=this.$wrapLimit,G,J,ne=O;for(S=Math.min(S,A.length-1);ne<=S;)J=this.getFoldLine(ne,J),J?(G=[],J.walk((function(de,ee,se,ce){var le;if(de!=null){le=this.$getDisplayTokens(de,G.length),le[0]=k;for(var pe=1;pe<le.length;pe++)le[pe]=C}else le=this.$getDisplayTokens(A[ee].substring(ce,se),G.length);G=G.concat(le)}).bind(this),J.end.row,A[J.end.row].length+1),B[J.start.row]=this.$computeWrapSplits(G,U,N),ne=J.end.row+1):(G=this.$getDisplayTokens(A[ne]),B[ne]=this.$computeWrapSplits(G,U,N),ne++)},F.prototype.$computeWrapSplits=function(O,S,A){if(O.length==0)return[];var N=[],B=O.length,U=0,G=0,J=this.$wrapAsCode,ne=this.$indentedSoftWrap,de=S<=Math.max(2*A,8)||ne===!1?0:Math.floor(S/2);function ee(){var me=0;if(de===0)return me;if(ne)for(var $e=0;$e<O.length;$e++){var Ee=O[$e];if(Ee==D)me+=1;else if(Ee==I)me+=A;else{if(Ee==T)continue;break}}return J&&ne!==!1&&(me+=A),Math.min(me,de)}function se(me){for(var $e=me-U,Ee=U;Ee<me;Ee++){var He=O[Ee];(He===12||He===2)&&($e-=1)}N.length||(ce=ee(),N.indent=ce),G+=$e,N.push(G),U=me}for(var ce=0;B-U>S-ce;){var le=U+S-ce;if(O[le-1]>=D&&O[le]>=D){se(le);continue}if(O[le]==k||O[le]==C){for(le;le!=U-1&&O[le]!=k;le--);if(le>U){se(le);continue}for(le=U+S,le;le<O.length&&O[le]==C;le++);if(le==O.length)break;se(le);continue}for(var pe=Math.max(le-(S-(S>>2)),U-1);le>pe&&O[le]<k;)le--;if(J){for(;le>pe&&O[le]<k;)le--;for(;le>pe&&O[le]==L;)le--}else for(;le>pe&&O[le]<D;)le--;if(le>pe){se(++le);continue}le=U+S,O[le]==R&&le--,se(le-ce)}return N},F.prototype.$getDisplayTokens=function(O,S){var A=[],N;S=S||0;for(var B=0;B<O.length;B++){var U=O.charCodeAt(B);if(U==9){N=this.getScreenTabSize(A.length+S),A.push(I);for(var G=1;G<N;G++)A.push(T)}else U==32?A.push(D):U>39&&U<48||U>57&&U<64?A.push(L):U>=4352&&W(U)?A.push(M,R):A.push(M)}return A},F.prototype.$getStringScreenWidth=function(O,S,A){if(S==0)return[0,0];S==null&&(S=1/0),A=A||0;var N,B;for(B=0;B<O.length&&(N=O.charCodeAt(B),N==9?A+=this.getScreenTabSize(A):N>=4352&&W(N)?A+=2:A+=1,!(A>S));B++);return[A,B]},F.prototype.getRowLength=function(O){var S=1;return this.lineWidgets&&(S+=this.lineWidgets[O]&&this.lineWidgets[O].rowCount||0),!this.$useWrapMode||!this.$wrapData[O]?S:this.$wrapData[O].length+S},F.prototype.getRowLineCount=function(O){return!this.$useWrapMode||!this.$wrapData[O]?1:this.$wrapData[O].length+1},F.prototype.getRowWrapIndent=function(O){if(this.$useWrapMode){var S=this.screenToDocumentPosition(O,Number.MAX_VALUE),A=this.$wrapData[S.row];return A.length&&A[0]<S.column?A.indent:0}else return 0},F.prototype.getScreenLastRowColumn=function(O){var S=this.screenToDocumentPosition(O,Number.MAX_VALUE);return this.documentToScreenColumn(S.row,S.column)},F.prototype.getDocumentLastRowColumn=function(O,S){var A=this.documentToScreenRow(O,S);return this.getScreenLastRowColumn(A)},F.prototype.getDocumentLastRowColumnPosition=function(O,S){var A=this.documentToScreenRow(O,S);return this.screenToDocumentPosition(A,Number.MAX_VALUE/10)},F.prototype.getRowSplitData=function(O){if(this.$useWrapMode)return this.$wrapData[O]},F.prototype.getScreenTabSize=function(O){return this.$tabSize-(O%this.$tabSize|0)},F.prototype.screenToDocumentRow=function(O,S){return this.screenToDocumentPosition(O,S).row},F.prototype.screenToDocumentColumn=function(O,S){return this.screenToDocumentPosition(O,S).column},F.prototype.screenToDocumentPosition=function(O,S,A){if(O<0)return{row:0,column:0};var N,se=0,B=0,U,ee=0,G=0,J=this.$screenRowCache,ne=this.$getRowCacheIndex(J,O),de=J.length;if(de&&ne>=0)var ee=J[ne],se=this.$docRowCache[ne],ce=O>J[de-1];else var ce=!de;for(var le=this.getLength()-1,pe=this.getNextFoldLine(se),me=pe?pe.start.row:1/0;ee<=O&&(G=this.getRowLength(se),!(ee+G>O||se>=le));)ee+=G,se++,se>me&&(se=pe.end.row+1,pe=this.getNextFoldLine(se,pe),me=pe?pe.start.row:1/0),ce&&(this.$docRowCache.push(se),this.$screenRowCache.push(ee));if(pe&&pe.start.row<=se)N=this.getFoldDisplayLine(pe),se=pe.start.row;else{if(ee+G<=O||se>le)return{row:le,column:this.getLine(le).length};N=this.getLine(se),pe=null}var $e=0,Ee=Math.floor(O-ee);if(this.$useWrapMode){var He=this.$wrapData[se];He&&(U=He[Ee],Ee>0&&He.length&&($e=He.indent,B=He[Ee-1]||He[He.length-1],N=N.substring(B)))}return A!==void 0&&this.$bidiHandler.isBidiRow(ee+Ee,se,Ee)&&(S=this.$bidiHandler.offsetToCol(A)),B+=this.$getStringScreenWidth(N,S-$e)[1],this.$useWrapMode&&B>=U&&(B=U-1),pe?pe.idxToPosition(B):{row:se,column:B}},F.prototype.documentToScreenPosition=function(O,S){if(typeof S>"u")var A=this.$clipPositionToDocument(O.row,O.column);else A=this.$clipPositionToDocument(O,S);O=A.row,S=A.column;var ee=0,N=null,B=null;B=this.getFoldAt(O,S,1),B&&(O=B.start.row,S=B.start.column);var U,de=0,G=this.$docRowCache,J=this.$getRowCacheIndex(G,O),ne=G.length;if(ne&&J>=0)var de=G[J],ee=this.$screenRowCache[J],se=O>G[ne-1];else var se=!ne;for(var ce=this.getNextFoldLine(de),le=ce?ce.start.row:1/0;de<O;){if(de>=le){if(U=ce.end.row+1,U>O)break;ce=this.getNextFoldLine(U,ce),le=ce?ce.start.row:1/0}else U=de+1;ee+=this.getRowLength(de),de=U,se&&(this.$docRowCache.push(de),this.$screenRowCache.push(ee))}var pe="";ce&&de>=le?(pe=this.getFoldDisplayLine(ce,O,S),N=ce.start.row):(pe=this.getLine(O).substring(0,S),N=O);var me=0;if(this.$useWrapMode){var $e=this.$wrapData[N];if($e){for(var Ee=0;pe.length>=$e[Ee];)ee++,Ee++;pe=pe.substring($e[Ee-1]||0,pe.length),me=Ee>0?$e.indent:0}}return this.lineWidgets&&this.lineWidgets[de]&&this.lineWidgets[de].rowsAbove&&(ee+=this.lineWidgets[de].rowsAbove),{row:ee,column:me+this.$getStringScreenWidth(pe)[0]}},F.prototype.documentToScreenColumn=function(O,S){return this.documentToScreenPosition(O,S).column},F.prototype.documentToScreenRow=function(O,S){return this.documentToScreenPosition(O,S).row},F.prototype.getScreenLength=function(){var O=0,S=null;if(this.$useWrapMode)for(var A=this.$wrapData.length,N=0,B=0,S=this.$foldData[B++],U=S?S.start.row:1/0;N<A;){var G=this.$wrapData[N];O+=G?G.length+1:1,N++,N>U&&(N=S.end.row+1,S=this.$foldData[B++],U=S?S.start.row:1/0)}else{O=this.getLength();for(var J=this.$foldData,B=0;B<J.length;B++)S=J[B],O-=S.end.row-S.start.row}return this.lineWidgets&&(O+=this.$getWidgetScreenLength()),O},F.prototype.$setFontMetrics=function(O){this.$enableVarChar&&(this.$getStringScreenWidth=function(S,A,N){if(A===0)return[0,0];A||(A=1/0),N=N||0;var B,U;for(U=0;U<S.length&&(B=S.charAt(U),B===" "?N+=this.getScreenTabSize(N):N+=O.getCharacterWidth(B),!(N>A));U++);return[N,U]})},F.prototype.getPrecedingCharacter=function(){var O=this.selection.getCursor();if(O.column===0)return O.row===0?"":this.doc.getNewLineCharacter();var S=this.getLine(O.row);return S[O.column-1]},F.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()},F})();x.$uid=0,x.prototype.$modes=u.$modes,x.prototype.getValue=x.prototype.toString,x.prototype.$defaultUndoManager={undo:function(){},redo:function(){},hasUndo:function(){},hasRedo:function(){},reset:function(){},add:function(){},addSelection:function(){},startNewGroup:function(){},addSession:function(){}},x.prototype.$overwrite=!1,x.prototype.$mode=null,x.prototype.$modeId=null,x.prototype.$scrollTop=0,x.prototype.$scrollLeft=0,x.prototype.$wrapLimit=80,x.prototype.$useWrapMode=!1,x.prototype.$wrapLimitRange={min:null,max:null},x.prototype.lineWidgets=null,x.prototype.isFullWidth=W,f.implement(x.prototype,d);var M=1,R=2,k=3,C=4,L=9,D=10,I=11,T=12;function W(F){return F<4352?!1:F>=4352&&F<=4447||F>=4515&&F<=4519||F>=4602&&F<=4607||F>=9001&&F<=9002||F>=11904&&F<=11929||F>=11931&&F<=12019||F>=12032&&F<=12245||F>=12272&&F<=12283||F>=12288&&F<=12350||F>=12353&&F<=12438||F>=12441&&F<=12543||F>=12549&&F<=12589||F>=12593&&F<=12686||F>=12688&&F<=12730||F>=12736&&F<=12771||F>=12784&&F<=12830||F>=12832&&F<=12871||F>=12880&&F<=13054||F>=13056&&F<=19903||F>=19968&&F<=42124||F>=42128&&F<=42182||F>=43360&&F<=43388||F>=44032&&F<=55203||F>=55216&&F<=55238||F>=55243&&F<=55291||F>=63744&&F<=64255||F>=65040&&F<=65049||F>=65072&&F<=65106||F>=65108&&F<=65126||F>=65128&&F<=65131||F>=65281&&F<=65376||F>=65504&&F<=65510}e("./edit_session/folding").Folding.call(x.prototype),e("./edit_session/bracket_match").BracketMatch.call(x.prototype),u.defineOptions(x.prototype,"session",{wrap:{set:function(F){if(!F||F=="off"?F=!1:F=="free"?F=!0:F=="printMargin"?F=-1:typeof F=="string"&&(F=parseInt(F,10)||!1),this.$wrap!=F)if(this.$wrap=F,!F)this.setUseWrapMode(!1);else{var O=typeof F=="number"?F:null;this.setWrapLimitRange(O,O),this.setUseWrapMode(!0)}},get:function(){return this.getUseWrapMode()?this.$wrap==-1?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(F){F=F=="auto"?this.$mode.type!="text":F!="text",F!=this.$wrapAsCode&&(this.$wrapAsCode=F,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(F){this.$useWorker=F,this.$stopWorker(),F&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(F){F=parseInt(F),F>0&&this.$tabSize!==F&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=F,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(F){this.setFoldStyle(F)},handlesSet:!0},overwrite:{set:function(F){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(F){this.doc.setNewLineMode(F)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(F){this.setMode(F)},get:function(){return this.$modeId},handlesSet:!0}}),r.EditSession=x}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(e,r,m){var f=e("./lib/lang"),g=e("./lib/oop"),w=e("./range").Range,u=(function(){function c(){this.$options={}}return c.prototype.set=function(h){return g.mixin(this.$options,h),this},c.prototype.getOptions=function(){return f.copyObject(this.$options)},c.prototype.setOptions=function(h){this.$options=h},c.prototype.find=function(h){var o=this.$options,s=this.$matchIterator(h,o);if(!s)return!1;var p=null;return s.forEach(function(b,x,M,R){return p=new w(b,x,M,R),x==R&&o.start&&o.start.start&&o.skipCurrent!=!1&&p.isEqual(o.start)?(p=null,!1):!0}),p},c.prototype.findAll=function(h){var o=this.$options;if(!o.needle)return[];this.$assembleRegExp(o);var s=o.range,p=s?h.getLines(s.start.row,s.end.row):h.doc.getAllLines(),b=[],x=o.re;if(o.$isMultiLine){var M=x.length,R=p.length-M,k;e:for(var C=x.offset||0;C<=R;C++){for(var L=0;L<M;L++)if(p[C+L].search(x[L])==-1)continue e;var D=p[C],I=p[C+M-1],T=D.length-D.match(x[0])[0].length,W=I.match(x[M-1])[0].length;k&&k.end.row===C&&k.end.column>T||(b.push(k=new w(C,T,C+M-1,W)),M>2&&(C=C+M-2))}}else for(var F,O=0;O<p.length;O++)if(this.$isMultilineSearch(o)){var S=p.length-1;if(F=this.$multiLineForward(h,x,O,S),F){var A=F.endRow<=S?F.endRow-1:S;A>O&&(O=A),b.push(new w(F.startRow,F.startCol,F.endRow,F.endCol))}}else{F=f.getMatchOffsets(p[O],x);for(var L=0;L<F.length;L++){var N=F[L];b.push(new w(O,N.offset,O,N.offset+N.length))}}if(s){for(var B=s.start.column,U=s.end.column,O=0,L=b.length-1;O<L&&b[O].start.column<B&&b[O].start.row==0;)O++;for(var G=s.end.row-s.start.row;O<L&&b[L].end.column>U&&b[L].end.row==G;)L--;for(b=b.slice(O,L+1),O=0,L=b.length;O<L;O++)b[O].start.row+=s.start.row,b[O].end.row+=s.start.row}return b},c.prototype.parseReplaceString=function(h){for(var o={DollarSign:36,Ampersand:38,Digit0:48,Digit1:49,Digit9:57,Backslash:92,n:110,t:116},s="",p=0,b=h.length;p<b;p++){var x=h.charCodeAt(p);if(x===o.Backslash){if(p++,p>=b){s+="\\";break}var M=h.charCodeAt(p);switch(M){case o.Backslash:s+="\\";break;case o.n:s+=`
202
+ `;break;case o.t:s+=" ";break}continue}if(x===o.DollarSign){if(p++,p>=b){s+="$";break}var R=h.charCodeAt(p);if(R===o.DollarSign){s+="$$";continue}if(R===o.Digit0||R===o.Ampersand){s+="$&";continue}if(o.Digit1<=R&&R<=o.Digit9){s+="$"+h[p];continue}}s+=h[p]}return s||h},c.prototype.replace=function(h,o){var s=this.$options,p=this.$assembleRegExp(s);if(s.$isMultiLine)return o;if(p){var b=this.$isMultilineSearch(s);b&&(h=h.replace(/\r\n|\r|\n/g,`
203
+ `));var x=p.exec(h);if(!x||!b&&x[0].length!=h.length)return null;if(o=s.regExp?this.parseReplaceString(o):o.replace(/\$/g,"$$$$"),o=h.replace(p,o),s.preserveCase){o=o.split("");for(var M=Math.min(h.length,h.length);M--;){var R=h[M];R&&R.toLowerCase()!=R?o[M]=o[M].toUpperCase():o[M]=o[M].toLowerCase()}o=o.join("")}return o}},c.prototype.$assembleRegExp=function(h,o){if(h.needle instanceof RegExp)return h.re=h.needle;var s=h.needle;if(!h.needle)return h.re=!1;h.regExp||(s=f.escapeRegExp(s));var p=h.caseSensitive?"gm":"gmi";try{new RegExp(s,"u"),h.$supportsUnicodeFlag=!0,p+="u"}catch{h.$supportsUnicodeFlag=!1}if(h.wholeWord&&(s=d(s,h)),h.$isMultiLine=!o&&/[\n\r]/.test(s),h.$isMultiLine)return h.re=this.$assembleMultilineRegExp(s,p);try{var b=new RegExp(s,p)}catch{b=!1}return h.re=b},c.prototype.$assembleMultilineRegExp=function(h,o){for(var s=h.replace(/\r\n|\r|\n/g,`$
204
+ ^`).split(`
205
+ `),p=[],b=0;b<s.length;b++)try{p.push(new RegExp(s[b],o))}catch{return!1}return p},c.prototype.$isMultilineSearch=function(h){return h.re&&/\\r\\n|\\r|\\n/.test(h.re.source)&&h.regExp&&!h.$isMultiLine},c.prototype.$multiLineForward=function(h,o,s,p){for(var b,x=l(h,s),M=s;M<=p;){for(var R=0;R<x&&!(M>p);R++){var k=h.getLine(M++);b=b==null?k:b+`
206
+ `+k}var C=o.exec(b);if(o.lastIndex=0,C){var L=b.slice(0,C.index).split(`
207
+ `),D=C[0].split(`
208
+ `),I=s+L.length-1,T=L[L.length-1].length,W=I+D.length-1,F=D.length==1?T+D[0].length:D[D.length-1].length;return{startRow:I,startCol:T,endRow:W,endCol:F}}}return null},c.prototype.$multiLineBackward=function(h,o,s,p,b){for(var x,M=l(h,p),R=h.getLine(p).length-s,k=p;k>=b;){for(var C=0;C<M&&k>=b;C++){var L=h.getLine(k--);x=x==null?L:L+`
209
+ `+x}var D=a(x,o,R);if(D){var I=x.slice(0,D.index).split(`
210
+ `),T=D[0].split(`
211
+ `),W=k+I.length,F=I[I.length-1].length,O=W+T.length-1,S=T.length==1?F+T[0].length:T[T.length-1].length;return{startRow:W,startCol:F,endRow:O,endCol:S}}}return null},c.prototype.$matchIterator=function(h,o){var s=this.$assembleRegExp(o);if(!s)return!1;var p=this.$isMultilineSearch(o),b=this.$multiLineForward,x=this.$multiLineBackward,M=o.backwards==!0,R=o.skipCurrent!=!1,k=s.unicode,C=o.range,L=o.start;L||(L=C?C[M?"end":"start"]:h.selection.getRange()),L.start&&(L=L[R!=M?"end":"start"]);var D=C?C.start.row:0,I=C?C.end.row:h.getLength()-1;if(M)var T=function(O){var S=L.row;if(!F(S,L.column,O)){for(S--;S>=D;S--)if(F(S,Number.MAX_VALUE,O))return;if(o.wrap!=!1){for(S=I,D=L.row;S>=D;S--)if(F(S,Number.MAX_VALUE,O))return}}};else var T=function(O){var S=L.row;if(!F(S,L.column,O)){for(S=S+1;S<=I;S++)if(F(S,0,O))return;if(o.wrap!=!1){for(S=D,I=L.row;S<=I;S++)if(F(S,0,O))return}}};if(o.$isMultiLine)var W=s.length,F=function(O,S,A){var N=M?O-W+1:O;if(!(N<0||N+W>h.getLength())){var B=h.getLine(N),U=B.search(s[0]);if(!(!M&&U<S||U===-1)){for(var G=1;G<W;G++)if(B=h.getLine(N+G),B.search(s[G])==-1)return;var J=B.match(s[W-1])[0].length;if(!(M&&J>S)&&A(N,U,N+W-1,J))return!0}}};else if(M)var F=function(O,S,A){if(p){var N=x(h,s,S,O,D);if(!N)return!1;if(A(N.startRow,N.startCol,N.endRow,N.endCol))return!0}else{var B=h.getLine(O),U=[],G,J=0;for(s.lastIndex=0;G=s.exec(B);){var ne=G[0].length;if(J=G.index,!ne){if(J>=B.length)break;s.lastIndex=J+=f.skipEmptyMatch(B,J,k)}if(G.index+ne>S)break;U.push(G.index,ne)}for(var de=U.length-1;de>=0;de-=2){var ee=U[de-1],ne=U[de];if(A(O,ee,O,ee+ne))return!0}}};else var F=function(O,S,A){if(s.lastIndex=S,p){var N=b(h,s,O,I);if(N){var B=N.endRow<=I?N.endRow-1:I;B>O&&(O=B)}if(!N)return!1;if(A(N.startRow,N.startCol,N.endRow,N.endCol))return!0}else for(var U=h.getLine(O),G,J;J=s.exec(U);){var ne=J[0].length;if(G=J.index,A(O,G,O,G+ne))return!0;if(!ne&&(s.lastIndex=G+=f.skipEmptyMatch(U,G,k),G>=U.length))return!1}};return{forEach:T}},c})();function d(c,h){var o=f.supportsLookbehind();function s(M,R){R===void 0&&(R=!0);var k=o&&h.$supportsUnicodeFlag?new RegExp("[\\p{L}\\p{N}_]","u"):new RegExp("\\w");return k.test(M)||h.regExp?o&&h.$supportsUnicodeFlag?R?"(?<=^|[^\\p{L}\\p{N}_])":"(?=[^\\p{L}\\p{N}_]|$)":"\\b":""}var p=Array.from(c),b=p[0],x=p[p.length-1];return s(b)+c+s(x,!1)}function a(c,h,o){for(var s=null,p=0;p<=c.length;){h.lastIndex=p;var b=h.exec(c);if(!b)break;var x=b.index+b[0].length;if(x>c.length-o)break;(!s||x>s.index+s[0].length)&&(s=b),p=b.index+1}return s}function l(c,h){var o=5e3,s={row:h,column:0},p=c.doc.positionToIndex(s),b=p+o,x=c.doc.indexToPosition(b),M=x.row;return M+1}r.Search=u}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,r,m){var f=this&&this.__extends||(function(){var c=function(h,o){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,p){s.__proto__=p}||function(s,p){for(var b in p)Object.prototype.hasOwnProperty.call(p,b)&&(s[b]=p[b])},c(h,o)};return function(h,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");c(h,o);function s(){this.constructor=h}h.prototype=o===null?Object.create(o):(s.prototype=o.prototype,new s)}})(),g=e("../lib/keys"),w=e("../lib/useragent"),u=g.KEY_MODS,d=(function(){function c(h,o){this.$init(h,o,!1)}return c.prototype.$init=function(h,o,s){this.platform=o||(w.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(h),this.$singleCommand=s},c.prototype.addCommand=function(h){this.commands[h.name]&&this.removeCommand(h),this.commands[h.name]=h,h.bindKey&&this._buildKeyHash(h)},c.prototype.removeCommand=function(h,o){var s=h&&(typeof h=="string"?h:h.name);h=this.commands[s],o||delete this.commands[s];var p=this.commandKeyBinding;for(var b in p){var x=p[b];if(x==h)delete p[b];else if(Array.isArray(x)){var M=x.indexOf(h);M!=-1&&(x.splice(M,1),x.length==1&&(p[b]=x[0]))}}},c.prototype.bindKey=function(h,o,s){if(typeof h=="object"&&h&&(s==null&&(s=h.position),h=h[this.platform]),!!h){if(typeof o=="function")return this.addCommand({exec:o,bindKey:h,name:o.name||h});h.split("|").forEach(function(p){var b="";if(p.indexOf(" ")!=-1){var x=p.split(/\s+/);p=x.pop(),x.forEach(function(k){var C=this.parseKeys(k),L=u[C.hashId]+C.key;b+=(b?" ":"")+L,this._addCommandToBinding(b,"chainKeys")},this),b+=" "}var M=this.parseKeys(p),R=u[M.hashId]+M.key;this._addCommandToBinding(b+R,o,s)},this)}},c.prototype._addCommandToBinding=function(h,o,s){var p=this.commandKeyBinding,b;if(!o)delete p[h];else if(!p[h]||this.$singleCommand)p[h]=o;else{Array.isArray(p[h])?(b=p[h].indexOf(o))!=-1&&p[h].splice(b,1):p[h]=[p[h]],typeof s!="number"&&(s=a(o));var x=p[h];for(b=0;b<x.length;b++){var M=x[b],R=a(M);if(R>s)break}x.splice(b,0,o)}},c.prototype.addCommands=function(h){h&&Object.keys(h).forEach(function(o){var s=h[o];if(s){if(typeof s=="string")return this.bindKey(s,o);typeof s=="function"&&(s={exec:s}),typeof s=="object"&&(s.name||(s.name=o),this.addCommand(s))}},this)},c.prototype.removeCommands=function(h){Object.keys(h).forEach(function(o){this.removeCommand(h[o])},this)},c.prototype.bindKeys=function(h){Object.keys(h).forEach(function(o){this.bindKey(o,h[o])},this)},c.prototype._buildKeyHash=function(h){this.bindKey(h.bindKey,h)},c.prototype.parseKeys=function(h){var o=h.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(R){return R}),s=o.pop(),p=g[s];if(g.FUNCTION_KEYS[p])s=g.FUNCTION_KEYS[p].toLowerCase();else if(o.length){if(o.length==1&&o[0]=="shift")return{key:s.toUpperCase(),hashId:-1}}else return{key:s,hashId:-1};for(var b=0,x=o.length;x--;){var M=g.KEY_MODS[o[x]];if(M==null)return typeof console<"u"&&console.error("invalid modifier "+o[x]+" in "+h),!1;b|=M}return{key:s,hashId:b}},c.prototype.findKeyCommand=function(h,o){var s=u[h]+o;return this.commandKeyBinding[s]},c.prototype.handleKeyboard=function(h,o,s,p){if(!(p<0)){var b=u[o]+s,x=this.commandKeyBinding[b];return h.$keyChain&&(h.$keyChain+=" "+b,x=this.commandKeyBinding[h.$keyChain]||x),x&&(x=="chainKeys"||x[x.length-1]=="chainKeys")?(h.$keyChain=h.$keyChain||b,{command:"null"}):(h.$keyChain&&((!o||o==4)&&s.length==1?h.$keyChain=h.$keyChain.slice(0,-b.length-1):(o==-1||p>0)&&(h.$keyChain="")),{command:x})}},c.prototype.getStatusText=function(h,o){return o.$keyChain||""},c})();function a(c){return typeof c=="object"&&c.bindKey&&c.bindKey.position||(c.isDefault?-100:0)}var l=(function(c){f(h,c);function h(o,s){var p=c.call(this,o,s)||this;return p.$singleCommand=!0,p}return h})(d);l.call=function(c,h,o){d.prototype.$init.call(c,h,o,!0)},d.call=function(c,h,o){d.prototype.$init.call(c,h,o,!1)},r.HashHandler=l,r.MultiHashHandler=d}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(e,r,m){var f=this&&this.__extends||(function(){var a=function(l,c){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,o){h.__proto__=o}||function(h,o){for(var s in o)Object.prototype.hasOwnProperty.call(o,s)&&(h[s]=o[s])},a(l,c)};return function(l,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");a(l,c);function h(){this.constructor=l}l.prototype=c===null?Object.create(c):(h.prototype=c.prototype,new h)}})(),g=e("../lib/oop"),w=e("../keyboard/hash_handler").MultiHashHandler,u=e("../lib/event_emitter").EventEmitter,d=(function(a){f(l,a);function l(c,h){var o=a.call(this,h,c)||this;return o.byName=o.commands,o.setDefaultHandler("exec",function(s){return s.args?s.command.exec(s.editor,s.args,s.event,!1):s.command.exec(s.editor,{},s.event,!0)}),o}return l.prototype.exec=function(c,h,o){if(Array.isArray(c)){for(var s=c.length;s--;)if(this.exec(c[s],h,o))return!0;return!1}typeof c=="string"&&(c=this.commands[c]);var p={editor:h,command:c,args:o};return this.canExecute(c,h)?(p.returnValue=this._emit("exec",p),this._signal("afterExec",p),p.returnValue!==!1):(this._signal("commandUnavailable",p),!1)},l.prototype.canExecute=function(c,h){return typeof c=="string"&&(c=this.commands[c]),!(!c||h&&h.$readOnly&&!c.readOnly||this.$checkCommandState!=!1&&c.isAvailable&&!c.isAvailable(h))},l.prototype.toggleRecording=function(c){if(!this.$inReplay)return c&&c._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(h){this.macro.push([h.command,h.args])}).bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},l.prototype.replay=function(c){if(!(this.$inReplay||!this.macro)){if(this.recording)return this.toggleRecording(c);try{this.$inReplay=!0,this.macro.forEach(function(h){typeof h=="string"?this.exec(h,c):this.exec(h[0],c,h[1])},this)}finally{this.$inReplay=!1}}},l.prototype.trimMacro=function(c){return c.map(function(h){return typeof h[0]!="string"&&(h[0]=h[0].name),h[1]||(h=h[0]),h})},l})(w);g.implement(d.prototype,u),r.CommandManager=d}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(e,r,m){var f=e("../lib/lang"),g=e("../config"),w=e("../range").Range;function u(a,l){return{win:a,mac:l}}r.commands=[{name:"showSettingsMenu",description:"Show settings menu",bindKey:u("Ctrl-,","Command-,"),exec:function(a){g.loadModule("ace/ext/settings_menu",function(l){l.init(a),a.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",description:"Go to next error",bindKey:u("Alt-E","F4"),exec:function(a){g.loadModule("ace/ext/error_marker",function(l){l.showErrorMarker(a,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",description:"Go to previous error",bindKey:u("Alt-Shift-E","Shift-F4"),exec:function(a){g.loadModule("ace/ext/error_marker",function(l){l.showErrorMarker(a,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",description:"Select all",bindKey:u("Ctrl-A","Command-A"),exec:function(a){a.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:u(null,"Ctrl-L"),exec:function(a){a.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:u("Ctrl-L","Command-L"),exec:function(a,l){typeof l=="number"&&!isNaN(l)&&a.gotoLine(l),a.prompt({$type:"gotoLine"})},readOnly:!0},{name:"fold",bindKey:u("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(a){a.session.toggleFold(!1)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:u("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(a){a.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",description:"Toggle fold widget",bindKey:u("F2","F2"),exec:function(a){a.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",description:"Toggle parent fold widget",bindKey:u("Alt-F2","Alt-F2"),exec:function(a){a.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:u(null,"Ctrl-Command-Option-0"),exec:function(a){a.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:u(null,"Ctrl-Command-Option-0"),exec:function(a){a.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:u("Alt-0","Command-Option-0"),exec:function(a){a.session.foldAll(),a.session.unfold(a.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",description:"Unfold all",bindKey:u("Alt-Shift-0","Command-Option-Shift-0"),exec:function(a){a.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:u("Ctrl-K","Command-G"),exec:function(a){a.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:u("Ctrl-Shift-K","Command-Shift-G"),exec:function(a){a.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",description:"Select or find next",bindKey:u("Alt-K","Ctrl-G"),exec:function(a){a.selection.isEmpty()?a.selection.selectWord():a.findNext()},readOnly:!0},{name:"selectOrFindPrevious",description:"Select or find previous",bindKey:u("Alt-Shift-K","Ctrl-Shift-G"),exec:function(a){a.selection.isEmpty()?a.selection.selectWord():a.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:u("Ctrl-F","Command-F"),exec:function(a){g.loadModule("ace/ext/searchbox",function(l){l.Search(a)})},readOnly:!0},{name:"overwrite",description:"Overwrite",bindKey:"Insert",exec:function(a){a.toggleOverwrite()},readOnly:!0},{name:"selecttostart",description:"Select to start",bindKey:u("Ctrl-Shift-Home","Command-Shift-Home|Command-Shift-Up"),exec:function(a){a.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",description:"Go to start",bindKey:u("Ctrl-Home","Command-Home|Command-Up"),exec:function(a){a.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",description:"Select up",bindKey:u("Shift-Up","Shift-Up|Ctrl-Shift-P"),exec:function(a){a.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",description:"Go line up",bindKey:u("Up","Up|Ctrl-P"),exec:function(a,l){a.navigateUp(l.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",description:"Select to end",bindKey:u("Ctrl-Shift-End","Command-Shift-End|Command-Shift-Down"),exec:function(a){a.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",description:"Go to end",bindKey:u("Ctrl-End","Command-End|Command-Down"),exec:function(a){a.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",description:"Select down",bindKey:u("Shift-Down","Shift-Down|Ctrl-Shift-N"),exec:function(a){a.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",description:"Go line down",bindKey:u("Down","Down|Ctrl-N"),exec:function(a,l){a.navigateDown(l.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",description:"Select word left",bindKey:u("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(a){a.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",description:"Go to word left",bindKey:u("Ctrl-Left","Option-Left"),exec:function(a){a.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",description:"Select to line start",bindKey:u("Alt-Shift-Left","Command-Shift-Left|Ctrl-Shift-A"),exec:function(a){a.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",description:"Go to line start",bindKey:u("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(a){a.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",description:"Select left",bindKey:u("Shift-Left","Shift-Left|Ctrl-Shift-B"),exec:function(a){a.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",description:"Go to left",bindKey:u("Left","Left|Ctrl-B"),exec:function(a,l){a.navigateLeft(l.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",description:"Select word right",bindKey:u("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(a){a.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",description:"Go to word right",bindKey:u("Ctrl-Right","Option-Right"),exec:function(a){a.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",description:"Select to line end",bindKey:u("Alt-Shift-Right","Command-Shift-Right|Shift-End|Ctrl-Shift-E"),exec:function(a){a.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",description:"Go to line end",bindKey:u("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(a){a.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",description:"Select right",bindKey:u("Shift-Right","Shift-Right"),exec:function(a){a.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:u("Right","Right|Ctrl-F"),exec:function(a,l){a.navigateRight(l.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",description:"Select page down",bindKey:"Shift-PageDown",exec:function(a){a.selectPageDown()},readOnly:!0},{name:"pagedown",description:"Page down",bindKey:u(null,"Option-PageDown"),exec:function(a){a.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:u("PageDown","PageDown|Ctrl-V"),exec:function(a){a.gotoPageDown()},readOnly:!0},{name:"selectpageup",description:"Select page up",bindKey:"Shift-PageUp",exec:function(a){a.selectPageUp()},readOnly:!0},{name:"pageup",description:"Page up",bindKey:u(null,"Option-PageUp"),exec:function(a){a.scrollPageUp()},readOnly:!0},{name:"gotopageup",description:"Go to page up",bindKey:"PageUp",exec:function(a){a.gotoPageUp()},readOnly:!0},{name:"scrollup",description:"Scroll up",bindKey:u("Ctrl-Up",null),exec:function(a){a.renderer.scrollBy(0,-2*a.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:u("Ctrl-Down",null),exec:function(a){a.renderer.scrollBy(0,2*a.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",description:"Select line start",bindKey:"Shift-Home",exec:function(a){a.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",description:"Select line end",bindKey:"Shift-End",exec:function(a){a.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",description:"Toggle recording",bindKey:u("Ctrl-Alt-E","Command-Option-E"),exec:function(a){a.commands.toggleRecording(a)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:u("Ctrl-Shift-E","Command-Shift-E"),exec:function(a){a.commands.replay(a)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:u("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(a){a.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:u("Ctrl-Shift-\\|Ctrl-Shift-P","Command-Shift-\\"),exec:function(a){a.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",description:"Expand to matching",bindKey:u("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(a){a.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",description:"Pass keys to browser",bindKey:u(null,null),exec:function(){},passEvent:!0,readOnly:!0},{name:"copy",description:"Copy",exec:function(a){},readOnly:!0},{name:"cut",description:"Cut",exec:function(a){var l=a.$copyWithEmptySelection&&a.selection.isEmpty(),c=l?a.selection.getLineRange():a.selection.getRange();a._emit("cut",c),c.isEmpty()||a.session.remove(c),a.clearSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",description:"Paste",exec:function(a,l){a.$handlePaste(l)},scrollIntoView:"cursor"},{name:"removeline",description:"Remove line",bindKey:u("Ctrl-D","Command-D"),exec:function(a){a.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:u("Ctrl-Shift-D","Command-Shift-D"),exec:function(a){a.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:u("Ctrl-Alt-S","Command-Alt-S"),exec:function(a){a.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:u("Ctrl-/","Command-/"),exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:u("Ctrl-Shift-/","Command-Shift-/"),exec:function(a){a.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:u("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(a){a.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:u("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(a){a.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:u("Ctrl-H","Command-Option-F"),exec:function(a){g.loadModule("ace/ext/searchbox",function(l){l.Search(a,!0)})}},{name:"undo",description:"Undo",bindKey:u("Ctrl-Z","Command-Z"),exec:function(a){a.undo()}},{name:"redo",description:"Redo",bindKey:u("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(a){a.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:u("Alt-Shift-Up","Command-Option-Up"),exec:function(a){a.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:u("Alt-Up","Option-Up"),exec:function(a){a.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:u("Alt-Shift-Down","Command-Option-Down"),exec:function(a){a.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:u("Alt-Down","Option-Down"),exec:function(a){a.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:u("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(a){a.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:u("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(a){a.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",description:"Cut or delete",bindKey:u("Shift-Delete",null),exec:function(a){if(a.selection.isEmpty())a.remove("left");else return!1},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",description:"Remove to line start",bindKey:u("Alt-Backspace","Command-Backspace"),exec:function(a){a.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:u("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(a){a.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:u("Ctrl-Shift-Backspace",null),exec:function(a){var l=a.selection.getRange();l.start.column=0,a.session.remove(l)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineendhard",description:"Remove to line end hard",bindKey:u("Ctrl-Shift-Delete",null),exec:function(a){var l=a.selection.getRange();l.end.column=Number.MAX_VALUE,a.session.remove(l)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",description:"Remove word left",bindKey:u("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(a){a.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:u("Ctrl-Delete","Alt-Delete"),exec:function(a){a.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:u("Shift-Tab","Shift-Tab"),exec:function(a){a.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:u("Tab","Tab"),exec:function(a){a.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:u("Ctrl-[","Ctrl-["),exec:function(a){a.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:u("Ctrl-]","Ctrl-]"),exec:function(a){a.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",description:"Insert string",exec:function(a,l){a.insert(l)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",description:"Insert text",exec:function(a,l){a.insert(f.stringRepeat(l.text||"",l.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:u(null,"Ctrl-O"),exec:function(a){a.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:u("Alt-Shift-X","Ctrl-T"),exec:function(a){a.transposeLetters()},multiSelectAction:function(a){a.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:u("Ctrl-U","Ctrl-U"),exec:function(a){a.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:u("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(a){a.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:u(null,null),exec:function(a){a.autoIndent()},scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:u("Ctrl-Shift-L","Command-Shift-L"),exec:function(a){var l=a.selection.getRange();l.start.column=l.end.column=0,l.end.row++,a.selection.setRange(l,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"openlink",bindKey:u("Ctrl+F3","F3"),exec:function(a){a.openLink()}},{name:"joinlines",description:"Join lines",bindKey:u(null,null),exec:function(a){for(var l=a.selection.isBackwards(),c=l?a.selection.getSelectionLead():a.selection.getSelectionAnchor(),h=l?a.selection.getSelectionAnchor():a.selection.getSelectionLead(),o=a.session.doc.getLine(c.row).length,s=a.session.doc.getTextRange(a.selection.getRange()),p=s.replace(/\n\s*/," ").length,b=a.session.doc.getLine(c.row),x=c.row+1;x<=h.row+1;x++){var M=f.stringTrimLeft(f.stringTrimRight(a.session.doc.getLine(x)));M.length!==0&&(M=" "+M),b+=M}h.row+1<a.session.doc.getLength()-1&&(b+=a.session.doc.getNewLineCharacter()),a.clearSelection(),a.session.doc.replace(new w(c.row,0,h.row+2,0),b),p>0?(a.selection.moveCursorTo(c.row,c.column),a.selection.selectTo(c.row,c.column+p)):(o=a.session.doc.getLine(c.row).length>o?o+1:o,a.selection.moveCursorTo(c.row,o))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:u(null,null),exec:function(a){var l=a.session.doc.getLength()-1,c=a.session.doc.getLine(l).length,h=a.selection.rangeList.ranges,o=[];h.length<1&&(h=[a.selection.getRange()]);for(var s=0;s<h.length;s++)s==h.length-1&&(h[s].end.row===l&&h[s].end.column===c||o.push(new w(h[s].end.row,h[s].end.column,l,c))),s===0?h[s].start.row===0&&h[s].start.column===0||o.push(new w(0,0,h[s].start.row,h[s].start.column)):o.push(new w(h[s-1].end.row,h[s-1].end.column,h[s].start.row,h[s].start.column));a.exitMultiSelectMode(),a.clearSelection();for(var s=0;s<o.length;s++)a.selection.addRange(o[s],!1)},readOnly:!0,scrollIntoView:"none"},{name:"addLineAfter",description:"Add new line after the current line",exec:function(a){a.selection.clearSelection(),a.navigateLineEnd(),a.insert(`
212
+ `)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"addLineBefore",description:"Add new line before the current line",exec:function(a){a.selection.clearSelection();var l=a.getCursorPosition();a.selection.moveTo(l.row-1,Number.MAX_VALUE),a.insert(`
213
+ `),l.row===0&&a.navigateUp()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"openCommandPallete",exec:function(a){console.warn("This is an obsolete command. Please use `openCommandPalette` instead."),a.prompt({$type:"commands"})},readOnly:!0},{name:"openCommandPalette",description:"Open command palette",bindKey:u("F1","F1"),exec:function(a){a.prompt({$type:"commands"})},readOnly:!0},{name:"modeSelect",description:"Change language mode...",bindKey:u(null,null),exec:function(a){a.prompt({$type:"modes"})},readOnly:!0}];for(var d=1;d<9;d++)r.commands.push({name:"foldToLevel"+d,description:"Fold To Level "+d,level:d,exec:function(a){a.session.foldToLevel(this.level)},scrollIntoView:"center",readOnly:!0})}),ace.define("ace/keyboard/gutter_handler",["require","exports","module","ace/lib/keys"],function(e,r,m){var f=e("../lib/keys"),g=(function(){function u(d){this.editor=d,this.gutterLayer=d.renderer.$gutterLayer,this.element=d.renderer.$gutter,this.lines=d.renderer.$gutterLayer.$lines,this.activeRowIndex=null,this.activeLane=null,this.annotationTooltip=this.editor.$mouseHandler.$tooltip}return u.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))},u.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))},u.prototype.$onGutterKeyDown=function(d){if(this.annotationTooltip.isOpen){d.preventDefault(),d.keyCode===f.escape&&this.annotationTooltip.hide();return}if(d.target===this.element){if(d.keyCode!=f.enter)return;d.preventDefault();var a=this.editor.getCursorPosition().row;this.editor.isRowVisible(a)||this.editor.scrollToLine(a,!0,!0),setTimeout((function(){var l=this.$rowToRowIndex(this.gutterLayer.$cursorCell.row),c=this.$findNearestFoldLaneWidget(l),h=this.$findNearestAnnotation(l);if(!(c===null&&h===null)){var o=this.$findClosestNumber(c,h,l);if(o===c)if(this.activeLane="fold",this.activeRowIndex=c,this.$isCustomWidgetVisible(c)){this.$focusCustomWidget(this.activeRowIndex);return}else{this.$focusFoldWidget(this.activeRowIndex);return}else{this.activeRowIndex=h,this.activeLane="annotation",this.$focusAnnotation(this.activeRowIndex);return}}}).bind(this),10);return}this.$handleGutterKeyboardInteraction(d),setTimeout((function(){this.editor._signal("gutterkeydown",new w(d,this))}).bind(this),10)},u.prototype.$handleGutterKeyboardInteraction=function(d){if(d.keyCode===f.tab){d.preventDefault();return}if(d.keyCode===f.escape){d.preventDefault(),this.$blurGutter(),this.element.focus(),this.lane=null;return}if(d.keyCode===f.up){switch(d.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetUp();break;case"annotation":this.$moveAnnotationUp();break}return}if(d.keyCode===f.down){switch(d.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetDown();break;case"annotation":this.$moveAnnotationDown();break}return}if(d.keyCode===f.left){d.preventDefault(),this.$switchLane("annotation");return}if(d.keyCode===f.right){d.preventDefault(),this.$switchLane("fold");return}if(d.keyCode===f.enter||d.keyCode===f.space){switch(d.preventDefault(),this.activeLane){case"fold":var a=this.$rowIndexToRow(this.activeRowIndex),l=this.editor.session.$gutterCustomWidgets[a];if(l)l.callbacks&&l.callbacks.onClick&&l.callbacks.onClick(d,a);else if(this.gutterLayer.session.foldWidgets[a]==="start"){this.editor.session.onFoldWidgetClick(this.$rowIndexToRow(this.activeRowIndex),d),setTimeout((function(){this.$rowIndexToRow(this.activeRowIndex)!==a&&(this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=this.$rowToRowIndex(a),this.$focusFoldWidget(this.activeRowIndex))}).bind(this),10);break}else if(this.gutterLayer.session.foldWidgets[this.$rowIndexToRow(this.activeRowIndex)]==="end")break;return;case"annotation":this.annotationTooltip.showTooltip(this.$rowIndexToRow(this.activeRowIndex)),this.annotationTooltip.$fromKeyboard=!0;break}return}},u.prototype.$blurGutter=function(){if(this.activeRowIndex!==null)switch(this.activeLane){case"fold":this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex);break;case"annotation":this.$blurAnnotation(this.activeRowIndex);break}this.annotationTooltip.isOpen&&this.annotationTooltip.hide()},u.prototype.$isFoldWidgetVisible=function(d){var a=this.editor.isRowFullyVisible(this.$rowIndexToRow(d)),l=this.$getFoldWidget(d).style.display!=="none";return a&&l},u.prototype.$isCustomWidgetVisible=function(d){var a=this.editor.isRowFullyVisible(this.$rowIndexToRow(d)),l=!!this.$getCustomWidget(d);return a&&l},u.prototype.$isAnnotationVisible=function(d){var a=this.editor.isRowFullyVisible(this.$rowIndexToRow(d)),l=this.$getAnnotation(d).style.display!=="none";return a&&l},u.prototype.$getFoldWidget=function(d){var a=this.lines.get(d),l=a.element;return l.childNodes[1]},u.prototype.$getCustomWidget=function(d){var a=this.lines.get(d),l=a.element;return l.childNodes[3]},u.prototype.$getAnnotation=function(d){var a=this.lines.get(d),l=a.element;return l.childNodes[2]},u.prototype.$findNearestFoldLaneWidget=function(d){if(this.$isCustomWidgetVisible(d)||this.$isFoldWidgetVisible(d))return d;for(var a=0;d-a>0||d+a<this.lines.getLength()-1;){if(a++,d-a>=0&&this.$isCustomWidgetVisible(d-a))return d-a;if(d+a<=this.lines.getLength()-1&&this.$isCustomWidgetVisible(d+a))return d+a;if(d-a>=0&&this.$isFoldWidgetVisible(d-a))return d-a;if(d+a<=this.lines.getLength()-1&&this.$isFoldWidgetVisible(d+a))return d+a}return null},u.prototype.$findNearestAnnotation=function(d){if(this.$isAnnotationVisible(d))return d;for(var a=0;d-a>0||d+a<this.lines.getLength()-1;){if(a++,d-a>=0&&this.$isAnnotationVisible(d-a))return d-a;if(d+a<=this.lines.getLength()-1&&this.$isAnnotationVisible(d+a))return d+a}return null},u.prototype.$focusFoldWidget=function(d){if(d!=null){var a=this.$getFoldWidget(d);a.classList.add(this.editor.renderer.keyboardFocusClassName),a.focus()}},u.prototype.$focusCustomWidget=function(d){if(d!=null){var a=this.$getCustomWidget(d);a&&(a.classList.add(this.editor.renderer.keyboardFocusClassName),a.focus())}},u.prototype.$focusAnnotation=function(d){if(d!=null){var a=this.$getAnnotation(d);a.classList.add(this.editor.renderer.keyboardFocusClassName),a.focus()}},u.prototype.$blurFoldWidget=function(d){var a=this.$getFoldWidget(d);a.classList.remove(this.editor.renderer.keyboardFocusClassName),a.blur()},u.prototype.$blurCustomWidget=function(d){var a=this.$getCustomWidget(d);a&&(a.classList.remove(this.editor.renderer.keyboardFocusClassName),a.blur())},u.prototype.$blurAnnotation=function(d){var a=this.$getAnnotation(d);a.classList.remove(this.editor.renderer.keyboardFocusClassName),a.blur()},u.prototype.$moveFoldWidgetUp=function(){for(var d=this.activeRowIndex;d>0;)if(d--,this.$isFoldWidgetVisible(d)||this.$isCustomWidgetVisible(d)){this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex),this.activeRowIndex=d,this.$isFoldWidgetVisible(d)?this.$focusFoldWidget(this.activeRowIndex):this.$focusCustomWidget(this.activeRowIndex);return}},u.prototype.$moveFoldWidgetDown=function(){for(var d=this.activeRowIndex;d<this.lines.getLength()-1;)if(d++,this.$isFoldWidgetVisible(d)||this.$isCustomWidgetVisible(d)){this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex),this.activeRowIndex=d,this.$isFoldWidgetVisible(d)?this.$focusFoldWidget(this.activeRowIndex):this.$focusCustomWidget(this.activeRowIndex);return}},u.prototype.$moveAnnotationUp=function(){for(var d=this.activeRowIndex;d>0;)if(d--,this.$isAnnotationVisible(d)){this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=d,this.$focusAnnotation(this.activeRowIndex);return}},u.prototype.$moveAnnotationDown=function(){for(var d=this.activeRowIndex;d<this.lines.getLength()-1;)if(d++,this.$isAnnotationVisible(d)){this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=d,this.$focusAnnotation(this.activeRowIndex);return}},u.prototype.$findClosestNumber=function(d,a,l){return d===null?a:a===null||Math.abs(l-d)<=Math.abs(l-a)?d:a},u.prototype.$switchLane=function(d){switch(d){case"annotation":if(this.activeLane==="annotation")break;var a=this.$findNearestAnnotation(this.activeRowIndex);if(a==null)break;this.activeLane="annotation",this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex),this.activeRowIndex=a,this.$focusAnnotation(this.activeRowIndex);break;case"fold":if(this.activeLane==="fold")break;var l=this.$findNearestFoldLaneWidget(this.activeRowIndex);if(l===null)break;this.activeLane="fold",this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=l,this.$isCustomWidgetVisible(l)?this.$focusCustomWidget(this.activeRowIndex):this.$focusFoldWidget(this.activeRowIndex);break}},u.prototype.$rowIndexToRow=function(d){var a=this.lines.get(d);return a?a.row:null},u.prototype.$rowToRowIndex=function(d){for(var a=0;a<this.lines.getLength();a++){var l=this.lines.get(a);if(l.row==d)return a}return null},u})();r.GutterKeyboardHandler=g;var w=(function(){function u(d,a){this.gutterKeyboardHandler=a,this.domEvent=d}return u.prototype.getKey=function(){return f.keyCodeToString(this.domEvent.keyCode)},u.prototype.getRow=function(){return this.gutterKeyboardHandler.$rowIndexToRow(this.gutterKeyboardHandler.activeRowIndex)},u.prototype.isInAnnotationLane=function(){return this.gutterKeyboardHandler.activeLane==="annotation"},u.prototype.isInFoldLane=function(){return this.gutterKeyboardHandler.activeLane==="fold"},u})();r.GutterKeyboardEvent=w}),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(e,r,m){var f=this&&this.__values||function(S){var A=typeof Symbol=="function"&&Symbol.iterator,N=A&&S[A],B=0;if(N)return N.call(S);if(S&&typeof S.length=="number")return{next:function(){return S&&B>=S.length&&(S=void 0),{value:S&&S[B++],done:!S}}};throw new TypeError(A?"Object is not iterable.":"Symbol.iterator is not defined.")},g=e("./lib/oop"),w=e("./lib/dom"),u=e("./lib/lang"),d=e("./lib/useragent"),a=e("./keyboard/textinput").TextInput,l=e("./mouse/mouse_handler").MouseHandler,c=e("./mouse/fold_handler").FoldHandler,h=e("./keyboard/keybinding").KeyBinding,o=e("./edit_session").EditSession,s=e("./search").Search,p=e("./range").Range,b=e("./lib/event_emitter").EventEmitter,x=e("./commands/command_manager").CommandManager,M=e("./commands/default_commands").commands,R=e("./config"),k=e("./token_iterator").TokenIterator,C=e("./keyboard/gutter_handler").GutterKeyboardHandler,L=e("./config").nls,D=e("./clipboard"),I=e("./lib/keys"),T=e("./lib/event"),W=e("./tooltip").HoverTooltip,F=(function(){function S(A,N,B){this.id="editor"+ ++S.$uid,this.session,this.$toDestroy=[];var U=A.getContainerElement();this.container=U,this.renderer=A,this.commands=new x(d.isMac?"mac":"win",M),typeof document=="object"&&(this.textInput=new a(A.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.$mouseHandler=new l(this),new c(this)),this.keyBinding=new h(this),this.$search=new s().set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=u.delayedCall((function(){this._signal("input",{}),this.session&&!this.session.destroyed&&this.session.bgTokenizer.scheduleStart()}).bind(this)),this.on("change",function(G,J){J._$emitInputEvent.schedule(31)}),this.setSession(N||B&&B.session||new o("")),R.resetOptions(this),B&&this.setOptions(B),R._signal("editor",this)}return S.prototype.$initOperationListeners=function(){this.commands.on("exec",this.startOperation.bind(this),!0),this.commands.on("afterExec",this.endOperation.bind(this),!0)},S.prototype.startOperation=function(A){this.session.startOperation(A)},S.prototype.endOperation=function(A){this.session.endOperation(A)},S.prototype.onStartOperation=function(A){this.curOp=this.session.curOp,this.curOp.scrollTop=this.renderer.scrollTop,this.prevOp=this.session.prevOp,A||(this.previousCommand=null)},S.prototype.onEndOperation=function(A){if(this.curOp&&this.session){if(A&&A.returnValue===!1){this.curOp=null;return}if(this._signal("beforeEndOperation"),!this.curOp)return;var N=this.curOp.command,B=N&&N.scrollIntoView;if(B){switch(B){case"center-animate":B="animate";case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var U=this.selection.getRange(),G=this.renderer.layerConfig;(U.start.row>=G.lastRow||U.end.row<=G.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break}B=="animate"&&this.renderer.animateScrolling(this.curOp.scrollTop)}this.$lastSel=this.session.selection.toJSON(),this.prevOp=this.curOp,this.curOp=null}},S.prototype.$historyTracker=function(A){if(this.$mergeUndoDeltas){var N=this.prevOp,B=this.$mergeableCommands,U=N.command&&A.command.name==N.command.name;if(A.command.name=="insertstring"){var G=A.args;this.mergeNextCommand===void 0&&(this.mergeNextCommand=!0),U=U&&this.mergeNextCommand&&(!/\s/.test(G)||/\s/.test(N.args)),this.mergeNextCommand=!0}else U=U&&B.indexOf(A.command.name)!==-1;this.$mergeUndoDeltas!="always"&&Date.now()-this.sequenceStartTime>2e3&&(U=!1),U?this.session.mergeUndoDeltas=!0:B.indexOf(A.command.name)!==-1&&(this.sequenceStartTime=Date.now())}},S.prototype.setKeyboardHandler=function(A,N){if(A&&typeof A=="string"&&A!="ace"){this.$keybindingId=A;var B=this;R.loadModule(["keybinding",A],function(U){B.$keybindingId==A&&B.keyBinding.setKeyboardHandler(U&&U.handler),N&&N()})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(A),N&&N()},S.prototype.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},S.prototype.setSession=function(A){if(this.session!=A){this.curOp&&this.endOperation(),this.curOp={};var N=this.session;if(N){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 B=this.session.getSelection();B.off("changeCursor",this.$onCursorChange),B.off("changeSelection",this.$onSelectionChange)}this.session=A,A?(this.$onDocumentChange=this.onDocumentChange.bind(this),A.on("change",this.$onDocumentChange),this.renderer.setSession(A),this.$onChangeMode=this.onChangeMode.bind(this),A.on("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),A.on("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),A.on("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),A.on("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),A.on("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),A.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=A.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(A)),this._signal("changeSession",{session:A,oldSession:N}),this.curOp=null,N&&N._signal("changeEditor",{oldEditor:this}),N&&(N.$editor=null),A&&A._signal("changeEditor",{editor:this}),A&&(A.$editor=this),A&&!A.destroyed&&A.bgTokenizer.scheduleStart()}},S.prototype.getSession=function(){return this.session},S.prototype.setValue=function(A,N){return this.session.doc.setValue(A),N?N==1?this.navigateFileEnd():N==-1&&this.navigateFileStart():this.selectAll(),A},S.prototype.getValue=function(){return this.session.getValue()},S.prototype.getSelection=function(){return this.selection},S.prototype.resize=function(A){this.renderer.onResize(A)},S.prototype.setTheme=function(A,N){this.renderer.setTheme(A,N)},S.prototype.getTheme=function(){return this.renderer.getTheme()},S.prototype.setStyle=function(A,N){this.renderer.setStyle(A,N)},S.prototype.unsetStyle=function(A){this.renderer.unsetStyle(A)},S.prototype.getFontSize=function(){return this.getOption("fontSize")||w.computedStyle(this.container).fontSize},S.prototype.setFontSize=function(A){this.setOption("fontSize",A)},S.prototype.$highlightBrackets=function(){if(!this.$highlightPending){var A=this;this.$highlightPending=!0,setTimeout(function(){A.$highlightPending=!1;var N=A.session;if(!(!N||N.destroyed)){N.$bracketHighlight&&(N.$bracketHighlight.markerIds.forEach(function(ce){N.removeMarker(ce)}),N.$bracketHighlight=null);var B=A.getCursorPosition(),U=A.getKeyboardHandler(),G=U&&U.$getDirectionForHighlight&&U.$getDirectionForHighlight(A),J=N.getMatchingBracketRanges(B,G);if(!J){var ne=new k(N,B.row,B.column),de=ne.getCurrentToken();if(de&&/\b(?:tag-open|tag-name)/.test(de.type)){var ee=N.getMatchingTags(B);ee&&(J=[ee.openTagName.isEmpty()?ee.openTag:ee.openTagName,ee.closeTagName.isEmpty()?ee.closeTag:ee.closeTagName])}}if(!J&&N.$mode.getMatching&&(J=N.$mode.getMatching(A.session)),!J){A.getHighlightIndentGuides()&&A.renderer.$textLayer.$highlightIndentGuide();return}var se="ace_bracket";Array.isArray(J)?J.length==1&&(se="ace_error_bracket"):J=[J],J.length==2&&(p.comparePoints(J[0].end,J[1].start)==0?J=[p.fromPoints(J[0].start,J[1].end)]:p.comparePoints(J[0].start,J[1].end)==0&&(J=[p.fromPoints(J[1].start,J[0].end)])),N.$bracketHighlight={ranges:J,markerIds:J.map(function(ce){return N.addMarker(ce,se,"text")})},A.getHighlightIndentGuides()&&A.renderer.$textLayer.$highlightIndentGuide()}},50)}},S.prototype.focus=function(){this.textInput.focus()},S.prototype.isFocused=function(){return this.textInput.isFocused()},S.prototype.blur=function(){this.textInput.blur()},S.prototype.onFocus=function(A){this.$isFocused||(this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",A))},S.prototype.onBlur=function(A){this.$isFocused&&(this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",A))},S.prototype.$cursorChange=function(){this.renderer.updateCursor(),this.$highlightBrackets(),this.$updateHighlightActiveLine()},S.prototype.onDocumentChange=function(A){var N=this.session.$useWrapMode,B=A.start.row==A.end.row?A.end.row:1/0;this.renderer.updateLines(A.start.row,B,N),this._signal("change",A),this.$cursorChange()},S.prototype.onTokenizerUpdate=function(A){var N=A.data;this.renderer.updateLines(N.first,N.last)},S.prototype.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},S.prototype.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},S.prototype.onCursorChange=function(){this.$cursorChange(),this._signal("changeSelection")},S.prototype.$updateHighlightActiveLine=function(){var A=this.getSession(),N;if(this.$highlightActiveLine&&((this.$selectionStyle!="line"||!this.selection.isMultiLine())&&(N=this.getCursorPosition()),this.renderer.theme&&this.renderer.theme.$selectionColorConflict&&!this.selection.isEmpty()&&(N=!1),this.renderer.$maxLines&&this.session.getLength()===1&&!(this.renderer.$minLines>1)&&(N=!1)),A.$highlightLineMarker&&!N)A.removeMarker(A.$highlightLineMarker.id),A.$highlightLineMarker=null;else if(!A.$highlightLineMarker&&N){var B=new p(N.row,N.column,N.row,1/0);B.id=A.addMarker(B,"ace_active-line","screenLine"),A.$highlightLineMarker=B}else N&&(A.$highlightLineMarker.start.row=N.row,A.$highlightLineMarker.end.row=N.row,A.$highlightLineMarker.start.column=N.column,A._signal("changeBackMarker"))},S.prototype.onSelectionChange=function(A){var N=this.session;if(N.$selectionMarker&&N.removeMarker(N.$selectionMarker),N.$selectionMarker=null,this.selection.isEmpty())this.$updateHighlightActiveLine();else{var B=this.selection.getRange(),U=this.getSelectionStyle();N.$selectionMarker=N.addMarker(B,"ace_selection",U)}var G=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(G),this._signal("changeSelection")},S.prototype.$getSelectionHighLightRegexp=function(){var A=this.session,N=this.getSelectionRange();if(!(N.isEmpty()||N.isMultiLine())){var B=N.start.column,U=N.end.column,G=A.getLine(N.start.row),J=G.substring(B,U);if(!(J.length>5e3||!/[\w\d]/.test(J))){var ne=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:J}),de=G.substring(B-1,U+1);if(ne.test(de))return ne}}},S.prototype.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},S.prototype.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},S.prototype.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},S.prototype.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},S.prototype.onChangeMode=function(A){this.renderer.updateText(),this._emit("changeMode",A)},S.prototype.onChangeWrapLimit=function(){this.renderer.updateFull()},S.prototype.onChangeWrapMode=function(){this.renderer.onResize(!0)},S.prototype.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},S.prototype.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},S.prototype.getCopyText=function(){var A=this.getSelectedText(),N=this.session.doc.getNewLineCharacter(),B=!1;if(!A&&this.$copyWithEmptySelection){B=!0;for(var U=this.selection.getAllRanges(),G=0;G<U.length;G++){var J=U[G];G&&U[G-1].start.row==J.start.row||(A+=this.session.getLine(J.start.row)+N)}}var ne={text:A};return this._signal("copy",ne),D.lineMode=B?ne.text:!1,ne.text},S.prototype.onCopy=function(){this.commands.exec("copy",this)},S.prototype.onCut=function(){this.commands.exec("cut",this)},S.prototype.onPaste=function(A,N){var B={text:A,event:N};this.commands.exec("paste",this,B)},S.prototype.$handlePaste=function(A){typeof A=="string"&&(A={text:A}),this._signal("paste",A);var N=A.text,B=N===D.lineMode,U=this.session;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)B?U.insert({row:this.selection.lead.row,column:0},N):this.insert(N);else if(B)this.selection.rangeList.ranges.forEach(function(se){U.insert({row:se.start.row,column:0},N)});else{var G=N.split(/\r\n|\r|\n/),J=this.selection.rangeList.ranges,ne=G.length==2&&(!G[0]||!G[1]);if(G.length!=J.length||ne)return this.commands.exec("insertstring",this,N);for(var de=J.length;de--;){var ee=J[de];ee.isEmpty()||U.remove(ee),U.insert(ee.start,G[de])}}},S.prototype.execCommand=function(A,N){return this.commands.exec(A,this,N)},S.prototype.insert=function(A,N){var B=this.session,U=B.getMode(),G=this.getCursorPosition();if(this.getBehavioursEnabled()&&!N){var J=U.transformAction(B.getState(G.row),"insertion",this,B,A);J&&(A!==J.text&&(this.inVirtualSelectionMode||(this.session.mergeUndoDeltas=!1,this.mergeNextCommand=!1)),A=J.text)}if(A==" "&&(A=this.session.getTabString()),this.selection.isEmpty()){if(this.session.getOverwrite()&&A.indexOf(`
214
+ `)==-1){var ne=p.fromPoints(G,G);ne.end.column+=A.length,this.session.remove(ne)}}else{var ne=this.getSelectionRange();G=this.session.remove(ne),this.clearSelection()}if(A==`
215
+ `||A==`\r
216
+ `){var ce=B.getLine(G.row);if(G.column>ce.search(/\S|$/)){var de=ce.substr(G.column).search(/\S|$/);B.doc.removeInLine(G.row,G.column,G.column+de)}}this.clearSelection();var ee=G.column,se=B.getState(G.row),ce=B.getLine(G.row),le=U.checkOutdent(se,ce,A);if(B.insert(G,A),J&&J.selection&&(J.selection.length==2?this.selection.setSelectionRange(new p(G.row,ee+J.selection[0],G.row,ee+J.selection[1])):this.selection.setSelectionRange(new p(G.row+J.selection[0],J.selection[1],G.row+J.selection[2],J.selection[3]))),this.$enableAutoIndent){if(B.getDocument().isNewLine(A)){var pe=U.getNextLineIndent(se,ce.slice(0,G.column),B.getTabString());B.insert({row:G.row+1,column:0},pe)}le&&U.autoOutdent(se,B,G.row)}},S.prototype.autoIndent=function(){for(var A=this.session,N=A.getMode(),B=this.selection.isEmpty()?[new p(0,0,A.doc.getLength()-1,0)]:this.selection.getAllRanges(),U="",G="",J="",ne=A.getTabString(),de=0;de<B.length;de++)for(var ee=B[de].start.row,se=B[de].end.row,ce=ee;ce<=se;ce++){ce>0&&(U=A.getState(ce-1),G=A.getLine(ce-1),J=N.getNextLineIndent(U,G,ne));var le=A.getLine(ce),pe=N.$getIndent(le);if(J!==pe){if(pe.length>0){var me=new p(ce,0,ce,pe.length);A.remove(me)}J.length>0&&A.insert({row:ce,column:0},J)}N.autoOutdent(U,A,ce)}},S.prototype.onTextInput=function(A,N){if(!N)return this.keyBinding.onTextInput(A);this.startOperation({command:{name:"insertstring"}});var B=this.applyComposition.bind(this,A,N);this.selection.rangeCount?this.forEachSelection(B):B(),this.endOperation()},S.prototype.applyComposition=function(A,N){if(N.extendLeft||N.extendRight){var B=this.selection.getRange();B.start.column-=N.extendLeft,B.end.column+=N.extendRight,B.start.column<0&&(B.start.row--,B.start.column+=this.session.getLine(B.start.row).length+1),this.selection.setRange(B),!A&&!B.isEmpty()&&this.remove()}if((A||!this.selection.isEmpty())&&this.insert(A,!0),N.restoreStart||N.restoreEnd){var B=this.selection.getRange();B.start.column-=N.restoreStart,B.end.column-=N.restoreEnd,this.selection.setRange(B)}},S.prototype.onCommandKey=function(A,N,B){return this.keyBinding.onCommandKey(A,N,B)},S.prototype.setOverwrite=function(A){this.session.setOverwrite(A)},S.prototype.getOverwrite=function(){return this.session.getOverwrite()},S.prototype.toggleOverwrite=function(){this.session.toggleOverwrite()},S.prototype.setScrollSpeed=function(A){this.setOption("scrollSpeed",A)},S.prototype.getScrollSpeed=function(){return this.getOption("scrollSpeed")},S.prototype.setDragDelay=function(A){this.setOption("dragDelay",A)},S.prototype.getDragDelay=function(){return this.getOption("dragDelay")},S.prototype.setSelectionStyle=function(A){this.setOption("selectionStyle",A)},S.prototype.getSelectionStyle=function(){return this.getOption("selectionStyle")},S.prototype.setHighlightActiveLine=function(A){this.setOption("highlightActiveLine",A)},S.prototype.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},S.prototype.setHighlightGutterLine=function(A){this.setOption("highlightGutterLine",A)},S.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},S.prototype.setHighlightSelectedWord=function(A){this.setOption("highlightSelectedWord",A)},S.prototype.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},S.prototype.setAnimatedScroll=function(A){this.renderer.setAnimatedScroll(A)},S.prototype.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},S.prototype.setShowInvisibles=function(A){this.renderer.setShowInvisibles(A)},S.prototype.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},S.prototype.setDisplayIndentGuides=function(A){this.renderer.setDisplayIndentGuides(A)},S.prototype.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},S.prototype.setHighlightIndentGuides=function(A){this.renderer.setHighlightIndentGuides(A)},S.prototype.getHighlightIndentGuides=function(){return this.renderer.getHighlightIndentGuides()},S.prototype.setShowPrintMargin=function(A){this.renderer.setShowPrintMargin(A)},S.prototype.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},S.prototype.setPrintMarginColumn=function(A){this.renderer.setPrintMarginColumn(A)},S.prototype.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},S.prototype.setReadOnly=function(A){this.setOption("readOnly",A)},S.prototype.getReadOnly=function(){return this.getOption("readOnly")},S.prototype.setBehavioursEnabled=function(A){this.setOption("behavioursEnabled",A)},S.prototype.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},S.prototype.setWrapBehavioursEnabled=function(A){this.setOption("wrapBehavioursEnabled",A)},S.prototype.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},S.prototype.setShowFoldWidgets=function(A){this.setOption("showFoldWidgets",A)},S.prototype.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},S.prototype.setFadeFoldWidgets=function(A){this.setOption("fadeFoldWidgets",A)},S.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},S.prototype.remove=function(A){this.selection.isEmpty()&&(A=="left"?this.selection.selectLeft():this.selection.selectRight());var N=this.getSelectionRange();if(this.getBehavioursEnabled()){var B=this.session,U=B.getState(N.start.row),G=B.getMode().transformAction(U,"deletion",this,B,N);if(N.end.column===0){var J=B.getTextRange(N);if(J[J.length-1]==`
217
+ `){var ne=B.getLine(N.end.row);/^\s+$/.test(ne)&&(N.end.column=ne.length)}}G&&(N=G)}this.session.remove(N),this.clearSelection()},S.prototype.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},S.prototype.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},S.prototype.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},S.prototype.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var A=this.getSelectionRange();A.start.column==A.end.column&&A.start.row==A.end.row&&(A.end.column=0,A.end.row++),this.session.remove(A),this.clearSelection()},S.prototype.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var A=this.getCursorPosition();this.insert(`
218
+ `),this.moveCursorToPosition(A)},S.prototype.setGhostText=function(A,N){this.renderer.setGhostText(A,N)},S.prototype.removeGhostText=function(){this.renderer.removeGhostText()},S.prototype.transposeLetters=function(){if(this.selection.isEmpty()){var A=this.getCursorPosition(),N=A.column;if(N!==0){var B=this.session.getLine(A.row),U,G;N<B.length?(U=B.charAt(N)+B.charAt(N-1),G=new p(A.row,N-1,A.row,N+1)):(U=B.charAt(N-1)+B.charAt(N-2),G=new p(A.row,N-2,A.row,N)),this.session.replace(G,U),this.session.selection.moveToPosition(G.end)}}},S.prototype.toLowerCase=function(){var A=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var N=this.getSelectionRange(),B=this.session.getTextRange(N);this.session.replace(N,B.toLowerCase()),this.selection.setSelectionRange(A)},S.prototype.toUpperCase=function(){var A=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var N=this.getSelectionRange(),B=this.session.getTextRange(N);this.session.replace(N,B.toUpperCase()),this.selection.setSelectionRange(A)},S.prototype.indent=function(){var A=this.session,N=this.getSelectionRange();if(N.start.row<N.end.row){var B=this.$getSelectedRows();A.indentRows(B.first,B.last," ");return}else if(N.start.column<N.end.column){var U=A.getTextRange(N);if(!/^\s+$/.test(U)){var B=this.$getSelectedRows();A.indentRows(B.first,B.last," ");return}}var G=A.getLine(N.start.row),J=N.start,ne=A.getTabSize(),de=A.documentToScreenColumn(J.row,J.column);if(this.session.getUseSoftTabs())var ee=ne-de%ne,se=u.stringRepeat(" ",ee);else{for(var ee=de%ne;G[N.start.column-1]==" "&&ee;)N.start.column--,ee--;this.selection.setSelectionRange(N),se=" "}return this.insert(se)},S.prototype.blockIndent=function(){var A=this.$getSelectedRows();this.session.indentRows(A.first,A.last," ")},S.prototype.blockOutdent=function(){var A=this.session.getSelection();this.session.outdentRows(A.getRange())},S.prototype.sortLines=function(){for(var A=this.$getSelectedRows(),N=this.session,B=[],U=A.first;U<=A.last;U++)B.push(N.getLine(U));B.sort(function(ne,de){return ne.toLowerCase()<de.toLowerCase()?-1:ne.toLowerCase()>de.toLowerCase()?1:0});for(var G=new p(0,0,0,0),U=A.first;U<=A.last;U++){var J=N.getLine(U);G.start.row=U,G.end.row=U,G.end.column=J.length,N.replace(G,B[U-A.first])}},S.prototype.toggleCommentLines=function(){var A=this.session.getState(this.getCursorPosition().row),N=this.$getSelectedRows();this.session.getMode().toggleCommentLines(A,this.session,N.first,N.last)},S.prototype.toggleBlockComment=function(){var A=this.getCursorPosition(),N=this.session.getState(A.row),B=this.getSelectionRange();this.session.getMode().toggleBlockComment(N,this.session,B,A)},S.prototype.getNumberAt=function(A,N){var B=/[\-]?[0-9]+(?:\.[0-9]+)?/g;B.lastIndex=0;for(var U=this.session.getLine(A);B.lastIndex<N;){var G=B.exec(U);if(G.index<=N&&G.index+G[0].length>=N){var J={value:G[0],start:G.index,end:G.index+G[0].length};return J}}return null},S.prototype.modifyNumber=function(A){var N=this.selection.getCursor().row,B=this.selection.getCursor().column,U=new p(N,B-1,N,B),G=this.session.getTextRange(U);if(!isNaN(parseFloat(G))&&isFinite(G)){var J=this.getNumberAt(N,B);if(J){var ne=J.value.indexOf(".")>=0?J.start+J.value.indexOf(".")+1:J.end,de=J.start+J.value.length-ne,ee=parseFloat(J.value);ee*=Math.pow(10,de),ne!==J.end&&B<ne?A*=Math.pow(10,J.end-B-1):A*=Math.pow(10,J.end-B),ee+=A,ee/=Math.pow(10,de);var se=ee.toFixed(de),ce=new p(N,J.start,N,J.end);this.session.replace(ce,se),this.moveCursorTo(N,Math.max(J.start+1,B+se.length-J.value.length))}}else this.toggleWord()},S.prototype.toggleWord=function(){var A=this.selection.getCursor().row,N=this.selection.getCursor().column;this.selection.selectWord();var B=this.getSelectedText(),U=this.selection.getWordRange().start.column,G=B.replace(/([a-z]+|[A-Z]+)(?=[A-Z_]|$)/g,"$1 ").split(/\s/),J=N-U-1;J<0&&(J=0);var ne=0,de=0,ee=this;B.match(/[A-Za-z0-9_]+/)&&G.forEach(function(Ue,ot){de=ne+Ue.length,J>=ne&&J<=de&&(B=Ue,ee.selection.clearSelection(),ee.moveCursorTo(A,ne+U),ee.selection.selectTo(A,de+U)),ne=de});for(var se=this.$toggleWordPairs,ce,le=0;le<se.length;le++)for(var pe=se[le],me=0;me<=1;me++){var $e=+!me,Ee=B.match(new RegExp("^\\s?_?("+u.escapeRegExp(pe[me])+")\\s?$","i"));if(Ee){var He=B.match(new RegExp("([_]|^|\\s)("+u.escapeRegExp(Ee[1])+")($|\\s)","g"));He&&(ce=B.replace(new RegExp(u.escapeRegExp(pe[me]),"i"),function(Ue){var ot=pe[$e];return Ue.toUpperCase()==Ue?ot=ot.toUpperCase():Ue.charAt(0).toUpperCase()==Ue.charAt(0)&&(ot=ot.substr(0,0)+pe[$e].charAt(0).toUpperCase()+ot.substr(1)),ot}),this.insert(ce),ce="")}}},S.prototype.findLinkAt=function(A,N){var B,U,G=this.session.getLine(A),J=G.split(/((?:https?|ftp):\/\/[\S]+)/),ne=N;ne<0&&(ne=0);var de=0,ee=0,se;try{for(var ce=f(J),le=ce.next();!le.done;le=ce.next()){var pe=le.value;if(ee=de+pe.length,ne>=de&&ne<=ee&&pe.match(/((?:https?|ftp):\/\/[\S]+)/)){se=pe.replace(/[\s:.,'";}\]]+$/,"");break}de=ee}}catch(me){B={error:me}}finally{try{le&&!le.done&&(U=ce.return)&&U.call(ce)}finally{if(B)throw B.error}}return se},S.prototype.openLink=function(){var A=this.selection.getCursor(),N=this.findLinkAt(A.row,A.column);return N&&window.open(N,"_blank"),N!=null},S.prototype.removeLines=function(){var A=this.$getSelectedRows();this.session.removeFullLines(A.first,A.last),this.clearSelection()},S.prototype.duplicateSelection=function(){var A=this.selection,N=this.session,B=A.getRange(),U=A.isBackwards();if(B.isEmpty()){var G=B.start.row;N.duplicateLines(G,G)}else{var J=U?B.start:B.end,ne=N.insert(J,N.getTextRange(B));B.start=J,B.end=ne,A.setSelectionRange(B,U)}},S.prototype.moveLinesDown=function(){this.$moveLines(1,!1)},S.prototype.moveLinesUp=function(){this.$moveLines(-1,!1)},S.prototype.moveText=function(A,N,B){return this.session.moveText(A,N,B)},S.prototype.copyLinesUp=function(){this.$moveLines(-1,!0)},S.prototype.copyLinesDown=function(){this.$moveLines(1,!0)},S.prototype.$moveLines=function(A,N){var B,U,G=this.selection;if(!G.inMultiSelectMode||this.inVirtualSelectionMode){var J=G.toOrientedRange();B=this.$getSelectedRows(J),U=this.session.$moveLines(B.first,B.last,N?0:A),N&&A==-1&&(U=0),J.moveBy(U,0),G.fromOrientedRange(J)}else{var ne=G.rangeList.ranges;G.rangeList.detach(this.session),this.inVirtualSelectionMode=!0;for(var de=0,ee=0,se=ne.length,ce=0;ce<se;ce++){var le=ce;ne[ce].moveBy(de,0),B=this.$getSelectedRows(ne[ce]);for(var pe=B.first,me=B.last;++ce<se;){ee&&ne[ce].moveBy(ee,0);var $e=this.$getSelectedRows(ne[ce]);if(N&&$e.first!=me||!N&&$e.first>me+1)break;me=$e.last}for(ce--,de=this.session.$moveLines(pe,me,N?0:A),N&&A==-1&&(le=ce+1);le<=ce;)ne[le].moveBy(de,0),le++;N||(de=0),ee+=de}G.fromOrientedRange(G.ranges[0]),G.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},S.prototype.$getSelectedRows=function(A){return A=(A||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(A.start.row),last:this.session.getRowFoldEnd(A.end.row)}},S.prototype.onCompositionStart=function(A){this.renderer.showComposition(A)},S.prototype.onCompositionUpdate=function(A){this.renderer.setCompositionText(A)},S.prototype.onCompositionEnd=function(){this.renderer.hideComposition()},S.prototype.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},S.prototype.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},S.prototype.isRowVisible=function(A){return A>=this.getFirstVisibleRow()&&A<=this.getLastVisibleRow()},S.prototype.isRowFullyVisible=function(A){return A>=this.renderer.getFirstFullyVisibleRow()&&A<=this.renderer.getLastFullyVisibleRow()},S.prototype.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},S.prototype.$moveByPage=function(A,N){var B=this.renderer,U=this.renderer.layerConfig,G=A*Math.floor(U.height/U.lineHeight);N===!0?this.selection.$moveSelection(function(){this.moveCursorBy(G,0)}):N===!1&&(this.selection.moveCursorBy(G,0),this.selection.clearSelection());var J=B.scrollTop;B.scrollBy(0,G*U.lineHeight),N!=null&&B.scrollCursorIntoView(null,.5),B.animateScrolling(J)},S.prototype.selectPageDown=function(){this.$moveByPage(1,!0)},S.prototype.selectPageUp=function(){this.$moveByPage(-1,!0)},S.prototype.gotoPageDown=function(){this.$moveByPage(1,!1)},S.prototype.gotoPageUp=function(){this.$moveByPage(-1,!1)},S.prototype.scrollPageDown=function(){this.$moveByPage(1)},S.prototype.scrollPageUp=function(){this.$moveByPage(-1)},S.prototype.scrollToRow=function(A){this.renderer.scrollToRow(A)},S.prototype.scrollToLine=function(A,N,B,U){this.renderer.scrollToLine(A,N,B,U)},S.prototype.centerSelection=function(){var A=this.getSelectionRange(),N={row:Math.floor(A.start.row+(A.end.row-A.start.row)/2),column:Math.floor(A.start.column+(A.end.column-A.start.column)/2)};this.renderer.alignCursor(N,.5)},S.prototype.getCursorPosition=function(){return this.selection.getCursor()},S.prototype.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},S.prototype.getSelectionRange=function(){return this.selection.getRange()},S.prototype.selectAll=function(){this.selection.selectAll()},S.prototype.clearSelection=function(){this.selection.clearSelection()},S.prototype.moveCursorTo=function(A,N){this.selection.moveCursorTo(A,N)},S.prototype.moveCursorToPosition=function(A){this.selection.moveCursorToPosition(A)},S.prototype.jumpToMatching=function(A,N){var B=this.getCursorPosition(),U=new k(this.session,B.row,B.column),G=U.getCurrentToken(),J=0;G&&G.type.indexOf("tag-name")!==-1&&(G=U.stepBackward());var ne=G||U.stepForward();if(ne){var de,ee=!1,se={},ce=B.column-ne.start,le,pe={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(ne.value.match(/[{}()\[\]]/g)){for(;ce<ne.value.length&&!ee;ce++)if(pe[ne.value[ce]])switch(le=pe[ne.value[ce]]+"."+ne.type.replace("rparen","lparen"),isNaN(se[le])&&(se[le]=0),ne.value[ce]){case"(":case"[":case"{":se[le]++;break;case")":case"]":case"}":se[le]--,se[le]===-1&&(de="bracket",ee=!0);break}}else ne.type.indexOf("tag-name")!==-1&&(isNaN(se[ne.value])&&(se[ne.value]=0),G.value==="<"&&J>1?se[ne.value]++:G.value==="</"&&se[ne.value]--,se[ne.value]===-1&&(de="tag",ee=!0));ee||(G=ne,J++,ne=U.stepForward(),ce=0)}while(ne&&!ee);if(de){var me,$e;if(de==="bracket")me=this.session.getBracketRange(B),me||(me=new p(U.getCurrentTokenRow(),U.getCurrentTokenColumn()+ce-1,U.getCurrentTokenRow(),U.getCurrentTokenColumn()+ce-1),$e=me.start,(N||$e.row===B.row&&Math.abs($e.column-B.column)<2)&&(me=this.session.getBracketRange($e)));else if(de==="tag"){if(!ne||ne.type.indexOf("tag-name")===-1)return;if(me=new p(U.getCurrentTokenRow(),U.getCurrentTokenColumn()-2,U.getCurrentTokenRow(),U.getCurrentTokenColumn()-2),me.compare(B.row,B.column)===0){var Ee=this.session.getMatchingTags(B);Ee&&(Ee.openTag.contains(B.row,B.column)?(me=Ee.closeTag,$e=me.start):(me=Ee.openTag,Ee.closeTag.start.row===B.row&&Ee.closeTag.start.column===B.column?$e=me.end:$e=me.start))}$e=$e||me.start}$e=me&&me.cursor||$e,$e&&(A?me&&N?this.selection.setRange(me):me&&me.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo($e.row,$e.column):this.selection.moveTo($e.row,$e.column))}}},S.prototype.gotoLine=function(A,N,B){this.selection.clearSelection(),this.session.unfold({row:A-1,column:N||0}),this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(A-1,N||0),this.isRowFullyVisible(A-1)||this.scrollToLine(A-1,!0,B)},S.prototype.navigateTo=function(A,N){this.selection.moveTo(A,N)},S.prototype.navigateUp=function(A){if(this.selection.isMultiLine()&&!this.selection.isBackwards()){var N=this.selection.anchor.getPosition();return this.moveCursorToPosition(N)}this.selection.clearSelection(),this.selection.moveCursorBy(-A||-1,0)},S.prototype.navigateDown=function(A){if(this.selection.isMultiLine()&&this.selection.isBackwards()){var N=this.selection.anchor.getPosition();return this.moveCursorToPosition(N)}this.selection.clearSelection(),this.selection.moveCursorBy(A||1,0)},S.prototype.navigateLeft=function(A){if(this.selection.isEmpty())for(A=A||1;A--;)this.selection.moveCursorLeft();else{var N=this.getSelectionRange().start;this.moveCursorToPosition(N)}this.clearSelection()},S.prototype.navigateRight=function(A){if(this.selection.isEmpty())for(A=A||1;A--;)this.selection.moveCursorRight();else{var N=this.getSelectionRange().end;this.moveCursorToPosition(N)}this.clearSelection()},S.prototype.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},S.prototype.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},S.prototype.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},S.prototype.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},S.prototype.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},S.prototype.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},S.prototype.replace=function(A,N){N&&this.$search.set(N);var B=this.$search.find(this.session),U=0;return B&&(this.$tryReplace(B,A)&&(U=1),this.selection.setSelectionRange(B),this.renderer.scrollSelectionIntoView(B.start,B.end)),U},S.prototype.replaceAll=function(A,N){N&&this.$search.set(N);var B=this.$search.findAll(this.session),U=0;if(!B.length)return U;var G=this.getSelectionRange();this.selection.moveTo(0,0);for(var J=B.length-1;J>=0;--J)this.$tryReplace(B[J],A)&&U++;return this.selection.setSelectionRange(G),U},S.prototype.$tryReplace=function(A,N){var B=this.session.getTextRange(A);return N=this.$search.replace(B,N),N!==null?(A.end=this.session.replace(A,N),A):null},S.prototype.getLastSearchOptions=function(){return this.$search.getOptions()},S.prototype.find=function(A,N,B){N||(N={}),typeof A=="string"||A instanceof RegExp?N.needle=A:typeof A=="object"&&g.mixin(N,A);var U=this.selection.getRange();N.needle==null&&(A=this.session.getTextRange(U)||this.$search.$options.needle,A||(U=this.session.getWordRange(U.start.row,U.start.column),A=this.session.getTextRange(U)),this.$search.set({needle:A})),this.$search.set(N),N.start||this.$search.set({start:U});var G=this.$search.find(this.session);if(N.preventScroll)return G;if(G)return this.revealRange(G,B),G;N.backwards?U.start=U.end:U.end=U.start,this.selection.setRange(U)},S.prototype.findNext=function(A,N){this.find({skipCurrent:!0,backwards:!1},A,N)},S.prototype.findPrevious=function(A,N){this.find(A,{skipCurrent:!0,backwards:!0},N)},S.prototype.revealRange=function(A,N){this.session.unfold(A),this.selection.setSelectionRange(A);var B=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(A.start,A.end,.5),N!==!1&&this.renderer.animateScrolling(B)},S.prototype.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},S.prototype.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},S.prototype.destroy=function(){this.destroyed=!0,this.$toDestroy&&(this.$toDestroy.forEach(function(A){A.destroy()}),this.$toDestroy=[]),this.$mouseHandler&&this.$mouseHandler.destroy(),this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy(),this._$emitInputEvent&&this._$emitInputEvent.cancel(),this.removeAllListeners()},S.prototype.setAutoScrollEditorIntoView=function(A){if(A){var N,B=this,U=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var G=this.$scrollAnchor;G.style.cssText="position:absolute",this.container.insertBefore(G,this.container.firstChild);var J=this.on("changeSelection",function(){U=!0}),ne=this.renderer.on("beforeRender",function(){U&&(N=B.renderer.container.getBoundingClientRect())}),de=this.renderer.on("afterRender",function(){if(U&&N&&(B.isFocused()||B.searchBox&&B.searchBox.isFocused())){var ee=B.renderer,se=ee.$cursorLayer.$pixelPos,ce=ee.layerConfig,le=se.top-ce.offset;se.top>=0&&le+N.top<0?U=!0:se.top<ce.height&&se.top+N.top+ce.lineHeight>window.innerHeight?U=!1:U=null,U!=null&&(G.style.top=le+"px",G.style.left=se.left+"px",G.style.height=ce.lineHeight+"px",G.scrollIntoView(U)),U=N=null}});this.setAutoScrollEditorIntoView=function(ee){ee||(delete this.setAutoScrollEditorIntoView,this.off("changeSelection",J),this.renderer.off("afterRender",de),this.renderer.off("beforeRender",ne))}}},S.prototype.$resetCursorStyle=function(){var A=this.$cursorStyle||"ace",N=this.renderer.$cursorLayer;N&&(N.setSmoothBlinking(/smooth/.test(A)),N.isBlinking=!this.$readOnly&&A!="wide",w.setCssClass(N.element,"ace_slim-cursors",/slim/.test(A)))},S.prototype.prompt=function(A,N,B){var U=this;R.loadModule("ace/ext/prompt",function(G){G.prompt(U,A,N,B)})},Object.defineProperty(S.prototype,"hoverTooltip",{get:function(){return this.$hoverTooltip||(this.$hoverTooltip=new W(this.container))},set:function(A){this.$hoverTooltip&&this.$hoverTooltip.destroy(),this.$hoverTooltip=A},enumerable:!1,configurable:!0}),S})();F.$uid=0,F.prototype.curOp=null,F.prototype.prevOp={},F.prototype.$mergeableCommands=["backspace","del","insertstring"],F.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"],["&&","||"],["==","!="]],g.implement(F.prototype,b),R.defineOptions(F.prototype,"editor",{selectionStyle:{set:function(S){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:S})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(S){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(S){var A=this;if(this.textInput.setReadOnly(S),!this.destroyed){this.$resetCursorStyle(),this.$readOnlyCallback||(this.$readOnlyCallback=function(B){var U=!1;if(B&&B.type=="keydown"){if(B&&B.key&&!B.ctrlKey&&!B.metaKey&&(B.key==" "&&B.preventDefault(),U=B.key.length==1),!U)return}else B&&B.type!=="exec"&&(U=!0);if(U){var G=w.createElement("div");G.textContent=L("editor.tooltip.disable-editing","Editing is disabled"),A.hoverTooltip.isOpen||A.hoverTooltip.showForRange(A,A.getSelectionRange(),G)}else A.hoverTooltip&&A.hoverTooltip.isOpen&&A.hoverTooltip.hide()});var N=this.textInput.getElement();S?(T.addListener(N,"keydown",this.$readOnlyCallback,this),this.commands.on("exec",this.$readOnlyCallback),this.commands.on("commandUnavailable",this.$readOnlyCallback)):(T.removeListener(N,"keydown",this.$readOnlyCallback),this.commands.off("exec",this.$readOnlyCallback),this.commands.off("commandUnavailable",this.$readOnlyCallback))}},initialValue:!1},copyWithEmptySelection:{set:function(S){this.textInput.setCopyWithEmptySelection(S)},initialValue:!1},cursorStyle:{set:function(S){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(S){this.setAutoScrollEditorIntoView(S)}},keyboardHandler:{set:function(S){this.setKeyboardHandler(S)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function(S){this.session.setValue(S)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function(S){this.setSession(S)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function(S){this.renderer.$gutterLayer.setShowLineNumbers(S),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),S&&this.$relativeLineNumbers?O.attach(this):O.detach(this)},initialValue:!0},relativeLineNumbers:{set:function(S){this.$showLineNumbers&&S?O.attach(this):O.detach(this)}},placeholder:{set:function(S){this.$updatePlaceholder||(this.$updatePlaceholder=(function(){var A=this.session&&(this.renderer.$composition||this.session.getLength()>1||this.session.getLine(0).length>0);if(A&&this.renderer.placeholderNode)this.renderer.off("afterRender",this.$updatePlaceholder),w.removeCssClass(this.container,"ace_hasPlaceholder"),this.renderer.placeholderNode.remove(),this.renderer.placeholderNode=null;else if(!A&&!this.renderer.placeholderNode){this.renderer.on("afterRender",this.$updatePlaceholder),w.addCssClass(this.container,"ace_hasPlaceholder");var N=w.createElement("div");N.className="ace_placeholder",N.textContent=this.$placeholder||"",this.renderer.placeholderNode=N,this.renderer.content.appendChild(this.renderer.placeholderNode)}else!A&&this.renderer.placeholderNode&&(this.renderer.placeholderNode.textContent=this.$placeholder||"")}).bind(this),this.on("input",this.$updatePlaceholder)),this.$updatePlaceholder()}},enableKeyboardAccessibility:{set:function(S){var A={name:"blurTextInput",description:"Set focus to the editor content div to allow tabbing through the page",bindKey:"Esc",exec:function(U){U.blur(),U.renderer.scroller.focus()},readOnly:!0},N=function(U){if(U.target==this.renderer.scroller&&U.keyCode===I.enter){U.preventDefault();var G=this.getCursorPosition().row;this.isRowVisible(G)||this.scrollToLine(G,!0,!0),this.focus()}},B;S?(this.renderer.enableKeyboardAccessibility=!0,this.renderer.keyboardFocusClassName="ace_keyboard-focus",this.textInput.getElement().setAttribute("tabindex",-1),this.textInput.setNumberOfExtraLines(d.isWin?3:0),this.renderer.scroller.setAttribute("tabindex",0),this.renderer.scroller.setAttribute("role","group"),this.renderer.scroller.setAttribute("aria-roledescription",L("editor.scroller.aria-roledescription","editor")),this.renderer.scroller.classList.add(this.renderer.keyboardFocusClassName),this.renderer.scroller.setAttribute("aria-label",L("editor.scroller.aria-label","Editor content, press Enter to start editing, press Escape to exit")),this.renderer.scroller.addEventListener("keyup",N.bind(this)),this.commands.addCommand(A),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",L("editor.gutter.aria-roledescription","editor gutter")),this.renderer.$gutter.setAttribute("aria-label",L("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),B||(B=new C(this)),B.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",N.bind(this)),this.commands.removeCommand(A),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),B&&B.removeListener())},initialValue:!1},textInputAriaLabel:{set:function(S){this.$textInputAriaLabel=S},initialValue:""},enableMobileMenu:{set:function(S){this.$enableMobileMenu=S},initialValue:!0},customScrollbar:"renderer",hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",displayIndentGuides:"renderer",highlightIndentGuides:"renderer",showGutter:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",hasCssTransforms:"renderer",maxPixelHeight:"renderer",useTextareaForIME:"renderer",useResizeObserver:"renderer",useSvgGutterIcons:"renderer",showFoldedAnnotations:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimeout:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",navigateWithinSoftTabs:"session",tabSize:"session",wrap:"session",indentedSoftWrap:"session",foldStyle:"session",mode:"session"});var O={getText:function(S,A){return(Math.abs(S.selection.lead.row-A)||A+1+(A<9?"·":""))+""},getWidth:function(S,A,N){return Math.max(A.toString().length,(N.lastRow+1).toString().length,2)*N.characterWidth},update:function(S,A){A.renderer.$loop.schedule(A.renderer.CHANGE_GUTTER)},attach:function(S){S.renderer.$gutterLayer.$renderer=this,S.on("changeSelection",this.update),this.update(null,S)},detach:function(S){S.renderer.$gutterLayer.$renderer==this&&(S.renderer.$gutterLayer.$renderer=null),S.off("changeSelection",this.update),this.update(null,S)}};r.Editor=F}),ace.define("ace/layer/lines",["require","exports","module","ace/lib/dom"],function(e,r,m){var f=e("../lib/dom"),g=(function(){function w(u,d){this.element=u,this.canvasHeight=d||5e5,this.element.style.height=this.canvasHeight*2+"px",this.cells=[],this.cellCache=[],this.$offsetCoefficient=0}return w.prototype.moveContainer=function(u){f.translate(this.element,0,-(u.firstRowScreen*u.lineHeight%this.canvasHeight)-u.offset*this.$offsetCoefficient)},w.prototype.pageChanged=function(u,d){return Math.floor(u.firstRowScreen*u.lineHeight/this.canvasHeight)!==Math.floor(d.firstRowScreen*d.lineHeight/this.canvasHeight)},w.prototype.computeLineTop=function(u,d,a){var l=d.firstRowScreen*d.lineHeight,c=Math.floor(l/this.canvasHeight),h=a.documentToScreenRow(u,0)*d.lineHeight;return h-c*this.canvasHeight},w.prototype.computeLineHeight=function(u,d,a){return d.lineHeight*a.getRowLineCount(u)},w.prototype.getLength=function(){return this.cells.length},w.prototype.get=function(u){return this.cells[u]},w.prototype.shift=function(){this.$cacheCell(this.cells.shift())},w.prototype.pop=function(){this.$cacheCell(this.cells.pop())},w.prototype.push=function(u){if(Array.isArray(u)){this.cells.push.apply(this.cells,u);for(var d=f.createFragment(this.element),a=0;a<u.length;a++)d.appendChild(u[a].element);this.element.appendChild(d)}else this.cells.push(u),this.element.appendChild(u.element)},w.prototype.unshift=function(u){if(Array.isArray(u)){this.cells.unshift.apply(this.cells,u);for(var d=f.createFragment(this.element),a=0;a<u.length;a++)d.appendChild(u[a].element);this.element.firstChild?this.element.insertBefore(d,this.element.firstChild):this.element.appendChild(d)}else this.cells.unshift(u),this.element.insertAdjacentElement("afterbegin",u.element)},w.prototype.last=function(){return this.cells.length?this.cells[this.cells.length-1]:null},w.prototype.$cacheCell=function(u){u&&(u.element.remove(),this.cellCache.push(u))},w.prototype.createCell=function(u,d,a,l){var c=this.cellCache.pop();if(!c){var h=f.createElement("div");l&&l(h),this.element.appendChild(h),c={element:h,text:"",row:u}}return c.row=u,c},w})();r.Lines=g}),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(e,r,m){var f=e("../lib/dom"),g=e("../lib/oop"),w=e("../lib/lang"),u=e("../lib/event_emitter").EventEmitter,d=e("./lines").Lines,a=e("../config").nls,l=(function(){function h(o){this.$showCursorMarker=null,this.element=f.createElement("div"),this.element.className="ace_layer ace_gutter-layer",o.appendChild(this.element),this.setShowFoldWidgets(this.$showFoldWidgets),this.gutterWidth=0,this.$annotations=[],this.$updateAnnotations=this.$updateAnnotations.bind(this),this.$lines=new d(this.element),this.$lines.$offsetCoefficient=1}return h.prototype.setSession=function(o){this.session&&this.session.off("change",this.$updateAnnotations),this.session=o,o&&o.on("change",this.$updateAnnotations)},h.prototype.addGutterDecoration=function(o,s){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(o,s)},h.prototype.removeGutterDecoration=function(o,s){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(o,s)},h.prototype.setAnnotations=function(o){this.$annotations=[];for(var s=0;s<o.length;s++){var p=o[s],b=p.row,x=this.$annotations[b];x||(x=this.$annotations[b]={text:[],type:[],displayText:[]});var M=p.text,R=p.text,k=p.type;M=M?w.escapeHTML(M):p.html||"",R=R||p.html||"",x.text.indexOf(M)===-1&&(x.text.push(M),x.type.push(k),x.displayText.push(R));var C=p.className;C?x.className=C:k==="error"?x.className=" ace_error":k==="security"&&!/\bace_error\b/.test(x.className)?x.className=" ace_security":k==="warning"&&!/\bace_(error|security)\b/.test(x.className)?x.className=" ace_warning":k==="info"&&!x.className?x.className=" ace_info":k==="hint"&&!x.className&&(x.className=" ace_hint")}},h.prototype.$updateAnnotations=function(o){if(this.$annotations.length){var s=o.start.row,p=o.end.row-s;if(p!==0)if(o.action=="remove")this.$annotations.splice(s,p+1,null);else{var b=new Array(p+1);b.unshift(s,1),this.$annotations.splice.apply(this.$annotations,b)}}},h.prototype.update=function(o){this.config=o;var s=this.session,p=o.firstRow,b=Math.min(o.lastRow+o.gutterOffset,s.getLength()-1);this.oldLastRow=b,this.config=o,this.$lines.moveContainer(o),this.$updateCursorRow();for(var x=s.getNextFoldLine(p),M=x?x.start.row:1/0,R=null,k=-1,C=p;;){if(C>M&&(C=x.end.row+1,x=s.getNextFoldLine(C,x),M=x?x.start.row:1/0),C>b){for(;this.$lines.getLength()>k+1;)this.$lines.pop();break}R=this.$lines.get(++k),R?R.row=C:(R=this.$lines.createCell(C,o,this.session,c),this.$lines.push(R)),this.$renderCell(R,o,x,C),C++}this._signal("afterRender"),this.$updateGutterWidth(o),this.$showCursorMarker&&this.$highlightGutterLine&&this.$updateCursorMarker()},h.prototype.$updateGutterWidth=function(o){var s=this.session,p=s.gutterRenderer||this.$renderer,b=s.$firstLineNumber,x=this.$lines.last()?this.$lines.last().text:"";(this.$fixedWidth||s.$useWrapMode)&&(x=s.getLength()+b-1);var M=p?p.getWidth(s,x,o):x.toString().length*o.characterWidth,R=this.$padding||this.$computePadding();M+=R.left+R.right,M!==this.gutterWidth&&!isNaN(M)&&(this.gutterWidth=M,this.element.parentNode.style.width=this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._signal("changeGutterWidth",M))},h.prototype.$updateCursorRow=function(){if(this.$highlightGutterLine){var o=this.session.selection.getCursor();this.$cursorRow!==o.row&&(this.$cursorRow=o.row)}},h.prototype.updateLineHighlight=function(){if(this.$showCursorMarker&&this.$updateCursorMarker(),!!this.$highlightGutterLine){var o=this.session.selection.cursor.row;if(this.$cursorRow=o,!(this.$cursorCell&&this.$cursorCell.row==o)){this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ",""));var s=this.$lines.cells;this.$cursorCell=null;for(var p=0;p<s.length;p++){var b=s[p];if(b.row>=this.$cursorRow){if(b.row>this.$cursorRow){var x=this.session.getFoldLine(this.$cursorRow);if(p>0&&x&&x.start.row==s[p-1].row)b=s[p-1];else break}b.element.className="ace_gutter-active-line "+b.element.className,this.$cursorCell=b;break}}}}},h.prototype.$updateCursorMarker=function(){if(this.session){var o=this.session;this.$highlightElement||(this.$highlightElement=f.createElement("div"),this.$highlightElement.className="ace_gutter-cursor",this.$highlightElement.style.pointerEvents="none",this.element.appendChild(this.$highlightElement));var s=o.selection.cursor,p=this.config,b=this.$lines,x=p.firstRowScreen*p.lineHeight,M=Math.floor(x/b.canvasHeight),R=o.documentToScreenRow(s)*p.lineHeight,k=R-M*b.canvasHeight;f.setStyle(this.$highlightElement.style,"height",p.lineHeight+"px"),f.setStyle(this.$highlightElement.style,"top",k+"px")}},h.prototype.scrollLines=function(o){var s=this.config;if(this.config=o,this.$updateCursorRow(),this.$lines.pageChanged(s,o))return this.update(o);this.$lines.moveContainer(o);var p=Math.min(o.lastRow+o.gutterOffset,this.session.getLength()-1),b=this.oldLastRow;if(this.oldLastRow=p,!s||b<o.firstRow)return this.update(o);if(p<s.firstRow)return this.update(o);if(s.firstRow<o.firstRow)for(var x=this.session.getFoldedRowCount(s.firstRow,o.firstRow-1);x>0;x--)this.$lines.shift();if(b>p)for(var x=this.session.getFoldedRowCount(p+1,b);x>0;x--)this.$lines.pop();o.firstRow<s.firstRow&&this.$lines.unshift(this.$renderLines(o,o.firstRow,s.firstRow-1)),p>b&&this.$lines.push(this.$renderLines(o,b+1,p)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(o)},h.prototype.$renderLines=function(o,s,p){for(var b=[],x=s,M=this.session.getNextFoldLine(x),R=M?M.start.row:1/0;x>R&&(x=M.end.row+1,M=this.session.getNextFoldLine(x,M),R=M?M.start.row:1/0),!(x>p);){var k=this.$lines.createCell(x,o,this.session,c);this.$renderCell(k,o,M,x),b.push(k),x++}return b},h.prototype.$renderCell=function(o,s,p,b){var x=o.element,M=this.session,R=x.childNodes[0],k=x.childNodes[1],C=x.childNodes[2],L=x.childNodes[3],D=C.firstChild,I=M.$firstLineNumber,T=M.$breakpoints,W=M.$decorations,F=M.gutterRenderer||this.$renderer,O=this.$showFoldWidgets&&M.foldWidgets,S=p?p.start.row:Number.MAX_VALUE,A=s.lineHeight+"px",N=this.$useSvgGutterIcons?"ace_gutter-cell_svg-icons ":"ace_gutter-cell ",B=this.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",U=(F?F.getText(M,b):b+I).toString();if(this.$highlightGutterLine&&(b==this.$cursorRow||p&&b<this.$cursorRow&&b>=S&&this.$cursorRow<=p.end.row)&&(N+="ace_gutter-active-line ",this.$cursorCell!=o&&(this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ","")),this.$cursorCell=o)),T[b]&&(N+=T[b]),W[b]&&(N+=W[b]),this.$annotations[b]&&b!==S&&(N+=this.$annotations[b].className),O){var G=O[b];G==null&&(G=O[b]=M.getFoldWidget(b))}if(G){var J="ace_fold-widget ace_"+G,ne=G=="start"&&b==S&&b<p.end.row;if(ne){J+=" ace_closed";for(var de="",ee=!1,se=b+1;se<=p.end.row;se++)if(this.$annotations[se]){if(this.$annotations[se].className===" ace_error"){ee=!0,de=" ace_error_fold";break}this.$annotations[se].className===" ace_security"?(ee=!0,de=" ace_security_fold"):this.$annotations[se].className===" ace_warning"&&de!==" ace_security_fold"&&(ee=!0,de=" ace_warning_fold")}N+=de}else J+=" ace_open";k.className!=J&&(k.className=J),f.setStyle(k.style,"height",A),f.setStyle(k.style,"display","inline-block"),k.setAttribute("role","button"),k.setAttribute("tabindex","-1");var ce=M.getFoldWidgetRange(b);ce?k.setAttribute("aria-label",a("gutter.code-folding.range.aria-label","Toggle code folding, rows $0 through $1",[ce.start.row+1,ce.end.row+1])):p?k.setAttribute("aria-label",a("gutter.code-folding.closed.aria-label","Toggle code folding, rows $0 through $1",[p.start.row+1,p.end.row+1])):k.setAttribute("aria-label",a("gutter.code-folding.open.aria-label","Toggle code folding, row $0",[b+1])),ne?(k.setAttribute("aria-expanded","false"),k.setAttribute("title",a("gutter.code-folding.closed.title","Unfold code"))):(k.setAttribute("aria-expanded","true"),k.setAttribute("title",a("gutter.code-folding.open.title","Fold code")))}else k&&(f.setStyle(k.style,"display","none"),k.setAttribute("tabindex","0"),k.removeAttribute("role"),k.removeAttribute("aria-label"));var le=this.session.$gutterCustomWidgets[b];if(le?this.$addCustomWidget(b,le,o):L&&this.$removeCustomWidget(b,o),ee&&this.$showFoldedAnnotations){C.className="ace_gutter_annotation",D.className=B,D.className+=de,f.setStyle(D.style,"height",A),f.setStyle(C.style,"display","block"),f.setStyle(C.style,"height",A);var pe;switch(de){case" ace_error_fold":pe=a("gutter.annotation.aria-label.error","Error, read annotations row $0",[U]);break;case" ace_security_fold":pe=a("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[U]);break;case" ace_warning_fold":pe=a("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[U]);break}C.setAttribute("aria-label",pe),C.setAttribute("tabindex","-1"),C.setAttribute("role","button")}else if(this.$annotations[b]){C.className="ace_gutter_annotation",D.className=B,this.$useSvgGutterIcons?D.className+=this.$annotations[b].className:x.classList.add(this.$annotations[b].className.replace(" ","")),f.setStyle(D.style,"height",A),f.setStyle(C.style,"display","block"),f.setStyle(C.style,"height",A);var pe;switch(this.$annotations[b].className){case" ace_error":pe=a("gutter.annotation.aria-label.error","Error, read annotations row $0",[U]);break;case" ace_security":pe=a("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[U]);break;case" ace_warning":pe=a("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[U]);break;case" ace_info":pe=a("gutter.annotation.aria-label.info","Info, read annotations row $0",[U]);break;case" ace_hint":pe=a("gutter.annotation.aria-label.hint","Suggestion, read annotations row $0",[U]);break}C.setAttribute("aria-label",pe),C.setAttribute("tabindex","-1"),C.setAttribute("role","button")}else f.setStyle(C.style,"display","none"),C.removeAttribute("aria-label"),C.removeAttribute("role"),C.setAttribute("tabindex","0");return U!==R.data&&(R.data=U),x.className!=N&&(x.className=N),f.setStyle(o.element.style,"height",this.$lines.computeLineHeight(b,s,M)+"px"),f.setStyle(o.element.style,"top",this.$lines.computeLineTop(b,s,M)+"px"),o.text=U,C.style.display==="none"&&k.style.display==="none"&&!le?o.element.setAttribute("aria-hidden",!0):o.element.setAttribute("aria-hidden",!1),o},h.prototype.setHighlightGutterLine=function(o){this.$highlightGutterLine=o,!o&&this.$highlightElement&&(this.$highlightElement.remove(),this.$highlightElement=null)},h.prototype.setShowLineNumbers=function(o){this.$renderer=!o&&{getWidth:function(){return 0},getText:function(){return""}}},h.prototype.getShowLineNumbers=function(){return this.$showLineNumbers},h.prototype.setShowFoldWidgets=function(o){o?f.addCssClass(this.element,"ace_folding-enabled"):f.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=o,this.$padding=null},h.prototype.getShowFoldWidgets=function(){return this.$showFoldWidgets},h.prototype.$hideFoldWidget=function(o,s){var p=s||this.$getGutterCell(o);if(p&&p.element){var b=p.element.childNodes[1];b&&f.setStyle(b.style,"display","none")}},h.prototype.$showFoldWidget=function(o,s){var p=s||this.$getGutterCell(o);if(p&&p.element){var b=p.element.childNodes[1];b&&this.session.foldWidgets&&this.session.foldWidgets[p.row]&&f.setStyle(b.style,"display","inline-block")}},h.prototype.$getGutterCell=function(o){var s=this.$lines.cells,p=0,b=s.length-1;if(!(o<s[0].row||o>s[b].row)){for(;p<=b;){var x=Math.floor((p+b)/2),M=s[x];if(M.row>o)b=x-1;else if(M.row<o)p=x+1;else return M}return M}},h.prototype.$addCustomWidget=function(o,s,p){var b=s.className,x=s.label,M=s.title,R=s.callbacks;this.session.$gutterCustomWidgets[o]={className:b,label:x,title:M,callbacks:R},this.$hideFoldWidget(o,p);var k=p||this.$getGutterCell(o);if(k&&k.element){var C=k.element.querySelector(".ace_custom-widget");C&&C.remove(),C=f.createElement("span"),C.className="ace_custom-widget ".concat(b),C.setAttribute("tabindex","-1"),C.setAttribute("role","button"),C.setAttribute("aria-label",x),C.setAttribute("title",M),f.setStyle(C.style,"display","inline-block"),f.setStyle(C.style,"height","inherit"),R&&R.onClick&&C.addEventListener("click",function(L){R.onClick(L,o),L.stopPropagation()}),k.element.appendChild(C)}},h.prototype.$removeCustomWidget=function(o,s){delete this.session.$gutterCustomWidgets[o],this.$showFoldWidget(o,s);var p=s||this.$getGutterCell(o);if(p&&p.element){var b=p.element.querySelector(".ace_custom-widget");b&&p.element.removeChild(b)}},h.prototype.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var o=f.computedStyle(this.element.firstChild);return this.$padding={},this.$padding.left=(parseInt(o.borderLeftWidth)||0)+(parseInt(o.paddingLeft)||0)+1,this.$padding.right=(parseInt(o.borderRightWidth)||0)+(parseInt(o.paddingRight)||0),this.$padding},h.prototype.getRegion=function(o){var s=this.$padding||this.$computePadding(),p=this.element.getBoundingClientRect();if(o.x<s.left+p.left)return"markers";if(this.$showFoldWidgets&&o.x>p.right-s.right)return"foldWidgets"},h})();l.prototype.$fixedWidth=!1,l.prototype.$highlightGutterLine=!0,l.prototype.$renderer=void 0,l.prototype.$showLineNumbers=!0,l.prototype.$showFoldWidgets=!0,g.implement(l.prototype,u);function c(h){var o=document.createTextNode("");h.appendChild(o);var s=f.createElement("span");h.appendChild(s);var p=f.createElement("span");h.appendChild(p);var b=f.createElement("span");return p.appendChild(b),h}r.Gutter=l}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(e,r,m){var f=e("../range").Range,g=e("../lib/dom"),w=(function(){function d(a){this.element=g.createElement("div"),this.element.className="ace_layer ace_marker-layer",a.appendChild(this.element)}return d.prototype.setPadding=function(a){this.$padding=a},d.prototype.setSession=function(a){this.session=a},d.prototype.setMarkers=function(a){this.markers=a},d.prototype.elt=function(a,l){var c=this.i!=-1&&this.element.childNodes[this.i];c?this.i++:(c=document.createElement("div"),this.element.appendChild(c),this.i=-1),c.style.cssText=l,c.className=a},d.prototype.update=function(a){if(a){this.config=a,this.i=0;var l;for(var c in this.markers){var h=this.markers[c];if(!h.range){h.update(l,this,this.session,a);continue}var o=h.range.clipRows(a.firstRow,a.lastRow);if(!o.isEmpty())if(o=o.toScreenRange(this.session),h.renderer){var s=this.$getTop(o.start.row,a),p=this.$padding+o.start.column*a.characterWidth;h.renderer(l,o,p,s,a)}else h.type=="fullLine"?this.drawFullLineMarker(l,o,h.clazz,a):h.type=="screenLine"?this.drawScreenLineMarker(l,o,h.clazz,a):o.isMultiLine()?h.type=="text"?this.drawTextMarker(l,o,h.clazz,a):this.drawMultiLineMarker(l,o,h.clazz,a):this.drawSingleLineMarker(l,o,h.clazz+" ace_start ace_br15",a)}if(this.i!=-1)for(;this.i<this.element.childElementCount;)this.element.removeChild(this.element.lastChild)}},d.prototype.$getTop=function(a,l){return(a-l.firstRowScreen)*l.lineHeight},d.prototype.drawTextMarker=function(a,l,c,h,o){for(var s=this.session,p=l.start.row,b=l.end.row,x=p,M=0,R=0,k=s.getScreenLastRowColumn(x),C=new f(x,l.start.column,x,R);x<=b;x++)C.start.row=C.end.row=x,C.start.column=x==p?l.start.column:s.getRowWrapIndent(x),C.end.column=k,M=R,R=k,k=x+1<b?s.getScreenLastRowColumn(x+1):x==b?0:l.end.column,this.drawSingleLineMarker(a,C,c+(x==p?" ace_start":"")+" ace_br"+u(x==p||x==p+1&&l.start.column,M<R,R>k,x==b),h,x==b?0:1,o)},d.prototype.drawMultiLineMarker=function(a,l,c,h,o){var s=this.$padding,p=h.lineHeight,b=this.$getTop(l.start.row,h),x=s+l.start.column*h.characterWidth;if(o=o||"",this.session.$bidiHandler.isBidiRow(l.start.row)){var M=l.clone();M.end.row=M.start.row,M.end.column=this.session.getLine(M.start.row).length,this.drawBidiSingleLineMarker(a,M,c+" ace_br1 ace_start",h,null,o)}else this.elt(c+" ace_br1 ace_start","height:"+p+"px;right:"+s+"px;top:"+b+"px;left:"+x+"px;"+(o||""));if(this.session.$bidiHandler.isBidiRow(l.end.row)){var M=l.clone();M.start.row=M.end.row,M.start.column=0,this.drawBidiSingleLineMarker(a,M,c+" ace_br12",h,null,o)}else{b=this.$getTop(l.end.row,h);var R=l.end.column*h.characterWidth;this.elt(c+" ace_br12","height:"+p+"px;width:"+R+"px;top:"+b+"px;left:"+s+"px;"+(o||""))}if(p=(l.end.row-l.start.row-1)*h.lineHeight,!(p<=0)){b=this.$getTop(l.start.row+1,h);var k=(l.start.column?1:0)|(l.end.column?0:8);this.elt(c+(k?" ace_br"+k:""),"height:"+p+"px;right:"+s+"px;top:"+b+"px;left:"+s+"px;"+(o||""))}},d.prototype.drawSingleLineMarker=function(a,l,c,h,o,s){if(this.session.$bidiHandler.isBidiRow(l.start.row))return this.drawBidiSingleLineMarker(a,l,c,h,o,s);var p=h.lineHeight,b=(l.end.column+(o||0)-l.start.column)*h.characterWidth,x=this.$getTop(l.start.row,h),M=this.$padding+l.start.column*h.characterWidth;this.elt(c,"height:"+p+"px;width:"+b+"px;top:"+x+"px;left:"+M+"px;"+(s||""))},d.prototype.drawBidiSingleLineMarker=function(a,l,c,h,o,s){var p=h.lineHeight,b=this.$getTop(l.start.row,h),x=this.$padding,M=this.session.$bidiHandler.getSelections(l.start.column,l.end.column);M.forEach(function(R){this.elt(c,"height:"+p+"px;width:"+(R.width+(o||0))+"px;top:"+b+"px;left:"+(x+R.left)+"px;"+(s||""))},this)},d.prototype.drawFullLineMarker=function(a,l,c,h,o){var s=this.$getTop(l.start.row,h),p=h.lineHeight;l.start.row!=l.end.row&&(p+=this.$getTop(l.end.row,h)-s),this.elt(c,"height:"+p+"px;top:"+s+"px;left:0;right:0;"+(o||""))},d.prototype.drawScreenLineMarker=function(a,l,c,h,o){var s=this.$getTop(l.start.row,h),p=h.lineHeight;this.elt(c,"height:"+p+"px;top:"+s+"px;left:0;right:0;"+(o||""))},d})();w.prototype.$padding=0;function u(d,a,l,c){return(d?1:0)|(a?2:0)|(l?4:0)|(c?8:0)}r.Marker=w}),ace.define("ace/layer/text_util",["require","exports","module"],function(e,r,m){var f=new Set(["text","rparen","lparen"]);r.isTextToken=function(g){return f.has(g)}}),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(e,r,m){var f=e("../lib/oop"),g=e("../lib/dom"),w=e("../lib/lang"),u=e("./lines").Lines,d=e("../lib/event_emitter").EventEmitter,a=e("../config").nls,l=e("./text_util").isTextToken,c=(function(){function h(o){this.dom=g,this.element=this.dom.createElement("div"),this.element.className="ace_layer ace_text-layer",o.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this),this.$lines=new u(this.element)}return h.prototype.$updateEolChar=function(){var o=this.session.doc,s=o.getNewLineCharacter()==`
219
+ `&&o.getNewLineMode()!="windows",p=s?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=p)return this.EOL_CHAR=p,!0},h.prototype.setPadding=function(o){this.$padding=o,this.element.style.margin="0 "+o+"px"},h.prototype.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},h.prototype.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},h.prototype.$setFontMetrics=function(o){this.$fontMetrics=o,this.$fontMetrics.on("changeCharacterSize",(function(s){this._signal("changeCharacterSize",s)}).bind(this)),this.$pollSizeChanges()},h.prototype.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},h.prototype.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},h.prototype.setSession=function(o){this.session=o,o&&this.$computeTabString()},h.prototype.setShowInvisibles=function(o){return this.showInvisibles==o?!1:(this.showInvisibles=o,typeof o=="string"?(this.showSpaces=/tab/i.test(o),this.showTabs=/space/i.test(o),this.showEOL=/eol/i.test(o)):this.showSpaces=this.showTabs=this.showEOL=o,this.$computeTabString(),!0)},h.prototype.setDisplayIndentGuides=function(o){return this.displayIndentGuides==o?!1:(this.displayIndentGuides=o,this.$computeTabString(),!0)},h.prototype.setHighlightIndentGuides=function(o){return this.$highlightIndentGuides===o?!1:(this.$highlightIndentGuides=o,o)},h.prototype.$computeTabString=function(){var o=this.session.getTabSize();this.tabSize=o;for(var s=this.$tabStrings=[0],p=1;p<o+1;p++)if(this.showTabs){var b=this.dom.createElement("span");b.className="ace_invisible ace_invisible_tab",b.textContent=w.stringRepeat(this.TAB_CHAR,p),s.push(b)}else s.push(this.dom.createTextNode(w.stringRepeat(" ",p),this.element));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;var x="ace_indent-guide",M=this.showSpaces?" ace_invisible ace_invisible_space":"",R=this.showSpaces?w.stringRepeat(this.SPACE_CHAR,this.tabSize):w.stringRepeat(" ",this.tabSize),k=this.showTabs?" ace_invisible ace_invisible_tab":"",C=this.showTabs?w.stringRepeat(this.TAB_CHAR,this.tabSize):R,b=this.dom.createElement("span");b.className=x+M,b.textContent=R,this.$tabStrings[" "]=b;var b=this.dom.createElement("span");b.className=x+k,b.textContent=C,this.$tabStrings[" "]=b}},h.prototype.updateLines=function(o,s,p){if(this.config.lastRow!=o.lastRow||this.config.firstRow!=o.firstRow)return this.update(o);this.config=o;for(var b=Math.max(s,o.firstRow),x=Math.min(p,o.lastRow),M=this.element.childNodes,R=0,k=o.firstRow;k<b;k++){var C=this.session.getFoldLine(k);if(C)if(C.containsRow(b)){b=C.start.row;break}else k=C.end.row;R++}for(var L=!1,k=b,C=this.session.getNextFoldLine(k),D=C?C.start.row:1/0;k>D&&(k=C.end.row+1,C=this.session.getNextFoldLine(k,C),D=C?C.start.row:1/0),!(k>x);){var I=M[R++];if(I){this.dom.removeChildren(I),this.$renderLine(I,k,k==D?C:!1),L&&(I.style.top=this.$lines.computeLineTop(k,o,this.session)+"px");var T=o.lineHeight*this.session.getRowLength(k)+"px";I.style.height!=T&&(L=!0,I.style.height=T)}k++}if(L)for(;R<this.$lines.cells.length;){var W=this.$lines.cells[R++];W.element.style.top=this.$lines.computeLineTop(W.row,o,this.session)+"px"}},h.prototype.scrollLines=function(o){var s=this.config;if(this.config=o,this.$lines.pageChanged(s,o))return this.update(o);this.$lines.moveContainer(o);var p=o.lastRow,b=s?s.lastRow:-1;if(!s||b<o.firstRow)return this.update(o);if(p<s.firstRow)return this.update(o);if(!s||s.lastRow<o.firstRow)return this.update(o);if(o.lastRow<s.firstRow)return this.update(o);if(s.firstRow<o.firstRow)for(var x=this.session.getFoldedRowCount(s.firstRow,o.firstRow-1);x>0;x--)this.$lines.shift();if(s.lastRow>o.lastRow)for(var x=this.session.getFoldedRowCount(o.lastRow+1,s.lastRow);x>0;x--)this.$lines.pop();o.firstRow<s.firstRow&&this.$lines.unshift(this.$renderLinesFragment(o,o.firstRow,s.firstRow-1)),o.lastRow>s.lastRow&&this.$lines.push(this.$renderLinesFragment(o,s.lastRow+1,o.lastRow)),this.$highlightIndentGuide()},h.prototype.$renderLinesFragment=function(o,s,p){for(var b=[],x=s,M=this.session.getNextFoldLine(x),R=M?M.start.row:1/0;x>R&&(x=M.end.row+1,M=this.session.getNextFoldLine(x,M),R=M?M.start.row:1/0),!(x>p);){var k=this.$lines.createCell(x,o,this.session),C=k.element;this.dom.removeChildren(C),g.setStyle(C.style,"height",this.$lines.computeLineHeight(x,o,this.session)+"px"),g.setStyle(C.style,"top",this.$lines.computeLineTop(x,o,this.session)+"px"),this.$renderLine(C,x,x==R?M:!1),this.$useLineGroups()?C.className="ace_line_group":C.className="ace_line",b.push(k),x++}return b},h.prototype.update=function(o){this.$lines.moveContainer(o),this.config=o;for(var s=o.firstRow,p=o.lastRow,b=this.$lines;b.getLength();)b.pop();b.push(this.$renderLinesFragment(o,s,p))},h.prototype.$renderToken=function(o,s,p,b){for(var x=this,M=/(\t)|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\uFEFF\uFFF9-\uFFFC\u2066\u2067\u2068\u202A\u202B\u202D\u202E\u202C\u2069\u2060\u2061\u2062\u2063\u2064\u206A\u206B\u206B\u206C\u206D\u206E\u206F]+)|(\u3000)|([\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3001-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]|[\uD800-\uDBFF][\uDC00-\uDFFF])/g,R=this.dom.createFragment(this.element),k,C=0;k=M.exec(b);){var L=k[1],D=k[2],I=k[3],T=k[4],W=k[5];if(!(!x.showSpaces&&D)){var F=C!=k.index?b.slice(C,k.index):"";if(C=k.index+k[0].length,F&&R.appendChild(this.dom.createTextNode(F,this.element)),L){var O=x.session.getScreenTabSize(s+k.index),S=x.$tabStrings[O].cloneNode(!0);S.charCount=1,R.appendChild(S),s+=O-1}else if(D)if(x.showSpaces){var A=this.dom.createElement("span");A.className="ace_invisible ace_invisible_space",A.textContent=w.stringRepeat(x.SPACE_CHAR,D.length),R.appendChild(A)}else R.appendChild(this.dom.createTextNode(D,this.element));else if(I){var A=this.dom.createElement("span");A.className="ace_invisible ace_invisible_space ace_invalid",A.textContent=w.stringRepeat(x.SPACE_CHAR,I.length),R.appendChild(A)}else if(T){s+=1;var A=this.dom.createElement("span");A.style.width=x.config.characterWidth*2+"px",A.className=x.showSpaces?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",A.textContent=x.showSpaces?x.SPACE_CHAR:T,R.appendChild(A)}else if(W){s+=1;var A=this.dom.createElement("span");A.style.width=x.config.characterWidth*2+"px",A.className="ace_cjk",A.textContent=W,R.appendChild(A)}}}if(R.appendChild(this.dom.createTextNode(C?b.slice(C):b,this.element)),l(p.type))o.appendChild(R);else{var N="ace_"+p.type.replace(/\./g," ace_"),A=this.dom.createElement("span");p.type=="fold"&&(A.style.width=p.value.length*this.config.characterWidth+"px",A.setAttribute("title",a("inline-fold.closed.title","Unfold code"))),A.className=N,A.appendChild(R),o.appendChild(A)}return s+b.length},h.prototype.renderIndentGuide=function(o,s,p){var b=s.search(this.$indentGuideRe);if(b<=0||b>=p)return s;if(s[0]==" "){b-=b%this.tabSize;for(var x=b/this.tabSize,M=0;M<x;M++)o.appendChild(this.$tabStrings[" "].cloneNode(!0));return this.$highlightIndentGuide(),s.substr(b)}else if(s[0]==" "){for(var M=0;M<b;M++){var R=this.$tabStrings[" "].cloneNode(!0);R.charCount=1,o.appendChild(R)}return this.$highlightIndentGuide(),s.substr(b)}return this.$highlightIndentGuide(),s},h.prototype.$highlightIndentGuide=function(){if(!(!this.$highlightIndentGuides||!this.displayIndentGuides)){this.$highlightIndentGuideMarker={indentLevel:void 0,start:void 0,end:void 0,dir:void 0};var o=this.session.doc.$lines;if(o){var s=this.session.selection.getCursor(),p=/^\s*/.exec(this.session.doc.getLine(s.row))[0].length,b=Math.floor(p/this.tabSize);this.$highlightIndentGuideMarker={indentLevel:b,start:s.row};var x=this.session.$bracketHighlight;if(x){for(var M=this.session.$bracketHighlight.ranges,R=0;R<M.length;R++)if(s.row!==M[R].start.row){this.$highlightIndentGuideMarker.end=M[R].start.row+1,s.row>M[R].start.row?this.$highlightIndentGuideMarker.dir=-1:this.$highlightIndentGuideMarker.dir=1;break}}if(!this.$highlightIndentGuideMarker.end&&o[s.row]!==""&&s.column===o[s.row].length){this.$highlightIndentGuideMarker.dir=1;for(var R=s.row+1;R<o.length;R++){var k=o[R],C=/^\s*/.exec(k)[0].length;if(k!==""&&(this.$highlightIndentGuideMarker.end=R,C<=p))break}}this.$renderHighlightIndentGuide()}}},h.prototype.$clearActiveIndentGuide=function(){for(var o=this.element.querySelectorAll(".ace_indent-guide-active"),s=0;s<o.length;s++)o[s].classList.remove("ace_indent-guide-active")},h.prototype.$setIndentGuideActive=function(o,s){var p=this.session.doc.getLine(o.row);if(p!==""){var b=o.element;if(o.element.classList&&o.element.classList.contains("ace_line_group"))if(o.element.childNodes.length>0)b=o.element.childNodes[0];else return;var x=b.childNodes;if(x){var M=x[s-1];M&&M.classList&&M.classList.contains("ace_indent-guide")&&M.classList.add("ace_indent-guide-active")}}},h.prototype.$renderHighlightIndentGuide=function(){if(this.$lines){var o=this.$lines.cells;this.$clearActiveIndentGuide();var s=this.$highlightIndentGuideMarker.indentLevel;if(s!==0)if(this.$highlightIndentGuideMarker.dir===1)for(var p=0;p<o.length;p++){var b=o[p];if(this.$highlightIndentGuideMarker.end&&b.row>=this.$highlightIndentGuideMarker.start+1){if(b.row>=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(b,s)}}else for(var p=o.length-1;p>=0;p--){var b=o[p];if(this.$highlightIndentGuideMarker.end&&b.row<this.$highlightIndentGuideMarker.start){if(b.row<this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(b,s)}}}},h.prototype.$createLineElement=function(o){var s=this.dom.createElement("div");return s.className="ace_line",s.style.height=this.config.lineHeight+"px",s},h.prototype.$renderWrappedLine=function(o,s,p){var b=0,x=0,M=p[0],R=0,k=this.$createLineElement();o.appendChild(k);for(var C=0;C<s.length;C++){var L=s[C],D=L.value;if(C==0&&this.displayIndentGuides){if(b=D.length,D=this.renderIndentGuide(k,D,M),!D)continue;b-=D.length}if(b+D.length<M)R=this.$renderToken(k,R,L,D),b+=D.length;else{for(;b+D.length>=M;){R=this.$renderToken(k,R,L,D.substring(0,M-b)),D=D.substring(M-b),b=M,k=this.$createLineElement(),o.appendChild(k);var I=this.dom.createTextNode(w.stringRepeat(" ",p.indent),this.element);I.charCount=0,k.appendChild(I),x++,R=0,M=p[x]||Number.MAX_VALUE}D.length!=0&&(b+=D.length,R=this.$renderToken(k,R,L,D))}}p[p.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage(k,R,null,"",!0)},h.prototype.$renderSimpleLine=function(o,s){for(var p=0,b=0;b<s.length;b++){var x=s[b],M=x.value;if(!(b==0&&this.displayIndentGuides&&(M=this.renderIndentGuide(o,M),!M))){if(p+M.length>this.MAX_LINE_LENGTH)return this.$renderOverflowMessage(o,p,x,M);p=this.$renderToken(o,p,x,M)}}},h.prototype.$renderOverflowMessage=function(o,s,p,b,x){p&&this.$renderToken(o,s,p,b.slice(0,this.MAX_LINE_LENGTH-s));var M=this.dom.createElement("span");M.className="ace_inline_button ace_keyword ace_toggle_wrap",M.textContent=x?"<hide>":"<click to see more...>",o.appendChild(M)},h.prototype.$renderLine=function(o,s,p){if(!p&&p!=!1&&(p=this.session.getFoldLine(s)),p)var b=this.$getFoldLineTokens(s,p);else var b=this.session.getTokens(s);var x=o;if(b.length){var M=this.session.getRowSplitData(s);if(M&&M.length){this.$renderWrappedLine(o,b,M);var x=o.lastChild}else{var x=o;this.$useLineGroups()&&(x=this.$createLineElement(),o.appendChild(x)),this.$renderSimpleLine(x,b)}}else this.$useLineGroups()&&(x=this.$createLineElement(),o.appendChild(x));if(this.showEOL&&x){p&&(s=p.end.row);var R=this.dom.createElement("span");R.className="ace_invisible ace_invisible_eol",R.textContent=s==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,x.appendChild(R)}},h.prototype.$getFoldLineTokens=function(o,s){var p=this.session,b=[];function x(R,k,C){for(var L=0,D=0;D+R[L].value.length<k;)if(D+=R[L].value.length,L++,L==R.length)return;if(D!=k){var I=R[L].value.substring(k-D);I.length>C-k&&(I=I.substring(0,C-k)),b.push({type:R[L].type,value:I}),D=k+I.length,L+=1}for(;D<C&&L<R.length;){var I=R[L].value;I.length+D>C?b.push({type:R[L].type,value:I.substring(0,C-D)}):b.push(R[L]),D+=I.length,L+=1}}var M=p.getTokens(o);return s.walk(function(R,k,C,L,D){R!=null?b.push({type:"fold",value:R}):(D&&(M=p.getTokens(k)),M.length&&x(M,L,C))},s.end.row,this.session.getLine(s.end.row).length),b},h.prototype.$useLineGroups=function(){return this.session.getUseWrapMode()},h})();c.prototype.EOF_CHAR="¶",c.prototype.EOL_CHAR_LF="¬",c.prototype.EOL_CHAR_CRLF="¤",c.prototype.EOL_CHAR=c.prototype.EOL_CHAR_LF,c.prototype.TAB_CHAR="—",c.prototype.SPACE_CHAR="·",c.prototype.$padding=0,c.prototype.MAX_LINE_LENGTH=1e4,c.prototype.showInvisibles=!1,c.prototype.showSpaces=!1,c.prototype.showTabs=!1,c.prototype.showEOL=!1,c.prototype.displayIndentGuides=!0,c.prototype.$highlightIndentGuides=!0,c.prototype.$tabStrings=[],c.prototype.destroy={},c.prototype.onChangeTabSize=c.prototype.$computeTabString,f.implement(c.prototype,d),r.Text=c}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(e,r,m){var f=e("../lib/dom"),g=(function(){function w(u){this.element=f.createElement("div"),this.element.className="ace_layer ace_cursor-layer",u.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),f.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)}return w.prototype.$updateOpacity=function(u){for(var d=this.cursors,a=d.length;a--;)f.setStyle(d[a].style,"opacity",u?"":"0")},w.prototype.$startCssAnimation=function(){for(var u=this.cursors,d=u.length;d--;)u[d].style.animationDuration=this.blinkInterval+"ms";this.$isAnimating=!0,setTimeout((function(){this.$isAnimating&&f.addCssClass(this.element,"ace_animate-blinking")}).bind(this))},w.prototype.$stopCssAnimation=function(){this.$isAnimating=!1,f.removeCssClass(this.element,"ace_animate-blinking")},w.prototype.setPadding=function(u){this.$padding=u},w.prototype.setSession=function(u){this.session=u},w.prototype.setBlinking=function(u){u!=this.isBlinking&&(this.isBlinking=u,this.restartTimer())},w.prototype.setBlinkInterval=function(u){u!=this.blinkInterval&&(this.blinkInterval=u,this.restartTimer())},w.prototype.setSmoothBlinking=function(u){u!=this.smoothBlinking&&(this.smoothBlinking=u,f.setCssClass(this.element,"ace_smooth-blinking",u),this.$updateCursors(!0),this.restartTimer())},w.prototype.addCursor=function(){var u=f.createElement("div");return u.className="ace_cursor",this.element.appendChild(u),this.cursors.push(u),u},w.prototype.removeCursor=function(){if(this.cursors.length>1){var u=this.cursors.pop();return u.parentNode.removeChild(u),u}},w.prototype.hideCursor=function(){this.isVisible=!1,f.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},w.prototype.showCursor=function(){this.isVisible=!0,f.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},w.prototype.restartTimer=function(){var u=this.$updateCursors;if(clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&(this.$isSmoothBlinking=!1,f.removeCssClass(this.element,"ace_smooth-blinking")),u(!0),!this.isBlinking||!this.blinkInterval||!this.isVisible){this.$stopCssAnimation();return}if(this.smoothBlinking&&(this.$isSmoothBlinking=!0,setTimeout((function(){this.$isSmoothBlinking&&f.addCssClass(this.element,"ace_smooth-blinking")}).bind(this))),f.HAS_CSS_ANIMATION)this.$startCssAnimation();else{var d=(function(){this.timeoutId=setTimeout(function(){u(!1)},.6*this.blinkInterval)}).bind(this);this.intervalId=setInterval(function(){u(!0),d()},this.blinkInterval),d()}},w.prototype.getPixelPosition=function(u,d){if(!this.config||!this.session)return{left:0,top:0};u||(u=this.session.selection.getCursor());var a=this.session.documentToScreenPosition(u),l=this.$padding+(this.session.$bidiHandler.isBidiRow(a.row,u.row)?this.session.$bidiHandler.getPosLeft(a.column):a.column*this.config.characterWidth),c=(a.row-(d?this.config.firstRowScreen:0))*this.config.lineHeight;return{left:l,top:c}},w.prototype.isCursorInView=function(u,d){return u.top>=0&&u.top<d.maxHeight},w.prototype.update=function(u){this.config=u;var d=this.session.$selectionMarkers,a=0,l=0;(d===void 0||d.length===0)&&(d=[{cursor:null}]);for(var a=0,c=d.length;a<c;a++){var h=this.getPixelPosition(d[a].cursor,!0);if(!((h.top>u.height+u.offset||h.top<0)&&a>1)){var o=this.cursors[l++]||this.addCursor(),s=o.style;this.drawCursor?this.drawCursor(o,h,u,d[a],this.session):this.isCursorInView(h,u)?(f.setStyle(s,"display","block"),f.translate(o,h.left,h.top),f.setStyle(s,"width",Math.round(u.characterWidth)+"px"),f.setStyle(s,"height",u.lineHeight+"px")):f.setStyle(s,"display","none")}}for(;this.cursors.length>l;)this.removeCursor();var p=this.session.getOverwrite();this.$setOverwrite(p),this.$pixelPos=h,this.restartTimer()},w.prototype.$setOverwrite=function(u){u!=this.overwrite&&(this.overwrite=u,u?f.addCssClass(this.element,"ace_overwrite-cursors"):f.removeCssClass(this.element,"ace_overwrite-cursors"))},w.prototype.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)},w})();g.prototype.$padding=0,g.prototype.drawCursor=null,r.Cursor=g}),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(e,r,m){var f=this&&this.__extends||(function(){var o=function(s,p){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,x){b.__proto__=x}||function(b,x){for(var M in x)Object.prototype.hasOwnProperty.call(x,M)&&(b[M]=x[M])},o(s,p)};return function(s,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");o(s,p);function b(){this.constructor=s}s.prototype=p===null?Object.create(p):(b.prototype=p.prototype,new b)}})(),g=e("./lib/oop"),w=e("./lib/dom"),u=e("./lib/event"),d=e("./lib/event_emitter").EventEmitter,a=32768,l=(function(){function o(s,p){this.element=w.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+p,this.element.tabIndex=-1,this.inner=w.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent=" ",this.element.appendChild(this.inner),s.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,u.addListener(this.element,"scroll",this.onScroll.bind(this)),u.addListener(this.element,"mousedown",u.preventDefault)}return o.prototype.setVisible=function(s){this.element.style.display=s?"":"none",this.isVisible=s,this.coeff=1},o})();g.implement(l.prototype,d);var c=(function(o){f(s,o);function s(p,b){var x=o.call(this,p,"-v")||this;return x.scrollTop=0,x.scrollHeight=0,b.$scrollbarWidth=x.width=w.scrollbarWidth(p.ownerDocument),x.inner.style.width=x.element.style.width=(x.width||15)+5+"px",x.$minWidth=0,x}return s.prototype.onScroll=function(){if(!this.skipEvent){if(this.scrollTop=this.element.scrollTop,this.coeff!=1){var p=this.element.clientHeight/this.scrollHeight;this.scrollTop=this.scrollTop*(1-p)/(this.coeff-p)}this._emit("scroll",{data:this.scrollTop})}this.skipEvent=!1},s.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},s.prototype.setHeight=function(p){this.element.style.height=p+"px"},s.prototype.setScrollHeight=function(p){this.scrollHeight=p,p>a?(this.coeff=a/p,p=a):this.coeff!=1&&(this.coeff=1),this.inner.style.height=p+"px"},s.prototype.setScrollTop=function(p){this.scrollTop!=p&&(this.skipEvent=!0,this.scrollTop=p,this.element.scrollTop=p*this.coeff)},s})(l);c.prototype.setInnerHeight=c.prototype.setScrollHeight;var h=(function(o){f(s,o);function s(p,b){var x=o.call(this,p,"-h")||this;return x.scrollLeft=0,x.height=b.$scrollbarWidth,x.inner.style.height=x.element.style.height=(x.height||15)+5+"px",x}return s.prototype.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},s.prototype.getHeight=function(){return this.isVisible?this.height:0},s.prototype.setWidth=function(p){this.element.style.width=p+"px"},s.prototype.setInnerWidth=function(p){this.inner.style.width=p+"px"},s.prototype.setScrollWidth=function(p){this.inner.style.width=p+"px"},s.prototype.setScrollLeft=function(p){this.scrollLeft!=p&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=p)},s})(l);r.ScrollBar=c,r.ScrollBarV=c,r.ScrollBarH=h,r.VScrollBar=c,r.HScrollBar=h}),ace.define("ace/scrollbar_custom",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(e,r,m){var f=this&&this.__extends||(function(){var h=function(o,s){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,b){p.__proto__=b}||function(p,b){for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(p[x]=b[x])},h(o,s)};return function(o,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");h(o,s);function p(){this.constructor=o}o.prototype=s===null?Object.create(s):(p.prototype=s.prototype,new p)}})(),g=e("./lib/oop"),w=e("./lib/dom"),u=e("./lib/event"),d=e("./lib/event_emitter").EventEmitter;w.importCssString(`.ace_editor>.ace_sb-v div, .ace_editor>.ace_sb-h div{
220
+ position: absolute;
221
+ background: rgba(128, 128, 128, 0.6);
222
+ -moz-box-sizing: border-box;
223
+ box-sizing: border-box;
224
+ border: 1px solid #bbb;
225
+ border-radius: 2px;
226
+ z-index: 8;
227
+ }
228
+ .ace_editor>.ace_sb-v, .ace_editor>.ace_sb-h {
229
+ position: absolute;
230
+ z-index: 6;
231
+ background: none;
232
+ overflow: hidden!important;
233
+ }
234
+ .ace_editor>.ace_sb-v {
235
+ z-index: 6;
236
+ right: 0;
237
+ top: 0;
238
+ width: 12px;
239
+ }
240
+ .ace_editor>.ace_sb-v div {
241
+ z-index: 8;
242
+ right: 0;
243
+ width: 100%;
244
+ }
245
+ .ace_editor>.ace_sb-h {
246
+ bottom: 0;
247
+ left: 0;
248
+ height: 12px;
249
+ }
250
+ .ace_editor>.ace_sb-h div {
251
+ bottom: 0;
252
+ height: 100%;
253
+ }
254
+ .ace_editor>.ace_sb_grabbed {
255
+ z-index: 8;
256
+ background: #000;
257
+ }`,"ace_scrollbar.css",!1);var a=(function(){function h(o,s){this.element=w.createElement("div"),this.element.className="ace_sb"+s,this.inner=w.createElement("div"),this.inner.className="",this.element.appendChild(this.inner),this.VScrollWidth=12,this.HScrollHeight=12,o.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,u.addMultiMouseDownListener(this.element,[500,300,300],this,"onMouseDown")}return h.prototype.setVisible=function(o){this.element.style.display=o?"":"none",this.isVisible=o,this.coeff=1},h})();g.implement(a.prototype,d);var l=(function(h){f(o,h);function o(s,p){var b=h.call(this,s,"-v")||this;return b.scrollTop=0,b.scrollHeight=0,b.parent=s,b.width=b.VScrollWidth,b.renderer=p,b.inner.style.width=b.element.style.width=(b.width||15)+"px",b.$minWidth=0,b}return o.prototype.onMouseDown=function(s,p){if(s==="mousedown"&&!(u.getButton(p)!==0||p.detail===2)){if(p.target===this.inner){var b=this,x=p.clientY,M=function(T){x=T.clientY},R=function(){clearInterval(D)},k=p.clientY,C=this.thumbTop,L=function(){if(x!==void 0){var T=b.scrollTopFromThumbTop(C+x-k);T!==b.scrollTop&&b._emit("scroll",{data:T})}};u.capture(this.inner,M,R);var D=setInterval(L,20);return u.preventDefault(p)}var I=p.clientY-this.element.getBoundingClientRect().top-this.thumbHeight/2;return this._emit("scroll",{data:this.scrollTopFromThumbTop(I)}),u.preventDefault(p)}},o.prototype.getHeight=function(){return this.height},o.prototype.scrollTopFromThumbTop=function(s){var p=s*(this.pageHeight-this.viewHeight)/(this.slideHeight-this.thumbHeight);return p=p>>0,p<0?p=0:p>this.pageHeight-this.viewHeight&&(p=this.pageHeight-this.viewHeight),p},o.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},o.prototype.setHeight=function(s){this.height=Math.max(0,s),this.slideHeight=this.height,this.viewHeight=this.height,this.setScrollHeight(this.pageHeight,!0)},o.prototype.setScrollHeight=function(s,p){this.pageHeight===s&&!p||(this.pageHeight=s,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})))},o.prototype.setScrollTop=function(s){this.scrollTop=s,s<0&&(s=0),this.thumbTop=s*(this.slideHeight-this.thumbHeight)/(this.pageHeight-this.viewHeight),this.inner.style.top=this.thumbTop+"px"},o})(a);l.prototype.setInnerHeight=l.prototype.setScrollHeight;var c=(function(h){f(o,h);function o(s,p){var b=h.call(this,s,"-h")||this;return b.scrollLeft=0,b.scrollWidth=0,b.height=b.HScrollHeight,b.inner.style.height=b.element.style.height=(b.height||12)+"px",b.renderer=p,b}return o.prototype.onMouseDown=function(s,p){if(s==="mousedown"&&!(u.getButton(p)!==0||p.detail===2)){if(p.target===this.inner){var b=this,x=p.clientX,M=function(T){x=T.clientX},R=function(){clearInterval(D)},k=p.clientX,C=this.thumbLeft,L=function(){if(x!==void 0){var T=b.scrollLeftFromThumbLeft(C+x-k);T!==b.scrollLeft&&b._emit("scroll",{data:T})}};u.capture(this.inner,M,R);var D=setInterval(L,20);return u.preventDefault(p)}var I=p.clientX-this.element.getBoundingClientRect().left-this.thumbWidth/2;return this._emit("scroll",{data:this.scrollLeftFromThumbLeft(I)}),u.preventDefault(p)}},o.prototype.getHeight=function(){return this.isVisible?this.height:0},o.prototype.scrollLeftFromThumbLeft=function(s){var p=s*(this.pageWidth-this.viewWidth)/(this.slideWidth-this.thumbWidth);return p=p>>0,p<0?p=0:p>this.pageWidth-this.viewWidth&&(p=this.pageWidth-this.viewWidth),p},o.prototype.setWidth=function(s){this.width=Math.max(0,s),this.element.style.width=this.width+"px",this.slideWidth=this.width,this.viewWidth=this.width,this.setScrollWidth(this.pageWidth,!0)},o.prototype.setScrollWidth=function(s,p){this.pageWidth===s&&!p||(this.pageWidth=s,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})))},o.prototype.setScrollLeft=function(s){this.scrollLeft=s,s<0&&(s=0),this.thumbLeft=s*(this.slideWidth-this.thumbWidth)/(this.pageWidth-this.viewWidth),this.inner.style.left=this.thumbLeft+"px"},o})(a);c.prototype.setInnerWidth=c.prototype.setScrollWidth,r.ScrollBar=l,r.ScrollBarV=l,r.ScrollBarH=c,r.VScrollBar=l,r.HScrollBar=c}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(e,r,m){var f=e("./lib/event"),g=(function(){function w(u,d){this.onRender=u,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=d||window;var a=this;this._flush=function(l){a.pending=!1;var c=a.changes;if(c&&(f.blockIdle(100),a.changes=0,a.onRender(c)),a.changes){if(a.$recursionLimit--<0)return;a.schedule()}else a.$recursionLimit=2}}return w.prototype.schedule=function(u){this.changes=this.changes|u,this.changes&&!this.pending&&(f.nextFrame(this._flush),this.pending=!0)},w.prototype.clear=function(u){var d=this.changes;return this.changes=0,d},w})();r.RenderLoop=g}),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(e,r,m){var f=e("../lib/oop"),g=e("../lib/dom"),w=e("../lib/lang"),u=e("../lib/event"),d=e("../lib/useragent"),a=e("../lib/event_emitter").EventEmitter,l=512,c=typeof ResizeObserver=="function",h=200,o=(function(){function s(p){this.el=g.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=g.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=g.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),p.appendChild(this.el),this.$measureNode.textContent=w.stringRepeat("X",l),this.$characterSize={width:0,height:0},c?this.$addObserver():this.checkForSizeChanges()}return s.prototype.$setMeasureNodeStyles=function(p,b){p.width=p.height="auto",p.left=p.top="0px",p.visibility="hidden",p.position="absolute",p.whiteSpace="pre",d.isIE<8?p["font-family"]="inherit":p.font="inherit",p.overflow=b?"hidden":"visible"},s.prototype.checkForSizeChanges=function(p){if(p===void 0&&(p=this.$measureSizes()),p&&(this.$characterSize.width!==p.width||this.$characterSize.height!==p.height)){this.$measureNode.style.fontWeight="bold";var b=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=p,this.charSizes=Object.create(null),this.allowBoldFonts=b&&b.width===p.width&&b.height===p.height,this._emit("changeCharacterSize",{data:p})}},s.prototype.$addObserver=function(){var p=this;this.$observer=new window.ResizeObserver(function(b){p.checkForSizeChanges()}),this.$observer.observe(this.$measureNode)},s.prototype.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer||this.$observer)return this.$pollSizeChangesTimer;var p=this;return this.$pollSizeChangesTimer=u.onIdle(function b(){p.checkForSizeChanges(),u.onIdle(b,500)},500)},s.prototype.setPolling=function(p){p?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},s.prototype.$measureSizes=function(p){var b={height:(p||this.$measureNode).clientHeight,width:(p||this.$measureNode).clientWidth/l};return b.width===0||b.height===0?null:b},s.prototype.$measureCharWidth=function(p){this.$main.textContent=w.stringRepeat(p,l);var b=this.$main.getBoundingClientRect();return b.width/l},s.prototype.getCharacterWidth=function(p){var b=this.charSizes[p];return b===void 0&&(b=this.charSizes[p]=this.$measureCharWidth(p)/this.$characterSize.width),b},s.prototype.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},s.prototype.$getZoom=function(p){return!p||!p.parentElement?1:(Number(window.getComputedStyle(p).zoom)||1)*this.$getZoom(p.parentElement)},s.prototype.$initTransformMeasureNodes=function(){var p=function(b,x){return["div",{style:"position: absolute;top:"+b+"px;left:"+x+"px;"}]};this.els=g.buildDom([p(0,0),p(h,0),p(0,h),p(h,h)],this.el)},s.prototype.transformCoordinates=function(p,b){if(p){var x=this.$getZoom(this.el);p=C(1/x,p)}function M(J,ne,de){var ee=J[1]*ne[0]-J[0]*ne[1];return[(-ne[1]*de[0]+ne[0]*de[1])/ee,(+J[1]*de[0]-J[0]*de[1])/ee]}function R(J,ne){return[J[0]-ne[0],J[1]-ne[1]]}function k(J,ne){return[J[0]+ne[0],J[1]+ne[1]]}function C(J,ne){return[J*ne[0],J*ne[1]]}this.els||this.$initTransformMeasureNodes();function L(J){var ne=J.getBoundingClientRect();return[ne.left,ne.top]}var D=L(this.els[0]),I=L(this.els[1]),T=L(this.els[2]),W=L(this.els[3]),F=M(R(W,I),R(W,T),R(k(I,T),k(W,D))),O=C(1+F[0],R(I,D)),S=C(1+F[1],R(T,D));if(b){var A=b,N=F[0]*A[0]/h+F[1]*A[1]/h+1,B=k(C(A[0],O),C(A[1],S));return k(C(1/N/h,B),D)}var U=R(p,D),G=M(R(O,C(F[0],U)),R(S,C(F[1],U)),U);return C(h,G)},s})();o.prototype.$characterSize={width:0,height:0},f.implement(o.prototype,a),r.FontMetrics=o}),ace.define("ace/css/editor-css",["require","exports","module"],function(e,r,m){m.exports=`
258
+ .ace_br1 {border-top-left-radius : 3px;}
259
+ .ace_br2 {border-top-right-radius : 3px;}
260
+ .ace_br3 {border-top-left-radius : 3px; border-top-right-radius: 3px;}
261
+ .ace_br4 {border-bottom-right-radius: 3px;}
262
+ .ace_br5 {border-top-left-radius : 3px; border-bottom-right-radius: 3px;}
263
+ .ace_br6 {border-top-right-radius : 3px; border-bottom-right-radius: 3px;}
264
+ .ace_br7 {border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px;}
265
+ .ace_br8 {border-bottom-left-radius : 3px;}
266
+ .ace_br9 {border-top-left-radius : 3px; border-bottom-left-radius: 3px;}
267
+ .ace_br10{border-top-right-radius : 3px; border-bottom-left-radius: 3px;}
268
+ .ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-left-radius: 3px;}
269
+ .ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
270
+ .ace_br13{border-top-left-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
271
+ .ace_br14{border-top-right-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
272
+ .ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
273
+
274
+
275
+ .ace_editor {
276
+ position: relative;
277
+ overflow: hidden;
278
+ padding: 0;
279
+ font: 12px/normal 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'Source Code Pro', 'source-code-pro', monospace;
280
+ direction: ltr;
281
+ text-align: left;
282
+ -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
283
+ forced-color-adjust: none;
284
+ }
285
+
286
+ .ace_scroller {
287
+ position: absolute;
288
+ overflow: hidden;
289
+ top: 0;
290
+ bottom: 0;
291
+ background-color: inherit;
292
+ -ms-user-select: none;
293
+ -moz-user-select: none;
294
+ -webkit-user-select: none;
295
+ user-select: none;
296
+ cursor: text;
297
+ }
298
+
299
+ .ace_content {
300
+ position: absolute;
301
+ box-sizing: border-box;
302
+ min-width: 100%;
303
+ contain: style size layout;
304
+ font-variant-ligatures: no-common-ligatures;
305
+ }
306
+ .ace_invisible {
307
+ font-variant-ligatures: none;
308
+ }
309
+
310
+ .ace_keyboard-focus:focus {
311
+ box-shadow: inset 0 0 0 2px #5E9ED6;
312
+ outline: none;
313
+ }
314
+
315
+ .ace_dragging .ace_scroller:before{
316
+ position: absolute;
317
+ top: 0;
318
+ left: 0;
319
+ right: 0;
320
+ bottom: 0;
321
+ content: '';
322
+ background: rgba(250, 250, 250, 0.01);
323
+ z-index: 1000;
324
+ }
325
+ .ace_dragging.ace_dark .ace_scroller:before{
326
+ background: rgba(0, 0, 0, 0.01);
327
+ }
328
+
329
+ .ace_gutter {
330
+ position: absolute;
331
+ overflow : hidden;
332
+ width: auto;
333
+ top: 0;
334
+ bottom: 0;
335
+ left: 0;
336
+ cursor: default;
337
+ z-index: 4;
338
+ -ms-user-select: none;
339
+ -moz-user-select: none;
340
+ -webkit-user-select: none;
341
+ user-select: none;
342
+ contain: style size layout;
343
+ }
344
+
345
+ .ace_gutter-active-line {
346
+ position: absolute;
347
+ left: 0;
348
+ right: 0;
349
+ }
350
+
351
+ .ace_scroller.ace_scroll-left:after {
352
+ content: "";
353
+ position: absolute;
354
+ top: 0;
355
+ right: 0;
356
+ bottom: 0;
357
+ left: 0;
358
+ box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;
359
+ pointer-events: none;
360
+ }
361
+
362
+ .ace_gutter-cell, .ace_gutter-cell_svg-icons {
363
+ position: absolute;
364
+ top: 0;
365
+ left: 0;
366
+ right: 0;
367
+ padding-left: 19px;
368
+ padding-right: 6px;
369
+ background-repeat: no-repeat;
370
+ }
371
+
372
+ .ace_gutter-cell_svg-icons .ace_gutter_annotation {
373
+ margin-left: -14px;
374
+ float: left;
375
+ }
376
+
377
+ .ace_gutter-cell .ace_gutter_annotation {
378
+ margin-left: -19px;
379
+ float: left;
380
+ }
381
+
382
+ .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 {
383
+ 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==");
384
+ background-repeat: no-repeat;
385
+ background-position: 2px center;
386
+ }
387
+
388
+ .ace_gutter-cell.ace_warning, .ace_icon.ace_warning, .ace_icon.ace_warning_fold {
389
+ 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==");
390
+ background-repeat: no-repeat;
391
+ background-position: 2px center;
392
+ }
393
+
394
+ .ace_gutter-cell.ace_info, .ace_icon.ace_info, .ace_gutter-cell.ace_hint, .ace_icon.ace_hint {
395
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");
396
+ background-repeat: no-repeat;
397
+ background-position: 2px center;
398
+ }
399
+
400
+ .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 {
401
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");
402
+ }
403
+
404
+ .ace_icon_svg.ace_error {
405
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJyZWQiIHNoYXBlLXJlbmRlcmluZz0iZ2VvbWV0cmljUHJlY2lzaW9uIj4KPGNpcmNsZSBmaWxsPSJub25lIiBjeD0iOCIgY3k9IjgiIHI9IjciIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPGxpbmUgeDE9IjExIiB5MT0iNSIgeDI9IjUiIHkyPSIxMSIvPgo8bGluZSB4MT0iMTEiIHkxPSIxMSIgeDI9IjUiIHkyPSI1Ii8+CjwvZz4KPC9zdmc+");
406
+ background-color: crimson;
407
+ }
408
+ .ace_icon_svg.ace_security {
409
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8ZyBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZT0iZGFya29yYW5nZSIgZmlsbD0ibm9uZSIgc2hhcGUtcmVuZGVyaW5nPSJnZW9tZXRyaWNQcmVjaXNpb24iPgogICAgICAgIDxwYXRoIGNsYXNzPSJzdHJva2UtbGluZWpvaW4tcm91bmQiIGQ9Ik04IDE0LjgzMDdDOCAxNC44MzA3IDIgMTIuOTA0NyAyIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOEM3Ljk4OTk5IDEuMzQ5MTggMTAuNjkgMy4yNjU0OCAxNCAzLjI2NTQ4VjguMDg5OTJDMTQgMTIuOTA0NyA4IDE0LjgzMDcgOCAxNC44MzA3WiIvPgogICAgICAgIDxwYXRoIGQ9Ik0yIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOCIvPgogICAgICAgIDxwYXRoIGQ9Ik0xMy45OSA4LjA4OTkyVjMuMjY1NDhDMTAuNjggMy4yNjU0OCA4IDEuMzQ5MTggOCAxLjM0OTE4Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggNFY5Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggMTBWMTIiLz4KICAgIDwvZz4KPC9zdmc+");
410
+ background-color: crimson;
411
+ }
412
+ .ace_icon_svg.ace_warning {
413
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJkYXJrb3JhbmdlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+Cjxwb2x5Z29uIHN0cm9rZS1saW5lam9pbj0icm91bmQiIGZpbGw9Im5vbmUiIHBvaW50cz0iOCAxIDE1IDE1IDEgMTUgOCAxIi8+CjxyZWN0IHg9IjgiIHk9IjEyIiB3aWR0aD0iMC4wMSIgaGVpZ2h0PSIwLjAxIi8+CjxsaW5lIHgxPSI4IiB5MT0iNiIgeDI9IjgiIHkyPSIxMCIvPgo8L2c+Cjwvc3ZnPg==");
414
+ background-color: darkorange;
415
+ }
416
+ .ace_icon_svg.ace_info {
417
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJibHVlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+CjxjaXJjbGUgZmlsbD0ibm9uZSIgY3g9IjgiIGN5PSI4IiByPSI3IiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+Cjxwb2x5bGluZSBwb2ludHM9IjggMTEgOCA4Ii8+Cjxwb2x5bGluZSBwb2ludHM9IjkgOCA2IDgiLz4KPGxpbmUgeDE9IjEwIiB5MT0iMTEiIHgyPSI2IiB5Mj0iMTEiLz4KPHJlY3QgeD0iOCIgeT0iNSIgd2lkdGg9IjAuMDEiIGhlaWdodD0iMC4wMSIvPgo8L2c+Cjwvc3ZnPg==");
418
+ background-color: royalblue;
419
+ }
420
+ .ace_icon_svg.ace_hint {
421
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8ZyBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZT0ic2lsdmVyIiBmaWxsPSJub25lIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTYgMTRIMTAiLz4KICAgICAgICA8cGF0aCBkPSJNOCAxMUg5QzkgOS40NzAwMiAxMiA4LjU0MDAyIDEyIDUuNzYwMDJDMTIuMDIgNC40MDAwMiAxMS4zOSAzLjM2MDAyIDEwLjQzIDIuNjcwMDJDOSAxLjY0MDAyIDcuMDAwMDEgMS42NDAwMiA1LjU3MDAxIDIuNjcwMDJDNC42MTAwMSAzLjM2MDAyIDMuOTggNC40MDAwMiA0IDUuNzYwMDJDNCA4LjU0MDAyIDcuMDAwMDEgOS40NzAwMiA3LjAwMDAxIDExSDhaIi8+CiAgICA8L2c+Cjwvc3ZnPg==");
422
+ background-color: silver;
423
+ }
424
+
425
+ .ace_icon_svg.ace_error_fold {
426
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiIgZmlsbD0ibm9uZSI+CiAgPHBhdGggZD0ibSAxOC45Mjk4NTEsNy44Mjk4MDc2IGMgMC4xNDYzNTMsNi4zMzc0NjA0IC02LjMyMzE0Nyw3Ljc3Nzg0NDQgLTcuNDc3OTEyLDcuNzc3ODQ0NCAtMi4xMDcyNzI2LC0wLjEyODc1IDUuMTE3Njc4LDAuMzU2MjQ5IDUuMDUxNjk4LC03Ljg3MDA2MTggLTAuNjA0NjcyLC04LjAwMzk3MzQ5IC03LjA3NzI3MDYsLTcuNTYzMTE4OSAtNC44NTczLC03LjQzMDM5NTU2IDEuNjA2LC0wLjExNTE0MjI1IDYuODk3NDg1LDEuMjYyNTQ1OTYgNy4yODM1MTQsNy41MjI2MTI5NiB6IiBmaWxsPSJjcmltc29uIiBzdHJva2Utd2lkdGg9IjIiLz4KICA8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0ibSA4LjExNDc1NjIsMi4wNTI5ODI4IGMgMy4zNDkxNjk4LDAgNi4wNjQxMzI4LDIuNjc2ODYyNyA2LjA2NDEzMjgsNS45Nzg5NTMgMCwzLjMwMjExMjIgLTIuNzE0OTYzLDUuOTc4OTIwMiAtNi4wNjQxMzI4LDUuOTc4OTIwMiAtMy4zNDkxNDczLDAgLTYuMDY0MTc3MiwtMi42NzY4MDggLTYuMDY0MTc3MiwtNS45Nzg5MjAyIDAuMDA1MzksLTMuMjk5ODg2MSAyLjcxNzI2NTYsLTUuOTczNjQwOCA2LjA2NDE3NzIsLTUuOTc4OTUzIHogbSAwLC0xLjczNTgyNzE5IGMgLTQuMzIxNDgzNiwwIC03LjgyNDc0MDM4LDMuNDU0MDE4NDkgLTcuODI0NzQwMzgsNy43MTQ3ODAxOSAwLDQuMjYwNzI4MiAzLjUwMzI1Njc4LDcuNzE0NzQ1MiA3LjgyNDc0MDM4LDcuNzE0NzQ1MiA0LjMyMTQ0OTgsMCA3LjgyNDY5OTgsLTMuNDU0MDE3IDcuODI0Njk5OCwtNy43MTQ3NDUyIDAsLTIuMDQ2MDkxNCAtMC44MjQzOTIsLTQuMDA4MzY3MiAtMi4yOTE3NTYsLTUuNDU1MTc0NiBDIDEyLjE4MDIyNSwxLjEyOTk2NDggMTAuMTkwMDEzLDAuMzE3MTU1NjEgOC4xMTQ3NTYyLDAuMzE3MTU1NjEgWiBNIDYuOTM3NDU2Myw4LjI0MDU5ODUgNC42NzE4Njg1LDEwLjQ4NTg1MiA2LjAwODY4MTQsMTEuODc2NzI4IDguMzE3MDAzNSw5LjYwMDc5MTEgMTAuNjI1MzM3LDExLjg3NjcyOCAxMS45NjIxMzgsMTAuNDg1ODUyIDkuNjk2NTUwOCw4LjI0MDU5ODUgMTEuOTYyMTM4LDYuMDA2ODA2NiAxMC41NzMyNDYsNC42Mzc0MzM1IDguMzE3MDAzNSw2Ljg3MzQyOTcgNi4wNjA3NjA3LDQuNjM3NDMzNSA0LjY3MTg2ODUsNi4wMDY4MDY2IFoiIGZpbGw9ImNyaW1zb24iIHN0cm9rZS13aWR0aD0iMiIvPgo8L3N2Zz4=");
427
+ background-color: crimson;
428
+ }
429
+ .ace_icon_svg.ace_security_fold {
430
+ -webkit-mask-image: url("data:image/svg+xml;base64,CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMTcgMTQiIGZpbGw9Im5vbmUiPgogICAgPHBhdGggZD0iTTEwLjAwMDEgMTMuNjk5MkMxMC4wMDAxIDEzLjY5OTIgMTEuOTI0MSAxMy40NzYzIDEzIDEyLjY5OTJDMTQuNDEzOSAxMS42NzgxIDE2IDEwLjUgMTYuMTI1MSA2LjgxMTI2VjIuNTg5ODdDMTYuMTI1MSAyLjU0NzY4IDE2LjEyMjEgMi41MDYxOSAxNi4xMTY0IDIuNDY1NTlWMS43MTQ4NUgxNS4yNDE0TDE1LjIzMDcgMS43MTQ4NEwxNC42MjUxIDEuNjk5MjJWNi44MTEyM0MxNC42MjUxIDguNTEwNjEgMTQuNjI1MSA5LjQ2NDYxIDEyLjc4MjQgMTEuNzIxQzEyLjE1ODYgMTIuNDg0OCAxMC4wMDAxIDEzLjY5OTIgMTAuMDAwMSAxMy42OTkyWiIgZmlsbD0iY3JpbXNvbiIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgICA8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTcuMzM2MDkgMC4zNjc0NzVDNy4wMzIxNCAwLjE1MjY1MiA2LjYyNTQ4IDAuMTUzNjE0IDYuMzIyNTMgMC4zNjk5OTdMNi4zMDg2OSAwLjM3OTU1NEM2LjI5NTUzIDAuMzg4NTg4IDYuMjczODggMC40MDMyNjYgNi4yNDQxNyAwLjQyMjc4OUM2LjE4NDcxIDAuNDYxODYgNi4wOTMyMSAwLjUyMDE3MSA1Ljk3MzEzIDAuNTkxMzczQzUuNzMyNTEgMC43MzQwNTkgNS4zNzk5IDAuOTI2ODY0IDQuOTQyNzkgMS4xMjAwOUM0LjA2MTQ0IDEuNTA5NyAyLjg3NTQxIDEuODgzNzcgMS41ODk4NCAxLjg4Mzc3SDAuNzE0ODQ0VjIuNzU4NzdWNi45ODAxNUMwLjcxNDg0NCA5LjQ5Mzc0IDIuMjg4NjYgMTEuMTk3MyAzLjcwMjU0IDEyLjIxODVDNC40MTg0NSAxMi43MzU1IDUuMTI4NzQgMTMuMTA1MyA1LjY1NzMzIDEzLjM0NTdDNS45MjI4NCAxMy40NjY0IDYuMTQ1NjYgMTMuNTU1OSA2LjMwNDY1IDEzLjYxNjFDNi4zODQyMyAxMy42NDYyIDYuNDQ4MDUgMTMuNjY5IDYuNDkzNDkgMTMuNjg0OEM2LjUxNjIyIDEzLjY5MjcgNi41MzQzOCAxMy42OTg5IDYuNTQ3NjQgMTMuNzAzM0w2LjU2MzgyIDEzLjcwODdMNi41NjkwOCAxMy43MTA0TDYuNTcwOTkgMTMuNzExTDYuODM5ODQgMTMuNzUzM0w2LjU3MjQyIDEzLjcxMTVDNi43NDYzMyAxMy43NjczIDYuOTMzMzUgMTMuNzY3MyA3LjEwNzI3IDEzLjcxMTVMNy4xMDg3IDEzLjcxMUw3LjExMDYxIDEzLjcxMDRMNy4xMTU4NyAxMy43MDg3TDcuMTMyMDUgMTMuNzAzM0M3LjE0NTMxIDEzLjY5ODkgNy4xNjM0NiAxMy42OTI3IDcuMTg2MTkgMTMuNjg0OEM3LjIzMTY0IDEzLjY2OSA3LjI5NTQ2IDEzLjY0NjIgNy4zNzUwMyAxMy42MTYxQzcuNTM0MDMgMTMuNTU1OSA3Ljc1Njg1IDEzLjQ2NjQgOC4wMjIzNiAxMy4zNDU3QzguNTUwOTUgMTMuMTA1MyA5LjI2MTIzIDEyLjczNTUgOS45NzcxNSAxMi4yMTg1QzExLjM5MSAxMS4xOTczIDEyLjk2NDggOS40OTM3NyAxMi45NjQ4IDYuOTgwMThWMi43NTg4QzEyLjk2NDggMi43MTY2IDEyLjk2MTkgMi42NzUxMSAxMi45NTYxIDIuNjM0NTFWMS44ODM3N0gxMi4wODExQzEyLjA3NzUgMS44ODM3NyAxMi4wNzQgMS44ODM3NyAxMi4wNzA0IDEuODgzNzdDMTAuNzk3OSAxLjg4MDA0IDkuNjE5NjIgMS41MTEwMiA4LjczODk0IDEuMTI0ODZDOC43MzUzNCAxLjEyMzI3IDguNzMxNzQgMS4xMjE2OCA4LjcyODE0IDEuMTIwMDlDOC4yOTEwMyAwLjkyNjg2NCA3LjkzODQyIDAuNzM0MDU5IDcuNjk3NzkgMC41OTEzNzNDNy41Nzc3MiAwLjUyMDE3MSA3LjQ4NjIyIDAuNDYxODYgNy40MjY3NiAwLjQyMjc4OUM3LjM5NzA1IDAuNDAzMjY2IDcuMzc1MzkgMC4zODg1ODggNy4zNjIyNCAwLjM3OTU1NEw3LjM0ODk2IDAuMzcwMzVDNy4zNDg5NiAwLjM3MDM1IDcuMzQ4NDcgMC4zNzAwMiA3LjM0NTYzIDAuMzc0MDU0TDcuMzM3NzkgMC4zNjg2NTlMNy4zMzYwOSAwLjM2NzQ3NVpNOC4wMzQ3MSAyLjcyNjkxQzguODYwNCAzLjA5MDYzIDkuOTYwNjYgMy40NjMwOSAxMS4yMDYxIDMuNTg5MDdWNi45ODAxNUgxMS4yMTQ4QzExLjIxNDggOC42Nzk1MyAxMC4xNjM3IDkuOTI1MDcgOC45NTI1NCAxMC43OTk4QzguMzU1OTUgMTEuMjMwNiA3Ljc1Mzc0IDExLjU0NTQgNy4yOTc5NiAxMS43NTI3QzcuMTE2NzEgMTEuODM1MSA2Ljk2MDYyIDExLjg5OTYgNi44Mzk4NCAxMS45NDY5QzYuNzE5MDYgMTEuODk5NiA2LjU2Mjk3IDExLjgzNTEgNi4zODE3MyAxMS43NTI3QzUuOTI1OTUgMTEuNTQ1NCA1LjMyMzczIDExLjIzMDYgNC43MjcxNSAxMC43OTk4QzMuNTE2MDMgOS45MjUwNyAyLjQ2NDg0IDguNjc5NTUgMi40NjQ4NCA2Ljk4MDE4VjMuNTg5MDlDMy43MTczOCAzLjQ2MjM5IDQuODIzMDggMy4wODYzOSA1LjY1MDMzIDIuNzIwNzFDNi4xNDIyOCAyLjUwMzI0IDYuNTQ0ODUgMi4yODUzNyA2LjgzMjU0IDIuMTE2MjRDNy4xMjE4MSAyLjI4NTM1IDcuNTI3IDIuNTAzNTIgOC4wMjE5NiAyLjcyMTMxQzguMDI2MiAyLjcyMzE3IDguMDMwNDUgMi43MjUwNCA4LjAzNDcxIDIuNzI2OTFaTTUuOTY0ODQgMy40MDE0N1Y3Ljc3NjQ3SDcuNzE0ODRWMy40MDE0N0g1Ljk2NDg0Wk01Ljk2NDg0IDEwLjQwMTVWOC42NTE0N0g3LjcxNDg0VjEwLjQwMTVINS45NjQ4NFoiIGZpbGw9ImNyaW1zb24iIHN0cm9rZS13aWR0aD0iMiIvPgo8L3N2Zz4=");
431
+ background-color: crimson;
432
+ }
433
+ .ace_icon_svg.ace_warning_fold {
434
+ -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjAiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAyMCAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xNC43NzY5IDE0LjczMzdMOC42NTE5MiAyLjQ4MzY5QzguMzI5NDYgMS44Mzg3NyA3LjQwOTEzIDEuODM4NzcgNy4wODY2NyAyLjQ4MzY5TDAuOTYxNjY5IDE0LjczMzdDMC42NzA3NzUgMTUuMzE1NSAxLjA5MzgzIDE2IDEuNzQ0MjkgMTZIMTMuOTk0M0MxNC42NDQ4IDE2IDE1LjA2NzggMTUuMzE1NSAxNC43NzY5IDE0LjczMzdaTTMuMTYwMDcgMTQuMjVMNy44NjkyOSA0LjgzMTU2TDEyLjU3ODUgMTQuMjVIMy4xNjAwN1pNOC43NDQyOSAxMS42MjVWMTMuMzc1SDYuOTk0MjlWMTEuNjI1SDguNzQ0MjlaTTYuOTk0MjkgMTAuNzVWNy4yNUg4Ljc0NDI5VjEwLjc1SDYuOTk0MjlaIiBmaWxsPSIjRUM3MjExIi8+CjxwYXRoIGQ9Ik0xMS4xOTkxIDIuOTUyMzhDMTAuODgwOSAyLjMxNDY3IDEwLjM1MzcgMS44MDUyNiA5LjcwNTUgMS41MDlMMTEuMDQxIDEuMDY5NzhDMTEuNjg4MyAwLjk0OTgxNCAxMi4zMzcgMS4yNzI2MyAxMi42MzE3IDEuODYxNDFMMTcuNjEzNiAxMS44MTYxQzE4LjM1MjcgMTMuMjkyOSAxNy41OTM4IDE1LjA4MDQgMTYuMDE4IDE1LjU3NDVDMTYuNDA0NCAxNC40NTA3IDE2LjMyMzEgMTMuMjE4OCAxNS43OTI0IDEyLjE1NTVMMTEuMTk5MSAyLjk1MjM4WiIgZmlsbD0iI0VDNzIxMSIvPgo8L3N2Zz4=");
435
+ background-color: darkorange;
436
+ }
437
+
438
+ .ace_scrollbar {
439
+ contain: strict;
440
+ position: absolute;
441
+ right: 0;
442
+ bottom: 0;
443
+ z-index: 6;
444
+ }
445
+
446
+ .ace_scrollbar-inner {
447
+ position: absolute;
448
+ cursor: text;
449
+ left: 0;
450
+ top: 0;
451
+ }
452
+
453
+ .ace_scrollbar-v{
454
+ overflow-x: hidden;
455
+ overflow-y: scroll;
456
+ top: 0;
457
+ }
458
+
459
+ .ace_scrollbar-h {
460
+ overflow-x: scroll;
461
+ overflow-y: hidden;
462
+ left: 0;
463
+ }
464
+
465
+ .ace_print-margin {
466
+ position: absolute;
467
+ height: 100%;
468
+ }
469
+
470
+ .ace_text-input {
471
+ position: absolute;
472
+ z-index: 0;
473
+ width: 0.5em;
474
+ height: 1em;
475
+ opacity: 0;
476
+ background: transparent;
477
+ -moz-appearance: none;
478
+ appearance: none;
479
+ border: none;
480
+ resize: none;
481
+ outline: none;
482
+ overflow: hidden;
483
+ font: inherit;
484
+ padding: 0 1px;
485
+ margin: 0 -1px;
486
+ contain: strict;
487
+ -ms-user-select: text;
488
+ -moz-user-select: text;
489
+ -webkit-user-select: text;
490
+ user-select: text;
491
+ /*with \`pre-line\` chrome inserts &nbsp; instead of space*/
492
+ white-space: pre!important;
493
+ }
494
+ .ace_text-input.ace_composition {
495
+ background: transparent;
496
+ color: inherit;
497
+ z-index: 1000;
498
+ opacity: 1;
499
+ }
500
+ .ace_composition_placeholder { color: transparent }
501
+ .ace_composition_marker {
502
+ border-bottom: 1px solid;
503
+ position: absolute;
504
+ border-radius: 0;
505
+ margin-top: 1px;
506
+ }
507
+
508
+ [ace_nocontext=true] {
509
+ transform: none!important;
510
+ filter: none!important;
511
+ clip-path: none!important;
512
+ mask : none!important;
513
+ contain: none!important;
514
+ perspective: none!important;
515
+ mix-blend-mode: initial!important;
516
+ z-index: auto;
517
+ }
518
+
519
+ .ace_layer {
520
+ z-index: 1;
521
+ position: absolute;
522
+ overflow: hidden;
523
+ /* workaround for chrome bug https://github.com/ajaxorg/ace/issues/2312*/
524
+ word-wrap: normal;
525
+ white-space: pre;
526
+ height: 100%;
527
+ width: 100%;
528
+ box-sizing: border-box;
529
+ /* setting pointer-events: auto; on node under the mouse, which changes
530
+ during scroll, will break mouse wheel scrolling in Safari */
531
+ pointer-events: none;
532
+ }
533
+
534
+ .ace_gutter-layer {
535
+ position: relative;
536
+ width: auto;
537
+ text-align: right;
538
+ pointer-events: auto;
539
+ height: 1000000px;
540
+ contain: style size layout;
541
+ }
542
+
543
+ .ace_text-layer {
544
+ font: inherit !important;
545
+ position: absolute;
546
+ height: 1000000px;
547
+ width: 1000000px;
548
+ contain: style size layout;
549
+ }
550
+
551
+ .ace_text-layer > .ace_line, .ace_text-layer > .ace_line_group {
552
+ contain: style size layout;
553
+ position: absolute;
554
+ top: 0;
555
+ left: 0;
556
+ right: 0;
557
+ }
558
+
559
+ .ace_hidpi .ace_text-layer,
560
+ .ace_hidpi .ace_gutter-layer,
561
+ .ace_hidpi .ace_content,
562
+ .ace_hidpi .ace_gutter {
563
+ contain: strict;
564
+ }
565
+ .ace_hidpi .ace_text-layer > .ace_line,
566
+ .ace_hidpi .ace_text-layer > .ace_line_group {
567
+ contain: strict;
568
+ }
569
+
570
+ .ace_cjk {
571
+ display: inline-block;
572
+ text-align: center;
573
+ }
574
+
575
+ .ace_cursor-layer {
576
+ z-index: 4;
577
+ }
578
+
579
+ .ace_cursor {
580
+ z-index: 4;
581
+ position: absolute;
582
+ box-sizing: border-box;
583
+ border-left: 2px solid;
584
+ /* workaround for smooth cursor repaintng whole screen in chrome */
585
+ transform: translatez(0);
586
+ }
587
+
588
+ .ace_multiselect .ace_cursor {
589
+ border-left-width: 1px;
590
+ }
591
+
592
+ .ace_slim-cursors .ace_cursor {
593
+ border-left-width: 1px;
594
+ }
595
+
596
+ .ace_overwrite-cursors .ace_cursor {
597
+ border-left-width: 0;
598
+ border-bottom: 1px solid;
599
+ }
600
+
601
+ .ace_hidden-cursors .ace_cursor {
602
+ opacity: 0.2;
603
+ }
604
+
605
+ .ace_hasPlaceholder .ace_hidden-cursors .ace_cursor {
606
+ opacity: 0;
607
+ }
608
+
609
+ .ace_smooth-blinking .ace_cursor {
610
+ transition: opacity 0.18s;
611
+ }
612
+
613
+ .ace_animate-blinking .ace_cursor {
614
+ animation-duration: 1000ms;
615
+ animation-timing-function: step-end;
616
+ animation-name: blink-ace-animate;
617
+ animation-iteration-count: infinite;
618
+ }
619
+
620
+ .ace_animate-blinking.ace_smooth-blinking .ace_cursor {
621
+ animation-duration: 1000ms;
622
+ animation-timing-function: ease-in-out;
623
+ animation-name: blink-ace-animate-smooth;
624
+ }
625
+
626
+ @keyframes blink-ace-animate {
627
+ from, to { opacity: 1; }
628
+ 60% { opacity: 0; }
629
+ }
630
+
631
+ @keyframes blink-ace-animate-smooth {
632
+ from, to { opacity: 1; }
633
+ 45% { opacity: 1; }
634
+ 60% { opacity: 0; }
635
+ 85% { opacity: 0; }
636
+ }
637
+
638
+ .ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {
639
+ position: absolute;
640
+ z-index: 3;
641
+ }
642
+
643
+ .ace_marker-layer .ace_selection {
644
+ position: absolute;
645
+ z-index: 5;
646
+ }
647
+
648
+ .ace_marker-layer .ace_bracket {
649
+ position: absolute;
650
+ z-index: 6;
651
+ }
652
+
653
+ .ace_marker-layer .ace_error_bracket {
654
+ position: absolute;
655
+ border-bottom: 1px solid #DE5555;
656
+ border-radius: 0;
657
+ }
658
+
659
+ .ace_marker-layer .ace_active-line {
660
+ position: absolute;
661
+ z-index: 2;
662
+ }
663
+
664
+ .ace_marker-layer .ace_selected-word {
665
+ position: absolute;
666
+ z-index: 4;
667
+ box-sizing: border-box;
668
+ }
669
+
670
+ .ace_line .ace_fold {
671
+ box-sizing: border-box;
672
+
673
+ display: inline-block;
674
+ height: 11px;
675
+ margin-top: -2px;
676
+ vertical-align: middle;
677
+
678
+ background-image:
679
+ url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),
680
+ url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");
681
+ background-repeat: no-repeat, repeat-x;
682
+ background-position: center center, top left;
683
+ color: transparent;
684
+
685
+ border: 1px solid black;
686
+ border-radius: 2px;
687
+
688
+ cursor: pointer;
689
+ pointer-events: auto;
690
+ }
691
+
692
+ .ace_dark .ace_fold {
693
+ }
694
+
695
+ .ace_fold:hover{
696
+ background-image:
697
+ url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),
698
+ url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");
699
+ }
700
+
701
+ .ace_tooltip {
702
+ background-color: #f5f5f5;
703
+ border: 1px solid gray;
704
+ border-radius: 1px;
705
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
706
+ color: black;
707
+ padding: 3px 4px;
708
+ position: fixed;
709
+ z-index: 999999;
710
+ box-sizing: border-box;
711
+ cursor: default;
712
+ white-space: pre-wrap;
713
+ word-wrap: break-word;
714
+ line-height: normal;
715
+ font-style: normal;
716
+ font-weight: normal;
717
+ letter-spacing: normal;
718
+ pointer-events: none;
719
+ overflow: auto;
720
+ max-width: min(33em, 66vw);
721
+ overscroll-behavior: contain;
722
+ }
723
+ .ace_tooltip pre {
724
+ white-space: pre-wrap;
725
+ }
726
+
727
+ .ace_tooltip.ace_dark {
728
+ background-color: #636363;
729
+ color: #fff;
730
+ }
731
+
732
+ .ace_tooltip:focus {
733
+ outline: 1px solid #5E9ED6;
734
+ }
735
+
736
+ .ace_icon {
737
+ display: inline-block;
738
+ width: 18px;
739
+ vertical-align: top;
740
+ }
741
+
742
+ .ace_icon_svg {
743
+ display: inline-block;
744
+ width: 12px;
745
+ vertical-align: top;
746
+ -webkit-mask-repeat: no-repeat;
747
+ -webkit-mask-size: 12px;
748
+ -webkit-mask-position: center;
749
+ }
750
+
751
+ .ace_folding-enabled > .ace_gutter-cell, .ace_folding-enabled > .ace_gutter-cell_svg-icons {
752
+ padding-right: 13px;
753
+ }
754
+
755
+ .ace_fold-widget, .ace_custom-widget {
756
+ box-sizing: border-box;
757
+
758
+ margin: 0 -12px 0 1px;
759
+ display: none;
760
+ width: 11px;
761
+ vertical-align: top;
762
+
763
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");
764
+ background-repeat: no-repeat;
765
+ background-position: center;
766
+
767
+ border-radius: 3px;
768
+
769
+ border: 1px solid transparent;
770
+ cursor: pointer;
771
+ pointer-events: auto;
772
+ }
773
+
774
+ .ace_custom-widget {
775
+ background: none;
776
+ }
777
+
778
+ .ace_folding-enabled .ace_fold-widget {
779
+ display: inline-block;
780
+ }
781
+
782
+ .ace_fold-widget.ace_end {
783
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");
784
+ }
785
+
786
+ .ace_fold-widget.ace_closed {
787
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");
788
+ }
789
+
790
+ .ace_fold-widget:hover {
791
+ border: 1px solid rgba(0, 0, 0, 0.3);
792
+ background-color: rgba(255, 255, 255, 0.2);
793
+ box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);
794
+ }
795
+
796
+ .ace_fold-widget:active {
797
+ border: 1px solid rgba(0, 0, 0, 0.4);
798
+ background-color: rgba(0, 0, 0, 0.05);
799
+ box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);
800
+ }
801
+ /**
802
+ * Dark version for fold widgets
803
+ */
804
+ .ace_dark .ace_fold-widget {
805
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");
806
+ }
807
+ .ace_dark .ace_fold-widget.ace_end {
808
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");
809
+ }
810
+ .ace_dark .ace_fold-widget.ace_closed {
811
+ background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");
812
+ }
813
+ .ace_dark .ace_fold-widget:hover {
814
+ box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);
815
+ background-color: rgba(255, 255, 255, 0.1);
816
+ }
817
+ .ace_dark .ace_fold-widget:active {
818
+ box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);
819
+ }
820
+
821
+ .ace_inline_button {
822
+ border: 1px solid lightgray;
823
+ display: inline-block;
824
+ margin: -1px 8px;
825
+ padding: 0 5px;
826
+ pointer-events: auto;
827
+ cursor: pointer;
828
+ }
829
+ .ace_inline_button:hover {
830
+ border-color: gray;
831
+ background: rgba(200,200,200,0.2);
832
+ display: inline-block;
833
+ pointer-events: auto;
834
+ }
835
+
836
+ .ace_fold-widget.ace_invalid {
837
+ background-color: #FFB4B4;
838
+ border-color: #DE5555;
839
+ }
840
+
841
+ .ace_fade-fold-widgets .ace_fold-widget {
842
+ transition: opacity 0.4s ease 0.05s;
843
+ opacity: 0;
844
+ }
845
+
846
+ .ace_fade-fold-widgets:hover .ace_fold-widget {
847
+ transition: opacity 0.05s ease 0.05s;
848
+ opacity:1;
849
+ }
850
+
851
+ .ace_underline {
852
+ text-decoration: underline;
853
+ }
854
+
855
+ .ace_bold {
856
+ font-weight: bold;
857
+ }
858
+
859
+ .ace_nobold .ace_bold {
860
+ font-weight: normal;
861
+ }
862
+
863
+ .ace_italic {
864
+ font-style: italic;
865
+ }
866
+
867
+
868
+ .ace_error-marker {
869
+ background-color: rgba(255, 0, 0,0.2);
870
+ position: absolute;
871
+ z-index: 9;
872
+ }
873
+
874
+ .ace_highlight-marker {
875
+ background-color: rgba(255, 255, 0,0.2);
876
+ position: absolute;
877
+ z-index: 8;
878
+ }
879
+
880
+ .ace_mobile-menu {
881
+ position: absolute;
882
+ line-height: 1.5;
883
+ border-radius: 4px;
884
+ -ms-user-select: none;
885
+ -moz-user-select: none;
886
+ -webkit-user-select: none;
887
+ user-select: none;
888
+ background: white;
889
+ box-shadow: 1px 3px 2px grey;
890
+ border: 1px solid #dcdcdc;
891
+ color: black;
892
+ }
893
+ .ace_dark > .ace_mobile-menu {
894
+ background: #333;
895
+ color: #ccc;
896
+ box-shadow: 1px 3px 2px grey;
897
+ border: 1px solid #444;
898
+
899
+ }
900
+ .ace_mobile-button {
901
+ padding: 2px;
902
+ cursor: pointer;
903
+ overflow: hidden;
904
+ }
905
+ .ace_mobile-button:hover {
906
+ background-color: #eee;
907
+ opacity:1;
908
+ }
909
+ .ace_mobile-button:active {
910
+ background-color: #ddd;
911
+ }
912
+
913
+ .ace_placeholder {
914
+ position: relative;
915
+ font-family: arial;
916
+ transform: scale(0.9);
917
+ transform-origin: left;
918
+ white-space: pre;
919
+ opacity: 0.7;
920
+ margin: 0 10px;
921
+ z-index: 1;
922
+ }
923
+
924
+ .ace_ghost_text {
925
+ opacity: 0.5;
926
+ font-style: italic;
927
+ }
928
+
929
+ .ace_ghost_text_container > div {
930
+ white-space: pre;
931
+ }
932
+
933
+ .ghost_text_line_wrapped::after {
934
+ content: "↩";
935
+ position: absolute;
936
+ }
937
+
938
+ .ace_lineWidgetContainer.ace_ghost_text {
939
+ margin: 0px 4px
940
+ }
941
+
942
+ .ace_screenreader-only {
943
+ position:absolute;
944
+ left:-10000px;
945
+ top:auto;
946
+ width:1px;
947
+ height:1px;
948
+ overflow:hidden;
949
+ }
950
+
951
+ .ace_hidden_token {
952
+ display: none;
953
+ }`}),ace.define("ace/layer/decorators",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter"],function(e,r,m){var f=e("../lib/dom"),g=e("../lib/oop"),w=e("../lib/event_emitter").EventEmitter,u=(function(){function d(a,l){this.renderer=l,this.pixelRatio=1,this.maxHeight=l.layerConfig.maxHeight,this.lineHeight=l.layerConfig.lineHeight,this.minDecorationHeight=2*this.pixelRatio|0,this.halfMinDecorationHeight=this.minDecorationHeight/2|0,this.colors={},this.colors.dark={error:"rgba(255, 18, 18, 1)",warning:"rgba(18, 136, 18, 1)",info:"rgba(18, 18, 136, 1)"},this.colors.light={error:"rgb(255,51,51)",warning:"rgb(32,133,72)",info:"rgb(35,68,138)"},this.setScrollBarV(a)}return d.prototype.$createCanvas=function(){this.canvas=f.createElement("canvas"),this.canvas.style.top="0px",this.canvas.style.right="0px",this.canvas.style.zIndex="7",this.canvas.style.position="absolute"},d.prototype.setScrollBarV=function(a){this.$createCanvas(),this.scrollbarV=a,a.element.appendChild(this.canvas),this.setDimensions()},d.prototype.$updateDecorators=function(a){if(typeof this.canvas.getContext!="function")return;var l=this.renderer.theme.isDark===!0?this.colors.dark:this.colors.light;this.setDimensions(a);var c=this.canvas.getContext("2d");function h(O,S){return O.priority<S.priority?-1:O.priority>S.priority?1:0}var o=this.renderer.session.$annotations;if(c.clearRect(0,0,this.canvas.width,this.canvas.height),o){var s={info:1,warning:2,error:3};o.forEach(function(O){O.priority=s[O.type]||null}),o=o.sort(h);for(var p=0;p<o.length;p++){var b=o[p].row,x=this.getVerticalOffsetForRow(b),M=x+this.lineHeight,R=Math.round(this.heightRatio*x),k=Math.round(this.heightRatio*M),C=Math.round((R+k)/2),L=k-C;L<this.halfMinDecorationHeight&&(L=this.halfMinDecorationHeight),C-L<0&&(C=L),C+L>this.canvasHeight&&(C=this.canvasHeight-L);var D=C-L,I=C+L,T=I-D;c.fillStyle=l[o[p].type]||null,c.fillRect(0,D,Math.round(this.oneZoneWidth-1),T)}}var W=this.renderer.session.selection.getCursor();if(W){var F=Math.round(this.getVerticalOffsetForRow(W.row)*this.heightRatio);c.fillStyle="rgba(0, 0, 0, 0.5)",c.fillRect(0,F,this.canvasWidth,2)}},d.prototype.getVerticalOffsetForRow=function(a){a=a|0;var l=this.renderer.session.documentToScreenRow(a,0)*this.lineHeight;return l},d.prototype.setDimensions=function(a){a=a||this.renderer.layerConfig,this.maxHeight=a.maxHeight,this.lineHeight=a.lineHeight,this.canvasHeight=a.height,this.canvasWidth=this.scrollbarV.width||this.canvasWidth,this.setZoneWidth(),this.canvas.width=this.canvasWidth,this.canvas.height=this.canvasHeight,this.maxHeight<this.canvasHeight?this.heightRatio=1:this.heightRatio=this.canvasHeight/this.maxHeight},d.prototype.setZoneWidth=function(){this.oneZoneWidth=this.canvasWidth},d.prototype.destroy=function(){this.canvas.parentNode.removeChild(this.canvas)},d})();g.implement(u.prototype,w),r.Decorator=u}),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(e,r,m){var f=e("./lib/oop"),g=e("./lib/dom"),w=e("./lib/lang"),u=e("./config"),d=e("./layer/gutter").Gutter,a=e("./layer/marker").Marker,l=e("./layer/text").Text,c=e("./layer/cursor").Cursor,h=e("./scrollbar").HScrollBar,o=e("./scrollbar").VScrollBar,s=e("./scrollbar_custom").HScrollBar,p=e("./scrollbar_custom").VScrollBar,b=e("./renderloop").RenderLoop,x=e("./layer/font_metrics").FontMetrics,M=e("./lib/event_emitter").EventEmitter,R=e("./css/editor-css"),k=e("./layer/decorators").Decorator,C=e("./lib/useragent"),L=e("./layer/text_util").isTextToken;g.importCssString(R,"ace_editor.css",!1);var D=(function(){function I(T,W){var F=this;this.container=T||g.createElement("div"),g.addCssClass(this.container,"ace_editor"),g.HI_DPI&&g.addCssClass(this.container,"ace_hidpi"),this.setTheme(W),u.get("useStrictCSP")==null&&u.set("useStrictCSP",!1),this.$gutter=g.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.$gutter.setAttribute("aria-hidden","true"),this.scroller=g.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=g.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new d(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new a(this.content);var O=this.$textLayer=new l(this.content);this.canvas=O.element,this.$markerFront=new a(this.content),this.$cursorLayer=new c(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new o(this.container,this),this.scrollBarH=new h(this.container,this),this.scrollBarV.on("scroll",function(S){F.$scrollAnimation||F.session.setScrollTop(S.data-F.scrollMargin.top)}),this.scrollBarH.on("scroll",function(S){F.$scrollAnimation||F.session.setScrollLeft(S.data-F.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new x(this.container),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.on("changeCharacterSize",function(S){F.updateCharacterSize(),F.onResize(!0,F.gutterWidth,F.$size.width,F.$size.height),F._signal("changeCharacterSize",S)}),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=!C.isIOS,this.$loop=new b(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),this.$addResizeObserver(),u.resetOptions(this),u._signal("renderer",this)}return I.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(),g.setStyle(this.scroller.style,"line-height",this.lineHeight+"px")},I.prototype.setSession=function(T){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=T,T&&this.scrollMargin.top&&T.getScrollTop()<=0&&T.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(T),this.$markerBack.setSession(T),this.$markerFront.setSession(T),this.$gutterLayer.setSession(T),this.$textLayer.setSession(T),T&&(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))},I.prototype.updateLines=function(T,W,F){if(W===void 0&&(W=1/0),this.$changedLines?(this.$changedLines.firstRow>T&&(this.$changedLines.firstRow=T),this.$changedLines.lastRow<W&&(this.$changedLines.lastRow=W)):this.$changedLines={firstRow:T,lastRow:W},this.$changedLines.lastRow<this.layerConfig.firstRow)if(F)this.$changedLines.lastRow=this.layerConfig.lastRow;else return;this.$changedLines.firstRow>this.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)},I.prototype.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},I.prototype.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},I.prototype.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},I.prototype.updateFull=function(T){T?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},I.prototype.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},I.prototype.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},I.prototype.onResize=function(T,W,F,O){if(!(this.resizing>2)){this.resizing>0?this.resizing++:this.resizing=T?1:0;var S=this.container;O||(O=S.clientHeight||S.scrollHeight),!O&&this.$maxLines&&this.lineHeight>1&&(!S.style.height||S.style.height=="0px")&&(S.style.height="1px",O=S.clientHeight||S.scrollHeight),F||(F=S.clientWidth||S.scrollWidth);var A=this.$updateCachedSize(T,W,F,O);if(this.$resizeTimer&&this.$resizeTimer.cancel(),!this.$size.scrollerHeight||!F&&!O)return this.resizing=0;T&&(this.$gutterLayer.$padding=null),T?this.$renderChanges(A|this.$changes,!0):this.$loop.schedule(A|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.$customScrollbar&&this.$updateCustomScrollbar(!0)}},I.prototype.$updateCachedSize=function(T,W,F,O){O-=this.$extraHeight||0;var S=0,A=this.$size,N={width:A.width,height:A.height,scrollerHeight:A.scrollerHeight,scrollerWidth:A.scrollerWidth};if(O&&(T||A.height!=O)&&(A.height=O,S|=this.CHANGE_SIZE,A.scrollerHeight=A.height,this.$horizScroll&&(A.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.setHeight(A.scrollerHeight),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",S=S|this.CHANGE_SCROLL),F&&(T||A.width!=F)){S|=this.CHANGE_SIZE,A.width=F,W==null&&(W=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=W,g.setStyle(this.scrollBarH.element.style,"left",W+"px"),g.setStyle(this.scroller.style,"left",W+this.margin.left+"px"),A.scrollerWidth=Math.max(0,F-W-this.scrollBarV.getWidth()-this.margin.h),g.setStyle(this.$gutter.style,"left",this.margin.left+"px");var B=this.scrollBarV.getWidth()+"px";g.setStyle(this.scrollBarH.element.style,"right",B),g.setStyle(this.scroller.style,"right",B),g.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight()),this.scrollBarH.setWidth(A.scrollerWidth),(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||T)&&(S|=this.CHANGE_FULL)}return A.$dirty=!F||!O,S&&this._signal("resize",N),S},I.prototype.onGutterResize=function(T){var W=this.$showGutter?T:0;W!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,W,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()},I.prototype.adjustWrapLimit=function(){var T=this.$size.scrollerWidth-this.$padding*2,W=Math.floor(T/this.characterWidth);return this.session.adjustWrapLimit(W,this.$showPrintMargin&&this.$printMarginColumn)},I.prototype.setAnimatedScroll=function(T){this.setOption("animatedScroll",T)},I.prototype.getAnimatedScroll=function(){return this.$animatedScroll},I.prototype.setShowInvisibles=function(T){this.setOption("showInvisibles",T),this.session.$bidiHandler.setShowInvisibles(T)},I.prototype.getShowInvisibles=function(){return this.getOption("showInvisibles")},I.prototype.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},I.prototype.setDisplayIndentGuides=function(T){this.setOption("displayIndentGuides",T)},I.prototype.getHighlightIndentGuides=function(){return this.getOption("highlightIndentGuides")},I.prototype.setHighlightIndentGuides=function(T){this.setOption("highlightIndentGuides",T)},I.prototype.setShowPrintMargin=function(T){this.setOption("showPrintMargin",T)},I.prototype.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},I.prototype.setPrintMarginColumn=function(T){this.setOption("printMarginColumn",T)},I.prototype.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},I.prototype.getShowGutter=function(){return this.getOption("showGutter")},I.prototype.setShowGutter=function(T){return this.setOption("showGutter",T)},I.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},I.prototype.setFadeFoldWidgets=function(T){this.setOption("fadeFoldWidgets",T)},I.prototype.setHighlightGutterLine=function(T){this.setOption("highlightGutterLine",T)},I.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},I.prototype.$updatePrintMargin=function(){if(!(!this.$showPrintMargin&&!this.$printMarginEl)){if(!this.$printMarginEl){var T=g.createElement("div");T.className="ace_layer ace_print-margin-layer",this.$printMarginEl=g.createElement("div"),this.$printMarginEl.className="ace_print-margin",T.appendChild(this.$printMarginEl),this.content.insertBefore(T,this.content.firstChild)}var W=this.$printMarginEl.style;W.left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",W.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&this.session.$wrap==-1&&this.adjustWrapLimit()}},I.prototype.getContainerElement=function(){return this.container},I.prototype.getMouseEventTarget=function(){return this.scroller},I.prototype.getTextAreaContainer=function(){return this.container},I.prototype.$moveTextAreaToCursor=function(){if(!this.$isMousePressed){var T=this.textarea.style,W=this.$composition;if(!this.$keepTextAreaAtCursor&&!W){g.translate(this.textarea,-100,0);return}var F=this.$cursorLayer.$pixelPos;if(F){W&&W.markerRange&&(F=this.$cursorLayer.getPixelPosition(W.markerRange.start,!0));var O=this.layerConfig,S=F.top,A=F.left;S-=O.offset;var N=W&&W.useTextareaForIME||C.isMobile?this.lineHeight:1;if(S<0||S>O.height-N){g.translate(this.textarea,0,0);return}var B=1,U=this.$size.height-N;if(!W)S+=this.lineHeight;else if(W.useTextareaForIME){var G=this.textarea.value;B=this.characterWidth*this.session.$getStringScreenWidth(G)[0]}else S+=this.lineHeight+2;A-=this.scrollLeft,A>this.$size.scrollerWidth-B&&(A=this.$size.scrollerWidth-B),A+=this.gutterWidth+this.margin.left,g.setStyle(T,"height",N+"px"),g.setStyle(T,"width",B+"px"),g.translate(this.textarea,Math.min(A,this.$size.scrollerWidth-B),Math.min(S,U))}}},I.prototype.getFirstVisibleRow=function(){return this.layerConfig.firstRow},I.prototype.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(this.layerConfig.offset===0?0:1)},I.prototype.getLastFullyVisibleRow=function(){var T=this.layerConfig,W=T.lastRow,F=this.session.documentToScreenRow(W,0)*T.lineHeight;return F-this.session.getScrollTop()>T.height-T.lineHeight?W-1:W},I.prototype.getLastVisibleRow=function(){return this.layerConfig.lastRow},I.prototype.setPadding=function(T){this.$padding=T,this.$textLayer.setPadding(T),this.$cursorLayer.setPadding(T),this.$markerFront.setPadding(T),this.$markerBack.setPadding(T),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},I.prototype.setScrollMargin=function(T,W,F,O){var S=this.scrollMargin;S.top=T|0,S.bottom=W|0,S.right=O|0,S.left=F|0,S.v=S.top+S.bottom,S.h=S.left+S.right,S.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-S.top),this.updateFull()},I.prototype.setMargin=function(T,W,F,O){var S=this.margin;S.top=T|0,S.bottom=W|0,S.right=O|0,S.left=F|0,S.v=S.top+S.bottom,S.h=S.left+S.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},I.prototype.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},I.prototype.setHScrollBarAlwaysVisible=function(T){this.setOption("hScrollBarAlwaysVisible",T)},I.prototype.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},I.prototype.setVScrollBarAlwaysVisible=function(T){this.setOption("vScrollBarAlwaysVisible",T)},I.prototype.$updateScrollBarV=function(){var T=this.layerConfig.maxHeight,W=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(T-=(W-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>T-W&&(T=this.scrollTop+W,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(T+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},I.prototype.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},I.prototype.freeze=function(){this.$frozen=!0},I.prototype.unfreeze=function(){this.$frozen=!1},I.prototype.$renderChanges=function(T,W){if(this.$changes&&(T|=this.$changes,this.$changes=0),!this.session||!this.container.offsetWidth||this.$frozen||!T&&!W){this.$changes|=T;return}if(this.$size.$dirty)return this.$changes|=T,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",T),this.session&&this.session.$bidiHandler&&this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);var F=this.layerConfig;if(T&this.CHANGE_FULL||T&this.CHANGE_SIZE||T&this.CHANGE_TEXT||T&this.CHANGE_LINES||T&this.CHANGE_SCROLL||T&this.CHANGE_H_SCROLL){if(T|=this.$computeLayerConfig()|this.$loop.clear(),F.firstRow!=this.layerConfig.firstRow&&F.firstRowScreen==this.layerConfig.firstRowScreen){var O=this.scrollTop+(F.firstRow-Math.max(this.layerConfig.firstRow,0))*this.lineHeight;O>0&&(this.scrollTop=O,T=T|this.CHANGE_SCROLL,T|=this.$computeLayerConfig()|this.$loop.clear())}F=this.layerConfig,this.$updateScrollBarV(),T&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),g.translate(this.content,-this.scrollLeft,-F.offset);var S=F.width+2*this.$padding+"px",A=F.minHeight+"px";g.setStyle(this.content.style,"width",S),g.setStyle(this.content.style,"height",A)}if(T&this.CHANGE_H_SCROLL&&(g.translate(this.content,-this.scrollLeft,-F.offset),this.scroller.className=this.scrollLeft<=0?"ace_scroller ":"ace_scroller ace_scroll-left ",this.enableKeyboardAccessibility&&(this.scroller.className+=this.keyboardFocusClassName)),T&this.CHANGE_FULL){this.$changedLines=null,this.$textLayer.update(F),this.$showGutter&&this.$gutterLayer.update(F),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(F),this.$markerBack.update(F),this.$markerFront.update(F),this.$cursorLayer.update(F),this.$moveTextAreaToCursor(),this._signal("afterRender",T);return}if(T&this.CHANGE_SCROLL){this.$changedLines=null,T&this.CHANGE_TEXT||T&this.CHANGE_LINES?this.$textLayer.update(F):this.$textLayer.scrollLines(F),this.$showGutter&&(T&this.CHANGE_GUTTER||T&this.CHANGE_LINES?this.$gutterLayer.update(F):this.$gutterLayer.scrollLines(F)),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(F),this.$markerBack.update(F),this.$markerFront.update(F),this.$cursorLayer.update(F),this.$moveTextAreaToCursor(),this._signal("afterRender",T);return}T&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(F),this.$showGutter&&this.$gutterLayer.update(F),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(F)):T&this.CHANGE_LINES?((this.$updateLines()||T&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(F),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(F)):T&this.CHANGE_TEXT||T&this.CHANGE_GUTTER?(this.$showGutter&&this.$gutterLayer.update(F),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(F)):T&this.CHANGE_CURSOR&&(this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(F),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(F)),T&this.CHANGE_CURSOR&&(this.$cursorLayer.update(F),this.$moveTextAreaToCursor()),T&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(F),T&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(F),this._signal("afterRender",T)},I.prototype.$autosize=function(){var T=this.session.getScreenLength()*this.lineHeight,W=this.$maxLines*this.lineHeight,F=Math.min(W,Math.max((this.$minLines||1)*this.lineHeight,T))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(F+=this.scrollBarH.getHeight()),this.$maxPixelHeight&&F>this.$maxPixelHeight&&(F=this.$maxPixelHeight);var O=F<=2*this.lineHeight,S=!O&&T>W;if(F!=this.desiredHeight||this.$size.height!=this.desiredHeight||S!=this.$vScroll){S!=this.$vScroll&&(this.$vScroll=S,this.scrollBarV.setVisible(S));var A=this.container.clientWidth;this.container.style.height=F+"px",this.$updateCachedSize(!0,this.$gutterWidth,A,F),this.desiredHeight=F,this._signal("autosize")}},I.prototype.$computeLayerConfig=function(){var T=this.session,W=this.$size,F=W.height<=2*this.lineHeight,O=this.session.getScreenLength(),S=O*this.lineHeight,A=this.$getLongestLine(),N=!F&&(this.$hScrollBarAlwaysVisible||W.scrollerWidth-A-2*this.$padding<0),B=this.$horizScroll!==N;B&&(this.$horizScroll=N,this.scrollBarH.setVisible(N));var U=this.$vScroll;this.$maxLines&&this.lineHeight>1&&(this.$autosize(),F=W.height<=2*this.lineHeight);var G=W.scrollerHeight+this.lineHeight,J=!this.$maxLines&&this.$scrollPastEnd?(W.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;S+=J;var ne=this.scrollMargin;this.session.setScrollTop(Math.max(-ne.top,Math.min(this.scrollTop,S-W.scrollerHeight+ne.bottom))),this.session.setScrollLeft(Math.max(-ne.left,Math.min(this.scrollLeft,A+2*this.$padding-W.scrollerWidth+ne.right)));var de=!F&&(this.$vScrollBarAlwaysVisible||W.scrollerHeight-S+J<0||this.scrollTop>ne.top),ee=U!==de;ee&&(this.$vScroll=de,this.scrollBarV.setVisible(de));var se=this.scrollTop%this.lineHeight,ce=Math.ceil(G/this.lineHeight)-1,le=Math.max(0,Math.round((this.scrollTop-se)/this.lineHeight)),pe=le+ce,me,$e,Ee=this.lineHeight;le=T.screenToDocumentRow(le,0);var He=T.getFoldLine(le);He&&(le=He.start.row),me=T.documentToScreenRow(le,0),$e=T.getRowLength(le)*Ee,pe=Math.min(T.screenToDocumentRow(pe,0),T.getLength()-1),G=W.scrollerHeight+T.getRowLength(pe)*Ee+$e,se=this.scrollTop-me*Ee,se<0&&me>0&&(me=Math.max(0,me+Math.floor(se/Ee)),se=this.scrollTop-me*Ee);var Ue=0;return(this.layerConfig.width!=A||B)&&(Ue=this.CHANGE_H_SCROLL),(B||ee)&&(Ue|=this.$updateCachedSize(!0,this.gutterWidth,W.width,W.height),this._signal("scrollbarVisibilityChanged"),ee&&(A=this.$getLongestLine())),this.layerConfig={width:A,padding:this.$padding,firstRow:le,firstRowScreen:me,lastRow:pe,lineHeight:Ee,characterWidth:this.characterWidth,minHeight:G,maxHeight:S,offset:se,gutterOffset:Ee?Math.max(0,Math.ceil((se+W.height-W.scrollerHeight)/Ee)):0,height:this.$size.scrollerHeight},this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(A-this.$padding),Ue},I.prototype.$updateLines=function(){if(this.$changedLines){var T=this.$changedLines.firstRow,W=this.$changedLines.lastRow;this.$changedLines=null;var F=this.layerConfig;if(!(T>F.lastRow+1)&&!(W<F.firstRow)){if(W===1/0){this.$showGutter&&this.$gutterLayer.update(F),this.$textLayer.update(F);return}return this.$textLayer.updateLines(F,T,W),!0}}},I.prototype.$getLongestLine=function(){var T=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(T+=1),this.$textLayer&&T>this.$textLayer.MAX_LINE_LENGTH&&(T=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(T*this.characterWidth))},I.prototype.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},I.prototype.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},I.prototype.addGutterDecoration=function(T,W){this.$gutterLayer.addGutterDecoration(T,W)},I.prototype.removeGutterDecoration=function(T,W){this.$gutterLayer.removeGutterDecoration(T,W)},I.prototype.updateBreakpoints=function(T){this._rows=T,this.$loop.schedule(this.CHANGE_GUTTER)},I.prototype.setAnnotations=function(T){this.$gutterLayer.setAnnotations(T),this.$loop.schedule(this.CHANGE_GUTTER)},I.prototype.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},I.prototype.hideCursor=function(){this.$cursorLayer.hideCursor()},I.prototype.showCursor=function(){this.$cursorLayer.showCursor()},I.prototype.scrollSelectionIntoView=function(T,W,F){this.scrollCursorIntoView(T,F),this.scrollCursorIntoView(W,F)},I.prototype.scrollCursorIntoView=function(T,W,F){if(this.$size.scrollerHeight!==0){var O=this.$cursorLayer.getPixelPosition(T),S=O.left,A=O.top,N=F&&F.top||0,B=F&&F.bottom||0;this.$scrollAnimation&&(this.$stopAnimation=!0);var U=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;U+N>A?(W&&U+N>A+this.lineHeight&&(A-=W*this.$size.scrollerHeight),A===0&&(A=-this.scrollMargin.top),this.session.setScrollTop(A)):U+this.$size.scrollerHeight-B<A+this.lineHeight&&(W&&U+this.$size.scrollerHeight-B<A-this.lineHeight&&(A+=W*this.$size.scrollerHeight),this.session.setScrollTop(A+this.lineHeight+B-this.$size.scrollerHeight));var G=this.scrollLeft,J=2*this.layerConfig.characterWidth;S-J<G?(S-=J,S<this.$padding+J&&(S=-this.scrollMargin.left),this.session.setScrollLeft(S)):(S+=J,G+this.$size.scrollerWidth<S+this.characterWidth?this.session.setScrollLeft(Math.round(S+this.characterWidth-this.$size.scrollerWidth)):G<=this.$padding&&S-G<this.characterWidth&&this.session.setScrollLeft(0))}},I.prototype.getScrollTop=function(){return this.session.getScrollTop()},I.prototype.getScrollLeft=function(){return this.session.getScrollLeft()},I.prototype.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},I.prototype.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},I.prototype.scrollToRow=function(T){this.session.setScrollTop(T*this.lineHeight)},I.prototype.alignCursor=function(T,W){typeof T=="number"&&(T={row:T,column:0});var F=this.$cursorLayer.getPixelPosition(T),O=this.$size.scrollerHeight-this.lineHeight,S=F.top-O*(W||0);return this.session.setScrollTop(S),S},I.prototype.$calcSteps=function(T,W){var F=0,O=this.STEPS,S=[],A=function(N,B,U){return U*(Math.pow(N-1,3)+1)+B};for(F=0;F<O;++F)S.push(A(F/this.STEPS,T,W-T));return S},I.prototype.scrollToLine=function(T,W,F,O){var S=this.$cursorLayer.getPixelPosition({row:T,column:0}),A=S.top;W&&(A-=this.$size.scrollerHeight/2);var N=this.scrollTop;this.session.setScrollTop(A),F!==!1&&this.animateScrolling(N,O)},I.prototype.animateScrolling=function(T,W){var F=this.scrollTop;if(!this.$animatedScroll)return;var O=this;if(T==F)return;if(this.$scrollAnimation){var S=this.$scrollAnimation.steps;if(S.length&&(T=S[0],T==F))return}var A=O.$calcSteps(T,F);this.$scrollAnimation={from:T,to:F,steps:A},clearInterval(this.$timer),O.session.setScrollTop(A.shift()),O.session.$scrollTop=F;function N(){O.$timer=clearInterval(O.$timer),O.$scrollAnimation=null,O.$stopAnimation=!1,W&&W()}this.$timer=setInterval(function(){if(O.$stopAnimation){N();return}if(!O.session)return clearInterval(O.$timer);A.length?(O.session.setScrollTop(A.shift()),O.session.$scrollTop=F):F!=null?(O.session.$scrollTop=-1,O.session.setScrollTop(F),F=null):N()},10)},I.prototype.scrollToY=function(T){this.scrollTop!==T&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=T)},I.prototype.scrollToX=function(T){this.scrollLeft!==T&&(this.scrollLeft=T),this.$loop.schedule(this.CHANGE_H_SCROLL)},I.prototype.scrollTo=function(T,W){this.session.setScrollTop(W),this.session.setScrollLeft(T)},I.prototype.scrollBy=function(T,W){W&&this.session.setScrollTop(this.session.getScrollTop()+W),T&&this.session.setScrollLeft(this.session.getScrollLeft()+T)},I.prototype.isScrollableBy=function(T,W){if(W<0&&this.session.getScrollTop()>=1-this.scrollMargin.top||W>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||T<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left||T>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right)return!0},I.prototype.pixelToScreenCoordinates=function(T,W){var F;if(this.$hasCssTransforms){F={top:0,left:0};var O=this.$fontMetrics.transformCoordinates([T,W]);T=O[1]-this.gutterWidth-this.margin.left,W=O[0]}else F=this.scroller.getBoundingClientRect();var S=T+this.scrollLeft-F.left-this.$padding,A=S/this.characterWidth,N=Math.floor((W+this.scrollTop-F.top)/this.lineHeight),B=this.$blockCursor?Math.floor(A):Math.round(A);return{row:N,column:B,side:A-B>0?1:-1,offsetX:S}},I.prototype.screenToTextCoordinates=function(T,W){var F;if(this.$hasCssTransforms){F={top:0,left:0};var O=this.$fontMetrics.transformCoordinates([T,W]);T=O[1]-this.gutterWidth-this.margin.left,W=O[0]}else F=this.scroller.getBoundingClientRect();var S=T+this.scrollLeft-F.left-this.$padding,A=S/this.characterWidth,N=this.$blockCursor?Math.floor(A):Math.round(A),B=(W+this.scrollTop-F.top)/this.lineHeight;return this.session.screenToDocumentPosition(B,Math.max(N,0),S)},I.prototype.textToScreenCoordinates=function(T,W){var F=this.scroller.getBoundingClientRect(),O=this.session.documentToScreenPosition(T,W),S=this.$padding+(this.session.$bidiHandler.isBidiRow(O.row,T)?this.session.$bidiHandler.getPosLeft(O.column):Math.round(O.column*this.characterWidth)),A=O.row*this.lineHeight;return{pageX:F.left+S-this.scrollLeft,pageY:F.top+A-this.scrollTop}},I.prototype.visualizeFocus=function(){g.addCssClass(this.container,"ace_focus")},I.prototype.visualizeBlur=function(){g.removeCssClass(this.container,"ace_focus")},I.prototype.showComposition=function(T){this.$composition=T,T.cssText||(T.cssText=this.textarea.style.cssText),T.useTextareaForIME==null&&(T.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(g.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):T.markerId=this.session.addMarker(T.markerRange,"ace_composition_marker","text")},I.prototype.setCompositionText=function(T){var W=this.session.selection.cursor;this.addToken(T,"composition_placeholder",W.row,W.column),this.$moveTextAreaToCursor()},I.prototype.hideComposition=function(){if(this.$composition){this.$composition.markerId&&this.session.removeMarker(this.$composition.markerId),g.removeCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText=this.$composition.cssText;var T=this.session.selection.cursor;this.removeExtraToken(T.row,T.column),this.$composition=null,this.$cursorLayer.element.style.display=""}},I.prototype.setGhostText=function(T,W){var F=this.session.selection.cursor,O=W||{row:F.row,column:F.column};this.removeGhostText();var S=this.$calculateWrappedTextChunks(T,O);this.addToken(S[0].text,"ghost_text",O.row,O.column),this.$ghostText={text:T,position:{row:O.row,column:O.column}};var A=g.createElement("div");if(S.length>1){var N=this.hideTokensAfterPosition(O.row,O.column),B;S.slice(1).forEach(function(ee){var se=g.createElement("div"),ce=g.createElement("span");ce.className="ace_ghost_text",ee.wrapped&&(se.className="ghost_text_line_wrapped"),ee.text.length===0&&(ee.text=" "),ce.appendChild(g.createTextNode(ee.text)),se.appendChild(ce),A.appendChild(se),B=se}),N.forEach(function(ee){var se=g.createElement("span");L(ee.type)||(se.className="ace_"+ee.type.replace(/\./g," ace_")),se.appendChild(g.createTextNode(ee.value)),B.appendChild(se)}),this.$ghostTextWidget={el:A,row:O.row,column:O.column,className:"ace_ghost_text_container"},this.session.widgetManager.addLineWidget(this.$ghostTextWidget);var U=this.$cursorLayer.getPixelPosition(O,!0),G=this.container,J=G.getBoundingClientRect().height,ne=S.length*this.lineHeight,de=ne<J-U.top;if(de)return;ne<J?this.scrollBy(0,(S.length-1)*this.lineHeight):this.scrollToRow(O.row)}},I.prototype.$calculateWrappedTextChunks=function(T,W){var F=this.$size.scrollerWidth-this.$padding*2,O=Math.floor(F/this.characterWidth)-2;O=O<=0?60:O;for(var S=T.split(/\r?\n/),A=[],N=0;N<S.length;N++){var B=this.session.$getDisplayTokens(S[N],W.column),U=this.session.$computeWrapSplits(B,O,this.session.$tabSize);if(U.length>0){var G=0;U.push(S[N].length);for(var J=0;J<U.length;J++){var ne=S[N].slice(G,U[J]);A.push({text:ne,wrapped:!0}),G=U[J]}}else A.push({text:S[N],wrapped:!1})}return A},I.prototype.removeGhostText=function(){if(this.$ghostText){var T=this.$ghostText.position;this.removeExtraToken(T.row,T.column),this.$ghostTextWidget&&(this.session.widgetManager.removeLineWidget(this.$ghostTextWidget),this.$ghostTextWidget=null),this.$ghostText=null}},I.prototype.addToken=function(T,W,F,O){var S=this.session;S.bgTokenizer.lines[F]=null;var A={type:W,value:T},N=S.getTokens(F);if(O==null||!N.length)N.push(A);else for(var B=0,U=0;U<N.length;U++){var G=N[U];if(B+=G.value.length,O<=B){var J=G.value.length-(B-O),ne=G.value.slice(0,J),de=G.value.slice(J);N.splice(U,1,{type:G.type,value:ne},A,{type:G.type,value:de});break}}this.updateLines(F,F)},I.prototype.hideTokensAfterPosition=function(T,W){for(var F=this.session.getTokens(T),O=0,S=!1,A=[],N=0;N<F.length;N++){var B=F[N];if(O+=B.value.length,B.type!=="ghost_text"){if(S){A.push({type:B.type,value:B.value}),B.type="hidden_token";continue}O===W&&(S=!0)}}return this.updateLines(T,T),A},I.prototype.removeExtraToken=function(T,W){this.session.bgTokenizer.lines[T]=null,this.updateLines(T,T)},I.prototype.setTheme=function(T,W){var F=this;if(this.$themeId=T,F._dispatchEvent("themeChange",{theme:T}),!T||typeof T=="string"){var O=T||this.$options.theme.initialValue;u.loadModule(["theme",O],S)}else S(T);function S(A){if(F.$themeId!=T)return W&&W();if(!A||!A.cssClass)throw new Error("couldn't load module "+T+" or it didn't call define");A.$id&&(F.$themeId=A.$id),g.importCssString(A.cssText,A.cssClass,F.container),F.theme&&g.removeCssClass(F.container,F.theme.cssClass);var N="padding"in A?A.padding:"padding"in(F.theme||{})?4:F.$padding;if(F.$padding&&N!=F.$padding&&F.setPadding(N),F.$gutterLayer){var B=A.$showGutterCursorMarker;B&&!F.$gutterLayer.$showCursorMarker?F.$gutterLayer.$showCursorMarker="theme":!B&&F.$gutterLayer.$showCursorMarker=="theme"&&(F.$gutterLayer.$showCursorMarker=null)}F.$theme=A.cssClass,F.theme=A,g.addCssClass(F.container,A.cssClass),g.setCssClass(F.container,"ace_dark",A.isDark),F.$size&&(F.$size.width=0,F.$updateSizeAsync()),F._dispatchEvent("themeLoaded",{theme:A}),W&&W(),C.isSafari&&F.scroller&&(F.scroller.style.background="red",F.scroller.style.background="")}},I.prototype.getTheme=function(){return this.$themeId},I.prototype.setStyle=function(T,W){g.setCssClass(this.container,T,W!==!1)},I.prototype.unsetStyle=function(T){g.removeCssClass(this.container,T)},I.prototype.setCursorStyle=function(T){g.setStyle(this.scroller.style,"cursor",T)},I.prototype.setMouseCursor=function(T){g.setStyle(this.scroller.style,"cursor",T)},I.prototype.attachToShadowRoot=function(){g.importCssString(R,"ace_editor.css",this.container)},I.prototype.destroy=function(){this.freeze(),this.$fontMetrics.destroy(),this.$cursorLayer.destroy(),this.removeAllListeners(),this.container.textContent="",this.setOption("useResizeObserver",!1)},I.prototype.$updateCustomScrollbar=function(T){var W=this;this.$horizScroll=this.$vScroll=null,this.scrollBarV.element.remove(),this.scrollBarH.element.remove(),T===!0?(this.scrollBarV=new p(this.container,this),this.scrollBarH=new s(this.container,this),this.scrollBarV.setHeight(this.$size.scrollerHeight),this.scrollBarH.setWidth(this.$size.scrollerWidth),this.scrollBarV.addEventListener("scroll",function(F){W.$scrollAnimation||W.session.setScrollTop(F.data-W.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(F){W.$scrollAnimation||W.session.setScrollLeft(F.data-W.scrollMargin.left)}),this.$scrollDecorator?(this.$scrollDecorator.setScrollBarV(this.scrollBarV),this.$scrollDecorator.$updateDecorators()):(this.$scrollDecorator=new k(this.scrollBarV,this),this.$scrollDecorator.$updateDecorators())):(this.scrollBarV=new o(this.container,this),this.scrollBarH=new h(this.container,this),this.scrollBarV.addEventListener("scroll",function(F){W.$scrollAnimation||W.session.setScrollTop(F.data-W.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(F){W.$scrollAnimation||W.session.setScrollLeft(F.data-W.scrollMargin.left)}))},I.prototype.$addResizeObserver=function(){if(!(!window.ResizeObserver||this.$resizeObserver)){var T=this;this.$resizeTimer=w.delayedCall(function(){T.destroyed||T.onResize()},50),this.$resizeObserver=new window.ResizeObserver(function(W){var F=W[0].contentRect.width,O=W[0].contentRect.height;Math.abs(T.$size.width-F)>1||Math.abs(T.$size.height-O)>1?T.$resizeTimer.delay():T.$resizeTimer.cancel()}),this.$resizeObserver.observe(this.container)}},I})();D.prototype.CHANGE_CURSOR=1,D.prototype.CHANGE_MARKER=2,D.prototype.CHANGE_GUTTER=4,D.prototype.CHANGE_SCROLL=8,D.prototype.CHANGE_LINES=16,D.prototype.CHANGE_TEXT=32,D.prototype.CHANGE_SIZE=64,D.prototype.CHANGE_MARKER_BACK=128,D.prototype.CHANGE_MARKER_FRONT=256,D.prototype.CHANGE_FULL=512,D.prototype.CHANGE_H_SCROLL=1024,D.prototype.$changes=0,D.prototype.$padding=null,D.prototype.$frozen=!1,D.prototype.STEPS=8,f.implement(D.prototype,M),u.defineOptions(D.prototype,"renderer",{useResizeObserver:{set:function(I){!I&&this.$resizeObserver?(this.$resizeObserver.disconnect(),this.$resizeTimer.cancel(),this.$resizeTimer=this.$resizeObserver=null):I&&!this.$resizeObserver&&this.$addResizeObserver()}},animatedScroll:{initialValue:!1},showInvisibles:{set:function(I){this.$textLayer.setShowInvisibles(I)&&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(I){typeof I=="number"&&(this.$printMarginColumn=I),this.$showPrintMargin=!!I,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(I){this.$gutter.style.display=I?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},useSvgGutterIcons:{set:function(I){this.$gutterLayer.$useSvgGutterIcons=I},initialValue:!1},showFoldedAnnotations:{set:function(I){this.$gutterLayer.$showFoldedAnnotations=I},initialValue:!1},fadeFoldWidgets:{set:function(I){g.setCssClass(this.$gutter,"ace_fade-fold-widgets",I)},initialValue:!1},showFoldWidgets:{set:function(I){this.$gutterLayer.setShowFoldWidgets(I),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(I){this.$textLayer.setDisplayIndentGuides(I)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightIndentGuides:{set:function(I){this.$textLayer.setHighlightIndentGuides(I)==!0?this.$textLayer.$highlightIndentGuide():this.$textLayer.$clearActiveIndentGuide(this.$textLayer.$lines.cells)},initialValue:!0},highlightGutterLine:{set:function(I){this.$gutterLayer.setHighlightGutterLine(I),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},hScrollBarAlwaysVisible:{set:function(I){(!this.$hScrollBarAlwaysVisible||!this.$horizScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(I){(!this.$vScrollBarAlwaysVisible||!this.$vScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(I){typeof I=="number"&&(I=I+"px"),this.container.style.fontSize=I,this.updateFontSize()},initialValue:12},fontFamily:{set:function(I){this.container.style.fontFamily=I,this.updateFontSize()}},maxLines:{set:function(I){this.updateFull()}},minLines:{set:function(I){this.$minLines<562949953421311||(this.$minLines=0),this.updateFull()}},maxPixelHeight:{set:function(I){this.updateFull()},initialValue:0},scrollPastEnd:{set:function(I){I=+I||0,this.$scrollPastEnd!=I&&(this.$scrollPastEnd=I,this.$loop.schedule(this.CHANGE_SCROLL))},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(I){this.$gutterLayer.$fixedWidth=!!I,this.$loop.schedule(this.CHANGE_GUTTER)}},customScrollbar:{set:function(I){this.$updateCustomScrollbar(I)},initialValue:!1},theme:{set:function(I){this.setTheme(I)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0},hasCssTransforms:{},useTextareaForIME:{initialValue:!C.isMobile&&!C.isIE}}),r.VirtualRenderer=D}),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],function(e,r,m){var f=e("../lib/oop"),g=e("../lib/net"),w=e("../lib/event_emitter").EventEmitter,u=e("../config");function d(h){var o="importScripts('"+g.qualifyURL(h)+"');";try{return new Blob([o],{type:"application/javascript"})}catch{var s=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder,p=new s;return p.append(o),p.getBlob("application/javascript")}}function a(h){if(typeof Worker>"u")return{postMessage:function(){},terminate:function(){}};if(u.get("loadWorkerFromBlob")){var o=d(h),s=window.URL||window.webkitURL,p=s.createObjectURL(o);return new Worker(p)}return new Worker(h)}var l=function(h){h.postMessage||(h=this.$createWorkerFromOldConfig.apply(this,arguments)),this.$worker=h,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(){f.implement(this,w),this.$createWorkerFromOldConfig=function(h,o,s,p,b){if(e.nameToUrl&&!e.toUrl&&(e.toUrl=e.nameToUrl),u.get("packaged")||!e.toUrl)p=p||u.moduleUrl(o,"worker");else{var x=this.$normalizePath;p=p||x(e.toUrl("ace/worker/worker.js",null,"_"));var M={};h.forEach(function(R){M[R]=x(e.toUrl(R,null,"_").replace(/(\.js)?(\?.*)?$/,""))})}return this.$worker=a(p),b&&this.send("importScripts",b),this.$worker.postMessage({init:!0,tlns:M,module:o,classname:s}),this.$worker},this.onMessage=function(h){var o=h.data;switch(o.type){case"event":this._signal(o.name,{data:o.data});break;case"call":var s=this.callbacks[o.id];s&&(s(o.data),delete this.callbacks[o.id]);break;case"error":this.reportError(o.data);break;case"log":window.console&&console.log&&console.log.apply(console,o.data);break}},this.reportError=function(h){window.console&&console.error&&console.error(h)},this.$normalizePath=function(h){return g.qualifyURL(h)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker.onerror=function(h){h.preventDefault()},this.$worker=null,this.$doc&&this.$doc.off("change",this.changeListener),this.$doc=null},this.send=function(h,o){this.$worker.postMessage({command:h,args:o})},this.call=function(h,o,s){if(s){var p=this.callbackId++;this.callbacks[p]=s,o.push(p)}this.send(h,o)},this.emit=function(h,o){try{o.data&&o.data.err&&(o.data.err={message:o.data.err.message,stack:o.data.err.stack,code:o.data.err.code}),this.$worker&&this.$worker.postMessage({event:h,data:{data:o.data}})}catch(s){console.error(s.stack)}},this.attachToDocument=function(h){this.$doc&&this.terminate(),this.$doc=h,this.call("setValue",[h.getValue()]),h.on("change",this.changeListener,!0)},this.changeListener=function(h){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0)),h.action=="insert"?this.deltaQueue.push(h.start,h.lines):this.deltaQueue.push(h.start,h.end)},this.$sendDeltaQueue=function(){var h=this.deltaQueue;h&&(this.deltaQueue=null,h.length>50&&h.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:h}))}}).call(l.prototype);var c=function(h,o,s){var p=null,b=!1,x=Object.create(w),M=[],R=new l({messageBuffer:M,terminate:function(){},postMessage:function(C){M.push(C),p&&(b?setTimeout(k):k())}});R.setEmitSync=function(C){b=C};var k=function(){var C=M.shift();C.command?p[C.command].apply(p,C.args):C.event&&x._signal(C.event,C.data)};return x.postMessage=function(C){R.onMessage({data:C})},x.callback=function(C,L){this.postMessage({type:"call",id:L,data:C})},x.emit=function(C,L){this.postMessage({type:"event",name:C,data:L})},u.loadModule(["worker",o],function(C){for(p=new C[s](x);M.length;)k()}),R};r.UIWorkerClient=c,r.WorkerClient=l,r.createWorker=a}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(e,r,m){var f=e("./range").Range,g=e("./lib/event_emitter").EventEmitter,w=e("./lib/oop"),u=(function(){function d(a,l,c,h,o,s){var p=this;this.length=l,this.session=a,this.doc=a.getDocument(),this.mainClass=o,this.othersClass=s,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate,!0),this.$others=h,this.$onCursorChange=function(){setTimeout(function(){p.onCursorChange()})},this.$pos=c;var b=a.getUndoManager().$undoStack||a.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=b.length,this.setup(),a.selection.on("changeCursor",this.$onCursorChange)}return d.prototype.setup=function(){var a=this,l=this.doc,c=this.session;this.selectionBefore=c.selection.toJSON(),c.selection.inMultiSelectMode&&c.selection.toSingleRange(),this.pos=l.createAnchor(this.$pos.row,this.$pos.column);var h=this.pos;h.$insertRight=!0,h.detach(),h.markerId=c.addMarker(new f(h.row,h.column,h.row,h.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach(function(o){var s=l.createAnchor(o.row,o.column);s.$insertRight=!0,s.detach(),a.others.push(s)}),c.setUndoSelect(!1)},d.prototype.showOtherMarkers=function(){if(!this.othersActive){var a=this.session,l=this;this.othersActive=!0,this.others.forEach(function(c){c.markerId=a.addMarker(new f(c.row,c.column,c.row,c.column+l.length),l.othersClass,null,!1)})}},d.prototype.hideOtherMarkers=function(){if(this.othersActive){this.othersActive=!1;for(var a=0;a<this.others.length;a++)this.session.removeMarker(this.others[a].markerId)}},d.prototype.onUpdate=function(a){if(this.$updating)return this.updateAnchors(a);var l=a;if(l.start.row===l.end.row&&l.start.row===this.pos.row){this.$updating=!0;var c=a.action==="insert"?l.end.column-l.start.column:l.start.column-l.end.column,h=l.start.column>=this.pos.column&&l.start.column<=this.pos.column+this.length+1,o=l.start.column-this.pos.column;if(this.updateAnchors(a),h&&(this.length+=c),h&&!this.session.$fromUndo){if(a.action==="insert")for(var s=this.others.length-1;s>=0;s--){var p=this.others[s],b={row:p.row,column:p.column+o};this.doc.insertMergedLines(b,a.lines)}else if(a.action==="remove")for(var s=this.others.length-1;s>=0;s--){var p=this.others[s],b={row:p.row,column:p.column+o};this.doc.remove(new f(b.row,b.column,b.row,b.column-c))}}this.$updating=!1,this.updateMarkers()}},d.prototype.updateAnchors=function(a){this.pos.onChange(a);for(var l=this.others.length;l--;)this.others[l].onChange(a);this.updateMarkers()},d.prototype.updateMarkers=function(){if(!this.$updating){var a=this,l=this.session,c=function(o,s){l.removeMarker(o.markerId),o.markerId=l.addMarker(new f(o.row,o.column,o.row,o.column+a.length),s,null,!1)};c(this.pos,this.mainClass);for(var h=this.others.length;h--;)c(this.others[h],this.othersClass)}},d.prototype.onCursorChange=function(a){if(!(this.$updating||!this.session)){var l=this.session.selection.getCursor();l.row===this.pos.row&&l.column>=this.pos.column&&l.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",a)):(this.hideOtherMarkers(),this._emit("cursorLeave",a))}},d.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},d.prototype.cancel=function(){if(this.$undoStackDepth!==-1){for(var a=this.session.getUndoManager(),l=(a.$undoStack||a.$undostack).length-this.$undoStackDepth,c=0;c<l;c++)a.undo(this.session,!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}},d})();w.implement(u.prototype,g),r.PlaceHolder=u}),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(e,r,m){var f=e("../lib/event"),g=e("../lib/useragent");function w(d,a){return d.row==a.row&&d.column==a.column}function u(d){var a=d.domEvent,l=a.altKey,c=a.shiftKey,h=a.ctrlKey,o=d.getAccelKey(),s=d.getButton();if(h&&g.isMac&&(s=a.button),d.editor.inMultiSelectMode&&s==2){d.editor.textInput.onContextMenu(d.domEvent);return}if(!h&&!l&&!o){s===0&&d.editor.inMultiSelectMode&&d.editor.exitMultiSelectMode();return}if(s===0){var p=d.editor,b=p.selection,x=p.inMultiSelectMode,M=d.getDocumentPosition(),R=b.getCursor(),k=d.inSelection()||b.isEmpty()&&w(M,R),C=d.x,L=d.y,D=function(ne){C=ne.clientX,L=ne.clientY},I=p.session,T=p.renderer.pixelToScreenCoordinates(C,L),W=T,F;if(p.$mouseHandler.$enableJumpToDef)h&&l||o&&l?F=c?"block":"add":l&&p.$blockSelectEnabled&&(F="block");else if(o&&!l){if(F="add",!x&&c)return}else l&&p.$blockSelectEnabled&&(F="block");if(F&&g.isMac&&a.ctrlKey&&p.$mouseHandler.cancelContextMenu(),F=="add"){if(!x&&k)return;if(!x){var O=b.toOrientedRange();p.addSelectionMarker(O)}var S=b.rangeList.rangeAtPoint(M);p.inVirtualSelectionMode=!0,c&&(S=null,O=b.ranges[0]||O,p.removeSelectionMarker(O)),p.once("mouseup",function(){var ne=b.toOrientedRange();S&&ne.isEmpty()&&w(S.cursor,ne.cursor)?b.substractPoint(ne.cursor):(c?b.substractPoint(O.cursor):O&&(p.removeSelectionMarker(O),b.addRange(O)),b.addRange(ne)),p.inVirtualSelectionMode=!1})}else if(F=="block"){d.stop(),p.inVirtualSelectionMode=!0;var A,N=[],B=function(){var ne=p.renderer.pixelToScreenCoordinates(C,L),de=I.screenToDocumentPosition(ne.row,ne.column,ne.offsetX);w(W,ne)&&w(de,b.lead)||(W=ne,p.selection.moveToPosition(de),p.renderer.scrollCursorIntoView(),p.removeSelectionMarkers(N),N=b.rectangularRangeBlock(W,T),p.$mouseHandler.$clickSelection&&N.length==1&&N[0].isEmpty()&&(N[0]=p.$mouseHandler.$clickSelection.clone()),N.forEach(p.addSelectionMarker,p),p.updateSelectionMarkers())};x&&!o?b.toSingleRange():!x&&o&&(A=b.toOrientedRange(),p.addSelectionMarker(A)),c?T=I.documentToScreenPosition(b.lead):b.moveToPosition(M),W={row:-1,column:-1};var U=function(ne){B(),clearInterval(J),p.removeSelectionMarkers(N),N.length||(N=[b.toOrientedRange()]),A&&(p.removeSelectionMarker(A),b.toSingleRange(A));for(var de=0;de<N.length;de++)b.addRange(N[de]);p.inVirtualSelectionMode=!1,p.$mouseHandler.$clickSelection=null},G=B;f.capture(p.container,D,U);var J=setInterval(function(){G()},20);return d.preventDefault()}}}r.onMouseDown=u}),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],function(e,r,m){r.defaultCommands=[{name:"addCursorAbove",description:"Add cursor above",exec:function(g){g.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelow",description:"Add cursor below",exec:function(g){g.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(g){g.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(g){g.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(g){g.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreAfter",description:"Select more after",exec:function(g){g.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",mac:"Ctrl-Alt-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextBefore",description:"Select next before",exec:function(g){g.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(g){g.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(g){g.multiSelect.rangeCount>1?g.multiSelect.joinSelections():g.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readOnly:!0},{name:"splitSelectionIntoLines",description:"Split into lines",exec:function(g){g.multiSelect.splitIntoLines()},readOnly:!0},{name:"alignCursors",description:"Align cursors",exec:function(g){g.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",description:"Find all",exec:function(g){g.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readOnly:!0}],r.multiSelectCommands=[{name:"singleSelection",description:"Single selection",bindKey:"esc",exec:function(g){g.exitMultiSelectMode()},scrollIntoView:"cursor",readOnly:!0,isAvailable:function(g){return g&&g.inMultiSelectMode}}];var f=e("../keyboard/hash_handler").HashHandler;r.keyboardHandler=new f(r.multiSelectCommands)}),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],function(e,r,m){var f=e("./range_list").RangeList,g=e("./range").Range,w=e("./selection").Selection,u=e("./mouse/multi_select_handler").onMouseDown,d=e("./lib/event"),a=e("./lib/lang"),l=e("./commands/multi_select_commands");r.commands=l.defaultCommands.concat(l.multiSelectCommands);var c=e("./search").Search,h=new c;function o(R,k,C){return h.$options.wrap=!0,h.$options.needle=k,h.$options.backwards=C==-1,h.find(R)}var s=e("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(s.prototype),(function(){this.ranges=null,this.rangeList=null,this.addRange=function(R,k){if(R){if(!this.inMultiSelectMode&&this.rangeCount===0){var C=this.toOrientedRange();if(this.rangeList.add(C),this.rangeList.add(R),this.rangeList.ranges.length!=2)return this.rangeList.removeAll(),k||this.fromOrientedRange(R);this.rangeList.removeAll(),this.rangeList.add(C),this.$onAddRange(C)}R.cursor||(R.cursor=R.end);var L=this.rangeList.add(R);return this.$onAddRange(R),L.length&&this.$onRemoveRange(L),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),k||this.fromOrientedRange(R)}},this.toSingleRange=function(R){R=R||this.ranges[0];var k=this.rangeList.removeAll();k.length&&this.$onRemoveRange(k),R&&this.fromOrientedRange(R)},this.substractPoint=function(R){var k=this.rangeList.substractPoint(R);if(k)return this.$onRemoveRange(k),k[0]},this.mergeOverlappingRanges=function(){var R=this.rangeList.merge();R.length&&this.$onRemoveRange(R)},this.$onAddRange=function(R){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(R),this._signal("addRange",{range:R})},this.$onRemoveRange=function(R){if(this.rangeCount=this.rangeList.ranges.length,this.rangeCount==1&&this.inMultiSelectMode){var k=this.rangeList.ranges.pop();R.push(k),this.rangeCount=0}for(var C=R.length;C--;){var L=this.ranges.indexOf(R[C]);this.ranges.splice(L,1)}this._signal("removeRange",{ranges:R}),this.rangeCount===0&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),k=k||this.ranges[0],k&&!k.isEqual(this.getRange())&&this.fromOrientedRange(k)},this.$initRangeList=function(){this.rangeList||(this.rangeList=new f,this.ranges=[],this.rangeCount=0)},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){for(var R=this.ranges.length?this.ranges:[this.getRange()],k=[],C=0;C<R.length;C++){var L=R[C],D=L.start.row,I=L.end.row;if(D===I)k.push(L.clone());else{for(k.push(new g(D,L.start.column,D,this.session.getLine(D).length));++D<I;)k.push(this.getLineRange(D,!0));k.push(new g(I,0,I,L.end.column))}C==0&&!this.isBackwards()&&(k=k.reverse())}this.toSingleRange();for(var C=k.length;C--;)this.addRange(k[C])},this.joinSelections=function(){var R=this.rangeList.ranges,k=R[R.length-1],C=g.fromPoints(R[0].start,k.end);this.toSingleRange(),this.setSelectionRange(C,k.cursor==k.start)},this.toggleBlockSelection=function(){if(this.rangeCount>1){var R=this.rangeList.ranges,k=R[R.length-1],C=g.fromPoints(R[0].start,k.end);this.toSingleRange(),this.setSelectionRange(C,k.cursor==k.start)}else{var L=this.session.documentToScreenPosition(this.cursor),D=this.session.documentToScreenPosition(this.anchor),I=this.rectangularRangeBlock(L,D);I.forEach(this.addRange,this)}},this.rectangularRangeBlock=function(R,k,C){var L=[],D=R.column<k.column;if(D)var I=R.column,T=k.column,W=R.offsetX,F=k.offsetX;else var I=k.column,T=R.column,W=k.offsetX,F=R.offsetX;var O=R.row<k.row;if(O)var S=R.row,A=k.row;else var S=k.row,A=R.row;I<0&&(I=0),S<0&&(S=0),S==A&&(C=!0);for(var N,B=S;B<=A;B++){var U=g.fromPoints(this.session.screenToDocumentPosition(B,I,W),this.session.screenToDocumentPosition(B,T,F));if(U.isEmpty()){if(N&&b(U.end,N))break;N=U.end}U.cursor=D?U.start:U.end,L.push(U)}if(O&&L.reverse(),!C){for(var G=L.length-1;L[G].isEmpty()&&G>0;)G--;if(G>0)for(var J=0;L[J].isEmpty();)J++;for(var ne=G;ne>=J;ne--)L[ne].isEmpty()&&L.splice(ne,1)}return L}}).call(w.prototype);var p=e("./editor").Editor;(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(R){R.cursor||(R.cursor=R.end);var k=this.getSelectionStyle();return R.marker=this.session.addMarker(R,"ace_selection",k),this.session.$selectionMarkers.push(R),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,R},this.removeSelectionMarker=function(R){if(R.marker){this.session.removeMarker(R.marker);var k=this.session.$selectionMarkers.indexOf(R);k!=-1&&this.session.$selectionMarkers.splice(k,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length}},this.removeSelectionMarkers=function(R){for(var k=this.session.$selectionMarkers,C=R.length;C--;){var L=R[C];if(L.marker){this.session.removeMarker(L.marker);var D=k.indexOf(L);D!=-1&&k.splice(D,1)}}this.session.selectionMarkerCount=k.length},this.$onAddRange=function(R){this.addSelectionMarker(R.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(R){this.removeSelectionMarkers(R.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(R){this.inMultiSelectMode||(this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(l.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers())},this.$onSingleSelect=function(R){this.session.multiSelect.inVirtualMode||(this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(l.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection"))},this.$onMultiSelectExec=function(R){var k=R.command,C=R.editor;if(C.multiSelect){if(k.multiSelectAction)k.multiSelectAction=="forEach"?L=C.forEachSelection(k,R.args):k.multiSelectAction=="forEachLine"?L=C.forEachSelection(k,R.args,!0):k.multiSelectAction=="single"?(C.exitMultiSelectMode(),L=k.exec(C,R.args||{})):L=k.multiSelectAction(C,R.args||{});else{var L=k.exec(C,R.args||{});C.multiSelect.addRange(C.multiSelect.toOrientedRange()),C.multiSelect.mergeOverlappingRanges()}return L}},this.forEachSelection=function(R,k,C){if(!this.inVirtualSelectionMode){var L=C&&C.keepOrder,D=C==!0||C&&C.$byLines,I=this.session,T=this.selection,W=T.rangeList,F=(L?T:W).ranges,O;if(!F.length)return R.exec?R.exec(this,k||{}):R(this,k||{});var S=T._eventRegistry;T._eventRegistry={};var A=new w(I);this.inVirtualSelectionMode=!0;for(var N=F.length;N--;){if(D)for(;N>0&&F[N].start.row==F[N-1].end.row;)N--;A.fromOrientedRange(F[N]),A.index=N,this.selection=I.selection=A;var B=R.exec?R.exec(this,k||{}):R(this,k||{});!O&&B!==void 0&&(O=B),A.toOrientedRange(F[N])}A.detach(),this.selection=I.selection=T,this.inVirtualSelectionMode=!1,T._eventRegistry=S,T.mergeOverlappingRanges(),T.ranges[0]&&T.fromOrientedRange(T.ranges[0]);var U=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),U&&U.from==U.to&&this.renderer.animateScrolling(U.from),O}},this.exitMultiSelectMode=function(){!this.inMultiSelectMode||this.inVirtualSelectionMode||this.multiSelect.toSingleRange()},this.getSelectedText=function(){var R="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var k=this.multiSelect.rangeList.ranges,C=[],L=0;L<k.length;L++)C.push(this.session.getTextRange(k[L]));var D=this.session.getDocument().getNewLineCharacter();R=C.join(D),R.length==(C.length-1)*D.length&&(R="")}else this.selection.isEmpty()||(R=this.session.getTextRange(this.getSelectionRange()));return R},this.$checkMultiselectChange=function(R,k){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var C=this.multiSelect.ranges[0];if(this.multiSelect.isEmpty()&&k==this.multiSelect.anchor)return;var L=k==this.multiSelect.anchor?C.cursor==C.start?C.end:C.start:C.cursor;L.row!=k.row||this.session.$clipPositionToDocument(L.row,L.column).column!=k.column?this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()):this.multiSelect.mergeOverlappingRanges()}},this.findAll=function(R,k,C){if(k=k||{},k.needle=R||k.needle,k.needle==null){var L=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();k.needle=this.session.getTextRange(L)}this.$search.set(k);var D=this.$search.findAll(this.session);if(!D.length)return 0;var I=this.multiSelect;C||I.toSingleRange(D[0]);for(var T=D.length;T--;)I.addRange(D[T],!0);return L&&I.rangeList.rangeAtPoint(L.start)&&I.addRange(L,!0),D.length},this.selectMoreLines=function(R,k){var C=this.selection.toOrientedRange(),L=C.cursor==C.end,D=this.session.documentToScreenPosition(C.cursor);this.selection.$desiredColumn&&(D.column=this.selection.$desiredColumn);var I=this.session.screenToDocumentPosition(D.row+R,D.column);if(C.isEmpty())var W=I;else var T=this.session.documentToScreenPosition(L?C.end:C.start),W=this.session.screenToDocumentPosition(T.row+R,T.column);if(L){var F=g.fromPoints(I,W);F.cursor=F.start}else{var F=g.fromPoints(W,I);F.cursor=F.end}if(F.desiredColumn=D.column,!this.selection.inMultiSelectMode)this.selection.addRange(C);else if(k)var O=C.cursor;this.selection.addRange(F),O&&this.selection.substractPoint(O)},this.transposeSelections=function(R){for(var k=this.session,C=k.multiSelect,L=C.ranges,D=L.length;D--;){var I=L[D];if(I.isEmpty()){var T=k.getWordRange(I.start.row,I.start.column);I.start.row=T.start.row,I.start.column=T.start.column,I.end.row=T.end.row,I.end.column=T.end.column}}C.mergeOverlappingRanges();for(var W=[],D=L.length;D--;){var I=L[D];W.unshift(k.getTextRange(I))}R<0?W.unshift(W.pop()):W.push(W.shift());for(var D=L.length;D--;){var I=L[D],F=I.clone();k.replace(I,W[D]),I.start.row=F.start.row,I.start.column=F.start.column}C.fromOrientedRange(C.ranges[0])},this.selectMore=function(R,k,C){var L=this.session,D=L.multiSelect,I=D.toOrientedRange();if(!(I.isEmpty()&&(I=L.getWordRange(I.start.row,I.start.column),I.cursor=R==-1?I.start:I.end,this.multiSelect.addRange(I),C))){var T=L.getTextRange(I),W=o(L,T,R);W&&(W.cursor=R==-1?W.start:W.end,this.session.unfold(W),this.multiSelect.addRange(W),this.renderer.scrollCursorIntoView(null,.5)),k&&this.multiSelect.substractPoint(I.cursor)}},this.alignCursors=function(){var R=this.session,k=R.multiSelect,C=k.ranges,L=-1,D=C.filter(function(G){if(G.cursor.row==L)return!0;L=G.cursor.row});if(!C.length||D.length==C.length-1){var I=this.selection.getRange(),T=I.start.row,W=I.end.row,F=T==W;if(F){var O=this.session.getLength(),S;do S=this.session.getLine(W);while(/[=:]/.test(S)&&++W<O);do S=this.session.getLine(T);while(/[=:]/.test(S)&&--T>0);T<0&&(T=0),W>=O&&(W=O-1)}var A=this.session.removeFullLines(T,W);A=this.$reAlignText(A,F),this.session.insert({row:T,column:0},A.join(`
954
+ `)+`
955
+ `),F||(I.start.column=0,I.end.column=A[A.length-1].length),this.selection.setRange(I)}else{D.forEach(function(G){k.substractPoint(G.cursor)});var N=0,B=1/0,U=C.map(function(G){var J=G.cursor,ne=R.getLine(J.row),de=ne.substr(J.column).search(/\S/g);return de==-1&&(de=0),J.column>N&&(N=J.column),de<B&&(B=de),de});C.forEach(function(G,J){var ne=G.cursor,de=N-ne.column,ee=U[J]-B;de>ee?R.insert(ne,a.stringRepeat(" ",de-ee)):R.remove(new g(ne.row,ne.column,ne.row,ne.column-de+ee)),G.start.column=G.end.column=N,G.start.row=G.end.row=ne.row,G.cursor=G.end}),k.fromOrientedRange(C[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}},this.$reAlignText=function(R,k){var C=!0,L=!0,D,I,T;return R.map(function(A){var N=A.match(/(\s*)(.*?)(\s*)([=:].*)/);return N?D==null?(D=N[1].length,I=N[2].length,T=N[3].length,N):(D+I+T!=N[1].length+N[2].length+N[3].length&&(L=!1),D!=N[1].length&&(C=!1),D>N[1].length&&(D=N[1].length),I<N[2].length&&(I=N[2].length),T>N[3].length&&(T=N[3].length),N):[A]}).map(k?F:C?L?O:F:S);function W(A){return a.stringRepeat(" ",A)}function F(A){return A[2]?W(D)+A[2]+W(I-A[2].length+T)+A[4].replace(/^([=:])\s+/,"$1 "):A[0]}function O(A){return A[2]?W(D+I-A[2].length)+A[2]+W(T)+A[4].replace(/^([=:])\s+/,"$1 "):A[0]}function S(A){return A[2]?W(D)+A[2]+W(T)+A[4].replace(/^([=:])\s+/,"$1 "):A[0]}}}).call(p.prototype);function b(R,k){return R.row==k.row&&R.column==k.column}r.onSessionChange=function(R){var k=R.session;k&&!k.multiSelect&&(k.$selectionMarkers=[],k.selection.$initRangeList(),k.multiSelect=k.selection),this.multiSelect=k&&k.multiSelect;var C=R.oldSession;C&&(C.multiSelect.off("addRange",this.$onAddRange),C.multiSelect.off("removeRange",this.$onRemoveRange),C.multiSelect.off("multiSelect",this.$onMultiSelect),C.multiSelect.off("singleSelect",this.$onSingleSelect),C.multiSelect.lead.off("change",this.$checkMultiselectChange),C.multiSelect.anchor.off("change",this.$checkMultiselectChange)),k&&(k.multiSelect.on("addRange",this.$onAddRange),k.multiSelect.on("removeRange",this.$onRemoveRange),k.multiSelect.on("multiSelect",this.$onMultiSelect),k.multiSelect.on("singleSelect",this.$onSingleSelect),k.multiSelect.lead.on("change",this.$checkMultiselectChange),k.multiSelect.anchor.on("change",this.$checkMultiselectChange)),k&&this.inMultiSelectMode!=k.selection.inMultiSelectMode&&(k.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())};function x(R){R.$multiselectOnSessionChange||(R.$onAddRange=R.$onAddRange.bind(R),R.$onRemoveRange=R.$onRemoveRange.bind(R),R.$onMultiSelect=R.$onMultiSelect.bind(R),R.$onSingleSelect=R.$onSingleSelect.bind(R),R.$multiselectOnSessionChange=r.onSessionChange.bind(R),R.$checkMultiselectChange=R.$checkMultiselectChange.bind(R),R.$multiselectOnSessionChange(R),R.on("changeSession",R.$multiselectOnSessionChange),R.on("mousedown",u),R.commands.addCommands(l.defaultCommands),M(R))}function M(R){if(!R.textInput)return;var k=R.textInput.getElement(),C=!1;d.addListener(k,"keydown",function(D){var I=D.keyCode==18&&!(D.ctrlKey||D.shiftKey||D.metaKey);R.$blockSelectEnabled&&I?C||(R.renderer.setMouseCursor("crosshair"),C=!0):C&&L()},R),d.addListener(k,"keyup",L,R),d.addListener(k,"blur",L,R);function L(D){C&&(R.renderer.setMouseCursor(""),C=!1)}}r.MultiSelect=x,e("./config").defineOptions(p.prototype,"editor",{enableMultiselect:{set:function(R){x(this),R?this.on("mousedown",u):this.off("mousedown",u)},value:!0},enableBlockSelect:{set:function(R){this.$blockSelectEnabled=R},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(e,r,m){var f=e("../../range").Range,g=r.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(w,u,d){var a=w.getLine(d);return this.foldingStartMarker.test(a)?"start":u=="markbeginend"&&this.foldingStopMarker&&this.foldingStopMarker.test(a)?"end":""},this.getFoldWidgetRange=function(w,u,d){return null},this.indentationBlock=function(w,u,d){var a=/\S/,l=w.getLine(u),c=l.search(a);if(c!=-1){for(var h=d||l.length,o=w.getLength(),s=u,p=u;++u<o;){var b=w.getLine(u).search(a);if(b!=-1){if(b<=c){var x=w.getTokenAt(u,0);if(!x||x.type!=="string")break}p=u}}if(p>s){var M=w.getLine(p).length;return new f(s,h,p,M)}}},this.openingBracketBlock=function(w,u,d,a,l){var c={row:d,column:a+1},h=w.$findClosingBracket(u,c,l);if(h){var o=w.foldWidgets[h.row];return o==null&&(o=w.getFoldWidget(h.row)),o=="start"&&h.row>c.row&&(h.row--,h.column=w.getLine(h.row).length),f.fromPoints(c,h)}},this.closingBracketBlock=function(w,u,d,a,l){var c={row:d,column:a},h=w.$findOpeningBracket(u,c);if(h)return h.column++,c.column--,f.fromPoints(h,c)}}).call(g.prototype)}),ace.define("ace/ext/error_marker",["require","exports","module","ace/lib/dom","ace/range","ace/config"],function(e,r,m){var f=e("../lib/dom"),g=e("../range").Range,w=e("../config").nls;function u(a,l,c){for(var h=0,o=a.length-1;h<=o;){var s=h+o>>1,p=c(l,a[s]);if(p>0)h=s+1;else if(p<0)o=s-1;else return s}return-(h+1)}function d(a,l,c){var h=a.getAnnotations().sort(g.comparePoints);if(h.length){var o=u(h,{row:l,column:-1},g.comparePoints);o<0&&(o=-o-1),o>=h.length?o=c>0?0:h.length-1:o===0&&c<0&&(o=h.length-1);var s=h[o];if(!(!s||!c)){if(s.row===l){do s=h[o+=c];while(s&&s.row===l);if(!s)return h.slice()}var p=[];l=s.row;do p[c<0?"unshift":"push"](s),s=h[o+=c];while(s&&s.row==l);return p.length&&p}}}r.showErrorMarker=function(a,l){var c=a.session,h=a.getCursorPosition(),o=h.row,s=c.widgetManager.getWidgetsAtRow(o).filter(function(D){return D.type=="errorMarker"})[0];s?s.destroy():o-=l;var p=d(c,o,l),b;if(p){var x=p[0];h.column=(x.pos&&typeof x.column!="number"?x.pos.sc:x.column)||0,h.row=x.row,b=a.renderer.$gutterLayer.$annotations[h.row]}else{if(s)return;b={displayText:[w("error-marker.good-state","Looks good!")],className:"ace_ok"}}a.session.unfold(h.row),a.selection.moveToPosition(h);var M={row:h.row,fixedWidth:!0,coverGutter:!0,el:f.createElement("div"),type:"errorMarker"},R=M.el.appendChild(f.createElement("div")),k=M.el.appendChild(f.createElement("div"));k.className="error_widget_arrow "+b.className;var C=a.renderer.$cursorLayer.getPixelPosition(h).left;k.style.left=C+a.renderer.gutterWidth-5+"px",M.el.className="error_widget_wrapper",R.className="error_widget "+b.className,b.displayText.forEach(function(D,I){R.appendChild(f.createTextNode(D)),I<b.displayText.length-1&&R.appendChild(f.createElement("br"))}),R.appendChild(f.createElement("div"));var L=function(D,I,T){if(I===0&&(T==="esc"||T==="return"))return M.destroy(),{command:"null"}};M.destroy=function(){a.$mouseHandler.isMousePressed||(a.keyBinding.removeKeyboardHandler(L),c.widgetManager.removeLineWidget(M),a.off("changeSelection",M.destroy),a.off("changeSession",M.destroy),a.off("mouseup",M.destroy),a.off("change",M.destroy))},a.keyBinding.addKeyboardHandler(L),a.on("changeSelection",M.destroy),a.on("changeSession",M.destroy),a.on("mouseup",M.destroy),a.on("change",M.destroy),a.session.widgetManager.addLineWidget(M),M.el.onmousedown=a.focus.bind(a),a.renderer.scrollCursorIntoView(null,.5,{bottom:M.el.offsetHeight})},f.importCssString(`
956
+ .error_widget_wrapper {
957
+ background: inherit;
958
+ color: inherit;
959
+ border:none
960
+ }
961
+ .error_widget {
962
+ border-top: solid 2px;
963
+ border-bottom: solid 2px;
964
+ margin: 5px 0;
965
+ padding: 10px 40px;
966
+ white-space: pre-wrap;
967
+ }
968
+ .error_widget.ace_error, .error_widget_arrow.ace_error{
969
+ border-color: #ff5a5a
970
+ }
971
+ .error_widget.ace_warning, .error_widget_arrow.ace_warning{
972
+ border-color: #F1D817
973
+ }
974
+ .error_widget.ace_info, .error_widget_arrow.ace_info{
975
+ border-color: #5a5a5a
976
+ }
977
+ .error_widget.ace_ok, .error_widget_arrow.ace_ok{
978
+ border-color: #5aaa5a
979
+ }
980
+ .error_widget_arrow {
981
+ position: absolute;
982
+ border: solid 5px;
983
+ border-top-color: transparent!important;
984
+ border-right-color: transparent!important;
985
+ border-left-color: transparent!important;
986
+ top: -5px;
987
+ }
988
+ `,"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(e,r,m){e("./loader_build")(r);var f=e("./lib/dom"),g=e("./range").Range,w=e("./editor").Editor,u=e("./edit_session").EditSession,d=e("./undomanager").UndoManager,a=e("./virtual_renderer").VirtualRenderer;e("./worker/worker_client"),e("./keyboard/hash_handler"),e("./placeholder"),e("./multi_select"),e("./mode/folding/fold_mode"),e("./theme/textmate"),e("./ext/error_marker"),r.config=e("./config"),r.edit=function(c,h){if(typeof c=="string"){var o=c;if(c=document.getElementById(o),!c)throw new Error("ace.edit can't find div #"+o)}if(c&&c.env&&c.env.editor instanceof w)return c.env.editor;var s="";if(c&&/input|textarea/i.test(c.tagName)){var p=c;s=p.value,c=f.createElement("pre"),p.parentNode.replaceChild(c,p)}else c&&(s=c.textContent,c.innerHTML="");var b=r.createEditSession(s),x=new w(new a(c),b,h),M={document:b,editor:x,onResize:x.resize.bind(x,null)};return p&&(M.textarea=p),x.on("destroy",function(){M.editor.container.env=null}),x.container.env=x.env=M,x},r.createEditSession=function(c,h){var o=new u(c,h);return o.setUndoManager(new d),o},r.Range=g,r.Editor=w,r.EditSession=u,r.UndoManager=d,r.VirtualRenderer=a;var l=r.config.version;r.version=l}),(function(){ace.require(["ace/ace"],function(e){e&&(e.config.init(!0),e.define=ace.define);var r=(function(){return this})();!r&&typeof window<"u"&&(r=window),!r&&typeof self<"u"&&(r=self),r.ace||(r.ace=e);for(var m in e)e.hasOwnProperty(m)&&(r.ace[m]=e[m]);r.ace.default=r.ace,t&&(t.exports=r.ace)})})()})(sg)),sg.exports}var X2=On("m",xA()),lg={exports:{}},cg;function CA(){return cg||(cg=1,(function(t,n){ace.define("ace/mode/ruby_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(e,r,m){var f=e("../lib/oop"),g=e("./text_highlight_rules").TextHighlightRules,w=r.constantOtherSymbol={token:"constant.other.symbol.ruby",regex:"[:](?:[A-Za-z_]|[@$](?=[a-zA-Z0-9_]))[a-zA-Z0-9_]*[!=?]?"};r.qString={token:"string",regex:"['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"},r.qqString={token:"string",regex:'["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'},r.tString={token:"string",regex:"[`](?:(?:\\\\.)|(?:[^'\\\\]))*?[`]"};var u=r.constantNumericHex={token:"constant.numeric",regex:"0[xX][0-9a-fA-F](?:[0-9a-fA-F]|_(?=[0-9a-fA-F]))*\\b"},d=r.constantNumericBinary={token:"constant.numeric",regex:/\b(0[bB][01](?:[01]|_(?=[01]))*)\b/},a=r.constantNumericDecimal={token:"constant.numeric",regex:/\b(0[dD](?:[1-9](?:[\d]|_(?=[\d]))*|0))\b/},l=r.constantNumericOctal={token:"constant.numeric",regex:/\b(0[oO]?(?:[1-7](?:[0-7]|_(?=[0-7]))*|0))\b/},c=r.constantNumericRational={token:"constant.numeric",regex:/\b([\d]+(?:[./][\d]+)?ri?)\b/},h=r.constantNumericComplex={token:"constant.numeric",regex:/\b([\d]i)\b/},o=r.constantNumericFloat={token:"constant.numeric",regex:"[+-]?\\d(?:\\d|_(?=\\d))*(?:(?:\\.\\d(?:\\d|_(?=\\d))*)?(?:[eE][+-]?\\d+)?)?i?\\b"},s=r.instanceVariable={token:"variable.instance",regex:"@{1,2}[a-zA-Z_\\d]+"},p=function(){var b="abort|Array|assert|assert_equal|assert_not_equal|assert_same|assert_not_same|assert_nil|assert_not_nil|assert_match|assert_no_match|assert_in_delta|assert_throws|assert_raise|assert_nothing_raised|assert_instance_of|assert_kind_of|assert_respond_to|assert_operator|assert_send|assert_difference|assert_no_difference|assert_recognizes|assert_generates|assert_response|assert_redirected_to|assert_template|assert_select|assert_select_email|assert_select_rjs|assert_select_encoded|css_select|at_exit|attr|attr_writer|attr_reader|attr_accessor|attr_accessible|autoload|binding|block_given?|callcc|caller|catch|chomp|chomp!|chop|chop!|defined?|delete_via_redirect|eval|exec|exit|exit!|fail|Float|flunk|follow_redirect!|fork|form_for|form_tag|format|gets|global_variables|gsub|gsub!|get_via_redirect|host!|https?|https!|include|Integer|lambda|link_to|link_to_unless_current|link_to_function|link_to_remote|load|local_variables|loop|open|open_session|p|print|printf|proc|putc|puts|post_via_redirect|put_via_redirect|raise|rand|raw|readline|readlines|redirect?|request_via_redirect|require|scan|select|set_trace_func|sleep|split|sprintf|srand|String|stylesheet_link_tag|syscall|system|sub|sub!|test|throw|trace_var|trap|untrace_var|atan2|cos|exp|frexp|ldexp|log|log10|sin|sqrt|tan|render|javascript_include_tag|csrf_meta_tag|label_tag|text_field_tag|submit_tag|check_box_tag|content_tag|radio_button_tag|text_area_tag|password_field_tag|hidden_field_tag|fields_for|select_tag|options_for_select|options_from_collection_for_select|collection_select|time_zone_select|select_date|select_time|select_datetime|date_select|time_select|datetime_select|select_year|select_month|select_day|select_hour|select_minute|select_second|file_field_tag|file_field|respond_to|skip_before_filter|around_filter|after_filter|verify|protect_from_forgery|rescue_from|helper_method|redirect_to|before_filter|send_data|send_file|validates_presence_of|validates_uniqueness_of|validates_length_of|validates_format_of|validates_acceptance_of|validates_associated|validates_exclusion_of|validates_inclusion_of|validates_numericality_of|validates_with|validates_each|authenticate_or_request_with_http_basic|authenticate_or_request_with_http_digest|filter_parameter_logging|match|get|post|resources|redirect|scope|assert_routing|translate|localize|extract_locale_from_tld|caches_page|expire_page|caches_action|expire_action|cache|expire_fragment|expire_cache_for|observe|cache_sweeper|has_many|has_one|belongs_to|has_and_belongs_to_many|p|warn|refine|using|module_function|extend|alias_method|private_class_method|remove_method|undef_method",x="alias|and|BEGIN|begin|break|case|class|def|defined|do|else|elsif|END|end|ensure|__FILE__|finally|for|gem|if|in|__LINE__|module|next|not|or|private|protected|public|redo|rescue|retry|return|super|then|undef|unless|until|when|while|yield|__ENCODING__|prepend",M="true|TRUE|false|FALSE|nil|NIL|ARGF|ARGV|DATA|ENV|RUBY_PLATFORM|RUBY_RELEASE_DATE|RUBY_VERSION|STDERR|STDIN|STDOUT|TOPLEVEL_BINDING|RUBY_PATCHLEVEL|RUBY_REVISION|RUBY_COPYRIGHT|RUBY_ENGINE|RUBY_ENGINE_VERSION|RUBY_DESCRIPTION",R="$DEBUG|$defout|$FILENAME|$LOAD_PATH|$SAFE|$stdin|$stdout|$stderr|$VERBOSE|$!|root_url|flash|session|cookies|params|request|response|logger|self",k=this.$keywords=this.createKeywordMapper({keyword:x,"constant.language":M,"variable.language":R,"support.function":b,"invalid.deprecated":"debugger"},"identifier"),C=`\\\\(?:n(?:[1-7][0-7]{0,2}|0)|[nsrtvfbae'"\\\\]|c(?:\\\\M-)?.|M-(?:\\\\C-|\\\\c)?.|C-(?:\\\\M-)?.|[0-7]{3}|x[\\da-fA-F]{2}|u[\\da-fA-F]{4}|u{[\\da-fA-F]{1,6}(?:\\s[\\da-fA-F]{1,6})*})`,L={"(":")","[":"]","{":"}","<":">","^":"^","|":"|","%":"%"};this.$rules={start:[{token:"comment",regex:"#.*$"},{token:"comment.multiline",regex:"^=begin(?=$|\\s.*$)",next:"comment"},{token:"string.regexp",regex:/[/](?=.*\/)/,next:"regex"},[{token:["constant.other.symbol.ruby","string.start"],regex:/(:)?(")/,push:[{token:"constant.language.escape",regex:C},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.end",regex:/"/,next:"pop"},{defaultToken:"string"}]},{token:"string.start",regex:/`/,push:[{token:"constant.language.escape",regex:C},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.end",regex:/`/,next:"pop"},{defaultToken:"string"}]},{token:["constant.other.symbol.ruby","string.start"],regex:/(:)?(')/,push:[{token:"constant.language.escape",regex:/\\['\\]/},{token:"string.end",regex:/'/,next:"pop"},{defaultToken:"string"}]},{token:"string.start",regex:/%[qwx]([(\[<{^|%])/,onMatch:function(D,I,T){T.length&&(T=[]);var W=D[D.length-1];return T.unshift(W,I),this.next="qStateWithoutInterpolation",this.token}},{token:"string.start",regex:/%[QWX]?([(\[<{^|%])/,onMatch:function(D,I,T){T.length&&(T=[]);var W=D[D.length-1];return T.unshift(W,I),this.next="qStateWithInterpolation",this.token}},{token:"constant.other.symbol.ruby",regex:/%[si]([(\[<{^|%])/,onMatch:function(D,I,T){T.length&&(T=[]);var W=D[D.length-1];return T.unshift(W,I),this.next="sStateWithoutInterpolation",this.token}},{token:"constant.other.symbol.ruby",regex:/%[SI]([(\[<{^|%])/,onMatch:function(D,I,T){T.length&&(T=[]);var W=D[D.length-1];return T.unshift(W,I),this.next="sStateWithInterpolation",this.token}},{token:"string.regexp",regex:/%[r]([(\[<{^|%])/,onMatch:function(D,I,T){T.length&&(T=[]);var W=D[D.length-1];return T.unshift(W,I),this.next="rState",this.token}}],{token:"punctuation",regex:"::"},s,{token:"variable.global",regex:"[$][a-zA-Z_\\d]+"},{token:"support.class",regex:"[A-Z][a-zA-Z_\\d]*"},{token:["punctuation.operator","support.function"],regex:/(\.)([a-zA-Z_\d]+)(?=\()/},{token:["punctuation.operator","identifier"],regex:/(\.)([a-zA-Z_][a-zA-Z_\d]*)/},{token:"string.character",regex:"\\B\\?(?:"+C+"|\\S)"},{token:"punctuation.operator",regex:/\?(?=.+:)/},c,h,w,u,o,d,a,l,{token:"constant.language.boolean",regex:"(?:true|false)\\b"},{token:k,regex:"[a-zA-Z_$][a-zA-Z0-9_$]*\\b"},{token:"punctuation.separator.key-value",regex:"=>"},{stateName:"heredoc",onMatch:function(D,I,T){var W=D[2]=="-"||D[2]=="~"?"indentedHeredoc":"heredoc",F=D.split(this.splitRegex);return T.push(W,F[3]),[{type:"constant",value:F[1]},{type:"string",value:F[2]},{type:"support.class",value:F[3]},{type:"string",value:F[4]}]},regex:"(<<[-~]?)(['\"`]?)([\\w]+)(['\"`]?)",rules:{heredoc:[{onMatch:function(D,I,T){return D===T[1]?(T.shift(),T.shift(),this.next=T[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}],indentedHeredoc:[{token:"string",regex:"^ +"},{onMatch:function(D,I,T){return D===T[1]?(T.shift(),T.shift(),this.next=T[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}]}},{regex:"$",token:"empty",next:function(D,I){return I[0]==="heredoc"||I[0]==="indentedHeredoc"?I[0]:D}},{token:"keyword.operator",regex:"!|\\$|%|&|\\*|/|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\||\\b(?:in|instanceof|new|delete|typeof|void)"},{token:"paren.lparen",regex:"[[({]"},{token:"paren.rparen",regex:"[\\])}]",onMatch:function(D,I,T){return this.next="",D=="}"&&T.length>1&&T[1]!="start"&&(T.shift(),this.next=T.shift()),this.token}},{token:"text",regex:"\\s+"},{token:"punctuation.operator",regex:/[?:,;.]/}],comment:[{token:"comment.multiline",regex:"^=end(?=$|\\s.*$)",next:"start"},{token:"comment",regex:".+"}],qStateWithInterpolation:[{token:"string.start",regex:/[(\[<{]/,onMatch:function(D,I,T){return T.length&&D===T[0]?(T.unshift(D,I),this.token):"string"}},{token:"constant.language.escape",regex:C},{token:"constant.language.escape",regex:/\\./},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.end",regex:/[)\]>}^|%]/,onMatch:function(D,I,T){return T.length&&D===L[T[0]]?(T.shift(),this.next=T.shift(),this.token):(this.next="","string")}},{defaultToken:"string"}],qStateWithoutInterpolation:[{token:"string.start",regex:/[(\[<{]/,onMatch:function(D,I,T){return T.length&&D===T[0]?(T.unshift(D,I),this.token):"string"}},{token:"constant.language.escape",regex:/\\['\\]/},{token:"constant.language.escape",regex:/\\./},{token:"string.end",regex:/[)\]>}^|%]/,onMatch:function(D,I,T){return T.length&&D===L[T[0]]?(T.shift(),this.next=T.shift(),this.token):(this.next="","string")}},{defaultToken:"string"}],sStateWithoutInterpolation:[{token:"constant.other.symbol.ruby",regex:/[(\[<{]/,onMatch:function(D,I,T){return T.length&&D===T[0]?(T.unshift(D,I),this.token):"constant.other.symbol.ruby"}},{token:"constant.other.symbol.ruby",regex:/[)\]>}^|%]/,onMatch:function(D,I,T){return T.length&&D===L[T[0]]?(T.shift(),this.next=T.shift(),this.token):(this.next="","constant.other.symbol.ruby")}},{defaultToken:"constant.other.symbol.ruby"}],sStateWithInterpolation:[{token:"constant.other.symbol.ruby",regex:/[(\[<{]/,onMatch:function(D,I,T){return T.length&&D===T[0]?(T.unshift(D,I),this.token):"constant.other.symbol.ruby"}},{token:"constant.language.escape",regex:C},{token:"constant.language.escape",regex:/\\./},{token:"paren.start",regex:/#{/,push:"start"},{token:"constant.other.symbol.ruby",regex:/[)\]>}^|%]/,onMatch:function(D,I,T){return T.length&&D===L[T[0]]?(T.shift(),this.next=T.shift(),this.token):(this.next="","constant.other.symbol.ruby")}},{defaultToken:"constant.other.symbol.ruby"}],rState:[{token:"string.regexp",regex:/[(\[<{]/,onMatch:function(D,I,T){return T.length&&D===T[0]?(T.unshift(D,I),this.token):"constant.language.escape"}},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.regexp",regex:/\//},{token:"string.regexp",regex:/[)\]>}^|%][imxouesn]*/,onMatch:function(D,I,T){return T.length&&D[0]===L[T[0]]?(T.shift(),this.next=T.shift(),this.token):(this.next="","constant.language.escape")}},{include:"regex"},{defaultToken:"string.regexp"}],regex:[{token:"regexp.keyword",regex:/\\[wWdDhHsS]/},{token:"constant.language.escape",regex:/\\[AGbBzZ]/},{token:"constant.language.escape",regex:/\\g<[a-zA-Z0-9]*>/},{token:["constant.language.escape","regexp.keyword","constant.language.escape"],regex:/(\\p{\^?)(Alnum|Alpha|Blank|Cntrl|Digit|Graph|Lower|Print|Punct|Space|Upper|XDigit|Word|ASCII|Any|Assigned|Arabic|Armenian|Balinese|Bengali|Bopomofo|Braille|Buginese|Buhid|Canadian_Aboriginal|Carian|Cham|Cherokee|Common|Coptic|Cuneiform|Cypriot|Cyrillic|Deseret|Devanagari|Ethiopic|Georgian|Glagolitic|Gothic|Greek|Gujarati|Gurmukhi|Han|Hangul|Hanunoo|Hebrew|Hiragana|Inherited|Kannada|Katakana|Kayah_Li|Kharoshthi|Khmer|Lao|Latin|Lepcha|Limbu|Linear_B|Lycian|Lydian|Malayalam|Mongolian|Myanmar|New_Tai_Lue|Nko|Ogham|Ol_Chiki|Old_Italic|Old_Persian|Oriya|Osmanya|Phags_Pa|Phoenician|Rejang|Runic|Saurashtra|Shavian|Sinhala|Sundanese|Syloti_Nagri|Syriac|Tagalog|Tagbanwa|Tai_Le|Tamil|Telugu|Thaana|Thai|Tibetan|Tifinagh|Ugaritic|Vai|Yi|Ll|Lm|Lt|Lu|Lo|Mn|Mc|Me|Nd|Nl|Pc|Pd|Ps|Pe|Pi|Pf|Po|No|Sm|Sc|Sk|So|Zs|Zl|Zp|Cc|Cf|Cn|Co|Cs|N|L|M|P|S|Z|C)(})/},{token:["constant.language.escape","invalid","constant.language.escape"],regex:/(\\p{\^?)([^/]*)(})/},{token:"regexp.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"string.regexp",regex:/[/][imxouesn]*/,next:"start"},{token:"invalid",regex:/\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/},{token:"constant.language.escape",regex:/\(\?(?:[:=!>]|<'?[a-zA-Z]*'?>|<[=!])|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/},{token:"constant.language.delimiter",regex:/\|/},{token:"regexp.keyword",regex:/\[\[:(?:alnum|alpha|blank|cntrl|digit|graph|lower|print|punct|space|upper|xdigit|word|ascii):\]\]/},{token:"constant.language.escape",regex:/\[\^?/,push:"regex_character_class"},{defaultToken:"string.regexp"}],regex_character_class:[{token:"regexp.keyword",regex:/\\[wWdDhHsS]/},{token:"regexp.charclass.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"constant.language.escape",regex:/&?&?\[\^?/,push:"regex_character_class"},{token:"constant.language.escape",regex:"]",next:"pop"},{token:"constant.language.escape",regex:"-"},{defaultToken:"string.regexp.characterclass"}]},this.normalizeRules()};f.inherits(p,g),r.RubyHighlightRules=p}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(e,r,m){var f=e("../range").Range,g=function(){};(function(){this.checkOutdent=function(w,u){return/^\s+$/.test(w)?/^\s*\}/.test(u):!1},this.autoOutdent=function(w,u){var d=w.getLine(u),a=d.match(/^(\s*\})/);if(!a)return 0;var l=a[1].length,c=w.findMatchingBracket({row:u,column:l});if(!c||c.row==u)return 0;var h=this.$getIndent(w.getLine(c.row));w.replace(new f(u,0,u,l-1),h)},this.$getIndent=function(w){return w.match(/^\s*/)[0]}}).call(g.prototype),r.MatchingBraceOutdent=g}),ace.define("ace/mode/folding/ruby",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range","ace/token_iterator"],function(e,r,m){var f=e("../../lib/oop"),g=e("./fold_mode").FoldMode,w=e("../../range").Range,u=e("../../token_iterator").TokenIterator,d=r.FoldMode=function(){};f.inherits(d,g),(function(){this.indentKeywords={class:1,def:1,module:1,do:1,unless:1,if:1,while:1,for:1,until:1,begin:1,else:0,elsif:0,rescue:0,ensure:0,when:0,end:-1,case:1,"=begin":1,"=end":-1},this.foldingStartMarker=/(?:\s|^)(def|do|while|class|unless|module|if|for|until|begin|else|elsif|case|rescue|ensure|when)\b|({\s*$)|(=begin)/,this.foldingStopMarker=/(=end(?=$|\s.*$))|(^\s*})|\b(end)\b/,this.getFoldWidget=function(a,l,c){var h=a.getLine(c),o=this.foldingStartMarker.test(h),s=this.foldingStopMarker.test(h);if(o&&!s){var p=h.match(this.foldingStartMarker);if(p[1]){if((p[1]=="if"||p[1]=="else"||p[1]=="while"||p[1]=="until"||p[1]=="unless")&&(p[1]=="else"&&/^\s*else\s*$/.test(h)===!1||/^\s*(?:if|else|while|until|unless)\s*/.test(h)===!1)||p[1]=="when"&&/\sthen\s/.test(h)===!0)return;if(a.getTokenAt(c,p.index+2).type==="keyword")return"start"}else if(!p[3]||a.getTokenAt(c,p.index+1).type==="comment.multiline")return"start"}if(l!="markbeginend"||!s||o&&s)return"";var p=h.match(this.foldingStopMarker);if(p[3]==="end"){if(a.getTokenAt(c,p.index+1).type==="keyword")return"end"}else if(!p[1]||a.getTokenAt(c,p.index+1).type==="comment.multiline")return"end"},this.getFoldWidgetRange=function(a,l,c){var h=a.doc.getLine(c),o=this.foldingStartMarker.exec(h);if(o)return o[1]||o[3]?this.rubyBlock(a,c,o.index+2):this.openingBracketBlock(a,"{",c,o.index);var o=this.foldingStopMarker.exec(h);if(o)return o[3]==="end"&&a.getTokenAt(c,o.index+1).type==="keyword"?this.rubyBlock(a,c,o.index+1):o[1]==="=end"&&a.getTokenAt(c,o.index+1).type==="comment.multiline"?this.rubyBlock(a,c,o.index+1):this.closingBracketBlock(a,"}",c,o.index+o[0].length)},this.rubyBlock=function(a,l,c,h){var o=new u(a,l,c),s=o.getCurrentToken();if(!(!s||s.type!="keyword"&&s.type!="comment.multiline")){var p=s.value,b=a.getLine(l);switch(s.value){case"if":case"unless":case"while":case"until":var x=new RegExp("^\\s*"+s.value);if(!x.test(b))return;var M=this.indentKeywords[p];break;case"when":if(/\sthen\s/.test(b))return;case"elsif":case"rescue":case"ensure":var M=1;break;case"else":var x=new RegExp("^\\s*"+s.value+"\\s*$");if(!x.test(b))return;var M=1;break;default:var M=this.indentKeywords[p]}var R=[p];if(M){var k=M===-1?a.getLine(l-1).length:a.getLine(l).length,C=l,L=[];if(L.push(o.getCurrentTokenRange()),o.step=M===-1?o.stepBackward:o.stepForward,s.type=="comment.multiline"){for(;s=o.step();)if(s.type==="comment.multiline"){if(M==1){if(k=6,s.value=="=end")break}else if(s.value=="=begin")break}}else for(;s=o.step();){var D=!1;if(s.type==="keyword"){var I=M*this.indentKeywords[s.value];switch(b=a.getLine(o.getCurrentTokenRow()),s.value){case"do":for(var T=o.$tokenIndex-1;T>=0;T--){var W=o.$rowTokens[T];if(W&&(W.value=="while"||W.value=="until"||W.value=="for")){I=0;break}}break;case"else":var x=new RegExp("^\\s*"+s.value+"\\s*$");(!x.test(b)||p=="case")&&(I=0,D=!0);break;case"if":case"unless":case"while":case"until":var x=new RegExp("^\\s*"+s.value);x.test(b)||(I=0,D=!0);break;case"when":(/\sthen\s/.test(b)||p=="case")&&(I=0,D=!0)}if(I>0)R.unshift(s.value);else if(I<=0&&D===!1){if(R.shift(),!R.length&&((p=="while"||p=="until"||p=="for")&&s.value!="do"||s.value=="do"&&M==-1&&I!=0||s.value!="do"))break;I===0&&R.unshift(s.value)}}}if(!s)return null;if(h)return L.push(o.getCurrentTokenRange()),L;var l=o.getCurrentTokenRow();if(M===-1){if(s.type==="comment.multiline")var F=6;else var F=a.getLine(l).length;return new w(l,F,C-1,k)}return new w(C,k,l-1,a.getLine(l-1).length)}}}}).call(d.prototype)}),ace.define("ace/mode/ruby",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ruby_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/folding/ruby"],function(e,r,m){var f=e("../lib/oop"),g=e("./text").Mode,w=e("./ruby_highlight_rules").RubyHighlightRules,u=e("./matching_brace_outdent").MatchingBraceOutdent,d=e("../range").Range,a=e("./folding/ruby").FoldMode,l=function(){this.HighlightRules=w,this.$outdent=new u,this.$behaviour=this.$defaultBehaviour,this.foldingRules=new a,this.indentKeywords=this.foldingRules.indentKeywords};f.inherits(l,g),(function(){this.lineCommentStart="#",this.getNextLineIndent=function(c,h,o){var s=this.$getIndent(h),p=this.getTokenizer().getLineTokens(h,c),b=p.tokens;if(b.length&&b[b.length-1].type=="comment")return s;if(c=="start"){var x=h.match(/^.*[\{\(\[]\s*$/),M=h.match(/^\s*(class|def|module)\s.*$/),R=h.match(/.*do(\s*|\s+\|.*\|\s*)$/),k=h.match(/^\s*(if|else|when|elsif|unless|while|for|begin|rescue|ensure)\s*/);(x||M||R||k)&&(s+=o)}return s},this.checkOutdent=function(c,h,o){return/^\s+(end|else|rescue|ensure)$/.test(h+o)||this.$outdent.checkOutdent(h,o)},this.autoOutdent=function(c,h,o){var s=h.getLine(o);if(/}/.test(s))return this.$outdent.autoOutdent(h,o);var p=this.$getIndent(s),b=h.getLine(o-1),x=this.$getIndent(b),M=h.getTabString();x.length<=p.length&&p.slice(-M.length)==M&&h.remove(new d(o,p.length-M.length,o,p.length))},this.getMatching=function(c,h,o){if(h==null){var s=c.selection.lead;o=s.column,h=s.row}var p=c.getTokenAt(h,o);if(p&&p.value in this.indentKeywords)return this.foldingRules.rubyBlock(c,h,o,!0)},this.$id="ace/mode/ruby",this.snippetFileId="ace/snippets/ruby"}).call(l.prototype),r.Mode=l}),(function(){ace.require(["ace/mode/ruby"],function(e){t&&(t.exports=e)})})()})(lg)),lg.exports}CA();var ug={exports:{}},hg;function AA(){return hg||(hg=1,(function(t,n){ace.define("ace/mode/python_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(e,r,m){var f=e("../lib/oop"),g=e("./text_highlight_rules").TextHighlightRules,w=function(){var u="and|as|assert|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|not|or|pass|print|raise|return|try|while|with|yield|async|await|nonlocal",d="True|False|None|NotImplemented|Ellipsis|__debug__",a="abs|divmod|input|open|staticmethod|all|enumerate|int|ord|str|any|eval|isinstance|pow|sum|basestring|execfile|issubclass|print|super|binfile|bin|iter|property|tuple|bool|filter|len|range|type|bytearray|float|list|raw_input|unichr|callable|format|locals|reduce|unicode|chr|frozenset|long|reload|vars|classmethod|getattr|map|repr|xrange|cmp|globals|max|reversed|zip|compile|hasattr|memoryview|round|__import__|complex|hash|min|apply|delattr|help|next|setattr|set|buffer|dict|hex|object|slice|coerce|dir|id|oct|sorted|intern|ascii|breakpoint|bytes",l=this.createKeywordMapper({"invalid.deprecated":"debugger","support.function":a,"variable.language":"self|cls","constant.language":d,keyword:u},"identifier"),c="[uU]?",h="[rR]",o="[fF]",s="(?:[rR][fF]|[fF][rR])",p="(?:(?:[1-9]\\d*)|(?:0))",b="(?:0[oO]?[0-7]+)",x="(?:0[xX][\\dA-Fa-f]+)",M="(?:0[bB][01]+)",R="(?:"+p+"|"+b+"|"+x+"|"+M+")",k="(?:[eE][+-]?\\d+)",C="(?:\\.\\d+)",L="(?:\\d+)",D="(?:(?:"+L+"?"+C+")|(?:"+L+"\\.))",I="(?:(?:"+D+"|"+L+")"+k+")",T="(?:"+I+"|"+D+")",W=`\\\\(x[0-9A-Fa-f]{2}|[0-7]{3}|[\\\\abfnrtv'"]|U[0-9A-Fa-f]{8}|u[0-9A-Fa-f]{4})`;this.$rules={start:[{token:"comment",regex:"#.*$"},{token:"string",regex:c+'"{3}',next:"qqstring3"},{token:"string",regex:c+'"(?=.)',next:"qqstring"},{token:"string",regex:c+"'{3}",next:"qstring3"},{token:"string",regex:c+"'(?=.)",next:"qstring"},{token:"string",regex:h+'"{3}',next:"rawqqstring3"},{token:"string",regex:h+'"(?=.)',next:"rawqqstring"},{token:"string",regex:h+"'{3}",next:"rawqstring3"},{token:"string",regex:h+"'(?=.)",next:"rawqstring"},{token:"string",regex:o+'"{3}',next:"fqqstring3"},{token:"string",regex:o+'"(?=.)',next:"fqqstring"},{token:"string",regex:o+"'{3}",next:"fqstring3"},{token:"string",regex:o+"'(?=.)",next:"fqstring"},{token:"string",regex:s+'"{3}',next:"rfqqstring3"},{token:"string",regex:s+'"(?=.)',next:"rfqqstring"},{token:"string",regex:s+"'{3}",next:"rfqstring3"},{token:"string",regex:s+"'(?=.)",next:"rfqstring"},{token:"keyword.operator",regex:"\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|%|@|<<|>>|&|\\||\\^|~|<|>|<=|=>|==|!=|<>|="},{token:"punctuation",regex:",|:|;|\\->|\\+=|\\-=|\\*=|\\/=|\\/\\/=|%=|@=|&=|\\|=|^=|>>=|<<=|\\*\\*="},{token:"paren.lparen",regex:"[\\[\\(\\{]"},{token:"paren.rparen",regex:"[\\]\\)\\}]"},{token:["keyword","text","entity.name.function"],regex:"(def|class)(\\s+)([\\u00BF-\\u1FFF\\u2C00-\\uD7FF\\w]+)"},{token:"text",regex:"\\s+"},{include:"constants"}],qqstring3:[{token:"constant.language.escape",regex:W},{token:"string",regex:'"{3}',next:"start"},{defaultToken:"string"}],qstring3:[{token:"constant.language.escape",regex:W},{token:"string",regex:"'{3}",next:"start"},{defaultToken:"string"}],qqstring:[{token:"constant.language.escape",regex:W},{token:"string",regex:"\\\\$",next:"qqstring"},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],qstring:[{token:"constant.language.escape",regex:W},{token:"string",regex:"\\\\$",next:"qstring"},{token:"string",regex:"'|$",next:"start"},{defaultToken:"string"}],rawqqstring3:[{token:"string",regex:'"{3}',next:"start"},{defaultToken:"string"}],rawqstring3:[{token:"string",regex:"'{3}",next:"start"},{defaultToken:"string"}],rawqqstring:[{token:"string",regex:"\\\\$",next:"rawqqstring"},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],rawqstring:[{token:"string",regex:"\\\\$",next:"rawqstring"},{token:"string",regex:"'|$",next:"start"},{defaultToken:"string"}],fqqstring3:[{token:"constant.language.escape",regex:W},{token:"string",regex:'"{3}',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqstring3:[{token:"constant.language.escape",regex:W},{token:"string",regex:"'{3}",next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqqstring:[{token:"constant.language.escape",regex:W},{token:"string",regex:"\\\\$",next:"fqqstring"},{token:"string",regex:'"|$',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqstring:[{token:"constant.language.escape",regex:W},{token:"string",regex:"'|$",next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],rfqqstring3:[{token:"string",regex:'"{3}',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],rfqstring3:[{token:"string",regex:"'{3}",next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],rfqqstring:[{token:"string",regex:"\\\\$",next:"rfqqstring"},{token:"string",regex:'"|$',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],rfqstring:[{token:"string",regex:"'|$",next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqstringParRules:[{token:"paren.lparen",regex:"[\\[\\(]"},{token:"paren.rparen",regex:"[\\]\\)]"},{token:"string",regex:"\\s+"},{token:"string",regex:"'[^']*'"},{token:"string",regex:'"[^"]*"'},{token:"function.support",regex:"(!s|!r|!a)"},{include:"constants"},{token:"paren.rparen",regex:"}",next:"pop"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"}],constants:[{token:"constant.numeric",regex:"(?:"+T+"|\\d+)[jJ]\\b"},{token:"constant.numeric",regex:T},{token:"constant.numeric",regex:R+"[lL]\\b"},{token:"constant.numeric",regex:R+"\\b"},{token:["punctuation","function.support"],regex:"(\\.)([a-zA-Z_]+)\\b"},{token:l,regex:"[a-zA-Z_$][a-zA-Z0-9_$]*\\b"}]},this.normalizeRules()};f.inherits(w,g),r.PythonHighlightRules=w}),ace.define("ace/mode/folding/pythonic",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"],function(e,r,m){var f=e("../../lib/oop"),g=e("./fold_mode").FoldMode,w=r.FoldMode=function(u){this.foldingStartMarker=new RegExp("([\\[{])(?:\\s*)$|("+u+")(?:\\s*)(?:#.*)?$")};f.inherits(w,g),(function(){this.getFoldWidgetRange=function(u,d,a){var l=u.getLine(a),c=l.match(this.foldingStartMarker);if(c)return c[1]?this.openingBracketBlock(u,c[1],a,c.index):c[2]?this.indentationBlock(u,a,c.index+c[2].length):this.indentationBlock(u,a)}}).call(w.prototype)}),ace.define("ace/mode/python",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/python_highlight_rules","ace/mode/folding/pythonic","ace/range"],function(e,r,m){var f=e("../lib/oop"),g=e("./text").Mode,w=e("./python_highlight_rules").PythonHighlightRules,u=e("./folding/pythonic").FoldMode,d=e("../range").Range,a=function(){this.HighlightRules=w,this.foldingRules=new u("\\:"),this.$behaviour=this.$defaultBehaviour};f.inherits(a,g),(function(){this.lineCommentStart="#",this.$pairQuotesAfter={"'":/[ruf]/i,'"':/[ruf]/i},this.getNextLineIndent=function(c,h,o){var s=this.$getIndent(h),p=this.getTokenizer().getLineTokens(h,c),b=p.tokens;if(b.length&&b[b.length-1].type=="comment")return s;if(c=="start"){var x=h.match(/^.*[\{\(\[:]\s*$/);x&&(s+=o)}return s};var l={pass:1,return:1,raise:1,break:1,continue:1};this.checkOutdent=function(c,h,o){if(o!==`\r
989
+ `&&o!=="\r"&&o!==`
990
+ `)return!1;var s=this.getTokenizer().getLineTokens(h.trim(),c).tokens;if(!s)return!1;do var p=s.pop();while(p&&(p.type=="comment"||p.type=="text"&&p.value.match(/^\s+$/)));return p?p.type=="keyword"&&l[p.value]:!1},this.autoOutdent=function(c,h,o){o+=1;var s=this.$getIndent(h.getLine(o)),p=h.getTabString();s.slice(-p.length)==p&&h.remove(new d(o,s.length-p.length,o,s.length))},this.$id="ace/mode/python",this.snippetFileId="ace/snippets/python"}).call(a.prototype),r.Mode=a}),(function(){ace.require(["ace/mode/python"],function(e){t&&(t.exports=e)})})()})(ug)),ug.exports}AA();var dg={exports:{}},fg;function _A(){return fg||(fg=1,(function(t,n){ace.define("ace/mode/json_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(e,r,m){var f=e("../lib/oop"),g=e("./text_highlight_rules").TextHighlightRules,w=function(){this.$rules={start:[{token:"variable",regex:'["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]\\s*(?=:)'},{token:"string",regex:'"',next:"string"},{token:"constant.numeric",regex:"0[xX][0-9a-fA-F]+\\b"},{token:"constant.numeric",regex:"[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"},{token:"constant.language.boolean",regex:"(?:true|false)\\b"},{token:"text",regex:"['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"},{token:"comment",regex:"\\/\\/.*$"},{token:"comment.start",regex:"\\/\\*",next:"comment"},{token:"paren.lparen",regex:"[[({]"},{token:"paren.rparen",regex:"[\\])}]"},{token:"punctuation.operator",regex:/[,]/},{token:"text",regex:"\\s+"}],string:[{token:"constant.language.escape",regex:/\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|["\\\/bfnrt])/},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],comment:[{token:"comment.end",regex:"\\*\\/",next:"start"},{defaultToken:"comment"}]}};f.inherits(w,g),r.JsonHighlightRules=w}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(e,r,m){var f=e("../range").Range,g=function(){};(function(){this.checkOutdent=function(w,u){return/^\s+$/.test(w)?/^\s*\}/.test(u):!1},this.autoOutdent=function(w,u){var d=w.getLine(u),a=d.match(/^(\s*\})/);if(!a)return 0;var l=a[1].length,c=w.findMatchingBracket({row:u,column:l});if(!c||c.row==u)return 0;var h=this.$getIndent(w.getLine(c.row));w.replace(new f(u,0,u,l-1),h)},this.$getIndent=function(w){return w.match(/^\s*/)[0]}}).call(g.prototype),r.MatchingBraceOutdent=g}),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(e,r,m){var f=e("../../lib/oop"),g=e("../../range").Range,w=e("./fold_mode").FoldMode,u=r.FoldMode=function(d){d&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+d.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+d.end)))};f.inherits(u,w),(function(){this.foldingStartMarker=/([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/,this.foldingStopMarker=/^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/,this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/,this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/,this.startRegionRe=/^\s*(\/\*|\/\/)#?region\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(d,a,l){var c=d.getLine(l);if(this.singleLineBlockCommentRe.test(c)&&!this.startRegionRe.test(c)&&!this.tripleStarBlockCommentRe.test(c))return"";var h=this._getFoldWidgetBase(d,a,l);return!h&&this.startRegionRe.test(c)?"start":h},this.getFoldWidgetRange=function(d,a,l,c){var h=d.getLine(l);if(this.startRegionRe.test(h))return this.getCommentRegionBlock(d,h,l);var o=h.match(this.foldingStartMarker);if(o){var s=o.index;if(o[1])return this.openingBracketBlock(d,o[1],l,s);var p=d.getCommentFoldRange(l,s+o[0].length,1);return p&&!p.isMultiLine()&&(c?p=this.getSectionRange(d,l):a!="all"&&(p=null)),p}if(a!=="markbegin"){var o=h.match(this.foldingStopMarker);if(o){var s=o.index+o[0].length;return o[1]?this.closingBracketBlock(d,o[1],l,s):d.getCommentFoldRange(l,s,-1)}}},this.getSectionRange=function(d,a){var l=d.getLine(a),c=l.search(/\S/),h=a,o=l.length;a+=1;for(var s=a,p=d.getLength();++a<p;){l=d.getLine(a);var b=l.search(/\S/);if(b!==-1){if(c>b)break;var x=this.getFoldWidgetRange(d,"all",a);if(x){if(x.start.row<=h)break;if(x.isMultiLine())a=x.end.row;else if(c==b)break}s=a}}return new g(h,o,s,d.getLine(s).length)},this.getCommentRegionBlock=function(d,a,l){for(var c=a.search(/\s*$/),h=d.getLength(),o=l,s=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,p=1;++l<h;){a=d.getLine(l);var b=s.exec(a);if(b&&(b[1]?p--:p++,!p))break}var x=l;if(x>o)return new g(o,c,x,a.length)}}).call(u.prototype)}),ace.define("ace/mode/json",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/json_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/cstyle","ace/worker/worker_client"],function(e,r,m){var f=e("../lib/oop"),g=e("./text").Mode,w=e("./json_highlight_rules").JsonHighlightRules,u=e("./matching_brace_outdent").MatchingBraceOutdent,d=e("./folding/cstyle").FoldMode,a=e("../worker/worker_client").WorkerClient,l=function(){this.HighlightRules=w,this.$outdent=new u,this.$behaviour=this.$defaultBehaviour,this.foldingRules=new d};f.inherits(l,g),(function(){this.lineCommentStart="//",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(c,h,o){var s=this.$getIndent(h);if(c=="start"){var p=h.match(/^.*[\{\(\[]\s*$/);p&&(s+=o)}return s},this.checkOutdent=function(c,h,o){return this.$outdent.checkOutdent(h,o)},this.autoOutdent=function(c,h,o){this.$outdent.autoOutdent(h,o)},this.createWorker=function(c){var h=new a(["ace"],"ace/mode/json_worker","JsonWorker");return h.attachToDocument(c.getDocument()),h.on("annotate",function(o){c.setAnnotations(o.data)}),h.on("terminate",function(){c.clearAnnotations()}),h},this.$id="ace/mode/json"}).call(l.prototype),r.Mode=l}),(function(){ace.require(["ace/mode/json"],function(e){t&&(t.exports=e)})})()})(dg)),dg.exports}_A();var pg={exports:{}},gg;function kA(){return gg||(gg=1,(function(t,n){ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"],function(e,r,m){var f=e("../lib/oop");e("../lib/lang");var g=e("./text_highlight_rules").TextHighlightRules,w=r.supportType="align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|max-zoom|min-height|min-width|min-zoom|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|user-select|user-zoom|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index",u=r.supportFunction="rgb|rgba|url|attr|counter|counters",d=r.supportConstant="absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|flex-end|flex-start|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero|zoom",a=r.supportConstantColor="aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen",l=r.supportConstantFonts="arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace",c=r.numRe="\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))",h=r.pseudoElements="(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b",o=r.pseudoClasses="(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b",s=function(){var p=this.createKeywordMapper({"support.function":u,"support.constant":d,"support.type":w,"support.constant.color":a,"support.constant.fonts":l},"text",!0);this.$rules={start:[{include:["strings","url","comments"]},{token:"paren.lparen",regex:"\\{",next:"ruleset"},{token:"paren.rparen",regex:"\\}"},{token:"string",regex:"@(?!viewport)",next:"media"},{token:"keyword",regex:"#[a-z0-9-_]+"},{token:"keyword",regex:"%"},{token:"variable",regex:"\\.[a-z0-9-_]+"},{token:"string",regex:":[a-z0-9-_]+"},{token:"constant.numeric",regex:c},{token:"constant",regex:"[a-z0-9-_]+"},{caseInsensitive:!0}],media:[{include:["strings","url","comments"]},{token:"paren.lparen",regex:"\\{",next:"start"},{token:"paren.rparen",regex:"\\}",next:"start"},{token:"string",regex:";",next:"start"},{token:"keyword",regex:"(?:media|supports|document|charset|import|namespace|media|supports|document|page|font|keyframes|viewport|counter-style|font-feature-values|swash|ornaments|annotation|stylistic|styleset|character-variant)"}],comments:[{token:"comment",regex:"\\/\\*",push:[{token:"comment",regex:"\\*\\/",next:"pop"},{defaultToken:"comment"}]}],ruleset:[{regex:"-(webkit|ms|moz|o)-",token:"text"},{token:"punctuation.operator",regex:"[:;]"},{token:"paren.rparen",regex:"\\}",next:"start"},{include:["strings","url","comments"]},{token:["constant.numeric","keyword"],regex:"("+c+")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vmax|vmin|vm|vw|%)"},{token:"constant.numeric",regex:c},{token:"constant.numeric",regex:"#[a-f0-9]{6}"},{token:"constant.numeric",regex:"#[a-f0-9]{3}"},{token:["punctuation","entity.other.attribute-name.pseudo-element.css"],regex:h},{token:["punctuation","entity.other.attribute-name.pseudo-class.css"],regex:o},{include:"url"},{token:p,regex:"\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"},{token:"paren.lparen",regex:"\\{"},{caseInsensitive:!0}],url:[{token:"support.function",regex:"(?:url(:?-prefix)?|domain|regexp)\\(",push:[{token:"support.function",regex:"\\)",next:"pop"},{defaultToken:"string"}]}],strings:[{token:"string.start",regex:"'",push:[{token:"string.end",regex:"'|$",next:"pop"},{include:"escapes"},{token:"constant.language.escape",regex:/\\$/,consumeLineEnd:!0},{defaultToken:"string"}]},{token:"string.start",regex:'"',push:[{token:"string.end",regex:'"|$',next:"pop"},{include:"escapes"},{token:"constant.language.escape",regex:/\\$/,consumeLineEnd:!0},{defaultToken:"string"}]}],escapes:[{token:"constant.language.escape",regex:/\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/}]},this.normalizeRules()};f.inherits(s,g),r.CssHighlightRules=s}),ace.define("ace/mode/jsdoc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(e,r,m){var f=e("../lib/oop"),g=e("./text_highlight_rules").TextHighlightRules,w=function(){this.$rules={start:[{token:["comment.doc.tag","comment.doc.text","lparen.doc"],regex:"(@(?:param|member|typedef|property|namespace|var|const|callback))(\\s*)({)",push:[{token:"lparen.doc",regex:"{",push:[{include:"doc-syntax"},{token:"rparen.doc",regex:"}|(?=$)",next:"pop"}]},{token:["rparen.doc","text.doc","variable.parameter.doc","lparen.doc","variable.parameter.doc","rparen.doc"],regex:/(})(\s*)(?:([\w=:\/\.]+)|(?:(\[)([\w=:\/\.\-\'\" ]+)(\])))/,next:"pop"},{token:"rparen.doc",regex:"}|(?=$)",next:"pop"},{include:"doc-syntax"},{defaultToken:"text.doc"}]},{token:["comment.doc.tag","text.doc","lparen.doc"],regex:"(@(?:returns?|yields|type|this|suppress|public|protected|private|package|modifies|implements|external|exception|throws|enum|define|extends))(\\s*)({)",push:[{token:"lparen.doc",regex:"{",push:[{include:"doc-syntax"},{token:"rparen.doc",regex:"}|(?=$)",next:"pop"}]},{token:"rparen.doc",regex:"}|(?=$)",next:"pop"},{include:"doc-syntax"},{defaultToken:"text.doc"}]},{token:["comment.doc.tag","text.doc","variable.parameter.doc"],regex:'(@(?:alias|memberof|instance|module|name|lends|namespace|external|this|template|requires|param|implements|function|extends|typedef|mixes|constructor|var|memberof\\!|event|listens|exports|class|constructs|interface|emits|fires|throws|const|callback|borrows|augments))(\\s+)(\\w[\\w#.:/~"\\-]*)?'},{token:["comment.doc.tag","text.doc","variable.parameter.doc"],regex:"(@method)(\\s+)(\\w[\\w.\\(\\)]*)"},{token:"comment.doc.tag",regex:"@access\\s+(?:private|public|protected)"},{token:"comment.doc.tag",regex:"@kind\\s+(?:class|constant|event|external|file|function|member|mixin|module|namespace|typedef)"},{token:"comment.doc.tag",regex:"@\\w+(?=\\s|$)"},w.getTagRule(),{defaultToken:"comment.doc.body",caseInsensitive:!0}],"doc-syntax":[{token:"operator.doc",regex:/[|:]/},{token:"paren.doc",regex:/[\[\]]/}]},this.normalizeRules()};f.inherits(w,g),w.getTagRule=function(u){return{token:"comment.doc.tag.storage.type",regex:"\\b(?:TODO|FIXME|XXX|HACK)\\b"}},w.getStartRule=function(u){return{token:"comment.doc",regex:/\/\*\*(?!\/)/,next:u}},w.getEndRule=function(u){return{token:"comment.doc",regex:"\\*\\/",next:u}},r.JsDocCommentHighlightRules=w}),ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/jsdoc_comment_highlight_rules","ace/mode/text_highlight_rules"],function(e,r,m){function f(){var c=a.replace("\\d","\\d\\-"),h={onMatch:function(s,p,b){var x=s.charAt(1)=="/"?2:1;return x==1?(p!=this.nextState?b.unshift(this.next,this.nextState,0):b.unshift(this.next),b[2]++):x==2&&p==this.nextState&&(b[1]--,(!b[1]||b[1]<0)&&(b.shift(),b.shift())),[{type:"meta.tag.punctuation."+(x==1?"":"end-")+"tag-open.xml",value:s.slice(0,x)},{type:"meta.tag.tag-name.xml",value:s.substr(x)}]},regex:"</?(?:"+c+"|(?=>))",next:"jsxAttributes",nextState:"jsx"};this.$rules.start.unshift(h);var o={regex:"{",token:"paren.quasi.start",push:"start"};this.$rules.jsx=[o,h,{include:"reference"},{defaultToken:"string.xml"}],this.$rules.jsxAttributes=[{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",onMatch:function(s,p,b){return p==b[0]&&b.shift(),s.length==2&&(b[0]==this.nextState&&b[1]--,(!b[1]||b[1]<0)&&b.splice(0,2)),this.next=b[0]||"start",[{type:this.token,value:s}]},nextState:"jsx"},o,g("jsxAttributes"),{token:"entity.other.attribute-name.xml",regex:c},{token:"keyword.operator.attribute-equals.xml",regex:"="},{token:"text.tag-whitespace.xml",regex:"\\s+"},{token:"string.attribute-value.xml",regex:"'",stateName:"jsx_attr_q",push:[{token:"string.attribute-value.xml",regex:"'",next:"pop"},{include:"reference"},{defaultToken:"string.attribute-value.xml"}]},{token:"string.attribute-value.xml",regex:'"',stateName:"jsx_attr_qq",push:[{token:"string.attribute-value.xml",regex:'"',next:"pop"},{include:"reference"},{defaultToken:"string.attribute-value.xml"}]},h],this.$rules.reference=[{token:"constant.language.escape.reference.xml",regex:"(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"}]}function g(c){return[{token:"comment",regex:/\/\*/,next:[u.getTagRule(),{token:"comment",regex:"\\*\\/",next:c||"pop"},{defaultToken:"comment",caseInsensitive:!0}]},{token:"comment",regex:"\\/\\/",next:[u.getTagRule(),{token:"comment",regex:"$|^",next:c||"pop"},{defaultToken:"comment",caseInsensitive:!0}]}]}var w=e("../lib/oop"),u=e("./jsdoc_comment_highlight_rules").JsDocCommentHighlightRules,d=e("./text_highlight_rules").TextHighlightRules,a="[a-zA-Z\\$_¡-￿][a-zA-Z\\d\\$_¡-￿]*",l=function(c){var h={"variable.language":"Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|Symbol|Namespace|QName|XML|XMLList|ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|SyntaxError|TypeError|URIError|decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|isNaN|parseFloat|parseInt|JSON|Math|this|arguments|prototype|window|document",keyword:"const|yield|import|get|set|async|await|break|case|catch|continue|default|delete|do|else|finally|for|if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|__parent__|__count__|escape|unescape|with|__proto__|class|enum|extends|super|export|implements|private|public|interface|package|protected|static|constructor","storage.type":"const|let|var|function","constant.language":"null|Infinity|NaN|undefined","support.function":"alert","constant.language.boolean":"true|false"},o=this.createKeywordMapper(h,"identifier"),s="case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void",p="\\\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|u{[0-9a-fA-F]{1,6}}|[0-2][0-7]{0,2}|3[0-7][0-7]?|[4-7][0-7]?|.)",b="(function)(\\s*)(\\*?)",x={token:["identifier","text","paren.lparen"],regex:"(\\b(?!"+Object.values(h).join("|")+"\\b)"+a+")(\\s*)(\\()"};this.$rules={no_regex:[u.getStartRule("doc-start"),g("no_regex"),x,{token:"string",regex:"'(?=.)",next:"qstring"},{token:"string",regex:'"(?=.)',next:"qqstring"},{include:"numeric_constants"},{token:["entity.name.function","text","keyword.operator","text","storage.type","text","storage.type","text","paren.lparen"],regex:"("+a+")(\\s*)(=)(\\s*)"+b+"(\\s*)(\\()",next:"function_arguments"},{token:["storage.type","text","storage.type","text","text","entity.name.function","text","paren.lparen"],regex:"(function)(?:(?:(\\s*)(\\*)(\\s*))|(\\s+))("+a+")(\\s*)(\\()",next:"function_arguments"},{token:["entity.name.function","text","punctuation.operator","text","storage.type","text","storage.type","text","paren.lparen"],regex:"("+a+")(\\s*)(:)(\\s*)"+b+"(\\s*)(\\()",next:"function_arguments"},{token:["text","text","storage.type","text","storage.type","text","paren.lparen"],regex:"(:)(\\s*)"+b+"(\\s*)(\\()",next:"function_arguments"},{token:"keyword",regex:`from(?=\\s*('|"))`},{token:"keyword",regex:"(?:"+s+")\\b",next:"start"},{token:"support.constant",regex:/that\b/},{token:["storage.type","punctuation.operator","support.function.firebug"],regex:/(console)(\.)(warn|info|log|error|debug|time|trace|timeEnd|assert)\b/},{token:o,regex:a},{token:"punctuation.operator",regex:/[.](?![.])/,next:"property"},{token:"storage.type",regex:/=>/,next:"start"},{token:"keyword.operator",regex:/--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,next:"start"},{token:"punctuation.operator",regex:/[?:,;.]/,next:"start"},{token:"paren.lparen",regex:/[\[({]/,next:"start"},{token:"paren.rparen",regex:/[\])}]/},{token:"comment",regex:/^#!.*$/}],property:[{token:"text",regex:"\\s+"},{token:"keyword.operator",regex:/=/},{token:["storage.type","text","storage.type","text","paren.lparen"],regex:b+"(\\s*)(\\()",next:"function_arguments"},{token:["storage.type","text","storage.type","text","text","entity.name.function","text","paren.lparen"],regex:"(function)(?:(?:(\\s*)(\\*)(\\s*))|(\\s+))(\\w+)(\\s*)(\\()",next:"function_arguments"},{token:"punctuation.operator",regex:/[.](?![.])/},{token:"support.function",regex:"prototype"},{token:"support.function",regex:/(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|lter|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward|rEach)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/},{token:"support.function.dom",regex:/(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/},{token:"support.constant",regex:/(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/},{token:"identifier",regex:a},{regex:"",token:"empty",next:"no_regex"}],start:[u.getStartRule("doc-start"),g("start"),{token:"string.regexp",regex:"\\/",next:"regex"},{token:"text",regex:"\\s+|^$",next:"start"},{token:"empty",regex:"",next:"no_regex"}],regex:[{token:"regexp.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"string.regexp",regex:"/[sxngimy]*",next:"no_regex"},{token:"invalid",regex:/\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/},{token:"constant.language.escape",regex:/\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/},{token:"constant.language.delimiter",regex:/\|/},{token:"constant.language.escape",regex:/\[\^?/,next:"regex_character_class"},{token:"empty",regex:"$",next:"no_regex"},{defaultToken:"string.regexp"}],regex_character_class:[{token:"regexp.charclass.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"constant.language.escape",regex:"]",next:"regex"},{token:"constant.language.escape",regex:"-"},{token:"empty",regex:"$",next:"no_regex"},{defaultToken:"string.regexp.charachterclass"}],default_parameter:[{token:"string",regex:"'(?=.)",push:[{token:"string",regex:"'|$",next:"pop"},{include:"qstring"}]},{token:"string",regex:'"(?=.)',push:[{token:"string",regex:'"|$',next:"pop"},{include:"qqstring"}]},{token:"constant.language",regex:"null|Infinity|NaN|undefined"},{include:"numeric_constants"},{token:"punctuation.operator",regex:",",next:"function_arguments"},{token:"text",regex:"\\s+"},{token:"punctuation.operator",regex:"$"},{token:"empty",regex:"",next:"no_regex"}],function_arguments:[g("function_arguments"),{token:"variable.parameter",regex:a},{token:"punctuation.operator",regex:","},{token:"text",regex:"\\s+"},{token:"punctuation.operator",regex:"$"},{token:"empty",regex:"",next:"no_regex"}],qqstring:[{token:"constant.language.escape",regex:p},{token:"string",regex:"\\\\$",consumeLineEnd:!0},{token:"string",regex:'"|$',next:"no_regex"},{defaultToken:"string"}],qstring:[{token:"constant.language.escape",regex:p},{token:"string",regex:"\\\\$",consumeLineEnd:!0},{token:"string",regex:"'|$",next:"no_regex"},{defaultToken:"string"}],numeric_constants:[{token:"constant.numeric",regex:/0(?:[xX][0-9a-fA-F_]+|[oO][0-7_]+|[bB][01_]+)\b/},{token:"constant.numeric",regex:/(?:\d[\d_]*(?:\.[\d_]*)?|\.\d[\d_]*)(?:[eE][+-]?\d+\b)?/}]},(!c||!c.noES6)&&(this.$rules.no_regex.unshift({regex:"[{}]",onMatch:function(M,R,k){if(this.next=M=="{"?this.nextState:"",M=="{"&&k.length)k.unshift("start",R);else if(M=="}"&&k.length&&(k.shift(),this.next=k.shift(),this.next.indexOf("string")!=-1||this.next.indexOf("jsx")!=-1))return"paren.quasi.end";return M=="{"?"paren.lparen":"paren.rparen"},nextState:"start"},{token:"string.quasi.start",regex:/`/,push:[{token:"constant.language.escape",regex:p},{token:"paren.quasi.start",regex:/\${/,push:"start"},{token:"string.quasi.end",regex:/`/,next:"pop"},{defaultToken:"string.quasi"}]},{token:["variable.parameter","text"],regex:"("+a+")(\\s*)(?=\\=>)"},{token:"paren.lparen",regex:"(\\()(?=[^\\(]+\\s*=>)",next:"function_arguments"},{token:"variable.language",regex:"(?:(?:(?:Weak)?(?:Set|Map))|Promise)\\b"}),this.$rules.function_arguments.unshift({token:"keyword.operator",regex:"=",next:"default_parameter"},{token:"keyword.operator",regex:"\\.{3}"}),this.$rules.property.unshift({token:"support.function",regex:"(findIndex|repeat|startsWith|endsWith|includes|isSafeInteger|trunc|cbrt|log2|log10|sign|then|catch|finally|resolve|reject|race|any|all|allSettled|keys|entries|isInteger)\\b(?=\\()"},{token:"constant.language",regex:"(?:MAX_SAFE_INTEGER|MIN_SAFE_INTEGER|EPSILON)\\b"}),(!c||c.jsx!=0)&&f.call(this)),this.embedRules(u,"doc-",[u.getEndRule("no_regex")]),this.normalizeRules()};w.inherits(l,d),r.JavaScriptHighlightRules=l}),ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(e,r,m){var f=e("../lib/oop"),g=e("./text_highlight_rules").TextHighlightRules,w=function(u){var d="[_:a-zA-ZÀ-￿][-_:.a-zA-Z0-9À-￿]*";this.$rules={start:[{token:"string.cdata.xml",regex:"<\\!\\[CDATA\\[",next:"cdata"},{token:["punctuation.instruction.xml","keyword.instruction.xml"],regex:"(<\\?)("+d+")",next:"processing_instruction"},{token:"comment.start.xml",regex:"<\\!--",next:"comment"},{token:["xml-pe.doctype.xml","xml-pe.doctype.xml"],regex:"(<\\!)(DOCTYPE)(?=[\\s])",next:"doctype",caseInsensitive:!0},{include:"tag"},{token:"text.end-tag-open.xml",regex:"</"},{token:"text.tag-open.xml",regex:"<"},{include:"reference"},{defaultToken:"text.xml"}],processing_instruction:[{token:"entity.other.attribute-name.decl-attribute-name.xml",regex:d},{token:"keyword.operator.decl-attribute-equals.xml",regex:"="},{include:"whitespace"},{include:"string"},{token:"punctuation.xml-decl.xml",regex:"\\?>",next:"start"}],doctype:[{include:"whitespace"},{include:"string"},{token:"xml-pe.doctype.xml",regex:">",next:"start"},{token:"xml-pe.xml",regex:"[-_a-zA-Z0-9:]+"},{token:"punctuation.int-subset",regex:"\\[",push:"int_subset"}],int_subset:[{token:"text.xml",regex:"\\s+"},{token:"punctuation.int-subset.xml",regex:"]",next:"pop"},{token:["punctuation.markup-decl.xml","keyword.markup-decl.xml"],regex:"(<\\!)("+d+")",push:[{token:"text",regex:"\\s+"},{token:"punctuation.markup-decl.xml",regex:">",next:"pop"},{include:"string"}]}],cdata:[{token:"string.cdata.xml",regex:"\\]\\]>",next:"start"},{token:"text.xml",regex:"\\s+"},{token:"text.xml",regex:"(?:[^\\]]|\\](?!\\]>))+"}],comment:[{token:"comment.end.xml",regex:"-->",next:"start"},{defaultToken:"comment.xml"}],reference:[{token:"constant.language.escape.reference.xml",regex:"(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"}],attr_reference:[{token:"constant.language.escape.reference.attribute-value.xml",regex:"(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"}],tag:[{token:["meta.tag.punctuation.tag-open.xml","meta.tag.punctuation.end-tag-open.xml","meta.tag.tag-name.xml"],regex:"(?:(<)|(</))((?:"+d+":)?"+d+")",next:[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:"start"}]}],tag_whitespace:[{token:"text.tag-whitespace.xml",regex:"\\s+"}],whitespace:[{token:"text.whitespace.xml",regex:"\\s+"}],string:[{token:"string.xml",regex:"'",push:[{token:"string.xml",regex:"'",next:"pop"},{defaultToken:"string.xml"}]},{token:"string.xml",regex:'"',push:[{token:"string.xml",regex:'"',next:"pop"},{defaultToken:"string.xml"}]}],attributes:[{token:"entity.other.attribute-name.xml",regex:d},{token:"keyword.operator.attribute-equals.xml",regex:"="},{include:"tag_whitespace"},{include:"attribute_value"}],attribute_value:[{token:"string.attribute-value.xml",regex:"'",push:[{token:"string.attribute-value.xml",regex:"'",next:"pop"},{include:"attr_reference"},{defaultToken:"string.attribute-value.xml"}]},{token:"string.attribute-value.xml",regex:'"',push:[{token:"string.attribute-value.xml",regex:'"',next:"pop"},{include:"attr_reference"},{defaultToken:"string.attribute-value.xml"}]}]},this.constructor===w&&this.normalizeRules()};(function(){this.embedTagRules=function(u,d,a){this.$rules.tag.unshift({token:["meta.tag.punctuation.tag-open.xml","meta.tag."+a+".tag-name.xml"],regex:"(<)("+a+"(?=\\s|>|$))",next:[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:d+"start"}]}),this.$rules[a+"-end"]=[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:"start",onMatch:function(l,c,h){return h.splice(0),this.token}}],this.embedRules(u,d,[{token:["meta.tag.punctuation.end-tag-open.xml","meta.tag."+a+".tag-name.xml"],regex:"(</)("+a+"(?=\\s|>|$))",next:a+"-end"},{token:"string.cdata.xml",regex:"<\\!\\[CDATA\\["},{token:"string.cdata.xml",regex:"\\]\\]>"}])}}).call(g.prototype),f.inherits(w,g),r.XmlHighlightRules=w}),ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"],function(e,r,m){var f=e("../lib/oop"),g=e("../lib/lang"),w=e("./css_highlight_rules").CssHighlightRules,u=e("./javascript_highlight_rules").JavaScriptHighlightRules,d=e("./xml_highlight_rules").XmlHighlightRules,a=g.createMap({a:"anchor",button:"form",form:"form",img:"image",input:"form",label:"form",option:"form",script:"script",select:"form",textarea:"form",style:"style",table:"table",tbody:"table",td:"table",tfoot:"table",th:"table",tr:"table"}),l=function(){d.call(this),this.addRules({attributes:[{include:"tag_whitespace"},{token:"entity.other.attribute-name.xml",regex:"[-_a-zA-Z0-9:.]+"},{token:"keyword.operator.attribute-equals.xml",regex:"=",push:[{include:"tag_whitespace"},{token:"string.unquoted.attribute-value.html",regex:"[^<>='\"`\\s]+",next:"pop"},{token:"empty",regex:"",next:"pop"}]},{include:"attribute_value"}],tag:[{token:function(c,h){var o=a[h];return["meta.tag.punctuation."+(c=="<"?"":"end-")+"tag-open.xml","meta.tag"+(o?"."+o:"")+".tag-name.xml"]},regex:"(</?)([-_a-zA-Z0-9:.]+)",next:"tag_stuff"}],tag_stuff:[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:"start"}]}),this.embedTagRules(w,"css-","style"),this.embedTagRules(new u({jsx:!1}).getRules(),"js-","script"),this.constructor===l&&this.normalizeRules()};f.inherits(l,d),r.HtmlHighlightRules=l}),ace.define("ace/mode/markdown_highlight_rules",["require","exports","module","ace/config","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/html_highlight_rules"],function(e,r,m){var f=e("../config").$modes,g=e("../lib/oop"),w=e("../lib/lang"),u=e("./text_highlight_rules").TextHighlightRules,d=e("./html_highlight_rules").HtmlHighlightRules,a=function(c){return"(?:[^"+w.escapeRegExp(c)+"\\\\]|\\\\.)*"},l=function(){d.call(this);var c={token:"support.function",regex:/^\s*(```+[^`]*|~~~+[^~]*)$/,onMatch:function(o,s,p,b){var x=o.match(/^(\s*)([`~]+)(.*)/),M=/[\w-]+|$/.exec(x[3])[0];return f[M]||(M=""),p.unshift("githubblock",[],[x[1],x[2],M],s),this.token},next:"githubblock"},h=[{token:"support.function",regex:".*",onMatch:function(o,s,p,b){var x=p[1],M=p[2][0],R=p[2][1],k=p[2][2],C=/^(\s*)(`+|~+)\s*$/.exec(o);if(C&&C[1].length<M.length+3&&C[2].length>=R.length&&C[2][0]==R[0])return p.splice(0,3),this.next=p.shift(),this.token;if(this.next="",k&&f[k]){var L=f[k].getTokenizer().getLineTokens(o,x.slice(0));return p[1]=L.state,L.tokens}return this.token}}];this.$rules.start.unshift({token:"empty_line",regex:"^$",next:"allowBlock"},{token:"markup.heading.1",regex:"^=+(?=\\s*$)"},{token:"markup.heading.2",regex:"^\\-+(?=\\s*$)"},{token:function(o){return"markup.heading."+o.length},regex:/^#{1,6}(?=\s|$)/,next:"header"},c,{token:"string.blockquote",regex:"^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",next:"blockquote"},{token:"constant",regex:"^ {0,3}(?:(?:\\* ?){3,}|(?:\\- ?){3,}|(?:\\_ ?){3,})\\s*$",next:"allowBlock"},{token:"markup.list",regex:"^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",next:"listblock-start"},{include:"basic"}),this.addRules({basic:[{token:"constant.language.escape",regex:/\\[\\`*_{}\[\]()#+\-.!]/},{token:"support.function",regex:"(`+)(.*?[^`])(\\1)"},{token:["text","constant","text","url","string","text"],regex:'^([ ]{0,3}\\[)([^\\]]+)(\\]:\\s*)([^ ]+)(\\s*(?:["][^"]+["])?(\\s*))$'},{token:["text","string","text","constant","text"],regex:"(\\[)("+a("]")+")(\\]\\s*\\[)("+a("]")+")(\\])"},{token:["text","string","text","markup.underline","string","text"],regex:"(\\!?\\[)("+a("]")+')(\\]\\()((?:[^\\)\\s\\\\]|\\\\.|\\s(?=[^"]))*)(\\s*"'+a('"')+'"\\s*)?(\\))'},{token:"string.strong",regex:"([*]{2}|[_]{2}(?=\\S))(.*?\\S[*_]*)(\\1)"},{token:"string.emphasis",regex:"([*]|[_](?=\\S))(.*?\\S[*_]*)(\\1)"},{token:["text","url","text"],regex:`(<)((?:https?|ftp|dict):[^'">\\s]+|(?:mailto:)?[-.\\w]+\\@[-a-z0-9]+(?:\\.[-a-z0-9]+)*\\.[a-z]+)(>)`}],allowBlock:[{token:"support.function",regex:"^ {4}.+",next:"allowBlock"},{token:"empty_line",regex:"^$",next:"allowBlock"},{token:"empty",regex:"",next:"start"}],header:[{regex:"$",next:"start"},{include:"basic"},{defaultToken:"heading"}],"listblock-start":[{token:"support.variable",regex:/(?:\[[ x]\])?/,next:"listblock"}],listblock:[{token:"empty_line",regex:"^$",next:"start"},{token:"markup.list",regex:"^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",next:"listblock-start"},{include:"basic",noEscape:!0},c,{defaultToken:"list"}],blockquote:[{token:"empty_line",regex:"^\\s*$",next:"start"},{token:"string.blockquote",regex:"^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",next:"blockquote"},{include:"basic",noEscape:!0},{defaultToken:"string.blockquote"}],githubblock:h}),this.normalizeRules()};g.inherits(l,u),r.MarkdownHighlightRules=l}),ace.define("ace/mode/folding/markdown",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"],function(e,r,m){var f=e("../../lib/oop"),g=e("./fold_mode").FoldMode,w=e("../../range").Range,u=r.FoldMode=function(){};f.inherits(u,g),(function(){this.foldingStartMarker=/^(?:[=-]+\s*$|#{1,6} |`{3})/,this.getFoldWidget=function(d,a,l){var c=d.getLine(l);return this.foldingStartMarker.test(c)?c[0]=="`"&&d.bgTokenizer.getState(l)=="start"?"end":"start":""},this.getFoldWidgetRange=function(d,a,l){function c(D){return M=d.getTokens(D)[0],M&&M.type.lastIndexOf(R,0)===0}function h(){var D=M.value[0];return D=="="?6:D=="-"?5:7-M.value.search(/[^#]|$/)}var o=d.getLine(l),s=o.length,p=d.getLength(),b=l,x=l;if(o.match(this.foldingStartMarker)){if(o[0]=="`"){if(d.bgTokenizer.getState(l)!=="start"){for(;++l<p&&(o=d.getLine(l),!(o[0]=="`"&o.substring(0,3)=="```")););return new w(b,s,l,0)}for(;l-- >0&&(o=d.getLine(l),!(o[0]=="`"&o.substring(0,3)=="```")););return new w(l,o.length,b,0)}var M,R="markup.heading";if(c(l)){for(var k=h();++l<p;)if(c(l)){var C=h();if(C>=k)break}if(x=l-(!M||["=","-"].indexOf(M.value[0])==-1?1:2),x>b)for(;x>b&&/^\s*$/.test(d.getLine(x));)x--;if(x>b){var L=d.getLine(x).length;return new w(b,s,x,L)}}}}}).call(u.prototype)}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(e,r,m){var f=e("../range").Range,g=function(){};(function(){this.checkOutdent=function(w,u){return/^\s+$/.test(w)?/^\s*\}/.test(u):!1},this.autoOutdent=function(w,u){var d=w.getLine(u),a=d.match(/^(\s*\})/);if(!a)return 0;var l=a[1].length,c=w.findMatchingBracket({row:u,column:l});if(!c||c.row==u)return 0;var h=this.$getIndent(w.getLine(c.row));w.replace(new f(u,0,u,l-1),h)},this.$getIndent=function(w){return w.match(/^\s*/)[0]}}).call(g.prototype),r.MatchingBraceOutdent=g}),ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator"],function(e,r,m){function f(a,l){return a&&a.type.lastIndexOf(l+".xml")>-1}var g=e("../../lib/oop"),w=e("../behaviour").Behaviour,u=e("../../token_iterator").TokenIterator,d=function(){this.add("string_dquotes","insertion",function(a,l,c,h,o){if(o=='"'||o=="'"){var s=o,p=h.doc.getTextRange(c.getSelectionRange());if(p!==""&&p!=="'"&&p!='"'&&c.getWrapBehavioursEnabled())return{text:s+p+s,selection:!1};var b=c.getCursorPosition(),x=h.doc.getLine(b.row),M=x.substring(b.column,b.column+1),R=new u(h,b.row,b.column),k=R.getCurrentToken();if(M==s&&(f(k,"attribute-value")||f(k,"string")))return{text:"",selection:[1,1]};if(k||(k=R.stepBackward()),!k)return;for(;f(k,"tag-whitespace")||f(k,"whitespace");)k=R.stepBackward();var C=!M||M.match(/\s/);if(f(k,"attribute-equals")&&(C||M==">")||f(k,"decl-attribute-equals")&&(C||M=="?"))return{text:s+s,selection:[1,1]}}}),this.add("string_dquotes","deletion",function(a,l,c,h,o){var s=h.doc.getTextRange(o);if(!o.isMultiLine()&&(s=='"'||s=="'")){var p=h.doc.getLine(o.start.row),b=p.substring(o.start.column+1,o.start.column+2);if(b==s)return o.end.column++,o}}),this.add("autoclosing","insertion",function(a,l,c,h,o){if(o==">"){var s=c.getSelectionRange().start,p=new u(h,s.row,s.column),b=p.getCurrentToken()||p.stepBackward();if(!b||!(f(b,"tag-name")||f(b,"tag-whitespace")||f(b,"attribute-name")||f(b,"attribute-equals")||f(b,"attribute-value"))||f(b,"reference.attribute-value"))return;if(f(b,"attribute-value")){var x=p.getCurrentTokenColumn()+b.value.length;if(s.column<x)return;if(s.column==x){var M=p.stepForward();if(M&&f(M,"attribute-value"))return;p.stepBackward()}}if(/^\s*>/.test(h.getLine(s.row).slice(s.column)))return;for(;!f(b,"tag-name");)if(b=p.stepBackward(),b.value=="<"){b=p.stepForward();break}var R=p.getCurrentTokenRow(),k=p.getCurrentTokenColumn();if(f(p.stepBackward(),"end-tag-open"))return;var C=b.value;return R==s.row&&(C=C.substring(0,s.column-k)),this.voidElements&&this.voidElements.hasOwnProperty(C.toLowerCase())?void 0:{text:"></"+C+">",selection:[1,1]}}}),this.add("autoindent","insertion",function(a,l,c,h,o){if(o==`
991
+ `){var s=c.getCursorPosition(),p=h.getLine(s.row),b=new u(h,s.row,s.column),x=b.getCurrentToken();if(f(x,"")&&x.type.indexOf("tag-close")!==-1){if(x.value=="/>")return;for(;x&&x.type.indexOf("tag-name")===-1;)x=b.stepBackward();if(!x)return;var M=x.value,R=b.getCurrentTokenRow();if(x=b.stepBackward(),!x||x.type.indexOf("end-tag")!==-1)return;if(this.voidElements&&!this.voidElements[M]||!this.voidElements){var k=h.getTokenAt(s.row,s.column+1),p=h.getLine(R),C=this.$getIndent(p),L=C+h.getTabString();return k&&k.value==="</"?{text:`
992
+ `+L+`
993
+ `+C,selection:[1,L.length,1,L.length]}:{text:`
994
+ `+L}}}}})};g.inherits(d,w),r.XmlBehaviour=d}),ace.define("ace/mode/behaviour/javascript",["require","exports","module","ace/lib/oop","ace/token_iterator","ace/mode/behaviour/cstyle","ace/mode/behaviour/xml"],function(e,r,m){var f=e("../../lib/oop"),g=e("../../token_iterator").TokenIterator,w=e("../behaviour/cstyle").CstyleBehaviour,u=e("../behaviour/xml").XmlBehaviour,d=function(){var a=new u({closeCurlyBraces:!0}).getBehaviours();this.addBehaviours(a),this.inherit(w),this.add("autoclosing-fragment","insertion",function(l,c,h,o,s){if(s==">"){var p=h.getSelectionRange().start,b=new g(o,p.row,p.column),x=b.getCurrentToken()||b.stepBackward();if(!x)return;if(x.value=="<")return{text:"></>",selection:[1,1]}}})};f.inherits(d,w),r.JavaScriptBehaviour=d}),ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(e,r,m){function f(l,c){return l&&l.type&&l.type.lastIndexOf(c+".xml")>-1}var g=e("../../lib/oop"),w=e("../../range").Range,u=e("./fold_mode").FoldMode,d=r.FoldMode=function(l,c){u.call(this),this.voidElements=l||{},this.optionalEndTags=g.mixin({},this.voidElements),c&&g.mixin(this.optionalEndTags,c)};g.inherits(d,u);var a=function(){this.tagName="",this.closing=!1,this.selfClosing=!1,this.start={row:0,column:0},this.end={row:0,column:0}};(function(){this.getFoldWidget=function(l,c,h){var o=this._getFirstTagInLine(l,h);return o?o.closing||!o.tagName&&o.selfClosing?c==="markbeginend"?"end":"":!o.tagName||o.selfClosing||this.voidElements.hasOwnProperty(o.tagName.toLowerCase())||this._findEndTagInLine(l,h,o.tagName,o.end.column)?"":"start":this.getCommentFoldWidget(l,h)},this.getCommentFoldWidget=function(l,c){return/comment/.test(l.getState(c))&&/<!-/.test(l.getLine(c))?"start":""},this._getFirstTagInLine=function(l,c){for(var h=l.getTokens(c),o=new a,s=0;s<h.length;s++){var p=h[s];if(f(p,"tag-open")){if(o.end.column=o.start.column+p.value.length,o.closing=f(p,"end-tag-open"),p=h[++s],!p)return null;if(o.tagName=p.value,p.value===""){if(p=h[++s],!p)return null;o.tagName=p.value}for(o.end.column+=p.value.length,s++;s<h.length;s++)if(p=h[s],o.end.column+=p.value.length,f(p,"tag-close")){o.selfClosing=p.value=="/>";break}return o}if(f(p,"tag-close"))return o.selfClosing=p.value=="/>",o;o.start.column+=p.value.length}return null},this._findEndTagInLine=function(l,c,h,o){for(var s=l.getTokens(c),p=0,b=0;b<s.length;b++){var x=s[b];if(p+=x.value.length,!(p<o-1)&&f(x,"end-tag-open")&&(x=s[b+1],f(x,"tag-name")&&x.value===""&&(x=s[b+2]),x&&x.value==h))return!0}return!1},this.getFoldWidgetRange=function(l,c,h){var o=this._getFirstTagInLine(l,h);if(!o)return this.getCommentFoldWidget(l,h)&&l.getCommentFoldRange(h,l.getLine(h).length);var s=l.getMatchingTags({row:h,column:0});if(s)return new w(s.openTag.end.row,s.openTag.end.column,s.closeTag.start.row,s.closeTag.start.column)}}).call(d.prototype)}),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(e,r,m){var f=e("../../lib/oop"),g=e("../../range").Range,w=e("./fold_mode").FoldMode,u=r.FoldMode=function(d){d&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+d.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+d.end)))};f.inherits(u,w),(function(){this.foldingStartMarker=/([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/,this.foldingStopMarker=/^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/,this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/,this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/,this.startRegionRe=/^\s*(\/\*|\/\/)#?region\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(d,a,l){var c=d.getLine(l);if(this.singleLineBlockCommentRe.test(c)&&!this.startRegionRe.test(c)&&!this.tripleStarBlockCommentRe.test(c))return"";var h=this._getFoldWidgetBase(d,a,l);return!h&&this.startRegionRe.test(c)?"start":h},this.getFoldWidgetRange=function(d,a,l,c){var h=d.getLine(l);if(this.startRegionRe.test(h))return this.getCommentRegionBlock(d,h,l);var o=h.match(this.foldingStartMarker);if(o){var s=o.index;if(o[1])return this.openingBracketBlock(d,o[1],l,s);var p=d.getCommentFoldRange(l,s+o[0].length,1);return p&&!p.isMultiLine()&&(c?p=this.getSectionRange(d,l):a!="all"&&(p=null)),p}if(a!=="markbegin"){var o=h.match(this.foldingStopMarker);if(o){var s=o.index+o[0].length;return o[1]?this.closingBracketBlock(d,o[1],l,s):d.getCommentFoldRange(l,s,-1)}}},this.getSectionRange=function(d,a){var l=d.getLine(a),c=l.search(/\S/),h=a,o=l.length;a+=1;for(var s=a,p=d.getLength();++a<p;){l=d.getLine(a);var b=l.search(/\S/);if(b!==-1){if(c>b)break;var x=this.getFoldWidgetRange(d,"all",a);if(x){if(x.start.row<=h)break;if(x.isMultiLine())a=x.end.row;else if(c==b)break}s=a}}return new g(h,o,s,d.getLine(s).length)},this.getCommentRegionBlock=function(d,a,l){for(var c=a.search(/\s*$/),h=d.getLength(),o=l,s=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,p=1;++l<h;){a=d.getLine(l);var b=s.exec(a);if(b&&(b[1]?p--:p++,!p))break}var x=l;if(x>o)return new g(o,c,x,a.length)}}).call(u.prototype)}),ace.define("ace/mode/folding/javascript",["require","exports","module","ace/lib/oop","ace/mode/folding/xml","ace/mode/folding/cstyle"],function(e,r,m){var f=e("../../lib/oop"),g=e("./xml").FoldMode,w=e("./cstyle").FoldMode,u=r.FoldMode=function(d){d&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+d.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+d.end))),this.xmlFoldMode=new g};f.inherits(u,w),(function(){this.getFoldWidgetRangeBase=this.getFoldWidgetRange,this.getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(d,a,l){var c=this.getFoldWidgetBase(d,a,l);return c||this.xmlFoldMode.getFoldWidget(d,a,l)},this.getFoldWidgetRange=function(d,a,l,c){var h=this.getFoldWidgetRangeBase(d,a,l,c);return h||this.xmlFoldMode.getFoldWidgetRange(d,a,l)}}).call(u.prototype)}),ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/javascript","ace/mode/folding/javascript"],function(e,r,m){var f=e("../lib/oop"),g=e("./text").Mode,w=e("./javascript_highlight_rules").JavaScriptHighlightRules,u=e("./matching_brace_outdent").MatchingBraceOutdent,d=e("../worker/worker_client").WorkerClient,a=e("./behaviour/javascript").JavaScriptBehaviour,l=e("./folding/javascript").FoldMode,c=function(){this.HighlightRules=w,this.$outdent=new u,this.$behaviour=new a,this.foldingRules=new l};f.inherits(c,g),(function(){this.lineCommentStart="//",this.blockComment={start:"/*",end:"*/"},this.$quotes={'"':'"',"'":"'","`":"`"},this.$pairQuotesAfter={"`":/\w/},this.getNextLineIndent=function(h,o,s){var p=this.$getIndent(o),b=this.getTokenizer().getLineTokens(o,h),x=b.tokens,M=b.state;if(x.length&&x[x.length-1].type=="comment")return p;if(h=="start"||h=="no_regex"){var R=o.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);R&&(p+=s)}else if(h=="doc-start"&&(M=="start"||M=="no_regex"))return"";return p},this.checkOutdent=function(h,o,s){return this.$outdent.checkOutdent(o,s)},this.autoOutdent=function(h,o,s){this.$outdent.autoOutdent(o,s)},this.createWorker=function(h){var o=new d(["ace"],"ace/mode/javascript_worker","JavaScriptWorker");return o.attachToDocument(h.getDocument()),o.on("annotate",function(s){h.setAnnotations(s.data)}),o.on("terminate",function(){h.clearAnnotations()}),o},this.$id="ace/mode/javascript",this.snippetFileId="ace/snippets/javascript"}).call(c.prototype),r.Mode=c}),ace.define("ace/mode/css_completions",["require","exports","module"],function(e,r,m){var f={background:{"#$0":1},"background-color":{"#$0":1,transparent:1,fixed:1},"background-image":{"url('/$0')":1},"background-repeat":{repeat:1,"repeat-x":1,"repeat-y":1,"no-repeat":1,inherit:1},"background-position":{bottom:2,center:2,left:2,right:2,top:2,inherit:2},"background-attachment":{scroll:1,fixed:1},"background-size":{cover:1,contain:1},"background-clip":{"border-box":1,"padding-box":1,"content-box":1},"background-origin":{"border-box":1,"padding-box":1,"content-box":1},border:{"solid $0":1,"dashed $0":1,"dotted $0":1,"#$0":1},"border-color":{"#$0":1},"border-style":{solid:2,dashed:2,dotted:2,double:2,groove:2,hidden:2,inherit:2,inset:2,none:2,outset:2,ridged:2},"border-collapse":{collapse:1,separate:1},bottom:{px:1,em:1,"%":1},clear:{left:1,right:1,both:1,none:1},color:{"#$0":1,"rgb(#$00,0,0)":1},cursor:{default:1,pointer:1,move:1,text:1,wait:1,help:1,progress:1,"n-resize":1,"ne-resize":1,"e-resize":1,"se-resize":1,"s-resize":1,"sw-resize":1,"w-resize":1,"nw-resize":1},display:{none:1,block:1,inline:1,"inline-block":1,"table-cell":1},"empty-cells":{show:1,hide:1},float:{left:1,right:1,none:1},"font-family":{Arial:2,"Comic Sans MS":2,Consolas:2,"Courier New":2,Courier:2,Georgia:2,Monospace:2,"Sans-Serif":2,"Segoe UI":2,Tahoma:2,"Times New Roman":2,"Trebuchet MS":2,Verdana:1},"font-size":{px:1,em:1,"%":1},"font-weight":{bold:1,normal:1},"font-style":{italic:1,normal:1},"font-variant":{normal:1,"small-caps":1},height:{px:1,em:1,"%":1},left:{px:1,em:1,"%":1},"letter-spacing":{normal:1},"line-height":{normal:1},"list-style-type":{none:1,disc:1,circle:1,square:1,decimal:1,"decimal-leading-zero":1,"lower-roman":1,"upper-roman":1,"lower-greek":1,"lower-latin":1,"upper-latin":1,georgian:1,"lower-alpha":1,"upper-alpha":1},margin:{px:1,em:1,"%":1},"margin-right":{px:1,em:1,"%":1},"margin-left":{px:1,em:1,"%":1},"margin-top":{px:1,em:1,"%":1},"margin-bottom":{px:1,em:1,"%":1},"max-height":{px:1,em:1,"%":1},"max-width":{px:1,em:1,"%":1},"min-height":{px:1,em:1,"%":1},"min-width":{px:1,em:1,"%":1},overflow:{hidden:1,visible:1,auto:1,scroll:1},"overflow-x":{hidden:1,visible:1,auto:1,scroll:1},"overflow-y":{hidden:1,visible:1,auto:1,scroll:1},padding:{px:1,em:1,"%":1},"padding-top":{px:1,em:1,"%":1},"padding-right":{px:1,em:1,"%":1},"padding-bottom":{px:1,em:1,"%":1},"padding-left":{px:1,em:1,"%":1},"page-break-after":{auto:1,always:1,avoid:1,left:1,right:1},"page-break-before":{auto:1,always:1,avoid:1,left:1,right:1},position:{absolute:1,relative:1,fixed:1,static:1},right:{px:1,em:1,"%":1},"table-layout":{fixed:1,auto:1},"text-decoration":{none:1,underline:1,"line-through":1,blink:1},"text-align":{left:1,right:1,center:1,justify:1},"text-transform":{capitalize:1,uppercase:1,lowercase:1,none:1},top:{px:1,em:1,"%":1},"vertical-align":{top:1,bottom:1},visibility:{hidden:1,visible:1},"white-space":{nowrap:1,normal:1,pre:1,"pre-line":1,"pre-wrap":1},width:{px:1,em:1,"%":1},"word-spacing":{normal:1},filter:{"alpha(opacity=$0100)":1},"text-shadow":{"$02px 2px 2px #777":1},"text-overflow":{"ellipsis-word":1,clip:1,ellipsis:1},"-moz-border-radius":1,"-moz-border-radius-topright":1,"-moz-border-radius-bottomright":1,"-moz-border-radius-topleft":1,"-moz-border-radius-bottomleft":1,"-webkit-border-radius":1,"-webkit-border-top-right-radius":1,"-webkit-border-top-left-radius":1,"-webkit-border-bottom-right-radius":1,"-webkit-border-bottom-left-radius":1,"-moz-box-shadow":1,"-webkit-box-shadow":1,transform:{"rotate($00deg)":1,"skew($00deg)":1},"-moz-transform":{"rotate($00deg)":1,"skew($00deg)":1},"-webkit-transform":{"rotate($00deg)":1,"skew($00deg)":1}},g=function(){};(function(){this.completionsDefined=!1,this.defineCompletions=function(){if(document){var w=document.createElement("c").style;for(var u in w)if(typeof w[u]=="string"){var d=u.replace(/[A-Z]/g,function(a){return"-"+a.toLowerCase()});f.hasOwnProperty(d)||(f[d]=1)}}this.completionsDefined=!0},this.getCompletions=function(w,u,d,a){if(this.completionsDefined||this.defineCompletions(),w==="ruleset"||u.$mode.$id=="ace/mode/scss"){var l=u.getLine(d.row).substr(0,d.column),c=/\([^)]*$/.test(l);return c&&(l=l.substr(l.lastIndexOf("(")+1)),/:[^;]+$/.test(l)?this.getPropertyValueCompletions(w,u,d,a):this.getPropertyCompletions(w,u,d,a,c)}return[]},this.getPropertyCompletions=function(w,u,d,a,l){l=l||!1;var c=Object.keys(f);return c.map(function(h){return{caption:h,snippet:h+": $0"+(l?"":";"),meta:"property",score:1e6}})},this.getPropertyValueCompletions=function(w,u,d,a){var l=u.getLine(d.row).substr(0,d.column),c=(/([\w\-]+):[^:]*$/.exec(l)||{})[1];if(!c)return[];var h=[];return c in f&&typeof f[c]=="object"&&(h=Object.keys(f[c])),h.map(function(o){return{caption:o,snippet:o,meta:"property value",score:1e6}})}}).call(g.prototype),r.CssCompletions=g}),ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"],function(e,r,m){var f=e("../../lib/oop");e("../behaviour").Behaviour;var g=e("./cstyle").CstyleBehaviour,w=e("../../token_iterator").TokenIterator,u=function(){this.inherit(g),this.add("colon","insertion",function(d,a,l,c,h){if(h===":"&&l.selection.isEmpty()){var o=l.getCursorPosition(),s=new w(c,o.row,o.column),p=s.getCurrentToken();if(p&&p.value.match(/\s+/)&&(p=s.stepBackward()),p&&p.type==="support.type"){var b=c.doc.getLine(o.row),x=b.substring(o.column,o.column+1);if(x===":")return{text:"",selection:[1,1]};if(/^(\s+[^;]|\s*$)/.test(b.substring(o.column)))return{text:":;",selection:[1,1]}}}}),this.add("colon","deletion",function(d,a,l,c,h){var o=c.doc.getTextRange(h);if(!h.isMultiLine()&&o===":"){var s=l.getCursorPosition(),p=new w(c,s.row,s.column),b=p.getCurrentToken();if(b&&b.value.match(/\s+/)&&(b=p.stepBackward()),b&&b.type==="support.type"){var x=c.doc.getLine(h.start.row),M=x.substring(h.end.column,h.end.column+1);if(M===";")return h.end.column++,h}}}),this.add("semicolon","insertion",function(d,a,l,c,h){if(h===";"&&l.selection.isEmpty()){var o=l.getCursorPosition(),s=c.doc.getLine(o.row),p=s.substring(o.column,o.column+1);if(p===";")return{text:"",selection:[1,1]}}}),this.add("!important","insertion",function(d,a,l,c,h){if(h==="!"&&l.selection.isEmpty()){var o=l.getCursorPosition(),s=c.doc.getLine(o.row);if(/^\s*(;|}|$)/.test(s.substring(o.column)))return{text:"!important",selection:[10,10]}}})};f.inherits(u,g),r.CssBehaviour=u}),ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"],function(e,r,m){var f=e("../lib/oop"),g=e("./text").Mode,w=e("./css_highlight_rules").CssHighlightRules,u=e("./matching_brace_outdent").MatchingBraceOutdent,d=e("../worker/worker_client").WorkerClient,a=e("./css_completions").CssCompletions,l=e("./behaviour/css").CssBehaviour,c=e("./folding/cstyle").FoldMode,h=function(){this.HighlightRules=w,this.$outdent=new u,this.$behaviour=new l,this.$completer=new a,this.foldingRules=new c};f.inherits(h,g),(function(){this.foldingRules="cStyle",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(o,s,p){var b=this.$getIndent(s),x=this.getTokenizer().getLineTokens(s,o).tokens;if(x.length&&x[x.length-1].type=="comment")return b;var M=s.match(/^.*\{\s*$/);return M&&(b+=p),b},this.checkOutdent=function(o,s,p){return this.$outdent.checkOutdent(s,p)},this.autoOutdent=function(o,s,p){this.$outdent.autoOutdent(s,p)},this.getCompletions=function(o,s,p,b){return this.$completer.getCompletions(o,s,p,b)},this.createWorker=function(o){var s=new d(["ace"],"ace/mode/css_worker","Worker");return s.attachToDocument(o.getDocument()),s.on("annotate",function(p){o.setAnnotations(p.data)}),s.on("terminate",function(){o.clearAnnotations()}),s},this.$id="ace/mode/css",this.snippetFileId="ace/snippets/css"}).call(h.prototype),r.Mode=h}),ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"],function(e,r,m){var f=e("../../lib/oop"),g=e("./fold_mode").FoldMode,w=r.FoldMode=function(u,d){this.defaultMode=u,this.subModes=d};f.inherits(w,g),(function(){this.$getMode=function(u){typeof u!="string"&&(u=u[0]);for(var d in this.subModes)if(u.indexOf(d)===0)return this.subModes[d];return null},this.$tryMode=function(u,d,a,l){var c=this.$getMode(u);return c?c.getFoldWidget(d,a,l):""},this.getFoldWidget=function(u,d,a){return this.$tryMode(u.getState(a-1),u,d,a)||this.$tryMode(u.getState(a),u,d,a)||this.defaultMode.getFoldWidget(u,d,a)},this.getFoldWidgetRange=function(u,d,a){var l=this.$getMode(u.getState(a-1));return(!l||!l.getFoldWidget(u,d,a))&&(l=this.$getMode(u.getState(a))),(!l||!l.getFoldWidget(u,d,a))&&(l=this.defaultMode),l.getFoldWidgetRange(u,d,a)}}).call(w.prototype)}),ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"],function(e,r,m){var f=e("../../lib/oop"),g=e("./mixed").FoldMode,w=e("./xml").FoldMode,u=e("./cstyle").FoldMode,d=r.FoldMode=function(a,l){g.call(this,new w(a,l),{"js-":new u,"css-":new u})};f.inherits(d,g)}),ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"],function(e,r,m){function f(s,p){return s.type.lastIndexOf(p+".xml")>-1}function g(s,p){for(var b=new u(s,p.row,p.column),x=b.getCurrentToken();x&&!f(x,"tag-name");)x=b.stepBackward();if(x)return x.value}function w(s,p){for(var b=new u(s,p.row,p.column),x=b.getCurrentToken();x&&!f(x,"attribute-name");)x=b.stepBackward();if(x)return x.value}var u=e("../token_iterator").TokenIterator,d=["accesskey","class","contenteditable","contextmenu","dir","draggable","dropzone","hidden","id","inert","itemid","itemprop","itemref","itemscope","itemtype","lang","spellcheck","style","tabindex","title","translate"],a=["onabort","onblur","oncancel","oncanplay","oncanplaythrough","onchange","onclick","onclose","oncontextmenu","oncuechange","ondblclick","ondrag","ondragend","ondragenter","ondragleave","ondragover","ondragstart","ondrop","ondurationchange","onemptied","onended","onerror","onfocus","oninput","oninvalid","onkeydown","onkeypress","onkeyup","onload","onloadeddata","onloadedmetadata","onloadstart","onmousedown","onmousemove","onmouseout","onmouseover","onmouseup","onmousewheel","onpause","onplay","onplaying","onprogress","onratechange","onreset","onscroll","onseeked","onseeking","onselect","onshow","onstalled","onsubmit","onsuspend","ontimeupdate","onvolumechange","onwaiting"],l=d.concat(a),c={a:{href:1,target:{_blank:1,top:1},ping:1,rel:{nofollow:1,alternate:1,author:1,bookmark:1,help:1,license:1,next:1,noreferrer:1,prefetch:1,prev:1,search:1,tag:1},media:1,hreflang:1,type:1},abbr:{},address:{},area:{shape:1,coords:1,href:1,hreflang:1,alt:1,target:1,media:1,rel:1,ping:1,type:1},article:{pubdate:1},aside:{},audio:{src:1,autobuffer:1,autoplay:{autoplay:1},loop:{loop:1},controls:{controls:1},muted:{muted:1},preload:{auto:1,metadata:1,none:1}},b:{},base:{href:1,target:1},bdi:{},bdo:{},blockquote:{cite:1},body:{onafterprint:1,onbeforeprint:1,onbeforeunload:1,onhashchange:1,onmessage:1,onoffline:1,onpopstate:1,onredo:1,onresize:1,onstorage:1,onundo:1,onunload:1},br:{},button:{autofocus:1,disabled:{disabled:1},form:1,formaction:1,formenctype:1,formmethod:1,formnovalidate:1,formtarget:1,name:1,value:1,type:{button:1,submit:1}},canvas:{width:1,height:1},caption:{},cite:{},code:{},col:{span:1},colgroup:{span:1},command:{type:1,label:1,icon:1,disabled:1,checked:1,radiogroup:1,command:1},data:{},datalist:{},dd:{},del:{cite:1,datetime:1},details:{open:1},dfn:{},dialog:{open:1},div:{},dl:{},dt:{},em:{},embed:{src:1,height:1,width:1,type:1},fieldset:{disabled:1,form:1,name:1},figcaption:{},figure:{},footer:{},form:{"accept-charset":1,action:1,autocomplete:1,enctype:{"multipart/form-data":1,"application/x-www-form-urlencoded":1},method:{get:1,post:1},name:1,novalidate:1,target:{_blank:1,top:1}},h1:{},h2:{},h3:{},h4:{},h5:{},h6:{},head:{},header:{},hr:{},html:{manifest:1},i:{},iframe:{name:1,src:1,height:1,width:1,sandbox:{"allow-same-origin":1,"allow-top-navigation":1,"allow-forms":1,"allow-scripts":1},seamless:{seamless:1}},img:{alt:1,src:1,height:1,width:1,usemap:1,ismap:1},input:{type:{text:1,password:1,hidden:1,checkbox:1,submit:1,radio:1,file:1,button:1,reset:1,image:31,color:1,date:1,datetime:1,"datetime-local":1,email:1,month:1,number:1,range:1,search:1,tel:1,time:1,url:1,week:1},accept:1,alt:1,autocomplete:{on:1,off:1},autofocus:{autofocus:1},checked:{checked:1},disabled:{disabled:1},form:1,formaction:1,formenctype:{"application/x-www-form-urlencoded":1,"multipart/form-data":1,"text/plain":1},formmethod:{get:1,post:1},formnovalidate:{formnovalidate:1},formtarget:{_blank:1,_self:1,_parent:1,_top:1},height:1,list:1,max:1,maxlength:1,min:1,multiple:{multiple:1},name:1,pattern:1,placeholder:1,readonly:{readonly:1},required:{required:1},size:1,src:1,step:1,width:1,files:1,value:1},ins:{cite:1,datetime:1},kbd:{},keygen:{autofocus:1,challenge:{challenge:1},disabled:{disabled:1},form:1,keytype:{rsa:1,dsa:1,ec:1},name:1},label:{form:1,for:1},legend:{},li:{value:1},link:{href:1,hreflang:1,rel:{stylesheet:1,icon:1},media:{all:1,screen:1,print:1},type:{"text/css":1,"image/png":1,"image/jpeg":1,"image/gif":1},sizes:1},main:{},map:{name:1},mark:{},math:{},menu:{type:1,label:1},meta:{"http-equiv":{"content-type":1},name:{description:1,keywords:1},content:{"text/html; charset=UTF-8":1},charset:1},meter:{value:1,min:1,max:1,low:1,high:1,optimum:1},nav:{},noscript:{href:1},object:{param:1,data:1,type:1,height:1,width:1,usemap:1,name:1,form:1,classid:1},ol:{start:1,reversed:1},optgroup:{disabled:1,label:1},option:{disabled:1,selected:1,label:1,value:1},output:{for:1,form:1,name:1},p:{},param:{name:1,value:1},pre:{},progress:{value:1,max:1},q:{cite:1},rp:{},rt:{},ruby:{},s:{},samp:{},script:{charset:1,type:{"text/javascript":1},src:1,defer:1,async:1},select:{autofocus:1,disabled:1,form:1,multiple:{multiple:1},name:1,size:1,readonly:{readonly:1}},small:{},source:{src:1,type:1,media:1},span:{},strong:{},style:{type:1,media:{all:1,screen:1,print:1},scoped:1},sub:{},sup:{},svg:{},table:{summary:1},tbody:{},td:{headers:1,rowspan:1,colspan:1},textarea:{autofocus:{autofocus:1},disabled:{disabled:1},form:1,maxlength:1,name:1,placeholder:1,readonly:{readonly:1},required:{required:1},rows:1,cols:1,wrap:{on:1,off:1,hard:1,soft:1}},tfoot:{},th:{headers:1,rowspan:1,colspan:1,scope:1},thead:{},time:{datetime:1},title:{},tr:{},track:{kind:1,src:1,srclang:1,label:1,default:1},section:{},summary:{},u:{},ul:{},var:{},video:{src:1,autobuffer:1,autoplay:{autoplay:1},loop:{loop:1},controls:{controls:1},width:1,height:1,poster:1,muted:{muted:1},preload:{auto:1,metadata:1,none:1}},wbr:{}},h=Object.keys(c),o=function(){};(function(){this.getCompletions=function(s,p,b,x){var M=p.getTokenAt(b.row,b.column);if(!M)return[];if(f(M,"tag-name")||f(M,"tag-open")||f(M,"end-tag-open"))return this.getTagCompletions(s,p,b,x);if(f(M,"tag-whitespace")||f(M,"attribute-name"))return this.getAttributeCompletions(s,p,b,x);if(f(M,"attribute-value"))return this.getAttributeValueCompletions(s,p,b,x);var R=p.getLine(b.row).substr(0,b.column);return/&[a-z]*$/i.test(R)?this.getHTMLEntityCompletions(s,p,b,x):[]},this.getTagCompletions=function(s,p,b,x){return h.map(function(M){return{value:M,meta:"tag",score:1e6}})},this.getAttributeCompletions=function(s,p,b,x){var M=g(p,b);if(!M)return[];var R=l;return M in c&&(R=R.concat(Object.keys(c[M]))),R.map(function(k){return{caption:k,snippet:k+'="$0"',meta:"attribute",score:1e6}})},this.getAttributeValueCompletions=function(s,p,b,x){var M=g(p,b),R=w(p,b);if(!M)return[];var k=[];return M in c&&R in c[M]&&typeof c[M][R]=="object"&&(k=Object.keys(c[M][R])),k.map(function(C){return{caption:C,snippet:C,meta:"attribute value",score:1e6}})},this.getHTMLEntityCompletions=function(s,p,b,x){var M=["Aacute;","aacute;","Acirc;","acirc;","acute;","AElig;","aelig;","Agrave;","agrave;","alefsym;","Alpha;","alpha;","amp;","and;","ang;","Aring;","aring;","asymp;","Atilde;","atilde;","Auml;","auml;","bdquo;","Beta;","beta;","brvbar;","bull;","cap;","Ccedil;","ccedil;","cedil;","cent;","Chi;","chi;","circ;","clubs;","cong;","copy;","crarr;","cup;","curren;","Dagger;","dagger;","dArr;","darr;","deg;","Delta;","delta;","diams;","divide;","Eacute;","eacute;","Ecirc;","ecirc;","Egrave;","egrave;","empty;","emsp;","ensp;","Epsilon;","epsilon;","equiv;","Eta;","eta;","ETH;","eth;","Euml;","euml;","euro;","exist;","fnof;","forall;","frac12;","frac14;","frac34;","frasl;","Gamma;","gamma;","ge;","gt;","hArr;","harr;","hearts;","hellip;","Iacute;","iacute;","Icirc;","icirc;","iexcl;","Igrave;","igrave;","image;","infin;","int;","Iota;","iota;","iquest;","isin;","Iuml;","iuml;","Kappa;","kappa;","Lambda;","lambda;","lang;","laquo;","lArr;","larr;","lceil;","ldquo;","le;","lfloor;","lowast;","loz;","lrm;","lsaquo;","lsquo;","lt;","macr;","mdash;","micro;","middot;","minus;","Mu;","mu;","nabla;","nbsp;","ndash;","ne;","ni;","not;","notin;","nsub;","Ntilde;","ntilde;","Nu;","nu;","Oacute;","oacute;","Ocirc;","ocirc;","OElig;","oelig;","Ograve;","ograve;","oline;","Omega;","omega;","Omicron;","omicron;","oplus;","or;","ordf;","ordm;","Oslash;","oslash;","Otilde;","otilde;","otimes;","Ouml;","ouml;","para;","part;","permil;","perp;","Phi;","phi;","Pi;","pi;","piv;","plusmn;","pound;","Prime;","prime;","prod;","prop;","Psi;","psi;","quot;","radic;","rang;","raquo;","rArr;","rarr;","rceil;","rdquo;","real;","reg;","rfloor;","Rho;","rho;","rlm;","rsaquo;","rsquo;","sbquo;","Scaron;","scaron;","sdot;","sect;","shy;","Sigma;","sigma;","sigmaf;","sim;","spades;","sub;","sube;","sum;","sup;","sup1;","sup2;","sup3;","supe;","szlig;","Tau;","tau;","there4;","Theta;","theta;","thetasym;","thinsp;","THORN;","thorn;","tilde;","times;","trade;","Uacute;","uacute;","uArr;","uarr;","Ucirc;","ucirc;","Ugrave;","ugrave;","uml;","upsih;","Upsilon;","upsilon;","Uuml;","uuml;","weierp;","Xi;","xi;","Yacute;","yacute;","yen;","Yuml;","yuml;","Zeta;","zeta;","zwj;","zwnj;"];return M.map(function(R){return{caption:R,snippet:R,meta:"html entity",score:1e6}})}}).call(o.prototype),r.HtmlCompletions=o}),ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"],function(e,r,m){var f=e("../lib/oop"),g=e("../lib/lang"),w=e("./text").Mode,u=e("./javascript").Mode,d=e("./css").Mode,a=e("./html_highlight_rules").HtmlHighlightRules,l=e("./behaviour/xml").XmlBehaviour,c=e("./folding/html").FoldMode,h=e("./html_completions").HtmlCompletions,o=e("../worker/worker_client").WorkerClient,s=["area","base","br","col","embed","hr","img","input","keygen","link","meta","menuitem","param","source","track","wbr"],p=["li","dt","dd","p","rt","rp","optgroup","option","colgroup","td","th"],b=function(x){this.fragmentContext=x&&x.fragmentContext,this.HighlightRules=a,this.$behaviour=new l,this.$completer=new h,this.createModeDelegates({"js-":u,"css-":d}),this.foldingRules=new c(this.voidElements,g.arrayToMap(p))};f.inherits(b,w),(function(){this.blockComment={start:"<!--",end:"-->"},this.voidElements=g.arrayToMap(s),this.getNextLineIndent=function(x,M,R){return this.$getIndent(M)},this.checkOutdent=function(x,M,R){return!1},this.getCompletions=function(x,M,R,k){return this.$completer.getCompletions(x,M,R,k)},this.createWorker=function(x){if(this.constructor==b){var M=new o(["ace"],"ace/mode/html_worker","Worker");return M.attachToDocument(x.getDocument()),this.fragmentContext&&M.call("setOptions",[{context:this.fragmentContext}]),M.on("error",function(R){x.setAnnotations(R.data)}),M.on("terminate",function(){x.clearAnnotations()}),M}},this.$id="ace/mode/html",this.snippetFileId="ace/snippets/html"}).call(b.prototype),r.Mode=b}),ace.define("ace/mode/sh_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(e,r,m){var f=e("../lib/oop"),g=e("./text_highlight_rules").TextHighlightRules,w=r.reservedKeywords="!|{|}|case|do|done|elif|else|esac|fi|for|if|in|then|until|while|&|;|export|local|read|typeset|unset|elif|select|set|function|declare|readonly",u=r.languageConstructs="[|]|alias|bg|bind|break|builtin|cd|command|compgen|complete|continue|dirs|disown|echo|enable|eval|exec|exit|fc|fg|getopts|hash|help|history|jobs|kill|let|logout|popd|printf|pushd|pwd|return|set|shift|shopt|source|suspend|test|times|trap|type|ulimit|umask|unalias|wait",d=function(){var a=this.createKeywordMapper({keyword:w,"support.function.builtin":u,"invalid.deprecated":"debugger"},"identifier"),l="(?:(?:[1-9]\\d*)|(?:0))",c="(?:\\.\\d+)",h="(?:\\d+)",o="(?:(?:"+h+"?"+c+")|(?:"+h+"\\.))",s="(?:(?:"+o+"|"+h+"))",p="(?:"+s+"|"+o+")",b="(?:&"+h+")",x="[a-zA-Z_][a-zA-Z0-9_]*",M="(?:"+x+"(?==))",R="(?:\\$(?:SHLVL|\\$|\\!|\\?))",k="(?:"+x+"\\s*\\(\\))";this.$rules={start:[{token:"constant",regex:/\\./},{token:["text","comment"],regex:/(^|\s)(#.*)$/},{token:"string.start",regex:'"',push:[{token:"constant.language.escape",regex:/\\(?:[$`"\\]|$)/},{include:"variables"},{token:"keyword.operator",regex:/`/},{token:"string.end",regex:'"',next:"pop"},{defaultToken:"string"}]},{token:"string",regex:"\\$'",push:[{token:"constant.language.escape",regex:/\\(?:[abeEfnrtv\\'"]|x[a-fA-F\d]{1,2}|u[a-fA-F\d]{4}([a-fA-F\d]{4})?|c.|\d{1,3})/},{token:"string",regex:"'",next:"pop"},{defaultToken:"string"}]},{regex:"<<<",token:"keyword.operator"},{stateName:"heredoc",regex:"(<<-?)(\\s*)(['\"`]?)([\\w\\-]+)(['\"`]?)",onMatch:function(C,L,D){var I=C[2]=="-"?"indentedHeredoc":"heredoc",T=C.split(this.splitRegex);return D.push(I,T[4]),[{type:"constant",value:T[1]},{type:"text",value:T[2]},{type:"string",value:T[3]},{type:"support.class",value:T[4]},{type:"string",value:T[5]}]},rules:{heredoc:[{onMatch:function(C,L,D){return C===D[1]?(D.shift(),D.shift(),this.next=D[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}],indentedHeredoc:[{token:"string",regex:"^ +"},{onMatch:function(C,L,D){return C===D[1]?(D.shift(),D.shift(),this.next=D[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}]}},{regex:"$",token:"empty",next:function(C,L){return L[0]==="heredoc"||L[0]==="indentedHeredoc"?L[0]:C}},{token:["keyword","text","text","text","variable"],regex:/(declare|local|readonly)(\s+)(?:(-[fixar]+)(\s+))?([a-zA-Z_][a-zA-Z0-9_]*\b)/},{token:"variable.language",regex:R},{token:"variable",regex:M},{include:"variables"},{token:"support.function",regex:k},{token:"support.function",regex:b},{token:"string",start:"'",end:"'"},{token:"constant.numeric",regex:p},{token:"constant.numeric",regex:l+"\\b"},{token:a,regex:"[a-zA-Z_][a-zA-Z0-9_]*\\b"},{token:"keyword.operator",regex:"\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|~|<|>|<=|=>|=|!=|[%&|`]"},{token:"punctuation.operator",regex:";"},{token:"paren.lparen",regex:"[\\[\\(\\{]"},{token:"paren.rparen",regex:"[\\]]"},{token:"paren.rparen",regex:"[\\)\\}]",next:"pop"}],variables:[{token:"variable",regex:/(\$)(\w+)/},{token:["variable","paren.lparen"],regex:/(\$)(\()/,push:"start"},{token:["variable","paren.lparen","keyword.operator","variable","keyword.operator"],regex:/(\$)(\{)([#!]?)(\w+|[*@#?\-$!0_])(:[?+\-=]?|##?|%%?|,,?\/|\^\^?)?/,push:"start"},{token:"variable",regex:/\$[*@#?\-$!0_]/},{token:["variable","paren.lparen"],regex:/(\$)(\{)/,push:"start"}]},this.normalizeRules()};f.inherits(d,g),r.ShHighlightRules=d}),ace.define("ace/mode/sh",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sh_highlight_rules","ace/range","ace/mode/folding/cstyle"],function(e,r,m){var f=e("../lib/oop"),g=e("./text").Mode,w=e("./sh_highlight_rules").ShHighlightRules,u=e("../range").Range,d=e("./folding/cstyle").FoldMode,a=function(){this.HighlightRules=w,this.foldingRules=new d,this.$behaviour=this.$defaultBehaviour};f.inherits(a,g),(function(){this.lineCommentStart="#",this.getNextLineIndent=function(c,h,o){var s=this.$getIndent(h),p=this.getTokenizer().getLineTokens(h,c),b=p.tokens;if(b.length&&b[b.length-1].type=="comment")return s;if(c=="start"){var x=h.match(/^.*[\{\(\[:]\s*$/);x&&(s+=o)}return s};var l={pass:1,return:1,raise:1,break:1,continue:1};this.checkOutdent=function(c,h,o){if(o!==`\r
995
+ `&&o!=="\r"&&o!==`
996
+ `)return!1;var s=this.getTokenizer().getLineTokens(h.trim(),c).tokens;if(!s)return!1;do var p=s.pop();while(p&&(p.type=="comment"||p.type=="text"&&p.value.match(/^\s+$/)));return p?p.type=="keyword"&&l[p.value]:!1},this.autoOutdent=function(c,h,o){o+=1;var s=this.$getIndent(h.getLine(o)),p=h.getTabString();s.slice(-p.length)==p&&h.remove(new u(o,s.length-p.length,o,s.length))},this.$id="ace/mode/sh",this.snippetFileId="ace/snippets/sh"}).call(a.prototype),r.Mode=a}),ace.define("ace/mode/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/xml_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/xml","ace/worker/worker_client"],function(e,r,m){var f=e("../lib/oop"),g=e("../lib/lang"),w=e("./text").Mode,u=e("./xml_highlight_rules").XmlHighlightRules,d=e("./behaviour/xml").XmlBehaviour,a=e("./folding/xml").FoldMode,l=e("../worker/worker_client").WorkerClient,c=function(){this.HighlightRules=u,this.$behaviour=new d,this.foldingRules=new a};f.inherits(c,w),(function(){this.voidElements=g.arrayToMap([]),this.blockComment={start:"<!--",end:"-->"},this.createWorker=function(h){var o=new l(["ace"],"ace/mode/xml_worker","Worker");return o.attachToDocument(h.getDocument()),o.on("error",function(s){h.setAnnotations(s.data)}),o.on("terminate",function(){h.clearAnnotations()}),o},this.$id="ace/mode/xml"}).call(c.prototype),r.Mode=c}),ace.define("ace/mode/markdown",["require","exports","module","ace/lib/oop","ace/mode/behaviour/cstyle","ace/mode/text","ace/mode/markdown_highlight_rules","ace/mode/folding/markdown","ace/mode/javascript","ace/mode/html","ace/mode/sh","ace/mode/sh","ace/mode/xml","ace/mode/css"],function(e,r,m){var f=e("../lib/oop"),g=e("./behaviour/cstyle").CstyleBehaviour,w=e("./text").Mode,u=e("./markdown_highlight_rules").MarkdownHighlightRules,d=e("./folding/markdown").FoldMode,a=function(){this.HighlightRules=u,this.createModeDelegates({javascript:e("./javascript").Mode,html:e("./html").Mode,bash:e("./sh").Mode,sh:e("./sh").Mode,xml:e("./xml").Mode,css:e("./css").Mode}),this.foldingRules=new d,this.$behaviour=new g({braces:!0})};f.inherits(a,w),(function(){this.type="text",this.blockComment={start:"<!--",end:"-->"},this.$quotes={'"':'"',"`":"`"},this.getNextLineIndent=function(l,c,h){if(l=="listblock"){var o=/^(\s*)(?:([-+*])|(\d+)\.)(\s+)/.exec(c);if(!o)return"";var s=o[2];return s||(s=parseInt(o[3],10)+1+"."),o[1]+s+o[4]}return this.$getIndent(c)},this.$id="ace/mode/markdown",this.snippetFileId="ace/snippets/markdown"}).call(a.prototype),r.Mode=a}),(function(){ace.require(["ace/mode/markdown"],function(e){t&&(t.exports=e)})})()})(pg)),pg.exports}kA();var mg={exports:{}},vg;function SA(){return vg||(vg=1,(function(t,n){ace.define("ace/theme/twilight-css",["require","exports","module"],function(e,r,m){m.exports=`.ace-twilight .ace_gutter {
997
+ background: #232323;
998
+ color: #E2E2E2
999
+ }
1000
+
1001
+ .ace-twilight .ace_print-margin {
1002
+ width: 1px;
1003
+ background: #232323
1004
+ }
1005
+
1006
+ .ace-twilight {
1007
+ background-color: #141414;
1008
+ color: #F8F8F8
1009
+ }
1010
+
1011
+ .ace-twilight .ace_cursor {
1012
+ color: #A7A7A7
1013
+ }
1014
+
1015
+ .ace-twilight .ace_marker-layer .ace_selection {
1016
+ background: rgba(221, 240, 255, 0.20)
1017
+ }
1018
+
1019
+ .ace-twilight.ace_multiselect .ace_selection.ace_start {
1020
+ box-shadow: 0 0 3px 0px #141414;
1021
+ }
1022
+
1023
+ .ace-twilight .ace_marker-layer .ace_step {
1024
+ background: rgb(102, 82, 0)
1025
+ }
1026
+
1027
+ .ace-twilight .ace_marker-layer .ace_bracket {
1028
+ margin: -1px 0 0 -1px;
1029
+ border: 1px solid rgba(255, 255, 255, 0.25)
1030
+ }
1031
+
1032
+ .ace-twilight .ace_marker-layer .ace_active-line {
1033
+ background: rgba(255, 255, 255, 0.031)
1034
+ }
1035
+
1036
+ .ace-twilight .ace_gutter-active-line {
1037
+ background-color: rgba(255, 255, 255, 0.031)
1038
+ }
1039
+
1040
+ .ace-twilight .ace_marker-layer .ace_selected-word {
1041
+ border: 1px solid rgba(221, 240, 255, 0.20)
1042
+ }
1043
+
1044
+ .ace-twilight .ace_invisible {
1045
+ color: rgba(255, 255, 255, 0.25)
1046
+ }
1047
+
1048
+ .ace-twilight .ace_keyword,
1049
+ .ace-twilight .ace_meta {
1050
+ color: #CDA869
1051
+ }
1052
+
1053
+ .ace-twilight .ace_constant,
1054
+ .ace-twilight .ace_constant.ace_character,
1055
+ .ace-twilight .ace_constant.ace_character.ace_escape,
1056
+ .ace-twilight .ace_constant.ace_other,
1057
+ .ace-twilight .ace_heading,
1058
+ .ace-twilight .ace_markup.ace_heading,
1059
+ .ace-twilight .ace_support.ace_constant {
1060
+ color: #CF6A4C
1061
+ }
1062
+
1063
+ .ace-twilight .ace_invalid.ace_illegal {
1064
+ color: #F8F8F8;
1065
+ background-color: rgba(86, 45, 86, 0.75)
1066
+ }
1067
+
1068
+ .ace-twilight .ace_invalid.ace_deprecated {
1069
+ text-decoration: underline;
1070
+ font-style: italic;
1071
+ color: #D2A8A1
1072
+ }
1073
+
1074
+ .ace-twilight .ace_support {
1075
+ color: #9B859D
1076
+ }
1077
+
1078
+ .ace-twilight .ace_fold {
1079
+ background-color: #AC885B;
1080
+ border-color: #F8F8F8
1081
+ }
1082
+
1083
+ .ace-twilight .ace_support.ace_function {
1084
+ color: #DAD085
1085
+ }
1086
+
1087
+ .ace-twilight .ace_list,
1088
+ .ace-twilight .ace_markup.ace_list,
1089
+ .ace-twilight .ace_storage {
1090
+ color: #F9EE98
1091
+ }
1092
+
1093
+ .ace-twilight .ace_entity.ace_name.ace_function,
1094
+ .ace-twilight .ace_meta.ace_tag {
1095
+ color: #AC885B
1096
+ }
1097
+
1098
+ .ace-twilight .ace_string {
1099
+ color: #8F9D6A
1100
+ }
1101
+
1102
+ .ace-twilight .ace_string.ace_regexp {
1103
+ color: #E9C062
1104
+ }
1105
+
1106
+ .ace-twilight .ace_comment {
1107
+ font-style: italic;
1108
+ color: #5F5A60
1109
+ }
1110
+
1111
+ .ace-twilight .ace_variable {
1112
+ color: #7587A6
1113
+ }
1114
+
1115
+ .ace-twilight .ace_xml-pe {
1116
+ color: #494949
1117
+ }
1118
+
1119
+ .ace-twilight .ace_indent-guide {
1120
+ background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWMQERFpYLC1tf0PAAgOAnPnhxyiAAAAAElFTkSuQmCC) right repeat-y
1121
+ }
1122
+
1123
+ .ace-twilight .ace_indent-guide-active {
1124
+ background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQIW2PQ1dX9zzBz5sz/ABCcBFFentLlAAAAAElFTkSuQmCC) right repeat-y;
1125
+ }
1126
+ `}),ace.define("ace/theme/twilight",["require","exports","module","ace/theme/twilight-css","ace/lib/dom"],function(e,r,m){r.isDark=!0,r.cssClass="ace-twilight",r.cssText=e("./twilight-css");var f=e("../lib/dom");f.importCssString(r.cssText,r.cssClass,!1)}),(function(){ace.require(["ace/theme/twilight"],function(e){t&&(t.exports=e)})})()})(mg)),mg.exports}SA();var yg={exports:{}},bg;function $A(){return bg||(bg=1,(function(t,n){ace.define("ace/snippets",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/range_list","ace/keyboard/hash_handler","ace/tokenizer","ace/clipboard","ace/editor"],function(e,r,m){function f(C){var L=new Date().toLocaleString("en-us",C);return L.length==1?"0"+L:L}var g=e("./lib/dom"),w=e("./lib/oop"),u=e("./lib/event_emitter").EventEmitter,d=e("./lib/lang"),a=e("./range").Range,l=e("./range_list").RangeList,c=e("./keyboard/hash_handler").HashHandler,h=e("./tokenizer").Tokenizer,o=e("./clipboard"),s={CURRENT_WORD:function(C){return C.session.getTextRange(C.session.getWordRange())},SELECTION:function(C,L,D){var I=C.session.getTextRange();return D?I.replace(/\n\r?([ \t]*\S)/g,`
1127
+ `+D+"$1"):I},CURRENT_LINE:function(C){return C.session.getLine(C.getCursorPosition().row)},PREV_LINE:function(C){return C.session.getLine(C.getCursorPosition().row-1)},LINE_INDEX:function(C){return C.getCursorPosition().row},LINE_NUMBER:function(C){return C.getCursorPosition().row+1},SOFT_TABS:function(C){return C.session.getUseSoftTabs()?"YES":"NO"},TAB_SIZE:function(C){return C.session.getTabSize()},CLIPBOARD:function(C){return o.getText&&o.getText()},FILENAME:function(C){return/[^/\\]*$/.exec(this.FILEPATH(C))[0]},FILENAME_BASE:function(C){return/[^/\\]*$/.exec(this.FILEPATH(C))[0].replace(/\.[^.]*$/,"")},DIRECTORY:function(C){return this.FILEPATH(C).replace(/[^/\\]*$/,"")},FILEPATH:function(C){return"/not implemented.txt"},WORKSPACE_NAME:function(){return"Unknown"},FULLNAME:function(){return"Unknown"},BLOCK_COMMENT_START:function(C){var L=C.session.$mode||{};return L.blockComment&&L.blockComment.start||""},BLOCK_COMMENT_END:function(C){var L=C.session.$mode||{};return L.blockComment&&L.blockComment.end||""},LINE_COMMENT:function(C){var L=C.session.$mode||{};return L.lineCommentStart||""},CURRENT_YEAR:f.bind(null,{year:"numeric"}),CURRENT_YEAR_SHORT:f.bind(null,{year:"2-digit"}),CURRENT_MONTH:f.bind(null,{month:"numeric"}),CURRENT_MONTH_NAME:f.bind(null,{month:"long"}),CURRENT_MONTH_NAME_SHORT:f.bind(null,{month:"short"}),CURRENT_DATE:f.bind(null,{day:"2-digit"}),CURRENT_DAY_NAME:f.bind(null,{weekday:"long"}),CURRENT_DAY_NAME_SHORT:f.bind(null,{weekday:"short"}),CURRENT_HOUR:f.bind(null,{hour:"2-digit",hour12:!1}),CURRENT_MINUTE:f.bind(null,{minute:"2-digit"}),CURRENT_SECOND:f.bind(null,{second:"2-digit"})};s.SELECTED_TEXT=s.SELECTION;var p=(function(){function C(){this.snippetMap={},this.snippetNameMap={},this.variables=s}return C.prototype.getTokenizer=function(){return C.$tokenizer||this.createTokenizer()},C.prototype.createTokenizer=function(){function L(T){return T=T.substr(1),/^\d+$/.test(T)?[{tabstopId:parseInt(T,10)}]:[{text:T}]}function D(T){return"(?:[^\\\\"+T+"]|\\\\.)"}var I={regex:"/("+D("/")+"+)/",onMatch:function(T,W,F){var O=F[0];return O.fmtString=!0,O.guard=T.slice(1,-1),O.flag="",""},next:"formatString"};return C.$tokenizer=new h({start:[{regex:/\\./,onMatch:function(T,W,F){var O=T[1];return(O=="}"&&F.length||"`$\\".indexOf(O)!=-1)&&(T=O),[T]}},{regex:/}/,onMatch:function(T,W,F){return[F.length?F.shift():T]}},{regex:/\$(?:\d+|\w+)/,onMatch:L},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(T,W,F){var O=L(T.substr(1));return F.unshift(O[0]),O},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+D("\\|")+"*\\|",onMatch:function(T,W,F){var O=T.slice(1,-1).replace(/\\[,|\\]|,/g,function(S){return S.length==2?S[1]:"\0"}).split("\0").map(function(S){return{value:S}});return F[0].choices=O,[O[0]]},next:"start"},I,{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:/:/,onMatch:function(T,W,F){return F.length&&F[0].expectElse?(F[0].expectElse=!1,F[0].ifEnd={elseEnd:F[0]},[F[0].ifEnd]):":"}},{regex:/\\./,onMatch:function(T,W,F){var O=T[1];return O=="}"&&F.length||"`$\\".indexOf(O)!=-1?T=O:O=="n"?T=`
1128
+ `:O=="t"?T=" ":"ulULE".indexOf(O)!=-1&&(T={changeCase:O,local:O>"a"}),[T]}},{regex:"/\\w*}",onMatch:function(T,W,F){var O=F.shift();return O&&(O.flag=T.slice(1,-1)),this.next=O&&O.tabstopId?"start":"",[O||T]},next:"start"},{regex:/\$(?:\d+|\w+)/,onMatch:function(T,W,F){return[{text:T.slice(1)}]}},{regex:/\${\w+/,onMatch:function(T,W,F){var O={text:T.slice(2)};return F.unshift(O),[O]},next:"formatStringVar"},{regex:/\n/,token:"newline",merge:!1},{regex:/}/,onMatch:function(T,W,F){var O=F.shift();return this.next=O&&O.tabstopId?"start":"",[O||T]},next:"start"}],formatStringVar:[{regex:/:\/\w+}/,onMatch:function(T,W,F){var O=F[0];return O.formatFunction=T.slice(2,-1),[F.shift()]},next:"formatString"},I,{regex:/:[\?\-+]?/,onMatch:function(T,W,F){T[1]=="+"&&(F[0].ifEnd=F[0]),T[1]=="?"&&(F[0].expectElse=!0)},next:"formatString"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"formatString"}]}),C.$tokenizer},C.prototype.tokenizeTmSnippet=function(L,D){return this.getTokenizer().getLineTokens(L,D).tokens.map(function(I){return I.value||I})},C.prototype.getVariableValue=function(L,D,I){if(/^\d+$/.test(D))return(this.variables.__||{})[D]||"";if(/^[A-Z]\d+$/.test(D))return(this.variables[D[0]+"__"]||{})[D.substr(1)]||"";if(D=D.replace(/^TM_/,""),!this.variables.hasOwnProperty(D))return"";var T=this.variables[D];return typeof T=="function"&&(T=this.variables[D](L,D,I)),T??""},C.prototype.tmStrFormat=function(L,D,I){if(!D.fmt)return L;var T=D.flag||"",W=D.guard;W=new RegExp(W,T.replace(/[^gim]/g,""));var F=typeof D.fmt=="string"?this.tokenizeTmSnippet(D.fmt,"formatString"):D.fmt,O=this,S=L.replace(W,function(){var A=O.variables.__;O.variables.__=[].slice.call(arguments);for(var N=O.resolveVariables(F,I),B="E",U=0;U<N.length;U++){var G=N[U];if(typeof G=="object")if(N[U]="",G.changeCase&&G.local){var J=N[U+1];J&&typeof J=="string"&&(G.changeCase=="u"?N[U]=J[0].toUpperCase():N[U]=J[0].toLowerCase(),N[U+1]=J.substr(1))}else G.changeCase&&(B=G.changeCase);else B=="U"?N[U]=G.toUpperCase():B=="L"&&(N[U]=G.toLowerCase())}return O.variables.__=A,N.join("")});return S},C.prototype.tmFormatFunction=function(L,D,I){return D.formatFunction=="upcase"?L.toUpperCase():D.formatFunction=="downcase"?L.toLowerCase():L},C.prototype.resolveVariables=function(L,D){function I(B){var U=L.indexOf(B,O+1);U!=-1&&(O=U)}for(var T=[],W="",F=!0,O=0;O<L.length;O++){var S=L[O];if(typeof S=="string"){T.push(S),S==`
1129
+ `?(F=!0,W=""):F&&(W=/^\t*/.exec(S)[0],F=/\S/.test(S));continue}if(S){if(F=!1,S.fmtString){var A=L.indexOf(S,O+1);A==-1&&(A=L.length),S.fmt=L.slice(O+1,A),O=A}if(S.text){var N=this.getVariableValue(D,S.text,W)+"";S.fmtString&&(N=this.tmStrFormat(N,S,D)),S.formatFunction&&(N=this.tmFormatFunction(N,S,D)),N&&!S.ifEnd?(T.push(N),I(S)):!N&&S.ifEnd&&I(S.ifEnd)}else S.elseEnd?I(S.elseEnd):(S.tabstopId!=null||S.changeCase!=null)&&T.push(S)}}return T},C.prototype.getDisplayTextForSnippet=function(L,D){var I=b.call(this,L,D);return I.text},C.prototype.insertSnippetForSelection=function(L,D,I){I===void 0&&(I={});var T=b.call(this,L,D,I),W=L.getSelectionRange(),F=L.session.replace(W,T.text),O=new x(L),S=L.inVirtualSelectionMode&&L.selection.index;O.addTabstops(T.tabstops,W.start,F,S)},C.prototype.insertSnippet=function(L,D,I){I===void 0&&(I={});var T=this;if(L.inVirtualSelectionMode)return T.insertSnippetForSelection(L,D,I);L.forEachSelection(function(){T.insertSnippetForSelection(L,D,I)},null,{keepOrder:!0}),L.tabstopManager&&L.tabstopManager.tabNext()},C.prototype.$getScope=function(L){var D=L.session.$mode.$id||"";if(D=D.split("/").pop(),D==="html"||D==="php"){D==="php"&&!L.session.$mode.inlinePhp&&(D="html");var I=L.getCursorPosition(),T=L.session.getState(I.row);typeof T=="object"&&(T=T[0]),T.substring&&(T.substring(0,3)=="js-"?D="javascript":T.substring(0,4)=="css-"?D="css":T.substring(0,4)=="php-"&&(D="php"))}return D},C.prototype.getActiveScopes=function(L){var D=this.$getScope(L),I=[D],T=this.snippetMap;return T[D]&&T[D].includeScopes&&I.push.apply(I,T[D].includeScopes),I.push("_"),I},C.prototype.expandWithTab=function(L,D){var I=this,T=L.forEachSelection(function(){return I.expandSnippetForSelection(L,D)},null,{keepOrder:!0});return T&&L.tabstopManager&&L.tabstopManager.tabNext(),T},C.prototype.expandSnippetForSelection=function(L,D){var I=L.getCursorPosition(),T=L.session.getLine(I.row),W=T.substring(0,I.column),F=T.substr(I.column),O=this.snippetMap,S;return this.getActiveScopes(L).some(function(A){var N=O[A];return N&&(S=this.findMatchingSnippet(N,W,F)),!!S},this),S?(D&&D.dryRun||(L.session.doc.removeInLine(I.row,I.column-S.replaceBefore.length,I.column+S.replaceAfter.length),this.variables.M__=S.matchBefore,this.variables.T__=S.matchAfter,this.insertSnippetForSelection(L,S.content),this.variables.M__=this.variables.T__=null),!0):!1},C.prototype.findMatchingSnippet=function(L,D,I){for(var T=L.length;T--;){var W=L[T];if(!(W.startRe&&!W.startRe.test(D))&&!(W.endRe&&!W.endRe.test(I))&&!(!W.startRe&&!W.endRe))return W.matchBefore=W.startRe?W.startRe.exec(D):[""],W.matchAfter=W.endRe?W.endRe.exec(I):[""],W.replaceBefore=W.triggerRe?W.triggerRe.exec(D)[0]:"",W.replaceAfter=W.endTriggerRe?W.endTriggerRe.exec(I)[0]:"",W}},C.prototype.register=function(L,D){function I(A){return A&&!/^\^?\(.*\)\$?$|^\\b$/.test(A)&&(A="(?:"+A+")"),A||""}function T(A,N,B){return A=I(A),N=I(N),A=N+A,A&&A[A.length-1]!="$"&&(A+="$"),new RegExp(A)}function W(A){A.scope||(A.scope=D||"_"),D=A.scope,F[D]||(F[D]=[],O[D]={});var N=O[D];if(A.name){var B=N[A.name];B&&S.unregister(B),N[A.name]=A}F[D].push(A),A.prefix&&(A.tabTrigger=A.prefix),!A.content&&A.body&&(A.content=Array.isArray(A.body)?A.body.join(`
1130
+ `):A.body),A.tabTrigger&&!A.trigger&&(!A.guard&&/^\w/.test(A.tabTrigger)&&(A.guard="\\b"),A.trigger=d.escapeRegExp(A.tabTrigger)),!(!A.trigger&&!A.guard&&!A.endTrigger&&!A.endGuard)&&(A.startRe=T(A.trigger,A.guard),A.triggerRe=new RegExp(A.trigger),A.endRe=T(A.endTrigger,A.endGuard),A.endTriggerRe=new RegExp(A.endTrigger))}var F=this.snippetMap,O=this.snippetNameMap,S=this;L||(L=[]),Array.isArray(L)?L.forEach(W):Object.keys(L).forEach(function(A){W(L[A])}),this._signal("registerSnippets",{scope:D})},C.prototype.unregister=function(L,D){function I(F){var O=W[F.scope||D];if(O&&O[F.name]){delete O[F.name];var S=T[F.scope||D],A=S&&S.indexOf(F);A>=0&&S.splice(A,1)}}var T=this.snippetMap,W=this.snippetNameMap;L.content?I(L):Array.isArray(L)&&L.forEach(I)},C.prototype.parseSnippetFile=function(L){L=L.replace(/\r/g,"");for(var D=[],I={},T=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm,W;W=T.exec(L);){if(W[1])try{I=JSON.parse(W[1]),D.push(I)}catch{}if(W[4])I.content=W[4].replace(/^\t/gm,""),D.push(I),I={};else{var F=W[2],O=W[3];if(F=="regex"){var S=/\/((?:[^\/\\]|\\.)*)|$/g;I.guard=S.exec(O)[1],I.trigger=S.exec(O)[1],I.endTrigger=S.exec(O)[1],I.endGuard=S.exec(O)[1]}else F=="snippet"?(I.tabTrigger=O.match(/^\S*/)[0],I.name||(I.name=O)):F&&(I[F]=O)}}return D},C.prototype.getSnippetByName=function(L,D){var I=this.snippetNameMap,T;return this.getActiveScopes(D).some(function(W){var F=I[W];return F&&(T=F[L]),!!T},this),T},C})();w.implement(p.prototype,u);var b=function(C,L,D){function I(le){for(var pe=[],me=0;me<le.length;me++){var $e=le[me];if(typeof $e=="object"){if(N[$e.tabstopId])continue;var Ee=le.lastIndexOf($e,me-1);$e=pe[Ee]||{tabstopId:$e.tabstopId}}pe[me]=$e}return pe}D===void 0&&(D={});var T=C.getCursorPosition(),W=C.session.getLine(T.row),F=C.session.getTabString(),O=W.match(/^\s*/)[0];T.column<O.length&&(O=O.slice(0,T.column)),L=L.replace(/\r/g,"");var S=this.tokenizeTmSnippet(L);S=this.resolveVariables(S,C),S=S.map(function(le){return le==`
1131
+ `&&!D.excludeExtraIndent?le+O:typeof le=="string"?le.replace(/\t/g,F):le});var A=[];S.forEach(function(le,pe){if(typeof le=="object"){var me=le.tabstopId,$e=A[me];if($e||($e=A[me]=[],$e.index=me,$e.value="",$e.parents={}),$e.indexOf(le)===-1){le.choices&&!$e.choices&&($e.choices=le.choices),$e.push(le);var Ee=S.indexOf(le,pe+1);if(Ee!==-1){var He=S.slice(pe+1,Ee),Ue=He.some(function(ot){return typeof ot=="object"});Ue&&!$e.value?$e.value=He:He.length&&(!$e.value||typeof $e.value!="string")&&($e.value=He.join(""))}}}}),A.forEach(function(le){le.length=0});for(var N={},B=0;B<S.length;B++){var U=S[B];if(typeof U=="object"){var G=U.tabstopId,J=A[G],ne=S.indexOf(U,B+1);if(N[G]){N[G]===U&&(delete N[G],Object.keys(N).forEach(function(le){J.parents[le]=!0}));continue}N[G]=U;var de=J.value;typeof de!="string"?de=I(de):U.fmt&&(de=this.tmStrFormat(de,U,C)),S.splice.apply(S,[B+1,Math.max(0,ne-B)].concat(de,U)),J.indexOf(U)===-1&&J.push(U)}}var ee=0,se=0,ce="";return S.forEach(function(le){if(typeof le=="string"){var pe=le.split(`
1132
+ `);pe.length>1?(se=pe[pe.length-1].length,ee+=pe.length-1):se+=le.length,ce+=le}else le&&(le.start?le.end={row:ee,column:se}:le.start={row:ee,column:se})}),{text:ce,tabstops:A,tokens:S}},x=(function(){function C(L){if(this.index=0,this.ranges=[],this.tabstops=[],L.tabstopManager)return L.tabstopManager;L.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=d.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(L)}return C.prototype.attach=function(L){this.$openTabstops=null,this.selectedTabstop=null,this.editor=L,this.session=L.session,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},C.prototype.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges.length=0,this.tabstops.length=0,this.selectedTabstop=null,this.editor.off("change",this.$onChange),this.editor.off("changeSelection",this.$onChangeSelection),this.editor.off("changeSession",this.$onChangeSession),this.editor.commands.off("afterExec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.session=null,this.editor=null},C.prototype.onChange=function(L){for(var D=L.action[0]=="r",I=this.selectedTabstop||{},T=I.parents||{},W=this.tabstops.slice(),F=0;F<W.length;F++){var O=W[F],S=O==I||T[O.index];if(O.rangeList.$bias=S?0:1,L.action=="remove"&&O!==I){var A=O.parents&&O.parents[I.index],N=O.rangeList.pointIndex(L.start,A);N=N<0?-N-1:N+1;var B=O.rangeList.pointIndex(L.end,A);B=B<0?-B-1:B-1;for(var U=O.rangeList.ranges.slice(N,B),G=0;G<U.length;G++)this.removeRange(U[G])}O.rangeList.$onChange(L)}var J=this.session;!this.$inChange&&D&&J.getLength()==1&&!J.getValue()&&this.detach()},C.prototype.updateLinkedFields=function(){var L=this.selectedTabstop;if(!(!L||!L.hasLinkedRanges||!L.firstNonLinked)){this.$inChange=!0;for(var D=this.session,I=D.getTextRange(L.firstNonLinked),T=0;T<L.length;T++){var W=L[T];if(W.linked){var F=W.original,O=r.snippetManager.tmStrFormat(I,F,this.editor);D.replace(W,O)}}this.$inChange=!1}},C.prototype.onAfterExec=function(L){L.command&&!L.command.readOnly&&this.updateLinkedFields()},C.prototype.onChangeSelection=function(){if(this.editor){for(var L=this.editor.selection.lead,D=this.editor.selection.anchor,I=this.editor.selection.isEmpty(),T=0;T<this.ranges.length;T++)if(!this.ranges[T].linked){var W=this.ranges[T].contains(L.row,L.column),F=I||this.ranges[T].contains(D.row,D.column);if(W&&F)return}this.detach()}},C.prototype.onChangeSession=function(){this.detach()},C.prototype.tabNext=function(L){var D=this.tabstops.length,I=this.index+(L||1);I=Math.min(Math.max(I,1),D),I==D&&(I=0),this.selectTabstop(I),this.updateTabstopMarkers(),I===0&&this.detach()},C.prototype.selectTabstop=function(L){this.$openTabstops=null;var D=this.tabstops[this.index];if(D&&this.addTabstopMarkers(D),this.index=L,D=this.tabstops[this.index],!(!D||!D.length)){this.selectedTabstop=D;var I=D.firstNonLinked||D;if(D.choices&&(I.cursor=I.start),this.editor.inVirtualSelectionMode)this.editor.selection.fromOrientedRange(I);else{var T=this.editor.multiSelect;T.toSingleRange(I);for(var W=0;W<D.length;W++)D.hasLinkedRanges&&D[W].linked||T.addRange(D[W].clone(),!0)}this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler),this.selectedTabstop&&this.selectedTabstop.choices&&this.editor.execCommand("startAutocomplete",{matches:this.selectedTabstop.choices})}},C.prototype.addTabstops=function(L,D,I){var T=this.useLink||!this.editor.getOption("enableMultiselect");if(this.$openTabstops||(this.$openTabstops=[]),!L[0]){var W=a.fromPoints(I,I);R(W.start,D),R(W.end,D),L[0]=[W],L[0].index=0}var F=this.index,O=[F+1,0],S=this.ranges,A=this.snippetId=(this.snippetId||0)+1;L.forEach(function(N,B){var U=this.$openTabstops[B]||N;U.snippetId=A;for(var G=0;G<N.length;G++){var J=N[G],ne=a.fromPoints(J.start,J.end||J.start);M(ne.start,D),M(ne.end,D),ne.original=J,ne.tabstop=U,S.push(ne),U!=N?U.unshift(ne):U[G]=ne,J.fmtString||U.firstNonLinked&&T?(ne.linked=!0,U.hasLinkedRanges=!0):U.firstNonLinked||(U.firstNonLinked=ne)}U.firstNonLinked||(U.hasLinkedRanges=!1),U===N&&(O.push(U),this.$openTabstops[B]=U),this.addTabstopMarkers(U),U.rangeList=U.rangeList||new l,U.rangeList.$bias=0,U.rangeList.addList(U)},this),O.length>2&&(this.tabstops.length&&O.push(O.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,O))},C.prototype.addTabstopMarkers=function(L){var D=this.session;L.forEach(function(I){I.markerId||(I.markerId=D.addMarker(I,"ace_snippet-marker","text"))})},C.prototype.removeTabstopMarkers=function(L){var D=this.session;L.forEach(function(I){D.removeMarker(I.markerId),I.markerId=null})},C.prototype.updateTabstopMarkers=function(){if(this.selectedTabstop){var L=this.selectedTabstop.snippetId;this.selectedTabstop.index===0&&L--,this.tabstops.forEach(function(D){D.snippetId===L?this.addTabstopMarkers(D):this.removeTabstopMarkers(D)},this)}},C.prototype.removeRange=function(L){var D=L.tabstop.indexOf(L);D!=-1&&L.tabstop.splice(D,1),D=this.ranges.indexOf(L),D!=-1&&this.ranges.splice(D,1),D=L.tabstop.rangeList.ranges.indexOf(L),D!=-1&&L.tabstop.splice(D,1),this.session.removeMarker(L.markerId),L.tabstop.length||(D=this.tabstops.indexOf(L.tabstop),D!=-1&&this.tabstops.splice(D,1),this.tabstops.length||this.detach())},C})();x.prototype.keyboardHandler=new c,x.prototype.keyboardHandler.bindKeys({Tab:function(C){r.snippetManager&&r.snippetManager.expandWithTab(C)||(C.tabstopManager.tabNext(1),C.renderer.scrollCursorIntoView())},"Shift-Tab":function(C){C.tabstopManager.tabNext(-1),C.renderer.scrollCursorIntoView()},Esc:function(C){C.tabstopManager.detach()}});var M=function(C,L){C.row==0&&(C.column+=L.column),C.row+=L.row},R=function(C,L){C.row==L.row&&(C.column-=L.column),C.row-=L.row};g.importCssString(`
1133
+ .ace_snippet-marker {
1134
+ -moz-box-sizing: border-box;
1135
+ box-sizing: border-box;
1136
+ background: rgba(194, 193, 208, 0.09);
1137
+ border: 1px dotted rgba(211, 208, 235, 0.62);
1138
+ position: absolute;
1139
+ }`,"snippets.css",!1),r.snippetManager=new p;var k=e("./editor").Editor;(function(){this.insertSnippet=function(C,L){return r.snippetManager.insertSnippet(this,C,L)},this.expandSnippet=function(C){return r.snippetManager.expandWithTab(this,C)}}).call(k.prototype)}),ace.define("ace/autocomplete/popup",["require","exports","module","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom","ace/config","ace/lib/useragent"],function(e,r,m){var f=e("../virtual_renderer").VirtualRenderer,g=e("../editor").Editor,w=e("../range").Range,u=e("../lib/event"),d=e("../lib/lang"),a=e("../lib/dom"),l=e("../config").nls,c=e("./../lib/useragent"),h=function(M){return"suggest-aria-id:".concat(M)},o=c.isSafari?"menu":"listbox",s=c.isSafari?"menuitem":"option",p=c.isSafari?"aria-current":"aria-selected",b=function(M){var R=new f(M);R.$maxLines=4;var k=new g(R);return k.setHighlightActiveLine(!1),k.setShowPrintMargin(!1),k.renderer.setShowGutter(!1),k.renderer.setHighlightGutterLine(!1),k.$mouseHandler.$focusTimeout=0,k.$highlightTagPending=!0,k},x=(function(){function M(R){var k=a.createElement("div"),C=b(k);R&&R.appendChild(k),k.style.display="none",C.renderer.content.style.cursor="default",C.renderer.setStyle("ace_autocomplete"),C.renderer.$textLayer.element.setAttribute("role",o),C.renderer.$textLayer.element.setAttribute("aria-roledescription",l("autocomplete.popup.aria-roledescription","Autocomplete suggestions")),C.renderer.$textLayer.element.setAttribute("aria-label",l("autocomplete.popup.aria-label","Autocomplete suggestions")),C.renderer.textarea.setAttribute("aria-hidden","true"),C.setOption("displayIndentGuides",!1),C.setOption("dragDelay",150);var L=function(){};C.focus=L,C.$isFocused=!0,C.renderer.$cursorLayer.restartTimer=L,C.renderer.$cursorLayer.element.style.opacity="0",C.renderer.$maxLines=8,C.renderer.$keepTextAreaAtCursor=!1,C.setHighlightActiveLine(!1),C.session.highlight(""),C.session.$searchHighlight.clazz="ace_highlight-marker",C.on("mousedown",function(S){var A=S.getDocumentPosition();C.selection.moveToPosition(A),T.start.row=T.end.row=A.row,S.stop()});var D,I=new w(-1,0,-1,1/0),T=new w(-1,0,-1,1/0);T.id=C.session.addMarker(T,"ace_active-line","fullLine"),C.setSelectOnHover=function(S){S?I.id&&(C.session.removeMarker(I.id),I.id=null):I.id=C.session.addMarker(I,"ace_line-hover","fullLine")},C.setSelectOnHover(!1),C.on("mousemove",function(S){if(!D){D=S;return}if(!(D.x==S.x&&D.y==S.y)){D=S,D.scrollTop=C.renderer.scrollTop,C.isMouseOver=!0;var A=D.getDocumentPosition().row;I.start.row!=A&&(I.id||C.setRow(A),F(A))}}),C.renderer.on("beforeRender",function(){if(D&&I.start.row!=-1){D.$pos=null;var S=D.getDocumentPosition().row;I.id||C.setRow(S),F(S,!0)}}),C.renderer.on("afterRender",function(){for(var S=C.renderer.$textLayer,A=S.config.firstRow,N=S.config.lastRow;A<=N;A++){var B=S.element.childNodes[A-S.config.firstRow];B.setAttribute("role",s),B.setAttribute("aria-roledescription",l("autocomplete.popup.item.aria-roledescription","item")),B.setAttribute("aria-setsize",C.data.length),B.setAttribute("aria-describedby","doc-tooltip"),B.setAttribute("aria-posinset",A+1);var U=C.getData(A);if(U){var G="".concat(U.caption||U.value).concat(U.meta?", ".concat(U.meta):"");B.setAttribute("aria-label",G)}var J=B.querySelectorAll(".ace_completion-highlight");J.forEach(function(ne){ne.setAttribute("role","mark")})}}),C.renderer.on("afterRender",function(){var S=C.getRow(),A=C.renderer.$textLayer,N=A.element.childNodes[S-A.config.firstRow],B=document.activeElement;if(N!==C.selectedNode&&C.selectedNode&&(a.removeCssClass(C.selectedNode,"ace_selected"),C.selectedNode.removeAttribute(p),C.selectedNode.removeAttribute("id")),B.removeAttribute("aria-activedescendant"),C.selectedNode=N,N){var U=h(S);a.addCssClass(N,"ace_selected"),N.id=U,A.element.setAttribute("aria-activedescendant",U),B.setAttribute("aria-activedescendant",U),N.setAttribute(p,"true")}});var W=function(){F(-1)},F=function(S,A){S!==I.start.row&&(I.start.row=I.end.row=S,A||C.session._emit("changeBackMarker"),C._emit("changeHoverMarker"))};C.getHoveredRow=function(){return I.start.row},u.addListener(C.container,"mouseout",function(){C.isMouseOver=!1,W()}),C.on("hide",W),C.on("changeSelection",W),C.session.doc.getLength=function(){return C.data.length},C.session.doc.getLine=function(S){var A=C.data[S];return typeof A=="string"?A:A&&A.value||""};var O=C.session.bgTokenizer;return O.$tokenizeRow=function(S){function A(le,pe){le&&B.push({type:(N.className||"")+(pe||""),value:le})}var N=C.data[S],B=[];if(!N)return B;typeof N=="string"&&(N={value:N});for(var U=N.caption||N.value||N.name,G=U.toLowerCase(),J=(C.filterText||"").toLowerCase(),ne=0,de=0,ee=0;ee<=J.length;ee++)if(ee!=de&&(N.matchMask&1<<ee||ee==J.length)){var se=J.slice(de,ee);de=ee;var ce=G.indexOf(se,ne);if(ce==-1)continue;A(U.slice(ne,ce),""),ne=ce+se.length,A(U.slice(ce,ne),"completion-highlight")}return A(U.slice(ne,U.length),""),B.push({type:"completion-spacer",value:" "}),N.meta&&B.push({type:"completion-meta",value:N.meta}),N.message&&B.push({type:"completion-message",value:N.message}),B},O.$updateOnChange=L,O.start=L,C.session.$computeWidth=function(){return this.screenWidth=0},C.isOpen=!1,C.isTopdown=!1,C.autoSelect=!0,C.filterText="",C.isMouseOver=!1,C.data=[],C.setData=function(S,A){C.filterText=A||"",C.setValue(d.stringRepeat(`
1140
+ `,S.length),-1),C.data=S||[],C.setRow(0)},C.getData=function(S){return C.data[S]},C.getRow=function(){return T.start.row},C.setRow=function(S){S=Math.max(this.autoSelect?0:-1,Math.min(this.data.length-1,S)),T.start.row!=S&&(C.selection.clearSelection(),T.start.row=T.end.row=S||0,C.session._emit("changeBackMarker"),C.moveCursorTo(S||0,0),C.isOpen&&C._signal("select"))},C.on("changeSelection",function(){C.isOpen&&C.setRow(C.selection.lead.row),C.renderer.scrollCursorIntoView()}),C.hide=function(){this.container.style.display="none",C.anchorPos=null,C.anchor=null,C.isOpen&&(C.isOpen=!1,this._signal("hide"))},C.tryShow=function(S,A,N,B){if(!B&&C.isOpen&&C.anchorPos&&C.anchor&&C.anchorPos.top===S.top&&C.anchorPos.left===S.left&&C.anchor===N)return!0;var U=this.container,G=this.renderer.scrollBar.width||10,J=window.innerHeight-G,ne=window.innerWidth-G,de=this.renderer,ee=de.$maxLines*A*1.4,se={top:0,bottom:0},ce=J-S.top-3*this.$borderSize-A,le=S.top-3*this.$borderSize;N||(le<=ce||ce>=ee?N="bottom":N="top"),N==="top"?(se.bottom=S.top-this.$borderSize,se.top=se.bottom-ee):N==="bottom"&&(se.top=S.top+A+this.$borderSize,se.bottom=se.top+ee);var pe=se.top>=0&&se.bottom<=J;if(!B&&!pe)return!1;pe?de.$maxPixelHeight=null:N==="top"?de.$maxPixelHeight=le:de.$maxPixelHeight=ce,N==="top"?(U.style.top="",U.style.bottom=J+G-se.bottom+"px",C.isTopdown=!1):(U.style.top=se.top+"px",U.style.bottom="",C.isTopdown=!0),U.style.display="";var me=S.left;return me+U.offsetWidth>ne&&(me=ne-U.offsetWidth),U.style.left=me+"px",U.style.right="",a.$fixPositionBug(U),C.isOpen||(C.isOpen=!0,this._signal("show"),D=null),C.anchorPos=S,C.anchor=N,!0},C.show=function(S,A,N){this.tryShow(S,A,N?"bottom":void 0,!0)},C.goTo=function(S){var A=this.getRow(),N=this.session.getLength()-1;switch(S){case"up":A=A<=0?N:A-1;break;case"down":A=A>=N?-1:A+1;break;case"start":A=0;break;case"end":A=N}this.setRow(A)},C.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},C.$imageSize=0,C.$borderSize=1,C}return M})();a.importCssString(`
1141
+ .ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {
1142
+ background-color: #CAD6FA;
1143
+ z-index: 1;
1144
+ }
1145
+ .ace_dark.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {
1146
+ background-color: #3a674e;
1147
+ }
1148
+ .ace_editor.ace_autocomplete .ace_line-hover {
1149
+ border: 1px solid #abbffe;
1150
+ margin-top: -1px;
1151
+ background: rgba(233,233,253,0.4);
1152
+ position: absolute;
1153
+ z-index: 2;
1154
+ }
1155
+ .ace_dark.ace_editor.ace_autocomplete .ace_line-hover {
1156
+ border: 1px solid rgba(109, 150, 13, 0.8);
1157
+ background: rgba(58, 103, 78, 0.62);
1158
+ }
1159
+ .ace_completion-meta {
1160
+ opacity: 0.5;
1161
+ margin-left: 0.9em;
1162
+ }
1163
+ .ace_completion-message {
1164
+ margin-left: 0.9em;
1165
+ color: blue;
1166
+ }
1167
+ .ace_editor.ace_autocomplete .ace_completion-highlight{
1168
+ color: #2d69c7;
1169
+ }
1170
+ .ace_dark.ace_editor.ace_autocomplete .ace_completion-highlight{
1171
+ color: #93ca12;
1172
+ }
1173
+ .ace_editor.ace_autocomplete {
1174
+ width: 300px;
1175
+ z-index: 200000;
1176
+ border: 1px lightgray solid;
1177
+ position: fixed;
1178
+ box-shadow: 2px 3px 5px rgba(0,0,0,.2);
1179
+ line-height: 1.4;
1180
+ background: #fefefe;
1181
+ color: #111;
1182
+ }
1183
+ .ace_dark.ace_editor.ace_autocomplete {
1184
+ border: 1px #484747 solid;
1185
+ box-shadow: 2px 3px 5px rgba(0, 0, 0, 0.51);
1186
+ line-height: 1.4;
1187
+ background: #25282c;
1188
+ color: #c1c1c1;
1189
+ }
1190
+ .ace_autocomplete .ace_text-layer {
1191
+ width: calc(100% - 8px);
1192
+ }
1193
+ .ace_autocomplete .ace_line {
1194
+ display: flex;
1195
+ align-items: center;
1196
+ }
1197
+ .ace_autocomplete .ace_line > * {
1198
+ min-width: 0;
1199
+ flex: 0 0 auto;
1200
+ }
1201
+ .ace_autocomplete .ace_line .ace_ {
1202
+ flex: 0 1 auto;
1203
+ overflow: hidden;
1204
+ text-overflow: ellipsis;
1205
+ }
1206
+ .ace_autocomplete .ace_completion-spacer {
1207
+ flex: 1;
1208
+ }
1209
+ .ace_autocomplete.ace_loading:after {
1210
+ content: "";
1211
+ position: absolute;
1212
+ top: 0px;
1213
+ height: 2px;
1214
+ width: 8%;
1215
+ background: blue;
1216
+ z-index: 100;
1217
+ animation: ace_progress 3s infinite linear;
1218
+ animation-delay: 300ms;
1219
+ transform: translateX(-100%) scaleX(1);
1220
+ }
1221
+ @keyframes ace_progress {
1222
+ 0% { transform: translateX(-100%) scaleX(1) }
1223
+ 50% { transform: translateX(625%) scaleX(2) }
1224
+ 100% { transform: translateX(1500%) scaleX(3) }
1225
+ }
1226
+ @media (prefers-reduced-motion) {
1227
+ .ace_autocomplete.ace_loading:after {
1228
+ transform: translateX(625%) scaleX(2);
1229
+ animation: none;
1230
+ }
1231
+ }
1232
+ `,"autocompletion.css",!1),r.AcePopup=x,r.$singleLineEditor=b,r.getAriaId=h}),ace.define("ace/autocomplete/inline_screenreader",["require","exports","module"],function(e,r,m){var f=(function(){function g(w){this.editor=w,this.screenReaderDiv=document.createElement("div"),this.screenReaderDiv.classList.add("ace_screenreader-only"),this.editor.container.appendChild(this.screenReaderDiv)}return g.prototype.setScreenReaderContent=function(w){for(!this.popup&&this.editor.completer&&this.editor.completer.popup&&(this.popup=this.editor.completer.popup,this.popup.renderer.on("afterRender",(function(){var d=this.popup.getRow(),a=this.popup.renderer.$textLayer,l=a.element.childNodes[d-a.config.firstRow];if(l){for(var c="doc-tooltip ",h=0;h<this._lines.length;h++)c+="ace-inline-screenreader-line-".concat(h," ");l.setAttribute("aria-describedby",c)}}).bind(this)));this.screenReaderDiv.firstChild;)this.screenReaderDiv.removeChild(this.screenReaderDiv.firstChild);this._lines=w.split(/\r\n|\r|\n/);var u=this.createCodeBlock();this.screenReaderDiv.appendChild(u)},g.prototype.destroy=function(){this.screenReaderDiv.remove()},g.prototype.createCodeBlock=function(){var w=document.createElement("pre");w.setAttribute("id","ace-inline-screenreader");for(var u=0;u<this._lines.length;u++){var d=document.createElement("code");d.setAttribute("id","ace-inline-screenreader-line-".concat(u));var a=document.createTextNode(this._lines[u]);d.appendChild(a),w.appendChild(d)}return w},g})();r.AceInlineScreenReader=f}),ace.define("ace/autocomplete/inline",["require","exports","module","ace/snippets","ace/autocomplete/inline_screenreader"],function(e,r,m){var f=e("../snippets").snippetManager,g=e("./inline_screenreader").AceInlineScreenReader,w=(function(){function u(){this.editor=null}return u.prototype.show=function(d,a,l){if(l=l||"",d&&this.editor&&this.editor!==d&&(this.hide(),this.editor=null,this.inlineScreenReader=null),!d||!a)return!1;this.inlineScreenReader||(this.inlineScreenReader=new g(d));var c=a.snippet?f.getDisplayTextForSnippet(d,a.snippet):a.value;return a.hideInlinePreview||!c||!c.startsWith(l)?!1:(this.editor=d,this.inlineScreenReader.setScreenReaderContent(c),c=c.slice(l.length),c===""?d.removeGhostText():d.setGhostText(c),!0)},u.prototype.isOpen=function(){return this.editor?!!this.editor.renderer.$ghostText:!1},u.prototype.hide=function(){return this.editor?(this.editor.removeGhostText(),!0):!1},u.prototype.destroy=function(){this.hide(),this.editor=null,this.inlineScreenReader&&(this.inlineScreenReader.destroy(),this.inlineScreenReader=null)},u})();r.AceInline=w}),ace.define("ace/autocomplete/util",["require","exports","module"],function(e,r,m){r.parForEach=function(g,w,u){var d=0,a=g.length;a===0&&u();for(var l=0;l<a;l++)w(g[l],function(c,h){d++,d===a&&u(c,h)})};var f=/[a-zA-Z_0-9\$\-\u00A2-\u2000\u2070-\uFFFF]/;r.retrievePrecedingIdentifier=function(g,w,u){u=u||f;for(var d=[],a=w-1;a>=0&&u.test(g[a]);a--)d.push(g[a]);return d.reverse().join("")},r.retrieveFollowingIdentifier=function(g,w,u){u=u||f;for(var d=[],a=w;a<g.length&&u.test(g[a]);a++)d.push(g[a]);return d},r.getCompletionPrefix=function(g){var w=g.getCursorPosition(),u=g.session.getLine(w.row),d;return g.completers.forEach((function(a){a.identifierRegexps&&a.identifierRegexps.forEach((function(l){!d&&l&&(d=this.retrievePrecedingIdentifier(u,w.column,l))}).bind(this))}).bind(this)),d||this.retrievePrecedingIdentifier(u,w.column)},r.triggerAutocomplete=function(g,u){var u=u??g.session.getPrecedingCharacter();return g.completers.some(function(d){if(d.triggerCharacters&&Array.isArray(d.triggerCharacters))return d.triggerCharacters.includes(u)})}}),ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/inline","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/lang","ace/lib/dom","ace/snippets","ace/config","ace/lib/event","ace/lib/scroll"],function(e,r,m){var f=e("./keyboard/hash_handler").HashHandler,g=e("./autocomplete/popup").AcePopup,w=e("./autocomplete/inline").AceInline,u=e("./autocomplete/popup").getAriaId,d=e("./autocomplete/util"),a=e("./lib/lang"),l=e("./lib/dom"),c=e("./snippets").snippetManager,h=e("./config"),o=e("./lib/event"),s=e("./lib/scroll").preventParentScroll,p=function(R,k){k.completer&&k.completer.destroy()},b=(function(){function R(){this.autoInsert=!1,this.autoSelect=!0,this.autoShown=!1,this.exactMatch=!1,this.inlineEnabled=!1,this.keyboardHandler=new f,this.keyboardHandler.bindKeys(this.commands),this.parentNode=null,this.setSelectOnHover=!1,this.hasSeen=new Set,this.showLoadingState=!1,this.stickySelectionDelay=500,this.blurListener=this.blurListener.bind(this),this.changeListener=this.changeListener.bind(this),this.mousedownListener=this.mousedownListener.bind(this),this.mousewheelListener=this.mousewheelListener.bind(this),this.onLayoutChange=this.onLayoutChange.bind(this),this.changeTimer=a.delayedCall((function(){this.updateCompletions(!0)}).bind(this)),this.tooltipTimer=a.delayedCall(this.updateDocTooltip.bind(this),50),this.popupTimer=a.delayedCall(this.$updatePopupPosition.bind(this),50),this.stickySelectionTimer=a.delayedCall((function(){this.stickySelection=!0}).bind(this),this.stickySelectionDelay),this.$firstOpenTimer=a.delayedCall((function(){var k=this.completionProvider&&this.completionProvider.initialPosition;this.autoShown||this.popup&&this.popup.isOpen||!k||this.editor.completers.length===0||(this.completions=new M(R.completionsForLoading),this.openPopup(this.editor,k.prefix,!1),this.popup.renderer.setStyle("ace_loading",!0))}).bind(this),this.stickySelectionDelay)}return Object.defineProperty(R,"completionsForLoading",{get:function(){return[{caption:h.nls("autocomplete.loading","Loading..."),value:""}]},enumerable:!1,configurable:!0}),R.prototype.$init=function(){return this.popup=new g(this.parentNode||document.body||document.documentElement),this.popup.on("click",(function(k){this.insertMatch(),k.stop()}).bind(this)),this.popup.focus=this.editor.focus.bind(this.editor),this.popup.on("show",this.$onPopupShow.bind(this)),this.popup.on("hide",this.$onHidePopup.bind(this)),this.popup.on("select",this.$onPopupChange.bind(this)),o.addListener(this.popup.container,"mouseout",this.mouseOutListener.bind(this)),this.popup.on("changeHoverMarker",this.tooltipTimer.bind(null,null)),this.popup.renderer.on("afterRender",this.$onPopupRender.bind(this)),this.popup},R.prototype.$initInline=function(){if(!(!this.inlineEnabled||this.inlineRenderer))return this.inlineRenderer=new w,this.inlineRenderer},R.prototype.getPopup=function(){return this.popup||this.$init()},R.prototype.$onHidePopup=function(){this.inlineRenderer&&this.inlineRenderer.hide(),this.hideDocTooltip(),this.stickySelectionTimer.cancel(),this.popupTimer.cancel(),this.stickySelection=!1},R.prototype.$seen=function(k){!this.hasSeen.has(k)&&k&&k.completer&&k.completer.onSeen&&typeof k.completer.onSeen=="function"&&(k.completer.onSeen(this.editor,k),this.hasSeen.add(k))},R.prototype.$onPopupChange=function(k){if(this.inlineRenderer&&this.inlineEnabled){var C=k?null:this.popup.getData(this.popup.getRow());if(this.$updateGhostText(C),this.popup.isMouseOver&&this.setSelectOnHover){this.tooltipTimer.call(null,null);return}this.popupTimer.schedule(),this.tooltipTimer.schedule()}else this.popupTimer.call(null,null),this.tooltipTimer.call(null,null)},R.prototype.$updateGhostText=function(k){var C=this.base.row,L=this.base.column,D=this.editor.getCursorPosition().column,I=this.editor.session.getLine(C).slice(L,D);this.inlineRenderer.show(this.editor,k,I)?this.$seen(k):this.inlineRenderer.hide()},R.prototype.$onPopupRender=function(){var k=this.inlineRenderer&&this.inlineEnabled;if(this.completions&&this.completions.filtered&&this.completions.filtered.length>0)for(var C=this.popup.getFirstVisibleRow();C<=this.popup.getLastVisibleRow();C++){var L=this.popup.getData(C);L&&(!k||L.hideInlinePreview)&&this.$seen(L)}},R.prototype.$onPopupShow=function(k){this.$onPopupChange(k),this.stickySelection=!1,this.stickySelectionDelay>=0&&this.stickySelectionTimer.schedule(this.stickySelectionDelay)},R.prototype.observeLayoutChanges=function(){if(!(this.$elements||!this.editor)){window.addEventListener("resize",this.onLayoutChange,{passive:!0}),window.addEventListener("wheel",this.mousewheelListener);for(var k=this.editor.container.parentNode,C=[];k;)C.push(k),k.addEventListener("scroll",this.onLayoutChange,{passive:!0}),k=k.parentNode;this.$elements=C}},R.prototype.unObserveLayoutChanges=function(){var k=this;window.removeEventListener("resize",this.onLayoutChange,{passive:!0}),window.removeEventListener("wheel",this.mousewheelListener),this.$elements&&this.$elements.forEach(function(C){C.removeEventListener("scroll",k.onLayoutChange,{passive:!0})}),this.$elements=null},R.prototype.onLayoutChange=function(){if(!this.popup.isOpen)return this.unObserveLayoutChanges();this.$updatePopupPosition(),this.updateDocTooltip()},R.prototype.$updatePopupPosition=function(){var k=this.editor,C=k.renderer,L=C.layerConfig.lineHeight,D=C.$cursorLayer.getPixelPosition(this.base,!0);D.left-=this.popup.getTextLeftOffset();var I=k.container.getBoundingClientRect();D.top+=I.top-C.layerConfig.offset,D.left+=I.left-k.renderer.scrollLeft,D.left+=C.gutterWidth;var T={top:D.top,left:D.left};C.$ghostText&&C.$ghostTextWidget&&this.base.row===C.$ghostText.position.row&&(T.top+=C.$ghostTextWidget.el.offsetHeight);var W=k.container.getBoundingClientRect().bottom-L,F=W<T.top?{top:W,left:T.left}:T;this.popup.tryShow(F,L,"bottom")||this.popup.tryShow(D,L,"top")||this.popup.show(D,L)},R.prototype.openPopup=function(k,C,L){this.$firstOpenTimer.cancel(),this.popup||this.$init(),this.inlineEnabled&&!this.inlineRenderer&&this.$initInline(),this.popup.autoSelect=this.autoSelect,this.popup.setSelectOnHover(this.setSelectOnHover);var D=this.popup.getRow(),I=this.popup.data[D];this.popup.setData(this.completions.filtered,this.completions.filterText),this.editor.textInput.setAriaOptions&&this.editor.textInput.setAriaOptions({activeDescendant:u(this.popup.getRow()),inline:this.inlineEnabled}),k.keyBinding.addKeyboardHandler(this.keyboardHandler);var T;this.stickySelection&&(T=this.popup.data.indexOf(I)),(!T||T===-1)&&(T=0),this.popup.setRow(this.autoSelect?T:-1),T===D&&I!==this.completions.filtered[T]&&this.$onPopupChange();var W=this.inlineRenderer&&this.inlineEnabled;if(T===D&&W){var F=this.popup.getData(this.popup.getRow());this.$updateGhostText(F)}L||(this.popup.setTheme(k.getTheme()),this.popup.setFontSize(k.getFontSize()),this.$updatePopupPosition(),this.tooltipNode&&this.updateDocTooltip()),this.changeTimer.cancel(),this.observeLayoutChanges()},R.prototype.detach=function(){this.editor&&(this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.off("changeSelection",this.changeListener),this.editor.off("blur",this.blurListener),this.editor.off("mousedown",this.mousedownListener),this.editor.off("mousewheel",this.mousewheelListener)),this.$firstOpenTimer.cancel(),this.changeTimer.cancel(),this.hideDocTooltip(),this.completionProvider&&this.completionProvider.detach(),this.popup&&this.popup.isOpen&&this.popup.hide(),this.popup&&this.popup.renderer&&this.popup.renderer.off("afterRender",this.$onPopupRender),this.base&&this.base.detach(),this.activated=!1,this.completionProvider=this.completions=this.base=null,this.unObserveLayoutChanges()},R.prototype.changeListener=function(k){var C=this.editor.selection.lead;(C.row!=this.base.row||C.column<this.base.column)&&this.detach(),this.activated?this.changeTimer.schedule():this.detach()},R.prototype.blurListener=function(k){var C=document.activeElement,L=this.editor.textInput.getElement(),D=k.relatedTarget&&this.tooltipNode&&this.tooltipNode.contains(k.relatedTarget),I=this.popup&&this.popup.container;C!=L&&C.parentNode!=I&&!D&&C!=this.tooltipNode&&k.relatedTarget!=L&&this.detach()},R.prototype.mousedownListener=function(k){this.detach()},R.prototype.mousewheelListener=function(k){this.popup&&!this.popup.isMouseOver&&this.detach()},R.prototype.mouseOutListener=function(k){this.popup.isOpen&&this.$updatePopupPosition()},R.prototype.goTo=function(k){this.popup.goTo(k)},R.prototype.insertMatch=function(k,C){if(k||(k=this.popup.getData(this.popup.getRow())),!k)return!1;if(k.value==="")return this.detach();var L=this.completions,D=this.getCompletionProvider().insertMatch(this.editor,k,L.filterText,C);return this.completions==L&&this.detach(),D},R.prototype.showPopup=function(k,C){this.editor&&this.detach(),this.activated=!0,this.editor=k,k.completer!=this&&(k.completer&&k.completer.detach(),k.completer=this),k.on("changeSelection",this.changeListener),k.on("blur",this.blurListener),k.on("mousedown",this.mousedownListener),k.on("mousewheel",this.mousewheelListener),this.updateCompletions(!1,C)},R.prototype.getCompletionProvider=function(k){return this.completionProvider||(this.completionProvider=new x(k)),this.completionProvider},R.prototype.gatherCompletions=function(k,C){return this.getCompletionProvider().gatherCompletions(k,C)},R.prototype.updateCompletions=function(k,C){if(k&&this.base&&this.completions){var D=this.editor.getCursorPosition(),I=this.editor.session.getTextRange({start:this.base,end:D});if(I==this.completions.filterText)return;if(this.completions.setFilter(I),!this.completions.filtered.length)return this.detach();if(this.completions.filtered.length==1&&this.completions.filtered[0].value==I&&!this.completions.filtered[0].snippet)return this.detach();this.openPopup(this.editor,I,k);return}if(C&&C.matches){var D=this.editor.getSelectionRange().start;return this.base=this.editor.session.doc.createAnchor(D.row,D.column),this.base.$insertRight=!0,this.completions=new M(C.matches),this.getCompletionProvider().completions=this.completions,this.openPopup(this.editor,"",k)}var L=this.editor.getSession(),D=this.editor.getCursorPosition(),I=d.getCompletionPrefix(this.editor);this.base=L.doc.createAnchor(D.row,D.column-I.length),this.base.$insertRight=!0;var T={exactMatch:this.exactMatch,ignoreCaption:this.ignoreCaption};this.getCompletionProvider({prefix:I,pos:D}).provideCompletions(this.editor,T,(function(W,F,O){var S=F.filtered,A=d.getCompletionPrefix(this.editor);if(this.$firstOpenTimer.cancel(),O){if(!S.length){var N=!this.autoShown&&this.emptyMessage;if(typeof N=="function"&&(N=this.emptyMessage(A)),N){var B=[{caption:N,value:""}];this.completions=new M(B),this.openPopup(this.editor,A,k),this.popup.renderer.setStyle("ace_loading",!1),this.popup.renderer.setStyle("ace_empty-message",!0);return}return this.detach()}if(S.length==1&&S[0].value==A&&!S[0].snippet)return this.detach();if(this.autoInsert&&!this.autoShown&&S.length==1)return this.insertMatch(S[0])}this.completions=!O&&this.showLoadingState?new M(R.completionsForLoading.concat(S),F.filterText):F,this.openPopup(this.editor,A,k),this.popup.renderer.setStyle("ace_empty-message",!1),this.popup.renderer.setStyle("ace_loading",!O)}).bind(this)),this.showLoadingState&&!this.autoShown&&(!this.popup||!this.popup.isOpen)&&this.$firstOpenTimer.delay(this.stickySelectionDelay/2)},R.prototype.cancelContextMenu=function(){this.editor.$mouseHandler.cancelContextMenu()},R.prototype.updateDocTooltip=function(){var k=this.popup,C=this.completions&&this.completions.filtered,L=C&&(C[k.getHoveredRow()]||C[k.getRow()]),D=null;if(!L||!this.editor||!this.popup.isOpen)return this.hideDocTooltip();for(var I=this.editor.completers.length,T=0;T<I;T++){var W=this.editor.completers[T];if(W.getDocTooltip&&L.completerId===W.id){D=W.getDocTooltip(L);break}}if(!D&&typeof L!="string"&&(D=L),typeof D=="string"&&(D={docText:D}),!D||!D.docHTML&&!D.docText)return this.hideDocTooltip();this.showDocTooltip(D)},R.prototype.showDocTooltip=function(k){this.tooltipNode||(this.tooltipNode=l.createElement("div"),this.tooltipNode.style.margin="0",this.tooltipNode.style.pointerEvents="auto",this.tooltipNode.style.overscrollBehavior="contain",this.tooltipNode.tabIndex=-1,this.tooltipNode.onblur=this.blurListener.bind(this),this.tooltipNode.onclick=this.onTooltipClick.bind(this),this.tooltipNode.id="doc-tooltip",this.tooltipNode.setAttribute("role","tooltip"),this.tooltipNode.addEventListener("wheel",s));var C=this.editor.renderer.theme;this.tooltipNode.className="ace_tooltip ace_doc-tooltip "+(C.isDark?"ace_dark ":"")+(C.cssClass||"");var L=this.tooltipNode;k.docHTML?L.innerHTML=k.docHTML:k.docText&&(L.textContent=k.docText),L.parentNode||this.popup.container.appendChild(this.tooltipNode);var D=this.popup,I=D.container.getBoundingClientRect(),T=400,W=300,F=D.renderer.scrollBar.width||10,O=I.left,S=window.innerWidth-I.right-F,A=D.isTopdown?window.innerHeight-F-I.bottom:I.top,N=[Math.min(S/T,1),Math.min(O/T,1),Math.min(A/W,1)*.9],B=Math.max.apply(Math,N),U=L.style;U.display="block",B==N[0]||N[0]>=1?(U.left=I.right+1+"px",U.right="",U.maxWidth=T*B+"px",U.top=I.top+"px",U.bottom="",U.maxHeight=Math.min(window.innerHeight-F-I.top,W)+"px"):B==N[1]||N[1]>=1?(U.right=window.innerWidth-I.left+"px",U.left="",U.maxWidth=T*B+"px",U.top=I.top+"px",U.bottom="",U.maxHeight=Math.min(window.innerHeight-F-I.top,W)+"px"):B==N[2]&&(U.left=I.left+"px",U.right="",U.maxWidth=Math.min(T,window.innerWidth-I.left)+"px",D.isTopdown?(U.top=I.bottom+"px",U.bottom="",U.maxHeight=Math.min(window.innerHeight-F-I.bottom,W)+"px"):(U.top="",U.bottom=window.innerHeight-I.top+"px",U.maxHeight=Math.min(I.top,W)+"px")),l.$fixPositionBug(L)},R.prototype.hideDocTooltip=function(){if(this.tooltipTimer.cancel(),!!this.tooltipNode){var k=this.tooltipNode;!this.editor.isFocused()&&document.activeElement==k&&this.editor.focus(),this.tooltipNode=null,k.parentNode&&k.parentNode.removeChild(k)}},R.prototype.onTooltipClick=function(k){for(var C=k.target;C&&C!=this.tooltipNode;){if(C.nodeName=="A"&&C.href){C.rel="noreferrer",C.target="_blank";break}C=C.parentNode}},R.prototype.destroy=function(){if(this.detach(),this.popup){this.popup.destroy();var k=this.popup.container;k&&k.parentNode&&k.parentNode.removeChild(k)}this.editor&&this.editor.completer==this&&(this.editor.off("destroy",p),this.editor.completer=null),this.inlineRenderer=this.popup=this.editor=null},R.for=function(k){return k.completer instanceof R||(k.completer&&(k.completer.destroy(),k.completer=null),h.get("sharedPopups")?(R.$sharedInstance||(R.$sharedInstance=new R),k.completer=R.$sharedInstance):(k.completer=new R,k.once("destroy",p))),k.completer},R})();b.prototype.commands={Up:function(R){R.completer.goTo("up")},Down:function(R){R.completer.goTo("down")},"Ctrl-Up|Ctrl-Home":function(R){R.completer.goTo("start")},"Ctrl-Down|Ctrl-End":function(R){R.completer.goTo("end")},Esc:function(R){R.completer.detach()},Return:function(R){return R.completer.insertMatch()},"Shift-Return":function(R){R.completer.insertMatch(null,{deleteSuffix:!0})},Tab:function(R){var k=R.completer.insertMatch();if(k||R.tabstopManager)return k;R.completer.goTo("down")},Backspace:function(R){R.execCommand("backspace");var k=d.getCompletionPrefix(R);!k&&R.completer&&R.completer.detach()},PageUp:function(R){R.completer.popup.gotoPageUp()},PageDown:function(R){R.completer.popup.gotoPageDown()}},b.startCommand={name:"startAutocomplete",exec:function(R,k){var C=b.for(R);C.autoInsert=!1,C.autoSelect=!0,C.autoShown=!1,C.showPopup(R,k),C.cancelContextMenu()},bindKey:"Ctrl-Space|Ctrl-Shift-Space|Alt-Space"};var x=(function(){function R(k){this.initialPosition=k,this.active=!0}return R.prototype.insertByIndex=function(k,C,L){return!this.completions||!this.completions.filtered?!1:this.insertMatch(k,this.completions.filtered[C],L)},R.prototype.insertMatch=function(k,C,L){if(!C)return!1;if(k.startOperation({command:{name:"insertMatch"}}),C.completer&&C.completer.insertMatch)C.completer.insertMatch(k,C);else{if(!this.completions)return!1;var D=this.completions.filterText.length,I=0;if(C.range&&C.range.start.row===C.range.end.row&&(D-=this.initialPosition.prefix.length,D+=this.initialPosition.pos.column-C.range.start.column,I+=C.range.end.column-this.initialPosition.pos.column),D||I){var T;k.selection.getAllRanges?T=k.selection.getAllRanges():T=[k.getSelectionRange()];for(var W=0,F;F=T[W];W++)F.start.column-=D,F.end.column+=I,k.session.remove(F)}C.snippet?c.insertSnippet(k,C.snippet):this.$insertString(k,C),C.completer&&C.completer.onInsert&&typeof C.completer.onInsert=="function"&&C.completer.onInsert(k,C),C.command&&C.command==="startAutocomplete"&&k.execCommand(C.command)}return k.endOperation(),!0},R.prototype.$insertString=function(k,C){var L=C.value||C;k.execCommand("insertstring",L)},R.prototype.gatherCompletions=function(k,C){var L=k.getSession(),D=k.getCursorPosition(),I=d.getCompletionPrefix(k),T=[];this.completers=k.completers;var W=k.completers.length;return k.completers.forEach(function(F,O){F.getCompletions(k,L,D,I,function(S,A){F.hideInlinePreview&&(A=A.map(function(N){return Object.assign(N,{hideInlinePreview:F.hideInlinePreview})})),!S&&A&&(T=T.concat(A)),C(null,{prefix:d.getCompletionPrefix(k),matches:T,finished:--W===0})})}),!0},R.prototype.provideCompletions=function(k,C,L){var D=(function(F){var O=F.prefix,S=F.matches;this.completions=new M(S),C.exactMatch&&(this.completions.exactMatch=!0),C.ignoreCaption&&(this.completions.ignoreCaption=!0),this.completions.setFilter(O),(F.finished||this.completions.filtered.length)&&L(null,this.completions,F.finished)}).bind(this),I=!0,T=null;if(this.gatherCompletions(k,(function(F,O){if(this.active){F&&(L(F,[],!0),this.detach());var S=O.prefix;if(S.indexOf(O.prefix)===0){if(I){T=O;return}D(O)}}}).bind(this)),I=!1,T){var W=T;T=null,D(W)}},R.prototype.detach=function(){this.active=!1,this.completers&&this.completers.forEach(function(k){typeof k.cancel=="function"&&k.cancel()})},R})(),M=(function(){function R(k,C){this.all=k,this.filtered=k,this.filterText=C||"",this.exactMatch=!1,this.ignoreCaption=!1}return R.prototype.setFilter=function(k){if(k.length>this.filterText&&k.lastIndexOf(this.filterText,0)===0)var C=this.filtered;else var C=this.all;this.filterText=k,C=this.filterCompletions(C,this.filterText),C=C.sort(function(D,I){return I.exactMatch-D.exactMatch||I.$score-D.$score||(D.caption||D.value).localeCompare(I.caption||I.value)});var L=null;C=C.filter(function(D){var I=D.snippet||D.caption||D.value;return I===L?!1:(L=I,!0)}),this.filtered=C},R.prototype.filterCompletions=function(k,C){var L=[],D=C.toUpperCase(),I=C.toLowerCase();e:for(var T=0,W;W=k[T];T++){if(W.skipFilter){W.$score=W.score,L.push(W);continue}var F=!this.ignoreCaption&&W.caption||W.value||W.snippet;if(F){var O=-1,S=0,A=0,N,B;if(this.exactMatch){if(C!==F.substr(0,C.length))continue e}else{var U=F.toLowerCase().indexOf(I);if(U>-1)A=U;else for(var G=0;G<C.length;G++){var J=F.indexOf(I[G],O+1),ne=F.indexOf(D[G],O+1);if(N=J>=0&&(ne<0||J<ne)?J:ne,N<0)continue e;B=N-O-1,B>0&&(O===-1&&(A+=10),A+=B,S|=1<<G),O=N}}W.matchMask=S,W.exactMatch=A?0:1,W.$score=(W.score||0)-A,L.push(W)}}return L},R})();r.Autocomplete=b,r.CompletionProvider=x,r.FilteredList=M}),ace.define("ace/marker_group",["require","exports","module"],function(e,r,m){var f=(function(){function g(w,u){u&&(this.markerType=u.markerType),this.markers=[],this.session=w,w.addDynamicMarker(this)}return g.prototype.getMarkerAtPosition=function(w){return this.markers.find(function(u){return u.range.contains(w.row,w.column)})},g.prototype.markersComparator=function(w,u){return w.range.start.row-u.range.start.row},g.prototype.setMarkers=function(w){this.markers=w.sort(this.markersComparator).slice(0,this.MAX_MARKERS),this.session._signal("changeBackMarker")},g.prototype.update=function(w,u,d,a){if(!(!this.markers||!this.markers.length))for(var l=a.firstRow,c=a.lastRow,h,o=0,s=0,p=0;p<this.markers.length;p++){var b=this.markers[p];if(!(b.range.end.row<l)&&!(b.range.start.row>c)&&(b.range.start.row===s?o++:(s=b.range.start.row,o=0),!(o>200))){var x=b.range.clipRows(l,c);if(!(x.start.row===x.end.row&&x.start.column===x.end.column)){var M=x.toScreenRange(d);if(M.isEmpty()){h=d.getNextFoldLine(x.end.row,h),h&&h.end.row>x.end.row&&(l=h.end.row);continue}this.markerType==="fullLine"?u.drawFullLineMarker(w,M,b.className,a):M.isMultiLine()?this.markerType==="line"?u.drawMultiLineMarker(w,M,b.className,a):u.drawTextMarker(w,M,b.className,a):u.drawSingleLineMarker(w,M,b.className+" ace_br15",a)}}}},g})();f.prototype.MAX_MARKERS=1e4,r.MarkerGroup=f}),ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"],function(e,r,m){function f(d,a){var l=d.getTextRange(w.fromPoints({row:0,column:0},a));return l.split(u).length-1}function g(d,a){var l=f(d,a),c=d.getValue().split(u),h=Object.create(null),o=c[l];return c.forEach(function(s,p){if(!(!s||s===o)){var b=Math.abs(l-p),x=c.length-b;h[s]?h[s]=Math.max(x,h[s]):h[s]=x}}),h}var w=e("../range").Range,u=/[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;r.id="textCompleter",r.getCompletions=function(d,a,l,c,h){var o=g(a,l),s=Object.keys(o);h(null,s.map(function(p){return{caption:p,value:p,score:o[p],meta:"local"}}))}}),ace.define("ace/ext/language_tools",["require","exports","module","ace/snippets","ace/autocomplete","ace/config","ace/lib/lang","ace/autocomplete/util","ace/marker_group","ace/autocomplete/text_completer","ace/editor","ace/config"],function(e,r,m){var f=e("../snippets").snippetManager,g=e("../autocomplete").Autocomplete,w=e("../config"),u=e("../lib/lang"),d=e("../autocomplete/util"),a=e("../marker_group").MarkerGroup,l=e("../autocomplete/text_completer"),c={getCompletions:function(I,T,W,F,O){if(T.$mode.completer)return T.$mode.completer.getCompletions(I,T,W,F,O);var S=I.session.getState(W.row),A=T.$mode.getCompletions(S,T,W,F);A=A.map(function(N){return N.completerId=c.id,N}),O(null,A)},id:"keywordCompleter"},h=function(I){var T={};return I.replace(/\${(\d+)(:(.*?))?}/g,function(W,F,O,S){return T[F]=S||""}).replace(/\$(\d+?)/g,function(W,F){return T[F]})},o={getCompletions:function(I,T,W,F,O){var S=[],A=T.getTokenAt(W.row,W.column);A&&A.type.match(/(tag-name|tag-open|tag-whitespace|attribute-name|attribute-value)\.xml$/)?S.push("html-tag"):S=f.getActiveScopes(I);var N=f.snippetMap,B=[];S.forEach(function(U){for(var G=N[U]||[],J=G.length;J--;){var ne=G[J],de=ne.name||ne.tabTrigger;de&&B.push({caption:de,snippet:ne.content,meta:ne.tabTrigger&&!ne.name?ne.tabTrigger+"⇥ ":"snippet",completerId:o.id})}},this),O(null,B)},getDocTooltip:function(I){I.snippet&&!I.docHTML&&(I.docHTML=["<b>",u.escapeHTML(I.caption),"</b>","<hr></hr>",u.escapeHTML(h(I.snippet))].join(""))},id:"snippetCompleter"},s=[o,l,c];r.setCompleters=function(I){s.length=0,I&&s.push.apply(s,I)},r.addCompleter=function(I){s.push(I)},r.textCompleter=l,r.keyWordCompleter=c,r.snippetCompleter=o;var p={name:"expandSnippet",exec:function(I){return f.expandWithTab(I)},bindKey:"Tab"},b=function(I,T){x(T.session.$mode)},x=function(I){typeof I=="string"&&(I=w.$modes[I]),I&&(f.files||(f.files={}),M(I.$id,I.snippetFileId),I.modes&&I.modes.forEach(x))},M=function(I,T){!T||!I||f.files[I]||(f.files[I]={},w.loadModule(T,function(W){W&&(f.files[I]=W,!W.snippets&&W.snippetText&&(W.snippets=f.parseSnippetFile(W.snippetText)),f.register(W.snippets||[],W.scope),W.includeScopes&&(f.snippetMap[W.scope].includeScopes=W.includeScopes,W.includeScopes.forEach(function(F){x("ace/mode/"+F)})))}))},R=function(I){var T=I.editor,W=T.completer&&T.completer.activated;if(I.command.name==="backspace")W&&!d.getCompletionPrefix(T)&&T.completer.detach();else if(I.command.name==="insertstring"&&!W){k=I;var F=I.editor.$liveAutocompletionDelay;F?C.delay(F):L(I)}},k,C=u.delayedCall(function(){L(k)},0),L=function(I){var T=I.editor,W=d.getCompletionPrefix(T),F=I.args,O=d.triggerAutocomplete(T,F);if(W&&W.length>=T.$liveAutocompletionThreshold||O){var S=g.for(T);S.autoShown=!0,S.showPopup(T)}},D=e("../editor").Editor;e("../config").defineOptions(D.prototype,"editor",{enableBasicAutocompletion:{set:function(I){I?(g.for(this),this.completers||(this.completers=Array.isArray(I)?I:s),this.commands.addCommand(g.startCommand)):this.commands.removeCommand(g.startCommand)},value:!1},enableLiveAutocompletion:{set:function(I){I?(this.completers||(this.completers=Array.isArray(I)?I:s),this.commands.on("afterExec",R)):this.commands.off("afterExec",R)},value:!1},liveAutocompletionDelay:{initialValue:0},liveAutocompletionThreshold:{initialValue:0},enableSnippets:{set:function(I){I?(this.commands.addCommand(p),this.on("changeMode",b),b(null,this)):(this.commands.removeCommand(p),this.off("changeMode",b))},value:!1}}),r.MarkerGroup=a}),(function(){ace.require(["ace/ext/language_tools"],function(e){t&&(t.exports=e)})})()})(yg)),yg.exports}$A();var wg={exports:{}},xg;function RA(){return xg||(xg=1,(function(t,n){ace.define("ace/ext/searchbox-css",["require","exports","module"],function(e,r,m){m.exports=`
1233
+
1234
+ /* ------------------------------------------------------------------------------------------
1235
+ * Editor Search Form
1236
+ * --------------------------------------------------------------------------------------- */
1237
+ .ace_search {
1238
+ background-color: #ddd;
1239
+ color: #666;
1240
+ border: 1px solid #cbcbcb;
1241
+ border-top: 0 none;
1242
+ overflow: hidden;
1243
+ margin: 0;
1244
+ padding: 4px 6px 0 4px;
1245
+ position: absolute;
1246
+ top: 0;
1247
+ z-index: 99;
1248
+ white-space: normal;
1249
+ }
1250
+ .ace_search.left {
1251
+ border-left: 0 none;
1252
+ border-radius: 0px 0px 5px 0px;
1253
+ left: 0;
1254
+ }
1255
+ .ace_search.right {
1256
+ border-radius: 0px 0px 0px 5px;
1257
+ border-right: 0 none;
1258
+ right: 0;
1259
+ }
1260
+
1261
+ .ace_search_form, .ace_replace_form {
1262
+ margin: 0 20px 4px 0;
1263
+ overflow: hidden;
1264
+ line-height: 1.9;
1265
+ }
1266
+ .ace_replace_form {
1267
+ margin-right: 0;
1268
+ }
1269
+ .ace_search_form.ace_nomatch {
1270
+ outline: 1px solid red;
1271
+ }
1272
+
1273
+ .ace_search_field {
1274
+ border-radius: 3px 0 0 3px;
1275
+ background-color: white;
1276
+ color: black;
1277
+ border: 1px solid #cbcbcb;
1278
+ border-right: 0 none;
1279
+ outline: 0;
1280
+ padding: 0;
1281
+ font-size: inherit;
1282
+ margin: 0;
1283
+ line-height: inherit;
1284
+ padding: 0 6px;
1285
+ min-width: 17em;
1286
+ vertical-align: top;
1287
+ min-height: 1.8em;
1288
+ box-sizing: content-box;
1289
+ }
1290
+ .ace_searchbtn {
1291
+ border: 1px solid #cbcbcb;
1292
+ line-height: inherit;
1293
+ display: inline-block;
1294
+ padding: 0 6px;
1295
+ background: #fff;
1296
+ border-right: 0 none;
1297
+ border-left: 1px solid #dcdcdc;
1298
+ cursor: pointer;
1299
+ margin: 0;
1300
+ position: relative;
1301
+ color: #666;
1302
+ }
1303
+ .ace_searchbtn:last-child {
1304
+ border-radius: 0 3px 3px 0;
1305
+ border-right: 1px solid #cbcbcb;
1306
+ }
1307
+ .ace_searchbtn:disabled {
1308
+ background: none;
1309
+ cursor: default;
1310
+ }
1311
+ .ace_searchbtn:hover {
1312
+ background-color: #eef1f6;
1313
+ }
1314
+ .ace_searchbtn.prev, .ace_searchbtn.next {
1315
+ padding: 0px 0.7em
1316
+ }
1317
+ .ace_searchbtn.prev:after, .ace_searchbtn.next:after {
1318
+ content: "";
1319
+ border: solid 2px #888;
1320
+ width: 0.5em;
1321
+ height: 0.5em;
1322
+ border-width: 2px 0 0 2px;
1323
+ display:inline-block;
1324
+ transform: rotate(-45deg);
1325
+ }
1326
+ .ace_searchbtn.next:after {
1327
+ border-width: 0 2px 2px 0 ;
1328
+ }
1329
+ .ace_searchbtn_close {
1330
+ background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAcCAYAAABRVo5BAAAAZ0lEQVR42u2SUQrAMAhDvazn8OjZBilCkYVVxiis8H4CT0VrAJb4WHT3C5xU2a2IQZXJjiQIRMdkEoJ5Q2yMqpfDIo+XY4k6h+YXOyKqTIj5REaxloNAd0xiKmAtsTHqW8sR2W5f7gCu5nWFUpVjZwAAAABJRU5ErkJggg==) no-repeat 50% 0;
1331
+ border-radius: 50%;
1332
+ border: 0 none;
1333
+ color: #656565;
1334
+ cursor: pointer;
1335
+ font: 16px/16px Arial;
1336
+ padding: 0;
1337
+ height: 14px;
1338
+ width: 14px;
1339
+ top: 9px;
1340
+ right: 7px;
1341
+ position: absolute;
1342
+ }
1343
+ .ace_searchbtn_close:hover {
1344
+ background-color: #656565;
1345
+ background-position: 50% 100%;
1346
+ color: white;
1347
+ }
1348
+
1349
+ .ace_button {
1350
+ margin-left: 2px;
1351
+ cursor: pointer;
1352
+ -webkit-user-select: none;
1353
+ -moz-user-select: none;
1354
+ -o-user-select: none;
1355
+ -ms-user-select: none;
1356
+ user-select: none;
1357
+ overflow: hidden;
1358
+ opacity: 0.7;
1359
+ border: 1px solid rgba(100,100,100,0.23);
1360
+ padding: 1px;
1361
+ box-sizing: border-box!important;
1362
+ color: black;
1363
+ }
1364
+
1365
+ .ace_button:hover {
1366
+ background-color: #eee;
1367
+ opacity:1;
1368
+ }
1369
+ .ace_button:active {
1370
+ background-color: #ddd;
1371
+ }
1372
+
1373
+ .ace_button.checked {
1374
+ border-color: #3399ff;
1375
+ opacity:1;
1376
+ }
1377
+
1378
+ .ace_search_options{
1379
+ margin-bottom: 3px;
1380
+ text-align: right;
1381
+ -webkit-user-select: none;
1382
+ -moz-user-select: none;
1383
+ -o-user-select: none;
1384
+ -ms-user-select: none;
1385
+ user-select: none;
1386
+ clear: both;
1387
+ }
1388
+
1389
+ .ace_search_counter {
1390
+ float: left;
1391
+ font-family: arial;
1392
+ padding: 0 8px;
1393
+ }`}),ace.define("ace/ext/searchbox",["require","exports","module","ace/ext/searchbox","ace/ext/searchbox","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/ext/searchbox-css","ace/keyboard/hash_handler","ace/lib/keys","ace/config"],function(e,r,m){var f=e("../lib/dom"),g=e("../lib/lang"),w=e("../lib/event"),u=e("./searchbox-css"),d=e("../keyboard/hash_handler").HashHandler,a=e("../lib/keys"),l=e("../config").nls,c=999;f.importCssString(u,"ace_searchbox",!1);var h=(function(){function p(b,x,M){this.activeInput,this.element=f.buildDom(["div",{class:"ace_search right"},["span",{action:"hide",class:"ace_searchbtn_close"}],["div",{class:"ace_search_form"},["input",{class:"ace_search_field",placeholder:l("search-box.find.placeholder","Search for"),spellcheck:"false"}],["span",{action:"findPrev",class:"ace_searchbtn prev"},"​"],["span",{action:"findNext",class:"ace_searchbtn next"},"​"],["span",{action:"findAll",class:"ace_searchbtn",title:"Alt-Enter"},l("search-box.find-all.text","All")]],["div",{class:"ace_replace_form"},["input",{class:"ace_search_field",placeholder:l("search-box.replace.placeholder","Replace with"),spellcheck:"false"}],["span",{action:"replaceAndFindNext",class:"ace_searchbtn"},l("search-box.replace-next.text","Replace")],["span",{action:"replaceAll",class:"ace_searchbtn"},l("search-box.replace-all.text","All")]],["div",{class:"ace_search_options"},["span",{action:"toggleReplace",class:"ace_button",title:l("search-box.toggle-replace.title","Toggle Replace mode"),style:"float:left;margin-top:-2px;padding:0 5px;"},"+"],["span",{class:"ace_search_counter"}],["span",{action:"toggleRegexpMode",class:"ace_button",title:l("search-box.toggle-regexp.title","RegExp Search")},".*"],["span",{action:"toggleCaseSensitive",class:"ace_button",title:l("search-box.toggle-case.title","CaseSensitive Search")},"Aa"],["span",{action:"toggleWholeWords",class:"ace_button",title:l("search-box.toggle-whole-word.title","Whole Word Search")},"\\b"],["span",{action:"searchInSelection",class:"ace_button",title:l("search-box.toggle-in-selection.title","Search In Selection")},"S"]]]),this.setSession=this.setSession.bind(this),this.$onEditorInput=this.onEditorInput.bind(this),this.$init(),this.setEditor(b),f.importCssString(u,"ace_searchbox",b.container),w.addListener(this.element,"touchstart",function(R){R.stopPropagation()},b)}return p.prototype.setEditor=function(b){b.searchBox=this,b.renderer.scroller.appendChild(this.element),this.editor=b},p.prototype.setSession=function(b){this.searchRange=null,this.$syncOptions(!0)},p.prototype.onEditorInput=function(){this.find(!1,!1,!0)},p.prototype.$initElements=function(b){this.searchBox=b.querySelector(".ace_search_form"),this.replaceBox=b.querySelector(".ace_replace_form"),this.searchOption=b.querySelector("[action=searchInSelection]"),this.replaceOption=b.querySelector("[action=toggleReplace]"),this.regExpOption=b.querySelector("[action=toggleRegexpMode]"),this.caseSensitiveOption=b.querySelector("[action=toggleCaseSensitive]"),this.wholeWordOption=b.querySelector("[action=toggleWholeWords]"),this.searchInput=this.searchBox.querySelector(".ace_search_field"),this.replaceInput=this.replaceBox.querySelector(".ace_search_field"),this.searchCounter=b.querySelector(".ace_search_counter")},p.prototype.$init=function(){var b=this.element;this.$initElements(b);var x=this;w.addListener(b,"mousedown",function(M){setTimeout(function(){x.activeInput.focus()},0),w.stopPropagation(M)}),w.addListener(b,"click",function(M){var R=M.target||M.srcElement,k=R.getAttribute("action");k&&x[k]?x[k]():x.$searchBarKb.commands[k]&&x.$searchBarKb.commands[k].exec(x),w.stopPropagation(M)}),w.addCommandKeyListener(b,function(M,R,k){var C=a.keyCodeToString(k),L=x.$searchBarKb.findKeyCommand(R,C);L&&L.exec&&(L.exec(x),w.stopEvent(M))}),this.$onChange=g.delayedCall(function(){x.find(!1,!1)}),w.addListener(this.searchInput,"input",function(){x.$onChange.schedule(20)}),w.addListener(this.searchInput,"focus",function(){x.activeInput=x.searchInput,x.searchInput.value&&x.highlight()}),w.addListener(this.replaceInput,"focus",function(){x.activeInput=x.replaceInput,x.searchInput.value&&x.highlight()})},p.prototype.setSearchRange=function(b){this.searchRange=b,b?this.searchRangeMarker=this.editor.session.addMarker(b,"ace_active-line"):this.searchRangeMarker&&(this.editor.session.removeMarker(this.searchRangeMarker),this.searchRangeMarker=null)},p.prototype.$syncOptions=function(b){f.setCssClass(this.replaceOption,"checked",this.searchRange),f.setCssClass(this.searchOption,"checked",this.searchOption.checked),this.replaceOption.textContent=this.replaceOption.checked?"-":"+",f.setCssClass(this.regExpOption,"checked",this.regExpOption.checked),f.setCssClass(this.wholeWordOption,"checked",this.wholeWordOption.checked),f.setCssClass(this.caseSensitiveOption,"checked",this.caseSensitiveOption.checked);var x=this.editor.getReadOnly();this.replaceOption.style.display=x?"none":"",this.replaceBox.style.display=this.replaceOption.checked&&!x?"":"none",this.find(!1,!1,b)},p.prototype.highlight=function(b){this.editor.session.highlight(b||this.editor.$search.$options.re),this.editor.renderer.updateBackMarkers()},p.prototype.find=function(b,x,M){if(this.editor.session){var R=this.editor.find(this.searchInput.value,{skipCurrent:b,backwards:x,wrap:!0,regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked,preventScroll:M,range:this.searchRange}),k=!R&&this.searchInput.value;f.setCssClass(this.searchBox,"ace_nomatch",k),this.editor._emit("findSearchBox",{match:!k}),this.highlight(),this.updateCounter()}},p.prototype.updateCounter=function(){var b=this.editor,x=b.$search.$options.re,M=x.unicode,R=0,k=0;if(x){var C=this.searchRange?b.session.getTextRange(this.searchRange):b.getValue();b.$search.$isMultilineSearch(b.getLastSearchOptions())&&(C=C.replace(/\r\n|\r|\n/g,`
1394
+ `),b.session.doc.$autoNewLine=`
1395
+ `);var L=b.session.doc.positionToIndex(b.selection.anchor);this.searchRange&&(L-=b.session.doc.positionToIndex(this.searchRange.start));for(var D=x.lastIndex=0,I;(I=x.exec(C))&&(R++,D=I.index,D<=L&&k++,!(R>c||!I[0]&&(x.lastIndex=D+=g.skipEmptyMatch(C,D,M),D>=C.length))););}this.searchCounter.textContent=l("search-box.search-counter","$0 of $1",[k,R>c?c+"+":R])},p.prototype.findNext=function(){this.find(!0,!1)},p.prototype.findPrev=function(){this.find(!0,!0)},p.prototype.findAll=function(){var b=this.editor.findAll(this.searchInput.value,{regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked}),x=!b&&this.searchInput.value;f.setCssClass(this.searchBox,"ace_nomatch",x),this.editor._emit("findSearchBox",{match:!x}),this.highlight(),this.hide()},p.prototype.replace=function(){this.editor.getReadOnly()||this.editor.replace(this.replaceInput.value)},p.prototype.replaceAndFindNext=function(){this.editor.getReadOnly()||(this.editor.replace(this.replaceInput.value),this.findNext())},p.prototype.replaceAll=function(){this.editor.getReadOnly()||this.editor.replaceAll(this.replaceInput.value)},p.prototype.hide=function(){this.active=!1,this.setSearchRange(null),this.editor.off("changeSession",this.setSession),this.editor.off("input",this.$onEditorInput),this.element.style.display="none",this.editor.keyBinding.removeKeyboardHandler(this.$closeSearchBarKb),this.editor.focus()},p.prototype.show=function(b,x){this.active=!0,this.editor.on("changeSession",this.setSession),this.editor.on("input",this.$onEditorInput),this.element.style.display="",this.replaceOption.checked=x,this.editor.$search.$options.regExp&&(b=g.escapeRegExp(b)),b!=null&&(this.searchInput.value=b),this.searchInput.focus(),this.searchInput.select(),this.editor.keyBinding.addKeyboardHandler(this.$closeSearchBarKb),this.$syncOptions(!0)},p.prototype.isFocused=function(){var b=document.activeElement;return b==this.searchInput||b==this.replaceInput},p})(),o=new d;o.bindKeys({"Ctrl-f|Command-f":function(p){var b=p.isReplace=!p.isReplace;p.replaceBox.style.display=b?"":"none",p.replaceOption.checked=!1,p.$syncOptions(),p.searchInput.focus()},"Ctrl-H|Command-Option-F":function(p){p.editor.getReadOnly()||(p.replaceOption.checked=!0,p.$syncOptions(),p.replaceInput.focus())},"Ctrl-G|Command-G":function(p){p.findNext()},"Ctrl-Shift-G|Command-Shift-G":function(p){p.findPrev()},esc:function(p){setTimeout(function(){p.hide()})},Return:function(p){p.activeInput==p.replaceInput&&p.replace(),p.findNext()},"Shift-Return":function(p){p.activeInput==p.replaceInput&&p.replace(),p.findPrev()},"Alt-Return":function(p){p.activeInput==p.replaceInput&&p.replaceAll(),p.findAll()},"Tab|Shift-Tab":function(p){(p.activeInput==p.replaceInput?p.searchInput:p.replaceInput).focus()}}),o.addCommands([{name:"toggleRegexpMode",bindKey:{win:"Alt-R|Alt-/",mac:"Ctrl-Alt-R|Ctrl-Alt-/"},exec:function(p){p.regExpOption.checked=!p.regExpOption.checked,p.$syncOptions()}},{name:"toggleCaseSensitive",bindKey:{win:"Alt-C|Alt-I",mac:"Ctrl-Alt-R|Ctrl-Alt-I"},exec:function(p){p.caseSensitiveOption.checked=!p.caseSensitiveOption.checked,p.$syncOptions()}},{name:"toggleWholeWords",bindKey:{win:"Alt-B|Alt-W",mac:"Ctrl-Alt-B|Ctrl-Alt-W"},exec:function(p){p.wholeWordOption.checked=!p.wholeWordOption.checked,p.$syncOptions()}},{name:"toggleReplace",exec:function(p){p.replaceOption.checked=!p.replaceOption.checked,p.$syncOptions()}},{name:"searchInSelection",exec:function(p){p.searchOption.checked=!p.searchRange,p.setSearchRange(p.searchOption.checked&&p.editor.getSelectionRange()),p.$syncOptions()}}]);var s=new d([{bindKey:"Esc",name:"closeSearchBar",exec:function(p){p.searchBox.hide()}}]);h.prototype.$searchBarKb=o,h.prototype.$closeSearchBarKb=s,r.SearchBox=h,r.Search=function(p,b){var x=p.searchBox||new h(p),M=p.session.selection.getRange(),R=M.isMultiLine()?"":p.session.getTextRange(M);x.show(R,b)}}),(function(){ace.require(["ace/ext/searchbox"],function(e){t&&(t.exports=e)})})()})(wg)),wg.exports}RA();var Cg={exports:{}},Ag;function EA(){return Ag||(Ag=1,(function(t,n){ace.define("ace/ext/hardwrap",["require","exports","module","ace/range","ace/editor","ace/config"],function(e,r,m){function f(d,a){function l(I,T,W){if(!(I.length<T)){var F=I.slice(0,T),O=I.slice(T),S=/^(?:(\s+)|(\S+)(\s+))/.exec(O),A=/(?:(\s+)|(\s+)(\S+))$/.exec(F),N=0,B=0;if(A&&!A[2]&&(N=T-A[1].length,B=T),S&&!S[2]&&(N||(N=T),B=T+S[1].length),N)return{start:N,end:B};if(A&&A[2]&&A.index>W)return{start:A.index,end:A.index+A[2].length};if(S&&S[2])return N=T+S[2].length,{start:N,end:N+S[3].length}}}for(var c=a.column||d.getOption("printMarginColumn"),h=a.allowMerge!=0,o=Math.min(a.startRow,a.endRow),s=Math.max(a.startRow,a.endRow),p=d.session;o<=s;){var b=p.getLine(o);if(b.length>c){var x=l(b,c,5);if(x){var M=/^\s*/.exec(b)[0];p.replace(new w(o,x.start,o,x.end),`
1396
+ `+M)}s++}else if(h&&/\S/.test(b)&&o!=s){var R=p.getLine(o+1);if(R&&/\S/.test(R)){var k=b.replace(/\s+$/,""),C=R.replace(/^\s+/,""),L=k+" "+C,x=l(L,c,5);if(x&&x.start>k.length||L.length<c){var D=new w(o,k.length,o+1,R.length-C.length);p.replace(D," "),o--,s--}else k.length<b.length&&p.remove(new w(o,k.length,o,b.length))}}o++}}function g(d){if(d.command.name=="insertstring"&&/\S/.test(d.args)){var a=d.editor,l=a.selection.cursor;if(l.column<=a.renderer.$printMarginColumn)return;var c=a.session.$undoManager.$lastDelta;f(a,{startRow:l.row,endRow:l.row,allowMerge:!1}),c!=a.session.$undoManager.$lastDelta&&a.session.markUndoGroup()}}var w=e("../range").Range,u=e("../editor").Editor;e("../config").defineOptions(u.prototype,"editor",{hardWrap:{set:function(d){d?this.commands.on("afterExec",g):this.commands.off("afterExec",g)},value:!1}}),r.hardWrap=f}),ace.define("ace/keyboard/vim",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/dom","ace/lib/oop","ace/lib/keys","ace/lib/event","ace/search","ace/lib/useragent","ace/search_highlight","ace/commands/multi_select_commands","ace/mode/text","ace/ext/hardwrap","ace/multi_select"],function(e,r,m){function f(y){return{row:y.line,column:y.ch}}function g(y){return new De(y.row,y.column)}function w(y,$,_){if($.line===_.line&&$.ch>=_.ch-1){var P=y.getLine($.line),z=P.charCodeAt($.ch);55296<=z&&z<=55551&&(_.ch+=1)}return{start:$,end:_}}function u(y){y.setOption("disableInput",!0),y.setOption("showCursorWhenSelecting",!1),Be.signal(y,"vim-mode-change",{mode:"normal"}),y.on("cursorActivity",vo),L(y),Be.on(y.getInputField(),"paste",a(y))}function d(y){y.setOption("disableInput",!1),y.off("cursorActivity",vo),Be.off(y.getInputField(),"paste",a(y)),y.state.vim=null,on&&clearTimeout(on)}function a(y){var $=y.state.vim;return $.onPasteFn||($.onPasteFn=function(){$.insertMode||(y.setCursor(pe(y.getCursor(),0,1)),Vn.enterInsertMode(y,{},$))}),$.onPasteFn}function l(y,$){return $>=y.firstLine()&&$<=y.lastLine()}function c(y){return/^[a-z]$/.test(y)}function h(y){return"()[]{}".indexOf(y)!=-1}function o(y){return Ca.test(y)}function s(y){return ct.test(y)}function p(y){return/^\s*$/.test(y)}function b(y){return".?!".indexOf(y)!=-1}function x(y,$){for(var _=0;_<$.length;_++)if($[_]==y)return!0;return!1}function M(y,$,_,P,z){if($===void 0&&!z)throw Error("defaultValue is required unless callback is provided");if(_||(_="string"),qt[y]={type:_,defaultValue:$,callback:z},P)for(var j=0;j<P.length;j++)qt[P[j]]=qt[y];$&&R(y,$)}function R(y,$,_,P){var z=qt[y];P=P||{};var j=P.scope;if(!z)return new Error("Unknown option: "+y);if(z.type=="boolean"){if($&&$!==!0)return new Error("Invalid argument: "+y+"="+$);$!==!1&&($=!0)}z.callback?(j!=="local"&&z.callback($,void 0),j!=="global"&&_&&z.callback($,_)):(j!=="local"&&(z.value=z.type=="boolean"?!!$:$),j!=="global"&&_&&(_.state.vim.options[y]={value:$}))}function k(y,$,_){var P=qt[y];_=_||{};var z=_.scope;if(!P)return new Error("Unknown option: "+y);if(P.callback){var j=$&&P.callback(void 0,$);return z!=="global"&&j!==void 0?j:z!=="local"?P.callback():void 0}var j=z!=="global"&&$&&$.state.vim.options[y];return(j||z!=="local"&&P||{}).value}function C(){this.latestRegister=void 0,this.isPlaying=!1,this.isRecording=!1,this.replaySearchQueries=[],this.onRecordingDone=void 0,this.lastInsertModeChanges=Un()}function L(y){return y.state.vim||(y.state.vim={inputState:new S,lastEditInputState:void 0,lastEditActionCommand:void 0,lastHPos:-1,lastHSPos:-1,lastMotion:null,marks:{},insertMode:!1,insertModeReturn:!1,insertModeRepeat:void 0,visualMode:!1,visualLine:!1,visualBlock:!1,lastSelection:null,lastPastedText:null,sel:{},options:{},expectLiteralNext:!1}),y.state.vim}function D(){je={searchQuery:null,searchIsReversed:!1,lastSubstituteReplacePart:void 0,jumpList:Pi(),macroModeState:new C,lastCharacterSearch:{increment:0,forward:!0,selectedCharacter:""},registerController:new G({}),searchHistoryController:new J,exCommandHistoryController:new J};for(var y in qt){var $=qt[y];$.value=$.defaultValue}}function I(y){function $(Y){typeof Y=="string"?zt.value=Y:zt=null}if(y[0]=="<"){var _=y.toLowerCase().slice(1,-1),P=_.split("-");if(_=P.pop()||"",_=="lt")y="<";else if(_=="space")y=" ";else if(_=="cr")y=`
1397
+ `;else if(io[_]){var z=zt.value,j={key:io[_],target:{value:z,selectionEnd:z.length,selectionStart:z.length}};zt.onKeyDown&&zt.onKeyDown(j,zt.value,$),zt&&zt.onKeyUp&&zt.onKeyUp(j,zt.value,$);return}}if(y==`
1398
+ `){var q=zt;zt=null,q.onClose&&q.onClose(q.value)}else zt.value=(zt.value||"")+y}function T(y,$,_){var P=Fi;if(_){if(Pr.indexOf(_)!=-1)return;Pr.push(_),Fi=_.noremap!=0}try{for(var z=L(y),j=/<(?:[CSMA]-)*\w+>|./gi,q;q=j.exec($);){var Y=q[0],X=z.insertMode;if(zt){I(Y);continue}var re=wt.handleKey(y,Y,"mapping");if(!re&&X&&z.insertMode){if(Y[0]=="<"){var ue=Y.toLowerCase().slice(1,-1),be=ue.split("-");if(ue=be.pop()||"",ue=="lt")Y="<";else if(ue=="space")Y=" ";else if(ue=="cr")Y=`
1399
+ `;else{if(io.hasOwnProperty(ue)){Y=io[ue],Ms(y,Y);continue}Y=Y[0],j.lastIndex=q.index+1}}y.replaceSelection(Y)}}}finally{if(Pr.pop(),Fi=Pr.length?P:!1,!Pr.length&&zt){var ke=zt;zt=null,bn(y,ke)}}}function W(y,$){var _=y.key;if(!ir[_]){_.length>1&&_[0]=="n"&&(_=_.replace("Numpad","")),_=Fr[_]||_;var P="";if(y.ctrlKey&&(P+="C-"),y.altKey&&(P+="A-"),y.metaKey&&(P+="M-"),Be.isMac&&y.altKey&&!y.metaKey&&!y.ctrlKey&&(P=P.slice(2)),(P||_.length>1)&&y.shiftKey&&(P+="S-"),$&&!$.expectLiteralNext&&_.length==1){if(Fn.keymap&&_ in Fn.keymap)(Fn.remapCtrl!=0||!P)&&(_=Fn.keymap[_]);else if(_.charCodeAt(0)>255){var z=y.code&&y.code.slice(-1)||"";y.shiftKey||(z=z.toLowerCase()),z&&(_=z)}}return P+=_,P.length>1&&(P="<"+P+">"),P}}function F(y,$){Fn.string!==y&&(Fn=O(y)),Fn.remapCtrl=$}function O(y){function $(P){return P.split(/\\?(.)/).filter(Boolean)}var _={};return y?(y.split(/((?:[^\\,]|\\.)+),/).map(function(P){if(P){var z=P.split(/((?:[^\\;]|\\.)+);/);if(z.length==3){var j=$(z[1]),q=$(z[2]);if(j.length!==q.length)return;for(var Y=0;Y<j.length;++Y)_[j[Y]]=q[Y]}else if(z.length==1){var X=$(P);if(X.length%2!==0)return;for(var Y=0;Y<X.length;Y+=2)_[X[Y]]=X[Y+1]}}}),{keymap:_,string:y}):{keymap:_,string:""}}function S(){this.prefixRepeat=[],this.motionRepeat=[],this.operator=null,this.operatorArgs=null,this.motion=null,this.motionArgs=null,this.keyBuffer=[],this.registerName=null,this.changeQueue=null}function A(y,$){y.state.vim.inputState=new S,y.state.vim.expectLiteralNext=!1,Be.signal(y,"vim-command-done",$)}function N(){this.removed=[],this.inserted=""}function B(y,$,_){this.clear(),this.keyBuffer=[y||""],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!!$,this.blockwise=!!_}function U(y,$){var _=je.registerController.registers;if(!y||y.length!=1)throw Error("Register name must be 1 character");_[y]=$,Os.push(y)}function G(y){this.registers=y,this.unnamedRegister=y['"']=new B,y["."]=new B,y[":"]=new B,y["/"]=new B,y["+"]=new B}function J(){this.historyBuffer=[],this.iterator=0,this.initialPrefix=null}function ne(y,$){Mn[y]=$}function de(y,$){for(var _=[],P=0;P<$;P++)_.push(y);return _}function ee(y,$){rs[y]=$}function se(y,$){Vn[y]=$}function ce(y,$,_){var P=y.state.vim,z=P.insertMode||P.visualMode,j=Math.min(Math.max(y.firstLine(),$.line),y.lastLine()),q=y.getLine(j),Y=q.length-1+ +!!z,X=Math.min(Math.max(0,$.ch),Y),re=q.charCodeAt(X);if(56320<=re&&re<=57343){var ue=1;_&&_.line==j&&_.ch>X&&(ue=-1),X+=ue,X>Y&&(X-=2)}return new De(j,X)}function le(y){var $={};for(var _ in y)y.hasOwnProperty(_)&&($[_]=y[_]);return $}function pe(y,$,_){return typeof $=="object"&&(_=$.ch,$=$.line),new De(y.line+$,y.ch+_)}function me(y,$,_,P){P.operator&&(_="operatorPending");for(var z,j=[],q=[],Y=Fi?$.length-Oo:0,X=Y;X<$.length;X++){var re=$[X];_=="insert"&&re.context!="insert"||re.context&&re.context!=_||P.operator&&re.type=="action"||!(z=$e(y,re.keys))||(z=="partial"&&j.push(re),z=="full"&&q.push(re))}return{partial:j.length&&j,full:q.length&&q}}function $e(y,$){var _=$.slice(-11)=="<character>",P=$.slice(-10)=="<register>";if(_||P){var z=$.length-(_?11:10),j=y.slice(0,z),q=$.slice(0,z);return j==q&&y.length>z?"full":q.indexOf(j)==0?"partial":!1}return y==$?"full":$.indexOf(y)==0?"partial":!1}function Ee(y){var $=/^.*(<[^>]+>)$/.exec(y),_=$?$[1]:y.slice(-1);if(_.length>1)switch(_){case"<CR>":_=`
1400
+ `;break;case"<Space>":_=" ";break;default:_=""}return _}function He(y,$,_){return function(){for(var P=0;P<_;P++)$(y)}}function Ue(y){return new De(y.line,y.ch)}function ot(y,$){return y.ch==$.ch&&y.line==$.line}function Qe(y,$){return y.line<$.line?!0:y.line==$.line&&y.ch<$.ch}function lt(y,$){return arguments.length>2&&($=lt.apply(void 0,Array.prototype.slice.call(arguments,1))),Qe(y,$)?y:$}function Tt(y,$){return arguments.length>2&&($=Tt.apply(void 0,Array.prototype.slice.call(arguments,1))),Qe(y,$)?$:y}function ur(y,$,_){var P=Qe(y,$),z=Qe($,_);return P&&z}function At(y,$){return y.getLine($).length}function vr(y){return y.trim?y.trim():y.replace(/^\s+|\s+$/g,"")}function Dn(y){return y.replace(/([.?*+$\[\]\/\\(){}|\-])/g,"\\$1")}function Kn(y,$,_){var P=At(y,$),z=new Array(_-P+1).join(" ");y.setCursor(new De($,P)),y.replaceRange(z,y.getCursor())}function un(y,$){var _=[],P=y.listSelections(),z=Ue(y.clipPos($)),j=!ot($,z),q=y.getCursor("head"),Y=gt(P,q),X=ot(P[Y].head,P[Y].anchor),re=P.length-1,ue=re-Y>Y?re:0,be=P[ue].anchor,ke=Math.min(be.line,z.line),ye=Math.max(be.line,z.line),Ae=be.ch,Oe=z.ch,Ie=P[ue].head.ch-Ae,Ge=Oe-Ae;Ie>0&&Ge<=0?(Ae++,j||Oe--):Ie<0&&Ge>=0?(Ae--,X||Oe++):Ie<0&&Ge==-1&&(Ae--,Oe++);for(var ut=ke;ut<=ye;ut++){var Ze={anchor:new De(ut,Ae),head:new De(ut,Oe)};_.push(Ze)}return y.setSelections(_),$.ch=Oe,be.ch=Ae,be}function Yn(y,$,_){for(var P=[],z=0;z<_;z++){var j=pe($,z,0);P.push({anchor:j,head:j})}y.setSelections(P,0)}function gt(y,$,_){for(var P=0;P<y.length;P++){var z=ot(y[P].anchor,$),j=ot(y[P].head,$);if(z||j)return P}return-1}function Je(y,$){var _=$.lastSelection,P=function(){var j=y.listSelections(),q=j[0],Y=j[j.length-1],X=Qe(q.anchor,q.head)?q.anchor:q.head,re=Qe(Y.anchor,Y.head)?Y.head:Y.anchor;return[X,re]},z=function(){var j=y.getCursor(),q=y.getCursor(),Y=_.visualBlock;if(Y){var X=Y.width,re=Y.height;q=new De(j.line+re,j.ch+X);for(var ue=[],be=j.line;be<q.line;be++){var ke=new De(be,j.ch),ye=new De(be,q.ch),Ae={anchor:ke,head:ye};ue.push(Ae)}y.setSelections(ue)}else{var Oe=_.anchorMark.find(),Ie=_.headMark.find(),Ge=Ie.line-Oe.line,ut=Ie.ch-Oe.ch;q={line:q.line+Ge,ch:Ge?q.ch:ut+q.ch},_.visualLine&&(j=new De(j.line,0),q=new De(q.line,At(y,q.line))),y.setSelection(j,q)}return[j,q]};return $.visualMode?P():z()}function Ft(y,$){var _=$.sel.anchor,P=$.sel.head;$.lastPastedText&&(P=y.posFromIndex(y.indexFromPos(_)+$.lastPastedText.length),$.lastPastedText=null),$.lastSelection={anchorMark:y.setBookmark(_),headMark:y.setBookmark(P),anchor:Ue(_),head:Ue(P),visualMode:$.visualMode,visualLine:$.visualLine,visualBlock:$.visualBlock}}function An(y,$,_,P){var z=y.state.vim.sel,j=P?$:z.head,q=P?$:z.anchor,Y;return Qe(_,$)&&(Y=_,_=$,$=Y),Qe(j,q)?(j=lt($,j),q=Tt(q,_)):(q=lt($,q),j=Tt(j,_),j=pe(j,0,-1),j.ch==-1&&j.line!=y.firstLine()&&(j=new De(j.line-1,At(y,j.line-1)))),[q,j]}function _n(y,$,z){var P=y.state.vim;$=$||P.sel;var z=z||P.visualLine?"line":P.visualBlock?"block":"char",j=kn(y,$,z);y.setSelections(j.ranges,j.primary)}function kn(y,$,_,P){var z=Ue($.head),j=Ue($.anchor);if(_=="char"){var q=!P&&!Qe($.head,$.anchor)?1:0,Y=Qe($.head,$.anchor)?1:0;return z=pe($.head,0,q),j=pe($.anchor,0,Y),{ranges:[{anchor:j,head:z}],primary:0}}if(_=="line"){if(Qe($.head,$.anchor))z.ch=0,j.ch=At(y,j.line);else{j.ch=0;var X=y.lastLine();z.line>X&&(z.line=X),z.ch=At(y,z.line)}return{ranges:[{anchor:j,head:z}],primary:0}}if(_=="block"){var re=Math.min(j.line,z.line),ue=j.ch,be=Math.max(j.line,z.line),ke=z.ch;ue<ke?ke+=1:ue+=1;for(var ye=be-re+1,Ae=z.line==re?0:ye-1,Oe=[],Ie=0;Ie<ye;Ie++)Oe.push({anchor:new De(re+Ie,ue),head:new De(re+Ie,ke)});return{ranges:Oe,primary:Ae}}}function mn(y){var $=y.getCursor("head");return y.getSelection().length==1&&($=lt($,y.getCursor("anchor"))),$}function vn(y,$){var _=y.state.vim;$!==!1&&y.setCursor(ce(y,_.sel.head)),Ft(y,_),_.visualMode=!1,_.visualLine=!1,_.visualBlock=!1,_.insertMode||Be.signal(y,"vim-mode-change",{mode:"normal"})}function Wn(y,$,_){var P=y.getRange($,_);if(/\n\s*$/.test(P)){var z=P.split(`
1401
+ `);z.pop();for(var j,j=z.pop();z.length>0&&j&&p(j);j=z.pop())_.line--,_.ch=0;j?(_.line--,_.ch=At(y,_.line)):_.ch=0}}function Jn(y,$,_){$.ch=0,_.ch=0,_.line++}function Jt(y){if(!y)return 0;var $=y.search(/\S/);return $==-1?y.length:$}function jn(y,$,_){var P=$.inclusive,z=$.innerWord,j=$.bigWord,q=$.noSymbol,Y=$.multiline,X=_||mn(y),re=y.getLine(X.line),ue=re,be=X.line,ke=be,ye=X.ch,Ae,Oe=q?No[0]:Di[0];if(z&&/\s/.test(re.charAt(ye)))Oe=function($n){return/\s/.test($n)};else{for(;!Oe(re.charAt(ye));)if(ye++,ye>=re.length){if(!Y)return null;ye--,Ae=bi(y,X,!0,j,!0);break}j?Oe=Di[0]:(Oe=No[0],Oe(re.charAt(ye))||(Oe=No[1]))}for(var Ie=ye,Ge=ye;Oe(re.charAt(Ge))&&Ge>=0;)Ge--;if(Ge++,Ae)Ie=Ae.to,ke=Ae.line,ue=y.getLine(ke),!ue&&Ie==0&&Ie++;else for(;Oe(re.charAt(Ie))&&Ie<re.length;)Ie++;if(P){var ut=Ie,Ze=X.ch<=Ge&&/\s/.test(re.charAt(X.ch));if(!Ze)for(;/\s/.test(ue.charAt(Ie))&&Ie<ue.length;)Ie++;if(ut==Ie||Ze){for(var et=Ge;/\s/.test(re.charAt(Ge-1))&&Ge>0;)Ge--;!Ge&&!Ze&&(Ge=et)}}return{start:new De(be,Ge),end:new De(ke,Ie)}}function oi(y,$,_){var P=$;if(!Be.findMatchingTag||!Be.findEnclosingTag)return{start:P,end:P};var z=Be.findMatchingTag(y,$)||Be.findEnclosingTag(y,$);return!z||!z.open||!z.close?{start:P,end:P}:_?{start:z.open.from,end:z.close.to}:{start:z.open.to,end:z.close.from}}function Or(y,$,_){ot($,_)||je.jumpList.add(y,$,_)}function Rn(y,$){je.lastCharacterSearch.increment=y,je.lastCharacterSearch.forward=$.forward,je.lastCharacterSearch.selectedCharacter=$.selectedCharacter}function yr(y,$,_,P){var z=Ue(y.getCursor()),j=_?1:-1,q=_?y.lineCount():-1,Y=z.ch,X=z.line,re=y.getLine(X),ue={lineText:re,nextCh:re.charAt(Y),lastCh:null,index:Y,symb:P,reverseSymb:(_?{")":"(","}":"{"}:{"(":")","{":"}"})[P],forward:_,depth:0,curMoveThrough:!1},be=_i[P];if(!be)return z;var ke=ki[be].init,ye=ki[be].isComplete;for(ke&&ke(ue);X!==q&&$;){if(ue.index+=j,ue.nextCh=ue.lineText.charAt(ue.index),!ue.nextCh){if(X+=j,ue.lineText=y.getLine(X)||"",j>0)ue.index=0;else{var Ae=ue.lineText.length;ue.index=Ae>0?Ae-1:0}ue.nextCh=ue.lineText.charAt(ue.index)}ye(ue)&&(z.line=X,z.ch=ue.index,$--)}return ue.nextCh||ue.curMoveThrough?new De(X,ue.index):z}function bi(y,$,_,P,z){var j=$.line,q=$.ch,Y=y.getLine(j),X=_?1:-1,re=P?Di:No;if(z&&Y==""){if(j+=X,Y=y.getLine(j),!l(y,j))return null;q=_?0:Y.length}for(;;){if(z&&Y=="")return{from:0,to:0,line:j};for(var ue=X>0?Y.length:-1,be=ue,ke=ue;q!=ue;){for(var ye=!1,Ae=0;Ae<re.length&&!ye;++Ae)if(re[Ae](Y.charAt(q))){for(be=q;q!=ue&&re[Ae](Y.charAt(q));)q+=X;if(ke=q,ye=be!=ke,be==$.ch&&j==$.line&&ke==be+X)continue;return{from:Math.min(be,ke+1),to:Math.max(be,ke),line:j}}ye||(q+=X)}if(j+=X,!l(y,j))return null;Y=y.getLine(j),q=X>0?0:Y.length}}function rr(y,$,_,P,z,j){var q=Ue($),Y=[];(P&&!z||!P&&z)&&_++;for(var X=!P||!z,re=0;re<_;re++){var ue=bi(y,$,P,j,X);if(!ue){var be=At(y,y.lastLine());Y.push(P?{line:y.lastLine(),from:be,to:be}:{line:0,from:0,to:0});break}Y.push(ue),$=new De(ue.line,P?ue.to-1:ue.from)}var ke=Y.length!=_,ye=Y[0],Ae=Y.pop();return P&&!z?(!ke&&(ye.from!=q.ch||ye.line!=q.line)&&(Ae=Y.pop()),new De(Ae.line,Ae.from)):P&&z?new De(Ae.line,Ae.to-1):!P&&z?(!ke&&(ye.to!=q.ch||ye.line!=q.line)&&(Ae=Y.pop()),new De(Ae.line,Ae.to)):new De(Ae.line,Ae.from)}function Xi(y,$,_,P,z){var j=$,q=new De(j.line+_.repeat-1,1/0),Y=y.clipPos(q);return Y.ch--,z||(P.lastHPos=1/0,P.lastHSPos=y.charCoords(Y,"div").left),q}function wi(y,$,_,P,z){for(var j=z||y.getCursor(),q=j.ch,Y,X=0;X<$;X++){var re=y.getLine(j.line);if(Y=Qi(q,re,P,_),Y==-1)return null;q=Y}return new De(y.getCursor().line,Y)}function Eo(y,$){var _=y.getCursor().line;return ce(y,new De(_,$-1))}function Yr(y,$,_,P){!x(_,xo)&&!nn.test(_)||($.marks[_]&&$.marks[_].clear(),$.marks[_]=y.setBookmark(P))}function Qi(y,$,_,P,z){var j;return P?(j=$.indexOf(_,y+1),j!=-1):(j=$.lastIndexOf(_,y-1),j!=-1),j}function Jo(y,$,_,P,z){function j(Ge){return!/\S/.test(y.getLine(Ge))}function q(Ge,ut,Ze){return Ze?j(Ge)!=j(Ge+ut):!j(Ge)&&j(Ge+ut)}function Y(Ge){P=P>0?1:-1;var ut=y.ace.session.getFoldLine(Ge);ut&&Ge+P>ut.start.row&&Ge+P<ut.end.row&&(P=(P>0?ut.end.row:ut.start.row)-Ge)}var X=$.line,re=y.firstLine(),ue=y.lastLine(),be,ke,ye=X;if(P){for(;re<=ye&&ye<=ue&&_>0;)Y(ye),q(ye,P)&&_--,ye+=P;return new De(ye,0)}var Ae=y.state.vim;if(Ae.visualLine&&q(X,1,!0)){var Oe=Ae.sel.anchor;q(Oe.line,-1,!0)&&(!z||Oe.line!=X)&&(X+=1)}var Ie=j(X);for(ye=X;ye<=ue&&_;ye++)q(ye,1,!0)&&(!z||j(ye)!=Ie)&&_--;for(ke=new De(ye,0),ye>ue&&!Ie?Ie=!0:z=!1,ye=X;ye>re&&!((!z||j(ye)==Ie||ye==X)&&q(ye,-1,!0));ye--);return be=new De(ye,0),{start:be,end:ke}}function To(y,$,_,P,z){function j(re){re.pos+re.dir<0||re.pos+re.dir>=re.line.length?re.line=null:re.pos+=re.dir}function q(re,ue,be,ke){var ye=re.getLine(ue),Ae={line:ye,ln:ue,pos:be,dir:ke};if(Ae.line==="")return{ln:Ae.ln,pos:Ae.pos};var Oe=Ae.pos;for(j(Ae);Ae.line!==null;){if(Oe=Ae.pos,b(Ae.line[Ae.pos])){if(!z)return{ln:Ae.ln,pos:Ae.pos+1};for(j(Ae);Ae.line!==null&&p(Ae.line[Ae.pos]);)Oe=Ae.pos,j(Ae);return{ln:Ae.ln,pos:Oe+1}}j(Ae)}return{ln:Ae.ln,pos:Oe+1}}function Y(re,ue,be,ke){var ye=re.getLine(ue),Ae={line:ye,ln:ue,pos:be,dir:ke};if(Ae.line==="")return{ln:Ae.ln,pos:Ae.pos};var Oe=Ae.pos;for(j(Ae);Ae.line!==null;){if(!p(Ae.line[Ae.pos])&&!b(Ae.line[Ae.pos]))Oe=Ae.pos;else if(b(Ae.line[Ae.pos]))return z?p(Ae.line[Ae.pos+1])?{ln:Ae.ln,pos:Ae.pos+1}:{ln:Ae.ln,pos:Oe}:{ln:Ae.ln,pos:Oe};j(Ae)}return Ae.line=ye,z&&p(Ae.line[Ae.pos])?{ln:Ae.ln,pos:Ae.pos}:{ln:Ae.ln,pos:Oe}}for(var X={ln:$.line,pos:$.ch};_>0;)P<0?X=Y(y,X.ln,X.pos,P):X=q(y,X.ln,X.pos,P),_--;return new De(X.ln,X.pos)}function Zt(y,$,_,P){function z(X,re){if(re.pos+re.dir<0||re.pos+re.dir>=re.line.length){if(re.ln+=re.dir,!l(X,re.ln)){re.line=null,re.ln=null,re.pos=null;return}re.line=X.getLine(re.ln),re.pos=re.dir>0?0:re.line.length-1}else re.pos+=re.dir}function j(X,re,ue,be){var Ie=X.getLine(re),ke=Ie==="",ye={line:Ie,ln:re,pos:ue,dir:be},Ae={ln:ye.ln,pos:ye.pos},Oe=ye.line==="";for(z(X,ye);ye.line!==null;){if(Ae.ln=ye.ln,Ae.pos=ye.pos,ye.line===""&&!Oe)return{ln:ye.ln,pos:ye.pos};if(ke&&ye.line!==""&&!p(ye.line[ye.pos]))return{ln:ye.ln,pos:ye.pos};b(ye.line[ye.pos])&&!ke&&(ye.pos===ye.line.length-1||p(ye.line[ye.pos+1]))&&(ke=!0),z(X,ye)}var Ie=X.getLine(Ae.ln);Ae.pos=0;for(var Ge=Ie.length-1;Ge>=0;--Ge)if(!p(Ie[Ge])){Ae.pos=Ge;break}return Ae}function q(X,re,ue,be){var Oe=X.getLine(re),ke={line:Oe,ln:re,pos:ue,dir:be},ye={ln:ke.ln,pos:null},Ae=ke.line==="";for(z(X,ke);ke.line!==null;){if(ke.line===""&&!Ae)return ye.pos!==null?ye:{ln:ke.ln,pos:ke.pos};if(!(!b(ke.line[ke.pos])||ye.pos===null||ke.ln===ye.ln&&ke.pos+1===ye.pos))return ye;ke.line!==""&&!p(ke.line[ke.pos])&&(Ae=!1,ye={ln:ke.ln,pos:ke.pos}),z(X,ke)}var Oe=X.getLine(ye.ln);ye.pos=0;for(var Ie=0;Ie<Oe.length;++Ie)if(!p(Oe[Ie])){ye.pos=Ie;break}return ye}for(var Y={ln:$.line,pos:$.ch};_>0;)P<0?Y=q(y,Y.ln,Y.pos,P):Y=j(y,Y.ln,Y.pos,P),_--;return new De(Y.ln,Y.pos)}function fn(y,$,_,P){var z=$,j,q,Y={"(":/[()]/,")":/[()]/,"[":/[[\]]/,"]":/[[\]]/,"{":/[{}]/,"}":/[{}]/,"<":/[<>]/,">":/[<>]/}[_],X={"(":"(",")":"(","[":"[","]":"[","{":"{","}":"{","<":"<",">":"<"}[_],re=y.getLine(z.line).charAt(z.ch),ue=re===X?1:0;if(j=y.scanForBracket(new De(z.line,z.ch+ue),-1,void 0,{bracketRegex:Y}),q=y.scanForBracket(new De(z.line,z.ch+ue),1,void 0,{bracketRegex:Y}),!j||!q)return null;if(j=j.pos,q=q.pos,j.line==q.line&&j.ch>q.ch||j.line>q.line){var be=j;j=q,q=be}return P?q.ch+=1:j.ch+=1,{start:j,end:q}}function Nr(y,$,_,P){var z=Ue($),j=y.getLine(z.line),q=j.split(""),Y,X,re,ue,be=q.indexOf(_);if(z.ch<be)z.ch=be;else if(be<z.ch&&q[z.ch]==_){var ke=/string/.test(y.getTokenTypeAt(pe($,0,1))),ye=/string/.test(y.getTokenTypeAt($)),Ae=ke&&!ye;Ae||(X=z.ch,--z.ch)}if(q[z.ch]==_&&!X)Y=z.ch+1;else for(re=z.ch;re>-1&&!Y;re--)q[re]==_&&(Y=re+1);if(Y&&!X)for(re=Y,ue=q.length;re<ue&&!X;re++)q[re]==_&&(X=re);return!Y||!X?{start:z,end:z}:(P&&(--Y,++X),{start:new De(z.line,Y),end:new De(z.line,X)})}function Dr(){}function Sn(y){var $=y.state.vim;return $.searchState_||($.searchState_=new Dr)}function Zn(y){return Ci(y,"/")}function xi(y){return Jr(y,"/")}function Ci(y,$){var _=Jr(y,$)||[];if(!_.length)return[];var P=[];if(_[0]===0){for(var z=0;z<_.length;z++)typeof _[z]=="number"&&P.push(y.substring(_[z]+1,_[z+1]));return P}}function Jr(y,$){$||($="/");for(var _=!1,P=[],z=0;z<y.length;z++){var j=y.charAt(z);!_&&j==$&&P.push(z),_=!_&&j=="\\"}return P}function si(y){for(var $="|(){",_="}",P=!1,z=[],j=-1;j<y.length;j++){var q=y.charAt(j)||"",Y=y.charAt(j+1)||"",X=Y&&$.indexOf(Y)!=-1;P?((q!=="\\"||!X)&&z.push(q),P=!1):q==="\\"?(P=!0,Y&&_.indexOf(Y)!=-1&&(X=!0),(!X||Y==="\\")&&z.push(q)):(z.push(q),X&&Y!=="\\"&&z.push("\\"))}return z.join("")}function Zo(y){for(var $=!1,_=[],P=-1;P<y.length;P++){var z=y.charAt(P)||"",j=y.charAt(P+1)||"";zi[z+j]?(_.push(zi[z+j]),P++):$?(_.push(z),$=!1):z==="\\"?($=!0,o(j)||j==="$"?_.push("$"):j!=="/"&&j!=="\\"&&_.push("\\")):(z==="$"&&_.push("$"),_.push(z),j==="/"&&_.push("\\"))}return _.join("")}function Mo(y){for(var $=new Be.StringStream(y),_=[];!$.eol();){for(;$.peek()&&$.peek()!="\\";)_.push($.next());var P=!1;for(var z in Ns)if($.match(z,!0)){P=!0,_.push(Ns[z]);break}P||_.push($.next())}return _.join("")}function ai(y,$,_){var P=je.registerController.getRegister("/");if(P.setText(y),y instanceof RegExp)return y;var z=xi(y),j,q;if(!z.length)j=y;else{j=y.substring(0,z[0]);var Y=y.substring(z[0]);q=Y.indexOf("i")!=-1}if(!j)return null;k("pcre")||(j=si(j)),_&&($=/^[^A-Z]*$/.test(j));var X=new RegExp(j,$||q?"im":"m");return X}function _r(y){typeof y=="string"&&(y=document.createElement(y));for(var $,_=1;_<arguments.length;_++)if($=arguments[_])if(typeof $!="object"&&($=document.createTextNode($)),$.nodeType)y.appendChild($);else for(var P in $)Object.prototype.hasOwnProperty.call($,P)&&(P[0]==="$"?y.style[P.slice(1)]=$[P]:y.setAttribute(P,$[P]));return y}function $t(y,$){var _=_r("div",{$color:"red",$whiteSpace:"pre",class:"cm-vim-message"},$);y.openNotification?y.openNotification(_,{bottom:!0,duration:5e3}):alert(_.innerText)}function eo(y,$){return _r("div",{$display:"flex"},_r("span",{$fontFamily:"monospace",$whiteSpace:"pre",$flex:1},y,_r("input",{type:"text",autocorrect:"off",autocapitalize:"off",spellcheck:"false",$width:"100%"})),$&&_r("span",{$color:"#888"},$))}function bn(y,$){if(Pr.length){$.value||($.value=""),zt=$;return}var _=eo($.prefix,$.desc);if(y.openDialog)y.openDialog(_,$.onClose,{onKeyDown:$.onKeyDown,onKeyUp:$.onKeyUp,bottom:!0,selectValueOnOpen:!1,value:$.value});else{var P="";typeof $.prefix!="string"&&$.prefix&&(P+=$.prefix.textContent),$.desc&&(P+=" "+$.desc),$.onClose(prompt(P,""))}}function En(y,$){if(y instanceof RegExp&&$ instanceof RegExp){for(var _=["global","multiline","ignoreCase","source"],P=0;P<_.length;P++){var z=_[P];if(y[z]!==$[z])return!1}return!0}return!1}function hn(y,$,_,P){if($){var z=Sn(y),j=ai($,!!_,!!P);if(j)return Ni(y,j),En(j,z.getQuery())||z.setQuery(j),j}}function Tn(y){if(y.source.charAt(0)=="^")var $=!0;return{token:function(_){if($&&!_.sol()){_.skipToEnd();return}var P=_.match(y,!1);if(P)return P[0].length==0?(_.next(),"searching"):!_.sol()&&(_.backUp(1),!y.exec(_.next()+P[0]))?(_.next(),null):(_.match(y),"searching");for(;!_.eol()&&(_.next(),!_.match(y,!1)););},query:y}}function Ni(y,$){clearTimeout(on);var _=Sn(y);_.highlightTimeout=on,on=setTimeout(function(){if(y.state.vim){var P=Sn(y);P.highlightTimeout=null;var z=P.getOverlay();(!z||$!=z.query)&&(z&&y.removeOverlay(z),z=Tn($),y.addOverlay(z),y.showMatchesOnScrollbar&&(P.getScrollbarAnnotate()&&P.getScrollbarAnnotate().clear(),P.setScrollbarAnnotate(y.showMatchesOnScrollbar($))),P.setOverlay(z))}},50)}function Hn(y,$,_,P){return P===void 0&&(P=1),y.operation(function(){for(var z=y.getCursor(),j=y.getSearchCursor(_,z),q=0;q<P;q++){var Y=j.find($);if(q==0&&Y&&ot(j.from(),z)){var X=$?j.from():j.to();Y=j.find($),Y&&!Y[0]&&ot(j.from(),X)&&y.getLine(X.line).length==X.ch&&(Y=j.find($))}if(!Y&&(j=y.getSearchCursor(_,$?new De(y.lastLine()):new De(y.firstLine(),0)),!j.find($)))return}return j.from()})}function li(y,$,_,P,z){return P===void 0&&(P=1),y.operation(function(){var j=y.getCursor(),q=y.getSearchCursor(_,j),Y=q.find(!$);!z.visualMode&&Y&&ot(q.from(),j)&&q.find(!$);for(var X=0;X<P;X++)if(Y=q.find($),!Y&&(q=y.getSearchCursor(_,$?new De(y.lastLine()):new De(y.firstLine(),0)),!q.find($)))return;return[q.from(),q.to()]})}function br(y){var $=Sn(y);$.highlightTimeout&&(clearTimeout($.highlightTimeout),$.highlightTimeout=null),y.removeOverlay(Sn(y).getOverlay()),$.setOverlay(null),$.getScrollbarAnnotate()&&($.getScrollbarAnnotate().clear(),$.setScrollbarAnnotate(null))}function oe(y,$,_){return typeof y!="number"&&(y=y.line),$ instanceof Array?x(y,$):typeof _=="number"?y>=$&&y<=_:y==$}function Ne(y){var $=y.ace.renderer;return{top:$.getFirstFullyVisibleRow(),bottom:$.getLastFullyVisibleRow()}}function ze(y,$,_){if(_=="'"||_=="`")return je.jumpList.find(y,-1)||new De(0,0);if(_==".")return mt(y);var P=$.marks[_];return P&&P.find()}function mt(y){if(y.getLastEditEnd)return y.getLastEditEnd();for(var $=y.doc.history.done,_=$.length;_--;)if($[_].changes)return Ue($[_].changes[0].to)}function Ot(y,$,_,P,z,j,q,Y,X){function re(){y.operation(function(){for(;!Oe;)ue(),ke();ye()})}function ue(){var Ze=y.getRange(j.from(),j.to()),et=Ze.replace(q,Y),$n=j.to().line;j.replace(et),Ge=j.to().line,z+=Ge-$n,ut=Ge<$n}function be(){var Ze=Ie&&Ue(j.to()),et=j.findNext();return et&&!et[0]&&Ze&&ot(j.from(),Ze)&&(et=j.findNext()),et}function ke(){for(;be()&&oe(j.from(),P,z);)if(!(!_&&j.from().line==Ge&&!ut)){y.scrollIntoView(j.from(),30),y.setSelection(j.from(),j.to()),Ie=j.from(),Oe=!1;return}Oe=!0}function ye(Ze){if(Ze&&Ze(),y.focus(),Ie){y.setCursor(Ie);var et=y.state.vim;et.exMode=!1,et.lastHPos=et.lastHSPos=Ie.ch}X&&X()}function Ae(Ze,et,$n){Be.e_stop(Ze);var Ct=W(Ze);switch(Ct){case"y":ue(),ke();break;case"n":ke();break;case"a":var Yt=X;X=void 0,y.operation(re),X=Yt;break;case"l":ue();case"q":case"<Esc>":case"<C-c>":case"<C-[>":ye($n)}return Oe&&ye($n),!0}y.state.vim.exMode=!0;var Oe=!1,Ie,Ge,ut;if(ke(),Oe){$t(y,"No matches for "+q.source);return}if(!$){re(),X&&X();return}bn(y,{prefix:_r("span","replace with ",_r("strong",Y)," (y/n/a/q/l)"),onKeyDown:Ae})}function Mt(y,$){var _=y.state.vim,P=je.macroModeState,z=je.registerController.getRegister("."),j=P.isPlaying,q=P.lastInsertModeChanges;j||(y.off("change",mo),_.insertEnd&&_.insertEnd.clear(),_.insertEnd=null,Be.off(y.getInputField(),"keydown",Io)),!j&&_.insertModeRepeat>1&&(Ts(y,_,_.insertModeRepeat-1,!0),_.lastEditInputState.repeatOverride=_.insertModeRepeat),delete _.insertModeRepeat,_.insertMode=!1,$||y.setCursor(y.getCursor().line,y.getCursor().ch-1),y.setOption("keyMap","vim"),y.setOption("disableInput",!0),y.toggleOverwrite(!1),z.setText(q.changes.join("")),Be.signal(y,"vim-mode-change",{mode:"normal"}),P.isRecording&&Ht(P)}function wr(y){Pn.unshift(y)}function xr(y,$,_,P,z){var j={keys:y,type:$};j[$]=_,j[$+"Args"]=P;for(var q in z)j[q]=z[q];wr(j)}function hr(y,$,_,P){var z=je.registerController.getRegister(P);if(P==":"){z.keyBuffer[0]&&zr.processCommand(y,z.keyBuffer[0]),_.isPlaying=!1;return}var j=z.keyBuffer,q=0;_.isPlaying=!0,_.replaySearchQueries=z.searchQueries.slice(0);for(var Y=0;Y<j.length;Y++)for(var X=j[Y],re,ue;X;)if(re=/<\w+-.+?>|<\w+>|./.exec(X),ue=re[0],X=X.substring(re.index+ue.length),wt.handleKey(y,ue,"macro"),$.insertMode){var be=z.insertModeChanges[q++].changes;je.macroModeState.lastInsertModeChanges.changes=be,Qo(y,be,1),Mt(y)}_.isPlaying=!1}function ci(y,$){if(!y.isPlaying){var _=y.latestRegister,P=je.registerController.getRegister(_);P&&P.pushText($)}}function Ht(y){if(!y.isPlaying){var $=y.latestRegister,_=je.registerController.getRegister($);_&&_.pushInsertModeChanges&&_.pushInsertModeChanges(y.lastInsertModeChanges)}}function go(y,$){if(!y.isPlaying){var _=y.latestRegister,P=je.registerController.getRegister(_);P&&P.pushSearchQuery&&P.pushSearchQuery($)}}function mo(y,$){var _=je.macroModeState,P=_.lastInsertModeChanges;if(!_.isPlaying)for(var z=y.state.vim;$;){if(P.expectCursorActivityForChange=!0,P.ignoreCount>1)P.ignoreCount--;else if($.origin=="+input"||$.origin=="paste"||$.origin===void 0){var j=y.listSelections().length;j>1&&(P.ignoreCount=j);var q=$.text.join(`
1402
+ `);if(P.maybeReset&&(P.changes=[],P.maybeReset=!1),q)if(y.state.overwrite&&!/\n/.test(q))P.changes.push([q]);else{if(q.length>1){var Y=z&&z.insertEnd&&z.insertEnd.find(),X=y.getCursor();if(Y&&Y.line==X.line){var re=Y.ch-X.ch;re>0&&re<q.length&&(P.changes.push([q,re]),q="")}}q&&P.changes.push(q)}}$=$.next}}function vo(y){var $=y.state.vim;if($.insertMode){var _=je.macroModeState;if(_.isPlaying)return;var P=_.lastInsertModeChanges;P.expectCursorActivityForChange?P.expectCursorActivityForChange=!1:(P.maybeReset=!0,$.insertEnd&&$.insertEnd.clear(),$.insertEnd=y.setBookmark(y.getCursor(),{insertLeft:!0}))}else y.curOp.isVimOp||Es(y,$)}function Es(y,$,_){var P=y.getCursor("anchor"),z=y.getCursor("head");if($.visualMode&&!y.somethingSelected()?vn(y,!1):!$.visualMode&&!$.insertMode&&y.somethingSelected()&&($.visualMode=!0,$.visualLine=!1,Be.signal(y,"vim-mode-change",{mode:"visual"})),$.visualMode){var j=Qe(z,P)?0:-1,q=Qe(z,P)?-1:0;z=pe(z,0,j),P=pe(P,0,q),$.sel={anchor:P,head:z},Yr(y,$,"<",lt(z,P)),Yr(y,$,">",Tt(z,P))}else!$.insertMode&&!_&&($.lastHPos=y.getCursor().ch)}function Xo(y,$){this.keyName=y,this.key=$.key,this.ctrlKey=$.ctrlKey,this.altKey=$.altKey,this.metaKey=$.metaKey,this.shiftKey=$.shiftKey}function Io(y){var $=je.macroModeState,_=$.lastInsertModeChanges,P=Be.keyName?Be.keyName(y):y.key;P&&(P.indexOf("Delete")!=-1||P.indexOf("Backspace")!=-1)&&(_.maybeReset&&(_.changes=[],_.maybeReset=!1),_.changes.push(new Xo(P,y)))}function Ts(y,$,_,P){function z(){Y?Ai.processAction(y,$,$.lastEditActionCommand):Ai.evalInput(y,$)}function j(ue){if(q.lastInsertModeChanges.changes.length>0){ue=$.lastEditActionCommand?ue:1;var be=q.lastInsertModeChanges;Qo(y,be.changes,ue)}}var q=je.macroModeState;q.isPlaying=!0;var Y=!!$.lastEditActionCommand,X=$.inputState;if($.inputState=$.lastEditInputState,Y&&$.lastEditActionCommand.interlaceInsertRepeat)for(var re=0;re<_;re++)z(),j(1);else P||z(),j(_);$.inputState=X,$.insertMode&&!P&&Mt(y),q.isPlaying=!1}function Ms(y,$){Be.lookupKey($,"vim-insert",function(_){return typeof _=="string"?Be.commands[_](y):_(y),!0})}function Qo(y,$,_){var P=y.getCursor("head"),z=je.macroModeState.lastInsertModeChanges.visualBlock;z&&(Yn(y,P,z+1),_=y.listSelections().length,y.setCursor(P));for(var j=0;j<_;j++){z&&y.setCursor(pe(P,j,0));for(var q=0;q<$.length;q++){var Y=$[q];if(Y instanceof Xo)Ms(y,Y.keyName);else if(typeof Y=="string")y.replaceSelection(Y);else{var X=y.getCursor(),re=pe(X,0,Y[0].length-(Y[1]||0));y.replaceRange(Y[0],X,Y[1]?X:re),y.setCursor(re)}}}z&&y.setCursor(pe(P,0,1))}function ya(y,$,_,P){$.length>1&&$[0]=="n"&&($=$.replace("numpad","")),$=Co[$]||$;var z="";if(_.ctrlKey&&(z+="C-"),_.altKey&&(z+="A-"),(z||$.length>1)&&_.shiftKey&&(z+="S-"),P&&!P.expectLiteralNext&&$.length==1){if(Fn.keymap&&$ in Fn.keymap)(Fn.remapCtrl!==!1||!z)&&($=Fn.keymap[$]);else if($.charCodeAt(0)>255){var j=_.code&&_.code.slice(-1)||"";_.shiftKey||(j=j.toLowerCase()),j&&($=j)}}return z+=$,z.length>1&&(z="<"+z+">"),z}function yo(y){var $=new y.constructor;return Object.keys(y).forEach(function(_){if(_!="insertEnd"){var P=y[_];Array.isArray(P)?P=P.slice():P&&typeof P=="object"&&P.constructor!=Object&&(P=yo(P)),$[_]=P}}),y.sel&&($.sel={head:y.sel.head&&Ue(y.sel.head),anchor:y.sel.anchor&&Ue(y.sel.anchor)}),$}function es(y,$,_){var P=!1,z=wt.maybeInitVimState_(y),j=z.visualBlock||z.wasInVisualBlock,q=y.ace.inMultiSelectMode;if(z.wasInVisualBlock&&!q?z.wasInVisualBlock=!1:q&&z.visualBlock&&(z.wasInVisualBlock=!0),$=="<Esc>"&&!z.insertMode&&!z.visualMode&&q)y.ace.exitMultiSelectMode();else if(j||!q||y.ace.inVirtualSelectionMode)P=wt.handleKey(y,$,_);else{var Y=yo(z),X=z.inputState.changeQueueList||[];y.operation(function(){y.curOp.isVimOp=!0;var re=0;y.ace.forEachSelection(function(){var ue=y.ace.selection;y.state.vim.lastHPos=ue.$desiredColumn==null?ue.lead.column:ue.$desiredColumn,y.state.vim.inputState.changeQueue=X[re];var be=y.getCursor("head"),ke=y.getCursor("anchor"),ye=Qe(be,ke)?0:-1,Ae=Qe(be,ke)?-1:0;be=pe(be,0,ye),ke=pe(ke,0,Ae),y.state.vim.sel.head=be,y.state.vim.sel.anchor=ke,P=kr(y,$,_),ue.$desiredColumn=y.state.vim.lastHPos==-1?null:y.state.vim.lastHPos,y.ace.inVirtualSelectionMode&&(X[re]=y.state.vim.inputState.changeQueue),y.virtualSelectionMode()&&(y.state.vim=yo(Y)),re++}),y.curOp.cursorActivity&&!P&&(y.curOp.cursorActivity=!1),z.status=y.state.vim.status,y.state.vim=z,z.inputState.changeQueueList=X,z.inputState.changeQueue=null},!0)}return P&&!z.visualMode&&!z.insert&&z.visualMode!=y.somethingSelected()&&Es(y,z,!0),P}function to(y,$){$.off("beforeEndOperation",to);var _=$.state.cm.vimCmd;_&&$.execCommand(_.exec?_:_.name,_.args),$.curOp=$.prevOp}var dr=e("../range").Range,Is=e("../lib/event_emitter").EventEmitter,Zr=e("../lib/dom"),ba=e("../lib/oop"),wa=e("../lib/keys"),ts=e("../lib/event"),no=e("../search").Search,Lo=e("../lib/useragent"),ns=e("../search_highlight").SearchHighlight,bo=e("../commands/multi_select_commands"),xa=e("../mode/text").Mode.prototype.tokenRe,wo=e("../ext/hardwrap").hardWrap;e("../multi_select");var Be=function(y){this.ace=y,this.state={},this.marks={},this.options={},this.$uid=0,this.onChange=this.onChange.bind(this),this.onSelectionChange=this.onSelectionChange.bind(this),this.onBeforeEndOperation=this.onBeforeEndOperation.bind(this),this.ace.on("change",this.onChange),this.ace.on("changeSelection",this.onSelectionChange),this.ace.on("beforeEndOperation",this.onBeforeEndOperation)};Be.Pos=function(y,$){if(!(this instanceof De))return new De(y,$);this.line=y,this.ch=$},Be.defineOption=function(y,$,_){},Be.commands={redo:function(y){y.ace.redo()},undo:function(y){y.ace.undo()},newlineAndIndent:function(y){y.ace.insert(`
1403
+ `)},goLineLeft:function(y){y.ace.selection.moveCursorLineStart()},goLineRight:function(y){y.ace.selection.moveCursorLineEnd()}},Be.keyMap={},Be.addClass=Be.rmClass=function(){},Be.e_stop=Be.e_preventDefault=ts.stopEvent,Be.keyName=function(y){var $=wa[y.keyCode]||y.key||"";return $.length==1&&($=$.toUpperCase()),$=ts.getModifierString(y).replace(/(^|-)\w/g,function(_){return _.toUpperCase()})+$,$},Be.keyMap.default=function(y){return function($){var _=$.ace.commands.commandKeyBinding[y.toLowerCase()];return _&&$.ace.execCommand(_)!==!1}},Be.lookupKey=function y($,_,P){_||(_="default"),typeof _=="string"&&(_=Be.keyMap[_]||Be.keyMap.default);var z=typeof _=="function"?_($):_[$];if(z===!1)return"nothing";if(z==="...")return"multi";if(z!=null&&P(z))return"handled";if(_.fallthrough){if(!Array.isArray(_.fallthrough))return y($,_.fallthrough,P);for(var j=0;j<_.fallthrough.length;j++){var q=y($,_.fallthrough[j],P);if(q)return q}}},Be.findMatchingTag=function(y,$){return y.findMatchingTag($)},Be.findEnclosingTag=function(y,$){},Be.signal=function(y,$,_){return y._signal($,_)},Be.on=ts.addListener,Be.off=ts.removeListener,Be.isWordChar=function(y){return y<""?/^\w$/.test(y):(xa.lastIndex=0,xa.test(y))},(function(){ba.implement(Be.prototype,Is),this.destroy=function(){this.ace.off("change",this.onChange),this.ace.off("changeSelection",this.onSelectionChange),this.ace.off("beforeEndOperation",this.onBeforeEndOperation),this.removeOverlay()},this.virtualSelectionMode=function(){return this.ace.inVirtualSelectionMode&&this.ace.selection.index},this.onChange=function(_){this.$lineHandleChanges&&this.$lineHandleChanges.push(_);var P={text:_.action[0]=="i"?_.lines:[]},z=this.curOp=this.curOp||{};z.changeHandlers||(z.changeHandlers=this._eventRegistry.change&&this._eventRegistry.change.slice()),z.lastChange?z.lastChange.next=z.lastChange=P:z.lastChange=z.change=P,this.$updateMarkers(_)},this.onSelectionChange=function(){var _=this.curOp=this.curOp||{};_.cursorActivityHandlers||(_.cursorActivityHandlers=this._eventRegistry.cursorActivity&&this._eventRegistry.cursorActivity.slice()),this.curOp.cursorActivity=!0,this.ace.inMultiSelectMode&&this.ace.keyBinding.removeKeyboardHandler(bo.keyboardHandler)},this.operation=function(_,P){if(!P&&this.curOp||P&&this.curOp&&this.curOp.force)return _();if((P||!this.ace.curOp)&&this.curOp&&this.onBeforeEndOperation(),!this.ace.curOp){var z=this.ace.prevOp;this.ace.startOperation({command:{name:"vim",scrollIntoView:"cursor"}})}var j=this.curOp=this.curOp||{};this.curOp.force=P;var q=_();return this.ace.curOp&&this.ace.curOp.command.name=="vim"&&(this.state.dialog&&(this.ace.curOp.command.scrollIntoView=this.ace.curOp.vimDialogScroll),this.ace.endOperation(),!j.cursorActivity&&!j.lastChange&&z&&(this.ace.prevOp=z)),(P||!this.ace.curOp)&&this.curOp&&this.onBeforeEndOperation(),q},this.onBeforeEndOperation=function(){var _=this.curOp;_&&(_.change&&this.signal("change",_.change,_),_&&_.cursorActivity&&this.signal("cursorActivity",null,_),this.curOp=null)},this.signal=function(_,P,z){var j=z?z[_+"Handlers"]:(this._eventRegistry||{})[_];if(j){j=j.slice();for(var q=0;q<j.length;q++)j[q](this,P)}},this.firstLine=function(){return 0},this.lastLine=function(){return this.ace.session.getLength()-1},this.lineCount=function(){return this.ace.session.getLength()},this.setCursor=function(_,P){typeof _=="object"&&(P=_.ch,_=_.line);var z=!this.curOp&&!this.ace.inVirtualSelectionMode;this.ace.inVirtualSelectionMode||this.ace.exitMultiSelectMode(),this.ace.session.unfold({row:_,column:P}),this.ace.selection.moveTo(_,P),z&&(this.ace.renderer.scrollCursorIntoView(),this.ace.endOperation())},this.getCursor=function(_){var P=this.ace.selection,z=_=="anchor"?P.isEmpty()?P.lead:P.anchor:_=="head"||!_?P.lead:P.getRange()[_];return g(z)},this.listSelections=function(_){var P=this.ace.multiSelect.rangeList.ranges;return!P.length||this.ace.inVirtualSelectionMode?[{anchor:this.getCursor("anchor"),head:this.getCursor("head")}]:P.map(function(z){return{anchor:this.clipPos(g(z.cursor==z.end?z.start:z.end)),head:this.clipPos(g(z.cursor))}},this)},this.setSelections=function(_,P){var z=this.ace.multiSelect,j=_.map(function(re){var ue=f(re.anchor),be=f(re.head),ke=dr.comparePoints(ue,be)<0?new dr.fromPoints(ue,be):new dr.fromPoints(be,ue);return ke.cursor=dr.comparePoints(ke.start,be)?ke.end:ke.start,ke});if(this.ace.inVirtualSelectionMode){this.ace.selection.fromOrientedRange(j[0]);return}P?j[P]&&j.push(j.splice(P,1)[0]):j=j.reverse(),z.toSingleRange(j[0].clone());for(var q=this.ace.session,Y=0;Y<j.length;Y++){var X=q.$clipRangeToDocument(j[Y]);z.addRange(X)}},this.setSelection=function(_,P,z){var j=this.ace.selection;j.moveTo(_.line,_.ch),j.selectTo(P.line,P.ch),z&&z.origin=="*mouse"&&this.onBeforeEndOperation()},this.somethingSelected=function(_){return!this.ace.selection.isEmpty()},this.clipPos=function(_){var P=this.ace.session.$clipPositionToDocument(_.line,_.ch);return g(P)},this.foldCode=function(_){this.ace.session.$toggleFoldWidget(_.line,{})},this.markText=function(_){return{clear:function(){},find:function(){}}},this.$updateMarkers=function(_){var P=_.action=="insert",z=_.start,j=_.end,q=(j.row-z.row)*(P?1:-1),Y=(j.column-z.column)*(P?1:-1);P&&(j=z);for(var X in this.marks){var re=this.marks[X],ue=dr.comparePoints(re,z);if(!(ue<0)){if(ue===0&&P)if(!re.$insertRight)ue=1;else{if(re.bias!=1){re.bias=-1;continue}ue=1}var be=P?ue:dr.comparePoints(re,j);if(be>0){re.row+=q,re.column+=re.row==j.row?Y:0;continue}!P&&be<=0&&(re.row=z.row,re.column=z.column,be===0&&(re.bias=1))}}};var y=function(_,P,z,j){this.cm=_,this.id=P,this.row=z,this.column=j,_.marks[this.id]=this};y.prototype.clear=function(){delete this.cm.marks[this.id]},y.prototype.find=function(){return g(this)},this.setBookmark=function(_,P){var z=new y(this,this.$uid++,_.line,_.ch);return(!P||!P.insertLeft)&&(z.$insertRight=!0),this.marks[z.id]=z,z},this.moveH=function(_,P){if(P=="char"){var z=this.ace.selection;z.clearSelection(),z.moveCursorBy(0,_)}},this.findPosV=function(_,P,z,j){if(z=="page"){var q=this.ace.renderer,Y=q.layerConfig;P*=Math.floor(Y.height/Y.lineHeight),z="line"}if(z=="line"){var X=this.ace.session.documentToScreenPosition(_.line,_.ch);j!=null&&(X.column=j),X.row+=P,X.row=Math.min(Math.max(0,X.row),this.ace.session.getScreenLength()-1);var re=this.ace.session.screenToDocumentPosition(X.row,X.column);return g(re)}debugger},this.charCoords=function(_,P){if(P=="div"||!P){var z=this.ace.session.documentToScreenPosition(_.line,_.ch);return{left:z.column,top:z.row}}if(P=="local"){var j=this.ace.renderer,z=this.ace.session.documentToScreenPosition(_.line,_.ch),q=j.layerConfig.lineHeight,Y=j.layerConfig.characterWidth,X=q*z.row;return{left:z.column*Y,top:X,bottom:X+q}}},this.coordsChar=function(_,P){var z=this.ace.renderer;if(P=="local"){var j=Math.max(0,Math.floor(_.top/z.lineHeight)),q=Math.max(0,Math.floor(_.left/z.characterWidth)),Y=z.session.screenToDocumentPosition(j,q);return g(Y)}if(P=="div")throw"not implemented"},this.getSearchCursor=function(_,P,z){var j=!1,q=!1;_ instanceof RegExp&&!_.global&&(j=!_.ignoreCase,_=_.source,q=!0),_=="\\n"&&(_=`
1404
+ `,q=!1);var Y=new no;P.ch==null&&(P.ch=Number.MAX_VALUE);var X={row:P.line,column:P.ch},re=this,ue=null;return{findNext:function(){return this.find(!1)},findPrevious:function(){return this.find(!0)},find:function(be){Y.setOptions({needle:_,caseSensitive:j,wrap:!1,backwards:be,regExp:q,start:ue||X});var ke=Y.find(re.ace.session);return ue=ke,ue&&[!ue.isEmpty()]},from:function(){return ue&&g(ue.start)},to:function(){return ue&&g(ue.end)},replace:function(be){ue&&(ue.end=re.ace.session.doc.replace(ue,be))}}},this.scrollTo=function(_,P){var z=this.ace.renderer,j=z.layerConfig,q=j.maxHeight;q-=(z.$size.scrollerHeight-z.lineHeight)*z.$scrollPastEnd,P!=null&&this.ace.session.setScrollTop(Math.max(0,Math.min(P,q))),_!=null&&this.ace.session.setScrollLeft(Math.max(0,Math.min(_,j.width)))},this.scrollInfo=function(){return 0},this.scrollIntoView=function(_,P){if(_){var z=this.ace.renderer,j={top:0,bottom:P};z.scrollCursorIntoView(f(_),z.lineHeight*2/z.$size.scrollerHeight,j)}},this.getLine=function(_){return this.ace.session.getLine(_)},this.getRange=function(_,P){return this.ace.session.getTextRange(new dr(_.line,_.ch,P.line,P.ch))},this.replaceRange=function(_,P,z){z||(z=P);var j=new dr(P.line,P.ch,z.line,z.ch);return this.ace.session.$clipRangeToDocument(j),this.ace.session.replace(j,_)},this.replaceSelection=this.replaceSelections=function(_){var P=Array.isArray(_)&&_,z=this.ace.selection;if(this.ace.inVirtualSelectionMode){this.ace.session.replace(z.getRange(),P?_[0]||"":_);return}z.inVirtualSelectionMode=!0;var j=z.rangeList.ranges;j.length||(j=[this.ace.multiSelect.getRange()]);for(var q=j.length;q--;)this.ace.session.replace(j[q],P?_[q]||"":_);z.inVirtualSelectionMode=!1},this.getSelection=function(){return this.ace.getSelectedText()},this.getSelections=function(){return this.listSelections().map(function(_){return this.getRange(_.anchor,_.head)},this)},this.getInputField=function(){return this.ace.textInput.getElement()},this.getWrapperElement=function(){return this.ace.container};var $={indentWithTabs:"useSoftTabs",indentUnit:"tabSize",tabSize:"tabSize",firstLineNumber:"firstLineNumber",readOnly:"readOnly"};this.setOption=function(_,P){switch(this.state[_]=P,_){case"indentWithTabs":_=$[_],P=!P;break;case"keyMap":this.state.$keyMap=P;return;default:_=$[_]}_&&this.ace.setOption(_,P)},this.getOption=function(_){var P,z=$[_];switch(z&&(P=this.ace.getOption(z)),_){case"indentWithTabs":return _=$[_],!P;case"keyMap":return this.state.$keyMap||"vim"}return z?P:this.state[_]},this.toggleOverwrite=function(_){return this.state.overwrite=_,this.ace.setOverwrite(_)},this.addOverlay=function(_){if(!this.$searchHighlight||!this.$searchHighlight.session){var P=new ns(null,"ace_highlight-marker","text"),z=this.ace.session.addDynamicMarker(P);P.id=z.id,P.session=this.ace.session,P.destroy=function(q){P.session.off("change",P.updateOnChange),P.session.off("changeEditor",P.destroy),P.session.removeMarker(P.id),P.session=null},P.updateOnChange=function(q){var Y=q.start.row;Y==q.end.row?P.cache[Y]=void 0:P.cache.splice(Y,P.cache.length)},P.session.on("changeEditor",P.destroy),P.session.on("change",P.updateOnChange)}var j=new RegExp(_.query.source,"gmi");this.$searchHighlight=_.highlight=P,this.$searchHighlight.setRegexp(j),this.ace.renderer.updateBackMarkers()},this.removeOverlay=function(_){this.$searchHighlight&&this.$searchHighlight.session&&this.$searchHighlight.destroy()},this.getScrollInfo=function(){var _=this.ace.renderer,P=_.layerConfig;return{left:_.scrollLeft,top:_.scrollTop,height:P.maxHeight,width:P.width,clientHeight:P.height,clientWidth:P.width}},this.getValue=function(){return this.ace.getValue()},this.setValue=function(_){return this.ace.setValue(_,-1)},this.getTokenTypeAt=function(_){var P=this.ace.session.getTokenAt(_.line,_.ch);return P&&/comment|string/.test(P.type)?"string":""},this.findMatchingBracket=function(_){var P=this.ace.session.findMatchingBracket(f(_));return{to:P&&g(P)}},this.findMatchingTag=function(_){var P=this.ace.session.getMatchingTags(f(_));if(P)return{open:{from:g(P.openTag.start),to:g(P.openTag.end)},close:{from:g(P.closeTag.start),to:g(P.closeTag.end)}}},this.indentLine=function(_,P){P===!0?this.ace.session.indentRows(_,_," "):P===!1&&this.ace.session.outdentRows(new dr(_,0,_,0))},this.indexFromPos=function(_){return this.ace.session.doc.positionToIndex(f(_))},this.posFromIndex=function(_){return g(this.ace.session.doc.indexToPosition(_))},this.focus=function(_){return this.ace.textInput.focus()},this.blur=function(_){return this.ace.blur()},this.defaultTextHeight=function(_){return this.ace.renderer.layerConfig.lineHeight},this.scanForBracket=function(_,P,z,j){var q=j.bracketRegex.source,Y=/paren|text|operator|tag/;if(P==1)var X=this.ace.session.$findClosingBracket(q.slice(1,2),f(_),Y);else{var X=this.ace.session.$findOpeningBracket(q.slice(-2,-1),{row:_.line,column:_.ch+1},Y);!X&&j.bracketRegex&&j.bracketRegex.test(this.getLine(_.line)[_.ch-1])&&(X={row:_.line,column:_.ch-1})}return X&&{pos:g(X)}},this.refresh=function(){return this.ace.resize(!0)},this.getMode=function(){return{name:this.getOption("mode")}},this.execCommand=function(_){if(Be.commands.hasOwnProperty(_))return Be.commands[_](this);if(_=="indentAuto")return this.ace.execCommand("autoindent");console.log(_+" is not implemented")},this.getLineNumber=function(_){var P=this.$lineHandleChanges;if(!P)return null;for(var z=_.row,j=0;j<P.length;j++){var q=P[j];if(q.start.row!=q.end.row){if(q.action[0]=="i")q.start.row<z&&(z+=q.end.row-q.start.row);else if(q.start.row<z){if(z<q.end.row||z==q.end.row&&q.start.column>0)return null;z-=q.end.row-q.start.row}}}return z},this.getLineHandle=function(_){return this.$lineHandleChanges||(this.$lineHandleChanges=[]),{text:this.ace.session.getLine(_),row:_}},this.releaseLineHandles=function(){this.$lineHandleChanges=void 0},this.getLastEditEnd=function(){var _=this.ace.session.$undoManager;if(_&&_.$lastDelta)return g(_.$lastDelta.end)}}).call(Be.prototype);var Ls=Be.StringStream=function(y,$){this.pos=this.start=0,this.string=y,this.tabSize=$||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0};Ls.prototype={eol:function(){return this.pos>=this.string.length},sol:function(){return this.pos==this.lineStart},peek:function(){return this.string.charAt(this.pos)||void 0},next:function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},eat:function(y){var $=this.string.charAt(this.pos);if(typeof y=="string")var _=$==y;else var _=$&&(y.test?y.test($):y($));if(_)return++this.pos,$},eatWhile:function(y){for(var $=this.pos;this.eat(y););return this.pos>$},eatSpace:function(){for(var y=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>y},skipToEnd:function(){this.pos=this.string.length},skipTo:function(y){var $=this.string.indexOf(y,this.pos);if($>-1)return this.pos=$,!0},backUp:function(y){this.pos-=y},column:function(){throw"not implemented"},indentation:function(){throw"not implemented"},match:function(y,$,_){if(typeof y!="string"){var P=this.string.slice(this.pos).match(y);return P&&P.index>0?null:(P&&$!==!1&&(this.pos+=P[0].length),P)}var z=function(q){return _?q.toLowerCase():q},j=this.string.substr(this.pos,y.length);if(z(j)==z(y))return $!==!1&&(this.pos+=y.length),!0},current:function(){return this.string.slice(this.start,this.pos)},hideFirstChars:function(y,$){this.lineStart+=y;try{return $()}finally{this.lineStart-=y}}},Be.defineExtension=function(y,$){Be.prototype[y]=$},Zr.importCssString(`.normal-mode .ace_cursor{
1405
+ border: none;
1406
+ background-color: rgba(255,0,0,0.5);
1407
+ }
1408
+ .normal-mode .ace_hidden-cursors .ace_cursor{
1409
+ background-color: transparent;
1410
+ border: 1px solid red;
1411
+ opacity: 0.7
1412
+ }
1413
+ .ace_dialog {
1414
+ position: absolute;
1415
+ left: 0; right: 0;
1416
+ background: inherit;
1417
+ z-index: 15;
1418
+ padding: .1em .8em;
1419
+ overflow: hidden;
1420
+ color: inherit;
1421
+ }
1422
+ .ace_dialog-top {
1423
+ border-bottom: 1px solid #444;
1424
+ top: 0;
1425
+ }
1426
+ .ace_dialog-bottom {
1427
+ border-top: 1px solid #444;
1428
+ bottom: 0;
1429
+ }
1430
+ .ace_dialog input {
1431
+ border: none;
1432
+ outline: none;
1433
+ background: transparent;
1434
+ width: 20em;
1435
+ color: inherit;
1436
+ font-family: monospace;
1437
+ }`,"vimMode",!1),(function(){function y(_,P,z){var j=_.ace.container,q;return q=j.appendChild(document.createElement("div")),z?q.className="ace_dialog ace_dialog-bottom":q.className="ace_dialog ace_dialog-top",typeof P=="string"?q.innerHTML=P:q.appendChild(P),q}function $(_,P){_.state.currentNotificationClose&&_.state.currentNotificationClose(),_.state.currentNotificationClose=P}Be.defineExtension("openDialog",function(_,P,z){function j(be){if(typeof be=="string")re.value=be;else{if(Y||be&&be.type=="blur"&&document.activeElement===re)return;X.state.dialog==q&&(X.state.dialog=null,X.focus()),Y=!0,q.remove(),z.onClose&&z.onClose(q);var ke=X;ke.state.vim&&(ke.state.vim.status=null,ke.ace._signal("changeStatus"),ke.ace.renderer.$loop.schedule(ke.ace.renderer.CHANGE_CURSOR))}}if(!this.virtualSelectionMode()){z||(z={}),$(this,null);var q=y(this,_,z.bottom),Y=!1,X=this;this.state.dialog=q;var re=q.getElementsByTagName("input")[0],ue;return re?(z.value&&(re.value=z.value,z.selectValueOnOpen!==!1&&re.select()),z.onInput&&Be.on(re,"input",function(be){z.onInput(be,re.value,j)}),z.onKeyUp&&Be.on(re,"keyup",function(be){z.onKeyUp(be,re.value,j)}),Be.on(re,"keydown",function(be){z&&z.onKeyDown&&z.onKeyDown(be,re.value,j)||(be.keyCode==13&&P(re.value),(be.keyCode==27||z.closeOnEnter!==!1&&be.keyCode==13)&&(Be.e_stop(be),j()))}),z.closeOnBlur!==!1&&Be.on(re,"blur",j),re.focus()):(ue=q.getElementsByTagName("button")[0])&&(Be.on(ue,"click",function(){j(),X.focus()}),z.closeOnBlur!==!1&&Be.on(ue,"blur",j),ue.focus()),j}}),Be.defineExtension("openNotification",function(_,P){function z(){q||(q=!0,clearTimeout(Y),j.remove())}if(!this.virtualSelectionMode()){$(this,z);var j=y(this,_,P&&P.bottom),q=!1,Y,X=P&&typeof P.duration<"u"?P.duration:5e3;return Be.on(j,"click",function(re){Be.e_preventDefault(re),z()}),X&&(Y=setTimeout(z,X)),z}})})();var De=Be.Pos,Pn=[{keys:"<Left>",type:"keyToKey",toKeys:"h"},{keys:"<Right>",type:"keyToKey",toKeys:"l"},{keys:"<Up>",type:"keyToKey",toKeys:"k"},{keys:"<Down>",type:"keyToKey",toKeys:"j"},{keys:"g<Up>",type:"keyToKey",toKeys:"gk"},{keys:"g<Down>",type:"keyToKey",toKeys:"gj"},{keys:"<Space>",type:"keyToKey",toKeys:"l"},{keys:"<BS>",type:"keyToKey",toKeys:"h"},{keys:"<Del>",type:"keyToKey",toKeys:"x"},{keys:"<C-Space>",type:"keyToKey",toKeys:"W"},{keys:"<C-BS>",type:"keyToKey",toKeys:"B"},{keys:"<S-Space>",type:"keyToKey",toKeys:"w"},{keys:"<S-BS>",type:"keyToKey",toKeys:"b"},{keys:"<C-n>",type:"keyToKey",toKeys:"j"},{keys:"<C-p>",type:"keyToKey",toKeys:"k"},{keys:"<C-[>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-c>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-[>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"<C-c>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"<C-Esc>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-Esc>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"s",type:"keyToKey",toKeys:"cl",context:"normal"},{keys:"s",type:"keyToKey",toKeys:"c",context:"visual"},{keys:"S",type:"keyToKey",toKeys:"cc",context:"normal"},{keys:"S",type:"keyToKey",toKeys:"VdO",context:"visual"},{keys:"<Home>",type:"keyToKey",toKeys:"0"},{keys:"<End>",type:"keyToKey",toKeys:"$"},{keys:"<PageUp>",type:"keyToKey",toKeys:"<C-b>"},{keys:"<PageDown>",type:"keyToKey",toKeys:"<C-f>"},{keys:"<CR>",type:"keyToKey",toKeys:"j^",context:"normal"},{keys:"<Ins>",type:"keyToKey",toKeys:"i",context:"normal"},{keys:"<Ins>",type:"action",action:"toggleOverwrite",context:"insert"},{keys:"H",type:"motion",motion:"moveToTopLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"M",type:"motion",motion:"moveToMiddleLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"L",type:"motion",motion:"moveToBottomLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"h",type:"motion",motion:"moveByCharacters",motionArgs:{forward:!1}},{keys:"l",type:"motion",motion:"moveByCharacters",motionArgs:{forward:!0}},{keys:"j",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,linewise:!0}},{keys:"k",type:"motion",motion:"moveByLines",motionArgs:{forward:!1,linewise:!0}},{keys:"gj",type:"motion",motion:"moveByDisplayLines",motionArgs:{forward:!0}},{keys:"gk",type:"motion",motion:"moveByDisplayLines",motionArgs:{forward:!1}},{keys:"w",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!1}},{keys:"W",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!1,bigWord:!0}},{keys:"e",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!0,inclusive:!0}},{keys:"E",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!0,bigWord:!0,inclusive:!0}},{keys:"b",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1}},{keys:"B",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1,bigWord:!0}},{keys:"ge",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!0,inclusive:!0}},{keys:"gE",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!0,bigWord:!0,inclusive:!0}},{keys:"{",type:"motion",motion:"moveByParagraph",motionArgs:{forward:!1,toJumplist:!0}},{keys:"}",type:"motion",motion:"moveByParagraph",motionArgs:{forward:!0,toJumplist:!0}},{keys:"(",type:"motion",motion:"moveBySentence",motionArgs:{forward:!1}},{keys:")",type:"motion",motion:"moveBySentence",motionArgs:{forward:!0}},{keys:"<C-f>",type:"motion",motion:"moveByPage",motionArgs:{forward:!0}},{keys:"<C-b>",type:"motion",motion:"moveByPage",motionArgs:{forward:!1}},{keys:"<C-d>",type:"motion",motion:"moveByScroll",motionArgs:{forward:!0,explicitRepeat:!0}},{keys:"<C-u>",type:"motion",motion:"moveByScroll",motionArgs:{forward:!1,explicitRepeat:!0}},{keys:"gg",type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!1,explicitRepeat:!0,linewise:!0,toJumplist:!0}},{keys:"G",type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!0,explicitRepeat:!0,linewise:!0,toJumplist:!0}},{keys:"g$",type:"motion",motion:"moveToEndOfDisplayLine"},{keys:"g^",type:"motion",motion:"moveToStartOfDisplayLine"},{keys:"g0",type:"motion",motion:"moveToStartOfDisplayLine"},{keys:"0",type:"motion",motion:"moveToStartOfLine"},{keys:"^",type:"motion",motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"+",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,toFirstChar:!0}},{keys:"-",type:"motion",motion:"moveByLines",motionArgs:{forward:!1,toFirstChar:!0}},{keys:"_",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,toFirstChar:!0,repeatOffset:-1}},{keys:"$",type:"motion",motion:"moveToEol",motionArgs:{inclusive:!0}},{keys:"%",type:"motion",motion:"moveToMatchedSymbol",motionArgs:{inclusive:!0,toJumplist:!0}},{keys:"f<character>",type:"motion",motion:"moveToCharacter",motionArgs:{forward:!0,inclusive:!0}},{keys:"F<character>",type:"motion",motion:"moveToCharacter",motionArgs:{forward:!1}},{keys:"t<character>",type:"motion",motion:"moveTillCharacter",motionArgs:{forward:!0,inclusive:!0}},{keys:"T<character>",type:"motion",motion:"moveTillCharacter",motionArgs:{forward:!1}},{keys:";",type:"motion",motion:"repeatLastCharacterSearch",motionArgs:{forward:!0}},{keys:",",type:"motion",motion:"repeatLastCharacterSearch",motionArgs:{forward:!1}},{keys:"'<register>",type:"motion",motion:"goToMark",motionArgs:{toJumplist:!0,linewise:!0}},{keys:"`<register>",type:"motion",motion:"goToMark",motionArgs:{toJumplist:!0}},{keys:"]`",type:"motion",motion:"jumpToMark",motionArgs:{forward:!0}},{keys:"[`",type:"motion",motion:"jumpToMark",motionArgs:{forward:!1}},{keys:"]'",type:"motion",motion:"jumpToMark",motionArgs:{forward:!0,linewise:!0}},{keys:"['",type:"motion",motion:"jumpToMark",motionArgs:{forward:!1,linewise:!0}},{keys:"]p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!0,isEdit:!0,matchIndent:!0}},{keys:"[p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!1,isEdit:!0,matchIndent:!0}},{keys:"]<character>",type:"motion",motion:"moveToSymbol",motionArgs:{forward:!0,toJumplist:!0}},{keys:"[<character>",type:"motion",motion:"moveToSymbol",motionArgs:{forward:!1,toJumplist:!0}},{keys:"|",type:"motion",motion:"moveToColumn"},{keys:"o",type:"motion",motion:"moveToOtherHighlightedEnd",context:"visual"},{keys:"O",type:"motion",motion:"moveToOtherHighlightedEnd",motionArgs:{sameLine:!0},context:"visual"},{keys:"d",type:"operator",operator:"delete"},{keys:"y",type:"operator",operator:"yank"},{keys:"c",type:"operator",operator:"change"},{keys:"=",type:"operator",operator:"indentAuto"},{keys:">",type:"operator",operator:"indent",operatorArgs:{indentRight:!0}},{keys:"<",type:"operator",operator:"indent",operatorArgs:{indentRight:!1}},{keys:"g~",type:"operator",operator:"changeCase"},{keys:"gu",type:"operator",operator:"changeCase",operatorArgs:{toLower:!0},isEdit:!0},{keys:"gU",type:"operator",operator:"changeCase",operatorArgs:{toLower:!1},isEdit:!0},{keys:"n",type:"motion",motion:"findNext",motionArgs:{forward:!0,toJumplist:!0}},{keys:"N",type:"motion",motion:"findNext",motionArgs:{forward:!1,toJumplist:!0}},{keys:"gn",type:"motion",motion:"findAndSelectNextInclusive",motionArgs:{forward:!0}},{keys:"gN",type:"motion",motion:"findAndSelectNextInclusive",motionArgs:{forward:!1}},{keys:"gq",type:"operator",operator:"hardWrap"},{keys:"gw",type:"operator",operator:"hardWrap",operatorArgs:{keepCursor:!0}},{keys:"x",type:"operatorMotion",operator:"delete",motion:"moveByCharacters",motionArgs:{forward:!0},operatorMotionArgs:{visualLine:!1}},{keys:"X",type:"operatorMotion",operator:"delete",motion:"moveByCharacters",motionArgs:{forward:!1},operatorMotionArgs:{visualLine:!0}},{keys:"D",type:"operatorMotion",operator:"delete",motion:"moveToEol",motionArgs:{inclusive:!0},context:"normal"},{keys:"D",type:"operator",operator:"delete",operatorArgs:{linewise:!0},context:"visual"},{keys:"Y",type:"operatorMotion",operator:"yank",motion:"expandToLine",motionArgs:{linewise:!0},context:"normal"},{keys:"Y",type:"operator",operator:"yank",operatorArgs:{linewise:!0},context:"visual"},{keys:"C",type:"operatorMotion",operator:"change",motion:"moveToEol",motionArgs:{inclusive:!0},context:"normal"},{keys:"C",type:"operator",operator:"change",operatorArgs:{linewise:!0},context:"visual"},{keys:"~",type:"operatorMotion",operator:"changeCase",motion:"moveByCharacters",motionArgs:{forward:!0},operatorArgs:{shouldMoveCursor:!0},context:"normal"},{keys:"~",type:"operator",operator:"changeCase",context:"visual"},{keys:"<C-u>",type:"operatorMotion",operator:"delete",motion:"moveToStartOfLine",context:"insert"},{keys:"<C-w>",type:"operatorMotion",operator:"delete",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1},context:"insert"},{keys:"<C-w>",type:"idle",context:"normal"},{keys:"<C-i>",type:"action",action:"jumpListWalk",actionArgs:{forward:!0}},{keys:"<C-o>",type:"action",action:"jumpListWalk",actionArgs:{forward:!1}},{keys:"<C-e>",type:"action",action:"scroll",actionArgs:{forward:!0,linewise:!0}},{keys:"<C-y>",type:"action",action:"scroll",actionArgs:{forward:!1,linewise:!0}},{keys:"a",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"charAfter"},context:"normal"},{keys:"A",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"eol"},context:"normal"},{keys:"A",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"endOfSelectedArea"},context:"visual"},{keys:"i",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"inplace"},context:"normal"},{keys:"gi",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"lastEdit"},context:"normal"},{keys:"I",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"firstNonBlank"},context:"normal"},{keys:"gI",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"bol"},context:"normal"},{keys:"I",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"startOfSelectedArea"},context:"visual"},{keys:"o",type:"action",action:"newLineAndEnterInsertMode",isEdit:!0,interlaceInsertRepeat:!0,actionArgs:{after:!0},context:"normal"},{keys:"O",type:"action",action:"newLineAndEnterInsertMode",isEdit:!0,interlaceInsertRepeat:!0,actionArgs:{after:!1},context:"normal"},{keys:"v",type:"action",action:"toggleVisualMode"},{keys:"V",type:"action",action:"toggleVisualMode",actionArgs:{linewise:!0}},{keys:"<C-v>",type:"action",action:"toggleVisualMode",actionArgs:{blockwise:!0}},{keys:"<C-q>",type:"action",action:"toggleVisualMode",actionArgs:{blockwise:!0}},{keys:"gv",type:"action",action:"reselectLastSelection"},{keys:"J",type:"action",action:"joinLines",isEdit:!0},{keys:"gJ",type:"action",action:"joinLines",actionArgs:{keepSpaces:!0},isEdit:!0},{keys:"p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!0,isEdit:!0}},{keys:"P",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!1,isEdit:!0}},{keys:"r<character>",type:"action",action:"replace",isEdit:!0},{keys:"@<register>",type:"action",action:"replayMacro"},{keys:"q<register>",type:"action",action:"enterMacroRecordMode"},{keys:"R",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{replace:!0},context:"normal"},{keys:"R",type:"operator",operator:"change",operatorArgs:{linewise:!0,fullLine:!0},context:"visual",exitVisualBlock:!0},{keys:"u",type:"action",action:"undo",context:"normal"},{keys:"u",type:"operator",operator:"changeCase",operatorArgs:{toLower:!0},context:"visual",isEdit:!0},{keys:"U",type:"operator",operator:"changeCase",operatorArgs:{toLower:!1},context:"visual",isEdit:!0},{keys:"<C-r>",type:"action",action:"redo"},{keys:"m<register>",type:"action",action:"setMark"},{keys:'"<register>',type:"action",action:"setRegister"},{keys:"<C-r><register>",type:"action",action:"insertRegister",context:"insert",isEdit:!0},{keys:"<C-o>",type:"action",action:"oneNormalCommand",context:"insert"},{keys:"zz",type:"action",action:"scrollToCursor",actionArgs:{position:"center"}},{keys:"z.",type:"action",action:"scrollToCursor",actionArgs:{position:"center"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"zt",type:"action",action:"scrollToCursor",actionArgs:{position:"top"}},{keys:"z<CR>",type:"action",action:"scrollToCursor",actionArgs:{position:"top"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"zb",type:"action",action:"scrollToCursor",actionArgs:{position:"bottom"}},{keys:"z-",type:"action",action:"scrollToCursor",actionArgs:{position:"bottom"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:".",type:"action",action:"repeatLastEdit"},{keys:"<C-a>",type:"action",action:"incrementNumberToken",isEdit:!0,actionArgs:{increase:!0,backtrack:!1}},{keys:"<C-x>",type:"action",action:"incrementNumberToken",isEdit:!0,actionArgs:{increase:!1,backtrack:!1}},{keys:"<C-t>",type:"action",action:"indent",actionArgs:{indentRight:!0},context:"insert"},{keys:"<C-d>",type:"action",action:"indent",actionArgs:{indentRight:!1},context:"insert"},{keys:"a<register>",type:"motion",motion:"textObjectManipulation"},{keys:"i<register>",type:"motion",motion:"textObjectManipulation",motionArgs:{textObjectInner:!0}},{keys:"/",type:"search",searchArgs:{forward:!0,querySrc:"prompt",toJumplist:!0}},{keys:"?",type:"search",searchArgs:{forward:!1,querySrc:"prompt",toJumplist:!0}},{keys:"*",type:"search",searchArgs:{forward:!0,querySrc:"wordUnderCursor",wholeWordOnly:!0,toJumplist:!0}},{keys:"#",type:"search",searchArgs:{forward:!1,querySrc:"wordUnderCursor",wholeWordOnly:!0,toJumplist:!0}},{keys:"g*",type:"search",searchArgs:{forward:!0,querySrc:"wordUnderCursor",toJumplist:!0}},{keys:"g#",type:"search",searchArgs:{forward:!1,querySrc:"wordUnderCursor",toJumplist:!0}},{keys:":",type:"ex"}],Oo=Pn.length,ro=[{name:"colorscheme",shortName:"colo"},{name:"map"},{name:"imap",shortName:"im"},{name:"nmap",shortName:"nm"},{name:"vmap",shortName:"vm"},{name:"omap",shortName:"om"},{name:"noremap",shortName:"no"},{name:"nnoremap",shortName:"nn"},{name:"vnoremap",shortName:"vn"},{name:"inoremap",shortName:"ino"},{name:"onoremap",shortName:"ono"},{name:"unmap"},{name:"mapclear",shortName:"mapc"},{name:"nmapclear",shortName:"nmapc"},{name:"vmapclear",shortName:"vmapc"},{name:"imapclear",shortName:"imapc"},{name:"omapclear",shortName:"omapc"},{name:"write",shortName:"w"},{name:"undo",shortName:"u"},{name:"redo",shortName:"red"},{name:"set",shortName:"se"},{name:"setlocal",shortName:"setl"},{name:"setglobal",shortName:"setg"},{name:"sort",shortName:"sor"},{name:"substitute",shortName:"s",possiblyAsync:!0},{name:"startinsert",shortName:"start"},{name:"nohlsearch",shortName:"noh"},{name:"yank",shortName:"y"},{name:"delmarks",shortName:"delm"},{name:"registers",shortName:"reg",excludeFromCommandHistory:!0},{name:"vglobal",shortName:"v"},{name:"delete",shortName:"d"},{name:"join",shortName:"j"},{name:"normal",shortName:"norm"},{name:"global",shortName:"g"}],Fn=O(""),Ca=/[\d]/,No=[Be.isWordChar,function(y){return y&&!Be.isWordChar(y)&&!/\s/.test(y)}],Di=[function(y){return/\S/.test(y)}],xo=["<",">"],Os=["-",'"',".",":","_","/","+"],nn=/^\w$/,ct;try{ct=new RegExp("^[\\p{Lu}]$","u")}catch{ct=/^[A-Z]$/}var qt={};M("filetype",void 0,"string",["ft"],function(y,$){if($!==void 0){if(y===void 0){var _=$.getOption("mode");return _=="null"?"":_}var _=y==""?"null":y;$.setOption("mode",_)}}),M("textwidth",80,"number",["tw"],function(y,$){if($!==void 0){if(y===void 0){var _=$.getOption("textwidth");return _}var P=Math.round(y);P>1&&$.setOption("textwidth",P)}});var Pi=function(){function y(X,re,ue){function be(Oe){var Ie=++z%P,Ge=Y[Ie];Ge&&Ge.clear(),Y[Ie]=X.setBookmark(Oe)}var ke=z%P,ye=Y[ke];if(ye){var Ae=ye.find();Ae&&!ot(Ae,re)&&be(re)}else be(re);be(ue),j=z,q=z-P+1,q<0&&(q=0)}function $(X,re){z+=re,z>j?z=j:z<q&&(z=q);var ue=Y[(P+z)%P];if(ue&&!ue.find()){var be=re>0?1:-1,ke,ye=X.getCursor();do if(z+=be,ue=Y[(P+z)%P],ue&&(ke=ue.find())&&!ot(ye,ke))break;while(z<j&&z>q)}return ue}function _(X,re){var ue=z,be=$(X,re);return z=ue,be&&be.find()}var P=100,z=-1,j=0,q=0,Y=new Array(P);return{cachedCursor:void 0,add:y,find:_,move:$}},Un=function(y){return y?{changes:y.changes,expectCursorActivityForChange:y.expectCursorActivityForChange}:{changes:[],expectCursorActivityForChange:!1}};C.prototype={exitMacroRecordMode:function(){var y=je.macroModeState;y.onRecordingDone&&y.onRecordingDone(),y.onRecordingDone=void 0,y.isRecording=!1},enterMacroRecordMode:function(y,$){var _=je.registerController.getRegister($);if(_){if(_.clear(),this.latestRegister=$,y.openDialog){var P=_r("span",{class:"cm-vim-message"},"recording @"+$);this.onRecordingDone=y.openDialog(P,null,{bottom:!0})}this.isRecording=!0}}};var je,wn,wt={enterVimMode:u,leaveVimMode:d,buildKeyMap:function(){},getRegisterController:function(){return je.registerController},resetVimGlobalState_:D,getVimGlobalState_:function(){return je},maybeInitVimState_:L,suppressErrorLogging:!1,InsertModeKey:Xo,map:function(y,$,_){zr.map(y,$,_)},unmap:function(y,$){return zr.unmap(y,$)},noremap:function(y,$,_){zr.map(y,$,_,!0)},mapclear:function(y){var $=Pn.length,_=Oo,P=Pn.slice(0,$-_);if(Pn=Pn.slice($-_),y)for(var z=P.length-1;z>=0;z--){var j=P[z];if(y!==j.context)if(j.context)this._mapCommand(j);else{var q=["normal","insert","visual"];for(var Y in q)if(q[Y]!==y){var X={};for(var re in j)X[re]=j[re];X.context=q[Y],this._mapCommand(X)}}}},langmap:F,vimKeyFromEvent:W,setOption:R,getOption:k,defineOption:M,defineEx:function(y,$,_){if(!$)$=y;else if(y.indexOf($)!==0)throw new Error('(Vim.defineEx) "'+$+'" is not a prefix of "'+y+'", command not registered');fr[y]=_,zr.commandMap_[$]={name:y,shortName:$,type:"api"}},handleKey:function(y,$,_){var P=this.findKey(y,$,_);if(typeof P=="function")return P()},multiSelectHandleKey:es,findKey:function(y,$,_){function P(){var re=je.macroModeState;if(re.isRecording){if($=="q")return re.exitMacroRecordMode(),A(y),!0;_!="mapping"&&ci(re,$)}}function z(){if($=="<Esc>"){if(Y.visualMode)vn(y);else{if(!Y.insertMode)return;Mt(y)}return A(y),!0}}function j(){if(z())return!0;Y.inputState.keyBuffer.push($);var re=Y.inputState.keyBuffer.join(""),ue=$.length==1,be=Ai.matchCommand(re,Pn,Y.inputState,"insert"),ke=Y.inputState.changeQueue;if(be.type=="none")return A(y),!1;if(be.type=="partial"){if(be.expectLiteralNext&&(Y.expectLiteralNext=!0),wn&&window.clearTimeout(wn),wn=ue&&window.setTimeout(function(){Y.insertMode&&Y.inputState.keyBuffer.length&&A(y)},k("insertModeEscKeysTimeout")),ue){var ye=y.listSelections();(!ke||ke.removed.length!=ye.length)&&(ke=Y.inputState.changeQueue=new N),ke.inserted+=$;for(var Ae=0;Ae<ye.length;Ae++){var Oe=lt(ye[Ae].anchor,ye[Ae].head),Ie=Tt(ye[Ae].anchor,ye[Ae].head),Ge=y.getRange(Oe,y.state.overwrite?pe(Ie,0,1):Ie);ke.removed[Ae]=(ke.removed[Ae]||"")+Ge}}return!ue}if(Y.expectLiteralNext=!1,wn&&window.clearTimeout(wn),be.command&&ke){for(var ye=y.listSelections(),Ae=0;Ae<ye.length;Ae++){var ut=ye[Ae].head;y.replaceRange(ke.removed[Ae]||"",pe(ut,0,-ke.inserted.length),ut,"+input")}je.macroModeState.lastInsertModeChanges.changes.pop()}return be.command||A(y),be.command}function q(){if(P()||z())return!0;Y.inputState.keyBuffer.push($);var re=Y.inputState.keyBuffer.join("");if(/^[1-9]\d*$/.test(re))return!0;var ue=/^(\d*)(.*)$/.exec(re);if(!ue)return A(y),!1;var be=Y.visualMode?"visual":"normal",ke=ue[2]||ue[1];Y.inputState.operatorShortcut&&Y.inputState.operatorShortcut.slice(-1)==ke&&(ke=Y.inputState.operatorShortcut);var ye=Ai.matchCommand(ke,Pn,Y.inputState,be);return ye.type=="none"?(A(y),!1):ye.type=="partial"?(ye.expectLiteralNext&&(Y.expectLiteralNext=!0),!0):ye.type=="clear"?(A(y),!0):(Y.expectLiteralNext=!1,Y.inputState.keyBuffer.length=0,ue=/^(\d*)(.*)$/.exec(re),ue[1]&&ue[1]!="0"&&Y.inputState.pushRepeatDigit(ue[1]),ye.command)}var Y=L(y),X;return Y.insertMode?X=j():X=q(),X===!1?!Y.insertMode&&$.length===1?function(){return!0}:void 0:X===!0?function(){return!0}:function(){if(!((X.operator||X.isEdit)&&y.getOption("readOnly")))return y.operation(function(){y.curOp.isVimOp=!0;try{X.type=="keyToKey"?T(y,X.toKeys,X):Ai.processCommand(y,Y,X)}catch(re){throw y.state.vim=void 0,L(y),wt.suppressErrorLogging||console.log(re),re}return!0})}},handleEx:function(y,$){zr.processCommand(y,$)},defineMotion:ne,defineAction:se,defineOperator:ee,mapCommand:xr,_mapCommand:wr,defineRegister:U,exitVisualMode:vn,exitInsertMode:Mt},Pr=[],Fi=!1,zt,Fr={Return:"CR",Backspace:"BS",Delete:"Del",Escape:"Esc",Insert:"Ins",ArrowLeft:"Left",ArrowRight:"Right",ArrowUp:"Up",ArrowDown:"Down",Enter:"CR"," ":"Space"},ir={Shift:1,Alt:1,Command:1,Control:1,CapsLock:1,AltGraph:1,Dead:1,Unidentified:1},io={};"Left|Right|Up|Down|End|Home".split("|").concat(Object.keys(Fr)).forEach(function(y){io[(Fr[y]||"").toLowerCase()]=io[y.toLowerCase()]=y}),M("langmap",void 0,"string",["lmap"],function(y,$){if(y===void 0)return Fn.string;F(y)}),S.prototype.pushRepeatDigit=function(y){this.operator?this.motionRepeat=this.motionRepeat.concat(y):this.prefixRepeat=this.prefixRepeat.concat(y)},S.prototype.getRepeat=function(){var y=0;return(this.prefixRepeat.length>0||this.motionRepeat.length>0)&&(y=1,this.prefixRepeat.length>0&&(y*=parseInt(this.prefixRepeat.join(""),10)),this.motionRepeat.length>0&&(y*=parseInt(this.motionRepeat.join(""),10))),y},B.prototype={setText:function(y,$,_){this.keyBuffer=[y||""],this.linewise=!!$,this.blockwise=!!_},pushText:function(y,$){$&&(this.linewise||this.keyBuffer.push(`
1438
+ `),this.linewise=!0),this.keyBuffer.push(y)},pushInsertModeChanges:function(y){this.insertModeChanges.push(Un(y))},pushSearchQuery:function(y){this.searchQueries.push(y)},clear:function(){this.keyBuffer=[],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!1},toString:function(){return this.keyBuffer.join("")}},G.prototype={pushText:function(y,$,_,P,z){if(y!=="_"){P&&_.charAt(_.length-1)!==`
1439
+ `&&(_+=`
1440
+ `);var j=this.isValidRegister(y)?this.getRegister(y):null;if(!j){switch($){case"yank":this.registers[0]=new B(_,P,z);break;case"delete":case"change":_.indexOf(`
1441
+ `)==-1?this.registers["-"]=new B(_,P):(this.shiftNumericRegisters_(),this.registers[1]=new B(_,P))}this.unnamedRegister.setText(_,P,z);return}var q=s(y);q?j.pushText(_,P):j.setText(_,P,z),y==="+"&&typeof navigator<"u"&&typeof navigator.clipboard<"u"&&typeof navigator.clipboard.readText=="function"&&navigator.clipboard.writeText(_),this.unnamedRegister.setText(j.toString(),P)}},getRegister:function(y){return this.isValidRegister(y)?(y=y.toLowerCase(),this.registers[y]||(this.registers[y]=new B),this.registers[y]):this.unnamedRegister},isValidRegister:function(y){return y&&(x(y,Os)||nn.test(y))},shiftNumericRegisters_:function(){for(var y=9;y>=2;y--)this.registers[y]=this.getRegister(""+(y-1))}},J.prototype={nextMatch:function(y,$){var _=this.historyBuffer,P=$?-1:1;this.initialPrefix===null&&(this.initialPrefix=y);for(var z=this.iterator+P;$?z>=0:z<_.length;z+=P)for(var j=_[z],q=0;q<=j.length;q++)if(this.initialPrefix==j.substring(0,q))return this.iterator=z,j;if(z>=_.length)return this.iterator=_.length,this.initialPrefix;if(z<0)return y},pushInput:function(y){var $=this.historyBuffer.indexOf(y);$>-1&&this.historyBuffer.splice($,1),y.length&&this.historyBuffer.push(y)},reset:function(){this.initialPrefix=null,this.iterator=this.historyBuffer.length}};var Ai={matchCommand:function(y,$,_,P){var z=me(y,$,P,_);if(!z.full&&!z.partial)return{type:"none"};if(!z.full&&z.partial)return{type:"partial",expectLiteralNext:z.partial.length==1&&z.partial[0].keys.slice(-11)=="<character>"};for(var j,q=0;q<z.full.length;q++){var Y=z.full[q];j||(j=Y)}if(j.keys.slice(-11)=="<character>"||j.keys.slice(-10)=="<register>"){var X=Ee(y);if(!X||X.length>1)return{type:"clear"};_.selectedCharacter=X}return{type:"full",command:j}},processCommand:function(y,$,_){switch($.inputState.repeatOverride=_.repeatOverride,_.type){case"motion":this.processMotion(y,$,_);break;case"operator":this.processOperator(y,$,_);break;case"operatorMotion":this.processOperatorMotion(y,$,_);break;case"action":this.processAction(y,$,_);break;case"search":this.processSearch(y,$,_);break;case"ex":case"keyToEx":this.processEx(y,$,_);break}},processMotion:function(y,$,_){$.inputState.motion=_.motion,$.inputState.motionArgs=le(_.motionArgs),this.evalInput(y,$)},processOperator:function(y,$,_){var P=$.inputState;if(P.operator){if(P.operator==_.operator){P.motion="expandToLine",P.motionArgs={linewise:!0},this.evalInput(y,$);return}A(y)}P.operator=_.operator,P.operatorArgs=le(_.operatorArgs),_.keys.length>1&&(P.operatorShortcut=_.keys),_.exitVisualBlock&&($.visualBlock=!1,_n(y)),$.visualMode&&this.evalInput(y,$)},processOperatorMotion:function(y,$,_){var P=$.visualMode,z=le(_.operatorMotionArgs);z&&P&&z.visualLine&&($.visualLine=!0),this.processOperator(y,$,_),P||this.processMotion(y,$,_)},processAction:function(y,$,_){var P=$.inputState,z=P.getRepeat(),j=!!z,q=le(_.actionArgs)||{};P.selectedCharacter&&(q.selectedCharacter=P.selectedCharacter),_.operator&&this.processOperator(y,$,_),_.motion&&this.processMotion(y,$,_),(_.motion||_.operator)&&this.evalInput(y,$),q.repeat=z||1,q.repeatIsExplicit=j,q.registerName=P.registerName,A(y),$.lastMotion=null,_.isEdit&&this.recordLastEdit($,P,_),Vn[_.action](y,q,$)},processSearch:function(y,$,_){function P(Ie,Ge,ut){je.searchHistoryController.pushInput(Ie),je.searchHistoryController.reset();try{hn(y,Ie,Ge,ut)}catch{$t(y,"Invalid regex: "+Ie),A(y);return}Ai.processMotion(y,$,{type:"motion",motion:"findNext",motionArgs:{forward:!0,toJumplist:_.searchArgs.toJumplist}})}function z(Ie){P(Ie,!0,!0);var Ge=je.macroModeState;Ge.isRecording&&go(Ge,Ie)}function j(Ie,Ge,ut){var Ze=W(Ie),et,$n;Ze=="<Up>"||Ze=="<Down>"?(et=Ze=="<Up>",$n=Ie.target?Ie.target.selectionEnd:0,Ge=je.searchHistoryController.nextMatch(Ge,et)||"",ut(Ge),$n&&Ie.target&&(Ie.target.selectionEnd=Ie.target.selectionStart=Math.min($n,Ie.target.value.length))):Ze&&Ze!="<Left>"&&Ze!="<Right>"&&je.searchHistoryController.reset();var Ct;try{Ct=hn(y,Ge,!0,!0)}catch{}Ct?y.scrollIntoView(Hn(y,!Y,Ct),30):(br(y),y.scrollTo(be.left,be.top))}function q(Ie,Ge,ut){var Ze=W(Ie);Ze=="<Esc>"||Ze=="<C-c>"||Ze=="<C-[>"||Ze=="<BS>"&&Ge==""?(je.searchHistoryController.pushInput(Ge),je.searchHistoryController.reset(),hn(y,ue),br(y),y.scrollTo(be.left,be.top),Be.e_stop(Ie),A(y),ut(),y.focus()):Ze=="<Up>"||Ze=="<Down>"?Be.e_stop(Ie):Ze=="<C-u>"&&(Be.e_stop(Ie),ut(""))}if(y.getSearchCursor){var Y=_.searchArgs.forward,X=_.searchArgs.wholeWordOnly;Sn(y).setReversed(!Y);var re=Y?"/":"?",ue=Sn(y).getQuery(),be=y.getScrollInfo();switch(_.searchArgs.querySrc){case"prompt":var ke=je.macroModeState;if(ke.isPlaying){var Oe=ke.replaySearchQueries.shift();P(Oe,!0,!1)}else bn(y,{onClose:z,prefix:re,desc:"(JavaScript regexp)",onKeyUp:j,onKeyDown:q});break;case"wordUnderCursor":var ye=jn(y,{noSymbol:!0}),Ae=!0;if(ye||(ye=jn(y,{noSymbol:!1}),Ae=!1),!ye){$t(y,"No word under cursor"),A(y);return}var Oe=y.getLine(ye.start.line).substring(ye.start.ch,ye.end.ch);Ae&&X?Oe="\\b"+Oe+"\\b":Oe=Dn(Oe),je.jumpList.cachedCursor=y.getCursor(),y.setCursor(ye.start),P(Oe,!0,!1)}}},processEx:function(y,$,_){function P(j){je.exCommandHistoryController.pushInput(j),je.exCommandHistoryController.reset(),zr.processCommand(y,j),y.state.vim&&A(y)}function z(j,q,Y){var X=W(j),re,ue;(X=="<Esc>"||X=="<C-c>"||X=="<C-[>"||X=="<BS>"&&q=="")&&(je.exCommandHistoryController.pushInput(q),je.exCommandHistoryController.reset(),Be.e_stop(j),A(y),Y(),y.focus()),X=="<Up>"||X=="<Down>"?(Be.e_stop(j),re=X=="<Up>",ue=j.target?j.target.selectionEnd:0,q=je.exCommandHistoryController.nextMatch(q,re)||"",Y(q),ue&&j.target&&(j.target.selectionEnd=j.target.selectionStart=Math.min(ue,j.target.value.length))):X=="<C-u>"?(Be.e_stop(j),Y("")):X&&X!="<Left>"&&X!="<Right>"&&je.exCommandHistoryController.reset()}_.type=="keyToEx"?zr.processCommand(y,_.exArgs.input):$.visualMode?bn(y,{onClose:P,prefix:":",value:"'<,'>",onKeyDown:z,selectValueOnOpen:!1}):bn(y,{onClose:P,prefix:":",onKeyDown:z})},evalInput:function(y,$){var _=$.inputState,P=_.motion,z=_.motionArgs||{},j=_.operator,q=_.operatorArgs||{},Y=_.registerName,X=$.sel,re=Ue($.visualMode?ce(y,X.head):y.getCursor("head")),ue=Ue($.visualMode?ce(y,X.anchor):y.getCursor("anchor")),be=Ue(re),ke=Ue(ue),ye,Ae,Oe;if(j&&this.recordLastEdit($,_),_.repeatOverride!==void 0?Oe=_.repeatOverride:Oe=_.getRepeat(),Oe>0&&z.explicitRepeat?z.repeatIsExplicit=!0:(z.noRepeat||!z.explicitRepeat&&Oe===0)&&(Oe=1,z.repeatIsExplicit=!1),_.selectedCharacter&&(z.selectedCharacter=q.selectedCharacter=_.selectedCharacter),z.repeat=Oe,A(y),P){var Ie=Mn[P](y,re,z,$,_);if($.lastMotion=Mn[P],!Ie)return;if(z.toJumplist){!j&&y.ace.curOp!=null&&(y.ace.curOp.command.scrollIntoView="center-animate");var Ge=je.jumpList,ut=Ge.cachedCursor;ut?(Or(y,ut,Ie),delete Ge.cachedCursor):Or(y,re,Ie)}Ie instanceof Array?(Ae=Ie[0],ye=Ie[1]):ye=Ie,ye||(ye=Ue(re)),$.visualMode?((!$.visualBlock||ye.ch!==1/0)&&(ye=ce(y,ye,be)),Ae&&(Ae=ce(y,Ae)),Ae=Ae||ke,X.anchor=Ae,X.head=ye,_n(y),Yr(y,$,"<",Qe(Ae,ye)?Ae:ye),Yr(y,$,">",Qe(Ae,ye)?ye:Ae)):j||(y.ace.curOp&&(y.ace.curOp.vimDialogScroll="center-animate"),ye=ce(y,ye,be),y.setCursor(ye.line,ye.ch))}if(j){if(q.lastSel){Ae=ke;var Ze=q.lastSel,et=Math.abs(Ze.head.line-Ze.anchor.line),$n=Math.abs(Ze.head.ch-Ze.anchor.ch);Ze.visualLine?ye=new De(ke.line+et,ke.ch):Ze.visualBlock?ye=new De(ke.line+et,ke.ch+$n):Ze.head.line==Ze.anchor.line?ye=new De(ke.line,ke.ch+$n):ye=new De(ke.line+et,ke.ch),$.visualMode=!0,$.visualLine=Ze.visualLine,$.visualBlock=Ze.visualBlock,X=$.sel={anchor:Ae,head:ye},_n(y)}else $.visualMode&&(q.lastSel={anchor:Ue(X.anchor),head:Ue(X.head),visualBlock:$.visualBlock,visualLine:$.visualLine});var Ct,Yt,It,_t,or;if($.visualMode){Ct=lt(X.head,X.anchor),Yt=Tt(X.head,X.anchor),It=$.visualLine||q.linewise,_t=$.visualBlock?"block":It?"line":"char";var pr=w(y,Ct,Yt);if(or=kn(y,{anchor:pr.start,head:pr.end},_t),It){var In=or.ranges;if(_t=="block")for(var V=0;V<In.length;V++)In[V].head.ch=At(y,In[V].head.line);else _t=="line"&&(In[0].head=new De(In[0].head.line+1,0))}}else{if(Ct=Ue(Ae||ke),Yt=Ue(ye||be),Qe(Yt,Ct)){var Z=Ct;Ct=Yt,Yt=Z}It=z.linewise||q.linewise,It?Jn(y,Ct,Yt):z.forward&&Wn(y,Ct,Yt),_t="char";var ie=!z.inclusive||It,pr=w(y,Ct,Yt);or=kn(y,{anchor:pr.start,head:pr.end},_t,ie)}y.setSelections(or.ranges,or.primary),$.lastMotion=null,q.repeat=Oe,q.registerName=Y,q.linewise=It;var ae=rs[j](y,q,or.ranges,ke,ye);$.visualMode&&vn(y,ae!=null),ae&&y.setCursor(ae)}},recordLastEdit:function(y,$,_){var P=je.macroModeState;P.isPlaying||(y.lastEditInputState=$,y.lastEditActionCommand=_,P.lastInsertModeChanges.changes=[],P.lastInsertModeChanges.expectCursorActivityForChange=!1,P.lastInsertModeChanges.visualBlock=y.visualBlock?y.sel.head.line-y.sel.anchor.line:0)}},Mn={moveToTopLine:function(y,$,_){var P=Ne(y).top+_.repeat-1;return new De(P,Jt(y.getLine(P)))},moveToMiddleLine:function(y){var $=Ne(y),_=Math.floor(($.top+$.bottom)*.5);return new De(_,Jt(y.getLine(_)))},moveToBottomLine:function(y,$,_){var P=Ne(y).bottom-_.repeat+1;return new De(P,Jt(y.getLine(P)))},expandToLine:function(y,$,_){var P=$;return new De(P.line+_.repeat-1,1/0)},findNext:function(y,$,_){var P=Sn(y),z=P.getQuery();if(z){var j=!_.forward;return j=P.isReversed()?!j:j,Ni(y,z),Hn(y,j,z,_.repeat)}},findAndSelectNextInclusive:function(y,$,_,P,z){var j=Sn(y),q=j.getQuery();if(q){var Y=!_.forward;Y=j.isReversed()?!Y:Y;var X=li(y,Y,q,_.repeat,P);if(X){if(z.operator)return X;var re=X[0],ue=new De(X[1].line,X[1].ch-1);if(P.visualMode){(P.visualLine||P.visualBlock)&&(P.visualLine=!1,P.visualBlock=!1,Be.signal(y,"vim-mode-change",{mode:"visual",subMode:""}));var be=P.sel.anchor;if(be)return j.isReversed()?_.forward?[be,re]:[be,ue]:_.forward?[be,ue]:[be,re]}else P.visualMode=!0,P.visualLine=!1,P.visualBlock=!1,Be.signal(y,"vim-mode-change",{mode:"visual",subMode:""});return Y?[ue,re]:[re,ue]}}},goToMark:function(y,$,_,P){var z=ze(y,P,_.selectedCharacter);return z?_.linewise?{line:z.line,ch:Jt(y.getLine(z.line))}:z:null},moveToOtherHighlightedEnd:function(y,$,_,P){if(P.visualBlock&&_.sameLine){var z=P.sel;return[ce(y,new De(z.anchor.line,z.head.ch)),ce(y,new De(z.head.line,z.anchor.ch))]}return[P.sel.head,P.sel.anchor]},jumpToMark:function(y,$,_,P){for(var z=$,j=0;j<_.repeat;j++){var q=z;for(var Y in P.marks)if(c(Y)){var X=P.marks[Y].find(),re=_.forward?Qe(X,q):Qe(q,X);if(!re&&!(_.linewise&&X.line==q.line)){var ue=ot(q,z),be=_.forward?ur(q,X,z):ur(z,X,q);(ue||be)&&(z=X)}}}return _.linewise&&(z=new De(z.line,Jt(y.getLine(z.line)))),z},moveByCharacters:function(y,$,_){var P=$,z=_.repeat,j=_.forward?P.ch+z:P.ch-z;return new De(P.line,j)},moveByLines:function(y,$,_,P){var z=$,j=z.ch;switch(P.lastMotion){case this.moveByLines:case this.moveByDisplayLines:case this.moveByScroll:case this.moveToColumn:case this.moveToEol:j=P.lastHPos;break;default:P.lastHPos=j}var q=_.repeat+(_.repeatOffset||0),Y=_.forward?z.line+q:z.line-q,X=y.firstLine(),re=y.lastLine();if(Y<X&&z.line==X)return this.moveToStartOfLine(y,$,_,P);if(Y>re&&z.line==re)return Xi(y,$,_,P,!0);var ue=y.ace.session.getFoldLine(Y);return ue&&(_.forward?Y>ue.start.row&&(Y=ue.end.row+1):Y=ue.start.row),_.toFirstChar&&(j=Jt(y.getLine(Y)),P.lastHPos=j),P.lastHSPos=y.charCoords(new De(Y,j),"div").left,new De(Y,j)},moveByDisplayLines:function(y,$,_,P){var z=$;switch(P.lastMotion){case this.moveByDisplayLines:case this.moveByScroll:case this.moveByLines:case this.moveToColumn:case this.moveToEol:break;default:P.lastHSPos=y.charCoords(z,"div").left}var j=_.repeat,X=y.findPosV(z,_.forward?j:-j,"line",P.lastHSPos);if(X.hitSide)if(_.forward)var q=y.charCoords(X,"div"),Y={top:q.top+8,left:P.lastHSPos},X=y.coordsChar(Y,"div");else{var re=y.charCoords(new De(y.firstLine(),0),"div");re.left=P.lastHSPos,X=y.coordsChar(re,"div")}return P.lastHPos=X.ch,X},moveByPage:function(y,$,_){var P=$,z=_.repeat;return y.findPosV(P,_.forward?z:-z,"page")},moveByParagraph:function(y,$,_){var P=_.forward?1:-1;return Jo(y,$,_.repeat,P)},moveBySentence:function(y,$,_){var P=_.forward?1:-1;return Zt(y,$,_.repeat,P)},moveByScroll:function(y,$,_,P){var z=y.getScrollInfo(),j=null,q=_.repeat;q||(q=z.clientHeight/(2*y.defaultTextHeight()));var Y=y.charCoords($,"local");if(_.repeat=q,j=Mn.moveByDisplayLines(y,$,_,P),!j)return null;var X=y.charCoords(j,"local");return y.scrollTo(null,z.top+X.top-Y.top),j},moveByWords:function(y,$,_){return rr(y,$,_.repeat,!!_.forward,!!_.wordEnd,!!_.bigWord)},moveTillCharacter:function(y,$,_){var P=_.repeat,z=wi(y,P,_.forward,_.selectedCharacter,$),j=_.forward?-1:1;return Rn(j,_),z?(z.ch+=j,z):null},moveToCharacter:function(y,$,_){var P=_.repeat;return Rn(0,_),wi(y,P,_.forward,_.selectedCharacter,$)||$},moveToSymbol:function(y,$,_){var P=_.repeat;return yr(y,P,_.forward,_.selectedCharacter)||$},moveToColumn:function(y,$,_,P){var z=_.repeat;return P.lastHPos=z-1,P.lastHSPos=y.charCoords($,"div").left,Eo(y,z)},moveToEol:function(y,$,_,P){return Xi(y,$,_,P,!1)},moveToFirstNonWhiteSpaceCharacter:function(y,$){var _=$;return new De(_.line,Jt(y.getLine(_.line)))},moveToMatchedSymbol:function(y,$){for(var _=$,P=_.line,z=_.ch,j=y.getLine(P),q;z<j.length;z++)if(q=j.charAt(z),q&&h(q)){var Y=y.getTokenTypeAt(new De(P,z+1));if(Y!=="string"&&Y!=="comment")break}if(z<j.length){var X=/[<>]/.test(j[z])?/[(){}[\]<>]/:/[(){}[\]]/,re=y.findMatchingBracket(new De(P,z+1),{bracketRegex:X});return re.to}return _},moveToStartOfLine:function(y,$){return new De($.line,0)},moveToLineOrEdgeOfDocument:function(y,$,_){var P=_.forward?y.lastLine():y.firstLine();return _.repeatIsExplicit&&(P=_.repeat-y.getOption("firstLineNumber")),new De(P,Jt(y.getLine(P)))},moveToStartOfDisplayLine:function(y){return y.execCommand("goLineLeft"),y.getCursor()},moveToEndOfDisplayLine:function(y){y.execCommand("goLineRight");var $=y.getCursor();return $.sticky=="before"&&$.ch--,$},textObjectManipulation:function(y,$,_,P){var z={"(":")",")":"(","{":"}","}":"{","[":"]","]":"[","<":">",">":"<"},j={"'":!0,'"':!0,"`":!0},q=_.selectedCharacter;q=="b"?q="(":q=="B"&&(q="{");var Y=!_.textObjectInner,X,re;if(z[q]){if(re=!0,X=fn(y,$,q,Y),!X){var ue=y.getSearchCursor(new RegExp("\\"+q,"g"),$);ue.find()&&(X=fn(y,ue.from(),q,Y))}}else if(j[q])re=!0,X=Nr(y,$,q,Y);else if(q==="W"||q==="w")for(var be=_.repeat||1;be-- >0;){var ke=jn(y,{inclusive:Y,innerWord:!Y,bigWord:q==="W",noSymbol:q==="W",multiline:!0},X&&X.end);ke&&(X||(X=ke),X.end=ke.end)}else if(q==="p")if(X=Jo(y,$,_.repeat,0,Y),_.linewise=!0,P.visualMode)P.visualLine||(P.visualLine=!0);else{var ye=P.inputState.operatorArgs;ye&&(ye.linewise=!0),X.end.line--}else if(q==="t")X=oi(y,$,Y);else if(q==="s"){var Ae=y.getLine($.line);$.ch>0&&b(Ae[$.ch])&&($.ch-=1);var Oe=To(y,$,_.repeat,1,Y),Ie=To(y,$,_.repeat,-1,Y);p(y.getLine(Ie.line)[Ie.ch])&&p(y.getLine(Oe.line)[Oe.ch-1])&&(Ie={line:Ie.line,ch:Ie.ch+1}),X={start:Ie,end:Oe}}return X?y.state.vim.visualMode?An(y,X.start,X.end,re):[X.start,X.end]:null},repeatLastCharacterSearch:function(y,$,_){var P=je.lastCharacterSearch,z=_.repeat,j=_.forward===P.forward,q=(P.increment?1:0)*(j?-1:1);y.moveH(-q,"char"),_.inclusive=!!j;var Y=wi(y,z,j,P.selectedCharacter);return Y?(Y.ch+=q,Y):(y.moveH(q,"char"),$)}},rs={change:function(y,$,_){var P,z,j=y.state.vim,q=_[0].anchor,Y=_[0].head;if(j.visualMode)if($.fullLine)Y.ch=Number.MAX_VALUE,Y.line--,y.setSelection(q,Y),z=y.getSelection(),y.replaceSelection(""),P=q;else{z=y.getSelection();var X=de("",_.length);y.replaceSelections(X),P=lt(_[0].head,_[0].anchor)}else{z=y.getRange(q,Y);var re=j.lastEditInputState||{};if(re.motion=="moveByWords"&&!p(z)){var ue=/\s+$/.exec(z);ue&&re.motionArgs&&re.motionArgs.forward&&(Y=pe(Y,0,-ue[0].length),z=z.slice(0,-ue[0].length))}$.linewise&&(q=new De(q.line,Jt(y.getLine(q.line))),Y.line>q.line&&(Y=new De(Y.line-1,Number.MAX_VALUE))),y.replaceRange("",q,Y),P=q}je.registerController.pushText($.registerName,"change",z,$.linewise,_.length>1),Vn.enterInsertMode(y,{head:P},y.state.vim)},delete:function(y,$,_){var P,z,j=y.state.vim;if(j.visualBlock){z=y.getSelection();var q=de("",_.length);y.replaceSelections(q),P=lt(_[0].head,_[0].anchor)}else{var Y=_[0].anchor,X=_[0].head;$.linewise&&X.line!=y.firstLine()&&Y.line==y.lastLine()&&Y.line==X.line-1&&(Y.line==y.firstLine()?Y.ch=0:Y=new De(Y.line-1,At(y,Y.line-1))),z=y.getRange(Y,X),y.replaceRange("",Y,X),P=Y,$.linewise&&(P=Mn.moveToFirstNonWhiteSpaceCharacter(y,Y))}return je.registerController.pushText($.registerName,"delete",z,$.linewise,j.visualBlock),ce(y,P)},indent:function(y,$,_){var P=y.state.vim,z=P.visualMode?$.repeat:1;if(P.visualBlock){for(var j=y.getOption("tabSize"),q=y.getOption("indentWithTabs")?" ":" ".repeat(j),Y,X=_.length-1;X>=0;X--)if(Y=lt(_[X].anchor,_[X].head),$.indentRight)y.replaceRange(q.repeat(z),Y,Y);else{for(var re=y.getLine(Y.line),ue=0,be=0;be<z;be++){var ke=re[Y.ch+ue];if(ke==" ")ue++;else{if(ke!=" ")break;ue++;for(var ye=1;ye<q.length&&(ke=re[Y.ch+ue],ke===" ");ye++)ue++}}y.replaceRange("",Y,pe(Y,0,ue))}return Y}if(y.indentMore)for(var be=0;be<z;be++)$.indentRight?y.indentMore():y.indentLess();else{var Ae=_[0].anchor.line,Oe=P.visualBlock?_[_.length-1].anchor.line:_[0].head.line;$.linewise&&Oe--;for(var X=Ae;X<=Oe;X++)for(var be=0;be<z;be++)y.indentLine(X,$.indentRight)}return Mn.moveToFirstNonWhiteSpaceCharacter(y,_[0].anchor)},indentAuto:function(y,$,_){return y.execCommand("indentAuto"),Mn.moveToFirstNonWhiteSpaceCharacter(y,_[0].anchor)},hardWrap:function(y,$,_,P,z){if(y.hardWrap){var j=_[0].anchor.line,q=_[0].head.line;$.linewise&&q--;var Y=y.hardWrap({from:j,to:q});return Y>j&&$.linewise&&Y--,$.keepCursor?P:new De(Y,0)}},changeCase:function(y,$,_,P,z){for(var j=y.getSelections(),q=[],Y=$.toLower,X=0;X<j.length;X++){var re=j[X],ue="";if(Y===!0)ue=re.toLowerCase();else if(Y===!1)ue=re.toUpperCase();else for(var be=0;be<re.length;be++){var ke=re.charAt(be);ue+=s(ke)?ke.toLowerCase():ke.toUpperCase()}q.push(ue)}return y.replaceSelections(q),$.shouldMoveCursor?z:!y.state.vim.visualMode&&$.linewise&&_[0].anchor.line+1==_[0].head.line?Mn.moveToFirstNonWhiteSpaceCharacter(y,P):$.linewise?P:lt(_[0].anchor,_[0].head)},yank:function(y,$,_,P){var z=y.state.vim,j=y.getSelection(),q=z.visualMode?lt(z.sel.anchor,z.sel.head,_[0].head,_[0].anchor):P;return je.registerController.pushText($.registerName,"yank",j,$.linewise,z.visualBlock),q}},Vn={jumpListWalk:function(y,$,_){if(!_.visualMode){var P=$.repeat,z=$.forward,j=je.jumpList,q=j.move(y,z?P:-P),Y=q?q.find():void 0;Y=Y||y.getCursor(),y.setCursor(Y),y.ace.curOp.command.scrollIntoView="center-animate"}},scroll:function(y,$,_){if(!_.visualMode){var P=$.repeat||1,z=y.defaultTextHeight(),j=y.getScrollInfo().top,q=z*P,Y=$.forward?j+q:j-q,X=Ue(y.getCursor()),re=y.charCoords(X,"local");if($.forward)Y>re.top?(X.line+=(Y-re.top)/z,X.line=Math.ceil(X.line),y.setCursor(X),re=y.charCoords(X,"local"),y.scrollTo(null,re.top)):y.scrollTo(null,Y);else{var ue=Y+y.getScrollInfo().clientHeight;ue<re.bottom?(X.line-=(re.bottom-ue)/z,X.line=Math.floor(X.line),y.setCursor(X),re=y.charCoords(X,"local"),y.scrollTo(null,re.bottom-y.getScrollInfo().clientHeight)):y.scrollTo(null,Y)}}},scrollToCursor:function(y,$){var _=y.getCursor().line,P=y.charCoords(new De(_,0),"local"),z=y.getScrollInfo().clientHeight,j=P.top;switch($.position){case"center":j=P.bottom-z/2;break;case"bottom":var q=new De(_,y.getLine(_).length-1),Y=y.charCoords(q,"local"),X=Y.bottom-j;j=j-z+X}y.scrollTo(null,j)},replayMacro:function(y,$,_){var P=$.selectedCharacter,z=$.repeat,j=je.macroModeState;for(P=="@"?P=j.latestRegister:j.latestRegister=P;z--;)hr(y,_,j,P)},enterMacroRecordMode:function(y,$){var _=je.macroModeState,P=$.selectedCharacter;je.registerController.isValidRegister(P)&&_.enterMacroRecordMode(y,P)},toggleOverwrite:function(y){y.state.overwrite?(y.toggleOverwrite(!1),y.setOption("keyMap","vim-insert"),Be.signal(y,"vim-mode-change",{mode:"insert"})):(y.toggleOverwrite(!0),y.setOption("keyMap","vim-replace"),Be.signal(y,"vim-mode-change",{mode:"replace"}))},enterInsertMode:function(y,$,_){if(!y.getOption("readOnly")){_.insertMode=!0,_.insertModeRepeat=$&&$.repeat||1;var P=$?$.insertAt:null,z=_.sel,j=$.head||y.getCursor("head"),q=y.listSelections().length;if(P=="eol")j=new De(j.line,At(y,j.line));else if(P=="bol")j=new De(j.line,0);else if(P=="charAfter"){var Y=w(y,j,pe(j,0,1));j=Y.end}else if(P=="firstNonBlank"){var Y=w(y,j,Mn.moveToFirstNonWhiteSpaceCharacter(y,j));j=Y.end}else if(P=="startOfSelectedArea"){if(!_.visualMode)return;_.visualBlock?(j=new De(Math.min(z.head.line,z.anchor.line),Math.min(z.head.ch,z.anchor.ch)),q=Math.abs(z.head.line-z.anchor.line)+1):z.head.line<z.anchor.line?j=z.head:j=new De(z.anchor.line,0)}else if(P=="endOfSelectedArea"){if(!_.visualMode)return;_.visualBlock?(j=new De(Math.min(z.head.line,z.anchor.line),Math.max(z.head.ch,z.anchor.ch)+1),q=Math.abs(z.head.line-z.anchor.line)+1):z.head.line>=z.anchor.line?j=pe(z.head,0,1):j=new De(z.anchor.line,0)}else if(P=="inplace"){if(_.visualMode)return}else P=="lastEdit"&&(j=mt(y)||j);y.setOption("disableInput",!1),$&&$.replace?(y.toggleOverwrite(!0),y.setOption("keyMap","vim-replace"),Be.signal(y,"vim-mode-change",{mode:"replace"})):(y.toggleOverwrite(!1),y.setOption("keyMap","vim-insert"),Be.signal(y,"vim-mode-change",{mode:"insert"})),je.macroModeState.isPlaying||(y.on("change",mo),_.insertEnd&&_.insertEnd.clear(),_.insertEnd=y.setBookmark(j,{insertLeft:!0}),Be.on(y.getInputField(),"keydown",Io)),_.visualMode&&vn(y),Yn(y,j,q)}},toggleVisualMode:function(y,$,_){var P=$.repeat,z=y.getCursor(),j;if(_.visualMode)_.visualLine^$.linewise||_.visualBlock^$.blockwise?(_.visualLine=!!$.linewise,_.visualBlock=!!$.blockwise,Be.signal(y,"vim-mode-change",{mode:"visual",subMode:_.visualLine?"linewise":_.visualBlock?"blockwise":""}),_n(y)):vn(y);else{_.visualMode=!0,_.visualLine=!!$.linewise,_.visualBlock=!!$.blockwise,j=ce(y,new De(z.line,z.ch+P-1));var q=w(y,z,j);_.sel={anchor:q.start,head:q.end},Be.signal(y,"vim-mode-change",{mode:"visual",subMode:_.visualLine?"linewise":_.visualBlock?"blockwise":""}),_n(y),Yr(y,_,"<",lt(z,j)),Yr(y,_,">",Tt(z,j))}},reselectLastSelection:function(y,$,_){var P=_.lastSelection;if(_.visualMode&&Ft(y,_),P){var z=P.anchorMark.find(),j=P.headMark.find();if(!z||!j)return;_.sel={anchor:z,head:j},_.visualMode=!0,_.visualLine=P.visualLine,_.visualBlock=P.visualBlock,_n(y),Yr(y,_,"<",lt(z,j)),Yr(y,_,">",Tt(z,j)),Be.signal(y,"vim-mode-change",{mode:"visual",subMode:_.visualLine?"linewise":_.visualBlock?"blockwise":""})}},joinLines:function(y,$,_){var P,z;if(_.visualMode){if(P=y.getCursor("anchor"),z=y.getCursor("head"),Qe(z,P)){var j=z;z=P,P=j}z.ch=At(y,z.line)-1}else{var q=Math.max($.repeat,2);P=y.getCursor(),z=ce(y,new De(P.line+q-1,1/0))}for(var Y=0,X=P.line;X<z.line;X++){Y=At(y,P.line);var re="",ue=0;if(!$.keepSpaces){var be=y.getLine(P.line+1);ue=be.search(/\S/),ue==-1?ue=be.length:re=" "}y.replaceRange(re,new De(P.line,Y),new De(P.line+1,ue))}var ke=ce(y,new De(P.line,Y));_.visualMode&&vn(y,!1),y.setCursor(ke)},newLineAndEnterInsertMode:function(y,$,_){_.insertMode=!0;var P=Ue(y.getCursor());if(P.line===y.firstLine()&&!$.after)y.replaceRange(`
1442
+ `,new De(y.firstLine(),0)),y.setCursor(y.firstLine(),0);else{P.line=$.after?P.line:P.line-1,P.ch=At(y,P.line),y.setCursor(P);var z=Be.commands.newlineAndIndentContinueComment||Be.commands.newlineAndIndent;z(y)}this.enterInsertMode(y,{repeat:$.repeat},_)},paste:function(y,$,_){var P=this,z=je.registerController.getRegister($.registerName),j=function(){var q=z.toString();P.continuePaste(y,$,_,q,z)};$.registerName==="+"&&typeof navigator<"u"&&typeof navigator.clipboard<"u"&&typeof navigator.clipboard.readText=="function"?navigator.clipboard.readText().then(function(q){P.continuePaste(y,$,_,q,z)},function(){j()}):j()},continuePaste:function(y,$,_,P,z){var j=Ue(y.getCursor());if(P){if($.matchIndent){var q=y.getOption("tabSize"),Y=function(In){var V=In.split(" ").length-1,Z=In.split(" ").length-1;return V*q+Z*1},X=y.getLine(y.getCursor().line),re=Y(X.match(/^\s*/)[0]),ue=P.replace(/\n$/,""),be=P!==ue,ke=Y(P.match(/^\s*/)[0]),P=ue.replace(/^\s*/gm,function(In){var V=re+(Y(In)-ke);if(V<0)return"";if(y.getOption("indentWithTabs")){var Z=Math.floor(V/q);return Array(Z+1).join(" ")}return Array(V+1).join(" ")});P+=be?`
1443
+ `:""}if($.repeat>1)var P=Array($.repeat+1).join(P);var ye=z.linewise,Ae=z.blockwise;if(Ae){P=P.split(`
1444
+ `),ye&&P.pop();for(var Oe=0;Oe<P.length;Oe++)P[Oe]=P[Oe]==""?" ":P[Oe];j.ch+=$.after?1:0,j.ch=Math.min(At(y,j.line),j.ch)}else ye?_.visualMode?P=_.visualLine?P.slice(0,-1):`
1445
+ `+P.slice(0,P.length-1)+`
1446
+ `:$.after?(P=`
1447
+ `+P.slice(0,P.length-1),j.ch=At(y,j.line)):j.ch=0:j.ch+=$.after?1:0;var Ie;if(_.visualMode){_.lastPastedText=P;var Ge,ut=Je(y,_),Ze=ut[0],et=ut[1],$n=y.getSelection(),Ct=y.listSelections(),Yt=new Array(Ct.length).join("1").split("1");_.lastSelection&&(Ge=_.lastSelection.headMark.find()),je.registerController.unnamedRegister.setText($n),Ae?(y.replaceSelections(Yt),et=new De(Ze.line+P.length-1,Ze.ch),y.setCursor(Ze),un(y,et),y.replaceSelections(P),Ie=Ze):_.visualBlock?(y.replaceSelections(Yt),y.setCursor(Ze),y.replaceRange(P,Ze,Ze),Ie=Ze):(y.replaceRange(P,Ze,et),Ie=y.posFromIndex(y.indexFromPos(Ze)+P.length-1)),Ge&&(_.lastSelection.headMark=y.setBookmark(Ge)),ye&&(Ie.ch=0)}else if(Ae){y.setCursor(j);for(var Oe=0;Oe<P.length;Oe++){var It=j.line+Oe;It>y.lastLine()&&y.replaceRange(`
1448
+ `,new De(It,0));var _t=At(y,It);_t<j.ch&&Kn(y,It,j.ch)}y.setCursor(j),un(y,new De(j.line+P.length-1,j.ch)),y.replaceSelections(P),Ie=j}else if(y.replaceRange(P,j),ye){var It=$.after?j.line+1:j.line;Ie=new De(It,Jt(y.getLine(It)))}else Ie=Ue(j),/\n/.test(P)||(Ie.ch+=P.length-($.after?1:0));_.visualMode&&vn(y,!1),y.setCursor(Ie)}},undo:function(y,$){y.operation(function(){He(y,Be.commands.undo,$.repeat)(),y.setCursor(ce(y,y.getCursor("start")))})},redo:function(y,$){He(y,Be.commands.redo,$.repeat)()},setRegister:function(y,$,_){_.inputState.registerName=$.selectedCharacter},insertRegister:function(y,$,_){var P=$.selectedCharacter,z=je.registerController.getRegister(P),j=z&&z.toString();j&&y.replaceSelection(j)},oneNormalCommand:function(y,$,_){Mt(y,!0),_.insertModeReturn=!0,Be.on(y,"vim-command-done",function P(){_.visualMode||(_.insertModeReturn&&(_.insertModeReturn=!1,_.insertMode||Vn.enterInsertMode(y,{},_)),Be.off(y,"vim-command-done",P))})},setMark:function(y,$,_){var P=$.selectedCharacter;Yr(y,_,P,y.getCursor())},replace:function(y,$,_){var P=$.selectedCharacter,z=y.getCursor(),j,q,Y=y.listSelections();if(_.visualMode)z=y.getCursor("start"),q=y.getCursor("end");else{var X=y.getLine(z.line);j=z.ch+$.repeat,j>X.length&&(j=X.length),q=new De(z.line,j)}var re=w(y,z,q);if(z=re.start,q=re.end,P==`
1449
+ `)_.visualMode||y.replaceRange("",z,q),(Be.commands.newlineAndIndentContinueComment||Be.commands.newlineAndIndent)(y);else{var ue=y.getRange(z,q);if(ue=ue.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,P),ue=ue.replace(/[^\n]/g,P),_.visualBlock){var be=new Array(y.getOption("tabSize")+1).join(" ");ue=y.getSelection(),ue=ue.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,P),ue=ue.replace(/\t/g,be).replace(/[^\n]/g,P).split(`
1450
+ `),y.replaceSelections(ue)}else y.replaceRange(ue,z,q);_.visualMode?(z=Qe(Y[0].anchor,Y[0].head)?Y[0].anchor:Y[0].head,y.setCursor(z),vn(y,!1)):y.setCursor(pe(q,0,-1))}},incrementNumberToken:function(y,$){for(var _=y.getCursor(),P=y.getLine(_.line),z=/(-?)(?:(0x)([\da-f]+)|(0b|0|)(\d+))/gi,j,q,Y,X;(j=z.exec(P))!==null&&(q=j.index,Y=q+j[0].length,!(_.ch<Y)););if(!(!$.backtrack&&Y<=_.ch)&&j){var re=j[2]||j[4],ue=j[3]||j[5],be=$.increase?1:-1,ke={"0b":2,0:8,"":10,"0x":16}[re.toLowerCase()],ye=parseInt(j[1]+ue,ke)+be*$.repeat;X=ye.toString(ke);var Ae=re?new Array(ue.length-X.length+1+j[1].length).join("0"):"";X.charAt(0)==="-"?X="-"+re+Ae+X.substr(1):X=re+Ae+X;var Oe=new De(_.line,q),Ie=new De(_.line,Y);y.replaceRange(X,Oe,Ie),y.setCursor(new De(_.line,q+X.length-1))}},repeatLastEdit:function(y,$,_){var P=_.lastEditInputState;if(P){var z=$.repeat;z&&$.repeatIsExplicit?_.lastEditInputState.repeatOverride=z:z=_.lastEditInputState.repeatOverride||z,Ts(y,_,z,!1)}},indent:function(y,$){y.indentLine(y.getCursor().line,$.indentRight)},exitInsertMode:Mt},_i={"(":"bracket",")":"bracket","{":"bracket","}":"bracket","[":"section","]":"section","*":"comment","/":"comment",m:"method",M:"method","#":"preprocess"},ki={bracket:{isComplete:function(y){if(y.nextCh===y.symb){if(y.depth++,y.depth>=1)return!0}else y.nextCh===y.reverseSymb&&y.depth--;return!1}},section:{init:function(y){y.curMoveThrough=!0,y.symb=(y.forward?"]":"[")===y.symb?"{":"}"},isComplete:function(y){return y.index===0&&y.nextCh===y.symb}},comment:{isComplete:function(y){var $=y.lastCh==="*"&&y.nextCh==="/";return y.lastCh=y.nextCh,$}},method:{init:function(y){y.symb=y.symb==="m"?"{":"}",y.reverseSymb=y.symb==="{"?"}":"{"},isComplete:function(y){return y.nextCh===y.symb}},preprocess:{init:function(y){y.index=0},isComplete:function(y){if(y.nextCh==="#"){var $=y.lineText.match(/^#(\w+)/)[1];if($==="endif"){if(y.forward&&y.depth===0)return!0;y.depth++}else if($==="if"){if(!y.forward&&y.depth===0)return!0;y.depth--}if($==="else"&&y.depth===0)return!0}return!1}}};M("pcre",!0,"boolean"),Dr.prototype={getQuery:function(){return je.query},setQuery:function(y){je.query=y},getOverlay:function(){return this.searchOverlay},setOverlay:function(y){this.searchOverlay=y},isReversed:function(){return je.isReversed},setReversed:function(y){je.isReversed=y},getScrollbarAnnotate:function(){return this.annotate},setScrollbarAnnotate:function(y){this.annotate=y}};var zi={"\\n":`
1451
+ `,"\\r":"\r","\\t":" "},Ns={"\\/":"/","\\\\":"\\","\\n":`
1452
+ `,"\\r":"\r","\\t":" ","\\&":"&"},on=0,Aa=function(){this.buildCommandMap_()};Aa.prototype={processCommand:function(y,$,_){var P=this;y.operation(function(){y.curOp.isVimOp=!0,P._processCommand(y,$,_)})},_processCommand:function(y,$,_){var P=y.state.vim,z=je.registerController.getRegister(":"),j=z.toString(),q=new Be.StringStream($);z.setText($);var Y=_||{};Y.input=$;try{this.parseInput_(y,q,Y)}catch(ue){throw $t(y,ue.toString()),ue}P.visualMode&&vn(y);var X,re;if(!Y.commandName)Y.line!==void 0&&(re="move");else if(X=this.matchCommand_(Y.commandName),X){if(re=X.name,X.excludeFromCommandHistory&&z.setText(j),this.parseCommandArgs_(q,Y,X),X.type=="exToKey"){T(y,X.toKeys,X);return}if(X.type=="exToEx"){this.processCommand(y,X.toInput);return}}if(!re){$t(y,'Not an editor command ":'+$+'"');return}try{fr[re](y,Y),(!X||!X.possiblyAsync)&&Y.callback&&Y.callback()}catch(ue){throw $t(y,ue.toString()),ue}},parseInput_:function(y,$,_){if($.eatWhile(":"),$.eat("%")?(_.line=y.firstLine(),_.lineEnd=y.lastLine()):(_.line=this.parseLineSpec_(y,$),_.line!==void 0&&$.eat(",")&&(_.lineEnd=this.parseLineSpec_(y,$))),_.line==null)if(y.state.vim.visualMode){var P=ze(y,y.state.vim,"<");_.selectionLine=P&&P.line,P=ze(y,y.state.vim,">"),_.selectionLineEnd=P&&P.line}else _.selectionLine=y.getCursor().line;else _.selectionLine=_.line,_.selectionLineEnd=_.lineEnd;var z=$.match(/^(\w+|!!|@@|[!#&*<=>@~])/);return z?_.commandName=z[1]:_.commandName=$.match(/.*/)[0],_},parseLineSpec_:function(y,$){var _=$.match(/^(\d+)/);if(_)return parseInt(_[1],10)-1;switch($.next()){case".":return this.parseLineSpecOffset_($,y.getCursor().line);case"$":return this.parseLineSpecOffset_($,y.lastLine());case"'":var P=$.next(),z=ze(y,y.state.vim,P);if(!z)throw new Error("Mark not set");return this.parseLineSpecOffset_($,z.line);case"-":case"+":return $.backUp(1),this.parseLineSpecOffset_($,y.getCursor().line);default:return $.backUp(1),void 0}},parseLineSpecOffset_:function(y,$){var _=y.match(/^([+-])?(\d+)/);if(_){var P=parseInt(_[2],10);_[1]=="-"?$-=P:$+=P}return $},parseCommandArgs_:function(y,$,_){if(!y.eol()){$.argString=y.match(/.*/)[0];var P=_.argDelimiter||/\s+/,z=vr($.argString).split(P);z.length&&z[0]&&($.args=z)}},matchCommand_:function(y){for(var $=y.length;$>0;$--){var _=y.substring(0,$);if(this.commandMap_[_]){var P=this.commandMap_[_];if(P.name.indexOf(y)===0)return P}}return null},buildCommandMap_:function(){this.commandMap_={};for(var y=0;y<ro.length;y++){var $=ro[y],_=$.shortName||$.name;this.commandMap_[_]=$}},map:function(y,$,_,P){if(y!=":"&&y.charAt(0)==":"){if(_)throw Error("Mode not supported for ex mappings");var z=y.substring(1);$!=":"&&$.charAt(0)==":"?this.commandMap_[z]={name:z,type:"exToEx",toInput:$.substring(1),user:!0}:this.commandMap_[z]={name:z,type:"exToKey",toKeys:$,user:!0}}else{var j={keys:y,type:"keyToKey",toKeys:$,noremap:!!P};_&&(j.context=_),Pn.unshift(j)}},unmap:function(y,$){if(y!=":"&&y.charAt(0)==":"){if($)throw Error("Mode not supported for ex mappings");var _=y.substring(1);if(this.commandMap_[_]&&this.commandMap_[_].user)return delete this.commandMap_[_],!0}else for(var P=y,z=0;z<Pn.length;z++)if(P==Pn[z].keys&&Pn[z].context===$)return Pn.splice(z,1),!0}};var fr={colorscheme:function(y,$){if(!$.args||$.args.length<1){$t(y,y.getOption("theme"));return}y.setOption("theme",$.args[0])},map:function(y,$,_,P){var z=$.args;if(!z||z.length<2){y&&$t(y,"Invalid mapping: "+$.input);return}zr.map(z[0],z[1],_,P)},imap:function(y,$){this.map(y,$,"insert")},nmap:function(y,$){this.map(y,$,"normal")},vmap:function(y,$){this.map(y,$,"visual")},omap:function(y,$){this.map(y,$,"operatorPending")},noremap:function(y,$){this.map(y,$,void 0,!0)},inoremap:function(y,$){this.map(y,$,"insert",!0)},nnoremap:function(y,$){this.map(y,$,"normal",!0)},vnoremap:function(y,$){this.map(y,$,"visual",!0)},onoremap:function(y,$){this.map(y,$,"operatorPending",!0)},unmap:function(y,$,_){var P=$.args;(!P||P.length<1||!zr.unmap(P[0],_))&&y&&$t(y,"No such mapping: "+$.input)},mapclear:function(y,$){wt.mapclear()},imapclear:function(y,$){wt.mapclear("insert")},nmapclear:function(y,$){wt.mapclear("normal")},vmapclear:function(y,$){wt.mapclear("visual")},omapclear:function(y,$){wt.mapclear("operatorPending")},move:function(y,$){Ai.processCommand(y,y.state.vim,{type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!1,explicitRepeat:!0,linewise:!0},repeatOverride:$.line+1})},set:function(y,$){var _=$.args,P=$.setCfg||{};if(!_||_.length<1){y&&$t(y,"Invalid mapping: "+$.input);return}var z=_[0].split("="),j=z[0],q=z[1],Y=!1,X=!1;if(j.charAt(j.length-1)=="?"){if(q)throw Error("Trailing characters: "+$.argString);j=j.substring(0,j.length-1),Y=!0}else j.charAt(j.length-1)=="!"&&(j=j.substring(0,j.length-1),X=!0);q===void 0&&j.substring(0,2)=="no"&&(j=j.substring(2),q=!1);var re=qt[j]&&qt[j].type=="boolean";if(re&&(X?q=!k(j,y,P):q==null&&(q=!0)),!re&&q===void 0||Y){var ue=k(j,y,P);ue instanceof Error?$t(y,ue.message):ue===!0||ue===!1?$t(y," "+(ue?"":"no")+j):$t(y," "+j+"="+ue)}else{var be=R(j,q,y,P);be instanceof Error&&$t(y,be.message)}},setlocal:function(y,$){$.setCfg={scope:"local"},this.set(y,$)},setglobal:function(y,$){$.setCfg={scope:"global"},this.set(y,$)},registers:function(y,$){var _=$.args,P=je.registerController.registers,z=`----------Registers----------
1453
+
1454
+ `;if(_){var j;_=_.join("");for(var q=0;q<_.length;q++)if(j=_.charAt(q),!!je.registerController.isValidRegister(j)){var Y=P[j]||new B;z+='"'+j+" "+Y.toString()+`
1455
+ `}}else for(var j in P){var X=P[j].toString();X.length&&(z+='"'+j+" "+X+`
1456
+ `)}$t(y,z)},sort:function(y,$){function _(){if($.argString){var It=new Be.StringStream($.argString);if(It.eat("!")&&(j=!0),It.eol())return;if(!It.eatSpace())return"Invalid arguments";var _t=It.match(/([dinuox]+)?\s*(\/.+\/)?\s*/);if(!_t&&!It.eol())return"Invalid arguments";if(_t[1]){q=_t[1].indexOf("i")!=-1,Y=_t[1].indexOf("u")!=-1;var or=_t[1].indexOf("d")!=-1||_t[1].indexOf("n")!=-1&&1,pr=_t[1].indexOf("x")!=-1&&1,In=_t[1].indexOf("o")!=-1&&1;if(or+pr+In>1)return"Invalid arguments";X=or&&"decimal"||pr&&"hex"||In&&"octal"}_t[2]&&(re=new RegExp(_t[2].substr(1,_t[2].length-2),q?"i":""))}}function P(It,_t){if(j){var or;or=It,It=_t,_t=or}q&&(It=It.toLowerCase(),_t=_t.toLowerCase());var pr=X&&Ie.exec(It),In=X&&Ie.exec(_t);return pr?(pr=parseInt((pr[1]+pr[2]).toLowerCase(),Ge),In=parseInt((In[1]+In[2]).toLowerCase(),Ge),pr-In):It<_t?-1:1}function z(It,_t){if(j){var or;or=It,It=_t,_t=or}return q&&(It[0]=It[0].toLowerCase(),_t[0]=_t[0].toLowerCase()),It[0]<_t[0]?-1:1}var j,q,Y,X,re,ue=_();if(ue){$t(y,ue+": "+$.argString);return}var be=$.line||y.firstLine(),ke=$.lineEnd||$.line||y.lastLine();if(be!=ke){var ye=new De(be,0),Ae=new De(ke,At(y,ke)),Oe=y.getRange(ye,Ae).split(`
1457
+ `),Ie=re||(X=="decimal"?/(-?)([\d]+)/:X=="hex"?/(-?)(?:0x)?([0-9a-f]+)/i:X=="octal"?/([0-7]+)/:null),Ge=X=="decimal"?10:X=="hex"?16:X=="octal"?8:null,ut=[],Ze=[];if(X||re)for(var et=0;et<Oe.length;et++){var $n=re?Oe[et].match(re):null;$n&&$n[0]!=""?ut.push($n):!re&&Ie.exec(Oe[et])?ut.push(Oe[et]):Ze.push(Oe[et])}else Ze=Oe;if(ut.sort(re?z:P),re)for(var et=0;et<ut.length;et++)ut[et]=ut[et].input;else X||Ze.sort(P);if(Oe=j?ut.concat(Ze):Ze.concat(ut),Y){var Ct=Oe,Yt;Oe=[];for(var et=0;et<Ct.length;et++)Ct[et]!=Yt&&Oe.push(Ct[et]),Yt=Ct[et]}y.replaceRange(Oe.join(`
1458
+ `),ye,Ae)}},vglobal:function(y,$){this.global(y,$)},normal:function(y,$){var _=$.argString;if(_&&_[0]=="!"&&(_=_.slice(1),Fi=!0),_=_.trimStart(),!_){$t(y,"Argument is required.");return}var P=$.line;if(typeof P=="number")for(var z=isNaN($.lineEnd)?P:$.lineEnd,j=P;j<=z;j++)y.setCursor(j,0),T(y,$.argString.trimStart()),y.state.vim.insertMode&&Mt(y,!0);else T(y,$.argString.trimStart()),y.state.vim.insertMode&&Mt(y,!0)},global:function(y,$){var _=$.argString;if(!_){$t(y,"Regular Expression missing from global");return}var P=$.commandName[0]==="v";_[0]==="!"&&$.commandName[0]==="g"&&(P=!0,_=_.slice(1));var z=$.line!==void 0?$.line:y.firstLine(),j=$.lineEnd||$.line||y.lastLine(),q=Zn(_),Y=_,X;if(q.length&&(Y=q[0],X=q.slice(1,q.length).join("/")),Y)try{hn(y,Y,!0,!0)}catch{$t(y,"Invalid regex: "+Y);return}for(var re=Sn(y).getQuery(),ue=[],be=z;be<=j;be++){var ke=y.getLine(be),ye=re.test(ke);ye!==P&&ue.push(X?y.getLineHandle(be):ke)}if(!X){$t(y,ue.join(`
1459
+ `));return}var Ae=0,Oe=function(){if(Ae<ue.length){var Ie=ue[Ae++],Ge=y.getLineNumber(Ie);if(Ge==null){Oe();return}var ut=Ge+1+X;zr.processCommand(y,ut,{callback:Oe})}else y.releaseLineHandles&&y.releaseLineHandles()};Oe()},substitute:function(y,$){if(!y.getSearchCursor)throw new Error("Search feature not available. Requires searchcursor.js or any other getSearchCursor implementation.");var _=$.argString,P=_?Ci(_,_[0]):[],z,j="",q,Y,X,re=!1,ue=!1;if(P.length)z=P[0],k("pcre")&&z!==""&&(z=new RegExp(z).source),j=P[1],j!==void 0&&(k("pcre")?j=Mo(j.replace(/([^\\])&/g,"$1$$&")):j=Zo(j),je.lastSubstituteReplacePart=j),q=P[2]?P[2].split(" "):[];else if(_&&_.length){$t(y,"Substitutions should be of the form :s/pattern/replace/");return}if(q&&(Y=q[0],X=parseInt(q[1]),Y&&(Y.indexOf("c")!=-1&&(re=!0),Y.indexOf("g")!=-1&&(ue=!0),k("pcre")?z=z+"/"+Y:z=z.replace(/\//g,"\\/")+"/"+Y)),z)try{hn(y,z,!0,!0)}catch{$t(y,"Invalid regex: "+z);return}if(j=j||je.lastSubstituteReplacePart,j===void 0){$t(y,"No previous substitute regular expression");return}var be=Sn(y),ke=be.getQuery(),ye=$.line!==void 0?$.line:y.getCursor().line,Ae=$.lineEnd||ye;ye==y.firstLine()&&Ae==y.lastLine()&&(Ae=1/0),X&&(ye=Ae,Ae=ye+X-1);var Oe=ce(y,new De(ye,0)),Ie=y.getSearchCursor(ke,Oe);Ot(y,re,ue,ye,Ae,Ie,ke,j,$.callback)},startinsert:function(y,$){T(y,$.argString=="!"?"A":"i",{})},redo:Be.commands.redo,undo:Be.commands.undo,write:function(y){Be.commands.save?Be.commands.save(y):y.save&&y.save()},nohlsearch:function(y){br(y)},yank:function(y){var $=Ue(y.getCursor()),_=$.line,P=y.getLine(_);je.registerController.pushText("0","yank",P,!0,!0)},delete:function(y,$){var _=$.selectionLine,P=isNaN($.selectionLineEnd)?_:$.selectionLineEnd;rs.delete(y,{linewise:!0},[{anchor:new De(_,0),head:new De(P+1,0)}])},join:function(y,$){var _=$.selectionLine,P=isNaN($.selectionLineEnd)?_:$.selectionLineEnd;y.setCursor(new De(_,0)),Vn.joinLines(y,{repeat:P-_},y.state.vim)},delmarks:function(y,$){if(!$.argString||!vr($.argString)){$t(y,"Argument required");return}for(var _=y.state.vim,P=new Be.StringStream(vr($.argString));!P.eol();){P.eatSpace();var z=P.pos;if(!P.match(/[a-zA-Z]/,!1)){$t(y,"Invalid argument: "+$.argString.substring(z));return}var j=P.next();if(P.match("-",!0)){if(!P.match(/[a-zA-Z]/,!1)){$t(y,"Invalid argument: "+$.argString.substring(z));return}var q=j,Y=P.next();if(!(c(q)&&c(Y)||s(q)&&s(Y))){$t(y,"Invalid argument: "+q+"-");return}var X=q.charCodeAt(0),re=Y.charCodeAt(0);if(X>=re){$t(y,"Invalid argument: "+$.argString.substring(z));return}for(var ue=0;ue<=re-X;ue++){var be=String.fromCharCode(X+ue);delete _.marks[be]}}else delete _.marks[j]}}},zr=new Aa;M("insertModeEscKeysTimeout",200,"number"),Be.Vim=wt;var Co={return:"CR",backspace:"BS",delete:"Del",esc:"Esc",left:"Left",right:"Right",up:"Up",down:"Down",space:"Space",insert:"Ins",home:"Home",end:"End",pageup:"PageUp",pagedown:"PageDown",enter:"CR"},kr=wt.handleKey.bind(wt);wt.handleKey=function(y,$,_){return y.operation(function(){return kr(y,$,_)},!0)},D(),r.CodeMirror=Be;var ui=wt.maybeInitVimState_;r.handler={$id:"ace/keyboard/vim",drawCursor:function(y,$,_,P,z){var j=this.state.vim||{},q=_.characterWidth,Y=_.lineHeight,X=$.top,re=$.left;if(!j.insertMode){var ue=P.cursor?dr.comparePoints(P.cursor,P.start)<=0:z.selection.isBackwards()||z.selection.isEmpty();!ue&&re>q&&(re-=q)}!j.insertMode&&j.status&&(Y/=2,X+=Y),Zr.translate(y,re,X),Zr.setStyle(y.style,"width",q+"px"),Zr.setStyle(y.style,"height",Y+"px")},$getDirectionForHighlight:function(y){var $=y.state.cm,_=ui($);if(!_.insertMode)return y.session.selection.isBackwards()||y.session.selection.isEmpty()},handleKeyboard:function(y,$,_,P,z){var j=y.editor,q=j.state.cm,Y=ui(q);if(P!=-1){if(Y.insertMode||($==-1?(_.charCodeAt(0)>255&&y.inputKey&&(_=y.inputKey,_&&y.inputHash==4&&(_=_.toUpperCase())),y.inputChar=_):$==4||$==0?y.inputKey==_&&y.inputHash==$&&y.inputChar?(_=y.inputChar,$=-1):(y.inputChar=null,y.inputKey=_,y.inputHash=$):y.inputChar=y.inputKey=null),q.state.overwrite&&Y.insertMode&&_=="backspace"&&$==0)return{command:"gotoleft"};if(_=="c"&&$==1&&!Lo.isMac&&j.getCopyText())return j.once("copy",function(){Y.insertMode?j.selection.clearSelection():q.operation(function(){vn(q)})}),{command:"null",passEvent:!0};if(_=="esc"&&!Y.insertMode&&!Y.visualMode&&!q.ace.inMultiSelectMode){var X=Sn(q),re=X.getOverlay();re&&q.removeOverlay(re)}if($==-1||$&1||$===0&&_.length>1){var ue=Y.insertMode,be=ya($,_,z||{},Y);Y.status==null&&(Y.status="");var ke=es(q,be,"user");return Y=ui(q),ke&&Y.status!=null?Y.status+=be:Y.status==null&&(Y.status=""),q._signal("changeStatus"),!ke&&($!=-1||ue)?void 0:{command:"null",passEvent:!ke}}}},attach:function(y){function $(){var P=ui(_).insertMode;_.ace.renderer.setStyle("normal-mode",!P),y.textInput.setCommandMode(!P),y.renderer.$keepTextAreaAtCursor=P,y.renderer.$blockCursor=!P}y.state||(y.state={});var _=new Be(y);y.state.cm=_,y.$vimModeHandler=this,u(_),ui(_).status=null,_.on("vim-command-done",function(){_.virtualSelectionMode()||(ui(_).status=null,_.ace._signal("changeStatus"),_.ace.session.markUndoGroup())}),_.on("changeStatus",function(){_.ace.renderer.updateCursor(),_.ace._signal("changeStatus")}),_.on("vim-mode-change",function(){_.virtualSelectionMode()||($(),_._signal("changeStatus"))}),$(),y.renderer.$cursorLayer.drawCursor=this.drawCursor.bind(_)},detach:function(y){var $=y.state.cm;d($),$.destroy(),y.state.cm=null,y.$vimModeHandler=null,y.renderer.$cursorLayer.drawCursor=null,y.renderer.setStyle("normal-mode",!1),y.textInput.setCommandMode(!1),y.renderer.$keepTextAreaAtCursor=!0},getStatusText:function(y){var $=y.state.cm,_=ui($);if(_.insertMode)return"INSERT";var P="";return _.visualMode&&(P+="VISUAL",_.visualLine&&(P+=" LINE"),_.visualBlock&&(P+=" BLOCK")),_.status&&(P+=(P?" ":"")+_.status),P}},wt.defineOption({name:"wrap",set:function(y,$){$&&$.ace.setOption("wrap",y)},type:"boolean"},!1),wt.defineEx("write","w",function(){console.log(":write is not implemented")}),Pn.push({keys:"zc",type:"action",action:"fold",actionArgs:{open:!1}},{keys:"zC",type:"action",action:"fold",actionArgs:{open:!1,all:!0}},{keys:"zo",type:"action",action:"fold",actionArgs:{open:!0}},{keys:"zO",type:"action",action:"fold",actionArgs:{open:!0,all:!0}},{keys:"za",type:"action",action:"fold",actionArgs:{toggle:!0}},{keys:"zA",type:"action",action:"fold",actionArgs:{toggle:!0,all:!0}},{keys:"zf",type:"action",action:"fold",actionArgs:{open:!0,all:!0}},{keys:"zd",type:"action",action:"fold",actionArgs:{open:!0,all:!0}},{keys:"<C-A-k>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorAbove"}},{keys:"<C-A-j>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorBelow"}},{keys:"<C-A-S-k>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorAboveSkipCurrent"}},{keys:"<C-A-S-j>",type:"action",action:"aceCommand",actionArgs:{name:"addCursorBelowSkipCurrent"}},{keys:"<C-A-h>",type:"action",action:"aceCommand",actionArgs:{name:"selectMoreBefore"}},{keys:"<C-A-l>",type:"action",action:"aceCommand",actionArgs:{name:"selectMoreAfter"}},{keys:"<C-A-S-h>",type:"action",action:"aceCommand",actionArgs:{name:"selectNextBefore"}},{keys:"<C-A-S-l>",type:"action",action:"aceCommand",actionArgs:{name:"selectNextAfter"}}),Pn.push({keys:"gq",type:"operator",operator:"hardWrap"}),wt.defineOperator("hardWrap",function(y,$,_,P,z){var j=_[0].anchor.line,q=_[0].head.line;return $.linewise&&q--,wo(y.ace,{startRow:j,endRow:q}),De(q,0)}),M("textwidth",void 0,"number",["tw"],function(y,$){if($!==void 0){if(y===void 0){var _=$.ace.getOption("printMarginColumn");return _}var P=Math.round(y);P>1&&$.ace.setOption("printMarginColumn",P)}}),Vn.aceCommand=function(y,$,_){y.vimCmd=$,y.ace.inVirtualSelectionMode?y.ace.on("beforeEndOperation",to):to(null,y.ace)},Vn.fold=function(y,$,_){y.ace.execCommand(["toggleFoldWidget","toggleFoldWidget","foldOther","unfoldall"][($.all?2:0)+($.open?1:0)])},Oo=Pn.length,r.handler.defaultKeymap=Pn,r.handler.actions=Vn,r.Vim=wt}),(function(){ace.require(["ace/keyboard/vim"],function(e){t&&(t.exports=e)})})()})(Cg)),Cg.exports}EA();var _g={},kg;function TA(){return kg||(kg=1,(function(t){(function(){var n={not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function e(w){return m(g(w),arguments)}function r(w,u){return e.apply(null,[w].concat(u||[]))}function m(w,u){var d=1,a=w.length,l,c="",h,o,s,p,b,x,M,R;for(h=0;h<a;h++)if(typeof w[h]=="string")c+=w[h];else if(typeof w[h]=="object"){if(s=w[h],s.keys)for(l=u[d],o=0;o<s.keys.length;o++){if(l==null)throw new Error(e('[sprintf] Cannot access property "%s" of undefined value "%s"',s.keys[o],s.keys[o-1]));l=l[s.keys[o]]}else s.param_no?l=u[s.param_no]:l=u[d++];if(n.not_type.test(s.type)&&n.not_primitive.test(s.type)&&l instanceof Function&&(l=l()),n.numeric_arg.test(s.type)&&typeof l!="number"&&isNaN(l))throw new TypeError(e("[sprintf] expecting number but found %T",l));switch(n.number.test(s.type)&&(M=l>=0),s.type){case"b":l=parseInt(l,10).toString(2);break;case"c":l=String.fromCharCode(parseInt(l,10));break;case"d":case"i":l=parseInt(l,10);break;case"j":l=JSON.stringify(l,null,s.width?parseInt(s.width):0);break;case"e":l=s.precision?parseFloat(l).toExponential(s.precision):parseFloat(l).toExponential();break;case"f":l=s.precision?parseFloat(l).toFixed(s.precision):parseFloat(l);break;case"g":l=s.precision?String(Number(l.toPrecision(s.precision))):parseFloat(l);break;case"o":l=(parseInt(l,10)>>>0).toString(8);break;case"s":l=String(l),l=s.precision?l.substring(0,s.precision):l;break;case"t":l=String(!!l),l=s.precision?l.substring(0,s.precision):l;break;case"T":l=Object.prototype.toString.call(l).slice(8,-1).toLowerCase(),l=s.precision?l.substring(0,s.precision):l;break;case"u":l=parseInt(l,10)>>>0;break;case"v":l=l.valueOf(),l=s.precision?l.substring(0,s.precision):l;break;case"x":l=(parseInt(l,10)>>>0).toString(16);break;case"X":l=(parseInt(l,10)>>>0).toString(16).toUpperCase();break}n.json.test(s.type)?c+=l:(n.number.test(s.type)&&(!M||s.sign)?(R=M?"+":"-",l=l.toString().replace(n.sign,"")):R="",b=s.pad_char?s.pad_char==="0"?"0":s.pad_char.charAt(1):" ",x=s.width-(R+l).length,p=s.width&&x>0?b.repeat(x):"",c+=s.align?R+l+p:b==="0"?R+p+l:p+R+l)}return c}var f=Object.create(null);function g(w){if(f[w])return f[w];for(var u=w,d,a=[],l=0;u;){if((d=n.text.exec(u))!==null)a.push(d[0]);else if((d=n.modulo.exec(u))!==null)a.push("%");else if((d=n.placeholder.exec(u))!==null){if(d[2]){l|=1;var c=[],h=d[2],o=[];if((o=n.key.exec(h))!==null)for(c.push(o[1]);(h=h.substring(o[0].length))!=="";)if((o=n.key_access.exec(h))!==null)c.push(o[1]);else if((o=n.index_access.exec(h))!==null)c.push(o[1]);else throw new SyntaxError("[sprintf] failed to parse named argument key");else throw new SyntaxError("[sprintf] failed to parse named argument key");d[2]=c}else l|=2;if(l===3)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");a.push({placeholder:d[0],param_no:d[1],keys:d[2],sign:d[3],pad_char:d[4],align:d[5],width:d[6],precision:d[7],type:d[8]})}else throw new SyntaxError("[sprintf] unexpected placeholder");u=u.substring(d[0].length)}return f[w]=a}t.sprintf=e,t.vsprintf=r,typeof window<"u"&&(window.sprintf=e,window.vsprintf=r)})()})(_g)),_g}TA();var Gl={exports:{}},MA=Gl.exports,Sg;function IA(){return Sg||(Sg=1,(function(t,n){(function(){var e,r="4.18.1",m=200,f="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",g="Expected a function",w="Invalid `variable` option passed into `_.template`",u="Invalid `imports` option passed into `_.template`",d="__lodash_hash_undefined__",a=500,l="__lodash_placeholder__",c=1,h=2,o=4,s=1,p=2,b=1,x=2,M=4,R=8,k=16,C=32,L=64,D=128,I=256,T=512,W=30,F="...",O=800,S=16,A=1,N=2,B=3,U=1/0,G=9007199254740991,J=17976931348623157e292,ne=NaN,de=4294967295,ee=de-1,se=de>>>1,ce=[["ary",D],["bind",b],["bindKey",x],["curry",R],["curryRight",k],["flip",T],["partial",C],["partialRight",L],["rearg",I]],le="[object Arguments]",pe="[object Array]",me="[object AsyncFunction]",$e="[object Boolean]",Ee="[object Date]",He="[object DOMException]",Ue="[object Error]",ot="[object Function]",Qe="[object GeneratorFunction]",lt="[object Map]",Tt="[object Number]",ur="[object Null]",At="[object Object]",vr="[object Promise]",Dn="[object Proxy]",Kn="[object RegExp]",un="[object Set]",Yn="[object String]",gt="[object Symbol]",Je="[object Undefined]",Ft="[object WeakMap]",An="[object WeakSet]",_n="[object ArrayBuffer]",kn="[object DataView]",mn="[object Float32Array]",vn="[object Float64Array]",Wn="[object Int8Array]",Jn="[object Int16Array]",Jt="[object Int32Array]",jn="[object Uint8Array]",oi="[object Uint8ClampedArray]",Or="[object Uint16Array]",Rn="[object Uint32Array]",yr=/\b__p \+= '';/g,bi=/\b(__p \+=) '' \+/g,rr=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Xi=/&(?:amp|lt|gt|quot|#39);/g,wi=/[&<>"']/g,Eo=RegExp(Xi.source),Yr=RegExp(wi.source),Qi=/<%-([\s\S]+?)%>/g,Jo=/<%([\s\S]+?)%>/g,To=/<%=([\s\S]+?)%>/g,Zt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,fn=/^\w*$/,Nr=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Dr=/[\\^$.*+?()[\]{}|]/g,Sn=RegExp(Dr.source),Zn=/^\s+/,xi=/\s/,Ci=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Jr=/\{\n\/\* \[wrapped with (.+)\] \*/,si=/,? & /,Zo=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,Mo=/[()=,{}\[\]\/\s]/,ai=/\\(\\)?/g,_r=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,$t=/\w*$/,eo=/^[-+]0x[0-9a-f]+$/i,bn=/^0b[01]+$/i,En=/^\[object .+?Constructor\]$/,hn=/^0o[0-7]+$/i,Tn=/^(?:0|[1-9]\d*)$/,Ni=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Hn=/($^)/,li=/['\n\r\u2028\u2029\\]/g,br="\\ud800-\\udfff",oe="\\u0300-\\u036f",Ne="\\ufe20-\\ufe2f",ze="\\u20d0-\\u20ff",mt=oe+Ne+ze,Ot="\\u2700-\\u27bf",Mt="a-z\\xdf-\\xf6\\xf8-\\xff",wr="\\xac\\xb1\\xd7\\xf7",xr="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",hr="\\u2000-\\u206f",ci=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ht="A-Z\\xc0-\\xd6\\xd8-\\xde",go="\\ufe0e\\ufe0f",mo=wr+xr+hr+ci,vo="['’]",Es="["+br+"]",Xo="["+mo+"]",Io="["+mt+"]",Ts="\\d+",Ms="["+Ot+"]",Qo="["+Mt+"]",ya="[^"+br+mo+Ts+Ot+Mt+Ht+"]",yo="\\ud83c[\\udffb-\\udfff]",es="(?:"+Io+"|"+yo+")",to="[^"+br+"]",dr="(?:\\ud83c[\\udde6-\\uddff]){2}",Is="[\\ud800-\\udbff][\\udc00-\\udfff]",Zr="["+Ht+"]",ba="\\u200d",wa="(?:"+Qo+"|"+ya+")",ts="(?:"+Zr+"|"+ya+")",no="(?:"+vo+"(?:d|ll|m|re|s|t|ve))?",Lo="(?:"+vo+"(?:D|LL|M|RE|S|T|VE))?",ns=es+"?",bo="["+go+"]?",xa="(?:"+ba+"(?:"+[to,dr,Is].join("|")+")"+bo+ns+")*",wo="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Be="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Ls=bo+ns+xa,De="(?:"+[Ms,dr,Is].join("|")+")"+Ls,Pn="(?:"+[to+Io+"?",Io,dr,Is,Es].join("|")+")",Oo=RegExp(vo,"g"),ro=RegExp(Io,"g"),Fn=RegExp(yo+"(?="+yo+")|"+Pn+Ls,"g"),Ca=RegExp([Zr+"?"+Qo+"+"+no+"(?="+[Xo,Zr,"$"].join("|")+")",ts+"+"+Lo+"(?="+[Xo,Zr+wa,"$"].join("|")+")",Zr+"?"+wa+"+"+no,Zr+"+"+Lo,Be,wo,Ts,De].join("|"),"g"),No=RegExp("["+ba+br+mt+go+"]"),Di=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,xo=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Os=-1,nn={};nn[mn]=nn[vn]=nn[Wn]=nn[Jn]=nn[Jt]=nn[jn]=nn[oi]=nn[Or]=nn[Rn]=!0,nn[le]=nn[pe]=nn[_n]=nn[$e]=nn[kn]=nn[Ee]=nn[Ue]=nn[ot]=nn[lt]=nn[Tt]=nn[At]=nn[Kn]=nn[un]=nn[Yn]=nn[Ft]=!1;var ct={};ct[le]=ct[pe]=ct[_n]=ct[kn]=ct[$e]=ct[Ee]=ct[mn]=ct[vn]=ct[Wn]=ct[Jn]=ct[Jt]=ct[lt]=ct[Tt]=ct[At]=ct[Kn]=ct[un]=ct[Yn]=ct[gt]=ct[jn]=ct[oi]=ct[Or]=ct[Rn]=!0,ct[Ue]=ct[ot]=ct[Ft]=!1;var qt={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},Pi={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},Un={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},je={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},wn=parseFloat,wt=parseInt,Pr=typeof Go=="object"&&Go&&Go.Object===Object&&Go,Fi=typeof self=="object"&&self&&self.Object===Object&&self,zt=Pr||Fi||Function("return this")(),Fr=n&&!n.nodeType&&n,ir=Fr&&!0&&t&&!t.nodeType&&t,io=ir&&ir.exports===Fr,Ai=io&&Pr.process,Mn=(function(){try{var ve=ir&&ir.require&&ir.require("util").types;return ve||Ai&&Ai.binding&&Ai.binding("util")}catch{}})(),rs=Mn&&Mn.isArrayBuffer,Vn=Mn&&Mn.isDate,_i=Mn&&Mn.isMap,ki=Mn&&Mn.isRegExp,zi=Mn&&Mn.isSet,Ns=Mn&&Mn.isTypedArray;function on(ve,Re,Se){switch(Se.length){case 0:return ve.call(Re);case 1:return ve.call(Re,Se[0]);case 2:return ve.call(Re,Se[0],Se[1]);case 3:return ve.call(Re,Se[0],Se[1],Se[2])}return ve.apply(Re,Se)}function Aa(ve,Re,Se,qe){for(var ht=-1,kt=ve==null?0:ve.length;++ht<kt;){var en=ve[ht];Re(qe,en,Se(en),ve)}return qe}function fr(ve,Re){for(var Se=-1,qe=ve==null?0:ve.length;++Se<qe&&Re(ve[Se],Se,ve)!==!1;);return ve}function zr(ve,Re){for(var Se=ve==null?0:ve.length;Se--&&Re(ve[Se],Se,ve)!==!1;);return ve}function Co(ve,Re){for(var Se=-1,qe=ve==null?0:ve.length;++Se<qe;)if(!Re(ve[Se],Se,ve))return!1;return!0}function kr(ve,Re){for(var Se=-1,qe=ve==null?0:ve.length,ht=0,kt=[];++Se<qe;){var en=ve[Se];Re(en,Se,ve)&&(kt[ht++]=en)}return kt}function ui(ve,Re){var Se=ve==null?0:ve.length;return!!Se&&be(ve,Re,0)>-1}function y(ve,Re,Se){for(var qe=-1,ht=ve==null?0:ve.length;++qe<ht;)if(Se(Re,ve[qe]))return!0;return!1}function $(ve,Re){for(var Se=-1,qe=ve==null?0:ve.length,ht=Array(qe);++Se<qe;)ht[Se]=Re(ve[Se],Se,ve);return ht}function _(ve,Re){for(var Se=-1,qe=Re.length,ht=ve.length;++Se<qe;)ve[ht+Se]=Re[Se];return ve}function P(ve,Re,Se,qe){var ht=-1,kt=ve==null?0:ve.length;for(qe&&kt&&(Se=ve[++ht]);++ht<kt;)Se=Re(Se,ve[ht],ht,ve);return Se}function z(ve,Re,Se,qe){var ht=ve==null?0:ve.length;for(qe&&ht&&(Se=ve[--ht]);ht--;)Se=Re(Se,ve[ht],ht,ve);return Se}function j(ve,Re){for(var Se=-1,qe=ve==null?0:ve.length;++Se<qe;)if(Re(ve[Se],Se,ve))return!0;return!1}var q=Oe("length");function Y(ve){return ve.split("")}function X(ve){return ve.match(Zo)||[]}function re(ve,Re,Se){var qe;return Se(ve,function(ht,kt,en){if(Re(ht,kt,en))return qe=kt,!1}),qe}function ue(ve,Re,Se,qe){for(var ht=ve.length,kt=Se+(qe?1:-1);qe?kt--:++kt<ht;)if(Re(ve[kt],kt,ve))return kt;return-1}function be(ve,Re,Se){return Re===Re?xt(ve,Re,Se):ue(ve,ye,Se)}function ke(ve,Re,Se,qe){for(var ht=Se-1,kt=ve.length;++ht<kt;)if(qe(ve[ht],Re))return ht;return-1}function ye(ve){return ve!==ve}function Ae(ve,Re){var Se=ve==null?0:ve.length;return Se?Ze(ve,Re)/Se:ne}function Oe(ve){return function(Re){return Re==null?e:Re[ve]}}function Ie(ve){return function(Re){return ve==null?e:ve[Re]}}function Ge(ve,Re,Se,qe,ht){return ht(ve,function(kt,en,Wt){Se=qe?(qe=!1,kt):Re(Se,kt,en,Wt)}),Se}function ut(ve,Re){var Se=ve.length;for(ve.sort(Re);Se--;)ve[Se]=ve[Se].value;return ve}function Ze(ve,Re){for(var Se,qe=-1,ht=ve.length;++qe<ht;){var kt=Re(ve[qe]);kt!==e&&(Se=Se===e?kt:Se+kt)}return Se}function et(ve,Re){for(var Se=-1,qe=Array(ve);++Se<ve;)qe[Se]=Re(Se);return qe}function $n(ve,Re){return $(Re,function(Se){return[Se,ve[Se]]})}function Ct(ve){return ve&&ve.slice(0,ft(ve)+1).replace(Zn,"")}function Yt(ve){return function(Re){return ve(Re)}}function It(ve,Re){return $(Re,function(Se){return ve[Se]})}function _t(ve,Re){return ve.has(Re)}function or(ve,Re){for(var Se=-1,qe=ve.length;++Se<qe&&be(Re,ve[Se],0)>-1;);return Se}function pr(ve,Re){for(var Se=ve.length;Se--&&be(Re,ve[Se],0)>-1;);return Se}function In(ve,Re){for(var Se=ve.length,qe=0;Se--;)ve[Se]===Re&&++qe;return qe}var V=Ie(qt),Z=Ie(Pi);function ie(ve){return"\\"+je[ve]}function ae(ve,Re){return ve==null?e:ve[Re]}function ge(ve){return No.test(ve)}function _e(ve){return Di.test(ve)}function Te(ve){for(var Re,Se=[];!(Re=ve.next()).done;)Se.push(Re.value);return Se}function Fe(ve){var Re=-1,Se=Array(ve.size);return ve.forEach(function(qe,ht){Se[++Re]=[ht,qe]}),Se}function We(ve,Re){return function(Se){return ve(Re(Se))}}function Ve(ve,Re){for(var Se=-1,qe=ve.length,ht=0,kt=[];++Se<qe;){var en=ve[Se];(en===Re||en===l)&&(ve[Se]=l,kt[ht++]=Se)}return kt}function Ke(ve){var Re=-1,Se=Array(ve.size);return ve.forEach(function(qe){Se[++Re]=qe}),Se}function Xe(ve){var Re=-1,Se=Array(ve.size);return ve.forEach(function(qe){Se[++Re]=[qe,qe]}),Se}function xt(ve,Re,Se){for(var qe=Se-1,ht=ve.length;++qe<ht;)if(ve[qe]===Re)return qe;return-1}function Xt(ve,Re,Se){for(var qe=Se+1;qe--;)if(ve[qe]===Re)return qe;return qe}function Bt(ve){return ge(ve)?yn(ve):q(ve)}function bt(ve){return ge(ve)?Ln(ve):Y(ve)}function ft(ve){for(var Re=ve.length;Re--&&xi.test(ve.charAt(Re)););return Re}var at=Ie(Un);function yn(ve){for(var Re=Fn.lastIndex=0;Fn.test(ve);)++Re;return Re}function Ln(ve){return ve.match(Fn)||[]}function sr(ve){return ve.match(Ca)||[]}var sn=(function ve(Re){Re=Re==null?zt:dn.defaults(zt.Object(),Re,dn.pick(zt,xo));var Se=Re.Array,qe=Re.Date,ht=Re.Error,kt=Re.Function,en=Re.Math,Wt=Re.Object,hi=Re.RegExp,Sr=Re.String,xn=Re.TypeError,Bi=Se.prototype,$r=kt.prototype,Do=Wt.prototype,Ec=Re["__core-js_shared__"],Tc=$r.toString,an=Do.hasOwnProperty,ST=0,ab=(function(){var i=/[^.]+$/.exec(Ec&&Ec.keys&&Ec.keys.IE_PROTO||"");return i?"Symbol(src)_1."+i:""})(),Mc=Do.toString,$T=Tc.call(Wt),RT=zt._,ET=hi("^"+Tc.call(an).replace(Dr,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ic=io?Re.Buffer:e,is=Re.Symbol,Lc=Re.Uint8Array,lb=Ic?Ic.allocUnsafe:e,Oc=We(Wt.getPrototypeOf,Wt),cb=Wt.create,ub=Do.propertyIsEnumerable,Nc=Bi.splice,hb=is?is.isConcatSpreadable:e,hl=is?is.iterator:e,Ds=is?is.toStringTag:e,Dc=(function(){try{var i=Ws(Wt,"defineProperty");return i({},"",{}),i}catch{}})(),TT=Re.clearTimeout!==zt.clearTimeout&&Re.clearTimeout,MT=qe&&qe.now!==zt.Date.now&&qe.now,IT=Re.setTimeout!==zt.setTimeout&&Re.setTimeout,Pc=en.ceil,Fc=en.floor,Ed=Wt.getOwnPropertySymbols,LT=Ic?Ic.isBuffer:e,db=Re.isFinite,OT=Bi.join,NT=We(Wt.keys,Wt),gr=en.max,Br=en.min,DT=qe.now,PT=Re.parseInt,fb=en.random,FT=Bi.reverse,Td=Ws(Re,"DataView"),dl=Ws(Re,"Map"),Md=Ws(Re,"Promise"),_a=Ws(Re,"Set"),fl=Ws(Re,"WeakMap"),pl=Ws(Wt,"create"),zc=fl&&new fl,ka={},zT=js(Td),BT=js(dl),WT=js(Md),jT=js(_a),HT=js(fl),Bc=is?is.prototype:e,gl=Bc?Bc.valueOf:e,pb=Bc?Bc.toString:e;function Q(i){if(qn(i)&&!Rt(i)&&!(i instanceof Gt)){if(i instanceof Wi)return i;if(an.call(i,"__wrapped__"))return g0(i)}return new Wi(i)}var Sa=(function(){function i(){}return function(v){if(!zn(v))return{};if(cb)return cb(v);i.prototype=v;var E=new i;return i.prototype=e,E}})();function Wc(){}function Wi(i,v){this.__wrapped__=i,this.__actions__=[],this.__chain__=!!v,this.__index__=0,this.__values__=e}Q.templateSettings={escape:Qi,evaluate:Jo,interpolate:To,variable:"",imports:{_:Q}},Q.prototype=Wc.prototype,Q.prototype.constructor=Q,Wi.prototype=Sa(Wc.prototype),Wi.prototype.constructor=Wi;function Gt(i){this.__wrapped__=i,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=de,this.__views__=[]}function UT(){var i=new Gt(this.__wrapped__);return i.__actions__=di(this.__actions__),i.__dir__=this.__dir__,i.__filtered__=this.__filtered__,i.__iteratees__=di(this.__iteratees__),i.__takeCount__=this.__takeCount__,i.__views__=di(this.__views__),i}function VT(){if(this.__filtered__){var i=new Gt(this);i.__dir__=-1,i.__filtered__=!0}else i=this.clone(),i.__dir__*=-1;return i}function qT(){var i=this.__wrapped__.value(),v=this.__dir__,E=Rt(i),H=v<0,K=E?i.length:0,te=iI(0,K,this.__views__),he=te.start,fe=te.end,we=fe-he,Me=H?fe:he-1,Le=this.__iteratees__,Pe=Le.length,Ye=0,st=Br(we,this.__takeCount__);if(!E||!H&&K==we&&st==we)return Fb(i,this.__actions__);var yt=[];e:for(;we--&&Ye<st;){Me+=v;for(var Dt=-1,pt=i[Me];++Dt<Pe;){var Ut=Le[Dt],Kt=Ut.iteratee,Ri=Ut.type,ei=Kt(pt);if(Ri==N)pt=ei;else if(!ei){if(Ri==A)continue e;break e}}yt[Ye++]=pt}return yt}Gt.prototype=Sa(Wc.prototype),Gt.prototype.constructor=Gt;function Ps(i){var v=-1,E=i==null?0:i.length;for(this.clear();++v<E;){var H=i[v];this.set(H[0],H[1])}}function GT(){this.__data__=pl?pl(null):{},this.size=0}function KT(i){var v=this.has(i)&&delete this.__data__[i];return this.size-=v?1:0,v}function YT(i){var v=this.__data__;if(pl){var E=v[i];return E===d?e:E}return an.call(v,i)?v[i]:e}function JT(i){var v=this.__data__;return pl?v[i]!==e:an.call(v,i)}function ZT(i,v){var E=this.__data__;return this.size+=this.has(i)?0:1,E[i]=pl&&v===e?d:v,this}Ps.prototype.clear=GT,Ps.prototype.delete=KT,Ps.prototype.get=YT,Ps.prototype.has=JT,Ps.prototype.set=ZT;function Po(i){var v=-1,E=i==null?0:i.length;for(this.clear();++v<E;){var H=i[v];this.set(H[0],H[1])}}function XT(){this.__data__=[],this.size=0}function QT(i){var v=this.__data__,E=jc(v,i);if(E<0)return!1;var H=v.length-1;return E==H?v.pop():Nc.call(v,E,1),--this.size,!0}function eM(i){var v=this.__data__,E=jc(v,i);return E<0?e:v[E][1]}function tM(i){return jc(this.__data__,i)>-1}function nM(i,v){var E=this.__data__,H=jc(E,i);return H<0?(++this.size,E.push([i,v])):E[H][1]=v,this}Po.prototype.clear=XT,Po.prototype.delete=QT,Po.prototype.get=eM,Po.prototype.has=tM,Po.prototype.set=nM;function Fo(i){var v=-1,E=i==null?0:i.length;for(this.clear();++v<E;){var H=i[v];this.set(H[0],H[1])}}function rM(){this.size=0,this.__data__={hash:new Ps,map:new(dl||Po),string:new Ps}}function iM(i){var v=eu(this,i).delete(i);return this.size-=v?1:0,v}function oM(i){return eu(this,i).get(i)}function sM(i){return eu(this,i).has(i)}function aM(i,v){var E=eu(this,i),H=E.size;return E.set(i,v),this.size+=E.size==H?0:1,this}Fo.prototype.clear=rM,Fo.prototype.delete=iM,Fo.prototype.get=oM,Fo.prototype.has=sM,Fo.prototype.set=aM;function Fs(i){var v=-1,E=i==null?0:i.length;for(this.__data__=new Fo;++v<E;)this.add(i[v])}function lM(i){return this.__data__.set(i,d),this}function cM(i){return this.__data__.has(i)}Fs.prototype.add=Fs.prototype.push=lM,Fs.prototype.has=cM;function oo(i){var v=this.__data__=new Po(i);this.size=v.size}function uM(){this.__data__=new Po,this.size=0}function hM(i){var v=this.__data__,E=v.delete(i);return this.size=v.size,E}function dM(i){return this.__data__.get(i)}function fM(i){return this.__data__.has(i)}function pM(i,v){var E=this.__data__;if(E instanceof Po){var H=E.__data__;if(!dl||H.length<m-1)return H.push([i,v]),this.size=++E.size,this;E=this.__data__=new Fo(H)}return E.set(i,v),this.size=E.size,this}oo.prototype.clear=uM,oo.prototype.delete=hM,oo.prototype.get=dM,oo.prototype.has=fM,oo.prototype.set=pM;function gb(i,v){var E=Rt(i),H=!E&&Hs(i),K=!E&&!H&&cs(i),te=!E&&!H&&!K&&Ta(i),he=E||H||K||te,fe=he?et(i.length,Sr):[],we=fe.length;for(var Me in i)(v||an.call(i,Me))&&!(he&&(Me=="length"||K&&(Me=="offset"||Me=="parent")||te&&(Me=="buffer"||Me=="byteLength"||Me=="byteOffset")||Wo(Me,we)))&&fe.push(Me);return fe}function mb(i){var v=i.length;return v?i[jd(0,v-1)]:e}function gM(i,v){return tu(di(i),zs(v,0,i.length))}function mM(i){return tu(di(i))}function Id(i,v,E){(E!==e&&!ao(i[v],E)||E===e&&!(v in i))&&Ao(i,v,E)}function ml(i,v,E){var H=i[v];(!(an.call(i,v)&&ao(H,E))||E===e&&!(v in i))&&Ao(i,v,E)}function jc(i,v){for(var E=i.length;E--;)if(ao(i[E][0],v))return E;return-1}function vM(i,v,E,H){return os(i,function(K,te,he){v(H,K,E(K),he)}),H}function vb(i,v){return i&&ko(v,Cr(v),i)}function yM(i,v){return i&&ko(v,pi(v),i)}function Ao(i,v,E){v=="__proto__"&&Dc?Dc(i,v,{configurable:!0,enumerable:!0,value:E,writable:!0}):i[v]=E}function Ld(i,v){for(var E=-1,H=v.length,K=Se(H),te=i==null;++E<H;)K[E]=te?e:gf(i,v[E]);return K}function zs(i,v,E){return i===i&&(E!==e&&(i=i<=E?i:E),v!==e&&(i=i>=v?i:v)),i}function ji(i,v,E,H,K,te){var he,fe=v&c,we=v&h,Me=v&o;if(E&&(he=K?E(i,H,K,te):E(i)),he!==e)return he;if(!zn(i))return i;var Le=Rt(i);if(Le){if(he=sI(i),!fe)return di(i,he)}else{var Pe=Wr(i),Ye=Pe==ot||Pe==Qe;if(cs(i))return Wb(i,fe);if(Pe==At||Pe==le||Ye&&!K){if(he=we||Ye?{}:s0(i),!fe)return we?YM(i,yM(he,i)):KM(i,vb(he,i))}else{if(!ct[Pe])return K?i:{};he=aI(i,Pe,fe)}}te||(te=new oo);var st=te.get(i);if(st)return st;te.set(i,he),N0(i)?i.forEach(function(pt){he.add(ji(pt,v,E,pt,i,te))}):L0(i)&&i.forEach(function(pt,Ut){he.set(Ut,ji(pt,v,E,Ut,i,te))});var yt=Me?we?Qd:Xd:we?pi:Cr,Dt=Le?e:yt(i);return fr(Dt||i,function(pt,Ut){Dt&&(Ut=pt,pt=i[Ut]),ml(he,Ut,ji(pt,v,E,Ut,i,te))}),he}function bM(i){var v=Cr(i);return function(E){return yb(E,i,v)}}function yb(i,v,E){var H=E.length;if(i==null)return!H;for(i=Wt(i);H--;){var K=E[H],te=v[K],he=i[K];if(he===e&&!(K in i)||!te(he))return!1}return!0}function bb(i,v,E){if(typeof i!="function")throw new xn(g);return Al(function(){i.apply(e,E)},v)}function vl(i,v,E,H){var K=-1,te=ui,he=!0,fe=i.length,we=[],Me=v.length;if(!fe)return we;E&&(v=$(v,Yt(E))),H?(te=y,he=!1):v.length>=m&&(te=_t,he=!1,v=new Fs(v));e:for(;++K<fe;){var Le=i[K],Pe=E==null?Le:E(Le);if(Le=H||Le!==0?Le:0,he&&Pe===Pe){for(var Ye=Me;Ye--;)if(v[Ye]===Pe)continue e;we.push(Le)}else te(v,Pe,H)||we.push(Le)}return we}var os=qb(_o),wb=qb(Nd,!0);function wM(i,v){var E=!0;return os(i,function(H,K,te){return E=!!v(H,K,te),E}),E}function Hc(i,v,E){for(var H=-1,K=i.length;++H<K;){var te=i[H],he=v(te);if(he!=null&&(fe===e?he===he&&!$i(he):E(he,fe)))var fe=he,we=te}return we}function xM(i,v,E,H){var K=i.length;for(E=Nt(E),E<0&&(E=-E>K?0:K+E),H=H===e||H>K?K:Nt(H),H<0&&(H+=K),H=E>H?0:P0(H);E<H;)i[E++]=v;return i}function xb(i,v){var E=[];return os(i,function(H,K,te){v(H,K,te)&&E.push(H)}),E}function Rr(i,v,E,H,K){var te=-1,he=i.length;for(E||(E=cI),K||(K=[]);++te<he;){var fe=i[te];v>0&&E(fe)?v>1?Rr(fe,v-1,E,H,K):_(K,fe):H||(K[K.length]=fe)}return K}var Od=Gb(),Cb=Gb(!0);function _o(i,v){return i&&Od(i,v,Cr)}function Nd(i,v){return i&&Cb(i,v,Cr)}function Uc(i,v){return kr(v,function(E){return jo(i[E])})}function Bs(i,v){v=as(v,i);for(var E=0,H=v.length;i!=null&&E<H;)i=i[so(v[E++])];return E&&E==H?i:e}function Ab(i,v,E){var H=v(i);return Rt(i)?H:_(H,E(i))}function Xr(i){return i==null?i===e?Je:ur:Ds&&Ds in Wt(i)?rI(i):mI(i)}function Dd(i,v){return i>v}function CM(i,v){return i!=null&&an.call(i,v)}function AM(i,v){return i!=null&&v in Wt(i)}function _M(i,v,E){return i>=Br(v,E)&&i<gr(v,E)}function Pd(i,v,E){for(var H=E?y:ui,K=i[0].length,te=i.length,he=te,fe=Se(te),we=1/0,Me=[];he--;){var Le=i[he];he&&v&&(Le=$(Le,Yt(v))),we=Br(Le.length,we),fe[he]=!E&&(v||K>=120&&Le.length>=120)?new Fs(he&&Le):e}Le=i[0];var Pe=-1,Ye=fe[0];e:for(;++Pe<K&&Me.length<we;){var st=Le[Pe],yt=v?v(st):st;if(st=E||st!==0?st:0,!(Ye?_t(Ye,yt):H(Me,yt,E))){for(he=te;--he;){var Dt=fe[he];if(!(Dt?_t(Dt,yt):H(i[he],yt,E)))continue e}Ye&&Ye.push(yt),Me.push(st)}}return Me}function kM(i,v,E,H){return _o(i,function(K,te,he){v(H,E(K),te,he)}),H}function yl(i,v,E){v=as(v,i),i=u0(i,v);var H=i==null?i:i[so(Ui(v))];return H==null?e:on(H,i,E)}function _b(i){return qn(i)&&Xr(i)==le}function SM(i){return qn(i)&&Xr(i)==_n}function $M(i){return qn(i)&&Xr(i)==Ee}function bl(i,v,E,H,K){return i===v?!0:i==null||v==null||!qn(i)&&!qn(v)?i!==i&&v!==v:RM(i,v,E,H,bl,K)}function RM(i,v,E,H,K,te){var he=Rt(i),fe=Rt(v),we=he?pe:Wr(i),Me=fe?pe:Wr(v);we=we==le?At:we,Me=Me==le?At:Me;var Le=we==At,Pe=Me==At,Ye=we==Me;if(Ye&&cs(i)){if(!cs(v))return!1;he=!0,Le=!1}if(Ye&&!Le)return te||(te=new oo),he||Ta(i)?r0(i,v,E,H,K,te):tI(i,v,we,E,H,K,te);if(!(E&s)){var st=Le&&an.call(i,"__wrapped__"),yt=Pe&&an.call(v,"__wrapped__");if(st||yt){var Dt=st?i.value():i,pt=yt?v.value():v;return te||(te=new oo),K(Dt,pt,E,H,te)}}return Ye?(te||(te=new oo),nI(i,v,E,H,K,te)):!1}function EM(i){return qn(i)&&Wr(i)==lt}function Fd(i,v,E,H){var K=E.length,te=K,he=!H;if(i==null)return!te;for(i=Wt(i);K--;){var fe=E[K];if(he&&fe[2]?fe[1]!==i[fe[0]]:!(fe[0]in i))return!1}for(;++K<te;){fe=E[K];var we=fe[0],Me=i[we],Le=fe[1];if(he&&fe[2]){if(Me===e&&!(we in i))return!1}else{var Pe=new oo;if(H)var Ye=H(Me,Le,we,i,v,Pe);if(!(Ye===e?bl(Le,Me,s|p,H,Pe):Ye))return!1}}return!0}function kb(i){if(!zn(i)||hI(i))return!1;var v=jo(i)?ET:En;return v.test(js(i))}function TM(i){return qn(i)&&Xr(i)==Kn}function MM(i){return qn(i)&&Wr(i)==un}function IM(i){return qn(i)&&au(i.length)&&!!nn[Xr(i)]}function Sb(i){return typeof i=="function"?i:i==null?gi:typeof i=="object"?Rt(i)?Eb(i[0],i[1]):Rb(i):Y0(i)}function zd(i){if(!Cl(i))return NT(i);var v=[];for(var E in Wt(i))an.call(i,E)&&E!="constructor"&&v.push(E);return v}function LM(i){if(!zn(i))return gI(i);var v=Cl(i),E=[];for(var H in i)H=="constructor"&&(v||!an.call(i,H))||E.push(H);return E}function Bd(i,v){return i<v}function $b(i,v){var E=-1,H=fi(i)?Se(i.length):[];return os(i,function(K,te,he){H[++E]=v(K,te,he)}),H}function Rb(i){var v=tf(i);return v.length==1&&v[0][2]?l0(v[0][0],v[0][1]):function(E){return E===i||Fd(E,i,v)}}function Eb(i,v){return rf(i)&&a0(v)?l0(so(i),v):function(E){var H=gf(E,i);return H===e&&H===v?mf(E,i):bl(v,H,s|p)}}function Vc(i,v,E,H,K){i!==v&&Od(v,function(te,he){if(K||(K=new oo),zn(te))OM(i,v,he,E,Vc,H,K);else{var fe=H?H(sf(i,he),te,he+"",i,v,K):e;fe===e&&(fe=te),Id(i,he,fe)}},pi)}function OM(i,v,E,H,K,te,he){var fe=sf(i,E),we=sf(v,E),Me=he.get(we);if(Me){Id(i,E,Me);return}var Le=te?te(fe,we,E+"",i,v,he):e,Pe=Le===e;if(Pe){var Ye=Rt(we),st=!Ye&&cs(we),yt=!Ye&&!st&&Ta(we);Le=we,Ye||st||yt?Rt(fe)?Le=fe:Xn(fe)?Le=di(fe):st?(Pe=!1,Le=Wb(we,!0)):yt?(Pe=!1,Le=jb(we,!0)):Le=[]:_l(we)||Hs(we)?(Le=fe,Hs(fe)?Le=F0(fe):(!zn(fe)||jo(fe))&&(Le=s0(we))):Pe=!1}Pe&&(he.set(we,Le),K(Le,we,H,te,he),he.delete(we)),Id(i,E,Le)}function Tb(i,v){var E=i.length;if(E)return v+=v<0?E:0,Wo(v,E)?i[v]:e}function Mb(i,v,E){v.length?v=$(v,function(te){return Rt(te)?function(he){return Bs(he,te.length===1?te[0]:te)}:te}):v=[gi];var H=-1;v=$(v,Yt(vt()));var K=$b(i,function(te,he,fe){var we=$(v,function(Me){return Me(te)});return{criteria:we,index:++H,value:te}});return ut(K,function(te,he){return GM(te,he,E)})}function NM(i,v){return Ib(i,v,function(E,H){return mf(i,H)})}function Ib(i,v,E){for(var H=-1,K=v.length,te={};++H<K;){var he=v[H],fe=Bs(i,he);E(fe,he)&&wl(te,as(he,i),fe)}return te}function DM(i){return function(v){return Bs(v,i)}}function Wd(i,v,E,H){var K=H?ke:be,te=-1,he=v.length,fe=i;for(i===v&&(v=di(v)),E&&(fe=$(i,Yt(E)));++te<he;)for(var we=0,Me=v[te],Le=E?E(Me):Me;(we=K(fe,Le,we,H))>-1;)fe!==i&&Nc.call(fe,we,1),Nc.call(i,we,1);return i}function Lb(i,v){for(var E=i?v.length:0,H=E-1;E--;){var K=v[E];if(E==H||K!==te){var te=K;Wo(K)?Nc.call(i,K,1):Vd(i,K)}}return i}function jd(i,v){return i+Fc(fb()*(v-i+1))}function PM(i,v,E,H){for(var K=-1,te=gr(Pc((v-i)/(E||1)),0),he=Se(te);te--;)he[H?te:++K]=i,i+=E;return he}function Hd(i,v){var E="";if(!i||v<1||v>G)return E;do v%2&&(E+=i),v=Fc(v/2),v&&(i+=i);while(v);return E}function jt(i,v){return af(c0(i,v,gi),i+"")}function FM(i){return mb(Ma(i))}function zM(i,v){var E=Ma(i);return tu(E,zs(v,0,E.length))}function wl(i,v,E,H){if(!zn(i))return i;v=as(v,i);for(var K=-1,te=v.length,he=te-1,fe=i;fe!=null&&++K<te;){var we=so(v[K]),Me=E;if(we==="__proto__"||we==="constructor"||we==="prototype")return i;if(K!=he){var Le=fe[we];Me=H?H(Le,we,fe):e,Me===e&&(Me=zn(Le)?Le:Wo(v[K+1])?[]:{})}ml(fe,we,Me),fe=fe[we]}return i}var Ob=zc?function(i,v){return zc.set(i,v),i}:gi,BM=Dc?function(i,v){return Dc(i,"toString",{configurable:!0,enumerable:!1,value:yf(v),writable:!0})}:gi;function WM(i){return tu(Ma(i))}function Hi(i,v,E){var H=-1,K=i.length;v<0&&(v=-v>K?0:K+v),E=E>K?K:E,E<0&&(E+=K),K=v>E?0:E-v>>>0,v>>>=0;for(var te=Se(K);++H<K;)te[H]=i[H+v];return te}function jM(i,v){var E;return os(i,function(H,K,te){return E=v(H,K,te),!E}),!!E}function qc(i,v,E){var H=0,K=i==null?H:i.length;if(typeof v=="number"&&v===v&&K<=se){for(;H<K;){var te=H+K>>>1,he=i[te];he!==null&&!$i(he)&&(E?he<=v:he<v)?H=te+1:K=te}return K}return Ud(i,v,gi,E)}function Ud(i,v,E,H){var K=0,te=i==null?0:i.length;if(te===0)return 0;v=E(v);for(var he=v!==v,fe=v===null,we=$i(v),Me=v===e;K<te;){var Le=Fc((K+te)/2),Pe=E(i[Le]),Ye=Pe!==e,st=Pe===null,yt=Pe===Pe,Dt=$i(Pe);if(he)var pt=H||yt;else Me?pt=yt&&(H||Ye):fe?pt=yt&&Ye&&(H||!st):we?pt=yt&&Ye&&!st&&(H||!Dt):st||Dt?pt=!1:pt=H?Pe<=v:Pe<v;pt?K=Le+1:te=Le}return Br(te,ee)}function Nb(i,v){for(var E=-1,H=i.length,K=0,te=[];++E<H;){var he=i[E],fe=v?v(he):he;if(!E||!ao(fe,we)){var we=fe;te[K++]=he===0?0:he}}return te}function Db(i){return typeof i=="number"?i:$i(i)?ne:+i}function Si(i){if(typeof i=="string")return i;if(Rt(i))return $(i,Si)+"";if($i(i))return pb?pb.call(i):"";var v=i+"";return v=="0"&&1/i==-U?"-0":v}function ss(i,v,E){var H=-1,K=ui,te=i.length,he=!0,fe=[],we=fe;if(E)he=!1,K=y;else if(te>=m){var Me=v?null:QM(i);if(Me)return Ke(Me);he=!1,K=_t,we=new Fs}else we=v?[]:fe;e:for(;++H<te;){var Le=i[H],Pe=v?v(Le):Le;if(Le=E||Le!==0?Le:0,he&&Pe===Pe){for(var Ye=we.length;Ye--;)if(we[Ye]===Pe)continue e;v&&we.push(Pe),fe.push(Le)}else K(we,Pe,E)||(we!==fe&&we.push(Pe),fe.push(Le))}return fe}function Vd(i,v){v=as(v,i);var E=-1,H=v.length;if(!H)return!0;for(;++E<H;){var K=so(v[E]);if(K==="__proto__"&&!an.call(i,"__proto__")||(K==="constructor"||K==="prototype")&&E<H-1)return!1}var te=u0(i,v);return te==null||delete te[so(Ui(v))]}function Pb(i,v,E,H){return wl(i,v,E(Bs(i,v)),H)}function Gc(i,v,E,H){for(var K=i.length,te=H?K:-1;(H?te--:++te<K)&&v(i[te],te,i););return E?Hi(i,H?0:te,H?te+1:K):Hi(i,H?te+1:0,H?K:te)}function Fb(i,v){var E=i;return E instanceof Gt&&(E=E.value()),P(v,function(H,K){return K.func.apply(K.thisArg,_([H],K.args))},E)}function qd(i,v,E){var H=i.length;if(H<2)return H?ss(i[0]):[];for(var K=-1,te=Se(H);++K<H;)for(var he=i[K],fe=-1;++fe<H;)fe!=K&&(te[K]=vl(te[K]||he,i[fe],v,E));return ss(Rr(te,1),v,E)}function zb(i,v,E){for(var H=-1,K=i.length,te=v.length,he={};++H<K;){var fe=H<te?v[H]:e;E(he,i[H],fe)}return he}function Gd(i){return Xn(i)?i:[]}function Kd(i){return typeof i=="function"?i:gi}function as(i,v){return Rt(i)?i:rf(i,v)?[i]:p0(ln(i))}var HM=jt;function ls(i,v,E){var H=i.length;return E=E===e?H:E,!v&&E>=H?i:Hi(i,v,E)}var Bb=TT||function(i){return zt.clearTimeout(i)};function Wb(i,v){if(v)return i.slice();var E=i.length,H=lb?lb(E):new i.constructor(E);return i.copy(H),H}function Yd(i){var v=new i.constructor(i.byteLength);return new Lc(v).set(new Lc(i)),v}function UM(i,v){var E=v?Yd(i.buffer):i.buffer;return new i.constructor(E,i.byteOffset,i.byteLength)}function VM(i){var v=new i.constructor(i.source,$t.exec(i));return v.lastIndex=i.lastIndex,v}function qM(i){return gl?Wt(gl.call(i)):{}}function jb(i,v){var E=v?Yd(i.buffer):i.buffer;return new i.constructor(E,i.byteOffset,i.length)}function Hb(i,v){if(i!==v){var E=i!==e,H=i===null,K=i===i,te=$i(i),he=v!==e,fe=v===null,we=v===v,Me=$i(v);if(!fe&&!Me&&!te&&i>v||te&&he&&we&&!fe&&!Me||H&&he&&we||!E&&we||!K)return 1;if(!H&&!te&&!Me&&i<v||Me&&E&&K&&!H&&!te||fe&&E&&K||!he&&K||!we)return-1}return 0}function GM(i,v,E){for(var H=-1,K=i.criteria,te=v.criteria,he=K.length,fe=E.length;++H<he;){var we=Hb(K[H],te[H]);if(we){if(H>=fe)return we;var Me=E[H];return we*(Me=="desc"?-1:1)}}return i.index-v.index}function Ub(i,v,E,H){for(var K=-1,te=i.length,he=E.length,fe=-1,we=v.length,Me=gr(te-he,0),Le=Se(we+Me),Pe=!H;++fe<we;)Le[fe]=v[fe];for(;++K<he;)(Pe||K<te)&&(Le[E[K]]=i[K]);for(;Me--;)Le[fe++]=i[K++];return Le}function Vb(i,v,E,H){for(var K=-1,te=i.length,he=-1,fe=E.length,we=-1,Me=v.length,Le=gr(te-fe,0),Pe=Se(Le+Me),Ye=!H;++K<Le;)Pe[K]=i[K];for(var st=K;++we<Me;)Pe[st+we]=v[we];for(;++he<fe;)(Ye||K<te)&&(Pe[st+E[he]]=i[K++]);return Pe}function di(i,v){var E=-1,H=i.length;for(v||(v=Se(H));++E<H;)v[E]=i[E];return v}function ko(i,v,E,H){var K=!E;E||(E={});for(var te=-1,he=v.length;++te<he;){var fe=v[te],we=H?H(E[fe],i[fe],fe,E,i):e;we===e&&(we=i[fe]),K?Ao(E,fe,we):ml(E,fe,we)}return E}function KM(i,v){return ko(i,nf(i),v)}function YM(i,v){return ko(i,i0(i),v)}function Kc(i,v){return function(E,H){var K=Rt(E)?Aa:vM,te=v?v():{};return K(E,i,vt(H,2),te)}}function $a(i){return jt(function(v,E){var H=-1,K=E.length,te=K>1?E[K-1]:e,he=K>2?E[2]:e;for(te=i.length>3&&typeof te=="function"?(K--,te):e,he&&Qr(E[0],E[1],he)&&(te=K<3?e:te,K=1),v=Wt(v);++H<K;){var fe=E[H];fe&&i(v,fe,H,te)}return v})}function qb(i,v){return function(E,H){if(E==null)return E;if(!fi(E))return i(E,H);for(var K=E.length,te=v?K:-1,he=Wt(E);(v?te--:++te<K)&&H(he[te],te,he)!==!1;);return E}}function Gb(i){return function(v,E,H){for(var K=-1,te=Wt(v),he=H(v),fe=he.length;fe--;){var we=he[i?fe:++K];if(E(te[we],we,te)===!1)break}return v}}function JM(i,v,E){var H=v&b,K=xl(i);function te(){var he=this&&this!==zt&&this instanceof te?K:i;return he.apply(H?E:this,arguments)}return te}function Kb(i){return function(v){v=ln(v);var E=ge(v)?bt(v):e,H=E?E[0]:v.charAt(0),K=E?ls(E,1).join(""):v.slice(1);return H[i]()+K}}function Ra(i){return function(v){return P(G0(q0(v).replace(Oo,"")),i,"")}}function xl(i){return function(){var v=arguments;switch(v.length){case 0:return new i;case 1:return new i(v[0]);case 2:return new i(v[0],v[1]);case 3:return new i(v[0],v[1],v[2]);case 4:return new i(v[0],v[1],v[2],v[3]);case 5:return new i(v[0],v[1],v[2],v[3],v[4]);case 6:return new i(v[0],v[1],v[2],v[3],v[4],v[5]);case 7:return new i(v[0],v[1],v[2],v[3],v[4],v[5],v[6])}var E=Sa(i.prototype),H=i.apply(E,v);return zn(H)?H:E}}function ZM(i,v,E){var H=xl(i);function K(){for(var te=arguments.length,he=Se(te),fe=te,we=Ea(K);fe--;)he[fe]=arguments[fe];var Me=te<3&&he[0]!==we&&he[te-1]!==we?[]:Ve(he,we);if(te-=Me.length,te<E)return Qb(i,v,Yc,K.placeholder,e,he,Me,e,e,E-te);var Le=this&&this!==zt&&this instanceof K?H:i;return on(Le,this,he)}return K}function Yb(i){return function(v,E,H){var K=Wt(v);if(!fi(v)){var te=vt(E,3);v=Cr(v),E=function(fe){return te(K[fe],fe,K)}}var he=i(v,E,H);return he>-1?K[te?v[he]:he]:e}}function Jb(i){return Bo(function(v){var E=v.length,H=E,K=Wi.prototype.thru;for(i&&v.reverse();H--;){var te=v[H];if(typeof te!="function")throw new xn(g);if(K&&!he&&Qc(te)=="wrapper")var he=new Wi([],!0)}for(H=he?H:E;++H<E;){te=v[H];var fe=Qc(te),we=fe=="wrapper"?ef(te):e;we&&of(we[0])&&we[1]==(D|R|C|I)&&!we[4].length&&we[9]==1?he=he[Qc(we[0])].apply(he,we[3]):he=te.length==1&&of(te)?he[fe]():he.thru(te)}return function(){var Me=arguments,Le=Me[0];if(he&&Me.length==1&&Rt(Le))return he.plant(Le).value();for(var Pe=0,Ye=E?v[Pe].apply(this,Me):Le;++Pe<E;)Ye=v[Pe].call(this,Ye);return Ye}})}function Yc(i,v,E,H,K,te,he,fe,we,Me){var Le=v&D,Pe=v&b,Ye=v&x,st=v&(R|k),yt=v&T,Dt=Ye?e:xl(i);function pt(){for(var Ut=arguments.length,Kt=Se(Ut),Ri=Ut;Ri--;)Kt[Ri]=arguments[Ri];if(st)var ei=Ea(pt),Ei=In(Kt,ei);if(H&&(Kt=Ub(Kt,H,K,st)),te&&(Kt=Vb(Kt,te,he,st)),Ut-=Ei,st&&Ut<Me){var Qn=Ve(Kt,ei);return Qb(i,v,Yc,pt.placeholder,E,Kt,Qn,fe,we,Me-Ut)}var lo=Pe?E:this,Uo=Ye?lo[i]:i;return Ut=Kt.length,fe?Kt=vI(Kt,fe):yt&&Ut>1&&Kt.reverse(),Le&&we<Ut&&(Kt.length=we),this&&this!==zt&&this instanceof pt&&(Uo=Dt||xl(Uo)),Uo.apply(lo,Kt)}return pt}function Zb(i,v){return function(E,H){return kM(E,i,v(H),{})}}function Jc(i,v){return function(E,H){var K;if(E===e&&H===e)return v;if(E!==e&&(K=E),H!==e){if(K===e)return H;typeof E=="string"||typeof H=="string"?(E=Si(E),H=Si(H)):(E=Db(E),H=Db(H)),K=i(E,H)}return K}}function Jd(i){return Bo(function(v){return v=$(v,Yt(vt())),jt(function(E){var H=this;return i(v,function(K){return on(K,H,E)})})})}function Zc(i,v){v=v===e?" ":Si(v);var E=v.length;if(E<2)return E?Hd(v,i):v;var H=Hd(v,Pc(i/Bt(v)));return ge(v)?ls(bt(H),0,i).join(""):H.slice(0,i)}function XM(i,v,E,H){var K=v&b,te=xl(i);function he(){for(var fe=-1,we=arguments.length,Me=-1,Le=H.length,Pe=Se(Le+we),Ye=this&&this!==zt&&this instanceof he?te:i;++Me<Le;)Pe[Me]=H[Me];for(;we--;)Pe[Me++]=arguments[++fe];return on(Ye,K?E:this,Pe)}return he}function Xb(i){return function(v,E,H){return H&&typeof H!="number"&&Qr(v,E,H)&&(E=H=e),v=Ho(v),E===e?(E=v,v=0):E=Ho(E),H=H===e?v<E?1:-1:Ho(H),PM(v,E,H,i)}}function Xc(i){return function(v,E){return typeof v=="string"&&typeof E=="string"||(v=Vi(v),E=Vi(E)),i(v,E)}}function Qb(i,v,E,H,K,te,he,fe,we,Me){var Le=v&R,Pe=Le?he:e,Ye=Le?e:he,st=Le?te:e,yt=Le?e:te;v|=Le?C:L,v&=~(Le?L:C),v&M||(v&=-4);var Dt=[i,v,K,st,Pe,yt,Ye,fe,we,Me],pt=E.apply(e,Dt);return of(i)&&h0(pt,Dt),pt.placeholder=H,d0(pt,i,v)}function Zd(i){var v=en[i];return function(E,H){if(E=Vi(E),H=H==null?0:Br(Nt(H),292),H&&db(E)){var K=(ln(E)+"e").split("e"),te=v(K[0]+"e"+(+K[1]+H));return K=(ln(te)+"e").split("e"),+(K[0]+"e"+(+K[1]-H))}return v(E)}}var QM=_a&&1/Ke(new _a([,-0]))[1]==U?function(i){return new _a(i)}:xf;function e0(i){return function(v){var E=Wr(v);return E==lt?Fe(v):E==un?Xe(v):$n(v,i(v))}}function zo(i,v,E,H,K,te,he,fe){var we=v&x;if(!we&&typeof i!="function")throw new xn(g);var Me=H?H.length:0;if(Me||(v&=-97,H=K=e),he=he===e?he:gr(Nt(he),0),fe=fe===e?fe:Nt(fe),Me-=K?K.length:0,v&L){var Le=H,Pe=K;H=K=e}var Ye=we?e:ef(i),st=[i,v,E,H,K,Le,Pe,te,he,fe];if(Ye&&pI(st,Ye),i=st[0],v=st[1],E=st[2],H=st[3],K=st[4],fe=st[9]=st[9]===e?we?0:i.length:gr(st[9]-Me,0),!fe&&v&(R|k)&&(v&=-25),!v||v==b)var yt=JM(i,v,E);else v==R||v==k?yt=ZM(i,v,fe):(v==C||v==(b|C))&&!K.length?yt=XM(i,v,E,H):yt=Yc.apply(e,st);var Dt=Ye?Ob:h0;return d0(Dt(yt,st),i,v)}function t0(i,v,E,H){return i===e||ao(i,Do[E])&&!an.call(H,E)?v:i}function n0(i,v,E,H,K,te){return zn(i)&&zn(v)&&(te.set(v,i),Vc(i,v,e,n0,te),te.delete(v)),i}function eI(i){return _l(i)?e:i}function r0(i,v,E,H,K,te){var he=E&s,fe=i.length,we=v.length;if(fe!=we&&!(he&&we>fe))return!1;var Me=te.get(i),Le=te.get(v);if(Me&&Le)return Me==v&&Le==i;var Pe=-1,Ye=!0,st=E&p?new Fs:e;for(te.set(i,v),te.set(v,i);++Pe<fe;){var yt=i[Pe],Dt=v[Pe];if(H)var pt=he?H(Dt,yt,Pe,v,i,te):H(yt,Dt,Pe,i,v,te);if(pt!==e){if(pt)continue;Ye=!1;break}if(st){if(!j(v,function(Ut,Kt){if(!_t(st,Kt)&&(yt===Ut||K(yt,Ut,E,H,te)))return st.push(Kt)})){Ye=!1;break}}else if(!(yt===Dt||K(yt,Dt,E,H,te))){Ye=!1;break}}return te.delete(i),te.delete(v),Ye}function tI(i,v,E,H,K,te,he){switch(E){case kn:if(i.byteLength!=v.byteLength||i.byteOffset!=v.byteOffset)return!1;i=i.buffer,v=v.buffer;case _n:return!(i.byteLength!=v.byteLength||!te(new Lc(i),new Lc(v)));case $e:case Ee:case Tt:return ao(+i,+v);case Ue:return i.name==v.name&&i.message==v.message;case Kn:case Yn:return i==v+"";case lt:var fe=Fe;case un:var we=H&s;if(fe||(fe=Ke),i.size!=v.size&&!we)return!1;var Me=he.get(i);if(Me)return Me==v;H|=p,he.set(i,v);var Le=r0(fe(i),fe(v),H,K,te,he);return he.delete(i),Le;case gt:if(gl)return gl.call(i)==gl.call(v)}return!1}function nI(i,v,E,H,K,te){var he=E&s,fe=Xd(i),we=fe.length,Me=Xd(v),Le=Me.length;if(we!=Le&&!he)return!1;for(var Pe=we;Pe--;){var Ye=fe[Pe];if(!(he?Ye in v:an.call(v,Ye)))return!1}var st=te.get(i),yt=te.get(v);if(st&&yt)return st==v&&yt==i;var Dt=!0;te.set(i,v),te.set(v,i);for(var pt=he;++Pe<we;){Ye=fe[Pe];var Ut=i[Ye],Kt=v[Ye];if(H)var Ri=he?H(Kt,Ut,Ye,v,i,te):H(Ut,Kt,Ye,i,v,te);if(!(Ri===e?Ut===Kt||K(Ut,Kt,E,H,te):Ri)){Dt=!1;break}pt||(pt=Ye=="constructor")}if(Dt&&!pt){var ei=i.constructor,Ei=v.constructor;ei!=Ei&&"constructor"in i&&"constructor"in v&&!(typeof ei=="function"&&ei instanceof ei&&typeof Ei=="function"&&Ei instanceof Ei)&&(Dt=!1)}return te.delete(i),te.delete(v),Dt}function Bo(i){return af(c0(i,e,y0),i+"")}function Xd(i){return Ab(i,Cr,nf)}function Qd(i){return Ab(i,pi,i0)}var ef=zc?function(i){return zc.get(i)}:xf;function Qc(i){for(var v=i.name+"",E=ka[v],H=an.call(ka,v)?E.length:0;H--;){var K=E[H],te=K.func;if(te==null||te==i)return K.name}return v}function Ea(i){var v=an.call(Q,"placeholder")?Q:i;return v.placeholder}function vt(){var i=Q.iteratee||bf;return i=i===bf?Sb:i,arguments.length?i(arguments[0],arguments[1]):i}function eu(i,v){var E=i.__data__;return uI(v)?E[typeof v=="string"?"string":"hash"]:E.map}function tf(i){for(var v=Cr(i),E=v.length;E--;){var H=v[E],K=i[H];v[E]=[H,K,a0(K)]}return v}function Ws(i,v){var E=ae(i,v);return kb(E)?E:e}function rI(i){var v=an.call(i,Ds),E=i[Ds];try{i[Ds]=e;var H=!0}catch{}var K=Mc.call(i);return H&&(v?i[Ds]=E:delete i[Ds]),K}var nf=Ed?function(i){return i==null?[]:(i=Wt(i),kr(Ed(i),function(v){return ub.call(i,v)}))}:Cf,i0=Ed?function(i){for(var v=[];i;)_(v,nf(i)),i=Oc(i);return v}:Cf,Wr=Xr;(Td&&Wr(new Td(new ArrayBuffer(1)))!=kn||dl&&Wr(new dl)!=lt||Md&&Wr(Md.resolve())!=vr||_a&&Wr(new _a)!=un||fl&&Wr(new fl)!=Ft)&&(Wr=function(i){var v=Xr(i),E=v==At?i.constructor:e,H=E?js(E):"";if(H)switch(H){case zT:return kn;case BT:return lt;case WT:return vr;case jT:return un;case HT:return Ft}return v});function iI(i,v,E){for(var H=-1,K=E.length;++H<K;){var te=E[H],he=te.size;switch(te.type){case"drop":i+=he;break;case"dropRight":v-=he;break;case"take":v=Br(v,i+he);break;case"takeRight":i=gr(i,v-he);break}}return{start:i,end:v}}function oI(i){var v=i.match(Jr);return v?v[1].split(si):[]}function o0(i,v,E){v=as(v,i);for(var H=-1,K=v.length,te=!1;++H<K;){var he=so(v[H]);if(!(te=i!=null&&E(i,he)))break;i=i[he]}return te||++H!=K?te:(K=i==null?0:i.length,!!K&&au(K)&&Wo(he,K)&&(Rt(i)||Hs(i)))}function sI(i){var v=i.length,E=new i.constructor(v);return v&&typeof i[0]=="string"&&an.call(i,"index")&&(E.index=i.index,E.input=i.input),E}function s0(i){return typeof i.constructor=="function"&&!Cl(i)?Sa(Oc(i)):{}}function aI(i,v,E){var H=i.constructor;switch(v){case _n:return Yd(i);case $e:case Ee:return new H(+i);case kn:return UM(i,E);case mn:case vn:case Wn:case Jn:case Jt:case jn:case oi:case Or:case Rn:return jb(i,E);case lt:return new H;case Tt:case Yn:return new H(i);case Kn:return VM(i);case un:return new H;case gt:return qM(i)}}function lI(i,v){var E=v.length;if(!E)return i;var H=E-1;return v[H]=(E>1?"& ":"")+v[H],v=v.join(E>2?", ":" "),i.replace(Ci,`{
1460
+ /* [wrapped with `+v+`] */
1461
+ `)}function cI(i){return Rt(i)||Hs(i)||!!(hb&&i&&i[hb])}function Wo(i,v){var E=typeof i;return v=v??G,!!v&&(E=="number"||E!="symbol"&&Tn.test(i))&&i>-1&&i%1==0&&i<v}function Qr(i,v,E){if(!zn(E))return!1;var H=typeof v;return(H=="number"?fi(E)&&Wo(v,E.length):H=="string"&&v in E)?ao(E[v],i):!1}function rf(i,v){if(Rt(i))return!1;var E=typeof i;return E=="number"||E=="symbol"||E=="boolean"||i==null||$i(i)?!0:fn.test(i)||!Zt.test(i)||v!=null&&i in Wt(v)}function uI(i){var v=typeof i;return v=="string"||v=="number"||v=="symbol"||v=="boolean"?i!=="__proto__":i===null}function of(i){var v=Qc(i),E=Q[v];if(typeof E!="function"||!(v in Gt.prototype))return!1;if(i===E)return!0;var H=ef(E);return!!H&&i===H[0]}function hI(i){return!!ab&&ab in i}var dI=Ec?jo:Af;function Cl(i){var v=i&&i.constructor,E=typeof v=="function"&&v.prototype||Do;return i===E}function a0(i){return i===i&&!zn(i)}function l0(i,v){return function(E){return E==null?!1:E[i]===v&&(v!==e||i in Wt(E))}}function fI(i){var v=ou(i,function(H){return E.size===a&&E.clear(),H}),E=v.cache;return v}function pI(i,v){var E=i[1],H=v[1],K=E|H,te=K<(b|x|D),he=H==D&&E==R||H==D&&E==I&&i[7].length<=v[8]||H==(D|I)&&v[7].length<=v[8]&&E==R;if(!(te||he))return i;H&b&&(i[2]=v[2],K|=E&b?0:M);var fe=v[3];if(fe){var we=i[3];i[3]=we?Ub(we,fe,v[4]):fe,i[4]=we?Ve(i[3],l):v[4]}return fe=v[5],fe&&(we=i[5],i[5]=we?Vb(we,fe,v[6]):fe,i[6]=we?Ve(i[5],l):v[6]),fe=v[7],fe&&(i[7]=fe),H&D&&(i[8]=i[8]==null?v[8]:Br(i[8],v[8])),i[9]==null&&(i[9]=v[9]),i[0]=v[0],i[1]=K,i}function gI(i){var v=[];if(i!=null)for(var E in Wt(i))v.push(E);return v}function mI(i){return Mc.call(i)}function c0(i,v,E){return v=gr(v===e?i.length-1:v,0),function(){for(var H=arguments,K=-1,te=gr(H.length-v,0),he=Se(te);++K<te;)he[K]=H[v+K];K=-1;for(var fe=Se(v+1);++K<v;)fe[K]=H[K];return fe[v]=E(he),on(i,this,fe)}}function u0(i,v){return v.length<2?i:Bs(i,Hi(v,0,-1))}function vI(i,v){for(var E=i.length,H=Br(v.length,E),K=di(i);H--;){var te=v[H];i[H]=Wo(te,E)?K[te]:e}return i}function sf(i,v){if(!(v==="constructor"&&typeof i[v]=="function")&&v!="__proto__")return i[v]}var h0=f0(Ob),Al=IT||function(i,v){return zt.setTimeout(i,v)},af=f0(BM);function d0(i,v,E){var H=v+"";return af(i,lI(H,yI(oI(H),E)))}function f0(i){var v=0,E=0;return function(){var H=DT(),K=S-(H-E);if(E=H,K>0){if(++v>=O)return arguments[0]}else v=0;return i.apply(e,arguments)}}function tu(i,v){var E=-1,H=i.length,K=H-1;for(v=v===e?H:v;++E<v;){var te=jd(E,K),he=i[te];i[te]=i[E],i[E]=he}return i.length=v,i}var p0=fI(function(i){var v=[];return i.charCodeAt(0)===46&&v.push(""),i.replace(Nr,function(E,H,K,te){v.push(K?te.replace(ai,"$1"):H||E)}),v});function so(i){if(typeof i=="string"||$i(i))return i;var v=i+"";return v=="0"&&1/i==-U?"-0":v}function js(i){if(i!=null){try{return Tc.call(i)}catch{}try{return i+""}catch{}}return""}function yI(i,v){return fr(ce,function(E){var H="_."+E[0];v&E[1]&&!ui(i,H)&&i.push(H)}),i.sort()}function g0(i){if(i instanceof Gt)return i.clone();var v=new Wi(i.__wrapped__,i.__chain__);return v.__actions__=di(i.__actions__),v.__index__=i.__index__,v.__values__=i.__values__,v}function bI(i,v,E){(E?Qr(i,v,E):v===e)?v=1:v=gr(Nt(v),0);var H=i==null?0:i.length;if(!H||v<1)return[];for(var K=0,te=0,he=Se(Pc(H/v));K<H;)he[te++]=Hi(i,K,K+=v);return he}function wI(i){for(var v=-1,E=i==null?0:i.length,H=0,K=[];++v<E;){var te=i[v];te&&(K[H++]=te)}return K}function xI(){var i=arguments.length;if(!i)return[];for(var v=Se(i-1),E=arguments[0],H=i;H--;)v[H-1]=arguments[H];return _(Rt(E)?di(E):[E],Rr(v,1))}var CI=jt(function(i,v){return Xn(i)?vl(i,Rr(v,1,Xn,!0)):[]}),AI=jt(function(i,v){var E=Ui(v);return Xn(E)&&(E=e),Xn(i)?vl(i,Rr(v,1,Xn,!0),vt(E,2)):[]}),_I=jt(function(i,v){var E=Ui(v);return Xn(E)&&(E=e),Xn(i)?vl(i,Rr(v,1,Xn,!0),e,E):[]});function kI(i,v,E){var H=i==null?0:i.length;return H?(v=E||v===e?1:Nt(v),Hi(i,v<0?0:v,H)):[]}function SI(i,v,E){var H=i==null?0:i.length;return H?(v=E||v===e?1:Nt(v),v=H-v,Hi(i,0,v<0?0:v)):[]}function $I(i,v){return i&&i.length?Gc(i,vt(v,3),!0,!0):[]}function RI(i,v){return i&&i.length?Gc(i,vt(v,3),!0):[]}function EI(i,v,E,H){var K=i==null?0:i.length;return K?(E&&typeof E!="number"&&Qr(i,v,E)&&(E=0,H=K),xM(i,v,E,H)):[]}function m0(i,v,E){var H=i==null?0:i.length;if(!H)return-1;var K=E==null?0:Nt(E);return K<0&&(K=gr(H+K,0)),ue(i,vt(v,3),K)}function v0(i,v,E){var H=i==null?0:i.length;if(!H)return-1;var K=H-1;return E!==e&&(K=Nt(E),K=E<0?gr(H+K,0):Br(K,H-1)),ue(i,vt(v,3),K,!0)}function y0(i){var v=i==null?0:i.length;return v?Rr(i,1):[]}function TI(i){var v=i==null?0:i.length;return v?Rr(i,U):[]}function MI(i,v){var E=i==null?0:i.length;return E?(v=v===e?1:Nt(v),Rr(i,v)):[]}function II(i){for(var v=-1,E=i==null?0:i.length,H={};++v<E;){var K=i[v];Ao(H,K[0],K[1])}return H}function b0(i){return i&&i.length?i[0]:e}function LI(i,v,E){var H=i==null?0:i.length;if(!H)return-1;var K=E==null?0:Nt(E);return K<0&&(K=gr(H+K,0)),be(i,v,K)}function OI(i){var v=i==null?0:i.length;return v?Hi(i,0,-1):[]}var NI=jt(function(i){var v=$(i,Gd);return v.length&&v[0]===i[0]?Pd(v):[]}),DI=jt(function(i){var v=Ui(i),E=$(i,Gd);return v===Ui(E)?v=e:E.pop(),E.length&&E[0]===i[0]?Pd(E,vt(v,2)):[]}),PI=jt(function(i){var v=Ui(i),E=$(i,Gd);return v=typeof v=="function"?v:e,v&&E.pop(),E.length&&E[0]===i[0]?Pd(E,e,v):[]});function FI(i,v){return i==null?"":OT.call(i,v)}function Ui(i){var v=i==null?0:i.length;return v?i[v-1]:e}function zI(i,v,E){var H=i==null?0:i.length;if(!H)return-1;var K=H;return E!==e&&(K=Nt(E),K=K<0?gr(H+K,0):Br(K,H-1)),v===v?Xt(i,v,K):ue(i,ye,K,!0)}function BI(i,v){return i&&i.length?Tb(i,Nt(v)):e}var WI=jt(w0);function w0(i,v){return i&&i.length&&v&&v.length?Wd(i,v):i}function jI(i,v,E){return i&&i.length&&v&&v.length?Wd(i,v,vt(E,2)):i}function HI(i,v,E){return i&&i.length&&v&&v.length?Wd(i,v,e,E):i}var UI=Bo(function(i,v){var E=i==null?0:i.length,H=Ld(i,v);return Lb(i,$(v,function(K){return Wo(K,E)?+K:K}).sort(Hb)),H});function VI(i,v){var E=[];if(!(i&&i.length))return E;var H=-1,K=[],te=i.length;for(v=vt(v,3);++H<te;){var he=i[H];v(he,H,i)&&(E.push(he),K.push(H))}return Lb(i,K),E}function lf(i){return i==null?i:FT.call(i)}function qI(i,v,E){var H=i==null?0:i.length;return H?(E&&typeof E!="number"&&Qr(i,v,E)?(v=0,E=H):(v=v==null?0:Nt(v),E=E===e?H:Nt(E)),Hi(i,v,E)):[]}function GI(i,v){return qc(i,v)}function KI(i,v,E){return Ud(i,v,vt(E,2))}function YI(i,v){var E=i==null?0:i.length;if(E){var H=qc(i,v);if(H<E&&ao(i[H],v))return H}return-1}function JI(i,v){return qc(i,v,!0)}function ZI(i,v,E){return Ud(i,v,vt(E,2),!0)}function XI(i,v){var E=i==null?0:i.length;if(E){var H=qc(i,v,!0)-1;if(ao(i[H],v))return H}return-1}function QI(i){return i&&i.length?Nb(i):[]}function eL(i,v){return i&&i.length?Nb(i,vt(v,2)):[]}function tL(i){var v=i==null?0:i.length;return v?Hi(i,1,v):[]}function nL(i,v,E){return i&&i.length?(v=E||v===e?1:Nt(v),Hi(i,0,v<0?0:v)):[]}function rL(i,v,E){var H=i==null?0:i.length;return H?(v=E||v===e?1:Nt(v),v=H-v,Hi(i,v<0?0:v,H)):[]}function iL(i,v){return i&&i.length?Gc(i,vt(v,3),!1,!0):[]}function oL(i,v){return i&&i.length?Gc(i,vt(v,3)):[]}var sL=jt(function(i){return ss(Rr(i,1,Xn,!0))}),aL=jt(function(i){var v=Ui(i);return Xn(v)&&(v=e),ss(Rr(i,1,Xn,!0),vt(v,2))}),lL=jt(function(i){var v=Ui(i);return v=typeof v=="function"?v:e,ss(Rr(i,1,Xn,!0),e,v)});function cL(i){return i&&i.length?ss(i):[]}function uL(i,v){return i&&i.length?ss(i,vt(v,2)):[]}function hL(i,v){return v=typeof v=="function"?v:e,i&&i.length?ss(i,e,v):[]}function cf(i){if(!(i&&i.length))return[];var v=0;return i=kr(i,function(E){if(Xn(E))return v=gr(E.length,v),!0}),et(v,function(E){return $(i,Oe(E))})}function x0(i,v){if(!(i&&i.length))return[];var E=cf(i);return v==null?E:$(E,function(H){return on(v,e,H)})}var dL=jt(function(i,v){return Xn(i)?vl(i,v):[]}),fL=jt(function(i){return qd(kr(i,Xn))}),pL=jt(function(i){var v=Ui(i);return Xn(v)&&(v=e),qd(kr(i,Xn),vt(v,2))}),gL=jt(function(i){var v=Ui(i);return v=typeof v=="function"?v:e,qd(kr(i,Xn),e,v)}),mL=jt(cf);function vL(i,v){return zb(i||[],v||[],ml)}function yL(i,v){return zb(i||[],v||[],wl)}var bL=jt(function(i){var v=i.length,E=v>1?i[v-1]:e;return E=typeof E=="function"?(i.pop(),E):e,x0(i,E)});function C0(i){var v=Q(i);return v.__chain__=!0,v}function wL(i,v){return v(i),i}function nu(i,v){return v(i)}var xL=Bo(function(i){var v=i.length,E=v?i[0]:0,H=this.__wrapped__,K=function(te){return Ld(te,i)};return v>1||this.__actions__.length||!(H instanceof Gt)||!Wo(E)?this.thru(K):(H=H.slice(E,+E+(v?1:0)),H.__actions__.push({func:nu,args:[K],thisArg:e}),new Wi(H,this.__chain__).thru(function(te){return v&&!te.length&&te.push(e),te}))});function CL(){return C0(this)}function AL(){return new Wi(this.value(),this.__chain__)}function _L(){this.__values__===e&&(this.__values__=D0(this.value()));var i=this.__index__>=this.__values__.length,v=i?e:this.__values__[this.__index__++];return{done:i,value:v}}function kL(){return this}function SL(i){for(var v,E=this;E instanceof Wc;){var H=g0(E);H.__index__=0,H.__values__=e,v?K.__wrapped__=H:v=H;var K=H;E=E.__wrapped__}return K.__wrapped__=i,v}function $L(){var i=this.__wrapped__;if(i instanceof Gt){var v=i;return this.__actions__.length&&(v=new Gt(this)),v=v.reverse(),v.__actions__.push({func:nu,args:[lf],thisArg:e}),new Wi(v,this.__chain__)}return this.thru(lf)}function RL(){return Fb(this.__wrapped__,this.__actions__)}var EL=Kc(function(i,v,E){an.call(i,E)?++i[E]:Ao(i,E,1)});function TL(i,v,E){var H=Rt(i)?Co:wM;return E&&Qr(i,v,E)&&(v=e),H(i,vt(v,3))}function ML(i,v){var E=Rt(i)?kr:xb;return E(i,vt(v,3))}var IL=Yb(m0),LL=Yb(v0);function OL(i,v){return Rr(ru(i,v),1)}function NL(i,v){return Rr(ru(i,v),U)}function DL(i,v,E){return E=E===e?1:Nt(E),Rr(ru(i,v),E)}function A0(i,v){var E=Rt(i)?fr:os;return E(i,vt(v,3))}function _0(i,v){var E=Rt(i)?zr:wb;return E(i,vt(v,3))}var PL=Kc(function(i,v,E){an.call(i,E)?i[E].push(v):Ao(i,E,[v])});function FL(i,v,E,H){i=fi(i)?i:Ma(i),E=E&&!H?Nt(E):0;var K=i.length;return E<0&&(E=gr(K+E,0)),lu(i)?E<=K&&i.indexOf(v,E)>-1:!!K&&be(i,v,E)>-1}var zL=jt(function(i,v,E){var H=-1,K=typeof v=="function",te=fi(i)?Se(i.length):[];return os(i,function(he){te[++H]=K?on(v,he,E):yl(he,v,E)}),te}),BL=Kc(function(i,v,E){Ao(i,E,v)});function ru(i,v){var E=Rt(i)?$:$b;return E(i,vt(v,3))}function WL(i,v,E,H){return i==null?[]:(Rt(v)||(v=v==null?[]:[v]),E=H?e:E,Rt(E)||(E=E==null?[]:[E]),Mb(i,v,E))}var jL=Kc(function(i,v,E){i[E?0:1].push(v)},function(){return[[],[]]});function HL(i,v,E){var H=Rt(i)?P:Ge,K=arguments.length<3;return H(i,vt(v,4),E,K,os)}function UL(i,v,E){var H=Rt(i)?z:Ge,K=arguments.length<3;return H(i,vt(v,4),E,K,wb)}function VL(i,v){var E=Rt(i)?kr:xb;return E(i,su(vt(v,3)))}function qL(i){var v=Rt(i)?mb:FM;return v(i)}function GL(i,v,E){(E?Qr(i,v,E):v===e)?v=1:v=Nt(v);var H=Rt(i)?gM:zM;return H(i,v)}function KL(i){var v=Rt(i)?mM:WM;return v(i)}function YL(i){if(i==null)return 0;if(fi(i))return lu(i)?Bt(i):i.length;var v=Wr(i);return v==lt||v==un?i.size:zd(i).length}function JL(i,v,E){var H=Rt(i)?j:jM;return E&&Qr(i,v,E)&&(v=e),H(i,vt(v,3))}var ZL=jt(function(i,v){if(i==null)return[];var E=v.length;return E>1&&Qr(i,v[0],v[1])?v=[]:E>2&&Qr(v[0],v[1],v[2])&&(v=[v[0]]),Mb(i,Rr(v,1),[])}),iu=MT||function(){return zt.Date.now()};function XL(i,v){if(typeof v!="function")throw new xn(g);return i=Nt(i),function(){if(--i<1)return v.apply(this,arguments)}}function k0(i,v,E){return v=E?e:v,v=i&&v==null?i.length:v,zo(i,D,e,e,e,e,v)}function S0(i,v){var E;if(typeof v!="function")throw new xn(g);return i=Nt(i),function(){return--i>0&&(E=v.apply(this,arguments)),i<=1&&(v=e),E}}var uf=jt(function(i,v,E){var H=b;if(E.length){var K=Ve(E,Ea(uf));H|=C}return zo(i,H,v,E,K)}),$0=jt(function(i,v,E){var H=b|x;if(E.length){var K=Ve(E,Ea($0));H|=C}return zo(v,H,i,E,K)});function R0(i,v,E){v=E?e:v;var H=zo(i,R,e,e,e,e,e,v);return H.placeholder=R0.placeholder,H}function E0(i,v,E){v=E?e:v;var H=zo(i,k,e,e,e,e,e,v);return H.placeholder=E0.placeholder,H}function T0(i,v,E){var H,K,te,he,fe,we,Me=0,Le=!1,Pe=!1,Ye=!0;if(typeof i!="function")throw new xn(g);v=Vi(v)||0,zn(E)&&(Le=!!E.leading,Pe="maxWait"in E,te=Pe?gr(Vi(E.maxWait)||0,v):te,Ye="trailing"in E?!!E.trailing:Ye);function st(Qn){var lo=H,Uo=K;return H=K=e,Me=Qn,he=i.apply(Uo,lo),he}function yt(Qn){return Me=Qn,fe=Al(Ut,v),Le?st(Qn):he}function Dt(Qn){var lo=Qn-we,Uo=Qn-Me,J0=v-lo;return Pe?Br(J0,te-Uo):J0}function pt(Qn){var lo=Qn-we,Uo=Qn-Me;return we===e||lo>=v||lo<0||Pe&&Uo>=te}function Ut(){var Qn=iu();if(pt(Qn))return Kt(Qn);fe=Al(Ut,Dt(Qn))}function Kt(Qn){return fe=e,Ye&&H?st(Qn):(H=K=e,he)}function Ri(){fe!==e&&Bb(fe),Me=0,H=we=K=fe=e}function ei(){return fe===e?he:Kt(iu())}function Ei(){var Qn=iu(),lo=pt(Qn);if(H=arguments,K=this,we=Qn,lo){if(fe===e)return yt(we);if(Pe)return Bb(fe),fe=Al(Ut,v),st(we)}return fe===e&&(fe=Al(Ut,v)),he}return Ei.cancel=Ri,Ei.flush=ei,Ei}var QL=jt(function(i,v){return bb(i,1,v)}),eO=jt(function(i,v,E){return bb(i,Vi(v)||0,E)});function tO(i){return zo(i,T)}function ou(i,v){if(typeof i!="function"||v!=null&&typeof v!="function")throw new xn(g);var E=function(){var H=arguments,K=v?v.apply(this,H):H[0],te=E.cache;if(te.has(K))return te.get(K);var he=i.apply(this,H);return E.cache=te.set(K,he)||te,he};return E.cache=new(ou.Cache||Fo),E}ou.Cache=Fo;function su(i){if(typeof i!="function")throw new xn(g);return function(){var v=arguments;switch(v.length){case 0:return!i.call(this);case 1:return!i.call(this,v[0]);case 2:return!i.call(this,v[0],v[1]);case 3:return!i.call(this,v[0],v[1],v[2])}return!i.apply(this,v)}}function nO(i){return S0(2,i)}var rO=HM(function(i,v){v=v.length==1&&Rt(v[0])?$(v[0],Yt(vt())):$(Rr(v,1),Yt(vt()));var E=v.length;return jt(function(H){for(var K=-1,te=Br(H.length,E);++K<te;)H[K]=v[K].call(this,H[K]);return on(i,this,H)})}),hf=jt(function(i,v){var E=Ve(v,Ea(hf));return zo(i,C,e,v,E)}),M0=jt(function(i,v){var E=Ve(v,Ea(M0));return zo(i,L,e,v,E)}),iO=Bo(function(i,v){return zo(i,I,e,e,e,v)});function oO(i,v){if(typeof i!="function")throw new xn(g);return v=v===e?v:Nt(v),jt(i,v)}function sO(i,v){if(typeof i!="function")throw new xn(g);return v=v==null?0:gr(Nt(v),0),jt(function(E){var H=E[v],K=ls(E,0,v);return H&&_(K,H),on(i,this,K)})}function aO(i,v,E){var H=!0,K=!0;if(typeof i!="function")throw new xn(g);return zn(E)&&(H="leading"in E?!!E.leading:H,K="trailing"in E?!!E.trailing:K),T0(i,v,{leading:H,maxWait:v,trailing:K})}function lO(i){return k0(i,1)}function cO(i,v){return hf(Kd(v),i)}function uO(){if(!arguments.length)return[];var i=arguments[0];return Rt(i)?i:[i]}function hO(i){return ji(i,o)}function dO(i,v){return v=typeof v=="function"?v:e,ji(i,o,v)}function fO(i){return ji(i,c|o)}function pO(i,v){return v=typeof v=="function"?v:e,ji(i,c|o,v)}function gO(i,v){return v==null||yb(i,v,Cr(v))}function ao(i,v){return i===v||i!==i&&v!==v}var mO=Xc(Dd),vO=Xc(function(i,v){return i>=v}),Hs=_b((function(){return arguments})())?_b:function(i){return qn(i)&&an.call(i,"callee")&&!ub.call(i,"callee")},Rt=Se.isArray,yO=rs?Yt(rs):SM;function fi(i){return i!=null&&au(i.length)&&!jo(i)}function Xn(i){return qn(i)&&fi(i)}function bO(i){return i===!0||i===!1||qn(i)&&Xr(i)==$e}var cs=LT||Af,wO=Vn?Yt(Vn):$M;function xO(i){return qn(i)&&i.nodeType===1&&!_l(i)}function CO(i){if(i==null)return!0;if(fi(i)&&(Rt(i)||typeof i=="string"||typeof i.splice=="function"||cs(i)||Ta(i)||Hs(i)))return!i.length;var v=Wr(i);if(v==lt||v==un)return!i.size;if(Cl(i))return!zd(i).length;for(var E in i)if(an.call(i,E))return!1;return!0}function AO(i,v){return bl(i,v)}function _O(i,v,E){E=typeof E=="function"?E:e;var H=E?E(i,v):e;return H===e?bl(i,v,e,E):!!H}function df(i){if(!qn(i))return!1;var v=Xr(i);return v==Ue||v==He||typeof i.message=="string"&&typeof i.name=="string"&&!_l(i)}function kO(i){return typeof i=="number"&&db(i)}function jo(i){if(!zn(i))return!1;var v=Xr(i);return v==ot||v==Qe||v==me||v==Dn}function I0(i){return typeof i=="number"&&i==Nt(i)}function au(i){return typeof i=="number"&&i>-1&&i%1==0&&i<=G}function zn(i){var v=typeof i;return i!=null&&(v=="object"||v=="function")}function qn(i){return i!=null&&typeof i=="object"}var L0=_i?Yt(_i):EM;function SO(i,v){return i===v||Fd(i,v,tf(v))}function $O(i,v,E){return E=typeof E=="function"?E:e,Fd(i,v,tf(v),E)}function RO(i){return O0(i)&&i!=+i}function EO(i){if(dI(i))throw new ht(f);return kb(i)}function TO(i){return i===null}function MO(i){return i==null}function O0(i){return typeof i=="number"||qn(i)&&Xr(i)==Tt}function _l(i){if(!qn(i)||Xr(i)!=At)return!1;var v=Oc(i);if(v===null)return!0;var E=an.call(v,"constructor")&&v.constructor;return typeof E=="function"&&E instanceof E&&Tc.call(E)==$T}var ff=ki?Yt(ki):TM;function IO(i){return I0(i)&&i>=-G&&i<=G}var N0=zi?Yt(zi):MM;function lu(i){return typeof i=="string"||!Rt(i)&&qn(i)&&Xr(i)==Yn}function $i(i){return typeof i=="symbol"||qn(i)&&Xr(i)==gt}var Ta=Ns?Yt(Ns):IM;function LO(i){return i===e}function OO(i){return qn(i)&&Wr(i)==Ft}function NO(i){return qn(i)&&Xr(i)==An}var DO=Xc(Bd),PO=Xc(function(i,v){return i<=v});function D0(i){if(!i)return[];if(fi(i))return lu(i)?bt(i):di(i);if(hl&&i[hl])return Te(i[hl]());var v=Wr(i),E=v==lt?Fe:v==un?Ke:Ma;return E(i)}function Ho(i){if(!i)return i===0?i:0;if(i=Vi(i),i===U||i===-U){var v=i<0?-1:1;return v*J}return i===i?i:0}function Nt(i){var v=Ho(i),E=v%1;return v===v?E?v-E:v:0}function P0(i){return i?zs(Nt(i),0,de):0}function Vi(i){if(typeof i=="number")return i;if($i(i))return ne;if(zn(i)){var v=typeof i.valueOf=="function"?i.valueOf():i;i=zn(v)?v+"":v}if(typeof i!="string")return i===0?i:+i;i=Ct(i);var E=bn.test(i);return E||hn.test(i)?wt(i.slice(2),E?2:8):eo.test(i)?ne:+i}function F0(i){return ko(i,pi(i))}function FO(i){return i?zs(Nt(i),-G,G):i===0?i:0}function ln(i){return i==null?"":Si(i)}var zO=$a(function(i,v){if(Cl(v)||fi(v)){ko(v,Cr(v),i);return}for(var E in v)an.call(v,E)&&ml(i,E,v[E])}),z0=$a(function(i,v){ko(v,pi(v),i)}),B0=$a(function(i,v,E,H){ko(v,pi(v),i,H)}),pf=$a(function(i,v,E,H){ko(v,Cr(v),i,H)}),BO=Bo(Ld);function WO(i,v){var E=Sa(i);return v==null?E:vb(E,v)}var jO=jt(function(i,v){i=Wt(i);var E=-1,H=v.length,K=H>2?v[2]:e;for(K&&Qr(v[0],v[1],K)&&(H=1);++E<H;)for(var te=v[E],he=pi(te),fe=-1,we=he.length;++fe<we;){var Me=he[fe],Le=i[Me];(Le===e||ao(Le,Do[Me])&&!an.call(i,Me))&&(i[Me]=te[Me])}return i}),HO=jt(function(i){return i.push(e,n0),on(W0,e,i)});function UO(i,v){return re(i,vt(v,3),_o)}function VO(i,v){return re(i,vt(v,3),Nd)}function qO(i,v){return i==null?i:Od(i,vt(v,3),pi)}function GO(i,v){return i==null?i:Cb(i,vt(v,3),pi)}function KO(i,v){return i&&_o(i,vt(v,3))}function YO(i,v){return i&&Nd(i,vt(v,3))}function JO(i){return i==null?[]:Uc(i,Cr(i))}function ZO(i){return i==null?[]:Uc(i,pi(i))}function gf(i,v,E){var H=i==null?e:Bs(i,v);return H===e?E:H}function XO(i,v){return i!=null&&o0(i,v,CM)}function mf(i,v){return i!=null&&o0(i,v,AM)}var QO=Zb(function(i,v,E){v!=null&&typeof v.toString!="function"&&(v=Mc.call(v)),i[v]=E},yf(gi)),eN=Zb(function(i,v,E){v!=null&&typeof v.toString!="function"&&(v=Mc.call(v)),an.call(i,v)?i[v].push(E):i[v]=[E]},vt),tN=jt(yl);function Cr(i){return fi(i)?gb(i):zd(i)}function pi(i){return fi(i)?gb(i,!0):LM(i)}function nN(i,v){var E={};return v=vt(v,3),_o(i,function(H,K,te){Ao(E,v(H,K,te),H)}),E}function rN(i,v){var E={};return v=vt(v,3),_o(i,function(H,K,te){Ao(E,K,v(H,K,te))}),E}var iN=$a(function(i,v,E){Vc(i,v,E)}),W0=$a(function(i,v,E,H){Vc(i,v,E,H)}),oN=Bo(function(i,v){var E={};if(i==null)return E;var H=!1;v=$(v,function(te){return te=as(te,i),H||(H=te.length>1),te}),ko(i,Qd(i),E),H&&(E=ji(E,c|h|o,eI));for(var K=v.length;K--;)Vd(E,v[K]);return E});function sN(i,v){return j0(i,su(vt(v)))}var aN=Bo(function(i,v){return i==null?{}:NM(i,v)});function j0(i,v){if(i==null)return{};var E=$(Qd(i),function(H){return[H]});return v=vt(v),Ib(i,E,function(H,K){return v(H,K[0])})}function lN(i,v,E){v=as(v,i);var H=-1,K=v.length;for(K||(K=1,i=e);++H<K;){var te=i==null?e:i[so(v[H])];te===e&&(H=K,te=E),i=jo(te)?te.call(i):te}return i}function cN(i,v,E){return i==null?i:wl(i,v,E)}function uN(i,v,E,H){return H=typeof H=="function"?H:e,i==null?i:wl(i,v,E,H)}var H0=e0(Cr),U0=e0(pi);function hN(i,v,E){var H=Rt(i),K=H||cs(i)||Ta(i);if(v=vt(v,4),E==null){var te=i&&i.constructor;K?E=H?new te:[]:zn(i)?E=jo(te)?Sa(Oc(i)):{}:E={}}return(K?fr:_o)(i,function(he,fe,we){return v(E,he,fe,we)}),E}function dN(i,v){return i==null?!0:Vd(i,v)}function fN(i,v,E){return i==null?i:Pb(i,v,Kd(E))}function pN(i,v,E,H){return H=typeof H=="function"?H:e,i==null?i:Pb(i,v,Kd(E),H)}function Ma(i){return i==null?[]:It(i,Cr(i))}function gN(i){return i==null?[]:It(i,pi(i))}function mN(i,v,E){return E===e&&(E=v,v=e),E!==e&&(E=Vi(E),E=E===E?E:0),v!==e&&(v=Vi(v),v=v===v?v:0),zs(Vi(i),v,E)}function vN(i,v,E){return v=Ho(v),E===e?(E=v,v=0):E=Ho(E),i=Vi(i),_M(i,v,E)}function yN(i,v,E){if(E&&typeof E!="boolean"&&Qr(i,v,E)&&(v=E=e),E===e&&(typeof v=="boolean"?(E=v,v=e):typeof i=="boolean"&&(E=i,i=e)),i===e&&v===e?(i=0,v=1):(i=Ho(i),v===e?(v=i,i=0):v=Ho(v)),i>v){var H=i;i=v,v=H}if(E||i%1||v%1){var K=fb();return Br(i+K*(v-i+wn("1e-"+((K+"").length-1))),v)}return jd(i,v)}var bN=Ra(function(i,v,E){return v=v.toLowerCase(),i+(E?V0(v):v)});function V0(i){return vf(ln(i).toLowerCase())}function q0(i){return i=ln(i),i&&i.replace(Ni,V).replace(ro,"")}function wN(i,v,E){i=ln(i),v=Si(v);var H=i.length;E=E===e?H:zs(Nt(E),0,H);var K=E;return E-=v.length,E>=0&&i.slice(E,K)==v}function xN(i){return i=ln(i),i&&Yr.test(i)?i.replace(wi,Z):i}function CN(i){return i=ln(i),i&&Sn.test(i)?i.replace(Dr,"\\$&"):i}var AN=Ra(function(i,v,E){return i+(E?"-":"")+v.toLowerCase()}),_N=Ra(function(i,v,E){return i+(E?" ":"")+v.toLowerCase()}),kN=Kb("toLowerCase");function SN(i,v,E){i=ln(i),v=Nt(v);var H=v?Bt(i):0;if(!v||H>=v)return i;var K=(v-H)/2;return Zc(Fc(K),E)+i+Zc(Pc(K),E)}function $N(i,v,E){i=ln(i),v=Nt(v);var H=v?Bt(i):0;return v&&H<v?i+Zc(v-H,E):i}function RN(i,v,E){i=ln(i),v=Nt(v);var H=v?Bt(i):0;return v&&H<v?Zc(v-H,E)+i:i}function EN(i,v,E){return E||v==null?v=0:v&&(v=+v),PT(ln(i).replace(Zn,""),v||0)}function TN(i,v,E){return(E?Qr(i,v,E):v===e)?v=1:v=Nt(v),Hd(ln(i),v)}function MN(){var i=arguments,v=ln(i[0]);return i.length<3?v:v.replace(i[1],i[2])}var IN=Ra(function(i,v,E){return i+(E?"_":"")+v.toLowerCase()});function LN(i,v,E){return E&&typeof E!="number"&&Qr(i,v,E)&&(v=E=e),E=E===e?de:E>>>0,E?(i=ln(i),i&&(typeof v=="string"||v!=null&&!ff(v))&&(v=Si(v),!v&&ge(i))?ls(bt(i),0,E):i.split(v,E)):[]}var ON=Ra(function(i,v,E){return i+(E?" ":"")+vf(v)});function NN(i,v,E){return i=ln(i),E=E==null?0:zs(Nt(E),0,i.length),v=Si(v),i.slice(E,E+v.length)==v}function DN(i,v,E){var H=Q.templateSettings;E&&Qr(i,v,E)&&(v=e),i=ln(i),v=pf({},v,H,t0);var K=pf({},v.imports,H.imports,t0),te=Cr(K),he=It(K,te);fr(te,function(pt){if(Mo.test(pt))throw new ht(u)});var fe,we,Me=0,Le=v.interpolate||Hn,Pe="__p += '",Ye=hi((v.escape||Hn).source+"|"+Le.source+"|"+(Le===To?_r:Hn).source+"|"+(v.evaluate||Hn).source+"|$","g"),st="//# sourceURL="+(an.call(v,"sourceURL")?(v.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Os+"]")+`
1462
+ `;i.replace(Ye,function(pt,Ut,Kt,Ri,ei,Ei){return Kt||(Kt=Ri),Pe+=i.slice(Me,Ei).replace(li,ie),Ut&&(fe=!0,Pe+=`' +
1463
+ __e(`+Ut+`) +
1464
+ '`),ei&&(we=!0,Pe+=`';
1465
+ `+ei+`;
1466
+ __p += '`),Kt&&(Pe+=`' +
1467
+ ((__t = (`+Kt+`)) == null ? '' : __t) +
1468
+ '`),Me=Ei+pt.length,pt}),Pe+=`';
1469
+ `;var yt=an.call(v,"variable")&&v.variable;if(!yt)Pe=`with (obj) {
1470
+ `+Pe+`
1471
+ }
1472
+ `;else if(Mo.test(yt))throw new ht(w);Pe=(we?Pe.replace(yr,""):Pe).replace(bi,"$1").replace(rr,"$1;"),Pe="function("+(yt||"obj")+`) {
1473
+ `+(yt?"":`obj || (obj = {});
1474
+ `)+"var __t, __p = ''"+(fe?", __e = _.escape":"")+(we?`, __j = Array.prototype.join;
1475
+ function print() { __p += __j.call(arguments, '') }
1476
+ `:`;
1477
+ `)+Pe+`return __p
1478
+ }`;var Dt=K0(function(){return kt(te,st+"return "+Pe).apply(e,he)});if(Dt.source=Pe,df(Dt))throw Dt;return Dt}function PN(i){return ln(i).toLowerCase()}function FN(i){return ln(i).toUpperCase()}function zN(i,v,E){if(i=ln(i),i&&(E||v===e))return Ct(i);if(!i||!(v=Si(v)))return i;var H=bt(i),K=bt(v),te=or(H,K),he=pr(H,K)+1;return ls(H,te,he).join("")}function BN(i,v,E){if(i=ln(i),i&&(E||v===e))return i.slice(0,ft(i)+1);if(!i||!(v=Si(v)))return i;var H=bt(i),K=pr(H,bt(v))+1;return ls(H,0,K).join("")}function WN(i,v,E){if(i=ln(i),i&&(E||v===e))return i.replace(Zn,"");if(!i||!(v=Si(v)))return i;var H=bt(i),K=or(H,bt(v));return ls(H,K).join("")}function jN(i,v){var E=W,H=F;if(zn(v)){var K="separator"in v?v.separator:K;E="length"in v?Nt(v.length):E,H="omission"in v?Si(v.omission):H}i=ln(i);var te=i.length;if(ge(i)){var he=bt(i);te=he.length}if(E>=te)return i;var fe=E-Bt(H);if(fe<1)return H;var we=he?ls(he,0,fe).join(""):i.slice(0,fe);if(K===e)return we+H;if(he&&(fe+=we.length-fe),ff(K)){if(i.slice(fe).search(K)){var Me,Le=we;for(K.global||(K=hi(K.source,ln($t.exec(K))+"g")),K.lastIndex=0;Me=K.exec(Le);)var Pe=Me.index;we=we.slice(0,Pe===e?fe:Pe)}}else if(i.indexOf(Si(K),fe)!=fe){var Ye=we.lastIndexOf(K);Ye>-1&&(we=we.slice(0,Ye))}return we+H}function HN(i){return i=ln(i),i&&Eo.test(i)?i.replace(Xi,at):i}var UN=Ra(function(i,v,E){return i+(E?" ":"")+v.toUpperCase()}),vf=Kb("toUpperCase");function G0(i,v,E){return i=ln(i),v=E?e:v,v===e?_e(i)?sr(i):X(i):i.match(v)||[]}var K0=jt(function(i,v){try{return on(i,e,v)}catch(E){return df(E)?E:new ht(E)}}),VN=Bo(function(i,v){return fr(v,function(E){E=so(E),Ao(i,E,uf(i[E],i))}),i});function qN(i){var v=i==null?0:i.length,E=vt();return i=v?$(i,function(H){if(typeof H[1]!="function")throw new xn(g);return[E(H[0]),H[1]]}):[],jt(function(H){for(var K=-1;++K<v;){var te=i[K];if(on(te[0],this,H))return on(te[1],this,H)}})}function GN(i){return bM(ji(i,c))}function yf(i){return function(){return i}}function KN(i,v){return i==null||i!==i?v:i}var YN=Jb(),JN=Jb(!0);function gi(i){return i}function bf(i){return Sb(typeof i=="function"?i:ji(i,c))}function ZN(i){return Rb(ji(i,c))}function XN(i,v){return Eb(i,ji(v,c))}var QN=jt(function(i,v){return function(E){return yl(E,i,v)}}),e2=jt(function(i,v){return function(E){return yl(i,E,v)}});function wf(i,v,E){var H=Cr(v),K=Uc(v,H);E==null&&!(zn(v)&&(K.length||!H.length))&&(E=v,v=i,i=this,K=Uc(v,Cr(v)));var te=!(zn(E)&&"chain"in E)||!!E.chain,he=jo(i);return fr(K,function(fe){var we=v[fe];i[fe]=we,he&&(i.prototype[fe]=function(){var Me=this.__chain__;if(te||Me){var Le=i(this.__wrapped__),Pe=Le.__actions__=di(this.__actions__);return Pe.push({func:we,args:arguments,thisArg:i}),Le.__chain__=Me,Le}return we.apply(i,_([this.value()],arguments))})}),i}function t2(){return zt._===this&&(zt._=RT),this}function xf(){}function n2(i){return i=Nt(i),jt(function(v){return Tb(v,i)})}var r2=Jd($),i2=Jd(Co),o2=Jd(j);function Y0(i){return rf(i)?Oe(so(i)):DM(i)}function s2(i){return function(v){return i==null?e:Bs(i,v)}}var a2=Xb(),l2=Xb(!0);function Cf(){return[]}function Af(){return!1}function c2(){return{}}function u2(){return""}function h2(){return!0}function d2(i,v){if(i=Nt(i),i<1||i>G)return[];var E=de,H=Br(i,de);v=vt(v),i-=de;for(var K=et(H,v);++E<i;)v(E);return K}function f2(i){return Rt(i)?$(i,so):$i(i)?[i]:di(p0(ln(i)))}function p2(i){var v=++ST;return ln(i)+v}var g2=Jc(function(i,v){return i+v},0),m2=Zd("ceil"),v2=Jc(function(i,v){return i/v},1),y2=Zd("floor");function b2(i){return i&&i.length?Hc(i,gi,Dd):e}function w2(i,v){return i&&i.length?Hc(i,vt(v,2),Dd):e}function x2(i){return Ae(i,gi)}function C2(i,v){return Ae(i,vt(v,2))}function A2(i){return i&&i.length?Hc(i,gi,Bd):e}function _2(i,v){return i&&i.length?Hc(i,vt(v,2),Bd):e}var k2=Jc(function(i,v){return i*v},1),S2=Zd("round"),$2=Jc(function(i,v){return i-v},0);function R2(i){return i&&i.length?Ze(i,gi):0}function E2(i,v){return i&&i.length?Ze(i,vt(v,2)):0}return Q.after=XL,Q.ary=k0,Q.assign=zO,Q.assignIn=z0,Q.assignInWith=B0,Q.assignWith=pf,Q.at=BO,Q.before=S0,Q.bind=uf,Q.bindAll=VN,Q.bindKey=$0,Q.castArray=uO,Q.chain=C0,Q.chunk=bI,Q.compact=wI,Q.concat=xI,Q.cond=qN,Q.conforms=GN,Q.constant=yf,Q.countBy=EL,Q.create=WO,Q.curry=R0,Q.curryRight=E0,Q.debounce=T0,Q.defaults=jO,Q.defaultsDeep=HO,Q.defer=QL,Q.delay=eO,Q.difference=CI,Q.differenceBy=AI,Q.differenceWith=_I,Q.drop=kI,Q.dropRight=SI,Q.dropRightWhile=$I,Q.dropWhile=RI,Q.fill=EI,Q.filter=ML,Q.flatMap=OL,Q.flatMapDeep=NL,Q.flatMapDepth=DL,Q.flatten=y0,Q.flattenDeep=TI,Q.flattenDepth=MI,Q.flip=tO,Q.flow=YN,Q.flowRight=JN,Q.fromPairs=II,Q.functions=JO,Q.functionsIn=ZO,Q.groupBy=PL,Q.initial=OI,Q.intersection=NI,Q.intersectionBy=DI,Q.intersectionWith=PI,Q.invert=QO,Q.invertBy=eN,Q.invokeMap=zL,Q.iteratee=bf,Q.keyBy=BL,Q.keys=Cr,Q.keysIn=pi,Q.map=ru,Q.mapKeys=nN,Q.mapValues=rN,Q.matches=ZN,Q.matchesProperty=XN,Q.memoize=ou,Q.merge=iN,Q.mergeWith=W0,Q.method=QN,Q.methodOf=e2,Q.mixin=wf,Q.negate=su,Q.nthArg=n2,Q.omit=oN,Q.omitBy=sN,Q.once=nO,Q.orderBy=WL,Q.over=r2,Q.overArgs=rO,Q.overEvery=i2,Q.overSome=o2,Q.partial=hf,Q.partialRight=M0,Q.partition=jL,Q.pick=aN,Q.pickBy=j0,Q.property=Y0,Q.propertyOf=s2,Q.pull=WI,Q.pullAll=w0,Q.pullAllBy=jI,Q.pullAllWith=HI,Q.pullAt=UI,Q.range=a2,Q.rangeRight=l2,Q.rearg=iO,Q.reject=VL,Q.remove=VI,Q.rest=oO,Q.reverse=lf,Q.sampleSize=GL,Q.set=cN,Q.setWith=uN,Q.shuffle=KL,Q.slice=qI,Q.sortBy=ZL,Q.sortedUniq=QI,Q.sortedUniqBy=eL,Q.split=LN,Q.spread=sO,Q.tail=tL,Q.take=nL,Q.takeRight=rL,Q.takeRightWhile=iL,Q.takeWhile=oL,Q.tap=wL,Q.throttle=aO,Q.thru=nu,Q.toArray=D0,Q.toPairs=H0,Q.toPairsIn=U0,Q.toPath=f2,Q.toPlainObject=F0,Q.transform=hN,Q.unary=lO,Q.union=sL,Q.unionBy=aL,Q.unionWith=lL,Q.uniq=cL,Q.uniqBy=uL,Q.uniqWith=hL,Q.unset=dN,Q.unzip=cf,Q.unzipWith=x0,Q.update=fN,Q.updateWith=pN,Q.values=Ma,Q.valuesIn=gN,Q.without=dL,Q.words=G0,Q.wrap=cO,Q.xor=fL,Q.xorBy=pL,Q.xorWith=gL,Q.zip=mL,Q.zipObject=vL,Q.zipObjectDeep=yL,Q.zipWith=bL,Q.entries=H0,Q.entriesIn=U0,Q.extend=z0,Q.extendWith=B0,wf(Q,Q),Q.add=g2,Q.attempt=K0,Q.camelCase=bN,Q.capitalize=V0,Q.ceil=m2,Q.clamp=mN,Q.clone=hO,Q.cloneDeep=fO,Q.cloneDeepWith=pO,Q.cloneWith=dO,Q.conformsTo=gO,Q.deburr=q0,Q.defaultTo=KN,Q.divide=v2,Q.endsWith=wN,Q.eq=ao,Q.escape=xN,Q.escapeRegExp=CN,Q.every=TL,Q.find=IL,Q.findIndex=m0,Q.findKey=UO,Q.findLast=LL,Q.findLastIndex=v0,Q.findLastKey=VO,Q.floor=y2,Q.forEach=A0,Q.forEachRight=_0,Q.forIn=qO,Q.forInRight=GO,Q.forOwn=KO,Q.forOwnRight=YO,Q.get=gf,Q.gt=mO,Q.gte=vO,Q.has=XO,Q.hasIn=mf,Q.head=b0,Q.identity=gi,Q.includes=FL,Q.indexOf=LI,Q.inRange=vN,Q.invoke=tN,Q.isArguments=Hs,Q.isArray=Rt,Q.isArrayBuffer=yO,Q.isArrayLike=fi,Q.isArrayLikeObject=Xn,Q.isBoolean=bO,Q.isBuffer=cs,Q.isDate=wO,Q.isElement=xO,Q.isEmpty=CO,Q.isEqual=AO,Q.isEqualWith=_O,Q.isError=df,Q.isFinite=kO,Q.isFunction=jo,Q.isInteger=I0,Q.isLength=au,Q.isMap=L0,Q.isMatch=SO,Q.isMatchWith=$O,Q.isNaN=RO,Q.isNative=EO,Q.isNil=MO,Q.isNull=TO,Q.isNumber=O0,Q.isObject=zn,Q.isObjectLike=qn,Q.isPlainObject=_l,Q.isRegExp=ff,Q.isSafeInteger=IO,Q.isSet=N0,Q.isString=lu,Q.isSymbol=$i,Q.isTypedArray=Ta,Q.isUndefined=LO,Q.isWeakMap=OO,Q.isWeakSet=NO,Q.join=FI,Q.kebabCase=AN,Q.last=Ui,Q.lastIndexOf=zI,Q.lowerCase=_N,Q.lowerFirst=kN,Q.lt=DO,Q.lte=PO,Q.max=b2,Q.maxBy=w2,Q.mean=x2,Q.meanBy=C2,Q.min=A2,Q.minBy=_2,Q.stubArray=Cf,Q.stubFalse=Af,Q.stubObject=c2,Q.stubString=u2,Q.stubTrue=h2,Q.multiply=k2,Q.nth=BI,Q.noConflict=t2,Q.noop=xf,Q.now=iu,Q.pad=SN,Q.padEnd=$N,Q.padStart=RN,Q.parseInt=EN,Q.random=yN,Q.reduce=HL,Q.reduceRight=UL,Q.repeat=TN,Q.replace=MN,Q.result=lN,Q.round=S2,Q.runInContext=ve,Q.sample=qL,Q.size=YL,Q.snakeCase=IN,Q.some=JL,Q.sortedIndex=GI,Q.sortedIndexBy=KI,Q.sortedIndexOf=YI,Q.sortedLastIndex=JI,Q.sortedLastIndexBy=ZI,Q.sortedLastIndexOf=XI,Q.startCase=ON,Q.startsWith=NN,Q.subtract=$2,Q.sum=R2,Q.sumBy=E2,Q.template=DN,Q.times=d2,Q.toFinite=Ho,Q.toInteger=Nt,Q.toLength=P0,Q.toLower=PN,Q.toNumber=Vi,Q.toSafeInteger=FO,Q.toString=ln,Q.toUpper=FN,Q.trim=zN,Q.trimEnd=BN,Q.trimStart=WN,Q.truncate=jN,Q.unescape=HN,Q.uniqueId=p2,Q.upperCase=UN,Q.upperFirst=vf,Q.each=A0,Q.eachRight=_0,Q.first=b0,wf(Q,(function(){var i={};return _o(Q,function(v,E){an.call(Q.prototype,E)||(i[E]=v)}),i})(),{chain:!1}),Q.VERSION=r,fr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(i){Q[i].placeholder=Q}),fr(["drop","take"],function(i,v){Gt.prototype[i]=function(E){E=E===e?1:gr(Nt(E),0);var H=this.__filtered__&&!v?new Gt(this):this.clone();return H.__filtered__?H.__takeCount__=Br(E,H.__takeCount__):H.__views__.push({size:Br(E,de),type:i+(H.__dir__<0?"Right":"")}),H},Gt.prototype[i+"Right"]=function(E){return this.reverse()[i](E).reverse()}}),fr(["filter","map","takeWhile"],function(i,v){var E=v+1,H=E==A||E==B;Gt.prototype[i]=function(K){var te=this.clone();return te.__iteratees__.push({iteratee:vt(K,3),type:E}),te.__filtered__=te.__filtered__||H,te}}),fr(["head","last"],function(i,v){var E="take"+(v?"Right":"");Gt.prototype[i]=function(){return this[E](1).value()[0]}}),fr(["initial","tail"],function(i,v){var E="drop"+(v?"":"Right");Gt.prototype[i]=function(){return this.__filtered__?new Gt(this):this[E](1)}}),Gt.prototype.compact=function(){return this.filter(gi)},Gt.prototype.find=function(i){return this.filter(i).head()},Gt.prototype.findLast=function(i){return this.reverse().find(i)},Gt.prototype.invokeMap=jt(function(i,v){return typeof i=="function"?new Gt(this):this.map(function(E){return yl(E,i,v)})}),Gt.prototype.reject=function(i){return this.filter(su(vt(i)))},Gt.prototype.slice=function(i,v){i=Nt(i);var E=this;return E.__filtered__&&(i>0||v<0)?new Gt(E):(i<0?E=E.takeRight(-i):i&&(E=E.drop(i)),v!==e&&(v=Nt(v),E=v<0?E.dropRight(-v):E.take(v-i)),E)},Gt.prototype.takeRightWhile=function(i){return this.reverse().takeWhile(i).reverse()},Gt.prototype.toArray=function(){return this.take(de)},_o(Gt.prototype,function(i,v){var E=/^(?:filter|find|map|reject)|While$/.test(v),H=/^(?:head|last)$/.test(v),K=Q[H?"take"+(v=="last"?"Right":""):v],te=H||/^find/.test(v);K&&(Q.prototype[v]=function(){var he=this.__wrapped__,fe=H?[1]:arguments,we=he instanceof Gt,Me=fe[0],Le=we||Rt(he),Pe=function(Ut){var Kt=K.apply(Q,_([Ut],fe));return H&&Ye?Kt[0]:Kt};Le&&E&&typeof Me=="function"&&Me.length!=1&&(we=Le=!1);var Ye=this.__chain__,st=!!this.__actions__.length,yt=te&&!Ye,Dt=we&&!st;if(!te&&Le){he=Dt?he:new Gt(this);var pt=i.apply(he,fe);return pt.__actions__.push({func:nu,args:[Pe],thisArg:e}),new Wi(pt,Ye)}return yt&&Dt?i.apply(this,fe):(pt=this.thru(Pe),yt?H?pt.value()[0]:pt.value():pt)})}),fr(["pop","push","shift","sort","splice","unshift"],function(i){var v=Bi[i],E=/^(?:push|sort|unshift)$/.test(i)?"tap":"thru",H=/^(?:pop|shift)$/.test(i);Q.prototype[i]=function(){var K=arguments;if(H&&!this.__chain__){var te=this.value();return v.apply(Rt(te)?te:[],K)}return this[E](function(he){return v.apply(Rt(he)?he:[],K)})}}),_o(Gt.prototype,function(i,v){var E=Q[v];if(E){var H=E.name+"";an.call(ka,H)||(ka[H]=[]),ka[H].push({name:v,func:E})}}),ka[Yc(e,x).name]=[{name:"wrapper",func:e}],Gt.prototype.clone=UT,Gt.prototype.reverse=VT,Gt.prototype.value=qT,Q.prototype.at=xL,Q.prototype.chain=CL,Q.prototype.commit=AL,Q.prototype.next=_L,Q.prototype.plant=SL,Q.prototype.reverse=$L,Q.prototype.toJSON=Q.prototype.valueOf=Q.prototype.value=RL,Q.prototype.first=Q.prototype.head,hl&&(Q.prototype[hl]=kL),Q}),dn=sn();ir?((ir.exports=dn)._=dn,Fr._=dn):zt._=dn}).call(MA)})(Gl,Gl.exports)),Gl.exports}var LA=IA();On("T",ql(LA)).debounce(function(){this.rebuildDisplayText()},300);var $g={exports:{}},Rg;function OA(){return Rg||(Rg=1,(function(t,n){(function(){ace.require(["ace/mode/text"],function(e){t&&(t.exports=e)})})()})($g)),$g.exports}OA();const NA=!0,ar="u-",DA="uplot",PA=ar+"hz",FA=ar+"vt",zA=ar+"title",BA=ar+"wrap",WA=ar+"under",jA=ar+"over",HA=ar+"axis",ws=ar+"off",UA=ar+"select",VA=ar+"cursor-x",qA=ar+"cursor-y",GA=ar+"cursor-pt",KA=ar+"legend",YA=ar+"live",JA=ar+"inline",ZA=ar+"series",XA=ar+"marker",Eg=ar+"label",QA=ar+"value",qa="width",Ga="height",Ka="top",Tg="bottom",Qs="left",Bu="right",Wu="#000",Mg=Wu+"0",ju="mousemove",Ig="mousedown",Hu="mouseup",Lg="mouseenter",Og="mouseleave",Ng="dblclick",e_="resize",t_="scroll",Dg="change",Kl="dppxchange",Uu="--",ea=typeof window<"u",Vu=ea?document:null,ta=ea?window:null,n_=ea?navigator:null;let tn,Yl;function qu(){let t=devicePixelRatio;tn!=t&&(tn=t,Yl&&Yu(Dg,Yl,qu),Yl=matchMedia(`(min-resolution: ${tn-.001}dppx) and (max-resolution: ${tn+.001}dppx)`),xs(Dg,Yl,qu),ta.dispatchEvent(new CustomEvent(Kl)))}function mi(t,n){if(n!=null){let e=t.classList;!e.contains(n)&&e.add(n)}}function Gu(t,n){let e=t.classList;e.contains(n)&&e.remove(n)}function Cn(t,n,e){t.style[n]=e+"px"}function Ki(t,n,e,r){let m=Vu.createElement(t);return n!=null&&mi(m,n),e?.insertBefore(m,r),m}function Mi(t,n){return Ki("div",t,n)}const Pg=new WeakMap;function ho(t,n,e,r,m){let f="translate("+n+"px,"+e+"px)",g=Pg.get(t);f!=g&&(t.style.transform=f,Pg.set(t,f),n<0||e<0||n>r||e>m?mi(t,ws):Gu(t,ws))}const Fg=new WeakMap;function zg(t,n,e){let r=n+e,m=Fg.get(t);r!=m&&(Fg.set(t,r),t.style.background=n,t.style.borderColor=e)}const Bg=new WeakMap;function Wg(t,n,e,r){let m=n+""+e,f=Bg.get(t);m!=f&&(Bg.set(t,m),t.style.height=e+"px",t.style.width=n+"px",t.style.marginLeft=r?-n/2+"px":0,t.style.marginTop=r?-e/2+"px":0)}const Ku={passive:!0},r_={...Ku,capture:!0};function xs(t,n,e,r){n.addEventListener(t,e,r?r_:Ku)}function Yu(t,n,e,r){n.removeEventListener(t,e,Ku)}ea&&qu();function Yi(t,n,e,r){let m;e=e||0,r=r||n.length-1;let f=r<=2147483647;for(;r-e>1;)m=f?e+r>>1:yi((e+r)/2),n[m]<t?e=m:r=m;return t-n[e]<=n[r]-t?e:r}function jg(t){return(n,e,r)=>{let m=-1,f=-1;for(let g=e;g<=r;g++)if(t(n[g])){m=g;break}for(let g=r;g>=e;g--)if(t(n[g])){f=g;break}return[m,f]}}const Hg=t=>t!=null,Ug=t=>t!=null&&t>0,Jl=jg(Hg),i_=jg(Ug);function o_(t,n,e,r=0,m=!1){let f=m?i_:Jl,g=m?Ug:Hg;[n,e]=f(t,n,e);let w=t[n],u=t[n];if(n>-1)if(r==1)w=t[n],u=t[e];else if(r==-1)w=t[e],u=t[n];else for(let d=n;d<=e;d++){let a=t[d];g(a)&&(a<w?w=a:a>u&&(u=a))}return[w??pn,u??-pn]}function Zl(t,n,e,r){let m=Gg(t),f=Gg(n);t==n&&(m==-1?(t*=e,n/=e):(t/=e,n*=e));let g=e==10?$o:Kg,w=m==1?yi:Ii,u=f==1?Ii:yi,d=w(g(lr(t))),a=u(g(lr(n))),l=na(e,d),c=na(e,a);return e==10&&(d<0&&(l=gn(l,-d)),a<0&&(c=gn(c,-a))),r||e==2?(t=l*m,n=c*f):(t=tm(t,l),n=ec(n,c)),[t,n]}function Ju(t,n,e,r){let m=Zl(t,n,e,r);return t==0&&(m[0]=0),n==0&&(m[1]=0),m}const Zu=.1,Vg={mode:3,pad:Zu},Ya={pad:0,soft:null,mode:0},s_={min:Ya,max:Ya};function Xl(t,n,e,r){return tc(e)?qg(t,n,e):(Ya.pad=e,Ya.soft=r?0:null,Ya.mode=r?3:0,qg(t,n,s_))}function Qt(t,n){return t??n}function a_(t,n,e){for(n=Qt(n,0),e=Qt(e,t.length-1);n<=e;){if(t[n]!=null)return!0;n++}return!1}function qg(t,n,e){let r=e.min,m=e.max,f=Qt(r.pad,0),g=Qt(m.pad,0),w=Qt(r.hard,-pn),u=Qt(m.hard,pn),d=Qt(r.soft,pn),a=Qt(m.soft,-pn),l=Qt(r.mode,0),c=Qt(m.mode,0),h=n-t,o=$o(h),s=Ur(lr(t),lr(n)),p=$o(s),b=lr(p-o);(h<1e-24||b>10)&&(h=0,(t==0||n==0)&&(h=1e-24,l==2&&d!=pn&&(f=0),c==2&&a!=-pn&&(g=0)));let x=h||s||1e3,M=$o(x),R=na(10,yi(M)),k=x*(h==0?t==0?.1:1:f),C=gn(tm(t-k,R/10),24),L=t>=d&&(l==1||l==3&&C<=d||l==2&&C>=d)?d:pn,D=Ur(w,C<L&&t>=L?L:Ji(L,C)),I=x*(h==0?n==0?.1:1:g),T=gn(ec(n+I,R/10),24),W=n<=a&&(c==1||c==3&&T>=a||c==2&&T<=a)?a:-pn,F=Ji(u,T>W&&n<=W?W:Ur(W,T));return D==F&&D==0&&(F=100),[D,F]}const l_=new Intl.NumberFormat(ea?n_.language:"en-US"),Xu=t=>l_.format(t),vi=Math,Ql=vi.PI,lr=vi.abs,yi=vi.floor,cr=vi.round,Ii=vi.ceil,Ji=vi.min,Ur=vi.max,na=vi.pow,Gg=vi.sign,$o=vi.log10,Kg=vi.log2,c_=(t,n=1)=>vi.sinh(t)*n,Qu=(t,n=1)=>vi.asinh(t/n),pn=1/0;function Yg(t){return($o((t^t>>31)-(t>>31))|0)+1}function eh(t,n,e){return Ji(Ur(t,n),e)}function Jg(t){return typeof t=="function"}function Vt(t){return Jg(t)?t:()=>t}const u_=()=>{},Zg=t=>t,Xg=(t,n)=>n,h_=t=>null,Qg=t=>!0,em=(t,n)=>t==n,d_=/\.\d*?(?=9{6,}|0{6,})/gm,Cs=t=>{if(rm(t)||Ko.has(t))return t;const n=`${t}`,e=n.match(d_);if(e==null)return t;let r=e[0].length-1;if(n.indexOf("e-")!=-1){let[m,f]=n.split("e");return+`${Cs(m)}e${f}`}return gn(t,r)};function As(t,n){return Cs(gn(Cs(t/n))*n)}function ec(t,n){return Cs(Ii(Cs(t/n))*n)}function tm(t,n){return Cs(yi(Cs(t/n))*n)}function gn(t,n=0){if(rm(t))return t;let e=10**n,r=t*e*(1+Number.EPSILON);return cr(r)/e}const Ko=new Map;function nm(t){return((""+t).split(".")[1]||"").length}function Ja(t,n,e,r){let m=[],f=r.map(nm);for(let g=n;g<e;g++){let w=lr(g),u=gn(na(t,g),w);for(let d=0;d<r.length;d++){let a=t==10?+`${r[d]}e${g}`:r[d]*u,l=(g>=0?0:w)+(g>=f[d]?0:f[d]),c=t==10?a:gn(a,l);m.push(c),Ko.set(c,l)}}return m}const Za={},th=[],ra=[null,null],Yo=Array.isArray,rm=Number.isInteger,f_=t=>t===void 0;function im(t){return typeof t=="string"}function tc(t){let n=!1;if(t!=null){let e=t.constructor;n=e==null||e==Object}return n}function p_(t){return t!=null&&typeof t=="object"}const g_=Object.getPrototypeOf(Uint8Array),om="__proto__";function ia(t,n=tc){let e;if(Yo(t)){let r=t.find(m=>m!=null);if(Yo(r)||n(r)){e=Array(t.length);for(let m=0;m<t.length;m++)e[m]=ia(t[m],n)}else e=t.slice()}else if(t instanceof g_)e=t.slice();else if(n(t)){e={};for(let r in t)r!=om&&(e[r]=ia(t[r],n))}else e=t;return e}function er(t){let n=arguments;for(let e=1;e<n.length;e++){let r=n[e];for(let m in r)m!=om&&(tc(t[m])?er(t[m],ia(r[m])):t[m]=ia(r[m]))}return t}const m_=0,v_=1,y_=2;function b_(t,n,e){for(let r=0,m,f=-1;r<n.length;r++){let g=n[r];if(g>f){for(m=g-1;m>=0&&t[m]==null;)t[m--]=null;for(m=g+1;m<e&&t[m]==null;)t[f=m++]=null}}}function w_(t,n){if(A_(t)){let g=t[0].slice();for(let w=1;w<t.length;w++)g.push(...t[w].slice(1));return __(g[0])||(g=C_(g)),g}let e=new Set;for(let g=0;g<t.length;g++){let w=t[g][0],u=w.length;for(let d=0;d<u;d++)e.add(w[d])}let r=[Array.from(e).sort((g,w)=>g-w)],m=r[0].length,f=new Map;for(let g=0;g<m;g++)f.set(r[0][g],g);for(let g=0;g<t.length;g++){let w=t[g],u=w[0];for(let d=1;d<w.length;d++){let a=w[d],l=Array(m).fill(void 0),c=n?n[g][d]:v_,h=[];for(let o=0;o<a.length;o++){let s=a[o],p=f.get(u[o]);s===null?c!=m_&&(l[p]=s,c==y_&&h.push(p)):l[p]=s}b_(l,h,m),r.push(l)}}return r}const x_=typeof queueMicrotask>"u"?t=>Promise.resolve().then(t):queueMicrotask;function C_(t){let n=t[0],e=n.length,r=Array(e);for(let f=0;f<r.length;f++)r[f]=f;r.sort((f,g)=>n[f]-n[g]);let m=[];for(let f=0;f<t.length;f++){let g=t[f],w=Array(e);for(let u=0;u<e;u++)w[u]=g[r[u]];m.push(w)}return m}function A_(t){let n=t[0][0],e=n.length;for(let r=1;r<t.length;r++){let m=t[r][0];if(m.length!=e)return!1;if(m!=n){for(let f=0;f<e;f++)if(m[f]!=n[f])return!1}}return!0}function __(t,n=100){const e=t.length;if(e<=1)return!0;let r=0,m=e-1;for(;r<=m&&t[r]==null;)r++;for(;m>=r&&t[m]==null;)m--;if(m<=r)return!0;const f=Ur(1,yi((m-r+1)/n));for(let g=t[r],w=r+f;w<=m;w+=f){const u=t[w];if(u!=null){if(u<=g)return!1;g=u}}return!0}const sm=["January","February","March","April","May","June","July","August","September","October","November","December"],am=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function lm(t){return t.slice(0,3)}const k_=am.map(lm),S_=sm.map(lm),$_={MMMM:sm,MMM:S_,WWWW:am,WWW:k_};function Xa(t){return(t<10?"0":"")+t}function R_(t){return(t<10?"00":t<100?"0":"")+t}const E_={YYYY:t=>t.getFullYear(),YY:t=>(t.getFullYear()+"").slice(2),MMMM:(t,n)=>n.MMMM[t.getMonth()],MMM:(t,n)=>n.MMM[t.getMonth()],MM:t=>Xa(t.getMonth()+1),M:t=>t.getMonth()+1,DD:t=>Xa(t.getDate()),D:t=>t.getDate(),WWWW:(t,n)=>n.WWWW[t.getDay()],WWW:(t,n)=>n.WWW[t.getDay()],HH:t=>Xa(t.getHours()),H:t=>t.getHours(),h:t=>{let n=t.getHours();return n==0?12:n>12?n-12:n},AA:t=>t.getHours()>=12?"PM":"AM",aa:t=>t.getHours()>=12?"pm":"am",a:t=>t.getHours()>=12?"p":"a",mm:t=>Xa(t.getMinutes()),m:t=>t.getMinutes(),ss:t=>Xa(t.getSeconds()),s:t=>t.getSeconds(),fff:t=>R_(t.getMilliseconds())};function nh(t,n){n=n||$_;let e=[],r=/\{([a-z]+)\}|[^{]+/gi,m;for(;m=r.exec(t);)e.push(m[0][0]=="{"?E_[m[1]]:m[0]);return f=>{let g="";for(let w=0;w<e.length;w++)g+=typeof e[w]=="string"?e[w]:e[w](f,n);return g}}const T_=new Intl.DateTimeFormat().resolvedOptions().timeZone;function M_(t,n){let e;return n=="UTC"||n=="Etc/UTC"?e=new Date(+t+t.getTimezoneOffset()*6e4):n==T_?e=t:(e=new Date(t.toLocaleString("en-US",{timeZone:n})),e.setMilliseconds(t.getMilliseconds())),e}const cm=t=>t%1==0,nc=[1,2,2.5,5],I_=Ja(10,-32,0,nc),um=Ja(10,0,32,nc),L_=um.filter(cm),_s=I_.concat(um),rh=`
1479
+ `,hm="{YYYY}",dm=rh+hm,fm="{M}/{D}",Qa=rh+fm,rc=Qa+"/{YY}",pm="{aa}",O_="{h}:{mm}",oa=O_+pm,gm=rh+oa,mm=":{ss}",rn=null;function vm(t){let n=t*1e3,e=n*60,r=e*60,m=r*24,f=m*30,g=m*365,w=(t==1?Ja(10,0,3,nc).filter(cm):Ja(10,-3,0,nc)).concat([n,n*5,n*10,n*15,n*30,e,e*5,e*10,e*15,e*30,r,r*2,r*3,r*4,r*6,r*8,r*12,m,m*2,m*3,m*4,m*5,m*6,m*7,m*8,m*9,m*10,m*15,f,f*2,f*3,f*4,f*6,g,g*2,g*5,g*10,g*25,g*50,g*100]);const u=[[g,hm,rn,rn,rn,rn,rn,rn,1],[m*28,"{MMM}",dm,rn,rn,rn,rn,rn,1],[m,fm,dm,rn,rn,rn,rn,rn,1],[r,"{h}"+pm,rc,rn,Qa,rn,rn,rn,1],[e,oa,rc,rn,Qa,rn,rn,rn,1],[n,mm,rc+" "+oa,rn,Qa+" "+oa,rn,gm,rn,1],[t,mm+".{fff}",rc+" "+oa,rn,Qa+" "+oa,rn,gm,rn,1]];function d(a){return(l,c,h,o,s,p)=>{let b=[],x=s>=g,M=s>=f&&s<g,R=a(h),k=gn(R*t,3),C=ih(R.getFullYear(),x?0:R.getMonth(),M||x?1:R.getDate()),L=gn(C*t,3);if(M||x){let D=M?s/f:0,I=x?s/g:0,T=k==L?k:gn(ih(C.getFullYear()+I,C.getMonth()+D,1)*t,3),W=new Date(cr(T/t)),F=W.getFullYear(),O=W.getMonth();for(let S=0;T<=o;S++){let A=ih(F+I*S,O+D*S,1),N=A-a(gn(A*t,3));T=gn((+A+N)*t,3),T<=o&&b.push(T)}}else{let D=s>=m?m:s,I=yi(h)-yi(k),T=L+I+ec(k-L,D);b.push(T);let W=a(T),F=W.getHours()+W.getMinutes()/e+W.getSeconds()/r,O=s/r,S=l.axes[c]._space,A=p/S;for(;T=gn(T+s,t==1?0:3),!(T>o);)if(O>1){let N=yi(gn(F+O,6))%24,B=a(T).getHours()-N;B>1&&(B=-1),T-=B*r,F=(F+O)%24;let U=b[b.length-1];gn((T-U)/s,3)*A>=.7&&b.push(T)}else b.push(T)}return b}}return[w,u,d]}const[N_,D_,P_]=vm(1),[F_,z_,B_]=vm(.001);Ja(2,-53,53,[1]);function ym(t,n){return t.map(e=>e.map((r,m)=>m==0||m==8||r==null?r:n(m==1||e[8]==0?r:e[1]+r)))}function bm(t,n){return(e,r,m,f,g)=>{let w=n.find(o=>g>=o[0])||n[n.length-1],u,d,a,l,c,h;return r.map(o=>{let s=t(o),p=s.getFullYear(),b=s.getMonth(),x=s.getDate(),M=s.getHours(),R=s.getMinutes(),k=s.getSeconds(),C=p!=u&&w[2]||b!=d&&w[3]||x!=a&&w[4]||M!=l&&w[5]||R!=c&&w[6]||k!=h&&w[7]||w[1];return u=p,d=b,a=x,l=M,c=R,h=k,C(s)})}}function W_(t,n){let e=nh(n);return(r,m,f,g,w)=>m.map(u=>e(t(u)))}function ih(t,n,e){return new Date(t,n,e)}function wm(t,n){return n(t)}const j_="{YYYY}-{MM}-{DD} {h}:{mm}{aa}";function xm(t,n){return(e,r,m,f)=>f==null?Uu:n(t(r))}function H_(t,n){let e=t.series[n];return e.width?e.stroke(t,n):e.points.width?e.points.stroke(t,n):null}function U_(t,n){return t.series[n].fill(t,n)}const V_={show:!0,live:!0,isolate:!1,mount:u_,markers:{show:!0,width:2,stroke:H_,fill:U_,dash:"solid"},idx:null,idxs:null,values:[]};function q_(t,n){let e=t.cursor.points,r=Mi(),m=e.size(t,n);Cn(r,qa,m),Cn(r,Ga,m);let f=m/-2;Cn(r,"marginLeft",f),Cn(r,"marginTop",f);let g=e.width(t,n,m);return g&&Cn(r,"borderWidth",g),r}function G_(t,n){let e=t.series[n].points;return e._fill||e._stroke}function K_(t,n){let e=t.series[n].points;return e._stroke||e._fill}function Y_(t,n){return t.series[n].points.size}const oh=[0,0];function J_(t,n,e){return oh[0]=n,oh[1]=e,oh}function ic(t,n,e,r=!0){return m=>{m.button==0&&(!r||m.target==n)&&e(m)}}function sh(t,n,e,r=!0){return m=>{(!r||m.target==n)&&e(m)}}const Z_={show:!0,x:!0,y:!0,lock:!1,move:J_,points:{one:!1,show:q_,size:Y_,width:0,stroke:K_,fill:G_},bind:{mousedown:ic,mouseup:ic,click:ic,dblclick:ic,mousemove:sh,mouseleave:sh,mouseenter:sh},drag:{setScale:!0,x:!0,y:!1,dist:0,uni:null,click:(t,n)=>{n.stopPropagation(),n.stopImmediatePropagation()},_x:!1,_y:!1},focus:{dist:(t,n,e,r,m)=>r-m,prox:-1,bias:0},hover:{skip:[void 0],prox:null,bias:0},left:-10,top:-10,idx:null,dataIdx:null,idxs:null,event:null},Cm={show:!0,stroke:"rgba(0,0,0,0.07)",width:2},ah=er({},Cm,{filter:Xg}),Am=er({},ah,{size:10}),_m=er({},Cm,{show:!1}),lh='12px system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"',km="bold "+lh,Sm=1.5,$m={show:!0,scale:"x",stroke:Wu,space:50,gap:5,alignTo:1,size:50,labelGap:0,labelSize:30,labelFont:km,side:2,grid:ah,ticks:Am,border:_m,font:lh,lineGap:Sm,rotate:0},X_="Value",Q_="Time",Rm={show:!0,scale:"x",auto:!1,sorted:1,min:pn,max:-pn,idxs:[]};function ek(t,n,e,r,m){return n.map(f=>f==null?"":Xu(f))}function tk(t,n,e,r,m,f,g){let w=[],u=Ko.get(m)||0;e=g?e:gn(ec(e,m),u);for(let d=e;d<=r;d=gn(d+m,u))w.push(Object.is(d,-0)?0:d);return w}function ch(t,n,e,r,m,f,g){const w=[],u=t.scales[t.axes[n].scale].log,d=u==10?$o:Kg,a=yi(d(e));m=na(u,a),u==10&&(m=_s[Yi(m,_s)]);let l=e,c=m*u;u==10&&(c=_s[Yi(c,_s)]);do w.push(l),l=l+m,u==10&&!Ko.has(l)&&(l=gn(l,Ko.get(m))),l>=c&&(m=l,c=m*u,u==10&&(c=_s[Yi(c,_s)]));while(l<=r);return w}function nk(t,n,e,r,m,f,g){let w=t.scales[t.axes[n].scale].asinh,u=r>w?ch(t,n,Ur(w,e),r,m):[w],d=r>=0&&e<=0?[0]:[];return(e<-w?ch(t,n,Ur(w,-r),-e,m):[w]).reverse().map(a=>-a).concat(d,u)}const Em=/./,rk=/[12357]/,ik=/[125]/,Tm=/1/,uh=(t,n,e,r)=>t.map((m,f)=>n==4&&m==0||f%r==0&&e.test(m.toExponential()[m<0?1:0])?m:null);function ok(t,n,e,r,m){let f=t.axes[e],g=f.scale,w=t.scales[g],u=t.valToPos,d=f._space,a=u(10,g),l=u(9,g)-a>=d?Em:u(7,g)-a>=d?rk:u(5,g)-a>=d?ik:Tm;if(l==Tm){let c=lr(u(1,g)-a);if(c<d)return uh(n.slice().reverse(),w.distr,l,Ii(d/c)).reverse()}return uh(n,w.distr,l,1)}function sk(t,n,e,r,m){let f=t.axes[e],g=f.scale,w=f._space,u=t.valToPos,d=lr(u(1,g)-u(2,g));return d<w?uh(n.slice().reverse(),3,Em,Ii(w/d)).reverse():n}function ak(t,n,e,r){return r==null?Uu:n==null?"":Xu(n)}const Mm={show:!0,scale:"y",stroke:Wu,space:30,gap:5,alignTo:1,size:50,labelGap:0,labelSize:30,labelFont:km,side:3,grid:ah,ticks:Am,border:_m,font:lh,lineGap:Sm,rotate:0};function lk(t,n){let e=3+(t||1)*2;return gn(e*n,3)}function ck(t,n){let{scale:e,idxs:r}=t.series[0],m=t._data[0],f=t.valToPos(m[r[0]],e,!0),g=t.valToPos(m[r[1]],e,!0),w=lr(g-f),u=t.series[n],d=w/(u.points.space*tn);return r[1]-r[0]<=d}const Im={scale:null,auto:!0,sorted:0,min:pn,max:-pn},Lm=(t,n,e,r,m)=>m,Om={show:!0,auto:!0,sorted:0,gaps:Lm,alpha:1,facets:[er({},Im,{scale:"x"}),er({},Im,{scale:"y"})]},Nm={scale:"y",auto:!0,sorted:0,show:!0,spanGaps:!1,gaps:Lm,alpha:1,points:{show:ck,filter:null},values:null,min:pn,max:-pn,idxs:[],path:null,clip:null};function uk(t,n,e,r,m){return e/10}const Dm={time:NA,auto:!0,distr:1,log:10,asinh:1,min:null,max:null,dir:1,ori:0},hk=er({},Dm,{time:!1,ori:1}),Pm={};function Fm(t,n){let e=Pm[t];return e||(e={key:t,plots:[],sub(r){e.plots.push(r)},unsub(r){e.plots=e.plots.filter(m=>m!=r)},pub(r,m,f,g,w,u,d){for(let a=0;a<e.plots.length;a++)e.plots[a]!=m&&e.plots[a].pub(r,m,f,g,w,u,d)}},t!=null&&(Pm[t]=e)),e}const sa=1,hh=2;function ks(t,n,e){const r=t.mode,m=t.series[n],f=r==2?t._data[n]:t._data,g=t.scales,w=t.bbox;let u=f[0],d=r==2?f[1]:f[n],a=r==2?g[m.facets[0].scale]:g[t.series[0].scale],l=r==2?g[m.facets[1].scale]:g[m.scale],c=w.left,h=w.top,o=w.width,s=w.height,p=t.valToPosH,b=t.valToPosV;return a.ori==0?e(m,u,d,a,l,p,b,c,h,o,s,sc,aa,lc,Wm,Hm):e(m,u,d,a,l,b,p,h,c,s,o,ac,la,ph,jm,Um)}function dh(t,n){let e=0,r=0,m=Qt(t.bands,th);for(let f=0;f<m.length;f++){let g=m[f];g.series[0]==n?e=g.dir:g.series[1]==n&&(g.dir==1?r|=1:r|=2)}return[e,r==1?-1:r==2?1:r==3?2:0]}function dk(t,n,e,r,m){let f=t.mode,g=t.series[n],w=f==2?g.facets[1].scale:g.scale,u=t.scales[w];return m==-1?u.min:m==1?u.max:u.distr==3?u.dir==1?u.min:u.max:0}function Ro(t,n,e,r,m,f){return ks(t,n,(g,w,u,d,a,l,c,h,o,s,p)=>{let b=g.pxRound;const x=d.dir*(d.ori==0?1:-1),M=d.ori==0?aa:la;let R,k;x==1?(R=e,k=r):(R=r,k=e);let C=b(l(w[R],d,s,h)),L=b(c(u[R],a,p,o)),D=b(l(w[k],d,s,h)),I=b(c(f==1?a.max:a.min,a,p,o)),T=new Path2D(m);return M(T,D,I),M(T,C,I),M(T,C,L),T})}function oc(t,n,e,r,m,f){let g=null;if(t.length>0){g=new Path2D;const w=n==0?lc:ph;let u=e;for(let l=0;l<t.length;l++){let c=t[l];if(c[1]>c[0]){let h=c[0]-u;h>0&&w(g,u,r,h,r+f),u=c[1]}}let d=e+m-u,a=10;d>0&&w(g,u,r-a/2,d,r+f+a)}return g}function fk(t,n,e){let r=t[t.length-1];r&&r[0]==n?r[1]=e:t.push([n,e])}function fh(t,n,e,r,m,f,g){let w=[],u=t.length;for(let d=m==1?e:r;d>=e&&d<=r;d+=m)if(n[d]===null){let a=d,l=d;if(m==1)for(;++d<=r&&n[d]===null;)l=d;else for(;--d>=e&&n[d]===null;)l=d;let c=f(t[a]),h=l==a?c:f(t[l]),o=a-m;c=g<=0&&o>=0&&o<u?f(t[o]):c;let s=l+m;h=g>=0&&s>=0&&s<u?f(t[s]):h,h>=c&&w.push([c,h])}return w}function zm(t){return t==0?Zg:t==1?cr:n=>As(n,t)}function Bm(t){let n=t==0?sc:ac,e=t==0?(m,f,g,w,u,d)=>{m.arcTo(f,g,w,u,d)}:(m,f,g,w,u,d)=>{m.arcTo(g,f,u,w,d)},r=t==0?(m,f,g,w,u)=>{m.rect(f,g,w,u)}:(m,f,g,w,u)=>{m.rect(g,f,u,w)};return(m,f,g,w,u,d=0,a=0)=>{d==0&&a==0?r(m,f,g,w,u):(d=Ji(d,w/2,u/2),a=Ji(a,w/2,u/2),n(m,f+d,g),e(m,f+w,g,f+w,g+u,d),e(m,f+w,g+u,f,g+u,a),e(m,f,g+u,f,g,a),e(m,f,g,f+w,g,d),m.closePath())}}const sc=(t,n,e)=>{t.moveTo(n,e)},ac=(t,n,e)=>{t.moveTo(e,n)},aa=(t,n,e)=>{t.lineTo(n,e)},la=(t,n,e)=>{t.lineTo(e,n)},lc=Bm(0),ph=Bm(1),Wm=(t,n,e,r,m,f)=>{t.arc(n,e,r,m,f)},jm=(t,n,e,r,m,f)=>{t.arc(e,n,r,m,f)},Hm=(t,n,e,r,m,f,g)=>{t.bezierCurveTo(n,e,r,m,f,g)},Um=(t,n,e,r,m,f,g)=>{t.bezierCurveTo(e,n,m,r,g,f)};function Vm(t){return(n,e,r,m,f)=>ks(n,e,(g,w,u,d,a,l,c,h,o,s,p)=>{let{pxRound:b,points:x}=g,M,R;d.ori==0?(M=sc,R=Wm):(M=ac,R=jm);const k=gn(x.width*tn,3);let C=(x.size-x.width)/2*tn,L=gn(C*2,3),D=new Path2D,I=new Path2D,{left:T,top:W,width:F,height:O}=n.bbox;lc(I,T-L,W-L,F+L*2,O+L*2);const S=A=>{if(u[A]!=null){let N=b(l(w[A],d,s,h)),B=b(c(u[A],a,p,o));M(D,N+C,B),R(D,N,B,C,0,Ql*2)}};if(f)f.forEach(S);else for(let A=r;A<=m;A++)S(A);return{stroke:k>0?D:null,fill:D,clip:I,flags:sa|hh}})}function qm(t){return(n,e,r,m,f,g)=>{r!=m&&(f!=r&&g!=r&&t(n,e,r),f!=m&&g!=m&&t(n,e,m),t(n,e,g))}}const pk=qm(aa),gk=qm(la);function Gm(t){const n=Qt(t?.alignGaps,0);return(e,r,m,f)=>ks(e,r,(g,w,u,d,a,l,c,h,o,s,p)=>{[m,f]=Jl(u,m,f);let b=g.pxRound,x=F=>b(l(F,d,s,h)),M=F=>b(c(F,a,p,o)),R,k;d.ori==0?(R=aa,k=pk):(R=la,k=gk);const C=d.dir*(d.ori==0?1:-1),L={stroke:new Path2D,fill:null,clip:null,band:null,gaps:null,flags:sa},D=L.stroke;let I=!1;if(f-m>=s*4){let F=de=>e.posToVal(de,d.key,!0),O=null,S=null,A,N,B,U=x(w[C==1?m:f]),G=x(w[m]),J=x(w[f]),ne=F(C==1?G+1:J-1);for(let de=C==1?m:f;de>=m&&de<=f;de+=C){let ee=w[de],se=(C==1?ee<ne:ee>ne)?U:x(ee),ce=u[de];se==U?ce!=null?(N=ce,O==null?(R(D,se,M(N)),A=O=S=N):N<O?O=N:N>S&&(S=N)):ce===null&&(I=!0):(O!=null&&k(D,U,M(O),M(S),M(A),M(N)),ce!=null?(N=ce,R(D,se,M(N)),O=S=A=N):(O=S=null,ce===null&&(I=!0)),U=se,ne=F(U+C))}O!=null&&O!=S&&B!=U&&k(D,U,M(O),M(S),M(A),M(N))}else for(let F=C==1?m:f;F>=m&&F<=f;F+=C){let O=u[F];O===null?I=!0:O!=null&&R(D,x(w[F]),M(O))}let[T,W]=dh(e,r);if(g.fill!=null||T!=0){let F=L.fill=new Path2D(D),O=g.fillTo(e,r,g.min,g.max,T),S=M(O),A=x(w[m]),N=x(w[f]);C==-1&&([N,A]=[A,N]),R(F,N,S),R(F,A,S)}if(!g.spanGaps){let F=[];I&&F.push(...fh(w,u,m,f,C,x,n)),L.gaps=F=g.gaps(e,r,m,f,F),L.clip=oc(F,d.ori,h,o,s,p)}return W!=0&&(L.band=W==2?[Ro(e,r,m,f,D,-1),Ro(e,r,m,f,D,1)]:Ro(e,r,m,f,D,W)),L})}function mk(t){const n=Qt(t.align,1),e=Qt(t.ascDesc,!1),r=Qt(t.alignGaps,0),m=Qt(t.extend,!1);return(f,g,w,u)=>ks(f,g,(d,a,l,c,h,o,s,p,b,x,M)=>{[w,u]=Jl(l,w,u);let R=d.pxRound,{left:k,width:C}=f.bbox,L=J=>R(o(J,c,x,p)),D=J=>R(s(J,h,M,b)),I=c.ori==0?aa:la;const T={stroke:new Path2D,fill:null,clip:null,band:null,gaps:null,flags:sa},W=T.stroke,F=c.dir*(c.ori==0?1:-1);let O=D(l[F==1?w:u]),S=L(a[F==1?w:u]),A=S,N=S;m&&n==-1&&(N=k,I(W,N,O)),I(W,S,O);for(let J=F==1?w:u;J>=w&&J<=u;J+=F){let ne=l[J];if(ne==null)continue;let de=L(a[J]),ee=D(ne);n==1?I(W,de,O):I(W,A,ee),I(W,de,ee),O=ee,A=de}let B=A;m&&n==1&&(B=k+C,I(W,B,O));let[U,G]=dh(f,g);if(d.fill!=null||U!=0){let J=T.fill=new Path2D(W),ne=d.fillTo(f,g,d.min,d.max,U),de=D(ne);I(J,B,de),I(J,N,de)}if(!d.spanGaps){let J=[];J.push(...fh(a,l,w,u,F,L,r));let ne=d.width*tn/2,de=e||n==1?ne:-ne,ee=e||n==-1?-ne:ne;J.forEach(se=>{se[0]+=de,se[1]+=ee}),T.gaps=J=d.gaps(f,g,w,u,J),T.clip=oc(J,c.ori,p,b,x,M)}return G!=0&&(T.band=G==2?[Ro(f,g,w,u,W,-1),Ro(f,g,w,u,W,1)]:Ro(f,g,w,u,W,G)),T})}function Km(t,n,e,r,m,f,g=pn){if(t.length>1){let w=null;for(let u=0,d=1/0;u<t.length;u++)if(n[u]!==void 0){if(w!=null){let a=lr(t[u]-t[w]);a<d&&(d=a,g=lr(e(t[u],r,m,f)-e(t[w],r,m,f)))}w=u}}return g}function vk(t){t=t||Za;const n=Qt(t.size,[.6,pn,1]),e=t.align||0,r=t.gap||0;let m=t.radius;m=m==null?[0,0]:typeof m=="number"?[m,0]:m;const f=Vt(m),g=1-n[0],w=Qt(n[1],pn),u=Qt(n[2],1),d=Qt(t.disp,Za),a=Qt(t.each,h=>{}),{fill:l,stroke:c}=d;return(h,o,s,p)=>ks(h,o,(b,x,M,R,k,C,L,D,I,T,W)=>{let F=b.pxRound,O=e,S=r*tn,A=w*tn,N=u*tn,B,U;R.ori==0?[B,U]=f(h,o):[U,B]=f(h,o);const G=R.dir*(R.ori==0?1:-1);let J=R.ori==0?lc:ph,ne=R.ori==0?a:(Je,Ft,An,_n,kn,mn,vn)=>{a(Je,Ft,An,kn,_n,vn,mn)},de=Qt(h.bands,th).find(Je=>Je.series[0]==o),ee=de!=null?de.dir:0,se=b.fillTo(h,o,b.min,b.max,ee),ce=F(L(se,k,W,I)),le,pe,me,$e=T,Ee=F(b.width*tn),He=!1,Ue=null,ot=null,Qe=null,lt=null;l!=null&&(Ee==0||c!=null)&&(He=!0,Ue=l.values(h,o,s,p),ot=new Map,new Set(Ue).forEach(Je=>{Je!=null&&ot.set(Je,new Path2D)}),Ee>0&&(Qe=c.values(h,o,s,p),lt=new Map,new Set(Qe).forEach(Je=>{Je!=null&&lt.set(Je,new Path2D)})));let{x0:Tt,size:ur}=d;if(Tt!=null&&ur!=null){O=1,x=Tt.values(h,o,s,p),Tt.unit==2&&(x=x.map(Ft=>h.posToVal(D+Ft*T,R.key,!0)));let Je=ur.values(h,o,s,p);ur.unit==2?pe=Je[0]*T:pe=C(Je[0],R,T,D)-C(0,R,T,D),$e=Km(x,M,C,R,T,D,$e),me=$e-pe+S}else $e=Km(x,M,C,R,T,D,$e),me=$e*g+S,pe=$e-me;me<1&&(me=0),Ee>=pe/2&&(Ee=0),me<5&&(F=Zg);let At=me>0,vr=$e-me-(At?Ee:0);pe=F(eh(vr,N,A)),le=(O==0?pe/2:O==G?0:pe)-O*G*((O==0?S/2:0)+(At?Ee/2:0));const Dn={stroke:null,fill:null,clip:null,band:null,gaps:null,flags:0},Kn=He?null:new Path2D;let un=null;if(de!=null)un=h.data[de.series[1]];else{let{y0:Je,y1:Ft}=d;Je!=null&&Ft!=null&&(M=Ft.values(h,o,s,p),un=Je.values(h,o,s,p))}let Yn=B*pe,gt=U*pe;for(let Je=G==1?s:p;Je>=s&&Je<=p;Je+=G){let Ft=M[Je];if(Ft==null)continue;if(un!=null){let Jt=un[Je]??0;if(Ft-Jt==0)continue;ce=L(Jt,k,W,I)}let An=R.distr!=2||d!=null?x[Je]:Je,_n=C(An,R,T,D),kn=L(Qt(Ft,se),k,W,I),mn=F(_n-le),vn=F(Ur(kn,ce)),Wn=F(Ji(kn,ce)),Jn=vn-Wn;if(Ft!=null){let Jt=Ft<0?gt:Yn,jn=Ft<0?Yn:gt;He?(Ee>0&&Qe[Je]!=null&&J(lt.get(Qe[Je]),mn,Wn+yi(Ee/2),pe,Ur(0,Jn-Ee),Jt,jn),Ue[Je]!=null&&J(ot.get(Ue[Je]),mn,Wn+yi(Ee/2),pe,Ur(0,Jn-Ee),Jt,jn)):J(Kn,mn,Wn+yi(Ee/2),pe,Ur(0,Jn-Ee),Jt,jn),ne(h,o,Je,mn-Ee/2,Wn,pe+Ee,Jn)}}return Ee>0?Dn.stroke=He?lt:Kn:He||(Dn._fill=b.width==0?b._fill:b._stroke??b._fill,Dn.width=0),Dn.fill=He?ot:Kn,Dn})}function yk(t,n){const e=Qt(n?.alignGaps,0);return(r,m,f,g)=>ks(r,m,(w,u,d,a,l,c,h,o,s,p,b)=>{[f,g]=Jl(d,f,g);let x=w.pxRound,M=B=>x(c(B,a,p,o)),R=B=>x(h(B,l,b,s)),k,C,L;a.ori==0?(k=sc,L=aa,C=Hm):(k=ac,L=la,C=Um);const D=a.dir*(a.ori==0?1:-1);let I=M(u[D==1?f:g]),T=I,W=[],F=[];for(let B=D==1?f:g;B>=f&&B<=g;B+=D)if(d[B]!=null){let U=u[B],G=M(U);W.push(T=G),F.push(R(d[B]))}const O={stroke:t(W,F,k,L,C,x),fill:null,clip:null,band:null,gaps:null,flags:sa},S=O.stroke;let[A,N]=dh(r,m);if(w.fill!=null||A!=0){let B=O.fill=new Path2D(S),U=w.fillTo(r,m,w.min,w.max,A),G=R(U);L(B,T,G),L(B,I,G)}if(!w.spanGaps){let B=[];B.push(...fh(u,d,f,g,D,M,e)),O.gaps=B=w.gaps(r,m,f,g,B),O.clip=oc(B,a.ori,o,s,p,b)}return N!=0&&(O.band=N==2?[Ro(r,m,f,g,S,-1),Ro(r,m,f,g,S,1)]:Ro(r,m,f,g,S,N)),O})}function bk(t){return yk(wk,t)}function wk(t,n,e,r,m,f){const g=t.length;if(g<2)return null;const w=new Path2D;if(e(w,t[0],n[0]),g==2)r(w,t[1],n[1]);else{let u=Array(g),d=Array(g-1),a=Array(g-1),l=Array(g-1);for(let c=0;c<g-1;c++)a[c]=n[c+1]-n[c],l[c]=t[c+1]-t[c],d[c]=a[c]/l[c];u[0]=d[0];for(let c=1;c<g-1;c++)d[c]===0||d[c-1]===0||d[c-1]>0!=d[c]>0?u[c]=0:(u[c]=3*(l[c-1]+l[c])/((2*l[c]+l[c-1])/d[c-1]+(l[c]+2*l[c-1])/d[c]),isFinite(u[c])||(u[c]=0));u[g-1]=d[g-2];for(let c=0;c<g-1;c++)m(w,t[c]+l[c]/3,n[c]+u[c]*l[c]/3,t[c+1]-l[c]/3,n[c+1]-u[c+1]*l[c]/3,t[c+1],n[c+1])}return w}const gh=new Set;function Ym(){for(let t of gh)t.syncRect(!0)}ea&&(xs(e_,ta,Ym),xs(t_,ta,Ym,!0),xs(Kl,ta,()=>{Mr.pxRatio=tn}));const xk=Gm(),Ck=Vm();function Jm(t,n,e,r){return(r?[t[0],t[1]].concat(t.slice(2)):[t[0]].concat(t.slice(1))).map((m,f)=>mh(m,f,n,e))}function Ak(t,n){return t.map((e,r)=>r==0?{}:er({},n,e))}function mh(t,n,e,r){return er({},n==0?e:r,t)}function Zm(t,n,e){return n==null?ra:[n,e]}const _k=Zm;function kk(t,n,e){return n==null?ra:Xl(n,e,Zu,!0)}function Xm(t,n,e,r){return n==null?ra:Zl(n,e,t.scales[r].log,!1)}const Sk=Xm;function Qm(t,n,e,r){return n==null?ra:Ju(n,e,t.scales[r].log,!1)}const $k=Qm;function Rk(t,n,e,r,m){let f=Ur(Yg(t),Yg(n)),g=n-t,w=Yi(m/r*g,e);do{let u=e[w],d=r*u/g;if(d>=m&&f+(u<5?Ko.get(u):0)<=17)return[u,d]}while(++w<e.length);return[0,0]}function ev(t){let n,e;return t=t.replace(/(\d+)px/,(r,m)=>(n=cr((e=+m)*tn))+"px"),[t,n,e]}function Ek(t){t.show&&[t.font,t.labelFont].forEach(n=>{let e=gn(n[2]*tn,1);n[0]=n[0].replace(/[0-9.]+px/,e+"px"),n[1]=e})}function Mr(t,n,e){const r={mode:Qt(t.mode,1)},m=r.mode;function f(V,Z,ie,ae){let ge=Z.valToPct(V);return ae+ie*(Z.dir==-1?1-ge:ge)}function g(V,Z,ie,ae){let ge=Z.valToPct(V);return ae+ie*(Z.dir==-1?ge:1-ge)}function w(V,Z,ie,ae){return Z.ori==0?f(V,Z,ie,ae):g(V,Z,ie,ae)}r.valToPosH=f,r.valToPosV=g;let u=!1;r.status=0;const d=r.root=Mi(DA);if(t.id!=null&&(d.id=t.id),mi(d,t.class),t.title){let V=Mi(zA,d);V.textContent=t.title}const a=Ki("canvas"),l=r.ctx=a.getContext("2d"),c=Mi(BA,d);xs("click",c,V=>{V.target===o&&(ct!=Di||qt!=xo)&&Un.click(r,V)},!0);const h=r.under=Mi(WA,c);c.appendChild(a);const o=r.over=Mi(jA,c);t=ia(t);const s=+Qt(t.pxAlign,1),p=zm(s);(t.plugins||[]).forEach(V=>{V.opts&&(t=V.opts(r,t)||t)});const b=t.ms||.001,x=r.series=m==1?Jm(t.series||[],Rm,Nm,!1):Ak(t.series||[null],Om),M=r.axes=Jm(t.axes||[],$m,Mm,!0),R=r.scales={},k=r.bands=t.bands||[];k.forEach(V=>{V.fill=Vt(V.fill||null),V.dir=Qt(V.dir,-1)});const C=m==2?x[1].facets[0].scale:x[0].scale,L={axes:ts,series:Ts},D=(t.drawOrder||["axes","series"]).map(V=>L[V]);function I(V){const Z=V.distr==3?ie=>$o(ie>0?ie:V.clamp(r,ie,V.min,V.max,V.key)):V.distr==4?ie=>Qu(ie,V.asinh):V.distr==100?ie=>V.fwd(ie):ie=>ie;return ie=>{let ae=Z(ie),{_min:ge,_max:_e}=V,Te=_e-ge;return(ae-ge)/Te}}function T(V){let Z=R[V];if(Z==null){let ie=(t.scales||Za)[V]||Za;if(ie.from!=null){T(ie.from);let ae=er({},R[ie.from],ie,{key:V});ae.valToPct=I(ae),R[V]=ae}else{Z=R[V]=er({},V==C?Dm:hk,ie),Z.key=V;let ae=Z.time,ge=Z.range,_e=Yo(ge);if((V!=C||m==2&&!ae)&&(_e&&(ge[0]==null||ge[1]==null)&&(ge={min:ge[0]==null?Vg:{mode:1,hard:ge[0],soft:ge[0]},max:ge[1]==null?Vg:{mode:1,hard:ge[1],soft:ge[1]}},_e=!1),!_e&&tc(ge))){let Te=ge;ge=(Fe,We,Ve)=>We==null?ra:Xl(We,Ve,Te)}Z.range=Vt(ge||(ae?_k:V==C?Z.distr==3?Sk:Z.distr==4?$k:Zm:Z.distr==3?Xm:Z.distr==4?Qm:kk)),Z.auto=Vt(_e?!1:Z.auto),Z.clamp=Vt(Z.clamp||uk),Z._min=Z._max=null,Z.valToPct=I(Z)}}}T("x"),T("y"),m==1&&x.forEach(V=>{T(V.scale)}),M.forEach(V=>{T(V.scale)});for(let V in t.scales)T(V);const W=R[C],F=W.distr;let O,S;W.ori==0?(mi(d,PA),O=f,S=g):(mi(d,FA),O=g,S=f);const A={};for(let V in R){let Z=R[V];(Z.min!=null||Z.max!=null)&&(A[V]={min:Z.min,max:Z.max},Z.min=Z.max=null)}const N=t.tzDate||(V=>new Date(cr(V/b))),B=t.fmtDate||nh,U=b==1?P_(N):B_(N),G=bm(N,ym(b==1?D_:z_,B)),J=xm(N,wm(j_,B)),ne=[],de=r.legend=er({},V_,t.legend),ee=r.cursor=er({},Z_,{drag:{y:m==2}},t.cursor),se=de.show,ce=ee.show,le=de.markers;de.idxs=ne,le.width=Vt(le.width),le.dash=Vt(le.dash),le.stroke=Vt(le.stroke),le.fill=Vt(le.fill);let pe,me,$e,Ee=[],He=[],Ue,ot=!1,Qe={};if(de.live){const V=x[1]?x[1].values:null;ot=V!=null,Ue=ot?V(r,1,0):{_:0};for(let Z in Ue)Qe[Z]=Uu}if(se)if(pe=Ki("table",KA,d),$e=Ki("tbody",null,pe),de.mount(r,pe),ot){me=Ki("thead",null,pe,$e);let V=Ki("tr",null,me);Ki("th",null,V);for(var lt in Ue)Ki("th",Eg,V).textContent=lt}else mi(pe,JA),de.live&&mi(pe,YA);const Tt={show:!0},ur={show:!1};function At(V,Z){if(Z==0&&(ot||!de.live||m==2))return ra;let ie=[],ae=Ki("tr",ZA,$e,$e.childNodes[Z]);mi(ae,V.class),V.show||mi(ae,ws);let ge=Ki("th",null,ae);if(le.show){let Fe=Mi(XA,ge);if(Z>0){let We=le.width(r,Z);We&&(Fe.style.border=We+"px "+le.dash(r,Z)+" "+le.stroke(r,Z)),Fe.style.background=le.fill(r,Z)}}let _e=Mi(Eg,ge);V.label instanceof HTMLElement?_e.appendChild(V.label):_e.textContent=V.label,Z>0&&(le.show||(_e.style.color=V.width>0?le.stroke(r,Z):le.fill(r,Z)),Dn("click",ge,Fe=>{if(ee._lock)return;Zt(Fe);let We=x.indexOf(V);if((Fe.ctrlKey||Fe.metaKey)!=de.isolate){let Ve=x.some((Ke,Xe)=>Xe>0&&Xe!=We&&Ke.show);x.forEach((Ke,Xe)=>{Xe>0&&ir(Xe,Ve?Xe==We?Tt:ur:Tt,!0,Ct.setSeries)})}else ir(We,{show:!V.show},!0,Ct.setSeries)},!1),Dr&&Dn(Lg,ge,Fe=>{ee._lock||(Zt(Fe),ir(x.indexOf(V),zi,!0,Ct.setSeries))},!1));for(var Te in Ue){let Fe=Ki("td",QA,ae);Fe.textContent="--",ie.push(Fe)}return[ae,ie]}const vr=new Map;function Dn(V,Z,ie,ae=!0){const ge=vr.get(Z)||{},_e=ee.bind[V](r,Z,ie,ae);_e&&(xs(V,Z,ge[V]=_e),vr.set(Z,ge))}function Kn(V,Z,ie){const ae=vr.get(Z)||{};for(let ge in ae)(V==null||ge==V)&&(Yu(ge,Z,ae[ge]),delete ae[ge]);V==null&&vr.delete(Z)}let un=0,Yn=0,gt=0,Je=0,Ft=0,An=0,_n=Ft,kn=An,mn=gt,vn=Je,Wn=0,Jn=0,Jt=0,jn=0;r.bbox={};let oi=!1,Or=!1,Rn=!1,yr=!1,bi=!1,rr=!1;function Xi(V,Z,ie){(ie||V!=r.width||Z!=r.height)&&wi(V,Z),no(!1),Rn=!0,Or=!0,wo()}function wi(V,Z){r.width=un=gt=V,r.height=Yn=Je=Z,Ft=An=0,Jo(),To();let ie=r.bbox;Wn=ie.left=As(Ft*tn,.5),Jn=ie.top=As(An*tn,.5),Jt=ie.width=As(gt*tn,.5),jn=ie.height=As(Je*tn,.5)}const Eo=3;function Yr(){let V=!1,Z=0;for(;!V;){Z++;let ie=ba(Z),ae=wa(Z);V=Z==Eo||ie&&ae,V||(wi(r.width,r.height),Or=!0)}}function Qi({width:V,height:Z}){Xi(V,Z)}r.setSize=Qi;function Jo(){let V=!1,Z=!1,ie=!1,ae=!1;M.forEach((ge,_e)=>{if(ge.show&&ge._show){let{side:Te,_size:Fe}=ge,We=Te%2,Ve=ge.label!=null?ge.labelSize:0,Ke=Fe+Ve;Ke>0&&(We?(gt-=Ke,Te==3?(Ft+=Ke,ae=!0):ie=!0):(Je-=Ke,Te==0?(An+=Ke,V=!0):Z=!0))}}),ai[0]=V,ai[1]=ie,ai[2]=Z,ai[3]=ae,gt-=bn[1]+bn[3],Ft+=bn[3],Je-=bn[2]+bn[0],An+=bn[0]}function To(){let V=Ft+gt,Z=An+Je,ie=Ft,ae=An;function ge(_e,Te){switch(_e){case 1:return V+=Te,V-Te;case 2:return Z+=Te,Z-Te;case 3:return ie-=Te,ie+Te;case 0:return ae-=Te,ae+Te}}M.forEach((_e,Te)=>{if(_e.show&&_e._show){let Fe=_e.side;_e._pos=ge(Fe,_e._size),_e.label!=null&&(_e._lpos=ge(Fe,_e.labelSize))}})}if(ee.dataIdx==null){let V=ee.hover,Z=V.skip=new Set(V.skip??[]);Z.add(void 0);let ie=V.prox=Vt(V.prox),ae=V.bias??=0;ee.dataIdx=(ge,_e,Te,Fe)=>{if(_e==0)return Te;let We=Te,Ve=ie(ge,_e,Te,Fe)??pn,Ke=Ve>=0&&Ve<pn,Xe=W.ori==0?gt:Je,xt=ee.left,Xt=n[0],Bt=n[_e];if(Z.has(Bt[Te])){We=null;let bt=null,ft=null,at;if(ae==0||ae==-1)for(at=Te;bt==null&&at-- >0;)Z.has(Bt[at])||(bt=at);if(ae==0||ae==1)for(at=Te;ft==null&&at++<Bt.length;)Z.has(Bt[at])||(ft=at);if(bt!=null||ft!=null)if(Ke){let yn=bt==null?-1/0:O(Xt[bt],W,Xe,0),Ln=ft==null?1/0:O(Xt[ft],W,Xe,0),sr=xt-yn,sn=Ln-xt;sr<=sn?sr<=Ve&&(We=bt):sn<=Ve&&(We=ft)}else We=ft==null?bt:bt==null?ft:Te-bt<=ft-Te?bt:ft}else Ke&&lr(xt-O(Xt[Te],W,Xe,0))>Ve&&(We=null);return We}}const Zt=V=>{ee.event=V};ee.idxs=ne,ee._lock=!1;let fn=ee.points;fn.show=Vt(fn.show),fn.size=Vt(fn.size),fn.stroke=Vt(fn.stroke),fn.width=Vt(fn.width),fn.fill=Vt(fn.fill);const Nr=r.focus=er({},t.focus||{alpha:.3},ee.focus),Dr=Nr.prox>=0,Sn=Dr&&fn.one;let Zn=[],xi=[],Ci=[];function Jr(V,Z){let ie=fn.show(r,Z);if(ie instanceof HTMLElement)return mi(ie,GA),mi(ie,V.class),ho(ie,-10,-10,gt,Je),o.insertBefore(ie,Zn[Z]),ie}function si(V,Z){if(m==1||Z>0){let ie=m==1&&R[V.scale].time,ae=V.value;V.value=ie?im(ae)?xm(N,wm(ae,B)):ae||J:ae||ak,V.label=V.label||(ie?Q_:X_)}if(Sn||Z>0){V.width=V.width==null?1:V.width,V.paths=V.paths||xk||h_,V.fillTo=Vt(V.fillTo||dk),V.pxAlign=+Qt(V.pxAlign,s),V.pxRound=zm(V.pxAlign),V.stroke=Vt(V.stroke||null),V.fill=Vt(V.fill||null),V._stroke=V._fill=V._paths=V._focus=null;let ie=lk(Ur(1,V.width),1),ae=V.points=er({},{size:ie,width:Ur(1,ie*.2),stroke:V.stroke,space:ie*2,paths:Ck,_stroke:null,_fill:null},V.points);ae.show=Vt(ae.show),ae.filter=Vt(ae.filter),ae.fill=Vt(ae.fill),ae.stroke=Vt(ae.stroke),ae.paths=Vt(ae.paths),ae.pxAlign=V.pxAlign}if(se){let ie=At(V,Z);Ee.splice(Z,0,ie[0]),He.splice(Z,0,ie[1]),de.values.push(null)}if(ce){ne.splice(Z,0,null);let ie=null;Sn?Z==0&&(ie=Jr(V,Z)):Z>0&&(ie=Jr(V,Z)),Zn.splice(Z,0,ie),xi.splice(Z,0,0),Ci.splice(Z,0,0)}et("addSeries",Z)}function Zo(V,Z){Z=Z??x.length,V=m==1?mh(V,Z,Rm,Nm):mh(V,Z,{},Om),x.splice(Z,0,V),si(x[Z],Z)}r.addSeries=Zo;function Mo(V){if(x.splice(V,1),se){de.values.splice(V,1),He.splice(V,1);let Z=Ee.splice(V,1)[0];Kn(null,Z.firstChild),Z.remove()}ce&&(ne.splice(V,1),Zn.splice(V,1)[0].remove(),xi.splice(V,1),Ci.splice(V,1)),et("delSeries",V)}r.delSeries=Mo;const ai=[!1,!1,!1,!1];function _r(V,Z){if(V._show=V.show,V.show){let ie=V.side%2,ae=R[V.scale];ae==null&&(V.scale=ie?x[1].scale:C,ae=R[V.scale]);let ge=ae.time;V.size=Vt(V.size),V.space=Vt(V.space),V.rotate=Vt(V.rotate),Yo(V.incrs)&&V.incrs.forEach(Te=>{!Ko.has(Te)&&Ko.set(Te,nm(Te))}),V.incrs=Vt(V.incrs||(ae.distr==2?L_:ge?b==1?N_:F_:_s)),V.splits=Vt(V.splits||(ge&&ae.distr==1?U:ae.distr==3?ch:ae.distr==4?nk:tk)),V.stroke=Vt(V.stroke),V.grid.stroke=Vt(V.grid.stroke),V.ticks.stroke=Vt(V.ticks.stroke),V.border.stroke=Vt(V.border.stroke);let _e=V.values;V.values=Yo(_e)&&!Yo(_e[0])?Vt(_e):ge?Yo(_e)?bm(N,ym(_e,B)):im(_e)?W_(N,_e):_e||G:_e||ek,V.filter=Vt(V.filter||(ae.distr>=3&&ae.log==10?ok:ae.distr==3&&ae.log==2?sk:Xg)),V.font=ev(V.font),V.labelFont=ev(V.labelFont),V._size=V.size(r,null,Z,0),V._space=V._rotate=V._incrs=V._found=V._splits=V._values=null,V._size>0&&(ai[Z]=!0,V._el=Mi(HA,c))}}function $t(V,Z,ie,ae){let[ge,_e,Te,Fe]=ie,We=Z%2,Ve=0;return We==0&&(Fe||_e)&&(Ve=Z==0&&!ge||Z==2&&!Te?cr($m.size/3):0),We==1&&(ge||Te)&&(Ve=Z==1&&!_e||Z==3&&!Fe?cr(Mm.size/2):0),Ve}const eo=r.padding=(t.padding||[$t,$t,$t,$t]).map(V=>Vt(Qt(V,$t))),bn=r._padding=eo.map((V,Z)=>V(r,Z,ai,0));let En,hn=null,Tn=null;const Ni=m==1?x[0].idxs:null;let Hn=null,li=!1;function br(V,Z){if(n=V??[],r.data=r._data=n,m==2){En=0;for(let ie=1;ie<x.length;ie++)En+=n[ie][0].length}else{n.length==0&&(r.data=r._data=n=[[]]),Hn=n[0],En=Hn.length;let ie=n;if(F==2){ie=n.slice();let ae=ie[0]=Array(En);for(let ge=0;ge<En;ge++)ae[ge]=ge}r._data=n=ie}if(no(!0),et("setData"),F==2&&(Rn=!0),Z!==!1){let ie=W;ie.auto(r,li)?oe():Fr(C,ie.min,ie.max),yr=yr||ee.left>=0,rr=!0,wo()}}r.setData=br;function oe(){li=!0;let V,Z;m==1&&(En>0?(hn=Ni[0]=0,Tn=Ni[1]=En-1,V=n[0][hn],Z=n[0][Tn],F==2?(V=hn,Z=Tn):V==Z&&(F==3?[V,Z]=Zl(V,V,W.log,!1):F==4?[V,Z]=Ju(V,V,W.log,!1):W.time?Z=V+cr(86400/b):[V,Z]=Xl(V,Z,Zu,!0))):(hn=Ni[0]=V=null,Tn=Ni[1]=Z=null)),Fr(C,V,Z)}let Ne,ze,mt,Ot,Mt,wr,xr,hr,ci,Ht;function go(V,Z,ie,ae,ge,_e){V??=Mg,ie??=th,ae??="butt",ge??=Mg,_e??="round",V!=Ne&&(l.strokeStyle=Ne=V),ge!=ze&&(l.fillStyle=ze=ge),Z!=mt&&(l.lineWidth=mt=Z),_e!=Mt&&(l.lineJoin=Mt=_e),ae!=wr&&(l.lineCap=wr=ae),ie!=Ot&&l.setLineDash(Ot=ie)}function mo(V,Z,ie,ae){Z!=ze&&(l.fillStyle=ze=Z),V!=xr&&(l.font=xr=V),ie!=hr&&(l.textAlign=hr=ie),ae!=ci&&(l.textBaseline=ci=ae)}function vo(V,Z,ie,ae,ge=0){if(ae.length>0&&V.auto(r,li)&&(Z==null||Z.min==null)){let _e=Qt(hn,0),Te=Qt(Tn,ae.length-1),Fe=ie.min==null?o_(ae,_e,Te,ge,V.distr==3):[ie.min,ie.max];V.min=Ji(V.min,ie.min=Fe[0]),V.max=Ur(V.max,ie.max=Fe[1])}}const Es={min:null,max:null};function Xo(){for(let ae in R){let ge=R[ae];A[ae]==null&&(ge.min==null||A[C]!=null&&ge.auto(r,li))&&(A[ae]=Es)}for(let ae in R){let ge=R[ae];A[ae]==null&&ge.from!=null&&A[ge.from]!=null&&(A[ae]=Es)}A[C]!=null&&no(!0);let V={};for(let ae in A){let ge=A[ae];if(ge!=null){let _e=V[ae]=ia(R[ae],p_);if(ge.min!=null)er(_e,ge);else if(ae!=C||m==2)if(En==0&&_e.from==null){let Te=_e.range(r,null,null,ae);_e.min=Te[0],_e.max=Te[1]}else _e.min=pn,_e.max=-pn}}if(En>0){x.forEach((ae,ge)=>{if(m==1){let _e=ae.scale,Te=A[_e];if(Te==null)return;let Fe=V[_e];if(ge==0){let We=Fe.range(r,Fe.min,Fe.max,_e);Fe.min=We[0],Fe.max=We[1],hn=Yi(Fe.min,n[0]),Tn=Yi(Fe.max,n[0]),Tn-hn>1&&(n[0][hn]<Fe.min&&hn++,n[0][Tn]>Fe.max&&Tn--),ae.min=Hn[hn],ae.max=Hn[Tn]}else ae.show&&ae.auto&&vo(Fe,Te,ae,n[ge],ae.sorted);ae.idxs[0]=hn,ae.idxs[1]=Tn}else if(ge>0&&ae.show&&ae.auto){let[_e,Te]=ae.facets,Fe=_e.scale,We=Te.scale,[Ve,Ke]=n[ge],Xe=V[Fe],xt=V[We];Xe!=null&&vo(Xe,A[Fe],_e,Ve,_e.sorted),xt!=null&&vo(xt,A[We],Te,Ke,Te.sorted),ae.min=Te.min,ae.max=Te.max}});for(let ae in V){let ge=V[ae],_e=A[ae];if(ge.from==null&&(_e==null||_e.min==null)){let Te=ge.range(r,ge.min==pn?null:ge.min,ge.max==-pn?null:ge.max,ae);ge.min=Te[0],ge.max=Te[1]}}}for(let ae in V){let ge=V[ae];if(ge.from!=null){let _e=V[ge.from];if(_e.min==null)ge.min=ge.max=null;else{let Te=ge.range(r,_e.min,_e.max,ae);ge.min=Te[0],ge.max=Te[1]}}}let Z={},ie=!1;for(let ae in V){let ge=V[ae],_e=R[ae];if(_e.min!=ge.min||_e.max!=ge.max){_e.min=ge.min,_e.max=ge.max;let Te=_e.distr;_e._min=Te==3?$o(_e.min):Te==4?Qu(_e.min,_e.asinh):Te==100?_e.fwd(_e.min):_e.min,_e._max=Te==3?$o(_e.max):Te==4?Qu(_e.max,_e.asinh):Te==100?_e.fwd(_e.max):_e.max,Z[ae]=ie=!0}}if(ie){x.forEach((ae,ge)=>{m==2?ge>0&&Z.y&&(ae._paths=null):Z[ae.scale]&&(ae._paths=null)});for(let ae in Z)Rn=!0,et("setScale",ae);ce&&ee.left>=0&&(yr=rr=!0)}for(let ae in A)A[ae]=null}function Io(V){let Z=eh(hn-1,0,En-1),ie=eh(Tn+1,0,En-1);for(;V[Z]==null&&Z>0;)Z--;for(;V[ie]==null&&ie<En-1;)ie++;return[Z,ie]}function Ts(){if(En>0){let V=x.some(Z=>Z._focus)&&Ht!=Nr.alpha;V&&(l.globalAlpha=Ht=Nr.alpha),x.forEach((Z,ie)=>{if(ie>0&&Z.show&&(Ms(ie,!1),Ms(ie,!0),Z._paths==null)){let ae=Ht;Ht!=Z.alpha&&(l.globalAlpha=Ht=Z.alpha);let ge=m==2?[0,n[ie][0].length-1]:Io(n[ie]);Z._paths=Z.paths(r,ie,ge[0],ge[1]),Ht!=ae&&(l.globalAlpha=Ht=ae)}}),x.forEach((Z,ie)=>{if(ie>0&&Z.show){let ae=Ht;Ht!=Z.alpha&&(l.globalAlpha=Ht=Z.alpha),Z._paths!=null&&Qo(ie,!1);{let ge=Z._paths!=null?Z._paths.gaps:null,_e=Z.points.show(r,ie,hn,Tn,ge),Te=Z.points.filter(r,ie,_e,ge);(_e||Te)&&(Z.points._paths=Z.points.paths(r,ie,hn,Tn,Te),Qo(ie,!0))}Ht!=ae&&(l.globalAlpha=Ht=ae),et("drawSeries",ie)}}),V&&(l.globalAlpha=Ht=1)}}function Ms(V,Z){let ie=Z?x[V].points:x[V];ie._stroke=ie.stroke(r,V),ie._fill=ie.fill(r,V)}function Qo(V,Z){let ie=Z?x[V].points:x[V],{stroke:ae,fill:ge,clip:_e,flags:Te,_stroke:Fe=ie._stroke,_fill:We=ie._fill,_width:Ve=ie.width}=ie._paths;Ve=gn(Ve*tn,3);let Ke=null,Xe=Ve%2/2;Z&&We==null&&(We=Ve>0?"#fff":Fe);let xt=ie.pxAlign==1&&Xe>0;if(xt&&l.translate(Xe,Xe),!Z){let Xt=Wn-Ve/2,Bt=Jn-Ve/2,bt=Jt+Ve,ft=jn+Ve;Ke=new Path2D,Ke.rect(Xt,Bt,bt,ft)}Z?es(Fe,Ve,ie.dash,ie.cap,We,ae,ge,Te,_e):ya(V,Fe,Ve,ie.dash,ie.cap,We,ae,ge,Te,Ke,_e),xt&&l.translate(-Xe,-Xe)}function ya(V,Z,ie,ae,ge,_e,Te,Fe,We,Ve,Ke){let Xe=!1;We!=0&&k.forEach((xt,Xt)=>{if(xt.series[0]==V){let Bt=x[xt.series[1]],bt=n[xt.series[1]],ft=(Bt._paths||Za).band;Yo(ft)&&(ft=xt.dir==1?ft[0]:ft[1]);let at,yn=null;Bt.show&&ft&&a_(bt,hn,Tn)?(yn=xt.fill(r,Xt)||_e,at=Bt._paths.clip):ft=null,es(Z,ie,ae,ge,yn,Te,Fe,We,Ve,Ke,at,ft),Xe=!0}}),Xe||es(Z,ie,ae,ge,_e,Te,Fe,We,Ve,Ke)}const yo=sa|hh;function es(V,Z,ie,ae,ge,_e,Te,Fe,We,Ve,Ke,Xe){go(V,Z,ie,ae,ge),(We||Ve||Xe)&&(l.save(),We&&l.clip(We),Ve&&l.clip(Ve)),Xe?(Fe&yo)==yo?(l.clip(Xe),Ke&&l.clip(Ke),dr(ge,Te),to(V,_e,Z)):Fe&hh?(dr(ge,Te),l.clip(Xe),to(V,_e,Z)):Fe&sa&&(l.save(),l.clip(Xe),Ke&&l.clip(Ke),dr(ge,Te),l.restore(),to(V,_e,Z)):(dr(ge,Te),to(V,_e,Z)),(We||Ve||Xe)&&l.restore()}function to(V,Z,ie){ie>0&&(Z instanceof Map?Z.forEach((ae,ge)=>{l.strokeStyle=Ne=ge,l.stroke(ae)}):Z!=null&&V&&l.stroke(Z))}function dr(V,Z){Z instanceof Map?Z.forEach((ie,ae)=>{l.fillStyle=ze=ae,l.fill(ie)}):Z!=null&&V&&l.fill(Z)}function Is(V,Z,ie,ae){let ge=M[V],_e;if(ae<=0)_e=[0,0];else{let Te=ge._space=ge.space(r,V,Z,ie,ae),Fe=ge._incrs=ge.incrs(r,V,Z,ie,ae,Te);_e=Rk(Z,ie,Fe,ae,Te)}return ge._found=_e}function Zr(V,Z,ie,ae,ge,_e,Te,Fe,We,Ve){let Ke=Te%2/2;s==1&&l.translate(Ke,Ke),go(Fe,Te,We,Ve,Fe),l.beginPath();let Xe,xt,Xt,Bt,bt=ge+(ae==0||ae==3?-_e:_e);ie==0?(xt=ge,Bt=bt):(Xe=ge,Xt=bt);for(let ft=0;ft<V.length;ft++)Z[ft]!=null&&(ie==0?Xe=Xt=V[ft]:xt=Bt=V[ft],l.moveTo(Xe,xt),l.lineTo(Xt,Bt));l.stroke(),s==1&&l.translate(-Ke,-Ke)}function ba(V){let Z=!0;return M.forEach((ie,ae)=>{if(!ie.show)return;let ge=R[ie.scale];if(ge.min==null){ie._show&&(Z=!1,ie._show=!1,no(!1));return}else ie._show||(Z=!1,ie._show=!0,no(!1));let _e=ie.side,Te=_e%2,{min:Fe,max:We}=ge,[Ve,Ke]=Is(ae,Fe,We,Te==0?gt:Je);if(Ke==0)return;let Xe=ge.distr==2,xt=ie._splits=ie.splits(r,ae,Fe,We,Ve,Ke,Xe),Xt=ge.distr==2?xt.map(at=>Hn[at]):xt,Bt=ge.distr==2?Hn[xt[1]]-Hn[xt[0]]:Ve,bt=ie._values=ie.values(r,ie.filter(r,Xt,ae,Ke,Bt),ae,Ke,Bt);ie._rotate=_e==2?ie.rotate(r,bt,ae,Ke):0;let ft=ie._size;ie._size=Ii(ie.size(r,bt,ae,V)),ft!=null&&ie._size!=ft&&(Z=!1)}),Z}function wa(V){let Z=!0;return eo.forEach((ie,ae)=>{let ge=ie(r,ae,ai,V);ge!=bn[ae]&&(Z=!1),bn[ae]=ge}),Z}function ts(){for(let V=0;V<M.length;V++){let Z=M[V];if(!Z.show||!Z._show)continue;let ie=Z.side,ae=ie%2,ge,_e,Te=Z.stroke(r,V),Fe=ie==0||ie==3?-1:1,[We,Ve]=Z._found;if(Z.label!=null){let Sr=Z.labelGap*Fe,xn=cr((Z._lpos+Sr)*tn);mo(Z.labelFont[0],Te,"center",ie==2?Ka:Tg),l.save(),ae==1?(ge=_e=0,l.translate(xn,cr(Jn+jn/2)),l.rotate((ie==3?-Ql:Ql)/2)):(ge=cr(Wn+Jt/2),_e=xn);let Bi=Jg(Z.label)?Z.label(r,V,We,Ve):Z.label;l.fillText(Bi,ge,_e),l.restore()}if(Ve==0)continue;let Ke=R[Z.scale],Xe=ae==0?Jt:jn,xt=ae==0?Wn:Jn,Xt=Z._splits,Bt=Ke.distr==2?Xt.map(Sr=>Hn[Sr]):Xt,bt=Ke.distr==2?Hn[Xt[1]]-Hn[Xt[0]]:We,ft=Z.ticks,at=Z.border,yn=ft.show?ft.size:0,Ln=cr(yn*tn),sr=cr((Z.alignTo==2?Z._size-yn-Z.gap:Z.gap)*tn),sn=Z._rotate*-Ql/180,dn=p(Z._pos*tn),ve=(Ln+sr)*Fe,Re=dn+ve;_e=ae==0?Re:0,ge=ae==1?Re:0;let Se=Z.font[0],qe=Z.align==1?Qs:Z.align==2?Bu:sn>0?Qs:sn<0?Bu:ae==0?"center":ie==3?Bu:Qs,ht=sn||ae==1?"middle":ie==2?Ka:Tg;mo(Se,Te,qe,ht);let kt=Z.font[1]*Z.lineGap,en=Xt.map(Sr=>p(w(Sr,Ke,Xe,xt))),Wt=Z._values;for(let Sr=0;Sr<Wt.length;Sr++){let xn=Wt[Sr];if(xn!=null){ae==0?ge=en[Sr]:_e=en[Sr],xn=""+xn;let Bi=xn.indexOf(`
1480
+ `)==-1?[xn]:xn.split(/\n/gm);for(let $r=0;$r<Bi.length;$r++){let Do=Bi[$r];sn?(l.save(),l.translate(ge,_e+$r*kt),l.rotate(sn),l.fillText(Do,0,0),l.restore()):l.fillText(Do,ge,_e+$r*kt)}}}ft.show&&Zr(en,ft.filter(r,Bt,V,Ve,bt),ae,ie,dn,Ln,gn(ft.width*tn,3),ft.stroke(r,V),ft.dash,ft.cap);let hi=Z.grid;hi.show&&Zr(en,hi.filter(r,Bt,V,Ve,bt),ae,ae==0?2:1,ae==0?Jn:Wn,ae==0?jn:Jt,gn(hi.width*tn,3),hi.stroke(r,V),hi.dash,hi.cap),at.show&&Zr([dn],[1],ae==0?1:0,ae==0?1:2,ae==1?Jn:Wn,ae==1?jn:Jt,gn(at.width*tn,3),at.stroke(r,V),at.dash,at.cap)}et("drawAxes")}function no(V){x.forEach((Z,ie)=>{ie>0&&(Z._paths=null,V&&(m==1?(Z.min=null,Z.max=null):Z.facets.forEach(ae=>{ae.min=null,ae.max=null})))})}let Lo=!1,ns=!1,bo=[];function xa(){ns=!1;for(let V=0;V<bo.length;V++)et(...bo[V]);bo.length=0}function wo(){Lo||(x_(Ls),Lo=!0)}function Be(V,Z=!1){Lo=!0,ns=Z,V(r),Ls(),Z&&bo.length>0&&queueMicrotask(xa)}r.batch=Be;function Ls(){if(oi&&(Xo(),oi=!1),Rn&&(Yr(),Rn=!1),Or){if(Cn(h,Qs,Ft),Cn(h,Ka,An),Cn(h,qa,gt),Cn(h,Ga,Je),Cn(o,Qs,Ft),Cn(o,Ka,An),Cn(o,qa,gt),Cn(o,Ga,Je),Cn(c,qa,un),Cn(c,Ga,Yn),a.width=cr(un*tn),a.height=cr(Yn*tn),M.forEach(({_el:V,_show:Z,_size:ie,_pos:ae,side:ge})=>{if(V!=null)if(Z){let _e=ge===3||ge===0?ie:0,Te=ge%2==1;Cn(V,Te?"left":"top",ae-_e),Cn(V,Te?"width":"height",ie),Cn(V,Te?"top":"left",Te?An:Ft),Cn(V,Te?"height":"width",Te?Je:gt),Gu(V,ws)}else mi(V,ws)}),Ne=ze=mt=Mt=wr=xr=hr=ci=Ot=null,Ht=1,z(!0),Ft!=_n||An!=kn||gt!=mn||Je!=vn){no(!1);let V=gt/mn,Z=Je/vn;if(ce&&!yr&&ee.left>=0){ee.left*=V,ee.top*=Z,ro&&ho(ro,cr(ee.left),0,gt,Je),Fn&&ho(Fn,0,cr(ee.top),gt,Je);for(let ie=0;ie<Zn.length;ie++){let ae=Zn[ie];ae!=null&&(xi[ie]*=V,Ci[ie]*=Z,ho(ae,Ii(xi[ie]),Ii(Ci[ie]),gt,Je))}}if(wt.show&&!bi&&wt.left>=0&&wt.width>0){wt.left*=V,wt.width*=V,wt.top*=Z,wt.height*=Z;for(let ie in Y)Cn(Pr,ie,wt[ie])}_n=Ft,kn=An,mn=gt,vn=Je}et("setSize"),Or=!1}un>0&&Yn>0&&(l.clearRect(0,0,a.width,a.height),et("drawClear"),D.forEach(V=>V()),et("draw")),wt.show&&bi&&(Fi(wt),bi=!1),ce&&yr&&(_(null,!0,!1),yr=!1),de.show&&de.live&&rr&&(y(),rr=!1),u||(u=!0,r.status=1,et("ready")),li=!1,Lo=!1}r.redraw=(V,Z)=>{Rn=Z||!1,V!==!1?Fr(C,W.min,W.max):wo()};function De(V,Z){let ie=R[V];if(ie.from==null){if(En==0){let ae=ie.range(r,Z.min,Z.max,V);Z.min=ae[0],Z.max=ae[1]}if(Z.min>Z.max){let ae=Z.min;Z.min=Z.max,Z.max=ae}if(En>1&&Z.min!=null&&Z.max!=null&&Z.max-Z.min<1e-16)return;V==C&&ie.distr==2&&En>0&&(Z.min=Yi(Z.min,n[0]),Z.max=Yi(Z.max,n[0]),Z.min==Z.max&&Z.max++),A[V]=Z,oi=!0,wo()}}r.setScale=De;let Pn,Oo,ro,Fn,Ca,No,Di,xo,Os,nn,ct,qt,Pi=!1;const Un=ee.drag;let je=Un.x,wn=Un.y;ce&&(ee.x&&(Pn=Mi(VA,o)),ee.y&&(Oo=Mi(qA,o)),W.ori==0?(ro=Pn,Fn=Oo):(ro=Oo,Fn=Pn),ct=ee.left,qt=ee.top);const wt=r.select=er({show:!0,over:!0,left:0,width:0,top:0,height:0},t.select),Pr=wt.show?Mi(UA,wt.over?o:h):null;function Fi(V,Z){if(wt.show){for(let ie in V)wt[ie]=V[ie],ie in Y&&Cn(Pr,ie,V[ie]);Z!==!1&&et("setSelect")}}r.setSelect=Fi;function zt(V){if(x[V].show)se&&Gu(Ee[V],ws);else if(se&&mi(Ee[V],ws),ce){let Z=Sn?Zn[0]:Zn[V];Z!=null&&ho(Z,-10,-10,gt,Je)}}function Fr(V,Z,ie){De(V,{min:Z,max:ie})}function ir(V,Z,ie,ae){Z.focus!=null&&Ns(V),Z.show!=null&&x.forEach((ge,_e)=>{_e>0&&(V==_e||V==null)&&(ge.show=Z.show,zt(_e),m==2?(Fr(ge.facets[0].scale,null,null),Fr(ge.facets[1].scale,null,null)):Fr(ge.scale,null,null),wo())}),ie!==!1&&et("setSeries",V,Z),ae&&_t("setSeries",r,V,Z)}r.setSeries=ir;function io(V,Z){er(k[V],Z)}function Ai(V,Z){V.fill=Vt(V.fill||null),V.dir=Qt(V.dir,-1),Z=Z??k.length,k.splice(Z,0,V)}function Mn(V){V==null?k.length=0:k.splice(V,1)}r.addBand=Ai,r.setBand=io,r.delBand=Mn;function rs(V,Z){x[V].alpha=Z,ce&&Zn[V]!=null&&(Zn[V].style.opacity=Z),se&&Ee[V]&&(Ee[V].style.opacity=Z)}let Vn,_i,ki;const zi={focus:!0};function Ns(V){if(V!=ki){let Z=V==null,ie=Nr.alpha!=1;x.forEach((ae,ge)=>{if(m==1||ge>0){let _e=Z||ge==0||ge==V;ae._focus=Z?null:_e,ie&&rs(ge,_e?1:Nr.alpha)}}),ki=V,ie&&wo()}}se&&Dr&&Dn(Og,pe,V=>{ee._lock||(Zt(V),ki!=null&&ir(null,zi,!0,Ct.setSeries))});function on(V,Z,ie){let ae=R[Z];ie&&(V=V/tn-(ae.ori==1?An:Ft));let ge=gt;ae.ori==1&&(ge=Je,V=ge-V),ae.dir==-1&&(V=ge-V);let _e=ae._min,Te=ae._max,Fe=V/ge,We=_e+(Te-_e)*Fe,Ve=ae.distr;return Ve==3?na(10,We):Ve==4?c_(We,ae.asinh):Ve==100?ae.bwd(We):We}function Aa(V,Z){let ie=on(V,C,Z);return Yi(ie,n[0],hn,Tn)}r.valToIdx=V=>Yi(V,n[0]),r.posToIdx=Aa,r.posToVal=on,r.valToPos=(V,Z,ie)=>R[Z].ori==0?f(V,R[Z],ie?Jt:gt,ie?Wn:0):g(V,R[Z],ie?jn:Je,ie?Jn:0),r.setCursor=(V,Z,ie)=>{ct=V.left,qt=V.top,_(null,Z,ie)};function fr(V,Z){Cn(Pr,Qs,wt.left=V),Cn(Pr,qa,wt.width=Z)}function zr(V,Z){Cn(Pr,Ka,wt.top=V),Cn(Pr,Ga,wt.height=Z)}let Co=W.ori==0?fr:zr,kr=W.ori==1?fr:zr;function ui(){if(se&&de.live)for(let V=m==2?1:0;V<x.length;V++){if(V==0&&ot)continue;let Z=de.values[V],ie=0;for(let ae in Z)He[V][ie++].firstChild.nodeValue=Z[ae]}}function y(V,Z){if(V!=null&&(V.idxs?V.idxs.forEach((ie,ae)=>{ne[ae]=ie}):f_(V.idx)||ne.fill(V.idx),de.idx=ne[0]),se&&de.live){for(let ie=0;ie<x.length;ie++)(ie>0||m==1&&!ot)&&$(ie,ne[ie]);ui()}rr=!1,Z!==!1&&et("setLegend")}r.setLegend=y;function $(V,Z){let ie=x[V],ae=V==0&&F==2?Hn:n[V],ge;ot?ge=ie.values(r,V,Z)??Qe:(ge=ie.value(r,Z==null?null:ae[Z],V,Z),ge=ge==null?Qe:{_:ge}),de.values[V]=ge}function _(V,Z,ie){Os=ct,nn=qt,[ct,qt]=ee.move(r,ct,qt),ee.left=ct,ee.top=qt,ce&&(ro&&ho(ro,cr(ct),0,gt,Je),Fn&&ho(Fn,0,cr(qt),gt,Je));let ae,ge=hn>Tn;Vn=pn,_i=null;let _e=W.ori==0?gt:Je,Te=W.ori==1?gt:Je;if(ct<0||En==0||ge){ae=ee.idx=null;for(let Fe=0;Fe<x.length;Fe++){let We=Zn[Fe];We!=null&&ho(We,-10,-10,gt,Je)}Dr&&ir(null,zi,!0,V==null&&Ct.setSeries),de.live&&(ne.fill(ae),rr=!0)}else{let Fe,We,Ve;m==1&&(Fe=W.ori==0?ct:qt,We=on(Fe,C),ae=ee.idx=Yi(We,n[0],hn,Tn),Ve=O(n[0][ae],W,_e,0));let Ke=-10,Xe=-10,xt=0,Xt=0,Bt=!0,bt="",ft="";for(let at=m==2?1:0;at<x.length;at++){let yn=x[at],Ln=ne[at],sr=Ln==null?null:m==1?n[at][Ln]:n[at][1][Ln],sn=ee.dataIdx(r,at,ae,We),dn=sn==null?null:m==1?n[at][sn]:n[at][1][sn];if(rr=rr||dn!=sr||sn!=Ln,ne[at]=sn,at>0&&yn.show){let ve=sn==null?-10:sn==ae?Ve:O(m==1?n[0][sn]:n[at][0][sn],W,_e,0),Re=dn==null?-10:S(dn,m==1?R[yn.scale]:R[yn.facets[1].scale],Te,0);if(Dr&&dn!=null){let Se=W.ori==1?ct:qt,qe=lr(Nr.dist(r,at,sn,Re,Se));if(qe<Vn){let ht=Nr.bias;if(ht!=0){let kt=on(Se,yn.scale),en=dn>=0?1:-1,Wt=kt>=0?1:-1;Wt==en&&(Wt==1?ht==1?dn>=kt:dn<=kt:ht==1?dn<=kt:dn>=kt)&&(Vn=qe,_i=at)}else Vn=qe,_i=at}}if(rr||Sn){let Se,qe;W.ori==0?(Se=ve,qe=Re):(Se=Re,qe=ve);let ht,kt,en,Wt,hi,Sr,xn=!0,Bi=fn.bbox;if(Bi!=null){xn=!1;let $r=Bi(r,at);en=$r.left,Wt=$r.top,ht=$r.width,kt=$r.height}else en=Se,Wt=qe,ht=kt=fn.size(r,at);if(Sr=fn.fill(r,at),hi=fn.stroke(r,at),Sn)at==_i&&Vn<=Nr.prox&&(Ke=en,Xe=Wt,xt=ht,Xt=kt,Bt=xn,bt=Sr,ft=hi);else{let $r=Zn[at];$r!=null&&(xi[at]=en,Ci[at]=Wt,Wg($r,ht,kt,xn),zg($r,Sr,hi),ho($r,Ii(en),Ii(Wt),gt,Je))}}}}if(Sn){let at=Nr.prox,yn=ki==null?Vn<=at:Vn>at||_i!=ki;if(rr||yn){let Ln=Zn[0];Ln!=null&&(xi[0]=Ke,Ci[0]=Xe,Wg(Ln,xt,Xt,Bt),zg(Ln,bt,ft),ho(Ln,Ii(Ke),Ii(Xe),gt,Je))}}}if(wt.show&&Pi)if(V!=null){let[Fe,We]=Ct.scales,[Ve,Ke]=Ct.match,[Xe,xt]=V.cursor.sync.scales,Xt=V.cursor.drag;if(je=Xt._x,wn=Xt._y,je||wn){let{left:Bt,top:bt,width:ft,height:at}=V.select,yn=V.scales[Xe].ori,Ln=V.posToVal,sr,sn,dn,ve,Re,Se=Fe!=null&&Ve(Fe,Xe),qe=We!=null&&Ke(We,xt);Se&&je?(yn==0?(sr=Bt,sn=ft):(sr=bt,sn=at),dn=R[Fe],ve=O(Ln(sr,Xe),dn,_e,0),Re=O(Ln(sr+sn,Xe),dn,_e,0),Co(Ji(ve,Re),lr(Re-ve))):Co(0,_e),qe&&wn?(yn==1?(sr=Bt,sn=ft):(sr=bt,sn=at),dn=R[We],ve=S(Ln(sr,xt),dn,Te,0),Re=S(Ln(sr+sn,xt),dn,Te,0),kr(Ji(ve,Re),lr(Re-ve))):kr(0,Te)}else X()}else{let Fe=lr(Os-Ca),We=lr(nn-No);if(W.ori==1){let xt=Fe;Fe=We,We=xt}je=Un.x&&Fe>=Un.dist,wn=Un.y&&We>=Un.dist;let Ve=Un.uni;Ve!=null?je&&wn&&(je=Fe>=Ve,wn=We>=Ve,!je&&!wn&&(We>Fe?wn=!0:je=!0)):Un.x&&Un.y&&(je||wn)&&(je=wn=!0);let Ke,Xe;je&&(W.ori==0?(Ke=Di,Xe=ct):(Ke=xo,Xe=qt),Co(Ji(Ke,Xe),lr(Xe-Ke)),wn||kr(0,Te)),wn&&(W.ori==1?(Ke=Di,Xe=ct):(Ke=xo,Xe=qt),kr(Ji(Ke,Xe),lr(Xe-Ke)),je||Co(0,_e)),!je&&!wn&&(Co(0,0),kr(0,0))}if(Un._x=je,Un._y=wn,V==null){if(ie){if(Yt!=null){let[Fe,We]=Ct.scales;Ct.values[0]=Fe!=null?on(W.ori==0?ct:qt,Fe):null,Ct.values[1]=We!=null?on(W.ori==1?ct:qt,We):null}_t(ju,r,ct,qt,gt,Je,ae)}if(Dr){let Fe=ie&&Ct.setSeries,We=Nr.prox;ki==null?Vn<=We&&ir(_i,zi,!0,Fe):Vn>We?ir(null,zi,!0,Fe):_i!=ki&&ir(_i,zi,!0,Fe)}}rr&&(de.idx=ae,y()),Z!==!1&&et("setCursor")}let P=null;Object.defineProperty(r,"rect",{get(){return P==null&&z(!1),P}});function z(V=!1){V?P=null:(P=o.getBoundingClientRect(),et("syncRect",P))}function j(V,Z,ie,ae,ge,_e,Te){ee._lock||Pi&&V!=null&&V.movementX==0&&V.movementY==0||(q(V,Z,ie,ae,ge,_e,Te,!1,V!=null),V!=null?_(null,!0,!0):_(Z,!0,!1))}function q(V,Z,ie,ae,ge,_e,Te,Fe,We){if(P==null&&z(!1),Zt(V),V!=null)ie=V.clientX-P.left,ae=V.clientY-P.top;else{if(ie<0||ae<0){ct=-10,qt=-10;return}let[Ve,Ke]=Ct.scales,Xe=Z.cursor.sync,[xt,Xt]=Xe.values,[Bt,bt]=Xe.scales,[ft,at]=Ct.match,yn=Z.axes[0].side%2==1,Ln=W.ori==0?gt:Je,sr=W.ori==1?gt:Je,sn=yn?_e:ge,dn=yn?ge:_e,ve=yn?ae:ie,Re=yn?ie:ae;if(Bt!=null?ie=ft(Ve,Bt)?w(xt,R[Ve],Ln,0):-10:ie=Ln*(ve/sn),bt!=null?ae=at(Ke,bt)?w(Xt,R[Ke],sr,0):-10:ae=sr*(Re/dn),W.ori==1){let Se=ie;ie=ae,ae=Se}}We&&(Z==null||Z.cursor.event.type==ju)&&((ie<=1||ie>=gt-1)&&(ie=As(ie,gt)),(ae<=1||ae>=Je-1)&&(ae=As(ae,Je))),Fe?(Ca=ie,No=ae,[Di,xo]=ee.move(r,ie,ae)):(ct=ie,qt=ae)}const Y={width:0,height:0,left:0,top:0};function X(){Fi(Y,!1)}let re,ue,be,ke;function ye(V,Z,ie,ae,ge,_e,Te){Pi=!0,je=wn=Un._x=Un._y=!1,q(V,Z,ie,ae,ge,_e,Te,!0,!1),V!=null&&(Dn(Hu,Vu,Ae,!1),_t(Ig,r,Di,xo,gt,Je,null));let{left:Fe,top:We,width:Ve,height:Ke}=wt;re=Fe,ue=We,be=Ve,ke=Ke}function Ae(V,Z,ie,ae,ge,_e,Te){Pi=Un._x=Un._y=!1,q(V,Z,ie,ae,ge,_e,Te,!1,!0);let{left:Fe,top:We,width:Ve,height:Ke}=wt,Xe=Ve>0||Ke>0,xt=re!=Fe||ue!=We||be!=Ve||ke!=Ke;if(Xe&&xt&&Fi(wt),Un.setScale&&Xe&&xt){let Xt=Fe,Bt=Ve,bt=We,ft=Ke;if(W.ori==1&&(Xt=We,Bt=Ke,bt=Fe,ft=Ve),je&&Fr(C,on(Xt,C),on(Xt+Bt,C)),wn)for(let at in R){let yn=R[at];at!=C&&yn.from==null&&yn.min!=pn&&Fr(at,on(bt+ft,at),on(bt,at))}X()}else ee.lock&&(ee._lock=!ee._lock,_(Z,!0,V!=null));V!=null&&(Kn(Hu,Vu),_t(Hu,r,ct,qt,gt,Je,null))}function Oe(V,Z,ie,ae,ge,_e,Te){if(ee._lock)return;Zt(V);let Fe=Pi;if(Pi){let We=!0,Ve=!0,Ke=10,Xe,xt;W.ori==0?(Xe=je,xt=wn):(Xe=wn,xt=je),Xe&&xt&&(We=ct<=Ke||ct>=gt-Ke,Ve=qt<=Ke||qt>=Je-Ke),Xe&&We&&(ct=ct<Di?0:gt),xt&&Ve&&(qt=qt<xo?0:Je),_(null,!0,!0),Pi=!1}ct=-10,qt=-10,ne.fill(null),_(null,!0,!0),Fe&&(Pi=Fe)}function Ie(V,Z,ie,ae,ge,_e,Te){ee._lock||(Zt(V),oe(),X(),V!=null&&_t(Ng,r,ct,qt,gt,Je,null))}function Ge(){M.forEach(Ek),Xi(r.width,r.height,!0)}xs(Kl,ta,Ge);const ut={};ut.mousedown=ye,ut.mousemove=j,ut.mouseup=Ae,ut.dblclick=Ie,ut.setSeries=(V,Z,ie,ae)=>{let ge=Ct.match[2];ie=ge(r,Z,ie),ie!=-1&&ir(ie,ae,!0,!1)},ce&&(Dn(Ig,o,ye),Dn(ju,o,j),Dn(Lg,o,V=>{Zt(V),z(!1)}),Dn(Og,o,Oe),Dn(Ng,o,Ie),gh.add(r),r.syncRect=z);const Ze=r.hooks=t.hooks||{};function et(V,Z,ie){ns?bo.push([V,Z,ie]):V in Ze&&Ze[V].forEach(ae=>{ae.call(null,r,Z,ie)})}(t.plugins||[]).forEach(V=>{for(let Z in V.hooks)Ze[Z]=(Ze[Z]||[]).concat(V.hooks[Z])});const $n=(V,Z,ie)=>ie,Ct=er({key:null,setSeries:!1,filters:{pub:Qg,sub:Qg},scales:[C,x[1]?x[1].scale:null],match:[em,em,$n],values:[null,null]},ee.sync);Ct.match.length==2&&Ct.match.push($n),ee.sync=Ct;const Yt=Ct.key,It=Fm(Yt);function _t(V,Z,ie,ae,ge,_e,Te){Ct.filters.pub(V,Z,ie,ae,ge,_e,Te)&&It.pub(V,Z,ie,ae,ge,_e,Te)}It.sub(r);function or(V,Z,ie,ae,ge,_e,Te){Ct.filters.sub(V,Z,ie,ae,ge,_e,Te)&&ut[V](null,Z,ie,ae,ge,_e,Te)}r.pub=or;function pr(){It.unsub(r),gh.delete(r),vr.clear(),Yu(Kl,ta,Ge),d.remove(),pe?.remove(),et("destroy")}r.destroy=pr;function In(){et("init",t,n),br(n||t.data,!1),A[C]?De(C,A[C]):oe(),bi=wt.show&&(wt.width>0||wt.height>0),yr=rr=!0,Xi(t.width,t.height)}return x.forEach(si),M.forEach(_r),e?e instanceof HTMLElement?(e.appendChild(d),In()):e(r,In):In(),r}Mr.assign=er,Mr.fmtNum=Xu,Mr.rangeNum=Xl,Mr.rangeLog=Zl,Mr.rangeAsinh=Ju,Mr.orient=ks,Mr.pxRatio=tn,Mr.join=w_,Mr.fmtDate=nh,Mr.tzDate=M_,Mr.sync=Fm;{Mr.addGap=fk,Mr.clipGaps=oc;let t=Mr.paths={points:Vm};t.linear=Gm,t.stepped=mk,t.bars=vk,t.spline=bk}var tv,nv;function Tk(){return nv||(nv=1,tv=function(t,n,e,r,m){var f,g;if(r===void 0)r=0;else if(r=r|0,r<0||r>=t.length)throw new RangeError("invalid lower bound");if(m===void 0)m=t.length-1;else if(m=m|0,m<r||m>=t.length)throw new RangeError("invalid upper bound");for(;r<=m;)if(f=r+(m-r>>>1),g=+e(t[f],n,f,t),g<0)r=f+1;else if(g>0)m=f-1;else return f;return~r}),tv}var Mk=Tk();const eD=On("y",ql(Mk));var vh,rv;function Ik(){if(rv)return vh;rv=1;function t(n,e,r){var m=-1,f=n.length;e<0&&(e=-e>f?0:f+e),r=r>f?f:r,r<0&&(r+=f),f=e>r?0:r-e>>>0,e>>>=0;for(var g=Array(f);++m<f;)g[m]=n[m+e];return g}return vh=t,vh}var yh,iv;function Lk(){if(iv)return yh;iv=1;var t=Ik();function n(e,r,m){var f=e.length;return m=m===void 0?f:m,!r&&m>=f?e:t(e,r,m)}return yh=n,yh}var bh,ov;function sv(){if(ov)return bh;ov=1;var t="\\ud800-\\udfff",n="\\u0300-\\u036f",e="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",m=n+e+r,f="\\ufe0e\\ufe0f",g="\\u200d",w=RegExp("["+g+t+m+f+"]");function u(d){return w.test(d)}return bh=u,bh}var wh,av;function Ok(){if(av)return wh;av=1;function t(n){return n.split("")}return wh=t,wh}var xh,lv;function Nk(){if(lv)return xh;lv=1;var t="\\ud800-\\udfff",n="\\u0300-\\u036f",e="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",m=n+e+r,f="\\ufe0e\\ufe0f",g="["+t+"]",w="["+m+"]",u="\\ud83c[\\udffb-\\udfff]",d="(?:"+w+"|"+u+")",a="[^"+t+"]",l="(?:\\ud83c[\\udde6-\\uddff]){2}",c="[\\ud800-\\udbff][\\udc00-\\udfff]",h="\\u200d",o=d+"?",s="["+f+"]?",p="(?:"+h+"(?:"+[a,l,c].join("|")+")"+s+o+")*",b=s+o+p,x="(?:"+[a+w+"?",w,l,c,g].join("|")+")",M=RegExp(u+"(?="+u+")|"+x+b,"g");function R(k){return k.match(M)||[]}return xh=R,xh}var Ch,cv;function Dk(){if(cv)return Ch;cv=1;var t=Ok(),n=sv(),e=Nk();function r(m){return n(m)?e(m):t(m)}return Ch=r,Ch}var Ah,uv;function Pk(){if(uv)return Ah;uv=1;var t=typeof Go=="object"&&Go&&Go.Object===Object&&Go;return Ah=t,Ah}var _h,hv;function Fk(){if(hv)return _h;hv=1;var t=Pk(),n=typeof self=="object"&&self&&self.Object===Object&&self,e=t||n||Function("return this")();return _h=e,_h}var kh,dv;function Sh(){if(dv)return kh;dv=1;var t=Fk(),n=t.Symbol;return kh=n,kh}var $h,fv;function zk(){if(fv)return $h;fv=1;function t(n,e){for(var r=-1,m=n==null?0:n.length,f=Array(m);++r<m;)f[r]=e(n[r],r,n);return f}return $h=t,$h}var Rh,pv;function Bk(){if(pv)return Rh;pv=1;var t=Array.isArray;return Rh=t,Rh}var Eh,gv;function Wk(){if(gv)return Eh;gv=1;var t=Sh(),n=Object.prototype,e=n.hasOwnProperty,r=n.toString,m=t?t.toStringTag:void 0;function f(g){var w=e.call(g,m),u=g[m];try{g[m]=void 0;var d=!0}catch{}var a=r.call(g);return d&&(w?g[m]=u:delete g[m]),a}return Eh=f,Eh}var Th,mv;function jk(){if(mv)return Th;mv=1;var t=Object.prototype,n=t.toString;function e(r){return n.call(r)}return Th=e,Th}var Mh,vv;function Hk(){if(vv)return Mh;vv=1;var t=Sh(),n=Wk(),e=jk(),r="[object Null]",m="[object Undefined]",f=t?t.toStringTag:void 0;function g(w){return w==null?w===void 0?m:r:f&&f in Object(w)?n(w):e(w)}return Mh=g,Mh}var Ih,yv;function Uk(){if(yv)return Ih;yv=1;function t(n){return n!=null&&typeof n=="object"}return Ih=t,Ih}var Lh,bv;function Vk(){if(bv)return Lh;bv=1;var t=Hk(),n=Uk(),e="[object Symbol]";function r(m){return typeof m=="symbol"||n(m)&&t(m)==e}return Lh=r,Lh}var Oh,wv;function qk(){if(wv)return Oh;wv=1;var t=Sh(),n=zk(),e=Bk(),r=Vk(),m=t?t.prototype:void 0,f=m?m.toString:void 0;function g(w){if(typeof w=="string")return w;if(e(w))return n(w,g)+"";if(r(w))return f?f.call(w):"";var u=w+"";return u=="0"&&1/w==-1/0?"-0":u}return Oh=g,Oh}var Nh,xv;function cc(){if(xv)return Nh;xv=1;var t=qk();function n(e){return e==null?"":t(e)}return Nh=n,Nh}var Dh,Cv;function Gk(){if(Cv)return Dh;Cv=1;var t=Lk(),n=sv(),e=Dk(),r=cc();function m(f){return function(g){g=r(g);var w=n(g)?e(g):void 0,u=w?w[0]:g.charAt(0),d=w?t(w,1).join(""):g.slice(1);return u[f]()+d}}return Dh=m,Dh}var Ph,Av;function _v(){if(Av)return Ph;Av=1;var t=Gk(),n=t("toUpperCase");return Ph=n,Ph}var Kk=_v();const Yk=ql(Kk);var Fh,kv;function Jk(){if(kv)return Fh;kv=1;var t=cc(),n=_v();function e(r){return n(t(r).toLowerCase())}return Fh=e,Fh}var zh,Sv;function Zk(){if(Sv)return zh;Sv=1;function t(n,e,r,m){var f=-1,g=n==null?0:n.length;for(m&&g&&(r=n[++f]);++f<g;)r=e(r,n[f],f,n);return r}return zh=t,zh}var Bh,$v;function Xk(){if($v)return Bh;$v=1;function t(n){return function(e){return n?.[e]}}return Bh=t,Bh}var Wh,Rv;function Qk(){if(Rv)return Wh;Rv=1;var t=Xk(),n={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},e=t(n);return Wh=e,Wh}var jh,Ev;function eS(){if(Ev)return jh;Ev=1;var t=Qk(),n=cc(),e=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,r="\\u0300-\\u036f",m="\\ufe20-\\ufe2f",f="\\u20d0-\\u20ff",g=r+m+f,w="["+g+"]",u=RegExp(w,"g");function d(a){return a=n(a),a&&a.replace(e,t).replace(u,"")}return jh=d,jh}var Hh,Tv;function tS(){if(Tv)return Hh;Tv=1;var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function n(e){return e.match(t)||[]}return Hh=n,Hh}var Uh,Mv;function nS(){if(Mv)return Uh;Mv=1;var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function n(e){return t.test(e)}return Uh=n,Uh}var Vh,Iv;function rS(){if(Iv)return Vh;Iv=1;var t="\\ud800-\\udfff",n="\\u0300-\\u036f",e="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",m=n+e+r,f="\\u2700-\\u27bf",g="a-z\\xdf-\\xf6\\xf8-\\xff",w="\\xac\\xb1\\xd7\\xf7",u="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",d="\\u2000-\\u206f",a=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",l="A-Z\\xc0-\\xd6\\xd8-\\xde",c="\\ufe0e\\ufe0f",h=w+u+d+a,o="['’]",s="["+h+"]",p="["+m+"]",b="\\d+",x="["+f+"]",M="["+g+"]",R="[^"+t+h+b+f+g+l+"]",k="\\ud83c[\\udffb-\\udfff]",C="(?:"+p+"|"+k+")",L="[^"+t+"]",D="(?:\\ud83c[\\udde6-\\uddff]){2}",I="[\\ud800-\\udbff][\\udc00-\\udfff]",T="["+l+"]",W="\\u200d",F="(?:"+M+"|"+R+")",O="(?:"+T+"|"+R+")",S="(?:"+o+"(?:d|ll|m|re|s|t|ve))?",A="(?:"+o+"(?:D|LL|M|RE|S|T|VE))?",N=C+"?",B="["+c+"]?",U="(?:"+W+"(?:"+[L,D,I].join("|")+")"+B+N+")*",G="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",J="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",ne=B+N+U,de="(?:"+[x,D,I].join("|")+")"+ne,ee=RegExp([T+"?"+M+"+"+S+"(?="+[s,T,"$"].join("|")+")",O+"+"+A+"(?="+[s,T+F,"$"].join("|")+")",T+"?"+F+"+"+S,T+"+"+A,J,G,b,de].join("|"),"g");function se(ce){return ce.match(ee)||[]}return Vh=se,Vh}var qh,Lv;function iS(){if(Lv)return qh;Lv=1;var t=tS(),n=nS(),e=cc(),r=rS();function m(f,g,w){return f=e(f),g=w?void 0:g,g===void 0?n(f)?r(f):t(f):f.match(g)||[]}return qh=m,qh}var Gh,Ov;function oS(){if(Ov)return Gh;Ov=1;var t=Zk(),n=eS(),e=iS(),r="['’]",m=RegExp(r,"g");function f(g){return function(w){return t(e(n(w).replace(m,"")),g,"")}}return Gh=f,Gh}var Kh,Nv;function sS(){if(Nv)return Kh;Nv=1;var t=Jk(),n=oS(),e=n(function(r,m,f){return m=m.toLowerCase(),r+(f?t(m):m)});return Kh=e,Kh}var aS=sS();const lS=ql(aS),cS=Object.assign({"./ArrayWidget.vue":()=>it(()=>rt.import("./ArrayWidget-D1PArcGr-c8c751af5b0b3e9d923d.js"),void 0),"./ArrayplotWidget.vue":()=>it(()=>rt.import("./ArrayplotWidget-DPUPy0qM-b7c3bff83bf418fe0a6f.js"),void 0),"./BlockWidget.vue":()=>it(()=>rt.import("./BlockWidget-_VUsK5T9-e9ea12442411c894a337.js"),void 0),"./ButtonWidget.vue":()=>it(()=>rt.import("./ButtonWidget-DE41o-cg-c0cf6714bdd559938c90.js"),void 0),"./CanvasWidget.vue":()=>it(()=>rt.import("./CanvasWidget-BEi8h3Mq-93b602cbc1f1c3f8a989.js"),void 0),"./CanvasdotWidget.vue":()=>it(()=>rt.import("./CanvasdotWidget-eZuMgkhL-d2239b9c5db9ac121539.js"),void 0),"./CanvasimageWidget.vue":()=>it(()=>rt.import("./CanvasimageWidget-COv_Qnc8-b3b91fba8876839ea74b.js"),void 0),"./CanvasimagevalueWidget.vue":()=>it(()=>rt.import("./CanvasimagevalueWidget-BhuUqLOo-6673175b5d15945d1698.js"),void 0),"./CanvaslabelWidget.vue":()=>it(()=>rt.import("./CanvaslabelWidget-DtvbgeYH-65b35c16cb83363efca3.js"),void 0),"./CanvaslabelvalueWidget.vue":()=>it(()=>rt.import("./CanvaslabelvalueWidget-C_FRIeNb-127a95383fbb9d362d05.js"),void 0),"./CanvaslineWidget.vue":()=>it(()=>rt.import("./CanvaslineWidget-D1K_6mAY-aaa1cc8b5c1e016e8324.js"),void 0),"./CanvaslinevalueWidget.vue":()=>it(()=>rt.import("./CanvaslinevalueWidget-D4eaxWhR-363e4bb482ba7a73ba6a.js"),void 0),"./CheckbuttonWidget.vue":()=>it(()=>rt.import("./CheckbuttonWidget-ByxMDkiS-1d4c199071fc6e719a35.js"),void 0),"./ComboboxWidget.vue":()=>it(()=>rt.import("./ComboboxWidget-CAGxGv2r-770ba10af28e2ff80127.js"),void 0),"./DateWidget.vue":()=>it(()=>rt.import("./DateWidget-DkNWx28s-b13f63213d6b9fcb175d.js"),void 0),"./DynamicWidget.vue":()=>it(()=>rt.import("./DynamicWidget-BuSbQVhf-55ea1ee13a3afafb3570.js"),void 0),"./FilechecksumWidget.vue":()=>it(()=>rt.import("./FilechecksumWidget-DSfNEnDJ-4e730e295b0b0aa7d9ad.js"),void 0),"./FiledisplayWidget.vue":()=>it(()=>rt.import("./FiledisplayWidget-D2cxMmrP-a05420f106f98fc9a1c3.js"),void 0),"./FormatvalueWidget.vue":()=>it(()=>rt.import("./FormatvalueWidget-6-bj_PJO-19133d9392f2b921ec6c.js"),void 0),"./HorizontalWidget.vue":()=>it(()=>rt.import("./HorizontalWidget-C9UFBPsk-0c0dd37a884935f911ad.js"),void 0),"./HorizontalboxWidget.vue":()=>it(()=>rt.import("./HorizontalboxWidget-CWLfmRtr-37ef9ec7d67d226af1c4.js"),void 0),"./HorizontallineWidget.vue":()=>it(()=>rt.import("./HorizontallineWidget-DeFkOaYO-4210d0981cf03ed31819.js"),void 0),"./IframeWidget.vue":()=>it(()=>rt.import("./IframeWidget-Bn9eGzrq-4d363d16eda9121de56f.js"),void 0),"./ImageviewerWidget.vue":()=>it(()=>rt.import("./ImageviewerWidget-BUWhF32Z-8968c211affb8ae31358.js"),void 0),"./LabelWidget.vue":()=>it(()=>rt.import("./LabelWidget-BhzkN06D-82e78a304e7976c050e7.js"),void 0),"./LabelledWidget.vue":()=>it(()=>rt.import("./LabelledWidget-vx8NvW1b-2f85e885d9b34bfa9b83.js"),void 0),"./LabelprogressbarWidget.vue":()=>it(()=>rt.import("./LabelprogressbarWidget-t5PvKuS4-5368a53a7909f0a6a0ca.js"),void 0),"./LabelsparklineWidget.vue":()=>it(()=>rt.import("./LabelsparklineWidget-CebbEH-j-967cb6f44c6c55eaf6e2.js"),void 0),"./LabelvalueWidget.vue":()=>it(()=>rt.import("./LabelvalueWidget-Cbs1DBK2-37a6959ba720e2fb2607.js"),void 0),"./LabelvaluedescWidget.vue":()=>it(()=>rt.import("./LabelvaluedescWidget-B7OIOGc0-4e187a1ca9ccebd898ec.js"),void 0),"./LabelvaluelimitsbarWidget.vue":()=>it(()=>rt.import("./LabelvaluelimitsbarWidget-C57kf-oQ-91c29b441f80779ffdf4.js"),void 0),"./LabelvaluelimitscolumnWidget.vue":()=>it(()=>rt.import("./LabelvaluelimitscolumnWidget-BRlNDEqp-4560f2046838b297f8b9.js"),void 0),"./LabelvaluerangebarWidget.vue":()=>it(()=>rt.import("./LabelvaluerangebarWidget-Pt_evm3v-7cff22dc6c8171a0737f.js"),void 0),"./LedWidget.vue":()=>it(()=>rt.import("./LedWidget-D1lmNXpi-c9ddb6bb20c6b65e8752.js"),void 0),"./LimitsbarWidget.vue":()=>it(()=>rt.import("./LimitsbarWidget-VpxQXE-e-92655885f9c8ff8dd67a.js"),void 0),"./LimitscolorWidget.vue":()=>it(()=>rt.import("./LimitscolorWidget-79P41CX7-17bfc98cd285ef8d5cf0.js"),void 0),"./LimitscolumnWidget.vue":()=>it(()=>rt.import("./LimitscolumnWidget-BFDXhJeZ-543fc43f72002343d7bb.js"),void 0),"./LinegraphWidget.vue":()=>it(()=>rt.import("./LinegraphWidget-VqkpOlws-1b6eb0d902a3b0577bb7.js"),void 0),"./MatrixbycolumnsWidget.vue":()=>it(()=>rt.import("./MatrixbycolumnsWidget--ihvirDP-8fe2c21364aff79528e9.js"),void 0),"./ProgressbarWidget.vue":()=>it(()=>rt.import("./ProgressbarWidget-BIB3r9SL-04bfb4d921751b068806.js"),void 0),"./RadiobuttonWidget.vue":()=>it(()=>rt.import("./RadiobuttonWidget-C5rxLM7K-41dd5ecc6efc1f7ec023.js"),void 0),"./RadiogroupWidget.vue":()=>it(()=>rt.import("./RadiogroupWidget-CciTCv1U-5447f0a20fd31cb84781.js"),void 0),"./RangebarWidget.vue":()=>it(()=>rt.import("./RangebarWidget-MPQYi2Km-2d0bc2f6ae59f1fc6cb2.js"),void 0),"./RollupWidget.vue":()=>it(()=>rt.import("./RollupWidget-CfjGAhzg-d61d2e69d0dfb53f8d5a.js"),void 0),"./ScrollwindowWidget.vue":()=>it(()=>rt.import("./ScrollwindowWidget-CupaygNN-f0bc8971fbeb2f3b7ac6.js"),void 0),"./SignalWidget.vue":()=>it(()=>rt.import("./SignalWidget-C-qecoTO-ac5acb141c44fbe8bd3b.js"),void 0),"./SpacerWidget.vue":()=>it(()=>rt.import("./SpacerWidget-VVkOCb6N-ec90981ae0ee78718da0.js"),void 0),"./SparklineWidget.vue":()=>it(()=>rt.import("./SparklineWidget-Dsmn38z_-0e974d1a6820c9766d5e.js"),void 0),"./TabbookWidget.vue":()=>it(()=>rt.import("./TabbookWidget-CXklff-l-f8d84ac5de477b47cc89.js"),void 0),"./TextboxWidget.vue":()=>it(()=>rt.import("./TextboxWidget-CHs2VYIv-0afd03dec5b9e1bcf5d5.js"),void 0),"./TextfieldWidget.vue":()=>it(()=>rt.import("./TextfieldWidget-CdANAW-6-abb82a45c67e54365c38.js"),void 0),"./TimeWidget.vue":()=>it(()=>rt.import("./TimeWidget-D0xT1wXR-42543ac5f61f9caf689c.js"),void 0),"./TitleWidget.vue":()=>it(()=>rt.import("./TitleWidget-68NWCcXB-f800dbc154a0b790db80.js"),void 0),"./ValueWidget.vue":()=>it(()=>rt.import("./ValueWidget-B1aGUBP7-09e3a422caa4029a7a89.js"),void 0),"./ValuelimitsbarWidget.vue":()=>it(()=>rt.import("./ValuelimitsbarWidget-B7KcRjLS-89060ce240e589231a32.js"),void 0),"./ValuelimitscolumnWidget.vue":()=>it(()=>rt.import("./ValuelimitscolumnWidget-BVt6nLXq-c3953d4f07717ac68634.js"),void 0),"./ValuerangebarWidget.vue":()=>it(()=>rt.import("./ValuerangebarWidget-uVZEI32U-2e888511354ce5936843.js"),void 0),"./VerticalWidget.vue":()=>it(()=>rt.import("./VerticalWidget-DlftYBjH-6dab9f0f52b2711f6b3f.js"),void 0),"./VerticalboxWidget.vue":()=>it(()=>rt.import("./VerticalboxWidget-C7RrkfY0-2a1e515b69dfc37fd4b3.js"),void 0)}),uS=Object.entries(cS).reduce((t,[n,e])=>{n=n.split("/").pop();const r=Yk(lS(n.replace(/\.\w+$/,"")));return{...t,[r]:kf(e)}},{}),tD=On("w",{components:uS});function Dv(t,n){return function(){return t.apply(n,arguments)}}const{toString:hS}=Object.prototype,{getPrototypeOf:uc}=Object,{iterator:hc,toStringTag:Pv}=Symbol,dc=(t=>n=>{const e=hS.call(n);return t[e]||(t[e]=e.slice(8,-1).toLowerCase())})(Object.create(null)),Zi=t=>(t=t.toLowerCase(),n=>dc(n)===t),fc=t=>n=>typeof n===t,{isArray:ca}=Array,ua=fc("undefined");function el(t){return t!==null&&!ua(t)&&t.constructor!==null&&!ua(t.constructor)&&ii(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const Fv=Zi("ArrayBuffer");function dS(t){let n;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?n=ArrayBuffer.isView(t):n=t&&t.buffer&&Fv(t.buffer),n}const fS=fc("string"),ii=fc("function"),zv=fc("number"),tl=t=>t!==null&&typeof t=="object",pS=t=>t===!0||t===!1,pc=t=>{if(dc(t)!=="object")return!1;const n=uc(t);return(n===null||n===Object.prototype||Object.getPrototypeOf(n)===null)&&!(Pv in t)&&!(hc in t)},gS=t=>{if(!tl(t)||el(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},mS=Zi("Date"),vS=Zi("File"),yS=t=>!!(t&&typeof t.uri<"u"),bS=t=>t&&typeof t.getParts<"u",wS=Zi("Blob"),xS=Zi("FileList"),CS=t=>tl(t)&&ii(t.pipe);function AS(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}const Bv=AS(),Wv=typeof Bv.FormData<"u"?Bv.FormData:void 0,_S=t=>{if(!t)return!1;if(Wv&&t instanceof Wv)return!0;const n=uc(t);if(!n||n===Object.prototype||!ii(t.append))return!1;const e=dc(t);return e==="formdata"||e==="object"&&ii(t.toString)&&t.toString()==="[object FormData]"},kS=Zi("URLSearchParams"),[SS,$S,RS,ES]=["ReadableStream","Request","Response","Headers"].map(Zi),TS=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function nl(t,n,{allOwnKeys:e=!1}={}){if(t===null||typeof t>"u")return;let r,m;if(typeof t!="object"&&(t=[t]),ca(t))for(r=0,m=t.length;r<m;r++)n.call(null,t[r],r,t);else{if(el(t))return;const f=e?Object.getOwnPropertyNames(t):Object.keys(t),g=f.length;let w;for(r=0;r<g;r++)w=f[r],n.call(null,t[w],w,t)}}function jv(t,n){if(el(t))return null;n=n.toLowerCase();const e=Object.keys(t);let r=e.length,m;for(;r-- >0;)if(m=e[r],n===m.toLowerCase())return m;return null}const Ss=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Hv=t=>!ua(t)&&t!==Ss;function Yh(...t){const{caseless:n,skipUndefined:e}=Hv(this)&&this||{},r={},m=(f,g)=>{if(g==="__proto__"||g==="constructor"||g==="prototype")return;const w=n&&jv(r,g)||g,u=Jh(r,w)?r[w]:void 0;pc(u)&&pc(f)?r[w]=Yh(u,f):pc(f)?r[w]=Yh({},f):ca(f)?r[w]=f.slice():(!e||!ua(f))&&(r[w]=f)};for(let f=0,g=t.length;f<g;f++)t[f]&&nl(t[f],m);return r}const MS=(t,n,e,{allOwnKeys:r}={})=>(nl(n,(m,f)=>{e&&ii(m)?Object.defineProperty(t,f,{__proto__:null,value:Dv(m,e),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(t,f,{__proto__:null,value:m,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),t),IS=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),LS=(t,n,e,r)=>{t.prototype=Object.create(n.prototype,r),Object.defineProperty(t.prototype,"constructor",{__proto__:null,value:t,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(t,"super",{__proto__:null,value:n.prototype}),e&&Object.assign(t.prototype,e)},OS=(t,n,e,r)=>{let m,f,g;const w={};if(n=n||{},t==null)return n;do{for(m=Object.getOwnPropertyNames(t),f=m.length;f-- >0;)g=m[f],(!r||r(g,t,n))&&!w[g]&&(n[g]=t[g],w[g]=!0);t=e!==!1&&uc(t)}while(t&&(!e||e(t,n))&&t!==Object.prototype);return n},NS=(t,n,e)=>{t=String(t),(e===void 0||e>t.length)&&(e=t.length),e-=n.length;const r=t.indexOf(n,e);return r!==-1&&r===e},DS=t=>{if(!t)return null;if(ca(t))return t;let n=t.length;if(!zv(n))return null;const e=new Array(n);for(;n-- >0;)e[n]=t[n];return e},PS=(t=>n=>t&&n instanceof t)(typeof Uint8Array<"u"&&uc(Uint8Array)),FS=(t,n)=>{const e=(t&&t[hc]).call(t);let r;for(;(r=e.next())&&!r.done;){const m=r.value;n.call(t,m[0],m[1])}},zS=(t,n)=>{let e;const r=[];for(;(e=t.exec(n))!==null;)r.push(e);return r},BS=Zi("HTMLFormElement"),WS=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,e,r){return e.toUpperCase()+r}),Jh=(({hasOwnProperty:t})=>(n,e)=>t.call(n,e))(Object.prototype),jS=Zi("RegExp"),Uv=(t,n)=>{const e=Object.getOwnPropertyDescriptors(t),r={};nl(e,(m,f)=>{let g;(g=n(m,f,t))!==!1&&(r[f]=g||m)}),Object.defineProperties(t,r)},HS=t=>{Uv(t,(n,e)=>{if(ii(t)&&["arguments","caller","callee"].includes(e))return!1;const r=t[e];if(ii(r)){if(n.enumerable=!1,"writable"in n){n.writable=!1;return}n.set||(n.set=()=>{throw Error("Can not rewrite read-only method '"+e+"'")})}})},US=(t,n)=>{const e={},r=m=>{m.forEach(f=>{e[f]=!0})};return ca(t)?r(t):r(String(t).split(n)),e},VS=()=>{},qS=(t,n)=>t!=null&&Number.isFinite(t=+t)?t:n;function GS(t){return!!(t&&ii(t.append)&&t[Pv]==="FormData"&&t[hc])}const KS=t=>{const n=new WeakSet,e=r=>{if(tl(r)){if(n.has(r))return;if(el(r))return r;if(!("toJSON"in r)){n.add(r);const m=ca(r)?[]:{};return nl(r,(f,g)=>{const w=e(f);!ua(w)&&(m[g]=w)}),n.delete(r),m}}return r};return e(t)},YS=Zi("AsyncFunction"),JS=t=>t&&(tl(t)||ii(t))&&ii(t.then)&&ii(t.catch),Vv=((t,n)=>t?setImmediate:n?((e,r)=>(Ss.addEventListener("message",({source:m,data:f})=>{m===Ss&&f===e&&r.length&&r.shift()()},!1),m=>{r.push(m),Ss.postMessage(e,"*")}))(`axios@${Math.random()}`,[]):e=>setTimeout(e))(typeof setImmediate=="function",ii(Ss.postMessage)),ZS=typeof queueMicrotask<"u"?queueMicrotask.bind(Ss):typeof process<"u"&&process.nextTick||Vv,XS=t=>t!=null&&ii(t[hc]),Ce={isArray:ca,isArrayBuffer:Fv,isBuffer:el,isFormData:_S,isArrayBufferView:dS,isString:fS,isNumber:zv,isBoolean:pS,isObject:tl,isPlainObject:pc,isEmptyObject:gS,isReadableStream:SS,isRequest:$S,isResponse:RS,isHeaders:ES,isUndefined:ua,isDate:mS,isFile:vS,isReactNativeBlob:yS,isReactNative:bS,isBlob:wS,isRegExp:jS,isFunction:ii,isStream:CS,isURLSearchParams:kS,isTypedArray:PS,isFileList:xS,forEach:nl,merge:Yh,extend:MS,trim:TS,stripBOM:IS,inherits:LS,toFlatObject:OS,kindOf:dc,kindOfTest:Zi,endsWith:NS,toArray:DS,forEachEntry:FS,matchAll:zS,isHTMLForm:BS,hasOwnProperty:Jh,hasOwnProp:Jh,reduceDescriptors:Uv,freezeMethods:HS,toObjectSet:US,toCamelCase:WS,noop:VS,toFiniteNumber:qS,findKey:jv,global:Ss,isContextDefined:Hv,isSpecCompliantForm:GS,toJSONObject:KS,isAsyncFn:YS,isThenable:JS,setImmediate:Vv,asap:ZS,isIterable:XS},QS=Ce.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),e$=t=>{const n={};let e,r,m;return t&&t.split(`
1481
+ `).forEach(function(f){m=f.indexOf(":"),e=f.substring(0,m).trim().toLowerCase(),r=f.substring(m+1).trim(),!(!e||n[e]&&QS[e])&&(e==="set-cookie"?n[e]?n[e].push(r):n[e]=[r]:n[e]=n[e]?n[e]+", "+r:r)}),n};function t$(t){let n=0,e=t.length;for(;n<e;){const r=t.charCodeAt(n);if(r!==9&&r!==32)break;n+=1}for(;e>n;){const r=t.charCodeAt(e-1);if(r!==9&&r!==32)break;e-=1}return n===0&&e===t.length?t:t.slice(n,e)}const n$=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),r$=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function Zh(t,n){return Ce.isArray(t)?t.map(e=>Zh(e,n)):t$(String(t).replace(n,""))}const i$=t=>Zh(t,n$),o$=t=>Zh(t,r$);function qv(t){const n=Object.create(null);return Ce.forEach(t.toJSON(),(e,r)=>{n[r]=o$(e)}),n}const Gv=Symbol("internals");function rl(t){return t&&String(t).trim().toLowerCase()}function gc(t){return t===!1||t==null?t:Ce.isArray(t)?t.map(gc):i$(String(t))}function s$(t){const n=Object.create(null),e=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=e.exec(t);)n[r[1]]=r[2];return n}const a$=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function Xh(t,n,e,r,m){if(Ce.isFunction(r))return r.call(this,n,e);if(m&&(n=e),!!Ce.isString(n)){if(Ce.isString(r))return n.indexOf(r)!==-1;if(Ce.isRegExp(r))return r.test(n)}}function l$(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(n,e,r)=>e.toUpperCase()+r)}function c$(t,n){const e=Ce.toCamelCase(" "+n);["get","set","has"].forEach(r=>{Object.defineProperty(t,r+e,{__proto__:null,value:function(m,f,g){return this[r].call(this,n,m,f,g)},configurable:!0})})}let Vr=class{constructor(n){n&&this.set(n)}set(n,e,r){const m=this;function f(w,u,d){const a=rl(u);if(!a)throw new Error("header name must be a non-empty string");const l=Ce.findKey(m,a);(!l||m[l]===void 0||d===!0||d===void 0&&m[l]!==!1)&&(m[l||u]=gc(w))}const g=(w,u)=>Ce.forEach(w,(d,a)=>f(d,a,u));if(Ce.isPlainObject(n)||n instanceof this.constructor)g(n,e);else if(Ce.isString(n)&&(n=n.trim())&&!a$(n))g(e$(n),e);else if(Ce.isObject(n)&&Ce.isIterable(n)){let w={},u,d;for(const a of n){if(!Ce.isArray(a))throw TypeError("Object iterator must return a key-value pair");w[d=a[0]]=(u=w[d])?Ce.isArray(u)?[...u,a[1]]:[u,a[1]]:a[1]}g(w,e)}else n!=null&&f(e,n,r);return this}get(n,e){if(n=rl(n),n){const r=Ce.findKey(this,n);if(r){const m=this[r];if(!e)return m;if(e===!0)return s$(m);if(Ce.isFunction(e))return e.call(this,m,r);if(Ce.isRegExp(e))return e.exec(m);throw new TypeError("parser must be boolean|regexp|function")}}}has(n,e){if(n=rl(n),n){const r=Ce.findKey(this,n);return!!(r&&this[r]!==void 0&&(!e||Xh(this,this[r],r,e)))}return!1}delete(n,e){const r=this;let m=!1;function f(g){if(g=rl(g),g){const w=Ce.findKey(r,g);w&&(!e||Xh(r,r[w],w,e))&&(delete r[w],m=!0)}}return Ce.isArray(n)?n.forEach(f):f(n),m}clear(n){const e=Object.keys(this);let r=e.length,m=!1;for(;r--;){const f=e[r];(!n||Xh(this,this[f],f,n,!0))&&(delete this[f],m=!0)}return m}normalize(n){const e=this,r={};return Ce.forEach(this,(m,f)=>{const g=Ce.findKey(r,f);if(g){e[g]=gc(m),delete e[f];return}const w=n?l$(f):String(f).trim();w!==f&&delete e[f],e[w]=gc(m),r[w]=!0}),this}concat(...n){return this.constructor.concat(this,...n)}toJSON(n){const e=Object.create(null);return Ce.forEach(this,(r,m)=>{r!=null&&r!==!1&&(e[m]=n&&Ce.isArray(r)?r.join(", "):r)}),e}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([n,e])=>n+": "+e).join(`
1482
+ `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(n){return n instanceof this?n:new this(n)}static concat(n,...e){const r=new this(n);return e.forEach(m=>r.set(m)),r}static accessor(n){const e=(this[Gv]=this[Gv]={accessors:{}}).accessors,r=this.prototype;function m(f){const g=rl(f);e[g]||(c$(r,f),e[g]=!0)}return Ce.isArray(n)?n.forEach(m):m(n),this}};Vr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Ce.reduceDescriptors(Vr.prototype,({value:t},n)=>{let e=n[0].toUpperCase()+n.slice(1);return{get:()=>t,set(r){this[e]=r}}}),Ce.freezeMethods(Vr);const u$="[REDACTED ****]";function h$(t){if(Ce.hasOwnProp(t,"toJSON"))return!0;let n=Object.getPrototypeOf(t);for(;n&&n!==Object.prototype;){if(Ce.hasOwnProp(n,"toJSON"))return!0;n=Object.getPrototypeOf(n)}return!1}function d$(t,n){const e=new Set(n.map(f=>String(f).toLowerCase())),r=[],m=f=>{if(f===null||typeof f!="object"||Ce.isBuffer(f))return f;if(r.indexOf(f)!==-1)return;f instanceof Vr&&(f=f.toJSON()),r.push(f);let g;if(Ce.isArray(f))g=[],f.forEach((w,u)=>{const d=m(w);Ce.isUndefined(d)||(g[u]=d)});else{if(!Ce.isPlainObject(f)&&h$(f))return r.pop(),f;g=Object.create(null);for(const[w,u]of Object.entries(f)){const d=e.has(w.toLowerCase())?u$:m(u);Ce.isUndefined(d)||(g[w]=d)}}return r.pop(),g};return m(t)}let nt=class Q0 extends Error{static from(n,e,r,m,f,g){const w=new Q0(n.message,e||n.code,r,m,f);return w.cause=n,w.name=n.name,n.status!=null&&w.status==null&&(w.status=n.status),g&&Object.assign(w,g),w}constructor(n,e,r,m,f){super(n),Object.defineProperty(this,"message",{__proto__:null,value:n,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,e&&(this.code=e),r&&(this.config=r),m&&(this.request=m),f&&(this.response=f,this.status=f.status)}toJSON(){const n=this.config,e=n&&Ce.hasOwnProp(n,"redact")?n.redact:void 0,r=Ce.isArray(e)&&e.length>0?d$(n,e):Ce.toJSONObject(n);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:r,code:this.code,status:this.status}}};nt.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",nt.ERR_BAD_OPTION="ERR_BAD_OPTION",nt.ECONNABORTED="ECONNABORTED",nt.ETIMEDOUT="ETIMEDOUT",nt.ECONNREFUSED="ECONNREFUSED",nt.ERR_NETWORK="ERR_NETWORK",nt.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",nt.ERR_DEPRECATED="ERR_DEPRECATED",nt.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",nt.ERR_BAD_REQUEST="ERR_BAD_REQUEST",nt.ERR_CANCELED="ERR_CANCELED",nt.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",nt.ERR_INVALID_URL="ERR_INVALID_URL",nt.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const f$=null;function Qh(t){return Ce.isPlainObject(t)||Ce.isArray(t)}function Kv(t){return Ce.endsWith(t,"[]")?t.slice(0,-2):t}function ed(t,n,e){return t?t.concat(n).map(function(r,m){return r=Kv(r),!e&&m?"["+r+"]":r}).join(e?".":""):n}function p$(t){return Ce.isArray(t)&&!t.some(Qh)}const g$=Ce.toFlatObject(Ce,{},null,function(t){return/^is[A-Z]/.test(t)});function mc(t,n,e){if(!Ce.isObject(t))throw new TypeError("target must be an object");n=n||new FormData,e=Ce.toFlatObject(e,{metaTokens:!0,dots:!1,indexes:!1},!1,function(s,p){return!Ce.isUndefined(p[s])});const r=e.metaTokens,m=e.visitor||l,f=e.dots,g=e.indexes,w=e.Blob||typeof Blob<"u"&&Blob,u=e.maxDepth===void 0?100:e.maxDepth,d=w&&Ce.isSpecCompliantForm(n);if(!Ce.isFunction(m))throw new TypeError("visitor must be a function");function a(s){if(s===null)return"";if(Ce.isDate(s))return s.toISOString();if(Ce.isBoolean(s))return s.toString();if(!d&&Ce.isBlob(s))throw new nt("Blob is not supported. Use a Buffer instead.");return Ce.isArrayBuffer(s)||Ce.isTypedArray(s)?d&&typeof Blob=="function"?new Blob([s]):Buffer.from(s):s}function l(s,p,b){let x=s;if(Ce.isReactNative(n)&&Ce.isReactNativeBlob(s))return n.append(ed(b,p,f),a(s)),!1;if(s&&!b&&typeof s=="object"){if(Ce.endsWith(p,"{}"))p=r?p:p.slice(0,-2),s=JSON.stringify(s);else if(Ce.isArray(s)&&p$(s)||(Ce.isFileList(s)||Ce.endsWith(p,"[]"))&&(x=Ce.toArray(s)))return p=Kv(p),x.forEach(function(M,R){!(Ce.isUndefined(M)||M===null)&&n.append(g===!0?ed([p],R,f):g===null?p:p+"[]",a(M))}),!1}return Qh(s)?!0:(n.append(ed(b,p,f),a(s)),!1)}const c=[],h=Object.assign(g$,{defaultVisitor:l,convertValue:a,isVisitable:Qh});function o(s,p,b=0){if(!Ce.isUndefined(s)){if(b>u)throw new nt("Object is too deeply nested ("+b+" levels). Max depth: "+u,nt.ERR_FORM_DATA_DEPTH_EXCEEDED);if(c.indexOf(s)!==-1)throw Error("Circular reference detected in "+p.join("."));c.push(s),Ce.forEach(s,function(x,M){(!(Ce.isUndefined(x)||x===null)&&m.call(n,x,Ce.isString(M)?M.trim():M,p,h))===!0&&o(x,p?p.concat(M):[M],b+1)}),c.pop()}}if(!Ce.isObject(t))throw new TypeError("data must be an object");return o(t),n}function Yv(t){const n={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(t).replace(/[!'()~]|%20/g,function(e){return n[e]})}function td(t,n){this._pairs=[],t&&mc(t,this,n)}const Jv=td.prototype;Jv.append=function(t,n){this._pairs.push([t,n])},Jv.toString=function(t){const n=t?function(e){return t.call(this,e,Yv)}:Yv;return this._pairs.map(function(e){return n(e[0])+"="+n(e[1])},"").join("&")};function m$(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Zv(t,n,e){if(!n)return t;const r=e&&e.encode||m$,m=Ce.isFunction(e)?{serialize:e}:e,f=m&&m.serialize;let g;if(f?g=f(n,m):g=Ce.isURLSearchParams(n)?n.toString():new td(n,m).toString(r),g){const w=t.indexOf("#");w!==-1&&(t=t.slice(0,w)),t+=(t.indexOf("?")===-1?"?":"&")+g}return t}class Xv{constructor(){this.handlers=[]}use(n,e,r){return this.handlers.push({fulfilled:n,rejected:e,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(n){this.handlers[n]&&(this.handlers[n]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(n){Ce.forEach(this.handlers,function(e){e!==null&&n(e)})}}const nd={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},v$=typeof URLSearchParams<"u"?URLSearchParams:td,y$=typeof FormData<"u"?FormData:null,b$=typeof Blob<"u"?Blob:null,w$={isBrowser:!0,classes:{URLSearchParams:v$,FormData:y$,Blob:b$},protocols:["http","https","file","blob","url","data"]},rd=typeof window<"u"&&typeof document<"u",id=typeof navigator=="object"&&navigator||void 0,x$=rd&&(!id||["ReactNative","NativeScript","NS"].indexOf(id.product)<0),C$=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",A$=rd&&window.location.href||"http://localhost",_$=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:rd,hasStandardBrowserEnv:x$,hasStandardBrowserWebWorkerEnv:C$,navigator:id,origin:A$},Symbol.toStringTag,{value:"Module"})),Ir={..._$,...w$};function k$(t,n){return mc(t,new Ir.classes.URLSearchParams,{visitor:function(e,r,m,f){return Ir.isNode&&Ce.isBuffer(e)?(this.append(r,e.toString("base64")),!1):f.defaultVisitor.apply(this,arguments)},...n})}function S$(t){return Ce.matchAll(/\w+|\[(\w*)]/g,t).map(n=>n[0]==="[]"?"":n[1]||n[0])}function $$(t){const n={},e=Object.keys(t);let r;const m=e.length;let f;for(r=0;r<m;r++)f=e[r],n[f]=t[f];return n}function Qv(t){function n(e,r,m,f){let g=e[f++];if(g==="__proto__")return!0;const w=Number.isFinite(+g),u=f>=e.length;return g=!g&&Ce.isArray(m)?m.length:g,u?(Ce.hasOwnProp(m,g)?m[g]=Ce.isArray(m[g])?m[g].concat(r):[m[g],r]:m[g]=r,!w):((!Ce.hasOwnProp(m,g)||!Ce.isObject(m[g]))&&(m[g]=[]),n(e,r,m[g],f)&&Ce.isArray(m[g])&&(m[g]=$$(m[g])),!w)}if(Ce.isFormData(t)&&Ce.isFunction(t.entries)){const e={};return Ce.forEachEntry(t,(r,m)=>{n(S$(r),m,e,0)}),e}return null}const ha=(t,n)=>t!=null&&Ce.hasOwnProp(t,n)?t[n]:void 0;function R$(t,n,e){if(Ce.isString(t))try{return(n||JSON.parse)(t),Ce.trim(t)}catch(r){if(r.name!=="SyntaxError")throw r}return(e||JSON.stringify)(t)}const il={transitional:nd,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const e=n.getContentType()||"",r=e.indexOf("application/json")>-1,m=Ce.isObject(t);if(m&&Ce.isHTMLForm(t)&&(t=new FormData(t)),Ce.isFormData(t))return r?JSON.stringify(Qv(t)):t;if(Ce.isArrayBuffer(t)||Ce.isBuffer(t)||Ce.isStream(t)||Ce.isFile(t)||Ce.isBlob(t)||Ce.isReadableStream(t))return t;if(Ce.isArrayBufferView(t))return t.buffer;if(Ce.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let f;if(m){const g=ha(this,"formSerializer");if(e.indexOf("application/x-www-form-urlencoded")>-1)return k$(t,g).toString();if((f=Ce.isFileList(t))||e.indexOf("multipart/form-data")>-1){const w=ha(this,"env"),u=w&&w.FormData;return mc(f?{"files[]":t}:t,u&&new u,g)}}return m||r?(n.setContentType("application/json",!1),R$(t)):t}],transformResponse:[function(t){const n=ha(this,"transitional")||il.transitional,e=n&&n.forcedJSONParsing,r=ha(this,"responseType"),m=r==="json";if(Ce.isResponse(t)||Ce.isReadableStream(t))return t;if(t&&Ce.isString(t)&&(e&&!r||m)){const f=!(n&&n.silentJSONParsing)&&m;try{return JSON.parse(t,ha(this,"parseReviver"))}catch(g){if(f)throw g.name==="SyntaxError"?nt.from(g,nt.ERR_BAD_RESPONSE,this,null,ha(this,"response")):g}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Ir.classes.FormData,Blob:Ir.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};Ce.forEach(["delete","get","head","post","put","patch","query"],t=>{il.headers[t]={}});function od(t,n){const e=this||il,r=n||e,m=Vr.from(r.headers);let f=r.data;return Ce.forEach(t,function(g){f=g.call(e,f,m.normalize(),n?n.status:void 0)}),m.normalize(),f}function ey(t){return!!(t&&t.__CANCEL__)}let ol=class extends nt{constructor(n,e,r){super(n??"canceled",nt.ERR_CANCELED,e,r),this.name="CanceledError",this.__CANCEL__=!0}};function ty(t,n,e){const r=e.config.validateStatus;!e.status||!r||r(e.status)?t(e):n(new nt("Request failed with status code "+e.status,e.status>=400&&e.status<500?nt.ERR_BAD_REQUEST:nt.ERR_BAD_RESPONSE,e.config,e.request,e))}function E$(t){const n=/^([-+\w]{1,25}):(?:\/\/)?/.exec(t);return n&&n[1]||""}function T$(t,n){t=t||10;const e=new Array(t),r=new Array(t);let m=0,f=0,g;return n=n!==void 0?n:1e3,function(w){const u=Date.now(),d=r[f];g||(g=u),e[m]=w,r[m]=u;let a=f,l=0;for(;a!==m;)l+=e[a++],a=a%t;if(m=(m+1)%t,m===f&&(f=(f+1)%t),u-g<n)return;const c=d&&u-d;return c?Math.round(l*1e3/c):void 0}}function M$(t,n){let e=0,r=1e3/n,m,f;const g=(w,u=Date.now())=>{e=u,m=null,f&&(clearTimeout(f),f=null),t(...w)};return[(...w)=>{const u=Date.now(),d=u-e;d>=r?g(w,u):(m=w,f||(f=setTimeout(()=>{f=null,g(m)},r-d)))},()=>m&&g(m)]}const vc=(t,n,e=3)=>{let r=0;const m=T$(50,250);return M$(f=>{if(!f||typeof f.loaded!="number")return;const g=f.loaded,w=f.lengthComputable?f.total:void 0,u=w!=null?Math.min(g,w):g,d=Math.max(0,u-r),a=m(d);r=Math.max(r,u);const l={loaded:u,total:w,progress:w?u/w:void 0,bytes:d,rate:a||void 0,estimated:a&&w?(w-u)/a:void 0,event:f,lengthComputable:w!=null,[n?"download":"upload"]:!0};t(l)},e)},ny=(t,n)=>{const e=t!=null;return[r=>n[0]({lengthComputable:e,total:t,loaded:r}),n[1]]},ry=t=>(...n)=>Ce.asap(()=>t(...n)),I$=Ir.hasStandardBrowserEnv?((t,n)=>e=>(e=new URL(e,Ir.origin),t.protocol===e.protocol&&t.host===e.host&&(n||t.port===e.port)))(new URL(Ir.origin),Ir.navigator&&/(msie|trident)/i.test(Ir.navigator.userAgent)):()=>!0,L$=Ir.hasStandardBrowserEnv?{write(t,n,e,r,m,f,g){if(typeof document>"u")return;const w=[`${t}=${encodeURIComponent(n)}`];Ce.isNumber(e)&&w.push(`expires=${new Date(e).toUTCString()}`),Ce.isString(r)&&w.push(`path=${r}`),Ce.isString(m)&&w.push(`domain=${m}`),f===!0&&w.push("secure"),Ce.isString(g)&&w.push(`SameSite=${g}`),document.cookie=w.join("; ")},read(t){if(typeof document>"u")return null;const n=document.cookie.split(";");for(let e=0;e<n.length;e++){const r=n[e].replace(/^\s+/,""),m=r.indexOf("=");if(m!==-1&&r.slice(0,m)===t)return decodeURIComponent(r.slice(m+1))}return null},remove(t){this.write(t,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function O$(t){return typeof t!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function N$(t,n){return n?t.replace(/\/?\/$/,"")+"/"+n.replace(/^\/+/,""):t}function iy(t,n,e){let r=!O$(n);return t&&(r||e===!1)?N$(t,n):n}const oy=t=>t instanceof Vr?{...t}:t;function $s(t,n){n=n||{};const e=Object.create(null);Object.defineProperty(e,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function r(d,a,l,c){return Ce.isPlainObject(d)&&Ce.isPlainObject(a)?Ce.merge.call({caseless:c},d,a):Ce.isPlainObject(a)?Ce.merge({},a):Ce.isArray(a)?a.slice():a}function m(d,a,l,c){if(Ce.isUndefined(a)){if(!Ce.isUndefined(d))return r(void 0,d,l,c)}else return r(d,a,l,c)}function f(d,a){if(!Ce.isUndefined(a))return r(void 0,a)}function g(d,a){if(Ce.isUndefined(a)){if(!Ce.isUndefined(d))return r(void 0,d)}else return r(void 0,a)}function w(d,a,l){if(Ce.hasOwnProp(n,l))return r(d,a);if(Ce.hasOwnProp(t,l))return r(void 0,d)}const u={url:f,method:f,data:f,baseURL:g,transformRequest:g,transformResponse:g,paramsSerializer:g,timeout:g,timeoutMessage:g,withCredentials:g,withXSRFToken:g,adapter:g,responseType:g,xsrfCookieName:g,xsrfHeaderName:g,onUploadProgress:g,onDownloadProgress:g,decompress:g,maxContentLength:g,maxBodyLength:g,beforeRedirect:g,transport:g,httpAgent:g,httpsAgent:g,cancelToken:g,socketPath:g,allowedSocketPaths:g,responseEncoding:g,validateStatus:w,headers:(d,a,l)=>m(oy(d),oy(a),l,!0)};return Ce.forEach(Object.keys({...t,...n}),function(d){if(d==="__proto__"||d==="constructor"||d==="prototype")return;const a=Ce.hasOwnProp(u,d)?u[d]:m,l=Ce.hasOwnProp(t,d)?t[d]:void 0,c=Ce.hasOwnProp(n,d)?n[d]:void 0,h=a(l,c,d);Ce.isUndefined(h)&&a!==w||(e[d]=h)}),e}const D$=["content-type","content-length"];function P$(t,n,e){if(e!=="content-only"){t.set(n);return}Object.entries(n).forEach(([r,m])=>{D$.includes(r.toLowerCase())&&t.set(r,m)})}const F$=t=>encodeURIComponent(t).replace(/%([0-9A-F]{2})/gi,(n,e)=>String.fromCharCode(parseInt(e,16))),sy=t=>{const n=$s({},t),e=c=>Ce.hasOwnProp(n,c)?n[c]:void 0,r=e("data");let m=e("withXSRFToken");const f=e("xsrfHeaderName"),g=e("xsrfCookieName");let w=e("headers");const u=e("auth"),d=e("baseURL"),a=e("allowAbsoluteUrls"),l=e("url");if(n.headers=w=Vr.from(w),n.url=Zv(iy(d,l,a),t.params,t.paramsSerializer),u&&w.set("Authorization","Basic "+btoa((u.username||"")+":"+(u.password?F$(u.password):""))),Ce.isFormData(r)&&(Ir.hasStandardBrowserEnv||Ir.hasStandardBrowserWebWorkerEnv?w.setContentType(void 0):Ce.isFunction(r.getHeaders)&&P$(w,r.getHeaders(),e("formDataHeaderPolicy"))),Ir.hasStandardBrowserEnv&&(Ce.isFunction(m)&&(m=m(n)),m===!0||m==null&&I$(n.url))){const c=f&&g&&L$.read(g);c&&w.set(f,c)}return n},z$=typeof XMLHttpRequest<"u",B$=z$&&function(t){return new Promise(function(n,e){const r=sy(t);let m=r.data;const f=Vr.from(r.headers).normalize();let{responseType:g,onUploadProgress:w,onDownloadProgress:u}=r,d,a,l,c,h;function o(){c&&c(),h&&h(),r.cancelToken&&r.cancelToken.unsubscribe(d),r.signal&&r.signal.removeEventListener("abort",d)}let s=new XMLHttpRequest;s.open(r.method.toUpperCase(),r.url,!0),s.timeout=r.timeout;function p(){if(!s)return;const x=Vr.from("getAllResponseHeaders"in s&&s.getAllResponseHeaders()),M={data:!g||g==="text"||g==="json"?s.responseText:s.response,status:s.status,statusText:s.statusText,headers:x,config:t,request:s};ty(function(R){n(R),o()},function(R){e(R),o()},M),s=null}"onloadend"in s?s.onloadend=p:s.onreadystatechange=function(){!s||s.readyState!==4||s.status===0&&!(s.responseURL&&s.responseURL.startsWith("file:"))||setTimeout(p)},s.onabort=function(){s&&(e(new nt("Request aborted",nt.ECONNABORTED,t,s)),o(),s=null)},s.onerror=function(x){const M=x&&x.message?x.message:"Network Error",R=new nt(M,nt.ERR_NETWORK,t,s);R.event=x||null,e(R),o(),s=null},s.ontimeout=function(){let x=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const M=r.transitional||nd;r.timeoutErrorMessage&&(x=r.timeoutErrorMessage),e(new nt(x,M.clarifyTimeoutError?nt.ETIMEDOUT:nt.ECONNABORTED,t,s)),o(),s=null},m===void 0&&f.setContentType(null),"setRequestHeader"in s&&Ce.forEach(qv(f),function(x,M){s.setRequestHeader(M,x)}),Ce.isUndefined(r.withCredentials)||(s.withCredentials=!!r.withCredentials),g&&g!=="json"&&(s.responseType=r.responseType),u&&([l,h]=vc(u,!0),s.addEventListener("progress",l)),w&&s.upload&&([a,c]=vc(w),s.upload.addEventListener("progress",a),s.upload.addEventListener("loadend",c)),(r.cancelToken||r.signal)&&(d=x=>{s&&(e(!x||x.type?new ol(null,t,s):x),s.abort(),o(),s=null)},r.cancelToken&&r.cancelToken.subscribe(d),r.signal&&(r.signal.aborted?d():r.signal.addEventListener("abort",d)));const b=E$(r.url);if(b&&!Ir.protocols.includes(b)){e(new nt("Unsupported protocol "+b+":",nt.ERR_BAD_REQUEST,t));return}s.send(m||null)})},W$=(t,n)=>{if(t=t?t.filter(Boolean):[],!n&&!t.length)return;const e=new AbortController;let r=!1;const m=function(u){if(!r){r=!0,g();const d=u instanceof Error?u:this.reason;e.abort(d instanceof nt?d:new ol(d instanceof Error?d.message:d))}};let f=n&&setTimeout(()=>{f=null,m(new nt(`timeout of ${n}ms exceeded`,nt.ETIMEDOUT))},n);const g=()=>{t&&(f&&clearTimeout(f),f=null,t.forEach(u=>{u.unsubscribe?u.unsubscribe(m):u.removeEventListener("abort",m)}),t=null)};t.forEach(u=>u.addEventListener("abort",m));const{signal:w}=e;return w.unsubscribe=()=>Ce.asap(g),w},j$=function*(t,n){let e=t.byteLength;if(e<n){yield t;return}let r=0,m;for(;r<e;)m=r+n,yield t.slice(r,m),r=m},H$=async function*(t,n){for await(const e of U$(t))yield*j$(e,n)},U$=async function*(t){if(t[Symbol.asyncIterator]){yield*t;return}const n=t.getReader();try{for(;;){const{done:e,value:r}=await n.read();if(e)break;yield r}}finally{await n.cancel()}},ay=(t,n,e,r)=>{const m=H$(t,n);let f=0,g,w=u=>{g||(g=!0,r&&r(u))};return new ReadableStream({async pull(u){try{const{done:d,value:a}=await m.next();if(d){w(),u.close();return}let l=a.byteLength;if(e){let c=f+=l;e(c)}u.enqueue(new Uint8Array(a))}catch(d){throw w(d),d}},cancel(u){return w(u),m.return()}},{highWaterMark:2})};function V$(t){if(!t||typeof t!="string"||!t.startsWith("data:"))return 0;const n=t.indexOf(",");if(n<0)return 0;const e=t.slice(5,n),r=t.slice(n+1);if(/;base64/i.test(e)){let f=r.length;const g=r.length;for(let l=0;l<g;l++)if(r.charCodeAt(l)===37&&l+2<g){const c=r.charCodeAt(l+1),h=r.charCodeAt(l+2);(c>=48&&c<=57||c>=65&&c<=70||c>=97&&c<=102)&&(h>=48&&h<=57||h>=65&&h<=70||h>=97&&h<=102)&&(f-=2,l+=2)}let w=0,u=g-1;const d=l=>l>=2&&r.charCodeAt(l-2)===37&&r.charCodeAt(l-1)===51&&(r.charCodeAt(l)===68||r.charCodeAt(l)===100);u>=0&&(r.charCodeAt(u)===61?(w++,u--):d(u)&&(w++,u-=3)),w===1&&u>=0&&(r.charCodeAt(u)===61||d(u))&&w++;const a=Math.floor(f/4)*3-(w||0);return a>0?a:0}if(typeof Buffer<"u"&&typeof Buffer.byteLength=="function")return Buffer.byteLength(r,"utf8");let m=0;for(let f=0,g=r.length;f<g;f++){const w=r.charCodeAt(f);if(w<128)m+=1;else if(w<2048)m+=2;else if(w>=55296&&w<=56319&&f+1<g){const u=r.charCodeAt(f+1);u>=56320&&u<=57343?(m+=4,f++):m+=3}else m+=3}return m}const sd="1.16.1",ly=64*1024,{isFunction:yc}=Ce,cy=(t,...n)=>{try{return!!t(...n)}catch{return!1}},q$=t=>{const n=Ce.global!==void 0&&Ce.global!==null?Ce.global:globalThis,{ReadableStream:e,TextEncoder:r}=n;t=Ce.merge.call({skipUndefined:!0},{Request:n.Request,Response:n.Response},t);const{fetch:m,Request:f,Response:g}=t,w=m?yc(m):typeof fetch=="function",u=yc(f),d=yc(g);if(!w)return!1;const a=w&&yc(e),l=w&&(typeof r=="function"?(b=>x=>b.encode(x))(new r):async b=>new Uint8Array(await new f(b).arrayBuffer())),c=u&&a&&cy(()=>{let b=!1;const x=new f(Ir.origin,{body:new e,method:"POST",get duplex(){return b=!0,"half"}}),M=x.headers.has("Content-Type");return x.body!=null&&x.body.cancel(),b&&!M}),h=d&&a&&cy(()=>Ce.isReadableStream(new g("").body)),o={stream:h&&(b=>b.body)};w&&["text","arrayBuffer","blob","formData","stream"].forEach(b=>{!o[b]&&(o[b]=(x,M)=>{let R=x&&x[b];if(R)return R.call(x);throw new nt(`Response type '${b}' is not supported`,nt.ERR_NOT_SUPPORT,M)})});const s=async b=>{if(b==null)return 0;if(Ce.isBlob(b))return b.size;if(Ce.isSpecCompliantForm(b))return(await new f(Ir.origin,{method:"POST",body:b}).arrayBuffer()).byteLength;if(Ce.isArrayBufferView(b)||Ce.isArrayBuffer(b))return b.byteLength;if(Ce.isURLSearchParams(b)&&(b=b+""),Ce.isString(b))return(await l(b)).byteLength},p=async(b,x)=>Ce.toFiniteNumber(b.getContentLength())??s(x);return async b=>{let{url:x,method:M,data:R,signal:k,cancelToken:C,timeout:L,onDownloadProgress:D,onUploadProgress:I,responseType:T,headers:W,withCredentials:F="same-origin",fetchOptions:O,maxContentLength:S,maxBodyLength:A}=sy(b);const N=Ce.isNumber(S)&&S>-1,B=Ce.isNumber(A)&&A>-1;let U=m||fetch;T=T?(T+"").toLowerCase():"text";let G=W$([k,C&&C.toAbortSignal()],L),J=null;const ne=G&&G.unsubscribe&&(()=>{G.unsubscribe()});let de;try{if(N&&typeof x=="string"&&x.startsWith("data:")&&V$(x)>S)throw new nt("maxContentLength size of "+S+" exceeded",nt.ERR_BAD_RESPONSE,b,J);if(B&&M!=="get"&&M!=="head"){const me=await p(W,R);if(typeof me=="number"&&isFinite(me)&&me>A)throw new nt("Request body larger than maxBodyLength limit",nt.ERR_BAD_REQUEST,b,J)}if(I&&c&&M!=="get"&&M!=="head"&&(de=await p(W,R))!==0){let me=new f(x,{method:"POST",body:R,duplex:"half"}),$e;if(Ce.isFormData(R)&&($e=me.headers.get("content-type"))&&W.setContentType($e),me.body){const[Ee,He]=ny(de,vc(ry(I)));R=ay(me.body,ly,Ee,He)}}Ce.isString(F)||(F=F?"include":"omit");const ee=u&&"credentials"in f.prototype;if(Ce.isFormData(R)){const me=W.getContentType();me&&/^multipart\/form-data/i.test(me)&&!/boundary=/i.test(me)&&W.delete("content-type")}W.set("User-Agent","axios/"+sd,!1);const se={...O,signal:G,method:M.toUpperCase(),headers:qv(W.normalize()),body:R,duplex:"half",credentials:ee?F:void 0};J=u&&new f(x,se);let ce=await(u?U(J,O):U(x,se));if(N){const me=Ce.toFiniteNumber(ce.headers.get("content-length"));if(me!=null&&me>S)throw new nt("maxContentLength size of "+S+" exceeded",nt.ERR_BAD_RESPONSE,b,J)}const le=h&&(T==="stream"||T==="response");if(h&&ce.body&&(D||N||le&&ne)){const me={};["status","statusText","headers"].forEach(Qe=>{me[Qe]=ce[Qe]});const $e=Ce.toFiniteNumber(ce.headers.get("content-length")),[Ee,He]=D&&ny($e,vc(ry(D),!0))||[];let Ue=0;const ot=Qe=>{if(N&&(Ue=Qe,Ue>S))throw new nt("maxContentLength size of "+S+" exceeded",nt.ERR_BAD_RESPONSE,b,J);Ee&&Ee(Qe)};ce=new g(ay(ce.body,ly,ot,()=>{He&&He(),ne&&ne()}),me)}T=T||"text";let pe=await o[Ce.findKey(o,T)||"text"](ce,b);if(N&&!h&&!le){let me;if(pe!=null&&(typeof pe.byteLength=="number"?me=pe.byteLength:typeof pe.size=="number"?me=pe.size:typeof pe=="string"&&(me=typeof r=="function"?new r().encode(pe).byteLength:pe.length)),typeof me=="number"&&me>S)throw new nt("maxContentLength size of "+S+" exceeded",nt.ERR_BAD_RESPONSE,b,J)}return!le&&ne&&ne(),await new Promise((me,$e)=>{ty(me,$e,{data:pe,headers:Vr.from(ce.headers),status:ce.status,statusText:ce.statusText,config:b,request:J})})}catch(ee){if(ne&&ne(),G&&G.aborted&&G.reason instanceof nt){const se=G.reason;throw se.config=b,J&&(se.request=J),ee!==se&&(se.cause=ee),se}throw ee&&ee.name==="TypeError"&&/Load failed|fetch/i.test(ee.message)?Object.assign(new nt("Network Error",nt.ERR_NETWORK,b,J,ee&&ee.response),{cause:ee.cause||ee}):nt.from(ee,ee&&ee.code,b,J,ee&&ee.response)}}},G$=new Map,uy=t=>{let n=t&&t.env||{};const{fetch:e,Request:r,Response:m}=n,f=[r,m,e];let g=f.length,w=g,u,d,a=G$;for(;w--;)u=f[w],d=a.get(u),d===void 0&&a.set(u,d=w?new Map:q$(n)),a=d;return d};uy();const ad={http:f$,xhr:B$,fetch:{get:uy}};Ce.forEach(ad,(t,n)=>{if(t){try{Object.defineProperty(t,"name",{__proto__:null,value:n})}catch{}Object.defineProperty(t,"adapterName",{__proto__:null,value:n})}});const hy=t=>`- ${t}`,K$=t=>Ce.isFunction(t)||t===null||t===!1;function Y$(t,n){t=Ce.isArray(t)?t:[t];const{length:e}=t;let r,m;const f={};for(let g=0;g<e;g++){r=t[g];let w;if(m=r,!K$(r)&&(m=ad[(w=String(r)).toLowerCase()],m===void 0))throw new nt(`Unknown adapter '${w}'`);if(m&&(Ce.isFunction(m)||(m=m.get(n))))break;f[w||"#"+g]=m}if(!m){const g=Object.entries(f).map(([u,d])=>`adapter ${u} `+(d===!1?"is not supported by the environment":"is not available in the build"));let w=e?g.length>1?`since :
1483
+ `+g.map(hy).join(`
1484
+ `):" "+hy(g[0]):"as no adapter specified";throw new nt("There is no suitable adapter to dispatch the request "+w,"ERR_NOT_SUPPORT")}return m}const dy={getAdapter:Y$,adapters:ad};function ld(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new ol(null,t)}function fy(t){return ld(t),t.headers=Vr.from(t.headers),t.data=od.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),dy.getAdapter(t.adapter||il.adapter,t)(t).then(function(n){ld(t),t.response=n;try{n.data=od.call(t,t.transformResponse,n)}finally{delete t.response}return n.headers=Vr.from(n.headers),n},function(n){if(!ey(n)&&(ld(t),n&&n.response)){t.response=n.response;try{n.response.data=od.call(t,t.transformResponse,n.response)}finally{delete t.response}n.response.headers=Vr.from(n.response.headers)}return Promise.reject(n)})}const bc={};["object","boolean","number","function","string","symbol"].forEach((t,n)=>{bc[t]=function(e){return typeof e===t||"a"+(n<1?"n ":" ")+t}});const py={};bc.transitional=function(t,n,e){function r(m,f){return"[Axios v"+sd+"] Transitional option '"+m+"'"+f+(e?". "+e:"")}return(m,f,g)=>{if(t===!1)throw new nt(r(f," has been removed"+(n?" in "+n:"")),nt.ERR_DEPRECATED);return n&&!py[f]&&(py[f]=!0,console.warn(r(f," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(m,f,g):!0}},bc.spelling=function(t){return(n,e)=>(console.warn(`${e} is likely a misspelling of ${t}`),!0)};function J$(t,n,e){if(typeof t!="object")throw new nt("options must be an object",nt.ERR_BAD_OPTION_VALUE);const r=Object.keys(t);let m=r.length;for(;m-- >0;){const f=r[m],g=Object.prototype.hasOwnProperty.call(n,f)?n[f]:void 0;if(g){const w=t[f],u=w===void 0||g(w,f,t);if(u!==!0)throw new nt("option "+f+" must be "+u,nt.ERR_BAD_OPTION_VALUE);continue}if(e!==!0)throw new nt("Unknown option "+f,nt.ERR_BAD_OPTION)}}const wc={assertOptions:J$,validators:bc},Li=wc.validators;let Rs=class{constructor(t){this.defaults=t||{},this.interceptors={request:new Xv,response:new Xv}}async request(t,n){try{return await this._request(t,n)}catch(e){if(e instanceof Error){let r={};Error.captureStackTrace?Error.captureStackTrace(r):r=new Error;const m=(()=>{if(!r.stack)return"";const f=r.stack.indexOf(`
1485
+ `);return f===-1?"":r.stack.slice(f+1)})();try{if(!e.stack)e.stack=m;else if(m){const f=m.indexOf(`
1486
+ `),g=f===-1?-1:m.indexOf(`
1487
+ `,f+1),w=g===-1?"":m.slice(g+1);String(e.stack).endsWith(w)||(e.stack+=`
1488
+ `+m)}}catch{}}throw e}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=$s(this.defaults,n);const{transitional:e,paramsSerializer:r,headers:m}=n;e!==void 0&&wc.assertOptions(e,{silentJSONParsing:Li.transitional(Li.boolean),forcedJSONParsing:Li.transitional(Li.boolean),clarifyTimeoutError:Li.transitional(Li.boolean),legacyInterceptorReqResOrdering:Li.transitional(Li.boolean)},!1),r!=null&&(Ce.isFunction(r)?n.paramsSerializer={serialize:r}:wc.assertOptions(r,{encode:Li.function,serialize:Li.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),wc.assertOptions(n,{baseUrl:Li.spelling("baseURL"),withXsrfToken:Li.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let f=m&&Ce.merge(m.common,m[n.method]);m&&Ce.forEach(["delete","get","head","post","put","patch","query","common"],h=>{delete m[h]}),n.headers=Vr.concat(f,m);const g=[];let w=!0;this.interceptors.request.forEach(function(h){if(typeof h.runWhen=="function"&&h.runWhen(n)===!1)return;w=w&&h.synchronous;const o=n.transitional||nd;o&&o.legacyInterceptorReqResOrdering?g.unshift(h.fulfilled,h.rejected):g.push(h.fulfilled,h.rejected)});const u=[];this.interceptors.response.forEach(function(h){u.push(h.fulfilled,h.rejected)});let d,a=0,l;if(!w){const h=[fy.bind(this),void 0];for(h.unshift(...g),h.push(...u),l=h.length,d=Promise.resolve(n);a<l;)d=d.then(h[a++],h[a++]);return d}l=g.length;let c=n;for(;a<l;){const h=g[a++],o=g[a++];try{c=h(c)}catch(s){o.call(this,s);break}}try{d=fy.call(this,c)}catch(h){return Promise.reject(h)}for(a=0,l=u.length;a<l;)d=d.then(u[a++],u[a++]);return d}getUri(t){t=$s(this.defaults,t);const n=iy(t.baseURL,t.url,t.allowAbsoluteUrls);return Zv(n,t.params,t.paramsSerializer)}};Ce.forEach(["delete","get","head","options"],function(t){Rs.prototype[t]=function(n,e){return this.request($s(e||{},{method:t,url:n,data:(e||{}).data}))}}),Ce.forEach(["post","put","patch","query"],function(t){function n(e){return function(r,m,f){return this.request($s(f||{},{method:t,headers:e?{"Content-Type":"multipart/form-data"}:{},url:r,data:m}))}}Rs.prototype[t]=n(),t!=="query"&&(Rs.prototype[t+"Form"]=n(!0))});let Z$=class ew{constructor(n){if(typeof n!="function")throw new TypeError("executor must be a function.");let e;this.promise=new Promise(function(m){e=m});const r=this;this.promise.then(m=>{if(!r._listeners)return;let f=r._listeners.length;for(;f-- >0;)r._listeners[f](m);r._listeners=null}),this.promise.then=m=>{let f;const g=new Promise(w=>{r.subscribe(w),f=w}).then(m);return g.cancel=function(){r.unsubscribe(f)},g},n(function(m,f,g){r.reason||(r.reason=new ol(m,f,g),e(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(n){if(this.reason){n(this.reason);return}this._listeners?this._listeners.push(n):this._listeners=[n]}unsubscribe(n){if(!this._listeners)return;const e=this._listeners.indexOf(n);e!==-1&&this._listeners.splice(e,1)}toAbortSignal(){const n=new AbortController,e=r=>{n.abort(r)};return this.subscribe(e),n.signal.unsubscribe=()=>this.unsubscribe(e),n.signal}static source(){let n;return{token:new ew(function(e){n=e}),cancel:n}}};function X$(t){return function(n){return t.apply(null,n)}}function Q$(t){return Ce.isObject(t)&&t.isAxiosError===!0}const cd={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(cd).forEach(([t,n])=>{cd[n]=t});function gy(t){const n=new Rs(t),e=Dv(Rs.prototype.request,n);return Ce.extend(e,Rs.prototype,n,{allOwnKeys:!0}),Ce.extend(e,n,null,{allOwnKeys:!0}),e.create=function(r){return gy($s(t,r))},e}const tr=On("A",gy(il));tr.Axios=Rs,tr.CanceledError=ol,tr.CancelToken=Z$,tr.isCancel=ey,tr.VERSION=sd,tr.toFormData=mc,tr.AxiosError=nt,tr.Cancel=tr.CanceledError,tr.all=function(t){return Promise.all(t)},tr.spread=X$,tr.isAxiosError=Q$,tr.mergeConfig=$s,tr.AxiosHeaders=Vr,tr.formToJSON=t=>Qv(Ce.isHTMLForm(t)?new FormData(t):t),tr.getAdapter=dy.getAdapter,tr.HttpStatusCode=cd,tr.default=tr;const{Axios:nD,AxiosError:rD,CanceledError:iD,isCancel:oD,CancelToken:sD,VERSION:aD,all:lD,Cancel:cD,isAxiosError:uD,spread:hD,toFormData:dD,AxiosHeaders:fD,HttpStatusCode:pD,formToJSON:gD,getAdapter:mD,mergeConfig:vD,create:yD}=tr;function my(){return Object.assign({},Js())}function eR(t,n,e){const r=Hr(t,e?.in);return r.setTime(r.getTime()+n*Vl),r}function tR(t,n){const e=()=>uo(n?.in,NaN),r=oR(t);let m;if(r.date){const u=sR(r.date,2);m=aR(u.restDateString,u.year)}if(!m||isNaN(+m))return e();const f=+m;let g=0,w;if(r.time&&(g=lR(r.time),isNaN(g)))return e();if(r.timezone){if(w=cR(r.timezone),isNaN(w))return e()}else{const u=new Date(f+g),d=Hr(0,n?.in);return d.setFullYear(u.getUTCFullYear(),u.getUTCMonth(),u.getUTCDate()),d.setHours(u.getUTCHours(),u.getUTCMinutes(),u.getUTCSeconds(),u.getUTCMilliseconds()),d}return Hr(f+g+w,n?.in)}const xc={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},nR=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,rR=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,iR=/^([+-])(\d{2})(?::?(\d{2}))?$/;function oR(t){const n={},e=t.split(xc.dateTimeDelimiter);let r;if(e.length>2)return n;if(/:/.test(e[0])?r=e[0]:(n.date=e[0],r=e[1],xc.timeZoneDelimiter.test(n.date)&&(n.date=t.split(xc.timeZoneDelimiter)[0],r=t.substr(n.date.length,t.length))),r){const m=xc.timezone.exec(r);m?(n.time=r.replace(m[1],""),n.timezone=m[1]):n.time=r}return n}function sR(t,n){const e=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+n)+"})|(\\d{2}|[+-]\\d{"+(2+n)+"})$)"),r=t.match(e);if(!r)return{year:NaN,restDateString:""};const m=r[1]?parseInt(r[1]):null,f=r[2]?parseInt(r[2]):null;return{year:f===null?m:f*100,restDateString:t.slice((r[1]||r[2]).length)}}function aR(t,n){if(n===null)return new Date(NaN);const e=t.match(nR);if(!e)return new Date(NaN);const r=!!e[4],m=sl(e[1]),f=sl(e[2])-1,g=sl(e[3]),w=sl(e[4]),u=sl(e[5])-1;if(r)return pR(n,w,u)?uR(n,w,u):new Date(NaN);{const d=new Date(0);return!dR(n,f,g)||!fR(n,m)?new Date(NaN):(d.setUTCFullYear(n,f,Math.max(m,g)),d)}}function sl(t){return t?parseInt(t):1}function lR(t){const n=t.match(rR);if(!n)return NaN;const e=ud(n[1]),r=ud(n[2]),m=ud(n[3]);return gR(e,r,m)?e*Du+r*Vl+m*1e3:NaN}function ud(t){return t&&parseFloat(t.replace(",","."))||0}function cR(t){if(t==="Z")return 0;const n=t.match(iR);if(!n)return 0;const e=n[1]==="+"?-1:1,r=parseInt(n[2]),m=n[3]&&parseInt(n[3])||0;return mR(r,m)?e*(r*Du+m*Vl):NaN}function uR(t,n,e){const r=new Date(0);r.setUTCFullYear(t,0,4);const m=r.getUTCDay()||7,f=(n-1)*7+e+1-m;return r.setUTCDate(r.getUTCDate()+f),r}const hR=[31,null,31,30,31,30,31,31,30,31,30,31];function vy(t){return t%400===0||t%4===0&&t%100!==0}function dR(t,n,e){return n>=0&&n<=11&&e>=1&&e<=(hR[n]||(vy(t)?29:28))}function fR(t,n){return n>=1&&n<=(vy(t)?366:365)}function pR(t,n,e){return n>=1&&n<=53&&e>=0&&e<=6}function gR(t,n,e){return t===24?n===0&&e===0:e>=0&&e<60&&n>=0&&n<60&&t>=0&&t<25}function mR(t,n){return n>=0&&n<=59}function vR(t,n,e){return eR(t,-n,e)}function yy(t,n,e){const r=my(),m=wR(t,e.timeZone,e.locale??r.locale);return"formatToParts"in m?yR(m,n):bR(m,n)}function yR(t,n){const e=t.formatToParts(n);for(let r=e.length-1;r>=0;--r)if(e[r].type==="timeZoneName")return e[r].value}function bR(t,n){const e=t.format(n).replace(/\u200E/g,""),r=/ [\w-+ ]+$/.exec(e);return r?r[0].substr(1):""}function wR(t,n,e){return new Intl.DateTimeFormat(e?[e.code,"en-US"]:void 0,{timeZone:n,timeZoneName:t})}function xR(t,n){const e=SR(n);return"formatToParts"in e?AR(e,t):_R(e,t)}const CR={year:0,month:1,day:2,hour:3,minute:4,second:5};function AR(t,n){try{const e=t.formatToParts(n),r=[];for(let m=0;m<e.length;m++){const f=CR[e[m].type];f!==void 0&&(r[f]=parseInt(e[m].value,10))}return r}catch(e){if(e instanceof RangeError)return[NaN];throw e}}function _R(t,n){const e=t.format(n),r=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(e);return[parseInt(r[3],10),parseInt(r[1],10),parseInt(r[2],10),parseInt(r[4],10),parseInt(r[5],10),parseInt(r[6],10)]}const hd={},by=new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:"America/New_York",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}).format(new Date("2014-06-25T04:00:00.123Z")),kR=by==="06/25/2014, 00:00:00"||by==="‎06‎/‎25‎/‎2014‎ ‎00‎:‎00‎:‎00";function SR(t){return hd[t]||(hd[t]=kR?new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:t,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})),hd[t]}function wy(t,n,e,r,m,f,g){const w=new Date(0);return w.setUTCFullYear(t,n,e),w.setUTCHours(r,m,f,g),w}const xy=36e5,$R=6e4,dd={timezoneZ:/^(Z)$/,timezoneHH:/^([+-]\d{2})$/,timezoneHHMM:/^([+-])(\d{2}):?(\d{2})$/};function fd(t,n,e){if(!t)return 0;let r=dd.timezoneZ.exec(t);if(r)return 0;let m,f;if(r=dd.timezoneHH.exec(t),r)return m=parseInt(r[1],10),Cy(m)?-(m*xy):NaN;if(r=dd.timezoneHHMM.exec(t),r){m=parseInt(r[2],10);const g=parseInt(r[3],10);return Cy(m,g)?(f=Math.abs(m)*xy+g*$R,r[1]==="+"?-f:f):NaN}if(TR(t)){n=new Date(n||Date.now());const g=e?n:RR(n),w=pd(g,t);return-(e?w:ER(n,w,t))}return NaN}function RR(t){return wy(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds())}function pd(t,n){const e=xR(t,n),r=wy(e[0],e[1]-1,e[2],e[3]%24,e[4],e[5],0).getTime();let m=t.getTime();const f=m%1e3;return m-=f>=0?f:1e3+f,r-m}function ER(t,n,e){let r=t.getTime()-n;const m=pd(new Date(r),e);if(n===m)return n;r-=m-n;const f=pd(new Date(r),e);return m===f?m:Math.max(m,f)}function Cy(t,n){return-23<=t&&t<=23&&(n==null||0<=n&&n<=59)}const Ay={};function TR(t){if(Ay[t])return!0;try{return new Intl.DateTimeFormat(void 0,{timeZone:t}),Ay[t]=!0,!0}catch{return!1}}const MR=60*1e3,IR={X:function(t,n,e){const r=gd(e.timeZone,t);if(r===0)return"Z";switch(n){case"X":return _y(r);case"XXXX":case"XX":return da(r);default:return da(r,":")}},x:function(t,n,e){const r=gd(e.timeZone,t);switch(n){case"x":return _y(r);case"xxxx":case"xx":return da(r);default:return da(r,":")}},O:function(t,n,e){const r=gd(e.timeZone,t);switch(n){case"O":case"OO":case"OOO":return"GMT"+LR(r,":");default:return"GMT"+da(r,":")}},z:function(t,n,e){switch(n){case"z":case"zz":case"zzz":return yy("short",t,e);default:return yy("long",t,e)}}};function gd(t,n){const e=t?fd(t,n,!0)/MR:n?.getTimezoneOffset()??0;if(Number.isNaN(e))throw new RangeError("Invalid time zone specified: "+t);return e}function Cc(t,n){const e=t<0?"-":"";let r=Math.abs(t).toString();for(;r.length<n;)r="0"+r;return e+r}function da(t,n=""){const e=t>0?"-":"+",r=Math.abs(t),m=Cc(Math.floor(r/60),2),f=Cc(Math.floor(r%60),2);return e+m+n+f}function _y(t,n){return t%60===0?(t>0?"-":"+")+Cc(Math.abs(t)/60,2):da(t,n)}function LR(t,n=""){const e=t>0?"-":"+",r=Math.abs(t),m=Math.floor(r/60),f=r%60;return f===0?e+String(m):e+String(m)+n+Cc(f,2)}function ky(t){const n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+t-+n}const OR=/(Z|[+-]\d{2}(?::?\d{2})?| UTC| [a-zA-Z]+\/[a-zA-Z_]+(?:\/[a-zA-Z_]+)?)$/,md=36e5,Sy=6e4,NR=2,qr={dateTimePattern:/^([0-9W+-]+)(T| )(.*)/,datePattern:/^([0-9W+-]+)(.*)/,YY:/^(\d{2})$/,YYY:[/^([+-]\d{2})$/,/^([+-]\d{3})$/,/^([+-]\d{4})$/],YYYY:/^(\d{4})/,YYYYY:[/^([+-]\d{4})/,/^([+-]\d{5})/,/^([+-]\d{6})/],MM:/^-(\d{2})$/,DDD:/^-?(\d{3})$/,MMDD:/^-?(\d{2})-?(\d{2})$/,Www:/^-?W(\d{2})$/,WwwD:/^-?W(\d{2})-?(\d{1})$/,HH:/^(\d{2}([.,]\d*)?)$/,HHMM:/^(\d{2}):?(\d{2}([.,]\d*)?)$/,HHMMSS:/^(\d{2}):?(\d{2}):?(\d{2}([.,]\d*)?)$/,timeZone:OR};function $y(t,n={}){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");if(t===null)return new Date(NaN);const e=n.additionalDigits==null?NR:Number(n.additionalDigits);if(e!==2&&e!==1&&e!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(t instanceof Date||typeof t=="object"&&Object.prototype.toString.call(t)==="[object Date]")return new Date(t.getTime());if(typeof t=="number"||Object.prototype.toString.call(t)==="[object Number]")return new Date(t);if(Object.prototype.toString.call(t)!=="[object String]")return new Date(NaN);const r=DR(t),{year:m,restDateString:f}=PR(r.date,e),g=FR(f,m);if(g===null||isNaN(g.getTime()))return new Date(NaN);if(g){const w=g.getTime();let u=0,d;if(r.time&&(u=zR(r.time),u===null||isNaN(u)))return new Date(NaN);if(r.timeZone||n.timeZone){if(d=fd(r.timeZone||n.timeZone,new Date(w+u)),isNaN(d))return new Date(NaN)}else d=ky(new Date(w+u)),d=ky(new Date(w+u+d));return new Date(w+u+d)}else return new Date(NaN)}function DR(t){const n={};let e=qr.dateTimePattern.exec(t),r;if(e?(n.date=e[1],r=e[3]):(e=qr.datePattern.exec(t),e?(n.date=e[1],r=e[2]):(n.date=null,r=t)),r){const m=qr.timeZone.exec(r);m?(n.time=r.replace(m[1],""),n.timeZone=m[1].trim()):n.time=r}return n}function PR(t,n){if(t){const e=qr.YYY[n],r=qr.YYYYY[n];let m=qr.YYYY.exec(t)||r.exec(t);if(m){const f=m[1];return{year:parseInt(f,10),restDateString:t.slice(f.length)}}if(m=qr.YY.exec(t)||e.exec(t),m){const f=m[1];return{year:parseInt(f,10)*100,restDateString:t.slice(f.length)}}}return{year:null}}function FR(t,n){if(n===null)return null;let e,r,m;if(!t||!t.length)return e=new Date(0),e.setUTCFullYear(n),e;let f=qr.MM.exec(t);if(f)return e=new Date(0),r=parseInt(f[1],10)-1,Ty(n,r)?(e.setUTCFullYear(n,r),e):new Date(NaN);if(f=qr.DDD.exec(t),f){e=new Date(0);const g=parseInt(f[1],10);return jR(n,g)?(e.setUTCFullYear(n,0,g),e):new Date(NaN)}if(f=qr.MMDD.exec(t),f){e=new Date(0),r=parseInt(f[1],10)-1;const g=parseInt(f[2],10);return Ty(n,r,g)?(e.setUTCFullYear(n,r,g),e):new Date(NaN)}if(f=qr.Www.exec(t),f)return m=parseInt(f[1],10)-1,My(m)?Ry(n,m):new Date(NaN);if(f=qr.WwwD.exec(t),f){m=parseInt(f[1],10)-1;const g=parseInt(f[2],10)-1;return My(m,g)?Ry(n,m,g):new Date(NaN)}return null}function zR(t){let n,e,r=qr.HH.exec(t);if(r)return n=parseFloat(r[1].replace(",",".")),vd(n)?n%24*md:NaN;if(r=qr.HHMM.exec(t),r)return n=parseInt(r[1],10),e=parseFloat(r[2].replace(",",".")),vd(n,e)?n%24*md+e*Sy:NaN;if(r=qr.HHMMSS.exec(t),r){n=parseInt(r[1],10),e=parseInt(r[2],10);const m=parseFloat(r[3].replace(",","."));return vd(n,e,m)?n%24*md+e*Sy+m*1e3:NaN}return null}function Ry(t,n,e){n=n||0,e=e||0;const r=new Date(0);r.setUTCFullYear(t,0,4);const m=r.getUTCDay()||7,f=n*7+e+1-m;return r.setUTCDate(r.getUTCDate()+f),r}const BR=[31,28,31,30,31,30,31,31,30,31,30,31],WR=[31,29,31,30,31,30,31,31,30,31,30,31];function Ey(t){return t%400===0||t%4===0&&t%100!==0}function Ty(t,n,e){if(n<0||n>11)return!1;if(e!=null){if(e<1)return!1;const r=Ey(t);if(r&&e>WR[n]||!r&&e>BR[n])return!1}return!0}function jR(t,n){if(n<1)return!1;const e=Ey(t);return!(e&&n>366||!e&&n>365)}function My(t,n){return!(t<0||t>52||n!=null&&(n<0||n>6))}function vd(t,n,e){return!(t<0||t>=25||n!=null&&(n<0||n>=60)||e!=null&&(e<0||e>=60))}const HR=/([xXOz]+)|''|'(''|[^'])+('|$)/g;function UR(t,n,e={}){n=String(n);const r=n.match(HR);if(r){const m=$y(e.originalDate||t,e);n=r.reduce(function(f,g){if(g[0]==="'")return f;const w=f.indexOf(g),u=f[w-1]==="'",d=f.replace(g,"'"+IR[g[0]](m,g,e)+"'");return u?d.substring(0,w-1)+d.substring(w+1):d},n)}return bs(t,n,e)}function VR(t,n,e){t=$y(t,e);const r=fd(n,t,!0),m=new Date(t.getTime()-r),f=new Date(0);return f.setFullYear(m.getUTCFullYear(),m.getUTCMonth(),m.getUTCDate()),f.setHours(m.getUTCHours(),m.getUTCMinutes(),m.getUTCSeconds(),m.getUTCMilliseconds()),f}function Ac(t,n,e,r){return r={...r,timeZone:n,originalDate:t},UR(VR(t,n,{timeZone:r.timeZone}),e,r)}const _c="yyyy-MM-dd",Iy="HH:mm:ss.SSS",Ly="HH:mm:ss",kc=`${_c} ${Iy}`,Oy=`${_c} ${Ly}`,bD=On("R",{methods:{parseDateTime(t,n){return t.includes(" ")&&(t=t.replace(" ","T")),n&&n==="UTC"&&(t+="Z"),Date.parse(t)},formatUtcToLocal(t,n){return bs(!n||n==="local"?vR(t,t.getTimezoneOffset()):t,kc)},formatDateTime(t,n){return!n||n==="local"?bs(t,kc):Ac(t,n,kc)},formatDateTimeHMS(t,n){return!n||n==="local"?bs(t,Oy):Ac(t,n,Oy)},formatDate:function(t,n){return!n||n==="local"?bs(t,_c):Ac(t,this.timeZone,_c)},formatTime:function(t,n,e=Iy){return!n||n==="local"?bs(t,e):Ac(t,this.timeZone,e)},formatTimeHMS:function(t,n){return this.formatTime(t,n,Ly)},formatTimestamp(t,n){return this.formatDateTime(tR(t),n)},formatSeconds(t,n){return this.formatDateTime(new Date(t*1e3),n)},formatNanoseconds(t,n){return this.formatDateTime(new Date(parseInt(t)/1e6),n)}}}),Ny=100,Dy=On("e",Pf("app",{state:()=>({notifyHistory:[],namedWidgets:{},playback:{playbackMode:null,playbackDateTime:null,playbackStep:1,playbackLoading:0}}),getters:{namedWidget:t=>n=>t.namedWidgets[n]},actions:{notifyAddHistory(t){this.notifyHistory.length>=Ny&&(this.notifyHistory.length=Ny-1),this.notifyHistory.unshift(t)},notifyClearHistory(){this.notifyHistory=[]},setNamedWidget(t){Object.assign(this.namedWidgets,t)},clearNamedWidget(t){delete this.namedWidgets[t]},updatePlayback(t){Object.assign(this.playback,t)}}})),fa=Ff();fa.use(({store:t})=>{t.commit=(n,e)=>{typeof t[n]=="function"&&t[n](e)},t.dispatch=(n,e)=>{if(typeof t[n]=="function")return t[n](e)}});const qR=fa.install.bind(fa);fa.install=t=>{qR(t);const n=Dy(fa);t.config.globalProperties.$store={state:new Proxy({},{get(e,r){return n.$state}}),getters:new Proxy({},{get(e,r){if(r.includes("/")){const[,m]=r.split("/");return n[m]}return n[r]}}),commit(e,r){if(e.includes("/")){const[,m]=e.split("/");n[m]?.(r)}else n[e]?.(r)},dispatch(e,r){if(e.includes("/")){const[,m]=e.split("/");return n[m]?.(r)}else return n[e]?.(r)}}};const GR="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOAAAAAgCAYAAAALxXRVAAAAxHpUWHRSYXcgcHJvZmlsZSB0eXBlIGV4aWYAAHjabVDbDcMwCPxnio5gc8TB4zhtKnWDjl8IJEranmReh84Are/Xk24OrkIyzdp6a8UgXToPC7QExmZrkc1uWJOy/FIn3gm2EswjUm3Zv9frIRBuWDSdhPSexHIluqS+fgnlz/CJPH6kUE8hcBA1BUasVVrX+bzCcuyW0HjkRvQ69k8+2/Uek/0D5hUVxSwgMQD8gTAsaGYBb6zmhxFeEWiK2UH+3WkHfQAmGFlDwtBoyQAAAYVpQ0NQSUNDIHByb2ZpbGUAAHicfZE9SMNQFIVPW7UiFRE7iIhkqE7WQUUcaxWKUCHUCq06mLz0D5o0JCkujoJrwcGfxaqDi7OuDq6CIPgD4uripOgiJd6XFFrEeOHxPs675/DefYC/Xmaq2REDVM0yUom4kMmuCsFXdGEE/fBhQmKmPieKSXjW1z31Ud1FeZZ335/Vq+RMBvgE4hjTDYt4g3hm09I57xOHWVFSiM+Jxw26IPEj12WX3zgXHPbzzLCRTs0Th4mFQhvLbcyKhko8TRxRVI3y/RmXFc5bnNVylTXvyV8Yymkry1ynNYwEFrEEEQJkVFFCGRaitGukmEjRedzDP+T4RXLJ5CqBkWMBFaiQHD/4H/yerZmfmnSTQnGg88W2P0aB4C7QqNn297FtN06AwDNwpbX8lTow+0l6raVFjoC+beDiuqXJe8DlDjD4pEuG5EgBWv58Hng/o2/KAgO3QM+aO7fmOU4fgDTNKnkDHBwCYwXKXvd4d3f73P7tac7vB5UicrQ0WLbfAAANemlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4KPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iWE1QIENvcmUgNC40LjAtRXhpdjIiPgogPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4KICA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIgogICAgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iCiAgICB4bWxuczpzdEV2dD0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL3NUeXBlL1Jlc291cmNlRXZlbnQjIgogICAgeG1sbnM6R0lNUD0iaHR0cDovL3d3dy5naW1wLm9yZy94bXAvIgogICAgeG1sbnM6ZGM9Imh0dHA6Ly9wdXJsLm9yZy9kYy9lbGVtZW50cy8xLjEvIgogICAgeG1sbnM6dGlmZj0iaHR0cDovL25zLmFkb2JlLmNvbS90aWZmLzEuMC8iCiAgICB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iCiAgIHhtcE1NOkRvY3VtZW50SUQ9ImdpbXA6ZG9jaWQ6Z2ltcDozYjNlMzQ0NC03YTU4LTQxYjItYTZjYi0wMzljNWI3NjRmN2IiCiAgIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MGUxZjUyNzQtNTMyNC00MzE5LWE3MjYtOGQyNjJlNjI1Y2YwIgogICB4bXBNTTpPcmlnaW5hbERvY3VtZW50SUQ9InhtcC5kaWQ6ZDkzZGI3ODgtMmQwNi00NjdhLWI2OGItZWJlNmJiNGU1ODQ2IgogICBHSU1QOkFQST0iMi4wIgogICBHSU1QOlBsYXRmb3JtPSJNYWMgT1MiCiAgIEdJTVA6VGltZVN0YW1wPSIxNjg4MTUzMjA5MTAxNDUxIgogICBHSU1QOlZlcnNpb249IjIuMTAuMzQiCiAgIGRjOkZvcm1hdD0iaW1hZ2UvcG5nIgogICB0aWZmOk9yaWVudGF0aW9uPSIxIgogICB4bXA6Q3JlYXRvclRvb2w9IkdJTVAgMi4xMCIKICAgeG1wOk1ldGFkYXRhRGF0ZT0iMjAyMzowNjozMFQxMzoyNjo0OC0wNjowMCIKICAgeG1wOk1vZGlmeURhdGU9IjIwMjM6MDY6MzBUMTM6MjY6NDgtMDY6MDAiPgogICA8eG1wTU06SGlzdG9yeT4KICAgIDxyZGY6U2VxPgogICAgIDxyZGY6bGkKICAgICAgc3RFdnQ6YWN0aW9uPSJzYXZlZCIKICAgICAgc3RFdnQ6Y2hhbmdlZD0iLyIKICAgICAgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDozNWQ3MTYyZi0xYWQ1LTQwNWUtODAxOS03NmExMTI4MDI1YmYiCiAgICAgIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkdpbXAgMi4xMCAoTWFjIE9TKSIKICAgICAgc3RFdnQ6d2hlbj0iMjAyMy0wNi0zMFQxMzoyNjo0OS0wNjowMCIvPgogICAgPC9yZGY6U2VxPgogICA8L3htcE1NOkhpc3Rvcnk+CiAgPC9yZGY6RGVzY3JpcHRpb24+CiA8L3JkZjpSREY+CjwveDp4bXBtZXRhPgogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgCjw/eHBhY2tldCBlbmQ9InciPz5gv8dKAAAABmJLR0QA9QAHANj00CgxAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH5wYeExoxB4CzXgAAB65JREFUeNrtnF9sFNcVh78z6z8kEwgPTUVxTZqYh2lVbAKVKleuiuEJkGzIAzFSpEQukaoqQUUhiUiLSkRD2hQ1FYmqqnEtUqUK7UPBVozUBzBpUHkproGXrVqXAoKgKg/EZKFre+f0YcftFs967/zz7rrze5y999yd2fn2d8+9ZwZSpUqVKlWqVKmMpb9vcvT9zB90xF6RXo1UYWWllyAcfEzPjKL6ddy7oymEqcJKTBvmmrN7gR8bNt9v550fLG74KIUui3Vft2zN3Ywaf+bm1zTJ79+w4o8Stu/OO7ToNNsUtgJtqqwEEOEGMCEwIo2ceO9+rifx3TvGtdUt0CuwBaVNxRtfuYEwoXDSyjB0Ya1cW1QABoQvEoTa2XkG1W8kc7bygZw7tyFm+GKFsBYB3HmHFneKAyr0oxVmTYIryqDVxIG4QHxsTFcWXF5R2GV4Uw9kLL7/53Vyo+6noCHhAziYa85+L3CvTOZAYmcbIXYF+ACcxTgd7ZukpzBFVmFXRfgAFEthV2GKbN8kPVHHbx/TnhnXG9/0t4JdMy7Z9jHtqWsAI8AXGkI5e/YMIh8k4n5nz55JCL5FCWHfJ+x2lePAAyG6P+Aqx/s+YXfY8dec12fVZQhYGqL7UnUZWnNen61LAGOAL7wTJuGCIWMGgG9RQdg3SY8Lbxi53jxu6MIbYZywfUx7UN6MnrTzZi07oZSBbx9w6J7DN4BXgU7gyTLx3gXOAd+FYoJcopftvPNaVXLBkLlfCPgi54S1kAPuvENLYYpsSOfz06eZJhzTnPCxMV0545It43y3LTgsGYaXN/E3gFtTrNYCPS7sLdenwcKJIye8fPIpe3Sy90WBXkXbihDJhMJQ97Kh1x/Z8k4uEoBlnO8ysAX4C7AK+Caw3we+Q16bNmAUaAm7MKNdXRuYmRmN565r6A46/YwIX2gIawHAJ27xdpCcy3Rh5DfLecbI/f6kvuOLcFoyPF1ulbNjXFu1wFFVNvqNf/Er8kyUcxj87e82UtBB4OEyTa6Qkf7+HY+fjgKg3w1wyIPHzTVnLe9f5vkSCI8D+4C/em3EA/anwOrSQHbeMV6Fi8UFQ7hfTPCFgrDaAO68Q0thmquRpp7+d5qbaWRVJRfsGNdWd4arfvBdXC+bjAA+r6f8ILQaWBV2i8KD75RZuiObTCE0vciPAl/INWfFzjsuMAn8HPgOcB14ZRY+r/3ngM97brngeVuUGDHDV3c5oU6zLXb4vHxQp9lWqZlboNdvCikZnjZmvdj2tmFso2mn53xmKujg5ZNP2XEC2Af0z86v7byjwEcehF3ApVn4cs3Z5cCPvM+aIv1pRl0RDbjymQB8dQeht8letdhSnDnde5MeDuJcF9bKNQsOm8Q20ehk74vzTDv99LDXJzYA8RZWDuaas0tKIJwGrpbA91ngW/Ms0iysCwbomyB89QZhW1Vj69w2kmE48H+vXx8Nd25CcOc07RN0qrEb+FmuOdvkQeiWwLfEc8nX4vzFQrtg0H2/6cIvEoTvvxDqv16taQfUOavXCxp7trysVLOrnUHk18cvtplza1tSfcLM9RuBh8os6Ewn8suFccGgfWTJDiCb6N0t8uE/rCd3kypVSADfBfbYeee653rirYpi5527wCDF1dB479ugLhii6kW25m5i3dedGIRF+DYH3SdaaHmF1VWLLTq3za2p/11JN5FfH7/YZtNJmUiqTxAA9wHP23nn45JjnwEe9bYdAG4BR5OAMJCjhcwbE4OwTuDzNFHV2DK3jRaCV9L49pFw56YwlFQfUwB/CPzazjv/nD3g5Xw/AY4Aa7wtCrXzzk3gV8DmqrhghJrPRCCsL/gQGKlmbIWT9x5zYW/HuLaajtMxrq1eVUzF2CbqXjb0OnAlQJcrXp/YAPzQzjvXSuB7CHib4mrnZor7gF8tccKPKO4FLrwLxrB3GBuEdQYfgDRyAsFNgD5XGjlR8YbM+DrHUi1wNID7HcWnJK1M7Ip6ZMs7OTLSb36fSr/pb+4H4As+xwZzzdkvefDZFCtgSrcatgEvAV/2IFwNHPSJsz9RF4zofrFCWIfwAbx3P9dFGYydP2XQpBb0wlq5JjAwByplY/t5PTWfE3aMa2u5KhiBgSgP6vbvePw0GdlUwQmvBKmC8b7XXM1TjP1t4IuU32o4Afyd4sZ9pGLssv9u89WIhqj5rDjeiL0C9+4o4CwEfGkx9v95MXYJhHE9jgQxv6LCt0Y04tPusUEY0flq5Yn4vkl6XOV45LI0wbWE7ceWBdtMbx/THu9ZwOjua9F7cZ0MU4Mqe3HtvHO4zHS0qvCVzfMSfJLeeDpap9NOPx1bxrAFeyLlg4JrwZ6g8AFcXCfDCM/FkHs+V6vwVVyEiQHCRF7ONCcXjDH3Cw3hIoLvPxA+yBFL2A58GmbaaQnbjz3IkbDjX1ovb4lFLz6F1Qa6LRa9l9bLW7V8jStOLyJAmOyb0UodL8n3yJhAuAjhK3XCTBOOwICRGwquwECmCSeM8/k5YYPljW+eVw00WDi17HwVc8CIOeGCvJZQOzvPACSV+xnlhDHDl76WsLwW42sJ61ra1bVBu7o2VGXsEXuFvp/5pelzX6lSpUqVKlWqVKlSpUpVA/o34/Ptc3zCsREAAAAASUVORK5CYII=",KR={props:{status:{type:String,required:!0},large:{type:Boolean},small:{type:Boolean},scale:{type:Number,default:1}},computed:{icons:function(){return GR},scaleFactor:function(){return this.scale?this.scale:this.large?1:this.small?.3:.5},iconStyle:function(){const t=tE.indexOf(Py[this.status]),n=1-(t-1)*.05,e=224*this.scaleFactor*n,r=32*this.scaleFactor*n,m=32*this.scaleFactor*n;return[`background-image: url(${this.icons});`,`background-position-x: -${t*m}px;`,`background-size: ${e}px ${r}px;`,`height: ${m}px;`,`width: ${m}px;`,`padding-top: ${t-1}px;`].join("")}}};function YR(t,n,e,r,m,f){return Nn(),ti("div",{style:Ia(f.iconStyle)},null,4)}const JR=Vo(KR,[["render",YR]]),ZR={props:{icon:{type:String,default:null},size:{type:String,default:"small"},color:{type:String,default:"white"}},computed:{colorStyle:function(){return{"--iconColor":this.color}}}};function XR(t,n,e,r,m,f){const g=St("rux-icon");return Nn(),co(g,{size:e.size,icon:e.icon,style:Ia(f.colorStyle)},null,8,["size","icon","style"])}const QR=Vo(ZR,[["render",XR],["__scopeId","data-v-bb4cd487"]]),Py={fatal:"critical",FATAL:"critical",error:"critical",ERROR:"critical",warn:"caution",WARN:"caution",info:"normal",INFO:"normal",debug:"off",DEBUG:"off",critical:"critical",CRITICAL:"critical",serious:"serious",SERIOUS:"serious",caution:"caution",CAUTION:"caution",normal:"normal",NORMAL:"normal",standby:"standby",STANDBY:"standby",off:"off",OFF:"OFF"},yd={fatal:"#ff69B4",critical:"#ff3838",serious:"#ffb302",caution:"#fce83a",normal:"#56f000",standby:"#2dccff",off:"#a4abb6"},eE=function(t){const n="#000000",e="#ffffff",r=yd[Py[t]];if(r){const m=+`0x${r.slice(1,3)}`,f=+`0x${r.slice(3,5)}`,g=+`0x${r.slice(5,7)}`;if((m*299+f*587+g*114)/1e3>128)return n}return e},tE=Object.keys(yd),nE={astro:{component:t=>Us(QR,{...t})},"astro-status":{component:t=>Us(JR,{...t,status:t.icon})}},rE={extras:{component:t=>Us(vw,{...t})}},wD=On("k",{data:{configKey:"",dontSaveDefaultConfig:!1},methods:{loadDefaultConfig:function(){return localStorage[`${this.configKey}__default`]?JSON.parse(localStorage[`${this.configKey}__default`]):{}},saveDefaultConfig:function(t){this.dontSaveDefaultConfig!==!0&&(localStorage[`${this.configKey}__default`]=JSON.stringify(t))},openConfigBase:function(t,n=!1,e=null){new vs().load_config(this.configKey,t).then(r=>{r?(this.$notify.normal({title:"Loading configuration",body:t}),e&&e(JSON.parse(r)),n||this.$route.fullPath.includes(t)||this.$router.push({query:{config:t}})):this.$notify.caution({title:"Unknown configuration",body:t})}).catch(r=>{r&&this.$notify.serious({title:`Error opening configuration: ${t}`,body:r})})},saveConfigBase:function(t,n){new vs().save_config(this.configKey,t,JSON.stringify(n)).then(()=>{this.$notify.normal({title:"Saved configuration",body:t})}).catch(e=>{e&&this.$notify.serious({title:`Error saving configuration: ${t}`,body:e})})},resetConfigBase:function(){localStorage.removeItem(`${this.configKey}__default`);const t={...this.$route.query};delete t.config,this.$router.replace({query:t})}}}),iE={props:{configKey:{type:String,default:null},modelValue:Boolean},emits:["update:modelValue","warning","success"],data(){return{configs:[],headers:[{title:"Configuration",value:"config"},{title:"Actions",value:"actions",align:"end",sortable:!1}],search:null,selectedRows:[]}},computed:{selectedItem:function(){return this.selectedRows.length?this.configs.find(t=>t.configId===this.selectedRows[0]):null},error:function(){return this.selectedItem===""||this.selectedItem===null?"Must select a config":null},show:{get(){return this.modelValue},set(t){this.$emit("update:modelValue",t)}}},mounted(){let t=-1;new vs().list_configs(this.configKey).then(n=>{this.configs=n.map(e=>(t+=1,{configId:t,config:e}))}).catch(n=>{this.$emit("warning",`Failed to connect to OpenC3. ${n}`)})},methods:{selectRow:function(t){this.selectedRows=[t.item.configId]},success:function(){this.selectedItem&&(this.$emit("success",this.selectedItem.config),this.show=!1,this.search=null,this.selectedRows=[])},cancel:function(){this.show=!1,this.search=null,this.selectedRows=[]},deleteConfig:function(t){this.$dialog.confirm(`Are you sure you want to delete: ${t.config}`,{okText:"Delete",cancelText:"Cancel"}).then(n=>{this.selectedItem?.config===t.config&&(this.selectedRows=[]),this.configs.splice(this.configs.indexOf(t),1),new vs().delete_config(this.configKey,t.config)}).catch(n=>{n!==!0&&this.$emit("warning",`Failed to delete config ${t.config} Error: ${n}`)})}}},oE={class:"mt-4 pa-3"},sE=["textContent"];function aE(t,n,e,r,m,f){const g=St("v-spacer"),w=St("v-toolbar"),u=St("v-text-field"),d=St("v-row"),a=St("v-btn"),l=St("v-data-table"),c=St("v-card-text"),h=St("v-card-actions"),o=St("v-card"),s=St("v-dialog");return Nn(),co(s,{modelValue:f.show,"onUpdate:modelValue":n[4]||(n[4]=p=>f.show=p),persistent:"",width:"600",onKeydown:Sl(f.cancel,["esc"])},{default:Pt(()=>[dt(o,null,{default:Pt(()=>[mr("form",{onSubmit:n[3]||(n[3]=Vs((...p)=>f.success&&f.success(...p),["prevent"]))},[dt(w,{height:"24"},{default:Pt(()=>[dt(g),n[5]||(n[5]=mr("span",null,"Open Configuration",-1)),dt(g)]),_:1}),dt(c,null,{default:Pt(()=>[mr("div",oE,[dt(d,{dense:""},{default:Pt(()=>[dt(u,{modelValue:m.search,"onUpdate:modelValue":n[0]||(n[0]=p=>m.search=p),label:"Search",type:"text","prepend-inner-icon":"mdi-magnify",clearable:"",variant:"outlined",density:"compact","clear-icon":"mdi-close-circle-outline",autofocus:"","single-line":"","hide-details":"","data-test":"search"},null,8,["modelValue"])]),_:1}),dt(l,{modelValue:m.selectedRows,"onUpdate:modelValue":n[1]||(n[1]=p=>m.selectedRows=p),"show-select":"","select-strategy":"single","item-value":"configId",search:m.search,headers:m.headers,items:m.configs,"items-per-page":5,"items-per-page-options":[5],"onClick:row":n[2]||(n[2]=(p,b)=>f.selectRow(b))},{"item.actions":Pt(({item:p})=>[dt(a,{class:"mt-1",icon:"mdi-delete",variant:"text","data-test":"item-delete",onClick:b=>f.deleteConfig(p)},null,8,["onClick"])]),_:1},8,["modelValue","search","headers","items"]),dt(d,{dense:""},{default:Pt(()=>[$l(mr("span",{class:"ma-2 text-red",textContent:ni(f.error)},null,8,sE),[[Rl,f.error]])]),_:1})])]),_:1}),dt(h,{class:"px-2"},{default:Pt(()=>[dt(g),dt(a,{variant:"outlined","data-test":"open-config-cancel-btn",onClick:f.cancel},{default:Pt(()=>[...n[6]||(n[6]=[Er(" Cancel ",-1)])]),_:1},8,["onClick"]),dt(a,{variant:"flat",type:"submit","data-test":"open-config-submit-btn",disabled:!!f.error,onClick:Vs(f.success,["prevent"])},{default:Pt(()=>[...n[7]||(n[7]=[Er(" Ok ",-1)])]),_:1},8,["disabled","onClick"])]),_:1})],32)]),_:1})]),_:1},8,["modelValue","onKeydown"])}const xD=On("I",Vo(iE,[["render",aE]])),lE={props:{configKey:{type:String,default:null},modelValue:Boolean},emits:["update:modelValue","warning","success"],data(){return{configName:"",configs:[],headers:[{title:"Configuration",value:"config"},{title:"Actions",value:"actions",align:"end",sortable:!1}],search:null,selectedRows:[]}},computed:{selectedItem:function(){return this.selectedRows.length?this.configs.find(t=>t.configId===this.selectedRows[0]):null},error:function(){return this.configName?/^[A-Za-z0-9_\-. ]+$/.test(this.configName)?null:"Config name must only contain letters, numbers, hyphens, underscores, spaces, and periods":"Config must have a name"},show:{get(){return this.modelValue},set(t){this.$emit("update:modelValue",t)}}},watch:{selectedItem:function(t){t&&(this.configName=t.config)}},mounted(){let t=-1;new vs().list_configs(this.configKey).then(n=>{this.configs=n.map(e=>(t+=1,{configId:t,config:e}))}).catch(n=>{this.$emit("warning",`Failed to connect to OpenC3. ${n}`)})},methods:{selectRow:function(t){this.selectedRows=[t.item.configId]},success:function(){this.$emit("success",this.configName),this.show=!1,this.search=null,this.selectedRows=[],this.configName=""},cancel:function(){this.show=!1,this.search=null,this.selectedRows=[],this.configName=""},deleteConfig:function(t){this.$dialog.confirm(`Are you sure you want to delete: ${t.config}`,{okText:"Delete",cancelText:"Cancel"}).then(n=>{this.selectedItem?.config===t.config&&(this.selectedRows=[],this.configName=""),this.configs.splice(this.configs.indexOf(t),1),new vs().delete_config(this.configKey,t.config)}).catch(n=>{n!==!0&&this.$emit("warning",`Failed to delete config ${t.config} Error: ${n}`)})}}},cE={class:"mt-4 pa-3"},uE=["textContent"];function hE(t,n,e,r,m,f){const g=St("v-spacer"),w=St("v-toolbar"),u=St("v-text-field"),d=St("v-row"),a=St("v-btn"),l=St("v-data-table"),c=St("v-card-text"),h=St("v-card-actions"),o=St("v-card"),s=St("v-dialog");return Nn(),co(s,{modelValue:f.show,"onUpdate:modelValue":n[5]||(n[5]=p=>f.show=p),persistent:"",width:"600",onKeydown:Sl(f.cancel,["esc"])},{default:Pt(()=>[dt(o,null,{default:Pt(()=>[mr("form",{onSubmit:n[4]||(n[4]=Vs((...p)=>f.success&&f.success(...p),["prevent"]))},[dt(w,{height:"24"},{default:Pt(()=>[dt(g),n[6]||(n[6]=mr("span",null,"Save Configuration",-1)),dt(g)]),_:1}),dt(c,null,{default:Pt(()=>[mr("div",cE,[dt(d,{dense:""},{default:Pt(()=>[dt(u,{modelValue:m.search,"onUpdate:modelValue":n[0]||(n[0]=p=>m.search=p),label:"search",type:"text","prepend-inner-icon":"mdi-magnify",clearable:"",variant:"outlined",density:"compact","clear-icon":"mdi-close-circle-outline","single-line":"","hide-details":"","data-test":"search"},null,8,["modelValue"])]),_:1}),dt(l,{modelValue:m.selectedRows,"onUpdate:modelValue":n[1]||(n[1]=p=>m.selectedRows=p),"show-select":"","select-strategy":"single","item-value":"configId",search:m.search,headers:m.headers,items:m.configs,"items-per-page":5,"items-per-page-options":[5],"onClick:row":n[2]||(n[2]=(p,b)=>f.selectRow(b))},{"item.actions":Pt(({item:p})=>[dt(a,{class:"mt-1",icon:"mdi-delete",variant:"text","data-test":"item-delete",onClick:b=>f.deleteConfig(p)},null,8,["onClick"])]),_:1},8,["modelValue","search","headers","items"]),dt(d,{dense:""},{default:Pt(()=>[dt(u,{modelValue:m.configName,"onUpdate:modelValue":n[3]||(n[3]=p=>m.configName=p),"hide-details":"",autofocus:"",disabled:!!f.selectedItem,label:"Configuration Name","data-test":"name-input-save-config-dialog"},null,8,["modelValue","disabled"])]),_:1}),dt(d,{dense:""},{default:Pt(()=>[$l(mr("span",{class:"ma-2 text-red",textContent:ni(f.error)},null,8,uE),[[Rl,f.error]])]),_:1})])]),_:1}),dt(h,{class:"px-2"},{default:Pt(()=>[dt(g),dt(a,{variant:"outlined",onClick:f.cancel},{default:Pt(()=>[...n[7]||(n[7]=[Er(" Cancel ",-1)])]),_:1},8,["onClick"]),dt(a,{variant:"flat",type:"submit","data-test":"save-config-submit-btn",disabled:!!f.error,onClick:Vs(f.success,["prevent"])},{default:Pt(()=>[...n[8]||(n[8]=[Er(" Ok ",-1)])]),_:1},8,["disabled","onClick"])]),_:1})],32)]),_:1})]),_:1},8,["modelValue","onKeydown"])}const CD=On("M",Vo(lE,[["render",hE]])),dE=50,fE=2e3,Fy="single-spa:app-change",pE={data(){return{appsMounted:!1,show:!1,hideSpinner:!1,pollInterval:null}},computed:{showSpinner:function(){return!this.hideSpinner&&!this.show}},created(){window.addEventListener(Fy,this.handleAppChange)},mounted(){this.pollForMountedApps(),setTimeout(()=>{this.appsMounted||(this.show=!0,this.pollInterval&&clearInterval(this.pollInterval))},fE)},unmounted(){window.removeEventListener(Fy,this.handleAppChange),this.pollInterval&&clearInterval(this.pollInterval)},methods:{handleAppChange:function(t){this.show=!t.detail.appsByNewStatus.MOUNTED,this.hideSpinner=!0},pollForMountedApps:function(){this.pollInterval=setInterval(()=>{this.appsMounted=hu().length>0,hu().length>0&&(this.hideSpinner=!0,clearInterval(this.pollInterval))},dE)}}},gE={class:"mx-1"},mE={key:1,class:"d-flex justify-center align-center"};function vE(t,n,e,r,m,f){const g=St("v-card-title"),w=St("v-card-text"),u=St("v-card"),d=St("v-progress-circular");return Nn(),ti(kl,null,[m.show?(Nn(),co(u,{key:0},{default:Pt(()=>[dt(g,null,{default:Pt(()=>[...n[0]||(n[0]=[Er(" 404 Not Found ",-1)])]),_:1}),dt(w,{class:"d-flex align-center mt-3"},{default:Pt(()=>[n[1]||(n[1]=Er(" The requested URL ",-1)),mr("code",gE,ni(t.$route.fullPath),1),n[2]||(n[2]=Er(" was not routable. ",-1)),n[3]||(n[3]=mr("span",{class:"text-h3 mx-1"}," 🦄 ",-1))]),_:1})]),_:1})):So("",!0),f.showSpinner?(Nn(),ti("div",mE,[dt(d,{indeterminate:""})])):So("",!0)],64)}const zy=[{path:"/",name:"DataExtractor",component:()=>it(()=>rt.import("./DataExtractor-2097e7e5aaf43aad6f8b.js"),void 0)},{path:"/:pathMatch(.*)*",name:"NotFound",component:Vo(pE,[["render",vE]])}];zy.forEach(t=>Wf(t));const yE=Nf({history:Df(),routes:zy});function By(t,n){(n==null||n>t.length)&&(n=t.length);for(var e=0,r=Array(n);e<n;e++)r[e]=t[e];return r}function bE(t){if(Array.isArray(t))return t}function wE(t,n){var e=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(e!=null){var r,m,f,g,w=[],u=!0,d=!1;try{if(f=(e=e.call(t)).next,n!==0)for(;!(u=(r=f.call(e)).done)&&(w.push(r.value),w.length!==n);u=!0);}catch(a){d=!0,m=a}finally{try{if(!u&&e.return!=null&&(g=e.return(),Object(g)!==g))return}finally{if(d)throw m}}return w}}function xE(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
1489
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function CE(t,n){return bE(t)||wE(t,n)||AE(t,n)||xE()}function AE(t,n){if(t){if(typeof t=="string")return By(t,n);var e={}.toString.call(t).slice(8,-1);return e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set"?Array.from(t):e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?By(t,n):void 0}}const Wy=Object.entries,jy=Object.setPrototypeOf,_E=Object.isFrozen,kE=Object.getPrototypeOf,SE=Object.getOwnPropertyDescriptor;let Gr=Object.freeze,Oi=Object.seal,pa=Object.create,Hy=typeof Reflect<"u"&&Reflect,bd=Hy.apply,wd=Hy.construct;Gr||(Gr=function(t){return t}),Oi||(Oi=function(t){return t}),bd||(bd=function(t,n){for(var e=arguments.length,r=new Array(e>2?e-2:0),m=2;m<e;m++)r[m-2]=arguments[m];return t.apply(n,r)}),wd||(wd=function(t){for(var n=arguments.length,e=new Array(n>1?n-1:0),r=1;r<n;r++)e[r-1]=arguments[r];return new t(...e)});const ga=nr(Array.prototype.forEach),$E=nr(Array.prototype.lastIndexOf),Uy=nr(Array.prototype.pop),ma=nr(Array.prototype.push),RE=nr(Array.prototype.splice),Kr=Array.isArray,al=nr(String.prototype.toLowerCase),xd=nr(String.prototype.toString),Vy=nr(String.prototype.match),va=nr(String.prototype.replace),qy=nr(String.prototype.indexOf),EE=nr(String.prototype.trim),TE=nr(Number.prototype.toString),ME=nr(Boolean.prototype.toString),Gy=typeof BigInt>"u"?null:nr(BigInt.prototype.toString),Ky=typeof Symbol>"u"?null:nr(Symbol.prototype.toString),Bn=nr(Object.prototype.hasOwnProperty),ll=nr(Object.prototype.toString),Ar=nr(RegExp.prototype.test),cl=IE(TypeError);function nr(t){return function(n){n instanceof RegExp&&(n.lastIndex=0);for(var e=arguments.length,r=new Array(e>1?e-1:0),m=1;m<e;m++)r[m-1]=arguments[m];return bd(t,n,r)}}function IE(t){return function(){for(var n=arguments.length,e=new Array(n),r=0;r<n;r++)e[r]=arguments[r];return wd(t,e)}}function Lt(t,n){let e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:al;if(jy&&jy(t,null),!Kr(n))return t;let r=n.length;for(;r--;){let m=n[r];if(typeof m=="string"){const f=e(m);f!==m&&(_E(n)||(n[r]=f),m=f)}t[m]=!0}return t}function LE(t){for(let n=0;n<t.length;n++)Bn(t,n)||(t[n]=null);return t}function Lr(t){const n=pa(null);for(const r of Wy(t)){var e=CE(r,2);const m=e[0],f=e[1];Bn(t,m)&&(Kr(f)?n[m]=LE(f):f&&typeof f=="object"&&f.constructor===Object?n[m]=Lr(f):n[m]=f)}return n}function OE(t){switch(typeof t){case"string":return t;case"number":return TE(t);case"boolean":return ME(t);case"bigint":return Gy?Gy(t):"0";case"symbol":return Ky?Ky(t):"Symbol()";case"undefined":return ll(t);case"function":case"object":{if(t===null)return ll(t);const n=t,e=fo(n,"toString");if(typeof e=="function"){const r=e(n);return typeof r=="string"?r:ll(r)}return ll(t)}default:return ll(t)}}function fo(t,n){for(;t!==null;){const r=SE(t,n);if(r){if(r.get)return nr(r.get);if(typeof r.value=="function")return nr(r.value)}t=kE(t)}function e(){return null}return e}function NE(t){try{return Ar(t,""),!0}catch{return!1}}const Yy=Gr(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Cd=Gr(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Ad=Gr(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),DE=Gr(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),_d=Gr(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),PE=Gr(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Jy=Gr(["#text"]),Zy=Gr(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","command","commandfor","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns"]),kd=Gr(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Xy=Gr(["accent","accentunder","align","bevelled","close","columnalign","columnlines","columnspacing","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lquote","lspace","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Sc=Gr(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),FE=Oi(/{{[\w\W]*|^[\w\W]*}}/g),zE=Oi(/<%[\w\W]*|^[\w\W]*%>/g),BE=Oi(/\${[\w\W]*/g),WE=Oi(/^data-[\-\w.\u00B7-\uFFFF]+$/),jE=Oi(/^aria-[\-\w]+$/),Qy=Oi(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),HE=Oi(/^(?:\w+script|data):/i),UE=Oi(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),VE=Oi(/^html$/i),qE=Oi(/^[a-z][.\w]*(-[.\w]+)+$/i),po={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},GE=function(){return typeof window>"u"?null:window},KE=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let e=null;const r="data-tt-policy-suffix";n&&n.hasAttribute(r)&&(e=n.getAttribute(r));const m="dompurify"+(e?"#"+e:"");try{return t.createPolicy(m,{createHTML(f){return f},createScriptURL(f){return f}})}catch{return console.warn("TrustedTypes policy "+m+" could not be created."),null}},eb=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function tb(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:GE();const n=oe=>tb(oe);if(n.version="3.4.7",n.removed=[],!t||!t.document||t.document.nodeType!==po.document||!t.Element)return n.isSupported=!1,n;let e=t.document;const r=e,m=r.currentScript;t.DocumentFragment;const f=t.HTMLTemplateElement,g=t.Node,w=t.Element,u=t.NodeFilter;t.NamedNodeMap===void 0&&(t.NamedNodeMap||t.MozNamedAttrMap),t.HTMLFormElement;const a=t.DOMParser,l=t.trustedTypes,c=w.prototype,h=fo(c,"cloneNode"),o=fo(c,"remove"),s=fo(c,"nextSibling"),p=fo(c,"childNodes"),b=fo(c,"parentNode"),x=fo(c,"shadowRoot"),M=fo(c,"attributes"),R=g&&g.prototype?fo(g.prototype,"nodeType"):null,k=g&&g.prototype?fo(g.prototype,"nodeName"):null;if(typeof f=="function"){const oe=e.createElement("template");oe.content&&oe.content.ownerDocument&&(e=oe.content.ownerDocument)}let C,L="";const D=e,I=D.implementation,T=D.createNodeIterator,W=D.createDocumentFragment,F=D.getElementsByTagName,O=r.importNode;let S=eb();n.isSupported=typeof Wy=="function"&&typeof b=="function"&&I&&I.createHTMLDocument!==void 0;const A=FE,N=zE,B=BE,U=WE,G=jE,J=HE,ne=UE,de=qE;let ee=Qy,se=null;const ce=Lt({},[...Yy,...Cd,...Ad,..._d,...Jy]);let le=null;const pe=Lt({},[...Zy,...kd,...Xy,...Sc]);let me=Object.seal(pa(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),$e=null,Ee=null;const He=Object.seal(pa(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Ue=!0,ot=!0,Qe=!1,lt=!0,Tt=!1,ur=!0,At=!1,vr=!1,Dn=!1,Kn=!1,un=!1,Yn=!1,gt=!0,Je=!1;const Ft="user-content-";let An=!0,_n=!1,kn={},mn=null;const vn=Lt({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let Wn=null;const Jn=Lt({},["audio","video","img","source","image","track"]);let Jt=null;const jn=Lt({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),oi="http://www.w3.org/1998/Math/MathML",Or="http://www.w3.org/2000/svg",Rn="http://www.w3.org/1999/xhtml";let yr=Rn,bi=!1,rr=null;const Xi=Lt({},[oi,Or,Rn],xd);let wi=Lt({},["mi","mo","mn","ms","mtext"]),Eo=Lt({},["annotation-xml"]);const Yr=Lt({},["title","style","font","a","script"]);let Qi=null;const Jo=["application/xhtml+xml","text/html"],To="text/html";let Zt=null,fn=null;const Nr=e.createElement("form"),Dr=function(oe){return oe instanceof RegExp||oe instanceof Function},Sn=function(){let oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(fn&&fn===oe)return;(!oe||typeof oe!="object")&&(oe={}),oe=Lr(oe),Qi=Jo.indexOf(oe.PARSER_MEDIA_TYPE)===-1?To:oe.PARSER_MEDIA_TYPE,Zt=Qi==="application/xhtml+xml"?xd:al,se=Bn(oe,"ALLOWED_TAGS")&&Kr(oe.ALLOWED_TAGS)?Lt({},oe.ALLOWED_TAGS,Zt):ce,le=Bn(oe,"ALLOWED_ATTR")&&Kr(oe.ALLOWED_ATTR)?Lt({},oe.ALLOWED_ATTR,Zt):pe,rr=Bn(oe,"ALLOWED_NAMESPACES")&&Kr(oe.ALLOWED_NAMESPACES)?Lt({},oe.ALLOWED_NAMESPACES,xd):Xi,Jt=Bn(oe,"ADD_URI_SAFE_ATTR")&&Kr(oe.ADD_URI_SAFE_ATTR)?Lt(Lr(jn),oe.ADD_URI_SAFE_ATTR,Zt):jn,Wn=Bn(oe,"ADD_DATA_URI_TAGS")&&Kr(oe.ADD_DATA_URI_TAGS)?Lt(Lr(Jn),oe.ADD_DATA_URI_TAGS,Zt):Jn,mn=Bn(oe,"FORBID_CONTENTS")&&Kr(oe.FORBID_CONTENTS)?Lt({},oe.FORBID_CONTENTS,Zt):vn,$e=Bn(oe,"FORBID_TAGS")&&Kr(oe.FORBID_TAGS)?Lt({},oe.FORBID_TAGS,Zt):Lr({}),Ee=Bn(oe,"FORBID_ATTR")&&Kr(oe.FORBID_ATTR)?Lt({},oe.FORBID_ATTR,Zt):Lr({}),kn=Bn(oe,"USE_PROFILES")?oe.USE_PROFILES&&typeof oe.USE_PROFILES=="object"?Lr(oe.USE_PROFILES):oe.USE_PROFILES:!1,Ue=oe.ALLOW_ARIA_ATTR!==!1,ot=oe.ALLOW_DATA_ATTR!==!1,Qe=oe.ALLOW_UNKNOWN_PROTOCOLS||!1,lt=oe.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Tt=oe.SAFE_FOR_TEMPLATES||!1,ur=oe.SAFE_FOR_XML!==!1,At=oe.WHOLE_DOCUMENT||!1,Kn=oe.RETURN_DOM||!1,un=oe.RETURN_DOM_FRAGMENT||!1,Yn=oe.RETURN_TRUSTED_TYPE||!1,Dn=oe.FORCE_BODY||!1,gt=oe.SANITIZE_DOM!==!1,Je=oe.SANITIZE_NAMED_PROPS||!1,An=oe.KEEP_CONTENT!==!1,_n=oe.IN_PLACE||!1,ee=NE(oe.ALLOWED_URI_REGEXP)?oe.ALLOWED_URI_REGEXP:Qy,yr=typeof oe.NAMESPACE=="string"?oe.NAMESPACE:Rn,wi=Bn(oe,"MATHML_TEXT_INTEGRATION_POINTS")&&oe.MATHML_TEXT_INTEGRATION_POINTS&&typeof oe.MATHML_TEXT_INTEGRATION_POINTS=="object"?Lr(oe.MATHML_TEXT_INTEGRATION_POINTS):Lt({},["mi","mo","mn","ms","mtext"]),Eo=Bn(oe,"HTML_INTEGRATION_POINTS")&&oe.HTML_INTEGRATION_POINTS&&typeof oe.HTML_INTEGRATION_POINTS=="object"?Lr(oe.HTML_INTEGRATION_POINTS):Lt({},["annotation-xml"]);const Ne=Bn(oe,"CUSTOM_ELEMENT_HANDLING")&&oe.CUSTOM_ELEMENT_HANDLING&&typeof oe.CUSTOM_ELEMENT_HANDLING=="object"?Lr(oe.CUSTOM_ELEMENT_HANDLING):pa(null);if(me=pa(null),Bn(Ne,"tagNameCheck")&&Dr(Ne.tagNameCheck)&&(me.tagNameCheck=Ne.tagNameCheck),Bn(Ne,"attributeNameCheck")&&Dr(Ne.attributeNameCheck)&&(me.attributeNameCheck=Ne.attributeNameCheck),Bn(Ne,"allowCustomizedBuiltInElements")&&typeof Ne.allowCustomizedBuiltInElements=="boolean"&&(me.allowCustomizedBuiltInElements=Ne.allowCustomizedBuiltInElements),Tt&&(ot=!1),un&&(Kn=!0),kn&&(se=Lt({},Jy),le=pa(null),kn.html===!0&&(Lt(se,Yy),Lt(le,Zy)),kn.svg===!0&&(Lt(se,Cd),Lt(le,kd),Lt(le,Sc)),kn.svgFilters===!0&&(Lt(se,Ad),Lt(le,kd),Lt(le,Sc)),kn.mathMl===!0&&(Lt(se,_d),Lt(le,Xy),Lt(le,Sc))),He.tagCheck=null,He.attributeCheck=null,Bn(oe,"ADD_TAGS")&&(typeof oe.ADD_TAGS=="function"?He.tagCheck=oe.ADD_TAGS:Kr(oe.ADD_TAGS)&&(se===ce&&(se=Lr(se)),Lt(se,oe.ADD_TAGS,Zt))),Bn(oe,"ADD_ATTR")&&(typeof oe.ADD_ATTR=="function"?He.attributeCheck=oe.ADD_ATTR:Kr(oe.ADD_ATTR)&&(le===pe&&(le=Lr(le)),Lt(le,oe.ADD_ATTR,Zt))),Bn(oe,"ADD_URI_SAFE_ATTR")&&Kr(oe.ADD_URI_SAFE_ATTR)&&Lt(Jt,oe.ADD_URI_SAFE_ATTR,Zt),Bn(oe,"FORBID_CONTENTS")&&Kr(oe.FORBID_CONTENTS)&&(mn===vn&&(mn=Lr(mn)),Lt(mn,oe.FORBID_CONTENTS,Zt)),Bn(oe,"ADD_FORBID_CONTENTS")&&Kr(oe.ADD_FORBID_CONTENTS)&&(mn===vn&&(mn=Lr(mn)),Lt(mn,oe.ADD_FORBID_CONTENTS,Zt)),An&&(se["#text"]=!0),At&&Lt(se,["html","head","body"]),se.table&&(Lt(se,["tbody"]),delete $e.tbody),oe.TRUSTED_TYPES_POLICY){if(typeof oe.TRUSTED_TYPES_POLICY.createHTML!="function")throw cl('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof oe.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw cl('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');C=oe.TRUSTED_TYPES_POLICY,L=C.createHTML("")}else C===void 0&&(C=KE(l,m)),C!==null&&typeof L=="string"&&(L=C.createHTML(""));(S.uponSanitizeElement.length>0||S.uponSanitizeAttribute.length>0)&&se===ce&&(se=Lr(se)),S.uponSanitizeAttribute.length>0&&le===pe&&(le=Lr(le)),Gr&&Gr(oe),fn=oe},Zn=Lt({},[...Cd,...Ad,...DE]),xi=Lt({},[..._d,...PE]),Ci=function(oe){let Ne=b(oe);(!Ne||!Ne.tagName)&&(Ne={namespaceURI:yr,tagName:"template"});const ze=al(oe.tagName),mt=al(Ne.tagName);return rr[oe.namespaceURI]?oe.namespaceURI===Or?Ne.namespaceURI===Rn?ze==="svg":Ne.namespaceURI===oi?ze==="svg"&&(mt==="annotation-xml"||wi[mt]):!!Zn[ze]:oe.namespaceURI===oi?Ne.namespaceURI===Rn?ze==="math":Ne.namespaceURI===Or?ze==="math"&&Eo[mt]:!!xi[ze]:oe.namespaceURI===Rn?Ne.namespaceURI===Or&&!Eo[mt]||Ne.namespaceURI===oi&&!wi[mt]?!1:!xi[ze]&&(Yr[ze]||!Zn[ze]):!!(Qi==="application/xhtml+xml"&&rr[oe.namespaceURI]):!1},Jr=function(oe){ma(n.removed,{element:oe});try{b(oe).removeChild(oe)}catch{o(oe)}},si=function(oe,Ne){try{ma(n.removed,{attribute:Ne.getAttributeNode(oe),from:Ne})}catch{ma(n.removed,{attribute:null,from:Ne})}if(Ne.removeAttribute(oe),oe==="is")if(Kn||un)try{Jr(Ne)}catch{}else try{Ne.setAttribute(oe,"")}catch{}},Zo=function(oe){let Ne=null,ze=null;if(Dn)oe="<remove></remove>"+oe;else{const Mt=Vy(oe,/^[\r\n\t ]+/);ze=Mt&&Mt[0]}Qi==="application/xhtml+xml"&&yr===Rn&&(oe='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+oe+"</body></html>");const mt=C?C.createHTML(oe):oe;if(yr===Rn)try{Ne=new a().parseFromString(mt,Qi)}catch{}if(!Ne||!Ne.documentElement){Ne=I.createDocument(yr,"template",null);try{Ne.documentElement.innerHTML=bi?L:mt}catch{}}const Ot=Ne.body||Ne.documentElement;return oe&&ze&&Ot.insertBefore(e.createTextNode(ze),Ot.childNodes[0]||null),yr===Rn?F.call(Ne,At?"html":"body")[0]:At?Ne.documentElement:Ot},Mo=function(oe){return T.call(oe.ownerDocument||oe,oe,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},ai=function(oe){oe.normalize();const Ne=T.call(oe.ownerDocument||oe,oe,u.SHOW_TEXT|u.SHOW_COMMENT|u.SHOW_CDATA_SECTION|u.SHOW_PROCESSING_INSTRUCTION,null);let ze=Ne.nextNode();for(;ze;){let mt=ze.data;ga([A,N,B],Ot=>{mt=va(mt,Ot," ")}),ze.data=mt,ze=Ne.nextNode()}},_r=function(oe){const Ne=k?k(oe):null;return typeof Ne!="string"||Zt(Ne)!=="form"?!1:typeof oe.nodeName!="string"||typeof oe.textContent!="string"||typeof oe.removeChild!="function"||oe.attributes!==M(oe)||typeof oe.removeAttribute!="function"||typeof oe.setAttribute!="function"||typeof oe.namespaceURI!="string"||typeof oe.insertBefore!="function"||typeof oe.hasChildNodes!="function"||oe.nodeType!==R(oe)||oe.childNodes!==p(oe)},$t=function(oe){if(!R||typeof oe!="object"||oe===null)return!1;try{return R(oe)===po.documentFragment}catch{return!1}},eo=function(oe){if(!R||typeof oe!="object"||oe===null)return!1;try{return typeof R(oe)=="number"}catch{return!1}};function bn(oe,Ne,ze){ga(oe,mt=>{mt.call(n,Ne,ze,fn)})}const En=function(oe){let Ne=null;if(bn(S.beforeSanitizeElements,oe,null),_r(oe))return Jr(oe),!0;const ze=Zt(oe.nodeName);if(bn(S.uponSanitizeElement,oe,{tagName:ze,allowedTags:se}),ur&&oe.hasChildNodes()&&!eo(oe.firstElementChild)&&Ar(/<[/\w!]/g,oe.innerHTML)&&Ar(/<[/\w!]/g,oe.textContent)||ur&&oe.namespaceURI===Rn&&ze==="style"&&eo(oe.firstElementChild)||oe.nodeType===po.progressingInstruction||ur&&oe.nodeType===po.comment&&Ar(/<[/\w]/g,oe.data))return Jr(oe),!0;if($e[ze]||!(He.tagCheck instanceof Function&&He.tagCheck(ze))&&!se[ze]){if(!$e[ze]&&Ni(ze)&&(me.tagNameCheck instanceof RegExp&&Ar(me.tagNameCheck,ze)||me.tagNameCheck instanceof Function&&me.tagNameCheck(ze)))return!1;if(An&&!mn[ze]){const mt=b(oe),Ot=p(oe);if(Ot&&mt){const Mt=Ot.length;for(let wr=Mt-1;wr>=0;--wr){const xr=h(Ot[wr],!0);mt.insertBefore(xr,s(oe))}}}return Jr(oe),!0}return(R?R(oe):oe.nodeType)===po.element&&!Ci(oe)||(ze==="noscript"||ze==="noembed"||ze==="noframes")&&Ar(/<\/no(script|embed|frames)/i,oe.innerHTML)?(Jr(oe),!0):(Tt&&oe.nodeType===po.text&&(Ne=oe.textContent,ga([A,N,B],mt=>{Ne=va(Ne,mt," ")}),oe.textContent!==Ne&&(ma(n.removed,{element:oe.cloneNode()}),oe.textContent=Ne)),bn(S.afterSanitizeElements,oe,null),!1)},hn=function(oe,Ne,ze){if(Ee[Ne]||gt&&(Ne==="id"||Ne==="name")&&(ze in e||ze in Nr))return!1;const mt=le[Ne]||He.attributeCheck instanceof Function&&He.attributeCheck(Ne,oe);if(!(ot&&!Ee[Ne]&&Ar(U,Ne))&&!(Ue&&Ar(G,Ne))){if(!mt||Ee[Ne]){if(!(Ni(oe)&&(me.tagNameCheck instanceof RegExp&&Ar(me.tagNameCheck,oe)||me.tagNameCheck instanceof Function&&me.tagNameCheck(oe))&&(me.attributeNameCheck instanceof RegExp&&Ar(me.attributeNameCheck,Ne)||me.attributeNameCheck instanceof Function&&me.attributeNameCheck(Ne,oe))||Ne==="is"&&me.allowCustomizedBuiltInElements&&(me.tagNameCheck instanceof RegExp&&Ar(me.tagNameCheck,ze)||me.tagNameCheck instanceof Function&&me.tagNameCheck(ze))))return!1}else if(!Jt[Ne]&&!Ar(ee,va(ze,ne,""))&&!((Ne==="src"||Ne==="xlink:href"||Ne==="href")&&oe!=="script"&&qy(ze,"data:")===0&&Wn[oe])&&!(Qe&&!Ar(J,va(ze,ne,"")))&&ze)return!1}return!0},Tn=Lt({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),Ni=function(oe){return!Tn[al(oe)]&&Ar(de,oe)},Hn=function(oe){bn(S.beforeSanitizeAttributes,oe,null);const Ne=oe.attributes;if(!Ne||_r(oe))return;const ze={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:le,forceKeepAttr:void 0};let mt=Ne.length;for(;mt--;){const Ot=Ne[mt],Mt=Ot.name,wr=Ot.namespaceURI,xr=Ot.value,hr=Zt(Mt),ci=xr;let Ht=Mt==="value"?ci:EE(ci);if(ze.attrName=hr,ze.attrValue=Ht,ze.keepAttr=!0,ze.forceKeepAttr=void 0,bn(S.uponSanitizeAttribute,oe,ze),Ht=ze.attrValue,Je&&(hr==="id"||hr==="name")&&qy(Ht,Ft)!==0&&(si(Mt,oe),Ht=Ft+Ht),ur&&Ar(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,Ht)){si(Mt,oe);continue}if(hr==="attributename"&&Vy(Ht,"href")){si(Mt,oe);continue}if(ze.forceKeepAttr)continue;if(!ze.keepAttr){si(Mt,oe);continue}if(!lt&&Ar(/\/>/i,Ht)){si(Mt,oe);continue}Tt&&ga([A,N,B],mo=>{Ht=va(Ht,mo," ")});const go=Zt(oe.nodeName);if(!hn(go,hr,Ht)){si(Mt,oe);continue}if(C&&typeof l=="object"&&typeof l.getAttributeType=="function"&&!wr)switch(l.getAttributeType(go,hr)){case"TrustedHTML":{Ht=C.createHTML(Ht);break}case"TrustedScriptURL":{Ht=C.createScriptURL(Ht);break}}if(Ht!==ci)try{wr?oe.setAttributeNS(wr,Mt,Ht):oe.setAttribute(Mt,Ht),_r(oe)?Jr(oe):Uy(n.removed)}catch{si(Mt,oe)}}bn(S.afterSanitizeAttributes,oe,null)},li=function(oe){let Ne=null;const ze=Mo(oe);for(bn(S.beforeSanitizeShadowDOM,oe,null);Ne=ze.nextNode();)if(bn(S.uponSanitizeShadowNode,Ne,null),En(Ne),Hn(Ne),$t(Ne.content)&&li(Ne.content),(R?R(Ne):Ne.nodeType)===po.element){const mt=x?x(Ne):Ne.shadowRoot;$t(mt)&&(br(mt),li(mt))}bn(S.afterSanitizeShadowDOM,oe,null)},br=function(oe){const Ne=R?R(oe):oe.nodeType;if(Ne===po.element){const Ot=x?x(oe):oe.shadowRoot;$t(Ot)&&(br(Ot),li(Ot))}const ze=p?p(oe):oe.childNodes;if(!ze)return;const mt=[];ga(ze,Ot=>{ma(mt,Ot)});for(const Ot of mt)br(Ot);if(Ne===po.element){const Ot=k?k(oe):null;if(typeof Ot=="string"&&Zt(Ot)==="template"){const Mt=oe.content;$t(Mt)&&br(Mt)}}};return n.sanitize=function(oe){let Ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ze=null,mt=null,Ot=null,Mt=null;if(bi=!oe,bi&&(oe="<!-->"),typeof oe!="string"&&!eo(oe)&&(oe=OE(oe),typeof oe!="string"))throw cl("dirty is not a string, aborting");if(!n.isSupported)return oe;if(vr||Sn(Ne),n.removed=[],typeof oe=="string"&&(_n=!1),_n){const hr=k?k(oe):oe.nodeName;if(typeof hr=="string"){const ci=Zt(hr);if(!se[ci]||$e[ci])throw cl("root node is forbidden and cannot be sanitized in-place")}if(_r(oe))throw cl("root node is clobbered and cannot be sanitized in-place");br(oe)}else if(eo(oe))ze=Zo("<!---->"),mt=ze.ownerDocument.importNode(oe,!0),mt.nodeType===po.element&&mt.nodeName==="BODY"||mt.nodeName==="HTML"?ze=mt:ze.appendChild(mt),br(mt);else{if(!Kn&&!Tt&&!At&&oe.indexOf("<")===-1)return C&&Yn?C.createHTML(oe):oe;if(ze=Zo(oe),!ze)return Kn?null:Yn?L:""}ze&&Dn&&Jr(ze.firstChild);const wr=Mo(_n?oe:ze);for(;Ot=wr.nextNode();)En(Ot),Hn(Ot),$t(Ot.content)&&li(Ot.content);if(_n)return Tt&&ai(oe),oe;if(Kn){if(Tt&&ai(ze),un)for(Mt=W.call(ze.ownerDocument);ze.firstChild;)Mt.appendChild(ze.firstChild);else Mt=ze;return(le.shadowroot||le.shadowrootmode)&&(Mt=O.call(r,Mt,!0)),Mt}let xr=At?ze.outerHTML:ze.innerHTML;return At&&se["!doctype"]&&ze.ownerDocument&&ze.ownerDocument.doctype&&ze.ownerDocument.doctype.name&&Ar(VE,ze.ownerDocument.doctype.name)&&(xr="<!DOCTYPE "+ze.ownerDocument.doctype.name+`>
1490
+ `+xr),Tt&&ga([A,N,B],hr=>{xr=va(xr,hr," ")}),C&&Yn?C.createHTML(xr):xr},n.setConfig=function(){let oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Sn(oe),vr=!0},n.clearConfig=function(){fn=null,vr=!1},n.isValidAttribute=function(oe,Ne,ze){fn||Sn({});const mt=Zt(oe),Ot=Zt(Ne);return hn(mt,Ot,ze)},n.addHook=function(oe,Ne){typeof Ne=="function"&&ma(S[oe],Ne)},n.removeHook=function(oe,Ne){if(Ne!==void 0){const ze=$E(S[oe],Ne);return ze===-1?void 0:RE(S[oe],ze,1)[0]}return Uy(S[oe])},n.removeHooks=function(oe){S[oe]=[]},n.removeAllHooks=function(){S=eb()},n}var YE=tb();const JE={dark:!0,colors:{primary:"#005A8F",secondary:"#4DACFF",tertiary:"#BBC1C9","openc3-green":"#56f000","openc3-yellow":"#fce83a","openc3-red":"#ff3838","openc3-blue":"#2dccff","openc3-purple":"#c800c8","openc3-black":"#ffffff","openc3-white":"#ffffff"}},ZE={data:function(){return{show:!1,params:{title:"Title",text:"The text that is displayed",okText:"Ok",okClass:"primary",validateText:"CONFIRM",cancelText:"Cancel",html:!1},resolve:null,reject:null,validationText:null,rules:{required:t=>!!t||"Required.",match:t=>t===this.params.validateText||"Value mismatch."}}},computed:{dataTestOk:function(){return`confirm-dialog-${this.params.okText.toLowerCase()}`},dataTestCancel:function(){return`confirm-dialog-${this.params.cancelText.toLowerCase()}`},sanitizedText:function(){return YE.sanitize(this.params.text)}},methods:{dialog:function(t,n,e){this.params=t,this.show=!0,this.resolve=n,this.reject=e},ok:function(){(!this.params.validateText||this.params.validateText===this.validationText)&&(this.show=!1,this.resolve(!0),this.refresh())},cancel:function(){this.show=!1,this.reject(!0),this.refresh()},refresh:function(){this.validationText=""}}},XE=["innerHTML"],QE={key:2},eT={key:3,class:"validate mt-4"};function tT(t,n,e,r,m,f){const g=St("v-spacer"),w=St("v-toolbar"),u=St("v-icon"),d=St("v-text-field"),a=St("v-card-text"),l=St("v-btn"),c=St("v-card-actions"),h=St("v-card"),o=St("v-dialog"),s=St("v-app");return Nn(),co(s,null,{default:Pt(()=>[dt(o,{modelValue:t.show,"onUpdate:modelValue":n[1]||(n[1]=p=>t.show=p),persistent:"",width:"600",onKeydown:Sl(f.cancel,["esc"])},{default:Pt(()=>[dt(h,null,{default:Pt(()=>[dt(w,{height:"24"},{default:Pt(()=>[dt(g),mr("span",null,ni(t.params.title),1),dt(g)]),_:1}),dt(a,{class:"mt-4 pa-3"},{default:Pt(()=>[t.params.validateText?(Nn(),co(u,{key:0,class:"mr-2"},{default:Pt(()=>[...n[2]||(n[2]=[Er(" mdi-alert ",-1)])]),_:1})):So("",!0),t.params.html?(Nn(),ti("span",{key:1,innerHTML:f.sanitizedText},null,8,XE)):(Nn(),ti("span",QE,ni(f.sanitizedText),1)),t.params.validateText?(Nn(),ti("div",eT,[Er(" Enter "+ni(t.params.validateText)+" to confirm! ",1),dt(d,{modelValue:t.validationText,"onUpdate:modelValue":n[0]||(n[0]=p=>t.validationText=p),variant:"solo",density:"compact","single-line":"",rules:[t.rules.required,t.rules.match],"data-test":"confirm-dialog-validate"},null,8,["modelValue","rules"])])):So("",!0)]),_:1}),dt(c,{class:"px-2"},{default:Pt(()=>[dt(g),t.params.cancelText?(Nn(),co(l,{key:0,variant:"outlined","data-test":f.dataTestCancel,onClick:f.cancel},{default:Pt(()=>[Er(ni(t.params.cancelText),1)]),_:1},8,["data-test","onClick"])):So("",!0),dt(l,{variant:"flat",color:t.params.okClass,"data-test":f.dataTestOk,onClick:f.ok},{default:Pt(()=>[Er(ni(t.params.okText),1)]),_:1},8,["color","data-test","onClick"])]),_:1})]),_:1})]),_:1},8,["modelValue","onKeydown"])]),_:1})}const nT=Vo(ZE,[["render",tT],["__scopeId","data-v-53691296"]]);class rT{constructor(){this.mounted=!1,this.$root=null}mount(){if(this.mounted)return;const n=window.Vue.createApp(nT);n.use($d);const e=document.createElement("div");document.querySelector("#openc3-app-toolbar > div").appendChild(e),this.$root=n.mount(e),this.mounted=!0}open({title:n,text:e,okText:r,okClass:m,validateText:f,cancelText:g,html:w}){return this.mount(),new Promise((u,d)=>{this.$root.dialog({title:n,text:e,okText:r,okClass:m,validateText:f,cancelText:g,html:w},u,d)})}confirm(n,{okText:e="Ok",cancelText:r="Cancel",okClass:m="primary"}){return this.open({title:"Confirm",text:n,okText:e,okClass:m,validateText:null,cancelText:r,html:!1})}alert(n,{okText:e="Ok",html:r=!1,okClass:m="primary"}){return this.open({title:"Alert",text:n,okText:e,okClass:m,validateText:null,cancelText:null,html:r})}validate(n,{okText:e="Ok",validateText:r="CONFIRM",cancelText:m="Cancel",okClass:f="primary"}){return this.open({title:"Confirm",text:n,okText:e,okClass:f,validateText:r,cancelText:m,html:!1})}}const iT={install(t,n){const e=new rT;t.provide("dialog",e),t.config.globalProperties.hasOwnProperty("$dialog")||(t.config.globalProperties.$dialog=e)}},oT={data:function(){return{showToast:!1,expanded:!1,toastNotification:{title:"Title here",body:"This is the notification body",message:"Overall message here"},timeout:null,noToastPaths:["/login"]}},computed:{toastNotificationIcon:function(){return this.toastNotification.type==="notification"?"mdi-bell":"mdi-alert-box"},toastStyle:function(){return`
1491
+ --toast-bg-color:${yd[this.toastNotification.level]};
1492
+ --toast-fg-color:${eE(this.toastNotification.level)};
1493
+ `},contentStyle:function(){return`
1494
+ white-space: ${this.expanded?"normal":"nowrap"};
1495
+ overflow-x: ${this.expanded?"visible":"hidden"};
1496
+ text-overflow: ${this.expanded?"unset":"ellipsis"};
1497
+ `}},methods:{toast:function(t,n){this.noToastPaths.includes(window.location.pathname)||(n===void 0&&(n=5e3),this.toastNotification=t,this.showToast=!0,this.cancelAutohide(),n&&(this.timeout=setTimeout(()=>{this.hide()},n)))},hide:function(){this.cancelAutohide(),this.showToast=!1},cancelAutohide:function(){this.timeout&&(clearTimeout(this.timeout),this.timeout=null)},expand:function(){this.cancelAutohide(),this.expanded=!0}}},sT={key:0,class:"text-subtitle-1 mr-1 notification-text"},aT={key:1,class:"text-body-2 notification-text"},lT={key:2,class:"text-body-2 notification-text"};function cT(t,n,e,r,m,f){const g=St("v-icon"),w=St("v-spacer"),u=St("v-btn"),d=St("v-sheet"),a=St("v-slide-y-transition");return Nn(),co(a,null,{default:Pt(()=>[$l(dt(d,{style:Ia(f.toastStyle),class:"toast-notification",onClick:f.expand},{default:Pt(()=>[dt(g,{class:"mr-1 notification-text"},{default:Pt(()=>[Er(ni(f.toastNotificationIcon),1)]),_:1}),mr("div",{class:"toast-content",style:Ia(f.contentStyle)},[t.toastNotification.title?(Nn(),ti("span",sT,[t.toastNotification.body||t.toastNotification.message?(Nn(),ti(kl,{key:0},[Er(ni(t.toastNotification.title)+": ",1)],64)):(Nn(),ti(kl,{key:1},[Er(ni(t.toastNotification.title),1)],64))])):So("",!0),t.toastNotification.body?(Nn(),ti("span",aT,ni(t.toastNotification.body),1)):So("",!0),t.toastNotification.message?(Nn(),ti("span",lT,ni(t.toastNotification.message),1)):So("",!0)],4),dt(w),dt(u,{variant:"text",class:"notification-text",onClick:Vs(f.hide,["stop"])},{default:Pt(()=>[...n[0]||(n[0]=[Er(" Dismiss ",-1)])]),_:1},8,["onClick"])]),_:1},8,["style","onClick"]),[[Rl,t.showToast]])]),_:1})}const uT=Vo(oT,[["render",cT],["__scopeId","data-v-ef96840d"]]);class hT{constructor(n={}){this.store=null,this.mounted=!1,this.$root=null,window.$cosmosNotify?.$root?(this.mounted=!0,this.$root=window.$cosmosNotify.$root):window.$cosmosNotify=this}getStore(){return this.store||(this.store=Dy()),this.store}mount(){if(this.mounted)return;const n=uu(uT);n.use($d);const e=document.createElement("div");document.querySelector("#openc3-app-toolbar > div").appendChild(e),this.$root=n.mount(e),this.mounted=!0}open({method:n,title:e,body:r,message:m,level:f,duration:g,type:w="alert",logToConsole:u=!1,saveToHistory:d=!0}){this.mount(),u&&console.log(m?`${f.toUpperCase()} - ${m}`:`${f.toUpperCase()} - ${e}: ${r}`),d&&this.getStore().notifyAddHistory({title:e,body:r,message:m,level:f}),this[n]({title:e,body:r,message:m,level:f,duration:g,type:w})}toast({title:n,body:e,message:r,level:m,duration:f,type:g}){this.$root.toast({title:n,body:e,message:r,level:m,type:g},f)}critical({title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w}){this.open({method:"toast",level:"critical",title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w})}FATAL(n){this.critical(n)}ERROR(n){this.critical(n)}serious({title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w}){this.open({method:"toast",level:"serious",title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w})}caution({title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w}){this.open({method:"toast",level:"caution",title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w})}WARN(n){this.caution(n)}normal({title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w}){this.open({method:"toast",level:"normal",title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w})}INFO(n){this.normal(n)}DEBUG(n){this.normal(n)}standby({title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w}){this.open({method:"toast",level:"standby",title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w})}off({title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w}){this.open({method:"toast",level:"off",title:n,body:e,message:r,type:m,duration:f,logToConsole:g,saveToHistory:w})}}const dT={install(t,n){const e=new hT(n);t.provide("notify",e),t.config.globalProperties.hasOwnProperty("$notify")||(t.config.globalProperties.$notify=e)}};function fT(t){$f(`Vuetify: ${t}`)}function nb(t){let n;return t!==null&&typeof t=="object"&&((n=Object.getPrototypeOf(t))===Object.prototype||n===null)}function pT(t,n){const e={};for(const r of n)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}function rb(t={},n={},e,r){const m={};for(const f in t)m[f]=t[f];for(const f in n){const g=n[f],w=t[f];if(nb(w)&&nb(g)){m[f]=rb(w,g);continue}m[f]=g}return m}function ul(t=""){if(ul.cache.has(t))return ul.cache.get(t);const n=t.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return ul.cache.set(t,n),n}ul.cache=new Map;function ib(t,n){return e=>Object.keys(t).reduce((r,m)=>{const f=typeof t[m]=="object"&&t[m]!=null&&!Array.isArray(t[m])?t[m]:{type:t[m]};return e&&m in e?r[m]={...f,default:e[m]}:r[m]=f,n&&!r[m].source&&(r[m].source=n),r},{})}function ob(t,n){const e=If();if(!e)throw new Error(`[Vuetify] ${t} must be called from inside a setup function`);return e}function gT(t,n=ob("injectSelf")){const{provides:e}=n;if(e&&t in e)return e[t]}const Sd=Symbol.for("vuetify:defaults");function sb(){const t=Rf(Sd);if(!t)throw new Error("[Vuetify] Could not find defaults instance");return t}function mT(t,n){return t.props&&(typeof t.props[n]<"u"||typeof t.props[ul(n)]<"u")}function vT(t={},n,e=sb()){const r=ob("useDefaults");if(n=n??r.type.name??r.type.__name,!n)throw new Error("[Vuetify] Could not determine component name");const m=cu(()=>e.value?.[t._as??n]),f=new Proxy(t,{get(u,d){const a=Reflect.get(u,d);if(d==="class"||d==="style")return[m.value?.[d],a].filter(h=>h!=null);if(mT(r.vnode,d))return a;const l=m.value?.[d];if(l!==void 0)return l;const c=e.value?.global?.[d];return c!==void 0?c:a}}),g=Ef();Tf(()=>{if(m.value){const u=Object.entries(m.value).filter(([d])=>d.startsWith(d[0].toUpperCase()));g.value=u.length?Object.fromEntries(u):void 0}else g.value=void 0});function w(){const u=gT(Sd,r);Lf(Sd,cu(()=>g.value?rb(u?.value??{},g.value):u?.value))}return{props:f,provideSubDefaults:w}}function $c(t){if(t._setup=t._setup??t.setup,!t.name)return fT("The component is missing an explicit name, unable to generate default prop value"),t;if(t._setup){t.props=ib(t.props??{},t.name)();const n=Object.keys(t.props).filter(e=>e!=="class"&&e!=="style");t.filterProps=function(e){return pT(e,n)},t.props._as=String,t.setup=function(e,r){const m=sb();if(!m.value)return t._setup(e,r);const{props:f,provideSubDefaults:g}=vT(e,e._as??t.name,m),w=t._setup(f,r);return g(),w}}return t}function yT(t=!0){return n=>(t?$c:Sf)(n)}const bT=[String,Function,Object,Array],Rc=ib({icon:{type:bT},tag:{type:[String,Object,Function],required:!0}},"icon");yT()({name:"VComponentIcon",props:Rc(),setup(t,{slots:n}){return()=>{const e=t.icon;return dt(t.tag,null,{default:()=>[t.icon?dt(e,null,null):n.default?.()]})}}}),$c({name:"VSvgIcon",inheritAttrs:!1,props:Rc(),setup(t,{attrs:n}){return()=>dt(t.tag,Of(n,{style:null}),{default:()=>[mr("svg",{class:"v-icon__svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true"},[Array.isArray(t.icon)?t.icon.map(e=>Array.isArray(e)?mr("path",{d:e[0],"fill-opacity":e[1]},null):mr("path",{d:e},null)):mr("path",{d:t.icon},null)])]})}}),$c({name:"VLigatureIcon",props:Rc(),setup(t){return()=>dt(t.tag,null,{default:()=>[t.icon]})}});const wT=$c({name:"VClassIcon",props:Rc(),setup(t){return()=>dt(t.tag,{class:Mf(t.icon)},null)}}),xT={component:t=>Us(wT,{...t,class:"mdi"})},CT={dark:!0,colors:{primary:"#007ad0",secondary:"#4da3e0",tertiary:"#858585",surface:"#1f1f1f",background:"#161616","on-surface":"#d4d4d4","on-background":"#d4d4d4","openc3-green":"#56f000","openc3-yellow":"#fce83a","openc3-red":"#ff3838","openc3-blue":"#2dccff","openc3-purple":"#c800c8","openc3-black":"#ffffff","openc3-white":"#ffffff"}},AT={dark:!0,colors:{primary:"#5B52E0",secondary:"#8078F0",tertiary:"#7E8696",surface:"#24242F",background:"#1A1A24","on-surface":"#D0D4DC","on-background":"#D0D4DC","openc3-green":"#56f000","openc3-yellow":"#fce83a","openc3-red":"#ff3838","openc3-blue":"#2dccff","openc3-purple":"#c800c8","openc3-black":"#ffffff","openc3-white":"#ffffff"}},_T={dark:!0,colors:{primary:"#0097A7",secondary:"#26C6DA",tertiary:"#708090",surface:"#242D36",background:"#1A2027","on-surface":"#D4DCE4","on-background":"#D4DCE4","openc3-green":"#56f000","openc3-yellow":"#fce83a","openc3-red":"#ff3838","openc3-blue":"#2dccff","openc3-purple":"#c800c8","openc3-black":"#ffffff","openc3-white":"#ffffff"}},kT={dark:!0,colors:{primary:"#00897B",secondary:"#26A69A",tertiary:"#6E7680",surface:"#222428",background:"#181A1C","on-surface":"#D4D8DC","on-background":"#D4D8DC","openc3-green":"#56f000","openc3-yellow":"#fce83a","openc3-red":"#ff3838","openc3-blue":"#2dccff","openc3-purple":"#c800c8","openc3-black":"#ffffff","openc3-white":"#ffffff"}},$d=zf({theme:{defaultTheme:"cosmosDark",themes:{cosmosDark:JE,cosmosDarkCobalt:CT,cosmosDarkIndigo:AT,cosmosDarkSlate:_T,cosmosDarkEmerald:kT}},defaults:{VCheckbox:{color:"secondary"},VCheckboxBtn:{color:"secondary"},VRadio:{color:"secondary"},VRadioGroup:{color:"secondary"},VSwitch:{color:"secondary"}},icons:{defaultSet:"mdi",sets:{mdi:xT,...nE,...rE}}}),Rd=rw({createApp:uu,appOptions:{render(){return Us(hw,{})},el:"#openc3-tool"},handleInstance:t=>{t.use(yE),t.use(fa),t.use($d),t.use(iT),t.use(dT)}}),_D=On("d",Rd.bootstrap),kD=On("n",Rd.mount),SD=On("s",Rd.unmount)})}}));