openc3-cosmos-tool-cmdtlmserver 7.4.0 → 7.5.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 (116) hide show
  1. checksums.yaml +4 -4
  2. data/tools/cmdtlmserver/{ArrayWidget-CIDdZjk3-e93771de14c32c248c92.js → ArrayWidget-9OSo49r--717a71fa5a93a4306ec7.js} +2 -2
  3. data/tools/cmdtlmserver/{ArrayplotWidget-BfO1atvG-8b8fb63663cdcaf7deb3.js → ArrayplotWidget-D5C_WTX2-8ef1f79db3f1944b9c0b.js} +1 -1
  4. data/tools/cmdtlmserver/{BarColumn-CHX_3ye3-bd438bf972b67e4ed46c.js → BarColumn-CvHnnifr-c4951578f3fd3f76bfc6.js} +1 -1
  5. data/tools/cmdtlmserver/{BlockWidget-DSbunlY_-8140c3fc46c60895b065.js → BlockWidget-DuEDZ4dJ-967eda15c1451fca34fa.js} +2 -2
  6. data/tools/cmdtlmserver/{ButtonWidget-BB4ZOCI8-877b51169cdd22a77791.js → ButtonWidget-CZIUtd9z-61acef92520109286c0d.js} +1 -1
  7. data/tools/cmdtlmserver/CanvasWidget-C4-pXiKY-264004bbfd5904f1e69d.js +1 -0
  8. data/tools/cmdtlmserver/CanvasdotWidget-Bh0HHx67-b6476c69d59257ab08bc.js +1 -0
  9. data/tools/cmdtlmserver/{CanvasimageWidget-DY1DDf0a-a34fd029ec2d25c17273.js → CanvasimageWidget-Bu5NmsDs-cda2f1f9742ea195853b.js} +1 -1
  10. data/tools/cmdtlmserver/{CanvasimagevalueWidget-0lc2cCPV-2e9d2826ca46f991f111.js → CanvasimagevalueWidget-Dv8dQrnj-0b0689a4caece450db22.js} +1 -1
  11. data/tools/cmdtlmserver/CanvaslabelWidget-68IeeM3a-d8ee974f80ae555b6320.js +1 -0
  12. data/tools/cmdtlmserver/{CanvaslabelvalueWidget-Cf_dcDW2-bdf8b368fdb1fa71ebca.js → CanvaslabelvalueWidget-C6j_A4z6-2d9163c26db0115868c1.js} +1 -1
  13. data/tools/cmdtlmserver/{CanvaslineWidget-jg2ozQ0N-eb531c51bbb4d3dc6a91.js → CanvaslineWidget-BgQ6wLDv-6f3059055f7afe642488.js} +1 -1
  14. data/tools/cmdtlmserver/{CanvaslinevalueWidget-CKpjqlKA-17dde2a6a449ad806015.js → CanvaslinevalueWidget-C6-HkTJp-5717f7b45d0b57a344a4.js} +1 -1
  15. data/tools/cmdtlmserver/CheckbuttonWidget-DJmT73t9-dc118daa630bbe52aa2d.js +1 -0
  16. data/tools/cmdtlmserver/{CmdPacketsTab-f0d7bb17079717aaa76e.js → CmdPacketsTab-6f0b12d43c14a7da6718.js} +1 -1
  17. data/tools/cmdtlmserver/{CmdTlmServer-32bff3fcc4b2ce263346.js → CmdTlmServer-af3b7b8e2ea9bae2b3bd.js} +2 -2
  18. data/tools/cmdtlmserver/{ComboboxWidget-BzKkyRDT-d2609655726e617e6140.js → ComboboxWidget-vTtsjxRm-a15e957bce84abaae94e.js} +1 -1
  19. data/tools/cmdtlmserver/{DataFlowsTab-f8fa7ccddb2e11c0f4bd.js → DataFlowsTab-11ed530e003aefd013b6.js} +1 -1
  20. data/tools/cmdtlmserver/DateWidget-BjKIDtsf-a0a25d555d3032f182ea.js +1 -0
  21. data/tools/cmdtlmserver/{DetailsDialog-CLPj0nP0-a923096c03a16ab24ce5.js → DetailsDialog-S1nw1d0h-f0e9c707fdcfdc375368.js} +1 -1
  22. data/tools/cmdtlmserver/{DynamicWidget-yna_ejyc-67de1a2e4d3ca8e77d13.js → DynamicWidget-yna_ejyc-303515b4f32d2d98c6ee.js} +1 -1
  23. data/tools/cmdtlmserver/{FilechecksumWidget-DqNThsOX-9a244d23a05ba0cd4bc2.js → FilechecksumWidget-obppYSP4-700a6df90c74ce721080.js} +1 -1
  24. data/tools/cmdtlmserver/{FiledisplayWidget-BRhhiVEs-8aee77b81ad52706adde.js → FiledisplayWidget-BstroKFo-1648b09c912608be064e.js} +1 -1
  25. data/tools/cmdtlmserver/{FormatvalueWidget-pEjAh0h2-a8635e2292e64cf5e39f.js → FormatvalueWidget-MJIJg6Bf-0cd3eaea15a6bcd3ae72.js} +1 -1
  26. data/tools/cmdtlmserver/Graph-BL-czUPp-f5cc2eb30bdaad73b5ea.js +1 -0
  27. data/tools/cmdtlmserver/{GraphWidget-BZjBkefj-d9dcbf0fe719cf812d83.js → GraphWidget-C8KRp-QN-c0cd6dae0bf948656c58.js} +1 -1
  28. data/tools/cmdtlmserver/{HorizontalWidget-Brag6E4y-48ed7a3d841d69afb943.js → HorizontalWidget-Cn9qnYVh-badf3d172451b91a6d6f.js} +1 -1
  29. data/tools/cmdtlmserver/{HorizontalboxWidget-BnkH4cVq-a81cc9f7c04e629754a0.js → HorizontalboxWidget-gz8uYYFZ-96c1c64165978ab6eb9e.js} +1 -1
  30. data/tools/cmdtlmserver/HorizontallineWidget-CrDua5-L-debe3a4eea3dca880b37.js +1 -0
  31. data/tools/cmdtlmserver/{IframeWidget-Ciu5u58E-f35e28d26845c9ce425c.js → IframeWidget-CtS7MjKL-d9da1888b15c35e9c70b.js} +1 -1
  32. data/tools/cmdtlmserver/ImageLoader-Vpn27aUN-3490506bebda6aeb65a9.js +1 -0
  33. data/tools/cmdtlmserver/{ImageviewerWidget-vWMGPveb-3e068b180f6cf32ccd24.js → ImageviewerWidget-Kmzt8wuP-cc3b7e2f8ed939331fe4.js} +1 -1
  34. data/tools/cmdtlmserver/InterfaceFlowChart-50ef94018198e0750f4e.js +27 -0
  35. data/tools/cmdtlmserver/InterfacesTab-06eb69d86c8c7763e5cf.js +1 -0
  36. data/tools/cmdtlmserver/{LabelWidget-DVp0CmFH-97b4d14caae36b2b70fe.js → LabelWidget-DIZpHxYX-271eae93ef3508c18934.js} +1 -1
  37. data/tools/cmdtlmserver/LabelledWidget-CGxDI8XZ-eaf078ad95a37f4eeb80.js +1 -0
  38. data/tools/cmdtlmserver/{LabelprogressbarWidget-DME-BrZe-03f95b34969c5b14cff6.js → LabelprogressbarWidget-CXOc5p8G-b43b9d95abd873ade105.js} +1 -1
  39. data/tools/cmdtlmserver/LabelsparklineWidget-B_LuqFcA-1606a15bb9d50691d10e.js +1 -0
  40. data/tools/cmdtlmserver/LabelvalueWidget--G4wHMZL-160516ab83399994b95e.js +1 -0
  41. data/tools/cmdtlmserver/{LabelvaluedescWidget-c5BUCRxB-2656a7bcfe6096dc52cd.js → LabelvaluedescWidget-DqLK0wvi-b6d7c8ef799c34a4fb16.js} +1 -1
  42. data/tools/cmdtlmserver/LabelvaluelimitsbarWidget-BWOQJkLP-e669bc66e0d31684a5b1.js +1 -0
  43. data/tools/cmdtlmserver/LabelvaluelimitscolumnWidget-BfF73Y2F-191505c7e8b4e463139d.js +1 -0
  44. data/tools/cmdtlmserver/LabelvaluerangebarWidget-CKsFRW6t-5d1f6dbda4b998ccdabd.js +1 -0
  45. data/tools/cmdtlmserver/{Layout-Df-lJgpB-914d505c295d7f5a9791.js → Layout-CGL1JfeU-73de442baff32d7d5e6d.js} +1 -1
  46. data/tools/cmdtlmserver/{LedWidget-C97EJXBo-ce386ba85aedd75e9d27.js → LedWidget-DrAJ8_fN-c3588bb9b46e0569d22d.js} +1 -1
  47. data/tools/cmdtlmserver/{LimitsBar-DNV39okL-cd07952d9c04ed1affbf.js → LimitsBar-CxPzG0Zv-7f26c239a2c59217ec3d.js} +1 -1
  48. data/tools/cmdtlmserver/{LimitsbarWidget-BIO6xztx-28058ac54835f172dbaf.js → LimitsbarWidget-1IayV5D7-e6979d0bff067d206a17.js} +1 -1
  49. data/tools/cmdtlmserver/{LimitscolorWidget-BGrNA65J-a076cfb171ef2babaa50.js → LimitscolorWidget-C7LY3BQ7-a99b7c32677dc6dd0e0c.js} +1 -1
  50. data/tools/cmdtlmserver/{LimitscolumnWidget-Bw6EXJs9-d6e1e239d7c084c9f7bf.js → LimitscolumnWidget-JhIc5Sjl-3b17971ca7ecfc14b21e.js} +1 -1
  51. data/tools/cmdtlmserver/{LinegraphWidget-Drf9tTPN-7c9a449d8dd3306582bf.js → LinegraphWidget-BaROxuUn-59d99dd742687e40b25c.js} +1 -1
  52. data/tools/cmdtlmserver/{MatrixbycolumnsWidget-C33-g7kK-76c56ce004a1c3313336.js → MatrixbycolumnsWidget-i0gGPMOV-10eb0a46073fb0d00269.js} +1 -1
  53. data/tools/cmdtlmserver/{OpenC3TimePicker-cOr0aOVn-5ffe76ce1ab1f7ec0439.js → OpenC3TimePicker-DDTLwTEw-8a687401b8e481dd9f49.js} +1 -1
  54. data/tools/cmdtlmserver/{ProgressbarWidget-DqfSMI10-ce9c22710e61dc0b0e7c.js → ProgressbarWidget-QxEq8C4A-6708ed1493b466f3ad73.js} +1 -1
  55. data/tools/cmdtlmserver/{RadiobuttonWidget-CSQeEacF-29953a844e8a06d304b9.js → RadiobuttonWidget-DYf3qvBq-c45fbd59c85839b1c318.js} +1 -1
  56. data/tools/cmdtlmserver/RadiogroupWidget-C0b_ckej-49f9b3ab6551820edc3b.js +1 -0
  57. data/tools/cmdtlmserver/{RangebarWidget-CJSUof1--8b45d597a2fa911a953e.js → RangebarWidget-DcSEHktI-3e039851d9a494b6e2ae.js} +1 -1
  58. data/tools/cmdtlmserver/{RawBuffer-d28de8d99b97e4d9e74a.js → RawBuffer-20fcdaa013d70717df58.js} +1 -1
  59. data/tools/cmdtlmserver/{RawDialog-d0bdc67425dd15985b00.js → RawDialog-6255b78ac1df55878a41.js} +1 -1
  60. data/tools/cmdtlmserver/{RollupWidget-C977Lkcx-5ea74809c15bc60824cc.js → RollupWidget-AVS4drYX-b0a691257195289fcde6.js} +1 -1
  61. data/tools/cmdtlmserver/RoutersTab-516132811cc284689266.js +1 -0
  62. data/tools/cmdtlmserver/{ScrollwindowWidget-BFxz61oW-6a02d29fb76c6bc1625a.js → ScrollwindowWidget-Dpf3BScA-1f5fbe37bb33cad8cf87.js} +1 -1
  63. data/tools/cmdtlmserver/{SignalWidget-BT6AcbBx-2f3a2c5e5b84c96df438.js → SignalWidget-Q1YtPsNw-e755da3f6cb293fbfb21.js} +1 -1
  64. data/tools/cmdtlmserver/SpacerWidget-DGEOqhu_-b6e91ca4474e9fced162.js +1 -0
  65. data/tools/cmdtlmserver/SparklineWidget-DbNWbNzY-7b515c109437aabe3fd7.js +1 -0
  66. data/tools/cmdtlmserver/{StatusTab-575b3032342d08db5f96.js → StatusTab-8631fd8a07a20ba8efba.js} +1 -1
  67. data/tools/cmdtlmserver/TabbookWidget-CrkPPZIF-e6f81964bd00b58621c6.js +1 -0
  68. data/tools/cmdtlmserver/{TargetsTab-b9f1a2b988ce8badd79d.js → TargetsTab-266cdd09e5f9024e2e14.js} +1 -1
  69. data/tools/cmdtlmserver/TextboxWidget-CfQEzaRr-e866fabef32754083217.js +1 -0
  70. data/tools/cmdtlmserver/TextfieldWidget-BQL8dOTg-c36896326e3dd7157a9b.js +1 -0
  71. data/tools/cmdtlmserver/{TimeWidget-BTaXBxVm-c61be141d1e5cc25062c.js → TimeWidget-DiE_oc7J-bb6ed7460bd103205f07.js} +1 -1
  72. data/tools/cmdtlmserver/TitleWidget-C5a_ZsqM-2cd2d562e7df0e7c2632.js +1 -0
  73. data/tools/cmdtlmserver/{TlmPacketsTab-f24389ab30f97699f498.js → TlmPacketsTab-a593eaef44a42f06465a.js} +1 -1
  74. data/tools/cmdtlmserver/{Updater-f4069804660e1d2bb1fb.js → Updater-72956875f00bf04ede7a.js} +1 -1
  75. data/tools/cmdtlmserver/VWidget-D4ipW0SF-3c58c7bbca21ca655106.js +1 -0
  76. data/tools/cmdtlmserver/ValueWidget-9JNo-Sk8-ad0f7e86109c8aa425a5.js +1 -0
  77. data/tools/cmdtlmserver/{ValuelimitsbarWidget-CqRkPwWS-51f01694576524ab034a.js → ValuelimitsbarWidget-CqiFVnaT-548886eac7b4e05b16a7.js} +1 -1
  78. data/tools/cmdtlmserver/ValuelimitscolumnWidget-DWDFVRNg-27123b8e5c3ac13ee8c8.js +1 -0
  79. data/tools/cmdtlmserver/ValuerangebarWidget-BAVMrD0L-ab4e3bf7f05c9ddde140.js +1 -0
  80. data/tools/cmdtlmserver/{VerticalWidget-CoJiy2TT-aaba0f3431f867ad36d1.js → VerticalWidget-Dw0j42K2-a0e847b1aea8f4d4919f.js} +1 -1
  81. data/tools/cmdtlmserver/{VerticalboxWidget-BD5Eq3BH-8de3b73d0af06049b633.js → VerticalboxWidget-xusQtXo0-16edecad2b21c8c04312.js} +1 -1
  82. data/tools/cmdtlmserver/{Widget-ClRi417b-9e12a24a4c1c96620549.js → Widget-Dy-YgkeU-68b553c0438f37998671.js} +1 -1
  83. data/tools/cmdtlmserver/main-19e35e0fd00beb1bdc37.js +1493 -0
  84. data/tools/cmdtlmserver/main.js +1 -1
  85. data/tools/cmdtlmserver/services-31b16a6b1924df6608ce.js +10 -0
  86. metadata +84 -84
  87. data/tools/cmdtlmserver/CanvasWidget-DsyMt7xW-7cfb9d7eaec179010426.js +0 -1
  88. data/tools/cmdtlmserver/CanvasdotWidget-BZpkCAoH-adf05ba917ad02a80cab.js +0 -1
  89. data/tools/cmdtlmserver/CanvaslabelWidget-C6TDW9WO-da217b5f77c7ca2537f1.js +0 -1
  90. data/tools/cmdtlmserver/CheckbuttonWidget-BWXinMaT-a54626829bc2de216d16.js +0 -1
  91. data/tools/cmdtlmserver/DateWidget-qUbLzQsX-b058fb471e3fcd797726.js +0 -1
  92. data/tools/cmdtlmserver/Graph-GVQZltap-916f8970fd5d42822d89.js +0 -1
  93. data/tools/cmdtlmserver/HorizontallineWidget-k7fL4EPN-3583b50d2753936758e5.js +0 -1
  94. data/tools/cmdtlmserver/ImageLoader-DH5e4lg8-3426a1c0f41a2bf44392.js +0 -1
  95. data/tools/cmdtlmserver/InterfaceFlowChart-9ca67c593f3f2b877ee3.js +0 -27
  96. data/tools/cmdtlmserver/InterfacesTab-b3f53afb2ca5b30d2920.js +0 -1
  97. data/tools/cmdtlmserver/LabelledWidget-1DeE1-6G-12aab221c27e077c7d31.js +0 -1
  98. data/tools/cmdtlmserver/LabelsparklineWidget-4iDHGnPL-f5ce9a4673c260d290c5.js +0 -1
  99. data/tools/cmdtlmserver/LabelvalueWidget-C6NQSHTb-84fc8a12ee8e4f0de54c.js +0 -1
  100. data/tools/cmdtlmserver/LabelvaluelimitsbarWidget-DBKZLpXJ-af39812293b33f70b279.js +0 -1
  101. data/tools/cmdtlmserver/LabelvaluelimitscolumnWidget-NdEu06go-fef2aa9ed08cdf93d61d.js +0 -1
  102. data/tools/cmdtlmserver/LabelvaluerangebarWidget-CL5HLK0t-5e27588fee9cb4b7e9b8.js +0 -1
  103. data/tools/cmdtlmserver/RadiogroupWidget-DlQN9z-Z-bf4604885d001ad1f14f.js +0 -1
  104. data/tools/cmdtlmserver/RoutersTab-06e215b54b2908b15301.js +0 -1
  105. data/tools/cmdtlmserver/SpacerWidget-B_f09KAi-d35a958be49dff620492.js +0 -1
  106. data/tools/cmdtlmserver/SparklineWidget-Bji9DILO-bc83a95dc405fc0453c5.js +0 -1
  107. data/tools/cmdtlmserver/TabbookWidget-B74U8t2i-9274e9ec55c4292f274e.js +0 -1
  108. data/tools/cmdtlmserver/TextboxWidget-CbKE9aSW-41ad0a5667b4b674d749.js +0 -1
  109. data/tools/cmdtlmserver/TextfieldWidget-CpdmfNk5-5fd1754fbc27b848e303.js +0 -1
  110. data/tools/cmdtlmserver/TitleWidget-ulO_gdVY-db3241f7de1f3c57a698.js +0 -1
  111. data/tools/cmdtlmserver/VWidget-C4VLQ7-b-4ba9d3f0cbd835b6e437.js +0 -1
  112. data/tools/cmdtlmserver/ValueWidget-B3-Jjoux-a1da92404f65428e9c38.js +0 -1
  113. data/tools/cmdtlmserver/ValuelimitscolumnWidget-CF4CN14a-7d5d1d7a571bb56f6f9b.js +0 -1
  114. data/tools/cmdtlmserver/ValuerangebarWidget-DJtrknKH-4e5ab6bdc8c7135368d5.js +0 -1
  115. data/tools/cmdtlmserver/main-c7bd98cfab79a58efd19.js +0 -1493
  116. data/tools/cmdtlmserver/services-cd44604ec0d9ce785778.js +0 -10
@@ -0,0 +1,1493 @@
1
+ System.register(["vue","vue-router","pinia","single-spa","vuetify"],(function(lr,ht){"use strict";var In,wt,er,sn,Ge,Xt,gt,Fg,jg,Eo,Un,Ir,Wi,xr,qr,Wg,Hi,nn,vt,wi,Hg,Tl,Zs,Lt,ai,za,Fc,El,Ls,Ht,Ba,jc,Ug,Xs,Il,Fa,Vg,cs,jh,Gg,qg,Yg,ea,Wh,Kg,Jg,Qg,fr,Zg,an,Hh,Xg,xi,em,Ml,Wc,ja,tm,Uh,nm,rm,im,om,Vh,sm;return{setters:[lt=>{In=lt.resolveComponent,wt=lt.openBlock,er=lt.createBlock,sn=lt.withCtx,Ge=lt.createVNode,Xt=lt.createElementBlock,gt=lt.createElementVNode,Fg=lt.useCssVars,jg=lt.defineAsyncComponent,Eo=lt.h,Un=lt.normalizeStyle,Ir=lt.Fragment,Wi=lt.createTextVNode,xr=lt.toDisplayString,qr=lt.createCommentVNode,Wg=lt.toRefs,Hi=lt.shallowRef,nn=lt.ref,vt=lt.computed,wi=lt.watch,Hg=lt.onBeforeMount,Tl=lt.nextTick,Zs=lt.onBeforeUnmount,Lt=lt.toRef,ai=lt.watchEffect,za=lt.isVNode,Fc=lt.TransitionGroup,El=lt.Transition,Ls=lt.defineComponent,Ht=lt.unref,Ba=lt.provide,jc=lt.isRef,Ug=lt.getCurrentInstance,Xs=lt.inject,Il=lt.reactive,Fa=lt.onMounted,Vg=lt.onUpdated,cs=lt.toValue,jh=lt.onScopeDispose,Gg=lt.readonly,qg=lt.toRaw,Yg=lt.useId,ea=lt.resolveDynamicComponent,Wh=lt.capitalize,Kg=lt.camelize,Jg=lt.markRaw,Qg=lt.warn,fr=lt.mergeProps,Zg=lt.effectScope,an=lt.normalizeClass,Hh=lt.createApp,Xg=lt.withKeys,xi=lt.renderSlot,em=lt.useAttrs,Ml=lt.renderList,Wc=lt.normalizeProps,ja=lt.withDirectives,tm=lt.Text,Uh=lt.vShow},lt=>{nm=lt.createRouter,rm=lt.createWebHistory},lt=>{im=lt.defineStore,om=lt.createPinia},lt=>{Vh=lt.getMountedApps},lt=>{sm=lt.createVuetify}],execute:(function(){lr({B:jv,D:qa,F:sv,G:Yv,H:Wv,J:li,K:Kv,S:wd,Z:Jv,d:Vl,e:Fv,l:Jr,n:S0,o:Ga,s:qo,v:Cd});var lt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function am(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(c){return Object.getOwnPropertyDescriptor(e,c).enumerable}))),t.push.apply(t,r)}return t}function ta(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?arguments[n]:{};n%2?am(Object(t),!0).forEach((function(r){ck(e,r,t[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):am(Object(t)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}))}return e}function ck(e,n,t){return(n=(function(r){var c=(function(h,g){if(na(h)!=="object"||h===null)return h;var v=h[Symbol.toPrimitive];if(v!==void 0){var s=v.call(h,g);if(na(s)!=="object")return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return(g==="string"?String:Number)(h)})(r,"string");return na(c)==="symbol"?c:String(c)})(n))in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function na(e){return na=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},na(e)}(function(e){if(e.CSS&&e.CSS.escape)return e.CSS.escape;var n=function(t){if(arguments.length==0)throw new TypeError("`CSS.escape` requires an argument.");for(var r,c=String(t),h=c.length,g=-1,v="",s=c.charCodeAt(0);++g<h;)(r=c.charCodeAt(g))!=0?v+=r>=1&&r<=31||r==127||g==0&&r>=48&&r<=57||g==1&&r>=48&&r<=57&&s==45?"\\"+r.toString(16)+" ":g==0&&h==1&&r==45||!(r>=128||r==45||r==95||r>=48&&r<=57||r>=65&&r<=90||r>=97&&r<=122)?"\\"+c.charAt(g):c.charAt(g):v+="�";return v};e.CSS||(e.CSS={}),e.CSS.escape=n})(lt);var uk={appOptions:null,template:null,Vue:null,createApp:null,handleInstance:null};function hk(e){if(na(e)!=="object")throw new Error("single-spa-vue requires a configuration object");var n=ta(ta({},uk),e);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(na(n.appOptions.el)));n.createApp=n.createApp||n.Vue&&n.Vue.createApp;var t={};return{bootstrap:dk.bind(null,n,t),mount:fk.bind(null,n,t),unmount:gk.bind(null,n,t),update:pk.bind(null,n,t)}}function dk(e){return e.loadRootComponent?e.loadRootComponent().then((function(n){return e.rootComponent=n})):Promise.resolve()}function fk(e,n,t){var r={};return Promise.resolve().then((function(){return(function(c,h){return typeof c.appOptions=="function"?c.appOptions(h):Promise.resolve(ta({},c.appOptions))})(e,t).then((function(c){var h;if(t.domElement&&!c.el&&(c.el=t.domElement),c.el)if(typeof c.el=="string"){if(!(h=document.querySelector(c.el)))throw Error("If appOptions.el is provided to single-spa-vue, the dom element must exist in the dom. Was provided as ".concat(c.el))}else(h=c.el).id||(h.id="single-spa-application:".concat(t.name)),c.el="#".concat(CSS.escape(h.id));else{var g="single-spa-application:".concat(t.name);c.el="#".concat(CSS.escape(g)),(h=document.getElementById(g))||((h=document.createElement("div")).id=g,document.body.appendChild(h))}if(!e.replaceMode&&(c.el=c.el+" .single-spa-container",!h.querySelector(".single-spa-container"))){var v=document.createElement("div");v.className="single-spa-container",h.appendChild(v)}r.domEl=h,c.render||c.template||!e.rootComponent||(c.render=function(p){return p(e.rootComponent)}),c.data||(c.data={});var s=c.data;if(c.data=function(){return ta(ta({},typeof s=="function"?s.call(this,this):s),t)},e.createApp){if(r.vueInstance=e.createApp(c),e.handleInstance)return Promise.resolve(e.handleInstance(r.vueInstance,t)).then((function(){return r.root=r.vueInstance.mount(c.el),n[t.name]=r,r.vueInstance}));r.root=r.vueInstance.mount(c.el)}else if(r.vueInstance=new e.Vue(c),r.vueInstance.bind&&(r.vueInstance=r.vueInstance.bind(r.vueInstance)),e.handleInstance)return Promise.resolve(e.handleInstance(r.vueInstance,t)).then((function(){return n[t.name]=r,r.vueInstance}));return n[t.name]=r,r.vueInstance}))}))}function pk(e,n,t){return Promise.resolve().then((function(){var r=n[t.name],c=ta(ta({},e.appOptions.data||{}),t),h=r.root||r.vueInstance;for(var g in c)h[g]=c[g]}))}function gk(e,n,t){return Promise.resolve().then((function(){var r=n[t.name];e.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 mk=lr("_",(e,n)=>{const t=e.__vccOpts||e;for(const[r,c]of n)t[r]=c;return t}),vk={};function yk(e,n){const t=In("router-view"),r=In("v-app");return wt(),er(r,{id:"innerapp"},{default:sn(()=>[Ge(t)]),_:1})}const bk=mk(vk,[["render",yk]]),JW="modulepreload",QW=function(e){return"/"+e},ZW={},dt=function(n,t,r){let c=Promise.resolve();function h(g){const v=new Event("vite:preloadError",{cancelable:!0});if(v.payload=g,window.dispatchEvent(v),!v.defaultPrevented)throw g}return c.then(g=>{for(const v of g||[])v.status==="rejected"&&h(v.reason);return n().catch(h)})},lm=function(e){e.name!=="NotFound"&&(e.path=`/tools/cmdtlmserver/${e.path.replace(/^\//,"")}`),e.children?.forEach(lm)},ra=lr("h",(e,n)=>{const t=e.__vccOpts||e;for(const[r,c]of n)t[r]=c;return t}),wk="/icons/customIcons.svg",Gh={props:{icon:{type:String,default:null},size:{type:String,default:"small"},color:{type:String,default:"white"}},computed:{iconSrc:function(){return wk+"#"+this.icon}}},cm=()=>{Fg(e=>({v4ccb3d08:e.color}))},um=Gh.setup;Gh.setup=um?(e,n)=>(cm(),um(e,n)):cm;const xk={class:"cosmos-custom-icon"},Ck={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",preserveAspectRatio:"xMidYMid meet",focusable:"false"},kk=["href"];function _k(e,n,t,r,c,h){return wt(),Xt("span",xk,[(wt(),Xt("svg",Ck,[gt("use",{href:h.iconSrc},null,8,kk)]))])}const Ak=ra(Gh,[["render",_k],["__scopeId","data-v-54b83b01"]]);function hm(e,n){return function(){return e.apply(n,arguments)}}const{toString:$k}=Object.prototype,{getPrototypeOf:Os}=Object,{iterator:Rl,toStringTag:dm}=Symbol,Ll=(({hasOwnProperty:e})=>(n,t)=>e.call(n,t))(Object.prototype),fm=e=>typeof e=="string"&&(e==="__proto__"||e==="constructor"||e==="prototype"),pm=(e,n,t)=>e===Object.prototype||!t&&n===null,Sk=e=>{if(!Object.isExtensible(e))return!1;const n=Object.getOwnPropertyNames(e);return Object.getOwnPropertySymbols&&n.push(...Object.getOwnPropertySymbols(e)),n.every(t=>{if(fm(t))return!1;const r=Object.getOwnPropertyDescriptor(e,t);return!!r&&r.configurable&&r.writable===!0})},Ol=(e,n)=>{let t=e;const r=[];for(;t!=null;){if(r.indexOf(t)!==-1)return!1;r.push(t);const c=Os(t);if(pm(t,c,t===e))return!1;if(Ll(t,n))return!0;t=c}return!1},Tk=(e,n)=>e!=null&&Ol(e,n)?e[n]:void 0,Ek=e=>{if(e==null||typeof e!="object"&&typeof e!="function")return e;const n=Os(e);if(n===null&&Sk(e))return e;const t=Object.create(null),r=Object.create(null),c=[];let h=e;for(;h!=null&&c.indexOf(h)===-1;){c.push(h);const g=h===e?n:Os(h);if(pm(h,g,h===e))break;const v=Object.getOwnPropertyNames(h);Object.getOwnPropertySymbols&&v.push(...Object.getOwnPropertySymbols(h));for(const s of v)fm(s)||Ll(r,s)||(t[s]=e[s],r[s]=!0);h=g}return t},qh=(e=>n=>{const t=$k.call(n);return e[t]||(e[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),ao=e=>(e=e.toLowerCase(),n=>qh(n)===e),Hc=e=>n=>typeof n===e,{isArray:ia}=Array,oa=Hc("undefined");function Wa(e){return e!==null&&!oa(e)&&e.constructor!==null&&!oa(e.constructor)&&Ci(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const gm=ao("ArrayBuffer");function Ik(e){let n;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?n=ArrayBuffer.isView(e):n=e&&e.buffer&&gm(e.buffer),n}const Mk=Hc("string"),Ci=Hc("function"),mm=Hc("number"),Ha=e=>e!==null&&typeof e=="object",Rk=e=>e===!0||e===!1,Uc=e=>{if(!Ha(e))return!1;const n=Os(e);return(n===null||n===Object.prototype||Os(n)===null)&&!Ol(e,dm)&&!Ol(e,Rl)},Lk=e=>{if(!Ha(e)||Wa(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},Ok=ao("Date"),Nk=ao("File"),Dk=e=>!!(e&&typeof e.uri<"u"),Pk=e=>e&&typeof e.getParts<"u",zk=ao("Blob"),Bk=ao("FileList"),Fk=ao("Set"),jk=e=>Ha(e)&&Ci(e.pipe);function Wk(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}const vm=Wk(),ym=typeof vm.FormData<"u"?vm.FormData:void 0,Hk=e=>{if(!e)return!1;if(ym&&e instanceof ym)return!0;const n=Os(e);if(!n||n===Object.prototype||!Ci(e.append))return!1;const t=qh(e);return t==="formdata"||t==="object"&&Ci(e.toString)&&e.toString()==="[object FormData]"},Uk=ao("URLSearchParams"),[Vk,Gk,qk,Yk]=["ReadableStream","Request","Response","Headers"].map(ao),Kk=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Nl(e,n,{allOwnKeys:t=!1}={}){if(e===null||typeof e>"u")return;let r,c;if(typeof e!="object"&&(e=[e]),ia(e))for(r=0,c=e.length;r<c;r++)n.call(null,e[r],r,e);else{if(Wa(e))return;const h=t?Object.getOwnPropertyNames(e):Object.keys(e),g=h.length;let v;for(r=0;r<g;r++)v=h[r],n.call(null,e[v],v,e)}}function bm(e,n){if(Wa(e))return null;n=n.toLowerCase();const t=Object.keys(e);let r=t.length,c;for(;r-- >0;)if(c=t[r],n===c.toLowerCase())return c;return null}const sa=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,wm=e=>!oa(e)&&e!==sa;function Yh(...e){const{caseless:n,skipUndefined:t}=wm(this)&&this||{},r={},c=(h,g)=>{if(g==="__proto__"||g==="constructor"||g==="prototype")return;const v=n&&typeof g=="string"&&bm(r,g)||g,s=Ll(r,v)?r[v]:void 0;Uc(s)&&Uc(h)?r[v]=Yh(s,h):Uc(h)?r[v]=Yh({},h):ia(h)?r[v]=h.slice():(!t||!oa(h))&&(r[v]=h)};for(let h=0,g=e.length;h<g;h++){const v=e[h];if(!v||Wa(v)||(Nl(v,c),typeof v!="object"||ia(v)))continue;const s=Object.getOwnPropertySymbols(v);for(let p=0;p<s.length;p++){const a=s[p];a_.call(v,a)&&c(v[a],a)}}return r}const Jk=(e,n,t,{allOwnKeys:r}={})=>(Nl(n,(c,h)=>{t&&Ci(c)?Object.defineProperty(e,h,{__proto__:null,value:hm(c,t),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,h,{__proto__:null,value:c,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),Qk=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Zk=(e,n,t,r)=>{e.prototype=Object.create(n.prototype,r),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:n.prototype}),t&&Object.assign(e.prototype,t)},Xk=(e,n,t,r)=>{let c,h,g;const v={};if(n=n||{},e==null)return n;do{for(c=Object.getOwnPropertyNames(e),h=c.length;h-- >0;)g=c[h],(!r||r(g,e,n))&&!v[g]&&(n[g]=e[g],v[g]=!0);e=t!==!1&&Os(e)}while(e&&(!t||t(e,n))&&e!==Object.prototype);return n},e_=(e,n,t)=>{e=String(e),(t===void 0||t>e.length)&&(t=e.length),t-=n.length;const r=e.indexOf(n,t);return r!==-1&&r===t},t_=e=>{if(!e)return null;if(ia(e))return e;let n=e.length;if(!mm(n))return null;const t=new Array(n);for(;n-- >0;)t[n]=e[n];return t},n_=(e=>n=>e&&n instanceof e)(typeof Uint8Array<"u"&&Os(Uint8Array)),r_=(e,n)=>{const t=(e&&e[Rl]).call(e);let r;for(;(r=t.next())&&!r.done;){const c=r.value;n.call(e,c[0],c[1])}},i_=(e,n)=>{let t;const r=[];for(;(t=e.exec(n))!==null;)r.push(t);return r},o_=ao("HTMLFormElement"),s_=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,t,r){return t.toUpperCase()+r}),{propertyIsEnumerable:a_}=Object.prototype,l_=ao("RegExp"),xm=(e,n)=>{const t=Object.getOwnPropertyDescriptors(e),r={};Nl(t,(c,h)=>{let g;(g=n(c,h,e))!==!1&&(r[h]=g||c)}),Object.defineProperties(e,r)},c_=e=>{xm(e,(n,t)=>{if(Ci(e)&&["arguments","caller","callee"].includes(t))return!1;const r=e[t];if(Ci(r)){if(n.enumerable=!1,"writable"in n){n.writable=!1;return}n.set||(n.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},u_=(e,n)=>{const t={},r=c=>{c.forEach(h=>{t[h]=!0})};return ia(e)?r(e):r(String(e).split(n)),t},h_=()=>{},d_=(e,n)=>e!=null&&Number.isFinite(e=+e)?e:n;function f_(e){return!!(e&&Ci(e.append)&&e[dm]==="FormData"&&e[Rl])}const p_=e=>{const n=new WeakSet,t=r=>{if(Ha(r)){if(n.has(r))return;if(Wa(r))return r;if(!("toJSON"in r)){n.add(r);let c;if(Fk(r)){c=[];for(const h of r){const g=t(h);!oa(g)&&c.push(g)}}else c=ia(r)?[]:{},Nl(r,(h,g)=>{const v=t(h);!oa(v)&&(c[g]=v)});return n.delete(r),c}}return r};return t(e)},g_=ao("AsyncFunction"),m_=e=>e&&(Ha(e)||Ci(e))&&Ci(e.then)&&Ci(e.catch),Cm=((e,n)=>e?setImmediate:n?((t,r)=>(sa.addEventListener("message",({source:c,data:h})=>{c===sa&&h===t&&r.length&&r.shift()()},!1),c=>{r.push(c),sa.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",Ci(sa.postMessage)),v_=typeof queueMicrotask<"u"?queueMicrotask.bind(sa):typeof process<"u"&&process.nextTick||Cm,km=e=>e!=null&&Ci(e[Rl]),y_=e=>e!=null&&Ol(e,Rl)&&km(e),me={isArray:ia,isArrayBuffer:gm,isBuffer:Wa,isFormData:Hk,isArrayBufferView:Ik,isString:Mk,isNumber:mm,isBoolean:Rk,isObject:Ha,isPlainObject:Uc,isEmptyObject:Lk,isReadableStream:Vk,isRequest:Gk,isResponse:qk,isHeaders:Yk,isUndefined:oa,isDate:Ok,isFile:Nk,isReactNativeBlob:Dk,isReactNative:Pk,isBlob:zk,isRegExp:l_,isFunction:Ci,isStream:jk,isURLSearchParams:Uk,isTypedArray:n_,isFileList:Bk,forEach:Nl,merge:Yh,extend:Jk,trim:Kk,stripBOM:Qk,inherits:Zk,toFlatObject:Xk,kindOf:qh,kindOfTest:ao,endsWith:e_,toArray:t_,forEachEntry:r_,matchAll:i_,isHTMLForm:o_,hasOwnProperty:Ll,hasOwnProp:Ll,hasOwnInPrototypeChain:Ol,getSafeProp:Tk,toSafeFlatObject:Ek,reduceDescriptors:xm,freezeMethods:c_,toObjectSet:u_,toCamelCase:s_,noop:h_,toFiniteNumber:d_,findKey:bm,global:sa,isContextDefined:wm,isSpecCompliantForm:f_,toJSONObject:p_,isAsyncFn:g_,isThenable:m_,setImmediate:Cm,asap:v_,isIterable:km,isSafeIterable:y_},b_=me.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"]),w_=e=>{const n={};let t,r,c;return e&&e.split(`
2
+ `).forEach(function(h){c=h.indexOf(":"),t=h.substring(0,c).trim().toLowerCase(),r=h.substring(c+1).trim();const g=me.hasOwnProp(n,t);!t||g&&me.hasOwnProp(b_,t)||(t==="set-cookie"?g?n[t].push(r):n[t]=[r]:n[t]=g?n[t]+", "+r:r)}),n};function x_(e){let n=0,t=e.length;for(;n<t;){const r=e.charCodeAt(n);if(r!==9&&r!==32)break;n+=1}for(;t>n;){const r=e.charCodeAt(t-1);if(r!==9&&r!==32)break;t-=1}return n===0&&t===e.length?e:e.slice(n,t)}const C_=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),k_=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function Kh(e,n){return me.isArray(e)?e.map(t=>Kh(t,n)):x_(String(e).replace(n,""))}const __=e=>Kh(e,C_),A_=e=>Kh(e,k_);function _m(e){const n=Object.create(null);return me.forEach(e.toJSON(),(t,r)=>{n[r]=A_(t)}),n}const Am=Symbol("internals");function Dl(e){return e&&String(e).trim().toLowerCase()}function Vc(e){return e===!1||e==null?e:me.isArray(e)?e.map(Vc):__(String(e))}function $_(e){const n=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=t.exec(e);)n[r[1]]=r[2];return n}const S_=/^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/;function Jh(e){let n=0,t=e.length;for(;n<t;){const r=e.charCodeAt(n);if(r!==9&&r!==32)break;n+=1}for(;t>n;){const r=e.charCodeAt(t-1);if(r!==9&&r!==32)break;t-=1}return n===0&&t===e.length?e:e.slice(n,t)}function T_(e){const n=e.length-1;if(n<1||e.charCodeAt(0)!==34||e.charCodeAt(n)!==34)return e;let t="";for(let r=1;r<n;r++){const c=e.charCodeAt(r);if(c===34||c===92&&(r+=1,r>=n))return e;t+=e[r]}return t}function E_(e){const n=Object.create(null),t=String(e);let r=0,c=!1,h=!1;function g(v){const s=Jh(t.slice(r,v)),p=s.indexOf("=");if(p<1)return;const a=Jh(s.slice(0,p));if(!S_.test(a))return;const l=a.toLowerCase();if(l==="__proto__"||l==="constructor"||l==="prototype")return;const u=Jh(s.slice(p+1));n[l]=T_(u)}for(let v=0;v<t.length;v++){const s=t.charCodeAt(v);c?h?h=!1:s===92?h=!0:s===34&&(c=!1):s===34?c=!0:(s===44||s===59)&&(g(v),r=v+1)}return g(t.length),n}const I_=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Qh(e,n,t,r,c){if(me.isFunction(r))return r.call(this,n,t);if(c&&(n=t),!!me.isString(n)){if(me.isString(r))return n.indexOf(r)!==-1;if(me.isRegExp(r))return r.test(n)}}function M_(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(n,t,r)=>t.toUpperCase()+r)}function R_(e,n){const t=me.toCamelCase(" "+n);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+t,{__proto__:null,value:function(c,h,g){return this[r].call(this,n,c,h,g)},configurable:!0})})}let Yr=class{constructor(n){n&&this.set(n)}set(n,t,r){const c=this;function h(v,s,p){const a=Dl(s);if(!a)return;const l=me.findKey(c,a);(!l||c[l]===void 0||p===!0||p===void 0&&c[l]!==!1)&&(c[l||s]=Vc(v))}const g=(v,s)=>me.forEach(v,(p,a)=>h(p,a,s));if(me.isPlainObject(n)||n instanceof this.constructor)g(n,t);else if(me.isString(n)&&(n=n.trim())&&!I_(n))g(w_(n),t);else if(me.isObject(n)&&me.isSafeIterable(n)){let v=Object.create(null),s,p;for(const a of n){if(!me.isArray(a))throw new TypeError("Object iterator must return a key-value pair");p=a[0],me.hasOwnProp(v,p)?(s=v[p],v[p]=me.isArray(s)?[...s,a[1]]:[s,a[1]]):v[p]=a[1]}g(v,t)}else n!=null&&h(t,n,r);return this}get(n,t){if(n=Dl(n),n){const r=me.findKey(this,n);if(r){const c=this[r];if(!t)return c;if(t===!0)return $_(c);if(me.isFunction(t))return t.call(this,c,r);if(me.isRegExp(t))return t.exec(c);throw new TypeError("parser must be boolean|regexp|function")}}}has(n,t){if(n=Dl(n),n){const r=me.findKey(this,n);return!!(r&&this[r]!==void 0&&(!t||Qh(this,this[r],r,t)))}return!1}delete(n,t){const r=this;let c=!1;function h(g){if(g=Dl(g),g){const v=me.findKey(r,g);v&&(!t||Qh(r,r[v],v,t))&&(delete r[v],c=!0)}}return me.isArray(n)?n.forEach(h):h(n),c}clear(n){const t=Object.keys(this);let r=t.length,c=!1;for(;r--;){const h=t[r];(!n||Qh(this,this[h],h,n,!0))&&(delete this[h],c=!0)}return c}normalize(n){const t=this,r={};return me.forEach(this,(c,h)=>{const g=me.findKey(r,h);if(g){t[g]=Vc(c),delete t[h];return}const v=n?M_(h):String(h).trim();v!==h&&delete t[h],t[v]=Vc(c),r[v]=!0}),this}concat(...n){return this.constructor.concat(this,...n)}toJSON(n){const t=Object.create(null);return me.forEach(this,(r,c)=>{r!=null&&r!==!1&&(t[c]=n&&me.isArray(r)?r.join(", "):r)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([n,t])=>n+": "+t).join(`
3
+ `)}getSetCookie(){const n=this.get("set-cookie");return me.isArray(n)?n:n==null||n===!1?[]:[n]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(n){return n instanceof this?n:new this(n)}static parseParameters(n){return E_(n)}static concat(n,...t){const r=new this(n);return t.forEach(c=>r.set(c)),r}static accessor(n){const t=(this[Am]=this[Am]={accessors:{}}).accessors,r=this.prototype;function c(h){const g=Dl(h);t[g]||(R_(r,h),t[g]=!0)}return me.isArray(n)?n.forEach(c):c(n),this}};Yr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),me.reduceDescriptors(Yr.prototype,({value:e},n)=>{let t=n[0].toUpperCase()+n.slice(1);return{get:()=>e,set(r){this[t]=r}}}),me.freezeMethods(Yr);const Gc="[REDACTED ****]";function L_(e){if(me.hasOwnProp(e,"toJSON"))return!0;let n=Object.getPrototypeOf(e);for(;n&&n!==Object.prototype;){if(me.hasOwnProp(n,"toJSON"))return!0;n=Object.getPrototypeOf(n)}return!1}function O_(e,n){const t=new Set(n.map(h=>String(h).toLowerCase())),r=[],c=h=>{if(h===null||typeof h!="object"||me.isBuffer(h))return h;if(r.indexOf(h)!==-1)return;h instanceof Yr&&(h=h.toJSON()),r.push(h);let g;if(me.isArray(h))g=[],h.forEach((v,s)=>{const p=c(v);me.isUndefined(p)||(g[s]=p)});else{if(!me.isPlainObject(h)&&L_(h))return r.pop(),h;g=Object.create(null);for(const[v,s]of Object.entries(h)){const p=t.has(v.toLowerCase())?Gc:c(s);me.isUndefined(p)||(g[v]=p)}}return r.pop(),g};return c(e)}function $m(e){try{return String(e)}catch{return""}}function N_(e){return e.errors.map(n=>{try{return n&&n.message?$m(n.message):$m(n)}catch{return""}}).filter(Boolean).join("; ")||e.name||"AggregateError"}let tt=class ok extends Error{static from(n,t,r,c,h,g){let v=n.message;!v&&me.isArray(n.errors)&&n.errors.length&&(v=N_(n));const s=new ok(v,t||n.code,r,c,h);return Object.defineProperty(s,"cause",{__proto__:null,value:n,writable:!0,enumerable:!1,configurable:!0}),s.name=n.name,n.status!=null&&s.status==null&&(s.status=n.status),g&&Object.assign(s,g),s}constructor(n,t,r,c,h){super(n),Object.defineProperty(this,"message",{__proto__:null,value:n,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),r&&(this.config=r),c&&(this.request=c),h&&(this.response=h,this.status=h.status)}toJSON(){const n=this.config,t=n&&me.hasOwnProp(n,"redact")?n.redact:void 0,r=me.isArray(t)&&t.length>0?O_(n,t):me.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 D_=null,Sm=100;function Zh(e){return me.isPlainObject(e)||me.isArray(e)}function Tm(e){return me.endsWith(e,"[]")?e.slice(0,-2):e}function Xh(e,n,t){return e?e.concat(n).map(function(r,c){return r=Tm(r),!t&&c?"["+r+"]":r}).join(t?".":""):n}function P_(e){return me.isArray(e)&&!e.some(Zh)}const z_=me.toFlatObject(me,{},null,function(e){return/^is[A-Z]/.test(e)});function qc(e,n,t){if(!me.isObject(e))throw new TypeError("target must be an object");n=n||new FormData;const r=(x,R)=>{const T=me.getSafeProp(t,x);return me.isUndefined(T)?R:T},c=r("metaTokens",!0),h=r("visitor")||f,g=r("dots",!1),v=r("indexes",!1),s=r("Blob")||typeof Blob<"u"&&Blob,p=r("maxDepth",Sm),a=s&&me.isSpecCompliantForm(n),l=[];if(!me.isFunction(h))throw new TypeError("visitor must be a function");function u(x){if(x===null)return"";if(me.isDate(x))return x.toISOString();if(me.isBoolean(x))return x.toString();if(!a&&me.isBlob(x))throw new tt("Blob is not supported. Use a Buffer instead.");if(me.isArrayBuffer(x)||me.isTypedArray(x)){if(a&&typeof s=="function")return new s([x]);throw new tt("Blob is not supported. Use a Buffer instead.",tt.ERR_NOT_SUPPORT)}return x}function d(x){if(x>p)throw new tt("Object is too deeply nested ("+x+" levels). Max depth: "+p,tt.ERR_FORM_DATA_DEPTH_EXCEEDED)}function o(x,R){if(p===1/0)return JSON.stringify(x);const T=[];return JSON.stringify(x,function(_,C){if(!me.isObject(C))return C;for(;T.length&&T[T.length-1]!==this;)T.pop();return T.push(C),d(R+T.length-1),C})}function f(x,R,T){let _=x;if(me.isReactNative(n)&&me.isReactNativeBlob(x))return n.append(Xh(T,R,g),u(x)),!1;if(x&&!T&&typeof x=="object"){if(me.endsWith(R,"{}"))R=c?R:R.slice(0,-2),x=o(x,1);else if(me.isArray(x)&&P_(x)||(me.isFileList(x)||me.endsWith(R,"[]"))&&(_=me.toArray(x)))return R=Tm(R),_.forEach(function(C,P){!(me.isUndefined(C)||C===null)&&n.append(v===!0?Xh([R],P,g):v===null?R:R+"[]",u(C))}),!1}return Zh(x)?!0:(n.append(Xh(T,R,g),u(x)),!1)}const m=Object.assign(z_,{defaultVisitor:f,convertValue:u,isVisitable:Zh});function w(x,R,T=0){if(!me.isUndefined(x)){if(d(T),l.indexOf(x)!==-1)throw new Error("Circular reference detected in "+R.join("."));l.push(x),me.forEach(x,function(_,C){(!(me.isUndefined(_)||_===null)&&h.call(n,_,me.isString(C)?C.trim():C,R,m))===!0&&w(_,R?R.concat(C):[C],T+1)}),l.pop()}}if(!me.isObject(e))throw new TypeError("data must be an object");return w(e),n}function Em(e){const n={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(t){return n[t]})}function ed(e,n){this._pairs=[],e&&qc(e,this,n)}const Im=ed.prototype;Im.append=function(e,n){this._pairs.push([e,n])},Im.toString=function(e){const n=e?t=>e.call(this,t,Em):Em;return this._pairs.map(function(t){return n(t[0])+"="+n(t[1])},"").join("&")};function B_(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Mm(e,n,t){if(!n)return e;e=e||"";const r=me.isFunction(t)?{serialize:t}:t,c=me.getSafeProp(r,"encode")||B_,h=me.getSafeProp(r,"serialize");let g;if(h?g=h(n,r):g=me.isURLSearchParams(n)?n.toString():new ed(n,r).toString(c),g){const v=e.indexOf("#");v!==-1&&(e=e.slice(0,v)),e+=(e.indexOf("?")===-1?"?":"&")+g}return e}const Pl=Symbol("internals");function Rm(e){return e?e.length:0}function Lm(e){if(e)for(;e.length&&e[e.length-1]===null;)e.pop()}function zl(e,n){const t=e.handlers,r=Rm(t);t!==n.handlersRef?(n.handlersRef=t,n.handlerEntries.clear()):r!==n.handlersLength&&(r?n.handlerEntries.forEach(function(c,h){t[c.index]!==c.handler&&n.handlerEntries.delete(h)}):n.handlerEntries.clear()),n.handlersLength=r}let Om=class{constructor(){this.handlers=[],this[Pl]={handlersRef:this.handlers,handlersLength:this.handlers.length,handlerEntries:new Map,iterationDepth:0,nextId:0}}use(n,t,r){const c={fulfilled:n,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null},h=this[Pl];this.handlers==null&&(this.handlers=[]),zl(this,h);const g=h.nextId++;return this.handlers.push(c),h.handlerEntries.set(g,{handler:c,index:this.handlers.length-1}),h.handlersLength=this.handlers.length,g}eject(n){const t=this[Pl];zl(this,t);const r=t.handlerEntries.get(n);if(r){if(t.handlerEntries.delete(n),this.handlers[r.index]!==r.handler)return;this.handlers[r.index]=null,t.iterationDepth||(Lm(this.handlers),t.handlersLength=this.handlers.length)}}clear(){this.handlers&&(this.handlers=[],zl(this,this[Pl]))}forEach(n){const t=this[Pl];zl(this,t),t.iterationDepth++;try{me.forEach(this.handlers,function(r){r!==null&&n(r)})}finally{--t.iterationDepth||(zl(this,t),Lm(this.handlers),t.handlersLength=Rm(this.handlers))}}};const td={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0,advertiseZstdAcceptEncoding:!1,validateStatusUndefinedResolves:!0},F_=typeof URLSearchParams<"u"?URLSearchParams:ed,j_=typeof FormData<"u"?FormData:null,W_=typeof Blob<"u"?Blob:null,H_={isBrowser:!0,classes:{URLSearchParams:F_,FormData:j_,Blob:W_},protocols:["http","https","file","blob","url","data"]},nd=typeof window<"u"&&typeof document<"u",rd=typeof navigator=="object"&&navigator||void 0,U_=nd&&(!rd||["ReactNative","NativeScript","NS"].indexOf(rd.product)<0),V_=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",G_=nd&&window.location.href||"http://localhost",q_=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:nd,hasStandardBrowserEnv:U_,hasStandardBrowserWebWorkerEnv:V_,navigator:rd,origin:G_},Symbol.toStringTag,{value:"Module"})),Mr={...q_,...H_};function Y_(e,n){return qc(e,new Mr.classes.URLSearchParams,{visitor:function(t,r,c,h){return Mr.isNode&&me.isBuffer(t)?(this.append(r,t.toString("base64")),!1):h.defaultVisitor.apply(this,arguments)},...n})}const Nm=Sm;function Dm(e){if(e>Nm)throw new tt("FormData field is too deeply nested ("+e+" levels). Max depth: "+Nm,tt.ERR_FORM_DATA_DEPTH_EXCEEDED)}function K_(e){const n=[],t=/[^.[\]]+|\[([^.[\]]*)]/g;let r;for(;(r=t.exec(e))!==null;)Dm(n.length),n.push(r[0]==="[]"?"":r[1]||r[0]);return n}function J_(e){const n={},t=Object.keys(e);let r;const c=t.length;let h;for(r=0;r<c;r++)h=t[r],n[h]=e[h];return n}function Pm(e){function n(t,r,c,h){Dm(h);let g=t[h++];if(g==="__proto__")return!0;const v=Number.isFinite(+g),s=h>=t.length;return g=!g&&me.isArray(c)?c.length:g,s?(me.hasOwnProp(c,g)?c[g]=me.isArray(c[g])?c[g].concat(r):[c[g],r]:c[g]=r,!v):((!me.hasOwnProp(c,g)||!me.isObject(c[g]))&&(c[g]=[]),n(t,r,c[g],h)&&me.isArray(c[g])&&(c[g]=J_(c[g])),!v)}if(me.isFormData(e)&&me.isFunction(e.entries)){const t={};return me.forEachEntry(e,(r,c)=>{n(K_(r),c,t,0)}),t}return null}const zm=Object.freeze(["get","delete","head","options","post","put","patch","purge","link","unlink","query"]),Ua=(e,n)=>e!=null&&me.hasOwnProp(e,n)?e[n]:void 0;function Q_(e,n,t){if(me.isString(e))try{return(n||JSON.parse)(e),me.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(t||JSON.stringify)(e)}const Bl={transitional:td,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const t=n.getContentType()||"",r=t.indexOf("application/json")>-1,c=me.isObject(e);if(c&&me.isHTMLForm(e)&&(e=new FormData(e)),me.isFormData(e))return r?JSON.stringify(Pm(e)):e;if(me.isArrayBuffer(e)||me.isBuffer(e)||me.isStream(e)||me.isFile(e)||me.isBlob(e)||me.isReadableStream(e))return e;if(me.isArrayBufferView(e))return e.buffer;if(me.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let h;if(c){const g=Ua(this,"formSerializer");if(t.indexOf("application/x-www-form-urlencoded")>-1)return Y_(e,g).toString();if((h=me.isFileList(e))||t.indexOf("multipart/form-data")>-1){const v=Ua(this,"env"),s=v&&v.FormData;return qc(h?{"files[]":e}:e,s&&new s,g)}}return c||r?(n.setContentType("application/json",!1),Q_(e)):e}],transformResponse:[function(e){const n=Ua(this,"transitional")||Bl.transitional,t=n&&n.forcedJSONParsing,r=Ua(this,"responseType"),c=r==="json";if(me.isResponse(e)||me.isReadableStream(e))return e;if(e&&me.isString(e)&&(t&&!r||c)){const h=!(n&&n.silentJSONParsing)&&c;try{return JSON.parse(e,Ua(this,"parseReviver"))}catch(g){if(h)throw g.name==="SyntaxError"?tt.from(g,tt.ERR_BAD_RESPONSE,this,null,Ua(this,"response")):g}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Mr.classes.FormData,Blob:Mr.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};me.forEach(zm,e=>{Bl.headers[e]={}});function id(e,n){const t=this||Bl,r=n||t,c=Yr.from(r.headers);let h=r.data;return me.forEach(e,function(g){h=g.call(t,h,c.normalize(),n?n.status:void 0)}),c.normalize(),h}function Bm(e){return!!(e&&e.__CANCEL__)}let Fl=class extends tt{constructor(n,t,r){super(n??"canceled",tt.ERR_CANCELED,t,r),this.name="CanceledError",this.__CANCEL__=!0}};function Fm(e,n,t){const r=t.config.validateStatus;!t.status||!r||r(t.status)?e(t):n(new tt("Request failed with status code "+t.status,t.status>=400&&t.status<500?tt.ERR_BAD_REQUEST:tt.ERR_BAD_RESPONSE,t.config,t.request,t))}const Z_=/[\t\n\r]/g;function jm(e){if(typeof e!="string")return e;let n=0;for(;n<e.length&&e.charCodeAt(n)<=32;)n++;return e.slice(n).replace(Z_,"")}function od(e){const n=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return n&&n[1]||""}function X_(e,n){e=e||10;const t=new Array(e),r=new Array(e);let c=0,h=0,g;return n=n!==void 0?n:1e3,function(v){const s=Date.now(),p=r[h];g||(g=s),t[c]=v,r[c]=s;let a=h,l=0;for(;a!==c;)l+=t[a++],a=a%e;if(c=(c+1)%e,c===h&&(h=(h+1)%e),s-g<n)return;const u=p&&s-p;return u?Math.round(l*1e3/u):void 0}}function eA(e,n){let t=0,r=1e3/n,c,h;const g=(v,s=Date.now())=>{t=s,c=null,h&&(clearTimeout(h),h=null),e(...v)};return[(...v)=>{const s=Date.now(),p=s-t;p>=r?g(v,s):(c=v,h||(h=setTimeout(()=>{h=null,g(c)},r-p)))},()=>c&&g(c),(...v)=>g(v)]}const Yc=(e,n,t=3)=>{let r=0;const c=X_(50,250);return eA(h=>{if(!h||!me.isNumber(h.loaded))return;const g=h.loaded,v=h.lengthComputable?h.total:void 0,s=Math.max(0,v!=null?Math.min(g,v):g),p=Math.max(0,s-r),a=c(p);r=Math.max(r,s);const l={loaded:s,total:v,progress:v?s/v:void 0,bytes:p,rate:a||void 0,estimated:a&&v?(v-s)/a:void 0,event:h,lengthComputable:v!=null,[n?"download":"upload"]:!0};e(l)},t)},Wm=(e,n)=>{const t=e!=null;return[r=>n[0]({lengthComputable:t,total:e,loaded:r}),n[1]]},Hm=(e,n=me.asap)=>(...t)=>n(()=>e(...t)),tA=Mr.hasStandardBrowserEnv?((e,n)=>t=>(t=new URL(t,Mr.origin),e.protocol===t.protocol&&e.host===t.host&&(n||e.port===t.port)))(new URL(Mr.origin),Mr.navigator&&/(msie|trident)/i.test(Mr.navigator.userAgent)):()=>!0,nA=Mr.hasStandardBrowserEnv?{write(e,n,t,r,c,h,g){if(typeof document>"u")return;const v=[`${e}=${encodeURIComponent(n)}`];me.isNumber(t)&&v.push(`expires=${new Date(t).toUTCString()}`),me.isString(r)&&v.push(`path=${r}`),me.isString(c)&&v.push(`domain=${c}`),h===!0&&v.push("secure"),me.isString(g)&&v.push(`SameSite=${g}`),document.cookie=v.join("; ")},read(e){if(typeof document>"u")return null;const n=document.cookie.split(";");for(let t=0;t<n.length;t++){const r=n[t].replace(/^\s+/,""),c=r.indexOf("=");if(c!==-1&&r.slice(0,c)===e)try{return decodeURIComponent(r.slice(c+1))}catch{return r.slice(c+1)}}return null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function rA(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function iA(e,n){if(!n)return e;let t=e.length;for(;t>0&&e.charCodeAt(t-1)===47;)t--;return e.slice(0,t)+"/"+n.replace(/^\/+/,"")}const oA=/^https?:(?!\/\/)/i;function sA(e){return e&&e.replace(/(^|&)([^=&]*=)?[^&]+/g,(n,t,r="")=>`${t}${r}${Gc}`)}function aA(e){const n=e.replace(/^(https?:\/{0,2})[^/?#]*@/i,`$1${Gc}@`),t=n.indexOf("#"),r=(t===-1?n:n.slice(0,t)).replace(/([?&][^=&#]*=)[^&#]*/g,`$1${Gc}`);return t===-1?r:`${r}#${sA(n.slice(t+1))}`}function Um(e,n){if(typeof e=="string"){const t=jm(e);if(oA.test(t))throw new tt(`Invalid URL ${JSON.stringify(aA(t))}: missing "//" after protocol`,tt.ERR_INVALID_URL,n)}}function Vm(e,n,t,r){Um(n,r);let c=!rA(n);return e&&(c||t===!1)?(Um(e,r),iA(e,n)):n}const Gm=e=>e instanceof Yr?{...e}:e,lA=e=>Object.getOwnPropertySymbols&&Object.getOwnPropertyDescriptor?Object.keys(e).concat(Object.getOwnPropertySymbols(e).filter(n=>Object.getOwnPropertyDescriptor(e,n).enumerable)):Object.keys(e);function aa(e,n){e=e||{},n=n||{};const t=Object.create(null);Object.defineProperty(t,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function r(a,l,u,d){return me.isPlainObject(a)&&me.isPlainObject(l)?me.merge.call({caseless:d},a,l):me.isPlainObject(l)?me.merge({},l):me.isArray(l)?l.slice():l}function c(a,l,u,d){if(me.isUndefined(l)){if(!me.isUndefined(a))return r(void 0,a,u,d)}else return r(a,l,u,d)}function h(a,l){if(!me.isUndefined(l))return r(void 0,l)}function g(a,l){if(me.isUndefined(l)){if(!me.isUndefined(a))return r(void 0,a)}else return r(void 0,l)}function v(a){const l=me.hasOwnProp(n,"transitional")?n.transitional:void 0;if(!me.isUndefined(l))if(me.isPlainObject(l)){if(me.hasOwnProp(l,a))return l[a]}else return;const u=me.hasOwnProp(e,"transitional")?e.transitional:void 0;if(me.isPlainObject(u)&&me.hasOwnProp(u,a))return u[a]}function s(a,l,u){if(me.hasOwnProp(n,u))return r(a,l);if(me.hasOwnProp(e,u))return r(void 0,a)}const p={url:h,method:h,data:h,baseURL:g,transformRequest:g,transformResponse:g,paramsSerializer:g,timeout:g,timeoutErrorMessage: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:s,headers:(a,l,u)=>c(Gm(a),Gm(l),u,!0)};return me.forEach(lA({...e,...n}),function(a){if(a==="__proto__"||a==="constructor"||a==="prototype")return;const l=me.hasOwnProp(p,a)?p[a]:c,u=me.hasOwnProp(e,a)?e[a]:void 0,d=me.hasOwnProp(n,a)?n[a]:void 0,o=l(u,d,a);me.isUndefined(o)&&l!==s||(t[a]=o)}),me.hasOwnProp(n,"validateStatus")&&me.isUndefined(n.validateStatus)&&v("validateStatusUndefinedResolves")===!1&&(me.hasOwnProp(e,"validateStatus")?t.validateStatus=r(void 0,e.validateStatus):delete t.validateStatus),t}const cA=["content-type","content-length"];function uA(e,n,t){if(t!=="content-only"){e.set(n);return}Object.entries(n||{}).forEach(([r,c])=>{cA.includes(r.toLowerCase())&&e.set(r,c)})}const hA=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(n,t)=>String.fromCharCode(parseInt(t,16)));function qm(e){const n=aa({},e),t=u=>me.hasOwnProp(n,u)?n[u]:void 0,r=t("data");let c=t("withXSRFToken");const h=t("xsrfHeaderName"),g=t("xsrfCookieName");let v=t("headers");const s=t("auth"),p=t("baseURL"),a=t("allowAbsoluteUrls"),l=t("url");if(n.headers=v=Yr.from(v),n.url=Mm(Vm(p,l,a,n),t("params"),t("paramsSerializer")),s){const u=me.getSafeProp(s,"username")||"",d=me.getSafeProp(s,"password")||"";try{v.set("Authorization","Basic "+btoa(u+":"+(d?hA(d):"")))}catch(o){throw tt.from(o,tt.ERR_BAD_OPTION_VALUE,e)}}if(me.isFormData(r)){const u=me.getSafeProp(r,"getHeaders");Mr.hasStandardBrowserEnv||Mr.hasStandardBrowserWebWorkerEnv||me.isReactNative(r)?v.setContentType(void 0):me.isFunction(u)&&uA(v,u.call(r),t("formDataHeaderPolicy"))}if(Mr.hasStandardBrowserEnv&&(me.isFunction(c)&&(c=c(n)),c===!0||c==null&&tA(n.url))){const u=h&&g&&nA.read(g);u&&v.set(h,u)}return n}const dA=typeof XMLHttpRequest<"u",fA=dA&&function(e){return new Promise(function(n,t){const r=qm(e);let c=r.data;const h=Yr.from(r.headers).normalize();let{responseType:g,onUploadProgress:v,onDownloadProgress:s}=r,p,a,l,u,d,o;function f(){u&&u(),d&&d(),r.cancelToken&&r.cancelToken.unsubscribe(p),r.signal&&r.signal.removeEventListener("abort",p)}let m=new XMLHttpRequest;m.open(r.method.toUpperCase(),r.url,!0),m.timeout=r.timeout;function w(R){if(!m)return;if(m.status===0&&(od(jm(r.url))||od(Mr.origin))!=="file"&&!(m.responseURL&&m.responseURL.startsWith("file:"))){t(new tt("Request aborted",tt.ECONNABORTED,e,m)),f(),m=null;return}try{R?o&&o(R):d&&d()}catch(C){setTimeout(()=>{throw C})}if(!m)return;const T=Yr.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders()),_={data:!g||g==="text"||g==="json"?m.responseText:m.response,status:m.status,statusText:m.statusText,headers:T,config:e,request:m};Fm(function(C){n(C),f()},function(C){t(C),f()},_),m=null}"onloadend"in m?m.onloadend=w:m.onreadystatechange=function(){!m||m.readyState!==4||m.status===0&&!(m.responseURL&&m.responseURL.startsWith("file:"))||setTimeout(w)},m.onabort=function(){m&&(t(new tt("Request aborted",tt.ECONNABORTED,e,m)),f(),m=null)},m.onerror=function(R){const T=R&&R.message?R.message:"Network Error",_=new tt(T,tt.ERR_NETWORK,e,m);_.event=R||null,t(_),f(),m=null},m.ontimeout=function(){let R=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const T=r.transitional||td;r.timeoutErrorMessage&&(R=r.timeoutErrorMessage),t(new tt(R,T.clarifyTimeoutError?tt.ETIMEDOUT:tt.ECONNABORTED,e,m)),f(),m=null},c===void 0&&h.setContentType(null),"setRequestHeader"in m&&me.forEach(_m(h),function(R,T){m.setRequestHeader(T,R)}),me.isUndefined(r.withCredentials)||(m.withCredentials=!!r.withCredentials),g&&g!=="json"&&(m.responseType=r.responseType),s&&([l,d,o]=Yc(s,!0),m.addEventListener("progress",l)),v&&m.upload&&([a,u]=Yc(v),m.upload.addEventListener("progress",a),m.upload.addEventListener("loadend",u)),(r.cancelToken||r.signal)&&(p=R=>{m&&(t(!R||R.type?new Fl(null,e,m):R),m.abort(),f(),m=null)},r.cancelToken&&r.cancelToken.subscribe(p),r.signal&&(r.signal.aborted?p():r.signal.addEventListener("abort",p)));const x=od(r.url);if(x&&!Mr.protocols.includes(x)){t(new tt("Unsupported protocol "+x+":",tt.ERR_BAD_REQUEST,e)),f();return}m.send(c||null)})},pA=(e,n)=>{if(e=e?e.filter(Boolean):[],!n&&!e.length)return;const t=new AbortController;let r=!1;const c=function(s){if(!r){r=!0,g();const p=s instanceof Error?s:this.reason;t.abort(p instanceof tt?p:new Fl(p instanceof Error?p.message:p))}};let h=n&&setTimeout(()=>{h=null,c(new tt(`timeout of ${n}ms exceeded`,tt.ETIMEDOUT))},n);const g=()=>{e&&(h&&clearTimeout(h),h=null,e.forEach(s=>{s.unsubscribe?s.unsubscribe(c):s.removeEventListener("abort",c)}),e=null)};e.forEach(s=>{if(!r){if(s.aborted){c.call(s);return}s.addEventListener("abort",c,{once:!0})}});const{signal:v}=t;return v.unsubscribe=()=>me.asap(g),v},gA=function*(e,n){let t=e.byteLength;if(t<n){yield e;return}let r=0,c;for(;r<t;)c=r+n,yield e.slice(r,c),r=c},mA=async function*(e,n){for await(const t of vA(e))yield*gA(t,n)},vA=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const n=e.getReader();try{for(;;){const{done:t,value:r}=await n.read();if(t)break;yield r}}finally{await n.cancel()}},Ym=(e,n,t,r)=>{const c=mA(e,n);let h=0,g,v=s=>{g||(g=!0,r&&r(s))};return new ReadableStream({async pull(s){try{const{done:p,value:a}=await c.next();if(p){v(),s.close();return}let l=a.byteLength;if(t){let u=h+=l;t(u)}s.enqueue(new Uint8Array(a))}catch(p){throw v(p),p}},cancel(s){return v(s),c.return()}},{highWaterMark:2})},Km=e=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102,Jm=(e,n,t)=>n+2<t&&Km(e.charCodeAt(n+1))&&Km(e.charCodeAt(n+2)),Qm=e=>e<=57?e-48:(e&223)-55,yA=e=>e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||e===43||e===47||e===45||e===95,bA=e=>e===9||e===10||e===12||e===13||e===32,wA=e=>{const n=Math.floor(e/4),t=e%4;return n*3+(t===2?1:t===3?2:0)},xA=e=>{const n=e.length;let t=0;return n>0&&e.charCodeAt(n-1)===61&&(t++,n>1&&e.charCodeAt(n-2)===61&&t++),Math.floor((n-t)*3/4)},CA=e=>{const n=e.length;let t=0,r=0,c=!1;for(let h=0;h<n;h++){let g=e.charCodeAt(h);if(g===37&&Jm(e,h,n)&&(g=Qm(e.charCodeAt(h+1))*16+Qm(e.charCodeAt(h+2)),h+=2),!bA(g)){if(g===61){r++;continue}if(!yA(g)||r>0){c=!0;continue}t++}}return c||r>2||r>0&&(t+r)%4!==0||t%4===1?xA(e):wA(t)},kA=(e,n)=>{if(!e||typeof e!="string"||!e.startsWith("data:"))return 0;const t=e.indexOf(",");if(t<0)return 0;const r=e.slice(5,t),c=e.slice(t+1);if(/;base64/i.test(r))return n(c);let h=0;for(let g=0,v=c.length;g<v;g++){const s=c.charCodeAt(g);if(s===37&&Jm(c,g,v))h+=1,g+=2;else if(s<128)h+=1;else if(s<2048)h+=2;else if(s>=55296&&s<=56319&&g+1<v){const p=c.charCodeAt(g+1);p>=56320&&p<=57343?(h+=4,g++):h+=3}else h+=3}return h};function _A(e){const n=typeof e=="string"?e.indexOf("#"):-1;return kA(n===-1?e:e.slice(0,n),CA)}const sd="1.20.0",Zm=64*1024,AA={cache:"default",redirect:"follow",referrer:"about:client",referrerPolicy:"",mode:"cors",integrity:"",keepalive:!1,priority:"auto",window:null},{isFunction:Kc}=me,$A=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(n,t)=>String.fromCharCode(parseInt(t,16))),Xm=e=>{if(!me.isString(e))return e;try{return decodeURIComponent(e)}catch{return e}},ev=(e,...n)=>{try{return!!e(...n)}catch{return!1}},SA=e=>{const n=e.indexOf("://");let t=e;return n!==-1&&(t=t.slice(n+3)),t.includes("@")||t.includes(":")},TA=e=>{const n=me.global!==void 0&&me.global!==null?me.global:globalThis,{ReadableStream:t,TextEncoder:r}=n;e=me.merge.call({skipUndefined:!0},{Request:n.Request,Response:n.Response},e);const{fetch:c,Request:h,Response:g}=e,v=c?Kc(c):typeof fetch=="function",s=Kc(h),p=Kc(g);if(!v)return!1;const a=v&&Kc(t),l=v&&(typeof r=="function"?(w=>x=>w.encode(x))(new r):async w=>new Uint8Array(await new h(w).arrayBuffer())),u=s&&a&&ev(()=>{let w=!1;const x=new h(Mr.origin,{body:new t,method:"POST",get duplex(){return w=!0,"half"}}),R=x.headers.has("Content-Type");return x.body!=null&&x.body.cancel(),w&&!R}),d=p&&a&&ev(()=>me.isReadableStream(new g("").body)),o={stream:d&&(w=>w.body)};v&&["text","arrayBuffer","blob","formData","stream"].forEach(w=>{!o[w]&&(o[w]=(x,R)=>{let T=x&&x[w];if(T)return T.call(x);throw new tt(`Response type '${w}' is not supported`,tt.ERR_NOT_SUPPORT,R)})});const f=async w=>{if(w==null)return 0;if(me.isBlob(w))return w.size;if(me.isSpecCompliantForm(w))return(await new h(Mr.origin,{method:"POST",body:w}).arrayBuffer()).byteLength;if(me.isArrayBufferView(w)||me.isArrayBuffer(w))return w.byteLength;if(me.isURLSearchParams(w)&&(w=w+""),me.isString(w))return(await l(w)).byteLength},m=async(w,x)=>me.toFiniteNumber(w.getContentLength())??f(x);return async w=>{let{url:x,method:R,data:T,signal:_,cancelToken:C,timeout:P,onDownloadProgress:O,onUploadProgress:E,responseType:k,headers:B,withCredentials:N="same-origin",fetchOptions:M,maxContentLength:$,maxBodyLength:A,maxRedirects:D}=qm(w);const j=me.isNumber($)&&$>-1,U=me.isNumber(A)&&A>-1,q=ee=>me.hasOwnProp(w,ee)?w[ee]:void 0;let Q=c||fetch;k=k?(k+"").toLowerCase():"text";let re=pA([_,C&&C.toAbortSignal()],P),le=null;const ne=re&&re.unsubscribe&&(()=>{re.unsubscribe()});let ue,he=null;const oe=()=>new tt("Request body larger than maxBodyLength limit",tt.ERR_BAD_REQUEST,w,le);try{let ee;const ye=q("auth");if(ye){const Ie=me.getSafeProp(ye,"username")||"",Ct=me.getSafeProp(ye,"password")||"";ee={username:Ie,password:Ct}}if(SA(x)){const Ie=new URL(x,Mr.origin);if(!ee&&(Ie.username||Ie.password)){const Ct=Xm(Ie.username),St=Xm(Ie.password);ee={username:Ct,password:St}}(Ie.username||Ie.password)&&(Ie.username="",Ie.password="",x=Ie.href)}if(ee&&(B.delete("authorization"),B.set("Authorization","Basic "+btoa($A((ee.username||"")+":"+(ee.password||""))))),j&&typeof x=="string"&&x.startsWith("data:")&&_A(x)>$)throw new tt("maxContentLength size of "+$+" exceeded",tt.ERR_BAD_RESPONSE,w,le);if(U&&R!=="get"&&R!=="head"){const Ie=await f(T);if(typeof Ie=="number"&&isFinite(Ie)&&(ue=Ie,Ie>A))throw oe()}const we=U&&(me.isReadableStream(T)||me.isStream(T)),Ae=(Ie,Ct,St)=>Ym(Ie,Zm,Vt=>{if(U&&Vt>A)throw he=oe();Ct&&Ct(Vt)},St);if(u&&R!=="get"&&R!=="head"&&(E||we)){if(ue=ue??await m(B,T),ue!==0||we){let Ie=new h(x,{method:"POST",body:T,duplex:"half"}),Ct;if(me.isFormData(T)&&(Ct=Ie.headers.get("content-type"))&&B.setContentType(Ct),Ie.body){const[St,Vt]=E&&Wm(ue,Yc(Hm(E)))||[];T=Ae(Ie.body,St,Vt)}}}else if(we&&!s&&a&&R!=="get"&&R!=="head")T=Ae(T);else if(we&&s&&!u&&R!=="get"&&R!=="head")throw new tt("Stream request bodies are not supported by the current fetch implementation",tt.ERR_NOT_SUPPORT,w,le);me.isString(N)||(N=N?"include":"omit");const Je=s&&"credentials"in h.prototype;if(me.isFormData(T)){const Ie=B.getContentType();Ie&&/^multipart\/form-data/i.test(Ie)&&!/boundary=/i.test(Ie)&&B.delete("content-type")}B.set("User-Agent","axios/"+sd,!1);const ze=M==null?M:Object.assign(Object.create(null),M);ze&&(delete ze.body,delete ze.headers,delete ze.method,delete ze.signal,delete ze.duplex,delete ze.credentials);const Ye=Object.assign(Object.create(null),ze,{signal:re,method:R.toUpperCase(),headers:_m(B.normalize()),body:T,duplex:"half",credentials:Je?N:void 0});s&&(me.forEach(AA,(Ie,Ct)=>{Ye[Ct]===void 0&&(Ye[Ct]=Ie)}),Ye.signal===void 0&&(Ye.signal=null),Ye.body===void 0&&(Ye.body=null)),D===0&&(Ye.redirect="manual",ze&&(ze.redirect="manual")),le=s&&new h(x,Ye);let Ze=await(s?Q(le,ze):Q(x,Ye));const at=Yr.from(Ze.headers);if(j){const Ie=me.toFiniteNumber(at.getContentLength());if(Ie!=null&&Ie>$)throw new tt("maxContentLength size of "+$+" exceeded",tt.ERR_BAD_RESPONSE,w,le)}const ct=d&&(k==="stream"||k==="response");if(d&&Ze.body&&(O||j||ct&&ne)){const Ie={};["status","statusText","headers"].forEach(mt=>{Ie[mt]=Ze[mt]});const Ct=me.toFiniteNumber(at.getContentLength()),[St,Vt]=O&&Wm(Ct,Yc(Hm(O),!0))||[];let hn=0;const $n=mt=>{if(j&&(hn=mt,hn>$))throw new tt("maxContentLength size of "+$+" exceeded",tt.ERR_BAD_RESPONSE,w,le);St&&St(mt)};Ze=new g(Ym(Ze.body,Zm,$n,()=>{Vt&&Vt(),ne&&ne()}),Ie)}k=k||"text";let Ft=await o[me.findKey(o,k)||"text"](Ze,w);if(j&&!d&&!ct){let Ie;if(Ft!=null&&(typeof Ft.byteLength=="number"?Ie=Ft.byteLength:typeof Ft.size=="number"?Ie=Ft.size:typeof Ft=="string"&&(Ie=typeof r=="function"?new r().encode(Ft).byteLength:Ft.length)),typeof Ie=="number"&&Ie>$)throw new tt("maxContentLength size of "+$+" exceeded",tt.ERR_BAD_RESPONSE,w,le)}return!ct&&ne&&ne(),await new Promise((Ie,Ct)=>{Fm(Ie,Ct,{data:Ft,headers:Yr.from(Ze.headers),status:Ze.status,statusText:Ze.statusText,config:w,request:le})})}catch(ee){if(ne&&ne(),re&&re.aborted&&re.reason instanceof tt){const ye=re.reason;throw ye.config=w,le&&(ye.request=le),ee!==ye&&Object.defineProperty(ye,"cause",{__proto__:null,value:ee,writable:!0,enumerable:!1,configurable:!0}),ye}if(he)throw le&&!he.request&&(he.request=le),he;if(ee instanceof tt)throw le&&!ee.request&&(ee.request=le),ee;if(ee&&ee.name==="TypeError"&&/Load failed|fetch/i.test(ee.message)){const ye=new tt("Network Error",tt.ERR_NETWORK,w,le,ee&&ee.response);throw Object.defineProperty(ye,"cause",{__proto__:null,value:ee.cause||ee,writable:!0,enumerable:!1,configurable:!0}),ye}throw tt.from(ee,ee&&ee.code,w,le,ee&&ee.response)}}},EA=new Map,tv=e=>{let n=e&&e.env||{};const{fetch:t,Request:r,Response:c}=n,h=[r,c,t];let g=h.length,v=g,s,p,a=EA;for(;v--;)s=h[v],p=a.get(s),p===void 0&&a.set(s,p=v?new Map:TA(n)),a=p;return p};tv();const ad={http:D_,xhr:fA,fetch:{get:tv}};me.forEach(ad,(e,n)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:n})}catch{}Object.defineProperty(e,"adapterName",{__proto__:null,value:n})}});const nv=e=>`- ${e}`,IA=e=>me.isFunction(e)||e===null||e===!1;function MA(e,n){e=me.isArray(e)?e:[e];const{length:t}=e;let r,c;const h={};for(let g=0;g<t;g++){r=e[g];let v;if(c=r,!IA(r)&&(c=ad[(v=String(r)).toLowerCase()],c===void 0))throw new tt(`Unknown adapter '${v}'`);if(c&&(me.isFunction(c)||(c=c.get(n))))break;h[v||"#"+g]=c}if(!c){const g=Object.entries(h).map(([s,p])=>`adapter ${s} `+(p===!1?"is not supported by the environment":"is not available in the build"));let v=t?g.length>1?`since :
4
+ `+g.map(nv).join(`
5
+ `):" "+nv(g[0]):"as no adapter specified";throw new tt("There is no suitable adapter to dispatch the request "+v,tt.ERR_NOT_SUPPORT)}return c}const rv={getAdapter:MA,adapters:ad};function ld(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Fl(null,e)}function cd(e){const n=me.toSafeFlatObject(e);return ld(n),n.headers=Yr.from(me.getSafeProp(n,"headers")),n.data=id.call(n,n.transformRequest),["post","put","patch"].indexOf(n.method)!==-1&&n.headers.setContentType("application/x-www-form-urlencoded",!1),rv.getAdapter(n.adapter||Bl.adapter,n)(n).then(function(t){ld(n),n.response=t;try{t.data=id.call(n,n.transformResponse,t)}finally{delete n.response}return t.headers=Yr.from(t.headers),t},function(t){if(!Bm(t)&&(ld(n),t&&t.response)){n.response=t.response;try{t.response.data=id.call(n,n.transformResponse,t.response)}finally{delete n.response}t.response.headers=Yr.from(t.response.headers)}return Promise.reject(t)})}const Jc={};["object","boolean","number","function","string","symbol"].forEach((e,n)=>{Jc[e]=function(t){return typeof t===e||"a"+(n<1?"n ":" ")+e}});const iv={};Jc.transitional=function(e,n,t){function r(c,h){return"[Axios v"+sd+"] Transitional option '"+c+"'"+h+(t?". "+t:"")}return(c,h,g)=>{if(e===!1)throw new tt(r(h," has been removed"+(n?" in "+n:"")),tt.ERR_DEPRECATED);return n&&!iv[h]&&(iv[h]=!0,console.warn(r(h," has been deprecated since v"+n+" and will be removed in the near future"))),e?e(c,h,g):!0}},Jc.spelling=function(e){return(n,t)=>(console.warn(`${t} is likely a misspelling of ${e}`),!0)};function RA(e,n,t){if(typeof e!="object"||e===null)throw new tt("options must be an object",tt.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let c=r.length;for(;c-- >0;){const h=r[c],g=Object.prototype.hasOwnProperty.call(n,h)?n[h]:void 0;if(g){const v=e[h],s=v===void 0||g(v,h,e);if(s!==!0)throw new tt("option "+h+" must be "+s,tt.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new tt("Unknown option "+h,tt.ERR_BAD_OPTION)}}const Qc={assertOptions:RA,validators:Jc},Kr=Qc.validators;let la=class{constructor(n){this.defaults=n||{},this.interceptors={request:new Om,response:new Om}}async request(n,t){try{return await this._request(n,t)}catch(r){if(r instanceof Error)try{let c={};Error.captureStackTrace?Error.captureStackTrace(c):c=new Error;const h=c.stack;let g="";if(typeof h=="string"){const v=h.indexOf(`
6
+ `);g=v===-1?"":h.slice(v+1)}if(!r.stack)r.stack=g;else if(g){const v=g.indexOf(`
7
+ `),s=v===-1?-1:g.indexOf(`
8
+ `,v+1),p=s===-1?"":g.slice(s+1);String(r.stack).endsWith(p)||(r.stack+=`
9
+ `+g)}}catch{}throw r}}_request(n,t){typeof n=="string"?(t=t||{},t.url=n):t=n||{},t=aa(this.defaults,t);const{transitional:r,paramsSerializer:c,headers:h}=t;r!==void 0&&Qc.assertOptions(r,{silentJSONParsing:Kr.transitional(Kr.boolean),forcedJSONParsing:Kr.transitional(Kr.boolean),clarifyTimeoutError:Kr.transitional(Kr.boolean),legacyInterceptorReqResOrdering:Kr.transitional(Kr.boolean),advertiseZstdAcceptEncoding:Kr.transitional(Kr.boolean),validateStatusUndefinedResolves:Kr.transitional(Kr.boolean)},!1),c!=null&&(me.isFunction(c)?t.paramsSerializer={serialize:c}:Qc.assertOptions(c,{encode:Kr.function,serialize:Kr.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),Qc.assertOptions(t,{baseUrl:Kr.spelling("baseURL"),withXsrfToken:Kr.spelling("withXSRFToken")},!0),t.method=(me.getSafeProp(t,"method")||me.getSafeProp(this.defaults,"method")||"get").toLowerCase();let g=h&&me.merge(h.common,h[t.method]);h&&me.forEach(zm.concat("common"),o=>{delete h[o]}),t.headers=Yr.concat(g,h);const v=[];let s=!0;this.interceptors.request.forEach(function(o){if(typeof o.runWhen=="function"&&o.runWhen(t)===!1)return;s=s&&o.synchronous;const f=t.transitional||td;f&&f.legacyInterceptorReqResOrdering?v.unshift(o.fulfilled,o.rejected):v.push(o.fulfilled,o.rejected)});const p=[];this.interceptors.response.forEach(function(o){p.push(o.fulfilled,o.rejected)});let a,l=0,u;if(!s){const o=[cd.bind(this),void 0];for(o.unshift(...v),o.push(...p),u=o.length,a=Promise.resolve(t);l<u;)a=a.then(o[l++],o[l++]);return a}u=v.length;let d=t;for(;l<u;){const o=v[l++],f=v[l++];try{d=o?o(d):d}catch(m){if(!f){a=Promise.reject(m);break}try{const w=f.call(this,m);me.isThenable(w)&&(a=Promise.resolve(w).then(()=>cd.call(this,d)))}catch(w){a=Promise.reject(w)}break}}if(!a)try{a=cd.call(this,d)}catch(o){a=Promise.reject(o)}for(l=0,u=p.length;l<u;)a=a.then(p[l++],p[l++]);return a}getUri(n){n=aa(this.defaults,n);const t=Vm(n.baseURL,n.url,n.allowAbsoluteUrls,n);return Mm(t,n.params,n.paramsSerializer)}};me.forEach(["delete","get","head","options"],function(e){la.prototype[e]=function(n,t){return this.request(aa(t||{},{method:e,url:n,data:t&&me.hasOwnProp(t,"data")?t.data:void 0}))}}),me.forEach(["post","put","patch","query"],function(e){function n(t){return function(r,c,h){return this.request(aa(h||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:c}))}}la.prototype[e]=n(),e!=="query"&&(la.prototype[e+"Form"]=n(!0))});let LA=class sk{constructor(n){if(typeof n!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(c){t=c});const r=this;this.promise.then(c=>{if(!r._listeners)return;let h=r._listeners.length;for(;h-- >0;)r._listeners[h](c);r._listeners=null}),this.promise.then=c=>{let h;const g=new Promise(v=>{r.subscribe(v),h=v}).then(c);return g.cancel=function(){r.unsubscribe(h)},g},n(function(c,h,g){r.reason||(r.reason=new Fl(c,h,g),t(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 t=this._listeners.indexOf(n);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const n=new AbortController,t=r=>{n.abort(r)};return this.subscribe(t),n.signal.unsubscribe=()=>this.unsubscribe(t),n.signal}static source(){let n;return{token:new sk(function(t){n=t}),cancel:n}}};function OA(e){return function(n){return e.apply(null,n)}}function NA(e){return me.isObject(e)&&e.isAxiosError===!0}const Zc={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,ContentTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,UnprocessableContent: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,WebServerReturnsAnUnknownError:520,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(Zc).forEach(([e,n])=>{Zc[n]===void 0&&(Zc[n]=e)});function ov(e){const n=new la(e),t=hm(la.prototype.request,n);return me.extend(t,la.prototype,n,{allOwnKeys:!0}),me.extend(t,n,null,{allOwnKeys:!0}),t.create=function(r){return ov(aa(e,r))},t}const cr=ov(Bl);cr.Axios=la,cr.CanceledError=Fl,cr.CancelToken=LA,cr.isCancel=Bm,cr.VERSION=sd,cr.toFormData=qc,cr.AxiosError=tt,cr.Cancel=cr.CanceledError,cr.all=function(e){return Promise.all(e)},cr.spread=OA,cr.isAxiosError=NA,cr.mergeConfig=aa,cr.AxiosHeaders=Yr,cr.formToJSON=e=>Pm(me.isHTMLForm(e)?new FormData(e):e),cr.getAdapter=rv.getAdapter,cr.HttpStatusCode=Zc,cr.default=cr;const{Axios:XW,AxiosError:e3,CanceledError:t3,isCancel:n3,CancelToken:r3,VERSION:i3,all:o3,Cancel:s3,isAxiosError:a3,spread:l3,toFormData:c3,AxiosHeaders:u3,HttpStatusCode:h3,formToJSON:d3,getAdapter:f3,mergeConfig:p3,create:g3}=cr;function jl(e){return e?.name==="AuthRequiredError"}const DA=new Set(["OpenC3::AuthError","OpenC3::ForbiddenError"]);function PA(e){return e?.response?.status===401||e?.status===401||DA.has(e?.name)}function sv(e){!jl(e)&&!PA(e)&&console.error(e)}let av=class extends Error{constructor(n="Authentication required"){super(n),this.name="AuthRequiredError"}};globalThis.__openc3AuthRejectionHandler||(globalThis.__openc3AuthRejectionHandler=!0,globalThis.addEventListener?.("unhandledrejection",e=>{jl(e.reason)&&e.preventDefault()}));let lv=!1;function cv(){lv||(lv=!0,OpenC3Auth.login())}async function ud(){try{await OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity)&&OpenC3Auth.setTokens()}catch(e){throw jl(e)?e:(cv(),new av(e?.message))}if(!localStorage.openc3Token)throw cv(),new av}const uv=200,hd=cr.create({baseURL:location.origin,timeout:6e4,params:{}});hd.interceptors.response.use(e=>e,e=>{if(e.response){if(e.response.config.headers["Ignore-Errors"]&&e.response.config.headers["Ignore-Errors"].includes(e.response.status.toString()))return Promise.reject(e);if(e.response.status===401)return OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity,!0).then(function(h){h&&OpenC3Auth.setTokens()}).catch(sv),Promise.reject(e);const n=e.response?.data?.error?.data?.class;if(n==="HazardousError"||n==="CriticalCmdError")return Promise.reject(e);let t=`HTTP ${e.response.status} - `;e.response?.statusText&&(t+=`${e.response.statusText} `);const r=e.response?.config?.data;typeof r=="string"&&r.length>0&&(r.length>uv?t+=`${r.slice(0,uv)}... `:t+=`${r} `),e.response?.data?.message?t+=`${e.response.data.message}`:e.response?.data?.exception?t+=`${e.response.data.exception}`:e.response?.data?.error?.message?(e.response.data.error.class&&(t+=`${e.response.data.error.class} `),t+=`${e.response.data.error.message}`):t+=`${e.response?.data}`;const{$cosmosNotify:c}=window;throw c&&c.serious({title:"Network error",body:t}),e}else throw e});const Xc=async function(e,n,{data:t,params:r={},headers:c,noAuth:h=!1,optionalAuth:g=!1,noScope:v=!1,onUploadProgress:s=!1,responseType:p}={}){if(!h)if(g){try{await ud()}catch(a){if(!jl(a))throw a}localStorage.openc3Token&&(c.Authorization=localStorage.openc3Token)}else await ud(),c.Authorization=localStorage.openc3Token;return c.manual=!0,!v&&!r.scope&&(r.scope=window.openc3Scope),hd({method:e,url:n,data:t,params:r,headers:c,onUploadProgress:s,responseType:p})},dd={Accept:"application/json"},hv={...dd,"Content-Type":"application/json"},m3=lr("E",{get:function(e,{params:n,headers:t=dd,noScope:r,noAuth:c,optionalAuth:h,onUploadProgress:g,responseType:v}={}){return Xc("get",e,{params:n,headers:t,noScope:r,noAuth:c,optionalAuth:h,onUploadProgress:g,responseType:v})},put:function(e,{data:n,params:t,headers:r=hv,noScope:c,noAuth:h,onUploadProgress:g}={}){return Xc("put",e,{data:n,params:t,headers:r,noScope:c,noAuth:h,onUploadProgress:g})},post:function(e,{data:n,params:t,headers:r=hv,noScope:c,noAuth:h,onUploadProgress:g,responseType:v}={}){return Xc("post",e,{data:n,params:t,headers:r,noScope:c,noAuth:h,onUploadProgress:g,responseType:v})},delete:function(e,{params:n,headers:t=dd,noScope:r,noAuth:c,onUploadProgress:h}={}){return Xc("delete",e,{params:n,headers:t,noScope:r,noAuth:c,onUploadProgress:h})}});let eu=()=>({emit(e,...n){for(let t=this.events[e]||[],r=0,c=t.length;r<c;r++)t[r](...n)},events:{},on(e,n){return(this.events[e]||=[]).push(n),()=>{this.events[e]=this.events[e]?.filter(t=>n!==t)}}}),Wl=class extends Error{constructor(n,t){n instanceof Error?(super(n.message),this.cause=n):super(n),this.reason=t,this.name="ReasonError"}},fd=class extends Wl{constructor(n){super("Rejected",n),this.name="SubscriptionRejectedError"}},zA=class extends Wl{constructor(n){super(n||"Timed out to receive subscription ack"),this.name="SubscriptionTimeoutError"}},Io=class extends Wl{constructor(n,t){t?super(n,t):super("Disconnected",n),this.name="DisconnectedError"}},BA=class extends Io{constructor(n){super(n,"stale_connection"),this.name="StaleConnectionError"}};function dv(e){return e?`{${Object.keys(e).sort().filter(n=>e[n]!==void 0).map(n=>{let t=JSON.stringify(e[n]);return`${JSON.stringify(n)}:${t}`}).join(",")}}`:""}let FA=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,t){if(!this._info)return this._info={id:String(n),info:t},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((t,{id:r,info:c})=>(t[r]=c,t),{})}};const ca=Symbol("state");let fv=class{constructor(n={}){this.emitter=eu(),this.params=Object.freeze(n),this.presence=new FA(this),this.initialConnect=!0,this[ca]="idle"}get identifier(){return this._identifier?this._identifier:(this._identifier=dv({channel:this.channelId,...this.params}),this._identifier)}get channelId(){return this.constructor.identifier}get state(){return this[ca]}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[ca]="connecting"}connected(){if(this.state==="connected"||this.state==="closed")return;this[ca]="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[ca]="connected";let n=!0,t=!0;this.initialConnect=!1,this.emit("connect",{reconnect:t,restored:n})}disconnected(n){this.state==="disconnected"||this.state==="closed"||(this[ca]="disconnected",this.presence.reset(),this.emit("disconnect",n))}closed(n){this.state!=="closed"&&(this[ca]="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,t){if(this.state==="idle"||this.state==="closed")throw Error("Channel is not subscribed");return this.receiver.perform(this.identifier,n,t)}async send(n){return this.perform(void 0,n)}async whisper(n){try{await this.perform("$whisper",n)}catch(t){let r=this.receiver?this.receiver.logger:null;r&&r.warn("whisper failed: ",t)}}receive(n,t){this.emit("message",n,t)}on(n,t){return this.emitter.on(n,t)}once(n,t){let r=this.emitter.on(n,(...c)=>{r(),t(...c)});return r}emit(n,...t){return this.emitter.emit(n,...t)}ensureSubscribed(){return this.state==="connected"?Promise.resolve():this.state==="closed"?Promise.reject(Error("Channel is unsubscribed")):this.pendingSubscribe()}pendingSubscribe(){return this._pendingSubscribe?this._pendingSubscribe:(this._pendingSubscribe=new Promise((n,t)=>{let r=[()=>delete this._pendingSubscribe];r.push(this.on("connect",()=>{r.forEach(c=>c()),n()})),r.push(this.on("close",c=>{r.forEach(h=>h()),t(c||new Wl("Channel was disconnected before subscribing","canceled"))}))}),this._pendingSubscribe)}},jA=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 t=this.channels.indexOf(n);t>-1&&this.channels.splice(t,1)}notify(n,...t){this.state=n==="restored"?"connected":n,t.length===1?this.channels.forEach(r=>r[n](t[0])):this.channels.forEach(r=>r[n]())}pending(n){this._checkIntent(n);let t=this._pendings[0];return!t||t.intent!==n?Promise.resolve():t.promise}ensureResubscribed(){this.disposed||(this.intent=void 0,this.ensureSubscribed())}ensureSubscribed(){if(this.intent!=="subscribed"){if(this.disposed)throw Error("Subscription is disposed");this.intent="subscribed",!this._mergeWithPending("unsubscribed")&&this.subscriber(this)}}maybeUnsubscribe(){this.disposed||this.intent==="unsubscribed"||this.channels.length>0||(this.intent="unsubscribed",this._mergeWithPending("subscribed"))||this.unsubscriber(this)}async acquire(n){this._checkIntent(n);let t,r={promise:new Promise(h=>{t=h}),intent:n,release:()=>{this._pendings.splice(this._pendings.indexOf(r),1),t(r)},canceled:!1,acquired:!1},c=this._pendingTop;return this._pendings.push(r),c&&await c.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 t=this._pendingTop;return!t||t.acquired||t.intent!==n?!1:(this._pendings.pop(),t.canceled=!0,!0)}},WA=class{constructor(){this.queue=[]}async acquire(n,t){t==="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])}},HA=class{constructor(n){n.concurrentSubscribes===!1&&(this.glv=new WA),this._subscriptions={},this._localToRemote={}}all(){return Object.values(this._subscriptions)}get(n){return this._subscriptions[n]}create(n,{subscribe:t,unsubscribe:r}){let c=this._subscriptions[n]=new jA(n);return c.remoteId=this._localToRemote[n],c.subscriber=t,c.unsubscriber=r,c.gvl=this.glv,c}remove(n){delete this._subscriptions[n],delete this._localToRemote[n]}storeRemoteId(n,t){this._localToRemote[n]=t;let r=this.get(n);r&&(r.remoteId=t)}},UA=class{constructor(n={}){this.subscriptions=new HA(n),this._pendingMessages=[],this._remoteToLocal={}}subscribe(n,t){this._remoteToLocal[t]=n,this.subscriptions.storeRemoteId(n,t),this.flush(t)}unsubscribe(n){let t=this.subscriptions.get(n);if(!t)return;let r=t.remoteId;r&&delete this._remoteToLocal[r],this.subscriptions.remove(n)}transmit(n,t,r){let c=this._remoteToLocal[n];if(!c){this._pendingMessages.push([n,t,r]);return}let h=this.subscriptions.get(c);h&&h.channels.forEach(g=>{g.receive(t,r)})}notify(n,t,r){let c=this._remoteToLocal[n];if(!c)return;let h=this.subscriptions.get(c);h&&h.channels.forEach(g=>g.emit(t,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 t=[];for(let r of this._pendingMessages)r[0]===n?this.transmit(r[0],r[1],r[2]):t.push(r);this._pendingMessages=t}};const pv={debug:0,info:1,warn:2,error:3};let gv=class{constructor(n){this.level=n||"warn"}log(n,t,r){pv[n]<pv[this.level]||this.writeLogEntry(n,t,r)}writeLogEntry(){throw Error("Not implemented")}debug(n,t){this.log("debug",n,t)}info(n,t){this.log("info",n,t)}warn(n,t){this.log("warn",n,t)}error(n,t){this.log("error",n,t)}},Hl=class extends gv{writeLogEntry(){}},VA=class{encode(n){return JSON.stringify(n)}decode(n){try{return JSON.parse(n)}catch{}}},GA=0,mv=class{constructor(n={}){let{logger:t}=n;this.logger=t||new Hl,this.pendingSubscriptions={},this.pendingUnsubscriptions={},this.subscribeCooldownInterval=n.subscribeCooldownInterval||250,this.subscribeRetryInterval=n.subscribeRetryInterval||5e3}attached(n){this.cable=n}subscribe(n,t){let r={channel:n};t&&Object.assign(r,t);let c=dv(r);if(this.pendingUnsubscriptions[c]){let g=this.subscribeCooldownInterval*1.5;return this.logger.debug(`unsubscribed recently, cooldown for ${g}`,c),new Promise(v=>{setTimeout(()=>{v(this.subscribe(n,t))},g)})}if(this.pendingSubscriptions[c])return this.logger.warn("subscription is already pending, skipping",c),Promise.reject(Error("Already subscribing"));let h=this.subscribeRetryInterval;return new Promise((g,v)=>{let s=++GA;this.pendingSubscriptions[c]={resolve:g,reject:v,id:s},this.cable.send(this.buildSubscribeRequest(c)),this.maybeRetrySubscribe(s,c,h)})}buildSubscribeRequest(n){return{command:"subscribe",identifier:n}}maybeRetrySubscribe(n,t,r){setTimeout(()=>{let c=this.pendingSubscriptions[t];c&&c.id===n&&(this.logger.warn(`no subscription ack received in ${r}ms, retrying subscribe`,t),this.cable.send(this.buildSubscribeRequest(t)),this.maybeExpireSubscribe(n,t,r))},r)}maybeExpireSubscribe(n,t,r){setTimeout(()=>{let c=this.pendingSubscriptions[t];c&&c.id===n&&(delete this.pendingSubscriptions[t],c.reject(new zA(`Haven't received subscription ack in ${r*2}ms for ${t}`)))},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,t,r){return t==="$whisper"?this.whisper(n,r):(r||(r={}),r.action||=t,this.cable.send({command:"message",identifier:n,data:JSON.stringify(r)}),Promise.resolve())}whisper(n,t){return this.cable.send({command:"whisper",identifier:n,data:t}),Promise.resolve()}receive(n){if(typeof n!="object"){this.logger.error("unsupported message format",{message:n});return}let{type:t,identifier:r,message:c,reason:h,reconnect:g}=n;if(t==="ping")return this.cable.keepalive(n.message);if(this.cable.keepalive(),t==="welcome"){let v=n.sid;return v&&this.cable.setSessionId(v),this.cable.connected()}if(t==="disconnect"){let v=new Io(h);this.reset(v),g===!1?this.cable.closed(v):this.cable.disconnected(v);return}if(t==="confirm_subscription"){let v=this.pendingSubscriptions[r];if(!v){this.logger.error("subscription not found, unsubscribing",{type:t,identifier:r}),this.unsubscribe(r);return}return delete this.pendingSubscriptions[r],v.resolve(r)}if(t==="reject_subscription"){let v=this.pendingSubscriptions[r];return v?(delete this.pendingSubscriptions[r],v.reject(new fd)):this.logger.error("subscription not found",{type:t,identifier:r})}if(c)return{identifier:r,message:c};this.logger.warn(`unknown message type: ${t}`,{message:n})}reset(n){for(let t in this.pendingSubscriptions)this.pendingSubscriptions[t].reject(n);this.pendingSubscriptions={}}recoverableClosure(){return!1}};const vv=()=>Date.now()/1e3|0;let qA=class extends mv{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=vv()),this.sessionId=void 0,this.sendPongs=n.pongs}reset(n){for(let t in this.pendingPresence)this.pendingPresence[t].reject(n);return this.pendingPresence={},super.reset()}receive(n){if(typeof n!="object"){this.logger.error("unsupported message format",{message:n});return}let{type:t,identifier:r,message:c}=n;if(t==="disconnect")return delete this.sessionId,this.cable.setSessionId(""),super.receive(n);if(t==="reject_subscription")return super.receive(n);if(t==="confirm_subscription")return this.subscriptionStreams[r]||(this.subscriptionStreams[r]=new Set),super.receive(n);if(t==="ping")return this.restoreSince&&(this.restoreSince=vv()),this.sendPongs&&this.sendPong(),this.cable.keepalive(n.message);if(this.cable.keepalive(),t==="confirm_history"){this.logger.debug("history result received",n),this.cable.notify("history_received",r);return}if(t==="reject_history"){this.logger.warn("failed to retrieve history",n),this.cable.notify("history_not_found",r);return}if(t==="welcome"){if(this.disableSessionRecovery||(this.sessionId=n.sid,this.sessionId&&this.cable.setSessionId(this.sessionId)),n.restored){let h=n.restored_ids||Object.keys(this.subscriptionStreams);for(let g of h)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(h)}return this.cable.connected(this.sessionId)}if(t==="presence"){let h=c.type;if(h==="info"){let g=this.pendingPresence[r];g&&(delete this.pendingPresence[r],g.resolve(c))}else if(h==="error"){let g=this.pendingPresence[r];g&&(delete this.pendingPresence[r],g.reject(new Error("failed to retrieve presence")))}return{type:t,identifier:r,message:c}}if(c){let h=this.trackStreamPosition(r,n.stream_id,n.epoch,n.offset);return{identifier:r,message:c,meta:h}}this.logger.warn(`unknown message type: ${t}`,{message:n})}perform(n,t,r){switch(t){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,t,r)}unsubscribe(n){return delete this.presenceInfo[n],super.unsubscribe(n)}buildSubscribeRequest(n){let t=super.buildSubscribeRequest(n),r=this.historyRequestFor(n);r&&(t.history=r,this.pendingHistory[n]=!0);let c=this.presenceInfo[n];return c&&(t.presence=c),t}recoverableClosure(){return!!this.sessionId}historyRequestFor(n){let t={},r=!1;if(this.subscriptionStreams[n])for(let c of this.subscriptionStreams[n]){let h=this.streamsPositions[c];h&&(r=!0,t[c]=h)}if(!(!r&&!this.restoreSince))return{since:this.restoreSince,streams:t}}trackStreamPosition(n,t,r,c){if(!(!t||!r))return this.subscriptionStreams[n]||(this.subscriptionStreams[n]=new Set),this.subscriptionStreams[n].add(t),this.streamsPositions[t]={epoch:r,offset:c},{stream:t,epoch:r,offset:c}}async sendPong(){await new Promise(n=>setTimeout(n,0)),this.cable.state==="connected"&&this.cable.send({command:"pong"})}async join(n,t){return this.presenceInfo[n]=t,this.cable.send({command:"join",identifier:n,presence:t}),Promise.resolve()}async leave(n,t){return delete this.presenceInfo[n],this.cable.send({command:"leave",identifier:n,presence:t}),Promise.resolve()}presence(n,t){return this.pendingPresence[n]?(this.logger.warn("presence is already pending, skipping",n),Promise.reject(Error("presence request is already pending"))):new Promise((r,c)=>{this.pendingPresence[n]={resolve:r,reject:c},this.cable.send({command:"presence",identifier:n,data:t})})}},YA=class extends Wl{constructor(){super("No connection","closed"),this.name="NoConnectionError"}},yv=class extends fv{static identifier="__ghost__";constructor(n,t){super(t),this.channelId=n}set channelId(n){this._channelId=n}get channelId(){return this._channelId}};const KA="$pubsub";let bv=class extends fv{static identifier=KA;async perform(n,t){if(n.startsWith("$"))return super.perform(n,t);throw Error("not implemented")}};const ua=Symbol("state");let JA=class{constructor({transport:n,protocol:t,encoder:r,logger:c,lazy:h,hubOptions:g,performFailures:v,transportConfigurator:s}){this.emitter=eu(),this.transport=n,this.encoder=r,this.logger=c||new Hl,this.protocol=t,this.performFailures=v||"throw",this.protocol.attached(this),this.hub=new UA(g||{}),this[ua]="idle",this.handleClose=this.handleClose.bind(this),this.handleIncoming=this.handleIncoming.bind(this),this.transportConfigurator=s,this.transport.on("close",this.handleClose),this.transport.on("data",this.handleIncoming),this.initialConnect=!0,this.recovering=!1,h===!1&&this.connect().catch(()=>{})}get state(){return this[ua]}async connect(){if(this.state==="connected")return Promise.resolve();if(this.state==="connecting")return this.pendingConnect();let n=this.state==="idle";this[ua]="connecting";let t=this.pendingConnect();this.logger.debug("connecting");try{this.transportConfigurator&&await this.transportConfigurator(this.transport,{initial:n}),await this.transport.open()}catch(r){this.handleClose(r)}return t}setSessionId(n){this.sessionId=n,this.transport.setParam("sid",n)}connected(){if(this.state==="connected")return;this.logger.info("connected"),this[ua]="connected",this.recovering&&this.hub.subscriptions.all().forEach(t=>t.notify("disconnected",new Io("recovery_failed"))),this.hub.subscriptions.all().forEach(t=>this._resubscribe(t));let n=!1;this.recovering=!1,this.initialConnect?(this.initialConnect=!1,this.emit("connect",{reconnect:!1,restored:n})):this.emit("connect",{reconnect:!0,restored:n})}restored(n){this.logger.info("connection recovered",{remoteIds:n}),this[ua]="connected",this.hub.subscriptions.all().forEach(c=>{n&&c.remoteId&&n.includes(c.remoteId)?c.notify("restored"):(c.notify("disconnected",new Io("recovery_failed")),this._resubscribe(c))});let t=!this.initialConnect,r=!0;this.recovering=!1,this.initialConnect=!1,this.emit("connect",{reconnect:t,restored:r})}notify(n,t,r){t&&typeof t!="string"&&(r=t,t=void 0),t?this.hub.notify(t,"info",{type:n,data:r}):this.emit("info",{type:n,data:r})}handleClose(n){this.logger.debug("transport closed",{error:n}),this.disconnected(new Io(n,"transport_closed"))}disconnected(n){(this.state==="connected"||this.state==="connecting")&&(this.logger.info("disconnected",{reason:n}),this[ua]="disconnected",this.recovering=this.protocol.recoverableClosure(n),this.recovering?this.hub.subscriptions.all().forEach(t=>t.notify("connecting")):this.hub.subscriptions.all().forEach(t=>{t.notify("disconnected",n)}),this.protocol.reset(n),this.hub.close(),this.transport.close(),this.emit("disconnect",n))}closed(n){if(this.state==="closed"||this.state==="idle")return;let t;n&&(t=n instanceof Io?n:new Io(n,void 0)),this.logger.info("closed",{reason:n||"user"}),this[ua]="closed";let r=t||new Io("cable_closed");this.hub.subscriptions.all().forEach(c=>c.notify("disconnected",r)),this.hub.close(),this.protocol.reset(),this.transport.close(),this.initialConnect=!0,this.emit("close",t)}disconnect(){this.closed()}handleIncoming(n){if(this.state==="closed"||this.state==="idle")return;let t=this.encoder.decode(n);if(t===void 0){this.logger.error("failed to decode message",{message:n});return}this.logger.debug("incoming data",t);let r=this.protocol.receive(t);if(r){this.logger.debug("processed incoming message",r);let{type:c,identifier:h,message:g,meta:v}=r;c?this.hub.notify(h,c,g):this.hub.transmit(h,g,v)}}send(n){if(this.state==="closed")throw Error("Cable is closed");let t=this.encoder.encode(n);if(t===void 0){this.logger.error("failed to encode message",{message:n});return}this.logger.debug("outgoing message",n),this.transport.send(t)}keepalive(n){this.emit("keepalive",n)}streamFrom(n){let t=new bv({stream_name:n});return this.subscribe(t)}streamFromSigned(n){let t=new bv({signed_stream_name:n});return this.subscribe(t)}subscribeTo(n,t){let r,c;return typeof n=="string"&&(c=n,n=yv),r=c?new n(c,t):new n(t),this.subscribe(r)}subscribe(n){if(!n.attached(this))return n;let t=n.identifier;n.connecting();let r=this.hub.subscriptions.get(t)||this.hub.subscriptions.create(t,{subscribe:c=>this._subscribe(c,n.channelId,n.params),unsubscribe:c=>this._unsubscribe(c)});return r.add(n),r.intent==="subscribed"&&r.state==="connected"&&n.connected(),r.ensureSubscribed(),n}async _resubscribe(n){n.intent!=="subscribed"||!n.channels[0]||(n.notify("connecting"),n.ensureResubscribed())}async _subscribe(n,t,r){let c=n.id;if(this.state==="idle"&&this.connect().catch(()=>{}),this.state!=="connected"){this.logger.debug("cancel subscribe, no connection",{identifier:c});return}this.logger.debug("acquiring subscribe lock",{identifier:c});let h=await n.acquire("subscribed");if(h.canceled){this.logger.debug("subscribe lock has been canceled",{identifier:c}),h.release();return}if(this.logger.debug("subscribe lock has been acquired",{identifier:c}),n.intent!=="subscribed"){this.logger.debug("cancel subscribe request, already unsubscribed"),h.release();return}if(this.state!=="connected"){this.logger.debug("cancel subscribe, no connection",{identifier:c}),h.release();return}if(n.state==="connected"){this.logger.debug("already connected, skip subscribe command",{identifier:c}),n.notify("connected"),h.release();return}let g={identifier:t,params:r};this.logger.debug("subscribing",g);try{let v=await this.protocol.subscribe(t,r);this.hub.subscribe(c,v),this.logger.debug("subscribed",{...g,remoteId:v}),n.notify("connected")}catch(v){if(v){if(v instanceof fd&&this.logger.warn("rejected",g),v instanceof Io){this.logger.debug("disconnected during subscription; will retry on connect",g),h.release();return}this.logger.error("failed to subscribe",{error:v,...g})}n.close(v),this.hub.unsubscribe(c)}h.release()}unsubscribe(n){let t=n.identifier,r=this.hub.subscriptions.get(t);if(!r)throw Error(`Subscription not found: ${t}`);r.remove(n),n.closed(),r.maybeUnsubscribe()}async _unsubscribe(n){let t=n.id;this.logger.debug("acquiring unsubscribe lock",{identifier:t});let r=await n.acquire("unsubscribed");if(r.canceled){this.logger.debug("unsubscribe lock has been canceled",{identifier:t}),r.release();return}if(this.logger.debug("unsubscribe lock has been acquired",{identifier:t}),n.intent!=="unsubscribed"){this.logger.debug("cancel unsubscribe, no longer needed",{identifier:t,intent:n.intent}),r.release();return}if(n.state==="disconnected"||n.state==="closed"){this.logger.debug(`already ${n.state} connected, skip unsubscribe command`,{identifier:t}),r.release();return}let c=n.remoteId;if(this.logger.debug("unsubscribing...",{remoteId:c}),this.state!=="connected"){this.logger.debug("unsubscribe skipped (cable is not connected)",{id:t}),n.close(),this.hub.unsubscribe(t),r.release();return}try{await this.protocol.unsubscribe(c),this.logger.debug("unsubscribed remotely",{id:t})}catch(h){h&&(h instanceof Io?this.logger.debug("cable disconnected during the unsubscribe command execution",{id:t,error:h}):this.logger.error("unsubscribe failed",{id:t,error:h}))}n.intent==="unsubscribed"?(n.close(),this.hub.unsubscribe(t)):n.state="closed",r.release()}async perform(n,t,r){if(this.performFailures==="throw")return this._perform(n,t,r);try{return await this._perform(n,t,r)}catch(c){this.performFailures==="warn"&&this.logger.warn("perform failed",{error:c});return}}async _perform(n,t,r){if(this.state==="connecting"&&await this.pendingConnect(),this.state==="closed"||this.state==="disconnected")throw new YA;let c=this.hub.subscriptions.get(n);if(!c)throw Error(`Subscription not found: ${n}`);if(await c.pending("subscribed"),c.intent!=="subscribed")throw Error(`Subscription is closed: ${n}`);let h=c.remoteId,g={id:h,action:t,payload:r};this.logger.debug("perform",g);try{let v=await this.protocol.perform(h,t,r);return v&&this.logger.debug("perform result",{message:v,request:g}),v}catch(v){throw this.logger.error("perform failed",{error:v,request:g}),v}}on(n,t){return this.emitter.on(n,t)}once(n,t){let r=this.emitter.on(n,(...c)=>{r(),t(...c)});return r}emit(n,...t){return this.emitter.emit(n,...t)}pendingConnect(){return this._pendingConnect?this._pendingConnect:(this._pendingConnect=new Promise((n,t)=>{let r=[()=>delete this._pendingConnect];r.push(this.on("connect",()=>{r.forEach(c=>c()),n()})),r.push(this.on("close",c=>{r.forEach(h=>h()),t(c)})),r.push(this.on("disconnect",c=>{r.forEach(h=>h()),t(c)}))}),this._pendingConnect)}};const QA={maxMissingPings:2,maxReconnectAttempts:1/0},Va=()=>Date.now(),wv=(e,n)=>{n=n||{};let{backoffRate:t,jitterRatio:r,maxInterval:c}=n;return t=t||2,r===void 0&&(r=.5),h=>{let g=e*t**h,v=g*t,s=g+(v-g)*Math.random(),p=2*(Math.random()-.5)*r;return s=s*(1+p),c&&c<s&&(s=c),s}};let xv=class{constructor({pingInterval:n,...t}){if(this.pingInterval=n,!this.pingInterval)throw Error(`Incorrect pingInterval is provided: ${n}`);if(t=Object.assign({},QA,t),this.strategy=t.reconnectStrategy,!this.strategy)throw Error("Reconnect strategy must be provided");this.maxMissingPings=t.maxMissingPings,this.maxReconnectAttempts=t.maxReconnectAttempts,this.logger=t.logger||new Hl,this.state="pending_connect",this.attempts=0,this.disconnectedAt=Va()}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=Va(),this.state="connected",this.cancelReconnect(),this.startPolling()})),this.unbind.push(this.target.on("disconnect",()=>{this.disconnectedAt=Va(),this.state="disconnected",this.stopPolling(),this.scheduleReconnect()})),this.unbind.push(this.target.on("close",()=>{this.disconnectedAt=Va(),this.state="closed",this.cancelReconnect(),this.stopPolling()})),this.unbind.push(this.target.on("keepalive",()=>{this.pingedAt=Va()})),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=Va()-this.pingedAt;n>this.maxMissingPings*this.pingInterval&&(this.logger.warn(`Stale connection: ${n}ms without pings`),this.state="pending_disconnect",this.target.disconnected(new BA))}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)}},ZA=class{constructor(n,t={}){this.transports=n,this.transport=null,this.emitter=eu(),this.unbind=[],this.logger=t.logger||new Hl}displayName(){return"fallbacked transport"}async open(){for(let n=0;n<this.transports.length;n++){let t=this.transports[n];try{this.transport=t,this.resetListeners(),this.logger.debug(`Trying to connect via ${t.displayName()}`),await t.open(),this.logger.debug(`Connected via ${t.displayName()}`);return}catch(r){this.logger.debug(`Failed to connect via ${t.displayName()}: ${r.message}`)}}throw this.transport=null,this.resetListeners(),new Error("Couldn't connect via any available transport")}send(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,t){this.transports.forEach(r=>{r.setParam(n,t)})}setToken(n,t){this.transports.forEach(r=>{r.setToken(n,t)})}on(n,t){return this.emitter.on(n,t)}once(n,t){let r=this.emitter.on(n,(...c)=>{r(),t(...c)});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)}))}},XA=class{constructor(n,t={}){this.url=n;let r=t.websocketImplementation;if(r)this.Impl=r;else if(typeof WebSocket<"u")this.Impl=WebSocket;else throw new Error("No WebSocket support");this.connected=!1,this.emitter=eu();let{format:c,subprotocol:h,authStrategy:g}=t;this.format=c||"text",this.connectionOptions=t.websocketOptions,this.authStrategy=g||"param",this.authProtocol="",this.subprotocol=h}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((t,r)=>{let c=[];c.push(this.once("open",()=>{c.forEach(h=>h()),t()})),c.push(this.once("close",()=>{c.forEach(h=>h()),r(Error("WS connection closed"))}))})}setURL(n){this.url=n}setParam(n,t){let r=new URL(this.url);r.searchParams.set(n,t);let c=`${r.protocol}//${r.host}${r.pathname}?${r.searchParams}`;this.setURL(c)}setToken(n,t="jid"){if(this.authStrategy==="param")this.setParam(t,n);else if(this.authStrategy==="header"){this.connectionOptions=this.connectionOptions||{},this.connectionOptions.headers=this.connectionOptions.headers||{};let r=`x-${t}`.toLowerCase();r=Object.keys(this.connectionOptions.headers).find(c=>c.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,t){return this.emitter.on(n,t)}once(n,t){let r=this.emitter.on(n,(...c)=>{r(),t(...c)});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 t=n.data;this.format==="binary"&&(t=new Uint8Array(t)),this.emitter.emit("data",t)},this.ws.onopen=()=>{this.connected=!0,this.emitter.emit("open")}}onclose(){this.ws.onclose=void 0,this.ws.onmessage=void 0,this.ws.onopen=void 0,this.ws.close(),delete this.ws,this.connected=!1,this.emitter.emit("close")}},e$=class{constructor(n){this.channel=n}notify(n,...t){typeof this[n]=="function"&&this[n](...t)}perform(n,t={}){this.channel.perform(n,t)}send(n){this.channel.send(n)}whisper(n){return this.channel.whisper(n)}get identifier(){return this.channel.identifier}unsubscribe(){return this.channel.disconnect()}},t$=class extends yv{constructor(n,t,r){super(n,t),this.subscription=new e$(this),Object.assign(this.subscription,r),this.on("connect",({reconnect:c})=>this.subscription.notify("connected",{reconnected:c})),this.on("disconnect",()=>this.subscription.notify("disconnected",{allowReconnect:!0})),this.on("message",c=>this.subscription.notify("received",c)),this.on("close",c=>{c&&c instanceof fd?this.subscription.notify("rejected"):this.subscription.notify("disconnected",{allowReconnect:!1})})}},n$=class{constructor(n){this.cable=n}create(n,t){let r,c;typeof n=="object"?(r=n.channel,delete n.channel,c=n):(r=n,c={});let h=new t$(r,c,t);return h.subscription.notify("initialized"),this.cable.subscribe(h),h.subscription}findAll(n){return this.cable.hub.channels.filter(t=>t.identifier===n).map(t=>t.subscription)}},r$=class{constructor(n){this.cable=n,this.subscriptions=new n$(n)}send(n){return this.cable.send(n)}connect(){return this.cable.connect()}disconnect(){return this.cable.disconnect()}ensureActiveConnection(){return this.cable.connect()}};const Cv={protocol:"actioncable-v1-json",pingInterval:3e3,maxReconnectAttempts:1/0,maxMissingPings:2,logLevel:"warn",lazy:!0};function i$(e,n){if(typeof e=="object"&&typeof n>"u"&&(n=e,e=void 0),n=n||{},!e&&!n.transport)throw Error("URL or transport must be specified");n=Object.assign({},Cv,n);let{protocol:t,websocketImplementation:r,websocketFormat:c,websocketOptions:h,websocketAuthStrategy:g,fallbacks:v,logLevel:s,logger:p,transport:a,encoder:l,lazy:u,monitor:d,pingInterval:o,reconnectStrategy:f,maxMissingPings:m,maxReconnectAttempts:w,subprotocol:x,tokenRefresher:R,historyTimestamp:T,protocolOptions:_,concurrentSubscribes:C,performFailures:P,transportConfigurator:O,auth:E}=n;if(p=p||new Hl(s),typeof t=="string"){x=x||t;let N=t.substring(0,t.lastIndexOf("-")),M=t.substring(t.lastIndexOf("-")+1);if(_=_||{},N==="actioncable-v1")t=new mv({logger:p,..._});else if(N==="actioncable-v1-ext")t=new qA({logger:p,historyTimestamp:T,..._});else throw Error(`Protocol is not supported yet: ${t}`);if(M==="json")l=l||new VA,c=c||"text";else if(M==="msgpack"){if(c="binary",!l)throw Error("Msgpack encoder must be specified explicitly. Use `@anycable/msgpack-encoder` package or build your own")}else if(M==="protobuf"){if(c=c||"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: ${t}`)}if(!t)throw Error("Protocol must be specified");a=a||new XA(e,{websocketImplementation:r,websocketOptions:h,subprotocol:x,authStrategy:g,format:c}),v&&(a=new ZA([a,...v],{logger:p})),E&&E.token&&a.setToken(E.token,E.param||"jid"),f=f||wv(o),d!==!1&&(d=d||new xv({pingInterval:o,reconnectStrategy:f,maxMissingPings:m,maxReconnectAttempts:w,logger:p}));let k={concurrentSubscribes:C},B=new JA({protocol:t,transport:a,encoder:l,logger:p,lazy:u,hubOptions:k,performFailures:P,transportConfigurator:O});return d&&(d.watch(B),B.monitor=d),R&&o$(B,async()=>{try{await R(a)}catch(N){return p.error("Failed to refresh authentication token: "+N),!1}return B.connect().catch(()=>{}),!0}),B}function o$(e,n){let t=!1;e.on("connect",()=>t=!1),e.on("close",async r=>{if(r){if(t){e.logger.warn("Token auto-refresh is disabled",r);return}r.reason==="token_expired"&&(t=!0,await n())}})}let s$=class extends gv{writeLogEntry(n,t,r){r?console[n](t,r):console[n](t)}},a$=class extends xv{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")},t=c=>{this.reconnectNow()&&this.logger.debug("Trigger reconnect",{event:c})},r=()=>this.disconnect(new Io("page_frozen"));document.addEventListener("visibilitychange",n,!1),window.addEventListener("focus",t,!1),window.addEventListener("online",t,!1),window.addEventListener("resume",t,!1),window.addEventListener("freeze",r,!1),this.unbind.push(()=>{document.removeEventListener("visibilitychange",n,!1),window.removeEventListener("focus",t,!1),window.removeEventListener("online",t,!1),window.removeEventListener("resume",t,!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 l$=["cable","action-cable"],c$="/cable",tu=(e,n)=>{for(let t of l$){let r=e.head.querySelector(`meta[name='${t}-${n}']`);if(r)return r.getAttribute("content")}},kv=e=>e.match(/wss?:\/\//)?e:typeof window<"u"?`${window.location.protocol.replace("http","ws")}//${window.location.host}${e}`:e,u$=()=>{if(typeof document<"u"&&document.head){let e=tu(document,"url");if(e)return kv(e)}return kv(c$)},h$=()=>{if(typeof document<"u"&&document.head){let e=tu(document,"history-timestamp");if(e)return e|0}},d$=()=>{if(typeof document<"u"&&document.head)return tu(document,"token")},f$=()=>{if(typeof document<"u"&&document.head)return tu(document,"token-param")};function p$(e,n){typeof e=="object"&&typeof n>"u"&&(n=e,e=void 0),e=e||u$(),n=n||{},n.historyTimestamp||=h$();let t=d$();if(t){let p=f$();n.auth=Object.assign({token:t,param:p},n.auth||{})}n=Object.assign({},Cv,n);let{logLevel:r,logger:c,pingInterval:h,reconnectStrategy:g,maxMissingPings:v,maxReconnectAttempts:s}=n;return c=n.logger=n.logger||new s$(r),g=n.reconnectStrategy=n.reconnectStrategy||wv(h),n.monitor!==!1&&(n.monitor=n.monitor||new a$({pingInterval:h,reconnectStrategy:g,maxMissingPings:v,maxReconnectAttempts:s,logger:c})),i$(e,n)}function g$(e,n){let t=p$(e,n);return new r$(t)}const m$=1e3,_v="/openc3-api/cable",v$=6e4,y$="__openc3_cable__";let b$=class{constructor(n,t,r,c,h){this._cable=n,this._channel=t,this._scope=r,this._callbacks=c,this._additionalOptions=h,this._subscription=null,this._unsubscribed=!1,this._heartbeat=null}get identifier(){return this._subscription?.identifier}perform(n,t){return this._unsubscribed?Promise.resolve():this._subscription?.perform(n,t)}send(n){return this._unsubscribed?Promise.resolve():this._subscription?.send(n)}unsubscribe(){return this._unsubscribed=!0,this._stopHeartbeat(),this._cable._forget(this),this._subscription?.unsubscribe()}_subscribe(n){this._unsubscribed||(this._subscription=n.subscriptions.create({channel:this._channel,token:localStorage.openc3Token,...this._cable._heartbeatInterval?{heartbeat:!0}:{},...this._additionalOptions},{...this._callbacks,received:t=>{if(t?.[y$]==="resubscribe"){this._cable._scheduleRecovery();return}this._callbacks.received?.(t)},disconnected:t=>{this._unsubscribed||(t?.allowReconnect===!1&&this._cable._scheduleRecovery(),this._callbacks.disconnected?.(t))}}),this._startHeartbeat())}_startHeartbeat(){const n=this._cable._heartbeatInterval;!n||this._heartbeat||(this._heartbeat=setInterval(()=>{if(this._unsubscribed){this._stopHeartbeat();return}Promise.resolve().then(()=>this._subscription?.perform("heartbeat",{})).catch(()=>{})},n))}_stopHeartbeat(){this._heartbeat&&(clearInterval(this._heartbeat),this._heartbeat=null)}},Av=class{constructor(n=_v,{heartbeatInterval:t=n===_v?v$:0}={}){this._cable=null,this._url=n,this._heartbeatInterval=t,this._subscriptions=new Set,this._recovery=null}disconnect(){this._cancelRecovery(),this._subscriptions.forEach(n=>{n._unsubscribed=!0,n._stopHeartbeat()}),this._subscriptions.clear(),this._cable&&(this._cable.cable.disconnect(),this._cable=null)}createSubscription(n,t,r={},c={}){const h=new b$(this,n,t,r,c);return this._subscriptions.add(h),this._resubscribe(h).then(()=>h)}_resubscribe(n){if(this._cable==null){const t=new URL(this._url,document.baseURI);t.searchParams.set("scope",n._scope),this._cable=g$(t.href)}return OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity).then(t=>{t&&OpenC3Auth.setTokens(),this._cable&&n._subscribe(this._cable)}).catch(t=>{if(!jl(t))throw t})}_scheduleRecovery(){this._recovery||(this._recovery=setTimeout(()=>{const n=[...this._subscriptions];this._cable&&(this._cable.cable.disconnect(),this._cable=null),n.reduce((t,r)=>t.then(()=>this._resubscribe(r)),Promise.resolve()).catch(t=>console.error("failed to recover cable",t)).finally(()=>{this._recovery=null})},m$))}_cancelRecovery(){this._recovery&&(clearTimeout(this._recovery),this._recovery=null)}_forget(n){this._subscriptions.delete(n),this._subscriptions.size===0&&this._cancelRecovery()}recordPing(){}};lr("x",Av),lr("j",class{constructor(n,t,r="",c=""){this.keyword=n.keyword,this.parameters=n.parameters,this.filename=n.filename,this.line=n.line,this.lineNumber=n.lineNumber,this.message=t,this.usage=r,this.url=c}});function nu(e){return w$.test(e)}const w$=/^-?[0-9]+$/;function $v(e){return x$.test(e)}const x$=/^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?$/;function Sv(e,n){if(nu(e))return Number.isSafeInteger(Number.parseInt(e,10));const t=Number.parseFloat(e);if(Number.isInteger(t)&&!Number.isSafeInteger(t))return!1;const r=String(t);if(e===r)return!0;const c=Tv(e),h=Tv(r);return!!(c===h||n?.approx===!0&&h.length>=14&&c.startsWith(h.substring(0,14)))}let Ul=(function(e){return e.underflow="underflow",e.overflow="overflow",e.truncate_integer="truncate_integer",e.truncate_float="truncate_float",e})({});function C$(e){if(Sv(e,{approx:!1}))return;if(nu(e))return Ul.truncate_integer;const n=Number.parseFloat(e);return Number.isFinite(n)?n===0?Ul.underflow:Ul.truncate_float:Ul.overflow}function Tv(e){const{start:n,end:t}=k$(e),r=e.substring(n,t),c=r.indexOf(".");return c===-1?r:r.substring(0,c)+r.substring(c+1)}function k$(e){let n=0;for(e[0]==="-"&&n++;e[n]==="0"||e[n]===".";)n++;let t=e.lastIndexOf("e");for(t===-1&&(t=e.lastIndexOf("E")),t===-1&&(t=e.length);(e[t-1]==="0"||e[t-1]===".")&&t>n;)t--;return{start:n,end:t}}const Ev=Symbol.for("lossless-json.LosslessNumber");let _$=class{value;isLosslessNumber=!0;get[Ev](){return!0}constructor(n){if(!$v(n))throw new Error(`Invalid number (value: "${n}")`);this.value=n}valueOf(){const n=C$(this.value);if(n===void 0||n===Ul.truncate_float)return Number.parseFloat(this.value);if(nu(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 Iv(e){return e!==null&&typeof e=="object"&&e[Ev]===!0}function A$(e){return new _$(e)}function $$(e,n){return pd({"":e},"",e,n)}function pd(e,n,t,r){return Array.isArray(t)?r.call(e,n,T$(t,r)):t&&typeof t=="object"&&!Iv(t)?r.call(e,n,S$(t,r)):r.call(e,n,t)}function S$(e,n){for(const t of Object.keys(e)){const r=pd(e,t,e[t],n);r!==void 0?e[t]=r:delete e[t]}return e}function T$(e,n){for(let t=0;t<e.length;t++){const r=pd(e,String(t),e[t],n);r===void 0?delete e[t]:e[t]=r}return e}function E$(e,n,t){const r=typeof t=="function"?{parseNumber:t}:t,c=r?.parseNumber??A$,h=r?.onDuplicateKey??P;let g=0;const v=a();return w(v),R(),n?$$(v,n):v;function s(){if(e.charCodeAt(g)===N$){g++,u();const j={};let U=!0;for(;g<e.length&&e.charCodeAt(g)!==Lv;){U?U=!1:(f(),u());const q=g,Q=d();if(Q===void 0){C();return}u(),m();const re=a();if(re===void 0){N();return}if(Object.prototype.hasOwnProperty.call(j,Q)&&!gd(re,j[Q])){const le=h({key:Q,position:q+1,oldValue:j[Q],newValue:re});le!==void 0&&Mv(j,Q,le)}else Mv(j,Q,re)}return e.charCodeAt(g)!==Lv&&O(),g++,j}}function p(){if(e.charCodeAt(g)===D$){g++,u();const j=[];let U=!0;for(;g<e.length&&e.charCodeAt(g)!==Ov;){U?U=!1:f();const q=a();x(q),j.push(q)}return e.charCodeAt(g)!==Ov&&E(),g++,j}}function a(){u();const j=d()??o()??s()??p()??l("true",!0)??l("false",!1)??l("null",null);return u(),j}function l(j,U){if(e.slice(g,g+j.length)===j)return g+=j.length,U}function u(){for(;I$(e.charCodeAt(g));)g++}function d(){if(e.charCodeAt(g)===md){g++;let j="";for(;g<e.length&&e.charCodeAt(g)!==md;){if(e.charCodeAt(g)===O$){const U=e[g+1],q=L$[U];q!==void 0?(j+=q,g++):U==="u"?ru(e.charCodeAt(g+2))&&ru(e.charCodeAt(g+3))&&ru(e.charCodeAt(g+4))&&ru(e.charCodeAt(g+5))?(j+=String.fromCharCode(Number.parseInt(e.slice(g+2,g+6),16)),g+=5):M(g):B(g)}else R$(e.charCodeAt(g))?j+=e[g]:k(e[g]);g++}return _(),g++,j}}function o(){const j=g;if(e.charCodeAt(g)===Nv&&(g++,T(j)),e.charCodeAt(g)===vd)g++;else if(M$(e.charCodeAt(g)))for(g++;iu(e.charCodeAt(g));)g++;else return;if(e.charCodeAt(g)===U$)for(g++,T(j);iu(e.charCodeAt(g));)g++;if(e.charCodeAt(g)===K$||e.charCodeAt(g)===Y$)for(g++,(e.charCodeAt(g)===Nv||e.charCodeAt(g)===j$)&&g++,T(j);iu(e.charCodeAt(g));)g++;if(g>j)return c(e.slice(j,g))}function f(){if(e.charCodeAt(g)!==H$)throw new SyntaxError(`Comma ',' expected after value ${D()}`);g++}function m(){if(e.charCodeAt(g)!==V$)throw new SyntaxError(`Colon ':' expected after property name ${D()}`);g++}function w(j){if(j===void 0)throw new SyntaxError(`JSON value expected ${D()}`)}function x(j){if(j===void 0)throw new SyntaxError(`Array item expected ${D()}`)}function R(){if(g<e.length)throw new SyntaxError(`Expected end of input ${D()}`)}function T(j){if(!iu(e.charCodeAt(g))){const U=e.slice(j,g);throw new SyntaxError(`Invalid number '${U}', expecting a digit ${D()}`)}}function _(){if(e.charCodeAt(g)!==md)throw new SyntaxError(`End of string '"' expected ${D()}`)}function C(){throw new SyntaxError(`Quoted object key expected ${D()}`)}function P({key:j,position:U}){throw new SyntaxError(`Duplicate key '${j}' encountered at position ${U}`)}function O(){throw new SyntaxError(`Quoted object key or end of object '}' expected ${D()}`)}function E(){throw new SyntaxError(`Array item or end of array ']' expected ${D()}`)}function k(j){throw new SyntaxError(`Invalid character '${j}' ${$()}`)}function B(j){const U=e.slice(j,j+2);throw new SyntaxError(`Invalid escape character '${U}' ${$()}`)}function N(){throw new SyntaxError(`Object value expected after ':' ${$()}`)}function M(j){const U=e.slice(j,j+6);throw new SyntaxError(`Invalid unicode character '${U}' ${$()}`)}function $(){return`at position ${g}`}function A(){return g<e.length?`but got '${e[g]}'`:"but reached end of input"}function D(){return`${A()} ${$()}`}}function Mv(e,n,t){n==="__proto__"?Object.defineProperty(e,n,{value:t,writable:!0,enumerable:!0,configurable:!0}):e[n]=t}function I$(e){return e===P$||e===z$||e===B$||e===F$}function ru(e){return e>=vd&&e<=yd||e>=G$&&e<=J$||e>=q$&&e<=Q$}function iu(e){return e>=vd&&e<=yd}function M$(e){return e>=W$&&e<=yd}function R$(e){return e>=32&&e<=1114111}function gd(e,n){return e===n?!0:Array.isArray(e)&&Array.isArray(n)?e.length===n.length&&e.every((t,r)=>gd(t,n[r])):Rv(e)&&Rv(n)?[...new Set([...Object.keys(e),...Object.keys(n)])].every(t=>gd(e[t],n[t])):!1}function Rv(e){return typeof e=="object"&&e!==null}const L$={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:`
10
+ `,r:"\r",t:" "},O$=92,N$=123,Lv=125,D$=91,Ov=93,P$=32,z$=10,B$=9,F$=13,md=34,j$=43,Nv=45,vd=48,W$=49,yd=57,H$=44,U$=46,V$=58,G$=65,q$=97,Y$=69,K$=101,J$=70,Q$=102;function Z$(e,n,t,r){return c(e);function c(s,p){if(Array.isArray(r)){const a=r.find(l=>l.test(s));if(a){const l=a.stringify(s);if(typeof l!="string"||!$v(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 s=="boolean"||typeof s=="number"||typeof s=="string"||s===null||s instanceof Date||s instanceof Boolean||s instanceof Number||s instanceof String)return JSON.stringify(s);if(Iv(s)||typeof s=="bigint")return s.toString();if(Array.isArray(s))return h(s);if(s&&typeof s=="object")return g(s)}function h(s,p){if(s.length===0)return"[]";let a="[";for(let l=0;l<s.length;l++){const u=s[l];if(typeof u<"u"&&typeof u!="function"){const d=c(u);a+=d===void 0?"null":d}else a+="null";l<s.length-1&&(a+=",")}return a+="]",a}function g(s,p){if(typeof s.toJSON=="function")return c(s.toJSON());const a=Array.isArray(n)?[...new Set(n.map(String))]:Object.keys(s);if(a.length===0)return"{}";let l=!0,u="{";for(const d of a){const o=s[d];if(v(d,o)){const f=c(o);if(f===void 0)continue;l?l=!1:u+=",";const m=JSON.stringify(d);u+=`${m}:`,u+=f}}return u+="}",u}function v(s,p){return typeof p<"u"&&typeof p!="function"&&typeof p!="symbol"}}function X$(e){return nu(e)&&!Sv(e)?BigInt(e):Number.parseFloat(e)}lr("P",class{id=1;constructor(){}async exec(n,t,r={},c={},h=6e4){await ud(),this.id=this.id+1;try{return r.scope=window.openc3Scope,c.manual=!0,(await hd.post("/openc3-api/api",{jsonrpc:"2.0",method:n,params:t,id:this.id,keyword_params:r},{headers:{Authorization:localStorage.openc3Token,"Content-Type":"application/json-rpc",...c},timeout:h,transformRequest:[(g,v)=>Z$(g)],transformResponse:[g=>{try{return E$(g,void 0,X$)}catch{const v=typeof g=="string"?g.substring(0,200):String(g),s=new Error(`Server returned non-JSON response: ${v}`);throw s.name="ServerError",s}}]})).data.result}catch(g){let v=new Error;throw g.response?(v.name=g.response.data.error.data.class,v.message=g.response.data.error.data.message,v.object=g.response.data.error):g.request?(v.name="Request error",v.message="Request error, no response received"):v=g,v}}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,t,r,c,h){return this.exec("map_target_to_interface",[n,t],{cmd_only:r,tlm_only:c,unmap_old:h})}unmap_target_from_interface(n,t,r,c){return this.exec("unmap_target_from_interface",[n,t],{cmd_only:r,tlm_only:c})}connect_interface(n,...t){return t.length>0?this.exec("connect_interface",[n,...t]):this.exec("connect_interface",[n])}disconnect_interface(n){return this.exec("disconnect_interface",[n])}interface_cmd(n,t,...r){return this.exec("interface_cmd",[n,t,...r])}interface_target_enable(n,t,r=!1,c=!1){return this.exec("interface_target_enable",[n,t],{cmd_only:r,tlm_only:c})}interface_target_disable(n,t,r=!1,c=!1){return this.exec("interface_target_disable",[n,t],{cmd_only:r,tlm_only:c})}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,t,r,c,h){return this.exec("map_target_to_router",[n,t],{cmd_only:r,tlm_only:c,unmap_old:h})}unmap_target_from_router(n,t,r,c){return this.exec("unmap_target_from_router",[n,t],{cmd_only:r,tlm_only:c})}connect_router(n){return this.exec("connect_router",[n])}disconnect_router(n){return this.exec("disconnect_router",[n])}router_target_enable(n,t,r=!1,c=!1){return this.exec("router_target_enable",[n,t],{cmd_only:r,tlm_only:c})}router_target_disable(n,t,r=!1,c=!1){return this.exec("router_target_disable",[n,t],{cmd_only:r,tlm_only:c})}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,t,r){return this.exec("get_item",[n,t,r])}get_param(n,t,r){return this.exec("get_param",[n,t,r])}get_parameter(n,t,r){return this.get_param(n,t,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])}delete_limits_set(n){return this.exec("delete_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.get_target_names()}get_tlm(n,t){return this.exec("get_tlm",[n,t])}get_telemetry(n,t){return this.get_tlm(n,t)}get_all_tlm(n){return this.exec("get_all_tlm",[n])}get_all_telemetry(n){return this.get_all_tlm(n)}get_all_tlm_names(n,t=!1){return this.exec("get_all_tlm_names",[n],{hidden:t})}get_all_telemetry_names(n){return this.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,t,r,c=30){const h=await this.exec("get_tlm_packet",[n,t],{type:r,stale_time:c});if(h!=null){let g=h.length,v=null;for(let s=0;s<g;s++)v=this.decode_openc3_type(h[s][1]),v!==null&&(h[s][1]=v)}return h}get_packet_derived_items(n,t){return this.exec("get_packet_derived_items",[n,t])}get_tlm_buffer(n,t){return this.exec("get_tlm_buffer",[n,t])}get_tlm_available(n,t={},r={}){return this.exec("get_tlm_available",[n],t,r)}async get_tlm_values(n,t=30,r=null,c=null,h=null,g={}){let v={stale_time:t};r!==null&&(v.cache_timeout=r),c!==null&&(v.start_time=c.toISOString()),h!==null&&(v.end_time=h.toISOString());const s=await this.exec("get_tlm_values",[n],v,g,1e4);if(s&&s.length>0){let p=s.length,a=null;for(let l=0;l<p;l++)a=this.decode_openc3_type(s[l][0]),a!==null&&(s[l][0]=a)}return s}get_limits(n,t,r){return this.exec("get_limits",[n,t,r])}async tlm(n,t,r,c="CONVERTED"){let h=null;if(t===void 0)h=await this.exec("tlm",[n]);else if(r===void 0)if(["RAW","CONVERTED","FORMATTED"].includes(t))h=await this.exec("tlm",[n],{type:t});else{let v=new Error;throw v.name="TypeError",v.message=`Invalid data type ${t}. Valid options are RAW, CONVERTED or FORMATTED.`,v}else h=await this.exec("tlm",[n,t,r],{type:c});let g=this.decode_openc3_type(h);return g!==null&&(h=g),h}async inject_tlm(n,t,r=null,c="CONVERTED",h=!1){await this.exec("inject_tlm",[n,t,r],{type:c,stored:h})}set_tlm(n,t,r,c){return this.exec("set_tlm",[n,t,r],{type:c})}override_tlm(n,t,r,c){return this.exec("override_tlm",[n,t,r],{type:c})}get_overrides(){return this.exec("get_overrides")}normalize_tlm(n,t,r,c){return this.exec("normalize_tlm",[n,t,r],{type:c})}get_all_cmds(n){return this.exec("get_all_cmds",[n])}get_all_commands(n){return this.get_all_cmds(n)}get_all_cmd_names(n,t=!1){return this.exec("get_all_cmd_names",[n],{hidden:t})}get_all_command_names(n){return this.get_all_cmd_names(n)}get_cmd(n,t){return this.exec("get_cmd",[n,t])}get_command(n,t){return this.get_cmd(n,t)}get_cmd_cnts(n){return this.exec("get_cmd_cnts",[n])}get_cmd_value(n,t,r,c="CONVERTED"){return this.exec("get_cmd_value",[n,t,r,c])}get_cmd_buffer(n,t){return this.exec("get_cmd_buffer",[n,t])}_cmd(n,t,r,c,h,g={}){let v=null;for(let s in c)Object.prototype.hasOwnProperty.call(c,s)&&(v=this.encode_openc3_type(c[s]),v!==null&&(c[s]=v));return this.exec(n,[t,r,c],g,h)}get_cmd_hazardous(n,t,r,c={}){return t===void 0?this.exec("get_cmd_hazardous",n,{},c):this._cmd("get_cmd_hazardous",n,t,r,c)}cmd(n,t,r,c={},h={}){return t===void 0?this.exec("cmd",n,h,c):this._cmd("cmd",n,t,r,c,h)}cmd_no_range_check(n,t,r,c={},h={}){return t===void 0?this.exec("cmd_no_range_check",n,h,c):this._cmd("cmd_no_range_check",n,t,r,c,h)}cmd_raw(n,t,r,c={},h={}){return t===void 0?this.exec("cmd_raw",n,h,c):this._cmd("cmd_raw",n,t,r,c,h)}cmd_raw_no_range_check(n,t,r,c={},h={}){return t===void 0?this.exec("cmd_raw_no_range_check",n,h,c):this._cmd("cmd_raw_no_range_check",n,t,r,c,h)}cmd_no_hazardous_check(n,t,r,c={},h={}){return t===void 0?this.exec("cmd_no_hazardous_check",n,h,c):this._cmd("cmd_no_hazardous_check",n,t,r,c,h)}cmd_no_checks(n,t,r,c={},h={}){return t===void 0?this.exec("cmd_no_checks",n,h,c):this._cmd("cmd_no_checks",n,t,r,c,h)}cmd_raw_no_hazardous_check(n,t,r,c={},h={}){return t===void 0?this.exec("cmd_raw_no_hazardous_check",n,h,c):this._cmd("cmd_raw_no_hazardous_check",n,t,r,c,h)}cmd_raw_no_checks(n,t,r,c={},h={}){return t===void 0?this.exec("cmd_raw_no_checks",n,h,c):this._cmd("cmd_raw_no_checks",n,t,r,c,h)}build_cmd(n,t,r,c={},h={}){return t===void 0?this.exec("build_cmd",n,h,c):this._cmd("build_cmd",n,t,r,c,h)}build_command(n,t,r,c={},h={}){return this.build_cmd(n,t,r,c,h)}get_interface_names(){return this.exec("get_interface_names",[])}get_router_names(){return this.exec("get_router_names",[])}send_raw(n,t){return this.exec("send_raw",[n,t])}list_configs(n){return this.exec("list_configs",[n])}load_config(n,t){return this.exec("load_config",[n,t])}save_config(n,t,r){return this.exec("save_config",[n,t,r])}delete_config(n,t){return this.exec("delete_config",[n,t])}enable_limits(n,t,r){return this.exec("enable_limits",[n,t,r])}disable_limits(n,t,r){return this.exec("disable_limits",[n,t,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,t){return this.exec("get_setting",[n],t)}get_settings(n,t){return this.exec("get_settings",n,t)}set_setting(n,t){return this.exec("set_setting",[n,t])}update_news(){return this.exec("update_news",[])}update_plugin_store(){return this.exec("update_plugin_store",[])}save_setting(n,t){return this.set_setting(n,t)}get_metrics(n=!1){return this.exec("get_metrics",[],{detailed:n})}open_tab(n){window.open(n,"_blank")}async hashString(n){if(window.isSecureContext){const t=new TextEncoder().encode(n),r=await crypto.subtle.digest("SHA-256",t),c=new Uint8Array(r);return Array.from(c).map(h=>h.toString(16).padStart(2,"0")).join("")}}});const Dv=6048e5,eS=864e5,ou=6e4,bd=36e5,tS=1e3,Pv=Symbol.for("constructDateFrom");lr({a:ou,C:bd,k:tS});function qo(e,n){return typeof e=="function"?e(n):e&&typeof e=="object"&&Pv in e?e[Pv](n):e instanceof Date?new e.constructor(n):new Date(n)}function li(e,n){return qo(n||e,e)}let nS={};function Ga(){return nS}function qa(e,n){const t=Ga(),r=n?.weekStartsOn??n?.locale?.options?.weekStartsOn??t.weekStartsOn??t.locale?.options?.weekStartsOn??0,c=li(e,n?.in),h=c.getDay(),g=(h<r?7:0)+h-r;return c.setDate(c.getDate()-g),c.setHours(0,0,0,0),c}function Vl(e,n){return qa(e,{...n,weekStartsOn:1})}function zv(e,n){const t=li(e,n?.in),r=t.getFullYear(),c=qo(t,0);c.setFullYear(r+1,0,4),c.setHours(0,0,0,0);const h=Vl(c),g=qo(t,0);g.setFullYear(r,0,4),g.setHours(0,0,0,0);const v=Vl(g);return t.getTime()>=h.getTime()?r+1:t.getTime()>=v.getTime()?r:r-1}function wd(e){const n=li(e),t=new Date(Date.UTC(n.getFullYear(),n.getMonth(),n.getDate(),n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds()));return t.setUTCFullYear(n.getFullYear()),+e-+t}function rS(e,...n){const t=qo.bind(null,n.find(r=>typeof r=="object"));return n.map(t)}function Bv(e,n){const t=li(e,n?.in);return t.setHours(0,0,0,0),t}function iS(e,n,t){const[r,c]=rS(t?.in,e,n),h=Bv(r),g=Bv(c),v=+h-wd(h),s=+g-wd(g);return Math.round((v-s)/eS)}function oS(e,n){const t=zv(e,n),r=qo(e,0);return r.setFullYear(t,0,4),r.setHours(0,0,0,0),Vl(r)}function sS(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function Fv(e){return!(!sS(e)&&typeof e!="number"||isNaN(+li(e)))}function aS(e,n){const t=li(e,n?.in);return t.setFullYear(t.getFullYear(),0,1),t.setHours(0,0,0,0),t}const lS={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"}},cS=(e,n,t)=>{let r;const c=lS[e];return typeof c=="string"?r=c:n===1?r=c.one:r=c.other.replace("{{count}}",n.toString()),t?.addSuffix?t.comparison&&t.comparison>0?"in "+r:r+" ago":r};function xd(e){return(n={})=>{const t=n.width?String(n.width):e.defaultWidth;return e.formats[t]||e.formats[e.defaultWidth]}}const uS={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},hS={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dS={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},fS={date:xd({formats:uS,defaultWidth:"full"}),time:xd({formats:hS,defaultWidth:"full"}),dateTime:xd({formats:dS,defaultWidth:"full"})},pS={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},gS=(e,n,t,r)=>pS[e];function Gl(e){return(n,t)=>{const r=t?.context?String(t.context):"standalone";let c;if(r==="formatting"&&e.formattingValues){const g=e.defaultFormattingWidth||e.defaultWidth,v=t?.width?String(t.width):g;c=e.formattingValues[v]||e.formattingValues[g]}else{const g=e.defaultWidth,v=t?.width?String(t.width):e.defaultWidth;c=e.values[v]||e.values[g]}const h=e.argumentCallback?e.argumentCallback(n):n;return c[h]}}const mS={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},vS={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},yS={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"]},bS={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"]},wS={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"}},xS={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"}},CS=(e,n)=>{const t=Number(e),r=t%100;if(r>20||r<10)switch(r%10){case 1:return t+"st";case 2:return t+"nd";case 3:return t+"rd"}return t+"th"},kS={ordinalNumber:CS,era:Gl({values:mS,defaultWidth:"wide"}),quarter:Gl({values:vS,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Gl({values:yS,defaultWidth:"wide"}),day:Gl({values:bS,defaultWidth:"wide"}),dayPeriod:Gl({values:wS,defaultWidth:"wide",formattingValues:xS,defaultFormattingWidth:"wide"})};function ql(e){return(n,t={})=>{const r=t.width,c=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],h=n.match(c);if(!h)return null;const g=h[0],v=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],s=Array.isArray(v)?AS(v,l=>l.test(g)):_S(v,l=>l.test(g));let p;p=e.valueCallback?e.valueCallback(s):s,p=t.valueCallback?t.valueCallback(p):p;const a=n.slice(g.length);return{value:p,rest:a}}}function _S(e,n){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&n(e[t]))return t}function AS(e,n){for(let t=0;t<e.length;t++)if(n(e[t]))return t}function $S(e){return(n,t={})=>{const r=n.match(e.matchPattern);if(!r)return null;const c=r[0],h=n.match(e.parsePattern);if(!h)return null;let g=e.valueCallback?e.valueCallback(h[0]):h[0];g=t.valueCallback?t.valueCallback(g):g;const v=n.slice(c.length);return{value:g,rest:v}}}const SS=/^(\d+)(th|st|nd|rd)?/i,TS=/\d+/i,ES={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},IS={any:[/^b/i,/^(a|c)/i]},MS={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},RS={any:[/1/i,/2/i,/3/i,/4/i]},LS={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},OS={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]},NS={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},DS={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]},PS={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},zS={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}},BS={ordinalNumber:$S({matchPattern:SS,parsePattern:TS,valueCallback:e=>parseInt(e,10)}),era:ql({matchPatterns:ES,defaultMatchWidth:"wide",parsePatterns:IS,defaultParseWidth:"any"}),quarter:ql({matchPatterns:MS,defaultMatchWidth:"wide",parsePatterns:RS,defaultParseWidth:"any",valueCallback:e=>e+1}),month:ql({matchPatterns:LS,defaultMatchWidth:"wide",parsePatterns:OS,defaultParseWidth:"any"}),day:ql({matchPatterns:NS,defaultMatchWidth:"wide",parsePatterns:DS,defaultParseWidth:"any"}),dayPeriod:ql({matchPatterns:PS,defaultMatchWidth:"any",parsePatterns:zS,defaultParseWidth:"any"})},FS=lr("$",{code:"en-US",formatDistance:cS,formatLong:fS,formatRelative:gS,localize:kS,match:BS,options:{weekStartsOn:0,firstWeekContainsDate:1}});function jS(e,n){const t=li(e,n?.in);return iS(t,aS(t))+1}function jv(e,n){const t=li(e,n?.in),r=+Vl(t)-+oS(t);return Math.round(r/Dv)+1}function Cd(e,n){const t=li(e,n?.in),r=t.getFullYear(),c=Ga(),h=n?.firstWeekContainsDate??n?.locale?.options?.firstWeekContainsDate??c.firstWeekContainsDate??c.locale?.options?.firstWeekContainsDate??1,g=qo(n?.in||e,0);g.setFullYear(r+1,0,h),g.setHours(0,0,0,0);const v=qa(g,n),s=qo(n?.in||e,0);s.setFullYear(r,0,h),s.setHours(0,0,0,0);const p=qa(s,n);return+t>=+v?r+1:+t>=+p?r:r-1}function WS(e,n){const t=Ga(),r=n?.firstWeekContainsDate??n?.locale?.options?.firstWeekContainsDate??t.firstWeekContainsDate??t.locale?.options?.firstWeekContainsDate??1,c=Cd(e,n),h=qo(n?.in||e,0);return h.setFullYear(c,0,r),h.setHours(0,0,0,0),qa(h,n)}function Wv(e,n){const t=li(e,n?.in),r=+qa(t,n)-+WS(t,n);return Math.round(r/Dv)+1}function An(e,n){const t=e<0?"-":"",r=Math.abs(e).toString().padStart(n,"0");return t+r}const Ns={y(e,n){const t=e.getFullYear(),r=t>0?t:1-t;return An(n==="yy"?r%100:r,n.length)},M(e,n){const t=e.getMonth();return n==="M"?String(t+1):An(t+1,2)},d(e,n){return An(e.getDate(),n.length)},a(e,n){const t=e.getHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return t.toUpperCase();case"aaa":return t;case"aaaaa":return t[0];default:return t==="am"?"a.m.":"p.m."}},h(e,n){return An(e.getHours()%12||12,n.length)},H(e,n){return An(e.getHours(),n.length)},m(e,n){return An(e.getMinutes(),n.length)},s(e,n){return An(e.getSeconds(),n.length)},S(e,n){const t=n.length,r=e.getMilliseconds(),c=Math.trunc(r*Math.pow(10,t-3));return An(c,n.length)}},Ya={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Hv={G:function(e,n,t){const r=e.getFullYear()>0?1:0;switch(n){case"G":case"GG":case"GGG":return t.era(r,{width:"abbreviated"});case"GGGGG":return t.era(r,{width:"narrow"});default:return t.era(r,{width:"wide"})}},y:function(e,n,t){if(n==="yo"){const r=e.getFullYear(),c=r>0?r:1-r;return t.ordinalNumber(c,{unit:"year"})}return Ns.y(e,n)},Y:function(e,n,t,r){const c=Cd(e,r),h=c>0?c:1-c;if(n==="YY"){const g=h%100;return An(g,2)}return n==="Yo"?t.ordinalNumber(h,{unit:"year"}):An(h,n.length)},R:function(e,n){const t=zv(e);return An(t,n.length)},u:function(e,n){const t=e.getFullYear();return An(t,n.length)},Q:function(e,n,t){const r=Math.ceil((e.getMonth()+1)/3);switch(n){case"Q":return String(r);case"QQ":return An(r,2);case"Qo":return t.ordinalNumber(r,{unit:"quarter"});case"QQQ":return t.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return t.quarter(r,{width:"narrow",context:"formatting"});default:return t.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,n,t){const r=Math.ceil((e.getMonth()+1)/3);switch(n){case"q":return String(r);case"qq":return An(r,2);case"qo":return t.ordinalNumber(r,{unit:"quarter"});case"qqq":return t.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return t.quarter(r,{width:"narrow",context:"standalone"});default:return t.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,n,t){const r=e.getMonth();switch(n){case"M":case"MM":return Ns.M(e,n);case"Mo":return t.ordinalNumber(r+1,{unit:"month"});case"MMM":return t.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return t.month(r,{width:"narrow",context:"formatting"});default:return t.month(r,{width:"wide",context:"formatting"})}},L:function(e,n,t){const r=e.getMonth();switch(n){case"L":return String(r+1);case"LL":return An(r+1,2);case"Lo":return t.ordinalNumber(r+1,{unit:"month"});case"LLL":return t.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return t.month(r,{width:"narrow",context:"standalone"});default:return t.month(r,{width:"wide",context:"standalone"})}},w:function(e,n,t,r){const c=Wv(e,r);return n==="wo"?t.ordinalNumber(c,{unit:"week"}):An(c,n.length)},I:function(e,n,t){const r=jv(e);return n==="Io"?t.ordinalNumber(r,{unit:"week"}):An(r,n.length)},d:function(e,n,t){return n==="do"?t.ordinalNumber(e.getDate(),{unit:"date"}):Ns.d(e,n)},D:function(e,n,t){const r=jS(e);return n==="Do"?t.ordinalNumber(r,{unit:"dayOfYear"}):An(r,n.length)},E:function(e,n,t){const r=e.getDay();switch(n){case"E":case"EE":case"EEE":return t.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return t.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return t.day(r,{width:"short",context:"formatting"});default:return t.day(r,{width:"wide",context:"formatting"})}},e:function(e,n,t,r){const c=e.getDay(),h=(c-r.weekStartsOn+8)%7||7;switch(n){case"e":return String(h);case"ee":return An(h,2);case"eo":return t.ordinalNumber(h,{unit:"day"});case"eee":return t.day(c,{width:"abbreviated",context:"formatting"});case"eeeee":return t.day(c,{width:"narrow",context:"formatting"});case"eeeeee":return t.day(c,{width:"short",context:"formatting"});default:return t.day(c,{width:"wide",context:"formatting"})}},c:function(e,n,t,r){const c=e.getDay(),h=(c-r.weekStartsOn+8)%7||7;switch(n){case"c":return String(h);case"cc":return An(h,n.length);case"co":return t.ordinalNumber(h,{unit:"day"});case"ccc":return t.day(c,{width:"abbreviated",context:"standalone"});case"ccccc":return t.day(c,{width:"narrow",context:"standalone"});case"cccccc":return t.day(c,{width:"short",context:"standalone"});default:return t.day(c,{width:"wide",context:"standalone"})}},i:function(e,n,t){const r=e.getDay(),c=r===0?7:r;switch(n){case"i":return String(c);case"ii":return An(c,n.length);case"io":return t.ordinalNumber(c,{unit:"day"});case"iii":return t.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return t.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return t.day(r,{width:"short",context:"formatting"});default:return t.day(r,{width:"wide",context:"formatting"})}},a:function(e,n,t){const r=e.getHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return t.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return t.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return t.dayPeriod(r,{width:"narrow",context:"formatting"});default:return t.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(e,n,t){const r=e.getHours();let c;switch(r===12?c=Ya.noon:r===0?c=Ya.midnight:c=r/12>=1?"pm":"am",n){case"b":case"bb":return t.dayPeriod(c,{width:"abbreviated",context:"formatting"});case"bbb":return t.dayPeriod(c,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return t.dayPeriod(c,{width:"narrow",context:"formatting"});default:return t.dayPeriod(c,{width:"wide",context:"formatting"})}},B:function(e,n,t){const r=e.getHours();let c;switch(r>=17?c=Ya.evening:r>=12?c=Ya.afternoon:r>=4?c=Ya.morning:c=Ya.night,n){case"B":case"BB":case"BBB":return t.dayPeriod(c,{width:"abbreviated",context:"formatting"});case"BBBBB":return t.dayPeriod(c,{width:"narrow",context:"formatting"});default:return t.dayPeriod(c,{width:"wide",context:"formatting"})}},h:function(e,n,t){if(n==="ho"){let r=e.getHours()%12;return r===0&&(r=12),t.ordinalNumber(r,{unit:"hour"})}return Ns.h(e,n)},H:function(e,n,t){return n==="Ho"?t.ordinalNumber(e.getHours(),{unit:"hour"}):Ns.H(e,n)},K:function(e,n,t){const r=e.getHours()%12;return n==="Ko"?t.ordinalNumber(r,{unit:"hour"}):An(r,n.length)},k:function(e,n,t){let r=e.getHours();return r===0&&(r=24),n==="ko"?t.ordinalNumber(r,{unit:"hour"}):An(r,n.length)},m:function(e,n,t){return n==="mo"?t.ordinalNumber(e.getMinutes(),{unit:"minute"}):Ns.m(e,n)},s:function(e,n,t){return n==="so"?t.ordinalNumber(e.getSeconds(),{unit:"second"}):Ns.s(e,n)},S:function(e,n){return Ns.S(e,n)},X:function(e,n,t){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(n){case"X":return Vv(r);case"XXXX":case"XX":return ha(r);default:return ha(r,":")}},x:function(e,n,t){const r=e.getTimezoneOffset();switch(n){case"x":return Vv(r);case"xxxx":case"xx":return ha(r);default:return ha(r,":")}},O:function(e,n,t){const r=e.getTimezoneOffset();switch(n){case"O":case"OO":case"OOO":return"GMT"+Uv(r,":");default:return"GMT"+ha(r,":")}},z:function(e,n,t){const r=e.getTimezoneOffset();switch(n){case"z":case"zz":case"zzz":return"GMT"+Uv(r,":");default:return"GMT"+ha(r,":")}},t:function(e,n,t){const r=Math.trunc(+e/1e3);return An(r,n.length)},T:function(e,n,t){return An(+e,n.length)}};function Uv(e,n=""){const t=e>0?"-":"+",r=Math.abs(e),c=Math.trunc(r/60),h=r%60;return h===0?t+String(c):t+String(c)+n+An(h,2)}function Vv(e,n){return e%60===0?(e>0?"-":"+")+An(Math.abs(e)/60,2):ha(e,n)}function ha(e,n=""){const t=e>0?"-":"+",r=Math.abs(e),c=An(Math.trunc(r/60),2),h=An(r%60,2);return t+c+n+h}const Gv=(e,n)=>{switch(e){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"})}},qv=(e,n)=>{switch(e){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"})}},HS=(e,n)=>{const t=e.match(/(P+)(p+)?/)||[],r=t[1],c=t[2];if(!c)return Gv(e,n);let h;switch(r){case"P":h=n.dateTime({width:"short"});break;case"PP":h=n.dateTime({width:"medium"});break;case"PPP":h=n.dateTime({width:"long"});break;default:h=n.dateTime({width:"full"});break}return h.replace("{{date}}",Gv(r,n)).replace("{{time}}",qv(c,n))},US=lr("b",{p:qv,P:HS}),VS=/^D+$/,GS=/^Y+$/,qS=["D","DD","YY","YYYY"];function Yv(e){return VS.test(e)}function Kv(e){return GS.test(e)}function Jv(e,n,t){const r=YS(e,n,t);if(console.warn(r),qS.includes(e))throw new RangeError(r)}function YS(e,n,t){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${n}\`) for formatting ${r} to the input \`${t}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const KS=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,JS=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,QS=/^'([^]*?)'?$/,ZS=/''/g,XS=/[a-zA-Z]/;function Ds(e,n,t){const r=Ga(),c=t?.locale??r.locale??FS,h=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??r.firstWeekContainsDate??r.locale?.options?.firstWeekContainsDate??1,g=t?.weekStartsOn??t?.locale?.options?.weekStartsOn??r.weekStartsOn??r.locale?.options?.weekStartsOn??0,v=li(e,t?.in);if(!Fv(v))throw new RangeError("Invalid time value");let s=n.match(JS).map(a=>{const l=a[0];if(l==="p"||l==="P"){const u=US[l];return u(a,c.formatLong)}return a}).join("").match(KS).map(a=>{if(a==="''")return{isToken:!1,value:"'"};const l=a[0];if(l==="'")return{isToken:!1,value:eT(a)};if(Hv[l])return{isToken:!0,value:a};if(l.match(XS))throw new RangeError("Format string contains an unescaped latin alphabet character `"+l+"`");return{isToken:!1,value:a}});c.localize.preprocessor&&(s=c.localize.preprocessor(v,s));const p={firstWeekContainsDate:h,weekStartsOn:g,locale:c};return s.map(a=>{if(!a.isToken)return a.value;const l=a.value;(!t?.useAdditionalWeekYearTokens&&Kv(l)||!t?.useAdditionalDayOfYearTokens&&Yv(l))&&Jv(l,n,String(e));const u=Hv[l[0]];return u(v,l,c.localize,p)}).join("")}function eT(e){const n=e.match(QS);return n?n[1].replace(ZS,"'"):e}var Ps=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function su(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Qv={exports:{}},Zv;function tT(){return Zv||(Zv=1,(function(e,n){(function(){var t="ace",r=(function(){return this})();!r&&typeof window<"u"&&(r=window);var c=function(a,l,u){if(typeof a!="string"){c.original?c.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace());return}arguments.length==2&&(u=l),c.modules[a]||(c.payloads[a]=u,c.modules[a]=null)};c.modules={},c.payloads={};var h=function(a,l,u){if(typeof l=="string"){var d=s(a,l);if(d!=null)return u&&u(),d}else if(Object.prototype.toString.call(l)==="[object Array]"){for(var o=[],f=0,m=l.length;f<m;++f){var w=s(a,l[f]);if(w==null&&g.original)return;o.push(w)}return u&&u.apply(null,o)||!0}},g=function(a,l){var u=h("",a,l);return u==null&&g.original?g.original.apply(this,arguments):u},v=function(a,l){if(l.indexOf("!")!==-1){var u=l.split("!");return v(a,u[0])+"!"+v(a,u[1])}if(l.charAt(0)=="."){var d=a.split("/").slice(0,-1).join("/");for(l=d+"/"+l;l.indexOf(".")!==-1&&o!=l;){var o=l;l=l.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return l},s=function(a,l){l=v(a,l);var u=c.modules[l];if(!u){if(u=c.payloads[l],typeof u=="function"){var d={},o={id:l,uri:"",exports:d,packaged:!0},f=function(w,x){return h(l,w,x)},m=u(f,d,o);d=m||o.exports,c.modules[l]=d,delete c.payloads[l]}u=c.modules[l]=d||u}return u};function p(a){var l=r;r[a]||(r[a]={}),l=r[a],(!l.define||!l.define.packaged)&&(c.original=l.define,l.define=c,l.define.packaged=!0),(!l.require||!l.require.packaged)&&(g.original=l.require,l.require=g,l.require.packaged=!0)}p(t)})(),ace.define("ace/lib/es6-shim",["require","exports","module"],function(t,r,c){function h(g,v,s){Object.defineProperty(g,v,{value:s,enumerable:!1,writable:!0,configurable:!0})}String.prototype.startsWith||h(String.prototype,"startsWith",function(g,v){return v=v||0,this.lastIndexOf(g,v)===v}),String.prototype.endsWith||h(String.prototype,"endsWith",function(g,v){var s=this;(v===void 0||v>s.length)&&(v=s.length),v-=g.length;var p=s.indexOf(g,v);return p!==-1&&p===v}),String.prototype.repeat||h(String.prototype,"repeat",function(g){for(var v="",s=this;g>0;)g&1&&(v+=s),(g>>=1)&&(s+=s);return v}),String.prototype.includes||h(String.prototype,"includes",function(g,v){return this.indexOf(g,v)!=-1}),Object.assign||(Object.assign=function(g){if(g==null)throw new TypeError("Cannot convert undefined or null to object");for(var v=Object(g),s=1;s<arguments.length;s++){var p=arguments[s];p!=null&&Object.keys(p).forEach(function(a){v[a]=p[a]})}return v}),Object.values||(Object.values=function(g){return Object.keys(g).map(function(v){return g[v]})}),Array.prototype.find||h(Array.prototype,"find",function(g){for(var v=this.length,s=arguments[1],p=0;p<v;p++){var a=this[p];if(g.call(s,a,p,this))return a}}),Array.prototype.findIndex||h(Array.prototype,"findIndex",function(g){for(var v=this.length,s=arguments[1],p=0;p<v;p++){var a=this[p];if(g.call(s,a,p,this))return p}}),Array.prototype.includes||h(Array.prototype,"includes",function(g,v){return this.indexOf(g,v)!=-1}),Array.prototype.fill||h(Array.prototype,"fill",function(g){for(var v=this,s=v.length>>>0,p=arguments[1],a=p>>0,l=a<0?Math.max(s+a,0):Math.min(a,s),u=arguments[2],d=u===void 0?s:u>>0,o=d<0?Math.max(s+d,0):Math.min(d,s);l<o;)v[l]=g,l++;return v}),Array.of||h(Array,"of",function(){return Array.prototype.slice.call(arguments)})}),ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/es6-shim"],function(t,r,c){t("./es6-shim")}),ace.define("ace/lib/deep_copy",["require","exports","module"],function(t,r,c){r.deepCopy=function h(g){if(typeof g!="object"||!g)return g;var v;if(Array.isArray(g)){v=[];for(var s=0;s<g.length;s++)v[s]=h(g[s]);return v}if(Object.prototype.toString.call(g)!=="[object Object]")return g;v={};for(var s in g)v[s]=h(g[s]);return v}}),ace.define("ace/lib/lang",["require","exports","module","ace/lib/deep_copy"],function(t,r,c){r.last=function(v){return v[v.length-1]},r.stringReverse=function(v){return v.split("").reverse().join("")},r.stringRepeat=function(v,s){for(var p="";s>0;)s&1&&(p+=v),(s>>=1)&&(v+=v);return p};var h=/^\s\s*/,g=/\s\s*$/;r.stringTrimLeft=function(v){return v.replace(h,"")},r.stringTrimRight=function(v){return v.replace(g,"")},r.copyObject=function(v){var s={};for(var p in v)s[p]=v[p];return s},r.copyArray=function(v){for(var s=[],p=0,a=v.length;p<a;p++)v[p]&&typeof v[p]=="object"?s[p]=this.copyObject(v[p]):s[p]=v[p];return s},r.deepCopy=t("./deep_copy").deepCopy,r.arrayToMap=function(v){for(var s={},p=0;p<v.length;p++)s[v[p]]=1;return s},r.createMap=function(v){var s=Object.create(null);for(var p in v)s[p]=v[p];return s},r.arrayRemove=function(v,s){for(var p=0;p<=v.length;p++)s===v[p]&&v.splice(p,1)},r.escapeRegExp=function(v){return v.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},r.escapeHTML=function(v){return(""+v).replace(/&/g,"&#38;").replace(/"/g,"&#34;").replace(/'/g,"&#39;").replace(/</g,"&#60;")},r.getMatchOffsets=function(v,s){var p=[];return v.replace(s,function(a){p.push({offset:arguments[arguments.length-2],length:a.length})}),p},r.deferredCall=function(v){var s=null,p=function(){s=null,v()},a=function(l){return a.cancel(),s=setTimeout(p,l||0),a};return a.schedule=a,a.call=function(){return this.cancel(),v(),a},a.cancel=function(){return clearTimeout(s),s=null,a},a.isPending=function(){return s},a},r.delayedCall=function(v,s){var p=null,a=function(){p=null,v()},l=function(u){p==null&&(p=setTimeout(a,u||s))};return l.delay=function(u){p&&clearTimeout(p),p=setTimeout(a,u||s)},l.schedule=l,l.call=function(){this.cancel(),v()},l.cancel=function(){p&&clearTimeout(p),p=null},l.isPending=function(){return p},l},r.sleep=function(v){return new Promise(function(s){setTimeout(s,v)})},r.supportsLookbehind=function(){try{new RegExp("(?<=.)")}catch{return!1}return!0},r.skipEmptyMatch=function(v,s,p){return p&&v.codePointAt(s)>65535?2:1}}),ace.define("ace/lib/useragent",["require","exports","module"],function(t,r,c){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 h=typeof navigator=="object"?navigator:{},g=(/mac|win|linux/i.exec(h.platform)||["other"])[0].toLowerCase(),v=h.userAgent||"",s=h.appName||"";r.isWin=g=="win",r.isMac=g=="mac",r.isLinux=g=="linux",r.isIE=s=="Microsoft Internet Explorer"||s.indexOf("MSAppHost")>=0?parseFloat((v.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((v.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),r.isOldIE=r.isIE&&r.isIE<9,r.isGecko=r.isMozilla=v.match(/ Gecko\/\d+/),r.isOpera=typeof opera=="object"&&Object.prototype.toString.call(window.opera)=="[object Opera]",r.isWebKit=parseFloat(v.split("WebKit/")[1])||void 0,r.isChrome=parseFloat(v.split(" Chrome/")[1])||void 0,r.isSafari=parseFloat(v.split(" Safari/")[1])&&!r.isChrome||void 0,r.isEdge=parseFloat(v.split(" Edge/")[1])||void 0,r.isAIR=v.indexOf("AdobeAIR")>=0,r.isAndroid=v.indexOf("Android")>=0,r.isChromeOS=v.indexOf(" CrOS ")>=0,r.isIOS=/iPad|iPhone|iPod/.test(v)&&!window.MSStream,r.isIOS&&(r.isMac=!0),r.isMobile=r.isIOS||r.isAndroid}),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],function(t,r,c){var h=t("./useragent"),g="http://www.w3.org/1999/xhtml";r.buildDom=function u(d,o,f){if(typeof d=="string"&&d){var m=document.createTextNode(d);return o&&o.appendChild(m),m}if(!Array.isArray(d))return d&&d.appendChild&&o&&o.appendChild(d),d;if(typeof d[0]!="string"||!d[0]){for(var w=[],x=0;x<d.length;x++){var R=u(d[x],o,f);R&&w.push(R)}return w}var T=document.createElement(d[0]),_=d[1],C=1;_&&typeof _=="object"&&!Array.isArray(_)&&(C=2);for(var x=C;x<d.length;x++)u(d[x],T,f);return C==2&&Object.keys(_).forEach(function(P){var O=_[P];P==="class"?T.className=Array.isArray(O)?O.join(" "):O:typeof O=="function"||P=="value"||P[0]=="$"?T[P]=O:P==="ref"?f&&(f[O]=T):P==="style"?typeof O=="string"&&(T.style.cssText=O):O!=null&&T.setAttribute(P,O)}),o&&o.appendChild(T),T},r.getDocumentHead=function(u){return u||(u=document),u.head||u.getElementsByTagName("head")[0]||u.documentElement},r.createElement=function(u,d){return document.createElementNS?document.createElementNS(d||g,u):document.createElement(u)},r.removeChildren=function(u){u.innerHTML=""},r.createTextNode=function(u,d){var o=d?d.ownerDocument:document;return o.createTextNode(u)},r.createFragment=function(u){var d=u?u.ownerDocument:document;return d.createDocumentFragment()},r.hasCssClass=function(u,d){var o=(u.className+"").split(/\s+/g);return o.indexOf(d)!==-1},r.addCssClass=function(u,d){r.hasCssClass(u,d)||(u.className+=" "+d)},r.removeCssClass=function(u,d){for(var o=u.className.split(/\s+/g);;){var f=o.indexOf(d);if(f==-1)break;o.splice(f,1)}u.className=o.join(" ")},r.toggleCssClass=function(u,d){for(var o=u.className.split(/\s+/g),f=!0;;){var m=o.indexOf(d);if(m==-1)break;f=!1,o.splice(m,1)}return f&&o.push(d),u.className=o.join(" "),f},r.setCssClass=function(u,d,o){o?r.addCssClass(u,d):r.removeCssClass(u,d)},r.hasCssString=function(u,d){var o=0,f;if(d=d||document,f=d.querySelectorAll("style")){for(;o<f.length;)if(f[o++].id===u)return!0}},r.removeElementById=function(u,d){d=d||document,d.getElementById(u)&&d.getElementById(u).remove()};var v,s=[];r.useStrictCSP=function(u){v=u,u==!1?p():s||(s=[])};function p(){var u=s;s=null,u&&u.forEach(function(d){a(d[0],d[1])})}function a(u,d,o){if(!(typeof document>"u")){if(s){if(o)p();else if(o===!1)return s.push([u,d])}if(!v){var f=o;!o||!o.getRootNode?f=document:(f=o.getRootNode(),(!f||f==o)&&(f=document));var m=f.ownerDocument||f;if(d&&r.hasCssString(d,f))return null;d&&(u+=`
11
+ /*# sourceURL=ace/css/`+d+" */");var w=r.createElement("style");w.appendChild(m.createTextNode(u)),d&&(w.id=d),f==m&&(f=r.getDocumentHead(m)),f.insertBefore(w,f.firstChild)}}}if(r.importCssString=a,r.importCssStylsheet=function(u,d){r.buildDom(["link",{rel:"stylesheet",href:u}],r.getDocumentHead(d))},r.$fixPositionBug=function(u){var d=u.getBoundingClientRect();if(u.style.left){var o=parseFloat(u.style.left),f=+d.left;Math.abs(o-f)>1&&(u.style.left=2*o-f+"px")}if(u.style.right){var o=parseFloat(u.style.right),f=window.innerWidth-d.right;Math.abs(o-f)>1&&(u.style.right=2*o-f+"px")}if(u.style.top){var o=parseFloat(u.style.top),f=+d.top;Math.abs(o-f)>1&&(u.style.top=2*o-f+"px")}if(u.style.bottom){var o=parseFloat(u.style.bottom),f=window.innerHeight-d.bottom;Math.abs(o-f)>1&&(u.style.bottom=2*o-f+"px")}},r.scrollbarWidth=function(u){var d=r.createElement("ace_inner");d.style.width="100%",d.style.minWidth="0px",d.style.height="200px",d.style.display="block";var o=r.createElement("ace_outer"),f=o.style;f.position="absolute",f.left="-10000px",f.overflow="hidden",f.width="200px",f.minWidth="0px",f.height="150px",f.display="block",o.appendChild(d);var m=u&&u.documentElement||document&&document.documentElement;if(!m)return 0;m.appendChild(o);var w=d.offsetWidth;f.overflow="scroll";var x=d.offsetWidth;return w===x&&(x=o.clientWidth),m.removeChild(o),w-x},r.computedStyle=function(u,d){return window.getComputedStyle(u,"")||{}},r.setStyle=function(u,d,o){u[d]!==o&&(u[d]=o)},r.HAS_CSS_ANIMATION=!1,r.HAS_CSS_TRANSFORMS=!1,r.HI_DPI=h.isWin?typeof window<"u"&&window.devicePixelRatio>=1.5:!0,h.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),!h.isEdge&&typeof l.style.animationName<"u"&&(r.HAS_CSS_ANIMATION=!0),l=null}r.HAS_CSS_TRANSFORMS?r.translate=function(u,d,o){u.style.transform="translate("+Math.round(d)+"px, "+Math.round(o)+"px)"}:r.translate=function(u,d,o){u.style.top=Math.round(o)+"px",u.style.left=Math.round(d)+"px"}}),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(t,r,c){var h=t("./dom");r.get=function(g,v){var s=new XMLHttpRequest;s.open("GET",g,!0),s.onreadystatechange=function(){s.readyState===4&&v(s.responseText)},s.send(null)},r.loadScript=function(g,v){var s=h.getDocumentHead(),p=document.createElement("script");p.src=g,s.appendChild(p),p.onload=p.onreadystatechange=function(a,l){(l||!p.readyState||p.readyState=="loaded"||p.readyState=="complete")&&(p=p.onload=p.onreadystatechange=null,l||v())}},r.qualifyURL=function(g){var v=document.createElement("a");return v.href=g,v.href}}),ace.define("ace/lib/oop",["require","exports","module"],function(t,r,c){r.inherits=function(h,g){h.super_=g,h.prototype=Object.create(g.prototype,{constructor:{value:h,enumerable:!1,writable:!0,configurable:!0}})},r.mixin=function(h,g){for(var v in g)h[v]=g[v];return h},r.implement=function(h,g){r.mixin(h,g)}}),ace.define("ace/lib/event_emitter",["require","exports","module"],function(t,r,c){var h={},g=function(){this.propagationStopped=!0},v=function(){this.defaultPrevented=!0};h._emit=h._dispatchEvent=function(s,p){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var a=this._eventRegistry[s]||[],l=this._defaultHandlers[s];if(!(!a.length&&!l)){(typeof p!="object"||!p)&&(p={}),p.type||(p.type=s),p.stopPropagation||(p.stopPropagation=g),p.preventDefault||(p.preventDefault=v),a=a.slice();for(var u=0;u<a.length&&(a[u](p,this),!p.propagationStopped);u++);if(l&&!p.defaultPrevented)return l(p,this)}},h._signal=function(s,p){var a=(this._eventRegistry||{})[s];if(a){a=a.slice();for(var l=0;l<a.length;l++)a[l](p,this)}},h.once=function(s,p){var a=this;if(this.on(s,function l(){a.off(s,l),p.apply(null,arguments)}),!p)return new Promise(function(l){p=l})},h.setDefaultHandler=function(s,p){var a=this._defaultHandlers;if(a||(a=this._defaultHandlers={_disabled_:{}}),a[s]){var l=a[s],u=a._disabled_[s];u||(a._disabled_[s]=u=[]),u.push(l);var d=u.indexOf(p);d!=-1&&u.splice(d,1)}a[s]=p},h.removeDefaultHandler=function(s,p){var a=this._defaultHandlers;if(a){var l=a._disabled_[s];if(a[s]==p)l&&this.setDefaultHandler(s,l.pop());else if(l){var u=l.indexOf(p);u!=-1&&l.splice(u,1)}}},h.on=h.addEventListener=function(s,p,a){this._eventRegistry=this._eventRegistry||{};var l=this._eventRegistry[s];return l||(l=this._eventRegistry[s]=[]),l.indexOf(p)==-1&&l[a?"unshift":"push"](p),p},h.off=h.removeListener=h.removeEventListener=function(s,p){this._eventRegistry=this._eventRegistry||{};var a=this._eventRegistry[s];if(a){var l=a.indexOf(p);l!==-1&&a.splice(l,1)}},h.removeAllListeners=function(s){s||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[s]=void 0),this._defaultHandlers&&(this._defaultHandlers[s]=void 0)},r.EventEmitter=h}),ace.define("ace/lib/report_error",["require","exports","module"],function(t,r,c){r.reportError=function(h,g){var v=new Error(h);v.data=g,typeof console=="object"&&console.error&&console.error(v),setTimeout(function(){throw v})}}),ace.define("ace/lib/default_english_messages",["require","exports","module"],function(t,r,c){var h={"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=h}),ace.define("ace/lib/app_config",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/lib/report_error","ace/lib/default_english_messages"],function(t,r,c){"no use strict";var h=t("./oop"),g=t("./event_emitter").EventEmitter,v=t("./report_error").reportError,s=t("./default_english_messages").defaultEnglishMessages,p={setOptions:function(o){Object.keys(o).forEach(function(f){this.setOption(f,o[f])},this)},getOptions:function(o){var f={};if(o)Array.isArray(o)||(o=Object.keys(o));else{var m=this.$options;o=Object.keys(m).filter(function(w){return!m[w].hidden})}return o.forEach(function(w){f[w]=this.getOption(w)},this),f},setOption:function(o,f){if(this["$"+o]!==f){var m=this.$options[o];if(!m)return a('misspelled option "'+o+'"');if(m.forwardTo)return this[m.forwardTo]&&this[m.forwardTo].setOption(o,f);m.handlesSet||(this["$"+o]=f),m&&m.set&&m.set.call(this,f)}},getOption:function(o){var f=this.$options[o];return f?f.forwardTo?this[f.forwardTo]&&this[f.forwardTo].getOption(o):f&&f.get?f.get.call(this):this["$"+o]:a('misspelled option "'+o+'"')}};function a(o){typeof console<"u"&&console.warn&&console.warn.apply(console,arguments)}var l,u,d=(function(){function o(){this.$defaultOptions={},l=s,u="dollarSigns"}return o.prototype.defineOptions=function(f,m,w){return f.$options||(this.$defaultOptions[m]=f.$options={}),Object.keys(w).forEach(function(x){var R=w[x];typeof R=="string"&&(R={forwardTo:R}),R.name||(R.name=x),f.$options[R.name]=R,"initialValue"in R&&(f["$"+R.name]=R.initialValue)}),h.implement(f,p),this},o.prototype.resetOptions=function(f){Object.keys(f.$options).forEach(function(m){var w=f.$options[m];"value"in w&&f.setOption(m,w.value)})},o.prototype.setDefaultValue=function(f,m,w){if(!f){for(f in this.$defaultOptions)if(this.$defaultOptions[f][m])break;if(!this.$defaultOptions[f][m])return!1}var x=this.$defaultOptions[f]||(this.$defaultOptions[f]={});x[m]&&(x.forwardTo?this.setDefaultValue(x.forwardTo,m,w):x[m].value=w)},o.prototype.setDefaultValues=function(f,m){Object.keys(m).forEach(function(w){this.setDefaultValue(f,w,m[w])},this)},o.prototype.setMessages=function(f,m){l=f,m&&m.placeholders&&(u=m.placeholders)},o.prototype.nls=function(f,m,w){l[f]||(a("No message found for the key '"+f+"' in messages with id "+l.$id+", trying to find a translation for the default string '"+m+"'."),l[m]||a("No message found for the default string '"+m+"' in the provided messages. Falling back to the default English message."));var x=l[f]||l[m]||m;return w&&(u==="dollarSigns"&&(x=x.replace(/\$(\$|[\d]+)/g,function(R,T){return T=="$"?"$":w[T]})),u==="curlyBrackets"&&(x=x.replace(/\{([^\}]+)\}/g,function(R,T){return w[T]}))),x},o})();d.prototype.warn=a,d.prototype.reportError=v,h.implement(d.prototype,g),r.AppConfig=d}),ace.define("ace/theme/textmate-css",["require","exports","module"],function(t,r,c){c.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(t,r,c){r.isDark=!1,r.cssClass="ace-tm",r.cssText=t("./textmate-css"),r.$id="ace/theme/textmate";var h=t("../lib/dom");h.importCssString(r.cssText,r.cssClass,!1)}),ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/net","ace/lib/dom","ace/lib/app_config","ace/theme/textmate"],function(t,r,c){"no use strict";var h=t("./lib/lang"),g=t("./lib/net"),v=t("./lib/dom"),s=t("./lib/app_config").AppConfig;c.exports=r=new s;var p={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{},loadWorkerFromBlob:!0,sharedPopups:!1,useStrictCSP:null};r.get=function(d){if(!p.hasOwnProperty(d))throw new Error("Unknown config key: "+d);return p[d]},r.set=function(d,o){if(p.hasOwnProperty(d))p[d]=o;else if(this.setDefaultValue("",d,o)==!1)throw new Error("Unknown config key: "+d);d=="useStrictCSP"&&v.useStrictCSP(o)},r.all=function(){return h.copyObject(p)},r.$modes={},r.moduleUrl=function(d,o){if(p.$moduleUrls[d])return p.$moduleUrls[d];var f=d.split("/");o=o||f[f.length-2]||"";var m=o=="snippets"?"/":"-",w=f[f.length-1];if(o=="worker"&&m=="-"){var x=new RegExp("^"+o+"[\\-_]|[\\-_]"+o+"$","g");w=w.replace(x,"")}(!w||w==o)&&f.length>1&&(w=f[f.length-2]);var R=p[o+"Path"];return R==null?R=p.basePath:m=="/"&&(o=m=""),R&&R.slice(-1)!="/"&&(R+="/"),R+o+m+w+this.get("suffix")},r.setModuleUrl=function(d,o){return p.$moduleUrls[d]=o};var a=function(d,o){if(d==="ace/theme/textmate"||d==="./theme/textmate")return o(null,t("./theme/textmate"));if(l)return l(d,o);console.error("loader is not configured")},l;r.setLoader=function(d){l=d},r.dynamicModules=Object.create(null),r.$loading={},r.$loaded={},r.loadModule=function(d,o){var f;if(Array.isArray(d))var m=d[0],w=d[1];else if(typeof d=="string")var w=d;var x=function(R){if(R&&!r.$loading[w])return o&&o(R);if(r.$loading[w]||(r.$loading[w]=[]),r.$loading[w].push(o),!(r.$loading[w].length>1)){var T=function(){a(w,function(_,C){C&&(r.$loaded[w]=C),r._emit("load.module",{name:w,module:C});var P=r.$loading[w];r.$loading[w]=null,P.forEach(function(O){O&&O(C)})})};if(!r.get("packaged"))return T();g.loadScript(r.moduleUrl(w,m),T),u()}};if(r.dynamicModules[w])r.dynamicModules[w]().then(function(R){R.default?x(R.default):x(R)});else{try{f=this.$require(w)}catch{}x(f||r.$loaded[w])}},r.$require=function(d){if(typeof c.require=="function"){var o="require";return c[o](d)}},r.setModuleLoader=function(d,o){r.dynamicModules[d]=o};var u=function(){!p.basePath&&!p.workerPath&&!p.modePath&&!p.themePath&&!Object.keys(p.$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"),u=function(){})};r.version="1.45.2"}),ace.define("ace/loader_build",["require","exports","module","ace/lib/fixoldbrowsers","ace/config"],function(t,r,c){t("./lib/fixoldbrowsers");var h=t("./config");h.setLoader(function(p,a){t([p],function(l){a(null,l)})});var g=(function(){return this||typeof window<"u"&&window})();c.exports=function(p){h.init=v,h.$require=t,p.require=t},v(!0);function v(p){if(!(!g||!g.document)){h.set("packaged",p||t.packaged||c.packaged||g.define&&(void 0).packaged);var a={},l="",u=document.currentScript||document._currentScript,d=u&&u.ownerDocument||document;u&&u.src&&(l=u.src.split(/[?#]/)[0].split("/").slice(0,-1).join("/")||"");for(var o=d.getElementsByTagName("script"),f=0;f<o.length;f++){var m=o[f],w=m.src||m.getAttribute("src");if(w){for(var x=m.attributes,R=0,T=x.length;R<T;R++){var _=x[R];_.name.indexOf("data-ace-")===0&&(a[s(_.name.replace(/^data-ace-/,""))]=_.value)}var C=w.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 P in a)typeof a[P]<"u"&&h.set(P,a[P])}}function s(p){return p.replace(/-(.)/g,function(a,l){return l.toUpperCase()})}}),ace.define("ace/range",["require","exports","module"],function(t,r,c){var h=(function(){function g(v,s,p,a){this.start={row:v,column:s},this.end={row:p,column:a}}return g.prototype.isEqual=function(v){return this.start.row===v.start.row&&this.end.row===v.end.row&&this.start.column===v.start.column&&this.end.column===v.end.column},g.prototype.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},g.prototype.contains=function(v,s){return this.compare(v,s)==0},g.prototype.compareRange=function(v){var s,p=v.end,a=v.start;return s=this.compare(p.row,p.column),s==1?(s=this.compare(a.row,a.column),s==1?2:s==0?1:0):s==-1?-2:(s=this.compare(a.row,a.column),s==-1?-1:s==1?42:0)},g.prototype.comparePoint=function(v){return this.compare(v.row,v.column)},g.prototype.containsRange=function(v){return this.comparePoint(v.start)==0&&this.comparePoint(v.end)==0},g.prototype.intersects=function(v){var s=this.compareRange(v);return s==-1||s==0||s==1},g.prototype.isEnd=function(v,s){return this.end.row==v&&this.end.column==s},g.prototype.isStart=function(v,s){return this.start.row==v&&this.start.column==s},g.prototype.setStart=function(v,s){typeof v=="object"?(this.start.column=v.column,this.start.row=v.row):(this.start.row=v,this.start.column=s)},g.prototype.setEnd=function(v,s){typeof v=="object"?(this.end.column=v.column,this.end.row=v.row):(this.end.row=v,this.end.column=s)},g.prototype.inside=function(v,s){return this.compare(v,s)==0?!(this.isEnd(v,s)||this.isStart(v,s)):!1},g.prototype.insideStart=function(v,s){return this.compare(v,s)==0?!this.isEnd(v,s):!1},g.prototype.insideEnd=function(v,s){return this.compare(v,s)==0?!this.isStart(v,s):!1},g.prototype.compare=function(v,s){return!this.isMultiLine()&&v===this.start.row?s<this.start.column?-1:s>this.end.column?1:0:v<this.start.row?-1:v>this.end.row?1:this.start.row===v?s>=this.start.column?0:-1:this.end.row===v?s<=this.end.column?0:1:0},g.prototype.compareStart=function(v,s){return this.start.row==v&&this.start.column==s?-1:this.compare(v,s)},g.prototype.compareEnd=function(v,s){return this.end.row==v&&this.end.column==s?1:this.compare(v,s)},g.prototype.compareInside=function(v,s){return this.end.row==v&&this.end.column==s?1:this.start.row==v&&this.start.column==s?-1:this.compare(v,s)},g.prototype.clipRows=function(v,s){if(this.end.row>s)var p={row:s+1,column:0};else if(this.end.row<v)var p={row:v,column:0};if(this.start.row>s)var a={row:s+1,column:0};else if(this.start.row<v)var a={row:v,column:0};return g.fromPoints(a||this.start,p||this.end)},g.prototype.extend=function(v,s){var p=this.compare(v,s);if(p==0)return this;if(p==-1)var a={row:v,column:s};else var l={row:v,column:s};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(v){var s=v.documentToScreenPosition(this.start),p=v.documentToScreenPosition(this.end);return new g(s.row,s.column,p.row,p.column)},g.prototype.moveBy=function(v,s){this.start.row+=v,this.start.column+=s,this.end.row+=v,this.end.column+=s},g})();h.fromPoints=function(g,v){return new h(g.row,g.column,v.row,v.column)},h.comparePoints=function(g,v){return g.row-v.row||g.column-v.column},r.Range=h}),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],function(t,r,c){for(var h=t("./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:"*"}},v={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},s=0;s<10;s++)v["Digit"+s]=48+s,v["Numpad"+s]=96+s,g.PRINTABLE_KEYS[48+s]=""+s,g.FUNCTION_KEYS[96+s]="Numpad"+s;for(var s=65;s<91;s++){var p=String.fromCharCode(s+32);v["Key"+p.toUpperCase()]=s,g.PRINTABLE_KEYS[s]=p}for(var s=1;s<13;s++)v["F"+s]=111+s,g.FUNCTION_KEYS[111+s]="F"+s;var a={Shift:16,Control:17,Alt:18,Meta:224};for(var l in a)v[l]=v[l+"Left"]=v[l+"Right"]=a[l];r.$codeToKeyCode=v,g.PRINTABLE_KEYS[173]="-";for(var u in g.FUNCTION_KEYS){var d=g.FUNCTION_KEYS[u].toLowerCase();g[d]=parseInt(u,10)}for(var u in g.PRINTABLE_KEYS){var d=g.PRINTABLE_KEYS[u].toLowerCase();g[d]=parseInt(u,10)}h.mixin(g,g.MODIFIER_KEYS),h.mixin(g,g.PRINTABLE_KEYS),h.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"],f=Math.pow(2,o.length);f--;)g.KEY_MODS[f]=o.filter(function(m){return f&g.KEY_MODS[m]}).join("-")+"-"})(),g.KEY_MODS[0]="",g.KEY_MODS[-1]="input-",h.mixin(r,g),r.default=r,r.keyCodeToString=function(o){var f=g[o];return typeof f!="string"&&(f=String.fromCharCode(o)),f.toLowerCase()}}),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(t,r,c){var h=t("./keys"),g=t("./useragent"),v=null,s=0,p;function a(){p=!1;try{document.createComment("").addEventListener("test",function(){},{get passive(){return p={passive:!1},!0}})}catch{}}function l(){return p==null&&a(),p}function u(R,T,_){this.elem=R,this.type=T,this.callback=_}u.prototype.destroy=function(){o(this.elem,this.type,this.callback),this.elem=this.type=this.callback=void 0};var d=r.addListener=function(R,T,_,C){R.addEventListener(T,_,l()),C&&C.$toDestroy.push(new u(R,T,_))},o=r.removeListener=function(R,T,_){R.removeEventListener(T,_,l())};r.stopEvent=function(R){return r.stopPropagation(R),r.preventDefault(R),!1},r.stopPropagation=function(R){R.stopPropagation&&R.stopPropagation()},r.preventDefault=function(R){R.preventDefault&&R.preventDefault()},r.getButton=function(R){return R.type=="dblclick"?0:R.type=="contextmenu"||g.isMac&&R.ctrlKey&&!R.altKey&&!R.shiftKey?2:R.button},r.capture=function(R,T,_){var C=R&&R.ownerDocument||document;function P(O){T&&T(O),_&&_(O),o(C,"mousemove",T),o(C,"mouseup",P),o(C,"dragstart",P)}return d(C,"mousemove",T),d(C,"mouseup",P),d(C,"dragstart",P),P},r.addMouseWheelListener=function(R,T,_){d(R,"wheel",function(C){var P=.15,O=C.deltaX||0,E=C.deltaY||0;switch(C.deltaMode){case C.DOM_DELTA_PIXEL:C.wheelX=O*P,C.wheelY=E*P;break;case C.DOM_DELTA_LINE:var k=15;C.wheelX=O*k,C.wheelY=E*k;break;case C.DOM_DELTA_PAGE:var B=150;C.wheelX=O*B,C.wheelY=E*B;break}T(C)},_)},r.addMultiMouseDownListener=function(R,T,_,C,P){var O=0,E,k,B,N={2:"dblclick",3:"tripleclick",4:"quadclick"};function M($){if(r.getButton($)!==0?O=0:$.detail>1?(O++,O>4&&(O=1)):O=1,g.isIE){var A=Math.abs($.clientX-E)>5||Math.abs($.clientY-k)>5;(!B||A)&&(O=1),B&&clearTimeout(B),B=setTimeout(function(){B=null},T[O-1]||600),O==1&&(E=$.clientX,k=$.clientY)}if($._clicks=O,_[C]("mousedown",$),O>4)O=0;else if(O>1)return _[C](N[O],$)}Array.isArray(R)||(R=[R]),R.forEach(function($){d($,"mousedown",M,P)})};function f(R){return 0|(R.ctrlKey?1:0)|(R.altKey?2:0)|(R.shiftKey?4:0)|(R.metaKey?8:0)}r.getModifierString=function(R){return h.KEY_MODS[f(R)]};function m(R,T,_){var C=f(T);if(!_&&T.code&&(_=h.$codeToKeyCode[T.code]||_),!g.isMac&&v){if(T.getModifierState&&(T.getModifierState("OS")||T.getModifierState("Win"))&&(C|=8),v.altGr)if((3&C)!=3)v.altGr=0;else return;if(_===18||_===17){var P=T.location;if(_===17&&P===1)v[_]==1&&(s=T.timeStamp);else if(_===18&&C===3&&P===2){var O=T.timeStamp-s;O<50&&(v.altGr=!0)}}}if(_ in h.MODIFIER_KEYS&&(_=-1),!(!C&&_===13&&T.location===3&&(R(T,C,-_),T.defaultPrevented))){if(g.isChromeOS&&C&8){if(R(T,C,_),T.defaultPrevented)return;C&=-9}return!C&&!(_ in h.FUNCTION_KEYS)&&!(_ in h.PRINTABLE_KEYS)?!1:R(T,C,_)}}r.addCommandKeyListener=function(R,T,_){var C=null;d(R,"keydown",function(P){v[P.keyCode]=(v[P.keyCode]||0)+1;var O=m(T,P,P.keyCode);return C=P.defaultPrevented,O},_),d(R,"keypress",function(P){C&&(P.ctrlKey||P.altKey||P.shiftKey||P.metaKey)&&(r.stopEvent(P),C=null)},_),d(R,"keyup",function(P){v[P.keyCode]=null},_),v||(w(),d(window,"focus",w))};function w(){v=Object.create(null)}if(typeof window=="object"&&window.postMessage&&!g.isOldIE){var x=1;r.nextTick=function(R,T){T=T||window;var _="zero-timeout-message-"+x++,C=function(P){P.data==_&&(r.stopPropagation(P),o(T,"message",C),R())};d(T,"message",C),T.postMessage(_,"*")}}r.$idleBlocked=!1,r.onIdle=function(R,T){return setTimeout(function _(){r.$idleBlocked?setTimeout(_,100):R()},T)},r.$idleBlockId=null,r.blockIdle=function(R){r.$idleBlockId&&clearTimeout(r.$idleBlockId),r.$idleBlocked=!0,r.$idleBlockId=setTimeout(function(){r.$idleBlocked=!1},R||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(R){setTimeout(R,17)}}),ace.define("ace/clipboard",["require","exports","module"],function(t,r,c){var h;c.exports={lineMode:!1,pasteCancelled:function(){return h&&h>Date.now()-50?!0:h=!1},cancel:function(){h=Date.now()}}}),ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/config","ace/lib/useragent","ace/lib/dom","ace/lib/lang","ace/clipboard","ace/lib/keys"],function(t,r,c){var h=t("../lib/event"),g=t("../config").nls,v=t("../lib/useragent"),s=t("../lib/dom"),p=t("../lib/lang"),a=t("../clipboard"),l=v.isChrome<18,u=v.isIE,d=v.isChrome>63,o=400,f=t("../lib/keys"),m=f.KEY_MODS,w=v.isIOS,x=w?/\s/:/\n/,R=v.isMobile,T=(function(){function _(C,P){var O=this;this.host=P,this.text=s.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="",R||(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"}),h.addListener(this.text,"blur",function(E){O.ignoreFocusEvents||(P.onBlur(E),O.$isFocused=!1)},P),h.addListener(this.text,"focus",function(E){if(!O.ignoreFocusEvents){if(O.$isFocused=!0,v.isEdge)try{if(!document.hasFocus())return}catch{}P.onFocus(E),v.isEdge?setTimeout(O.resetSelection.bind(O)):O.resetSelection()}},P),this.$focusScroll=!1,P.on("beforeEndOperation",function(){var E=P.curOp,k=E&&E.command&&E.command.name;if(k!="insertstring"){var B=k&&(E.docChanged||E.selectionChanged);O.inComposition&&B&&(O.lastValue=O.text.value="",O.onCompositionEnd()),O.resetSelection()}}),P.on("changeSelection",this.setAriaLabel.bind(this)),this.resetSelection=w?this.$resetSelectionIOS:this.$resetSelection,this.$isFocused&&P.onFocus(),this.inputHandler=null,this.afterContextMenu=!1,h.addCommandKeyListener(this.text,function(E,k,B){if(!O.inComposition)return P.onCommandKey(E,k,B)},P),h.addListener(this.text,"select",this.onSelect.bind(this),P),h.addListener(this.text,"input",this.onInput.bind(this),P),h.addListener(this.text,"cut",this.onCut.bind(this),P),h.addListener(this.text,"copy",this.onCopy.bind(this),P),h.addListener(this.text,"paste",this.onPaste.bind(this),P),(!("oncut"in this.text)||!("oncopy"in this.text)||!("onpaste"in this.text))&&h.addListener(C,"keydown",function(E){if(!(v.isMac&&!E.metaKey||!E.ctrlKey))switch(E.keyCode){case 67:O.onCopy(E);break;case 86:O.onPaste(E);break;case 88:O.onCut(E);break}},P),this.syncComposition=p.delayedCall(this.onCompositionUpdate.bind(this),50).schedule.bind(null,null),h.addListener(this.text,"compositionstart",this.onCompositionStart.bind(this),P),h.addListener(this.text,"compositionupdate",this.onCompositionUpdate.bind(this),P),h.addListener(this.text,"keyup",this.onKeyup.bind(this),P),h.addListener(this.text,"keydown",this.syncComposition.bind(this),P),h.addListener(this.text,"compositionend",this.onCompositionEnd.bind(this),P),this.closeTimeout,h.addListener(this.text,"mouseup",this.$onContextMenu.bind(this),P),h.addListener(this.text,"mousedown",function(E){E.preventDefault(),O.onContextMenuClose()},P),h.addListener(P.renderer.scroller,"contextmenu",this.$onContextMenu.bind(this),P),h.addListener(this.text,"contextmenu",this.$onContextMenu.bind(this),P),w&&this.addIosSelectionHandler(C,P,this.text)}return _.prototype.addIosSelectionHandler=function(C,P,O){var E=this,k=null,B=!1;O.addEventListener("keydown",function(M){k&&clearTimeout(k),B=!0},!0),O.addEventListener("keyup",function(M){k=setTimeout(function(){B=!1},100)},!0);var N=function(M){if(document.activeElement===O&&!(B||E.inComposition||P.$mouseHandler.isMousePressed)&&!E.copied){var $=O.selectionStart,A=O.selectionEnd,D=null,j=0;if($==0?D=f.up:$==1?D=f.home:A>E.lastSelectionEnd&&E.lastValue[A]==`
170
+ `?D=f.end:$<E.lastSelectionStart&&E.lastValue[$-1]==" "?(D=f.left,j=m.option):$<E.lastSelectionStart||$==E.lastSelectionStart&&E.lastSelectionEnd!=E.lastSelectionStart&&$==A?D=f.left:A>E.lastSelectionEnd&&E.lastValue.slice(0,A).split(`
171
+ `).length>2?D=f.down:A>E.lastSelectionEnd&&E.lastValue[A-1]==" "?(D=f.right,j=m.option):(A>E.lastSelectionEnd||A==E.lastSelectionEnd&&E.lastSelectionEnd!=E.lastSelectionStart&&$==A)&&(D=f.right),$!==A&&(j|=m.shift),D){var U=P.onCommandKey({},j,D);if(!U&&P.commands){D=f.keyCodeToString(D);var q=P.commands.findKeyCommand(j,D);q&&P.execCommand(q)}E.lastSelectionStart=$,E.lastSelectionEnd=A,E.resetSelection("")}}};document.addEventListener("selectionchange",N),P.on("destroy",function(){document.removeEventListener("selectionchange",N)})},_.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)},_.prototype.$onContextMenu=function(C){this.host.textInput.onContextMenu(C),this.onContextMenuClose()},_.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()},_.prototype.cancelComposition=function(){this.ignoreFocusEvents=!0,this.text.blur(),this.text.focus(),this.ignoreFocusEvents=!1},_.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 P=this.host.getSelectionRange();P.end.row=P.start.row,P.end.column=P.start.column,this.inComposition.markerRange=P,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()))}},_.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)}}},_.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())},_.prototype.onCut=function(C){this.doCopy(C,!0)},_.prototype.onCopy=function(C){this.doCopy(C,!1)},_.prototype.onPaste=function(C){var P=this.handleClipboardData(C);a.pasteCancelled()||(typeof P=="string"?(P&&this.host.onPaste(P,C),v.isIE&&setTimeout(this.resetSelection),h.preventDefault(C)):(this.text.value="",this.pasted=!0))},_.prototype.doCopy=function(C,P){var O=this,E=this.host.getCopyText();if(!E)return h.preventDefault(C);this.handleClipboardData(C,E)?(w&&(this.resetSelection(E),this.copied=E,setTimeout(function(){O.copied=!1},10)),P?this.host.onCut():this.host.onCopy(),h.preventDefault(C)):(this.copied=!0,this.text.value=E,this.text.select(),setTimeout(function(){O.copied=!1,O.resetSelection(),P?O.host.onCut():O.host.onCopy()}))},_.prototype.handleClipboardData=function(C,P,O){var E=C.clipboardData||window.clipboardData;if(!(!E||l)){var k=u||O?"Text":"text/plain";try{return P?E.setData(k,P)!==!1:E.getData(k)}catch(B){if(!O)return this.handleClipboardData(B,P,!0)}}},_.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 P=this.text.value,O=this.sendText(P,!0);(P.length>o+100||x.test(O)||R&&this.lastSelectionStart<1&&this.lastSelectionStart==this.lastSelectionEnd)&&this.resetSelection()},_.prototype.sendText=function(C,P){if(this.afterContextMenu&&(this.afterContextMenu=!1),this.pasted)return this.resetSelection(),C&&this.host.onPaste(C),this.pasted=!1,"";for(var O=this.text.selectionStart,E=this.text.selectionEnd,k=this.lastSelectionStart,B=this.lastValue.length-this.lastSelectionEnd,N=C,M=C.length-O,$=C.length-E,A=0;k>0&&this.lastValue[A]==C[A];)A++,k--;for(N=N.slice(A),A=1;B>0&&this.lastValue.length-A>this.lastSelectionStart-1&&this.lastValue[this.lastValue.length-A]==C[C.length-A];)A++,B--;M-=A-1,$-=A-1;var D=N.length-A+1;if(D<0&&(k=-D,D=0),N=N.slice(0,D),!P&&!N&&!M&&!k&&!B&&!$)return"";this.sendingText=!0;var j=!1;return v.isAndroid&&N==". "&&(N=" ",j=!0),N&&!k&&!B&&!M&&!$||this.commandMode?this.host.onTextInput(N):this.host.onTextInput(N,{extendLeft:k,extendRight:B,restoreStart:M,restoreEnd:$}),this.sendingText=!1,this.lastValue=C,this.lastSelectionStart=O,this.lastSelectionEnd=E,this.lastRestoreEnd=$,j?`
172
+ `:N},_.prototype.onSelect=function(C){var P=this;if(!this.inComposition){var O=function(E){return E.selectionStart===0&&E.selectionEnd>=P.lastValue.length&&E.value===P.lastValue&&P.lastValue&&E.selectionEnd!==P.lastSelectionEnd};this.copied?this.copied=!1:O(this.text)?(this.host.selectAll(),this.resetSelection()):R&&this.text.selectionStart!=this.lastSelectionStart&&this.resetSelection()}},_.prototype.$resetSelectionIOS=function(C){if(!(!this.$isFocused||this.copied&&!C||this.sendingText)){C||(C="");var P=`
173
+ ab`+C+`cde fg
174
+ `;P!=this.text.value&&(this.text.value=this.lastValue=P);var O=4,E=4+(C.length||(this.host.selection.isEmpty()?0:1));(this.lastSelectionStart!=O||this.lastSelectionEnd!=E)&&this.text.setSelectionRange(O,E),this.lastSelectionStart=O,this.lastSelectionEnd=E}},_.prototype.$resetSelection=function(){var C=this;if(!(this.inComposition||this.sendingText)&&!(!this.$isFocused&&!this.afterContextMenu)){this.inComposition=!0;var P=0,O=0,E="",k=function(q,Q){for(var re=Q,le=1;le<=q-C.rowStart&&le<2*C.numberOfExtraLines+1;le++)re+=C.host.session.getLine(q-le).length+1;return re};if(this.host.session){var B=this.host.selection,N=B.getRange(),M=B.cursor.row;M===this.rowEnd+1?(this.rowStart=this.rowEnd+1,this.rowEnd=this.rowStart+2*this.numberOfExtraLines):M===this.rowStart-1?(this.rowEnd=this.rowStart-1,this.rowStart=this.rowEnd-2*this.numberOfExtraLines):(M<this.rowStart-1||M>this.rowEnd+1)&&(this.rowStart=M>this.numberOfExtraLines?M-this.numberOfExtraLines:0,this.rowEnd=M>this.numberOfExtraLines?M+this.numberOfExtraLines:2*this.numberOfExtraLines);for(var $=[],A=this.rowStart;A<=this.rowEnd;A++)$.push(this.host.session.getLine(A));if(E=$.join(`
175
+ `),P=k(N.start.row,N.start.column),O=k(N.end.row,N.end.column),N.start.row<this.rowStart){var D=this.host.session.getLine(this.rowStart-1);P=N.start.row<this.rowStart-1?0:P,O+=D.length+1,E=D+`
176
+ `+E}else if(N.end.row>this.rowEnd){var j=this.host.session.getLine(this.rowEnd+1);O=N.end.row>this.rowEnd+1?j.length:N.end.column,O+=E.length+1,E=E+`
177
+ `+j}else R&&M>0&&(E=`
178
+ `+E,O+=1,P+=1);E.length>o&&(P<o&&O<o?E=E.slice(0,o):(E=`
179
+ `,P==O?P=O=0:(P=0,O=1)));var U=E+`
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!=O||this.lastSelectionStart!=P||this.text.selectionEnd!=this.lastSelectionEnd)try{this.text.setSelectionRange(P,O),this.lastSelectionStart=P,this.lastSelectionEnd=O}catch{}this.inComposition=!1}},_.prototype.setHost=function(C){this.host=C},_.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},_.prototype.setAriaLabel=function(){var C="";if(this.host.$textInputAriaLabel&&(C+="".concat(this.host.$textInputAriaLabel,", ")),this.host.session){var P=this.host.session.selection.cursor.row;C+=g("text-input.aria-label","Cursor at row $0",[P+1])}this.text.setAttribute("aria-label",C)},_.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())},_.prototype.focus=function(){var C=this;if(this.setAriaOptions({setLabel:this.host.renderer.enableKeyboardAccessibility}),this.tempStyle||d||this.$focusScroll=="browser")return this.text.focus({preventScroll:!0});var P=this.text.style.top;this.text.style.position="fixed",this.text.style.top="0px";try{var O=this.text.getBoundingClientRect().top!=0}catch{return}var E=[];if(O)for(var k=this.text.parentElement;k&&k.nodeType==1;)E.push(k),k.setAttribute("ace_nocontext","true"),!k.parentElement&&k.getRootNode?k=k.getRootNode().host:k=k.parentElement;this.text.focus({preventScroll:!0}),O&&E.forEach(function(B){B.removeAttribute("ace_nocontext")}),setTimeout(function(){C.text.style.position="",C.text.style.top=="0px"&&(C.text.style.top=P)},0)},_.prototype.blur=function(){this.text.blur()},_.prototype.isFocused=function(){return this.$isFocused},_.prototype.setInputHandler=function(C){this.inputHandler=C},_.prototype.getInputHandler=function(){return this.inputHandler},_.prototype.getElement=function(){return this.text},_.prototype.setCommandMode=function(C){this.commandMode=C,this.text.readOnly=!1},_.prototype.setReadOnly=function(C){this.commandMode||(this.text.readOnly=C)},_.prototype.setCopyWithEmptySelection=function(C){},_.prototype.onContextMenu=function(C){this.afterContextMenu=!0,this.resetSelection(),this.host._emit("nativecontextmenu",{target:this.host,domEvent:C}),this.moveToMouse(C,!0)},_.prototype.moveToMouse=function(C,P){var O=this;this.tempStyle||(this.tempStyle=this.text.style.cssText),this.text.style.cssText=(P?"z-index:100000;":"")+(v.isIE?"opacity:0.1;":"")+"text-indent: -"+(this.lastSelectionStart+this.lastSelectionEnd)*this.host.renderer.characterWidth*.5+"px;";var E=this.host.container.getBoundingClientRect(),k=s.computedStyle(this.host.container),B=E.top+(parseInt(k.borderTopWidth)||0),N=E.left+(parseInt(k.borderLeftWidth)||0),M=E.bottom-B-this.text.clientHeight-2,$=function(A){s.translate(O.text,A.clientX-N-2,Math.min(A.clientY-B-2,M))};$(C),C.type=="mousedown"&&(this.host.renderer.$isMousePressed=!0,clearTimeout(this.closeTimeout),v.isWin&&h.capture(this.host.container,$,this.onContextMenuClose.bind(this)))},_.prototype.destroy=function(){this.text.parentElement&&this.text.parentElement.removeChild(this.text)},_})();r.TextInput=T,r.$setUserAgentForTests=function(_,C){R=_,w=C}}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],function(t,r,c){var h=t("../lib/useragent"),g=0,v=550,s=(function(){function l(u){u.$clickSelection=null;var d=u.editor;d.setDefaultHandler("mousedown",this.onMouseDown.bind(u)),d.setDefaultHandler("dblclick",this.onDoubleClick.bind(u)),d.setDefaultHandler("tripleclick",this.onTripleClick.bind(u)),d.setDefaultHandler("quadclick",this.onQuadClick.bind(u)),d.setDefaultHandler("mousewheel",this.onMouseWheel.bind(u));var o=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];o.forEach(function(f){u[f]=this[f]},this),u.selectByLines=this.extendSelectionBy.bind(u,"getLineRange"),u.selectByWords=this.extendSelectionBy.bind(u,"getWordRange")}return l.prototype.onMouseDown=function(u){var d=u.inSelection(),o=u.getDocumentPosition();this.mousedownEvent=u;var f=this.editor,m=u.getButton();if(m!==0){var w=f.getSelectionRange(),x=w.isEmpty();(x||m==1)&&f.selection.moveToPosition(o),m==2&&(f.textInput.onContextMenu(u.domEvent),h.isMozilla||u.preventDefault());return}if(this.mousedownEvent.time=Date.now(),d&&!f.isFocused()&&(f.focus(),this.$focusTimeout&&!this.$clickSelection&&!f.inMultiSelectMode)){this.setState("focusWait"),this.captureMouse(u);return}return this.captureMouse(u),this.startSelect(o,u.domEvent._clicks>1),u.preventDefault()},l.prototype.startSelect=function(u,d){u=u||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var o=this.editor;this.mousedownEvent&&(this.mousedownEvent.getShiftKey()?o.selection.selectToPosition(u):d||o.selection.moveToPosition(u),d||this.select(),o.setStyle("ace_selecting"),this.setState("select"))},l.prototype.select=function(){var u,d=this.editor,o=d.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var f=this.$clickSelection.comparePoint(o);if(f==-1)u=this.$clickSelection.end;else if(f==1)u=this.$clickSelection.start;else{var m=a(this.$clickSelection,o,d.session);o=m.cursor,u=m.anchor}d.selection.setSelectionAnchor(u.row,u.column)}d.selection.selectToPosition(o),d.renderer.scrollCursorIntoView()},l.prototype.extendSelectionBy=function(u){var d,o=this.editor,f=o.renderer.screenToTextCoordinates(this.x,this.y),m=o.selection[u](f.row,f.column);if(this.$clickSelection){var w=this.$clickSelection.comparePoint(m.start),x=this.$clickSelection.comparePoint(m.end);if(w==-1&&x<=0)d=this.$clickSelection.end,(m.end.row!=f.row||m.end.column!=f.column)&&(f=m.start);else if(x==1&&w>=0)d=this.$clickSelection.start,(m.start.row!=f.row||m.start.column!=f.column)&&(f=m.end);else if(w==-1&&x==1)f=m.end,d=m.start;else{var R=a(this.$clickSelection,f,o.session);f=R.cursor,d=R.anchor}o.selection.setSelectionAnchor(d.row,d.column)}o.selection.selectToPosition(f),o.renderer.scrollCursorIntoView()},l.prototype.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting")},l.prototype.focusWait=function(){var u=p(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),d=Date.now();(u>g||d-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},l.prototype.onDoubleClick=function(u){var d=u.getDocumentPosition(),o=this.editor,f=o.session,m=f.getBracketRange(d);m?(m.isEmpty()&&(m.start.column--,m.end.column++),this.setState("select")):(m=o.selection.getWordRange(d.row,d.column),this.setState("selectByWords")),this.$clickSelection=m,this.select()},l.prototype.onTripleClick=function(u){var d=u.getDocumentPosition(),o=this.editor;this.setState("selectByLines");var f=o.getSelectionRange();f.isMultiLine()&&f.contains(d.row,d.column)?(this.$clickSelection=o.selection.getLineRange(f.start.row),this.$clickSelection.end=o.selection.getLineRange(f.end.row).end):this.$clickSelection=o.selection.getLineRange(d.row),this.select()},l.prototype.onQuadClick=function(u){var d=this.editor;d.selectAll(),this.$clickSelection=d.getSelectionRange(),this.setState("selectAll")},l.prototype.onMouseWheel=function(u){if(!u.getAccelKey()){u.getShiftKey()&&u.wheelY&&!u.wheelX&&(u.wheelX=u.wheelY,u.wheelY=0);var d=this.editor;this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0});var o=this.$lastScroll,f=u.domEvent.timeStamp,m=f-o.t,w=m?u.wheelX/m:o.vx,x=m?u.wheelY/m:o.vy;m<v&&(w=(w+o.vx)/2,x=(x+o.vy)/2);var R=Math.abs(w/x),T=!1;if(R>=1&&d.renderer.isScrollableBy(u.wheelX*u.speed,0)&&(T=!0),R<=1&&d.renderer.isScrollableBy(0,u.wheelY*u.speed)&&(T=!0),T)o.allowed=f;else if(f-o.allowed<v){var _=Math.abs(w)<=1.5*Math.abs(o.vx)&&Math.abs(x)<=1.5*Math.abs(o.vy);_?(T=!0,o.allowed=f):o.allowed=0}if(o.t=f,o.vx=w,o.vy=x,T)return d.renderer.scrollBy(u.wheelX*u.speed,u.wheelY*u.speed),u.stop()}},l})();s.prototype.selectEnd=s.prototype.selectByLinesEnd,s.prototype.selectAllEnd=s.prototype.selectByLinesEnd,s.prototype.selectByWordsEnd=s.prototype.selectByLinesEnd,r.DefaultHandlers=s;function p(l,u,d,o){return Math.sqrt(Math.pow(d-l,2)+Math.pow(o-u,2))}function a(l,u,d){if(l.start.row==l.end.row)var o=2*u.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*u.column-2*d.getLine(l.start.row).length;else var o=2*u.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(t,r,c){var h=t("../lib/event"),g=t("../lib/useragent"),v=(function(){function s(p,a){this.speed,this.wheelX,this.wheelY,this.domEvent=p,this.editor=a,this.x=this.clientX=p.clientX,this.y=this.clientY=p.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1}return s.prototype.stopPropagation=function(){h.stopPropagation(this.domEvent),this.propagationStopped=!0},s.prototype.preventDefault=function(){h.preventDefault(this.domEvent),this.defaultPrevented=!0},s.prototype.stop=function(){this.stopPropagation(),this.preventDefault()},s.prototype.getDocumentPosition=function(){return this.$pos?this.$pos:(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY),this.$pos)},s.prototype.getGutterRow=function(){var p=this.getDocumentPosition().row,a=this.editor.session.documentToScreenRow(p,0),l=this.editor.session.documentToScreenRow(this.editor.renderer.$gutterLayer.$lines.get(0).row,0);return a-l},s.prototype.inSelection=function(){if(this.$inSelection!==null)return this.$inSelection;var p=this.editor,a=p.getSelectionRange();if(a.isEmpty())this.$inSelection=!1;else{var l=this.getDocumentPosition();this.$inSelection=a.contains(l.row,l.column)}return this.$inSelection},s.prototype.getButton=function(){return h.getButton(this.domEvent)},s.prototype.getShiftKey=function(){return this.domEvent.shiftKey},s.prototype.getAccelKey=function(){return g.isMac?this.domEvent.metaKey:this.domEvent.ctrlKey},s})();r.MouseEvent=v}),ace.define("ace/lib/scroll",["require","exports","module"],function(t,r,c){r.preventParentScroll=function(h){h.stopPropagation();var g=h.currentTarget,v=g.scrollHeight>g.clientHeight;v||h.preventDefault()}}),ace.define("ace/tooltip",["require","exports","module","ace/lib/dom","ace/lib/event","ace/range","ace/lib/scroll"],function(t,r,c){var h=this&&this.__extends||(function(){var f=function(m,w){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,R){x.__proto__=R}||function(x,R){for(var T in R)Object.prototype.hasOwnProperty.call(R,T)&&(x[T]=R[T])},f(m,w)};return function(m,w){if(typeof w!="function"&&w!==null)throw new TypeError("Class extends value "+String(w)+" is not a constructor or null");f(m,w);function x(){this.constructor=m}m.prototype=w===null?Object.create(w):(x.prototype=w.prototype,new x)}})(),g=this&&this.__values||function(f){var m=typeof Symbol=="function"&&Symbol.iterator,w=m&&f[m],x=0;if(w)return w.call(f);if(f&&typeof f.length=="number")return{next:function(){return f&&x>=f.length&&(f=void 0),{value:f&&f[x++],done:!f}}};throw new TypeError(m?"Object is not iterable.":"Symbol.iterator is not defined.")},v=t("./lib/dom");t("./lib/event");var s=t("./range").Range,p=t("./lib/scroll").preventParentScroll,a="ace_tooltip",l=(function(){function f(m){this.isOpen=!1,this.$element=null,this.$parentNode=m}return f.prototype.$init=function(){return this.$element=v.createElement("div"),this.$element.className=a,this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},f.prototype.getElement=function(){return this.$element||this.$init()},f.prototype.setText=function(m){this.getElement().textContent=m},f.prototype.setHtml=function(m){this.getElement().innerHTML=m},f.prototype.setPosition=function(m,w){this.getElement().style.left=m+"px",this.getElement().style.top=w+"px"},f.prototype.setClassName=function(m){v.addCssClass(this.getElement(),m)},f.prototype.setTheme=function(m){this.theme&&(this.theme.isDark&&v.removeCssClass(this.getElement(),"ace_dark"),this.theme.cssClass&&v.removeCssClass(this.getElement(),this.theme.cssClass)),m.isDark&&v.addCssClass(this.getElement(),"ace_dark"),m.cssClass&&v.addCssClass(this.getElement(),m.cssClass),this.theme={isDark:m.isDark,cssClass:m.cssClass}},f.prototype.show=function(m,w,x){m!=null&&this.setText(m),w!=null&&x!=null&&this.setPosition(w,x),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},f.prototype.hide=function(m){this.isOpen&&(this.getElement().style.display="none",this.getElement().className=a,this.isOpen=!1)},f.prototype.getHeight=function(){return this.getElement().offsetHeight},f.prototype.getWidth=function(){return this.getElement().offsetWidth},f.prototype.destroy=function(){this.isOpen=!1,this.$element&&this.$element.parentNode&&this.$element.parentNode.removeChild(this.$element)},f})(),u=(function(){function f(){this.popups=[]}return f.prototype.addPopup=function(m){this.popups.push(m),this.updatePopups()},f.prototype.removePopup=function(m){var w=this.popups.indexOf(m);w!==-1&&(this.popups.splice(w,1),this.updatePopups())},f.prototype.updatePopups=function(){var m,w,x,R;this.popups.sort(function(N,M){return M.priority-N.priority});var T=[];try{for(var _=g(this.popups),C=_.next();!C.done;C=_.next()){var P=C.value,O=!0;try{for(var E=(x=void 0,g(T)),k=E.next();!k.done;k=E.next()){var B=k.value;if(this.doPopupsOverlap(B,P)){O=!1;break}}}catch(N){x={error:N}}finally{try{k&&!k.done&&(R=E.return)&&R.call(E)}finally{if(x)throw x.error}}O?T.push(P):P.hide()}}catch(N){m={error:N}}finally{try{C&&!C.done&&(w=_.return)&&w.call(_)}finally{if(m)throw m.error}}},f.prototype.doPopupsOverlap=function(m,w){var x=m.getElement().getBoundingClientRect(),R=w.getElement().getBoundingClientRect();return x.left<R.right&&x.right>R.left&&x.top<R.bottom&&x.bottom>R.top},f})(),d=new u;r.popupManager=d,r.Tooltip=l;var o=(function(f){h(m,f);function m(w){w===void 0&&(w=document.body);var x=f.call(this,w)||this;x.timeout=void 0,x.lastT=0,x.idleTime=350,x.lastEvent=void 0,x.onMouseOut=x.onMouseOut.bind(x),x.onMouseMove=x.onMouseMove.bind(x),x.waitForHover=x.waitForHover.bind(x),x.hide=x.hide.bind(x);var R=x.getElement();return R.style.whiteSpace="pre-wrap",R.style.pointerEvents="auto",R.addEventListener("mouseout",x.onMouseOut),R.tabIndex=-1,R.addEventListener("blur",(function(){R.contains(document.activeElement)||this.hide()}).bind(x)),R.addEventListener("wheel",p),x}return m.prototype.addToEditor=function(w){w.on("mousemove",this.onMouseMove),w.on("mousedown",this.hide);var x=w.renderer.getMouseEventTarget();x&&typeof x.removeEventListener=="function"&&x.addEventListener("mouseout",this.onMouseOut,!0)},m.prototype.removeFromEditor=function(w){w.off("mousemove",this.onMouseMove),w.off("mousedown",this.hide);var x=w.renderer.getMouseEventTarget();x&&typeof x.removeEventListener=="function"&&x.removeEventListener("mouseout",this.onMouseOut,!0),this.timeout&&(clearTimeout(this.timeout),this.timeout=null)},m.prototype.onMouseMove=function(w,x){this.lastEvent=w,this.lastT=Date.now();var R=x.$mouseHandler.isMousePressed;if(this.isOpen){var T=this.lastEvent&&this.lastEvent.getDocumentPosition();(!this.range||!this.range.contains(T.row,T.column)||R||this.isOutsideOfText(this.lastEvent))&&this.hide()}this.timeout||R||(this.lastEvent=w,this.timeout=setTimeout(this.waitForHover,this.idleTime))},m.prototype.waitForHover=function(){this.timeout&&clearTimeout(this.timeout);var w=Date.now()-this.lastT;if(this.idleTime-w>10){this.timeout=setTimeout(this.waitForHover,this.idleTime-w);return}this.timeout=null,this.lastEvent&&!this.isOutsideOfText(this.lastEvent)&&this.$gatherData(this.lastEvent,this.lastEvent.editor)},m.prototype.isOutsideOfText=function(w){var x=w.editor,R=w.getDocumentPosition(),T=x.session.getLine(R.row);if(R.column==T.length){var _=x.renderer.pixelToScreenCoordinates(w.clientX,w.clientY),C=x.session.documentToScreenPosition(R.row,R.column);if(C.column!=_.column||C.row!=_.row)return!0}return!1},m.prototype.setDataProvider=function(w){this.$gatherData=w},m.prototype.showForRange=function(w,x,R,T){if(!(T&&T!=this.lastEvent)&&!(this.isOpen&&document.activeElement==this.getElement())){var _=w.renderer;this.isOpen||(d.addPopup(this),this.$registerCloseEvents(),this.setTheme(_.theme)),this.isOpen=!0,this.range=s.fromPoints(x.start,x.end);var C=_.textToScreenCoordinates(x.start.row,x.start.column),P=_.scroller.getBoundingClientRect();C.pageX<P.left&&(C.pageX=P.left);var O=this.getElement();O.innerHTML="",O.appendChild(R),O.style.maxHeight="",O.style.display="block",this.$setPosition(w,C,!0,x),v.$fixPositionBug(O)}},m.prototype.$setPosition=function(w,x,R,T){var _=10;R&&this.addMarker(T,w.session);var C=w.renderer,P=this.getElement(),O=P.offsetHeight,E=P.offsetWidth,k=x.pageY,B=x.pageX,N=window.innerHeight-k-C.lineHeight,M=this.$shouldPlaceAbove(O,k,N-_);P.style.maxHeight=(M?k:N)-_+"px",P.style.top=M?"":k+C.lineHeight+"px",P.style.bottom=M?window.innerHeight-k+"px":"",P.style.left=Math.min(B,window.innerWidth-E-_)+"px"},m.prototype.$shouldPlaceAbove=function(w,x,R){return!(x-w<0&&x<R)},m.prototype.addMarker=function(w,x){this.marker&&this.$markerSession.removeMarker(this.marker),this.$markerSession=x,this.marker=x&&x.addMarker(w,"ace_highlight-marker","text")},m.prototype.hide=function(w){w&&this.$fromKeyboard&&w.type=="keydown"&&w.code=="Escape"||!w&&document.activeElement==this.getElement()||w&&w.target&&(w.type!="keydown"||w.ctrlKey||w.metaKey)&&this.$element.contains(w.target)||(this.lastEvent=null,this.timeout&&clearTimeout(this.timeout),this.timeout=null,this.addMarker(null),this.isOpen&&(this.$fromKeyboard=!1,this.$removeCloseEvents(),this.getElement().style.display="none",this.isOpen=!1,d.removePopup(this)))},m.prototype.$registerCloseEvents=function(){window.addEventListener("keydown",this.hide,!0),window.addEventListener("wheel",this.hide,!0),window.addEventListener("mousedown",this.hide,!0)},m.prototype.$removeCloseEvents=function(){window.removeEventListener("keydown",this.hide,!0),window.removeEventListener("wheel",this.hide,!0),window.removeEventListener("mousedown",this.hide,!0)},m.prototype.onMouseOut=function(w){this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.lastEvent=null,this.isOpen&&(!w.relatedTarget||this.getElement().contains(w.relatedTarget)||w&&w.currentTarget.contains(w.relatedTarget)||w.relatedTarget.classList.contains("ace_content")||this.hide())},m})(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(t,r,c){var h=this&&this.__extends||(function(){var o=function(f,m){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(w,x){w.__proto__=x}||function(w,x){for(var R in x)Object.prototype.hasOwnProperty.call(x,R)&&(w[R]=x[R])},o(f,m)};return function(f,m){if(typeof m!="function"&&m!==null)throw new TypeError("Class extends value "+String(m)+" is not a constructor or null");o(f,m);function w(){this.constructor=f}f.prototype=m===null?Object.create(m):(w.prototype=m.prototype,new w)}})(),g=this&&this.__values||function(o){var f=typeof Symbol=="function"&&Symbol.iterator,m=f&&o[f],w=0;if(m)return m.call(o);if(o&&typeof o.length=="number")return{next:function(){return o&&w>=o.length&&(o=void 0),{value:o&&o[w++],done:!o}}};throw new TypeError(f?"Object is not iterable.":"Symbol.iterator is not defined.")},v=t("../lib/dom"),s=t("./mouse_event").MouseEvent,p=t("../tooltip").HoverTooltip,a=t("../config").nls,l=t("../range").Range;function u(o){var f=o.editor,m=f.renderer.$gutterLayer;o.$tooltip=new d(f),o.$tooltip.addToEditor(f),o.$tooltip.setDataProvider(function(w,x){var R=w.getDocumentPosition().row;o.$tooltip.showTooltip(R)}),o.editor.setDefaultHandler("guttermousedown",function(w){if(!(!f.isFocused()||w.getButton()!=0)){var x=m.getRegion(w);if(x!="foldWidgets"){var R=w.getDocumentPosition().row,T=f.session.selection;if(w.getShiftKey())T.selectTo(R,0);else{if(w.domEvent.detail==2)return f.selectAll(),w.preventDefault();o.$clickSelection=f.selection.getLineRange(R)}return o.setState("selectByLines"),o.captureMouse(w),w.preventDefault()}}})}r.GutterHandler=u;var d=(function(o){h(f,o);function f(m){var w=o.call(this,m.container)||this;w.id="gt"+ ++f.$uid,w.editor=m,w.visibleTooltipRow;var x=w.getElement();return x.setAttribute("role","tooltip"),x.setAttribute("id",w.id),x.style.pointerEvents="auto",w.idleTime=50,w.onDomMouseMove=w.onDomMouseMove.bind(w),w.onDomMouseOut=w.onDomMouseOut.bind(w),w.setClassName("ace_gutter-tooltip"),w}return f.prototype.onDomMouseMove=function(m){var w=new s(m,this.editor);this.onMouseMove(w,this.editor)},f.prototype.onDomMouseOut=function(m){var w=new s(m,this.editor);this.onMouseOut(w)},f.prototype.addToEditor=function(m){var w=m.renderer.$gutter;w.addEventListener("mousemove",this.onDomMouseMove),w.addEventListener("mouseout",this.onDomMouseOut),o.prototype.addToEditor.call(this,m)},f.prototype.removeFromEditor=function(m){var w=m.renderer.$gutter;w.removeEventListener("mousemove",this.onDomMouseMove),w.removeEventListener("mouseout",this.onDomMouseOut),o.prototype.removeFromEditor.call(this,m)},f.prototype.destroy=function(){this.editor&&this.removeFromEditor(this.editor),o.prototype.destroy.call(this)},Object.defineProperty(f,"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}),f.prototype.showTooltip=function(m){var w,x=this.editor.renderer.$gutterLayer,R=x.$annotations[m],T;R?T={displayText:Array.from(R.displayText),type:Array.from(R.type)}:T={displayText:[],type:[]};var _=x.session.getFoldLine(m);if(_&&x.$showFoldedAnnotations){for(var C={error:[],security:[],warning:[],info:[],hint:[]},P={error:1,security:2,warning:3,info:4,hint:5},O,E=m+1;E<=_.end.row;E++)if(x.$annotations[E])for(var k=0;k<x.$annotations[E].text.length;k++){var B=x.$annotations[E].type[k];C[B].push(x.$annotations[E].text[k]),(!O||P[B]<P[O])&&(O=B)}if(["error","security","warning"].includes(O)){var N="".concat(f.annotationsToSummaryString(C)," in folded code.");T.displayText.push(N),T.type.push(O+"_fold")}}if(T.displayText.length===0)return this.hide();for(var M={error:[],security:[],warning:[],info:[],hint:[]},$=x.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",E=0;E<T.displayText.length;E++){var A=v.createElement("span"),D=v.createElement("span");(w=D.classList).add.apply(w,["ace_".concat(T.type[E]),$]),D.setAttribute("aria-label","".concat(f.annotationLabels[T.type[E].replace("_fold","")].singular)),D.setAttribute("role","img"),D.appendChild(v.createTextNode(" ")),A.appendChild(D),A.appendChild(v.createTextNode(T.displayText[E])),A.appendChild(v.createElement("br")),M[T.type[E].replace("_fold","")].push(A)}var j=v.createElement("span");M.error.forEach(function(Q){return j.appendChild(Q)}),M.security.forEach(function(Q){return j.appendChild(Q)}),M.warning.forEach(function(Q){return j.appendChild(Q)}),M.info.forEach(function(Q){return j.appendChild(Q)}),M.hint.forEach(function(Q){return j.appendChild(Q)}),j.setAttribute("aria-live","polite");var U=this.$findLinkedAnnotationNode(m);U&&U.setAttribute("aria-describedby",this.id);var q=l.fromPoints({row:m,column:0},{row:m,column:0});this.showForRange(this.editor,q,j),this.visibleTooltipRow=m,this.editor._signal("showGutterTooltip",this)},f.prototype.$setPosition=function(m,w,x,R){var T=this.$findCellByRow(R.start.row);if(T){var _=T&&T.element,C=_&&_.querySelector(".ace_gutter_annotation");if(C){var P=C.getBoundingClientRect();if(P){var O={pageX:P.right,pageY:P.top};return o.prototype.$setPosition.call(this,m,O,!1,R)}}}},f.prototype.$shouldPlaceAbove=function(m,w,x){return x<m},f.prototype.$findLinkedAnnotationNode=function(m){var w=this.$findCellByRow(m);if(w){var x=w.element;if(x.childNodes.length>2)return x.childNodes[2]}},f.prototype.$findCellByRow=function(m){return this.editor.renderer.$gutterLayer.$lines.cells.find(function(w){return w.row===m})},f.prototype.hide=function(m){if(this.isOpen){if(this.$element.removeAttribute("aria-live"),this.visibleTooltipRow!=null){var w=this.$findLinkedAnnotationNode(this.visibleTooltipRow);w&&w.removeAttribute("aria-describedby")}this.visibleTooltipRow=void 0,this.editor._signal("hideGutterTooltip",this),o.prototype.hide.call(this,m)}},f.annotationsToSummaryString=function(m){var w,x,R=[],T=["error","security","warning","info","hint"];try{for(var _=g(T),C=_.next();!C.done;C=_.next()){var P=C.value;if(m[P].length){var O=m[P].length===1?f.annotationLabels[P].singular:f.annotationLabels[P].plural;R.push("".concat(m[P].length," ").concat(O))}}}catch(E){w={error:E}}finally{try{C&&!C.done&&(x=_.return)&&x.call(_)}finally{if(w)throw w.error}}return R.join(", ")},f.prototype.isOutsideOfText=function(m){var w=m.editor,x=w.renderer.$gutter.getBoundingClientRect();return!(m.clientX>=x.left&&m.clientX<=x.right&&m.clientY>=x.top&&m.clientY<=x.bottom)},f})(p);d.$uid=0,r.GutterTooltip=d}),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(t,r,c){var h=t("../lib/dom"),g=t("../lib/event"),v=t("../lib/useragent"),s=200,p=200,a=5;function l(d){var o=d.editor,f=h.createElement("div");f.style.cssText="top:-100px;position:absolute;z-index:2147483647;opacity:0.5",f.textContent=" ";var m=["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"];m.forEach(function(ne){d[ne]=this[ne]},this),o.on("mousedown",this.onMouseDown.bind(d));var w=o.container,x,R,T,_,C,P,O=0,E,k,B,N,M;this.onDragStart=function(ne){if(this.cancelDrag||!w.draggable){var ue=this;return setTimeout(function(){ue.startSelect(),ue.captureMouse(ne)},0),ne.preventDefault()}C=o.getSelectionRange();var he=ne.dataTransfer;he.effectAllowed=o.getReadOnly()?"copy":"copyMove",o.container.appendChild(f),he.setDragImage&&he.setDragImage(f,0,0),setTimeout(function(){o.container.removeChild(f)}),he.clearData(),he.setData("Text",o.session.getTextRange()),k=!0,this.setState("drag")},this.onDragEnd=function(ne){if(w.draggable=!1,k=!1,this.setState(null),!o.getReadOnly()){var ue=ne.dataTransfer.dropEffect;!E&&ue=="move"&&o.session.remove(o.getSelectionRange()),o.$resetCursorStyle()}this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(ne){if(!(o.getReadOnly()||!re(ne.dataTransfer)))return R=ne.clientX,T=ne.clientY,x||j(),O++,ne.dataTransfer.dropEffect=E=le(ne),g.preventDefault(ne)},this.onDragOver=function(ne){if(!(o.getReadOnly()||!re(ne.dataTransfer)))return R=ne.clientX,T=ne.clientY,x||(j(),O++),q!==null&&(q=null),ne.dataTransfer.dropEffect=E=le(ne),g.preventDefault(ne)},this.onDragLeave=function(ne){if(O--,O<=0&&x)return U(),E=null,g.preventDefault(ne)},this.onDrop=function(ne){if(P){var ue=ne.dataTransfer;if(k)switch(E){case"move":C.contains(P.row,P.column)?C={start:P,end:P}:C=o.moveText(C,P);break;case"copy":C=o.moveText(C,P,!0);break}else{var he=ue.getData("Text");C={start:P,end:o.session.insert(P,he)},o.focus(),E=null}return U(),g.preventDefault(ne)}},g.addListener(w,"dragstart",this.onDragStart.bind(d),o),g.addListener(w,"dragend",this.onDragEnd.bind(d),o),g.addListener(w,"dragenter",this.onDragEnter.bind(d),o),g.addListener(w,"dragover",this.onDragOver.bind(d),o),g.addListener(w,"dragleave",this.onDragLeave.bind(d),o),g.addListener(w,"drop",this.onDrop.bind(d),o);function $(ne,ue){var he=Date.now(),oe=!ue||ne.row!=ue.row,ee=!ue||ne.column!=ue.column;if(!N||oe||ee)o.moveCursorToPosition(ne),N=he,M={x:R,y:T};else{var ye=u(M.x,M.y,R,T);ye>a?N=null:he-N>=p&&(o.renderer.scrollCursorIntoView(),N=null)}}function A(ne,ue){var he=Date.now(),oe=o.renderer.layerConfig.lineHeight,ee=o.renderer.layerConfig.characterWidth,ye=o.renderer.scroller.getBoundingClientRect(),we={x:{left:R-ye.left,right:ye.right-R},y:{top:T-ye.top,bottom:ye.bottom-T}},Ae=Math.min(we.x.left,we.x.right),Je=Math.min(we.y.top,we.y.bottom),ze={row:ne.row,column:ne.column};Ae/ee<=2&&(ze.column+=we.x.left<we.x.right?-3:2),Je/oe<=1&&(ze.row+=we.y.top<we.y.bottom?-1:1);var Ye=ne.row!=ze.row,Ze=ne.column!=ze.column,at=!ue||ne.row!=ue.row;Ye||Ze&&!at?B?he-B>=s&&o.renderer.scrollCursorIntoView(ze):B=he:B=null}function D(){var ne=P;P=o.renderer.screenToTextCoordinates(R,T),$(P,ne),A(P,ne)}function j(){C=o.selection.toOrientedRange(),x=o.session.addMarker(C,"ace_selection",o.getSelectionStyle()),o.clearSelection(),o.isFocused()&&o.renderer.$cursorLayer.setBlinking(!1),clearInterval(_),D(),_=setInterval(D,20),O=0,g.addListener(document,"mousemove",Q)}function U(){clearInterval(_),o.session.removeMarker(x),x=null,o.selection.fromOrientedRange(C),o.isFocused()&&!k&&o.$resetCursorStyle(),C=null,P=null,O=0,B=null,N=null,g.removeListener(document,"mousemove",Q)}var q=null;function Q(){q==null&&(q=setTimeout(function(){q!=null&&x&&U()},20))}function re(ne){var ue=ne.types;return!ue||Array.prototype.some.call(ue,function(he){return he=="text/plain"||he=="Text"})}function le(ne){var ue=["copy","copymove","all","uninitialized"],he=["move","copymove","linkmove","all","uninitialized"],oe=v.isMac?ne.altKey:ne.ctrlKey,ee="uninitialized";try{ee=ne.dataTransfer.effectAllowed.toLowerCase()}catch{}var ye="none";return oe&&ue.indexOf(ee)>=0?ye="copy":he.indexOf(ee)>=0?ye="move":ue.indexOf(ee)>=0&&(ye="copy"),ye}}(function(){this.dragWait=function(){var d=Date.now()-this.mousedownEvent.time;d>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var d=this.editor.container;d.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(d){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var d=this.editor,o=d.container;o.draggable=!0,d.renderer.$cursorLayer.setBlinking(!1),d.setStyle("ace_dragging");var f=v.isWin?"default":"move";d.renderer.setCursorStyle(f),this.setState("dragReady")},this.onMouseDrag=function(d){var o=this.editor.container;if(v.isIE&&this.state=="dragReady"){var f=u(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);f>3&&o.dragDrop()}if(this.state==="dragWait"){var f=u(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);f>0&&(o.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(d){if(this.$dragEnabled){this.mousedownEvent=d;var o=this.editor,f=d.inSelection(),m=d.getButton(),w=d.domEvent.detail||1;if(w===1&&m===0&&f){if(d.editor.inMultiSelectMode&&(d.getAccelKey()||d.getShiftKey()))return;this.mousedownEvent.time=Date.now();var x=d.domEvent.target||d.domEvent.srcElement;if("unselectable"in x&&(x.unselectable="on"),o.getDragDelay()){if(v.isWebKit){this.cancelDrag=!0;var R=o.container;R.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(d,this.onMouseDrag.bind(this)),d.defaultPrevented=!0}}}}).call(l.prototype);function u(d,o,f,m){return Math.sqrt(Math.pow(f-d,2)+Math.pow(m-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(t,r,c){var h=t("./mouse_event").MouseEvent,g=t("../lib/event"),v=t("../lib/dom");r.addTouchListeners=function(s,p){var a="scroll",l,u,d,o,f,m,w=0,x,R=0,T=0,_=0,C,P;function O(){var $=window.navigator&&window.navigator.clipboard,A=!1,D=function(){var q=p.getCopyText(),Q=p.session.getUndoManager().hasUndo();P.replaceChild(v.buildDom(A?["span",!q&&j("selectall")&&["span",{class:"ace_mobile-button",action:"selectall"},"Select All"],q&&j("copy")&&["span",{class:"ace_mobile-button",action:"copy"},"Copy"],q&&j("cut")&&["span",{class:"ace_mobile-button",action:"cut"},"Cut"],$&&j("paste")&&["span",{class:"ace_mobile-button",action:"paste"},"Paste"],Q&&j("undo")&&["span",{class:"ace_mobile-button",action:"undo"},"Undo"],j("find")&&["span",{class:"ace_mobile-button",action:"find"},"Find"],j("openCommandPalette")&&["span",{class:"ace_mobile-button",action:"openCommandPalette"},"Palette"]]:["span"]),P.firstChild)},j=function(q){return p.commands.canExecute(q,p)},U=function(q){var Q=q.target.getAttribute("action");if(Q=="more"||!A)return A=!A,D();Q=="paste"?$.readText().then(function(re){p.execCommand(Q,re)}):Q&&((Q=="cut"||Q=="copy")&&($?$.writeText(p.getCopyText()):document.execCommand("copy")),p.execCommand(Q)),P.firstChild.style.display="none",A=!1,Q!="openCommandPalette"&&p.focus()};P=v.buildDom(["div",{class:"ace_mobile-menu",onclick:U},["span"],["span",{class:"ace_mobile-button",action:"more"},"..."]],p.container),P.addEventListener("touchstart",function(q){a="menu",q.stopPropagation(),q.preventDefault(),p.textInput.focus()}),P.addEventListener("touchend",function(q){q.stopPropagation(),q.preventDefault(),U(q)})}function E(){if(!p.getOption("enableMobileMenu")){P&&k();return}P||O();var $=p.selection.cursor,A=p.renderer.textToScreenCoordinates($.row,$.column),D=p.renderer.textToScreenCoordinates(0,0).pageX,j=p.renderer.scrollLeft,U=p.container.getBoundingClientRect();P.style.top=A.pageY-U.top-3+"px",A.pageX-U.left<U.width-70?(P.style.left="",P.style.right="10px"):(P.style.right="",P.style.left=D+j-U.left+"px"),P.style.display="",P.firstChild.style.display="none",p.on("input",k)}function k($){P&&(P.style.display="none"),p.off("input",k)}function B(){f=null,clearTimeout(f);var $=p.selection.getRange(),A=$.contains(x.row,x.column);($.isEmpty()||!A)&&(p.selection.moveToPosition(x),p.selection.selectWord()),a="wait",E()}function N(){f=null,clearTimeout(f),p.selection.moveToPosition(x);var $=R>=2?p.selection.getLineRange(x.row):p.session.getBracketRange(x);$&&!$.isEmpty()?p.selection.setRange($):p.selection.selectWord(),a="wait"}g.addListener(s,"contextmenu",function($){if(C){var A=p.textInput.getElement();A.focus()}},p),g.addListener(s,"touchstart",function($){var A=$.touches;if(f||A.length>1){clearTimeout(f),f=null,d=-1,a="zoom";return}C=p.$mouseHandler.isMousePressed=!0;var D=p.renderer.layerConfig.lineHeight,j=p.renderer.layerConfig.lineHeight,U=$.timeStamp;o=U;var q=A[0],Q=q.clientX,re=q.clientY;Math.abs(l-Q)+Math.abs(u-re)>D&&(d=-1),l=$.clientX=Q,u=$.clientY=re,T=_=0;var le=new h($,p);if(x=le.getDocumentPosition(),U-d<500&&A.length==1&&!w)R++,$.preventDefault(),$.button=0,N();else{R=0;var ne=p.selection.cursor,ue=p.selection.isEmpty()?ne:p.selection.anchor,he=p.renderer.$cursorLayer.getPixelPosition(ne,!0),oe=p.renderer.$cursorLayer.getPixelPosition(ue,!0),ee=p.renderer.scroller.getBoundingClientRect(),ye=p.renderer.layerConfig.offset,we=p.renderer.scrollLeft,Ae=function(Ye,Ze){return Ye=Ye/j,Ze=Ze/D-.75,Ye*Ye+Ze*Ze};if($.clientX<ee.left){a="zoom";return}var Je=Ae($.clientX-ee.left-he.left+we,$.clientY-ee.top-he.top+ye),ze=Ae($.clientX-ee.left-oe.left+we,$.clientY-ee.top-oe.top+ye);Je<3.5&&ze<3.5&&(a=Je>ze?"cursor":"anchor"),ze<3.5?a="anchor":Je<3.5?a="cursor":a="scroll",f=setTimeout(B,450)}d=U},p),g.addListener(s,"touchend",function($){C=p.$mouseHandler.isMousePressed=!1,m&&clearInterval(m),a=="zoom"?(a="",w=0):f?(p.selection.moveToPosition(x),w=0,E()):a=="scroll"?(M(),k()):E(),clearTimeout(f),f=null},p),g.addListener(s,"touchmove",function($){f&&(clearTimeout(f),f=null);var A=$.touches;if(!(A.length>1||a=="zoom")){var D=A[0],j=l-D.clientX,U=u-D.clientY;if(a=="wait")if(j*j+U*U>4)a="cursor";else return $.preventDefault();l=D.clientX,u=D.clientY,$.clientX=D.clientX,$.clientY=D.clientY;var q=$.timeStamp,Q=q-o;if(o=q,a=="scroll"){var re=new h($,p);re.speed=1,re.wheelX=j,re.wheelY=U,10*Math.abs(j)<Math.abs(U)&&(j=0),10*Math.abs(U)<Math.abs(j)&&(U=0),Q!=0&&(T=j/Q,_=U/Q),p._emit("mousewheel",re),re.propagationStopped||(T=_=0)}else{var le=new h($,p),ne=le.getDocumentPosition();a=="cursor"?p.selection.moveCursorToPosition(ne):a=="anchor"&&p.selection.setSelectionAnchor(ne.row,ne.column),p.renderer.scrollCursorIntoView(ne),$.preventDefault()}}},p);function M(){w+=60,m=setInterval(function(){w--<=0&&(clearInterval(m),m=null),Math.abs(T)<.01&&(T=0),Math.abs(_)<.01&&(_=0),w<20&&(T=.9*T),w<20&&(_=.9*_);var $=p.session.getScrollTop();p.renderer.scrollBy(10*T,10*_),$==p.session.getScrollTop()&&(w=0)},10)}}}),ace.define("ace/mouse/mouse_handler",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/mouse/default_handlers","ace/mouse/default_gutter_handler","ace/mouse/mouse_event","ace/mouse/dragdrop_handler","ace/mouse/touch_handler","ace/config"],function(t,r,c){var h=t("../lib/event"),g=t("../lib/useragent"),v=t("./default_handlers").DefaultHandlers,s=t("./default_gutter_handler").GutterHandler,p=t("./mouse_event").MouseEvent,a=t("./dragdrop_handler").DragdropHandler,l=t("./touch_handler").addTouchListeners,u=t("../config"),d=(function(){function o(f){this.$dragDelay,this.$dragEnabled,this.$mouseMoved,this.mouseEvent,this.$focusTimeout;var m=this;this.editor=f,new v(this),new s(this),new a(this);var w=function(T){var _=!document.hasFocus||!document.hasFocus()||!f.isFocused()&&document.activeElement==(f.textInput&&f.textInput.getElement());_&&window.focus(),f.focus(),setTimeout(function(){f.isFocused()||f.focus()})},x=f.renderer.getMouseEventTarget();h.addListener(x,"click",this.onMouseEvent.bind(this,"click"),f),h.addListener(x,"mousemove",this.onMouseMove.bind(this,"mousemove"),f),h.addMultiMouseDownListener([x,f.renderer.scrollBarV&&f.renderer.scrollBarV.inner,f.renderer.scrollBarH&&f.renderer.scrollBarH.inner,f.textInput&&f.textInput.getElement()].filter(Boolean),[400,300,250],this,"onMouseEvent",f),h.addMouseWheelListener(f.container,this.onMouseWheel.bind(this,"mousewheel"),f),l(f.container,f);var R=f.renderer.$gutter;h.addListener(R,"mousedown",this.onMouseEvent.bind(this,"guttermousedown"),f),h.addListener(R,"click",this.onMouseEvent.bind(this,"gutterclick"),f),h.addListener(R,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick"),f),h.addListener(R,"mousemove",this.onMouseEvent.bind(this,"guttermousemove"),f),h.addListener(x,"mousedown",w,f),h.addListener(R,"mousedown",w,f),g.isIE&&f.renderer.scrollBarV&&(h.addListener(f.renderer.scrollBarV.element,"mousedown",w,f),h.addListener(f.renderer.scrollBarH.element,"mousedown",w,f)),f.on("mousemove",function(T){if(!(m.state||m.$dragDelay||!m.$dragEnabled)){var _=f.renderer.screenToTextCoordinates(T.x,T.y),C=f.session.selection.getRange(),P=f.renderer;P.scroller.style.cursor!="crosshair"&&(!C.isEmpty()&&C.insideStart(_.row,_.column)?P.setCursorStyle("default"):P.setCursorStyle(""))}})}return o.prototype.onMouseEvent=function(f,m){this.editor.session&&this.editor._emit(f,new p(m,this.editor))},o.prototype.onMouseMove=function(f,m){var w=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;!w||!w.length||this.editor._emit(f,new p(m,this.editor))},o.prototype.onMouseWheel=function(f,m){var w=new p(m,this.editor);w.speed=this.$scrollSpeed*2,w.wheelX=m.wheelX,w.wheelY=m.wheelY,this.editor._emit(f,w)},o.prototype.setState=function(f){this.state=f},o.prototype.captureMouse=function(f,m){this.x=f.x,this.y=f.y,this.isMousePressed=!0;var w=this.editor,x=this.editor.renderer;x.$isMousePressed=!0;var R=this,T=!0,_=function(k){if(k){if(g.isWebKit&&!k.which&&R.releaseMouse)return R.releaseMouse();R.x=k.clientX,R.y=k.clientY,m&&m(k),R.mouseEvent=new p(k,R.editor),R.$mouseMoved=!0}},C=function(k){w.off("beforeEndOperation",E),T=!1,w.session&&P(),R[R.state+"End"]&&R[R.state+"End"](k),R.state="",R.isMousePressed=x.$isMousePressed=!1,x.$keepTextAreaAtCursor&&x.$moveTextAreaToCursor(),R.$onCaptureMouseMove=R.releaseMouse=null,k&&R.onMouseEvent("mouseup",k),w.endOperation()},P=function(){R[R.state]&&R[R.state](),R.$mouseMoved=!1},O=function(){T&&(P(),h.nextFrame(O))};if(g.isOldIE&&f.domEvent.type=="dblclick")return setTimeout(function(){C(f)});var E=function(k){R.releaseMouse&&w.curOp.command.name&&w.curOp.selectionChanged&&(R[R.state+"End"]&&R[R.state+"End"](),R.state="",R.releaseMouse())};w.on("beforeEndOperation",E),w.startOperation({command:{name:"mouse"}}),R.$onCaptureMouseMove=_,R.releaseMouse=h.capture(this.editor.container,_,C),O()},o.prototype.cancelContextMenu=function(){var f=(function(m){m&&m.domEvent&&m.domEvent.type!="contextmenu"||(this.editor.off("nativecontextmenu",f),m&&m.domEvent&&h.stopEvent(m.domEvent))}).bind(this);setTimeout(f,10),this.editor.on("nativecontextmenu",f)},o.prototype.destroy=function(){this.releaseMouse&&this.releaseMouse(),this.$tooltip&&this.$tooltip.destroy()},o})();d.prototype.releaseMouse=null,u.defineOptions(d.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:g.isMac?150:0},dragEnabled:{initialValue:!0},focusTimeout:{initialValue:0}}),r.MouseHandler=d}),ace.define("ace/mouse/fold_handler",["require","exports","module","ace/lib/dom"],function(t,r,c){var h=t("../lib/dom"),g=(function(){function v(s){s.on("click",function(p){var a=p.getDocumentPosition(),l=s.session,u=l.getFoldAt(a.row,a.column,1);u&&(p.getAccelKey()?l.removeFold(u):l.expandFold(u),p.stop());var d=p.domEvent&&p.domEvent.target;d&&h.hasCssClass(d,"ace_inline_button")&&h.hasCssClass(d,"ace_toggle_wrap")&&(l.setOption("wrap",!l.getUseWrapMode()),s.renderer.scrollCursorIntoView())}),s.on("gutterclick",function(p){var a=s.renderer.$gutterLayer.getRegion(p);if(a=="foldWidgets"){var l=p.getDocumentPosition().row,u=s.session;u.foldWidgets&&u.foldWidgets[l]&&s.session.onFoldWidgetClick(l,p),s.isFocused()||s.focus(),p.stop()}}),s.on("gutterdblclick",function(p){var a=s.renderer.$gutterLayer.getRegion(p);if(a=="foldWidgets"){var l=p.getDocumentPosition().row,u=s.session,d=u.getParentFoldRangeData(l,!0),o=d.range||d.firstRange;if(o){l=o.start.row;var f=u.getFoldAt(l,u.getLine(l).length,1);f?u.removeFold(f):(u.addFold("...",o),s.renderer.scrollCursorIntoView({row:o.start.row,column:0}))}p.stop()}})}return v})();r.FoldHandler=g}),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],function(t,r,c){var h=t("../lib/keys"),g=t("../lib/event"),v=(function(){function s(p){this.$editor=p,this.$data={editor:p},this.$handlers=[],this.setDefaultHandler(p.commands)}return s.prototype.setDefaultHandler=function(p){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=p,this.addKeyboardHandler(p,0)},s.prototype.setKeyboardHandler=function(p){var a=this.$handlers;if(a[a.length-1]!=p){for(;a[a.length-1]&&a[a.length-1]!=this.$defaultHandler;)this.removeKeyboardHandler(a[a.length-1]);this.addKeyboardHandler(p,1)}},s.prototype.addKeyboardHandler=function(p,a){if(p){typeof p=="function"&&!p.handleKeyboard&&(p.handleKeyboard=p);var l=this.$handlers.indexOf(p);l!=-1&&this.$handlers.splice(l,1),a==null?this.$handlers.push(p):this.$handlers.splice(a,0,p),l==-1&&p.attach&&p.attach(this.$editor)}},s.prototype.removeKeyboardHandler=function(p){var a=this.$handlers.indexOf(p);return a==-1?!1:(this.$handlers.splice(a,1),p.detach&&p.detach(this.$editor),!0)},s.prototype.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},s.prototype.getStatusText=function(){var p=this.$data,a=p.editor;return this.$handlers.map(function(l){return l.getStatusText&&l.getStatusText(a,p)||""}).filter(Boolean).join(" ")},s.prototype.$callKeyboardHandlers=function(p,a,l,u){for(var d,o=!1,f=this.$editor.commands,m=this.$handlers.length;m--&&(d=this.$handlers[m].handleKeyboard(this.$data,p,a,l,u),!(!(!d||!d.command)&&(d.command=="null"?o=!0:o=f.exec(d.command,this.$editor,d.args,u),o&&u&&p!=-1&&d.passEvent!=!0&&d.command.passEvent!=!0&&g.stopEvent(u),o))););return!o&&p==-1&&(d={command:"insertstring"},o=f.exec("insertstring",this.$editor,a)),o&&this.$editor._signal&&this.$editor._signal("keyboardActivity",d),o},s.prototype.onCommandKey=function(p,a,l){var u=h.keyCodeToString(l);return this.$callKeyboardHandlers(a,u,l,p)},s.prototype.onTextInput=function(p){return this.$callKeyboardHandlers(-1,p)},s})();r.KeyBinding=v}),ace.define("ace/lib/bidiutil",["require","exports","module"],function(t,r,c){var h=0,g=0,v=!1,s=!1,p=!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]],u=0,d=1,o=0,f=1,m=2,w=3,x=4,R=5,T=6,_=7,C=8,P=9,O=10,E=11,k=12,B=13,N=14,M=15,$=16,A=17,D=18,j=[D,D,D,D,D,D,D,D,D,T,R,T,C,R,D,D,D,D,D,D,D,D,D,D,D,D,D,D,R,R,R,T,C,x,x,E,E,E,x,x,x,x,x,O,P,O,P,P,m,m,m,m,m,m,m,m,m,m,P,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,D,D,D,D,D,D,R,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,P,x,E,E,E,E,x,x,x,x,o,x,x,D,x,x,E,E,m,m,x,o,x,x,x,m,o,x,x,x,x,x],U=[C,C,C,C,C,C,C,C,C,C,C,D,D,D,o,f,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,R,B,N,M,$,A,P,E,E,E,E,E,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,P,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 q(ne,ue,he,oe){var ee=h?l:a,ye=null,we=null,Ae=null,Je=0,ze=null,Ye=null,Ze=-1,at=null,ct=null,Ft=[];if(!oe)for(at=0,oe=[];at<he;at++)oe[at]=le(ne[at]);for(g=h,v=!1,s=!1,p=!1,ct=0;ct<he;ct++){if(ye=Je,Ft[ct]=we=re(ne,oe,Ft,ct),Je=ee[ye][we],ze=Je&240,Je&=15,ue[ct]=Ae=ee[Je][5],ze>0)if(ze==16){for(at=Ze;at<ct;at++)ue[at]=1;Ze=-1}else Ze=-1;if(Ye=ee[Je][6],Ye)Ze==-1&&(Ze=ct);else if(Ze>-1){for(at=Ze;at<ct;at++)ue[at]=Ae;Ze=-1}oe[ct]==R&&(ue[ct]=0),g|=Ae}if(p){for(at=0;at<he;at++)if(oe[at]==T){ue[at]=h;for(var Ie=at-1;Ie>=0&&oe[Ie]==C;Ie--)ue[Ie]=h}}}function Q(ne,ue,he){if(!(g<ne)){if(ne==1&&h==d&&!s){he.reverse();return}for(var oe=he.length,ee=0,ye,we,Ae,Je;ee<oe;){if(ue[ee]>=ne){for(ye=ee+1;ye<oe&&ue[ye]>=ne;)ye++;for(we=ee,Ae=ye-1;we<Ae;we++,Ae--)Je=he[we],he[we]=he[Ae],he[Ae]=Je;ee=ye}ee++}}}function re(ne,ue,he,oe){var ee=ue[oe],ye,we,Ae,Je;switch(ee){case o:case f:v=!1;case x:case w:return ee;case m:return v?w:m;case _:return v=!0,f;case C:return x;case P:return oe<1||oe+1>=ue.length||(ye=he[oe-1])!=m&&ye!=w||(we=ue[oe+1])!=m&&we!=w?x:(v&&(we=w),we==ye?we:x);case O:return ye=oe>0?he[oe-1]:R,ye==m&&oe+1<ue.length&&ue[oe+1]==m?m:x;case E:if(oe>0&&he[oe-1]==m)return m;if(v)return x;for(Je=oe+1,Ae=ue.length;Je<Ae&&ue[Je]==E;)Je++;return Je<Ae&&ue[Je]==m?m:x;case k:for(Ae=ue.length,Je=oe+1;Je<Ae&&ue[Je]==k;)Je++;if(Je<Ae){var ze=ne[oe],Ye=ze>=1425&&ze<=2303||ze==64286;if(ye=ue[Je],Ye&&(ye==f||ye==_))return f}return oe<1||(ye=ue[oe-1])==R?x:he[oe-1];case R:return v=!1,s=!0,h;case T:return p=!0,x;case B:case N:case $:case A:case M:v=!1;case D:return x}}function le(ne){var ue=ne.charCodeAt(0),he=ue>>8;return he==0?ue>191?o:j[ue]:he==5?/[\u0591-\u05f4]/.test(ne)?f:o:he==6?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(ne)?k:/[\u0660-\u0669\u066b-\u066c]/.test(ne)?w:ue==1642?E:/[\u06f0-\u06f9]/.test(ne)?m:_:he==32&&ue<=8287?U[ue&255]:he==254&&ue>=65136?_:x}r.L=o,r.R=f,r.EN=m,r.ON_R=3,r.AN=4,r.R_H=5,r.B=6,r.RLE=7,r.DOT="·",r.doBidiReorder=function(ne,ue,he){if(ne.length<2)return{};var oe=ne.split(""),ee=new Array(oe.length),ye=new Array(oe.length),we=[];h=he?d:u,q(oe,we,oe.length,ue);for(var Ae=0;Ae<ee.length;ee[Ae]=Ae,Ae++);Q(2,we,ee),Q(1,we,ee);for(var Ae=0;Ae<ee.length-1;Ae++)ue[Ae]===w?we[Ae]=r.AN:we[Ae]===f&&(ue[Ae]>_&&ue[Ae]<B||ue[Ae]===x||ue[Ae]===D)?we[Ae]=r.ON_R:Ae>0&&oe[Ae-1]==="ل"&&/\u0622|\u0623|\u0625|\u0627/.test(oe[Ae])&&(we[Ae-1]=we[Ae]=r.R_H,Ae++);oe[oe.length-1]===r.DOT&&(we[oe.length-1]=r.B),oe[0]==="‫"&&(we[0]=r.RLE);for(var Ae=0;Ae<ee.length;Ae++)ye[Ae]=we[ee[Ae]];return{logicalFromVisual:ee,bidiLevels:ye}},r.hasBidiCharacters=function(ne,ue){for(var he=!1,oe=0;oe<ne.length;oe++)ue[oe]=le(ne.charAt(oe)),!he&&(ue[oe]==f||ue[oe]==_||ue[oe]==w)&&(he=!0);return he},r.getVisualFromLogicalIdx=function(ne,ue){for(var he=0;he<ue.logicalFromVisual.length;he++)if(ue.logicalFromVisual[he]==ne)return he;return 0}}),ace.define("ace/bidihandler",["require","exports","module","ace/lib/bidiutil","ace/lib/lang"],function(t,r,c){var h=t("./lib/bidiutil");t("./lib/lang");var g=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\u202B]/,v=(function(){function s(p){this.session=p,this.bidiMap={},this.currentRow=null,this.bidiUtil=h,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=g.test(p.getValue())}return s.prototype.isBidiRow=function(p,a,l){return!!this.seenBidi},s.prototype.onChange=function(p){this.seenBidi?this.currentRow=null:p.action=="insert"&&g.test(p.lines.join(`
182
+ `))&&(this.seenBidi=!0,this.currentRow=null)},s.prototype.getDocumentRow=function(){var p=0,a=this.session.$screenRowCache;if(a.length){var l=this.session.$getRowCacheIndex(a,this.currentRow);l>=0&&(p=this.session.$docRowCache[l])}return p},s.prototype.getSplitIndex=function(){var p=0,a=this.session.$screenRowCache;if(a.length)for(var l,u=this.session.$getRowCacheIndex(a,this.currentRow);this.currentRow-p>0&&(l=this.session.$getRowCacheIndex(a,this.currentRow-p-1),l===u);)u=l,p++;else p=this.currentRow;return p},s.prototype.markAsDirty=function(){this.currentRow=null},s.prototype.setShowInvisibles=function(p){this.showInvisibles=p,this.currentRow=null},s.prototype.setEolChar=function(p){this.EOL=p},s.prototype.setContentWidth=function(p){this.contentWidth=p},s.prototype.isRtlLine=function(p){return this.$isRtl?!0:p!=null?this.session.getLine(p).charAt(0)==this.RLE:this.isRtlDir},s.prototype.setRtlDirection=function(p,a){for(var l=p.getCursorPosition(),u=p.selection.getSelectionAnchor().row;u<=l.row;u++)!a&&p.session.getLine(u).charAt(0)===p.session.$bidiHandler.RLE?p.session.doc.removeInLine(u,0,1):a&&p.session.getLine(u).charAt(0)!==p.session.$bidiHandler.RLE&&p.session.doc.insert({column:0,row:u},p.session.$bidiHandler.RLE)},s})();r.BidiHandler=v}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(t,r,c){var h=t("./lib/oop"),g=t("./lib/lang"),v=t("./lib/event_emitter").EventEmitter,s=t("./range").Range,p=(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 u=this;this.cursor.on("change",function(d){u.$cursorChanged=!0,u.$silent||u._emit("changeCursor"),!u.$isEmpty&&!u.$silent&&u._emit("changeSelection"),!u.$keepDesiredColumnOnChange&&d.old.column!=d.value.column&&(u.$desiredColumn=null)}),this.anchor.on("change",function(){u.$anchorChanged=!0,!u.$isEmpty&&!u.$silent&&u._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,u){this.$isEmpty=!1,this.anchor.setPosition(l,u)},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,u=this.lead;return l.row>u.row||l.row==u.row&&l.column>u.column},a.prototype.getRange=function(){var l=this.anchor,u=this.lead;return this.$isEmpty?s.fromPoints(u,u):this.isBackwards()?s.fromPoints(u,l):s.fromPoints(l,u)},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,u){var d=u?l.end:l.start,o=u?l.start:l.end;this.$setSelection(d.row,d.column,o.row,o.column)},a.prototype.$setSelection=function(l,u,d,o){if(!this.$silent){var f=this.$isEmpty,m=this.inMultiSelectMode;this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(l,u),this.cursor.setPosition(d,o),this.$isEmpty=!s.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||f!=this.$isEmpty||m)&&this._emit("changeSelection")}},a.prototype.$moveSelection=function(l){var u=this.lead;this.$isEmpty&&this.setSelectionAnchor(u.row,u.column),l.call(this)},a.prototype.selectTo=function(l,u){this.$moveSelection(function(){this.moveCursorTo(l,u)})},a.prototype.selectToPosition=function(l){this.$moveSelection(function(){this.moveCursorToPosition(l)})},a.prototype.moveTo=function(l,u){this.clearSelection(),this.moveCursorTo(l,u)},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,u){if(typeof u>"u"){var d=l||this.lead;l=d.row,u=d.column}return this.session.getWordRange(l,u)},a.prototype.selectWord=function(){this.setSelectionRange(this.getWordRange())},a.prototype.selectAWord=function(){var l=this.getCursor(),u=this.session.getAWordRange(l.row,l.column);this.setSelectionRange(u)},a.prototype.getLineRange=function(l,u){var d=typeof l=="number"?l:this.lead.row,o,f=this.session.getFoldLine(d);return f?(d=f.start.row,o=f.end.row):o=d,u===!0?new s(d,0,o,this.session.getLine(o).length):new s(d,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,u,d){var o=l.column,f=l.column+u;return d<0&&(o=l.column-u,f=l.column),this.session.isTabStop(l)&&this.doc.getLine(l.row).slice(o,f).split(" ").length-1==u},a.prototype.moveCursorLeft=function(){var l=this.lead.getPosition(),u;if(u=this.session.getFoldAt(l.row,l.column,-1))this.moveCursorTo(u.start.row,u.start.column);else if(l.column===0)l.row>0&&this.moveCursorTo(l.row-1,this.doc.getLine(l.row-1).length);else{var d=this.session.getTabSize();this.wouldMoveIntoSoftTab(l,d,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-d):this.moveCursorBy(0,-1)}},a.prototype.moveCursorRight=function(){var l=this.lead.getPosition(),u;if(u=this.session.getFoldAt(l.row,l.column,1))this.moveCursorTo(u.end.row,u.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 d=this.session.getTabSize(),l=this.lead;this.wouldMoveIntoSoftTab(l,d,1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,d):this.moveCursorBy(0,1)}},a.prototype.moveCursorLineStart=function(){var l=this.lead.row,u=this.lead.column,d=this.session.documentToScreenRow(l,u),o=this.session.screenToDocumentPosition(d,0),f=this.session.getDisplayLine(l,null,o.row,o.column),m=f.match(/^\s*/);m[0].length!=u&&!this.session.$useEmacsStyleLineStart&&(o.column+=m[0].length),this.moveCursorToPosition(o)},a.prototype.moveCursorLineEnd=function(){var l=this.lead,u=this.session.getDocumentLastRowColumnPosition(l.row,l.column);if(this.lead.column==u.column){var d=this.session.getLine(u.row);if(u.column==d.length){var o=d.search(/\s+$/);o>0&&(u.column=o)}}this.moveCursorTo(u.row,u.column)},a.prototype.moveCursorFileEnd=function(){var l=this.doc.getLength()-1,u=this.doc.getLine(l).length;this.moveCursorTo(l,u)},a.prototype.moveCursorFileStart=function(){this.moveCursorTo(0,0)},a.prototype.moveCursorLongWordRight=function(){var l=this.lead.row,u=this.lead.column,d=this.doc.getLine(l),o=d.substring(u);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var f=this.session.getFoldAt(l,u,1);if(f){this.moveCursorTo(f.end.row,f.end.column);return}if(this.session.nonTokenRe.exec(o)&&(u+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,o=d.substring(u)),u>=d.length){this.moveCursorTo(l,d.length),this.moveCursorRight(),l<this.doc.getLength()-1&&this.moveCursorWordRight();return}this.session.tokenRe.exec(o)&&(u+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(l,u)},a.prototype.moveCursorLongWordLeft=function(){var l=this.lead.row,u=this.lead.column,d;if(d=this.session.getFoldAt(l,u,-1)){this.moveCursorTo(d.start.row,d.start.column);return}var o=this.session.getFoldStringAt(l,u,-1);o==null&&(o=this.doc.getLine(l).substring(0,u));var f=g.stringReverse(o);if(this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.nonTokenRe.exec(f)&&(u-=this.session.nonTokenRe.lastIndex,f=f.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0),u<=0){this.moveCursorTo(l,0),this.moveCursorLeft(),l>0&&this.moveCursorWordLeft();return}this.session.tokenRe.exec(f)&&(u-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(l,u)},a.prototype.$shortWordEndIndex=function(l){var u=0,d,o=/\s/,f=this.session.tokenRe;if(f.lastIndex=0,this.session.tokenRe.exec(l))u=this.session.tokenRe.lastIndex;else{for(;(d=l[u])&&o.test(d);)u++;if(u<1){for(f.lastIndex=0;(d=l[u])&&!f.test(d);)if(f.lastIndex=0,u++,o.test(d))if(u>2){u--;break}else{for(;(d=l[u])&&o.test(d);)u++;if(u>2)break}}}return f.lastIndex=0,u},a.prototype.moveCursorShortWordRight=function(){var l=this.lead.row,u=this.lead.column,d=this.doc.getLine(l),o=d.substring(u),f=this.session.getFoldAt(l,u,1);if(f)return this.moveCursorTo(f.end.row,f.end.column);if(u==d.length){var m=this.doc.getLength();do l++,o=this.doc.getLine(l);while(l<m&&/^\s*$/.test(o));/^\s+/.test(o)||(o=""),u=0}var w=this.$shortWordEndIndex(o);this.moveCursorTo(l,u+w)},a.prototype.moveCursorShortWordLeft=function(){var l=this.lead.row,u=this.lead.column,d;if(d=this.session.getFoldAt(l,u,-1))return this.moveCursorTo(d.start.row,d.start.column);var o=this.session.getLine(l).substring(0,u);if(u===0){do l--,o=this.doc.getLine(l);while(l>0&&/^\s*$/.test(o));u=o.length,/\s+$/.test(o)||(o="")}var f=g.stringReverse(o),m=this.$shortWordEndIndex(f);return this.moveCursorTo(l,u-m)},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,u){var d=this.session.documentToScreenPosition(this.lead.row,this.lead.column),o,f=this.session.$fontMetrics,m=u===0&&l!==0&&f;if(u===0&&(m&&this.$desiredColumn==null&&(o=f.textWidth(d.row,d.column),isFinite(o)&&(this.$desiredColumn=o/f.config.characterWidth)),this.$desiredColumn?d.column=this.$desiredColumn:this.$desiredColumn=d.column),l!=0&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]){var w=this.session.lineWidgets[this.lead.row];l<0?l-=w.rowsAbove||0:l>0&&(l+=w.rowCount-(w.rowsAbove||0))}var x=d.row+l;if(m&&this.$desiredColumn!=null){o=this.$desiredColumn*f.config.characterWidth;var R=f.renderer&&f.renderer.$blockCursor;d.column=f.$pixelToColumn(x,d.column,o,R,!0)}var T=this.session.screenToDocumentPosition(x,d.column);this.moveCursorTo(T.row,T.column+u,u===0)},a.prototype.moveCursorToPosition=function(l){this.moveCursorTo(l.row,l.column)},a.prototype.moveCursorTo=function(l,u,d){var o=this.session.getFoldAt(l,u,1);o&&(l=o.start.row,u=o.start.column),this.$keepDesiredColumnOnChange=!0;var f=this.session.getLine(l);/[\uDC00-\uDFFF]/.test(f.charAt(u))&&f.charAt(u-1)&&(this.lead.row==l&&this.lead.column==u+1?u=u-1:u=u+1),this.lead.setPosition(l,u),this.$keepDesiredColumnOnChange=!1,d||(this.$desiredColumn=null)},a.prototype.moveCursorToScreen=function(l,u,d){var o=this.session.screenToDocumentPosition(l,u);this.moveCursorTo(o.row,o.column,d)},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 u=this.getRange();return l?(l.start.column=u.start.column,l.start.row=u.start.row,l.end.column=u.end.column,l.end.row=u.end.row):l=u,l.cursor=this.isBackwards()?l.start:l.end,l.desiredColumn=this.$desiredColumn,l},a.prototype.getRangeOfMovements=function(l){var u=this.getCursor();try{l(this);var d=this.getCursor();return s.fromPoints(u,d)}catch{return s.fromPoints(u,u)}finally{this.moveCursorToPosition(u)}},a.prototype.toJSON=function(){if(this.rangeCount)var l=this.ranges.map(function(u){var d=u.clone();return d.isBackwards=u.cursor==u.start,d});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 u=l.length;u--;){var d=s.fromPoints(l[u].start,l[u].end);l[u].isBackwards&&(d.cursor=d.start),this.addRange(d,!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 u=this.ranges.length;u--;)if(!this.ranges[u].isEqual(l[u]))return!1;return!0},a})();p.prototype.setSelectionAnchor=p.prototype.setAnchor,p.prototype.getSelectionAnchor=p.prototype.getAnchor,p.prototype.setSelectionRange=p.prototype.setRange,h.implement(p.prototype,v),r.Selection=p}),ace.define("ace/tokenizer",["require","exports","module","ace/lib/report_error"],function(t,r,c){var h=t("./lib/report_error").reportError,g=2e3,v=(function(){function s(p){this.splitRegex,this.states=p,this.regExps={},this.matchMappings={};for(var a in this.states){for(var l=this.states[a],u=[],d=0,o=this.matchMappings[a]={defaultToken:"text"},f="g",m=[],w=0;w<l.length;w++){var x=l[w];if(x.defaultToken&&(o.defaultToken=x.defaultToken),x.caseInsensitive&&f.indexOf("i")===-1&&(f+="i"),x.unicode&&f.indexOf("u")===-1&&(f+="u"),x.regex!=null){x.regex instanceof RegExp&&(x.regex=x.regex.toString().slice(1,-1));var R=x.regex,T=new RegExp("(?:("+R+")|(.))").exec("a").length-2;Array.isArray(x.token)?x.token.length==1||T==1?x.token=x.token[0]:T-1!=x.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:x,groupCount:T-1}),x.token=x.token[0]):(x.tokenArray=x.token,x.token=null,x.onMatch=this.$arrayTokens):typeof x.token=="function"&&!x.onMatch&&(T>1?x.onMatch=this.$applyToken:x.onMatch=x.token),T>1&&(/\\\d/.test(x.regex)?R=x.regex.replace(/\\([0-9]+)/g,function(_,C){return"\\"+(parseInt(C,10)+d+1)}):(T=1,R=this.removeCapturingGroups(x.regex)),!x.splitRegex&&typeof x.token!="string"&&m.push(x)),o[d]=w,d+=T,u.push(R),x.onMatch||(x.onMatch=null)}}u.length||(o[0]=0,u.push("$")),m.forEach(function(_){_.splitRegex=this.createSplitterRegexp(_.regex,f)},this),this.regExps[a]=new RegExp("("+u.join(")|(")+")|($)",f)}}return s.prototype.$setMaxTokenCount=function(p){g=p|0},s.prototype.$applyToken=function(p){var a=this.splitRegex.exec(p).slice(1),l=this.token.apply(this,a);if(typeof l=="string")return[{type:l,value:p}];for(var u=[],d=0,o=l.length;d<o;d++)a[d]&&(u[u.length]={type:l[d],value:a[d]});return u},s.prototype.$arrayTokens=function(p){if(!p)return[];var a=this.splitRegex.exec(p);if(!a)return"text";for(var l=[],u=this.tokenArray,d=0,o=u.length;d<o;d++)a[d+1]&&(l[l.length]={type:u[d],value:a[d+1]});return l},s.prototype.removeCapturingGroups=function(p){var a=p.replace(/\\.|\[(?:\\.|[^\\\]])*|\(\?[:=!<]|(\()/g,function(l,u){return u?"(?:":l});return a},s.prototype.createSplitterRegexp=function(p,a){if(p.indexOf("(?=")!=-1){var l=0,u=!1,d={};p.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,function(C,P,O,E,k,B){return u?u=k!="]":k?u=!0:E?(l==d.stack&&(d.end=B+1,d.stack=-1),l--):O&&(l++,O.length!=1&&(d.stack=l,d.start=B)),C}),d.end!=null&&/^\)*$/.test(p.substr(d.end))&&(p=p.substring(0,d.start)+p.substr(d.end))}for(var o;o=/^(?:\((?:\?:)?)*\(\?<[=!]/.exec(p);){var f=o[0].length-4,m=-1,w=0,x=!1,R=/\\.|[\[\]()]/g;R.lastIndex=f;for(var T;T=R.exec(p);){var _=T[0];if(!(_.length>1)){if(x)x=_!="]";else if(_=="[")x=!0;else if(_=="(")w++;else if(_==")"&&--w==0){m=T.index+1;break}}}if(m==-1)break;p=p.substring(0,f)+p.substr(m)}return p.charAt(0)!="^"&&(p="^"+p),p.charAt(p.length-1)!="$"&&(p+="$"),new RegExp(p,(a||"").replace("g",""))},s.prototype.getLineTokens=function(p,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 u=a||"start",d=this.states[u];d||(u="start",d=this.states[u]);var o=this.matchMappings[u],f=this.regExps[u];f.lastIndex=0;for(var m,w=[],x=0,R=0,T={type:null,value:""};m=f.exec(p);){var _=o.defaultToken,C=null,P=m[0],O=f.lastIndex;if(O-P.length>x){var E=p.substring(x,O-P.length);T.type==_?T.value+=E:(T.type&&w.push(T),T={type:_,value:E})}for(var k=0;k<m.length-2;k++)if(m[k+1]!==void 0){C=d[o[k]],C.onMatch?_=C.onMatch(P,u,l,p):_=C.token,C.next&&(typeof C.next=="string"?u=C.next:u=C.next(u,l),d=this.states[u],d||(this.reportError("state doesn't exist",u),u="start",d=this.states[u]),o=this.matchMappings[u],x=O,f=this.regExps[u],f.lastIndex=O),C.consumeLineEnd&&(x=O);break}if(P){if(typeof _=="string")(!C||C.merge!==!1)&&T.type===_?T.value+=P:(T.type&&w.push(T),T={type:_,value:P});else if(_){T.type&&w.push(T),T={type:null,value:""};for(var k=0;k<_.length;k++)w.push(_[k])}}if(x==p.length)break;if(x=O,R++>g){for(R>2*p.length&&this.reportError("infinite loop with in ace tokenizer",{startState:a,line:p});x<p.length;)T.type&&w.push(T),T={value:p.substring(x,x+=500),type:"overflow"};u="start",l=[];break}}return T.type&&w.push(T),l.length>1&&l[0]!==u&&l.unshift("#tmp",u),{tokens:w,state:l.length?l:u}},s})();v.prototype.reportError=h,r.Tokenizer=v}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/deep_copy"],function(t,r,c){var h=t("../lib/deep_copy").deepCopy,g;g=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}},(function(){this.addRules=function(p,a){if(!a){for(var l in p)this.$rules[l]=p[l];return}for(var l in p){for(var u=p[l],d=0;d<u.length;d++){var o=u[d];(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]=u}},this.getRules=function(){return this.$rules},this.embedRules=function(p,a,l,u,d){var o=typeof p=="function"?new p().getRules():p;if(u)for(var f=0;f<u.length;f++)u[f]=a+u[f];else{u=[];for(var m in o)u.push(a+m)}if(this.addRules(o,a),l)for(var w=Array.prototype[d?"push":"unshift"],f=0;f<u.length;f++)w.apply(this.$rules[u[f]],h(l));this.$embeds||(this.$embeds=[]),this.$embeds.push(a)},this.getEmbeds=function(){return this.$embeds};var v=function(p,a){return(p!="start"||a.length)&&a.unshift(this.nextState,p),this.nextState},s=function(p,a){return a.shift(),a.shift()||"start"};this.normalizeRules=function(){var p=0,a=this.$rules;function l(u){var d=a[u];d.processed=!0;for(var o=0;o<d.length;o++){var f=d[o],m=null;Array.isArray(f)&&(m=f,f={}),!f.regex&&f.start&&(f.regex=f.start,f.next||(f.next=[]),f.next.push({defaultToken:f.token},{token:f.token+".end",regex:f.end||f.start,next:"pop"}),f.token=f.token+".start",f.push=!0);var w=f.next||f.push;if(w&&Array.isArray(w)){var x=f.stateName;x||(x=f.token,typeof x!="string"&&(x=x[0]||""),a[x]&&(x+=p++)),a[x]=w,f.next=x,l(x)}else w=="pop"&&(f.next=s);if(f.push&&(f.nextState=f.next||f.push,f.next=v,delete f.push),f.rules)for(var R in f.rules)a[R]?a[R].push&&a[R].push.apply(a[R],f.rules[R]):a[R]=f.rules[R];var T=typeof f=="string"?f:f.include;if(T&&(T==="$self"&&(T="start"),Array.isArray(T)?m=T.map(function(C){return a[C]}):m=a[T]),m){var _=[o,1].concat(m);f.noEscape&&(_=_.filter(function(C){return!C.next})),d.splice.apply(d,_),o--}f.keywordMap&&(f.token=this.createKeywordMapper(f.keywordMap,f.defaultToken||"text",f.caseInsensitive),delete f.defaultToken)}}Object.keys(a).forEach(l,this)},this.createKeywordMapper=function(p,a,l,u){var d=Object.create(null);return this.$keywordList=[],Object.keys(p).forEach(function(o){for(var f=p[o],m=f.split(u||"|"),w=m.length;w--;){var x=m[w];this.$keywordList.push(x),l&&(x=x.toLowerCase()),d[x]=o}},this),p=null,l?function(o){return d[o.toLowerCase()]||a}:function(o){return d[o]||a}},this.getKeywords=function(){return this.$keywords}}).call(g.prototype),r.TextHighlightRules=g}),ace.define("ace/mode/behaviour",["require","exports","module"],function(t,r,c){var h;h=function(){this.$behaviours={}},(function(){this.add=function(g,v,s){switch(void 0){case this.$behaviours:this.$behaviours={};case this.$behaviours[g]:this.$behaviours[g]={}}this.$behaviours[g][v]=s},this.addBehaviours=function(g){for(var v in g)for(var s in g[v])this.add(v,s,g[v][s])},this.remove=function(g){this.$behaviours&&this.$behaviours[g]&&delete this.$behaviours[g]},this.inherit=function(g,v){if(typeof g=="function")var s=new g().getBehaviours(v);else var s=g.getBehaviours(v);this.addBehaviours(s)},this.getBehaviours=function(g){if(g){for(var v={},s=0;s<g.length;s++)this.$behaviours[g[s]]&&(v[g[s]]=this.$behaviours[g[s]]);return v}else return this.$behaviours}}).call(h.prototype),r.Behaviour=h}),ace.define("ace/token_iterator",["require","exports","module","ace/range"],function(t,r,c){var h=t("./range").Range,g=(function(){function v(s,p,a){this.$session=s,this.$row=p,this.$rowTokens=s.getTokens(p);var l=s.getTokenAt(p,a);this.$tokenIndex=l?l.index:-1}return v.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]},v.prototype.stepForward=function(){this.$tokenIndex+=1;for(var s;this.$tokenIndex>=this.$rowTokens.length;){if(this.$row+=1,s||(s=this.$session.getLength()),this.$row>=s)return this.$row=s-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},v.prototype.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},v.prototype.getCurrentTokenRow=function(){return this.$row},v.prototype.getCurrentTokenColumn=function(){var s=this.$rowTokens,p=this.$tokenIndex,a=s[p].start;if(a!==void 0)return a;for(a=0;p>0;)p-=1,a+=s[p].value.length;return a},v.prototype.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},v.prototype.getCurrentTokenRange=function(){var s=this.$rowTokens[this.$tokenIndex],p=this.getCurrentTokenColumn();return new h(this.$row,p,this.$row,p+s.value.length)},v})();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(t,r,c){var h=t("../../lib/oop"),g=t("../behaviour").Behaviour,v=t("../../token_iterator").TokenIterator,s=t("../../lib/lang"),p=["text","paren.rparen","rparen","paren","punctuation.operator"],a=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],l,u={},d={'"':'"',"'":"'"},o=function(w){var x=-1;if(w.multiSelect&&(x=w.selection.index,u.rangeCount!=w.multiSelect.rangeCount&&(u={rangeCount:w.multiSelect.rangeCount})),u[x])return l=u[x];l=u[x]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},f=function(w,x,R,T){var _=w.end.row-w.start.row;return{text:R+x+T,selection:[0,w.start.column+1,_,w.end.column+(_?0:1)]}},m;m=function(w){w=w||{},this.add("braces","insertion",function(x,R,T,_,C){var P=T.getCursorPosition(),O=_.doc.getLine(P.row);if(C=="{"){o(T);var E=T.getSelectionRange(),k=_.doc.getTextRange(E),B=_.getTokenAt(P.row,P.column);if(k!==""&&k!=="{"&&T.getWrapBehavioursEnabled())return f(E,k,"{","}");if(B&&/(?:string)\.quasi|\.xml/.test(B.type)){var N=[/tag\-(?:open|name)/,/attribute\-name/];return N.some(function(q){return q.test(B.type)})||/(string)\.quasi/.test(B.type)&&B.value[P.column-B.start-1]!=="$"?void 0:(m.recordAutoInsert(T,_,"}"),{text:"{}",selection:[1,1]})}else if(m.isSaneInsertion(T,_))return/[\]\}\)]/.test(O[P.column])||T.inMultiSelectMode||w.braces?(m.recordAutoInsert(T,_,"}"),{text:"{}",selection:[1,1]}):(m.recordMaybeInsert(T,_,"{"),{text:"{",selection:[1,1]})}else if(C=="}"){o(T);var M=O.substring(P.column,P.column+1);if(M=="}"){var $=_.$findOpeningBracket("}",{column:P.column+1,row:P.row});if($!==null&&m.isAutoInsertedClosing(P,O,C))return m.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}else if(C==`
183
+ `||C==`\r
184
+ `){o(T);var A="";m.isMaybeInsertedClosing(P,O)&&(A=s.stringRepeat("}",l.maybeInsertedBrackets),m.clearMaybeInsertedClosing());var M=O.substring(P.column,P.column+1);if(M==="}"){var D=_.findMatchingBracket({row:P.row,column:P.column+1},"}");if(!D)return null;var j=this.$getIndent(_.getLine(D.row))}else if(A)var j=this.$getIndent(O);else{m.clearMaybeInsertedClosing();return}var U=j+_.getTabString();return{text:`
185
+ `+U+`
186
+ `+j+A,selection:[1,U.length,1,U.length]}}else m.clearMaybeInsertedClosing()}),this.add("braces","deletion",function(x,R,T,_,C){var P=_.doc.getTextRange(C);if(!C.isMultiLine()&&P=="{"){o(T);var O=_.doc.getLine(C.start.row),E=O.substring(C.end.column,C.end.column+1);if(E=="}")return C.end.column++,C;l.maybeInsertedBrackets--}}),this.add("parens","insertion",function(x,R,T,_,C){if(C=="("){o(T);var P=T.getSelectionRange(),O=_.doc.getTextRange(P);if(O!==""&&T.getWrapBehavioursEnabled())return f(P,O,"(",")");if(m.isSaneInsertion(T,_))return m.recordAutoInsert(T,_,")"),{text:"()",selection:[1,1]}}else if(C==")"){o(T);var E=T.getCursorPosition(),k=_.doc.getLine(E.row),B=k.substring(E.column,E.column+1);if(B==")"){var N=_.$findOpeningBracket(")",{column:E.column+1,row:E.row});if(N!==null&&m.isAutoInsertedClosing(E,k,C))return m.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("parens","deletion",function(x,R,T,_,C){var P=_.doc.getTextRange(C);if(!C.isMultiLine()&&P=="("){o(T);var O=_.doc.getLine(C.start.row),E=O.substring(C.start.column+1,C.start.column+2);if(E==")")return C.end.column++,C}}),this.add("brackets","insertion",function(x,R,T,_,C){if(C=="["){o(T);var P=T.getSelectionRange(),O=_.doc.getTextRange(P);if(O!==""&&T.getWrapBehavioursEnabled())return f(P,O,"[","]");if(m.isSaneInsertion(T,_))return m.recordAutoInsert(T,_,"]"),{text:"[]",selection:[1,1]}}else if(C=="]"){o(T);var E=T.getCursorPosition(),k=_.doc.getLine(E.row),B=k.substring(E.column,E.column+1);if(B=="]"){var N=_.$findOpeningBracket("]",{column:E.column+1,row:E.row});if(N!==null&&m.isAutoInsertedClosing(E,k,C))return m.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("brackets","deletion",function(x,R,T,_,C){var P=_.doc.getTextRange(C);if(!C.isMultiLine()&&P=="["){o(T);var O=_.doc.getLine(C.start.row),E=O.substring(C.start.column+1,C.start.column+2);if(E=="]")return C.end.column++,C}}),this.add("string_dquotes","insertion",function(x,R,T,_,C){var P=_.$mode.$quotes||d;if(C.length==1&&P[C]){if(this.lineCommentStart&&this.lineCommentStart.indexOf(C)!=-1)return;o(T);var O=C,E=T.getSelectionRange(),k=_.doc.getTextRange(E);if(k!==""&&(k.length!=1||!P[k])&&T.getWrapBehavioursEnabled())return f(E,k,O,O);if(!k){var B=T.getCursorPosition(),N=_.doc.getLine(B.row),M=N.substring(B.column-1,B.column),$=N.substring(B.column,B.column+1),A=_.getTokenAt(B.row,B.column),D=_.getTokenAt(B.row,B.column+1);if(M=="\\"&&A&&/escape/.test(A.type))return null;var j=A&&/string|escape/.test(A.type),U=!D||/string|escape/.test(D.type),q;if($==O)q=j!==U,q&&/string\.end/.test(D.type)&&(q=!1);else{if(j&&!U||j&&U)return null;var Q=_.$mode.tokenRe;Q.lastIndex=0;var re=Q.test(M);Q.lastIndex=0;var le=Q.test($),ne=_.$mode.$pairQuotesAfter,ue=ne&&ne[O]&&ne[O].test(M);if(!ue&&re||le||$&&!/[\s;,.})\]\\]/.test($))return null;var he=N[B.column-2];if(M==O&&(he==O||Q.test(he)))return null;q=!0}return{text:q?O+O:"",selection:[1,1]}}}}),this.add("string_dquotes","deletion",function(x,R,T,_,C){var P=_.$mode.$quotes||d,O=_.doc.getTextRange(C);if(!C.isMultiLine()&&P.hasOwnProperty(O)){o(T);var E=_.doc.getLine(C.start.row),k=E.substring(C.start.column+1,C.start.column+2);if(k==O)return C.end.column++,C}}),w.closeDocComment!==!1&&this.add("doc comment end","insertion",function(x,R,T,_,C){if(x==="doc-start"&&(C===`
187
+ `||C===`\r
188
+ `)&&T.selection.isEmpty()){var P=T.getCursorPosition();if(P.column===0)return;for(var O=_.doc.getLine(P.row),E=_.doc.getLine(P.row+1),k=_.getTokens(P.row),B=0,N=0;N<k.length;N++){B+=k[N].value.length;var M=k[N];if(B>=P.column){if(B===P.column){if(!/\.doc/.test(M.type))return;if(/\*\//.test(M.value)){var $=k[N+1];if(!$||!/\.doc/.test($.type))return}}var A=P.column-(B-M.value.length),D=M.value.indexOf("*/"),j=M.value.indexOf("/**",D>-1?D+2:0);if(j!==-1&&A>j&&A<j+3||D!==-1&&j!==-1&&A>=D&&A<=j||!/\.doc/.test(M.type))return;break}}var U=this.$getIndent(O);if(/\s*\*/.test(E))return/^\s*\*/.test(O)?{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(O.substring(0,P.column)))return{text:C+U+" * "+C+" "+U+"*/",selection:[1,4+U.length,1,4+U.length]}}})},m.isSaneInsertion=function(w,x){var R=w.getCursorPosition(),T=new v(x,R.row,R.column);if(!this.$matchTokenType(T.getCurrentToken()||"text",p)){if(/[)}\]]/.test(w.session.getLine(R.row)[R.column]))return!0;var _=new v(x,R.row,R.column+1);if(!this.$matchTokenType(_.getCurrentToken()||"text",p))return!1}return T.stepForward(),T.getCurrentTokenRow()!==R.row||this.$matchTokenType(T.getCurrentToken()||"text",a)},m.$matchTokenType=function(w,x){return x.indexOf(w.type||w)>-1},m.recordAutoInsert=function(w,x,R){var T=w.getCursorPosition(),_=x.doc.getLine(T.row);this.isAutoInsertedClosing(T,_,l.autoInsertedLineEnd[0])||(l.autoInsertedBrackets=0),l.autoInsertedRow=T.row,l.autoInsertedLineEnd=R+_.substr(T.column),l.autoInsertedBrackets++},m.recordMaybeInsert=function(w,x,R){var T=w.getCursorPosition(),_=x.doc.getLine(T.row);this.isMaybeInsertedClosing(T,_)||(l.maybeInsertedBrackets=0),l.maybeInsertedRow=T.row,l.maybeInsertedLineStart=_.substr(0,T.column)+R,l.maybeInsertedLineEnd=_.substr(T.column),l.maybeInsertedBrackets++},m.isAutoInsertedClosing=function(w,x,R){return l.autoInsertedBrackets>0&&w.row===l.autoInsertedRow&&R===l.autoInsertedLineEnd[0]&&x.substr(w.column)===l.autoInsertedLineEnd},m.isMaybeInsertedClosing=function(w,x){return l.maybeInsertedBrackets>0&&w.row===l.maybeInsertedRow&&x.substr(w.column)===l.maybeInsertedLineEnd&&x.substr(0,w.column)==l.maybeInsertedLineStart},m.popAutoInsertedClosing=function(){l.autoInsertedLineEnd=l.autoInsertedLineEnd.substr(1),l.autoInsertedBrackets--},m.clearMaybeInsertedClosing=function(){l&&(l.maybeInsertedBrackets=0,l.maybeInsertedRow=-1)},h.inherits(m,g),r.CstyleBehaviour=m}),ace.define("ace/unicode",["require","exports","module"],function(t,r,c){for(var h=[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,v=[],s=0;s<h.length;s+=2)v.push(g+=h[s]),h[s+1]&&v.push(45,g+=h[s+1]);r.wordChars=String.fromCharCode.apply(null,v)}),ace.define("ace/mode/text",["require","exports","module","ace/config","ace/tokenizer","ace/mode/text_highlight_rules","ace/mode/behaviour/cstyle","ace/unicode","ace/lib/lang","ace/token_iterator","ace/range"],function(t,r,c){var h=t("../config"),g=t("../tokenizer").Tokenizer,v=t("./text_highlight_rules").TextHighlightRules,s=t("./behaviour/cstyle").CstyleBehaviour,p=t("../unicode"),a=t("../lib/lang"),l=t("../token_iterator").TokenIterator,u=t("../range").Range,d;d=function(){this.HighlightRules=v},(function(){this.$defaultBehaviour=new s,this.tokenRe=new RegExp("^["+p.wordChars+"\\$_]+","g"),this.nonTokenRe=new RegExp("^(?:[^"+p.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,f,m,w){var x=f.doc,R=!0,T=!0,_=1/0,C=f.getTabSize(),P=!1;if(this.lineCommentStart){if(Array.isArray(this.lineCommentStart))var O=this.lineCommentStart.map(a.escapeRegExp).join("|"),E=this.lineCommentStart[0];else var O=a.escapeRegExp(this.lineCommentStart),E=this.lineCommentStart;O=new RegExp("^(\\s*)(?:"+O+") ?"),P=f.getUseSoftTabs();var k=function(q,Q){var re=q.match(O);if(re){var le=re[1].length,ne=re[0].length;!$(q,le,ne)&&re[0][ne-1]==" "&&ne--,x.removeInLine(Q,le,ne)}},B=E+" ",N=function(q,Q){(!R||/\S/.test(q))&&($(q,_,_)?x.insertInLine({row:Q,column:_},B):x.insertInLine({row:Q,column:_},E))},M=function(q,Q){return O.test(q)},$=function(q,Q,re){for(var le=0;Q--&&q.charAt(Q)==" ";)le++;if(le%C!=0)return!1;for(var le=0;q.charAt(re++)==" ";)le++;return C>2?le%C!=C-1:le%C==0}}else{if(!this.blockComment)return!1;var E=this.blockComment.start,A=this.blockComment.end,O=new RegExp("^(\\s*)(?:"+a.escapeRegExp(E)+")"),D=new RegExp("(?:"+a.escapeRegExp(A)+")\\s*$"),N=function(ue,he){M(ue,he)||(!R||/\S/.test(ue))&&(x.insertInLine({row:he,column:ue.length},A),x.insertInLine({row:he,column:_},E))},k=function(ue,he){var oe;(oe=ue.match(D))&&x.removeInLine(he,ue.length-oe[0].length,ue.length),(oe=ue.match(O))&&x.removeInLine(he,oe[1].length,oe[0].length)},M=function(ue,he){if(O.test(ue))return!0;for(var oe=f.getTokens(he),ee=0;ee<oe.length;ee++)if(oe[ee].type==="comment")return!0}}function j(q){for(var Q=m;Q<=w;Q++)q(x.getLine(Q),Q)}var U=1/0;j(function(q,Q){var re=q.search(/\S/);re!==-1?(re<_&&(_=re),T&&!M(q,Q)&&(T=!1)):U>q.length&&(U=q.length)}),_==1/0&&(_=U,R=!1,T=!1),P&&_%C!=0&&(_=Math.floor(_/C)*C),j(T?k:N)},this.toggleBlockComment=function(o,f,m,w){var x=this.blockComment;if(x){!x.start&&x[0]&&(x=x[0]);var R=new l(f,w.row,w.column),T=R.getCurrentToken();f.selection;var _=f.selection.toOrientedRange(),C,P;if(T&&/comment/.test(T.type)){for(var O,E;T&&/comment/.test(T.type);){var k=T.value.indexOf(x.start);if(k!=-1){var B=R.getCurrentTokenRow(),N=R.getCurrentTokenColumn()+k;O=new u(B,N,B,N+x.start.length);break}T=R.stepBackward()}for(var R=new l(f,w.row,w.column),T=R.getCurrentToken();T&&/comment/.test(T.type);){var k=T.value.indexOf(x.end);if(k!=-1){var B=R.getCurrentTokenRow(),N=R.getCurrentTokenColumn()+k;E=new u(B,N,B,N+x.end.length);break}T=R.stepForward()}E&&f.remove(E),O&&(f.remove(O),C=O.start.row,P=-x.start.length)}else P=x.start.length,C=m.start.row,f.insert(m.end,x.end),f.insert(m.start,x.start);_.start.row==C&&(_.start.column+=P),_.end.row==C&&(_.end.column+=P),f.selection.fromOrientedRange(_)}},this.getNextLineIndent=function(o,f,m){return this.$getIndent(f)},this.checkOutdent=function(o,f,m){return!1},this.autoOutdent=function(o,f,m){},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 f in o)if(o[f]){var m=o[f],w=m.prototype.$id,x=h.$modes[w];x||(h.$modes[w]=x=new m),h.$modes[f]||(h.$modes[f]=x),this.$embeds.push(f),this.$modes[f]=x}for(var R=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"],T=function(P){(function(O){var E=R[P],k=O[E];O[R[P]]=function(){return this.$delegator(E,arguments,k)}})(_)},_=this,f=0;f<R.length;f++)T(f)},this.$delegator=function(o,f,m){var w=f[0]||"start";if(typeof w!="string"){if(Array.isArray(w[2])){var x=w[2][w[2].length-1],R=this.$modes[x];if(R)return R[o].apply(R,[w[1]].concat([].slice.call(f,1)))}w=w[0]||"start"}for(var T=0;T<this.$embeds.length;T++)if(this.$modes[this.$embeds[T]]){var _=w.split(this.$embeds[T]);if(!_[0]&&_[1]){f[0]=_[1];var R=this.$modes[this.$embeds[T]];return R[o].apply(R,f)}}var C=m.apply(this,f);return m?C:void 0},this.transformAction=function(o,f,m,w,x){if(this.$behaviour){var R=this.$behaviour.getBehaviours();for(var T in R)if(R[T][f]){var _=R[T][f].apply(this,arguments);if(_)return _}}},this.getKeywords=function(o){if(!this.completionKeywords){var f=this.$tokenizer.rules,m=[];for(var w in f)for(var x=f[w],R=0,T=x.length;R<T;R++)if(typeof x[R].token=="string")/keyword|support|storage/.test(x[R].token)&&m.push(x[R].regex);else if(typeof x[R].token=="object"){for(var _=0,C=x[R].token.length;_<C;_++)if(/keyword|support|storage/.test(x[R].token[_])){var w=x[R].regex.match(/\(.+?\)/g)[_];m.push(w.substr(1,w.length-2))}}this.completionKeywords=m}return o?m.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(o,f,m,w){var x=this.$keywordList||this.$createKeywordList();return x.map(function(R){return{name:R,value:R,score:0,meta:"keyword"}})},this.$id="ace/mode/text"}).call(d.prototype),r.Mode=d}),ace.define("ace/line_widgets",["require","exports","module","ace/lib/dom"],function(t,r,c){var h=t("./lib/dom"),g=(function(){function v(s){this.session=s,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 v.prototype.getRowLength=function(s){var p;return this.lineWidgets?p=this.lineWidgets[s]&&this.lineWidgets[s].rowCount||0:p=0,!this.$useWrapMode||!this.$wrapData[s]?1+p:this.$wrapData[s].length+1+p},v.prototype.$getWidgetScreenLength=function(){var s=0;return this.lineWidgets.forEach(function(p){p&&p.rowCount&&!p.hidden&&(s+=p.rowCount)}),s},v.prototype.$onChangeEditor=function(s){this.attach(s.editor)},v.prototype.attach=function(s){s&&s.widgetManager&&s.widgetManager!=this&&s.widgetManager.detach(),this.editor!=s&&(this.detach(),this.editor=s,s&&(s.widgetManager=this,s.renderer.on("beforeRender",this.measureWidgets),s.renderer.on("afterRender",this.renderWidgets)))},v.prototype.detach=function(s){var p=this.editor;if(p){this.editor=null,p.widgetManager=null,p.renderer.off("beforeRender",this.measureWidgets),p.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))})}},v.prototype.updateOnFold=function(s,p){var a=p.lineWidgets;if(!(!a||!s.action)){for(var l=s.data,u=l.start.row,d=l.end.row,o=s.action=="add",f=u+1;f<d;f++)a[f]&&(a[f].hidden=o);a[d]&&(o?a[u]?a[d].hidden=o:a[u]=a[d]:(a[u]==a[d]&&(a[u]=void 0),a[d].hidden=o))}},v.prototype.updateOnChange=function(s){var p=this.session.lineWidgets;if(p){var a=s.start.row,l=s.end.row-a;if(l!==0)if(s.action=="remove"){var u=p.splice(a+1,l);!p[a]&&u[u.length-1]&&(p[a]=u.pop()),u.forEach(function(o){o&&this.removeLineWidget(o)},this),this.$updateRows()}else{var d=new Array(l);p[a]&&p[a].column!=null&&s.start.column>p[a].column&&a++,d.unshift(a,0),p.splice.apply(p,d),this.$updateRows()}}},v.prototype.$updateRows=function(){var s=this.session.lineWidgets;if(s){var p=!0;s.forEach(function(a,l){if(a)for(p=!1,a.row=l;a.$oldWidget;)a.$oldWidget.row=l,a=a.$oldWidget}),p&&(this.session.lineWidgets=null)}},v.prototype.$registerLineWidget=function(s){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var p=this.session.lineWidgets[s.row];return p&&(s.$oldWidget=p,p.el&&p.el.parentNode&&(p.el.parentNode.removeChild(p.el),p._inDocument=!1)),this.session.lineWidgets[s.row]=s,s},v.prototype.addLineWidget=function(s){if(this.$registerLineWidget(s),s.session=this.session,!this.editor)return s;var p=this.editor.renderer;s.html&&!s.el&&(s.el=h.createElement("div"),s.el.innerHTML=s.html),s.text&&!s.el&&(s.el=h.createElement("div"),s.el.textContent=s.text),s.el&&(h.addCssClass(s.el,"ace_lineWidgetContainer"),s.className&&h.addCssClass(s.el,s.className),s.el.style.position="absolute",s.el.style.zIndex="5",p.container.appendChild(s.el),s._inDocument=!0,s.coverGutter||(s.el.style.zIndex="3"),s.pixelHeight==null&&(s.pixelHeight=s.el.offsetHeight)),s.rowCount==null&&(s.rowCount=s.pixelHeight/p.layerConfig.lineHeight);var a=this.session.getFoldAt(s.row,0);if(s.$fold=a,a){var l=this.session.lineWidgets;s.row==a.end.row&&!l[a.start.row]?l[a.start.row]=s:s.hidden=!0}return this.session._emit("changeFold",{data:{start:{row:s.row}}}),this.$updateRows(),this.renderWidgets(null,p),this.onWidgetChanged(s),s},v.prototype.removeLineWidget=function(s){if(s._inDocument=!1,s.session=null,s.el&&s.el.parentNode&&s.el.parentNode.removeChild(s.el),s.editor&&s.editor.destroy)try{s.editor.destroy()}catch{}if(this.session.lineWidgets){var p=this.session.lineWidgets[s.row];if(p==s)this.session.lineWidgets[s.row]=s.$oldWidget,s.$oldWidget&&this.onWidgetChanged(s.$oldWidget);else for(;p;){if(p.$oldWidget==s){p.$oldWidget=s.$oldWidget;break}p=p.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:s.row}}}),this.$updateRows()},v.prototype.getWidgetsAtRow=function(s){for(var p=this.session.lineWidgets,a=p&&p[s],l=[];a;)l.push(a),a=a.$oldWidget;return l},v.prototype.onWidgetChanged=function(s){this.session._changedWidgets.push(s),this.editor&&this.editor.renderer.updateFull()},v.prototype.measureWidgets=function(s,p){var a=this.session._changedWidgets,l=p.layerConfig;if(!(!a||!a.length)){for(var u=1/0,d=0;d<a.length;d++){var o=a[d];if(!(!o||!o.el)&&o.session==this.session){if(!o._inDocument){if(this.session.lineWidgets[o.row]!=o)continue;o._inDocument=!0,p.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 f=o.h/l.lineHeight;o.coverLine&&(f-=this.session.getRowLineCount(o.row),f<0&&(f=0)),o.rowCount!=f&&(o.rowCount=f,o.row<u&&(u=o.row))}}u!=1/0&&(this.session._emit("changeFold",{data:{start:{row:u}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]}},v.prototype.renderWidgets=function(s,p){var a=p.layerConfig,l=this.session.lineWidgets;if(l){for(var u=Math.min(this.firstRow,a.firstRow),d=Math.max(this.lastRow,a.lastRow,l.length);u>0&&!l[u];)u--;this.firstRow=a.firstRow,this.lastRow=a.lastRow,p.$cursorLayer.config=a;for(var o=u;o<=d;o++){var f=l[o];if(!(!f||!f.el)){if(f.hidden){f.el.style.top=-100-(f.pixelHeight||0)+"px";continue}f._inDocument||(f._inDocument=!0,p.container.appendChild(f.el));var m=p.$cursorLayer.getPixelPosition({row:o,column:0},!0).top;f.coverLine||(m+=a.lineHeight*this.session.getRowLineCount(f.row)),f.el.style.top=m-a.offset+"px";var w=f.coverGutter?0:p.gutterWidth;f.fixedWidth||(w-=p.scrollLeft),f.el.style.left=w+"px",f.fullWidth&&f.screenWidth&&(f.el.style.minWidth=a.width+2*a.padding+"px"),f.fixedWidth?f.el.style.right=p.scrollBar.getWidth()+"px":f.el.style.right=""}}}},v})();r.LineWidgets=g}),ace.define("ace/apply_delta",["require","exports","module"],function(t,r,c){r.applyDelta=function(h,g,v){var s=g.start.row,p=g.start.column,a=h[s]||"";switch(g.action){case"insert":var l=g.lines;if(l.length===1)h[s]=a.substring(0,p)+g.lines[0]+a.substring(p);else{var u=[s,1].concat(g.lines);h.splice.apply(h,u),h[s]=a.substring(0,p)+h[s],h[s+g.lines.length-1]+=a.substring(p)}break;case"remove":var d=g.end.column,o=g.end.row;s===o?h[s]=a.substring(0,p)+a.substring(d):h.splice(s,o-s+1,a.substring(0,p)+h[o].substring(d));break}}}),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(t,r,c){var h=t("./lib/oop"),g=t("./lib/event_emitter").EventEmitter,v=(function(){function a(l,u,d){this.$onChange=this.onChange.bind(this),this.attach(l),typeof u!="number"?this.setPosition(u.row,u.column):this.setPosition(u,d)}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 u=p(l,{row:this.row,column:this.column},this.$insertRight);this.setPosition(u.row,u.column,!0)}},a.prototype.setPosition=function(l,u,d){var o;if(d?o={row:l,column:u}:o=this.$clipPositionToDocument(l,u),!(this.row==o.row&&this.column==o.column)){var f={row:this.row,column:this.column};this.row=o.row,this.column=o.column,this._signal("change",{old:f,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,u){var d={};return l>=this.document.getLength()?(d.row=Math.max(0,this.document.getLength()-1),d.column=this.document.getLine(d.row).length):l<0?(d.row=0,d.column=0):(d.row=l,d.column=Math.min(this.document.getLine(d.row).length,Math.max(0,u))),u<0&&(d.column=0),d},a})();v.prototype.$insertRight=!1,h.implement(v.prototype,g);function s(a,l,u){var d=u?a.column<=l.column:a.column<l.column;return a.row<l.row||a.row==l.row&&d}function p(a,l,u){var d=a.action=="insert",o=(d?1:-1)*(a.end.row-a.start.row),f=(d?1:-1)*(a.end.column-a.start.column),m=a.start,w=d?m:a.end;return s(l,m,u)?{row:l.row,column:l.column}:s(w,l,!u)?{row:l.row+o,column:l.column+(l.row==w.row?f:0)}:{row:m.row,column:m.column}}r.Anchor=v}),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"],function(t,r,c){var h=t("./lib/oop"),g=t("./apply_delta").applyDelta,v=t("./lib/event_emitter").EventEmitter,s=t("./range").Range,p=t("./anchor").Anchor,a=(function(){function l(u){this.$lines=[""],u.length===0?this.$lines=[""]:Array.isArray(u)?this.insertMergedLines({row:0,column:0},u):this.insert({row:0,column:0},u)}return l.prototype.setValue=function(u){var d=this.getLength()-1;this.remove(new s(0,0,d,this.getLine(d).length)),this.insert({row:0,column:0},u||"")},l.prototype.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},l.prototype.createAnchor=function(u,d){return new p(this,u,d)},l.prototype.$detectNewLine=function(u){var d=u.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=d?d[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(u){this.$newLineMode!==u&&(this.$newLineMode=u,this._signal("changeNewLineMode"))},l.prototype.getNewLineMode=function(){return this.$newLineMode},l.prototype.isNewLine=function(u){return u==`\r
193
+ `||u=="\r"||u==`
194
+ `},l.prototype.getLine=function(u){return this.$lines[u]||""},l.prototype.getLines=function(u,d){return this.$lines.slice(u,d+1)},l.prototype.getAllLines=function(){return this.getLines(0,this.getLength())},l.prototype.getLength=function(){return this.$lines.length},l.prototype.getTextRange=function(u){return this.getLinesForRange(u).join(this.getNewLineCharacter())},l.prototype.getLinesForRange=function(u){var d;if(u.start.row===u.end.row)d=[this.getLine(u.start.row).substring(u.start.column,u.end.column)];else{d=this.getLines(u.start.row,u.end.row),d[0]=(d[0]||"").substring(u.start.column);var o=d.length-1;u.end.row-u.start.row==o&&(d[o]=d[o].substring(0,u.end.column))}return d},l.prototype.insertLines=function(u,d){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(u,d)},l.prototype.removeLines=function(u,d){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(u,d)},l.prototype.insertNewLine=function(u){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(u,["",""])},l.prototype.insert=function(u,d){return this.getLength()<=1&&this.$detectNewLine(d),this.insertMergedLines(u,this.$split(d))},l.prototype.insertInLine=function(u,d){var o=this.clippedPos(u.row,u.column),f=this.pos(u.row,u.column+d.length);return this.applyDelta({start:o,end:f,action:"insert",lines:[d]},!0),this.clonePos(f)},l.prototype.clippedPos=function(u,d){var o=this.getLength();u===void 0?u=o:u<0?u=0:u>=o&&(u=o-1,d=void 0);var f=this.getLine(u);return d==null&&(d=f.length),d=Math.min(Math.max(d,0),f.length),{row:u,column:d}},l.prototype.clonePos=function(u){return{row:u.row,column:u.column}},l.prototype.pos=function(u,d){return{row:u,column:d}},l.prototype.$clipPosition=function(u){var d=this.getLength();return u.row>=d?(u.row=Math.max(0,d-1),u.column=this.getLine(d-1).length):(u.row=Math.max(0,u.row),u.column=Math.min(Math.max(u.column,0),this.getLine(u.row).length)),u},l.prototype.insertFullLines=function(u,d){u=Math.min(Math.max(u,0),this.getLength());var o=0;u<this.getLength()?(d=d.concat([""]),o=0):(d=[""].concat(d),u--,o=this.$lines[u].length),this.insertMergedLines({row:u,column:o},d)},l.prototype.insertMergedLines=function(u,d){var o=this.clippedPos(u.row,u.column),f={row:o.row+d.length-1,column:(d.length==1?o.column:0)+d[d.length-1].length};return this.applyDelta({start:o,end:f,action:"insert",lines:d}),this.clonePos(f)},l.prototype.remove=function(u){var d=this.clippedPos(u.start.row,u.start.column),o=this.clippedPos(u.end.row,u.end.column);return this.applyDelta({start:d,end:o,action:"remove",lines:this.getLinesForRange({start:d,end:o})}),this.clonePos(d)},l.prototype.removeInLine=function(u,d,o){var f=this.clippedPos(u,d),m=this.clippedPos(u,o);return this.applyDelta({start:f,end:m,action:"remove",lines:this.getLinesForRange({start:f,end:m})},!0),this.clonePos(f)},l.prototype.removeFullLines=function(u,d){u=Math.min(Math.max(0,u),this.getLength()-1),d=Math.min(Math.max(0,d),this.getLength()-1);var o=d==this.getLength()-1&&u>0,f=d<this.getLength()-1,m=o?u-1:u,w=o?this.getLine(m).length:0,x=f?d+1:d,R=f?0:this.getLine(x).length,T=new s(m,w,x,R),_=this.$lines.slice(u,d+1);return this.applyDelta({start:T.start,end:T.end,action:"remove",lines:this.getLinesForRange(T)}),_},l.prototype.removeNewLine=function(u){u<this.getLength()-1&&u>=0&&this.applyDelta({start:this.pos(u,this.getLine(u).length),end:this.pos(u+1,0),action:"remove",lines:["",""]})},l.prototype.replace=function(u,d){if(u instanceof s||(u=s.fromPoints(u.start,u.end)),d.length===0&&u.isEmpty())return u.start;if(d==this.getTextRange(u))return u.end;this.remove(u);var o;return d?o=this.insert(u.start,d):o=u.start,o},l.prototype.applyDeltas=function(u){for(var d=0;d<u.length;d++)this.applyDelta(u[d])},l.prototype.revertDeltas=function(u){for(var d=u.length-1;d>=0;d--)this.revertDelta(u[d])},l.prototype.applyDelta=function(u,d){var o=u.action=="insert";(o?u.lines.length<=1&&!u.lines[0]:!s.comparePoints(u.start,u.end))||(o&&u.lines.length>2e4?this.$splitAndapplyLargeDelta(u,2e4):(g(this.$lines,u,d),this._signal("change",u)))},l.prototype.$safeApplyDelta=function(u){var d=this.$lines.length;(u.action=="remove"&&u.start.row<d&&u.end.row<d||u.action=="insert"&&u.start.row<=d)&&this.applyDelta(u)},l.prototype.$splitAndapplyLargeDelta=function(u,d){for(var o=u.lines,f=o.length-d+1,m=u.start.row,w=u.start.column,x=0,R=0;x<f;x=R){R+=d-1;var T=o.slice(x,R);T.push(""),this.applyDelta({start:this.pos(m+x,w),end:this.pos(m+R,w=0),action:u.action,lines:T},!0)}u.lines=o.slice(x),u.start.row=m+x,u.start.column=w,this.applyDelta(u,!0)},l.prototype.revertDelta=function(u){this.$safeApplyDelta({start:this.clonePos(u.start),end:this.clonePos(u.end),action:u.action=="insert"?"remove":"insert",lines:u.lines.slice()})},l.prototype.indexToPosition=function(u,d){for(var o=this.$lines||this.getAllLines(),f=this.getNewLineCharacter().length,m=d||0,w=o.length;m<w;m++)if(u-=o[m].length+f,u<0)return{row:m,column:u+o[m].length+f};return{row:w-1,column:u+o[w-1].length+f}},l.prototype.positionToIndex=function(u,d){for(var o=this.$lines||this.getAllLines(),f=this.getNewLineCharacter().length,m=0,w=Math.min(u.row,o.length),x=d||0;x<w;++x)m+=o[x].length+f;return m+u.column},l.prototype.$split=function(u){return u.split(/\r\n|\r|\n/)},l})();a.prototype.$autoNewLine="",a.prototype.$newLineMode="auto",h.implement(a.prototype,v),r.Document=a}),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(t,r,c){var h=t("./lib/oop"),g=t("./lib/event_emitter").EventEmitter,v=(function(){function s(p,a){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=p;var l=this;this.$worker=function(){if(l.running){for(var u=new Date,d=l.currentLine,o=-1,f=l.doc,m=d;l.lines[d];)d++;var w=f.getLength(),x=0;for(l.running=!1;d<w;){l.$tokenizeRow(d),o=d;do d++;while(l.lines[d]);if(x++,x%5===0&&new Date-u>20){l.running=setTimeout(l.$worker,20);break}}l.currentLine=d,o==-1&&(o=d),m<=o&&l.fireUpdateEvent(m,o)}}}return s.prototype.setTokenizer=function(p){this.tokenizer=p,this.lines=[],this.states=[],this.start(0)},s.prototype.setDocument=function(p){this.doc=p,this.lines=[],this.states=[],this.stop()},s.prototype.fireUpdateEvent=function(p,a){var l={first:p,last:a};this._signal("update",{data:l})},s.prototype.start=function(p){this.currentLine=Math.min(p||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)},s.prototype.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},s.prototype.$updateOnChange=function(p){var a=p.start.row,l=p.end.row-a;if(l===0)this.lines[a]=null;else if(p.action=="remove")this.lines.splice(a,l+1,null),this.states.splice(a,l+1,null);else{var u=Array(l+1);u.unshift(a,1),this.lines.splice.apply(this.lines,u),this.states.splice.apply(this.states,u)}this.currentLine=Math.min(a,this.currentLine,this.doc.getLength()),this.stop()},s.prototype.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},s.prototype.getTokens=function(p){return this.lines[p]||this.$tokenizeRow(p)},s.prototype.getState=function(p){return this.currentLine==p&&this.$tokenizeRow(p),this.states[p]||"start"},s.prototype.$tokenizeRow=function(p){var a=this.doc.getLine(p),l=this.states[p-1],u=this.tokenizer.getLineTokens(a,l,p);return this.states[p]+""!=u.state+""?(this.states[p]=u.state,this.lines[p+1]=null,this.currentLine>p+1&&(this.currentLine=p+1)):this.currentLine==p&&(this.currentLine=p+1),this.lines[p]=u.tokens},s.prototype.cleanup=function(){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.removeAllListeners()},s})();h.implement(v.prototype,g),r.BackgroundTokenizer=v}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/range"],function(t,r,c){var h=t("./lib/lang"),g=t("./range").Range,v=(function(){function s(p,a,l){l===void 0&&(l="text"),this.setRegexp(p),this.clazz=a,this.type=l,this.docLen=0}return s.prototype.setRegexp=function(p){this.regExp+""!=p+""&&(this.regExp=p,this.cache=[])},s.prototype.update=function(p,a,l,u){if(this.regExp){for(var d=u.firstRow,o=u.lastRow,f={},m=l.$editor&&l.$editor.$search,w=m&&m.$isMultilineSearch(l.$editor.getLastSearchOptions()),x=l.getValue().length,R=x!=this.docLen,T=d;T<=o;T++){var _=this.cache[T];if(_==null||R){if(w){_=[];var C=m.$multiLineForward(l,this.regExp,T,o);if(C){var P=C.endRow<=o?C.endRow-1:o;P>T&&(T=P),_.push(new g(C.startRow,C.startCol,C.endRow,C.endCol))}_.length>this.MAX_RANGES&&(_=_.slice(0,this.MAX_RANGES))}else _=h.getMatchOffsets(l.getLine(T),this.regExp),_.length>this.MAX_RANGES&&(_=_.slice(0,this.MAX_RANGES)),_=_.map(function(B){return new g(T,B.offset,T,B.offset+B.length)});this.cache[T]=_.length?_:""}if(_.length!==0)for(var O=_.length;O--;){var E=_[O].toScreenRange(l),k=E.toString();f[k]||(f[k]=!0,a.drawSingleLineMarker(p,E,this.clazz,u))}}this.docLen=x}},s})();v.prototype.MAX_RANGES=500,r.SearchHighlight=v}),ace.define("ace/undomanager",["require","exports","module","ace/range"],function(t,r,c){var h=(function(){function _(){this.$keepRedoStack,this.$maxRev=0,this.$fromUndo=!1,this.$undoDepth=1/0,this.reset()}return _.prototype.addSession=function(C){this.$session=C},_.prototype.add=function(C,P,O){if(!this.$fromUndo&&C!=this.$lastDelta){if(this.$keepRedoStack||(this.$redoStack.length=0),P===!1||!this.lastDeltas){this.lastDeltas=[];var E=this.$undoStack.length;E>this.$undoDepth-1&&this.$undoStack.splice(0,E-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)}},_.prototype.addSelection=function(C,P){this.selections.push({value:C,rev:P||this.$rev})},_.prototype.startNewGroup=function(){return this.lastDeltas=null,this.$rev},_.prototype.markIgnored=function(C,P){P==null&&(P=this.$rev+1);for(var O=this.$undoStack,E=O.length;E--;){var k=O[E][0];if(k.id<=C)break;k.id<P&&(k.ignore=!0)}this.lastDeltas=null},_.prototype.getSelection=function(C,P){for(var O=this.selections,E=O.length;E--;){var k=O[E];if(k.rev<C)return P&&(k=O[E+1]),k}},_.prototype.getRevision=function(){return this.$rev},_.prototype.getDeltas=function(C,P){P==null&&(P=this.$rev+1);for(var O=this.$undoStack,E=null,k=0,B=O.length;B--;){var N=O[B][0];if(N.id<P&&!E&&(E=B+1),N.id<=C){k=B+1;break}}return O.slice(k,E)},_.prototype.getChangedRanges=function(C,P){P==null&&(P=this.$rev+1)},_.prototype.getChangedLines=function(C,P){P==null&&(P=this.$rev+1)},_.prototype.undo=function(C,P){this.lastDeltas=null;var O=this.$undoStack;if(g(O,O.length)){C||(C=this.$session),this.$redoStackBaseRev!==this.$rev&&this.$redoStack.length&&(this.$redoStack=[]),this.$fromUndo=!0;var E=O.pop(),k=null;return E&&(k=C.undoChanges(E,P),this.$redoStack.push(E),this.$syncRev()),this.$fromUndo=!1,k}},_.prototype.redo=function(C,P){if(this.lastDeltas=null,C||(C=this.$session),this.$fromUndo=!0,this.$redoStackBaseRev!=this.$rev){var O=this.getDeltas(this.$redoStackBaseRev,this.$rev+1);T(this.$redoStack,O),this.$redoStackBaseRev=this.$rev,this.$redoStack.forEach(function(B){B[0].id=++this.$maxRev},this)}var E=this.$redoStack.pop(),k=null;return E&&(k=C.redoChanges(E,P),this.$undoStack.push(E),this.$syncRev()),this.$fromUndo=!1,k},_.prototype.$syncRev=function(){var C=this.$undoStack,P=C[C.length-1],O=P&&P[0].id||0;this.$redoStackBaseRev=O,this.$rev=O},_.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=[]},_.prototype.canUndo=function(){return this.$undoStack.length>0},_.prototype.canRedo=function(){return this.$redoStack.length>0},_.prototype.bookmark=function(C){C==null&&(C=this.$rev),this.mark=C},_.prototype.isAtBookmark=function(){return this.$rev===this.mark},_.prototype.toJSON=function(){return{$redoStack:this.$redoStack,$undoStack:this.$undoStack}},_.prototype.fromJSON=function(C){this.reset(),C&&(this.$undoStack=C.$undoStack||[],this.$redoStack=C.$redoStack||[])},_.prototype.$prettyPrint=function(C){return C?l(C):l(this.$undoStack)+`
195
+ ---
196
+ `+l(this.$redoStack)},_})();h.prototype.hasUndo=h.prototype.canUndo,h.prototype.hasRedo=h.prototype.canRedo,h.prototype.isClean=h.prototype.isAtBookmark,h.prototype.markClean=h.prototype.bookmark;function g(_,C){for(var P=C;P--;){var O=_[P];if(O&&!O[0].ignore){for(;P<C-1;){var E=o(_[P],_[P+1]);_[P]=E[0],_[P+1]=E[1],P++}return!0}}}var v=t("./range").Range,s=v.comparePoints;v.comparePoints;function p(_){return{row:_.row,column:_.column}}function a(_){return{start:p(_.start),end:p(_.end),action:_.action,lines:_.lines.slice()}}function l(_){if(_=_||this,Array.isArray(_))return _.map(l).join(`
197
+ `);var C="";return _.action?(C=_.action=="insert"?"+":"-",C+="["+_.lines+"]"):_.value&&(Array.isArray(_.value)?C=_.value.map(u).join(`
198
+ `):C=u(_.value)),_.start&&(C+=u(_)),(_.id||_.rev)&&(C+=" ("+(_.id||_.rev)+")"),C}function u(_){return _.start.row+":"+_.start.column+"=>"+_.end.row+":"+_.end.column}function d(_,C){var P=_.action=="insert",O=C.action=="insert";if(P&&O)if(s(C.start,_.end)>=0)m(C,_,-1);else if(s(C.start,_.start)<=0)m(_,C,1);else return null;else if(P&&!O)if(s(C.start,_.end)>=0)m(C,_,-1);else if(s(C.end,_.start)<=0)m(_,C,-1);else return null;else if(!P&&O)if(s(C.start,_.start)>=0)m(C,_,1);else if(s(C.start,_.start)<=0)m(_,C,1);else return null;else if(!P&&!O)if(s(C.start,_.start)>=0)m(C,_,1);else if(s(C.end,_.start)<=0)m(_,C,-1);else return null;return[C,_]}function o(_,C){for(var P=_.length;P--;)for(var O=0;O<C.length;O++)if(!d(_[P],C[O])){for(;P<_.length;){for(;O--;)d(C[O],_[P]);O=C.length,P++}return[_,C]}return _.selectionBefore=C.selectionBefore=_.selectionAfter=C.selectionAfter=null,[C,_]}function f(_,C){var P=_.action=="insert",O=C.action=="insert";if(P&&O)s(_.start,C.start)<0?m(C,_,1):m(_,C,1);else if(P&&!O)s(_.start,C.end)>=0?m(_,C,-1):(s(_.start,C.start)<=0||m(_,v.fromPoints(C.start,_.start),-1),m(C,_,1));else if(!P&&O)s(C.start,_.end)>=0?m(C,_,-1):(s(C.start,_.start)<=0||m(C,v.fromPoints(_.start,C.start),-1),m(_,C,1));else if(!P&&!O)if(s(C.start,_.end)>=0)m(C,_,-1);else if(s(C.end,_.start)<=0)m(_,C,-1);else{var E,k;return s(_.start,C.start)<0&&(E=_,_=x(_,C.start)),s(_.end,C.end)>0&&(k=x(_,C.end)),w(C.end,_.start,_.end,-1),k&&!E&&(_.lines=k.lines,_.start=k.start,_.end=k.end,k=_),[C,E,k].filter(Boolean)}return[C,_]}function m(_,C,P){w(_.start,C.start,C.end,P),w(_.end,C.start,C.end,P)}function w(_,C,P,O){_.row==(O==1?C:P).row&&(_.column+=O*(P.column-C.column)),_.row+=O*(P.row-C.row)}function x(_,C){var P=_.lines,O=_.end;_.end=p(C);var E=_.end.row-_.start.row,k=P.splice(E,P.length),B=E?C.column:C.column-_.start.column;P.push(k[0].substring(0,B)),k[0]=k[0].substr(B);var N={start:p(C),end:O,lines:k,action:_.action};return N}function R(_,C){C=a(C);for(var P=_.length;P--;){for(var O=_[P],E=0;E<O.length;E++){var k=O[E],B=f(k,C);C=B[0],B.length!=2&&(B[2]?(O.splice(E+1,1,B[1],B[2]),E++):B[1]||(O.splice(E,1),E--))}O.length||_.splice(P,1)}return _}function T(_,C){for(var P=0;P<C.length;P++)for(var O=C[P],E=0;E<O.length;E++)R(_,O[E])}r.UndoManager=h}),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(t,r,c){var h=t("../range").Range,g=(function(){function v(s,p){this.foldData=s,Array.isArray(p)?this.folds=p:p=this.folds=[p];var a=p[p.length-1];this.range=new h(p[0].start.row,p[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 v.prototype.shiftRow=function(s){this.start.row+=s,this.end.row+=s,this.folds.forEach(function(p){p.start.row+=s,p.end.row+=s})},v.prototype.addFold=function(s){if(s.sameRow){if(s.start.row<this.startRow||s.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(s),this.folds.sort(function(p,a){return-p.range.compareEnd(a.start.row,a.start.column)}),this.range.compareEnd(s.start.row,s.start.column)>0?(this.end.row=s.end.row,this.end.column=s.end.column):this.range.compareStart(s.end.row,s.end.column)<0&&(this.start.row=s.start.row,this.start.column=s.start.column)}else if(s.start.row==this.end.row)this.folds.push(s),this.end.row=s.end.row,this.end.column=s.end.column;else if(s.end.row==this.start.row)this.folds.unshift(s),this.start.row=s.start.row,this.start.column=s.start.column;else throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");s.foldLine=this},v.prototype.containsRow=function(s){return s>=this.start.row&&s<=this.end.row},v.prototype.walk=function(s,p,a){var l=0,u=this.folds,d,o,f,m=!0;p==null&&(p=this.end.row,a=this.end.column);for(var w=0;w<u.length;w++){if(d=u[w],o=d.range.compareStart(p,a),o==-1){s(null,p,a,l,m);return}if(f=s(null,d.start.row,d.start.column,l,m),f=!f&&s(d.placeholder,d.start.row,d.start.column,l),f||o===0)return;m=!d.sameRow,l=d.end.column}s(null,p,a,l,m)},v.prototype.getNextFoldTo=function(s,p){for(var a,l,u=0;u<this.folds.length;u++){if(a=this.folds[u],l=a.range.compareEnd(s,p),l==-1)return{fold:a,kind:"after"};if(l===0)return{fold:a,kind:"inside"}}return null},v.prototype.addRemoveChars=function(s,p,a){var l=this.getNextFoldTo(s,p),u,d;if(l){if(u=l.fold,l.kind=="inside"&&u.start.column!=p&&u.start.row!=s)window.console&&window.console.log(s,p,u);else if(u.start.row==s){d=this.folds;var o=d.indexOf(u);for(o===0&&(this.start.column+=a),o;o<d.length;o++){if(u=d[o],u.start.column+=a,!u.sameRow)return;u.end.column+=a}this.end.column+=a}}},v.prototype.split=function(s,p){var a=this.getNextFoldTo(s,p);if(!a||a.kind=="inside")return null;var l=a.fold,u=this.folds,d=this.foldData,o=u.indexOf(l),f=u[o-1];this.end.row=f.end.row,this.end.column=f.end.column,u=u.splice(o,u.length-o);var m=new v(d,u);return d.splice(d.indexOf(this)+1,0,m),m},v.prototype.merge=function(s){for(var p=s.folds,a=0;a<p.length;a++)this.addFold(p[a]);var l=this.foldData;l.splice(l.indexOf(s),1)},v.prototype.toString=function(){var s=[this.range.toString()+": ["];return this.folds.forEach(function(p){s.push(" "+p.toString())}),s.push("]"),s.join(`
199
+ `)},v.prototype.idxToPosition=function(s){for(var p=0,a=0;a<this.folds.length;a++){var l=this.folds[a];if(s-=l.start.column-p,s<0)return{row:l.start.row,column:l.start.column+s};if(s-=l.placeholder.length,s<0)return l.start;p=l.end.column}return{row:this.end.row,column:this.end.column+s}},v})();r.FoldLine=g}),ace.define("ace/range_list",["require","exports","module","ace/range"],function(t,r,c){var h=t("./range").Range,g=h.comparePoints,v=(function(){function s(){this.ranges=[],this.$bias=1}return s.prototype.pointIndex=function(p,a,l){for(var u=this.ranges,d=l||0;d<u.length;d++){var o=u[d],f=g(p,o.end);if(!(f>0)){var m=g(p,o.start);return f===0?a&&m!==0?-d-2:d:m>0||m===0&&!a?d:-d-1}}return-d-1},s.prototype.add=function(p){var a=!p.isEmpty(),l=this.pointIndex(p.start,a);l<0&&(l=-l-1);var u=this.pointIndex(p.end,a,l);return u<0?u=-u-1:u++,this.ranges.splice(l,u-l,p)},s.prototype.addList=function(p){for(var a=[],l=p.length;l--;)a.push.apply(a,this.add(p[l]));return a},s.prototype.substractPoint=function(p){var a=this.pointIndex(p);if(a>=0)return this.ranges.splice(a,1)},s.prototype.merge=function(){var p=[],a=this.ranges;a=a.sort(function(f,m){return g(f.start,m.start)});for(var l=a[0],u,d=1;d<a.length;d++){u=l,l=a[d];var o=g(u.end,l.start);o<0||o==0&&!u.isEmpty()&&!l.isEmpty()||(g(u.end,l.end)<0&&(u.end.row=l.end.row,u.end.column=l.end.column),a.splice(d,1),p.push(l),l=u,d--)}return this.ranges=a,p},s.prototype.contains=function(p,a){return this.pointIndex({row:p,column:a})>=0},s.prototype.containsPoint=function(p){return this.pointIndex(p)>=0},s.prototype.rangeAtPoint=function(p){var a=this.pointIndex(p);if(a>=0)return this.ranges[a]},s.prototype.clipRows=function(p,a){var l=this.ranges;if(l[0].start.row>a||l[l.length-1].start.row<p)return[];var u=this.pointIndex({row:p,column:0});u<0&&(u=-u-1);var d=this.pointIndex({row:a,column:0},u);d<0&&(d=-d-1);for(var o=[],f=u;f<d;f++)o.push(l[f]);return o},s.prototype.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},s.prototype.attach=function(p){this.session&&this.detach(),this.session=p,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},s.prototype.detach=function(){this.session&&(this.session.removeListener("change",this.onChange),this.session=null)},s.prototype.$onChange=function(p){for(var a=p.start,l=p.end,u=a.row,d=l.row,o=this.ranges,f=0,m=o.length;f<m;f++){var w=o[f];if(w.end.row>=u)break}if(p.action=="insert")for(var x=d-u,R=-a.column+l.column;f<m;f++){var w=o[f];if(w.start.row>u)break;if(w.start.row==u&&w.start.column>=a.column&&(w.start.column==a.column&&this.$bias<=0||(w.start.column+=R,w.start.row+=x)),w.end.row==u&&w.end.column>=a.column){if(w.end.column==a.column&&this.$bias<0)continue;w.end.column==a.column&&R>0&&f<m-1&&w.end.column>w.start.column&&w.end.column==o[f+1].start.column&&(w.end.column-=R),w.end.column+=R,w.end.row+=x}}else for(var x=u-d,R=a.column-l.column;f<m;f++){var w=o[f];if(w.start.row>d)break;w.end.row<d&&(u<w.end.row||u==w.end.row&&a.column<w.end.column)?(w.end.row=u,w.end.column=a.column):w.end.row==d?w.end.column<=l.column?(x||w.end.column>a.column)&&(w.end.column=a.column,w.end.row=a.row):(w.end.column+=R,w.end.row+=x):w.end.row>d&&(w.end.row+=x),w.start.row<d&&(u<w.start.row||u==w.start.row&&a.column<w.start.column)?(w.start.row=u,w.start.column=a.column):w.start.row==d?w.start.column<=l.column?(x||w.start.column>a.column)&&(w.start.column=a.column,w.start.row=a.row):(w.start.column+=R,w.start.row+=x):w.start.row>d&&(w.start.row+=x)}if(x!=0&&f<m)for(;f<m;f++){var w=o[f];w.start.row+=x,w.end.row+=x}},s})();v.prototype.comparePoints=g,r.RangeList=v}),ace.define("ace/edit_session/fold",["require","exports","module","ace/range_list"],function(t,r,c){var h=this&&this.__extends||(function(){var u=function(d,o){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,m){f.__proto__=m}||function(f,m){for(var w in m)Object.prototype.hasOwnProperty.call(m,w)&&(f[w]=m[w])},u(d,o)};return function(d,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");u(d,o);function f(){this.constructor=d}d.prototype=o===null?Object.create(o):(f.prototype=o.prototype,new f)}})(),g=t("../range_list").RangeList,v=(function(u){h(d,u);function d(o,f){var m=u.call(this)||this;return m.foldLine=null,m.placeholder=f,m.range=o,m.start=o.start,m.end=o.end,m.sameRow=o.start.row==o.end.row,m.subFolds=m.ranges=[],m}return d.prototype.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},d.prototype.setFoldLine=function(o){this.foldLine=o,this.subFolds.forEach(function(f){f.setFoldLine(o)})},d.prototype.clone=function(){var o=this.range.clone(),f=new d(o,this.placeholder);return this.subFolds.forEach(function(m){f.subFolds.push(m.clone())}),f.collapseChildren=this.collapseChildren,f},d.prototype.addSubFold=function(o){if(!this.range.isEqual(o)){p(o,this.start);for(var f=o.start.row,m=o.start.column,w=0,x=-1;w<this.subFolds.length&&(x=this.subFolds[w].range.compare(f,m),x==1);w++);var R=this.subFolds[w],T=0;if(x==0){if(R.range.containsRange(o))return R.addSubFold(o);T=1}for(var f=o.range.end.row,m=o.range.end.column,_=w,x=-1;_<this.subFolds.length&&(x=this.subFolds[_].range.compare(f,m),x==1);_++);x==0&&_++;for(var C=this.subFolds.splice(w,_-w,o),P=x==0?C.length-1:C.length,O=T;O<P;O++)o.addSubFold(C[O]);return o.setFoldLine(this.foldLine),o}},d.prototype.restoreRange=function(o){return l(o,this.start)},d})(g);function s(u,d){u.row-=d.row,u.row==0&&(u.column-=d.column)}function p(u,d){s(u.start,d),s(u.end,d)}function a(u,d){u.row==0&&(u.column+=d.column),u.row+=d.row}function l(u,d){a(u.start,d),a(u.end,d)}r.Fold=v}),ace.define("ace/edit_session/folding",["require","exports","module","ace/range","ace/edit_session/fold_line","ace/edit_session/fold","ace/token_iterator","ace/mouse/mouse_event"],function(t,r,c){var h=t("../range").Range,g=t("./fold_line").FoldLine,v=t("./fold").Fold,s=t("../token_iterator").TokenIterator,p=t("../mouse/mouse_event").MouseEvent;function a(){this.getFoldAt=function(l,u,d){var o=this.getFoldLine(l);if(!o)return null;for(var f=o.folds,m=0;m<f.length;m++){var w=f[m].range;if(w.contains(l,u)){if(d==1&&w.isEnd(l,u)&&!w.isEmpty()||d==-1&&w.isStart(l,u)&&!w.isEmpty())continue;return f[m]}}},this.getFoldsInRange=function(l){var u=l.start,d=l.end,o=this.$foldData,f=[];u.column+=1,d.column-=1;for(var m=0;m<o.length;m++){var w=o[m].range.compareRange(l);if(w!=2){if(w==-2)break;for(var x=o[m].folds,R=0;R<x.length;R++){var T=x[R];if(w=T.range.compareRange(l),w==-2)break;if(w!=2){if(w==42)break;f.push(T)}}}}return u.column-=1,d.column+=1,f},this.getFoldsInRangeList=function(l){if(Array.isArray(l)){var u=[];l.forEach(function(o){u=u.concat(this.getFoldsInRange(o))},this)}else var u=this.getFoldsInRange(l);return u},this.getAllFolds=function(){for(var l=[],u=this.$foldData,d=0;d<u.length;d++)for(var o=0;o<u[d].folds.length;o++)l.push(u[d].folds[o]);return l},this.getFoldStringAt=function(l,u,d,o){if(o=o||this.getFoldLine(l),!o)return null;for(var f={end:{column:0}},m,w,x=0;x<o.folds.length;x++){w=o.folds[x];var R=w.range.compareEnd(l,u);if(R==-1){m=this.getLine(w.start.row).substring(f.end.column,w.start.column);break}else if(R===0)return null;f=w}return m||(m=this.getLine(w.start.row).substring(f.end.column)),d==-1?m.substring(0,u-f.end.column):d==1?m.substring(u-f.end.column):m},this.getFoldLine=function(l,u){var d=this.$foldData,o=0;for(u&&(o=d.indexOf(u)),o==-1&&(o=0),o;o<d.length;o++){var f=d[o];if(f.start.row<=l&&f.end.row>=l)return f;if(f.end.row>l)return null}return null},this.getNextFoldLine=function(l,u){var d=this.$foldData,o=0;for(u&&(o=d.indexOf(u)),o==-1&&(o=0),o;o<d.length;o++){var f=d[o];if(f.end.row>=l)return f}return null},this.getFoldedRowCount=function(l,u){for(var d=this.$foldData,o=u-l+1,f=0;f<d.length;f++){var m=d[f],w=m.end.row,x=m.start.row;if(w>=u){x<u&&(x>=l?o-=u-x:o=0);break}else w>=l&&(x>=l?o-=w-x:o-=w-l+1)}return o},this.$addFoldLine=function(l){return this.$foldData.push(l),this.$foldData.sort(function(u,d){return u.start.row-d.start.row}),l},this.addFold=function(l,u){var d=this.$foldData,o=!1,f;l instanceof v?f=l:(f=new v(u,l),f.collapseChildren=u.collapseChildren),this.$clipRangeToDocument(f.range);var m=f.start.row,w=f.start.column,x=f.end.row,R=f.end.column,T=this.getFoldAt(m,w,1),_=this.getFoldAt(x,R,-1);if(T&&_==T)return T.addSubFold(f);T&&!T.range.isStart(m,w)&&this.removeFold(T),_&&!_.range.isEnd(x,R)&&this.removeFold(_);var C=this.getFoldsInRange(f.range);C.length>0&&(this.removeFolds(C),f.collapseChildren||C.forEach(function(k){f.addSubFold(k)}));for(var P=0;P<d.length;P++){var O=d[P];if(x==O.start.row){O.addFold(f),o=!0;break}else if(m==O.end.row){if(O.addFold(f),o=!0,!f.sameRow){var E=d[P+1];if(E&&E.start.row==x){O.merge(E);break}}break}else if(x<=O.start.row)break}return o||(O=this.$addFoldLine(new g(this.$foldData,f))),this.$useWrapMode?this.$updateWrapData(O.start.row,O.start.row):this.$updateRowLengthCache(O.start.row,O.start.row),this.$modified=!0,this._signal("changeFold",{data:f,action:"add"}),f},this.addFolds=function(l){l.forEach(function(u){this.addFold(u)},this)},this.removeFold=function(l){var u=l.foldLine,d=u.start.row,o=u.end.row,f=this.$foldData,m=u.folds;if(m.length==1)f.splice(f.indexOf(u),1);else if(u.range.isEnd(l.end.row,l.end.column))m.pop(),u.end.row=m[m.length-1].end.row,u.end.column=m[m.length-1].end.column;else if(u.range.isStart(l.start.row,l.start.column))m.shift(),u.start.row=m[0].start.row,u.start.column=m[0].start.column;else if(l.sameRow)m.splice(m.indexOf(l),1);else{var w=u.split(l.start.row,l.start.column);m=w.folds,m.shift(),w.start.row=m[0].start.row,w.start.column=m[0].start.column}this.$updating||(this.$useWrapMode?this.$updateWrapData(d,o):this.$updateRowLengthCache(d,o)),this.$modified=!0,this._signal("changeFold",{data:l,action:"remove"})},this.removeFolds=function(l){for(var u=[],d=0;d<l.length;d++)u.push(l[d]);u.forEach(function(o){this.removeFold(o)},this),this.$modified=!0},this.expandFold=function(l){this.removeFold(l),l.subFolds.forEach(function(u){l.restoreRange(u),this.addFold(u)},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(u){this.expandFold(u)},this)},this.unfold=function(l,u){var d,o;if(l==null)d=new h(0,0,this.getLength(),0),u==null&&(u=!0);else if(typeof l=="number")d=new h(l,0,l,this.getLine(l).length);else if("row"in l)d=h.fromPoints(l,l);else{if(Array.isArray(l))return o=[],l.forEach(function(m){o=o.concat(this.unfold(m))},this),o;d=l}o=this.getFoldsInRangeList(d);for(var f=o;o.length==1&&h.comparePoints(o[0].start,d.start)<0&&h.comparePoints(o[0].end,d.end)>0;)this.expandFolds(o),o=this.getFoldsInRangeList(d);if(u!=!1?this.removeFolds(o):this.expandFolds(o),f.length)return f},this.isRowFolded=function(l,u){return!!this.getFoldLine(l,u)},this.getRowFoldEnd=function(l,u){var d=this.getFoldLine(l,u);return d?d.end.row:l},this.getRowFoldStart=function(l,u){var d=this.getFoldLine(l,u);return d?d.start.row:l},this.getFoldDisplayLine=function(l,u,d,o,f){o==null&&(o=l.start.row),f==null&&(f=0),u==null&&(u=l.end.row),d==null&&(d=this.getLine(u).length);var m=this.doc,w="";return l.walk(function(x,R,T,_){if(!(R<o)){if(R==o){if(T<f)return;_=Math.max(f,_)}x!=null?w+=x:w+=m.getLine(R).substring(_,T)}},u,d),w},this.getDisplayLine=function(l,u,d,o){var f=this.getFoldLine(l);if(f)return this.getFoldDisplayLine(f,l,u,d,o);var m;return m=this.doc.getLine(l),m.substring(o||0,u||m.length)},this.$cloneFoldData=function(){var l=[];return l=this.$foldData.map(function(u){var d=u.folds.map(function(o){return o.clone()});return new g(l,d)}),l},this.toggleFold=function(l){var u=this.selection,d=u.getRange(),o,f;if(d.isEmpty()){var m=d.start;if(o=this.getFoldAt(m.row,m.column),o){this.expandFold(o);return}else if(l){var w=this.getFoldLine(m.row);w&&this.expandFolds(w.folds);return}else(f=this.findMatchingBracket(m))?d.comparePoint(f)==1?d.end=f:(d.start=f,d.start.column++,d.end.column--):(f=this.findMatchingBracket({row:m.row,column:m.column+1}))?(d.comparePoint(f)==1?d.end=f:d.start=f,d.start.column++):d=this.getCommentFoldRange(m.row,m.column)||d}else{var x=this.getFoldsInRange(d);if(l&&x.length){this.expandFolds(x);return}else x.length==1&&(o=x[0])}if(o||(o=this.getFoldAt(d.start.row,d.start.column)),o&&o.range.toString()==d.toString()){this.expandFold(o);return}var R="...";if(!d.isMultiLine()){if(R=this.getTextRange(d),R.length<4)return;R=R.trim().substring(0,2)+".."}this.addFold(R,d)},this.getCommentFoldRange=function(l,u,d){var o=new s(this,l,u),f=o.getCurrentToken(),m=f&&f.type;if(f&&/^comment|string/.test(m)){m=m.match(/comment|string/)[0],m=="comment"&&(m+="|doc-start|\\.doc");var w=new RegExp(m),x=new h;if(d!=1){do f=o.stepBackward();while(f&&w.test(f.type));f=o.stepForward()}x.start.row=o.getCurrentTokenRow(),x.start.column=o.getCurrentTokenColumn()+f.value.length,o=new s(this,l,u);var R=this.getState(o.$row);if(d!=-1){var T=-1;do if(f=o.stepForward(),T==-1){var _=this.getState(o.$row);R.toString()!==_.toString()&&(T=o.$row)}else if(o.$row>T)break;while(f&&w.test(f.type));f=o.stepBackward()}else f=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,u,d,o){d==null&&(d=1e5);var f=this.foldWidgets;if(f){u=u||this.getLength(),l=l||0;for(var m=l;m<u;m++)if(f[m]==null&&(f[m]=this.getFoldWidget(m)),f[m]=="start"&&!(o&&!o(m))){var w=this.getFoldWidgetRange(m);w&&w.isMultiLine()&&w.end.row<=u&&w.start.row>=l&&(m=w.end.row,w.collapseChildren=d,this.addFold("...",w))}}},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(u){for(var d=l.getTokens(u),o=0;o<d.length;o++){var f=d[o];if(!(f.type=="text"&&/^\s+$/.test(f.value)))return!!/comment/.test(f.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 u=this.$foldMode;this.$setFolding(null),this.$setFolding(u)}},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,u){var d=this.foldWidgets;if(!d||u&&d[l])return{};for(var o=l-1,f;o>=0;){var m=d[o];if(m==null&&(m=d[o]=this.getFoldWidget(o)),m=="start"){var w=this.getFoldWidgetRange(o);if(f||(f=w),w&&w.end.row>=l)break}o--}return{range:o!==-1&&w,firstRange:f}},this.onFoldWidgetClick=function(l,u){u instanceof p&&(u=u.domEvent);var d={children:u.shiftKey,all:u.ctrlKey||u.metaKey,siblings:u.altKey},o=this.$toggleFoldWidget(l,d);if(!o){var f=u.target||u.srcElement;f&&/ace_fold-widget/.test(f.className)&&(f.className+=" ace_invalid")}},this.$toggleFoldWidget=function(l,u){if(this.getFoldWidget){var d=this.getFoldWidget(l),o=this.getLine(l),f=d==="end"?-1:1,m=this.getFoldAt(l,f===-1?0:o.length,f);if(m)return u.children||u.all?this.removeFold(m):this.expandFold(m),m;var w=this.getFoldWidgetRange(l,!0);if(w&&!w.isMultiLine()&&(m=this.getFoldAt(w.start.row,w.start.column,1),m&&w.isEqual(m.range)))return this.removeFold(m),m;if(u.siblings){var x=this.getParentFoldRangeData(l);if(x.range)var R=x.range.start.row+1,T=x.range.end.row;this.foldAll(R,T,u.all?1e4:0)}else u.children?(T=w?w.end.row:this.getLength(),this.foldAll(l+1,T,u.all?1e4:0)):w&&(u.all&&(w.collapseChildren=1e4),this.addFold("...",w));return w}},this.toggleFoldWidget=function(l){var u=this.selection.getCursor().row;u=this.getRowFoldStart(u);var d=this.$toggleFoldWidget(u,{});if(!d){var o=this.getParentFoldRangeData(u,!0);if(d=o.range||o.firstRange,d){u=d.start.row;var f=this.getFoldAt(u,this.getLine(u).length,1);f?this.removeFold(f):this.addFold("...",d)}}},this.updateFoldWidgets=function(l){var u=l.start.row,d=l.end.row-u;if(d===0)this.foldWidgets[u]=null;else if(l.action=="remove")this.foldWidgets.splice(u,d+1,null);else{var o=Array(d+1);o.unshift(u,1),this.foldWidgets.splice.apply(this.foldWidgets,o)}},this.tokenizerUpdateFoldWidgets=function(l){var u=l.data;u.first!=u.last&&this.foldWidgets.length>u.first&&this.foldWidgets.splice(u.first,this.foldWidgets.length)}}r.Folding=a}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(t,r,c){var h=t("../token_iterator").TokenIterator,g=t("../range").Range;function v(){this.findMatchingBracket=function(s,p){if(s.column==0)return null;var a=p||this.getLine(s.row).charAt(s.column-1);if(a=="")return null;var l=a.match(/([\(\[\{])|([\)\]\}])/);return l?l[1]?this.$findClosingBracket(l[1],s):this.$findOpeningBracket(l[2],s):null},this.getBracketRange=function(s){var p=this.getLine(s.row),a=!0,l,u=p.charAt(s.column-1),d=u&&u.match(/([\(\[\{])|([\)\]\}])/);if(d||(u=p.charAt(s.column),s={row:s.row,column:s.column+1},d=u&&u.match(/([\(\[\{])|([\)\]\}])/),a=!1),!d)return null;if(d[1]){var o=this.$findClosingBracket(d[1],s);if(!o)return null;l=g.fromPoints(s,o),a||(l.end.column++,l.start.column--),l.cursor=l.end}else{var o=this.$findOpeningBracket(d[2],s);if(!o)return null;l=g.fromPoints(o,s),a||(l.start.column++,l.end.column--),l.cursor=l.start}return l},this.getMatchingBracketRanges=function(s,p){var a=this.getLine(s.row),l=/([\(\[\{])|([\)\]\}])/,u=!p&&a.charAt(s.column-1),d=u&&u.match(l);if(d||(u=(p===void 0||p)&&a.charAt(s.column),s={row:s.row,column:s.column+1},d=u&&u.match(l)),!d)return null;var o=new g(s.row,s.column-1,s.row,s.column),f=d[1]?this.$findClosingBracket(d[1],s):this.$findOpeningBracket(d[2],s);if(!f)return[o];var m=new g(f.row,f.column,f.row,f.column+1);return[o,m]},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(s,p,a){var l=this.$brackets[s],u=1,d=new h(this,p.row,p.column),o=d.getCurrentToken();if(o||(o=d.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 f=p.column-d.getCurrentTokenColumn()-2,m=o.value;;){for(;f>=0;){var w=m.charAt(f);if(w==l){if(u-=1,u==0)return{row:d.getCurrentTokenRow(),column:f+d.getCurrentTokenColumn()}}else w==s&&(u+=1);f-=1}do o=d.stepBackward();while(o&&!a.test(o.type));if(o==null)break;m=o.value,f=m.length-1}return null}},this.$findClosingBracket=function(s,p,a){var l=this.$brackets[s],u=1,d=new h(this,p.row,p.column),o=d.getCurrentToken();if(o||(o=d.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 f=p.column-d.getCurrentTokenColumn();;){for(var m=o.value,w=m.length;f<w;){var x=m.charAt(f);if(x==l){if(u-=1,u==0)return{row:d.getCurrentTokenRow(),column:f+d.getCurrentTokenColumn()}}else x==s&&(u+=1);f+=1}do o=d.stepForward();while(o&&!a.test(o.type));if(o==null)break;f=0}return null}},this.getMatchingTags=function(s){var p=new h(this,s.row,s.column),a=this.$findTagName(p);if(a){var l=p.stepBackward();return l.value==="<"?this.$findClosingTag(p,a):this.$findOpeningTag(p,a)}},this.$findTagName=function(s){var p=s.getCurrentToken(),a=!1,l=!1;if(p&&p.type.indexOf("tag-name")===-1)do l?p=s.stepBackward():p=s.stepForward(),p&&(p.value==="/>"?l=!0:p.type.indexOf("tag-name")!==-1&&(a=!0));while(p&&!a);return p},this.$findClosingTag=function(s,p){var a,l=p.value,u=p.value,d=0,o=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);p=s.stepForward();var f=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+p.value.length),m=!1;do{if(a=p,a.type.indexOf("tag-close")!==-1&&!m){var w=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);m=!0}if(p=s.stepForward(),p){if(p.value===">"&&!m){var w=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);m=!0}if(p.type.indexOf("tag-name")!==-1){if(l=p.value,u===l){if(a.value==="<")d++;else if(a.value==="</"&&(d--,d<0)){s.stepBackward();var x=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+2);p=s.stepForward();var R=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+p.value.length);if(p.type.indexOf("tag-close")===-1&&(p=s.stepForward()),p&&p.value===">")var T=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);else return}}}else if(u===l&&p.value==="/>"&&(d--,d<0))var x=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+2),R=x,T=R,w=new g(f.end.row,f.end.column,f.end.row,f.end.column+1)}}while(p&&d>=0);if(o&&w&&x&&T&&f&&R)return{openTag:new g(o.start.row,o.start.column,w.end.row,w.end.column),closeTag:new g(x.start.row,x.start.column,T.end.row,T.end.column),openTagName:f,closeTagName:R}},this.$findOpeningTag=function(s,p){var a=s.getCurrentToken(),l=p.value,u=0,d=s.getCurrentTokenRow(),o=s.getCurrentTokenColumn(),f=o+2,m=new g(d,o,d,f);s.stepForward();var w=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+p.value.length);if(p.type.indexOf("tag-close")===-1&&(p=s.stepForward()),!(!p||p.value!==">")){var x=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);s.stepBackward(),s.stepBackward();do if(p=a,d=s.getCurrentTokenRow(),o=s.getCurrentTokenColumn(),f=o+p.value.length,a=s.stepBackward(),p){if(p.type.indexOf("tag-name")!==-1){if(l===p.value)if(a.value==="<"){if(u++,u>0){var R=new g(d,o,d,f),T=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1);do p=s.stepForward();while(p&&p.value!==">");var _=new g(s.getCurrentTokenRow(),s.getCurrentTokenColumn(),s.getCurrentTokenRow(),s.getCurrentTokenColumn()+1)}}else a.value==="</"&&u--}else if(p.value==="/>"){for(var C=0,P=a;P;){if(P.type.indexOf("tag-name")!==-1&&P.value===l){u--;break}else if(P.value==="<")break;P=s.stepBackward(),C++}for(var O=0;O<C;O++)s.stepForward()}}while(a&&u<=0);if(T&&_&&m&&x&&R&&w)return{openTag:new g(T.start.row,T.start.column,_.end.row,_.end.column),closeTag:new g(m.start.row,m.start.column,x.end.row,x.end.column),openTagName:R,closeTagName:w}}}}r.BracketMatch=v}),ace.define("ace/edit_session",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/bidihandler","ace/config","ace/lib/event_emitter","ace/selection","ace/mode/text","ace/range","ace/line_widgets","ace/document","ace/background_tokenizer","ace/search_highlight","ace/undomanager","ace/edit_session/folding","ace/edit_session/bracket_match"],function(t,r,c){var h=t("./lib/oop"),g=t("./lib/lang"),v=t("./bidihandler").BidiHandler,s=t("./config"),p=t("./lib/event_emitter").EventEmitter,a=t("./selection").Selection,l=t("./mode/text").Mode,u=t("./range").Range,d=t("./line_widgets").LineWidgets,o=t("./document").Document,f=t("./background_tokenizer").BackgroundTokenizer,m=t("./search_highlight").SearchHighlight,w=t("./undomanager").UndoManager,x=(function(){function N(M,$){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"+ ++N.$uid,this.$foldData.toString=function(){return this.join(`
200
+ `)},this.$gutterCustomWidgets={},this.bgTokenizer=new f(new l().getTokenizer(),this);var A=this;this.bgTokenizer.on("update",function(D){A._signal("tokenizerUpdate",D)}),this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this),(typeof M!="object"||!M.getLine)&&(M=new o(M)),this.setDocument(M),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 v(this),s.resetOptions(this),this.setMode($),s._signal("session",this),this.destroyed=!1,this.$initOperationListeners()}return N.prototype.$initOperationListeners=function(){var M=this;this.curOp=null,this.on("change",function(){M.curOp||(M.startOperation(),M.curOp.selectionBefore=M.$lastSel),M.curOp.docChanged=!0},!0),this.on("changeSelection",function(){M.curOp||(M.startOperation(),M.curOp.selectionBefore=M.$lastSel),M.curOp.selectionChanged=!0},!0),this.$operationResetTimer=g.delayedCall(this.endOperation.bind(this,!0))},N.prototype.startOperation=function(M){if(this.curOp){if(!M||this.curOp.command)return;this.prevOp=this.curOp}M||(M={}),this.$operationResetTimer.schedule(),this.curOp={command:M.command||{},args:M.args},this.curOp.selectionBefore=this.selection.toJSON(),this._signal("startOperation",M)},N.prototype.endOperation=function(M){if(this.curOp){if(M&&M.returnValue===!1){this.curOp=null,this._signal("endOperation",M);return}if(M==!0&&this.curOp.command&&this.curOp.command.name=="mouse")return;var $=this.selection.toJSON();this.curOp.selectionAfter=$,this.$lastSel=this.selection.toJSON(),this.getUndoManager().addSelection($),this._signal("beforeEndOperation"),this.prevOp=this.curOp,this.curOp=null,this._signal("endOperation",M)}},N.prototype.setDocument=function(M){this.doc&&this.doc.off("change",this.$onChange),this.doc=M,M.on("change",this.$onChange,!0),this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},N.prototype.getDocument=function(){return this.doc},Object.defineProperty(N.prototype,"widgetManager",{get:function(){var M=new d(this);return this.widgetManager=M,this.$editor&&M.attach(this.$editor),M},set:function(M){Object.defineProperty(this,"widgetManager",{writable:!0,enumerable:!0,configurable:!0,value:M})},enumerable:!1,configurable:!0}),N.prototype.$resetRowCache=function(M){if(!M){this.$docRowCache=[],this.$screenRowCache=[];return}var $=this.$docRowCache.length,A=this.$getRowCacheIndex(this.$docRowCache,M)+1;$>A&&(this.$docRowCache.splice(A,$),this.$screenRowCache.splice(A,$))},N.prototype.$getRowCacheIndex=function(M,$){for(var A=0,D=M.length-1;A<=D;){var j=A+D>>1,U=M[j];if($>U)A=j+1;else if($<U)D=j-1;else return j}return A-1},N.prototype.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.destroyed||this.bgTokenizer.start(0)},N.prototype.onChangeFold=function(M){var $=M.data;this.$resetRowCache($.start.row)},N.prototype.onChange=function(M){this.$modified=!0,this.$bidiHandler.onChange(M),this.$resetRowCache(M.start.row);var $=this.$updateInternalDataOnChange(M);!this.$fromUndo&&this.$undoManager&&($&&$.length&&(this.$undoManager.add({action:"removeFolds",folds:$},this.mergeUndoDeltas),this.mergeUndoDeltas=!0),this.$undoManager.add(M,this.mergeUndoDeltas),this.mergeUndoDeltas=!0,this.$informUndoManager.schedule()),this.bgTokenizer.$updateOnChange(M),this._signal("change",M)},N.prototype.onSelectionChange=function(){this._signal("changeSelection")},N.prototype.setValue=function(M){this.doc.setValue(M),this.selection.moveTo(0,0),this.$resetRowCache(0),this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},N.fromJSON=function(M){typeof M=="string"&&(M=JSON.parse(M));var $=new w;M.history&&($.$undoStack=M.history.$undoStack||[],$.$redoStack=M.history.$redoStack||[],$.mark=M.history.mark||0,$.$rev=M.history.rev||0);var A=new N(M.value);return M.folds.forEach(function(D){A.addFold("...",u.fromPoints(D.start,D.end))}),A.setAnnotations(M.annotations),A.setBreakpoints(M.breakpoints),A.setMode(M.mode),A.setScrollLeft(M.scrollLeft),A.setScrollTop(M.scrollTop),A.setUndoManager($),A.selection.fromJSON(M.selection),A},N.prototype.toJSON=function(){return{annotations:this.$annotations,breakpoints:this.$breakpoints,folds:this.getAllFolds().map(function(M){return M.range}),history:this.getUndoManager(),mode:this.$mode.$id,scrollLeft:this.$scrollLeft,scrollTop:this.$scrollTop,selection:this.selection.toJSON(),value:this.doc.getValue()}},N.prototype.toString=function(){return this.doc.getValue()},N.prototype.getSelection=function(){return this.selection},N.prototype.getState=function(M){return this.bgTokenizer.getState(M)},N.prototype.getTokens=function(M){return this.bgTokenizer.getTokens(M)},N.prototype.getTokenAt=function(M,$){var A=this.bgTokenizer.getTokens(M),D,j=0;if($==null){var U=A.length-1;j=this.getLine(M).length}else for(var U=0;U<A.length&&(j+=A[U].value.length,!(j>=$));U++);return D=A[U],D?(D.index=U,D.start=j-D.value.length,D):null},N.prototype.setUndoManager=function(M){if(this.$undoManager=M,this.$informUndoManager&&this.$informUndoManager.cancel(),M){var $=this;M.addSession(this),this.$syncInformUndoManager=function(){$.$informUndoManager.cancel(),$.mergeUndoDeltas=!1},this.$informUndoManager=g.delayedCall(this.$syncInformUndoManager)}else this.$syncInformUndoManager=function(){}},N.prototype.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},N.prototype.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},N.prototype.getTabString=function(){return this.getUseSoftTabs()?g.stringRepeat(" ",this.getTabSize()):" "},N.prototype.setUseSoftTabs=function(M){this.setOption("useSoftTabs",M)},N.prototype.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},N.prototype.setTabSize=function(M){this.setOption("tabSize",M)},N.prototype.getTabSize=function(){return this.$tabSize},N.prototype.isTabStop=function(M){return this.$useSoftTabs&&M.column%this.$tabSize===0},N.prototype.setNavigateWithinSoftTabs=function(M){this.setOption("navigateWithinSoftTabs",M)},N.prototype.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},N.prototype.setOverwrite=function(M){this.setOption("overwrite",M)},N.prototype.getOverwrite=function(){return this.$overwrite},N.prototype.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},N.prototype.addGutterDecoration=function(M,$){this.$decorations[M]||(this.$decorations[M]=""),this.$decorations[M]+=" "+$,this._signal("changeBreakpoint",{})},N.prototype.removeGutterCustomWidget=function(M){this.$editor&&this.$editor.renderer.$gutterLayer.$removeCustomWidget(M)},N.prototype.addGutterCustomWidget=function(M,$){this.$editor&&this.$editor.renderer.$gutterLayer.$addCustomWidget(M,$)},N.prototype.removeGutterDecoration=function(M,$){this.$decorations[M]=(this.$decorations[M]||"").replace(" "+$,""),this._signal("changeBreakpoint",{})},N.prototype.getBreakpoints=function(){return this.$breakpoints},N.prototype.setBreakpoints=function(M){this.$breakpoints=[];for(var $=0;$<M.length;$++)this.$breakpoints[M[$]]="ace_breakpoint";this._signal("changeBreakpoint",{})},N.prototype.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},N.prototype.setBreakpoint=function(M,$){$===void 0&&($="ace_breakpoint"),$?this.$breakpoints[M]=$:delete this.$breakpoints[M],this._signal("changeBreakpoint",{})},N.prototype.clearBreakpoint=function(M){delete this.$breakpoints[M],this._signal("changeBreakpoint",{})},N.prototype.addMarker=function(M,$,A,D){var j=this.$markerId++,U={range:M,type:A||"line",renderer:typeof A=="function"?A:null,clazz:$,inFront:!!D,id:j};return D?(this.$frontMarkers[j]=U,this._signal("changeFrontMarker")):(this.$backMarkers[j]=U,this._signal("changeBackMarker")),j},N.prototype.addDynamicMarker=function(M,$){if(M.update){var A=this.$markerId++;return M.id=A,M.inFront=!!$,$?(this.$frontMarkers[A]=M,this._signal("changeFrontMarker")):(this.$backMarkers[A]=M,this._signal("changeBackMarker")),M}},N.prototype.removeMarker=function(M){var $=this.$frontMarkers[M]||this.$backMarkers[M];if($){var A=$.inFront?this.$frontMarkers:this.$backMarkers;delete A[M],this._signal($.inFront?"changeFrontMarker":"changeBackMarker")}},N.prototype.getMarkers=function(M){return M?this.$frontMarkers:this.$backMarkers},N.prototype.highlight=function(M){if(!this.$searchHighlight){var $=new m(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker($)}this.$searchHighlight.setRegexp(M)},N.prototype.highlightLines=function(M,$,A,D){typeof $!="number"&&(A=$,$=M),A||(A="ace_step");var j=new u(M,0,$,1/0);return j.id=this.addMarker(j,A,"fullLine",D),j},N.prototype.setAnnotations=function(M){this.$annotations=M,this._signal("changeAnnotation",{})},N.prototype.getAnnotations=function(){return this.$annotations||[]},N.prototype.clearAnnotations=function(){this.setAnnotations([])},N.prototype.$detectNewLine=function(M){var $=M.match(/^.*?(\r?\n)/m);$?this.$autoNewLine=$[1]:this.$autoNewLine=`
201
+ `},N.prototype.getWordRange=function(M,$){var A=this.getLine(M),D=!1;if($>0&&(D=!!A.charAt($-1).match(this.tokenRe)),D||(D=!!A.charAt($).match(this.tokenRe)),D)var j=this.tokenRe;else if(/^\s+$/.test(A.slice($-1,$+1)))var j=/\s/;else var j=this.nonTokenRe;var U=$;if(U>0){do U--;while(U>=0&&A.charAt(U).match(j));U++}for(var q=$;q<A.length&&A.charAt(q).match(j);)q++;return new u(M,U,M,q)},N.prototype.getAWordRange=function(M,$){for(var A=this.getWordRange(M,$),D=this.getLine(A.end.row);D.charAt(A.end.column).match(/[ \t]/);)A.end.column+=1;return A},N.prototype.setNewLineMode=function(M){this.doc.setNewLineMode(M)},N.prototype.getNewLineMode=function(){return this.doc.getNewLineMode()},N.prototype.setUseWorker=function(M){this.setOption("useWorker",M)},N.prototype.getUseWorker=function(){return this.$useWorker},N.prototype.onReloadTokenizer=function(M){var $=M.data;this.bgTokenizer.start($.first),this._signal("tokenizerUpdate",M)},N.prototype.setMode=function(M,$){if(M&&typeof M=="object"){if(M.getTokenizer)return this.$onChangeMode(M);var A=M,D=A.path}else D=M||"ace/mode/text";if(this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new l),this.$modes[D]&&!A){this.$onChangeMode(this.$modes[D]),$&&$();return}this.$modeId=D,s.loadModule(["mode",D],(function(j){if(!this.destroyed){if(this.$modeId!==D)return $&&$();this.$modes[D]&&!A?this.$onChangeMode(this.$modes[D]):j&&j.Mode&&(j=new j.Mode(A),A||(this.$modes[D]=j,j.$id=D),this.$onChangeMode(j)),$&&$()}}).bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0)},N.prototype.$onChangeMode=function(M,$){if($||(this.$modeId=M.$id),this.$mode!==M){var A=this.$mode;this.$mode=M,this.$stopWorker(),this.$useWorker&&this.$startWorker();var D=M.getTokenizer();if(D.on!==void 0){var j=this.onReloadTokenizer.bind(this);D.on("update",j)}this.bgTokenizer.setTokenizer(D),this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=M.tokenRe,this.nonTokenRe=M.nonTokenRe,$||(M.attachToSession&&M.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(M.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode",{oldMode:A,mode:M}))}},N.prototype.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},N.prototype.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(M){s.warn("Could not load worker",M),this.$worker=null}},N.prototype.getMode=function(){return this.$mode},N.prototype.setScrollTop=function(M){this.$scrollTop===M||isNaN(M)||(this.$scrollTop=M,this._signal("changeScrollTop",M))},N.prototype.getScrollTop=function(){return this.$scrollTop},N.prototype.setScrollLeft=function(M){this.$scrollLeft===M||isNaN(M)||(this.$scrollLeft=M,this._signal("changeScrollLeft",M))},N.prototype.getScrollLeft=function(){return this.$scrollLeft},N.prototype.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},N.prototype.getLineWidgetMaxWidth=function(){if(this.lineWidgetsWidth!=null)return this.lineWidgetsWidth;var M=0;return this.lineWidgets.forEach(function($){$&&$.screenWidth>M&&(M=$.screenWidth)}),this.lineWidgetWidth=M},N.prototype.$computeWidth=function(M){if(this.$modified||M){if(this.$modified=!1,this.$useWrapMode)return this.screenWidth=this.$wrapLimit;for(var $=this.doc.getAllLines(),A=this.$rowLengthCache,D=0,j=0,U=this.$foldData[j],q=U?U.start.row:1/0,Q=$.length,re=0;re<Q;re++){if(re>q){if(re=U.end.row+1,re>=Q)break;U=this.$foldData[j++],q=U?U.start.row:1/0}A[re]==null&&(A[re]=this.$getStringScreenWidth($[re])[0]),A[re]>D&&(D=A[re])}this.screenWidth=D}},N.prototype.getLine=function(M){return this.doc.getLine(M)},N.prototype.getLines=function(M,$){return this.doc.getLines(M,$)},N.prototype.getLength=function(){return this.doc.getLength()},N.prototype.getTextRange=function(M){return this.doc.getTextRange(M||this.selection.getRange())},N.prototype.insert=function(M,$){return this.doc.insert(M,$)},N.prototype.remove=function(M){return this.doc.remove(M)},N.prototype.removeFullLines=function(M,$){return this.doc.removeFullLines(M,$)},N.prototype.undoChanges=function(M,$){if(M.length){this.$fromUndo=!0;for(var A=M.length-1;A!=-1;A--){var D=M[A];D.action=="insert"||D.action=="remove"?this.doc.revertDelta(D):D.folds&&this.addFolds(D.folds)}!$&&this.$undoSelect&&(M.selectionBefore?this.selection.fromJSON(M.selectionBefore):this.selection.setRange(this.$getUndoSelection(M,!0))),this.$fromUndo=!1}},N.prototype.redoChanges=function(M,$){if(M.length){this.$fromUndo=!0;for(var A=0;A<M.length;A++){var D=M[A];(D.action=="insert"||D.action=="remove")&&this.doc.$safeApplyDelta(D)}!$&&this.$undoSelect&&(M.selectionAfter?this.selection.fromJSON(M.selectionAfter):this.selection.setRange(this.$getUndoSelection(M,!1))),this.$fromUndo=!1}},N.prototype.setUndoSelect=function(M){this.$undoSelect=M},N.prototype.$getUndoSelection=function(M,$){function A(Q){return $?Q.action!=="insert":Q.action==="insert"}for(var D,j,U=0;U<M.length;U++){var q=M[U];if(q.start){if(!D){A(q)?D=u.fromPoints(q.start,q.end):D=u.fromPoints(q.start,q.start);continue}A(q)?(j=q.start,D.compare(j.row,j.column)==-1&&D.setStart(j),j=q.end,D.compare(j.row,j.column)==1&&D.setEnd(j)):(j=q.start,D.compare(j.row,j.column)==-1&&(D=u.fromPoints(q.start,q.start)))}}return D},N.prototype.replace=function(M,$){return this.doc.replace(M,$)},N.prototype.moveText=function(M,$,A){var D=this.getTextRange(M),j=this.getFoldsInRange(M),U=u.fromPoints($,$);if(!A){this.remove(M);var q=M.start.row-M.end.row,Q=q?-M.end.column:M.start.column-M.end.column;Q&&(U.start.row==M.end.row&&U.start.column>M.end.column&&(U.start.column+=Q),U.end.row==M.end.row&&U.end.column>M.end.column&&(U.end.column+=Q)),q&&U.start.row>=M.end.row&&(U.start.row+=q,U.end.row+=q)}if(U.end=this.insert(U.start,D),j.length){var re=M.start,le=U.start,q=le.row-re.row,Q=le.column-re.column;this.addFolds(j.map(function(he){return he=he.clone(),he.start.row==re.row&&(he.start.column+=Q),he.end.row==re.row&&(he.end.column+=Q),he.start.row+=q,he.end.row+=q,he}))}return U},N.prototype.indentRows=function(M,$,A){A=A.replace(/\t/g,this.getTabString());for(var D=M;D<=$;D++)this.doc.insertInLine({row:D,column:0},A)},N.prototype.outdentRows=function(M){for(var $=M.collapseRows(),A=new u(0,0,0,0),D=this.getTabSize(),j=$.start.row;j<=$.end.row;++j){var U=this.getLine(j);A.start.row=j,A.end.row=j;for(var q=0;q<D&&U.charAt(q)==" ";++q);q<D&&U.charAt(q)==" "?(A.start.column=q,A.end.column=q+1):(A.start.column=0,A.end.column=q),this.remove(A)}},N.prototype.$moveLines=function(M,$,A){if(M=this.getRowFoldStart(M),$=this.getRowFoldEnd($),A<0){var D=this.getRowFoldStart(M+A);if(D<0)return 0;var j=D-M}else if(A>0){var D=this.getRowFoldEnd($+A);if(D>this.doc.getLength()-1)return 0;var j=D-$}else{M=this.$clipRowToDocument(M),$=this.$clipRowToDocument($);var j=$-M+1}var U=new u(M,0,$,Number.MAX_VALUE),q=this.getFoldsInRange(U).map(function(re){return re=re.clone(),re.start.row+=j,re.end.row+=j,re}),Q=A==0?this.doc.getLines(M,$):this.doc.removeFullLines(M,$);return this.doc.insertFullLines(M+j,Q),q.length&&this.addFolds(q),j},N.prototype.moveLinesUp=function(M,$){return this.$moveLines(M,$,-1)},N.prototype.moveLinesDown=function(M,$){return this.$moveLines(M,$,1)},N.prototype.duplicateLines=function(M,$){return this.$moveLines(M,$,0)},N.prototype.$clipRowToDocument=function(M){return Math.max(0,Math.min(M,this.doc.getLength()-1))},N.prototype.$clipColumnToRow=function(M,$){return $<0?0:Math.min(this.doc.getLine(M).length,$)},N.prototype.$clipPositionToDocument=function(M,$){if($=Math.max(0,$),M<0)M=0,$=0;else{var A=this.doc.getLength();M>=A?(M=A-1,$=this.doc.getLine(A-1).length):$=Math.min(this.doc.getLine(M).length,$)}return{row:M,column:$}},N.prototype.$clipRangeToDocument=function(M){M.start.row<0?(M.start.row=0,M.start.column=0):M.start.column=this.$clipColumnToRow(M.start.row,M.start.column);var $=this.doc.getLength()-1;return M.end.row>$?(M.end.row=$,M.end.column=this.doc.getLine($).length):M.end.column=this.$clipColumnToRow(M.end.row,M.end.column),M},N.prototype.setUseWrapMode=function(M){if(M!=this.$useWrapMode){if(this.$useWrapMode=M,this.$modified=!0,this.$resetRowCache(0),M){var $=this.getLength();this.$wrapData=Array($),this.$updateWrapData(0,$-1)}this._signal("changeWrapMode")}},N.prototype.getUseWrapMode=function(){return this.$useWrapMode},N.prototype.setWrapLimitRange=function(M,$){(this.$wrapLimitRange.min!==M||this.$wrapLimitRange.max!==$)&&(this.$wrapLimitRange={min:M,max:$},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode"))},N.prototype.adjustWrapLimit=function(M,$){var A=this.$wrapLimitRange;A.max<0&&(A={min:$,max:$});var D=this.$constrainWrapLimit(M,A.min,A.max);return D!=this.$wrapLimit&&D>1?(this.$wrapLimit=D,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0):!1},N.prototype.$constrainWrapLimit=function(M,$,A){return $&&(M=Math.max($,M)),A&&(M=Math.min(A,M)),M},N.prototype.getWrapLimit=function(){return this.$wrapLimit},N.prototype.setWrapLimit=function(M){this.setWrapLimitRange(M,M)},N.prototype.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},N.prototype.$updateInternalDataOnChange=function(M){var $=this.$useWrapMode,A=M.action,D=M.start,j=M.end,U=D.row,q=j.row,Q=q-U,re=null;if(this.$updating=!0,Q!=0)if(A==="remove"){this[$?"$wrapData":"$rowLengthCache"].splice(U,Q);var le=this.$foldData;re=this.getFoldsInRange(M),this.removeFolds(re);var ne=this.getFoldLine(j.row),ue=0;if(ne){ne.addRemoveChars(j.row,j.column,D.column-j.column),ne.shiftRow(-Q);var he=this.getFoldLine(U);he&&he!==ne&&(he.merge(ne),ne=he),ue=le.indexOf(ne)+1}for(ue;ue<le.length;ue++){var ne=le[ue];ne.start.row>=j.row&&ne.shiftRow(-Q)}q=U}else{var oe=Array(Q);oe.unshift(U,0);var ee=$?this.$wrapData:this.$rowLengthCache;ee.splice.apply(ee,oe);var le=this.$foldData,ne=this.getFoldLine(U),ue=0;if(ne){var ye=ne.range.compareInside(D.row,D.column);ye==0?(ne=ne.split(D.row,D.column),ne&&(ne.shiftRow(Q),ne.addRemoveChars(q,0,j.column-D.column))):ye==-1&&(ne.addRemoveChars(U,0,j.column-D.column),ne.shiftRow(Q)),ue=le.indexOf(ne)+1}for(ue;ue<le.length;ue++){var ne=le[ue];ne.start.row>=U&&ne.shiftRow(Q)}}else{Q=Math.abs(M.start.column-M.end.column),A==="remove"&&(re=this.getFoldsInRange(M),this.removeFolds(re),Q=-Q);var ne=this.getFoldLine(U);ne&&ne.addRemoveChars(U,D.column,Q)}return $&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,$?this.$updateWrapData(U,q):this.$updateRowLengthCache(U,q),re},N.prototype.$updateRowLengthCache=function(M,$){this.$rowLengthCache[M]=null,this.$rowLengthCache[$]=null},N.prototype.$updateWrapData=function(M,$){var A=this.doc.getAllLines(),D=this.getTabSize(),j=this.$wrapData,U=this.$wrapLimit,q,Q,re=M;for($=Math.min($,A.length-1);re<=$;)Q=this.getFoldLine(re,Q),Q?(q=[],Q.walk((function(le,ne,ue,he){var oe;if(le!=null){oe=this.$getDisplayTokens(le,q.length),oe[0]=_;for(var ee=1;ee<oe.length;ee++)oe[ee]=C}else oe=this.$getDisplayTokens(A[ne].substring(he,ue),q.length);q=q.concat(oe)}).bind(this),Q.end.row,A[Q.end.row].length+1),j[Q.start.row]=this.$computeWrapSplits(q,U,D),re=Q.end.row+1):(q=this.$getDisplayTokens(A[re]),j[re]=this.$computeWrapSplits(q,U,D),re++)},N.prototype.$computeWrapSplits=function(M,$,A){if(M.length==0)return[];var D=[],j=M.length,U=0,q=0,Q=this.$wrapAsCode,re=this.$indentedSoftWrap,le=$<=Math.max(2*A,8)||re===!1?0:Math.floor($/2);function ne(){var ye=0;if(le===0)return ye;if(re)for(var we=0;we<M.length;we++){var Ae=M[we];if(Ae==O)ye+=1;else if(Ae==E)ye+=A;else{if(Ae==k)continue;break}}return Q&&re!==!1&&(ye+=A),Math.min(ye,le)}function ue(ye){for(var we=ye-U,Ae=U;Ae<ye;Ae++){var Je=M[Ae];(Je===12||Je===2)&&(we-=1)}D.length||(he=ne(),D.indent=he),q+=we,D.push(q),U=ye}for(var he=0;j-U>$-he;){var oe=U+$-he;if(M[oe-1]>=O&&M[oe]>=O){ue(oe);continue}if(M[oe]==_||M[oe]==C){for(oe;oe!=U-1&&M[oe]!=_;oe--);if(oe>U){ue(oe);continue}for(oe=U+$,oe;oe<M.length&&M[oe]==C;oe++);if(oe==M.length)break;ue(oe);continue}for(var ee=Math.max(oe-($-($>>2)),U-1);oe>ee&&M[oe]<_;)oe--;if(Q){for(;oe>ee&&M[oe]<_;)oe--;for(;oe>ee&&M[oe]==P;)oe--}else for(;oe>ee&&M[oe]<O;)oe--;if(oe>ee){ue(++oe);continue}oe=U+$,M[oe]==T&&oe--,ue(oe-he)}return D},N.prototype.$getDisplayTokens=function(M,$){var A=[],D;$=$||0;for(var j=0;j<M.length;j++){var U=M.charCodeAt(j);if(U==9){D=this.getScreenTabSize(A.length+$),A.push(E);for(var q=1;q<D;q++)A.push(k)}else U==32?A.push(O):U>39&&U<48||U>57&&U<64?A.push(P):U>=4352&&B(U)?A.push(R,T):A.push(R)}return A},N.prototype.$getStringScreenWidth=function(M,$,A){if($==0)return[0,0];$==null&&($=1/0),A=A||0;var D,j;for(j=0;j<M.length&&(D=M.charCodeAt(j),D==9?A+=this.getScreenTabSize(A):A+=1,!(A>$));j++);return[A,j]},N.prototype.getRowLength=function(M){var $=1;return this.lineWidgets&&($+=this.lineWidgets[M]&&this.lineWidgets[M].rowCount||0),!this.$useWrapMode||!this.$wrapData[M]?$:this.$wrapData[M].length+$},N.prototype.getRowLineCount=function(M){return!this.$useWrapMode||!this.$wrapData[M]?1:this.$wrapData[M].length+1},N.prototype.getRowWrapIndent=function(M){if(this.$useWrapMode){var $=this.screenToDocumentPosition(M,Number.MAX_VALUE),A=this.$wrapData[$.row];return A.length&&A[0]<$.column?A.indent:0}else return 0},N.prototype.getScreenLastRowColumn=function(M){var $=this.screenToDocumentPosition(M,Number.MAX_VALUE);return this.documentToScreenColumn($.row,$.column)},N.prototype.getDocumentLastRowColumn=function(M,$){var A=this.documentToScreenRow(M,$);return this.getScreenLastRowColumn(A)},N.prototype.getDocumentLastRowColumnPosition=function(M,$){var A=this.documentToScreenRow(M,$);return this.screenToDocumentPosition(A,Number.MAX_VALUE/10)},N.prototype.getRowSplitData=function(M){if(this.$useWrapMode)return this.$wrapData[M]},N.prototype.getScreenTabSize=function(M){return this.$tabSize-(M%this.$tabSize|0)},N.prototype.screenToDocumentRow=function(M,$){return this.screenToDocumentPosition(M,$).row},N.prototype.screenToDocumentColumn=function(M,$){return this.screenToDocumentPosition(M,$).column},N.prototype.screenToDocumentPosition=function(M,$){if(M<0)return{row:0,column:0};var A,ne=0,D=0,j,le=0,U=0,q=this.$screenRowCache,Q=this.$getRowCacheIndex(q,M),re=q.length;if(re&&Q>=0)var le=q[Q],ne=this.$docRowCache[Q],ue=M>q[re-1];else var ue=!re;for(var he=this.getLength()-1,oe=this.getNextFoldLine(ne),ee=oe?oe.start.row:1/0;le<=M&&(U=this.getRowLength(ne),!(le+U>M||ne>=he));)le+=U,ne++,ne>ee&&(ne=oe.end.row+1,oe=this.getNextFoldLine(ne,oe),ee=oe?oe.start.row:1/0),ue&&(this.$docRowCache.push(ne),this.$screenRowCache.push(le));if(oe&&oe.start.row<=ne)A=this.getFoldDisplayLine(oe),ne=oe.start.row;else{if(le+U<=M||ne>he)return{row:he,column:this.getLine(he).length};A=this.getLine(ne),oe=null}var ye=0,we=Math.floor(M-le);if(this.$useWrapMode){var Ae=this.$wrapData[ne];Ae&&(j=Ae[we],we>0&&Ae.length&&(ye=Ae.indent,D=Ae[we-1]||Ae[Ae.length-1],A=A.substring(D)))}return D+=this.$getStringScreenWidth(A,$-ye)[1],this.$useWrapMode&&D>=j&&(D=j-1),oe?oe.idxToPosition(D):{row:ne,column:D}},N.prototype.documentToScreenPosition=function(M,$){if(typeof $>"u")var A=this.$clipPositionToDocument(M.row,M.column);else A=this.$clipPositionToDocument(M,$);M=A.row,$=A.column;var ne=0,D=null,j=null;j=this.getFoldAt(M,$,1),j&&(M=j.start.row,$=j.start.column);var U,le=0,q=this.$docRowCache,Q=this.$getRowCacheIndex(q,M),re=q.length;if(re&&Q>=0)var le=q[Q],ne=this.$screenRowCache[Q],ue=M>q[re-1];else var ue=!re;for(var he=this.getNextFoldLine(le),oe=he?he.start.row:1/0;le<M;){if(le>=oe){if(U=he.end.row+1,U>M)break;he=this.getNextFoldLine(U,he),oe=he?he.start.row:1/0}else U=le+1;ne+=this.getRowLength(le),le=U,ue&&(this.$docRowCache.push(le),this.$screenRowCache.push(ne))}var ee="";he&&le>=oe?(ee=this.getFoldDisplayLine(he,M,$),D=he.start.row):(ee=this.getLine(M).substring(0,$),D=M);var ye=0;if(this.$useWrapMode){var we=this.$wrapData[D];if(we){for(var Ae=0;ee.length>=we[Ae];)ne++,Ae++;ee=ee.substring(we[Ae-1]||0,ee.length),ye=Ae>0?we.indent:0}}return this.lineWidgets&&this.lineWidgets[le]&&this.lineWidgets[le].rowsAbove&&(ne+=this.lineWidgets[le].rowsAbove),{row:ne,column:ye+this.$getStringScreenWidth(ee)[0]}},N.prototype.documentToScreenColumn=function(M,$){return this.documentToScreenPosition(M,$).column},N.prototype.documentToScreenRow=function(M,$){return this.documentToScreenPosition(M,$).row},N.prototype.getScreenLength=function(){var M=0,$=null;if(this.$useWrapMode)for(var A=this.$wrapData.length,D=0,j=0,$=this.$foldData[j++],U=$?$.start.row:1/0;D<A;){var q=this.$wrapData[D];M+=q?q.length+1:1,D++,D>U&&(D=$.end.row+1,$=this.$foldData[j++],U=$?$.start.row:1/0)}else{M=this.getLength();for(var Q=this.$foldData,j=0;j<Q.length;j++)$=Q[j],M-=$.end.row-$.start.row}return this.lineWidgets&&(M+=this.$getWidgetScreenLength()),M},N.prototype.$setFontMetrics=function(M){this.$enableVarChar&&(this.$getStringScreenWidth=function($,A,D){if(A===0)return[0,0];A||(A=1/0),D=D||0;var j,U;for(U=0;U<$.length&&(j=$.charAt(U),j===" "?D+=this.getScreenTabSize(D):D+=M.getCharacterWidth(j),!(D>A));U++);return[D,U]})},N.prototype.getPrecedingCharacter=function(){var M=this.selection.getCursor();if(M.column===0)return M.row===0?"":this.doc.getNewLineCharacter();var $=this.getLine(M.row);return $[M.column-1]},N.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()},N})();x.$uid=0,x.prototype.$modes=s.$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=B,h.implement(x.prototype,p);var R=1,T=2,_=3,C=4,P=9,O=10,E=11,k=12;function B(N){return N<4352?!1:N>=4352&&N<=4447||N>=4515&&N<=4519||N>=4602&&N<=4607||N>=9001&&N<=9002||N>=11904&&N<=11929||N>=11931&&N<=12019||N>=12032&&N<=12245||N>=12272&&N<=12283||N>=12288&&N<=12350||N>=12353&&N<=12438||N>=12441&&N<=12543||N>=12549&&N<=12589||N>=12593&&N<=12686||N>=12688&&N<=12730||N>=12736&&N<=12771||N>=12784&&N<=12830||N>=12832&&N<=12871||N>=12880&&N<=13054||N>=13056&&N<=19903||N>=19968&&N<=42124||N>=42128&&N<=42182||N>=43360&&N<=43388||N>=44032&&N<=55203||N>=55216&&N<=55238||N>=55243&&N<=55291||N>=63744&&N<=64255||N>=65040&&N<=65049||N>=65072&&N<=65106||N>=65108&&N<=65126||N>=65128&&N<=65131||N>=65281&&N<=65376||N>=65504&&N<=65510}t("./edit_session/folding").Folding.call(x.prototype),t("./edit_session/bracket_match").BracketMatch.call(x.prototype),s.defineOptions(x.prototype,"session",{wrap:{set:function(N){if(!N||N=="off"?N=!1:N=="free"?N=!0:N=="printMargin"?N=-1:typeof N=="string"&&(N=parseInt(N,10)||!1),this.$wrap!=N)if(this.$wrap=N,!N)this.setUseWrapMode(!1);else{var M=typeof N=="number"?N:null;this.setWrapLimitRange(M,M),this.setUseWrapMode(!0)}},get:function(){return this.getUseWrapMode()?this.$wrap==-1?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(N){N=N=="auto"?this.$mode.type!="text":N!="text",N!=this.$wrapAsCode&&(this.$wrapAsCode=N,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(N){this.$useWorker=N,this.$stopWorker(),N&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(N){N=parseInt(N),N>0&&this.$tabSize!==N&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=N,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(N){this.setFoldStyle(N)},handlesSet:!0},overwrite:{set:function(N){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(N){this.doc.setNewLineMode(N)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(N){this.setMode(N)},get:function(){return this.$modeId},handlesSet:!0}}),r.EditSession=x}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(t,r,c){var h=t("./lib/lang"),g=t("./lib/oop"),v=t("./range").Range,s=(function(){function u(){this.$options={}}return u.prototype.set=function(d){return g.mixin(this.$options,d),this},u.prototype.getOptions=function(){return h.copyObject(this.$options)},u.prototype.setOptions=function(d){this.$options=d},u.prototype.find=function(d){var o=this.$options,f=this.$matchIterator(d,o);if(!f)return!1;var m=null;return f.forEach(function(w,x,R,T){return m=new v(w,x,R,T),x==T&&o.start&&o.start.start&&o.skipCurrent!=!1&&m.isEqual(o.start)?(m=null,!1):!0}),m},u.prototype.findAll=function(d){var o=this.$options;if(!o.needle)return[];this.$assembleRegExp(o);var f=o.range,m=f?d.getLines(f.start.row,f.end.row):d.doc.getAllLines(),w=[],x=o.re;if(o.$isMultiLine){var R=x.length,T=m.length-R,_;e:for(var C=x.offset||0;C<=T;C++){for(var P=0;P<R;P++)if(m[C+P].search(x[P])==-1)continue e;var O=m[C],E=m[C+R-1],k=O.length-O.match(x[0])[0].length,B=E.match(x[R-1])[0].length;_&&_.end.row===C&&_.end.column>k||(w.push(_=new v(C,k,C+R-1,B)),R>2&&(C=C+R-2))}}else for(var N,M=0;M<m.length;M++)if(this.$isMultilineSearch(o)){var $=m.length-1;if(N=this.$multiLineForward(d,x,M,$),N){var A=N.endRow<=$?N.endRow-1:$;A>M&&(M=A),w.push(new v(N.startRow,N.startCol,N.endRow,N.endCol))}}else{N=h.getMatchOffsets(m[M],x);for(var P=0;P<N.length;P++){var D=N[P];w.push(new v(M,D.offset,M,D.offset+D.length))}}if(f){for(var j=f.start.column,U=f.end.column,M=0,P=w.length-1;M<P&&w[M].start.column<j&&w[M].start.row==0;)M++;for(var q=f.end.row-f.start.row;M<P&&w[P].end.column>U&&w[P].end.row==q;)P--;for(w=w.slice(M,P+1),M=0,P=w.length;M<P;M++)w[M].start.row+=f.start.row,w[M].end.row+=f.start.row}return w},u.prototype.parseReplaceString=function(d){for(var o={DollarSign:36,Ampersand:38,Digit0:48,Digit1:49,Digit9:57,Backslash:92,n:110,t:116},f="",m=0,w=d.length;m<w;m++){var x=d.charCodeAt(m);if(x===o.Backslash){if(m++,m>=w){f+="\\";break}var R=d.charCodeAt(m);switch(R){case o.Backslash:f+="\\";break;case o.n:f+=`
202
+ `;break;case o.t:f+=" ";break}continue}if(x===o.DollarSign){if(m++,m>=w){f+="$";break}var T=d.charCodeAt(m);if(T===o.DollarSign){f+="$$";continue}if(T===o.Digit0||T===o.Ampersand){f+="$&";continue}if(o.Digit1<=T&&T<=o.Digit9){f+="$"+d[m];continue}}f+=d[m]}return f||d},u.prototype.replace=function(d,o){var f=this.$options,m=this.$assembleRegExp(f);if(f.$isMultiLine)return o;if(m){var w=this.$isMultilineSearch(f);w&&(d=d.replace(/\r\n|\r|\n/g,`
203
+ `));var x=m.exec(d);if(!x||!w&&x[0].length!=d.length)return null;if(o=f.regExp?this.parseReplaceString(o):o.replace(/\$/g,"$$$$"),o=d.replace(m,o),f.preserveCase){o=o.split("");for(var R=Math.min(d.length,d.length);R--;){var T=d[R];T&&T.toLowerCase()!=T?o[R]=o[R].toUpperCase():o[R]=o[R].toLowerCase()}o=o.join("")}return o}},u.prototype.$assembleRegExp=function(d,o){if(d.needle instanceof RegExp)return d.re=d.needle;var f=d.needle;if(!d.needle)return d.re=!1;d.regExp||(f=h.escapeRegExp(f));var m=d.caseSensitive?"gm":"gmi";try{new RegExp(f,"u"),d.$supportsUnicodeFlag=!0,m+="u"}catch{d.$supportsUnicodeFlag=!1}if(d.wholeWord&&(f=p(f,d)),d.$isMultiLine=!o&&/[\n\r]/.test(f),d.$isMultiLine)return d.re=this.$assembleMultilineRegExp(f,m);try{var w=new RegExp(f,m)}catch{w=!1}return d.re=w},u.prototype.$assembleMultilineRegExp=function(d,o){for(var f=d.replace(/\r\n|\r|\n/g,`$
204
+ ^`).split(`
205
+ `),m=[],w=0;w<f.length;w++)try{m.push(new RegExp(f[w],o))}catch{return!1}return m},u.prototype.$isMultilineSearch=function(d){return d.re&&/\\r\\n|\\r|\\n/.test(d.re.source)&&d.regExp&&!d.$isMultiLine},u.prototype.$multiLineForward=function(d,o,f,m){for(var w,x=l(d,f),R=f;R<=m;){for(var T=0;T<x&&!(R>m);T++){var _=d.getLine(R++);w=w==null?_:w+`
206
+ `+_}var C=o.exec(w);if(o.lastIndex=0,C){var P=w.slice(0,C.index).split(`
207
+ `),O=C[0].split(`
208
+ `),E=f+P.length-1,k=P[P.length-1].length,B=E+O.length-1,N=O.length==1?k+O[0].length:O[O.length-1].length;return{startRow:E,startCol:k,endRow:B,endCol:N}}}return null},u.prototype.$multiLineBackward=function(d,o,f,m,w){for(var x,R=l(d,m),T=d.getLine(m).length-f,_=m;_>=w;){for(var C=0;C<R&&_>=w;C++){var P=d.getLine(_--);x=x==null?P:P+`
209
+ `+x}var O=a(x,o,T);if(O){var E=x.slice(0,O.index).split(`
210
+ `),k=O[0].split(`
211
+ `),B=_+E.length,N=E[E.length-1].length,M=B+k.length-1,$=k.length==1?N+k[0].length:k[k.length-1].length;return{startRow:B,startCol:N,endRow:M,endCol:$}}}return null},u.prototype.$matchIterator=function(d,o){var f=this.$assembleRegExp(o);if(!f)return!1;var m=this.$isMultilineSearch(o),w=this.$multiLineForward,x=this.$multiLineBackward,R=o.backwards==!0,T=o.skipCurrent!=!1,_=f.unicode,C=o.range,P=o.start;P||(P=C?C[R?"end":"start"]:d.selection.getRange()),P.start&&(P=P[T!=R?"end":"start"]);var O=C?C.start.row:0,E=C?C.end.row:d.getLength()-1;if(R)var k=function(M){var $=P.row;if(!N($,P.column,M)){for($--;$>=O;$--)if(N($,Number.MAX_VALUE,M))return;if(o.wrap!=!1){for($=E,O=P.row;$>=O;$--)if(N($,Number.MAX_VALUE,M))return}}};else var k=function(M){var $=P.row;if(!N($,P.column,M)){for($=$+1;$<=E;$++)if(N($,0,M))return;if(o.wrap!=!1){for($=O,E=P.row;$<=E;$++)if(N($,0,M))return}}};if(o.$isMultiLine)var B=f.length,N=function(M,$,A){var D=R?M-B+1:M;if(!(D<0||D+B>d.getLength())){var j=d.getLine(D),U=j.search(f[0]);if(!(!R&&U<$||U===-1)){for(var q=1;q<B;q++)if(j=d.getLine(D+q),j.search(f[q])==-1)return;var Q=j.match(f[B-1])[0].length;if(!(R&&Q>$)&&A(D,U,D+B-1,Q))return!0}}};else if(R)var N=function(M,$,A){if(m){var D=x(d,f,$,M,O);if(!D)return!1;if(A(D.startRow,D.startCol,D.endRow,D.endCol))return!0}else{var j=d.getLine(M),U=[],q,Q=0;for(f.lastIndex=0;q=f.exec(j);){var re=q[0].length;if(Q=q.index,!re){if(Q>=j.length)break;f.lastIndex=Q+=h.skipEmptyMatch(j,Q,_)}if(q.index+re>$)break;U.push(q.index,re)}for(var le=U.length-1;le>=0;le-=2){var ne=U[le-1],re=U[le];if(A(M,ne,M,ne+re))return!0}}};else var N=function(M,$,A){if(f.lastIndex=$,m){var D=w(d,f,M,E);if(D){var j=D.endRow<=E?D.endRow-1:E;j>M&&(M=j)}if(!D)return!1;if(A(D.startRow,D.startCol,D.endRow,D.endCol))return!0}else for(var U=d.getLine(M),q,Q;Q=f.exec(U);){var re=Q[0].length;if(q=Q.index,A(M,q,M,q+re))return!0;if(!re&&(f.lastIndex=q+=h.skipEmptyMatch(U,q,_),q>=U.length))return!1}};return{forEach:k}},u})();function p(u,d){var o=h.supportsLookbehind();function f(R,T){T===void 0&&(T=!0);var _=o&&d.$supportsUnicodeFlag?new RegExp("[\\p{L}\\p{N}_]","u"):new RegExp("\\w");return _.test(R)||d.regExp?o&&d.$supportsUnicodeFlag?T?"(?<=^|[^\\p{L}\\p{N}_])":"(?=[^\\p{L}\\p{N}_]|$)":"\\b":""}var m=Array.from(u),w=m[0],x=m[m.length-1];return f(w)+u+f(x,!1)}function a(u,d,o){for(var f=null,m=0;m<=u.length;){d.lastIndex=m;var w=d.exec(u);if(!w)break;var x=w.index+w[0].length;if(x>u.length-o)break;(!f||x>f.index+f[0].length)&&(f=w),m=w.index+1}return f}function l(u,d){var o=5e3,f={row:d,column:0},m=u.doc.positionToIndex(f),w=m+o,x=u.doc.indexToPosition(w),R=x.row;return R+1}r.Search=s}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(t,r,c){var h=this&&this.__extends||(function(){var u=function(d,o){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,m){f.__proto__=m}||function(f,m){for(var w in m)Object.prototype.hasOwnProperty.call(m,w)&&(f[w]=m[w])},u(d,o)};return function(d,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");u(d,o);function f(){this.constructor=d}d.prototype=o===null?Object.create(o):(f.prototype=o.prototype,new f)}})(),g=t("../lib/keys"),v=t("../lib/useragent"),s=g.KEY_MODS,p=(function(){function u(d,o){this.$init(d,o,!1)}return u.prototype.$init=function(d,o,f){this.platform=o||(v.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(d),this.$singleCommand=f},u.prototype.addCommand=function(d){this.commands[d.name]&&this.removeCommand(d),this.commands[d.name]=d,d.bindKey&&this._buildKeyHash(d)},u.prototype.removeCommand=function(d,o){var f=d&&(typeof d=="string"?d:d.name);d=this.commands[f],o||delete this.commands[f];var m=this.commandKeyBinding;for(var w in m){var x=m[w];if(x==d)delete m[w];else if(Array.isArray(x)){var R=x.indexOf(d);R!=-1&&(x.splice(R,1),x.length==1&&(m[w]=x[0]))}}},u.prototype.bindKey=function(d,o,f){if(typeof d=="object"&&d&&(f==null&&(f=d.position),d=d[this.platform]),!!d){if(typeof o=="function")return this.addCommand({exec:o,bindKey:d,name:o.name||d});d.split("|").forEach(function(m){var w="";if(m.indexOf(" ")!=-1){var x=m.split(/\s+/);m=x.pop(),x.forEach(function(_){var C=this.parseKeys(_),P=s[C.hashId]+C.key;w+=(w?" ":"")+P,this._addCommandToBinding(w,"chainKeys")},this),w+=" "}var R=this.parseKeys(m),T=s[R.hashId]+R.key;this._addCommandToBinding(w+T,o,f)},this)}},u.prototype._addCommandToBinding=function(d,o,f){var m=this.commandKeyBinding,w;if(!o)delete m[d];else if(!m[d]||this.$singleCommand)m[d]=o;else{Array.isArray(m[d])?(w=m[d].indexOf(o))!=-1&&m[d].splice(w,1):m[d]=[m[d]],typeof f!="number"&&(f=a(o));var x=m[d];for(w=0;w<x.length;w++){var R=x[w],T=a(R);if(T>f)break}x.splice(w,0,o)}},u.prototype.addCommands=function(d){d&&Object.keys(d).forEach(function(o){var f=d[o];if(f){if(typeof f=="string")return this.bindKey(f,o);typeof f=="function"&&(f={exec:f}),typeof f=="object"&&(f.name||(f.name=o),this.addCommand(f))}},this)},u.prototype.removeCommands=function(d){Object.keys(d).forEach(function(o){this.removeCommand(d[o])},this)},u.prototype.bindKeys=function(d){Object.keys(d).forEach(function(o){this.bindKey(o,d[o])},this)},u.prototype._buildKeyHash=function(d){this.bindKey(d.bindKey,d)},u.prototype.parseKeys=function(d){var o=d.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(T){return T}),f=o.pop(),m=g[f];if(g.FUNCTION_KEYS[m])f=g.FUNCTION_KEYS[m].toLowerCase();else if(o.length){if(o.length==1&&o[0]=="shift")return{key:f.toUpperCase(),hashId:-1}}else return{key:f,hashId:-1};for(var w=0,x=o.length;x--;){var R=g.KEY_MODS[o[x]];if(R==null)return typeof console<"u"&&console.error("invalid modifier "+o[x]+" in "+d),!1;w|=R}return{key:f,hashId:w}},u.prototype.findKeyCommand=function(d,o){var f=s[d]+o;return this.commandKeyBinding[f]},u.prototype.handleKeyboard=function(d,o,f,m){if(!(m<0)){var w=s[o]+f,x=this.commandKeyBinding[w];return d.$keyChain&&(d.$keyChain+=" "+w,x=this.commandKeyBinding[d.$keyChain]||x),x&&(x=="chainKeys"||x[x.length-1]=="chainKeys")?(d.$keyChain=d.$keyChain||w,{command:"null"}):(d.$keyChain&&((!o||o==4)&&f.length==1?d.$keyChain=d.$keyChain.slice(0,-w.length-1):(o==-1||m>0)&&(d.$keyChain="")),{command:x})}},u.prototype.getStatusText=function(d,o){return o.$keyChain||""},u})();function a(u){return typeof u=="object"&&u.bindKey&&u.bindKey.position||(u.isDefault?-100:0)}var l=(function(u){h(d,u);function d(o,f){var m=u.call(this,o,f)||this;return m.$singleCommand=!0,m}return d})(p);l.call=function(u,d,o){p.prototype.$init.call(u,d,o,!0)},p.call=function(u,d,o){p.prototype.$init.call(u,d,o,!1)},r.HashHandler=l,r.MultiHashHandler=p}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(t,r,c){var h=this&&this.__extends||(function(){var a=function(l,u){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,o){d.__proto__=o}||function(d,o){for(var f in o)Object.prototype.hasOwnProperty.call(o,f)&&(d[f]=o[f])},a(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");a(l,u);function d(){this.constructor=l}l.prototype=u===null?Object.create(u):(d.prototype=u.prototype,new d)}})(),g=t("../lib/oop"),v=t("../keyboard/hash_handler").MultiHashHandler,s=t("../lib/event_emitter").EventEmitter,p=(function(a){h(l,a);function l(u,d){var o=a.call(this,d,u)||this;return o.byName=o.commands,o.setDefaultHandler("exec",function(f){return f.args?f.command.exec(f.editor,f.args,f.event,!1):f.command.exec(f.editor,{},f.event,!0)}),o}return l.prototype.exec=function(u,d,o){if(Array.isArray(u)){for(var f=u.length;f--;)if(this.exec(u[f],d,o))return!0;return!1}typeof u=="string"&&(u=this.commands[u]);var m={editor:d,command:u,args:o};return this.canExecute(u,d)?(m.returnValue=this._emit("exec",m),this._signal("afterExec",m),m.returnValue!==!1):(this._signal("commandUnavailable",m),!1)},l.prototype.canExecute=function(u,d){return typeof u=="string"&&(u=this.commands[u]),!(!u||d&&d.$readOnly&&!u.readOnly||this.$checkCommandState!=!1&&u.isAvailable&&!u.isAvailable(d))},l.prototype.toggleRecording=function(u){if(!this.$inReplay)return u&&u._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(d){this.macro.push([d.command,d.args])}).bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},l.prototype.replay=function(u){if(!(this.$inReplay||!this.macro)){if(this.recording)return this.toggleRecording(u);try{this.$inReplay=!0,this.macro.forEach(function(d){typeof d=="string"?this.exec(d,u):this.exec(d[0],u,d[1])},this)}finally{this.$inReplay=!1}}},l.prototype.trimMacro=function(u){return u.map(function(d){return typeof d[0]!="string"&&(d[0]=d[0].name),d[1]||(d=d[0]),d})},l})(v);g.implement(p.prototype,s),r.CommandManager=p}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(t,r,c){var h=t("../lib/lang"),g=t("../config"),v=t("../range").Range;function s(a,l){return{win:a,mac:l}}r.commands=[{name:"showSettingsMenu",description:"Show settings menu",bindKey:s("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:s("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:s("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:s("Ctrl-A","Command-A"),exec:function(a){a.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:s(null,"Ctrl-L"),exec:function(a){a.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:s("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:s("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:s("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:s("F2","F2"),exec:function(a){a.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",description:"Toggle parent fold widget",bindKey:s("Alt-F2","Alt-F2"),exec:function(a){a.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:s(null,"Ctrl-Command-Option-0"),exec:function(a){a.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:s(null,"Ctrl-Command-Option-0"),exec:function(a){a.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:s("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:s("Alt-Shift-0","Command-Option-Shift-0"),exec:function(a){a.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:s("Ctrl-K","Command-G"),exec:function(a){a.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:s("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:s("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:s("Alt-Shift-K","Ctrl-Shift-G"),exec:function(a){a.selection.isEmpty()?a.selection.selectWord():a.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:s("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:s("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:s("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:s("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:s("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:s("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:s("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:s("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:s("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:s("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:s("Ctrl-Left","Option-Left"),exec:function(a){a.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",description:"Select to line start",bindKey:s("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:s("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:s("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:s("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:s("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:s("Ctrl-Right","Option-Right"),exec:function(a){a.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",description:"Select to line end",bindKey:s("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:s("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:s("Shift-Right","Shift-Right"),exec:function(a){a.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:s("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:s(null,"Option-PageDown"),exec:function(a){a.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:s("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:s(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:s("Ctrl-Up",null),exec:function(a){a.renderer.scrollBy(0,-2*a.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:s("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:s("Ctrl-Alt-E","Command-Option-E"),exec:function(a){a.commands.toggleRecording(a)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:s("Ctrl-Shift-E","Command-Shift-E"),exec:function(a){a.commands.replay(a)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:s("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(a){a.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:s("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:s("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:s(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(),u=l?a.selection.getLineRange():a.selection.getRange();a._emit("cut",u),u.isEmpty()||a.session.remove(u),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:s("Ctrl-D","Command-D"),exec:function(a){a.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:s("Ctrl-Shift-D","Command-Shift-D"),exec:function(a){a.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:s("Ctrl-Alt-S","Command-Alt-S"),exec:function(a){a.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:s("Ctrl-/","Command-/"),exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:s("Ctrl-Shift-/","Command-Shift-/"),exec:function(a){a.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:s("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(a){a.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:s("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(a){a.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:s("Ctrl-H","Command-Option-F"),exec:function(a){g.loadModule("ace/ext/searchbox",function(l){l.Search(a,!0)})}},{name:"undo",description:"Undo",bindKey:s("Ctrl-Z","Command-Z"),exec:function(a){a.undo()}},{name:"redo",description:"Redo",bindKey:s("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(a){a.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:s("Alt-Shift-Up","Command-Option-Up"),exec:function(a){a.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:s("Alt-Up","Option-Up"),exec:function(a){a.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:s("Alt-Shift-Down","Command-Option-Down"),exec:function(a){a.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:s("Alt-Down","Option-Down"),exec:function(a){a.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:s("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(a){a.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:s("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:s("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:s("Alt-Backspace","Command-Backspace"),exec:function(a){a.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:s("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(a){a.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:s("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:s("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:s("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(a){a.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:s("Ctrl-Delete","Alt-Delete"),exec:function(a){a.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:s("Shift-Tab","Shift-Tab"),exec:function(a){a.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:s("Tab","Tab"),exec:function(a){a.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:s("Ctrl-[","Ctrl-["),exec:function(a){a.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:s("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(h.stringRepeat(l.text||"",l.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:s(null,"Ctrl-O"),exec:function(a){a.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:s("Alt-Shift-X","Ctrl-T"),exec:function(a){a.transposeLetters()},multiSelectAction:function(a){a.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:s("Ctrl-U","Ctrl-U"),exec:function(a){a.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:s("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(a){a.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:s(null,null),exec:function(a){a.autoIndent()},scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:s("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:s("Ctrl+F3","F3"),exec:function(a){a.openLink()}},{name:"joinlines",description:"Join lines",bindKey:s(null,null),exec:function(a){for(var l=a.selection.isBackwards(),u=l?a.selection.getSelectionLead():a.selection.getSelectionAnchor(),d=l?a.selection.getSelectionAnchor():a.selection.getSelectionLead(),o=a.session.doc.getLine(u.row).length,f=a.session.doc.getTextRange(a.selection.getRange()),m=f.replace(/\n\s*/," ").length,w=a.session.doc.getLine(u.row),x=u.row+1;x<=d.row+1;x++){var R=h.stringTrimLeft(h.stringTrimRight(a.session.doc.getLine(x)));R.length!==0&&(R=" "+R),w+=R}d.row+1<a.session.doc.getLength()-1&&(w+=a.session.doc.getNewLineCharacter()),a.clearSelection(),a.session.doc.replace(new v(u.row,0,d.row+2,0),w),m>0?(a.selection.moveCursorTo(u.row,u.column),a.selection.selectTo(u.row,u.column+m)):(o=a.session.doc.getLine(u.row).length>o?o+1:o,a.selection.moveCursorTo(u.row,o))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:s(null,null),exec:function(a){var l=a.session.doc.getLength()-1,u=a.session.doc.getLine(l).length,d=a.selection.rangeList.ranges,o=[];d.length<1&&(d=[a.selection.getRange()]);for(var f=0;f<d.length;f++)f==d.length-1&&(d[f].end.row===l&&d[f].end.column===u||o.push(new v(d[f].end.row,d[f].end.column,l,u))),f===0?d[f].start.row===0&&d[f].start.column===0||o.push(new v(0,0,d[f].start.row,d[f].start.column)):o.push(new v(d[f-1].end.row,d[f-1].end.column,d[f].start.row,d[f].start.column));a.exitMultiSelectMode(),a.clearSelection();for(var f=0;f<o.length;f++)a.selection.addRange(o[f],!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:s("F1","F1"),exec:function(a){a.prompt({$type:"commands"})},readOnly:!0},{name:"modeSelect",description:"Change language mode...",bindKey:s(null,null),exec:function(a){a.prompt({$type:"modes"})},readOnly:!0}];for(var p=1;p<9;p++)r.commands.push({name:"foldToLevel"+p,description:"Fold To Level "+p,level:p,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(t,r,c){var h=t("../lib/keys"),g=(function(){function s(p){this.editor=p,this.gutterLayer=p.renderer.$gutterLayer,this.element=p.renderer.$gutter,this.lines=p.renderer.$gutterLayer.$lines,this.activeRowIndex=null,this.activeLane=null,this.annotationTooltip=this.editor.$mouseHandler.$tooltip}return s.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))},s.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))},s.prototype.$onGutterKeyDown=function(p){if(this.annotationTooltip.isOpen){p.preventDefault(),p.keyCode===h.escape&&this.annotationTooltip.hide();return}if(p.target===this.element){if(p.keyCode!=h.enter)return;p.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),u=this.$findNearestFoldLaneWidget(l),d=this.$findNearestAnnotation(l);if(!(u===null&&d===null)){var o=this.$findClosestNumber(u,d,l);if(o===u)if(this.activeLane="fold",this.activeRowIndex=u,this.$isCustomWidgetVisible(u)){this.$focusCustomWidget(this.activeRowIndex);return}else{this.$focusFoldWidget(this.activeRowIndex);return}else{this.activeRowIndex=d,this.activeLane="annotation",this.$focusAnnotation(this.activeRowIndex);return}}}).bind(this),10);return}this.$handleGutterKeyboardInteraction(p),setTimeout((function(){this.editor._signal("gutterkeydown",new v(p,this))}).bind(this),10)},s.prototype.$handleGutterKeyboardInteraction=function(p){if(p.keyCode===h.tab){p.preventDefault();return}if(p.keyCode===h.escape){p.preventDefault(),this.$blurGutter(),this.element.focus(),this.lane=null;return}if(p.keyCode===h.up){switch(p.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetUp();break;case"annotation":this.$moveAnnotationUp();break}return}if(p.keyCode===h.down){switch(p.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetDown();break;case"annotation":this.$moveAnnotationDown();break}return}if(p.keyCode===h.left){p.preventDefault(),this.$switchLane("annotation");return}if(p.keyCode===h.right){p.preventDefault(),this.$switchLane("fold");return}if(p.keyCode===h.enter||p.keyCode===h.space){switch(p.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(p,a);else if(this.gutterLayer.session.foldWidgets[a]==="start"){this.editor.session.onFoldWidgetClick(this.$rowIndexToRow(this.activeRowIndex),p),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}},s.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()},s.prototype.$isFoldWidgetVisible=function(p){var a=this.editor.isRowFullyVisible(this.$rowIndexToRow(p)),l=this.$getFoldWidget(p).style.display!=="none";return a&&l},s.prototype.$isCustomWidgetVisible=function(p){var a=this.editor.isRowFullyVisible(this.$rowIndexToRow(p)),l=!!this.$getCustomWidget(p);return a&&l},s.prototype.$isAnnotationVisible=function(p){var a=this.editor.isRowFullyVisible(this.$rowIndexToRow(p)),l=this.$getAnnotation(p).style.display!=="none";return a&&l},s.prototype.$getFoldWidget=function(p){var a=this.lines.get(p),l=a.element;return l.childNodes[1]},s.prototype.$getCustomWidget=function(p){var a=this.lines.get(p),l=a.element;return l.childNodes[3]},s.prototype.$getAnnotation=function(p){var a=this.lines.get(p),l=a.element;return l.childNodes[2]},s.prototype.$findNearestFoldLaneWidget=function(p){if(this.$isCustomWidgetVisible(p)||this.$isFoldWidgetVisible(p))return p;for(var a=0;p-a>0||p+a<this.lines.getLength()-1;){if(a++,p-a>=0&&this.$isCustomWidgetVisible(p-a))return p-a;if(p+a<=this.lines.getLength()-1&&this.$isCustomWidgetVisible(p+a))return p+a;if(p-a>=0&&this.$isFoldWidgetVisible(p-a))return p-a;if(p+a<=this.lines.getLength()-1&&this.$isFoldWidgetVisible(p+a))return p+a}return null},s.prototype.$findNearestAnnotation=function(p){if(this.$isAnnotationVisible(p))return p;for(var a=0;p-a>0||p+a<this.lines.getLength()-1;){if(a++,p-a>=0&&this.$isAnnotationVisible(p-a))return p-a;if(p+a<=this.lines.getLength()-1&&this.$isAnnotationVisible(p+a))return p+a}return null},s.prototype.$focusFoldWidget=function(p){if(p!=null){var a=this.$getFoldWidget(p);a.classList.add(this.editor.renderer.keyboardFocusClassName),a.focus()}},s.prototype.$focusCustomWidget=function(p){if(p!=null){var a=this.$getCustomWidget(p);a&&(a.classList.add(this.editor.renderer.keyboardFocusClassName),a.focus())}},s.prototype.$focusAnnotation=function(p){if(p!=null){var a=this.$getAnnotation(p);a.classList.add(this.editor.renderer.keyboardFocusClassName),a.focus()}},s.prototype.$blurFoldWidget=function(p){var a=this.$getFoldWidget(p);a.classList.remove(this.editor.renderer.keyboardFocusClassName),a.blur()},s.prototype.$blurCustomWidget=function(p){var a=this.$getCustomWidget(p);a&&(a.classList.remove(this.editor.renderer.keyboardFocusClassName),a.blur())},s.prototype.$blurAnnotation=function(p){var a=this.$getAnnotation(p);a.classList.remove(this.editor.renderer.keyboardFocusClassName),a.blur()},s.prototype.$moveFoldWidgetUp=function(){for(var p=this.activeRowIndex;p>0;)if(p--,this.$isFoldWidgetVisible(p)||this.$isCustomWidgetVisible(p)){this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex),this.activeRowIndex=p,this.$isFoldWidgetVisible(p)?this.$focusFoldWidget(this.activeRowIndex):this.$focusCustomWidget(this.activeRowIndex);return}},s.prototype.$moveFoldWidgetDown=function(){for(var p=this.activeRowIndex;p<this.lines.getLength()-1;)if(p++,this.$isFoldWidgetVisible(p)||this.$isCustomWidgetVisible(p)){this.$blurFoldWidget(this.activeRowIndex),this.$blurCustomWidget(this.activeRowIndex),this.activeRowIndex=p,this.$isFoldWidgetVisible(p)?this.$focusFoldWidget(this.activeRowIndex):this.$focusCustomWidget(this.activeRowIndex);return}},s.prototype.$moveAnnotationUp=function(){for(var p=this.activeRowIndex;p>0;)if(p--,this.$isAnnotationVisible(p)){this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=p,this.$focusAnnotation(this.activeRowIndex);return}},s.prototype.$moveAnnotationDown=function(){for(var p=this.activeRowIndex;p<this.lines.getLength()-1;)if(p++,this.$isAnnotationVisible(p)){this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=p,this.$focusAnnotation(this.activeRowIndex);return}},s.prototype.$findClosestNumber=function(p,a,l){return p===null?a:a===null||Math.abs(l-p)<=Math.abs(l-a)?p:a},s.prototype.$switchLane=function(p){switch(p){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}},s.prototype.$rowIndexToRow=function(p){var a=this.lines.get(p);return a?a.row:null},s.prototype.$rowToRowIndex=function(p){for(var a=0;a<this.lines.getLength();a++){var l=this.lines.get(a);if(l.row==p)return a}return null},s})();r.GutterKeyboardHandler=g;var v=(function(){function s(p,a){this.gutterKeyboardHandler=a,this.domEvent=p}return s.prototype.getKey=function(){return h.keyCodeToString(this.domEvent.keyCode)},s.prototype.getRow=function(){return this.gutterKeyboardHandler.$rowIndexToRow(this.gutterKeyboardHandler.activeRowIndex)},s.prototype.isInAnnotationLane=function(){return this.gutterKeyboardHandler.activeLane==="annotation"},s.prototype.isInFoldLane=function(){return this.gutterKeyboardHandler.activeLane==="fold"},s})();r.GutterKeyboardEvent=v}),ace.define("ace/editor",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/keyboard/textinput","ace/mouse/mouse_handler","ace/mouse/fold_handler","ace/keyboard/keybinding","ace/edit_session","ace/search","ace/range","ace/lib/event_emitter","ace/commands/command_manager","ace/commands/default_commands","ace/config","ace/token_iterator","ace/keyboard/gutter_handler","ace/config","ace/clipboard","ace/lib/keys","ace/lib/event","ace/tooltip"],function(t,r,c){var h=this&&this.__values||function($){var A=typeof Symbol=="function"&&Symbol.iterator,D=A&&$[A],j=0;if(D)return D.call($);if($&&typeof $.length=="number")return{next:function(){return $&&j>=$.length&&($=void 0),{value:$&&$[j++],done:!$}}};throw new TypeError(A?"Object is not iterable.":"Symbol.iterator is not defined.")},g=t("./lib/oop"),v=t("./lib/dom"),s=t("./lib/lang"),p=t("./lib/useragent"),a=t("./keyboard/textinput").TextInput,l=t("./mouse/mouse_handler").MouseHandler,u=t("./mouse/fold_handler").FoldHandler,d=t("./keyboard/keybinding").KeyBinding,o=t("./edit_session").EditSession,f=t("./search").Search,m=t("./range").Range,w=t("./lib/event_emitter").EventEmitter,x=t("./commands/command_manager").CommandManager,R=t("./commands/default_commands").commands,T=t("./config"),_=t("./token_iterator").TokenIterator,C=t("./keyboard/gutter_handler").GutterKeyboardHandler,P=t("./config").nls,O=t("./clipboard"),E=t("./lib/keys"),k=t("./lib/event"),B=t("./tooltip").HoverTooltip,N=(function(){function $(A,D,j){this.id="editor"+ ++$.$uid,this.session,this.$toDestroy=[];var U=A.getContainerElement();this.container=U,this.renderer=A,this.commands=new x(p.isMac?"mac":"win",R),typeof document=="object"&&(this.textInput=new a(A.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.$mouseHandler=new l(this),new u(this)),this.keyBinding=new d(this),this.$search=new f().set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=s.delayedCall((function(){this._signal("input",{}),this.session&&!this.session.destroyed&&this.session.bgTokenizer.scheduleStart()}).bind(this)),this.on("change",function(q,Q){Q._$emitInputEvent.schedule(31)}),this.setSession(D||j&&j.session||new o("")),T.resetOptions(this),j&&this.setOptions(j),T._signal("editor",this)}return $.prototype.$initOperationListeners=function(){this.commands.on("exec",this.startOperation.bind(this),!0),this.commands.on("afterExec",this.endOperation.bind(this),!0)},$.prototype.startOperation=function(A){this.session.startOperation(A)},$.prototype.endOperation=function(A){this.session.endOperation(A)},$.prototype.onStartOperation=function(A){this.curOp=this.session.curOp,this.curOp.scrollTop=this.renderer.scrollTop,this.prevOp=this.session.prevOp,A||(this.previousCommand=null)},$.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 D=this.curOp.command,j=D&&D.scrollIntoView;if(j){switch(j){case"center-animate":j="animate";case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var U=this.selection.getRange(),q=this.renderer.layerConfig;(U.start.row>=q.lastRow||U.end.row<=q.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break}j=="animate"&&this.renderer.animateScrolling(this.curOp.scrollTop)}this.$lastSel=this.session.selection.toJSON(),this.prevOp=this.curOp,this.curOp=null}},$.prototype.$historyTracker=function(A){if(this.$mergeUndoDeltas){var D=this.prevOp,j=this.$mergeableCommands,U=D.command&&A.command.name==D.command.name;if(A.command.name=="insertstring"){var q=A.args;this.mergeNextCommand===void 0&&(this.mergeNextCommand=!0),U=U&&this.mergeNextCommand&&(!/\s/.test(q)||/\s/.test(D.args)),this.mergeNextCommand=!0}else U=U&&j.indexOf(A.command.name)!==-1;this.$mergeUndoDeltas!="always"&&Date.now()-this.sequenceStartTime>2e3&&(U=!1),U?this.session.mergeUndoDeltas=!0:j.indexOf(A.command.name)!==-1&&(this.sequenceStartTime=Date.now())}},$.prototype.setKeyboardHandler=function(A,D){if(A&&typeof A=="string"&&A!="ace"){this.$keybindingId=A;var j=this;T.loadModule(["keybinding",A],function(U){j.$keybindingId==A&&j.keyBinding.setKeyboardHandler(U&&U.handler),D&&D()})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(A),D&&D()},$.prototype.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},$.prototype.setSession=function(A){if(this.session!=A){this.curOp&&this.endOperation(),this.curOp={};var D=this.session;if(D){this.session.off("change",this.$onDocumentChange),this.session.off("changeMode",this.$onChangeMode),this.session.off("tokenizerUpdate",this.$onTokenizerUpdate),this.session.off("changeTabSize",this.$onChangeTabSize),this.session.off("changeWrapLimit",this.$onChangeWrapLimit),this.session.off("changeWrapMode",this.$onChangeWrapMode),this.session.off("changeFold",this.$onChangeFold),this.session.off("changeFrontMarker",this.$onChangeFrontMarker),this.session.off("changeBackMarker",this.$onChangeBackMarker),this.session.off("changeBreakpoint",this.$onChangeBreakpoint),this.session.off("changeAnnotation",this.$onChangeAnnotation),this.session.off("changeOverwrite",this.$onCursorChange),this.session.off("changeScrollTop",this.$onScrollTopChange),this.session.off("changeScrollLeft",this.$onScrollLeftChange),this.session.off("startOperation",this.$onStartOperation),this.session.off("endOperation",this.$onEndOperation);var j=this.session.getSelection();this.session.$fontMetrics=null,j.off("changeCursor",this.$onCursorChange),j.off("changeSelection",this.$onSelectionChange)}this.session=A,A?(this.$onDocumentChange=this.onDocumentChange.bind(this),A.on("change",this.$onDocumentChange),this.renderer.setSession(A),A.$fontMetrics=this.renderer.$fontMetrics,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:D}),this.curOp=null,D&&D._signal("changeEditor",{oldEditor:this}),D&&(D.$editor=null),A&&A._signal("changeEditor",{editor:this}),A&&(A.$editor=this),A&&!A.destroyed&&A.bgTokenizer.scheduleStart()}},$.prototype.getSession=function(){return this.session},$.prototype.setValue=function(A,D){return this.session.doc.setValue(A),D?D==1?this.navigateFileEnd():D==-1&&this.navigateFileStart():this.selectAll(),A},$.prototype.getValue=function(){return this.session.getValue()},$.prototype.getSelection=function(){return this.selection},$.prototype.resize=function(A){this.renderer.onResize(A)},$.prototype.setTheme=function(A,D){this.renderer.setTheme(A,D)},$.prototype.getTheme=function(){return this.renderer.getTheme()},$.prototype.setStyle=function(A,D){this.renderer.setStyle(A,D)},$.prototype.unsetStyle=function(A){this.renderer.unsetStyle(A)},$.prototype.getFontSize=function(){return this.getOption("fontSize")||v.computedStyle(this.container).fontSize},$.prototype.setFontSize=function(A){this.setOption("fontSize",A)},$.prototype.$highlightBrackets=function(){if(!this.$highlightPending){var A=this;this.$highlightPending=!0,setTimeout(function(){A.$highlightPending=!1;var D=A.session;if(!(!D||D.destroyed)){D.$bracketHighlight&&(D.$bracketHighlight.markerIds.forEach(function(he){D.removeMarker(he)}),D.$bracketHighlight=null);var j=A.getCursorPosition(),U=A.getKeyboardHandler(),q=U&&U.$getDirectionForHighlight&&U.$getDirectionForHighlight(A),Q=D.getMatchingBracketRanges(j,q);if(!Q){var re=new _(D,j.row,j.column),le=re.getCurrentToken();if(le&&/\b(?:tag-open|tag-name)/.test(le.type)){var ne=D.getMatchingTags(j);ne&&(Q=[ne.openTagName.isEmpty()?ne.openTag:ne.openTagName,ne.closeTagName.isEmpty()?ne.closeTag:ne.closeTagName])}}if(!Q&&D.$mode.getMatching&&(Q=D.$mode.getMatching(A.session)),!Q){A.getHighlightIndentGuides()&&A.renderer.$textLayer.$highlightIndentGuide();return}var ue="ace_bracket";Array.isArray(Q)?Q.length==1&&(ue="ace_error_bracket"):Q=[Q],Q.length==2&&(m.comparePoints(Q[0].end,Q[1].start)==0?Q=[m.fromPoints(Q[0].start,Q[1].end)]:m.comparePoints(Q[0].start,Q[1].end)==0&&(Q=[m.fromPoints(Q[1].start,Q[0].end)])),D.$bracketHighlight={ranges:Q,markerIds:Q.map(function(he){return D.addMarker(he,ue,"text")})},A.getHighlightIndentGuides()&&A.renderer.$textLayer.$highlightIndentGuide()}},50)}},$.prototype.focus=function(){this.textInput.focus()},$.prototype.isFocused=function(){return this.textInput.isFocused()},$.prototype.blur=function(){this.textInput.blur()},$.prototype.onFocus=function(A){this.$isFocused||(this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",A))},$.prototype.onBlur=function(A){this.$isFocused&&(this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",A))},$.prototype.$cursorChange=function(){this.renderer.updateCursor(),this.$highlightBrackets(),this.$updateHighlightActiveLine()},$.prototype.onDocumentChange=function(A){var D=this.session.$useWrapMode,j=A.start.row==A.end.row?A.end.row:1/0;this.renderer.updateLines(A.start.row,j,D),this._signal("change",A),this.$cursorChange()},$.prototype.onTokenizerUpdate=function(A){var D=A.data;this.renderer.updateLines(D.first,D.last)},$.prototype.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},$.prototype.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},$.prototype.onCursorChange=function(){this.$cursorChange(),this._signal("changeSelection")},$.prototype.$updateHighlightActiveLine=function(){var A=this.getSession(),D;if(this.$highlightActiveLine&&((this.$selectionStyle!="line"||!this.selection.isMultiLine())&&(D=this.getCursorPosition()),this.renderer.theme&&this.renderer.theme.$selectionColorConflict&&!this.selection.isEmpty()&&(D=!1),this.renderer.$maxLines&&this.session.getLength()===1&&!(this.renderer.$minLines>1)&&(D=!1)),A.$highlightLineMarker&&!D)A.removeMarker(A.$highlightLineMarker.id),A.$highlightLineMarker=null;else if(!A.$highlightLineMarker&&D){var j=new m(D.row,D.column,D.row,1/0);j.id=A.addMarker(j,"ace_active-line","screenLine"),A.$highlightLineMarker=j}else D&&(A.$highlightLineMarker.start.row=D.row,A.$highlightLineMarker.end.row=D.row,A.$highlightLineMarker.start.column=D.column,A._signal("changeBackMarker"))},$.prototype.onSelectionChange=function(A){var D=this.session;if(D.$selectionMarker&&D.removeMarker(D.$selectionMarker),D.$selectionMarker=null,this.selection.isEmpty())this.$updateHighlightActiveLine();else{var j=this.selection.getRange(),U=this.getSelectionStyle();D.$selectionMarker=D.addMarker(j,"ace_selection",U)}var q=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(q),this._signal("changeSelection")},$.prototype.$getSelectionHighLightRegexp=function(){var A=this.session,D=this.getSelectionRange();if(!(D.isEmpty()||D.isMultiLine())){var j=D.start.column,U=D.end.column,q=A.getLine(D.start.row),Q=q.substring(j,U);if(!(Q.length>5e3||!/[\w\d]/.test(Q))){var re=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:Q}),le=q.substring(j-1,U+1);if(re.test(le))return re}}},$.prototype.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},$.prototype.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},$.prototype.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},$.prototype.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},$.prototype.onChangeMode=function(A){this.renderer.updateText(),this._emit("changeMode",A)},$.prototype.onChangeWrapLimit=function(){this.renderer.updateFull()},$.prototype.onChangeWrapMode=function(){this.renderer.onResize(!0)},$.prototype.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},$.prototype.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},$.prototype.getCopyText=function(){var A=this.getSelectedText(),D=this.session.doc.getNewLineCharacter(),j=!1;if(!A&&this.$copyWithEmptySelection){j=!0;for(var U=this.selection.getAllRanges(),q=0;q<U.length;q++){var Q=U[q];q&&U[q-1].start.row==Q.start.row||(A+=this.session.getLine(Q.start.row)+D)}}var re={text:A};return this._signal("copy",re),O.lineMode=j?re.text:!1,re.text},$.prototype.onCopy=function(){this.commands.exec("copy",this)},$.prototype.onCut=function(){this.commands.exec("cut",this)},$.prototype.onPaste=function(A,D){var j={text:A,event:D};this.commands.exec("paste",this,j)},$.prototype.$handlePaste=function(A){typeof A=="string"&&(A={text:A}),this._signal("paste",A);var D=A.text,j=D===O.lineMode,U=this.session;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)j?U.insert({row:this.selection.lead.row,column:0},D):this.insert(D);else if(j)this.selection.rangeList.ranges.forEach(function(ue){U.insert({row:ue.start.row,column:0},D)});else{var q=D.split(/\r\n|\r|\n/),Q=this.selection.rangeList.ranges,re=q.length==2&&(!q[0]||!q[1]);if(q.length!=Q.length||re)return this.commands.exec("insertstring",this,D);for(var le=Q.length;le--;){var ne=Q[le];ne.isEmpty()||U.remove(ne),U.insert(ne.start,q[le])}}},$.prototype.execCommand=function(A,D){return this.commands.exec(A,this,D)},$.prototype.insert=function(A,D){var j=this.session,U=j.getMode(),q=this.getCursorPosition();if(this.getBehavioursEnabled()&&!D){var Q=U.transformAction(j.getState(q.row),"insertion",this,j,A);Q&&(A!==Q.text&&(this.inVirtualSelectionMode||(this.session.mergeUndoDeltas=!1,this.mergeNextCommand=!1)),A=Q.text)}if(A==" "&&(A=this.session.getTabString()),this.selection.isEmpty()){if(this.session.getOverwrite()&&A.indexOf(`
214
+ `)==-1){var re=m.fromPoints(q,q);re.end.column+=A.length,this.session.remove(re)}}else{var re=this.getSelectionRange();q=this.session.remove(re),this.clearSelection()}if(A==`
215
+ `||A==`\r
216
+ `){var he=j.getLine(q.row);if(q.column>he.search(/\S|$/)){var le=he.substr(q.column).search(/\S|$/);j.doc.removeInLine(q.row,q.column,q.column+le)}}this.clearSelection();var ne=q.column,ue=j.getState(q.row),he=j.getLine(q.row),oe=U.checkOutdent(ue,he,A);if(j.insert(q,A),Q&&Q.selection&&(Q.selection.length==2?this.selection.setSelectionRange(new m(q.row,ne+Q.selection[0],q.row,ne+Q.selection[1])):this.selection.setSelectionRange(new m(q.row+Q.selection[0],Q.selection[1],q.row+Q.selection[2],Q.selection[3]))),this.$enableAutoIndent){if(j.getDocument().isNewLine(A)){var ee=U.getNextLineIndent(ue,he.slice(0,q.column),j.getTabString());j.insert({row:q.row+1,column:0},ee)}oe&&U.autoOutdent(ue,j,q.row)}},$.prototype.autoIndent=function(){for(var A=this.session,D=A.getMode(),j=this.selection.isEmpty()?[new m(0,0,A.doc.getLength()-1,0)]:this.selection.getAllRanges(),U="",q="",Q="",re=A.getTabString(),le=0;le<j.length;le++)for(var ne=j[le].start.row,ue=j[le].end.row,he=ne;he<=ue;he++){he>0&&(U=A.getState(he-1),q=A.getLine(he-1),Q=D.getNextLineIndent(U,q,re));var oe=A.getLine(he),ee=D.$getIndent(oe);if(Q!==ee){if(ee.length>0){var ye=new m(he,0,he,ee.length);A.remove(ye)}Q.length>0&&A.insert({row:he,column:0},Q)}D.autoOutdent(U,A,he)}},$.prototype.onTextInput=function(A,D){if(!D)return this.keyBinding.onTextInput(A);this.startOperation({command:{name:"insertstring"}});var j=this.applyComposition.bind(this,A,D);this.selection.rangeCount?this.forEachSelection(j):j(),this.endOperation()},$.prototype.applyComposition=function(A,D){if(D.extendLeft||D.extendRight){var j=this.selection.getRange();j.start.column-=D.extendLeft,j.end.column+=D.extendRight,j.start.column<0&&(j.start.row--,j.start.column+=this.session.getLine(j.start.row).length+1),this.selection.setRange(j),!A&&!j.isEmpty()&&this.execCommand(D.extendLeft?"backspace":"del")}if((A||!this.selection.isEmpty())&&this.insert(A,!0),D.restoreStart||D.restoreEnd){var j=this.selection.getRange();j.start.column-=D.restoreStart,j.end.column-=D.restoreEnd,this.selection.setRange(j)}},$.prototype.onCommandKey=function(A,D,j){return this.keyBinding.onCommandKey(A,D,j)},$.prototype.setOverwrite=function(A){this.session.setOverwrite(A)},$.prototype.getOverwrite=function(){return this.session.getOverwrite()},$.prototype.toggleOverwrite=function(){this.session.toggleOverwrite()},$.prototype.setScrollSpeed=function(A){this.setOption("scrollSpeed",A)},$.prototype.getScrollSpeed=function(){return this.getOption("scrollSpeed")},$.prototype.setDragDelay=function(A){this.setOption("dragDelay",A)},$.prototype.getDragDelay=function(){return this.getOption("dragDelay")},$.prototype.setSelectionStyle=function(A){this.setOption("selectionStyle",A)},$.prototype.getSelectionStyle=function(){return this.getOption("selectionStyle")},$.prototype.setHighlightActiveLine=function(A){this.setOption("highlightActiveLine",A)},$.prototype.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},$.prototype.setHighlightGutterLine=function(A){this.setOption("highlightGutterLine",A)},$.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},$.prototype.setHighlightSelectedWord=function(A){this.setOption("highlightSelectedWord",A)},$.prototype.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},$.prototype.setAnimatedScroll=function(A){this.renderer.setAnimatedScroll(A)},$.prototype.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},$.prototype.setShowInvisibles=function(A){this.renderer.setShowInvisibles(A)},$.prototype.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},$.prototype.setDisplayIndentGuides=function(A){this.renderer.setDisplayIndentGuides(A)},$.prototype.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},$.prototype.setHighlightIndentGuides=function(A){this.renderer.setHighlightIndentGuides(A)},$.prototype.getHighlightIndentGuides=function(){return this.renderer.getHighlightIndentGuides()},$.prototype.setShowPrintMargin=function(A){this.renderer.setShowPrintMargin(A)},$.prototype.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},$.prototype.setPrintMarginColumn=function(A){this.renderer.setPrintMarginColumn(A)},$.prototype.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},$.prototype.setReadOnly=function(A){this.setOption("readOnly",A)},$.prototype.getReadOnly=function(){return this.getOption("readOnly")},$.prototype.setBehavioursEnabled=function(A){this.setOption("behavioursEnabled",A)},$.prototype.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},$.prototype.setWrapBehavioursEnabled=function(A){this.setOption("wrapBehavioursEnabled",A)},$.prototype.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},$.prototype.setShowFoldWidgets=function(A){this.setOption("showFoldWidgets",A)},$.prototype.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},$.prototype.setFadeFoldWidgets=function(A){this.setOption("fadeFoldWidgets",A)},$.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},$.prototype.remove=function(A){this.selection.isEmpty()&&(A=="left"?this.selection.selectLeft():this.selection.selectRight());var D=this.getSelectionRange();if(this.getBehavioursEnabled()){var j=this.session,U=j.getState(D.start.row),q=j.getMode().transformAction(U,"deletion",this,j,D);if(D.end.column===0){var Q=j.getTextRange(D);if(Q[Q.length-1]==`
217
+ `){var re=j.getLine(D.end.row);/^\s+$/.test(re)&&(D.end.column=re.length)}}q&&(D=q)}this.session.remove(D),this.clearSelection()},$.prototype.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},$.prototype.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},$.prototype.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},$.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()},$.prototype.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var A=this.getCursorPosition();this.insert(`
218
+ `),this.moveCursorToPosition(A)},$.prototype.setGhostText=function(A,D){this.renderer.setGhostText(A,D)},$.prototype.removeGhostText=function(){this.renderer.removeGhostText()},$.prototype.transposeLetters=function(){if(this.selection.isEmpty()){var A=this.getCursorPosition(),D=A.column;if(D!==0){var j=this.session.getLine(A.row),U,q;D<j.length?(U=j.charAt(D)+j.charAt(D-1),q=new m(A.row,D-1,A.row,D+1)):(U=j.charAt(D-1)+j.charAt(D-2),q=new m(A.row,D-2,A.row,D)),this.session.replace(q,U),this.session.selection.moveToPosition(q.end)}}},$.prototype.toLowerCase=function(){var A=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var D=this.getSelectionRange(),j=this.session.getTextRange(D);this.session.replace(D,j.toLowerCase()),this.selection.setSelectionRange(A)},$.prototype.toUpperCase=function(){var A=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var D=this.getSelectionRange(),j=this.session.getTextRange(D);this.session.replace(D,j.toUpperCase()),this.selection.setSelectionRange(A)},$.prototype.indent=function(){var A=this.session,D=this.getSelectionRange();if(D.start.row<D.end.row){var j=this.$getSelectedRows();A.indentRows(j.first,j.last," ");return}else if(D.start.column<D.end.column){var U=A.getTextRange(D);if(!/^\s+$/.test(U)){var j=this.$getSelectedRows();A.indentRows(j.first,j.last," ");return}}var q=A.getLine(D.start.row),Q=D.start,re=A.getTabSize(),le=A.documentToScreenColumn(Q.row,Q.column);if(this.session.getUseSoftTabs())var ne=re-le%re,ue=s.stringRepeat(" ",ne);else{for(var ne=le%re;q[D.start.column-1]==" "&&ne;)D.start.column--,ne--;this.selection.setSelectionRange(D),ue=" "}return this.insert(ue)},$.prototype.blockIndent=function(){var A=this.$getSelectedRows();this.session.indentRows(A.first,A.last," ")},$.prototype.blockOutdent=function(){var A=this.session.getSelection();this.session.outdentRows(A.getRange())},$.prototype.sortLines=function(){for(var A=this.$getSelectedRows(),D=this.session,j=[],U=A.first;U<=A.last;U++)j.push(D.getLine(U));j.sort(function(re,le){return re.toLowerCase()<le.toLowerCase()?-1:re.toLowerCase()>le.toLowerCase()?1:0});for(var q=new m(0,0,0,0),U=A.first;U<=A.last;U++){var Q=D.getLine(U);q.start.row=U,q.end.row=U,q.end.column=Q.length,D.replace(q,j[U-A.first])}},$.prototype.toggleCommentLines=function(){var A=this.session.getState(this.getCursorPosition().row),D=this.$getSelectedRows();this.session.getMode().toggleCommentLines(A,this.session,D.first,D.last)},$.prototype.toggleBlockComment=function(){var A=this.getCursorPosition(),D=this.session.getState(A.row),j=this.getSelectionRange();this.session.getMode().toggleBlockComment(D,this.session,j,A)},$.prototype.getNumberAt=function(A,D){var j=/[\-]?[0-9]+(?:\.[0-9]+)?/g;j.lastIndex=0;for(var U=this.session.getLine(A);j.lastIndex<D;){var q=j.exec(U);if(q.index<=D&&q.index+q[0].length>=D){var Q={value:q[0],start:q.index,end:q.index+q[0].length};return Q}}return null},$.prototype.modifyNumber=function(A){var D=this.selection.getCursor().row,j=this.selection.getCursor().column,U=new m(D,j-1,D,j),q=this.session.getTextRange(U);if(!isNaN(parseFloat(q))&&isFinite(q)){var Q=this.getNumberAt(D,j);if(Q){var re=Q.value.indexOf(".")>=0?Q.start+Q.value.indexOf(".")+1:Q.end,le=Q.start+Q.value.length-re,ne=parseFloat(Q.value);ne*=Math.pow(10,le),re!==Q.end&&j<re?A*=Math.pow(10,Q.end-j-1):A*=Math.pow(10,Q.end-j),ne+=A,ne/=Math.pow(10,le);var ue=ne.toFixed(le),he=new m(D,Q.start,D,Q.end);this.session.replace(he,ue),this.moveCursorTo(D,Math.max(Q.start+1,j+ue.length-Q.value.length))}}else this.toggleWord()},$.prototype.toggleWord=function(){var A=this.selection.getCursor().row,D=this.selection.getCursor().column;this.selection.selectWord();var j=this.getSelectedText(),U=this.selection.getWordRange().start.column,q=j.replace(/([a-z]+|[A-Z]+)(?=[A-Z_]|$)/g,"$1 ").split(/\s/),Q=D-U-1;Q<0&&(Q=0);var re=0,le=0,ne=this;j.match(/[A-Za-z0-9_]+/)&&q.forEach(function(ze,Ye){le=re+ze.length,Q>=re&&Q<=le&&(j=ze,ne.selection.clearSelection(),ne.moveCursorTo(A,re+U),ne.selection.selectTo(A,le+U)),re=le});for(var ue=this.$toggleWordPairs,he,oe=0;oe<ue.length;oe++)for(var ee=ue[oe],ye=0;ye<=1;ye++){var we=+!ye,Ae=j.match(new RegExp("^\\s?_?("+s.escapeRegExp(ee[ye])+")\\s?$","i"));if(Ae){var Je=j.match(new RegExp("([_]|^|\\s)("+s.escapeRegExp(Ae[1])+")($|\\s)","g"));Je&&(he=j.replace(new RegExp(s.escapeRegExp(ee[ye]),"i"),function(ze){var Ye=ee[we];return ze.toUpperCase()==ze?Ye=Ye.toUpperCase():ze.charAt(0).toUpperCase()==ze.charAt(0)&&(Ye=Ye.substr(0,0)+ee[we].charAt(0).toUpperCase()+Ye.substr(1)),Ye}),this.insert(he),he="")}}},$.prototype.findLinkAt=function(A,D){var j,U,q=this.session.getLine(A),Q=q.split(/((?:https?|ftp):\/\/[\S]+)/),re=D;re<0&&(re=0);var le=0,ne=0,ue;try{for(var he=h(Q),oe=he.next();!oe.done;oe=he.next()){var ee=oe.value;if(ne=le+ee.length,re>=le&&re<=ne&&ee.match(/((?:https?|ftp):\/\/[\S]+)/)){ue=ee.replace(/[\s:.,'";}\]]+$/,"");break}le=ne}}catch(ye){j={error:ye}}finally{try{oe&&!oe.done&&(U=he.return)&&U.call(he)}finally{if(j)throw j.error}}return ue},$.prototype.openLink=function(){var A=this.selection.getCursor(),D=this.findLinkAt(A.row,A.column);return D&&window.open(D,"_blank"),D!=null},$.prototype.removeLines=function(){var A=this.$getSelectedRows();this.session.removeFullLines(A.first,A.last),this.clearSelection()},$.prototype.duplicateSelection=function(){var A=this.selection,D=this.session,j=A.getRange(),U=A.isBackwards();if(j.isEmpty()){var q=j.start.row;D.duplicateLines(q,q)}else{var Q=U?j.start:j.end,re=D.insert(Q,D.getTextRange(j));j.start=Q,j.end=re,A.setSelectionRange(j,U)}},$.prototype.moveLinesDown=function(){this.$moveLines(1,!1)},$.prototype.moveLinesUp=function(){this.$moveLines(-1,!1)},$.prototype.moveText=function(A,D,j){return this.session.moveText(A,D,j)},$.prototype.copyLinesUp=function(){this.$moveLines(-1,!0)},$.prototype.copyLinesDown=function(){this.$moveLines(1,!0)},$.prototype.$moveLines=function(A,D){var j,U,q=this.selection;if(!q.inMultiSelectMode||this.inVirtualSelectionMode){var Q=q.toOrientedRange();j=this.$getSelectedRows(Q),U=this.session.$moveLines(j.first,j.last,D?0:A),D&&A==-1&&(U=0),Q.moveBy(U,0),q.fromOrientedRange(Q)}else{var re=q.rangeList.ranges;q.rangeList.detach(this.session),this.inVirtualSelectionMode=!0;for(var le=0,ne=0,ue=re.length,he=0;he<ue;he++){var oe=he;re[he].moveBy(le,0),j=this.$getSelectedRows(re[he]);for(var ee=j.first,ye=j.last;++he<ue;){ne&&re[he].moveBy(ne,0);var we=this.$getSelectedRows(re[he]);if(D&&we.first!=ye||!D&&we.first>ye+1)break;ye=we.last}for(he--,le=this.session.$moveLines(ee,ye,D?0:A),D&&A==-1&&(oe=he+1);oe<=he;)re[oe].moveBy(le,0),oe++;D||(le=0),ne+=le}q.fromOrientedRange(q.ranges[0]),q.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},$.prototype.$getSelectedRows=function(A){return A=(A||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(A.start.row),last:this.session.getRowFoldEnd(A.end.row)}},$.prototype.onCompositionStart=function(A){this.renderer.showComposition(A)},$.prototype.onCompositionUpdate=function(A){this.renderer.setCompositionText(A)},$.prototype.onCompositionEnd=function(){this.renderer.hideComposition()},$.prototype.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},$.prototype.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},$.prototype.isRowVisible=function(A){return A>=this.getFirstVisibleRow()&&A<=this.getLastVisibleRow()},$.prototype.isRowFullyVisible=function(A){return A>=this.renderer.getFirstFullyVisibleRow()&&A<=this.renderer.getLastFullyVisibleRow()},$.prototype.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},$.prototype.$moveByPage=function(A,D){var j=this.renderer,U=this.renderer.layerConfig,q=A*Math.floor(U.height/U.lineHeight);D===!0?this.selection.$moveSelection(function(){this.moveCursorBy(q,0)}):D===!1&&(this.selection.moveCursorBy(q,0),this.selection.clearSelection());var Q=j.scrollTop;j.scrollBy(0,q*U.lineHeight),D!=null&&j.scrollCursorIntoView(null,.5),j.animateScrolling(Q)},$.prototype.selectPageDown=function(){this.$moveByPage(1,!0)},$.prototype.selectPageUp=function(){this.$moveByPage(-1,!0)},$.prototype.gotoPageDown=function(){this.$moveByPage(1,!1)},$.prototype.gotoPageUp=function(){this.$moveByPage(-1,!1)},$.prototype.scrollPageDown=function(){this.$moveByPage(1)},$.prototype.scrollPageUp=function(){this.$moveByPage(-1)},$.prototype.scrollToRow=function(A){this.renderer.scrollToRow(A)},$.prototype.scrollToLine=function(A,D,j,U){this.renderer.scrollToLine(A,D,j,U)},$.prototype.centerSelection=function(){var A=this.getSelectionRange(),D={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(D,.5)},$.prototype.getCursorPosition=function(){return this.selection.getCursor()},$.prototype.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},$.prototype.getSelectionRange=function(){return this.selection.getRange()},$.prototype.selectAll=function(){this.selection.selectAll()},$.prototype.clearSelection=function(){this.selection.clearSelection()},$.prototype.moveCursorTo=function(A,D){this.selection.moveCursorTo(A,D)},$.prototype.moveCursorToPosition=function(A){this.selection.moveCursorToPosition(A)},$.prototype.jumpToMatching=function(A,D){var j=this.getCursorPosition(),U=new _(this.session,j.row,j.column),q=U.getCurrentToken(),Q=0;q&&q.type.indexOf("tag-name")!==-1&&(q=U.stepBackward());var re=q||U.stepForward();if(re){var le,ne=!1,ue={},he=j.column-re.start,oe,ee={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(re.value.match(/[{}()\[\]]/g)){for(;he<re.value.length&&!ne;he++)if(ee[re.value[he]])switch(oe=ee[re.value[he]]+"."+re.type.replace("rparen","lparen"),isNaN(ue[oe])&&(ue[oe]=0),re.value[he]){case"(":case"[":case"{":ue[oe]++;break;case")":case"]":case"}":ue[oe]--,ue[oe]===-1&&(le="bracket",ne=!0);break}}else re.type.indexOf("tag-name")!==-1&&(isNaN(ue[re.value])&&(ue[re.value]=0),q.value==="<"&&Q>1?ue[re.value]++:q.value==="</"&&ue[re.value]--,ue[re.value]===-1&&(le="tag",ne=!0));ne||(q=re,Q++,re=U.stepForward(),he=0)}while(re&&!ne);if(le){var ye,we;if(le==="bracket")ye=this.session.getBracketRange(j),ye||(ye=new m(U.getCurrentTokenRow(),U.getCurrentTokenColumn()+he-1,U.getCurrentTokenRow(),U.getCurrentTokenColumn()+he-1),we=ye.start,(D||we.row===j.row&&Math.abs(we.column-j.column)<2)&&(ye=this.session.getBracketRange(we)));else if(le==="tag"){if(!re||re.type.indexOf("tag-name")===-1)return;if(ye=new m(U.getCurrentTokenRow(),U.getCurrentTokenColumn()-2,U.getCurrentTokenRow(),U.getCurrentTokenColumn()-2),ye.compare(j.row,j.column)===0){var Ae=this.session.getMatchingTags(j);Ae&&(Ae.openTag.contains(j.row,j.column)?(ye=Ae.closeTag,we=ye.start):(ye=Ae.openTag,Ae.closeTag.start.row===j.row&&Ae.closeTag.start.column===j.column?we=ye.end:we=ye.start))}we=we||ye.start}we=ye&&ye.cursor||we,we&&(A?ye&&D?this.selection.setRange(ye):ye&&ye.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(we.row,we.column):this.selection.moveTo(we.row,we.column))}}},$.prototype.gotoLine=function(A,D,j){this.selection.clearSelection(),this.session.unfold({row:A-1,column:D||0}),this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(A-1,D||0),this.isRowFullyVisible(A-1)||this.scrollToLine(A-1,!0,j)},$.prototype.navigateTo=function(A,D){this.selection.moveTo(A,D)},$.prototype.navigateUp=function(A){if(this.selection.isMultiLine()&&!this.selection.isBackwards()){var D=this.selection.anchor.getPosition();return this.moveCursorToPosition(D)}this.selection.clearSelection(),this.selection.moveCursorBy(-A||-1,0)},$.prototype.navigateDown=function(A){if(this.selection.isMultiLine()&&this.selection.isBackwards()){var D=this.selection.anchor.getPosition();return this.moveCursorToPosition(D)}this.selection.clearSelection(),this.selection.moveCursorBy(A||1,0)},$.prototype.navigateLeft=function(A){if(this.selection.isEmpty())for(A=A||1;A--;)this.selection.moveCursorLeft();else{var D=this.getSelectionRange().start;this.moveCursorToPosition(D)}this.clearSelection()},$.prototype.navigateRight=function(A){if(this.selection.isEmpty())for(A=A||1;A--;)this.selection.moveCursorRight();else{var D=this.getSelectionRange().end;this.moveCursorToPosition(D)}this.clearSelection()},$.prototype.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},$.prototype.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},$.prototype.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},$.prototype.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},$.prototype.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},$.prototype.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},$.prototype.replace=function(A,D){D&&this.$search.set(D);var j=this.$search.find(this.session),U=0;return j&&(this.$tryReplace(j,A)&&(U=1),this.selection.setSelectionRange(j),this.renderer.scrollSelectionIntoView(j.start,j.end)),U},$.prototype.replaceAll=function(A,D){D&&this.$search.set(D);var j=this.$search.findAll(this.session),U=0;if(!j.length)return U;var q=this.getSelectionRange();this.selection.moveTo(0,0);for(var Q=j.length-1;Q>=0;--Q)this.$tryReplace(j[Q],A)&&U++;return this.selection.setSelectionRange(q),U},$.prototype.$tryReplace=function(A,D){var j=this.session.getTextRange(A);return D=this.$search.replace(j,D),D!==null?(A.end=this.session.replace(A,D),A):null},$.prototype.getLastSearchOptions=function(){return this.$search.getOptions()},$.prototype.find=function(A,D,j){D||(D={}),typeof A=="string"||A instanceof RegExp?D.needle=A:typeof A=="object"&&g.mixin(D,A);var U=this.selection.getRange();D.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(D),D.start||this.$search.set({start:U});var q=this.$search.find(this.session);if(D.preventScroll)return q;if(q)return this.revealRange(q,j),q;D.backwards?U.start=U.end:U.end=U.start,this.selection.setRange(U)},$.prototype.findNext=function(A,D){this.find({skipCurrent:!0,backwards:!1},A,D)},$.prototype.findPrevious=function(A,D){this.find(A,{skipCurrent:!0,backwards:!0},D)},$.prototype.revealRange=function(A,D){this.session.unfold(A),this.selection.setSelectionRange(A);var j=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(A.start,A.end,.5),D!==!1&&this.renderer.animateScrolling(j)},$.prototype.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},$.prototype.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},$.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()},$.prototype.setAutoScrollEditorIntoView=function(A){if(A){var D,j=this,U=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var q=this.$scrollAnchor;q.style.cssText="position:absolute",this.container.insertBefore(q,this.container.firstChild);var Q=this.on("changeSelection",function(){U=!0}),re=this.renderer.on("beforeRender",function(){U&&(D=j.renderer.container.getBoundingClientRect())}),le=this.renderer.on("afterRender",function(){if(U&&D&&(j.isFocused()||j.searchBox&&j.searchBox.isFocused())){var ne=j.renderer,ue=ne.$cursorLayer.$pixelPos,he=ne.layerConfig,oe=ue.top-he.offset;ue.top>=0&&oe+D.top<0?U=!0:ue.top<he.height&&ue.top+D.top+he.lineHeight>window.innerHeight?U=!1:U=null,U!=null&&(q.style.top=oe+"px",q.style.left=ue.left+"px",q.style.height=he.lineHeight+"px",q.scrollIntoView(U)),U=D=null}});this.setAutoScrollEditorIntoView=function(ne){ne||(delete this.setAutoScrollEditorIntoView,this.off("changeSelection",Q),this.renderer.off("afterRender",le),this.renderer.off("beforeRender",re))}}},$.prototype.$resetCursorStyle=function(){var A=this.$cursorStyle||"ace",D=this.renderer.$cursorLayer;D&&(D.setSmoothBlinking(/smooth/.test(A)),D.isBlinking=!this.$readOnly&&A!="wide",v.setCssClass(D.element,"ace_slim-cursors",/slim/.test(A)))},$.prototype.prompt=function(A,D,j){var U=this;T.loadModule("ace/ext/prompt",function(q){q.prompt(U,A,D,j)})},Object.defineProperty($.prototype,"hoverTooltip",{get:function(){return this.$hoverTooltip||(this.$hoverTooltip=new B(this.container))},set:function(A){this.$hoverTooltip&&this.$hoverTooltip.destroy(),this.$hoverTooltip=A},enumerable:!1,configurable:!0}),$})();N.$uid=0,N.prototype.curOp=null,N.prototype.prevOp={},N.prototype.$mergeableCommands=["backspace","del","insertstring"],N.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(N.prototype,w),T.defineOptions(N.prototype,"editor",{selectionStyle:{set:function($){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:$})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function($){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function($){var A=this;if(this.textInput.setReadOnly($),!this.destroyed){this.$resetCursorStyle(),this.$readOnlyCallback||(this.$readOnlyCallback=function(j){var U=!1;if(j&&j.type=="keydown"){if(j&&j.key&&!j.ctrlKey&&!j.metaKey&&(j.key==" "&&j.preventDefault(),U=j.key.length==1),!U)return}else j&&j.type!=="exec"&&(U=!0);if(U){var q=v.createElement("div");q.textContent=P("editor.tooltip.disable-editing","Editing is disabled"),A.hoverTooltip.isOpen||A.hoverTooltip.showForRange(A,A.getSelectionRange(),q)}else A.hoverTooltip&&A.hoverTooltip.isOpen&&A.hoverTooltip.hide()});var D=this.textInput.getElement();$?(k.addListener(D,"keydown",this.$readOnlyCallback,this),this.commands.on("exec",this.$readOnlyCallback),this.commands.on("commandUnavailable",this.$readOnlyCallback)):(k.removeListener(D,"keydown",this.$readOnlyCallback),this.commands.off("exec",this.$readOnlyCallback),this.commands.off("commandUnavailable",this.$readOnlyCallback))}},initialValue:!1},copyWithEmptySelection:{set:function($){this.textInput.setCopyWithEmptySelection($)},initialValue:!1},cursorStyle:{set:function($){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($){this.setAutoScrollEditorIntoView($)}},keyboardHandler:{set:function($){this.setKeyboardHandler($)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function($){this.session.setValue($)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function($){this.setSession($)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function($){this.renderer.$gutterLayer.setShowLineNumbers($),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),$&&this.$relativeLineNumbers?M.attach(this):M.detach(this)},initialValue:!0},relativeLineNumbers:{set:function($){this.$showLineNumbers&&$?M.attach(this):M.detach(this)}},placeholder:{set:function($){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),v.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),v.addCssClass(this.container,"ace_hasPlaceholder");var D=v.createElement("div");D.className="ace_placeholder",D.textContent=this.$placeholder||"",this.renderer.placeholderNode=D,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($){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},D=function(U){if(U.target==this.renderer.scroller&&U.keyCode===E.enter){U.preventDefault();var q=this.getCursorPosition().row;this.isRowVisible(q)||this.scrollToLine(q,!0,!0),this.focus()}},j;$?(this.renderer.enableKeyboardAccessibility=!0,this.renderer.keyboardFocusClassName="ace_keyboard-focus",this.textInput.getElement().setAttribute("tabindex",-1),this.textInput.setNumberOfExtraLines(p.isWin?3:0),this.renderer.scroller.setAttribute("tabindex",0),this.renderer.scroller.setAttribute("role","group"),this.renderer.scroller.setAttribute("aria-roledescription",P("editor.scroller.aria-roledescription","editor")),this.renderer.scroller.classList.add(this.renderer.keyboardFocusClassName),this.renderer.scroller.setAttribute("aria-label",P("editor.scroller.aria-label","Editor content, press Enter to start editing, press Escape to exit")),this.renderer.scroller.addEventListener("keyup",D.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",P("editor.gutter.aria-roledescription","editor gutter")),this.renderer.$gutter.setAttribute("aria-label",P("editor.gutter.aria-label","Editor gutter, press Enter to interact with controls using arrow keys, press Escape to exit")),this.renderer.$gutter.classList.add(this.renderer.keyboardFocusClassName),this.renderer.content.setAttribute("aria-hidden",!0),j||(j=new C(this)),j.addListener(),this.textInput.setAriaOptions({setLabel:!0})):(this.renderer.enableKeyboardAccessibility=!1,this.textInput.getElement().setAttribute("tabindex",0),this.textInput.setNumberOfExtraLines(0),this.renderer.scroller.setAttribute("tabindex",-1),this.renderer.scroller.removeAttribute("role"),this.renderer.scroller.removeAttribute("aria-roledescription"),this.renderer.scroller.classList.remove(this.renderer.keyboardFocusClassName),this.renderer.scroller.removeAttribute("aria-label"),this.renderer.scroller.removeEventListener("keyup",D.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),j&&j.removeListener())},initialValue:!1},textInputAriaLabel:{set:function($){this.$textInputAriaLabel=$},initialValue:""},enableMobileMenu:{set:function($){this.$enableMobileMenu=$},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 M={getText:function($,A){return(Math.abs($.selection.lead.row-A)||A+1+(A<9?"·":""))+""},getWidth:function($,A,D){return Math.max(A.toString().length,(D.lastRow+1).toString().length,2)*D.characterWidth},update:function($,A){A.renderer.$loop.schedule(A.renderer.CHANGE_GUTTER)},attach:function($){$.renderer.$gutterLayer.$renderer=this,$.on("changeSelection",this.update),this.update(null,$)},detach:function($){$.renderer.$gutterLayer.$renderer==this&&($.renderer.$gutterLayer.$renderer=null),$.off("changeSelection",this.update),this.update(null,$)}};r.Editor=N}),ace.define("ace/layer/lines",["require","exports","module","ace/lib/dom"],function(t,r,c){var h=t("../lib/dom"),g=(function(){function v(s,p){this.element=s,this.canvasHeight=p||5e5,this.element.style.height=this.canvasHeight*2+"px",this.cells=[],this.cellCache=[],this.$offsetCoefficient=0}return v.prototype.moveContainer=function(s){h.translate(this.element,0,-(s.firstRowScreen*s.lineHeight%this.canvasHeight)-s.offset*this.$offsetCoefficient)},v.prototype.pageChanged=function(s,p){return Math.floor(s.firstRowScreen*s.lineHeight/this.canvasHeight)!==Math.floor(p.firstRowScreen*p.lineHeight/this.canvasHeight)},v.prototype.computeLineTop=function(s,p,a){var l=p.firstRowScreen*p.lineHeight,u=Math.floor(l/this.canvasHeight),d=a.documentToScreenRow(s,0)*p.lineHeight;return d-u*this.canvasHeight},v.prototype.$getCellByScreenRow=function(s,p){for(var a=p.firstRowScreen*p.lineHeight,l=Math.floor(a/this.canvasHeight),u=s*p.lineHeight-l*this.canvasHeight,d=this.cells.length-1;d>=0;d--){var o=this.cells[d],f=parseInt(o.element.style.top),m=parseInt(o.element.style.height);if(f<=u){if(f+m<u)return null;var w=u-f;return{cell:o,offset:w}}}return null},v.prototype.computeLineHeight=function(s,p,a){return p.lineHeight*a.getRowLineCount(s)},v.prototype.getLength=function(){return this.cells.length},v.prototype.get=function(s){return this.cells[s]},v.prototype.shift=function(){this.$cacheCell(this.cells.shift())},v.prototype.pop=function(){this.$cacheCell(this.cells.pop())},v.prototype.push=function(s){if(Array.isArray(s)){this.cells.push.apply(this.cells,s);for(var p=h.createFragment(this.element),a=0;a<s.length;a++)p.appendChild(s[a].element);this.element.appendChild(p)}else this.cells.push(s),this.element.appendChild(s.element)},v.prototype.unshift=function(s){if(Array.isArray(s)){this.cells.unshift.apply(this.cells,s);for(var p=h.createFragment(this.element),a=0;a<s.length;a++)p.appendChild(s[a].element);this.element.firstChild?this.element.insertBefore(p,this.element.firstChild):this.element.appendChild(p)}else this.cells.unshift(s),this.element.insertAdjacentElement("afterbegin",s.element)},v.prototype.last=function(){return this.cells.length?this.cells[this.cells.length-1]:null},v.prototype.$cacheCell=function(s){s&&(s.element.remove(),this.cellCache.push(s))},v.prototype.createCell=function(s,p,a,l){var u=this.cellCache.pop();if(!u){var d=h.createElement("div");l&&l(d),this.element.appendChild(d),u={element:d,text:"",row:s}}return u.row=s,u},v})();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(t,r,c){var h=t("../lib/dom"),g=t("../lib/oop"),v=t("../lib/lang"),s=t("../lib/event_emitter").EventEmitter,p=t("./lines").Lines,a=t("../config").nls,l=(function(){function d(o){this.$showCursorMarker=null,this.element=h.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 p(this.element),this.$lines.$offsetCoefficient=1}return d.prototype.setSession=function(o){this.session&&this.session.off("change",this.$updateAnnotations),this.session=o,o&&o.on("change",this.$updateAnnotations)},d.prototype.addGutterDecoration=function(o,f){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(o,f)},d.prototype.removeGutterDecoration=function(o,f){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(o,f)},d.prototype.setAnnotations=function(o){this.$annotations=[];for(var f=0;f<o.length;f++){var m=o[f],w=m.row,x=this.$annotations[w];x||(x=this.$annotations[w]={text:[],type:[],displayText:[]});var R=m.text,T=m.text,_=m.type;R=R?v.escapeHTML(R):m.html||"",T=T||m.html||"",x.text.indexOf(R)===-1&&(x.text.push(R),x.type.push(_),x.displayText.push(T));var C=m.className;C?x.className=C:_==="error"?x.className=" ace_error":_==="security"&&!/\bace_error\b/.test(x.className)?x.className=" ace_security":_==="warning"&&!/\bace_(error|security)\b/.test(x.className)?x.className=" ace_warning":_==="info"&&!x.className?x.className=" ace_info":_==="hint"&&!x.className&&(x.className=" ace_hint")}},d.prototype.$updateAnnotations=function(o){if(this.$annotations.length){var f=o.start.row,m=o.end.row-f;if(m!==0)if(o.action=="remove")this.$annotations.splice(f,m+1,null);else{var w=new Array(m+1);w.unshift(f,1),this.$annotations.splice.apply(this.$annotations,w)}}},d.prototype.update=function(o){this.config=o;var f=this.session,m=o.firstRow,w=Math.min(o.lastRow+o.gutterOffset,f.getLength()-1);this.oldLastRow=w,this.config=o,this.$lines.moveContainer(o),this.$updateCursorRow();for(var x=f.getNextFoldLine(m),R=x?x.start.row:1/0,T=null,_=-1,C=m;;){if(C>R&&(C=x.end.row+1,x=f.getNextFoldLine(C,x),R=x?x.start.row:1/0),C>w){for(;this.$lines.getLength()>_+1;)this.$lines.pop();break}T=this.$lines.get(++_),T?T.row=C:(T=this.$lines.createCell(C,o,this.session,u),this.$lines.push(T)),this.$renderCell(T,o,x,C),C++}this._signal("afterRender"),this.$updateGutterWidth(o),this.$showCursorMarker&&this.$highlightGutterLine&&this.$updateCursorMarker()},d.prototype.$updateGutterWidth=function(o){var f=this.session,m=f.gutterRenderer||this.$renderer,w=f.$firstLineNumber,x=this.$lines.last()?this.$lines.last().text:"";(this.$fixedWidth||f.$useWrapMode)&&(x=f.getLength()+w-1);var R=m?m.getWidth(f,x,o):x.toString().length*o.characterWidth,T=this.$padding||this.$computePadding();R+=T.left+T.right,R!==this.gutterWidth&&!isNaN(R)&&(this.gutterWidth=R,this.element.parentNode.style.width=this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._signal("changeGutterWidth",R))},d.prototype.$updateCursorRow=function(){if(this.$highlightGutterLine){var o=this.session.selection.getCursor();this.$cursorRow!==o.row&&(this.$cursorRow=o.row)}},d.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 f=this.$lines.cells;this.$cursorCell=null;for(var m=0;m<f.length;m++){var w=f[m];if(w.row>=this.$cursorRow){if(w.row>this.$cursorRow){var x=this.session.getFoldLine(this.$cursorRow);if(m>0&&x&&x.start.row==f[m-1].row)w=f[m-1];else break}w.element.className="ace_gutter-active-line "+w.element.className,this.$cursorCell=w;break}}}}},d.prototype.$updateCursorMarker=function(){if(this.session){var o=this.session;this.$highlightElement||(this.$highlightElement=h.createElement("div"),this.$highlightElement.className="ace_gutter-cursor",this.$highlightElement.style.pointerEvents="none",this.element.appendChild(this.$highlightElement));var f=o.selection.cursor,m=this.config,w=this.$lines,x=m.firstRowScreen*m.lineHeight,R=Math.floor(x/w.canvasHeight),T=o.documentToScreenRow(f)*m.lineHeight,_=T-R*w.canvasHeight;h.setStyle(this.$highlightElement.style,"height",m.lineHeight+"px"),h.setStyle(this.$highlightElement.style,"top",_+"px")}},d.prototype.scrollLines=function(o){var f=this.config;if(this.config=o,this.$updateCursorRow(),this.$lines.pageChanged(f,o))return this.update(o);this.$lines.moveContainer(o);var m=Math.min(o.lastRow+o.gutterOffset,this.session.getLength()-1),w=this.oldLastRow;if(this.oldLastRow=m,!f||w<o.firstRow)return this.update(o);if(m<f.firstRow)return this.update(o);if(f.firstRow<o.firstRow)for(var x=this.session.getFoldedRowCount(f.firstRow,o.firstRow-1);x>0;x--)this.$lines.shift();if(w>m)for(var x=this.session.getFoldedRowCount(m+1,w);x>0;x--)this.$lines.pop();o.firstRow<f.firstRow&&this.$lines.unshift(this.$renderLines(o,o.firstRow,f.firstRow-1)),m>w&&this.$lines.push(this.$renderLines(o,w+1,m)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(o)},d.prototype.$renderLines=function(o,f,m){for(var w=[],x=f,R=this.session.getNextFoldLine(x),T=R?R.start.row:1/0;x>T&&(x=R.end.row+1,R=this.session.getNextFoldLine(x,R),T=R?R.start.row:1/0),!(x>m);){var _=this.$lines.createCell(x,o,this.session,u);this.$renderCell(_,o,R,x),w.push(_),x++}return w},d.prototype.$renderCell=function(o,f,m,w){var x=o.element,R=this.session,T=x.childNodes[0],_=x.childNodes[1],C=x.childNodes[2],P=x.childNodes[3],O=C.firstChild,E=R.$firstLineNumber,k=R.$breakpoints,B=R.$decorations,N=R.gutterRenderer||this.$renderer,M=this.$showFoldWidgets&&R.foldWidgets,$=m?m.start.row:Number.MAX_VALUE,A=f.lineHeight+"px",D=this.$useSvgGutterIcons?"ace_gutter-cell_svg-icons ":"ace_gutter-cell ",j=this.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",U=(N?N.getText(R,w):w+E).toString();if(this.$highlightGutterLine&&(w==this.$cursorRow||m&&w<this.$cursorRow&&w>=$&&this.$cursorRow<=m.end.row)&&(D+="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)),k[w]&&(D+=k[w]),B[w]&&(D+=B[w]),this.$annotations[w]&&w!==$&&(D+=this.$annotations[w].className),M){var q=M[w];q==null&&(q=M[w]=R.getFoldWidget(w))}if(q){var Q="ace_fold-widget ace_"+q,re=q=="start"&&w==$&&w<m.end.row;if(re){Q+=" ace_closed";for(var le="",ne=!1,ue=w+1;ue<=m.end.row;ue++)if(this.$annotations[ue]){if(this.$annotations[ue].className===" ace_error"){ne=!0,le=" ace_error_fold";break}this.$annotations[ue].className===" ace_security"?(ne=!0,le=" ace_security_fold"):this.$annotations[ue].className===" ace_warning"&&le!==" ace_security_fold"&&(ne=!0,le=" ace_warning_fold")}D+=le}else Q+=" ace_open";_.className!=Q&&(_.className=Q),h.setStyle(_.style,"height",A),h.setStyle(_.style,"display","inline-block"),_.setAttribute("role","button"),_.setAttribute("tabindex","-1");var he=R.getFoldWidgetRange(w);he?_.setAttribute("aria-label",a("gutter.code-folding.range.aria-label","Toggle code folding, rows $0 through $1",[he.start.row+1,he.end.row+1])):m?_.setAttribute("aria-label",a("gutter.code-folding.closed.aria-label","Toggle code folding, rows $0 through $1",[m.start.row+1,m.end.row+1])):_.setAttribute("aria-label",a("gutter.code-folding.open.aria-label","Toggle code folding, row $0",[w+1])),re?(_.setAttribute("aria-expanded","false"),_.setAttribute("title",a("gutter.code-folding.closed.title","Unfold code"))):(_.setAttribute("aria-expanded","true"),_.setAttribute("title",a("gutter.code-folding.open.title","Fold code")))}else _&&(h.setStyle(_.style,"display","none"),_.setAttribute("tabindex","0"),_.removeAttribute("role"),_.removeAttribute("aria-label"));var oe=this.session.$gutterCustomWidgets[w];if(oe?this.$addCustomWidget(w,oe,o):P&&this.$removeCustomWidget(w,o),ne&&this.$showFoldedAnnotations){C.className="ace_gutter_annotation",O.className=j,O.className+=le,h.setStyle(O.style,"height",A),h.setStyle(C.style,"display","block"),h.setStyle(C.style,"height",A);var ee;switch(le){case" ace_error_fold":ee=a("gutter.annotation.aria-label.error","Error, read annotations row $0",[U]);break;case" ace_security_fold":ee=a("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[U]);break;case" ace_warning_fold":ee=a("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[U]);break}C.setAttribute("aria-label",ee),C.setAttribute("tabindex","-1"),C.setAttribute("role","button")}else if(this.$annotations[w]){C.className="ace_gutter_annotation",O.className=j,this.$useSvgGutterIcons?O.className+=this.$annotations[w].className:x.classList.add(this.$annotations[w].className.replace(" ","")),h.setStyle(O.style,"height",A),h.setStyle(C.style,"display","block"),h.setStyle(C.style,"height",A);var ee;switch(this.$annotations[w].className){case" ace_error":ee=a("gutter.annotation.aria-label.error","Error, read annotations row $0",[U]);break;case" ace_security":ee=a("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[U]);break;case" ace_warning":ee=a("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[U]);break;case" ace_info":ee=a("gutter.annotation.aria-label.info","Info, read annotations row $0",[U]);break;case" ace_hint":ee=a("gutter.annotation.aria-label.hint","Suggestion, read annotations row $0",[U]);break}C.setAttribute("aria-label",ee),C.setAttribute("tabindex","-1"),C.setAttribute("role","button")}else h.setStyle(C.style,"display","none"),C.removeAttribute("aria-label"),C.removeAttribute("role"),C.setAttribute("tabindex","0");return U!==T.data&&(T.data=U),x.className!=D&&(x.className=D),h.setStyle(o.element.style,"height",this.$lines.computeLineHeight(w,f,R)+"px"),h.setStyle(o.element.style,"top",this.$lines.computeLineTop(w,f,R)+"px"),o.text=U,C.style.display==="none"&&_.style.display==="none"&&!oe?o.element.setAttribute("aria-hidden",!0):o.element.setAttribute("aria-hidden",!1),o},d.prototype.setHighlightGutterLine=function(o){this.$highlightGutterLine=o,!o&&this.$highlightElement&&(this.$highlightElement.remove(),this.$highlightElement=null)},d.prototype.setShowLineNumbers=function(o){this.$renderer=!o&&{getWidth:function(){return 0},getText:function(){return""}}},d.prototype.getShowLineNumbers=function(){return this.$showLineNumbers},d.prototype.setShowFoldWidgets=function(o){o?h.addCssClass(this.element,"ace_folding-enabled"):h.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=o,this.$padding=null},d.prototype.getShowFoldWidgets=function(){return this.$showFoldWidgets},d.prototype.$hideFoldWidget=function(o,f){var m=f||this.$getGutterCell(o);if(m&&m.element){var w=m.element.childNodes[1];w&&h.setStyle(w.style,"display","none")}},d.prototype.$showFoldWidget=function(o,f){var m=f||this.$getGutterCell(o);if(m&&m.element){var w=m.element.childNodes[1];w&&this.session.foldWidgets&&this.session.foldWidgets[m.row]&&h.setStyle(w.style,"display","inline-block")}},d.prototype.$getGutterCell=function(o){var f=this.$lines.cells,m=0,w=f.length-1;if(!(o<f[0].row||o>f[w].row)){for(;m<=w;){var x=Math.floor((m+w)/2),R=f[x];if(R.row>o)w=x-1;else if(R.row<o)m=x+1;else return R}return R}},d.prototype.$addCustomWidget=function(o,f,m){var w=f.className,x=f.label,R=f.title,T=f.callbacks;this.session.$gutterCustomWidgets[o]={className:w,label:x,title:R,callbacks:T},this.$hideFoldWidget(o,m);var _=m||this.$getGutterCell(o);if(_&&_.element){var C=_.element.querySelector(".ace_custom-widget");C&&C.remove(),C=h.createElement("span"),C.className="ace_custom-widget ".concat(w),C.setAttribute("tabindex","-1"),C.setAttribute("role","button"),C.setAttribute("aria-label",x),C.setAttribute("title",R),h.setStyle(C.style,"display","inline-block"),h.setStyle(C.style,"height","inherit"),T&&T.onClick&&C.addEventListener("click",function(P){T.onClick(P,o),P.stopPropagation()}),_.element.appendChild(C)}},d.prototype.$removeCustomWidget=function(o,f){delete this.session.$gutterCustomWidgets[o],this.$showFoldWidget(o,f);var m=f||this.$getGutterCell(o);if(m&&m.element){var w=m.element.querySelector(".ace_custom-widget");w&&m.element.removeChild(w)}},d.prototype.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var o=h.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},d.prototype.getRegion=function(o){var f=this.$padding||this.$computePadding(),m=this.element.getBoundingClientRect();if(o.x<f.left+m.left)return"markers";if(this.$showFoldWidgets&&o.x>m.right-f.right)return"foldWidgets"},d})();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,s);function u(d){var o=document.createTextNode("");d.appendChild(o);var f=h.createElement("span");d.appendChild(f);var m=h.createElement("span");d.appendChild(m);var w=h.createElement("span");return m.appendChild(w),d}r.Gutter=l}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(t,r,c){var h=t("../range").Range,g=t("../lib/dom"),v=(function(){function p(a){this.element=g.createElement("div"),this.element.className="ace_layer ace_marker-layer",a.appendChild(this.element)}return p.prototype.setPadding=function(a){this.$padding=a},p.prototype.setSession=function(a){this.session=a},p.prototype.setMarkers=function(a){this.markers=a},p.prototype.elt=function(a,l){var u=this.i!=-1&&this.element.childNodes[this.i];u?this.i++:(u=document.createElement("div"),this.element.appendChild(u),this.i=-1),u.style.cssText=l,u.className=a},p.prototype.update=function(a){if(a){this.config=a,this.element.style.display="none",this.i=0;var l;for(var u in this.markers){var d=this.markers[u];if(!d.range){d.update(l,this,this.session,a);continue}var o=d.range.clipRows(a.firstRow,a.lastRow);if(!o.isEmpty())if(o=o.toScreenRange(this.session),d.renderer){var f=this.$getTop(o.start.row,a),m=this.$padding+a.fontMetrics.textWidth(o.start.row,o.start.column);d.renderer(l,o,m,f,a)}else d.type=="fullLine"?this.drawFullLineMarker(l,o,d.clazz,a):d.type=="screenLine"?this.drawScreenLineMarker(l,o,d.clazz,a):o.isMultiLine()?d.type=="text"?this.drawTextMarker(l,o,d.clazz,a):this.drawMultiLineMarker(l,o,d.clazz,a):this.drawSingleLineMarker(l,o,d.clazz+" ace_start ace_br15",a)}if(this.i!=-1)for(;this.i<this.element.childElementCount;)this.element.removeChild(this.element.lastChild);this.element.style.display=""}},p.prototype.$getTop=function(a,l){return(a-l.firstRowScreen)*l.lineHeight},p.prototype.drawTextMarker=function(a,l,u,d,o){for(var f=this.session,m=l.start.row,w=l.end.row,x=m,R=0,T=0,_=f.getScreenLastRowColumn(x),C=new h(x,l.start.column,x,T);x<=w;x++)C.start.row=C.end.row=x,C.start.column=x==m?l.start.column:f.getRowWrapIndent(x),C.end.column=_,R=T,T=_,_=x+1<w?f.getScreenLastRowColumn(x+1):x==w?0:l.end.column,this.drawSingleLineMarker(a,C,u+(x==m?" ace_start":"")+" ace_br"+s(x==m||x==m+1&&l.start.column,R<T,T>_,x==w),d,x==w?0:1,o)},p.prototype.drawMultiLineMarker=function(a,l,u,d,o){var f=this.$padding,m=d.lineHeight,w=this.$getTop(l.start.row,d),x=f+d.fontMetrics.textWidth(l.start.row,l.start.column);if(o=o||"",this.session.$bidiHandler.isBidiRow(l.start.row)){var R=l.clone();R.end.row=R.start.row,R.end.column=Number.MAX_VALUE,this.drawBidiSingleLineMarker(a,R,u+" ace_br1 ace_start",d,null,o)}else this.elt(u+" ace_br1 ace_start","height:"+m+"px;right:"+f+"px;top:"+w+"px;left:"+x+"px;"+(o||""));if(this.session.$bidiHandler.isBidiRow(l.end.row)){var R=l.clone();R.start.row=R.end.row,R.start.column=0,this.drawBidiSingleLineMarker(a,R,u+" ace_br12",d,null,o)}else{w=this.$getTop(l.end.row,d);var T=d.fontMetrics.textWidth(l.end.row,l.end.column);this.elt(u+" ace_br12","height:"+m+"px;width:"+T+"px;top:"+w+"px;left:"+f+"px;"+(o||""))}if(m=(l.end.row-l.start.row-1)*d.lineHeight,!(m<=0)){w=this.$getTop(l.start.row+1,d);var _=(l.start.column?1:0)|(l.end.column?0:8);this.elt(u+(_?" ace_br"+_:""),"height:"+m+"px;right:"+f+"px;top:"+w+"px;left:"+f+"px;"+(o||""))}},p.prototype.drawSingleLineMarker=function(a,l,u,d,o,f){if(this.session.$bidiHandler.isBidiRow(l.start.row))return this.drawBidiSingleLineMarker(a,l,u,d,o,f);var m=d.lineHeight,w=d.fontMetrics.textWidth(l.start.row,l.end.column)+(o||0)*d.characterWidth,x=this.$getTop(l.start.row,d),R=d.fontMetrics.textWidth(l.start.row,l.start.column);this.elt(u,"height:"+m+"px;width:"+(w-R)+"px;top:"+x+"px;left:"+(this.$padding+R)+"px;"+(f||""))},p.prototype.drawBidiSingleLineMarker=function(a,l,u,d,o,f){var m=d.lineHeight,w=this.$getTop(l.start.row,d),x=this.$padding,R=this.config.fontMetrics.getRects(l.start,l.end);R.forEach(function(T){this.elt(u,"height:"+m+"px;width:"+(T.width+(o||0))+"px;top:"+w+"px;left:"+(x+T.left)+"px;"+(f||""))},this)},p.prototype.drawFullLineMarker=function(a,l,u,d,o){var f=this.$getTop(l.start.row,d),m=d.lineHeight;l.start.row!=l.end.row&&(m+=this.$getTop(l.end.row,d)-f),this.elt(u,"height:"+m+"px;top:"+f+"px;left:0;right:0;"+(o||""))},p.prototype.drawScreenLineMarker=function(a,l,u,d,o){var f=this.$getTop(l.start.row,d),m=d.lineHeight;this.elt(u,"height:"+m+"px;top:"+f+"px;left:0;right:0;"+(o||""))},p})();v.prototype.$padding=0;function s(p,a,l,u){return(p?1:0)|(a?2:0)|(l?4:0)|(u?8:0)}r.Marker=v}),ace.define("ace/layer/text_util",["require","exports","module"],function(t,r,c){var h=new Set(["text","rparen","lparen"]);r.isTextToken=function(g){return h.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(t,r,c){var h=t("../lib/oop"),g=t("../lib/dom"),v=t("../lib/lang"),s=t("./lines").Lines,p=t("../lib/event_emitter").EventEmitter,a=t("../config").nls,l=t("./text_util").isTextToken,u=(function(){function d(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 s(this.element)}return d.prototype.$updateEolChar=function(){var o=this.session.doc,f=o.getNewLineCharacter()==`
219
+ `&&o.getNewLineMode()!="windows",m=f?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=m)return this.EOL_CHAR=m,!0},d.prototype.setPadding=function(o){this.$padding=o,this.element.style.margin="0 "+o+"px"},d.prototype.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},d.prototype.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},d.prototype.$setFontMetrics=function(o){this.$fontMetrics=o,this.$fontMetrics.on("changeCharacterSize",(function(f){this._signal("changeCharacterSize",f)}).bind(this)),this.$pollSizeChanges()},d.prototype.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},d.prototype.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},d.prototype.setSession=function(o){this.session=o,o&&this.$computeTabString()},d.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)},d.prototype.setDisplayIndentGuides=function(o){return this.displayIndentGuides==o?!1:(this.displayIndentGuides=o,this.$computeTabString(),!0)},d.prototype.setHighlightIndentGuides=function(o){return this.$highlightIndentGuides===o?!1:(this.$highlightIndentGuides=o,o)},d.prototype.$computeTabString=function(){var o=this.session.getTabSize();this.tabSize=o;for(var f=this.$tabStrings=[0],m=1;m<o+1;m++)if(this.showTabs){var w=this.dom.createElement("span");w.className="ace_invisible ace_invisible_tab",w.textContent=v.stringRepeat(this.TAB_CHAR,m),f.push(w)}else f.push(this.dom.createTextNode(v.stringRepeat(" ",m),this.element));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;var x="ace_indent-guide",R=this.showSpaces?" ace_invisible ace_invisible_space":"",T=this.showSpaces?v.stringRepeat(this.SPACE_CHAR,this.tabSize):v.stringRepeat(" ",this.tabSize),_=this.showTabs?" ace_invisible ace_invisible_tab":"",C=this.showTabs?v.stringRepeat(this.TAB_CHAR,this.tabSize):T,w=this.dom.createElement("span");w.className=x+R,w.textContent=T,this.$tabStrings[" "]=w;var w=this.dom.createElement("span");w.className=x+_,w.textContent=C,this.$tabStrings[" "]=w}},d.prototype.updateLines=function(o,f,m){if(this.config.lastRow!=o.lastRow||this.config.firstRow!=o.firstRow)return this.update(o);this.config=o;for(var w=Math.max(f,o.firstRow),x=Math.min(m,o.lastRow),R=this.element.childNodes,T=0,_=o.firstRow;_<w;_++){var C=this.session.getFoldLine(_);if(C)if(C.containsRow(w)){w=C.start.row;break}else _=C.end.row;T++}for(var P=!1,_=w,C=this.session.getNextFoldLine(_),O=C?C.start.row:1/0;_>O&&(_=C.end.row+1,C=this.session.getNextFoldLine(_,C),O=C?C.start.row:1/0),!(_>x);){var E=R[T++];if(E){this.dom.removeChildren(E),this.$renderLine(E,_,_==O?C:!1),P&&(E.style.top=this.$lines.computeLineTop(_,o,this.session)+"px");var k=o.lineHeight*this.session.getRowLength(_)+"px";E.style.height!=k&&(P=!0,E.style.height=k)}_++}if(P)for(;T<this.$lines.cells.length;){var B=this.$lines.cells[T++];B.element.style.top=this.$lines.computeLineTop(B.row,o,this.session)+"px"}},d.prototype.scrollLines=function(o){var f=this.config;if(this.config=o,this.$lines.pageChanged(f,o))return this.update(o);this.$lines.moveContainer(o);var m=o.lastRow,w=f?f.lastRow:-1;if(!f||w<o.firstRow)return this.update(o);if(m<f.firstRow)return this.update(o);if(!f||f.lastRow<o.firstRow)return this.update(o);if(o.lastRow<f.firstRow)return this.update(o);if(f.firstRow<o.firstRow)for(var x=this.session.getFoldedRowCount(f.firstRow,o.firstRow-1);x>0;x--)this.$lines.shift();if(f.lastRow>o.lastRow)for(var x=this.session.getFoldedRowCount(o.lastRow+1,f.lastRow);x>0;x--)this.$lines.pop();o.firstRow<f.firstRow&&this.$lines.unshift(this.$renderLinesFragment(o,o.firstRow,f.firstRow-1)),o.lastRow>f.lastRow&&this.$lines.push(this.$renderLinesFragment(o,f.lastRow+1,o.lastRow)),this.$highlightIndentGuide()},d.prototype.$renderLinesFragment=function(o,f,m){for(var w=[],x=f,R=this.session.getNextFoldLine(x),T=R?R.start.row:1/0;x>T&&(x=R.end.row+1,R=this.session.getNextFoldLine(x,R),T=R?R.start.row:1/0),!(x>m);){var _=this.$lines.createCell(x,o,this.session),C=_.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==T?R:!1),this.$useLineGroups()?C.className="ace_line_group":C.className="ace_line",w.push(_),x++}return w},d.prototype.update=function(o){this.$lines.moveContainer(o),this.config=o;for(var f=o.firstRow,m=o.lastRow,w=this.$lines;w.getLength();)w.pop();w.push(this.$renderLinesFragment(o,f,m))},d.prototype.$renderToken=function(o,f,m,w){for(var x=this,R=/(\t)|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200C\u200E\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+)/g,T=this.dom.createFragment(this.element),_,C=0;_=R.exec(w);){var P=_[1],O=_[2],E=_[3],k=_[4];if(!(!x.showSpaces&&O)){var B=C!=_.index?w.slice(C,_.index):"";if(C=_.index+_[0].length,B&&T.appendChild(this.dom.createTextNode(B,this.element)),P){var N=x.session.getScreenTabSize(f+_.index),M=x.$tabStrings[N].cloneNode(!0);M.charCount=1,T.appendChild(M),f+=N-1}else if(O)if(x.showSpaces){var $=this.dom.createElement("span");$.className="ace_invisible ace_invisible_space",$.textContent=v.stringRepeat(x.SPACE_CHAR,O.length),T.appendChild($)}else T.appendChild(this.dom.createTextNode(O,this.element));else if(E){var $=this.dom.createElement("span");$.className="ace_invisible ace_invisible_space ace_invalid",$.textContent=v.stringRepeat(x.SPACE_CHAR,E.length),T.appendChild($)}else if(k)if(x.showSpaces){var $=this.dom.createElement("span");$.className="ace_invisible ace_invisible_space",$.textContent=v.stringRepeat(x.CJK_SPACE_CHAR,k.length),T.appendChild($)}else T.appendChild(this.dom.createTextNode(k,this.element))}}var A=C?w.slice(C):w;if(A.length>256)for(var D=0;D<A.length;)T.appendChild(this.dom.createTextNode(A.slice(D,D+=256),this.element));else T.appendChild(this.dom.createTextNode(A,this.element));if(l(m.type))o.appendChild(T);else{var j="ace_"+m.type.replace(/\./g," ace_"),$=this.dom.createElement("span");m.type=="fold"&&($.style.width=m.value.length*this.config.characterWidth+"px",$.setAttribute("title",a("inline-fold.closed.title","Unfold code"))),$.className=j,$.appendChild(T),o.appendChild($)}return f+w.length},d.prototype.renderIndentGuide=function(o,f,m){var w=f.search(this.$indentGuideRe);if(w<=0||w>=m)return f;if(f[0]==" "){w-=w%this.tabSize;for(var x=w/this.tabSize,R=0;R<x;R++)o.appendChild(this.$tabStrings[" "].cloneNode(!0));return this.$highlightIndentGuide(),f.substr(w)}else if(f[0]==" "){for(var R=0;R<w;R++){var T=this.$tabStrings[" "].cloneNode(!0);T.charCount=1,o.appendChild(T)}return this.$highlightIndentGuide(),f.substr(w)}return this.$highlightIndentGuide(),f},d.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 f=this.session.selection.getCursor(),m=/^\s*/.exec(this.session.doc.getLine(f.row))[0].length,w=Math.floor(m/this.tabSize);this.$highlightIndentGuideMarker={indentLevel:w,start:f.row};var x=this.session.$bracketHighlight;if(x){for(var R=this.session.$bracketHighlight.ranges,T=0;T<R.length;T++)if(f.row!==R[T].start.row){this.$highlightIndentGuideMarker.end=R[T].start.row+1,f.row>R[T].start.row?this.$highlightIndentGuideMarker.dir=-1:this.$highlightIndentGuideMarker.dir=1;break}}if(!this.$highlightIndentGuideMarker.end&&o[f.row]!==""&&f.column===o[f.row].length){this.$highlightIndentGuideMarker.dir=1;for(var T=f.row+1;T<o.length;T++){var _=o[T],C=/^\s*/.exec(_)[0].length;if(_!==""&&(this.$highlightIndentGuideMarker.end=T,C<=m))break}}this.$renderHighlightIndentGuide()}}},d.prototype.$clearActiveIndentGuide=function(){for(var o=this.element.querySelectorAll(".ace_indent-guide-active"),f=0;f<o.length;f++)o[f].classList.remove("ace_indent-guide-active")},d.prototype.$setIndentGuideActive=function(o,f){var m=this.session.doc.getLine(o.row);if(m!==""){var w=o.element;if(o.element.classList&&o.element.classList.contains("ace_line_group"))if(o.element.childNodes.length>0)w=o.element.childNodes[0];else return;var x=w.childNodes;if(x){var R=x[f-1];R&&R.classList&&R.classList.contains("ace_indent-guide")&&R.classList.add("ace_indent-guide-active")}}},d.prototype.$renderHighlightIndentGuide=function(){if(this.$lines){var o=this.$lines.cells;this.$clearActiveIndentGuide();var f=this.$highlightIndentGuideMarker.indentLevel;if(f!==0)if(this.$highlightIndentGuideMarker.dir===1)for(var m=0;m<o.length;m++){var w=o[m];if(this.$highlightIndentGuideMarker.end&&w.row>=this.$highlightIndentGuideMarker.start+1){if(w.row>=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(w,f)}}else for(var m=o.length-1;m>=0;m--){var w=o[m];if(this.$highlightIndentGuideMarker.end&&w.row<this.$highlightIndentGuideMarker.start){if(w.row<this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(w,f)}}}},d.prototype.$createLineElement=function(o){var f=this.dom.createElement("div");return f.className="ace_line",f.style.height=this.config.lineHeight+"px",f},d.prototype.$renderWrappedLine=function(o,f,m){var w=0,x=0,R=m[0],T=0,_=this.$createLineElement();o.appendChild(_);for(var C=0;C<f.length;C++){var P=f[C],O=P.value;if(C==0&&this.displayIndentGuides){if(w=O.length,O=this.renderIndentGuide(_,O,R),!O)continue;w-=O.length}if(w+O.length<R)T=this.$renderToken(_,T,P,O),w+=O.length;else{for(;w+O.length>=R;){T=this.$renderToken(_,T,P,O.substring(0,R-w)),O=O.substring(R-w),w=R,_=this.$createLineElement(),o.appendChild(_);var E=this.dom.createTextNode(v.stringRepeat(" ",m.indent),this.element);E.charCount=0,_.appendChild(E),x++,T=0,R=m[x]||Number.MAX_VALUE}O.length!=0&&(w+=O.length,T=this.$renderToken(_,T,P,O))}}m[m.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage(_,T,null,"",!0)},d.prototype.$renderSimpleLine=function(o,f){for(var m=0,w=0;w<f.length;w++){var x=f[w],R=x.value;if(!(w==0&&this.displayIndentGuides&&(R=this.renderIndentGuide(o,R),!R))){if(m+R.length>this.MAX_LINE_LENGTH)return this.$renderOverflowMessage(o,m,x,R);m=this.$renderToken(o,m,x,R)}}},d.prototype.$renderOverflowMessage=function(o,f,m,w,x){m&&this.$renderToken(o,f,m,w.slice(0,this.MAX_LINE_LENGTH-f));var R=this.dom.createElement("span");R.className="ace_inline_button ace_keyword ace_toggle_wrap",R.textContent=x?"<hide>":"<click to see more...>",o.appendChild(R)},d.prototype.$renderLine=function(o,f,m){if(!m&&m!=!1&&(m=this.session.getFoldLine(f)),m)var w=this.$getFoldLineTokens(f,m);else var w=this.session.getTokens(f);var x=o;if(w.length){var R=this.session.getRowSplitData(f);if(R&&R.length){this.$renderWrappedLine(o,w,R);var x=o.lastChild}else{var x=o;this.$useLineGroups()&&(x=this.$createLineElement(),o.appendChild(x)),this.$renderSimpleLine(x,w)}}else this.$useLineGroups()&&(x=this.$createLineElement(),o.appendChild(x));if(this.showEOL&&x){m&&(f=m.end.row);var T=this.dom.createElement("span");T.className="ace_invisible ace_invisible_eol",T.textContent=f==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,x.appendChild(T)}},d.prototype.$getFoldLineTokens=function(o,f){var m=this.session,w=[];function x(T,_,C){for(var P=0,O=0;O+T[P].value.length<_;)if(O+=T[P].value.length,P++,P==T.length)return;if(O!=_){var E=T[P].value.substring(_-O);E.length>C-_&&(E=E.substring(0,C-_)),w.push({type:T[P].type,value:E}),O=_+E.length,P+=1}for(;O<C&&P<T.length;){var E=T[P].value;E.length+O>C?w.push({type:T[P].type,value:E.substring(0,C-O)}):w.push(T[P]),O+=E.length,P+=1}}var R=m.getTokens(o);return f.walk(function(T,_,C,P,O){T!=null?w.push({type:"fold",value:T}):(O&&(R=m.getTokens(_)),R.length&&x(R,P,C))},f.end.row,this.session.getLine(f.end.row).length),w},d.prototype.$useLineGroups=function(){return this.session.getUseWrapMode()},d})();u.prototype.EOF_CHAR="¶",u.prototype.EOL_CHAR_LF="¬",u.prototype.EOL_CHAR_CRLF="¤",u.prototype.EOL_CHAR=u.prototype.EOL_CHAR_LF,u.prototype.TAB_CHAR="—",u.prototype.SPACE_CHAR="·",u.prototype.CJK_SPACE_CHAR="・",u.prototype.$padding=0,u.prototype.MAX_LINE_LENGTH=1e4,u.prototype.showInvisibles=!1,u.prototype.showSpaces=!1,u.prototype.showTabs=!1,u.prototype.showEOL=!1,u.prototype.displayIndentGuides=!0,u.prototype.$highlightIndentGuides=!0,u.prototype.$tabStrings=[],u.prototype.destroy={},u.prototype.onChangeTabSize=u.prototype.$computeTabString,h.implement(u.prototype,p),r.Text=u}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(t,r,c){var h=t("../lib/dom"),g=(function(){function v(s){this.element=h.createElement("div"),this.element.className="ace_layer ace_cursor-layer",s.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),h.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)}return v.prototype.$updateOpacity=function(s){for(var p=this.cursors,a=p.length;a--;)h.setStyle(p[a].style,"opacity",s?"":"0")},v.prototype.$startCssAnimation=function(){for(var s=this.cursors,p=s.length;p--;)s[p].style.animationDuration=this.blinkInterval+"ms";this.$isAnimating=!0,setTimeout((function(){this.$isAnimating&&h.addCssClass(this.element,"ace_animate-blinking")}).bind(this))},v.prototype.$stopCssAnimation=function(){this.$isAnimating=!1,h.removeCssClass(this.element,"ace_animate-blinking")},v.prototype.setPadding=function(s){this.$padding=s},v.prototype.setSession=function(s){this.session=s},v.prototype.setBlinking=function(s){s!=this.isBlinking&&(this.isBlinking=s,this.restartTimer())},v.prototype.setBlinkInterval=function(s){s!=this.blinkInterval&&(this.blinkInterval=s,this.restartTimer())},v.prototype.setSmoothBlinking=function(s){s!=this.smoothBlinking&&(this.smoothBlinking=s,h.setCssClass(this.element,"ace_smooth-blinking",s),this.$updateCursors(!0),this.restartTimer())},v.prototype.addCursor=function(){var s=h.createElement("div");return s.className="ace_cursor",this.element.appendChild(s),this.cursors.push(s),s},v.prototype.removeCursor=function(){if(this.cursors.length>1){var s=this.cursors.pop();return s.parentNode.removeChild(s),s}},v.prototype.hideCursor=function(){this.isVisible=!1,h.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},v.prototype.showCursor=function(){this.isVisible=!0,h.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},v.prototype.restartTimer=function(){var s=this.$updateCursors;if(clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&(this.$isSmoothBlinking=!1,h.removeCssClass(this.element,"ace_smooth-blinking")),s(!0),!this.isBlinking||!this.blinkInterval||!this.isVisible){this.$stopCssAnimation();return}if(this.smoothBlinking&&(this.$isSmoothBlinking=!0,setTimeout((function(){this.$isSmoothBlinking&&h.addCssClass(this.element,"ace_smooth-blinking")}).bind(this))),h.HAS_CSS_ANIMATION)this.$startCssAnimation();else{var p=(function(){this.timeoutId=setTimeout(function(){s(!1)},.6*this.blinkInterval)}).bind(this);this.intervalId=setInterval(function(){s(!0),p()},this.blinkInterval),p()}},v.prototype.getPixelPosition=function(s,p){if(!this.config||!this.session)return{left:0,top:0,width:0};s||(s=this.session.selection.getCursor());var a=this.session.documentToScreenPosition(s),l=this.config.fontMetrics.textWidth(a.row,a.column),u=this.$padding+l,d=(a.row-(p?this.config.firstRowScreen:0))*this.config.lineHeight,o=this.config.fontMetrics.textWidth(a.row,a.column+1)-l;return{left:u,top:d,width:Math.abs(o)||this.config.characterWidth}},v.prototype.isCursorInView=function(s,p){return s.top>=0&&s.top<p.maxHeight},v.prototype.update=function(s){this.config=s;var p=this.session.$selectionMarkers,a=0,l=0;(p===void 0||p.length===0)&&(p=[{cursor:null}]);for(var a=0,u=p.length;a<u;a++){var d=this.getPixelPosition(p[a].cursor,!0);if(!((d.top>s.height+s.offset||d.top<0)&&a>1)){var o=this.cursors[l++]||this.addCursor(),f=o.style;this.drawCursor?this.drawCursor(o,d,s,p[a],this.session):this.isCursorInView(d,s)?(h.setStyle(f,"display","block"),h.translate(o,d.left,d.top),h.setStyle(f,"width",Math.round(d.width)+"px"),h.setStyle(f,"height",s.lineHeight+"px")):h.setStyle(f,"display","none")}}for(;this.cursors.length>l;)this.removeCursor();var m=this.session.getOverwrite();this.$setOverwrite(m),this.$pixelPos=d,this.restartTimer()},v.prototype.$setOverwrite=function(s){s!=this.overwrite&&(this.overwrite=s,s?h.addCssClass(this.element,"ace_overwrite-cursors"):h.removeCssClass(this.element,"ace_overwrite-cursors"))},v.prototype.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)},v})();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(t,r,c){var h=this&&this.__extends||(function(){var o=function(f,m){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(w,x){w.__proto__=x}||function(w,x){for(var R in x)Object.prototype.hasOwnProperty.call(x,R)&&(w[R]=x[R])},o(f,m)};return function(f,m){if(typeof m!="function"&&m!==null)throw new TypeError("Class extends value "+String(m)+" is not a constructor or null");o(f,m);function w(){this.constructor=f}f.prototype=m===null?Object.create(m):(w.prototype=m.prototype,new w)}})(),g=t("./lib/oop"),v=t("./lib/dom"),s=t("./lib/event"),p=t("./lib/event_emitter").EventEmitter,a=32768,l=(function(){function o(f,m){this.element=v.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+m,this.element.tabIndex=-1,this.inner=v.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent=" ",this.element.appendChild(this.inner),f.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addListener(this.element,"scroll",this.onScroll.bind(this)),s.addListener(this.element,"mousedown",s.preventDefault)}return o.prototype.setVisible=function(f){this.element.style.display=f?"":"none",this.isVisible=f,this.coeff=1},o})();g.implement(l.prototype,p);var u=(function(o){h(f,o);function f(m,w){var x=o.call(this,m,"-v")||this;return x.scrollTop=0,x.scrollHeight=0,w.$scrollbarWidth=x.width=v.scrollbarWidth(m.ownerDocument),x.inner.style.width=x.element.style.width=(x.width||15)+5+"px",x.$minWidth=0,x}return f.prototype.onScroll=function(){if(!this.skipEvent){if(this.scrollTop=this.element.scrollTop,this.coeff!=1){var m=this.element.clientHeight/this.scrollHeight;this.scrollTop=this.scrollTop*(1-m)/(this.coeff-m)}this._emit("scroll",{data:this.scrollTop})}this.skipEvent=!1},f.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},f.prototype.setHeight=function(m){this.element.style.height=m+"px"},f.prototype.setScrollHeight=function(m){this.scrollHeight=m,m>a?(this.coeff=a/m,m=a):this.coeff!=1&&(this.coeff=1),this.inner.style.height=m+"px"},f.prototype.setScrollTop=function(m){this.scrollTop!=m&&(this.skipEvent=!0,this.scrollTop=m,this.element.scrollTop=m*this.coeff)},f})(l);u.prototype.setInnerHeight=u.prototype.setScrollHeight;var d=(function(o){h(f,o);function f(m,w){var x=o.call(this,m,"-h")||this;return x.scrollLeft=0,x.height=w.$scrollbarWidth,x.inner.style.height=x.element.style.height=(x.height||15)+5+"px",x}return f.prototype.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},f.prototype.getHeight=function(){return this.isVisible?this.height:0},f.prototype.setWidth=function(m){this.element.style.width=m+"px"},f.prototype.setInnerWidth=function(m){this.inner.style.width=m+"px"},f.prototype.setScrollWidth=function(m){this.inner.style.width=m+"px"},f.prototype.setScrollLeft=function(m){this.scrollLeft!=m&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=m)},f})(l);r.ScrollBar=u,r.ScrollBarV=u,r.ScrollBarH=d,r.VScrollBar=u,r.HScrollBar=d}),ace.define("ace/scrollbar_custom",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(t,r,c){var h=this&&this.__extends||(function(){var d=function(o,f){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,w){m.__proto__=w}||function(m,w){for(var x in w)Object.prototype.hasOwnProperty.call(w,x)&&(m[x]=w[x])},d(o,f)};return function(o,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");d(o,f);function m(){this.constructor=o}o.prototype=f===null?Object.create(f):(m.prototype=f.prototype,new m)}})(),g=t("./lib/oop"),v=t("./lib/dom"),s=t("./lib/event"),p=t("./lib/event_emitter").EventEmitter;v.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 d(o,f){this.element=v.createElement("div"),this.element.className="ace_sb"+f,this.inner=v.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,s.addMultiMouseDownListener(this.element,[500,300,300],this,"onMouseDown")}return d.prototype.setVisible=function(o){this.element.style.display=o?"":"none",this.isVisible=o,this.coeff=1},d})();g.implement(a.prototype,p);var l=(function(d){h(o,d);function o(f,m){var w=d.call(this,f,"-v")||this;return w.scrollTop=0,w.scrollHeight=0,w.parent=f,w.width=w.VScrollWidth,w.renderer=m,w.inner.style.width=w.element.style.width=(w.width||15)+"px",w.$minWidth=0,w}return o.prototype.onMouseDown=function(f,m){if(f==="mousedown"&&!(s.getButton(m)!==0||m.detail===2)){if(m.target===this.inner){var w=this,x=m.clientY,R=function(k){x=k.clientY},T=function(){clearInterval(O)},_=m.clientY,C=this.thumbTop,P=function(){if(x!==void 0){var k=w.scrollTopFromThumbTop(C+x-_);k!==w.scrollTop&&w._emit("scroll",{data:k})}};s.capture(this.inner,R,T);var O=setInterval(P,20);return s.preventDefault(m)}var E=m.clientY-this.element.getBoundingClientRect().top-this.thumbHeight/2;return this._emit("scroll",{data:this.scrollTopFromThumbTop(E)}),s.preventDefault(m)}},o.prototype.getHeight=function(){return this.height},o.prototype.scrollTopFromThumbTop=function(f){var m=f*(this.pageHeight-this.viewHeight)/(this.slideHeight-this.thumbHeight);return m=m>>0,m<0?m=0:m>this.pageHeight-this.viewHeight&&(m=this.pageHeight-this.viewHeight),m},o.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},o.prototype.setHeight=function(f){this.height=Math.max(0,f),this.slideHeight=this.height,this.viewHeight=this.height,this.setScrollHeight(this.pageHeight,!0)},o.prototype.setScrollHeight=function(f,m){this.pageHeight===f&&!m||(this.pageHeight=f,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(f){this.scrollTop=f,f<0&&(f=0),this.thumbTop=f*(this.slideHeight-this.thumbHeight)/(this.pageHeight-this.viewHeight),this.inner.style.top=this.thumbTop+"px"},o})(a);l.prototype.setInnerHeight=l.prototype.setScrollHeight;var u=(function(d){h(o,d);function o(f,m){var w=d.call(this,f,"-h")||this;return w.scrollLeft=0,w.scrollWidth=0,w.height=w.HScrollHeight,w.inner.style.height=w.element.style.height=(w.height||12)+"px",w.renderer=m,w}return o.prototype.onMouseDown=function(f,m){if(f==="mousedown"&&!(s.getButton(m)!==0||m.detail===2)){if(m.target===this.inner){var w=this,x=m.clientX,R=function(k){x=k.clientX},T=function(){clearInterval(O)},_=m.clientX,C=this.thumbLeft,P=function(){if(x!==void 0){var k=w.scrollLeftFromThumbLeft(C+x-_);k!==w.scrollLeft&&w._emit("scroll",{data:k})}};s.capture(this.inner,R,T);var O=setInterval(P,20);return s.preventDefault(m)}var E=m.clientX-this.element.getBoundingClientRect().left-this.thumbWidth/2;return this._emit("scroll",{data:this.scrollLeftFromThumbLeft(E)}),s.preventDefault(m)}},o.prototype.getHeight=function(){return this.isVisible?this.height:0},o.prototype.scrollLeftFromThumbLeft=function(f){var m=f*(this.pageWidth-this.viewWidth)/(this.slideWidth-this.thumbWidth);return m=m>>0,m<0?m=0:m>this.pageWidth-this.viewWidth&&(m=this.pageWidth-this.viewWidth),m},o.prototype.setWidth=function(f){this.width=Math.max(0,f),this.element.style.width=this.width+"px",this.slideWidth=this.width,this.viewWidth=this.width,this.setScrollWidth(this.pageWidth,!0)},o.prototype.setScrollWidth=function(f,m){this.pageWidth===f&&!m||(this.pageWidth=f,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(f){this.scrollLeft=f,f<0&&(f=0),this.thumbLeft=f*(this.slideWidth-this.thumbWidth)/(this.pageWidth-this.viewWidth),this.inner.style.left=this.thumbLeft+"px"},o})(a);u.prototype.setInnerWidth=u.prototype.setScrollWidth,r.ScrollBar=l,r.ScrollBarV=l,r.ScrollBarH=u,r.VScrollBar=l,r.HScrollBar=u}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(t,r,c){var h=t("./lib/event"),g=(function(){function v(s,p){this.onRender=s,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=p||window;var a=this;this._flush=function(l){a.pending=!1;var u=a.changes;if(u&&(h.blockIdle(100),a.changes=0,a.onRender(u)),a.changes){if(a.$recursionLimit--<0)return;a.schedule()}else a.$recursionLimit=2}}return v.prototype.schedule=function(s){this.changes=this.changes|s,this.changes&&!this.pending&&(h.nextFrame(this._flush),this.pending=!0)},v.prototype.clear=function(s){var p=this.changes;return this.changes=0,p},v})();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/event_emitter"],function(t,r,c){var h=this&&this.__read||function(O,E){var k=typeof Symbol=="function"&&O[Symbol.iterator];if(!k)return O;var B=k.call(O),N,M=[],$;try{for(;(E===void 0||E-- >0)&&!(N=B.next()).done;)M.push(N.value)}catch(A){$={error:A}}finally{try{N&&!N.done&&(k=B.return)&&k.call(B)}finally{if($)throw $.error}}return M},g=t("../lib/oop"),v=t("../lib/dom"),s=t("../lib/lang"),p=t("../lib/event"),a=t("../lib/event_emitter").EventEmitter,l=512,u=typeof ResizeObserver=="function",d=200,o=(function(){function O(E,k,B){this.config={characterWidth:1},this.$characterSize={width:0,height:0},this.textLayer=k,this.renderer=B,this.el=v.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=v.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=v.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),E.appendChild(this.el),this.$measureNode.textContent=s.stringRepeat("X",l),u?this.$addObserver():this.checkForSizeChanges(),this.textLayer.$setFontMetrics(this),this.$scratchRange=document.createRange()}return O.prototype.$setMeasureNodeStyles=function(E,k){E.width=E.height="auto",E.left=E.top="0px",E.visibility="hidden",E.position="absolute",E.whiteSpace="pre",E.font="inherit",E.overflow=k?"hidden":"visible"},O.prototype.checkForSizeChanges=function(E){if(E===void 0&&(E=this.$measureSizes()),E&&(this.$characterSize.width!==E.width||this.$characterSize.height!==E.height)){this.$measureNode.style.fontWeight="bold";var k=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=E,this.charSizes=Object.create(null),this.allowBoldFonts=k&&k.width===E.width&&k.height===E.height,this._emit("changeCharacterSize",{data:E})}},O.prototype.$addObserver=function(){var E=this;this.$observer=new window.ResizeObserver(function(k){E.checkForSizeChanges()}),this.$observer.observe(this.$measureNode)},O.prototype.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer||this.$observer)return this.$pollSizeChangesTimer;var E=this;return this.$pollSizeChangesTimer=p.onIdle(function k(){E.checkForSizeChanges(),p.onIdle(k,500)},500)},O.prototype.setPolling=function(E){E?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},O.prototype.$measureSizes=function(E){var k={height:(E||this.$measureNode).clientHeight,width:(E||this.$measureNode).clientWidth/l};return k.width===0||k.height===0?null:k},O.prototype.$measureCharWidth=function(E){this.$main.textContent=s.stringRepeat(E,l);var k=this.$main.getBoundingClientRect();return k.width/l},O.prototype.getCharacterWidth=function(E){var k=this.charSizes[E];return k===void 0&&(k=this.charSizes[E]=this.$measureCharWidth(E)/this.$characterSize.width),k},O.prototype.getTextWidth=function(E){return E?(this.$main.textContent=E,this.$main.clientWidth):0},O.prototype.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},O.prototype.$initTransformMeasureNodes=function(){var E=function(k,B){return["div",{style:"position: absolute;left:"+k+"px;top:"+B+"px;"}]};this.els=v.buildDom([E(0,0),E(d,0),E(0,d),E(d,d)],this.el)},O.prototype.getTransform=function(){if(this.config.$transformData)return this.config.$transformData;this.els||this.$initTransformMeasureNodes();function E(Q){var re=Q.getBoundingClientRect();return[re.left,re.top]}var k=E(this.els[0]),B=E(this.els[1]),N=E(this.els[2]),M=E(this.els[3]),$=m(w(M,B),w(M,N),w(x(B,N),x(M,k))),A=R((1+$[0])/d,w(B,k)),D=R((1+$[1])/d,w(N,k)),j=[A[0],D[0],0,A[1],D[1],0,$[0]/d,$[1]/d,1],U=1/(j[0]*j[4]-j[3]*j[1]),q=[j[4]*U,-j[1]*U,0,-j[3]*U,j[0]*U,0,(j[3]*j[7]-j[4]*j[6])*U,(j[1]*j[6]-j[0]*j[7])*U,1];return this.config.$transformData={M:j,MInv:q,t:k},this.config.$transformData},O.prototype.transformCoordinates=function(E,k){this.config.$transformData||this.getTransform();var B=this.config.$transformData;return k?x(_(B.M,k[0],k[1]),B.t):_(B.MInv,E[0]-B.t[0],E[1]-B.t[1])},O.prototype.recoverRect=function(E,k){var B=E.M,N=Math.abs(B[6])<1e-10&&Math.abs(B[7])<1e-10,M=k.left,$=k.top,A=k.width,D=k.height;if(M-=E.t[0],$-=E.t[1],N){var j=h(B,6),U=j[0],q=j[1],Q=j[2],re=j[3],le=j[4],ne=j[5],ue=[Math.abs(U),Math.abs(q),Math.abs(re),Math.abs(le)],he=ue[0]*ue[3]-ue[2]*ue[1],oe=void 0,ee=void 0;Math.abs(he)<1e-10?(ee=this.config&&this.config.lineHeight||0,oe=(A-ue[1]*ee)/ue[0]):(oe=(ue[3]*A-ue[1]*D)/he,ee=(-ue[2]*A+ue[0]*D)/he);var ye=U*le-q*re,we=M+A/2-Q,Ae=$+D/2-ne,Je=(le*we-q*Ae)/ye,ze=(-re*we+U*Ae)/ye;return{left:Je-oe/2,top:ze-ee/2,width:oe,height:ee,right:Je+oe/2,bottom:ze+ee/2}}return T(E,k)},O.prototype.$findElementForScreenRow=function(E){var k=this.textLayer;if(!this.config)return null;var B=k.$lines.$getCellByScreenRow(E,this.config),N=B&&B.cell.element;if(N&&k.$useLineGroups()){var M=Math.floor(B.offset/this.config.lineHeight);N=N.children[Math.max(M,0)]}return N},O.prototype.textWidth=function(E,k){var B=this.$findElementForScreenRow(E);return!B||!document.createRange?k*this.config.characterWidth:this.$measureLineToColumn(B,k)},O.prototype.$measureLineToColumn=function(E,k){var B=this.textLayer;try{var N=this.$findColumnPosition(E,k);if(!N)return k*this.config.characterWidth;this.$scratchRange.setStart(N.node,N.offset),this.$scratchRange.setEnd(N.node,N.offset);var M=this.$scratchRange.getBoundingClientRect();if(this.renderer.$hasCssTransforms){var $=this.getTransform(),A=this.recoverRect($,M),D=this.renderer.gutterWidth+this.renderer.margin.left+this.renderer.$padding-this.renderer.scrollLeft;return A.left-D+N.overflow*this.config.characterWidth}var j=B.element.getBoundingClientRect();return M.left-j.left+N.overflow*this.config.characterWidth}catch(U){return console.error("Error measuring text width:",U),k*this.config.characterWidth}},O.prototype.$findColumnPosition=function(E,k){for(var B=document.createTreeWalker(E,NodeFilter.SHOW_TEXT,null),N=0,M,$;M=B.nextNode();){var A=M.nodeValue,D=A.length;if(N+D>=k)return{node:M,offset:k-N,overflow:0};N+=D,$=M}return $&&{node:$,offset:$.nodeValue.length,overflow:k-N}},O.prototype.$pixelToColumn=function(E,k,B,N,M){var $=this,A=this.$scratchRange,D=this.$findElementForScreenRow(E);if(!D||k<0)return k;var j=this.renderer.$hasCssTransforms,U=j&&this.getTransform();M&&(j?B+=this.renderer.gutterWidth+this.renderer.margin.left+this.renderer.$padding-this.renderer.scrollLeft:B+=this.textLayer.element.getBoundingClientRect().left);var q=0,Q=function(ne){var ue=[];if(ne.nodeType===Node.TEXT_NODE?(A.setStart(ne,0),A.setEnd(ne,ne.nodeValue.length),ue=Array.from(A.getClientRects())):ne.nodeType===Node.ELEMENT_NODE&&(ue=Array.from(ne.getClientRects())),j){for(var he=[],oe=0;oe<ue.length;oe++){var ee=ue[oe];he.push($.recoverRect(U,ee))}ue=he}return ue},re=this;function le(ne){if(ne.nodeType===Node.TEXT_NODE){for(var ue=ne.nodeValue.length,he=Number.MAX_VALUE,oe=-1,ee=void 0,ye=ne.nodeValue,we=0;we<=ue;we++)if(A.setStart(ne,we),A.setEnd(ne,we),!(we>0&&we<ue&&/[\uDC00-\uDFFF]/.test(ye.charAt(we))&&/[\uD800-\uDBFF]/.test(ye.charAt(we-1)))){var Ae=A.getBoundingClientRect();j&&(Ae=re.recoverRect(U,Ae));var Je=B-Ae.left,ze=Math.abs(Je);ze<he&&(oe=we,he=ze,ee=Je)}return N&&ee<0&&(oe=Math.max(0,oe-1)),q=q+oe}else if(ne.nodeType===Node.ELEMENT_NODE)for(var Ye=ne.childNodes,Ze=0;Ze<Ye.length;Ze++){for(var at=Ye[Ze],ct=Q(at),we=0;we<ct.length;we++){var Ae=ct[we];if(Ae.left<=B&&B<=Ae.left+Ae.width)return le(at),q}q+=at.nodeType===Node.TEXT_NODE?at.nodeValue.length:at.textContent.length}}return le(D),q},O.prototype.getRects=function(E,k){var B=E.row,N=this.textLayer,M=this.$findElementForScreenRow(B);if(M)try{var $=this.$findColumnPosition(M,E.column),A=this.$findColumnPosition(M,k.column);if($&&A){this.$scratchRange.setStart($.node,$.offset),this.$scratchRange.setEnd(A.node,A.offset);var D=this.$scratchRange.getClientRects(),j=this.renderer&&this.renderer.$hasCssTransforms;if(j){for(var U=this.getTransform(),q=[],Q=0;Q<D.length;Q++){var re=this.recoverRect(U,D[Q]);re.right=re.left+re.width,q.push(re)}var le=this.renderer.gutterWidth+this.renderer.margin.left+this.renderer.$padding-this.renderer.scrollLeft,ue=f(q).map(function(oe){return{left:oe.left-le,width:oe.right-oe.left}});return ue}var ne=N.element.getBoundingClientRect(),ue=f(D).map(function(he){return{left:he.left-ne.left,width:he.right-he.left}});return ue}}catch(he){console.error("Error measuring text width:",he)}return[{left:E.column*this.config.characterWidth,width:(k.column-E.column)*this.config.characterWidth}]},O})();function f(O){for(var E=[],k=0;k<O.length;k++){for(var B=O[k],N=!1,M=0;M<E.length;M++){var $=E[M];if($.left<=B.left&&B.left<=$.right||$.left<=B.right&&B.right<=$.right||B.left<=$.left&&$.right<=B.right){$.left=Math.min($.left,B.left),$.right=Math.max($.right,B.right),N=!0;break}}N||E.push({left:B.left,right:B.right,top:B.top,height:B.height})}return E}function m(O,E,k){var B=O[1]*E[0]-O[0]*E[1];return[(-E[1]*k[0]+E[0]*k[1])/B,(+O[1]*k[0]-O[0]*k[1])/B]}function w(O,E){return[O[0]-E[0],O[1]-E[1]]}function x(O,E){return[O[0]+E[0],O[1]+E[1]]}function R(O,E){return[O*E[0],O*E[1]]}g.implement(o.prototype,a),r.FontMetrics=o;function T(O,E){var k=E.left,B=E.top,N=E.width,M=E.height,$=O.M;k-=O.t[0],B-=O.t[1],E={left:k,top:B,width:N,height:M};for(var A=[B,k+N,B+M,k],D=[!0,!1,!0,!1],j=[[0,0],[1,0],[1,1],[0,1]],U=null,q=[27,57,23,53,43,9,10,11,14,37,31,56,40,41,47],Q=-q.length;Q<256;Q++){var re=Q<0?q[q.length+Q]:Q,le=[re>>0&3,re>>2&3,re>>4&3,re>>6&3],ne=le.map(function(ze){return j[ze]}),ue=ne.map(function(ze,Ye){var Ze=h(ze,2),at=Ze[0],ct=Ze[1],Ft=A[Ye],Ie=D[Ye]?$.slice(3,6):$.slice(0,3),Ct=$.slice(6,9),St=Ie[0]-Ft*Ct[0],Vt=Ie[1]-Ft*Ct[1];return[St,Vt,at*St,ct*Vt,Ft*Ct[2]-Ie[2]]}),he=P(ue),U;if(he){var oe=h(he,4),ee=oe[0],ye=oe[1],we=oe[2],Ae=oe[3];if(we<0&&(ee+=we,we=-we),Ae<0&&(ye+=Ae,Ae=-Ae),C($,ee,ye,we,Ae,E)){U={left:ee,top:ye,width:we,height:Ae,right:ee+we,bottom:ye+Ae,mappingIdx:Q};break}}}return U||console.warn("No valid mapping found in 256 combinations."),U}var _=function(O,E,k){var B=O[6]*E+O[7]*k+O[8];return[(O[0]*E+O[1]*k+O[2])/B,(O[3]*E+O[4]*k+O[5])/B]};function C(O,E,k,B,N,M){var $=[[E,k],[E+B,k],[E+B,k+N],[E,k+N]];return $.every(function(A){var D=_(O,A[0],A[1]);return M.left-.5<=D[0]&&D[0]<=M.left+M.width+.5&&M.top-.5<=D[1]&&D[1]<=M.top+M.height+.5})}function P(O){for(var E,k=4,B=0;B<k;B++){for(var N=B,M=B+1;M<k;M++)Math.abs(O[M][B])>Math.abs(O[N][B])&&(N=M);E=h([O[N],O[B]],2),O[B]=E[0],O[N]=E[1];var $=O[B][B];if(Math.abs($)<1e-10)return null;for(var M=B;M<=k;M++)O[B][M]/=$;for(var A=0;A<k;A++)if(A!==B)for(var D=O[A][B],M=B;M<=k;M++)O[A][M]-=D*O[B][M]}return O.map(function(j){return j[k]})}}),ace.define("ace/css/editor-css",["require","exports","module"],function(t,r,c){c.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(t,r,c){var h=t("../lib/dom"),g=t("../lib/oop"),v=t("../lib/event_emitter").EventEmitter,s=(function(){function p(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 p.prototype.$createCanvas=function(){this.canvas=h.createElement("canvas"),this.canvas.style.top="0px",this.canvas.style.right="0px",this.canvas.style.zIndex="7",this.canvas.style.position="absolute"},p.prototype.setScrollBarV=function(a){this.$createCanvas(),this.scrollbarV=a,a.element.appendChild(this.canvas),this.setDimensions()},p.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 u=this.canvas.getContext("2d");function d(M,$){return M.priority<$.priority?-1:M.priority>$.priority?1:0}var o=this.renderer.session.$annotations;if(u.clearRect(0,0,this.canvas.width,this.canvas.height),o){var f={info:1,warning:2,error:3};o.forEach(function(M){M.priority=f[M.type]||null}),o=o.sort(d);for(var m=0;m<o.length;m++){var w=o[m].row,x=this.getVerticalOffsetForRow(w),R=x+this.lineHeight,T=Math.round(this.heightRatio*x),_=Math.round(this.heightRatio*R),C=Math.round((T+_)/2),P=_-C;P<this.halfMinDecorationHeight&&(P=this.halfMinDecorationHeight),C-P<0&&(C=P),C+P>this.canvasHeight&&(C=this.canvasHeight-P);var O=C-P,E=C+P,k=E-O;u.fillStyle=l[o[m].type]||null,u.fillRect(0,O,Math.round(this.oneZoneWidth-1),k)}}var B=this.renderer.session.selection.getCursor();if(B){var N=Math.round(this.getVerticalOffsetForRow(B.row)*this.heightRatio);u.fillStyle="rgba(0, 0, 0, 0.5)",u.fillRect(0,N,this.canvasWidth,2)}},p.prototype.getVerticalOffsetForRow=function(a){a=a|0;var l=this.renderer.session.documentToScreenRow(a,0)*this.lineHeight;return l},p.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},p.prototype.setZoneWidth=function(){this.oneZoneWidth=this.canvasWidth},p.prototype.destroy=function(){this.canvas.parentNode.removeChild(this.canvas)},p})();g.implement(s.prototype,v),r.Decorator=s}),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/config","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/scrollbar_custom","ace/scrollbar_custom","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter","ace/css/editor-css","ace/layer/decorators","ace/lib/useragent","ace/layer/text_util"],function(t,r,c){var h=t("./lib/oop"),g=t("./lib/dom"),v=t("./lib/lang"),s=t("./config"),p=t("./layer/gutter").Gutter,a=t("./layer/marker").Marker,l=t("./layer/text").Text,u=t("./layer/cursor").Cursor,d=t("./scrollbar").HScrollBar,o=t("./scrollbar").VScrollBar,f=t("./scrollbar_custom").HScrollBar,m=t("./scrollbar_custom").VScrollBar,w=t("./renderloop").RenderLoop,x=t("./layer/font_metrics").FontMetrics,R=t("./lib/event_emitter").EventEmitter,T=t("./css/editor-css"),_=t("./layer/decorators").Decorator,C=t("./lib/useragent"),P=t("./layer/text_util").isTextToken;g.importCssString(T,"ace_editor.css",!1);var O=(function(){function E(k,B){var N=this;this.container=k||g.createElement("div"),g.addCssClass(this.container,"ace_editor"),g.HI_DPI&&g.addCssClass(this.container,"ace_hidpi"),this.setTheme(B),s.get("useStrictCSP")==null&&s.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 p(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new a(this.content);var M=this.$textLayer=new l(this.content);this.canvas=M.element,this.$markerFront=new a(this.content),this.$cursorLayer=new u(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new o(this.container,this),this.scrollBarH=new d(this.container,this),this.scrollBarV.on("scroll",function($){N.$scrollAnimation||N.session.setScrollTop($.data-N.scrollMargin.top)}),this.scrollBarH.on("scroll",function($){N.$scrollAnimation||N.session.setScrollLeft($.data-N.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new x(this.container,this.$textLayer,this),this.$textLayer.on("changeCharacterSize",function($){N.updateCharacterSize(),N.onResize(!0,N.gutterWidth,N.$size.width,N.$size.height),N._signal("changeCharacterSize",$)}),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,fontMetrics:this.$fontMetrics,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1},this.$fontMetrics.config=this.layerConfig,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 w(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),this.$addResizeObserver(),s.resetOptions(this),s._signal("renderer",this)}return E.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")},E.prototype.setSession=function(k){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=k,k&&this.scrollMargin.top&&k.getScrollTop()<=0&&k.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(k),this.$markerBack.setSession(k),this.$markerFront.setSession(k),this.$gutterLayer.setSession(k),this.$textLayer.setSession(k),k&&(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))},E.prototype.updateLines=function(k,B,N){if(B===void 0&&(B=1/0),this.$changedLines?(this.$changedLines.firstRow>k&&(this.$changedLines.firstRow=k),this.$changedLines.lastRow<B&&(this.$changedLines.lastRow=B)):this.$changedLines={firstRow:k,lastRow:B},this.$changedLines.lastRow<this.layerConfig.firstRow)if(N)this.$changedLines.lastRow=this.layerConfig.lastRow;else return;this.$changedLines.firstRow>this.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)},E.prototype.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},E.prototype.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},E.prototype.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},E.prototype.updateFull=function(k){k?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},E.prototype.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},E.prototype.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},E.prototype.onResize=function(k,B,N,M){if(!(this.resizing>2)){this.resizing>0?this.resizing++:this.resizing=k?1:0;var $=this.container;M||(M=$.clientHeight||$.scrollHeight),!M&&this.$maxLines&&this.lineHeight>1&&(!$.style.height||$.style.height=="0px")&&($.style.height="1px",M=$.clientHeight||$.scrollHeight),N||(N=$.clientWidth||$.scrollWidth);var A=this.$updateCachedSize(k,B,N,M);if(this.$resizeTimer&&this.$resizeTimer.cancel(),!this.$size.scrollerHeight||!N&&!M)return this.resizing=0;k&&(this.$gutterLayer.$padding=null),k?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)}},E.prototype.$updateCachedSize=function(k,B,N,M){M-=this.$extraHeight||0;var $=0,A=this.$size,D={width:A.width,height:A.height,scrollerHeight:A.scrollerHeight,scrollerWidth:A.scrollerWidth};if(M&&(k||A.height!=M)&&(A.height=M,$|=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",$=$|this.CHANGE_SCROLL),N&&(k||A.width!=N)){$|=this.CHANGE_SIZE,A.width=N,B==null&&(B=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=B,g.setStyle(this.scrollBarH.element.style,"left",B+"px"),g.setStyle(this.scroller.style,"left",B+this.margin.left+"px"),A.scrollerWidth=Math.max(0,N-B-this.scrollBarV.getWidth()-this.margin.h),g.setStyle(this.$gutter.style,"left",this.margin.left+"px");var j=this.scrollBarV.getWidth()+"px";g.setStyle(this.scrollBarH.element.style,"right",j),g.setStyle(this.scroller.style,"right",j),g.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight()),this.scrollBarH.setWidth(A.scrollerWidth),(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||k)&&($|=this.CHANGE_FULL)}return A.$dirty=!N||!M,$&&this._signal("resize",D),$},E.prototype.onGutterResize=function(k){var B=this.$showGutter?k:0;B!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,B,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()},E.prototype.adjustWrapLimit=function(){var k=this.$size.scrollerWidth-this.$padding*2,B=Math.floor(k/this.characterWidth);return this.session.adjustWrapLimit(B,this.$showPrintMargin&&this.$printMarginColumn)},E.prototype.setAnimatedScroll=function(k){this.setOption("animatedScroll",k)},E.prototype.getAnimatedScroll=function(){return this.$animatedScroll},E.prototype.setShowInvisibles=function(k){this.setOption("showInvisibles",k),this.session.$bidiHandler.setShowInvisibles(k)},E.prototype.getShowInvisibles=function(){return this.getOption("showInvisibles")},E.prototype.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},E.prototype.setDisplayIndentGuides=function(k){this.setOption("displayIndentGuides",k)},E.prototype.getHighlightIndentGuides=function(){return this.getOption("highlightIndentGuides")},E.prototype.setHighlightIndentGuides=function(k){this.setOption("highlightIndentGuides",k)},E.prototype.setShowPrintMargin=function(k){this.setOption("showPrintMargin",k)},E.prototype.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},E.prototype.setPrintMarginColumn=function(k){this.setOption("printMarginColumn",k)},E.prototype.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},E.prototype.getShowGutter=function(){return this.getOption("showGutter")},E.prototype.setShowGutter=function(k){return this.setOption("showGutter",k)},E.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},E.prototype.setFadeFoldWidgets=function(k){this.setOption("fadeFoldWidgets",k)},E.prototype.setHighlightGutterLine=function(k){this.setOption("highlightGutterLine",k)},E.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},E.prototype.$updatePrintMargin=function(){if(!(!this.$showPrintMargin&&!this.$printMarginEl)){if(!this.$printMarginEl){var k=g.createElement("div");k.className="ace_layer ace_print-margin-layer",this.$printMarginEl=g.createElement("div"),this.$printMarginEl.className="ace_print-margin",k.appendChild(this.$printMarginEl),this.content.insertBefore(k,this.content.firstChild)}var B=this.$printMarginEl.style;B.left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",B.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&this.session.$wrap==-1&&this.adjustWrapLimit()}},E.prototype.getContainerElement=function(){return this.container},E.prototype.getMouseEventTarget=function(){return this.scroller},E.prototype.getTextAreaContainer=function(){return this.container},E.prototype.$moveTextAreaToCursor=function(){if(!this.$isMousePressed){var k=this.textarea.style,B=this.$composition;if(!this.$keepTextAreaAtCursor&&!B){g.translate(this.textarea,-100,0);return}var N=this.$cursorLayer.$pixelPos;if(N){B&&B.markerRange&&(N=this.$cursorLayer.getPixelPosition(B.markerRange.start,!0));var M=this.layerConfig,$=N.top,A=N.left;$-=M.offset;var D=B&&B.useTextareaForIME||C.isMobile?this.lineHeight:1;if($<0||$>M.height-D){g.translate(this.textarea,0,0);return}var j=1,U=this.$size.height-D;if(!B)$+=this.lineHeight;else if(B.useTextareaForIME){var q=this.textarea.value;j=this.$fontMetrics.getTextWidth(q)+1}else $+=this.lineHeight+2;A-=this.scrollLeft,A>this.$size.scrollerWidth-j&&(A=this.$size.scrollerWidth-j),A+=this.gutterWidth+this.margin.left,g.setStyle(k,"height",D+"px"),g.setStyle(k,"width",j+"px"),g.translate(this.textarea,Math.min(A,this.$size.scrollerWidth-j),Math.min($,U))}}},E.prototype.getFirstVisibleRow=function(){return this.layerConfig.firstRow},E.prototype.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(this.layerConfig.offset===0?0:1)},E.prototype.getLastFullyVisibleRow=function(){var k=this.layerConfig,B=k.lastRow,N=this.session.documentToScreenRow(B,0)*k.lineHeight;return N-this.session.getScrollTop()>k.height-k.lineHeight?B-1:B},E.prototype.getLastVisibleRow=function(){return this.layerConfig.lastRow},E.prototype.setPadding=function(k){this.$padding=k,this.$textLayer.setPadding(k),this.$cursorLayer.setPadding(k),this.$markerFront.setPadding(k),this.$markerBack.setPadding(k),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},E.prototype.setScrollMargin=function(k,B,N,M){var $=this.scrollMargin;$.top=k|0,$.bottom=B|0,$.right=M|0,$.left=N|0,$.v=$.top+$.bottom,$.h=$.left+$.right,$.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-$.top),this.updateFull()},E.prototype.setMargin=function(k,B,N,M){var $=this.margin;$.top=k|0,$.bottom=B|0,$.right=M|0,$.left=N|0,$.v=$.top+$.bottom,$.h=$.left+$.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},E.prototype.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},E.prototype.setHScrollBarAlwaysVisible=function(k){this.setOption("hScrollBarAlwaysVisible",k)},E.prototype.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},E.prototype.setVScrollBarAlwaysVisible=function(k){this.setOption("vScrollBarAlwaysVisible",k)},E.prototype.$updateScrollBarV=function(){var k=this.layerConfig.maxHeight,B=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(k-=(B-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>k-B&&(k=this.scrollTop+B,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(k+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},E.prototype.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},E.prototype.freeze=function(){this.$frozen=!0},E.prototype.unfreeze=function(){this.$frozen=!1},E.prototype.$renderChanges=function(k,B){if(this.$changes&&(k|=this.$changes,this.$changes=0),!this.session||!this.container.offsetWidth||this.$frozen||!k&&!B){this.$changes|=k;return}if(this.$size.$dirty)return this.$changes|=k,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",k);var N=this.layerConfig;if(k&this.CHANGE_FULL||k&this.CHANGE_SIZE||k&this.CHANGE_TEXT||k&this.CHANGE_LINES||k&this.CHANGE_SCROLL||k&this.CHANGE_H_SCROLL){if(k|=this.$computeLayerConfig()|this.$loop.clear(),N.firstRow!=this.layerConfig.firstRow&&N.firstRowScreen==this.layerConfig.firstRowScreen){var M=this.scrollTop+(N.firstRow-Math.max(this.layerConfig.firstRow,0))*this.lineHeight;M>0&&(this.scrollTop=M,k=k|this.CHANGE_SCROLL,k|=this.$computeLayerConfig()|this.$loop.clear())}N=this.layerConfig}if(k&this.CHANGE_H_SCROLL&&(this.$updateContentTransformAndSize(N,k),this.scroller.className=this.scrollLeft<=0?"ace_scroller ":"ace_scroller ace_scroll-left ",this.enableKeyboardAccessibility&&(this.scroller.className+=this.keyboardFocusClassName)),k&this.CHANGE_FULL){this.$changedLines=null,this.$textLayer.update(N),this.$showGutter&&this.$gutterLayer.update(N),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(N),this.$markerBack.update(N),this.$markerFront.update(N),this.$cursorLayer.update(N),this.$updateContentTransformAndSize(N,k),this.$moveTextAreaToCursor(),this._signal("afterRender",k);return}if(k&this.CHANGE_SCROLL){this.$changedLines=null,k&this.CHANGE_TEXT||k&this.CHANGE_LINES?this.$textLayer.update(N):this.$textLayer.scrollLines(N),this.$showGutter&&(k&this.CHANGE_GUTTER||k&this.CHANGE_LINES?this.$gutterLayer.update(N):this.$gutterLayer.scrollLines(N)),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(N),this.$markerBack.update(N),this.$markerFront.update(N),this.$cursorLayer.update(N),this.$updateContentTransformAndSize(N,k),this.$moveTextAreaToCursor(),this._signal("afterRender",k);return}k&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(N),this.$showGutter&&this.$gutterLayer.update(N),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(N),this.$updateContentTransformAndSize(N,k)):k&this.CHANGE_LINES?((this.$updateLines()||k&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(N),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(N),this.$updateContentTransformAndSize(N,k)):k&this.CHANGE_TEXT||k&this.CHANGE_GUTTER?(this.$showGutter&&this.$gutterLayer.update(N),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(N)):k&this.CHANGE_CURSOR&&(this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(N),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(N)),k&this.CHANGE_CURSOR&&(this.$cursorLayer.update(N),this.$moveTextAreaToCursor()),k&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(N),k&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(N),this._signal("afterRender",k)},E.prototype.$autosize=function(){var k=this.session.getScreenLength()*this.lineHeight,B=this.$maxLines*this.lineHeight,N=Math.min(B,Math.max((this.$minLines||1)*this.lineHeight,k))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(N+=this.scrollBarH.getHeight()),this.$maxPixelHeight&&N>this.$maxPixelHeight&&(N=this.$maxPixelHeight);var M=N<=2*this.lineHeight,$=!M&&k>B;if(N!=this.desiredHeight||this.$size.height!=this.desiredHeight||$!=this.$vScroll){$!=this.$vScroll&&(this.$vScroll=$,this.scrollBarV.setVisible($));var A=this.container.clientWidth;this.container.style.height=N+"px",this.$updateCachedSize(!0,this.$gutterWidth,A,N),this.desiredHeight=N,this._signal("autosize")}},E.prototype.$updateContentTransformAndSize=function(k,B){var N=this.scrollMargin;if(this.session&&!this.session.getUseWrapMode()){var M=this.$getLongestRenderedLine();k.width<M&&(k.width=M)}this.session&&this.session.setScrollLeft(Math.max(-N.left,Math.min(this.scrollLeft,k.width+2*this.$padding-this.$size.scrollerWidth+N.right))),g.translate(this.content,-this.scrollLeft,-k.offset);var $=k.width+2*this.$padding+"px",A=k.minHeight+"px";g.setStyle(this.content.style,"width",$),g.setStyle(this.content.style,"height",A),this.$updateScrollBarV(),B&this.CHANGE_H_SCROLL&&this.$updateScrollBarH()},E.prototype.$getLongestRenderedLine=function(){for(var k=0,B=this.$hasCssTransforms&&this.$fontMetrics.getTransform(),N=this.$textLayer.$lines.cells,M=0;M<N.length;M++){var $=N[M].element;this.$fontMetrics.$scratchRange.setStart($,0),this.$fontMetrics.$scratchRange.setEnd($,$.childNodes.length);var A=this.$fontMetrics.$scratchRange.getBoundingClientRect();this.$hasCssTransforms&&(A=this.$fontMetrics.recoverRect(B,A)||A);var D=A.width;D>k&&(k=D)}return k},E.prototype.$computeLayerConfig=function(){var k=this.session,B=this.$size,N=B.height<=2*this.lineHeight,M=this.session.getScreenLength(),$=M*this.lineHeight,A=this.$getLongestLine(),D=!N&&(this.$hScrollBarAlwaysVisible||B.scrollerWidth-A-2*this.$padding<0),j=this.$horizScroll!==D;j&&(this.$horizScroll=D,this.scrollBarH.setVisible(D));var U=this.$vScroll;this.$maxLines&&this.lineHeight>1&&(this.$autosize(),N=B.height<=2*this.lineHeight);var q=B.scrollerHeight+this.lineHeight,Q=!this.$maxLines&&this.$scrollPastEnd?(B.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;$+=Q;var re=this.scrollMargin;this.session.setScrollTop(Math.max(-re.top,Math.min(this.scrollTop,$-B.scrollerHeight+re.bottom)));var le=!N&&(this.$vScrollBarAlwaysVisible||B.scrollerHeight-$+Q<0||this.scrollTop>re.top),ne=U!==le;ne&&(this.$vScroll=le,this.scrollBarV.setVisible(le));var ue=this.scrollTop%this.lineHeight,he=Math.ceil(q/this.lineHeight)-1,oe=Math.max(0,Math.round((this.scrollTop-ue)/this.lineHeight)),ee=oe+he,ye,we,Ae=this.lineHeight;oe=k.screenToDocumentRow(oe,0);var Je=k.getFoldLine(oe);Je&&(oe=Je.start.row),ye=k.documentToScreenRow(oe,0),we=k.getRowLength(oe)*Ae,ee=Math.min(k.screenToDocumentRow(ee,0),k.getLength()-1),q=B.scrollerHeight+k.getRowLength(ee)*Ae+we,ue=this.scrollTop-ye*Ae,ue<0&&ye>0&&(ye=Math.max(0,ye+Math.floor(ue/Ae)),ue=this.scrollTop-ye*Ae);var ze=0;return(this.layerConfig.width!=A||j)&&(ze=this.CHANGE_H_SCROLL),(j||ne)&&(ze|=this.$updateCachedSize(!0,this.gutterWidth,B.width,B.height),this._signal("scrollbarVisibilityChanged"),ne&&(A=this.$getLongestLine())),this.layerConfig={width:A,padding:this.$padding,firstRow:oe,firstRowScreen:ye,lastRow:ee,lineHeight:Ae,characterWidth:this.characterWidth,fontMetrics:this.$fontMetrics,minHeight:q,maxHeight:$,offset:ue,gutterOffset:Ae?Math.max(0,Math.ceil((ue+B.height-B.scrollerHeight)/Ae)):0,height:this.$size.scrollerHeight},this.$fontMetrics.config=this.layerConfig,this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(A-this.$padding),ze},E.prototype.$updateLines=function(){if(this.$changedLines){var k=this.$changedLines.firstRow,B=this.$changedLines.lastRow;this.$changedLines=null;var N=this.layerConfig;if(!(k>N.lastRow+1)&&!(B<N.firstRow)){if(B===1/0){this.$showGutter&&this.$gutterLayer.update(N),this.$textLayer.update(N);return}return this.$textLayer.updateLines(N,k,B),!0}}},E.prototype.$getLongestLine=function(){var k=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(k+=1),this.$textLayer&&k>this.$textLayer.MAX_LINE_LENGTH&&(k=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(k*this.characterWidth))},E.prototype.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},E.prototype.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},E.prototype.addGutterDecoration=function(k,B){this.$gutterLayer.addGutterDecoration(k,B)},E.prototype.removeGutterDecoration=function(k,B){this.$gutterLayer.removeGutterDecoration(k,B)},E.prototype.updateBreakpoints=function(k){this._rows=k,this.$loop.schedule(this.CHANGE_GUTTER)},E.prototype.setAnnotations=function(k){this.$gutterLayer.setAnnotations(k),this.$loop.schedule(this.CHANGE_GUTTER)},E.prototype.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},E.prototype.hideCursor=function(){this.$cursorLayer.hideCursor()},E.prototype.showCursor=function(){this.$cursorLayer.showCursor()},E.prototype.scrollSelectionIntoView=function(k,B,N){this.scrollCursorIntoView(k,N),this.scrollCursorIntoView(B,N)},E.prototype.scrollCursorIntoView=function(k,B,N){if(this.$size.scrollerHeight!==0){var M=this.$cursorLayer.getPixelPosition(k),$=M.left,A=M.top,D=N&&N.top||0,j=N&&N.bottom||0;this.$scrollAnimation&&(this.$stopAnimation=!0);var U=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;U+D>A?(B&&U+D>A+this.lineHeight&&(A-=B*this.$size.scrollerHeight),A===0&&(A=-this.scrollMargin.top),this.session.setScrollTop(A)):U+this.$size.scrollerHeight-j<A+this.lineHeight&&(B&&U+this.$size.scrollerHeight-j<A-this.lineHeight&&(A+=B*this.$size.scrollerHeight),this.session.setScrollTop(A+this.lineHeight+j-this.$size.scrollerHeight));var q=this.scrollLeft,Q=2*this.layerConfig.characterWidth;$-Q<q?($-=Q,$<this.$padding+Q&&($=-this.scrollMargin.left),this.session.setScrollLeft($)):($+=Q,q+this.$size.scrollerWidth<$+this.characterWidth?this.session.setScrollLeft(Math.round($+this.characterWidth-this.$size.scrollerWidth)):q<=this.$padding&&$-q<this.characterWidth&&this.session.setScrollLeft(0))}},E.prototype.getScrollTop=function(){return this.session.getScrollTop()},E.prototype.getScrollLeft=function(){return this.session.getScrollLeft()},E.prototype.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},E.prototype.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},E.prototype.scrollToRow=function(k){this.session.setScrollTop(k*this.lineHeight)},E.prototype.alignCursor=function(k,B){typeof k=="number"&&(k={row:k,column:0});var N=this.$cursorLayer.getPixelPosition(k),M=this.$size.scrollerHeight-this.lineHeight,$=N.top-M*(B||0);return this.session.setScrollTop($),$},E.prototype.$calcSteps=function(k,B){var N=0,M=this.STEPS,$=[],A=function(D,j,U){return U*(Math.pow(D-1,3)+1)+j};for(N=0;N<M;++N)$.push(A(N/this.STEPS,k,B-k));return $},E.prototype.scrollToLine=function(k,B,N,M){var $=this.$cursorLayer.getPixelPosition({row:k,column:0}),A=$.top;B&&(A-=this.$size.scrollerHeight/2);var D=this.scrollTop;this.session.setScrollTop(A),N!==!1&&this.animateScrolling(D,M)},E.prototype.animateScrolling=function(k,B){var N=this.scrollTop;if(!this.$animatedScroll)return;var M=this;if(k==N)return;if(this.$scrollAnimation){var $=this.$scrollAnimation.steps;if($.length&&(k=$[0],k==N))return}var A=M.$calcSteps(k,N);this.$scrollAnimation={from:k,to:N,steps:A},clearInterval(this.$timer),M.session.setScrollTop(A.shift()),M.session.$scrollTop=N;function D(){M.$timer=clearInterval(M.$timer),M.$scrollAnimation=null,M.$stopAnimation=!1,B&&B()}this.$timer=setInterval(function(){if(M.$stopAnimation){D();return}if(!M.session)return clearInterval(M.$timer);A.length?(M.session.setScrollTop(A.shift()),M.session.$scrollTop=N):N!=null?(M.session.$scrollTop=-1,M.session.setScrollTop(N),N=null):D()},10)},E.prototype.scrollToY=function(k){this.scrollTop!==k&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=k)},E.prototype.scrollToX=function(k){this.scrollLeft!==k&&(this.scrollLeft=k),this.$loop.schedule(this.CHANGE_H_SCROLL)},E.prototype.scrollTo=function(k,B){this.session.setScrollTop(B),this.session.setScrollLeft(k)},E.prototype.scrollBy=function(k,B){B&&this.session.setScrollTop(this.session.getScrollTop()+B),k&&this.session.setScrollLeft(this.session.getScrollLeft()+k)},E.prototype.isScrollableBy=function(k,B){if(B<0&&this.session.getScrollTop()>=1-this.scrollMargin.top||B>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||k<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left||k>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right)return!0},E.prototype.pixelToScreenCoordinates=function(k,B){var N;if(this.$hasCssTransforms){N={top:this.margin.top,left:this.gutterWidth+this.margin.left};var M=this.$fontMetrics.transformCoordinates([k,B]);k=M[0],B=M[1]}else N=this.scroller.getBoundingClientRect();var $=k+this.scrollLeft-N.left-this.$padding,A=$/this.characterWidth,D=(B+this.scrollTop-N.top)/this.lineHeight,j=this.$blockCursor?Math.floor(A):Math.round(A);return j=this.$fontMetrics.$pixelToColumn(D,j,k,this.$blockCursor),{row:D,column:j,side:A-j>0?1:-1,offsetX:$}},E.prototype.screenToTextCoordinates=function(k,B){var N=this.pixelToScreenCoordinates(k,B);return this.session.screenToDocumentPosition(N.row,Math.max(N.column,0))},E.prototype.textToScreenCoordinates=function(k,B){var N=this.session.documentToScreenPosition(k,B),M=this.$padding+this.$fontMetrics.textWidth(N.row,N.column),$=N.row*this.lineHeight;if(this.$hasCssTransforms){var A=this.$fontMetrics.transformCoordinates(null,[this.gutterWidth+this.margin.left+M-this.scrollLeft,this.margin.top+$-this.scrollTop]);return{pageX:A[0],pageY:A[1]}}var D=this.scroller.getBoundingClientRect();return{pageX:D.left+M-this.scrollLeft,pageY:D.top+$-this.scrollTop}},E.prototype.visualizeFocus=function(){g.addCssClass(this.container,"ace_focus")},E.prototype.visualizeBlur=function(){g.removeCssClass(this.container,"ace_focus")},E.prototype.showComposition=function(k){this.$composition=k,k.cssText||(k.cssText=this.textarea.style.cssText),k.useTextareaForIME==null&&(k.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(g.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):k.markerId=this.session.addMarker(k.markerRange,"ace_composition_marker","text")},E.prototype.setCompositionText=function(k){var B=this.session.selection.cursor;this.addToken(k,"composition_placeholder",B.row,B.column),this.$moveTextAreaToCursor()},E.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 k=this.session.selection.cursor;this.removeExtraToken(k.row,k.column),this.$composition=null,this.$cursorLayer.element.style.display=""}},E.prototype.setGhostText=function(k,B){var N=this.session.selection.cursor,M=B||{row:N.row,column:N.column};this.removeGhostText();var $=this.$calculateWrappedTextChunks(k,M);this.addToken($[0].text,"ghost_text",M.row,M.column),this.$ghostText={text:k,position:{row:M.row,column:M.column}};var A=g.createElement("div");if($.length>1){var D=this.hideTokensAfterPosition(M.row,M.column),j;$.slice(1).forEach(function(ne){var ue=g.createElement("div"),he=g.createElement("span");he.className="ace_ghost_text",ne.wrapped&&(ue.className="ghost_text_line_wrapped"),ne.text.length===0&&(ne.text=" "),he.appendChild(g.createTextNode(ne.text)),ue.appendChild(he),A.appendChild(ue),j=ue}),D.forEach(function(ne){var ue=g.createElement("span");P(ne.type)||(ue.className="ace_"+ne.type.replace(/\./g," ace_")),ue.appendChild(g.createTextNode(ne.value)),j.appendChild(ue)}),this.$ghostTextWidget={el:A,row:M.row,column:M.column,className:"ace_ghost_text_container"},this.session.widgetManager.addLineWidget(this.$ghostTextWidget);var U=this.$cursorLayer.getPixelPosition(M,!0),q=this.container,Q=q.getBoundingClientRect().height,re=$.length*this.lineHeight,le=re<Q-U.top;if(le)return;re<Q?this.scrollBy(0,($.length-1)*this.lineHeight):this.scrollToRow(M.row)}},E.prototype.$calculateWrappedTextChunks=function(k,B){var N=this.$size.scrollerWidth-this.$padding*2,M=Math.floor(N/this.characterWidth)-2;M=M<=0?60:M;for(var $=k.split(/\r?\n/),A=[],D=0;D<$.length;D++){var j=this.session.$getDisplayTokens($[D],B.column),U=this.session.$computeWrapSplits(j,M,this.session.$tabSize);if(U.length>0){var q=0;U.push($[D].length);for(var Q=0;Q<U.length;Q++){var re=$[D].slice(q,U[Q]);A.push({text:re,wrapped:!0}),q=U[Q]}}else A.push({text:$[D],wrapped:!1})}return A},E.prototype.removeGhostText=function(){if(this.$ghostText){var k=this.$ghostText.position;this.removeExtraToken(k.row,k.column),this.$ghostTextWidget&&(this.session.widgetManager.removeLineWidget(this.$ghostTextWidget),this.$ghostTextWidget=null),this.$ghostText=null}},E.prototype.addToken=function(k,B,N,M){var $=this.session;$.bgTokenizer.lines[N]=null;var A={type:B,value:k},D=$.getTokens(N);if(M==null||!D.length)D.push(A);else for(var j=0,U=0;U<D.length;U++){var q=D[U];if(j+=q.value.length,M<=j){var Q=q.value.length-(j-M),re=q.value.slice(0,Q),le=q.value.slice(Q);D.splice(U,1,{type:q.type,value:re},A,{type:q.type,value:le});break}}this.updateLines(N,N)},E.prototype.hideTokensAfterPosition=function(k,B){for(var N=this.session.getTokens(k),M=0,$=!1,A=[],D=0;D<N.length;D++){var j=N[D];if(M+=j.value.length,j.type!=="ghost_text"){if($){A.push({type:j.type,value:j.value}),j.type="hidden_token";continue}M===B&&($=!0)}}return this.updateLines(k,k),A},E.prototype.removeExtraToken=function(k,B){this.session.bgTokenizer.lines[k]=null,this.updateLines(k,k)},E.prototype.setTheme=function(k,B){var N=this;if(this.$themeId=k,N._dispatchEvent("themeChange",{theme:k}),!k||typeof k=="string"){var M=k||this.$options.theme.initialValue;s.loadModule(["theme",M],$)}else $(k);function $(A){if(N.$themeId!=k)return B&&B();if(!A||!A.cssClass)throw new Error("couldn't load module "+k+" or it didn't call define");A.$id&&(N.$themeId=A.$id),g.importCssString(A.cssText,A.cssClass,N.container),N.theme&&g.removeCssClass(N.container,N.theme.cssClass);var D="padding"in A?A.padding:"padding"in(N.theme||{})?4:N.$padding;if(N.$padding&&D!=N.$padding&&N.setPadding(D),N.$gutterLayer){var j=A.$showGutterCursorMarker;j&&!N.$gutterLayer.$showCursorMarker?N.$gutterLayer.$showCursorMarker="theme":!j&&N.$gutterLayer.$showCursorMarker=="theme"&&(N.$gutterLayer.$showCursorMarker=null)}N.$theme=A.cssClass,N.theme=A,g.addCssClass(N.container,A.cssClass),g.setCssClass(N.container,"ace_dark",A.isDark),N.$size&&(N.$size.width=0,N.$updateSizeAsync()),N._dispatchEvent("themeLoaded",{theme:A}),B&&B(),C.isSafari&&N.scroller&&(N.scroller.style.background="red",N.scroller.style.background="")}},E.prototype.getTheme=function(){return this.$themeId},E.prototype.setStyle=function(k,B){g.setCssClass(this.container,k,B!==!1)},E.prototype.unsetStyle=function(k){g.removeCssClass(this.container,k)},E.prototype.setCursorStyle=function(k){g.setStyle(this.scroller.style,"cursor",k)},E.prototype.setMouseCursor=function(k){g.setStyle(this.scroller.style,"cursor",k)},E.prototype.attachToShadowRoot=function(){g.importCssString(T,"ace_editor.css",this.container)},E.prototype.destroy=function(){this.freeze(),this.$fontMetrics.destroy(),this.$cursorLayer.destroy(),this.removeAllListeners(),this.container.textContent="",this.setOption("useResizeObserver",!1)},E.prototype.$updateCustomScrollbar=function(k){var B=this;this.$horizScroll=this.$vScroll=null,this.scrollBarV.element.remove(),this.scrollBarH.element.remove(),k===!0?(this.scrollBarV=new m(this.container,this),this.scrollBarH=new f(this.container,this),this.scrollBarV.setHeight(this.$size.scrollerHeight),this.scrollBarH.setWidth(this.$size.scrollerWidth),this.scrollBarV.addEventListener("scroll",function(N){B.$scrollAnimation||B.session.setScrollTop(N.data-B.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(N){B.$scrollAnimation||B.session.setScrollLeft(N.data-B.scrollMargin.left)}),this.$scrollDecorator?(this.$scrollDecorator.setScrollBarV(this.scrollBarV),this.$scrollDecorator.$updateDecorators()):(this.$scrollDecorator=new _(this.scrollBarV,this),this.$scrollDecorator.$updateDecorators())):(this.scrollBarV=new o(this.container,this),this.scrollBarH=new d(this.container,this),this.scrollBarV.addEventListener("scroll",function(N){B.$scrollAnimation||B.session.setScrollTop(N.data-B.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(N){B.$scrollAnimation||B.session.setScrollLeft(N.data-B.scrollMargin.left)}))},E.prototype.$addResizeObserver=function(){if(!(!window.ResizeObserver||this.$resizeObserver)){var k=this;this.$resizeTimer=v.delayedCall(function(){k.destroyed||k.onResize()},50),this.$resizeObserver=new window.ResizeObserver(function(B){var N=B[0].contentRect.width,M=B[0].contentRect.height;Math.abs(k.$size.width-N)>1||Math.abs(k.$size.height-M)>1?k.$resizeTimer.delay():k.$resizeTimer.cancel()}),this.$resizeObserver.observe(this.container)}},E})();O.prototype.CHANGE_CURSOR=1,O.prototype.CHANGE_MARKER=2,O.prototype.CHANGE_GUTTER=4,O.prototype.CHANGE_SCROLL=8,O.prototype.CHANGE_LINES=16,O.prototype.CHANGE_TEXT=32,O.prototype.CHANGE_SIZE=64,O.prototype.CHANGE_MARKER_BACK=128,O.prototype.CHANGE_MARKER_FRONT=256,O.prototype.CHANGE_FULL=512,O.prototype.CHANGE_H_SCROLL=1024,O.prototype.$changes=0,O.prototype.$padding=null,O.prototype.$frozen=!1,O.prototype.STEPS=8,h.implement(O.prototype,R),s.defineOptions(O.prototype,"renderer",{useResizeObserver:{set:function(E){!E&&this.$resizeObserver?(this.$resizeObserver.disconnect(),this.$resizeTimer.cancel(),this.$resizeTimer=this.$resizeObserver=null):E&&!this.$resizeObserver&&this.$addResizeObserver()}},animatedScroll:{initialValue:!1},showInvisibles:{set:function(E){this.$textLayer.setShowInvisibles(E)&&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(E){typeof E=="number"&&(this.$printMarginColumn=E),this.$showPrintMargin=!!E,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(E){this.$gutter.style.display=E?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},useSvgGutterIcons:{set:function(E){this.$gutterLayer.$useSvgGutterIcons=E},initialValue:!1},showFoldedAnnotations:{set:function(E){this.$gutterLayer.$showFoldedAnnotations=E},initialValue:!1},fadeFoldWidgets:{set:function(E){g.setCssClass(this.$gutter,"ace_fade-fold-widgets",E)},initialValue:!1},showFoldWidgets:{set:function(E){this.$gutterLayer.setShowFoldWidgets(E),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(E){this.$textLayer.setDisplayIndentGuides(E)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightIndentGuides:{set:function(E){this.$textLayer.setHighlightIndentGuides(E)==!0?this.$textLayer.$highlightIndentGuide():this.$textLayer.$clearActiveIndentGuide(this.$textLayer.$lines.cells)},initialValue:!0},highlightGutterLine:{set:function(E){this.$gutterLayer.setHighlightGutterLine(E),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},hScrollBarAlwaysVisible:{set:function(E){(!this.$hScrollBarAlwaysVisible||!this.$horizScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(E){(!this.$vScrollBarAlwaysVisible||!this.$vScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(E){typeof E=="number"&&(E=E+"px"),this.container.style.fontSize=E,this.updateFontSize()},initialValue:12},fontFamily:{set:function(E){this.container.style.fontFamily=E,this.updateFontSize()}},maxLines:{set:function(E){this.updateFull()}},minLines:{set:function(E){this.$minLines<562949953421311||(this.$minLines=0),this.updateFull()}},maxPixelHeight:{set:function(E){this.updateFull()},initialValue:0},scrollPastEnd:{set:function(E){E=+E||0,this.$scrollPastEnd!=E&&(this.$scrollPastEnd=E,this.$loop.schedule(this.CHANGE_SCROLL))},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(E){this.$gutterLayer.$fixedWidth=!!E,this.$loop.schedule(this.CHANGE_GUTTER)}},customScrollbar:{set:function(E){this.$updateCustomScrollbar(E)},initialValue:!1},theme:{set:function(E){this.setTheme(E)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0},hasCssTransforms:{},useTextareaForIME:{initialValue:!C.isMobile&&!C.isIE}}),r.VirtualRenderer=O}),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],function(t,r,c){var h=t("../lib/oop"),g=t("../lib/net"),v=t("../lib/event_emitter").EventEmitter,s=t("../config");function p(d){var o="importScripts('"+g.qualifyURL(d)+"');";try{return new Blob([o],{type:"application/javascript"})}catch{var f=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder,m=new f;return m.append(o),m.getBlob("application/javascript")}}function a(d){if(typeof Worker>"u")return{postMessage:function(){},terminate:function(){}};if(s.get("loadWorkerFromBlob")){var o=p(d),f=window.URL||window.webkitURL,m=f.createObjectURL(o);return new Worker(m)}return new Worker(d)}var l=function(d){d.postMessage||(d=this.$createWorkerFromOldConfig.apply(this,arguments)),this.$worker=d,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(){h.implement(this,v),this.$createWorkerFromOldConfig=function(d,o,f,m,w){if(t.nameToUrl&&!t.toUrl&&(t.toUrl=t.nameToUrl),s.get("packaged")||!t.toUrl)m=m||s.moduleUrl(o,"worker");else{var x=this.$normalizePath;m=m||x(t.toUrl("ace/worker/worker.js",null,"_"));var R={};d.forEach(function(T){R[T]=x(t.toUrl(T,null,"_").replace(/(\.js)?(\?.*)?$/,""))})}return this.$worker=a(m),w&&this.send("importScripts",w),this.$worker.postMessage({init:!0,tlns:R,module:o,classname:f}),this.$worker},this.onMessage=function(d){var o=d.data;switch(o.type){case"event":this._signal(o.name,{data:o.data});break;case"call":var f=this.callbacks[o.id];f&&(f(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(d){window.console&&console.error&&console.error(d)},this.$normalizePath=function(d){return g.qualifyURL(d)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker.onerror=function(d){d.preventDefault()},this.$worker=null,this.$doc&&this.$doc.off("change",this.changeListener),this.$doc=null},this.send=function(d,o){this.$worker.postMessage({command:d,args:o})},this.call=function(d,o,f){if(f){var m=this.callbackId++;this.callbacks[m]=f,o.push(m)}this.send(d,o)},this.emit=function(d,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:d,data:{data:o.data}})}catch(f){console.error(f.stack)}},this.attachToDocument=function(d){this.$doc&&this.terminate(),this.$doc=d,this.call("setValue",[d.getValue()]),d.on("change",this.changeListener,!0)},this.changeListener=function(d){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0)),d.action=="insert"?this.deltaQueue.push(d.start,d.lines):this.deltaQueue.push(d.start,d.end)},this.$sendDeltaQueue=function(){var d=this.deltaQueue;d&&(this.deltaQueue=null,d.length>50&&d.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:d}))}}).call(l.prototype);var u=function(d,o,f){var m=null,w=!1,x=Object.create(v),R=[],T=new l({messageBuffer:R,terminate:function(){},postMessage:function(C){R.push(C),m&&(w?setTimeout(_):_())}});T.setEmitSync=function(C){w=C};var _=function(){var C=R.shift();C.command?m[C.command].apply(m,C.args):C.event&&x._signal(C.event,C.data)};return x.postMessage=function(C){T.onMessage({data:C})},x.callback=function(C,P){this.postMessage({type:"call",id:P,data:C})},x.emit=function(C,P){this.postMessage({type:"event",name:C,data:P})},s.loadModule(["worker",o],function(C){for(m=new C[f](x);R.length;)_()}),T};r.UIWorkerClient=u,r.WorkerClient=l,r.createWorker=a}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(t,r,c){var h=t("./range").Range,g=t("./lib/event_emitter").EventEmitter,v=t("./lib/oop"),s=(function(){function p(a,l,u,d,o,f){var m=this;this.length=l,this.session=a,this.doc=a.getDocument(),this.mainClass=o,this.othersClass=f,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate,!0),this.$others=d,this.$onCursorChange=function(){setTimeout(function(){m.onCursorChange()})},this.$pos=u;var w=a.getUndoManager().$undoStack||a.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=w.length,this.setup(),a.selection.on("changeCursor",this.$onCursorChange)}return p.prototype.setup=function(){var a=this,l=this.doc,u=this.session;this.selectionBefore=u.selection.toJSON(),u.selection.inMultiSelectMode&&u.selection.toSingleRange(),this.pos=l.createAnchor(this.$pos.row,this.$pos.column);var d=this.pos;d.$insertRight=!0,d.detach(),d.markerId=u.addMarker(new h(d.row,d.column,d.row,d.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach(function(o){var f=l.createAnchor(o.row,o.column);f.$insertRight=!0,f.detach(),a.others.push(f)}),u.setUndoSelect(!1)},p.prototype.showOtherMarkers=function(){if(!this.othersActive){var a=this.session,l=this;this.othersActive=!0,this.others.forEach(function(u){u.markerId=a.addMarker(new h(u.row,u.column,u.row,u.column+l.length),l.othersClass,null,!1)})}},p.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)}},p.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 u=a.action==="insert"?l.end.column-l.start.column:l.start.column-l.end.column,d=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),d&&(this.length+=u),d&&!this.session.$fromUndo){if(a.action==="insert")for(var f=this.others.length-1;f>=0;f--){var m=this.others[f],w={row:m.row,column:m.column+o};this.doc.insertMergedLines(w,a.lines)}else if(a.action==="remove")for(var f=this.others.length-1;f>=0;f--){var m=this.others[f],w={row:m.row,column:m.column+o};this.doc.remove(new h(w.row,w.column,w.row,w.column-u))}}this.$updating=!1,this.updateMarkers()}},p.prototype.updateAnchors=function(a){this.pos.onChange(a);for(var l=this.others.length;l--;)this.others[l].onChange(a);this.updateMarkers()},p.prototype.updateMarkers=function(){if(!this.$updating){var a=this,l=this.session,u=function(o,f){l.removeMarker(o.markerId),o.markerId=l.addMarker(new h(o.row,o.column,o.row,o.column+a.length),f,null,!1)};u(this.pos,this.mainClass);for(var d=this.others.length;d--;)u(this.others[d],this.othersClass)}},p.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))}},p.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},p.prototype.cancel=function(){if(this.$undoStackDepth!==-1){for(var a=this.session.getUndoManager(),l=(a.$undoStack||a.$undostack).length-this.$undoStackDepth,u=0;u<l;u++)a.undo(this.session,!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}},p})();v.implement(s.prototype,g),r.PlaceHolder=s}),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(t,r,c){var h=t("../lib/event"),g=t("../lib/useragent");function v(p,a){return p.row==a.row&&p.column==a.column}function s(p){var a=p.domEvent,l=a.altKey,u=a.shiftKey,d=a.ctrlKey,o=p.getAccelKey(),f=p.getButton();if(d&&g.isMac&&(f=a.button),p.editor.inMultiSelectMode&&f==2){p.editor.textInput.onContextMenu(p.domEvent);return}if(!d&&!l&&!o){f===0&&p.editor.inMultiSelectMode&&p.editor.exitMultiSelectMode();return}if(f===0){var m=p.editor,w=m.selection,x=m.inMultiSelectMode,R=p.getDocumentPosition(),T=w.getCursor(),_=p.inSelection()||w.isEmpty()&&v(R,T),C=p.x,P=p.y,O=function(re){C=re.clientX,P=re.clientY},E=m.session,k=m.renderer.pixelToScreenCoordinates(C,P),B=k,N;if(m.$mouseHandler.$enableJumpToDef)d&&l||o&&l?N=u?"block":"add":l&&m.$blockSelectEnabled&&(N="block");else if(o&&!l){if(N="add",!x&&u)return}else l&&m.$blockSelectEnabled&&(N="block");if(N&&g.isMac&&a.ctrlKey&&m.$mouseHandler.cancelContextMenu(),N=="add"){if(!x&&_)return;if(!x){var M=w.toOrientedRange();m.addSelectionMarker(M)}var $=w.rangeList.rangeAtPoint(R);m.inVirtualSelectionMode=!0,u&&($=null,M=w.ranges[0]||M,m.removeSelectionMarker(M)),m.once("mouseup",function(){var re=w.toOrientedRange();$&&re.isEmpty()&&v($.cursor,re.cursor)?w.substractPoint(re.cursor):(u?w.substractPoint(M.cursor):M&&(m.removeSelectionMarker(M),w.addRange(M)),w.addRange(re)),m.inVirtualSelectionMode=!1})}else if(N=="block"){p.stop(),m.inVirtualSelectionMode=!0;var A,D=[],j=function(){var re=m.renderer.pixelToScreenCoordinates(C,P),le=E.screenToDocumentPosition(re.row,re.column);v(B,re)&&v(le,w.lead)||(B=re,m.selection.moveToPosition(le),m.renderer.scrollCursorIntoView(),m.removeSelectionMarkers(D),D=w.rectangularRangeBlock(B,k),m.$mouseHandler.$clickSelection&&D.length==1&&D[0].isEmpty()&&(D[0]=m.$mouseHandler.$clickSelection.clone()),D.forEach(m.addSelectionMarker,m),m.updateSelectionMarkers())};x&&!o?w.toSingleRange():!x&&o&&(A=w.toOrientedRange(),m.addSelectionMarker(A)),u?k=E.documentToScreenPosition(w.lead):w.moveToPosition(R),B={row:-1,column:-1};var U=function(re){j(),clearInterval(Q),m.removeSelectionMarkers(D),D.length||(D=[w.toOrientedRange()]),A&&(m.removeSelectionMarker(A),w.toSingleRange(A));for(var le=0;le<D.length;le++)w.addRange(D[le]);m.inVirtualSelectionMode=!1,m.$mouseHandler.$clickSelection=null},q=j;h.capture(m.container,O,U);var Q=setInterval(function(){q()},20);return p.preventDefault()}}}r.onMouseDown=s}),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],function(t,r,c){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 h=t("../keyboard/hash_handler").HashHandler;r.keyboardHandler=new h(r.multiSelectCommands)}),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],function(t,r,c){var h=t("./range_list").RangeList,g=t("./range").Range,v=t("./selection").Selection,s=t("./mouse/multi_select_handler").onMouseDown,p=t("./lib/event"),a=t("./lib/lang"),l=t("./commands/multi_select_commands");r.commands=l.defaultCommands.concat(l.multiSelectCommands);var u=t("./search").Search,d=new u;function o(T,_,C){return d.$options.wrap=!0,d.$options.needle=_,d.$options.backwards=C==-1,d.find(T)}var f=t("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(f.prototype),(function(){this.ranges=null,this.rangeList=null,this.addRange=function(T,_){if(T){if(!this.inMultiSelectMode&&this.rangeCount===0){var C=this.toOrientedRange();if(this.rangeList.add(C),this.rangeList.add(T),this.rangeList.ranges.length!=2)return this.rangeList.removeAll(),_||this.fromOrientedRange(T);this.rangeList.removeAll(),this.rangeList.add(C),this.$onAddRange(C)}T.cursor||(T.cursor=T.end);var P=this.rangeList.add(T);return this.$onAddRange(T),P.length&&this.$onRemoveRange(P),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),_||this.fromOrientedRange(T)}},this.toSingleRange=function(T){T=T||this.ranges[0];var _=this.rangeList.removeAll();_.length&&this.$onRemoveRange(_),T&&this.fromOrientedRange(T)},this.substractPoint=function(T){var _=this.rangeList.substractPoint(T);if(_)return this.$onRemoveRange(_),_[0]},this.mergeOverlappingRanges=function(){var T=this.rangeList.merge();T.length&&this.$onRemoveRange(T)},this.$onAddRange=function(T){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(T),this._signal("addRange",{range:T})},this.$onRemoveRange=function(T){if(this.rangeCount=this.rangeList.ranges.length,this.rangeCount==1&&this.inMultiSelectMode){var _=this.rangeList.ranges.pop();T.push(_),this.rangeCount=0}for(var C=T.length;C--;){var P=this.ranges.indexOf(T[C]);P!=-1&&this.ranges.splice(P,1)}this._signal("removeRange",{ranges:T}),this.rangeCount===0&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),_=_||this.ranges[0],_&&!_.isEqual(this.getRange())&&this.fromOrientedRange(_)},this.$initRangeList=function(){this.rangeList||(this.rangeList=new h,this.ranges=[],this.rangeCount=0)},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){for(var T=this.ranges.length?this.ranges:[this.getRange()],_=[],C=0;C<T.length;C++){var P=T[C],O=P.start.row,E=P.end.row;if(O===E)_.push(P.clone());else{for(_.push(new g(O,P.start.column,O,this.session.getLine(O).length));++O<E;)_.push(this.getLineRange(O,!0));_.push(new g(E,0,E,P.end.column))}C==0&&!this.isBackwards()&&(_=_.reverse())}this.toSingleRange();for(var C=_.length;C--;)this.addRange(_[C])},this.joinSelections=function(){var T=this.rangeList.ranges,_=T[T.length-1],C=g.fromPoints(T[0].start,_.end);this.toSingleRange(),this.setSelectionRange(C,_.cursor==_.start)},this.toggleBlockSelection=function(){if(this.rangeCount>1){var T=this.rangeList.ranges,_=T[T.length-1],C=g.fromPoints(T[0].start,_.end);this.toSingleRange(),this.setSelectionRange(C,_.cursor==_.start)}else{var P=this.session.documentToScreenPosition(this.cursor),O=this.session.documentToScreenPosition(this.anchor),E=this.rectangularRangeBlock(P,O);E.forEach(this.addRange,this)}},this.rectangularRangeBlock=function(T,_,C){var P=[],O=T.column<_.column;if(O)var E=T.column,k=_.column;else var E=_.column,k=T.column;var B=T.row<_.row;if(B)var N=T.row,M=_.row;else var N=_.row,M=T.row;E<0&&(E=0),N<0&&(N=0),N==M&&(C=!0);for(var $,A=N;A<=M;A++){var D=g.fromPoints(this.session.screenToDocumentPosition(A,E),this.session.screenToDocumentPosition(A,k));if(D.isEmpty()){if($&&w(D.end,$))break;$=D.end}D.cursor=O?D.start:D.end,P.push(D)}if(B&&P.reverse(),!C){for(var j=P.length-1;P[j].isEmpty()&&j>0;)j--;if(j>0)for(var U=0;P[U].isEmpty();)U++;for(var q=j;q>=U;q--)P[q].isEmpty()&&P.splice(q,1)}return P}}).call(v.prototype);var m=t("./editor").Editor;(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(T){T.cursor||(T.cursor=T.end);var _=this.getSelectionStyle();return T.marker=this.session.addMarker(T,"ace_selection",_),this.session.$selectionMarkers.push(T),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,T},this.removeSelectionMarker=function(T){if(T.marker){this.session.removeMarker(T.marker);var _=this.session.$selectionMarkers.indexOf(T);_!=-1&&this.session.$selectionMarkers.splice(_,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length}},this.removeSelectionMarkers=function(T){for(var _=this.session.$selectionMarkers,C=T.length;C--;){var P=T[C];if(P.marker){this.session.removeMarker(P.marker);var O=_.indexOf(P);O!=-1&&_.splice(O,1)}}this.session.selectionMarkerCount=_.length},this.$onAddRange=function(T){this.addSelectionMarker(T.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(T){this.removeSelectionMarkers(T.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(T){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(T){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(T){var _=T.command,C=T.editor;if(C.multiSelect){if(_.multiSelectAction)_.multiSelectAction=="forEach"?P=C.forEachSelection(_,T.args):_.multiSelectAction=="forEachLine"?P=C.forEachSelection(_,T.args,!0):_.multiSelectAction=="single"?(C.exitMultiSelectMode(),P=_.exec(C,T.args||{})):P=_.multiSelectAction(C,T.args||{});else{var P=_.exec(C,T.args||{});C.multiSelect.addRange(C.multiSelect.toOrientedRange()),C.multiSelect.mergeOverlappingRanges()}return P}},this.forEachSelection=function(T,_,C){if(!this.inVirtualSelectionMode){var P=C&&C.keepOrder,O=C==!0||C&&C.$byLines,E=this.session,k=this.selection,B=k.rangeList,N=(P?k:B).ranges,M;if(!N.length)return T.exec?T.exec(this,_||{}):T(this,_||{});var $=k._eventRegistry;k._eventRegistry={};var A=new v(E);this.inVirtualSelectionMode=!0;try{for(var D=N.length;D--;){if(O)for(;D>0&&N[D].start.row==N[D-1].end.row;)D--;A.fromOrientedRange(N[D]),A.index=D,this.selection=E.selection=A;var j=T.exec?T.exec(this,_||{}):T(this,_||{});!M&&j!==void 0&&(M=j),A.toOrientedRange(N[D])}A.detach()}finally{this.selection=E.selection=k,this.inVirtualSelectionMode=!1,k._eventRegistry=$,k.mergeOverlappingRanges(),k.ranges[0]&&k.fromOrientedRange(k.ranges[0]);var U=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),U&&U.from==U.to&&this.renderer.animateScrolling(U.from),M}}},this.exitMultiSelectMode=function(){!this.inMultiSelectMode||this.inVirtualSelectionMode||this.multiSelect.toSingleRange()},this.getSelectedText=function(){var T="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var _=this.multiSelect.rangeList.ranges,C=[],P=0;P<_.length;P++)C.push(this.session.getTextRange(_[P]));var O=this.session.getDocument().getNewLineCharacter();T=C.join(O),T.length==(C.length-1)*O.length&&(T="")}else this.selection.isEmpty()||(T=this.session.getTextRange(this.getSelectionRange()));return T},this.$checkMultiselectChange=function(T,_){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var C=this.multiSelect.ranges[0];if(!C||this.multiSelect.isEmpty()&&_==this.multiSelect.anchor)return;var P=_==this.multiSelect.anchor?C.cursor==C.start?C.end:C.start:C.cursor;P.row!=_.row||this.session.$clipPositionToDocument(P.row,P.column).column!=_.column?this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()):this.multiSelect.mergeOverlappingRanges()}},this.findAll=function(T,_,C){if(_=_||{},_.needle=T||_.needle,_.needle==null){var P=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();_.needle=this.session.getTextRange(P)}this.$search.set(_);var O=this.$search.findAll(this.session);if(!O.length)return 0;var E=this.multiSelect;C||E.toSingleRange(O[0]);for(var k=O.length;k--;)E.addRange(O[k],!0);return P&&E.rangeList.rangeAtPoint(P.start)&&E.addRange(P,!0),O.length},this.selectMoreLines=function(T,_){var C=this.selection.toOrientedRange(),P=C.cursor==C.end,O=this.session.documentToScreenPosition(C.cursor);this.selection.$desiredColumn&&(O.column=this.selection.$desiredColumn);var E=this.session.screenToDocumentPosition(O.row+T,O.column);if(C.isEmpty())var B=E;else var k=this.session.documentToScreenPosition(P?C.end:C.start),B=this.session.screenToDocumentPosition(k.row+T,k.column);if(P){var N=g.fromPoints(E,B);N.cursor=N.start}else{var N=g.fromPoints(B,E);N.cursor=N.end}if(N.desiredColumn=O.column,!this.selection.inMultiSelectMode)this.selection.addRange(C);else if(_)var M=C.cursor;this.selection.addRange(N),M&&this.selection.substractPoint(M)},this.transposeSelections=function(T){for(var _=this.session,C=_.multiSelect,P=C.ranges,O=P.length;O--;){var E=P[O];if(E.isEmpty()){var k=_.getWordRange(E.start.row,E.start.column);E.start.row=k.start.row,E.start.column=k.start.column,E.end.row=k.end.row,E.end.column=k.end.column}}C.mergeOverlappingRanges();for(var B=[],O=P.length;O--;){var E=P[O];B.unshift(_.getTextRange(E))}T<0?B.unshift(B.pop()):B.push(B.shift());for(var O=P.length;O--;){var E=P[O],N=E.clone();_.replace(E,B[O]),E.start.row=N.start.row,E.start.column=N.start.column}C.fromOrientedRange(C.ranges[0])},this.selectMore=function(T,_,C){var P=this.session,O=P.multiSelect,E=O.toOrientedRange();if(!(E.isEmpty()&&(E=P.getWordRange(E.start.row,E.start.column),E.cursor=T==-1?E.start:E.end,this.multiSelect.addRange(E),C))){var k=P.getTextRange(E),B=o(P,k,T);B&&(B.cursor=T==-1?B.start:B.end,this.session.unfold(B),this.multiSelect.addRange(B),this.renderer.scrollCursorIntoView(null,.5)),_&&this.multiSelect.substractPoint(E.cursor)}},this.alignCursors=function(){var T=this.session,_=T.multiSelect,C=_.ranges,P=-1,O=C.filter(function(q){if(q.cursor.row==P)return!0;P=q.cursor.row});if(!C.length||O.length==C.length-1){var E=this.selection.getRange(),k=E.start.row,B=E.end.row,N=k==B;if(N){var M=this.session.getLength(),$;do $=this.session.getLine(B);while(/[=:]/.test($)&&++B<M);do $=this.session.getLine(k);while(/[=:]/.test($)&&--k>0);k<0&&(k=0),B>=M&&(B=M-1)}var A=this.session.removeFullLines(k,B);A=this.$reAlignText(A,N),this.session.insert({row:k,column:0},A.join(`
954
+ `)+`
955
+ `),N||(E.start.column=0,E.end.column=A[A.length-1].length),this.selection.setRange(E)}else{O.forEach(function(q){_.substractPoint(q.cursor)});var D=0,j=1/0,U=C.map(function(q){var Q=q.cursor,re=T.getLine(Q.row),le=re.substr(Q.column).search(/\S/g);return le==-1&&(le=0),Q.column>D&&(D=Q.column),le<j&&(j=le),le});C.forEach(function(q,Q){var re=q.cursor,le=D-re.column,ne=U[Q]-j;le>ne?T.insert(re,a.stringRepeat(" ",le-ne)):T.remove(new g(re.row,re.column,re.row,re.column-le+ne)),q.start.column=q.end.column=D,q.start.row=q.end.row=re.row,q.cursor=q.end}),_.fromOrientedRange(C[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}},this.$reAlignText=function(T,_){var C=!0,P=!0,O,E,k;return T.map(function(A){var D=A.match(/(\s*)(.*?)(\s*)([=:].*)/);return D?O==null?(O=D[1].length,E=D[2].length,k=D[3].length,D):(O+E+k!=D[1].length+D[2].length+D[3].length&&(P=!1),O!=D[1].length&&(C=!1),O>D[1].length&&(O=D[1].length),E<D[2].length&&(E=D[2].length),k>D[3].length&&(k=D[3].length),D):[A]}).map(_?N:C?P?M:N:$);function B(A){return a.stringRepeat(" ",A)}function N(A){return A[2]?B(O)+A[2]+B(E-A[2].length+k)+A[4].replace(/^([=:])\s+/,"$1 "):A[0]}function M(A){return A[2]?B(O+E-A[2].length)+A[2]+B(k)+A[4].replace(/^([=:])\s+/,"$1 "):A[0]}function $(A){return A[2]?B(O)+A[2]+B(k)+A[4].replace(/^([=:])\s+/,"$1 "):A[0]}}}).call(m.prototype);function w(T,_){return T.row==_.row&&T.column==_.column}r.onSessionChange=function(T){var _=T.session;_&&!_.multiSelect&&(_.$selectionMarkers=[],_.selection.$initRangeList(),_.multiSelect=_.selection),this.multiSelect=_&&_.multiSelect;var C=T.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)),_&&(_.multiSelect.on("addRange",this.$onAddRange),_.multiSelect.on("removeRange",this.$onRemoveRange),_.multiSelect.on("multiSelect",this.$onMultiSelect),_.multiSelect.on("singleSelect",this.$onSingleSelect),_.multiSelect.lead.on("change",this.$checkMultiselectChange),_.multiSelect.anchor.on("change",this.$checkMultiselectChange)),_&&this.inMultiSelectMode!=_.selection.inMultiSelectMode&&(_.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())};function x(T){T.$multiselectOnSessionChange||(T.$onAddRange=T.$onAddRange.bind(T),T.$onRemoveRange=T.$onRemoveRange.bind(T),T.$onMultiSelect=T.$onMultiSelect.bind(T),T.$onSingleSelect=T.$onSingleSelect.bind(T),T.$multiselectOnSessionChange=r.onSessionChange.bind(T),T.$checkMultiselectChange=T.$checkMultiselectChange.bind(T),T.$multiselectOnSessionChange(T),T.on("changeSession",T.$multiselectOnSessionChange),T.on("mousedown",s),T.commands.addCommands(l.defaultCommands),R(T))}function R(T){if(!T.textInput)return;var _=T.textInput.getElement(),C=!1;p.addListener(_,"keydown",function(O){var E=O.keyCode==18&&!(O.ctrlKey||O.shiftKey||O.metaKey);T.$blockSelectEnabled&&E?C||(T.renderer.setMouseCursor("crosshair"),C=!0):C&&P()},T),p.addListener(_,"keyup",P,T),p.addListener(_,"blur",P,T);function P(O){C&&(T.renderer.setMouseCursor(""),C=!1)}}r.MultiSelect=x,t("./config").defineOptions(m.prototype,"editor",{enableMultiselect:{set:function(T){x(this),T?this.on("mousedown",s):this.off("mousedown",s)},value:!0},enableBlockSelect:{set:function(T){this.$blockSelectEnabled=T},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(t,r,c){var h=t("../../range").Range,g=r.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(v,s,p){var a=v.getLine(p);return this.foldingStartMarker.test(a)?"start":s=="markbeginend"&&this.foldingStopMarker&&this.foldingStopMarker.test(a)?"end":""},this.getFoldWidgetRange=function(v,s,p){return null},this.indentationBlock=function(v,s,p){var a=/\S/,l=v.getLine(s),u=l.search(a);if(u!=-1){for(var d=p||l.length,o=v.getLength(),f=s,m=s;++s<o;){var w=v.getLine(s).search(a);if(w!=-1){if(w<=u){var x=v.getTokenAt(s,0);if(!x||x.type!=="string")break}m=s}}if(m>f){var R=v.getLine(m).length;return new h(f,d,m,R)}}},this.openingBracketBlock=function(v,s,p,a,l){var u={row:p,column:a+1},d=v.$findClosingBracket(s,u,l);if(d){var o=v.foldWidgets[d.row];return o==null&&(o=v.getFoldWidget(d.row)),o=="start"&&d.row>u.row&&(d.row--,d.column=v.getLine(d.row).length),h.fromPoints(u,d)}},this.closingBracketBlock=function(v,s,p,a,l){var u={row:p,column:a},d=v.$findOpeningBracket(s,u);if(d)return d.column++,u.column--,h.fromPoints(d,u)}}).call(g.prototype)}),ace.define("ace/ext/error_marker",["require","exports","module","ace/lib/dom","ace/range","ace/config"],function(t,r,c){var h=t("../lib/dom"),g=t("../range").Range,v=t("../config").nls;function s(a,l,u){for(var d=0,o=a.length-1;d<=o;){var f=d+o>>1,m=u(l,a[f]);if(m>0)d=f+1;else if(m<0)o=f-1;else return f}return-(d+1)}function p(a,l,u){var d=a.getAnnotations().sort(g.comparePoints);if(d.length){var o=s(d,{row:l,column:-1},g.comparePoints);o<0&&(o=-o-1),o>=d.length?o=u>0?0:d.length-1:o===0&&u<0&&(o=d.length-1);var f=d[o];if(!(!f||!u)){if(f.row===l){do f=d[o+=u];while(f&&f.row===l);if(!f)return d.slice()}var m=[];l=f.row;do m[u<0?"unshift":"push"](f),f=d[o+=u];while(f&&f.row==l);return m.length&&m}}}r.showErrorMarker=function(a,l){var u=a.session,d=a.getCursorPosition(),o=d.row,f=u.widgetManager.getWidgetsAtRow(o).filter(function(O){return O.type=="errorMarker"})[0];f?f.destroy():o-=l;var m=p(u,o,l),w;if(m){var x=m[0];d.column=(x.pos&&typeof x.column!="number"?x.pos.sc:x.column)||0,d.row=x.row,w=a.renderer.$gutterLayer.$annotations[d.row]}else{if(f)return;w={displayText:[v("error-marker.good-state","Looks good!")],className:"ace_ok"}}a.session.unfold(d.row),a.selection.moveToPosition(d);var R={row:d.row,fixedWidth:!0,coverGutter:!0,el:h.createElement("div"),type:"errorMarker"},T=R.el.appendChild(h.createElement("div")),_=R.el.appendChild(h.createElement("div"));_.className="error_widget_arrow "+w.className;var C=a.renderer.$cursorLayer.getPixelPosition(d).left;_.style.left=C+a.renderer.gutterWidth-5+"px",R.el.className="error_widget_wrapper",T.className="error_widget "+w.className,w.displayText.forEach(function(O,E){T.appendChild(h.createTextNode(O)),E<w.displayText.length-1&&T.appendChild(h.createElement("br"))}),T.appendChild(h.createElement("div"));var P=function(O,E,k){if(E===0&&(k==="esc"||k==="return"))return R.destroy(),{command:"null"}};R.destroy=function(){a.$mouseHandler.isMousePressed||(a.keyBinding.removeKeyboardHandler(P),u.widgetManager.removeLineWidget(R),a.off("changeSelection",R.destroy),a.off("changeSession",R.destroy),a.off("mouseup",R.destroy),a.off("change",R.destroy))},a.keyBinding.addKeyboardHandler(P),a.on("changeSelection",R.destroy),a.on("changeSession",R.destroy),a.on("mouseup",R.destroy),a.on("change",R.destroy),a.session.widgetManager.addLineWidget(R),R.el.onmousedown=a.focus.bind(a),a.renderer.scrollCursorIntoView(null,.5,{bottom:R.el.offsetHeight})},h.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(t,r,c){t("./loader_build")(r);var h=t("./lib/dom"),g=t("./range").Range,v=t("./editor").Editor,s=t("./edit_session").EditSession,p=t("./undomanager").UndoManager,a=t("./virtual_renderer").VirtualRenderer;t("./worker/worker_client"),t("./keyboard/hash_handler"),t("./placeholder"),t("./multi_select"),t("./mode/folding/fold_mode"),t("./theme/textmate"),t("./ext/error_marker"),r.config=t("./config"),r.edit=function(u,d){if(typeof u=="string"){var o=u;if(u=document.getElementById(o),!u)throw new Error("ace.edit can't find div #"+o)}if(u&&u.env&&u.env.editor instanceof v)return u.env.editor;var f="";if(u&&/input|textarea/i.test(u.tagName)){var m=u;f=m.value,u=h.createElement("pre"),m.parentNode.replaceChild(u,m)}else u&&(f=u.textContent,u.innerHTML="");var w=r.createEditSession(f),x=new v(new a(u),w,d),R={document:w,editor:x,onResize:x.resize.bind(x,null)};return m&&(R.textarea=m),x.on("destroy",function(){R.editor.container.env=null}),x.container.env=x.env=R,x},r.createEditSession=function(u,d){var o=new s(u,d);return o.setUndoManager(new p),o},r.Range=g,r.Editor=v,r.EditSession=s,r.UndoManager=p,r.VirtualRenderer=a;var l=r.config.version;r.version=l}),(function(){ace.require(["ace/ace"],function(t){t&&(t.config.init(!0),t.define=ace.define);var r=(function(){return this})();!r&&typeof window<"u"&&(r=window),!r&&typeof self<"u"&&(r=self),r.ace||(r.ace=t);for(var c in t)t.hasOwnProperty(c)&&(r.ace[c]=t[c]);r.ace.default=r.ace,e&&(e.exports=r.ace)})})()})(Qv)),Qv.exports}var b3=lr("m",tT()),Xv={exports:{}},ey;function nT(){return ey||(ey=1,(function(e,n){ace.define("ace/mode/ruby_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,c){var h=t("../lib/oop"),g=t("./text_highlight_rules").TextHighlightRules,v=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 s=r.constantNumericHex={token:"constant.numeric",regex:"0[xX][0-9a-fA-F](?:[0-9a-fA-F]|_(?=[0-9a-fA-F]))*\\b"},p=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/},u=r.constantNumericRational={token:"constant.numeric",regex:/\b([\d]+(?:[./][\d]+)?ri?)\b/},d=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"},f=r.instanceVariable={token:"variable.instance",regex:"@{1,2}[a-zA-Z_\\d]+"},m=function(){var w="abort|Array|assert|assert_equal|assert_not_equal|assert_same|assert_not_same|assert_nil|assert_not_nil|assert_match|assert_no_match|assert_in_delta|assert_throws|assert_raise|assert_nothing_raised|assert_instance_of|assert_kind_of|assert_respond_to|assert_operator|assert_send|assert_difference|assert_no_difference|assert_recognizes|assert_generates|assert_response|assert_redirected_to|assert_template|assert_select|assert_select_email|assert_select_rjs|assert_select_encoded|css_select|at_exit|attr|attr_writer|attr_reader|attr_accessor|attr_accessible|autoload|binding|block_given?|callcc|caller|catch|chomp|chomp!|chop|chop!|defined?|delete_via_redirect|eval|exec|exit|exit!|fail|Float|flunk|follow_redirect!|fork|form_for|form_tag|format|gets|global_variables|gsub|gsub!|get_via_redirect|host!|https?|https!|include|Integer|lambda|link_to|link_to_unless_current|link_to_function|link_to_remote|load|local_variables|loop|open|open_session|p|print|printf|proc|putc|puts|post_via_redirect|put_via_redirect|raise|rand|raw|readline|readlines|redirect?|request_via_redirect|require|scan|select|set_trace_func|sleep|split|sprintf|srand|String|stylesheet_link_tag|syscall|system|sub|sub!|test|throw|trace_var|trap|untrace_var|atan2|cos|exp|frexp|ldexp|log|log10|sin|sqrt|tan|render|javascript_include_tag|csrf_meta_tag|label_tag|text_field_tag|submit_tag|check_box_tag|content_tag|radio_button_tag|text_area_tag|password_field_tag|hidden_field_tag|fields_for|select_tag|options_for_select|options_from_collection_for_select|collection_select|time_zone_select|select_date|select_time|select_datetime|date_select|time_select|datetime_select|select_year|select_month|select_day|select_hour|select_minute|select_second|file_field_tag|file_field|respond_to|skip_before_filter|around_filter|after_filter|verify|protect_from_forgery|rescue_from|helper_method|redirect_to|before_filter|send_data|send_file|validates_presence_of|validates_uniqueness_of|validates_length_of|validates_format_of|validates_acceptance_of|validates_associated|validates_exclusion_of|validates_inclusion_of|validates_numericality_of|validates_with|validates_each|authenticate_or_request_with_http_basic|authenticate_or_request_with_http_digest|filter_parameter_logging|match|get|post|resources|redirect|scope|assert_routing|translate|localize|extract_locale_from_tld|caches_page|expire_page|caches_action|expire_action|cache|expire_fragment|expire_cache_for|observe|cache_sweeper|has_many|has_one|belongs_to|has_and_belongs_to_many|p|warn|refine|using|module_function|extend|alias_method|private_class_method|remove_method|undef_method",x="alias|and|BEGIN|begin|break|case|class|def|defined|do|else|elsif|END|end|ensure|__FILE__|finally|for|gem|if|in|__LINE__|module|next|not|or|private|protected|public|redo|rescue|retry|return|super|then|undef|unless|until|when|while|yield|__ENCODING__|prepend",R="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",T="$DEBUG|$defout|$FILENAME|$LOAD_PATH|$SAFE|$stdin|$stdout|$stderr|$VERBOSE|$!|root_url|flash|session|cookies|params|request|response|logger|self",_=this.$keywords=this.createKeywordMapper({keyword:x,"constant.language":R,"variable.language":T,"support.function":w,"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})*})`,P={"(":")","[":"]","{":"}","<":">","^":"^","|":"|","%":"%"};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(O,E,k){k.length&&(k=[]);var B=O[O.length-1];return k.unshift(B,E),this.next="qStateWithoutInterpolation",this.token}},{token:"string.start",regex:/%[QWX]?([(\[<{^|%])/,onMatch:function(O,E,k){k.length&&(k=[]);var B=O[O.length-1];return k.unshift(B,E),this.next="qStateWithInterpolation",this.token}},{token:"constant.other.symbol.ruby",regex:/%[si]([(\[<{^|%])/,onMatch:function(O,E,k){k.length&&(k=[]);var B=O[O.length-1];return k.unshift(B,E),this.next="sStateWithoutInterpolation",this.token}},{token:"constant.other.symbol.ruby",regex:/%[SI]([(\[<{^|%])/,onMatch:function(O,E,k){k.length&&(k=[]);var B=O[O.length-1];return k.unshift(B,E),this.next="sStateWithInterpolation",this.token}},{token:"string.regexp",regex:/%[r]([(\[<{^|%])/,onMatch:function(O,E,k){k.length&&(k=[]);var B=O[O.length-1];return k.unshift(B,E),this.next="rState",this.token}}],{token:"punctuation",regex:"::"},f,{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:/\?(?=.+:)/},u,d,v,s,o,p,a,l,{token:"constant.language.boolean",regex:"(?:true|false)\\b"},{token:_,regex:"[a-zA-Z_$][a-zA-Z0-9_$]*\\b"},{token:"punctuation.separator.key-value",regex:"=>"},{stateName:"heredoc",onMatch:function(O,E,k){var B=O[2]=="-"||O[2]=="~"?"indentedHeredoc":"heredoc",N=O.split(this.splitRegex);return k.push(B,N[3]),[{type:"constant",value:N[1]},{type:"string",value:N[2]},{type:"support.class",value:N[3]},{type:"string",value:N[4]}]},regex:"(<<[-~]?)(['\"`]?)([\\w]+)(['\"`]?)",rules:{heredoc:[{onMatch:function(O,E,k){return O===k[1]?(k.shift(),k.shift(),this.next=k[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}],indentedHeredoc:[{token:"string",regex:"^ +"},{onMatch:function(O,E,k){return O===k[1]?(k.shift(),k.shift(),this.next=k[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}]}},{regex:"$",token:"empty",next:function(O,E){return E[0]==="heredoc"||E[0]==="indentedHeredoc"?E[0]:O}},{token:"keyword.operator",regex:"!|\\$|%|&|\\*|/|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\||\\b(?:in|instanceof|new|delete|typeof|void)"},{token:"paren.lparen",regex:"[[({]"},{token:"paren.rparen",regex:"[\\])}]",onMatch:function(O,E,k){return this.next="",O=="}"&&k.length>1&&k[1]!="start"&&(k.shift(),this.next=k.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(O,E,k){return k.length&&O===k[0]?(k.unshift(O,E),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(O,E,k){return k.length&&O===P[k[0]]?(k.shift(),this.next=k.shift(),this.token):(this.next="","string")}},{defaultToken:"string"}],qStateWithoutInterpolation:[{token:"string.start",regex:/[(\[<{]/,onMatch:function(O,E,k){return k.length&&O===k[0]?(k.unshift(O,E),this.token):"string"}},{token:"constant.language.escape",regex:/\\['\\]/},{token:"constant.language.escape",regex:/\\./},{token:"string.end",regex:/[)\]>}^|%]/,onMatch:function(O,E,k){return k.length&&O===P[k[0]]?(k.shift(),this.next=k.shift(),this.token):(this.next="","string")}},{defaultToken:"string"}],sStateWithoutInterpolation:[{token:"constant.other.symbol.ruby",regex:/[(\[<{]/,onMatch:function(O,E,k){return k.length&&O===k[0]?(k.unshift(O,E),this.token):"constant.other.symbol.ruby"}},{token:"constant.other.symbol.ruby",regex:/[)\]>}^|%]/,onMatch:function(O,E,k){return k.length&&O===P[k[0]]?(k.shift(),this.next=k.shift(),this.token):(this.next="","constant.other.symbol.ruby")}},{defaultToken:"constant.other.symbol.ruby"}],sStateWithInterpolation:[{token:"constant.other.symbol.ruby",regex:/[(\[<{]/,onMatch:function(O,E,k){return k.length&&O===k[0]?(k.unshift(O,E),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(O,E,k){return k.length&&O===P[k[0]]?(k.shift(),this.next=k.shift(),this.token):(this.next="","constant.other.symbol.ruby")}},{defaultToken:"constant.other.symbol.ruby"}],rState:[{token:"string.regexp",regex:/[(\[<{]/,onMatch:function(O,E,k){return k.length&&O===k[0]?(k.unshift(O,E),this.token):"constant.language.escape"}},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.regexp",regex:/\//},{token:"string.regexp",regex:/[)\]>}^|%][imxouesn]*/,onMatch:function(O,E,k){return k.length&&O[0]===P[k[0]]?(k.shift(),this.next=k.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()};h.inherits(m,g),r.RubyHighlightRules=m}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(t,r,c){var h=t("../range").Range,g=function(){};(function(){this.checkOutdent=function(v,s){return/^\s+$/.test(v)?/^\s*\}/.test(s):!1},this.autoOutdent=function(v,s){var p=v.getLine(s),a=p.match(/^(\s*\})/);if(!a)return 0;var l=a[1].length,u=v.findMatchingBracket({row:s,column:l});if(!u||u.row==s)return 0;var d=this.$getIndent(v.getLine(u.row));v.replace(new h(s,0,s,l-1),d)},this.$getIndent=function(v){return v.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(t,r,c){var h=t("../../lib/oop"),g=t("./fold_mode").FoldMode,v=t("../../range").Range,s=t("../../token_iterator").TokenIterator,p=r.FoldMode=function(){};h.inherits(p,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,u){var d=a.getLine(u),o=this.foldingStartMarker.test(d),f=this.foldingStopMarker.test(d);if(o&&!f){var m=d.match(this.foldingStartMarker);if(m[1]){if((m[1]=="if"||m[1]=="else"||m[1]=="while"||m[1]=="until"||m[1]=="unless")&&(m[1]=="else"&&/^\s*else\s*$/.test(d)===!1||/^\s*(?:if|else|while|until|unless)\s*/.test(d)===!1)||m[1]=="when"&&/\sthen\s/.test(d)===!0)return;if(a.getTokenAt(u,m.index+2).type==="keyword")return"start"}else if(!m[3]||a.getTokenAt(u,m.index+1).type==="comment.multiline")return"start"}if(l!="markbeginend"||!f||o&&f)return"";var m=d.match(this.foldingStopMarker);if(m[3]==="end"){if(a.getTokenAt(u,m.index+1).type==="keyword")return"end"}else if(!m[1]||a.getTokenAt(u,m.index+1).type==="comment.multiline")return"end"},this.getFoldWidgetRange=function(a,l,u){var d=a.doc.getLine(u),o=this.foldingStartMarker.exec(d);if(o)return o[1]||o[3]?this.rubyBlock(a,u,o.index+2):this.openingBracketBlock(a,"{",u,o.index);var o=this.foldingStopMarker.exec(d);if(o)return o[3]==="end"&&a.getTokenAt(u,o.index+1).type==="keyword"?this.rubyBlock(a,u,o.index+1):o[1]==="=end"&&a.getTokenAt(u,o.index+1).type==="comment.multiline"?this.rubyBlock(a,u,o.index+1):this.closingBracketBlock(a,"}",u,o.index+o[0].length)},this.rubyBlock=function(a,l,u,d){var o=new s(a,l,u),f=o.getCurrentToken();if(!(!f||f.type!="keyword"&&f.type!="comment.multiline")){var m=f.value,w=a.getLine(l);switch(f.value){case"if":case"unless":case"while":case"until":var x=new RegExp("^\\s*"+f.value);if(!x.test(w))return;var R=this.indentKeywords[m];break;case"when":if(/\sthen\s/.test(w))return;case"elsif":case"rescue":case"ensure":var R=1;break;case"else":var x=new RegExp("^\\s*"+f.value+"\\s*$");if(!x.test(w))return;var R=1;break;default:var R=this.indentKeywords[m]}var T=[m];if(R){var _=R===-1?a.getLine(l-1).length:a.getLine(l).length,C=l,P=[];if(P.push(o.getCurrentTokenRange()),o.step=R===-1?o.stepBackward:o.stepForward,f.type=="comment.multiline"){for(;f=o.step();)if(f.type==="comment.multiline"){if(R==1){if(_=6,f.value=="=end")break}else if(f.value=="=begin")break}}else for(;f=o.step();){var O=!1;if(f.type==="keyword"){var E=R*this.indentKeywords[f.value];switch(w=a.getLine(o.getCurrentTokenRow()),f.value){case"do":for(var k=o.$tokenIndex-1;k>=0;k--){var B=o.$rowTokens[k];if(B&&(B.value=="while"||B.value=="until"||B.value=="for")){E=0;break}}break;case"else":var x=new RegExp("^\\s*"+f.value+"\\s*$");(!x.test(w)||m=="case")&&(E=0,O=!0);break;case"if":case"unless":case"while":case"until":var x=new RegExp("^\\s*"+f.value);x.test(w)||(E=0,O=!0);break;case"when":(/\sthen\s/.test(w)||m=="case")&&(E=0,O=!0)}if(E>0)T.unshift(f.value);else if(E<=0&&O===!1){if(T.shift(),!T.length&&((m=="while"||m=="until"||m=="for")&&f.value!="do"||f.value=="do"&&R==-1&&E!=0||f.value!="do"))break;E===0&&T.unshift(f.value)}}}if(!f)return null;if(d)return P.push(o.getCurrentTokenRange()),P;var l=o.getCurrentTokenRow();if(R===-1){if(f.type==="comment.multiline")var N=6;else var N=a.getLine(l).length;return new v(l,N,C-1,_)}return new v(C,_,l-1,a.getLine(l-1).length)}}}}).call(p.prototype)}),ace.define("ace/mode/ruby",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ruby_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/folding/ruby"],function(t,r,c){var h=t("../lib/oop"),g=t("./text").Mode,v=t("./ruby_highlight_rules").RubyHighlightRules,s=t("./matching_brace_outdent").MatchingBraceOutdent,p=t("../range").Range,a=t("./folding/ruby").FoldMode,l=function(){this.HighlightRules=v,this.$outdent=new s,this.$behaviour=this.$defaultBehaviour,this.foldingRules=new a,this.indentKeywords=this.foldingRules.indentKeywords};h.inherits(l,g),(function(){this.lineCommentStart="#",this.getNextLineIndent=function(u,d,o){var f=this.$getIndent(d),m=this.getTokenizer().getLineTokens(d,u),w=m.tokens;if(w.length&&w[w.length-1].type=="comment")return f;if(u=="start"){var x=d.match(/^.*[\{\(\[]\s*$/),R=d.match(/^\s*(class|def|module)\s.*$/),T=d.match(/.*do(\s*|\s+\|.*\|\s*)$/),_=d.match(/^\s*(if|else|when|elsif|unless|while|for|begin|rescue|ensure)\s*/);(x||R||T||_)&&(f+=o)}return f},this.checkOutdent=function(u,d,o){return/^\s+(end|else|rescue|ensure)$/.test(d+o)||this.$outdent.checkOutdent(d,o)},this.autoOutdent=function(u,d,o){var f=d.getLine(o);if(/}/.test(f))return this.$outdent.autoOutdent(d,o);var m=this.$getIndent(f),w=d.getLine(o-1),x=this.$getIndent(w),R=d.getTabString();x.length<=m.length&&m.slice(-R.length)==R&&d.remove(new p(o,m.length-R.length,o,m.length))},this.getMatching=function(u,d,o){if(d==null){var f=u.selection.lead;o=f.column,d=f.row}var m=u.getTokenAt(d,o);if(m&&m.value in this.indentKeywords)return this.foldingRules.rubyBlock(u,d,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(t){e&&(e.exports=t)})})()})(Xv)),Xv.exports}nT();var ty={exports:{}},ny;function rT(){return ny||(ny=1,(function(e,n){ace.define("ace/mode/python_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,c){var h=t("../lib/oop"),g=t("./text_highlight_rules").TextHighlightRules,v=function(){var s="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",p="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":p,keyword:s},"identifier"),u="[uU]?",d="[rR]",o="[fF]",f="(?:[rR][fF]|[fF][rR])",m="(?:(?:[1-9]\\d*)|(?:0))",w="(?:0[oO]?[0-7]+)",x="(?:0[xX][\\dA-Fa-f]+)",R="(?:0[bB][01]+)",T="(?:"+m+"|"+w+"|"+x+"|"+R+")",_="(?:[eE][+-]?\\d+)",C="(?:\\.\\d+)",P="(?:\\d+)",O="(?:(?:"+P+"?"+C+")|(?:"+P+"\\.))",E="(?:(?:"+O+"|"+P+")"+_+")",k="(?:"+E+"|"+O+")",B=`\\\\(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:u+'"{3}',next:"qqstring3"},{token:"string",regex:u+'"(?=.)',next:"qqstring"},{token:"string",regex:u+"'{3}",next:"qstring3"},{token:"string",regex:u+"'(?=.)",next:"qstring"},{token:"string",regex:d+'"{3}',next:"rawqqstring3"},{token:"string",regex:d+'"(?=.)',next:"rawqqstring"},{token:"string",regex:d+"'{3}",next:"rawqstring3"},{token:"string",regex:d+"'(?=.)",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:f+'"{3}',next:"rfqqstring3"},{token:"string",regex:f+'"(?=.)',next:"rfqqstring"},{token:"string",regex:f+"'{3}",next:"rfqstring3"},{token:"string",regex:f+"'(?=.)",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:B},{token:"string",regex:'"{3}',next:"start"},{defaultToken:"string"}],qstring3:[{token:"constant.language.escape",regex:B},{token:"string",regex:"'{3}",next:"start"},{defaultToken:"string"}],qqstring:[{token:"constant.language.escape",regex:B},{token:"string",regex:"\\\\$",next:"qqstring"},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],qstring:[{token:"constant.language.escape",regex:B},{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:B},{token:"string",regex:'"{3}',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqstring3:[{token:"constant.language.escape",regex:B},{token:"string",regex:"'{3}",next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqqstring:[{token:"constant.language.escape",regex:B},{token:"string",regex:"\\\\$",next:"fqqstring"},{token:"string",regex:'"|$',next:"start"},{token:"paren.lparen",regex:"{",push:"fqstringParRules"},{defaultToken:"string"}],fqstring:[{token:"constant.language.escape",regex:B},{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:"(?:"+k+"|\\d+)[jJ]\\b"},{token:"constant.numeric",regex:k},{token:"constant.numeric",regex:T+"[lL]\\b"},{token:"constant.numeric",regex:T+"\\b"},{token:["punctuation","function.support"],regex:"(\\.)([a-zA-Z_]+)\\b"},{token:l,regex:"[a-zA-Z_$][a-zA-Z0-9_$]*\\b"}]},this.normalizeRules()};h.inherits(v,g),r.PythonHighlightRules=v}),ace.define("ace/mode/folding/pythonic",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"],function(t,r,c){var h=t("../../lib/oop"),g=t("./fold_mode").FoldMode,v=r.FoldMode=function(s){this.foldingStartMarker=new RegExp("([\\[{])(?:\\s*)$|("+s+")(?:\\s*)(?:#.*)?$")};h.inherits(v,g),(function(){this.getFoldWidgetRange=function(s,p,a){var l=s.getLine(a),u=l.match(this.foldingStartMarker);if(u)return u[1]?this.openingBracketBlock(s,u[1],a,u.index):u[2]?this.indentationBlock(s,a,u.index+u[2].length):this.indentationBlock(s,a)}}).call(v.prototype)}),ace.define("ace/mode/python",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/python_highlight_rules","ace/mode/folding/pythonic","ace/range"],function(t,r,c){var h=t("../lib/oop"),g=t("./text").Mode,v=t("./python_highlight_rules").PythonHighlightRules,s=t("./folding/pythonic").FoldMode,p=t("../range").Range,a=function(){this.HighlightRules=v,this.foldingRules=new s("\\:"),this.$behaviour=this.$defaultBehaviour};h.inherits(a,g),(function(){this.lineCommentStart="#",this.$pairQuotesAfter={"'":/[ruf]/i,'"':/[ruf]/i},this.getNextLineIndent=function(u,d,o){var f=this.$getIndent(d),m=this.getTokenizer().getLineTokens(d,u),w=m.tokens;if(w.length&&w[w.length-1].type=="comment")return f;if(u=="start"){var x=d.match(/^.*[\{\(\[:]\s*$/);x&&(f+=o)}return f};var l={pass:1,return:1,raise:1,break:1,continue:1};this.checkOutdent=function(u,d,o){if(o!==`\r
989
+ `&&o!=="\r"&&o!==`
990
+ `)return!1;var f=this.getTokenizer().getLineTokens(d.trim(),u).tokens;if(!f)return!1;do var m=f.pop();while(m&&(m.type=="comment"||m.type=="text"&&m.value.match(/^\s+$/)));return m?m.type=="keyword"&&l[m.value]:!1},this.autoOutdent=function(u,d,o){o+=1;var f=this.$getIndent(d.getLine(o)),m=d.getTabString();f.slice(-m.length)==m&&d.remove(new p(o,f.length-m.length,o,f.length))},this.$id="ace/mode/python",this.snippetFileId="ace/snippets/python"}).call(a.prototype),r.Mode=a}),(function(){ace.require(["ace/mode/python"],function(t){e&&(e.exports=t)})})()})(ty)),ty.exports}rT();var ry={exports:{}},iy;function iT(){return iy||(iy=1,(function(e,n){ace.define("ace/mode/json_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,c){var h=t("../lib/oop"),g=t("./text_highlight_rules").TextHighlightRules,v=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"}]}};h.inherits(v,g),r.JsonHighlightRules=v}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(t,r,c){var h=t("../range").Range,g=function(){};(function(){this.checkOutdent=function(v,s){return/^\s+$/.test(v)?/^\s*\}/.test(s):!1},this.autoOutdent=function(v,s){var p=v.getLine(s),a=p.match(/^(\s*\})/);if(!a)return 0;var l=a[1].length,u=v.findMatchingBracket({row:s,column:l});if(!u||u.row==s)return 0;var d=this.$getIndent(v.getLine(u.row));v.replace(new h(s,0,s,l-1),d)},this.$getIndent=function(v){return v.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(t,r,c){var h=t("../../lib/oop"),g=t("../../range").Range,v=t("./fold_mode").FoldMode,s=r.FoldMode=function(p){p&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+p.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+p.end)))};h.inherits(s,v),(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(p,a,l){var u=p.getLine(l);if(this.singleLineBlockCommentRe.test(u)&&!this.startRegionRe.test(u)&&!this.tripleStarBlockCommentRe.test(u))return"";var d=this._getFoldWidgetBase(p,a,l);return!d&&this.startRegionRe.test(u)?"start":d},this.getFoldWidgetRange=function(p,a,l,u){var d=p.getLine(l);if(this.startRegionRe.test(d))return this.getCommentRegionBlock(p,d,l);var o=d.match(this.foldingStartMarker);if(o){var f=o.index;if(o[1])return this.openingBracketBlock(p,o[1],l,f);var m=p.getCommentFoldRange(l,f+o[0].length,1);return m&&!m.isMultiLine()&&(u?m=this.getSectionRange(p,l):a!="all"&&(m=null)),m}if(a!=="markbegin"){var o=d.match(this.foldingStopMarker);if(o){var f=o.index+o[0].length;return o[1]?this.closingBracketBlock(p,o[1],l,f):p.getCommentFoldRange(l,f,-1)}}},this.getSectionRange=function(p,a){var l=p.getLine(a),u=l.search(/\S/),d=a,o=l.length;a+=1;for(var f=a,m=p.getLength();++a<m;){l=p.getLine(a);var w=l.search(/\S/);if(w!==-1){if(u>w)break;var x=this.getFoldWidgetRange(p,"all",a);if(x){if(x.start.row<=d)break;if(x.isMultiLine())a=x.end.row;else if(u==w)break}f=a}}return new g(d,o,f,p.getLine(f).length)},this.getCommentRegionBlock=function(p,a,l){for(var u=a.search(/\s*$/),d=p.getLength(),o=l,f=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,m=1;++l<d;){a=p.getLine(l);var w=f.exec(a);if(w&&(w[1]?m--:m++,!m))break}var x=l;if(x>o)return new g(o,u,x,a.length)}}).call(s.prototype)}),ace.define("ace/mode/json",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/json_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/cstyle","ace/worker/worker_client"],function(t,r,c){var h=t("../lib/oop"),g=t("./text").Mode,v=t("./json_highlight_rules").JsonHighlightRules,s=t("./matching_brace_outdent").MatchingBraceOutdent,p=t("./folding/cstyle").FoldMode,a=t("../worker/worker_client").WorkerClient,l=function(){this.HighlightRules=v,this.$outdent=new s,this.$behaviour=this.$defaultBehaviour,this.foldingRules=new p};h.inherits(l,g),(function(){this.lineCommentStart="//",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(u,d,o){var f=this.$getIndent(d);if(u=="start"){var m=d.match(/^.*[\{\(\[]\s*$/);m&&(f+=o)}return f},this.checkOutdent=function(u,d,o){return this.$outdent.checkOutdent(d,o)},this.autoOutdent=function(u,d,o){this.$outdent.autoOutdent(d,o)},this.createWorker=function(u){var d=new a(["ace"],"ace/mode/json_worker","JsonWorker");return d.attachToDocument(u.getDocument()),d.on("annotate",function(o){u.setAnnotations(o.data)}),d.on("terminate",function(){u.clearAnnotations()}),d},this.$id="ace/mode/json"}).call(l.prototype),r.Mode=l}),(function(){ace.require(["ace/mode/json"],function(t){e&&(e.exports=t)})})()})(ry)),ry.exports}iT();var oy={exports:{}},sy;function oT(){return sy||(sy=1,(function(e,n){ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"],function(t,r,c){var h=t("../lib/oop");t("../lib/lang");var g=t("./text_highlight_rules").TextHighlightRules,v=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",s=r.supportFunction="rgb|rgba|url|attr|counter|counters",p=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",u=r.numRe="\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))",d=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",f=function(){var m=this.createKeywordMapper({"support.function":s,"support.constant":p,"support.type":v,"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:u},{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:"("+u+")(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:u},{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:d},{token:["punctuation","entity.other.attribute-name.pseudo-class.css"],regex:o},{include:"url"},{token:m,regex:"\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"},{token:"paren.lparen",regex:"\\{"},{caseInsensitive:!0}],url:[{token:"support.function",regex:"(?:url(:?-prefix)?|domain|regexp)\\(",push:[{token:"support.function",regex:"\\)",next:"pop"},{defaultToken:"string"}]}],strings:[{token:"string.start",regex:"'",push:[{token:"string.end",regex:"'|$",next:"pop"},{include:"escapes"},{token:"constant.language.escape",regex:/\\$/,consumeLineEnd:!0},{defaultToken:"string"}]},{token:"string.start",regex:'"',push:[{token:"string.end",regex:'"|$',next:"pop"},{include:"escapes"},{token:"constant.language.escape",regex:/\\$/,consumeLineEnd:!0},{defaultToken:"string"}]}],escapes:[{token:"constant.language.escape",regex:/\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/}]},this.normalizeRules()};h.inherits(f,g),r.CssHighlightRules=f}),ace.define("ace/mode/jsdoc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,c){var h=t("../lib/oop"),g=t("./text_highlight_rules").TextHighlightRules,v=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|$)"},v.getTagRule(),{defaultToken:"comment.doc.body",caseInsensitive:!0}],"doc-syntax":[{token:"operator.doc",regex:/[|:]/},{token:"paren.doc",regex:/[\[\]]/}]},this.normalizeRules()};h.inherits(v,g),v.getTagRule=function(s){return{token:"comment.doc.tag.storage.type",regex:"\\b(?:TODO|FIXME|XXX|HACK)\\b"}},v.getStartRule=function(s){return{token:"comment.doc",regex:/\/\*\*(?!\/)/,next:s}},v.getEndRule=function(s){return{token:"comment.doc",regex:"\\*\\/",next:s}},r.JsDocCommentHighlightRules=v}),ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/jsdoc_comment_highlight_rules","ace/mode/text_highlight_rules"],function(t,r,c){function h(){var u=a.replace("\\d","\\d\\-"),d={onMatch:function(f,m,w){var x=f.charAt(1)=="/"?2:1;return x==1?(m!=this.nextState?w.unshift(this.next,this.nextState,0):w.unshift(this.next),w[2]++):x==2&&m==this.nextState&&(w[1]--,(!w[1]||w[1]<0)&&(w.shift(),w.shift())),[{type:"meta.tag.punctuation."+(x==1?"":"end-")+"tag-open.xml",value:f.slice(0,x)},{type:"meta.tag.tag-name.xml",value:f.substr(x)}]},regex:"</?(?:"+u+"|(?=>))",next:"jsxAttributes",nextState:"jsx"};this.$rules.start.unshift(d);var o={regex:"{",token:"paren.quasi.start",push:"start"};this.$rules.jsx=[o,d,{include:"reference"},{defaultToken:"string.xml"}],this.$rules.jsxAttributes=[{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",onMatch:function(f,m,w){return m==w[0]&&w.shift(),f.length==2&&(w[0]==this.nextState&&w[1]--,(!w[1]||w[1]<0)&&w.splice(0,2)),this.next=w[0]||"start",[{type:this.token,value:f}]},nextState:"jsx"},o,g("jsxAttributes"),{token:"entity.other.attribute-name.xml",regex:u},{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"}]},d],this.$rules.reference=[{token:"constant.language.escape.reference.xml",regex:"(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"}]}function g(u){return[{token:"comment",regex:/\/\*/,next:[s.getTagRule(),{token:"comment",regex:"\\*\\/",next:u||"pop"},{defaultToken:"comment",caseInsensitive:!0}]},{token:"comment",regex:"\\/\\/",next:[s.getTagRule(),{token:"comment",regex:"$|^",next:u||"pop"},{defaultToken:"comment",caseInsensitive:!0}]}]}var v=t("../lib/oop"),s=t("./jsdoc_comment_highlight_rules").JsDocCommentHighlightRules,p=t("./text_highlight_rules").TextHighlightRules,a="[a-zA-Z\\$_¡-￿][a-zA-Z\\d\\$_¡-￿]*",l=function(u){var d={"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(d,"identifier"),f="case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void",m="\\\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|u{[0-9a-fA-F]{1,6}}|[0-2][0-7]{0,2}|3[0-7][0-7]?|[4-7][0-7]?|.)",w="(function)(\\s*)(\\*?)",x={token:["identifier","text","paren.lparen"],regex:"(\\b(?!"+Object.values(d).join("|")+"\\b)"+a+")(\\s*)(\\()"};this.$rules={no_regex:[s.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*)"+w+"(\\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*)"+w+"(\\s*)(\\()",next:"function_arguments"},{token:["text","text","storage.type","text","storage.type","text","paren.lparen"],regex:"(:)(\\s*)"+w+"(\\s*)(\\()",next:"function_arguments"},{token:"keyword",regex:`from(?=\\s*('|"))`},{token:"keyword",regex:"(?:"+f+")\\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:w+"(\\s*)(\\()",next:"function_arguments"},{token:["storage.type","text","storage.type","text","text","entity.name.function","text","paren.lparen"],regex:"(function)(?:(?:(\\s*)(\\*)(\\s*))|(\\s+))(\\w+)(\\s*)(\\()",next:"function_arguments"},{token:"punctuation.operator",regex:/[.](?![.])/},{token:"support.function",regex:"prototype"},{token:"support.function",regex:/(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|lter|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward|rEach)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/},{token:"support.function.dom",regex:/(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/},{token:"support.constant",regex:/(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/},{token:"identifier",regex:a},{regex:"",token:"empty",next:"no_regex"}],start:[s.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:m},{token:"string",regex:"\\\\$",consumeLineEnd:!0},{token:"string",regex:'"|$',next:"no_regex"},{defaultToken:"string"}],qstring:[{token:"constant.language.escape",regex:m},{token:"string",regex:"\\\\$",consumeLineEnd:!0},{token:"string",regex:"'|$",next:"no_regex"},{defaultToken:"string"}],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)?/}]},(!u||!u.noES6)&&(this.$rules.no_regex.unshift({regex:"[{}]",onMatch:function(R,T,_){if(this.next=R=="{"?this.nextState:"",R=="{"&&_.length)_.unshift("start",T);else if(R=="}"&&_.length&&(_.shift(),this.next=_.shift(),this.next.indexOf("string")!=-1||this.next.indexOf("jsx")!=-1))return"paren.quasi.end";return R=="{"?"paren.lparen":"paren.rparen"},nextState:"start"},{token:"string.quasi.start",regex:/`/,push:[{token:"constant.language.escape",regex:m},{token:"paren.quasi.start",regex:/\${/,push:"start"},{token:"string.quasi.end",regex:/`/,next:"pop"},{defaultToken:"string.quasi"}]},{token:["variable.parameter","text"],regex:"("+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"}),(!u||u.jsx!=0)&&h.call(this)),this.embedRules(s,"doc-",[s.getEndRule("no_regex")]),this.normalizeRules()};v.inherits(l,p),r.JavaScriptHighlightRules=l}),ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,c){var h=t("../lib/oop"),g=t("./text_highlight_rules").TextHighlightRules,v=function(s){var p="[_: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:"(<\\?)("+p+")",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:p},{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:"(<\\!)("+p+")",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:"(?:(<)|(</))((?:"+p+":)?"+p+")",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:p},{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===v&&this.normalizeRules()};(function(){this.embedTagRules=function(s,p,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:p+"start"}]}),this.$rules[a+"-end"]=[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:"start",onMatch:function(l,u,d){return d.splice(0),this.token}}],this.embedRules(s,p,[{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),h.inherits(v,g),r.XmlHighlightRules=v}),ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"],function(t,r,c){var h=t("../lib/oop"),g=t("../lib/lang"),v=t("./css_highlight_rules").CssHighlightRules,s=t("./javascript_highlight_rules").JavaScriptHighlightRules,p=t("./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(){p.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(u,d){var o=a[d];return["meta.tag.punctuation."+(u=="<"?"":"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(v,"css-","style"),this.embedTagRules(new s({jsx:!1}).getRules(),"js-","script"),this.constructor===l&&this.normalizeRules()};h.inherits(l,p),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(t,r,c){var h=t("../config").$modes,g=t("../lib/oop"),v=t("../lib/lang"),s=t("./text_highlight_rules").TextHighlightRules,p=t("./html_highlight_rules").HtmlHighlightRules,a=function(u){return"(?:[^"+v.escapeRegExp(u)+"\\\\]|\\\\.)*"},l=function(){p.call(this);var u={token:"support.function",regex:/^\s*(```+[^`]*|~~~+[^~]*)$/,onMatch:function(o,f,m,w){var x=o.match(/^(\s*)([`~]+)(.*)/),R=/[\w-]+|$/.exec(x[3])[0];return h[R]||(R=""),m.unshift("githubblock",[],[x[1],x[2],R],f),this.token},next:"githubblock"},d=[{token:"support.function",regex:".*",onMatch:function(o,f,m,w){var x=m[1],R=m[2][0],T=m[2][1],_=m[2][2],C=/^(\s*)(`+|~+)\s*$/.exec(o);if(C&&C[1].length<R.length+3&&C[2].length>=T.length&&C[2][0]==T[0])return m.splice(0,3),this.next=m.shift(),this.token;if(this.next="",_&&h[_]){var P=h[_].getTokenizer().getLineTokens(o,x.slice(0));return m[1]=P.state,P.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"},u,{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},u,{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:d}),this.normalizeRules()};g.inherits(l,s),r.MarkdownHighlightRules=l}),ace.define("ace/mode/folding/markdown",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"],function(t,r,c){var h=t("../../lib/oop"),g=t("./fold_mode").FoldMode,v=t("../../range").Range,s=r.FoldMode=function(){};h.inherits(s,g),(function(){this.foldingStartMarker=/^(?:[=-]+\s*$|#{1,6} |`{3})/,this.getFoldWidget=function(p,a,l){var u=p.getLine(l);return this.foldingStartMarker.test(u)?u[0]=="`"&&p.bgTokenizer.getState(l)=="start"?"end":"start":""},this.getFoldWidgetRange=function(p,a,l){function u(O){return R=p.getTokens(O)[0],R&&R.type.lastIndexOf(T,0)===0}function d(){var O=R.value[0];return O=="="?6:O=="-"?5:7-R.value.search(/[^#]|$/)}var o=p.getLine(l),f=o.length,m=p.getLength(),w=l,x=l;if(o.match(this.foldingStartMarker)){if(o[0]=="`"){if(p.bgTokenizer.getState(l)!=="start"){for(;++l<m&&(o=p.getLine(l),!(o[0]=="`"&o.substring(0,3)=="```")););return new v(w,f,l,0)}for(;l-- >0&&(o=p.getLine(l),!(o[0]=="`"&o.substring(0,3)=="```")););return new v(l,o.length,w,0)}var R,T="markup.heading";if(u(l)){for(var _=d();++l<m;)if(u(l)){var C=d();if(C>=_)break}if(x=l-(!R||["=","-"].indexOf(R.value[0])==-1?1:2),x>w)for(;x>w&&/^\s*$/.test(p.getLine(x));)x--;if(x>w){var P=p.getLine(x).length;return new v(w,f,x,P)}}}}}).call(s.prototype)}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(t,r,c){var h=t("../range").Range,g=function(){};(function(){this.checkOutdent=function(v,s){return/^\s+$/.test(v)?/^\s*\}/.test(s):!1},this.autoOutdent=function(v,s){var p=v.getLine(s),a=p.match(/^(\s*\})/);if(!a)return 0;var l=a[1].length,u=v.findMatchingBracket({row:s,column:l});if(!u||u.row==s)return 0;var d=this.$getIndent(v.getLine(u.row));v.replace(new h(s,0,s,l-1),d)},this.$getIndent=function(v){return v.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(t,r,c){function h(a,l){return a&&a.type.lastIndexOf(l+".xml")>-1}var g=t("../../lib/oop"),v=t("../behaviour").Behaviour,s=t("../../token_iterator").TokenIterator,p=function(){this.add("string_dquotes","insertion",function(a,l,u,d,o){if(o=='"'||o=="'"){var f=o,m=d.doc.getTextRange(u.getSelectionRange());if(m!==""&&m!=="'"&&m!='"'&&u.getWrapBehavioursEnabled())return{text:f+m+f,selection:!1};var w=u.getCursorPosition(),x=d.doc.getLine(w.row),R=x.substring(w.column,w.column+1),T=new s(d,w.row,w.column),_=T.getCurrentToken();if(R==f&&(h(_,"attribute-value")||h(_,"string")))return{text:"",selection:[1,1]};if(_||(_=T.stepBackward()),!_)return;for(;h(_,"tag-whitespace")||h(_,"whitespace");)_=T.stepBackward();var C=!R||R.match(/\s/);if(h(_,"attribute-equals")&&(C||R==">")||h(_,"decl-attribute-equals")&&(C||R=="?"))return{text:f+f,selection:[1,1]}}}),this.add("string_dquotes","deletion",function(a,l,u,d,o){var f=d.doc.getTextRange(o);if(!o.isMultiLine()&&(f=='"'||f=="'")){var m=d.doc.getLine(o.start.row),w=m.substring(o.start.column+1,o.start.column+2);if(w==f)return o.end.column++,o}}),this.add("autoclosing","insertion",function(a,l,u,d,o){if(o==">"){var f=u.getSelectionRange().start,m=new s(d,f.row,f.column),w=m.getCurrentToken()||m.stepBackward();if(!w||!(h(w,"tag-name")||h(w,"tag-whitespace")||h(w,"attribute-name")||h(w,"attribute-equals")||h(w,"attribute-value"))||h(w,"reference.attribute-value"))return;if(h(w,"attribute-value")){var x=m.getCurrentTokenColumn()+w.value.length;if(f.column<x)return;if(f.column==x){var R=m.stepForward();if(R&&h(R,"attribute-value"))return;m.stepBackward()}}if(/^\s*>/.test(d.getLine(f.row).slice(f.column)))return;for(;!h(w,"tag-name");)if(w=m.stepBackward(),w.value=="<"){w=m.stepForward();break}var T=m.getCurrentTokenRow(),_=m.getCurrentTokenColumn();if(h(m.stepBackward(),"end-tag-open"))return;var C=w.value;return T==f.row&&(C=C.substring(0,f.column-_)),this.voidElements&&this.voidElements.hasOwnProperty(C.toLowerCase())?void 0:{text:"></"+C+">",selection:[1,1]}}}),this.add("autoindent","insertion",function(a,l,u,d,o){if(o==`
991
+ `){var f=u.getCursorPosition(),m=d.getLine(f.row),w=new s(d,f.row,f.column),x=w.getCurrentToken();if(h(x,"")&&x.type.indexOf("tag-close")!==-1){if(x.value=="/>")return;for(;x&&x.type.indexOf("tag-name")===-1;)x=w.stepBackward();if(!x)return;var R=x.value,T=w.getCurrentTokenRow();if(x=w.stepBackward(),!x||x.type.indexOf("end-tag")!==-1)return;if(this.voidElements&&!this.voidElements[R]||!this.voidElements){var _=d.getTokenAt(f.row,f.column+1),m=d.getLine(T),C=this.$getIndent(m),P=C+d.getTabString();return _&&_.value==="</"?{text:`
992
+ `+P+`
993
+ `+C,selection:[1,P.length,1,P.length]}:{text:`
994
+ `+P}}}}})};g.inherits(p,v),r.XmlBehaviour=p}),ace.define("ace/mode/behaviour/javascript",["require","exports","module","ace/lib/oop","ace/token_iterator","ace/mode/behaviour/cstyle","ace/mode/behaviour/xml"],function(t,r,c){var h=t("../../lib/oop"),g=t("../../token_iterator").TokenIterator,v=t("../behaviour/cstyle").CstyleBehaviour,s=t("../behaviour/xml").XmlBehaviour,p=function(){var a=new s({closeCurlyBraces:!0}).getBehaviours();this.addBehaviours(a),this.inherit(v),this.add("autoclosing-fragment","insertion",function(l,u,d,o,f){if(f==">"){var m=d.getSelectionRange().start,w=new g(o,m.row,m.column),x=w.getCurrentToken()||w.stepBackward();if(!x)return;if(x.value=="<")return{text:"></>",selection:[1,1]}}})};h.inherits(p,v),r.JavaScriptBehaviour=p}),ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(t,r,c){function h(l,u){return l&&l.type&&l.type.lastIndexOf(u+".xml")>-1}var g=t("../../lib/oop"),v=t("../../range").Range,s=t("./fold_mode").FoldMode,p=r.FoldMode=function(l,u){s.call(this),this.voidElements=l||{},this.optionalEndTags=g.mixin({},this.voidElements),u&&g.mixin(this.optionalEndTags,u)};g.inherits(p,s);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,u,d){var o=this._getFirstTagInLine(l,d);return o?o.closing||!o.tagName&&o.selfClosing?u==="markbeginend"?"end":"":!o.tagName||o.selfClosing||this.voidElements.hasOwnProperty(o.tagName.toLowerCase())||this._findEndTagInLine(l,d,o.tagName,o.end.column)?"":"start":this.getCommentFoldWidget(l,d)},this.getCommentFoldWidget=function(l,u){return/comment/.test(l.getState(u))&&/<!-/.test(l.getLine(u))?"start":""},this._getFirstTagInLine=function(l,u){for(var d=l.getTokens(u),o=new a,f=0;f<d.length;f++){var m=d[f];if(h(m,"tag-open")){if(o.end.column=o.start.column+m.value.length,o.closing=h(m,"end-tag-open"),m=d[++f],!m)return null;if(o.tagName=m.value,m.value===""){if(m=d[++f],!m)return null;o.tagName=m.value}for(o.end.column+=m.value.length,f++;f<d.length;f++)if(m=d[f],o.end.column+=m.value.length,h(m,"tag-close")){o.selfClosing=m.value=="/>";break}return o}if(h(m,"tag-close"))return o.selfClosing=m.value=="/>",o;o.start.column+=m.value.length}return null},this._findEndTagInLine=function(l,u,d,o){for(var f=l.getTokens(u),m=0,w=0;w<f.length;w++){var x=f[w];if(m+=x.value.length,!(m<o-1)&&h(x,"end-tag-open")&&(x=f[w+1],h(x,"tag-name")&&x.value===""&&(x=f[w+2]),x&&x.value==d))return!0}return!1},this.getFoldWidgetRange=function(l,u,d){var o=this._getFirstTagInLine(l,d);if(!o)return this.getCommentFoldWidget(l,d)&&l.getCommentFoldRange(d,l.getLine(d).length);var f=l.getMatchingTags({row:d,column:0});if(f){var m=f.openTag.start.row;return new v(m,l.getLine(m).length,f.closeTag.start.row,f.closeTag.start.column)}}}).call(p.prototype)}),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(t,r,c){var h=t("../../lib/oop"),g=t("../../range").Range,v=t("./fold_mode").FoldMode,s=r.FoldMode=function(p){p&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+p.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+p.end)))};h.inherits(s,v),(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(p,a,l){var u=p.getLine(l);if(this.singleLineBlockCommentRe.test(u)&&!this.startRegionRe.test(u)&&!this.tripleStarBlockCommentRe.test(u))return"";var d=this._getFoldWidgetBase(p,a,l);return!d&&this.startRegionRe.test(u)?"start":d},this.getFoldWidgetRange=function(p,a,l,u){var d=p.getLine(l);if(this.startRegionRe.test(d))return this.getCommentRegionBlock(p,d,l);var o=d.match(this.foldingStartMarker);if(o){var f=o.index;if(o[1])return this.openingBracketBlock(p,o[1],l,f);var m=p.getCommentFoldRange(l,f+o[0].length,1);return m&&!m.isMultiLine()&&(u?m=this.getSectionRange(p,l):a!="all"&&(m=null)),m}if(a!=="markbegin"){var o=d.match(this.foldingStopMarker);if(o){var f=o.index+o[0].length;return o[1]?this.closingBracketBlock(p,o[1],l,f):p.getCommentFoldRange(l,f,-1)}}},this.getSectionRange=function(p,a){var l=p.getLine(a),u=l.search(/\S/),d=a,o=l.length;a+=1;for(var f=a,m=p.getLength();++a<m;){l=p.getLine(a);var w=l.search(/\S/);if(w!==-1){if(u>w)break;var x=this.getFoldWidgetRange(p,"all",a);if(x){if(x.start.row<=d)break;if(x.isMultiLine())a=x.end.row;else if(u==w)break}f=a}}return new g(d,o,f,p.getLine(f).length)},this.getCommentRegionBlock=function(p,a,l){for(var u=a.search(/\s*$/),d=p.getLength(),o=l,f=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,m=1;++l<d;){a=p.getLine(l);var w=f.exec(a);if(w&&(w[1]?m--:m++,!m))break}var x=l;if(x>o)return new g(o,u,x,a.length)}}).call(s.prototype)}),ace.define("ace/mode/folding/javascript",["require","exports","module","ace/lib/oop","ace/mode/folding/xml","ace/mode/folding/cstyle"],function(t,r,c){var h=t("../../lib/oop"),g=t("./xml").FoldMode,v=t("./cstyle").FoldMode,s=r.FoldMode=function(p){p&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+p.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+p.end))),this.xmlFoldMode=new g};h.inherits(s,v),(function(){this.getFoldWidgetRangeBase=this.getFoldWidgetRange,this.getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(p,a,l){var u=this.getFoldWidgetBase(p,a,l);return u||this.xmlFoldMode.getFoldWidget(p,a,l)},this.getFoldWidgetRange=function(p,a,l,u){var d=this.getFoldWidgetRangeBase(p,a,l,u);return d||this.xmlFoldMode.getFoldWidgetRange(p,a,l)}}).call(s.prototype)}),ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/javascript","ace/mode/folding/javascript"],function(t,r,c){var h=t("../lib/oop"),g=t("./text").Mode,v=t("./javascript_highlight_rules").JavaScriptHighlightRules,s=t("./matching_brace_outdent").MatchingBraceOutdent,p=t("../worker/worker_client").WorkerClient,a=t("./behaviour/javascript").JavaScriptBehaviour,l=t("./folding/javascript").FoldMode,u=function(){this.HighlightRules=v,this.$outdent=new s,this.$behaviour=new a,this.foldingRules=new l};h.inherits(u,g),(function(){this.lineCommentStart="//",this.blockComment={start:"/*",end:"*/"},this.$quotes={'"':'"',"'":"'","`":"`"},this.$pairQuotesAfter={"`":/\w/},this.getNextLineIndent=function(d,o,f){var m=this.$getIndent(o),w=this.getTokenizer().getLineTokens(o,d),x=w.tokens,R=w.state;if(x.length&&x[x.length-1].type=="comment")return m;if(d=="start"||d=="no_regex"){var T=o.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);T&&(m+=f)}else if(d=="doc-start"&&(R=="start"||R=="no_regex"))return"";return m},this.checkOutdent=function(d,o,f){return this.$outdent.checkOutdent(o,f)},this.autoOutdent=function(d,o,f){this.$outdent.autoOutdent(o,f)},this.createWorker=function(d){var o=new p(["ace"],"ace/mode/javascript_worker","JavaScriptWorker");return o.attachToDocument(d.getDocument()),o.on("annotate",function(f){d.setAnnotations(f.data)}),o.on("terminate",function(){d.clearAnnotations()}),o},this.$id="ace/mode/javascript",this.snippetFileId="ace/snippets/javascript"}).call(u.prototype),r.Mode=u}),ace.define("ace/mode/css_completions",["require","exports","module"],function(t,r,c){var h={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 v=document.createElement("c").style;for(var s in v)if(typeof v[s]=="string"){var p=s.replace(/[A-Z]/g,function(a){return"-"+a.toLowerCase()});h.hasOwnProperty(p)||(h[p]=1)}}this.completionsDefined=!0},this.getCompletions=function(v,s,p,a){if(this.completionsDefined||this.defineCompletions(),v==="ruleset"||s.$mode.$id=="ace/mode/scss"){var l=s.getLine(p.row).substr(0,p.column),u=/\([^)]*$/.test(l);return u&&(l=l.substr(l.lastIndexOf("(")+1)),/:[^;]+$/.test(l)?this.getPropertyValueCompletions(v,s,p,a):this.getPropertyCompletions(v,s,p,a,u)}return[]},this.getPropertyCompletions=function(v,s,p,a,l){l=l||!1;var u=Object.keys(h);return u.map(function(d){return{caption:d,snippet:d+": $0"+(l?"":";"),meta:"property",score:1e6}})},this.getPropertyValueCompletions=function(v,s,p,a){var l=s.getLine(p.row).substr(0,p.column),u=(/([\w\-]+):[^:]*$/.exec(l)||{})[1];if(!u)return[];var d=[];return u in h&&typeof h[u]=="object"&&(d=Object.keys(h[u])),d.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(t,r,c){var h=t("../../lib/oop");t("../behaviour").Behaviour;var g=t("./cstyle").CstyleBehaviour,v=t("../../token_iterator").TokenIterator,s=function(){this.inherit(g),this.add("colon","insertion",function(p,a,l,u,d){if(d===":"&&l.selection.isEmpty()){var o=l.getCursorPosition(),f=new v(u,o.row,o.column),m=f.getCurrentToken();if(m&&m.value.match(/\s+/)&&(m=f.stepBackward()),m&&m.type==="support.type"){var w=u.doc.getLine(o.row),x=w.substring(o.column,o.column+1);if(x===":")return{text:"",selection:[1,1]};if(/^(\s+[^;]|\s*$)/.test(w.substring(o.column)))return{text:":;",selection:[1,1]}}}}),this.add("colon","deletion",function(p,a,l,u,d){var o=u.doc.getTextRange(d);if(!d.isMultiLine()&&o===":"){var f=l.getCursorPosition(),m=new v(u,f.row,f.column),w=m.getCurrentToken();if(w&&w.value.match(/\s+/)&&(w=m.stepBackward()),w&&w.type==="support.type"){var x=u.doc.getLine(d.start.row),R=x.substring(d.end.column,d.end.column+1);if(R===";")return d.end.column++,d}}}),this.add("semicolon","insertion",function(p,a,l,u,d){if(d===";"&&l.selection.isEmpty()){var o=l.getCursorPosition(),f=u.doc.getLine(o.row),m=f.substring(o.column,o.column+1);if(m===";")return{text:"",selection:[1,1]}}}),this.add("!important","insertion",function(p,a,l,u,d){if(d==="!"&&l.selection.isEmpty()){var o=l.getCursorPosition(),f=u.doc.getLine(o.row);if(/^\s*(;|}|$)/.test(f.substring(o.column)))return{text:"!important",selection:[10,10]}}})};h.inherits(s,g),r.CssBehaviour=s}),ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"],function(t,r,c){var h=t("../lib/oop"),g=t("./text").Mode,v=t("./css_highlight_rules").CssHighlightRules,s=t("./matching_brace_outdent").MatchingBraceOutdent,p=t("../worker/worker_client").WorkerClient,a=t("./css_completions").CssCompletions,l=t("./behaviour/css").CssBehaviour,u=t("./folding/cstyle").FoldMode,d=function(){this.HighlightRules=v,this.$outdent=new s,this.$behaviour=new l,this.$completer=new a,this.foldingRules=new u};h.inherits(d,g),(function(){this.foldingRules="cStyle",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(o,f,m){var w=this.$getIndent(f),x=this.getTokenizer().getLineTokens(f,o).tokens;if(x.length&&x[x.length-1].type=="comment")return w;var R=f.match(/^.*\{\s*$/);return R&&(w+=m),w},this.checkOutdent=function(o,f,m){return this.$outdent.checkOutdent(f,m)},this.autoOutdent=function(o,f,m){this.$outdent.autoOutdent(f,m)},this.getCompletions=function(o,f,m,w){return this.$completer.getCompletions(o,f,m,w)},this.createWorker=function(o){var f=new p(["ace"],"ace/mode/css_worker","Worker");return f.attachToDocument(o.getDocument()),f.on("annotate",function(m){o.setAnnotations(m.data)}),f.on("terminate",function(){o.clearAnnotations()}),f},this.$id="ace/mode/css",this.snippetFileId="ace/snippets/css"}).call(d.prototype),r.Mode=d}),ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"],function(t,r,c){var h=t("../../lib/oop"),g=t("./fold_mode").FoldMode,v=r.FoldMode=function(s,p){this.defaultMode=s,this.subModes=p};h.inherits(v,g),(function(){this.$getMode=function(s){typeof s!="string"&&(s=s[0]);for(var p in this.subModes)if(s.indexOf(p)===0)return this.subModes[p];return null},this.$tryMode=function(s,p,a,l){var u=this.$getMode(s);return u?u.getFoldWidget(p,a,l):""},this.getFoldWidget=function(s,p,a){return this.$tryMode(s.getState(a-1),s,p,a)||this.$tryMode(s.getState(a),s,p,a)||this.defaultMode.getFoldWidget(s,p,a)},this.getFoldWidgetRange=function(s,p,a){var l=this.$getMode(s.getState(a-1));return(!l||!l.getFoldWidget(s,p,a))&&(l=this.$getMode(s.getState(a))),(!l||!l.getFoldWidget(s,p,a))&&(l=this.defaultMode),l.getFoldWidgetRange(s,p,a)}}).call(v.prototype)}),ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"],function(t,r,c){var h=t("../../lib/oop"),g=t("./mixed").FoldMode,v=t("./xml").FoldMode,s=t("./cstyle").FoldMode,p=r.FoldMode=function(a,l){g.call(this,new v(a,l),{"js-":new s,"css-":new s})};h.inherits(p,g)}),ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"],function(t,r,c){function h(f,m){return f.type.lastIndexOf(m+".xml")>-1}function g(f,m){for(var w=new s(f,m.row,m.column),x=w.getCurrentToken();x&&!h(x,"tag-name");)x=w.stepBackward();if(x)return x.value}function v(f,m){for(var w=new s(f,m.row,m.column),x=w.getCurrentToken();x&&!h(x,"attribute-name");)x=w.stepBackward();if(x)return x.value}var s=t("../token_iterator").TokenIterator,p=["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=p.concat(a),u={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:{}},d=Object.keys(u),o=function(){};(function(){this.getCompletions=function(f,m,w,x){var R=m.getTokenAt(w.row,w.column);if(!R)return[];if(h(R,"tag-name")||h(R,"tag-open")||h(R,"end-tag-open"))return this.getTagCompletions(f,m,w,x);if(h(R,"tag-whitespace")||h(R,"attribute-name"))return this.getAttributeCompletions(f,m,w,x);if(h(R,"attribute-value"))return this.getAttributeValueCompletions(f,m,w,x);var T=m.getLine(w.row).substr(0,w.column);return/&[a-z]*$/i.test(T)?this.getHTMLEntityCompletions(f,m,w,x):[]},this.getTagCompletions=function(f,m,w,x){return d.map(function(R){return{value:R,meta:"tag",score:1e6}})},this.getAttributeCompletions=function(f,m,w,x){var R=g(m,w);if(!R)return[];var T=l;return R in u&&(T=T.concat(Object.keys(u[R]))),T.map(function(_){return{caption:_,snippet:_+'="$0"',meta:"attribute",score:1e6}})},this.getAttributeValueCompletions=function(f,m,w,x){var R=g(m,w),T=v(m,w);if(!R)return[];var _=[];return R in u&&T in u[R]&&typeof u[R][T]=="object"&&(_=Object.keys(u[R][T])),_.map(function(C){return{caption:C,snippet:C,meta:"attribute value",score:1e6}})},this.getHTMLEntityCompletions=function(f,m,w,x){var R=["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 R.map(function(T){return{caption:T,snippet:T,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(t,r,c){var h=t("../lib/oop"),g=t("../lib/lang"),v=t("./text").Mode,s=t("./javascript").Mode,p=t("./css").Mode,a=t("./html_highlight_rules").HtmlHighlightRules,l=t("./behaviour/xml").XmlBehaviour,u=t("./folding/html").FoldMode,d=t("./html_completions").HtmlCompletions,o=t("../worker/worker_client").WorkerClient,f=["area","base","br","col","embed","hr","img","input","keygen","link","meta","menuitem","param","source","track","wbr"],m=["li","dt","dd","p","rt","rp","optgroup","option","colgroup","td","th"],w=function(x){this.fragmentContext=x&&x.fragmentContext,this.HighlightRules=a,this.$behaviour=new l,this.$completer=new d,this.createModeDelegates({"js-":s,"css-":p}),this.foldingRules=new u(this.voidElements,g.arrayToMap(m))};h.inherits(w,v),(function(){this.blockComment={start:"<!--",end:"-->"},this.voidElements=g.arrayToMap(f),this.getNextLineIndent=function(x,R,T){return this.$getIndent(R)},this.checkOutdent=function(x,R,T){return!1},this.getCompletions=function(x,R,T,_){return this.$completer.getCompletions(x,R,T,_)},this.createWorker=function(x){if(this.constructor==w){var R=new o(["ace"],"ace/mode/html_worker","Worker");return R.attachToDocument(x.getDocument()),this.fragmentContext&&R.call("setOptions",[{context:this.fragmentContext}]),R.on("error",function(T){x.setAnnotations(T.data)}),R.on("terminate",function(){x.clearAnnotations()}),R}},this.$id="ace/mode/html",this.snippetFileId="ace/snippets/html"}).call(w.prototype),r.Mode=w}),ace.define("ace/mode/sh_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(t,r,c){var h=t("../lib/oop"),g=t("./text_highlight_rules").TextHighlightRules,v=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",s=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",p=function(){var a=this.createKeywordMapper({keyword:v,"support.function.builtin":s,"invalid.deprecated":"debugger"},"identifier"),l="(?:(?:[1-9]\\d*)|(?:0))",u="(?:\\.\\d+)",d="(?:\\d+)",o="(?:(?:"+d+"?"+u+")|(?:"+d+"\\.))",f="(?:(?:"+o+"|"+d+"))",m="(?:"+f+"|"+o+")",w="(?:&"+d+")",x="[a-zA-Z_][a-zA-Z0-9_]*",R="(?:"+x+"(?==))",T="(?:\\$(?:SHLVL|\\$|\\!|\\?))",_="(?:"+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,P,O){var E=C[2]=="-"?"indentedHeredoc":"heredoc",k=C.split(this.splitRegex);return O.push(E,k[4]),[{type:"constant",value:k[1]},{type:"text",value:k[2]},{type:"string",value:k[3]},{type:"support.class",value:k[4]},{type:"string",value:k[5]}]},rules:{heredoc:[{onMatch:function(C,P,O){return C===O[1]?(O.shift(),O.shift(),this.next=O[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}],indentedHeredoc:[{token:"string",regex:"^ +"},{onMatch:function(C,P,O){return C===O[1]?(O.shift(),O.shift(),this.next=O[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}]}},{regex:"$",token:"empty",next:function(C,P){return P[0]==="heredoc"||P[0]==="indentedHeredoc"?P[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:T},{token:"variable",regex:R},{include:"variables"},{token:"support.function",regex:_},{token:"support.function",regex:w},{token:"string",start:"'",end:"'"},{token:"constant.numeric",regex:m},{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()};h.inherits(p,g),r.ShHighlightRules=p}),ace.define("ace/mode/sh",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sh_highlight_rules","ace/range","ace/mode/folding/cstyle"],function(t,r,c){var h=t("../lib/oop"),g=t("./text").Mode,v=t("./sh_highlight_rules").ShHighlightRules,s=t("../range").Range,p=t("./folding/cstyle").FoldMode,a=function(){this.HighlightRules=v,this.foldingRules=new p,this.$behaviour=this.$defaultBehaviour};h.inherits(a,g),(function(){this.lineCommentStart="#",this.getNextLineIndent=function(u,d,o){var f=this.$getIndent(d),m=this.getTokenizer().getLineTokens(d,u),w=m.tokens;if(w.length&&w[w.length-1].type=="comment")return f;if(u=="start"){var x=d.match(/^.*[\{\(\[:]\s*$/);x&&(f+=o)}return f};var l={pass:1,return:1,raise:1,break:1,continue:1};this.checkOutdent=function(u,d,o){if(o!==`\r
995
+ `&&o!=="\r"&&o!==`
996
+ `)return!1;var f=this.getTokenizer().getLineTokens(d.trim(),u).tokens;if(!f)return!1;do var m=f.pop();while(m&&(m.type=="comment"||m.type=="text"&&m.value.match(/^\s+$/)));return m?m.type=="keyword"&&l[m.value]:!1},this.autoOutdent=function(u,d,o){o+=1;var f=this.$getIndent(d.getLine(o)),m=d.getTabString();f.slice(-m.length)==m&&d.remove(new s(o,f.length-m.length,o,f.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(t,r,c){var h=t("../lib/oop"),g=t("../lib/lang"),v=t("./text").Mode,s=t("./xml_highlight_rules").XmlHighlightRules,p=t("./behaviour/xml").XmlBehaviour,a=t("./folding/xml").FoldMode,l=t("../worker/worker_client").WorkerClient,u=function(){this.HighlightRules=s,this.$behaviour=new p,this.foldingRules=new a};h.inherits(u,v),(function(){this.voidElements=g.arrayToMap([]),this.blockComment={start:"<!--",end:"-->"},this.createWorker=function(d){var o=new l(["ace"],"ace/mode/xml_worker","Worker");return o.attachToDocument(d.getDocument()),o.on("error",function(f){d.setAnnotations(f.data)}),o.on("terminate",function(){d.clearAnnotations()}),o},this.$id="ace/mode/xml"}).call(u.prototype),r.Mode=u}),ace.define("ace/mode/markdown",["require","exports","module","ace/lib/oop","ace/mode/behaviour/cstyle","ace/mode/text","ace/mode/markdown_highlight_rules","ace/mode/folding/markdown","ace/mode/javascript","ace/mode/html","ace/mode/sh","ace/mode/sh","ace/mode/xml","ace/mode/css"],function(t,r,c){var h=t("../lib/oop"),g=t("./behaviour/cstyle").CstyleBehaviour,v=t("./text").Mode,s=t("./markdown_highlight_rules").MarkdownHighlightRules,p=t("./folding/markdown").FoldMode,a=function(){this.HighlightRules=s,this.createModeDelegates({javascript:t("./javascript").Mode,html:t("./html").Mode,bash:t("./sh").Mode,sh:t("./sh").Mode,xml:t("./xml").Mode,css:t("./css").Mode}),this.foldingRules=new p,this.$behaviour=new g({braces:!0})};h.inherits(a,v),(function(){this.type="text",this.blockComment={start:"<!--",end:"-->"},this.$quotes={'"':'"',"`":"`"},this.getNextLineIndent=function(l,u,d){if(l=="listblock"){var o=/^(\s*)(?:([-+*])|(\d+)\.)(\s+)/.exec(u);if(!o)return"";var f=o[2];return f||(f=parseInt(o[3],10)+1+"."),o[1]+f+o[4]}return this.$getIndent(u)},this.$id="ace/mode/markdown",this.snippetFileId="ace/snippets/markdown"}).call(a.prototype),r.Mode=a}),(function(){ace.require(["ace/mode/markdown"],function(t){e&&(e.exports=t)})})()})(oy)),oy.exports}oT();var ay={exports:{}},ly;function sT(){return ly||(ly=1,(function(e,n){ace.define("ace/theme/twilight-css",["require","exports","module"],function(t,r,c){c.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(t,r,c){r.isDark=!0,r.cssClass="ace-twilight",r.cssText=t("./twilight-css");var h=t("../lib/dom");h.importCssString(r.cssText,r.cssClass,!1)}),(function(){ace.require(["ace/theme/twilight"],function(t){e&&(e.exports=t)})})()})(ay)),ay.exports}sT();var cy={exports:{}},uy;function aT(){return uy||(uy=1,(function(e,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(t,r,c){function h(C){var P=new Date().toLocaleString("en-us",C);return P.length==1?"0"+P:P}var g=t("./lib/dom"),v=t("./lib/oop"),s=t("./lib/event_emitter").EventEmitter,p=t("./lib/lang"),a=t("./range").Range,l=t("./range_list").RangeList,u=t("./keyboard/hash_handler").HashHandler,d=t("./tokenizer").Tokenizer,o=t("./clipboard"),f={CURRENT_WORD:function(C){return C.session.getTextRange(C.session.getWordRange())},SELECTION:function(C,P,O){var E=C.session.getTextRange();return O?E.replace(/\n\r?([ \t]*\S)/g,`
1127
+ `+O+"$1"):E},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 P=C.session.$mode||{};return P.blockComment&&P.blockComment.start||""},BLOCK_COMMENT_END:function(C){var P=C.session.$mode||{};return P.blockComment&&P.blockComment.end||""},LINE_COMMENT:function(C){var P=C.session.$mode||{};return P.lineCommentStart||""},CURRENT_YEAR:h.bind(null,{year:"numeric"}),CURRENT_YEAR_SHORT:h.bind(null,{year:"2-digit"}),CURRENT_MONTH:h.bind(null,{month:"numeric"}),CURRENT_MONTH_NAME:h.bind(null,{month:"long"}),CURRENT_MONTH_NAME_SHORT:h.bind(null,{month:"short"}),CURRENT_DATE:h.bind(null,{day:"2-digit"}),CURRENT_DAY_NAME:h.bind(null,{weekday:"long"}),CURRENT_DAY_NAME_SHORT:h.bind(null,{weekday:"short"}),CURRENT_HOUR:h.bind(null,{hour:"2-digit",hour12:!1}),CURRENT_MINUTE:h.bind(null,{minute:"2-digit"}),CURRENT_SECOND:h.bind(null,{second:"2-digit"})};f.SELECTED_TEXT=f.SELECTION;var m=(function(){function C(){this.snippetMap={},this.snippetNameMap={},this.variables=f}return C.prototype.getTokenizer=function(){return C.$tokenizer||this.createTokenizer()},C.prototype.createTokenizer=function(){function P(k){return k=k.substr(1),/^\d+$/.test(k)?[{tabstopId:parseInt(k,10)}]:[{text:k}]}function O(k){return"(?:[^\\\\"+k+"]|\\\\.)"}var E={regex:"/("+O("/")+"+)/",onMatch:function(k,B,N){var M=N[0];return M.fmtString=!0,M.guard=k.slice(1,-1),M.flag="",""},next:"formatString"};return C.$tokenizer=new d({start:[{regex:/\\./,onMatch:function(k,B,N){var M=k[1];return(M=="}"&&N.length||"`$\\".indexOf(M)!=-1)&&(k=M),[k]}},{regex:/}/,onMatch:function(k,B,N){return[N.length?N.shift():k]}},{regex:/\$(?:\d+|\w+)/,onMatch:P},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(k,B,N){var M=P(k.substr(1));return N.unshift(M[0]),M},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+O("\\|")+"*\\|",onMatch:function(k,B,N){var M=k.slice(1,-1).replace(/\\[,|\\]|,/g,function($){return $.length==2?$[1]:"\0"}).split("\0").map(function($){return{value:$}});return N[0].choices=M,[M[0]]},next:"start"},E,{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:/:/,onMatch:function(k,B,N){return N.length&&N[0].expectElse?(N[0].expectElse=!1,N[0].ifEnd={elseEnd:N[0]},[N[0].ifEnd]):":"}},{regex:/\\./,onMatch:function(k,B,N){var M=k[1];return M=="}"&&N.length||"`$\\".indexOf(M)!=-1?k=M:M=="n"?k=`
1128
+ `:M=="t"?k=" ":"ulULE".indexOf(M)!=-1&&(k={changeCase:M,local:M>"a"}),[k]}},{regex:"/\\w*}",onMatch:function(k,B,N){var M=N.shift();return M&&(M.flag=k.slice(1,-1)),this.next=M&&M.tabstopId?"start":"",[M||k]},next:"start"},{regex:/\$(?:\d+|\w+)/,onMatch:function(k,B,N){return[{text:k.slice(1)}]}},{regex:/\${\w+/,onMatch:function(k,B,N){var M={text:k.slice(2)};return N.unshift(M),[M]},next:"formatStringVar"},{regex:/\n/,token:"newline",merge:!1},{regex:/}/,onMatch:function(k,B,N){var M=N.shift();return this.next=M&&M.tabstopId?"start":"",[M||k]},next:"start"}],formatStringVar:[{regex:/:\/\w+}/,onMatch:function(k,B,N){var M=N[0];return M.formatFunction=k.slice(2,-1),[N.shift()]},next:"formatString"},E,{regex:/:[\?\-+]?/,onMatch:function(k,B,N){k[1]=="+"&&(N[0].ifEnd=N[0]),k[1]=="?"&&(N[0].expectElse=!0)},next:"formatString"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"formatString"}]}),C.$tokenizer},C.prototype.tokenizeTmSnippet=function(P,O){return this.getTokenizer().getLineTokens(P,O).tokens.map(function(E){return E.value||E})},C.prototype.getVariableValue=function(P,O,E){if(/^\d+$/.test(O))return(this.variables.__||{})[O]||"";if(/^[A-Z]\d+$/.test(O))return(this.variables[O[0]+"__"]||{})[O.substr(1)]||"";if(O=O.replace(/^TM_/,""),!this.variables.hasOwnProperty(O))return"";var k=this.variables[O];return typeof k=="function"&&(k=this.variables[O](P,O,E)),k??""},C.prototype.tmStrFormat=function(P,O,E){if(!O.fmt)return P;var k=O.flag||"",B=O.guard;B=new RegExp(B,k.replace(/[^gim]/g,""));var N=typeof O.fmt=="string"?this.tokenizeTmSnippet(O.fmt,"formatString"):O.fmt,M=this,$=P.replace(B,function(){var A=M.variables.__;M.variables.__=[].slice.call(arguments);for(var D=M.resolveVariables(N,E),j="E",U=0;U<D.length;U++){var q=D[U];if(typeof q=="object")if(D[U]="",q.changeCase&&q.local){var Q=D[U+1];Q&&typeof Q=="string"&&(q.changeCase=="u"?D[U]=Q[0].toUpperCase():D[U]=Q[0].toLowerCase(),D[U+1]=Q.substr(1))}else q.changeCase&&(j=q.changeCase);else j=="U"?D[U]=q.toUpperCase():j=="L"&&(D[U]=q.toLowerCase())}return M.variables.__=A,D.join("")});return $},C.prototype.tmFormatFunction=function(P,O,E){return O.formatFunction=="upcase"?P.toUpperCase():O.formatFunction=="downcase"?P.toLowerCase():P},C.prototype.resolveVariables=function(P,O){function E(j){var U=P.indexOf(j,M+1);U!=-1&&(M=U)}for(var k=[],B="",N=!0,M=0;M<P.length;M++){var $=P[M];if(typeof $=="string"){k.push($),$==`
1129
+ `?(N=!0,B=""):N&&(B=/^\t*/.exec($)[0],N=/\S/.test($));continue}if($){if(N=!1,$.fmtString){var A=P.indexOf($,M+1);A==-1&&(A=P.length),$.fmt=P.slice(M+1,A),M=A}if($.text){var D=this.getVariableValue(O,$.text,B)+"";$.fmtString&&(D=this.tmStrFormat(D,$,O)),$.formatFunction&&(D=this.tmFormatFunction(D,$,O)),D&&!$.ifEnd?(k.push(D),E($)):!D&&$.ifEnd&&E($.ifEnd)}else $.elseEnd?E($.elseEnd):($.tabstopId!=null||$.changeCase!=null)&&k.push($)}}return k},C.prototype.getDisplayTextForSnippet=function(P,O){var E=w.call(this,P,O);return E.text},C.prototype.insertSnippetForSelection=function(P,O,E){E===void 0&&(E={});var k=w.call(this,P,O,E),B=P.getSelectionRange(),N=P.session.replace(B,k.text),M=new x(P),$=P.inVirtualSelectionMode&&P.selection.index;M.addTabstops(k.tabstops,B.start,N,$)},C.prototype.insertSnippet=function(P,O,E){E===void 0&&(E={});var k=this;if(P.inVirtualSelectionMode)return k.insertSnippetForSelection(P,O,E);P.forEachSelection(function(){k.insertSnippetForSelection(P,O,E)},null,{keepOrder:!0}),P.tabstopManager&&P.tabstopManager.tabNext()},C.prototype.$getScope=function(P){var O=P.session.$mode.$id||"";if(O=O.split("/").pop(),O==="html"||O==="php"){O==="php"&&!P.session.$mode.inlinePhp&&(O="html");var E=P.getCursorPosition(),k=P.session.getState(E.row);typeof k=="object"&&(k=k[0]),k.substring&&(k.substring(0,3)=="js-"?O="javascript":k.substring(0,4)=="css-"?O="css":k.substring(0,4)=="php-"&&(O="php"))}return O},C.prototype.getActiveScopes=function(P){var O=this.$getScope(P),E=[O],k=this.snippetMap;return k[O]&&k[O].includeScopes&&E.push.apply(E,k[O].includeScopes),E.push("_"),E},C.prototype.expandWithTab=function(P,O){var E=this,k=P.forEachSelection(function(){return E.expandSnippetForSelection(P,O)},null,{keepOrder:!0});return k&&P.tabstopManager&&P.tabstopManager.tabNext(),k},C.prototype.expandSnippetForSelection=function(P,O){var E=P.getCursorPosition(),k=P.session.getLine(E.row),B=k.substring(0,E.column),N=k.substr(E.column),M=this.snippetMap,$;return this.getActiveScopes(P).some(function(A){var D=M[A];return D&&($=this.findMatchingSnippet(D,B,N)),!!$},this),$?(O&&O.dryRun||(P.session.doc.removeInLine(E.row,E.column-$.replaceBefore.length,E.column+$.replaceAfter.length),this.variables.M__=$.matchBefore,this.variables.T__=$.matchAfter,this.insertSnippetForSelection(P,$.content),this.variables.M__=this.variables.T__=null),!0):!1},C.prototype.findMatchingSnippet=function(P,O,E){for(var k=P.length;k--;){var B=P[k];if(!(B.startRe&&!B.startRe.test(O))&&!(B.endRe&&!B.endRe.test(E))&&!(!B.startRe&&!B.endRe))return B.matchBefore=B.startRe?B.startRe.exec(O):[""],B.matchAfter=B.endRe?B.endRe.exec(E):[""],B.replaceBefore=B.triggerRe?B.triggerRe.exec(O)[0]:"",B.replaceAfter=B.endTriggerRe?B.endTriggerRe.exec(E)[0]:"",B}},C.prototype.register=function(P,O){function E(A){return A&&!/^\^?\(.*\)\$?$|^\\b$/.test(A)&&(A="(?:"+A+")"),A||""}function k(A,D,j){return A=E(A),D=E(D),A=D+A,A&&A[A.length-1]!="$"&&(A+="$"),new RegExp(A)}function B(A){A.scope||(A.scope=O||"_"),O=A.scope,N[O]||(N[O]=[],M[O]={});var D=M[O];if(A.name){var j=D[A.name];j&&$.unregister(j),D[A.name]=A}N[O].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=p.escapeRegExp(A.tabTrigger)),!(!A.trigger&&!A.guard&&!A.endTrigger&&!A.endGuard)&&(A.startRe=k(A.trigger,A.guard),A.triggerRe=new RegExp(A.trigger),A.endRe=k(A.endTrigger,A.endGuard),A.endTriggerRe=new RegExp(A.endTrigger))}var N=this.snippetMap,M=this.snippetNameMap,$=this;P||(P=[]),Array.isArray(P)?P.forEach(B):Object.keys(P).forEach(function(A){B(P[A])}),this._signal("registerSnippets",{scope:O})},C.prototype.unregister=function(P,O){function E(N){var M=B[N.scope||O];if(M&&M[N.name]){delete M[N.name];var $=k[N.scope||O],A=$&&$.indexOf(N);A>=0&&$.splice(A,1)}}var k=this.snippetMap,B=this.snippetNameMap;P.content?E(P):Array.isArray(P)&&P.forEach(E)},C.prototype.parseSnippetFile=function(P){P=P.replace(/\r/g,"");for(var O=[],E={},k=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm,B;B=k.exec(P);){if(B[1])try{E=JSON.parse(B[1]),O.push(E)}catch{}if(B[4])E.content=B[4].replace(/^\t/gm,""),O.push(E),E={};else{var N=B[2],M=B[3];if(N=="regex"){var $=/\/((?:[^\/\\]|\\.)*)|$/g;E.guard=$.exec(M)[1],E.trigger=$.exec(M)[1],E.endTrigger=$.exec(M)[1],E.endGuard=$.exec(M)[1]}else N=="snippet"?(E.tabTrigger=M.match(/^\S*/)[0],E.name||(E.name=M)):N&&(E[N]=M)}}return O},C.prototype.getSnippetByName=function(P,O){var E=this.snippetNameMap,k;return this.getActiveScopes(O).some(function(B){var N=E[B];return N&&(k=N[P]),!!k},this),k},C})();v.implement(m.prototype,s);var w=function(C,P,O){function E(oe){for(var ee=[],ye=0;ye<oe.length;ye++){var we=oe[ye];if(typeof we=="object"){if(D[we.tabstopId])continue;var Ae=oe.lastIndexOf(we,ye-1);we=ee[Ae]||{tabstopId:we.tabstopId}}ee[ye]=we}return ee}O===void 0&&(O={});var k=C.getCursorPosition(),B=C.session.getLine(k.row),N=C.session.getTabString(),M=B.match(/^\s*/)[0];k.column<M.length&&(M=M.slice(0,k.column)),P=P.replace(/\r/g,"");var $=this.tokenizeTmSnippet(P);$=this.resolveVariables($,C),$=$.map(function(oe){return oe==`
1131
+ `&&!O.excludeExtraIndent?oe+M:typeof oe=="string"?oe.replace(/\t/g,N):oe});var A=[];$.forEach(function(oe,ee){if(typeof oe=="object"){var ye=oe.tabstopId,we=A[ye];if(we||(we=A[ye]=[],we.index=ye,we.value="",we.parents={}),we.indexOf(oe)===-1){oe.choices&&!we.choices&&(we.choices=oe.choices),we.push(oe);var Ae=$.indexOf(oe,ee+1);if(Ae!==-1){var Je=$.slice(ee+1,Ae),ze=Je.some(function(Ye){return typeof Ye=="object"});ze&&!we.value?we.value=Je:Je.length&&(!we.value||typeof we.value!="string")&&(we.value=Je.join(""))}}}}),A.forEach(function(oe){oe.length=0});for(var D={},j=0;j<$.length;j++){var U=$[j];if(typeof U=="object"){var q=U.tabstopId,Q=A[q],re=$.indexOf(U,j+1);if(D[q]){D[q]===U&&(delete D[q],Object.keys(D).forEach(function(oe){Q.parents[oe]=!0}));continue}D[q]=U;var le=Q.value;typeof le!="string"?le=E(le):U.fmt&&(le=this.tmStrFormat(le,U,C)),$.splice.apply($,[j+1,Math.max(0,re-j)].concat(le,U)),Q.indexOf(U)===-1&&Q.push(U)}}var ne=0,ue=0,he="";return $.forEach(function(oe){if(typeof oe=="string"){var ee=oe.split(`
1132
+ `);ee.length>1?(ue=ee[ee.length-1].length,ne+=ee.length-1):ue+=oe.length,he+=oe}else oe&&(oe.start?oe.end={row:ne,column:ue}:oe.start={row:ne,column:ue})}),{text:he,tabstops:A,tokens:$}},x=(function(){function C(P){if(this.index=0,this.ranges=[],this.tabstops=[],P.tabstopManager)return P.tabstopManager;P.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=p.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(P)}return C.prototype.attach=function(P){this.$openTabstops=null,this.selectedTabstop=null,this.editor=P,this.session=P.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(P){for(var O=P.action[0]=="r",E=this.selectedTabstop||{},k=E.parents||{},B=this.tabstops.slice(),N=0;N<B.length;N++){var M=B[N],$=M==E||k[M.index];if(M.rangeList.$bias=$?0:1,P.action=="remove"&&M!==E){var A=M.parents&&M.parents[E.index],D=M.rangeList.pointIndex(P.start,A);D=D<0?-D-1:D+1;var j=M.rangeList.pointIndex(P.end,A);j=j<0?-j-1:j-1;for(var U=M.rangeList.ranges.slice(D,j),q=0;q<U.length;q++)this.removeRange(U[q])}M.rangeList.$onChange(P)}var Q=this.session;!this.$inChange&&O&&Q.getLength()==1&&!Q.getValue()&&this.detach()},C.prototype.updateLinkedFields=function(){var P=this.selectedTabstop;if(!(!P||!P.hasLinkedRanges||!P.firstNonLinked)){this.$inChange=!0;for(var O=this.session,E=O.getTextRange(P.firstNonLinked),k=0;k<P.length;k++){var B=P[k];if(B.linked){var N=B.original,M=r.snippetManager.tmStrFormat(E,N,this.editor);O.replace(B,M)}}this.$inChange=!1}},C.prototype.onAfterExec=function(P){P.command&&!P.command.readOnly&&this.updateLinkedFields()},C.prototype.onChangeSelection=function(){if(this.editor){for(var P=this.editor.selection.lead,O=this.editor.selection.anchor,E=this.editor.selection.isEmpty(),k=0;k<this.ranges.length;k++)if(!this.ranges[k].linked){var B=this.ranges[k].contains(P.row,P.column),N=E||this.ranges[k].contains(O.row,O.column);if(B&&N)return}this.detach()}},C.prototype.onChangeSession=function(){this.detach()},C.prototype.tabNext=function(P){var O=this.tabstops.length,E=this.index+(P||1);E=Math.min(Math.max(E,1),O),E==O&&(E=0),this.selectTabstop(E),this.updateTabstopMarkers(),E===0&&this.detach()},C.prototype.selectTabstop=function(P){this.$openTabstops=null;var O=this.tabstops[this.index];if(O&&this.addTabstopMarkers(O),this.index=P,O=this.tabstops[this.index],!(!O||!O.length)){this.selectedTabstop=O;var E=O.firstNonLinked||O;if(O.choices&&(E.cursor=E.start),this.editor.inVirtualSelectionMode)this.editor.selection.fromOrientedRange(E);else{var k=this.editor.multiSelect;k.toSingleRange(E);for(var B=0;B<O.length;B++)O.hasLinkedRanges&&O[B].linked||k.addRange(O[B].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(P,O,E){var k=this.useLink||!this.editor.getOption("enableMultiselect");if(this.$openTabstops||(this.$openTabstops=[]),!P[0]){var B=a.fromPoints(E,E);T(B.start,O),T(B.end,O),P[0]=[B],P[0].index=0}var N=this.index,M=[N+1,0],$=this.ranges,A=this.snippetId=(this.snippetId||0)+1;P.forEach(function(D,j){var U=this.$openTabstops[j]||D;U.snippetId=A;for(var q=0;q<D.length;q++){var Q=D[q],re=a.fromPoints(Q.start,Q.end||Q.start);R(re.start,O),R(re.end,O),re.original=Q,re.tabstop=U,$.push(re),U!=D?U.unshift(re):U[q]=re,Q.fmtString||U.firstNonLinked&&k?(re.linked=!0,U.hasLinkedRanges=!0):U.firstNonLinked||(U.firstNonLinked=re)}U.firstNonLinked||(U.hasLinkedRanges=!1),U===D&&(M.push(U),this.$openTabstops[j]=U),this.addTabstopMarkers(U),U.rangeList=U.rangeList||new l,U.rangeList.$bias=0,U.rangeList.addList(U)},this),M.length>2&&(this.tabstops.length&&M.push(M.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,M))},C.prototype.addTabstopMarkers=function(P){var O=this.session;P.forEach(function(E){E.markerId||(E.markerId=O.addMarker(E,"ace_snippet-marker","text"))})},C.prototype.removeTabstopMarkers=function(P){var O=this.session;P.forEach(function(E){O.removeMarker(E.markerId),E.markerId=null})},C.prototype.updateTabstopMarkers=function(){if(this.selectedTabstop){var P=this.selectedTabstop.snippetId;this.selectedTabstop.index===0&&P--,this.tabstops.forEach(function(O){O.snippetId===P?this.addTabstopMarkers(O):this.removeTabstopMarkers(O)},this)}},C.prototype.removeRange=function(P){var O=P.tabstop.indexOf(P);O!=-1&&P.tabstop.splice(O,1),O=this.ranges.indexOf(P),O!=-1&&this.ranges.splice(O,1),O=P.tabstop.rangeList.ranges.indexOf(P),O!=-1&&P.tabstop.splice(O,1),this.session.removeMarker(P.markerId),P.tabstop.length||(O=this.tabstops.indexOf(P.tabstop),O!=-1&&this.tabstops.splice(O,1),this.tabstops.length||this.detach())},C})();x.prototype.keyboardHandler=new u,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 R=function(C,P){C.row==0&&(C.column+=P.column),C.row+=P.row},T=function(C,P){C.row==P.row&&(C.column-=P.column),C.row-=P.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 m;var _=t("./editor").Editor;(function(){this.insertSnippet=function(C,P){return r.snippetManager.insertSnippet(this,C,P)},this.expandSnippet=function(C){return r.snippetManager.expandWithTab(this,C)}}).call(_.prototype)}),ace.define("ace/autocomplete/popup",["require","exports","module","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom","ace/config","ace/lib/useragent"],function(t,r,c){var h=t("../virtual_renderer").VirtualRenderer,g=t("../editor").Editor,v=t("../range").Range,s=t("../lib/event"),p=t("../lib/lang"),a=t("../lib/dom"),l=t("../config").nls,u=t("./../lib/useragent"),d=function(R){return"suggest-aria-id:".concat(R)},o=u.isSafari?"menu":"listbox",f=u.isSafari?"menuitem":"option",m=u.isSafari?"aria-current":"aria-selected",w=function(R){var T=new h(R);T.$maxLines=4;var _=new g(T);return _.setHighlightActiveLine(!1),_.setShowPrintMargin(!1),_.renderer.setShowGutter(!1),_.renderer.setHighlightGutterLine(!1),_.$mouseHandler.$focusTimeout=0,_.$highlightTagPending=!0,_},x=(function(){function R(T){var _=a.createElement("div"),C=w(_);T&&T.appendChild(_),_.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 P=function(){};C.focus=P,C.$isFocused=!0,C.renderer.$cursorLayer.restartTimer=P,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($){var A=$.getDocumentPosition();C.selection.moveToPosition(A),k.start.row=k.end.row=A.row,$.stop()});var O,E=new v(-1,0,-1,1/0),k=new v(-1,0,-1,1/0);k.id=C.session.addMarker(k,"ace_active-line","fullLine"),C.setSelectOnHover=function($){$?E.id&&(C.session.removeMarker(E.id),E.id=null):E.id=C.session.addMarker(E,"ace_line-hover","fullLine")},C.setSelectOnHover(!1),C.on("mousemove",function($){if(!O){O=$;return}if(!(O.x==$.x&&O.y==$.y)){O=$,O.scrollTop=C.renderer.scrollTop,C.isMouseOver=!0;var A=O.getDocumentPosition().row;E.start.row!=A&&(E.id||C.setRow(A),N(A))}}),C.renderer.on("beforeRender",function(){if(O&&E.start.row!=-1){O.$pos=null;var $=O.getDocumentPosition().row;E.id||C.setRow($),N($,!0)}}),C.renderer.on("afterRender",function(){for(var $=C.renderer.$textLayer,A=$.config.firstRow,D=$.config.lastRow;A<=D;A++){var j=$.element.childNodes[A-$.config.firstRow];j.setAttribute("role",f),j.setAttribute("aria-roledescription",l("autocomplete.popup.item.aria-roledescription","item")),j.setAttribute("aria-setsize",C.data.length),j.setAttribute("aria-describedby","doc-tooltip"),j.setAttribute("aria-posinset",A+1);var U=C.getData(A);if(U){var q="".concat(U.caption||U.value).concat(U.meta?", ".concat(U.meta):"");j.setAttribute("aria-label",q)}var Q=j.querySelectorAll(".ace_completion-highlight");Q.forEach(function(re){re.setAttribute("role","mark")})}}),C.renderer.on("afterRender",function(){var $=C.getRow(),A=C.renderer.$textLayer,D=A.element.childNodes[$-A.config.firstRow],j=document.activeElement;if(D!==C.selectedNode&&C.selectedNode&&(a.removeCssClass(C.selectedNode,"ace_selected"),C.selectedNode.removeAttribute(m),C.selectedNode.removeAttribute("id")),j.removeAttribute("aria-activedescendant"),C.selectedNode=D,D){var U=d($);a.addCssClass(D,"ace_selected"),D.id=U,A.element.setAttribute("aria-activedescendant",U),j.setAttribute("aria-activedescendant",U),D.setAttribute(m,"true")}});var B=function(){N(-1)},N=function($,A){$!==E.start.row&&(E.start.row=E.end.row=$,A||C.session._emit("changeBackMarker"),C._emit("changeHoverMarker"))};C.getHoveredRow=function(){return E.start.row},s.addListener(C.container,"mouseout",function(){C.isMouseOver=!1,B()}),C.on("hide",B),C.on("changeSelection",B),C.session.doc.getLength=function(){return C.data.length},C.session.doc.getLine=function($){var A=C.data[$];return typeof A=="string"?A:A&&A.value||""};var M=C.session.bgTokenizer;return M.$tokenizeRow=function($){function A(oe,ee){oe&&j.push({type:(D.className||"")+(ee||""),value:oe})}var D=C.data[$],j=[];if(!D)return j;typeof D=="string"&&(D={value:D});for(var U=D.caption||D.value||D.name,q=U.toLowerCase(),Q=(C.filterText||"").toLowerCase(),re=0,le=0,ne=0;ne<=Q.length;ne++)if(ne!=le&&(D.matchMask&1<<ne||ne==Q.length)){var ue=Q.slice(le,ne);le=ne;var he=q.indexOf(ue,re);if(he==-1)continue;A(U.slice(re,he),""),re=he+ue.length,A(U.slice(he,re),"completion-highlight")}return A(U.slice(re,U.length),""),j.push({type:"completion-spacer",value:" "}),D.meta&&j.push({type:"completion-meta",value:D.meta}),D.message&&j.push({type:"completion-message",value:D.message}),j},M.$updateOnChange=P,M.start=P,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($,A){C.filterText=A||"",C.setValue(p.stringRepeat(`
1140
+ `,$.length),-1),C.data=$||[],C.setRow(0)},C.getData=function($){return C.data[$]},C.getRow=function(){return k.start.row},C.setRow=function($){$=Math.max(this.autoSelect?0:-1,Math.min(this.data.length-1,$)),k.start.row!=$&&(C.selection.clearSelection(),k.start.row=k.end.row=$||0,C.session._emit("changeBackMarker"),C.moveCursorTo($||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($,A,D,j){if(!j&&C.isOpen&&C.anchorPos&&C.anchor&&C.anchorPos.top===$.top&&C.anchorPos.left===$.left&&C.anchor===D)return!0;var U=this.container,q=this.renderer.scrollBar.width||10,Q=window.innerHeight-q,re=window.innerWidth-q,le=this.renderer,ne=le.$maxLines*A*1.4,ue={top:0,bottom:0},he=Q-$.top-3*this.$borderSize-A,oe=$.top-3*this.$borderSize;D||(oe<=he||he>=ne?D="bottom":D="top"),D==="top"?(ue.bottom=$.top-this.$borderSize,ue.top=ue.bottom-ne):D==="bottom"&&(ue.top=$.top+A+this.$borderSize,ue.bottom=ue.top+ne);var ee=ue.top>=0&&ue.bottom<=Q;if(!j&&!ee)return!1;ee?le.$maxPixelHeight=null:D==="top"?le.$maxPixelHeight=oe:le.$maxPixelHeight=he,D==="top"?(U.style.top="",U.style.bottom=Q+q-ue.bottom+"px",C.isTopdown=!1):(U.style.top=ue.top+"px",U.style.bottom="",C.isTopdown=!0),U.style.display="";var ye=$.left;return ye+U.offsetWidth>re&&(ye=re-U.offsetWidth),U.style.left=ye+"px",U.style.right="",a.$fixPositionBug(U),C.isOpen||(C.isOpen=!0,this._signal("show"),O=null),C.anchorPos=$,C.anchor=D,!0},C.show=function($,A,D){this.tryShow($,A,D?"bottom":void 0,!0)},C.goTo=function($){var A=this.getRow(),D=this.session.getLength()-1;switch($){case"up":A=A<=0?D:A-1;break;case"down":A=A>=D?-1:A+1;break;case"start":A=0;break;case"end":A=D}this.setRow(A)},C.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},C.$imageSize=0,C.$borderSize=1,C}return R})();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=w,r.getAriaId=d}),ace.define("ace/autocomplete/inline_screenreader",["require","exports","module"],function(t,r,c){var h=(function(){function g(v){this.editor=v,this.screenReaderDiv=document.createElement("div"),this.screenReaderDiv.classList.add("ace_screenreader-only"),this.editor.container.appendChild(this.screenReaderDiv)}return g.prototype.setScreenReaderContent=function(v){for(!this.popup&&this.editor.completer&&this.editor.completer.popup&&(this.popup=this.editor.completer.popup,this.popup.renderer.on("afterRender",(function(){var p=this.popup.getRow(),a=this.popup.renderer.$textLayer,l=a.element.childNodes[p-a.config.firstRow];if(l){for(var u="doc-tooltip ",d=0;d<this._lines.length;d++)u+="ace-inline-screenreader-line-".concat(d," ");l.setAttribute("aria-describedby",u)}}).bind(this)));this.screenReaderDiv.firstChild;)this.screenReaderDiv.removeChild(this.screenReaderDiv.firstChild);this._lines=v.split(/\r\n|\r|\n/);var s=this.createCodeBlock();this.screenReaderDiv.appendChild(s)},g.prototype.destroy=function(){this.screenReaderDiv.remove()},g.prototype.createCodeBlock=function(){var v=document.createElement("pre");v.setAttribute("id","ace-inline-screenreader");for(var s=0;s<this._lines.length;s++){var p=document.createElement("code");p.setAttribute("id","ace-inline-screenreader-line-".concat(s));var a=document.createTextNode(this._lines[s]);p.appendChild(a),v.appendChild(p)}return v},g})();r.AceInlineScreenReader=h}),ace.define("ace/autocomplete/inline",["require","exports","module","ace/snippets","ace/autocomplete/inline_screenreader"],function(t,r,c){var h=t("../snippets").snippetManager,g=t("./inline_screenreader").AceInlineScreenReader,v=(function(){function s(){this.editor=null}return s.prototype.show=function(p,a,l){if(l=l||"",p&&this.editor&&this.editor!==p&&(this.hide(),this.editor=null,this.inlineScreenReader=null),!p||!a)return!1;this.inlineScreenReader||(this.inlineScreenReader=new g(p));var u=a.snippet?h.getDisplayTextForSnippet(p,a.snippet):a.value;return a.hideInlinePreview||!u||!u.startsWith(l)?!1:(this.editor=p,this.inlineScreenReader.setScreenReaderContent(u),u=u.slice(l.length),u===""?p.removeGhostText():p.setGhostText(u),!0)},s.prototype.isOpen=function(){return this.editor?!!this.editor.renderer.$ghostText:!1},s.prototype.hide=function(){return this.editor?(this.editor.removeGhostText(),!0):!1},s.prototype.destroy=function(){this.hide(),this.editor=null,this.inlineScreenReader&&(this.inlineScreenReader.destroy(),this.inlineScreenReader=null)},s})();r.AceInline=v}),ace.define("ace/autocomplete/util",["require","exports","module"],function(t,r,c){r.parForEach=function(g,v,s){var p=0,a=g.length;a===0&&s();for(var l=0;l<a;l++)v(g[l],function(u,d){p++,p===a&&s(u,d)})};var h=/[a-zA-Z_0-9\$\-\u00A2-\u2000\u2070-\uFFFF]/;r.retrievePrecedingIdentifier=function(g,v,s){s=s||h;for(var p=[],a=v-1;a>=0&&s.test(g[a]);a--)p.push(g[a]);return p.reverse().join("")},r.retrieveFollowingIdentifier=function(g,v,s){s=s||h;for(var p=[],a=v;a<g.length&&s.test(g[a]);a++)p.push(g[a]);return p},r.getCompletionPrefix=function(g){var v=g.getCursorPosition(),s=g.session.getLine(v.row),p;return g.completers.forEach((function(a){a.identifierRegexps&&a.identifierRegexps.forEach((function(l){!p&&l&&(p=this.retrievePrecedingIdentifier(s,v.column,l))}).bind(this))}).bind(this)),p||this.retrievePrecedingIdentifier(s,v.column)},r.triggerAutocomplete=function(g,s){var s=s??g.session.getPrecedingCharacter();return g.completers.some(function(p){if(p.triggerCharacters&&Array.isArray(p.triggerCharacters))return p.triggerCharacters.includes(s)})}}),ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/inline","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/lang","ace/lib/dom","ace/snippets","ace/config","ace/lib/event","ace/lib/scroll"],function(t,r,c){var h=t("./keyboard/hash_handler").HashHandler,g=t("./autocomplete/popup").AcePopup,v=t("./autocomplete/inline").AceInline,s=t("./autocomplete/popup").getAriaId,p=t("./autocomplete/util"),a=t("./lib/lang"),l=t("./lib/dom"),u=t("./snippets").snippetManager,d=t("./config"),o=t("./lib/event"),f=t("./lib/scroll").preventParentScroll,m=function(T,_){_.completer&&_.completer.destroy()},w=(function(){function T(){this.autoInsert=!1,this.autoSelect=!0,this.autoShown=!1,this.exactMatch=!1,this.inlineEnabled=!1,this.keyboardHandler=new h,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 _=this.completionProvider&&this.completionProvider.initialPosition;this.autoShown||this.popup&&this.popup.isOpen||!_||this.editor.completers.length===0||(this.completions=new R(T.completionsForLoading),this.openPopup(this.editor,_.prefix,!1),this.popup.renderer.setStyle("ace_loading",!0))}).bind(this),this.stickySelectionDelay)}return Object.defineProperty(T,"completionsForLoading",{get:function(){return[{caption:d.nls("autocomplete.loading","Loading..."),value:""}]},enumerable:!1,configurable:!0}),T.prototype.$init=function(){return this.popup=new g(this.parentNode||document.body||document.documentElement),this.popup.on("click",(function(_){this.insertMatch(),_.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},T.prototype.$initInline=function(){if(!(!this.inlineEnabled||this.inlineRenderer))return this.inlineRenderer=new v,this.inlineRenderer},T.prototype.getPopup=function(){return this.popup||this.$init()},T.prototype.$onHidePopup=function(){this.inlineRenderer&&this.inlineRenderer.hide(),this.hideDocTooltip(),this.stickySelectionTimer.cancel(),this.popupTimer.cancel(),this.stickySelection=!1},T.prototype.$seen=function(_){!this.hasSeen.has(_)&&_&&_.completer&&_.completer.onSeen&&typeof _.completer.onSeen=="function"&&(_.completer.onSeen(this.editor,_),this.hasSeen.add(_))},T.prototype.$onPopupChange=function(_){if(this.inlineRenderer&&this.inlineEnabled){var C=_?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)},T.prototype.$updateGhostText=function(_){var C=this.base.row,P=this.base.column,O=this.editor.getCursorPosition().column,E=this.editor.session.getLine(C).slice(P,O);this.inlineRenderer.show(this.editor,_,E)?this.$seen(_):this.inlineRenderer.hide()},T.prototype.$onPopupRender=function(){var _=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 P=this.popup.getData(C);P&&(!_||P.hideInlinePreview)&&this.$seen(P)}},T.prototype.$onPopupShow=function(_){this.$onPopupChange(_),this.stickySelection=!1,this.stickySelectionDelay>=0&&this.stickySelectionTimer.schedule(this.stickySelectionDelay)},T.prototype.observeLayoutChanges=function(){if(!(this.$elements||!this.editor)){window.addEventListener("resize",this.onLayoutChange,{passive:!0}),window.addEventListener("wheel",this.mousewheelListener);for(var _=this.editor.container.parentNode,C=[];_;)C.push(_),_.addEventListener("scroll",this.onLayoutChange,{passive:!0}),_=_.parentNode;this.$elements=C}},T.prototype.unObserveLayoutChanges=function(){var _=this;window.removeEventListener("resize",this.onLayoutChange,{passive:!0}),window.removeEventListener("wheel",this.mousewheelListener),this.$elements&&this.$elements.forEach(function(C){C.removeEventListener("scroll",_.onLayoutChange,{passive:!0})}),this.$elements=null},T.prototype.onLayoutChange=function(){if(!this.popup.isOpen)return this.unObserveLayoutChanges();this.$updatePopupPosition(),this.updateDocTooltip()},T.prototype.$updatePopupPosition=function(){var _=this.editor,C=_.renderer,P=C.layerConfig.lineHeight,O=C.$cursorLayer.getPixelPosition(this.base,!0);O.left-=this.popup.getTextLeftOffset();var E=_.container.getBoundingClientRect();O.top+=E.top-C.layerConfig.offset,O.left+=E.left-_.renderer.scrollLeft,O.left+=C.gutterWidth;var k={top:O.top,left:O.left};C.$ghostText&&C.$ghostTextWidget&&this.base.row===C.$ghostText.position.row&&(k.top+=C.$ghostTextWidget.el.offsetHeight);var B=_.container.getBoundingClientRect().bottom-P,N=B<k.top?{top:B,left:k.left}:k;this.popup.tryShow(N,P,"bottom")||this.popup.tryShow(O,P,"top")||this.popup.show(O,P)},T.prototype.openPopup=function(_,C,P){this.$firstOpenTimer.cancel(),this.popup||this.$init(),this.inlineEnabled&&!this.inlineRenderer&&this.$initInline(),this.popup.autoSelect=this.autoSelect,this.popup.setSelectOnHover(this.setSelectOnHover);var O=this.popup.getRow(),E=this.popup.data[O];this.popup.setData(this.completions.filtered,this.completions.filterText),this.editor.textInput.setAriaOptions&&this.editor.textInput.setAriaOptions({activeDescendant:s(this.popup.getRow()),inline:this.inlineEnabled}),_.keyBinding.addKeyboardHandler(this.keyboardHandler);var k;this.stickySelection&&(k=this.popup.data.indexOf(E)),(!k||k===-1)&&(k=0),this.popup.setRow(this.autoSelect?k:-1),k===O&&E!==this.completions.filtered[k]&&this.$onPopupChange();var B=this.inlineRenderer&&this.inlineEnabled;if(k===O&&B){var N=this.popup.getData(this.popup.getRow());this.$updateGhostText(N)}P||(this.popup.setTheme(_.getTheme()),this.popup.setFontSize(_.getFontSize()),this.$updatePopupPosition(),this.tooltipNode&&this.updateDocTooltip()),this.changeTimer.cancel(),this.observeLayoutChanges()},T.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()},T.prototype.changeListener=function(_){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()},T.prototype.blurListener=function(_){var C=document.activeElement,P=this.editor.textInput.getElement(),O=_.relatedTarget&&this.tooltipNode&&this.tooltipNode.contains(_.relatedTarget),E=this.popup&&this.popup.container;C!=P&&C.parentNode!=E&&!O&&C!=this.tooltipNode&&_.relatedTarget!=P&&this.detach()},T.prototype.mousedownListener=function(_){this.detach()},T.prototype.mousewheelListener=function(_){this.popup&&!this.popup.isMouseOver&&this.detach()},T.prototype.mouseOutListener=function(_){this.popup.isOpen&&this.$updatePopupPosition()},T.prototype.goTo=function(_){this.popup.goTo(_)},T.prototype.insertMatch=function(_,C){if(_||(_=this.popup.getData(this.popup.getRow())),!_)return!1;if(_.value==="")return this.detach();var P=this.completions,O=this.getCompletionProvider().insertMatch(this.editor,_,P.filterText,C);return this.completions==P&&this.detach(),O},T.prototype.showPopup=function(_,C){this.editor&&this.detach(),this.activated=!0,this.editor=_,_.completer!=this&&(_.completer&&_.completer.detach(),_.completer=this),_.on("changeSelection",this.changeListener),_.on("blur",this.blurListener),_.on("mousedown",this.mousedownListener),_.on("mousewheel",this.mousewheelListener),this.updateCompletions(!1,C)},T.prototype.getCompletionProvider=function(_){return this.completionProvider||(this.completionProvider=new x(_)),this.completionProvider},T.prototype.gatherCompletions=function(_,C){return this.getCompletionProvider().gatherCompletions(_,C)},T.prototype.updateCompletions=function(_,C){if(_&&this.base&&this.completions){var O=this.editor.getCursorPosition(),E=this.editor.session.getTextRange({start:this.base,end:O});if(E==this.completions.filterText)return;if(this.completions.setFilter(E),!this.completions.filtered.length)return this.detach();if(this.completions.filtered.length==1&&this.completions.filtered[0].value==E&&!this.completions.filtered[0].snippet)return this.detach();this.openPopup(this.editor,E,_);return}if(C&&C.matches){var O=this.editor.getSelectionRange().start;return this.base=this.editor.session.doc.createAnchor(O.row,O.column),this.base.$insertRight=!0,this.completions=new R(C.matches),this.getCompletionProvider().completions=this.completions,this.openPopup(this.editor,"",_)}var P=this.editor.getSession(),O=this.editor.getCursorPosition(),E=p.getCompletionPrefix(this.editor);this.base=P.doc.createAnchor(O.row,O.column-E.length),this.base.$insertRight=!0;var k={exactMatch:this.exactMatch,ignoreCaption:this.ignoreCaption};this.getCompletionProvider({prefix:E,pos:O}).provideCompletions(this.editor,k,(function(B,N,M){var $=N.filtered,A=p.getCompletionPrefix(this.editor);if(this.$firstOpenTimer.cancel(),M){if(!$.length){var D=!this.autoShown&&this.emptyMessage;if(typeof D=="function"&&(D=this.emptyMessage(A)),D){var j=[{caption:D,value:""}];this.completions=new R(j),this.openPopup(this.editor,A,_),this.popup.renderer.setStyle("ace_loading",!1),this.popup.renderer.setStyle("ace_empty-message",!0);return}return this.detach()}if($.length==1&&$[0].value==A&&!$[0].snippet)return this.detach();if(this.autoInsert&&!this.autoShown&&$.length==1)return this.insertMatch($[0])}this.completions=!M&&this.showLoadingState?new R(T.completionsForLoading.concat($),N.filterText):N,this.openPopup(this.editor,A,_),this.popup.renderer.setStyle("ace_empty-message",!1),this.popup.renderer.setStyle("ace_loading",!M)}).bind(this)),this.showLoadingState&&!this.autoShown&&(!this.popup||!this.popup.isOpen)&&this.$firstOpenTimer.delay(this.stickySelectionDelay/2)},T.prototype.cancelContextMenu=function(){this.editor.$mouseHandler.cancelContextMenu()},T.prototype.updateDocTooltip=function(){var _=this.popup,C=this.completions&&this.completions.filtered,P=C&&(C[_.getHoveredRow()]||C[_.getRow()]),O=null;if(!P||!this.editor||!this.popup.isOpen)return this.hideDocTooltip();for(var E=this.editor.completers.length,k=0;k<E;k++){var B=this.editor.completers[k];if(B.getDocTooltip&&P.completerId===B.id){O=B.getDocTooltip(P);break}}if(!O&&typeof P!="string"&&(O=P),typeof O=="string"&&(O={docText:O}),!O||!O.docHTML&&!O.docText)return this.hideDocTooltip();this.showDocTooltip(O)},T.prototype.showDocTooltip=function(_){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",f));var C=this.editor.renderer.theme;this.tooltipNode.className="ace_tooltip ace_doc-tooltip "+(C.isDark?"ace_dark ":"")+(C.cssClass||"");var P=this.tooltipNode;_.docHTML?P.innerHTML=_.docHTML:_.docText&&(P.textContent=_.docText),P.parentNode||this.popup.container.appendChild(this.tooltipNode);var O=this.popup,E=O.container.getBoundingClientRect(),k=400,B=300,N=O.renderer.scrollBar.width||10,M=E.left,$=window.innerWidth-E.right-N,A=O.isTopdown?window.innerHeight-N-E.bottom:E.top,D=[Math.min($/k,1),Math.min(M/k,1),Math.min(A/B,1)*.9],j=Math.max.apply(Math,D),U=P.style;U.display="block",j==D[0]||D[0]>=1?(U.left=E.right+1+"px",U.right="",U.maxWidth=k*j+"px",U.top=E.top+"px",U.bottom="",U.maxHeight=Math.min(window.innerHeight-N-E.top,B)+"px"):j==D[1]||D[1]>=1?(U.right=window.innerWidth-E.left+"px",U.left="",U.maxWidth=k*j+"px",U.top=E.top+"px",U.bottom="",U.maxHeight=Math.min(window.innerHeight-N-E.top,B)+"px"):j==D[2]&&(U.left=E.left+"px",U.right="",U.maxWidth=Math.min(k,window.innerWidth-E.left)+"px",O.isTopdown?(U.top=E.bottom+"px",U.bottom="",U.maxHeight=Math.min(window.innerHeight-N-E.bottom,B)+"px"):(U.top="",U.bottom=window.innerHeight-E.top+"px",U.maxHeight=Math.min(E.top,B)+"px")),l.$fixPositionBug(P)},T.prototype.hideDocTooltip=function(){if(this.tooltipTimer.cancel(),!!this.tooltipNode){var _=this.tooltipNode;!this.editor.isFocused()&&document.activeElement==_&&this.editor.focus(),this.tooltipNode=null,_.parentNode&&_.parentNode.removeChild(_)}},T.prototype.onTooltipClick=function(_){for(var C=_.target;C&&C!=this.tooltipNode;){if(C.nodeName=="A"&&C.href){C.rel="noreferrer",C.target="_blank";break}C=C.parentNode}},T.prototype.destroy=function(){if(this.detach(),this.popup){this.popup.destroy();var _=this.popup.container;_&&_.parentNode&&_.parentNode.removeChild(_)}this.editor&&this.editor.completer==this&&(this.editor.off("destroy",m),this.editor.completer=null),this.inlineRenderer=this.popup=this.editor=null},T.for=function(_){return _.completer instanceof T||(_.completer&&(_.completer.destroy(),_.completer=null),d.get("sharedPopups")?(T.$sharedInstance||(T.$sharedInstance=new T),_.completer=T.$sharedInstance):(_.completer=new T,_.once("destroy",m))),_.completer},T})();w.prototype.commands={Up:function(T){T.completer.goTo("up")},Down:function(T){T.completer.goTo("down")},"Ctrl-Up|Ctrl-Home":function(T){T.completer.goTo("start")},"Ctrl-Down|Ctrl-End":function(T){T.completer.goTo("end")},Esc:function(T){T.completer.detach()},Return:function(T){return T.completer.insertMatch()},"Shift-Return":function(T){T.completer.insertMatch(null,{deleteSuffix:!0})},Tab:function(T){var _=T.completer.insertMatch();if(_||T.tabstopManager)return _;T.completer.goTo("down")},Backspace:function(T){T.execCommand("backspace");var _=p.getCompletionPrefix(T);!_&&T.completer&&T.completer.detach()},PageUp:function(T){T.completer.popup.gotoPageUp()},PageDown:function(T){T.completer.popup.gotoPageDown()}},w.startCommand={name:"startAutocomplete",exec:function(T,_){var C=w.for(T);C.autoInsert=!1,C.autoSelect=!0,C.autoShown=!1,C.showPopup(T,_),C.cancelContextMenu()},bindKey:"Ctrl-Space|Ctrl-Shift-Space|Alt-Space"};var x=(function(){function T(_){this.initialPosition=_,this.active=!0}return T.prototype.insertByIndex=function(_,C,P){return!this.completions||!this.completions.filtered?!1:this.insertMatch(_,this.completions.filtered[C],P)},T.prototype.insertMatch=function(_,C,P){if(!C)return!1;if(_.startOperation({command:{name:"insertMatch"}}),C.completer&&C.completer.insertMatch)C.completer.insertMatch(_,C);else{if(!this.completions)return!1;var O=this.completions.filterText.length,E=0;if(C.range&&C.range.start.row===C.range.end.row&&(O-=this.initialPosition.prefix.length,O+=this.initialPosition.pos.column-C.range.start.column,E+=C.range.end.column-this.initialPosition.pos.column),O||E){var k;_.selection.getAllRanges?k=_.selection.getAllRanges():k=[_.getSelectionRange()];for(var B=0,N;N=k[B];B++)N.start.column-=O,N.end.column+=E,_.session.remove(N)}C.snippet?u.insertSnippet(_,C.snippet):this.$insertString(_,C),C.completer&&C.completer.onInsert&&typeof C.completer.onInsert=="function"&&C.completer.onInsert(_,C),C.command&&C.command==="startAutocomplete"&&_.execCommand(C.command)}return _.endOperation(),!0},T.prototype.$insertString=function(_,C){var P=C.value||C;_.execCommand("insertstring",P)},T.prototype.gatherCompletions=function(_,C){var P=_.getSession(),O=_.getCursorPosition(),E=p.getCompletionPrefix(_),k=[];this.completers=_.completers;var B=_.completers.length;return _.completers.forEach(function(N,M){N.getCompletions(_,P,O,E,function($,A){N.hideInlinePreview&&(A=A.map(function(D){return Object.assign(D,{hideInlinePreview:N.hideInlinePreview})})),!$&&A&&(k=k.concat(A)),C(null,{prefix:p.getCompletionPrefix(_),matches:k,finished:--B===0})})}),!0},T.prototype.provideCompletions=function(_,C,P){var O=(function(N){var M=N.prefix,$=N.matches;this.completions=new R($),C.exactMatch&&(this.completions.exactMatch=!0),C.ignoreCaption&&(this.completions.ignoreCaption=!0),this.completions.setFilter(M),(N.finished||this.completions.filtered.length)&&P(null,this.completions,N.finished)}).bind(this),E=!0,k=null;if(this.gatherCompletions(_,(function(N,M){if(this.active){N&&(P(N,[],!0),this.detach());var $=M.prefix;if($.indexOf(M.prefix)===0){if(E){k=M;return}O(M)}}}).bind(this)),E=!1,k){var B=k;k=null,O(B)}},T.prototype.detach=function(){this.active=!1,this.completers&&this.completers.forEach(function(_){typeof _.cancel=="function"&&_.cancel()})},T})(),R=(function(){function T(_,C){this.all=_,this.filtered=_,this.filterText=C||"",this.exactMatch=!1,this.ignoreCaption=!1}return T.prototype.setFilter=function(_){if(_.length>this.filterText&&_.lastIndexOf(this.filterText,0)===0)var C=this.filtered;else var C=this.all;this.filterText=_,C=this.filterCompletions(C,this.filterText),C=C.sort(function(O,E){return E.exactMatch-O.exactMatch||E.$score-O.$score||(O.caption||O.value).localeCompare(E.caption||E.value)});var P=null;C=C.filter(function(O){var E=O.snippet||O.caption||O.value;return E===P?!1:(P=E,!0)}),this.filtered=C},T.prototype.filterCompletions=function(_,C){var P=[],O=C.toUpperCase(),E=C.toLowerCase();e:for(var k=0,B;B=_[k];k++){if(B.skipFilter){B.$score=B.score,P.push(B);continue}var N=!this.ignoreCaption&&B.caption||B.value||B.snippet;if(N){var M=-1,$=0,A=0,D,j;if(this.exactMatch){if(C!==N.substr(0,C.length))continue e}else{var U=N.toLowerCase().indexOf(E);if(U>-1)A=U;else for(var q=0;q<C.length;q++){var Q=N.indexOf(E[q],M+1),re=N.indexOf(O[q],M+1);if(D=Q>=0&&(re<0||Q<re)?Q:re,D<0)continue e;j=D-M-1,j>0&&(M===-1&&(A+=10),A+=j,$|=1<<q),M=D}}B.matchMask=$,B.exactMatch=A?0:1,B.$score=(B.score||0)-A,P.push(B)}}return P},T})();r.Autocomplete=w,r.CompletionProvider=x,r.FilteredList=R}),ace.define("ace/marker_group",["require","exports","module"],function(t,r,c){var h=(function(){function g(v,s){s&&(this.markerType=s.markerType),this.markers=[],this.session=v,v.addDynamicMarker(this)}return g.prototype.getMarkerAtPosition=function(v){return this.markers.find(function(s){return s.range.contains(v.row,v.column)})},g.prototype.markersComparator=function(v,s){return v.range.start.row-s.range.start.row},g.prototype.setMarkers=function(v){this.markers=v.sort(this.markersComparator).slice(0,this.MAX_MARKERS),this.session._signal("changeBackMarker")},g.prototype.update=function(v,s,p,a){if(!(!this.markers||!this.markers.length))for(var l=a.firstRow,u=a.lastRow,d,o=0,f=0,m=0;m<this.markers.length;m++){var w=this.markers[m];if(!(w.range.end.row<l)&&!(w.range.start.row>u)&&(w.range.start.row===f?o++:(f=w.range.start.row,o=0),!(o>200))){var x=w.range.clipRows(l,u);if(!(x.start.row===x.end.row&&x.start.column===x.end.column)){var R=x.toScreenRange(p);if(R.isEmpty()){d=p.getNextFoldLine(x.end.row,d),d&&d.end.row>x.end.row&&(l=d.end.row);continue}this.markerType==="fullLine"?s.drawFullLineMarker(v,R,w.className,a):R.isMultiLine()?this.markerType==="line"?s.drawMultiLineMarker(v,R,w.className,a):s.drawTextMarker(v,R,w.className,a):s.drawSingleLineMarker(v,R,w.className+" ace_br15",a)}}}},g})();h.prototype.MAX_MARKERS=1e4,r.MarkerGroup=h}),ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"],function(t,r,c){function h(p,a){var l=p.getTextRange(v.fromPoints({row:0,column:0},a));return l.split(s).length-1}function g(p,a){var l=h(p,a),u=p.getValue().split(s),d=Object.create(null),o=u[l];return u.forEach(function(f,m){if(!(!f||f===o)){var w=Math.abs(l-m),x=u.length-w;d[f]?d[f]=Math.max(x,d[f]):d[f]=x}}),d}var v=t("../range").Range,s=/[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;r.id="textCompleter",r.getCompletions=function(p,a,l,u,d){var o=g(a,l),f=Object.keys(o);d(null,f.map(function(m){return{caption:m,value:m,score:o[m],meta:"local"}}))}}),ace.define("ace/ext/language_tools",["require","exports","module","ace/snippets","ace/autocomplete","ace/config","ace/lib/lang","ace/autocomplete/util","ace/marker_group","ace/autocomplete/text_completer","ace/editor","ace/config"],function(t,r,c){var h=t("../snippets").snippetManager,g=t("../autocomplete").Autocomplete,v=t("../config"),s=t("../lib/lang"),p=t("../autocomplete/util"),a=t("../marker_group").MarkerGroup,l=t("../autocomplete/text_completer"),u={getCompletions:function(E,k,B,N,M){if(k.$mode.completer)return k.$mode.completer.getCompletions(E,k,B,N,M);var $=E.session.getState(B.row),A=k.$mode.getCompletions($,k,B,N);A=A.map(function(D){return D.completerId=u.id,D}),M(null,A)},id:"keywordCompleter"},d=function(E){var k={};return E.replace(/\${(\d+)(:(.*?))?}/g,function(B,N,M,$){return k[N]=$||""}).replace(/\$(\d+?)/g,function(B,N){return k[N]})},o={getCompletions:function(E,k,B,N,M){var $=[],A=k.getTokenAt(B.row,B.column);A&&A.type.match(/(tag-name|tag-open|tag-whitespace|attribute-name|attribute-value)\.xml$/)?$.push("html-tag"):$=h.getActiveScopes(E);var D=h.snippetMap,j=[];$.forEach(function(U){for(var q=D[U]||[],Q=q.length;Q--;){var re=q[Q],le=re.name||re.tabTrigger;le&&j.push({caption:le,snippet:re.content,meta:re.tabTrigger&&!re.name?re.tabTrigger+"⇥ ":"snippet",completerId:o.id})}},this),M(null,j)},getDocTooltip:function(E){E.snippet&&!E.docHTML&&(E.docHTML=["<b>",s.escapeHTML(E.caption),"</b>","<hr></hr>",s.escapeHTML(d(E.snippet))].join(""))},id:"snippetCompleter"},f=[o,l,u];r.setCompleters=function(E){f.length=0,E&&f.push.apply(f,E)},r.addCompleter=function(E){f.push(E)},r.textCompleter=l,r.keyWordCompleter=u,r.snippetCompleter=o;var m={name:"expandSnippet",exec:function(E){return h.expandWithTab(E)},bindKey:"Tab"},w=function(E,k){x(k.session.$mode)},x=function(E){typeof E=="string"&&(E=v.$modes[E]),E&&(h.files||(h.files={}),R(E.$id,E.snippetFileId),E.modes&&E.modes.forEach(x))},R=function(E,k){!k||!E||h.files[E]||(h.files[E]={},v.loadModule(k,function(B){B&&(h.files[E]=B,!B.snippets&&B.snippetText&&(B.snippets=h.parseSnippetFile(B.snippetText)),h.register(B.snippets||[],B.scope),B.includeScopes&&(h.snippetMap[B.scope].includeScopes=B.includeScopes,B.includeScopes.forEach(function(N){x("ace/mode/"+N)})))}))},T=function(E){var k=E.editor,B=k.completer&&k.completer.activated;if(E.command.name==="backspace")B&&!p.getCompletionPrefix(k)&&k.completer.detach();else if(E.command.name==="insertstring"&&!B){_=E;var N=E.editor.$liveAutocompletionDelay;N?C.delay(N):P(E)}},_,C=s.delayedCall(function(){P(_)},0),P=function(E){var k=E.editor,B=p.getCompletionPrefix(k),N=E.args,M=p.triggerAutocomplete(k,N);if(B&&B.length>=k.$liveAutocompletionThreshold||M){var $=g.for(k);$.autoShown=!0,$.showPopup(k)}},O=t("../editor").Editor;t("../config").defineOptions(O.prototype,"editor",{enableBasicAutocompletion:{set:function(E){E?(g.for(this),this.completers||(this.completers=Array.isArray(E)?E:f),this.commands.addCommand(g.startCommand)):this.commands.removeCommand(g.startCommand)},value:!1},enableLiveAutocompletion:{set:function(E){E?(this.completers||(this.completers=Array.isArray(E)?E:f),this.commands.on("afterExec",T)):this.commands.off("afterExec",T)},value:!1},liveAutocompletionDelay:{initialValue:0},liveAutocompletionThreshold:{initialValue:0},enableSnippets:{set:function(E){E?(this.commands.addCommand(m),this.on("changeMode",w),w(null,this)):(this.commands.removeCommand(m),this.off("changeMode",w))},value:!1}}),r.MarkerGroup=a}),(function(){ace.require(["ace/ext/language_tools"],function(t){e&&(e.exports=t)})})()})(cy)),cy.exports}aT();var hy={exports:{}},dy;function lT(){return dy||(dy=1,(function(e,n){ace.define("ace/ext/searchbox-css",["require","exports","module"],function(t,r,c){c.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(t,r,c){var h=t("../lib/dom"),g=t("../lib/lang"),v=t("../lib/event"),s=t("./searchbox-css"),p=t("../keyboard/hash_handler").HashHandler,a=t("../lib/keys"),l=t("../config").nls,u=999;h.importCssString(s,"ace_searchbox",!1);var d=(function(){function m(w,x,R){this.activeInput,this.element=h.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(w),h.importCssString(s,"ace_searchbox",w.container),v.addListener(this.element,"touchstart",function(T){T.stopPropagation()},w)}return m.prototype.setEditor=function(w){w.searchBox=this,w.renderer.scroller.appendChild(this.element),this.editor=w},m.prototype.setSession=function(w){this.searchRange=null,this.$syncOptions(!0)},m.prototype.onEditorInput=function(){this.find(!1,!1,!0)},m.prototype.$initElements=function(w){this.searchBox=w.querySelector(".ace_search_form"),this.replaceBox=w.querySelector(".ace_replace_form"),this.searchOption=w.querySelector("[action=searchInSelection]"),this.replaceOption=w.querySelector("[action=toggleReplace]"),this.regExpOption=w.querySelector("[action=toggleRegexpMode]"),this.caseSensitiveOption=w.querySelector("[action=toggleCaseSensitive]"),this.wholeWordOption=w.querySelector("[action=toggleWholeWords]"),this.searchInput=this.searchBox.querySelector(".ace_search_field"),this.replaceInput=this.replaceBox.querySelector(".ace_search_field"),this.searchCounter=w.querySelector(".ace_search_counter")},m.prototype.$init=function(){var w=this.element;this.$initElements(w);var x=this;v.addListener(w,"mousedown",function(R){setTimeout(function(){x.activeInput.focus()},0),v.stopPropagation(R)}),v.addListener(w,"click",function(R){var T=R.target||R.srcElement,_=T.getAttribute("action");_&&x[_]?x[_]():x.$searchBarKb.commands[_]&&x.$searchBarKb.commands[_].exec(x),v.stopPropagation(R)}),v.addCommandKeyListener(w,function(R,T,_){var C=a.keyCodeToString(_),P=x.$searchBarKb.findKeyCommand(T,C);P&&P.exec&&(P.exec(x),v.stopEvent(R))}),this.$onChange=g.delayedCall(function(){x.find(!1,!1)}),v.addListener(this.searchInput,"input",function(){x.$onChange.schedule(20)}),v.addListener(this.searchInput,"focus",function(){x.activeInput=x.searchInput,x.searchInput.value&&x.highlight()}),v.addListener(this.replaceInput,"focus",function(){x.activeInput=x.replaceInput,x.searchInput.value&&x.highlight()})},m.prototype.setSearchRange=function(w){this.searchRange=w,w?this.searchRangeMarker=this.editor.session.addMarker(w,"ace_active-line"):this.searchRangeMarker&&(this.editor.session.removeMarker(this.searchRangeMarker),this.searchRangeMarker=null)},m.prototype.$syncOptions=function(w){h.setCssClass(this.replaceOption,"checked",this.searchRange),h.setCssClass(this.searchOption,"checked",this.searchOption.checked),this.replaceOption.textContent=this.replaceOption.checked?"-":"+",h.setCssClass(this.regExpOption,"checked",this.regExpOption.checked),h.setCssClass(this.wholeWordOption,"checked",this.wholeWordOption.checked),h.setCssClass(this.caseSensitiveOption,"checked",this.caseSensitiveOption.checked);var x=this.editor.getReadOnly();this.replaceOption.style.display=x?"none":"",this.replaceBox.style.display=this.replaceOption.checked&&!x?"":"none",this.find(!1,!1,w)},m.prototype.highlight=function(w){this.editor.session.highlight(w||this.editor.$search.$options.re),this.editor.renderer.updateBackMarkers()},m.prototype.find=function(w,x,R){if(this.editor.session){var T=this.editor.find(this.searchInput.value,{skipCurrent:w,backwards:x,wrap:!0,regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked,preventScroll:R,range:this.searchRange}),_=!T&&this.searchInput.value;h.setCssClass(this.searchBox,"ace_nomatch",_),this.editor._emit("findSearchBox",{match:!_}),this.highlight(),this.updateCounter()}},m.prototype.updateCounter=function(){var w=this.editor,x=w.$search.$options.re,R=x.unicode,T=0,_=0;if(x){var C=this.searchRange?w.session.getTextRange(this.searchRange):w.getValue();w.$search.$isMultilineSearch(w.getLastSearchOptions())&&(C=C.replace(/\r\n|\r|\n/g,`
1394
+ `),w.session.doc.$autoNewLine=`
1395
+ `);var P=w.session.doc.positionToIndex(w.selection.anchor);this.searchRange&&(P-=w.session.doc.positionToIndex(this.searchRange.start));for(var O=x.lastIndex=0,E;(E=x.exec(C))&&(T++,O=E.index,O<=P&&_++,!(T>u||!E[0]&&(x.lastIndex=O+=g.skipEmptyMatch(C,O,R),O>=C.length))););}this.searchCounter.textContent=l("search-box.search-counter","$0 of $1",[_,T>u?u+"+":T])},m.prototype.findNext=function(){this.find(!0,!1)},m.prototype.findPrev=function(){this.find(!0,!0)},m.prototype.findAll=function(){var w=this.editor.findAll(this.searchInput.value,{regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked}),x=!w&&this.searchInput.value;h.setCssClass(this.searchBox,"ace_nomatch",x),this.editor._emit("findSearchBox",{match:!x}),this.highlight(),this.hide()},m.prototype.replace=function(){this.editor.getReadOnly()||this.editor.replace(this.replaceInput.value)},m.prototype.replaceAndFindNext=function(){this.editor.getReadOnly()||(this.editor.replace(this.replaceInput.value),this.findNext())},m.prototype.replaceAll=function(){this.editor.getReadOnly()||this.editor.replaceAll(this.replaceInput.value)},m.prototype.hide=function(){this.active=!1,this.setSearchRange(null),this.editor.off("changeSession",this.setSession),this.editor.off("input",this.$onEditorInput),this.element.style.display="none",this.editor.keyBinding.removeKeyboardHandler(this.$closeSearchBarKb),this.editor.focus()},m.prototype.show=function(w,x){this.active=!0,this.editor.on("changeSession",this.setSession),this.editor.on("input",this.$onEditorInput),this.element.style.display="",this.replaceOption.checked=x,this.editor.$search.$options.regExp&&(w=g.escapeRegExp(w)),w!=null&&(this.searchInput.value=w),this.searchInput.focus(),this.searchInput.select(),this.editor.keyBinding.addKeyboardHandler(this.$closeSearchBarKb),this.$syncOptions(!0)},m.prototype.isFocused=function(){var w=document.activeElement;return w==this.searchInput||w==this.replaceInput},m})(),o=new p;o.bindKeys({"Ctrl-f|Command-f":function(m){var w=m.isReplace=!m.isReplace;m.replaceBox.style.display=w?"":"none",m.replaceOption.checked=!1,m.$syncOptions(),m.searchInput.focus()},"Ctrl-H|Command-Option-F":function(m){m.editor.getReadOnly()||(m.replaceOption.checked=!0,m.$syncOptions(),m.replaceInput.focus())},"Ctrl-G|Command-G":function(m){m.findNext()},"Ctrl-Shift-G|Command-Shift-G":function(m){m.findPrev()},esc:function(m){setTimeout(function(){m.hide()})},Return:function(m){m.activeInput==m.replaceInput&&m.replace(),m.findNext()},"Shift-Return":function(m){m.activeInput==m.replaceInput&&m.replace(),m.findPrev()},"Alt-Return":function(m){m.activeInput==m.replaceInput&&m.replaceAll(),m.findAll()},"Tab|Shift-Tab":function(m){(m.activeInput==m.replaceInput?m.searchInput:m.replaceInput).focus()}}),o.addCommands([{name:"toggleRegexpMode",bindKey:{win:"Alt-R|Alt-/",mac:"Ctrl-Alt-R|Ctrl-Alt-/"},exec:function(m){m.regExpOption.checked=!m.regExpOption.checked,m.$syncOptions()}},{name:"toggleCaseSensitive",bindKey:{win:"Alt-C|Alt-I",mac:"Ctrl-Alt-R|Ctrl-Alt-I"},exec:function(m){m.caseSensitiveOption.checked=!m.caseSensitiveOption.checked,m.$syncOptions()}},{name:"toggleWholeWords",bindKey:{win:"Alt-B|Alt-W",mac:"Ctrl-Alt-B|Ctrl-Alt-W"},exec:function(m){m.wholeWordOption.checked=!m.wholeWordOption.checked,m.$syncOptions()}},{name:"toggleReplace",exec:function(m){m.replaceOption.checked=!m.replaceOption.checked,m.$syncOptions()}},{name:"searchInSelection",exec:function(m){m.searchOption.checked=!m.searchRange,m.setSearchRange(m.searchOption.checked&&m.editor.getSelectionRange()),m.$syncOptions()}}]);var f=new p([{bindKey:"Esc",name:"closeSearchBar",exec:function(m){m.searchBox.hide()}}]);d.prototype.$searchBarKb=o,d.prototype.$closeSearchBarKb=f,r.SearchBox=d,r.Search=function(m,w){var x=m.searchBox||new d(m),R=m.session.selection.getRange(),T=R.isMultiLine()?"":m.session.getTextRange(R);x.show(T,w)}}),(function(){ace.require(["ace/ext/searchbox"],function(t){e&&(e.exports=t)})})()})(hy)),hy.exports}lT();var fy={exports:{}},py;function cT(){return py||(py=1,(function(e,n){ace.define("ace/ext/hardwrap",["require","exports","module","ace/range","ace/editor","ace/config"],function(t,r,c){function h(p,a){function l(E,k,B){if(!(E.length<k)){var N=E.slice(0,k),M=E.slice(k),$=/^(?:(\s+)|(\S+)(\s+))/.exec(M),A=/(?:(\s+)|(\s+)(\S+))$/.exec(N),D=0,j=0;if(A&&!A[2]&&(D=k-A[1].length,j=k),$&&!$[2]&&(D||(D=k),j=k+$[1].length),D)return{start:D,end:j};if(A&&A[2]&&A.index>B)return{start:A.index,end:A.index+A[2].length};if($&&$[2])return D=k+$[2].length,{start:D,end:D+$[3].length}}}for(var u=a.column||p.getOption("printMarginColumn"),d=a.allowMerge!=0,o=Math.min(a.startRow,a.endRow),f=Math.max(a.startRow,a.endRow),m=p.session;o<=f;){var w=m.getLine(o);if(w.length>u){var x=l(w,u,5);if(x){var R=/^\s*/.exec(w)[0];m.replace(new v(o,x.start,o,x.end),`
1396
+ `+R)}f++}else if(d&&/\S/.test(w)&&o!=f){var T=m.getLine(o+1);if(T&&/\S/.test(T)){var _=w.replace(/\s+$/,""),C=T.replace(/^\s+/,""),P=_+" "+C,x=l(P,u,5);if(x&&x.start>_.length||P.length<u){var O=new v(o,_.length,o+1,T.length-C.length);m.replace(O," "),o--,f--}else _.length<w.length&&m.remove(new v(o,_.length,o,w.length))}}o++}}function g(p){if(p.command.name=="insertstring"&&/\S/.test(p.args)){var a=p.editor,l=a.selection.cursor;if(l.column<=a.renderer.$printMarginColumn)return;var u=a.session.$undoManager.$lastDelta;h(a,{startRow:l.row,endRow:l.row,allowMerge:!1}),u!=a.session.$undoManager.$lastDelta&&a.session.markUndoGroup()}}var v=t("../range").Range,s=t("../editor").Editor;t("../config").defineOptions(s.prototype,"editor",{hardWrap:{set:function(p){p?this.commands.on("afterExec",g):this.commands.off("afterExec",g)},value:!1}}),r.hardWrap=h}),ace.define("ace/keyboard/vim",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/dom","ace/lib/oop","ace/lib/keys","ace/lib/event","ace/search","ace/lib/useragent","ace/search_highlight","ace/commands/multi_select_commands","ace/mode/text","ace/ext/hardwrap","ace/multi_select"],function(t,r,c){function h(b){return{row:b.line,column:b.ch}}function g(b){return new Fe(b.row,b.column)}function v(b,I,S){if(I.line===S.line&&I.ch>=S.ch-1){var z=b.getLine(I.line),F=z.charCodeAt(I.ch);55296<=F&&F<=55551&&(S.ch+=1)}return{start:I,end:S}}function s(b){b.setOption("disableInput",!0),b.setOption("showCursorWhenSelecting",!1),Ue.signal(b,"vim-mode-change",{mode:"normal"}),b.on("cursorActivity",Qi),P(b),Ue.on(b.getInputField(),"paste",a(b))}function p(b){b.setOption("disableInput",!1),b.off("cursorActivity",Qi),Ue.off(b.getInputField(),"paste",a(b)),b.state.vim=null,xn&&clearTimeout(xn)}function a(b){var I=b.state.vim;return I.onPasteFn||(I.onPasteFn=function(){I.insertMode||(b.setCursor(ee(b.getCursor(),0,1)),sr.enterInsertMode(b,{},I))}),I.onPasteFn}function l(b,I){return I>=b.firstLine()&&I<=b.lastLine()}function u(b){return/^[a-z]$/.test(b)}function d(b){return"()[]{}".indexOf(b)!=-1}function o(b){return is.test(b)}function f(b){return We.test(b)}function m(b){return/^\s*$/.test(b)}function w(b){return".?!".indexOf(b)!=-1}function x(b,I){for(var S=0;S<I.length;S++)if(I[S]==b)return!0;return!1}function R(b,I,S,z,F){if(I===void 0&&!F)throw Error("defaultValue is required unless callback is provided");if(S||(S="string"),rt[b]={type:S,defaultValue:I,callback:F},z)for(var W=0;W<z.length;W++)rt[z[W]]=rt[b];I&&T(b,I)}function T(b,I,S,z){var F=rt[b];z=z||{};var W=z.scope;if(!F)return new Error("Unknown option: "+b);if(F.type=="boolean"){if(I&&I!==!0)return new Error("Invalid argument: "+b+"="+I);I!==!1&&(I=!0)}F.callback?(W!=="local"&&F.callback(I,void 0),W!=="global"&&S&&F.callback(I,S)):(W!=="local"&&(F.value=F.type=="boolean"?!!I:I),W!=="global"&&S&&(S.state.vim.options[b]={value:I}))}function _(b,I,S){var z=rt[b];S=S||{};var F=S.scope;if(!z)return new Error("Unknown option: "+b);if(z.callback){var W=I&&z.callback(void 0,I);return F!=="global"&&W!==void 0?W:F!=="local"?z.callback():void 0}var W=F!=="global"&&I&&I.state.vim.options[b];return(W||F!=="local"&&z||{}).value}function C(){this.latestRegister=void 0,this.isPlaying=!1,this.isRecording=!1,this.replaySearchQueries=[],this.onRecordingDone=void 0,this.lastInsertModeChanges=bn()}function P(b){return b.state.vim||(b.state.vim={inputState:new $,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}),b.state.vim}function O(){Ve={searchQuery:null,searchIsReversed:!1,lastSubstituteReplacePart:void 0,jumpList:rn(),macroModeState:new C,lastCharacterSearch:{increment:0,forward:!0,selectedCharacter:""},registerController:new q({}),searchHistoryController:new Q,exCommandHistoryController:new Q};for(var b in rt){var I=rt[b];I.value=I.defaultValue}}function E(b){function I(K){typeof K=="string"?qt.value=K:qt=null}if(b[0]=="<"){var S=b.toLowerCase().slice(1,-1),z=S.split("-");if(S=z.pop()||"",S=="lt")b="<";else if(S=="space")b=" ";else if(S=="cr")b=`
1397
+ `;else if(Wo[S]){var F=qt.value,W={key:Wo[S],target:{value:F,selectionEnd:F.length,selectionStart:F.length}};qt.onKeyDown&&qt.onKeyDown(W,qt.value,I),qt&&qt.onKeyUp&&qt.onKeyUp(W,qt.value,I);return}}if(b==`
1398
+ `){var G=qt;qt=null,G.onClose&&G.onClose(G.value)}else qt.value=(qt.value||"")+b}function k(b,I,S){var z=mi;if(S){if(ln.indexOf(S)!=-1)return;ln.push(S),mi=S.noremap!=0}try{for(var F=P(b),W=/<(?:[CSMA]-)*\w+>|./gi,G;G=W.exec(I);){var K=G[0],Z=F.insertMode;if(qt){E(K);continue}var se=xt.handleKey(b,K,"mapping");if(!se&&Z&&F.insertMode){if(K[0]=="<"){var de=K.toLowerCase().slice(1,-1),ke=de.split("-");if(de=ke.pop()||"",de=="lt")K="<";else if(de=="space")K=" ";else if(de=="cr")K=`
1399
+ `;else{if(Wo.hasOwnProperty(de)){K=Wo[de],Xo(b,K);continue}K=K[0],W.lastIndex=G.index+1}}b.replaceSelection(K)}}}finally{if(ln.pop(),mi=ln.length?z:!1,!ln.length&&qt){var Te=qt;qt=null,Nr(b,Te)}}}function B(b,I){var S=b.key;if(!yr[S]){S.length>1&&S[0]=="n"&&(S=S.replace("Numpad","")),S=ri[S]||S;var z="";if(b.ctrlKey&&(z+="C-"),b.altKey&&(z+="A-"),b.metaKey&&(z+="M-"),Ue.isMac&&b.altKey&&!b.metaKey&&!b.ctrlKey&&(z=z.slice(2)),(z||S.length>1)&&b.shiftKey&&(z+="S-"),I&&!I.expectLiteralNext&&S.length==1){if(Tn.keymap&&S in Tn.keymap)(Tn.remapCtrl!=0||!z)&&(S=Tn.keymap[S]);else if(S.charCodeAt(0)>255){var F=b.code&&b.code.slice(-1)||"";b.shiftKey||(F=F.toLowerCase()),F&&(S=F)}}return z+=S,z.length>1&&(z="<"+z+">"),z}}function N(b,I){Tn.string!==b&&(Tn=M(b)),Tn.remapCtrl=I}function M(b){function I(z){return z.split(/\\?(.)/).filter(Boolean)}var S={};return b?(b.split(/((?:[^\\,]|\\.)+),/).map(function(z){if(z){var F=z.split(/((?:[^\\;]|\\.)+);/);if(F.length==3){var W=I(F[1]),G=I(F[2]);if(W.length!==G.length)return;for(var K=0;K<W.length;++K)S[W[K]]=G[K]}else if(F.length==1){var Z=I(z);if(Z.length%2!==0)return;for(var K=0;K<Z.length;K+=2)S[Z[K]]=Z[K+1]}}}),{keymap:S,string:b}):{keymap:S,string:""}}function $(){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(b,I){b.state.vim.inputState=new $,b.state.vim.expectLiteralNext=!1,Ue.signal(b,"vim-command-done",I)}function D(){this.removed=[],this.inserted=""}function j(b,I,S){this.clear(),this.keyBuffer=[b||""],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!!I,this.blockwise=!!S}function U(b,I){var S=Ve.registerController.registers;if(!b||b.length!=1)throw Error("Register name must be 1 character");S[b]=I,Oe.push(b)}function q(b){this.registers=b,this.unnamedRegister=b['"']=new j,b["."]=new j,b[":"]=new j,b["/"]=new j,b["+"]=new j}function Q(){this.historyBuffer=[],this.iterator=0,this.initialPrefix=null}function re(b,I){Qn[b]=I}function le(b,I){for(var S=[],z=0;z<I;z++)S.push(b);return S}function ne(b,I){Vs[b]=I}function ue(b,I){sr[b]=I}function he(b,I,S){var z=b.state.vim,F=z.insertMode||z.visualMode,W=Math.min(Math.max(b.firstLine(),I.line),b.lastLine()),G=b.getLine(W),K=G.length-1+ +!!F,Z=Math.min(Math.max(0,I.ch),K),se=G.charCodeAt(Z);if(56320<=se&&se<=57343){var de=1;S&&S.line==W&&S.ch>Z&&(de=-1),Z+=de,Z>K&&(Z-=2)}return new Fe(W,Z)}function oe(b){var I={};for(var S in b)b.hasOwnProperty(S)&&(I[S]=b[S]);return I}function ee(b,I,S){return typeof I=="object"&&(S=I.ch,I=I.line),new Fe(b.line+I,b.ch+S)}function ye(b,I,S,z){z.operator&&(S="operatorPending");for(var F,W=[],G=[],K=mi?I.length-xo:0,Z=K;Z<I.length;Z++){var se=I[Z];S=="insert"&&se.context!="insert"||se.context&&se.context!=S||z.operator&&se.type=="action"||!(F=we(b,se.keys))||(F=="partial"&&W.push(se),F=="full"&&G.push(se))}return{partial:W.length&&W,full:G.length&&G}}function we(b,I){var S=I.slice(-11)=="<character>",z=I.slice(-10)=="<register>";if(S||z){var F=I.length-(S?11:10),W=b.slice(0,F),G=I.slice(0,F);return W==G&&b.length>F?"full":G.indexOf(W)==0?"partial":!1}return b==I?"full":I.indexOf(b)==0?"partial":!1}function Ae(b){var I=/^.*(<[^>]+>)$/.exec(b),S=I?I[1]:b.slice(-1);if(S.length>1)switch(S){case"<CR>":S=`
1400
+ `;break;case"<Space>":S=" ";break;default:S=""}return S}function Je(b,I,S){return function(){for(var z=0;z<S;z++)I(b)}}function ze(b){return new Fe(b.line,b.ch)}function Ye(b,I){return b.ch==I.ch&&b.line==I.line}function Ze(b,I){return b.line<I.line?!0:b.line==I.line&&b.ch<I.ch}function at(b,I){return arguments.length>2&&(I=at.apply(void 0,Array.prototype.slice.call(arguments,1))),Ze(b,I)?b:I}function ct(b,I){return arguments.length>2&&(I=ct.apply(void 0,Array.prototype.slice.call(arguments,1))),Ze(b,I)?I:b}function Ft(b,I,S){var z=Ze(b,I),F=Ze(I,S);return z&&F}function Ie(b,I){return b.getLine(I).length}function Ct(b){return b.trim?b.trim():b.replace(/^\s+|\s+$/g,"")}function St(b){return b.replace(/([.?*+$\[\]\/\\(){}|\-])/g,"\\$1")}function Vt(b,I,S){var z=Ie(b,I),F=new Array(S-z+1).join(" ");b.setCursor(new Fe(I,z)),b.replaceRange(F,b.getCursor())}function hn(b,I){var S=[],z=b.listSelections(),F=ze(b.clipPos(I)),W=!Ye(I,F),G=b.getCursor("head"),K=mt(z,G),Z=Ye(z[K].head,z[K].anchor),se=z.length-1,de=se-K>K?se:0,ke=z[de].anchor,Te=Math.min(ke.line,F.line),Ce=Math.max(ke.line,F.line),$e=ke.ch,Be=F.ch,De=z[de].head.ch-$e,et=Be-$e;De>0&&et<=0?($e++,W||Be--):De<0&&et>=0?($e--,Z||Be++):De<0&&et==-1&&($e--,Be++);for(var kt=Te;kt<=Ce;kt++){var ut={anchor:new Fe(kt,$e),head:new Fe(kt,Be)};S.push(ut)}return b.setSelections(S),I.ch=Be,ke.ch=$e,ke}function $n(b,I,S){for(var z=[],F=0;F<S;F++){var W=ee(I,F,0);z.push({anchor:W,head:W})}b.setSelections(z,0)}function mt(b,I,S){for(var z=0;z<b.length;z++){var F=Ye(b[z].anchor,I),W=Ye(b[z].head,I);if(F||W)return z}return-1}function it(b,I){var S=I.lastSelection,z=function(){var W=b.listSelections(),G=W[0],K=W[W.length-1],Z=Ze(G.anchor,G.head)?G.anchor:G.head,se=Ze(K.anchor,K.head)?K.head:K.anchor;return[Z,se]},F=function(){var W=b.getCursor(),G=b.getCursor(),K=S.visualBlock;if(K){var Z=K.width,se=K.height;G=new Fe(W.line+se,W.ch+Z);for(var de=[],ke=W.line;ke<G.line;ke++){var Te=new Fe(ke,W.ch),Ce=new Fe(ke,G.ch),$e={anchor:Te,head:Ce};de.push($e)}b.setSelections(de)}else{var Be=S.anchorMark.find(),De=S.headMark.find(),et=De.line-Be.line,kt=De.ch-Be.ch;G={line:G.line+et,ch:et?G.ch:kt+G.ch},S.visualLine&&(W=new Fe(W.line,0),G=new Fe(G.line,Ie(b,G.line))),b.setSelection(W,G)}return[W,G]};return I.visualMode?z():F()}function Gt(b,I){var S=I.sel.anchor,z=I.sel.head;I.lastPastedText&&(z=b.posFromIndex(b.indexFromPos(S)+I.lastPastedText.length),I.lastPastedText=null),I.lastSelection={anchorMark:b.setBookmark(S),headMark:b.setBookmark(z),anchor:ze(S),head:ze(z),visualMode:I.visualMode,visualLine:I.visualLine,visualBlock:I.visualBlock}}function Fn(b,I,S,z){var F=b.state.vim.sel,W=z?I:F.head,G=z?I:F.anchor,K;return Ze(S,I)&&(K=S,S=I,I=K),Ze(W,G)?(W=at(I,W),G=ct(G,S)):(G=at(I,G),W=ct(W,S),W=ee(W,0,-1),W.ch==-1&&W.line!=b.firstLine()&&(W=new Fe(W.line-1,Ie(b,W.line-1)))),[G,W]}function Sn(b,I,F){var z=b.state.vim;I=I||z.sel;var F=F||z.visualLine?"line":z.visualBlock?"block":"char",W=Dn(b,I,F);b.setSelections(W.ranges,W.primary)}function Dn(b,I,S,z){var F=ze(I.head),W=ze(I.anchor);if(S=="char"){var G=!z&&!Ze(I.head,I.anchor)?1:0,K=Ze(I.head,I.anchor)?1:0;return F=ee(I.head,0,G),W=ee(I.anchor,0,K),{ranges:[{anchor:W,head:F}],primary:0}}if(S=="line"){if(Ze(I.head,I.anchor))F.ch=0,W.ch=Ie(b,W.line);else{W.ch=0;var Z=b.lastLine();F.line>Z&&(F.line=Z),F.ch=Ie(b,F.line)}return{ranges:[{anchor:W,head:F}],primary:0}}if(S=="block"){var se=Math.min(W.line,F.line),de=W.ch,ke=Math.max(W.line,F.line),Te=F.ch;de<Te?Te+=1:de+=1;for(var Ce=ke-se+1,$e=F.line==se?0:Ce-1,Be=[],De=0;De<Ce;De++)Be.push({anchor:new Fe(se+De,de),head:new Fe(se+De,Te)});return{ranges:Be,primary:$e}}}function Gn(b){var I=b.getCursor("head");return b.getSelection().length==1&&(I=at(I,b.getCursor("anchor"))),I}function Ln(b,I){var S=b.state.vim;I!==!1&&b.setCursor(he(b,S.sel.head)),Gt(b,S),S.visualMode=!1,S.visualLine=!1,S.visualBlock=!1,S.insertMode||Ue.signal(b,"vim-mode-change",{mode:"normal"})}function qn(b,I,S){var z=b.getRange(I,S);if(/\n\s*$/.test(z)){var F=z.split(`
1401
+ `);F.pop();for(var W,W=F.pop();F.length>0&&W&&m(W);W=F.pop())S.line--,S.ch=0;W?(S.line--,S.ch=Ie(b,S.line)):S.ch=0}}function tr(b,I,S){I.ch=0,S.ch=0,S.line++}function dn(b){if(!b)return 0;var I=b.search(/\S/);return I==-1?b.length:I}function Pn(b,I,S){var z=I.inclusive,F=I.innerWord,W=I.bigWord,G=I.noSymbol,K=I.multiline,Z=S||Gn(b),se=b.getLine(Z.line),de=se,ke=Z.line,Te=ke,Ce=Z.ch,$e,Be=G?X[0]:xe[0];if(F&&/\s/.test(se.charAt(Ce)))Be=function(Hn){return/\s/.test(Hn)};else{for(;!Be(se.charAt(Ce));)if(Ce++,Ce>=se.length){if(!K)return null;Ce--,$e=fo(b,Z,!0,W,!0);break}W?Be=xe[0]:(Be=X[0],Be(se.charAt(Ce))||(Be=X[1]))}for(var De=Ce,et=Ce;Be(se.charAt(et))&&et>=0;)et--;if(et++,$e)De=$e.to,Te=$e.line,de=b.getLine(Te),!de&&De==0&&De++;else for(;Be(se.charAt(De))&&De<se.length;)De++;if(z){var kt=De,ut=Z.ch<=et&&/\s/.test(se.charAt(Z.ch));if(!ut)for(;/\s/.test(de.charAt(De))&&De<de.length;)De++;if(kt==De||ut){for(var pt=et;/\s/.test(se.charAt(et-1))&&et>0;)et--;!et&&!ut&&(et=pt)}}return{start:new Fe(ke,et),end:new Fe(Te,De)}}function Ti(b,I,S){var z=I;if(!Ue.findMatchingTag||!Ue.findEnclosingTag)return{start:z,end:z};var F=Ue.findMatchingTag(b,I)||Ue.findEnclosingTag(b,I);return!F||!F.open||!F.close?{start:z,end:z}:S?{start:F.open.from,end:F.close.to}:{start:F.open.to,end:F.close.from}}function Xr(b,I,S){Ye(I,S)||Ve.jumpList.add(b,I,S)}function ei(b,I){Ve.lastCharacterSearch.increment=b,Ve.lastCharacterSearch.forward=I.forward,Ve.lastCharacterSearch.selectedCharacter=I.selectedCharacter}function Ei(b,I,S,z){var F=ze(b.getCursor()),W=S?1:-1,G=S?b.lineCount():-1,K=F.ch,Z=F.line,se=b.getLine(Z),de={lineText:se,nextCh:se.charAt(K),lastCh:null,index:K,symb:z,reverseSymb:(S?{")":"(","}":"{"}:{"(":")","{":"}"})[z],forward:S,depth:0,curMoveThrough:!1},ke=to[z];if(!ke)return F;var Te=no[ke].init,Ce=no[ke].isComplete;for(Te&&Te(de);Z!==G&&I;){if(de.index+=W,de.nextCh=de.lineText.charAt(de.index),!de.nextCh){if(Z+=W,de.lineText=b.getLine(Z)||"",W>0)de.index=0;else{var $e=de.lineText.length;de.index=$e>0?$e-1:0}de.nextCh=de.lineText.charAt(de.index)}Ce(de)&&(F.line=Z,F.ch=de.index,I--)}return de.nextCh||de.curMoveThrough?new Fe(Z,de.index):F}function fo(b,I,S,z,F){var W=I.line,G=I.ch,K=b.getLine(W),Z=S?1:-1,se=z?xe:X;if(F&&K==""){if(W+=Z,K=b.getLine(W),!l(b,W))return null;G=S?0:K.length}for(;;){if(F&&K=="")return{from:0,to:0,line:W};for(var de=Z>0?K.length:-1,ke=de,Te=de;G!=de;){for(var Ce=!1,$e=0;$e<se.length&&!Ce;++$e)if(se[$e](K.charAt(G))){for(ke=G;G!=de&&se[$e](K.charAt(G));)G+=Z;if(Te=G,Ce=ke!=Te,ke==I.ch&&W==I.line&&Te==ke+Z)continue;return{from:Math.min(ke,Te+1),to:Math.max(ke,Te),line:W}}Ce||(G+=Z)}if(W+=Z,!l(b,W))return null;K=b.getLine(W),G=Z>0?0:K.length}}function vr(b,I,S,z,F,W){var G=ze(I),K=[];(z&&!F||!z&&F)&&S++;for(var Z=!z||!F,se=0;se<S;se++){var de=fo(b,I,z,W,Z);if(!de){var ke=Ie(b,b.lastLine());K.push(z?{line:b.lastLine(),from:ke,to:ke}:{line:0,from:0,to:0});break}K.push(de),I=new Fe(de.line,z?de.to-1:de.from)}var Te=K.length!=S,Ce=K[0],$e=K.pop();return z&&!F?(!Te&&(Ce.from!=G.ch||Ce.line!=G.line)&&($e=K.pop()),new Fe($e.line,$e.from)):z&&F?new Fe($e.line,$e.to-1):!z&&F?(!Te&&(Ce.to!=G.ch||Ce.line!=G.line)&&($e=K.pop()),new Fe($e.line,$e.to)):new Fe($e.line,$e.from)}function Ji(b,I,S,z,F){var W=I,G=new Fe(W.line+S.repeat-1,1/0),K=b.clipPos(G);return K.ch--,F||(z.lastHPos=1/0,z.lastHSPos=b.charCoords(K,"div").left),G}function jr(b,I,S,z,F){for(var W=F||b.getCursor(),G=W.ch,K,Z=0;Z<I;Z++){var se=b.getLine(W.line);if(K=Hs(G,se,z,S),K==-1)return null;G=K}return new Fe(b.getCursor().line,K)}function po(b,I){var S=b.getCursor().line;return he(b,new Fe(S,I-1))}function ur(b,I,S,z){!x(S,Me)&&!Ke.test(S)||(I.marks[S]&&I.marks[S].clear(),I.marks[S]=b.setBookmark(z))}function Hs(b,I,S,z,F){var W;return z?(W=I.indexOf(S,b+1),W!=-1):(W=I.lastIndexOf(S,b-1),W!=-1),W}function gs(b,I,S,z,F){function W(et){return!/\S/.test(b.getLine(et))}function G(et,kt,ut){return ut?W(et)!=W(et+kt):!W(et)&&W(et+kt)}function K(et){z=z>0?1:-1;var kt=b.ace.session.getFoldLine(et);kt&&et+z>kt.start.row&&et+z<kt.end.row&&(z=(z>0?kt.end.row:kt.start.row)-et)}var Z=I.line,se=b.firstLine(),de=b.lastLine(),ke,Te,Ce=Z;if(z){for(;se<=Ce&&Ce<=de&&S>0;)K(Ce),G(Ce,z)&&S--,Ce+=z;return new Fe(Ce,0)}var $e=b.state.vim;if($e.visualLine&&G(Z,1,!0)){var Be=$e.sel.anchor;G(Be.line,-1,!0)&&(!F||Be.line!=Z)&&(Z+=1)}var De=W(Z);for(Ce=Z;Ce<=de&&S;Ce++)G(Ce,1,!0)&&(!F||W(Ce)!=De)&&S--;for(Te=new Fe(Ce,0),Ce>de&&!De?De=!0:F=!1,Ce=Z;Ce>se&&!((!F||W(Ce)==De||Ce==Z)&&G(Ce,-1,!0));Ce--);return ke=new Fe(Ce,0),{start:ke,end:Te}}function Ko(b,I,S,z,F){function W(se){se.pos+se.dir<0||se.pos+se.dir>=se.line.length?se.line=null:se.pos+=se.dir}function G(se,de,ke,Te){var Ce=se.getLine(de),$e={line:Ce,ln:de,pos:ke,dir:Te};if($e.line==="")return{ln:$e.ln,pos:$e.pos};var Be=$e.pos;for(W($e);$e.line!==null;){if(Be=$e.pos,w($e.line[$e.pos])){if(!F)return{ln:$e.ln,pos:$e.pos+1};for(W($e);$e.line!==null&&m($e.line[$e.pos]);)Be=$e.pos,W($e);return{ln:$e.ln,pos:Be+1}}W($e)}return{ln:$e.ln,pos:Be+1}}function K(se,de,ke,Te){var Ce=se.getLine(de),$e={line:Ce,ln:de,pos:ke,dir:Te};if($e.line==="")return{ln:$e.ln,pos:$e.pos};var Be=$e.pos;for(W($e);$e.line!==null;){if(!m($e.line[$e.pos])&&!w($e.line[$e.pos]))Be=$e.pos;else if(w($e.line[$e.pos]))return F?m($e.line[$e.pos+1])?{ln:$e.ln,pos:$e.pos+1}:{ln:$e.ln,pos:Be}:{ln:$e.ln,pos:Be};W($e)}return $e.line=Ce,F&&m($e.line[$e.pos])?{ln:$e.ln,pos:$e.pos}:{ln:$e.ln,pos:Be}}for(var Z={ln:I.line,pos:I.ch};S>0;)z<0?Z=K(b,Z.ln,Z.pos,z):Z=G(b,Z.ln,Z.pos,z),S--;return new Fe(Z.ln,Z.pos)}function Ii(b,I,S,z){function F(Z,se){if(se.pos+se.dir<0||se.pos+se.dir>=se.line.length){if(se.ln+=se.dir,!l(Z,se.ln)){se.line=null,se.ln=null,se.pos=null;return}se.line=Z.getLine(se.ln),se.pos=se.dir>0?0:se.line.length-1}else se.pos+=se.dir}function W(Z,se,de,ke){var De=Z.getLine(se),Te=De==="",Ce={line:De,ln:se,pos:de,dir:ke},$e={ln:Ce.ln,pos:Ce.pos},Be=Ce.line==="";for(F(Z,Ce);Ce.line!==null;){if($e.ln=Ce.ln,$e.pos=Ce.pos,Ce.line===""&&!Be)return{ln:Ce.ln,pos:Ce.pos};if(Te&&Ce.line!==""&&!m(Ce.line[Ce.pos]))return{ln:Ce.ln,pos:Ce.pos};w(Ce.line[Ce.pos])&&!Te&&(Ce.pos===Ce.line.length-1||m(Ce.line[Ce.pos+1]))&&(Te=!0),F(Z,Ce)}var De=Z.getLine($e.ln);$e.pos=0;for(var et=De.length-1;et>=0;--et)if(!m(De[et])){$e.pos=et;break}return $e}function G(Z,se,de,ke){var Be=Z.getLine(se),Te={line:Be,ln:se,pos:de,dir:ke},Ce={ln:Te.ln,pos:null},$e=Te.line==="";for(F(Z,Te);Te.line!==null;){if(Te.line===""&&!$e)return Ce.pos!==null?Ce:{ln:Te.ln,pos:Te.pos};if(!(!w(Te.line[Te.pos])||Ce.pos===null||Te.ln===Ce.ln&&Te.pos+1===Ce.pos))return Ce;Te.line!==""&&!m(Te.line[Te.pos])&&($e=!1,Ce={ln:Te.ln,pos:Te.pos}),F(Z,Te)}var Be=Z.getLine(Ce.ln);Ce.pos=0;for(var De=0;De<Be.length;++De)if(!m(Be[De])){Ce.pos=De;break}return Ce}for(var K={ln:I.line,pos:I.ch};S>0;)z<0?K=G(b,K.ln,K.pos,z):K=W(b,K.ln,K.pos,z),S--;return new Fe(K.ln,K.pos)}function Yn(b,I,S,z){var F=I,W,G,K={"(":/[()]/,")":/[()]/,"[":/[[\]]/,"]":/[[\]]/,"{":/[{}]/,"}":/[{}]/,"<":/[<>]/,">":/[<>]/}[S],Z={"(":"(",")":"(","[":"[","]":"[","{":"{","}":"{","<":"<",">":"<"}[S],se=b.getLine(F.line).charAt(F.ch),de=se===Z?1:0;if(W=b.scanForBracket(new Fe(F.line,F.ch+de),-1,void 0,{bracketRegex:K}),G=b.scanForBracket(new Fe(F.line,F.ch+de),1,void 0,{bracketRegex:K}),!W||!G)return null;if(W=W.pos,G=G.pos,W.line==G.line&&W.ch>G.ch||W.line>G.line){var ke=W;W=G,G=ke}return z?G.ch+=1:W.ch+=1,{start:W,end:G}}function $r(b,I,S,z){var F=ze(I),W=b.getLine(F.line),G=W.split(""),K,Z,se,de,ke=G.indexOf(S);if(F.ch<ke)F.ch=ke;else if(ke<F.ch&&G[F.ch]==S){var Te=/string/.test(b.getTokenTypeAt(ee(I,0,1))),Ce=/string/.test(b.getTokenTypeAt(I)),$e=Te&&!Ce;$e||(Z=F.ch,--F.ch)}if(G[F.ch]==S&&!Z)K=F.ch+1;else for(se=F.ch;se>-1&&!K;se--)G[se]==S&&(K=se+1);if(K&&!Z)for(se=K,de=G.length;se<de&&!Z;se++)G[se]==S&&(Z=se);return!K||!Z?{start:F,end:F}:(z&&(--K,++Z),{start:new Fe(F.line,K),end:new Fe(F.line,Z)})}function Or(){}function mn(b){var I=b.state.vim;return I.searchState_||(I.searchState_=new Or)}function jn(b){return hi(b,"/")}function Mi(b){return ms(b,"/")}function hi(b,I){var S=ms(b,I)||[];if(!S.length)return[];var z=[];if(S[0]===0){for(var F=0;F<S.length;F++)typeof S[F]=="number"&&z.push(b.substring(S[F]+1,S[F+1]));return z}}function ms(b,I){I||(I="/");for(var S=!1,z=[],F=0;F<b.length;F++){var W=b.charAt(F);!S&&W==I&&z.push(F),S=!S&&W=="\\"}return z}function vs(b){for(var I="|(){",S="}",z=!1,F=[],W=-1;W<b.length;W++){var G=b.charAt(W)||"",K=b.charAt(W+1)||"",Z=K&&I.indexOf(K)!=-1;z?((G!=="\\"||!Z)&&F.push(G),z=!1):G==="\\"?(z=!0,K&&S.indexOf(K)!=-1&&(Z=!0),(!Z||K==="\\")&&F.push(G)):(F.push(G),Z&&K!=="\\"&&F.push("\\"))}return F.join("")}function ys(b){for(var I=!1,S=[],z=-1;z<b.length;z++){var F=b.charAt(z)||"",W=b.charAt(z+1)||"";Co[F+W]?(S.push(Co[F+W]),z++):I?(S.push(F),I=!1):F==="\\"?(I=!0,o(W)||W==="$"?S.push("$"):W!=="/"&&W!=="\\"&&S.push("\\")):(F==="$"&&S.push("$"),S.push(F),W==="/"&&S.push("\\"))}return S.join("")}function bs(b){for(var I=new Ue.StringStream(b),S=[];!I.eol();){for(;I.peek()&&I.peek()!="\\";)S.push(I.next());var z=!1;for(var F in Ea)if(I.match(F,!0)){z=!0,S.push(Ea[F]);break}z||S.push(I.next())}return S.join("")}function di(b,I,S){var z=Ve.registerController.getRegister("/");if(z.setText(b),b instanceof RegExp)return b;var F=Mi(b),W,G;if(!F.length)W=b;else{W=b.substring(0,F[0]);var K=b.substring(F[0]);G=K.indexOf("i")!=-1}if(!W)return null;_("pcre")||(W=vs(W)),S&&(I=/^[^A-Z]*$/.test(W));var Z=new RegExp(W,I||G?"im":"m");return Z}function Ri(b){typeof b=="string"&&(b=document.createElement(b));for(var I,S=1;S<arguments.length;S++)if(I=arguments[S])if(typeof I!="object"&&(I=document.createTextNode(I)),I.nodeType)b.appendChild(I);else for(var z in I)Object.prototype.hasOwnProperty.call(I,z)&&(z[0]==="$"?b.style[z.slice(1)]=I[z]:b.setAttribute(z,I[z]));return b}function Dt(b,I){var S=Ri("div",{$color:"red",$whiteSpace:"pre",class:"cm-vim-message"},I);b.openNotification?b.openNotification(S,{bottom:!0,duration:5e3}):alert(S.innerText)}function Us(b,I){return Ri("div",{$display:"flex"},Ri("span",{$fontFamily:"monospace",$whiteSpace:"pre",$flex:1},b,Ri("input",{type:"text",autocorrect:"off",autocapitalize:"off",spellcheck:"false",$width:"100%"})),I&&Ri("span",{$color:"#888"},I))}function Nr(b,I){if(ln.length){I.value||(I.value=""),qt=I;return}var S=Us(I.prefix,I.desc);if(b.openDialog)b.openDialog(S,I.onClose,{onKeyDown:I.onKeyDown,onKeyUp:I.onKeyUp,bottom:!0,selectValueOnOpen:!1,value:I.value});else{var z="";typeof I.prefix!="string"&&I.prefix&&(z+=I.prefix.textContent),I.desc&&(z+=" "+I.desc),I.onClose(prompt(z,""))}}function Pt(b,I){if(b instanceof RegExp&&I instanceof RegExp){for(var S=["global","multiline","ignoreCase","source"],z=0;z<S.length;z++){var F=S[z];if(b[F]!==I[F])return!1}return!0}return!1}function fn(b,I,S,z){if(I){var F=mn(b),W=di(I,!!S,!!z);if(W)return go(b,W),Pt(W,F.getQuery())||F.setQuery(W),W}}function Kn(b){if(b.source.charAt(0)=="^")var I=!0;return{token:function(S){if(I&&!S.sol()){S.skipToEnd();return}var z=S.match(b,!1);if(z)return z[0].length==0?(S.next(),"searching"):!S.sol()&&(S.backUp(1),!b.exec(S.next()+z[0]))?(S.next(),null):(S.match(b),"searching");for(;!S.eol()&&(S.next(),!S.match(b,!1)););},query:b}}function go(b,I){clearTimeout(xn);var S=mn(b);S.highlightTimeout=xn,xn=setTimeout(function(){if(b.state.vim){var z=mn(b);z.highlightTimeout=null;var F=z.getOverlay();(!F||I!=F.query)&&(F&&b.removeOverlay(F),F=Kn(I),b.addOverlay(F),b.showMatchesOnScrollbar&&(z.getScrollbarAnnotate()&&z.getScrollbarAnnotate().clear(),z.setScrollbarAnnotate(b.showMatchesOnScrollbar(I))),z.setOverlay(F))}},50)}function nr(b,I,S,z){return z===void 0&&(z=1),b.operation(function(){for(var F=b.getCursor(),W=b.getSearchCursor(S,F),G=0;G<z;G++){var K=W.find(I);if(G==0&&K&&Ye(W.from(),F)){var Z=I?W.from():W.to();K=W.find(I),K&&!K[0]&&Ye(W.from(),Z)&&b.getLine(Z.line).length==Z.ch&&(K=W.find(I))}if(!K&&(W=b.getSearchCursor(S,I?new Fe(b.lastLine()):new Fe(b.firstLine(),0)),!W.find(I)))return}return W.from()})}function mo(b,I,S,z,F){return z===void 0&&(z=1),b.operation(function(){var W=b.getCursor(),G=b.getSearchCursor(S,W),K=G.find(!I);!F.visualMode&&K&&Ye(G.from(),W)&&G.find(!I);for(var Z=0;Z<z;Z++)if(K=G.find(I),!K&&(G=b.getSearchCursor(S,I?new Fe(b.lastLine()):new Fe(b.firstLine(),0)),!G.find(I)))return;return[G.from(),G.to()]})}function Li(b){var I=mn(b);I.highlightTimeout&&(clearTimeout(I.highlightTimeout),I.highlightTimeout=null),b.removeOverlay(mn(b).getOverlay()),I.setOverlay(null),I.getScrollbarAnnotate()&&(I.getScrollbarAnnotate().clear(),I.setScrollbarAnnotate(null))}function ws(b,I,S){return typeof b!="number"&&(b=b.line),I instanceof Array?x(b,I):typeof S=="number"?b>=I&&b<=S:b==I}function vo(b){var I=b.ace.renderer;return{top:I.getFirstFullyVisibleRow(),bottom:I.getLastFullyVisibleRow()}}function fi(b,I,S){if(S=="'"||S=="`")return Ve.jumpList.find(b,-1)||new Fe(0,0);if(S==".")return Do(b);var z=I.marks[S];return z&&z.find()}function Do(b){if(b.getLastEditEnd)return b.getLastEditEnd();for(var I=b.doc.history.done,S=I.length;S--;)if(I[S].changes)return ze(I[S].changes[0].to)}function ti(b,I,S,z,F,W,G,K,Z){function se(){b.operation(function(){for(;!Be;)de(),Te();Ce()})}function de(){var ut=b.getRange(W.from(),W.to()),pt=ut.replace(G,K),Hn=W.to().line;W.replace(pt),et=W.to().line,F+=et-Hn,kt=et<Hn}function ke(){var ut=De&&ze(W.to()),pt=W.findNext();return pt&&!pt[0]&&ut&&Ye(W.from(),ut)&&(pt=W.findNext()),pt}function Te(){for(;ke()&&ws(W.from(),z,F);)if(!(!S&&W.from().line==et&&!kt)){b.scrollIntoView(W.from(),30),b.setSelection(W.from(),W.to()),De=W.from(),Be=!1;return}Be=!0}function Ce(ut){if(ut&&ut(),b.focus(),De){b.setCursor(De);var pt=b.state.vim;pt.exMode=!1,pt.lastHPos=pt.lastHSPos=De.ch}Z&&Z()}function $e(ut,pt,Hn){Ue.e_stop(ut);var Rt=B(ut);switch(Rt){case"y":de(),Te();break;case"n":Te();break;case"a":var cn=Z;Z=void 0,b.operation(se),Z=cn;break;case"l":de();case"q":case"<Esc>":case"<C-c>":case"<C-[>":Ce(Hn)}return Be&&Ce(Hn),!0}b.state.vim.exMode=!0;var Be=!1,De,et,kt;if(Te(),Be){Dt(b,"No matches for "+G.source);return}if(!I){se(),Z&&Z();return}Nr(b,{prefix:Ri("span","replace with ",Ri("strong",K)," (y/n/a/q/l)"),onKeyDown:$e})}function Dr(b,I){var S=b.state.vim,z=Ve.macroModeState,F=Ve.registerController.getRegister("."),W=z.isPlaying,G=z.lastInsertModeChanges;W||(b.off("change",Qo),S.insertEnd&&S.insertEnd.clear(),S.insertEnd=null,Ue.off(b.getInputField(),"keydown",Bo)),!W&&S.insertModeRepeat>1&&(Cs(b,S,S.insertModeRepeat-1,!0),S.lastEditInputState.repeatOverride=S.insertModeRepeat),delete S.insertModeRepeat,S.insertMode=!1,I||b.setCursor(b.getCursor().line,b.getCursor().ch-1),b.setOption("keyMap","vim"),b.setOption("disableInput",!0),b.toggleOverwrite(!1),F.setText(G.changes.join("")),Ue.signal(b,"vim-mode-change",{mode:"normal"}),z.isRecording&&rr(z)}function yo(b){Wn.unshift(b)}function Oi(b,I,S,z,F){var W={keys:b,type:I};W[I]=S,W[I+"Args"]=z;for(var G in F)W[G]=F[G];yo(W)}function Jo(b,I,S,z){var F=Ve.registerController.getRegister(z);if(z==":"){F.keyBuffer[0]&&ii.processCommand(b,F.keyBuffer[0]),S.isPlaying=!1;return}var W=F.keyBuffer,G=0;S.isPlaying=!0,S.replaySearchQueries=F.searchQueries.slice(0);for(var K=0;K<W.length;K++)for(var Z=W[K],se,de;Z;)if(se=/<\w+-.+?>|<\w+>|./.exec(Z),de=se[0],Z=Z.substring(se.index+de.length),xt.handleKey(b,de,"macro"),I.insertMode){var ke=F.insertModeChanges[G++].changes;Ve.macroModeState.lastInsertModeChanges.changes=ke,es(b,ke,1),Dr(b)}S.isPlaying=!1}function Po(b,I){if(!b.isPlaying){var S=b.latestRegister,z=Ve.registerController.getRegister(S);z&&z.pushText(I)}}function rr(b){if(!b.isPlaying){var I=b.latestRegister,S=Ve.registerController.getRegister(I);S&&S.pushInsertModeChanges&&S.pushInsertModeChanges(b.lastInsertModeChanges)}}function zo(b,I){if(!b.isPlaying){var S=b.latestRegister,z=Ve.registerController.getRegister(S);z&&z.pushSearchQuery&&z.pushSearchQuery(I)}}function Qo(b,I){var S=Ve.macroModeState,z=S.lastInsertModeChanges;if(!S.isPlaying)for(var F=b.state.vim;I;){if(z.expectCursorActivityForChange=!0,z.ignoreCount>1)z.ignoreCount--;else if(I.origin=="+input"||I.origin=="paste"||I.origin===void 0){var W=b.listSelections().length;W>1&&(z.ignoreCount=W);var G=I.text.join(`
1402
+ `);if(z.maybeReset&&(z.changes=[],z.maybeReset=!1),G)if(b.state.overwrite&&!/\n/.test(G))z.changes.push([G]);else{if(G.length>1){var K=F&&F.insertEnd&&F.insertEnd.find(),Z=b.getCursor();if(K&&K.line==Z.line){var se=K.ch-Z.ch;se>0&&se<G.length&&(z.changes.push([G,se]),G="")}}G&&z.changes.push(G)}}I=I.next}}function Qi(b){var I=b.state.vim;if(I.insertMode){var S=Ve.macroModeState;if(S.isPlaying)return;var z=S.lastInsertModeChanges;z.expectCursorActivityForChange?z.expectCursorActivityForChange=!1:(z.maybeReset=!0,I.insertEnd&&I.insertEnd.clear(),I.insertEnd=b.setBookmark(b.getCursor(),{insertLeft:!0}))}else b.curOp.isVimOp||xs(b,I)}function xs(b,I,S){var z=b.getCursor("anchor"),F=b.getCursor("head");if(I.visualMode&&!b.somethingSelected()?Ln(b,!1):!I.visualMode&&!I.insertMode&&b.somethingSelected()&&(I.visualMode=!0,I.visualLine=!1,Ue.signal(b,"vim-mode-change",{mode:"visual"})),I.visualMode){var W=Ze(F,z)?0:-1,G=Ze(F,z)?-1:0;F=ee(F,0,W),z=ee(z,0,G),I.sel={anchor:z,head:F},ur(b,I,"<",at(F,z)),ur(b,I,">",ct(F,z))}else!I.insertMode&&!S&&(I.lastHPos=b.getCursor().ch)}function Zo(b,I){this.keyName=b,this.key=I.key,this.ctrlKey=I.ctrlKey,this.altKey=I.altKey,this.metaKey=I.metaKey,this.shiftKey=I.shiftKey}function Bo(b){var I=Ve.macroModeState,S=I.lastInsertModeChanges,z=Ue.keyName?Ue.keyName(b):b.key;z&&(z.indexOf("Delete")!=-1||z.indexOf("Backspace")!=-1)&&(S.maybeReset&&(S.changes=[],S.maybeReset=!1),S.changes.push(new Zo(z,b)))}function Cs(b,I,S,z){function F(){K?eo.processAction(b,I,I.lastEditActionCommand):eo.evalInput(b,I)}function W(de){if(G.lastInsertModeChanges.changes.length>0){de=I.lastEditActionCommand?de:1;var ke=G.lastInsertModeChanges;es(b,ke.changes,de)}}var G=Ve.macroModeState;G.isPlaying=!0;var K=!!I.lastEditActionCommand,Z=I.inputState;if(I.inputState=I.lastEditInputState,K&&I.lastEditActionCommand.interlaceInsertRepeat)for(var se=0;se<S;se++)F(),W(1);else z||F(),W(S);I.inputState=Z,I.insertMode&&!z&&Dr(b),G.isPlaying=!1}function Xo(b,I){Ue.lookupKey(I,"vim-insert",function(S){return typeof S=="string"?Ue.commands[S](b):S(b),!0})}function es(b,I,S){var z=b.getCursor("head"),F=Ve.macroModeState.lastInsertModeChanges.visualBlock;F&&($n(b,z,F+1),S=b.listSelections().length,b.setCursor(z));for(var W=0;W<S;W++){F&&b.setCursor(ee(z,W,0));for(var G=0;G<I.length;G++){var K=I[G];if(K instanceof Zo)Xo(b,K.keyName);else if(typeof K=="string")b.replaceSelection(K);else{var Z=b.getCursor(),se=ee(Z,0,K[0].length-(K[1]||0));b.replaceRange(K[0],Z,K[1]?Z:se),b.setCursor(se)}}}F&&b.setCursor(ee(z,0,1))}function ks(b,I,S,z){I.length>1&&I[0]=="n"&&(I=I.replace("numpad","")),I=os[I]||I;var F="";if(S.ctrlKey&&(F+="C-"),S.altKey&&(F+="A-"),(F||I.length>1)&&S.shiftKey&&(F+="S-"),z&&!z.expectLiteralNext&&I.length==1){if(Tn.keymap&&I in Tn.keymap)(Tn.remapCtrl!==!1||!F)&&(I=Tn.keymap[I]);else if(I.charCodeAt(0)>255){var W=S.code&&S.code.slice(-1)||"";S.shiftKey||(W=W.toLowerCase()),W&&(I=W)}}return F+=I,F.length>1&&(F="<"+F+">"),F}function Ni(b){var I=new b.constructor;return Object.keys(b).forEach(function(S){if(S!="insertEnd"){var z=b[S];Array.isArray(z)?z=z.slice():z&&typeof z=="object"&&z.constructor!=Object&&(z=Ni(z)),I[S]=z}}),b.sel&&(I.sel={head:b.sel.head&&ze(b.sel.head),anchor:b.sel.anchor&&ze(b.sel.anchor)}),I}function Zi(b,I,S){var z=!1,F=xt.maybeInitVimState_(b),W=F.visualBlock||F.wasInVisualBlock,G=b.ace.inMultiSelectMode;if(F.wasInVisualBlock&&!G?F.wasInVisualBlock=!1:G&&F.visualBlock&&(F.wasInVisualBlock=!0),I=="<Esc>"&&!F.insertMode&&!F.visualMode&&G)b.ace.exitMultiSelectMode();else if(W||!G||b.ace.inVirtualSelectionMode)z=xt.handleKey(b,I,S);else{var K=Ni(F),Z=F.inputState.changeQueueList||[];b.operation(function(){b.curOp.isVimOp=!0;var se=0;b.ace.forEachSelection(function(){var de=b.ace.selection;b.state.vim.lastHPos=de.$desiredColumn==null?de.lead.column:de.$desiredColumn,b.state.vim.inputState.changeQueue=Z[se];var ke=b.getCursor("head"),Te=b.getCursor("anchor"),Ce=Ze(ke,Te)?0:-1,$e=Ze(ke,Te)?-1:0;ke=ee(ke,0,Ce),Te=ee(Te,0,$e),b.state.vim.sel.head=ke,b.state.vim.sel.anchor=Te,z=Hr(b,I,S),de.$desiredColumn=b.state.vim.lastHPos==-1?null:b.state.vim.lastHPos,b.ace.inVirtualSelectionMode&&(Z[se]=b.state.vim.inputState.changeQueue),b.virtualSelectionMode()&&(b.state.vim=Ni(K)),se++}),b.curOp.cursorActivity&&!z&&(b.curOp.cursorActivity=!1),F.status=b.state.vim.status,b.state.vim=F,F.inputState.changeQueueList=Z,F.inputState.changeQueue=null},!0)}return z&&!F.visualMode&&!F.insert&&F.visualMode!=b.somethingSelected()&&xs(b,F,!0),z}function pi(b,I){I.off("beforeEndOperation",pi);var S=I.state.cm.vimCmd;S&&I.execCommand(S.exec?S:S.name,S.args),I.curOp=I.prevOp}var or=t("../range").Range,bo=t("../lib/event_emitter").EventEmitter,Jn=t("../lib/dom"),wo=t("../lib/oop"),Pr=t("../lib/keys"),ts=t("../lib/event"),ni=t("../search").Search,Fo=t("../lib/useragent"),jo=t("../search_highlight").SearchHighlight,Wr=t("../commands/multi_select_commands"),ns=t("../mode/text").Mode.prototype.tokenRe,Xi=t("../ext/hardwrap").hardWrap;t("../multi_select");var Ue=function(b){this.ace=b,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)};Ue.Pos=function(b,I){if(!(this instanceof Fe))return new Fe(b,I);this.line=b,this.ch=I},Ue.defineOption=function(b,I,S){},Ue.commands={redo:function(b){b.ace.redo()},undo:function(b){b.ace.undo()},newlineAndIndent:function(b){b.ace.insert(`
1403
+ `)},goLineLeft:function(b){b.ace.selection.moveCursorLineStart()},goLineRight:function(b){b.ace.selection.moveCursorLineEnd()}},Ue.keyMap={},Ue.addClass=Ue.rmClass=function(){},Ue.e_stop=Ue.e_preventDefault=ts.stopEvent,Ue.keyName=function(b){var I=Pr[b.keyCode]||b.key||"";return I.length==1&&(I=I.toUpperCase()),I=ts.getModifierString(b).replace(/(^|-)\w/g,function(S){return S.toUpperCase()})+I,I},Ue.keyMap.default=function(b){return function(I){var S=I.ace.commands.commandKeyBinding[b.toLowerCase()];return S&&I.ace.execCommand(S)!==!1}},Ue.lookupKey=function b(I,S,z){S||(S="default"),typeof S=="string"&&(S=Ue.keyMap[S]||Ue.keyMap.default);var F=typeof S=="function"?S(I):S[I];if(F===!1)return"nothing";if(F==="...")return"multi";if(F!=null&&z(F))return"handled";if(S.fallthrough){if(!Array.isArray(S.fallthrough))return b(I,S.fallthrough,z);for(var W=0;W<S.fallthrough.length;W++){var G=b(I,S.fallthrough[W],z);if(G)return G}}},Ue.findMatchingTag=function(b,I){return b.findMatchingTag(I)},Ue.findEnclosingTag=function(b,I){},Ue.signal=function(b,I,S){return b._signal(I,S)},Ue.on=ts.addListener,Ue.off=ts.removeListener,Ue.isWordChar=function(b){return b<""?/^\w$/.test(b):(ns.lastIndex=0,ns.test(b))},(function(){wo.implement(Ue.prototype,bo),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(S){this.$lineHandleChanges&&this.$lineHandleChanges.push(S);var z={text:S.action[0]=="i"?S.lines:[]},F=this.curOp=this.curOp||{};F.changeHandlers||(F.changeHandlers=this._eventRegistry.change&&this._eventRegistry.change.slice()),F.lastChange?F.lastChange.next=F.lastChange=z:F.lastChange=F.change=z,this.$updateMarkers(S)},this.onSelectionChange=function(){var S=this.curOp=this.curOp||{};S.cursorActivityHandlers||(S.cursorActivityHandlers=this._eventRegistry.cursorActivity&&this._eventRegistry.cursorActivity.slice()),this.curOp.cursorActivity=!0,this.ace.inMultiSelectMode&&this.ace.keyBinding.removeKeyboardHandler(Wr.keyboardHandler)},this.operation=function(S,z){if(!z&&this.curOp||z&&this.curOp&&this.curOp.force)return S();if((z||!this.ace.curOp)&&this.curOp&&this.onBeforeEndOperation(),!this.ace.curOp){var F=this.ace.prevOp;this.ace.startOperation({command:{name:"vim",scrollIntoView:"cursor"}})}var W=this.curOp=this.curOp||{};this.curOp.force=z;var G=S();return this.ace.curOp&&this.ace.curOp.command.name=="vim"&&(this.state.dialog&&(this.ace.curOp.command.scrollIntoView=this.ace.curOp.vimDialogScroll),this.ace.endOperation(),!W.cursorActivity&&!W.lastChange&&F&&(this.ace.prevOp=F)),(z||!this.ace.curOp)&&this.curOp&&this.onBeforeEndOperation(),G},this.onBeforeEndOperation=function(){var S=this.curOp;S&&(S.change&&this.signal("change",S.change,S),S&&S.cursorActivity&&this.signal("cursorActivity",null,S),this.curOp=null)},this.signal=function(S,z,F){var W=F?F[S+"Handlers"]:(this._eventRegistry||{})[S];if(W){W=W.slice();for(var G=0;G<W.length;G++)W[G](this,z)}},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(S,z){typeof S=="object"&&(z=S.ch,S=S.line);var F=!this.curOp&&!this.ace.inVirtualSelectionMode;this.ace.inVirtualSelectionMode||this.ace.exitMultiSelectMode(),this.ace.session.unfold({row:S,column:z}),this.ace.selection.moveTo(S,z),F&&(this.ace.renderer.scrollCursorIntoView(),this.ace.endOperation())},this.getCursor=function(S){var z=this.ace.selection,F=S=="anchor"?z.isEmpty()?z.lead:z.anchor:S=="head"||!S?z.lead:z.getRange()[S];return g(F)},this.listSelections=function(S){var z=this.ace.multiSelect.rangeList.ranges;return!z.length||this.ace.inVirtualSelectionMode?[{anchor:this.getCursor("anchor"),head:this.getCursor("head")}]:z.map(function(F){return{anchor:this.clipPos(g(F.cursor==F.end?F.start:F.end)),head:this.clipPos(g(F.cursor))}},this)},this.setSelections=function(S,z){var F=this.ace.multiSelect,W=S.map(function(se){var de=h(se.anchor),ke=h(se.head),Te=or.comparePoints(de,ke)<0?new or.fromPoints(de,ke):new or.fromPoints(ke,de);return Te.cursor=or.comparePoints(Te.start,ke)?Te.end:Te.start,Te});if(this.ace.inVirtualSelectionMode){this.ace.selection.fromOrientedRange(W[0]);return}z?W[z]&&W.push(W.splice(z,1)[0]):W=W.reverse(),F.toSingleRange(W[0].clone());for(var G=this.ace.session,K=0;K<W.length;K++){var Z=G.$clipRangeToDocument(W[K]);F.addRange(Z)}},this.setSelection=function(S,z,F){var W=this.ace.selection;W.moveTo(S.line,S.ch),W.selectTo(z.line,z.ch),F&&F.origin=="*mouse"&&this.onBeforeEndOperation()},this.somethingSelected=function(S){return!this.ace.selection.isEmpty()},this.clipPos=function(S){var z=this.ace.session.$clipPositionToDocument(S.line,S.ch);return g(z)},this.foldCode=function(S){this.ace.session.$toggleFoldWidget(S.line,{})},this.markText=function(S){return{clear:function(){},find:function(){}}},this.$updateMarkers=function(S){var z=S.action=="insert",F=S.start,W=S.end,G=(W.row-F.row)*(z?1:-1),K=(W.column-F.column)*(z?1:-1);z&&(W=F);for(var Z in this.marks){var se=this.marks[Z],de=or.comparePoints(se,F);if(!(de<0)){if(de===0&&z)if(!se.$insertRight)de=1;else{if(se.bias!=1){se.bias=-1;continue}de=1}var ke=z?de:or.comparePoints(se,W);if(ke>0){se.row+=G,se.column+=se.row==W.row?K:0;continue}!z&&ke<=0&&(se.row=F.row,se.column=F.column,ke===0&&(se.bias=1))}}};var b=function(S,z,F,W){this.cm=S,this.id=z,this.row=F,this.column=W,S.marks[this.id]=this};b.prototype.clear=function(){delete this.cm.marks[this.id]},b.prototype.find=function(){return g(this)},this.setBookmark=function(S,z){var F=new b(this,this.$uid++,S.line,S.ch);return(!z||!z.insertLeft)&&(F.$insertRight=!0),this.marks[F.id]=F,F},this.moveH=function(S,z){if(z=="char"){var F=this.ace.selection;F.clearSelection(),F.moveCursorBy(0,S)}},this.findPosV=function(S,z,F,W){if(F=="page"){var G=this.ace.renderer,K=G.layerConfig;z*=Math.floor(K.height/K.lineHeight),F="line"}if(F=="line"){var Z=this.ace.session.documentToScreenPosition(S.line,S.ch);W!=null&&(Z.column=W),Z.row+=z,Z.row=Math.min(Math.max(0,Z.row),this.ace.session.getScreenLength()-1);var se=this.ace.session.screenToDocumentPosition(Z.row,Z.column);return g(se)}debugger},this.charCoords=function(S,z){if(z=="div"||!z){var F=this.ace.session.documentToScreenPosition(S.line,S.ch);return{left:F.column,top:F.row}}if(z=="local"){var W=this.ace.renderer,F=this.ace.session.documentToScreenPosition(S.line,S.ch),G=W.layerConfig.lineHeight,K=W.layerConfig.characterWidth,Z=G*F.row;return{left:F.column*K,top:Z,bottom:Z+G}}},this.coordsChar=function(S,z){var F=this.ace.renderer;if(z=="local"){var W=Math.max(0,Math.floor(S.top/F.lineHeight)),G=Math.max(0,Math.floor(S.left/F.characterWidth)),K=F.session.screenToDocumentPosition(W,G);return g(K)}if(z=="div")throw"not implemented"},this.getSearchCursor=function(S,z,F){var W=!1,G=!1;S instanceof RegExp&&!S.global&&(W=!S.ignoreCase,S=S.source,G=!0),S=="\\n"&&(S=`
1404
+ `,G=!1);var K=new ni;z.ch==null&&(z.ch=Number.MAX_VALUE);var Z={row:z.line,column:z.ch},se=this,de=null;return{findNext:function(){return this.find(!1)},findPrevious:function(){return this.find(!0)},find:function(ke){K.setOptions({needle:S,caseSensitive:W,wrap:!1,backwards:ke,regExp:G,start:de||Z});var Te=K.find(se.ace.session);return de=Te,de&&[!de.isEmpty()]},from:function(){return de&&g(de.start)},to:function(){return de&&g(de.end)},replace:function(ke){de&&(de.end=se.ace.session.doc.replace(de,ke))}}},this.scrollTo=function(S,z){var F=this.ace.renderer,W=F.layerConfig,G=W.maxHeight;G-=(F.$size.scrollerHeight-F.lineHeight)*F.$scrollPastEnd,z!=null&&this.ace.session.setScrollTop(Math.max(0,Math.min(z,G))),S!=null&&this.ace.session.setScrollLeft(Math.max(0,Math.min(S,W.width)))},this.scrollInfo=function(){return 0},this.scrollIntoView=function(S,z){if(S){var F=this.ace.renderer,W={top:0,bottom:z};F.scrollCursorIntoView(h(S),F.lineHeight*2/F.$size.scrollerHeight,W)}},this.getLine=function(S){return this.ace.session.getLine(S)},this.getRange=function(S,z){return this.ace.session.getTextRange(new or(S.line,S.ch,z.line,z.ch))},this.replaceRange=function(S,z,F){F||(F=z);var W=new or(z.line,z.ch,F.line,F.ch);return this.ace.session.$clipRangeToDocument(W),this.ace.session.replace(W,S)},this.replaceSelection=this.replaceSelections=function(S){var z=Array.isArray(S)&&S,F=this.ace.selection;if(this.ace.inVirtualSelectionMode){this.ace.session.replace(F.getRange(),z?S[0]||"":S);return}F.inVirtualSelectionMode=!0;var W=F.rangeList.ranges;W.length||(W=[this.ace.multiSelect.getRange()]);for(var G=W.length;G--;)this.ace.session.replace(W[G],z?S[G]||"":S);F.inVirtualSelectionMode=!1},this.getSelection=function(){return this.ace.getSelectedText()},this.getSelections=function(){return this.listSelections().map(function(S){return this.getRange(S.anchor,S.head)},this)},this.getInputField=function(){return this.ace.textInput.getElement()},this.getWrapperElement=function(){return this.ace.container};var I={indentWithTabs:"useSoftTabs",indentUnit:"tabSize",tabSize:"tabSize",firstLineNumber:"firstLineNumber",readOnly:"readOnly"};this.setOption=function(S,z){switch(this.state[S]=z,S){case"indentWithTabs":S=I[S],z=!z;break;case"keyMap":this.state.$keyMap=z;return;default:S=I[S]}S&&this.ace.setOption(S,z)},this.getOption=function(S){var z,F=I[S];switch(F&&(z=this.ace.getOption(F)),S){case"indentWithTabs":return S=I[S],!z;case"keyMap":return this.state.$keyMap||"vim"}return F?z:this.state[S]},this.toggleOverwrite=function(S){return this.state.overwrite=S,this.ace.setOverwrite(S)},this.addOverlay=function(S){if(!this.$searchHighlight||!this.$searchHighlight.session){var z=new jo(null,"ace_highlight-marker","text"),F=this.ace.session.addDynamicMarker(z);z.id=F.id,z.session=this.ace.session,z.destroy=function(G){z.session.off("change",z.updateOnChange),z.session.off("changeEditor",z.destroy),z.session.removeMarker(z.id),z.session=null},z.updateOnChange=function(G){var K=G.start.row;K==G.end.row?z.cache[K]=void 0:z.cache.splice(K,z.cache.length)},z.session.on("changeEditor",z.destroy),z.session.on("change",z.updateOnChange)}var W=new RegExp(S.query.source,"gmi");this.$searchHighlight=S.highlight=z,this.$searchHighlight.setRegexp(W),this.ace.renderer.updateBackMarkers()},this.removeOverlay=function(S){this.$searchHighlight&&this.$searchHighlight.session&&this.$searchHighlight.destroy()},this.getScrollInfo=function(){var S=this.ace.renderer,z=S.layerConfig;return{left:S.scrollLeft,top:S.scrollTop,height:z.maxHeight,width:z.width,clientHeight:z.height,clientWidth:z.width}},this.getValue=function(){return this.ace.getValue()},this.setValue=function(S){return this.ace.setValue(S,-1)},this.getTokenTypeAt=function(S){var z=this.ace.session.getTokenAt(S.line,S.ch);return z&&/comment|string/.test(z.type)?"string":""},this.findMatchingBracket=function(S){var z=this.ace.session.findMatchingBracket(h(S));return{to:z&&g(z)}},this.findMatchingTag=function(S){var z=this.ace.session.getMatchingTags(h(S));if(z)return{open:{from:g(z.openTag.start),to:g(z.openTag.end)},close:{from:g(z.closeTag.start),to:g(z.closeTag.end)}}},this.indentLine=function(S,z){z===!0?this.ace.session.indentRows(S,S," "):z===!1&&this.ace.session.outdentRows(new or(S,0,S,0))},this.indexFromPos=function(S){return this.ace.session.doc.positionToIndex(h(S))},this.posFromIndex=function(S){return g(this.ace.session.doc.indexToPosition(S))},this.focus=function(S){return this.ace.textInput.focus()},this.blur=function(S){return this.ace.blur()},this.defaultTextHeight=function(S){return this.ace.renderer.layerConfig.lineHeight},this.scanForBracket=function(S,z,F,W){var G=W.bracketRegex.source,K=/paren|text|operator|tag/;if(z==1)var Z=this.ace.session.$findClosingBracket(G.slice(1,2),h(S),K);else{var Z=this.ace.session.$findOpeningBracket(G.slice(-2,-1),{row:S.line,column:S.ch+1},K);!Z&&W.bracketRegex&&W.bracketRegex.test(this.getLine(S.line)[S.ch-1])&&(Z={row:S.line,column:S.ch-1})}return Z&&{pos:g(Z)}},this.refresh=function(){return this.ace.resize(!0)},this.getMode=function(){return{name:this.getOption("mode")}},this.execCommand=function(S){if(Ue.commands.hasOwnProperty(S))return Ue.commands[S](this);if(S=="indentAuto")return this.ace.execCommand("autoindent");console.log(S+" is not implemented")},this.getLineNumber=function(S){var z=this.$lineHandleChanges;if(!z)return null;for(var F=S.row,W=0;W<z.length;W++){var G=z[W];if(G.start.row!=G.end.row){if(G.action[0]=="i")G.start.row<F&&(F+=G.end.row-G.start.row);else if(G.start.row<F){if(F<G.end.row||F==G.end.row&&G.start.column>0)return null;F-=G.end.row-G.start.row}}}return F},this.getLineHandle=function(S){return this.$lineHandleChanges||(this.$lineHandleChanges=[]),{text:this.ace.session.getLine(S),row:S}},this.releaseLineHandles=function(){this.$lineHandleChanges=void 0},this.getLastEditEnd=function(){var S=this.ace.session.$undoManager;if(S&&S.$lastDelta)return g(S.$lastDelta.end)}}).call(Ue.prototype);var rs=Ue.StringStream=function(b,I){this.pos=this.start=0,this.string=b,this.tabSize=I||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0};rs.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(b){var I=this.string.charAt(this.pos);if(typeof b=="string")var S=I==b;else var S=I&&(b.test?b.test(I):b(I));if(S)return++this.pos,I},eatWhile:function(b){for(var I=this.pos;this.eat(b););return this.pos>I},eatSpace:function(){for(var b=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>b},skipToEnd:function(){this.pos=this.string.length},skipTo:function(b){var I=this.string.indexOf(b,this.pos);if(I>-1)return this.pos=I,!0},backUp:function(b){this.pos-=b},column:function(){throw"not implemented"},indentation:function(){throw"not implemented"},match:function(b,I,S){if(typeof b!="string"){var z=this.string.slice(this.pos).match(b);return z&&z.index>0?null:(z&&I!==!1&&(this.pos+=z[0].length),z)}var F=function(G){return S?G.toLowerCase():G},W=this.string.substr(this.pos,b.length);if(F(W)==F(b))return I!==!1&&(this.pos+=b.length),!0},current:function(){return this.string.slice(this.start,this.pos)},hideFirstChars:function(b,I){this.lineStart+=b;try{return I()}finally{this.lineStart-=b}}},Ue.defineExtension=function(b,I){Ue.prototype[b]=I},Jn.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 b(S,z,F){var W=S.ace.container,G;return G=W.appendChild(document.createElement("div")),F?G.className="ace_dialog ace_dialog-bottom":G.className="ace_dialog ace_dialog-top",typeof z=="string"?G.innerHTML=z:G.appendChild(z),G}function I(S,z){S.state.currentNotificationClose&&S.state.currentNotificationClose(),S.state.currentNotificationClose=z}Ue.defineExtension("openDialog",function(S,z,F){function W(ke){if(typeof ke=="string")se.value=ke;else{if(K||ke&&ke.type=="blur"&&document.activeElement===se)return;Z.state.dialog==G&&(Z.state.dialog=null,Z.focus()),K=!0,G.remove(),F.onClose&&F.onClose(G);var Te=Z;Te.state.vim&&(Te.state.vim.status=null,Te.ace._signal("changeStatus"),Te.ace.renderer.$loop.schedule(Te.ace.renderer.CHANGE_CURSOR))}}if(!this.virtualSelectionMode()){F||(F={}),I(this,null);var G=b(this,S,F.bottom),K=!1,Z=this;this.state.dialog=G;var se=G.getElementsByTagName("input")[0],de;return se?(F.value&&(se.value=F.value,F.selectValueOnOpen!==!1&&se.select()),F.onInput&&Ue.on(se,"input",function(ke){F.onInput(ke,se.value,W)}),F.onKeyUp&&Ue.on(se,"keyup",function(ke){F.onKeyUp(ke,se.value,W)}),Ue.on(se,"keydown",function(ke){F&&F.onKeyDown&&F.onKeyDown(ke,se.value,W)||(ke.keyCode==13&&z(se.value),(ke.keyCode==27||F.closeOnEnter!==!1&&ke.keyCode==13)&&(Ue.e_stop(ke),W()))}),F.closeOnBlur!==!1&&Ue.on(se,"blur",W),se.focus()):(de=G.getElementsByTagName("button")[0])&&(Ue.on(de,"click",function(){W(),Z.focus()}),F.closeOnBlur!==!1&&Ue.on(de,"blur",W),de.focus()),W}}),Ue.defineExtension("openNotification",function(S,z){function F(){G||(G=!0,clearTimeout(K),W.remove())}if(!this.virtualSelectionMode()){I(this,F);var W=b(this,S,z&&z.bottom),G=!1,K,Z=z&&typeof z.duration<"u"?z.duration:5e3;return Ue.on(W,"click",function(se){Ue.e_preventDefault(se),F()}),Z&&(K=setTimeout(F,Z)),F}})})();var Fe=Ue.Pos,Wn=[{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"}],xo=Wn.length,gi=[{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"}],Tn=M(""),is=/[\d]/,X=[Ue.isWordChar,function(b){return b&&!Ue.isWordChar(b)&&!/\s/.test(b)}],xe=[function(b){return/\S/.test(b)}],Me=["<",">"],Oe=["-",'"',".",":","_","/","+"],Ke=/^\w$/,We;try{We=new RegExp("^[\\p{Lu}]$","u")}catch{We=/^[A-Z]$/}var rt={};R("filetype",void 0,"string",["ft"],function(b,I){if(I!==void 0){if(b===void 0){var S=I.getOption("mode");return S=="null"?"":S}var S=b==""?"null":b;I.setOption("mode",S)}}),R("textwidth",80,"number",["tw"],function(b,I){if(I!==void 0){if(b===void 0){var S=I.getOption("textwidth");return S}var z=Math.round(b);z>1&&I.setOption("textwidth",z)}});var rn=function(){function b(Z,se,de){function ke(Be){var De=++F%z,et=K[De];et&&et.clear(),K[De]=Z.setBookmark(Be)}var Te=F%z,Ce=K[Te];if(Ce){var $e=Ce.find();$e&&!Ye($e,se)&&ke(se)}else ke(se);ke(de),W=F,G=F-z+1,G<0&&(G=0)}function I(Z,se){F+=se,F>W?F=W:F<G&&(F=G);var de=K[(z+F)%z];if(de&&!de.find()){var ke=se>0?1:-1,Te,Ce=Z.getCursor();do if(F+=ke,de=K[(z+F)%z],de&&(Te=de.find())&&!Ye(Ce,Te))break;while(F<W&&F>G)}return de}function S(Z,se){var de=F,ke=I(Z,se);return F=de,ke&&ke.find()}var z=100,F=-1,W=0,G=0,K=new Array(z);return{cachedCursor:void 0,add:b,find:S,move:I}},bn=function(b){return b?{changes:b.changes,expectCursorActivityForChange:b.expectCursorActivityForChange}:{changes:[],expectCursorActivityForChange:!1}};C.prototype={exitMacroRecordMode:function(){var b=Ve.macroModeState;b.onRecordingDone&&b.onRecordingDone(),b.onRecordingDone=void 0,b.isRecording=!1},enterMacroRecordMode:function(b,I){var S=Ve.registerController.getRegister(I);if(S){if(S.clear(),this.latestRegister=I,b.openDialog){var z=Ri("span",{class:"cm-vim-message"},"recording @"+I);this.onRecordingDone=b.openDialog(z,null,{bottom:!0})}this.isRecording=!0}}};var Ve,jt,xt={enterVimMode:s,leaveVimMode:p,buildKeyMap:function(){},getRegisterController:function(){return Ve.registerController},resetVimGlobalState_:O,getVimGlobalState_:function(){return Ve},maybeInitVimState_:P,suppressErrorLogging:!1,InsertModeKey:Zo,map:function(b,I,S){ii.map(b,I,S)},unmap:function(b,I){return ii.unmap(b,I)},noremap:function(b,I,S){ii.map(b,I,S,!0)},mapclear:function(b){var I=Wn.length,S=xo,z=Wn.slice(0,I-S);if(Wn=Wn.slice(I-S),b)for(var F=z.length-1;F>=0;F--){var W=z[F];if(b!==W.context)if(W.context)this._mapCommand(W);else{var G=["normal","insert","visual"];for(var K in G)if(G[K]!==b){var Z={};for(var se in W)Z[se]=W[se];Z.context=G[K],this._mapCommand(Z)}}}},langmap:N,vimKeyFromEvent:B,setOption:T,getOption:_,defineOption:R,defineEx:function(b,I,S){if(!I)I=b;else if(b.indexOf(I)!==0)throw new Error('(Vim.defineEx) "'+I+'" is not a prefix of "'+b+'", command not registered');Sr[b]=S,ii.commandMap_[I]={name:b,shortName:I,type:"api"}},handleKey:function(b,I,S){var z=this.findKey(b,I,S);if(typeof z=="function")return z()},multiSelectHandleKey:Zi,findKey:function(b,I,S){function z(){var se=Ve.macroModeState;if(se.isRecording){if(I=="q")return se.exitMacroRecordMode(),A(b),!0;S!="mapping"&&Po(se,I)}}function F(){if(I=="<Esc>"){if(K.visualMode)Ln(b);else{if(!K.insertMode)return;Dr(b)}return A(b),!0}}function W(){if(F())return!0;K.inputState.keyBuffer.push(I);var se=K.inputState.keyBuffer.join(""),de=I.length==1,ke=eo.matchCommand(se,Wn,K.inputState,"insert"),Te=K.inputState.changeQueue;if(ke.type=="none")return A(b),!1;if(ke.type=="partial"){if(ke.expectLiteralNext&&(K.expectLiteralNext=!0),jt&&window.clearTimeout(jt),jt=de&&window.setTimeout(function(){K.insertMode&&K.inputState.keyBuffer.length&&A(b)},_("insertModeEscKeysTimeout")),de){var Ce=b.listSelections();(!Te||Te.removed.length!=Ce.length)&&(Te=K.inputState.changeQueue=new D),Te.inserted+=I;for(var $e=0;$e<Ce.length;$e++){var Be=at(Ce[$e].anchor,Ce[$e].head),De=ct(Ce[$e].anchor,Ce[$e].head),et=b.getRange(Be,b.state.overwrite?ee(De,0,1):De);Te.removed[$e]=(Te.removed[$e]||"")+et}}return!de}if(K.expectLiteralNext=!1,jt&&window.clearTimeout(jt),ke.command&&Te){for(var Ce=b.listSelections(),$e=0;$e<Ce.length;$e++){var kt=Ce[$e].head;b.replaceRange(Te.removed[$e]||"",ee(kt,0,-Te.inserted.length),kt,"+input")}Ve.macroModeState.lastInsertModeChanges.changes.pop()}return ke.command||A(b),ke.command}function G(){if(z()||F())return!0;K.inputState.keyBuffer.push(I);var se=K.inputState.keyBuffer.join("");if(/^[1-9]\d*$/.test(se))return!0;var de=/^(\d*)(.*)$/.exec(se);if(!de)return A(b),!1;var ke=K.visualMode?"visual":"normal",Te=de[2]||de[1];K.inputState.operatorShortcut&&K.inputState.operatorShortcut.slice(-1)==Te&&(Te=K.inputState.operatorShortcut);var Ce=eo.matchCommand(Te,Wn,K.inputState,ke);return Ce.type=="none"?(A(b),!1):Ce.type=="partial"?(Ce.expectLiteralNext&&(K.expectLiteralNext=!0),!0):Ce.type=="clear"?(A(b),!0):(K.expectLiteralNext=!1,K.inputState.keyBuffer.length=0,de=/^(\d*)(.*)$/.exec(se),de[1]&&de[1]!="0"&&K.inputState.pushRepeatDigit(de[1]),Ce.command)}var K=P(b),Z;return K.insertMode?Z=W():Z=G(),Z===!1?!K.insertMode&&I.length===1?function(){return!0}:void 0:Z===!0?function(){return!0}:function(){if(!((Z.operator||Z.isEdit)&&b.getOption("readOnly")))return b.operation(function(){b.curOp.isVimOp=!0;try{Z.type=="keyToKey"?k(b,Z.toKeys,Z):eo.processCommand(b,K,Z)}catch(se){throw b.state.vim=void 0,P(b),xt.suppressErrorLogging||console.log(se),se}return!0})}},handleEx:function(b,I){ii.processCommand(b,I)},defineMotion:re,defineAction:ue,defineOperator:ne,mapCommand:Oi,_mapCommand:yo,defineRegister:U,exitVisualMode:Ln,exitInsertMode:Dr},ln=[],mi=!1,qt,ri={Return:"CR",Backspace:"BS",Delete:"Del",Escape:"Esc",Insert:"Ins",ArrowLeft:"Left",ArrowRight:"Right",ArrowUp:"Up",ArrowDown:"Down",Enter:"CR"," ":"Space"},yr={Shift:1,Alt:1,Command:1,Control:1,CapsLock:1,AltGraph:1,Dead:1,Unidentified:1},Wo={};"Left|Right|Up|Down|End|Home".split("|").concat(Object.keys(ri)).forEach(function(b){Wo[(ri[b]||"").toLowerCase()]=Wo[b.toLowerCase()]=b}),R("langmap",void 0,"string",["lmap"],function(b,I){if(b===void 0)return Tn.string;N(b)}),$.prototype.pushRepeatDigit=function(b){this.operator?this.motionRepeat=this.motionRepeat.concat(b):this.prefixRepeat=this.prefixRepeat.concat(b)},$.prototype.getRepeat=function(){var b=0;return(this.prefixRepeat.length>0||this.motionRepeat.length>0)&&(b=1,this.prefixRepeat.length>0&&(b*=parseInt(this.prefixRepeat.join(""),10)),this.motionRepeat.length>0&&(b*=parseInt(this.motionRepeat.join(""),10))),b},j.prototype={setText:function(b,I,S){this.keyBuffer=[b||""],this.linewise=!!I,this.blockwise=!!S},pushText:function(b,I){I&&(this.linewise||this.keyBuffer.push(`
1438
+ `),this.linewise=!0),this.keyBuffer.push(b)},pushInsertModeChanges:function(b){this.insertModeChanges.push(bn(b))},pushSearchQuery:function(b){this.searchQueries.push(b)},clear:function(){this.keyBuffer=[],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!1},toString:function(){return this.keyBuffer.join("")}},q.prototype={pushText:function(b,I,S,z,F){if(b!=="_"){z&&S.charAt(S.length-1)!==`
1439
+ `&&(S+=`
1440
+ `);var W=this.isValidRegister(b)?this.getRegister(b):null;if(!W){switch(I){case"yank":this.registers[0]=new j(S,z,F);break;case"delete":case"change":S.indexOf(`
1441
+ `)==-1?this.registers["-"]=new j(S,z):(this.shiftNumericRegisters_(),this.registers[1]=new j(S,z))}this.unnamedRegister.setText(S,z,F);return}var G=f(b);G?W.pushText(S,z):W.setText(S,z,F),b==="+"&&typeof navigator<"u"&&typeof navigator.clipboard<"u"&&typeof navigator.clipboard.readText=="function"&&navigator.clipboard.writeText(S),this.unnamedRegister.setText(W.toString(),z)}},getRegister:function(b){return this.isValidRegister(b)?(b=b.toLowerCase(),this.registers[b]||(this.registers[b]=new j),this.registers[b]):this.unnamedRegister},isValidRegister:function(b){return b&&(x(b,Oe)||Ke.test(b))},shiftNumericRegisters_:function(){for(var b=9;b>=2;b--)this.registers[b]=this.getRegister(""+(b-1))}},Q.prototype={nextMatch:function(b,I){var S=this.historyBuffer,z=I?-1:1;this.initialPrefix===null&&(this.initialPrefix=b);for(var F=this.iterator+z;I?F>=0:F<S.length;F+=z)for(var W=S[F],G=0;G<=W.length;G++)if(this.initialPrefix==W.substring(0,G))return this.iterator=F,W;if(F>=S.length)return this.iterator=S.length,this.initialPrefix;if(F<0)return b},pushInput:function(b){var I=this.historyBuffer.indexOf(b);I>-1&&this.historyBuffer.splice(I,1),b.length&&this.historyBuffer.push(b)},reset:function(){this.initialPrefix=null,this.iterator=this.historyBuffer.length}};var eo={matchCommand:function(b,I,S,z){var F=ye(b,I,z,S);if(!F.full&&!F.partial)return{type:"none"};if(!F.full&&F.partial)return{type:"partial",expectLiteralNext:F.partial.length==1&&F.partial[0].keys.slice(-11)=="<character>"};for(var W,G=0;G<F.full.length;G++){var K=F.full[G];W||(W=K)}if(W.keys.slice(-11)=="<character>"||W.keys.slice(-10)=="<register>"){var Z=Ae(b);if(!Z||Z.length>1)return{type:"clear"};S.selectedCharacter=Z}return{type:"full",command:W}},processCommand:function(b,I,S){switch(I.inputState.repeatOverride=S.repeatOverride,S.type){case"motion":this.processMotion(b,I,S);break;case"operator":this.processOperator(b,I,S);break;case"operatorMotion":this.processOperatorMotion(b,I,S);break;case"action":this.processAction(b,I,S);break;case"search":this.processSearch(b,I,S);break;case"ex":case"keyToEx":this.processEx(b,I,S);break}},processMotion:function(b,I,S){I.inputState.motion=S.motion,I.inputState.motionArgs=oe(S.motionArgs),this.evalInput(b,I)},processOperator:function(b,I,S){var z=I.inputState;if(z.operator){if(z.operator==S.operator){z.motion="expandToLine",z.motionArgs={linewise:!0},this.evalInput(b,I);return}A(b)}z.operator=S.operator,z.operatorArgs=oe(S.operatorArgs),S.keys.length>1&&(z.operatorShortcut=S.keys),S.exitVisualBlock&&(I.visualBlock=!1,Sn(b)),I.visualMode&&this.evalInput(b,I)},processOperatorMotion:function(b,I,S){var z=I.visualMode,F=oe(S.operatorMotionArgs);F&&z&&F.visualLine&&(I.visualLine=!0),this.processOperator(b,I,S),z||this.processMotion(b,I,S)},processAction:function(b,I,S){var z=I.inputState,F=z.getRepeat(),W=!!F,G=oe(S.actionArgs)||{};z.selectedCharacter&&(G.selectedCharacter=z.selectedCharacter),S.operator&&this.processOperator(b,I,S),S.motion&&this.processMotion(b,I,S),(S.motion||S.operator)&&this.evalInput(b,I),G.repeat=F||1,G.repeatIsExplicit=W,G.registerName=z.registerName,A(b),I.lastMotion=null,S.isEdit&&this.recordLastEdit(I,z,S),sr[S.action](b,G,I)},processSearch:function(b,I,S){function z(De,et,kt){Ve.searchHistoryController.pushInput(De),Ve.searchHistoryController.reset();try{fn(b,De,et,kt)}catch{Dt(b,"Invalid regex: "+De),A(b);return}eo.processMotion(b,I,{type:"motion",motion:"findNext",motionArgs:{forward:!0,toJumplist:S.searchArgs.toJumplist}})}function F(De){z(De,!0,!0);var et=Ve.macroModeState;et.isRecording&&zo(et,De)}function W(De,et,kt){var ut=B(De),pt,Hn;ut=="<Up>"||ut=="<Down>"?(pt=ut=="<Up>",Hn=De.target?De.target.selectionEnd:0,et=Ve.searchHistoryController.nextMatch(et,pt)||"",kt(et),Hn&&De.target&&(De.target.selectionEnd=De.target.selectionStart=Math.min(Hn,De.target.value.length))):ut&&ut!="<Left>"&&ut!="<Right>"&&Ve.searchHistoryController.reset();var Rt;try{Rt=fn(b,et,!0,!0)}catch{}Rt?b.scrollIntoView(nr(b,!K,Rt),30):(Li(b),b.scrollTo(ke.left,ke.top))}function G(De,et,kt){var ut=B(De);ut=="<Esc>"||ut=="<C-c>"||ut=="<C-[>"||ut=="<BS>"&&et==""?(Ve.searchHistoryController.pushInput(et),Ve.searchHistoryController.reset(),fn(b,de),Li(b),b.scrollTo(ke.left,ke.top),Ue.e_stop(De),A(b),kt(),b.focus()):ut=="<Up>"||ut=="<Down>"?Ue.e_stop(De):ut=="<C-u>"&&(Ue.e_stop(De),kt(""))}if(b.getSearchCursor){var K=S.searchArgs.forward,Z=S.searchArgs.wholeWordOnly;mn(b).setReversed(!K);var se=K?"/":"?",de=mn(b).getQuery(),ke=b.getScrollInfo();switch(S.searchArgs.querySrc){case"prompt":var Te=Ve.macroModeState;if(Te.isPlaying){var Be=Te.replaySearchQueries.shift();z(Be,!0,!1)}else Nr(b,{onClose:F,prefix:se,desc:"(JavaScript regexp)",onKeyUp:W,onKeyDown:G});break;case"wordUnderCursor":var Ce=Pn(b,{noSymbol:!0}),$e=!0;if(Ce||(Ce=Pn(b,{noSymbol:!1}),$e=!1),!Ce){Dt(b,"No word under cursor"),A(b);return}var Be=b.getLine(Ce.start.line).substring(Ce.start.ch,Ce.end.ch);$e&&Z?Be="\\b"+Be+"\\b":Be=St(Be),Ve.jumpList.cachedCursor=b.getCursor(),b.setCursor(Ce.start),z(Be,!0,!1)}}},processEx:function(b,I,S){function z(W){Ve.exCommandHistoryController.pushInput(W),Ve.exCommandHistoryController.reset(),ii.processCommand(b,W),b.state.vim&&A(b)}function F(W,G,K){var Z=B(W),se,de;(Z=="<Esc>"||Z=="<C-c>"||Z=="<C-[>"||Z=="<BS>"&&G=="")&&(Ve.exCommandHistoryController.pushInput(G),Ve.exCommandHistoryController.reset(),Ue.e_stop(W),A(b),K(),b.focus()),Z=="<Up>"||Z=="<Down>"?(Ue.e_stop(W),se=Z=="<Up>",de=W.target?W.target.selectionEnd:0,G=Ve.exCommandHistoryController.nextMatch(G,se)||"",K(G),de&&W.target&&(W.target.selectionEnd=W.target.selectionStart=Math.min(de,W.target.value.length))):Z=="<C-u>"?(Ue.e_stop(W),K("")):Z&&Z!="<Left>"&&Z!="<Right>"&&Ve.exCommandHistoryController.reset()}S.type=="keyToEx"?ii.processCommand(b,S.exArgs.input):I.visualMode?Nr(b,{onClose:z,prefix:":",value:"'<,'>",onKeyDown:F,selectValueOnOpen:!1}):Nr(b,{onClose:z,prefix:":",onKeyDown:F})},evalInput:function(b,I){var S=I.inputState,z=S.motion,F=S.motionArgs||{},W=S.operator,G=S.operatorArgs||{},K=S.registerName,Z=I.sel,se=ze(I.visualMode?he(b,Z.head):b.getCursor("head")),de=ze(I.visualMode?he(b,Z.anchor):b.getCursor("anchor")),ke=ze(se),Te=ze(de),Ce,$e,Be;if(W&&this.recordLastEdit(I,S),S.repeatOverride!==void 0?Be=S.repeatOverride:Be=S.getRepeat(),Be>0&&F.explicitRepeat?F.repeatIsExplicit=!0:(F.noRepeat||!F.explicitRepeat&&Be===0)&&(Be=1,F.repeatIsExplicit=!1),S.selectedCharacter&&(F.selectedCharacter=G.selectedCharacter=S.selectedCharacter),F.repeat=Be,A(b),z){var De=Qn[z](b,se,F,I,S);if(I.lastMotion=Qn[z],!De)return;if(F.toJumplist){!W&&b.ace.curOp!=null&&(b.ace.curOp.command.scrollIntoView="center-animate");var et=Ve.jumpList,kt=et.cachedCursor;kt?(Xr(b,kt,De),delete et.cachedCursor):Xr(b,se,De)}De instanceof Array?($e=De[0],Ce=De[1]):Ce=De,Ce||(Ce=ze(se)),I.visualMode?((!I.visualBlock||Ce.ch!==1/0)&&(Ce=he(b,Ce,ke)),$e&&($e=he(b,$e)),$e=$e||Te,Z.anchor=$e,Z.head=Ce,Sn(b),ur(b,I,"<",Ze($e,Ce)?$e:Ce),ur(b,I,">",Ze($e,Ce)?Ce:$e)):W||(b.ace.curOp&&(b.ace.curOp.vimDialogScroll="center-animate"),Ce=he(b,Ce,ke),b.setCursor(Ce.line,Ce.ch))}if(W){if(G.lastSel){$e=Te;var ut=G.lastSel,pt=Math.abs(ut.head.line-ut.anchor.line),Hn=Math.abs(ut.head.ch-ut.anchor.ch);ut.visualLine?Ce=new Fe(Te.line+pt,Te.ch):ut.visualBlock?Ce=new Fe(Te.line+pt,Te.ch+Hn):ut.head.line==ut.anchor.line?Ce=new Fe(Te.line,Te.ch+Hn):Ce=new Fe(Te.line+pt,Te.ch),I.visualMode=!0,I.visualLine=ut.visualLine,I.visualBlock=ut.visualBlock,Z=I.sel={anchor:$e,head:Ce},Sn(b)}else I.visualMode&&(G.lastSel={anchor:ze(Z.anchor),head:ze(Z.head),visualBlock:I.visualBlock,visualLine:I.visualLine});var Rt,cn,Bt,Ot,br;if(I.visualMode){Rt=at(Z.head,Z.anchor),cn=ct(Z.head,Z.anchor),Bt=I.visualLine||G.linewise,Ot=I.visualBlock?"block":Bt?"line":"char";var Tr=v(b,Rt,cn);if(br=Dn(b,{anchor:Tr.start,head:Tr.end},Ot),Bt){var Zn=br.ranges;if(Ot=="block")for(var V=0;V<Zn.length;V++)Zn[V].head.ch=Ie(b,Zn[V].head.line);else Ot=="line"&&(Zn[0].head=new Fe(Zn[0].head.line+1,0))}}else{if(Rt=ze($e||Te),cn=ze(Ce||ke),Ze(cn,Rt)){var J=Rt;Rt=cn,cn=J}Bt=F.linewise||G.linewise,Bt?tr(b,Rt,cn):F.forward&&qn(b,Rt,cn),Ot="char";var ae=!F.inclusive||Bt,Tr=v(b,Rt,cn);br=Dn(b,{anchor:Tr.start,head:Tr.end},Ot,ae)}b.setSelections(br.ranges,br.primary),I.lastMotion=null,G.repeat=Be,G.registerName=K,G.linewise=Bt;var ce=Vs[W](b,G,br.ranges,Te,Ce);I.visualMode&&Ln(b,ce!=null),ce&&b.setCursor(ce)}},recordLastEdit:function(b,I,S){var z=Ve.macroModeState;z.isPlaying||(b.lastEditInputState=I,b.lastEditActionCommand=S,z.lastInsertModeChanges.changes=[],z.lastInsertModeChanges.expectCursorActivityForChange=!1,z.lastInsertModeChanges.visualBlock=b.visualBlock?b.sel.head.line-b.sel.anchor.line:0)}},Qn={moveToTopLine:function(b,I,S){var z=vo(b).top+S.repeat-1;return new Fe(z,dn(b.getLine(z)))},moveToMiddleLine:function(b){var I=vo(b),S=Math.floor((I.top+I.bottom)*.5);return new Fe(S,dn(b.getLine(S)))},moveToBottomLine:function(b,I,S){var z=vo(b).bottom-S.repeat+1;return new Fe(z,dn(b.getLine(z)))},expandToLine:function(b,I,S){var z=I;return new Fe(z.line+S.repeat-1,1/0)},findNext:function(b,I,S){var z=mn(b),F=z.getQuery();if(F){var W=!S.forward;return W=z.isReversed()?!W:W,go(b,F),nr(b,W,F,S.repeat)}},findAndSelectNextInclusive:function(b,I,S,z,F){var W=mn(b),G=W.getQuery();if(G){var K=!S.forward;K=W.isReversed()?!K:K;var Z=mo(b,K,G,S.repeat,z);if(Z){if(F.operator)return Z;var se=Z[0],de=new Fe(Z[1].line,Z[1].ch-1);if(z.visualMode){(z.visualLine||z.visualBlock)&&(z.visualLine=!1,z.visualBlock=!1,Ue.signal(b,"vim-mode-change",{mode:"visual",subMode:""}));var ke=z.sel.anchor;if(ke)return W.isReversed()?S.forward?[ke,se]:[ke,de]:S.forward?[ke,de]:[ke,se]}else z.visualMode=!0,z.visualLine=!1,z.visualBlock=!1,Ue.signal(b,"vim-mode-change",{mode:"visual",subMode:""});return K?[de,se]:[se,de]}}},goToMark:function(b,I,S,z){var F=fi(b,z,S.selectedCharacter);return F?S.linewise?{line:F.line,ch:dn(b.getLine(F.line))}:F:null},moveToOtherHighlightedEnd:function(b,I,S,z){if(z.visualBlock&&S.sameLine){var F=z.sel;return[he(b,new Fe(F.anchor.line,F.head.ch)),he(b,new Fe(F.head.line,F.anchor.ch))]}return[z.sel.head,z.sel.anchor]},jumpToMark:function(b,I,S,z){for(var F=I,W=0;W<S.repeat;W++){var G=F;for(var K in z.marks)if(u(K)){var Z=z.marks[K].find(),se=S.forward?Ze(Z,G):Ze(G,Z);if(!se&&!(S.linewise&&Z.line==G.line)){var de=Ye(G,F),ke=S.forward?Ft(G,Z,F):Ft(F,Z,G);(de||ke)&&(F=Z)}}}return S.linewise&&(F=new Fe(F.line,dn(b.getLine(F.line)))),F},moveByCharacters:function(b,I,S){var z=I,F=S.repeat,W=S.forward?z.ch+F:z.ch-F;return new Fe(z.line,W)},moveByLines:function(b,I,S,z){var F=I,W=F.ch;switch(z.lastMotion){case this.moveByLines:case this.moveByDisplayLines:case this.moveByScroll:case this.moveToColumn:case this.moveToEol:W=z.lastHPos;break;default:z.lastHPos=W}var G=S.repeat+(S.repeatOffset||0),K=S.forward?F.line+G:F.line-G,Z=b.firstLine(),se=b.lastLine();if(K<Z&&F.line==Z)return this.moveToStartOfLine(b,I,S,z);if(K>se&&F.line==se)return Ji(b,I,S,z,!0);var de=b.ace.session.getFoldLine(K);return de&&(S.forward?K>de.start.row&&(K=de.end.row+1):K=de.start.row),S.toFirstChar&&(W=dn(b.getLine(K)),z.lastHPos=W),z.lastHSPos=b.charCoords(new Fe(K,W),"div").left,new Fe(K,W)},moveByDisplayLines:function(b,I,S,z){var F=I;switch(z.lastMotion){case this.moveByDisplayLines:case this.moveByScroll:case this.moveByLines:case this.moveToColumn:case this.moveToEol:break;default:z.lastHSPos=b.charCoords(F,"div").left}var W=S.repeat,Z=b.findPosV(F,S.forward?W:-W,"line",z.lastHSPos);if(Z.hitSide)if(S.forward)var G=b.charCoords(Z,"div"),K={top:G.top+8,left:z.lastHSPos},Z=b.coordsChar(K,"div");else{var se=b.charCoords(new Fe(b.firstLine(),0),"div");se.left=z.lastHSPos,Z=b.coordsChar(se,"div")}return z.lastHPos=Z.ch,Z},moveByPage:function(b,I,S){var z=I,F=S.repeat;return b.findPosV(z,S.forward?F:-F,"page")},moveByParagraph:function(b,I,S){var z=S.forward?1:-1;return gs(b,I,S.repeat,z)},moveBySentence:function(b,I,S){var z=S.forward?1:-1;return Ii(b,I,S.repeat,z)},moveByScroll:function(b,I,S,z){var F=b.getScrollInfo(),W=null,G=S.repeat;G||(G=F.clientHeight/(2*b.defaultTextHeight()));var K=b.charCoords(I,"local");if(S.repeat=G,W=Qn.moveByDisplayLines(b,I,S,z),!W)return null;var Z=b.charCoords(W,"local");return b.scrollTo(null,F.top+Z.top-K.top),W},moveByWords:function(b,I,S){return vr(b,I,S.repeat,!!S.forward,!!S.wordEnd,!!S.bigWord)},moveTillCharacter:function(b,I,S){var z=S.repeat,F=jr(b,z,S.forward,S.selectedCharacter,I),W=S.forward?-1:1;return ei(W,S),F?(F.ch+=W,F):null},moveToCharacter:function(b,I,S){var z=S.repeat;return ei(0,S),jr(b,z,S.forward,S.selectedCharacter,I)||I},moveToSymbol:function(b,I,S){var z=S.repeat;return Ei(b,z,S.forward,S.selectedCharacter)||I},moveToColumn:function(b,I,S,z){var F=S.repeat;return z.lastHPos=F-1,z.lastHSPos=b.charCoords(I,"div").left,po(b,F)},moveToEol:function(b,I,S,z){return Ji(b,I,S,z,!1)},moveToFirstNonWhiteSpaceCharacter:function(b,I){var S=I;return new Fe(S.line,dn(b.getLine(S.line)))},moveToMatchedSymbol:function(b,I){for(var S=I,z=S.line,F=S.ch,W=b.getLine(z),G;F<W.length;F++)if(G=W.charAt(F),G&&d(G)){var K=b.getTokenTypeAt(new Fe(z,F+1));if(K!=="string"&&K!=="comment")break}if(F<W.length){var Z=/[<>]/.test(W[F])?/[(){}[\]<>]/:/[(){}[\]]/,se=b.findMatchingBracket(new Fe(z,F+1),{bracketRegex:Z});return se.to}return S},moveToStartOfLine:function(b,I){return new Fe(I.line,0)},moveToLineOrEdgeOfDocument:function(b,I,S){var z=S.forward?b.lastLine():b.firstLine();return S.repeatIsExplicit&&(z=S.repeat-b.getOption("firstLineNumber")),new Fe(z,dn(b.getLine(z)))},moveToStartOfDisplayLine:function(b){return b.execCommand("goLineLeft"),b.getCursor()},moveToEndOfDisplayLine:function(b){b.execCommand("goLineRight");var I=b.getCursor();return I.sticky=="before"&&I.ch--,I},textObjectManipulation:function(b,I,S,z){var F={"(":")",")":"(","{":"}","}":"{","[":"]","]":"[","<":">",">":"<"},W={"'":!0,'"':!0,"`":!0},G=S.selectedCharacter;G=="b"?G="(":G=="B"&&(G="{");var K=!S.textObjectInner,Z,se;if(F[G]){if(se=!0,Z=Yn(b,I,G,K),!Z){var de=b.getSearchCursor(new RegExp("\\"+G,"g"),I);de.find()&&(Z=Yn(b,de.from(),G,K))}}else if(W[G])se=!0,Z=$r(b,I,G,K);else if(G==="W"||G==="w")for(var ke=S.repeat||1;ke-- >0;){var Te=Pn(b,{inclusive:K,innerWord:!K,bigWord:G==="W",noSymbol:G==="W",multiline:!0},Z&&Z.end);Te&&(Z||(Z=Te),Z.end=Te.end)}else if(G==="p")if(Z=gs(b,I,S.repeat,0,K),S.linewise=!0,z.visualMode)z.visualLine||(z.visualLine=!0);else{var Ce=z.inputState.operatorArgs;Ce&&(Ce.linewise=!0),Z.end.line--}else if(G==="t")Z=Ti(b,I,K);else if(G==="s"){var $e=b.getLine(I.line);I.ch>0&&w($e[I.ch])&&(I.ch-=1);var Be=Ko(b,I,S.repeat,1,K),De=Ko(b,I,S.repeat,-1,K);m(b.getLine(De.line)[De.ch])&&m(b.getLine(Be.line)[Be.ch-1])&&(De={line:De.line,ch:De.ch+1}),Z={start:De,end:Be}}return Z?b.state.vim.visualMode?Fn(b,Z.start,Z.end,se):[Z.start,Z.end]:null},repeatLastCharacterSearch:function(b,I,S){var z=Ve.lastCharacterSearch,F=S.repeat,W=S.forward===z.forward,G=(z.increment?1:0)*(W?-1:1);b.moveH(-G,"char"),S.inclusive=!!W;var K=jr(b,F,W,z.selectedCharacter);return K?(K.ch+=G,K):(b.moveH(G,"char"),I)}},Vs={change:function(b,I,S){var z,F,W=b.state.vim,G=S[0].anchor,K=S[0].head;if(W.visualMode)if(I.fullLine)K.ch=Number.MAX_VALUE,K.line--,b.setSelection(G,K),F=b.getSelection(),b.replaceSelection(""),z=G;else{F=b.getSelection();var Z=le("",S.length);b.replaceSelections(Z),z=at(S[0].head,S[0].anchor)}else{F=b.getRange(G,K);var se=W.lastEditInputState||{};if(se.motion=="moveByWords"&&!m(F)){var de=/\s+$/.exec(F);de&&se.motionArgs&&se.motionArgs.forward&&(K=ee(K,0,-de[0].length),F=F.slice(0,-de[0].length))}I.linewise&&(G=new Fe(G.line,dn(b.getLine(G.line))),K.line>G.line&&(K=new Fe(K.line-1,Number.MAX_VALUE))),b.replaceRange("",G,K),z=G}Ve.registerController.pushText(I.registerName,"change",F,I.linewise,S.length>1),sr.enterInsertMode(b,{head:z},b.state.vim)},delete:function(b,I,S){var z,F,W=b.state.vim;if(W.visualBlock){F=b.getSelection();var G=le("",S.length);b.replaceSelections(G),z=at(S[0].head,S[0].anchor)}else{var K=S[0].anchor,Z=S[0].head;I.linewise&&Z.line!=b.firstLine()&&K.line==b.lastLine()&&K.line==Z.line-1&&(K.line==b.firstLine()?K.ch=0:K=new Fe(K.line-1,Ie(b,K.line-1))),F=b.getRange(K,Z),b.replaceRange("",K,Z),z=K,I.linewise&&(z=Qn.moveToFirstNonWhiteSpaceCharacter(b,K))}return Ve.registerController.pushText(I.registerName,"delete",F,I.linewise,W.visualBlock),he(b,z)},indent:function(b,I,S){var z=b.state.vim,F=z.visualMode?I.repeat:1;if(z.visualBlock){for(var W=b.getOption("tabSize"),G=b.getOption("indentWithTabs")?" ":" ".repeat(W),K,Z=S.length-1;Z>=0;Z--)if(K=at(S[Z].anchor,S[Z].head),I.indentRight)b.replaceRange(G.repeat(F),K,K);else{for(var se=b.getLine(K.line),de=0,ke=0;ke<F;ke++){var Te=se[K.ch+de];if(Te==" ")de++;else{if(Te!=" ")break;de++;for(var Ce=1;Ce<G.length&&(Te=se[K.ch+de],Te===" ");Ce++)de++}}b.replaceRange("",K,ee(K,0,de))}return K}if(b.indentMore)for(var ke=0;ke<F;ke++)I.indentRight?b.indentMore():b.indentLess();else{var $e=S[0].anchor.line,Be=z.visualBlock?S[S.length-1].anchor.line:S[0].head.line;I.linewise&&Be--;for(var Z=$e;Z<=Be;Z++)for(var ke=0;ke<F;ke++)b.indentLine(Z,I.indentRight)}return Qn.moveToFirstNonWhiteSpaceCharacter(b,S[0].anchor)},indentAuto:function(b,I,S){return b.execCommand("indentAuto"),Qn.moveToFirstNonWhiteSpaceCharacter(b,S[0].anchor)},hardWrap:function(b,I,S,z,F){if(b.hardWrap){var W=S[0].anchor.line,G=S[0].head.line;I.linewise&&G--;var K=b.hardWrap({from:W,to:G});return K>W&&I.linewise&&K--,I.keepCursor?z:new Fe(K,0)}},changeCase:function(b,I,S,z,F){for(var W=b.getSelections(),G=[],K=I.toLower,Z=0;Z<W.length;Z++){var se=W[Z],de="";if(K===!0)de=se.toLowerCase();else if(K===!1)de=se.toUpperCase();else for(var ke=0;ke<se.length;ke++){var Te=se.charAt(ke);de+=f(Te)?Te.toLowerCase():Te.toUpperCase()}G.push(de)}return b.replaceSelections(G),I.shouldMoveCursor?F:!b.state.vim.visualMode&&I.linewise&&S[0].anchor.line+1==S[0].head.line?Qn.moveToFirstNonWhiteSpaceCharacter(b,z):I.linewise?z:at(S[0].anchor,S[0].head)},yank:function(b,I,S,z){var F=b.state.vim,W=b.getSelection(),G=F.visualMode?at(F.sel.anchor,F.sel.head,S[0].head,S[0].anchor):z;return Ve.registerController.pushText(I.registerName,"yank",W,I.linewise,F.visualBlock),G}},sr={jumpListWalk:function(b,I,S){if(!S.visualMode){var z=I.repeat,F=I.forward,W=Ve.jumpList,G=W.move(b,F?z:-z),K=G?G.find():void 0;K=K||b.getCursor(),b.setCursor(K),b.ace.curOp.command.scrollIntoView="center-animate"}},scroll:function(b,I,S){if(!S.visualMode){var z=I.repeat||1,F=b.defaultTextHeight(),W=b.getScrollInfo().top,G=F*z,K=I.forward?W+G:W-G,Z=ze(b.getCursor()),se=b.charCoords(Z,"local");if(I.forward)K>se.top?(Z.line+=(K-se.top)/F,Z.line=Math.ceil(Z.line),b.setCursor(Z),se=b.charCoords(Z,"local"),b.scrollTo(null,se.top)):b.scrollTo(null,K);else{var de=K+b.getScrollInfo().clientHeight;de<se.bottom?(Z.line-=(se.bottom-de)/F,Z.line=Math.floor(Z.line),b.setCursor(Z),se=b.charCoords(Z,"local"),b.scrollTo(null,se.bottom-b.getScrollInfo().clientHeight)):b.scrollTo(null,K)}}},scrollToCursor:function(b,I){var S=b.getCursor().line,z=b.charCoords(new Fe(S,0),"local"),F=b.getScrollInfo().clientHeight,W=z.top;switch(I.position){case"center":W=z.bottom-F/2;break;case"bottom":var G=new Fe(S,b.getLine(S).length-1),K=b.charCoords(G,"local"),Z=K.bottom-W;W=W-F+Z}b.scrollTo(null,W)},replayMacro:function(b,I,S){var z=I.selectedCharacter,F=I.repeat,W=Ve.macroModeState;for(z=="@"?z=W.latestRegister:W.latestRegister=z;F--;)Jo(b,S,W,z)},enterMacroRecordMode:function(b,I){var S=Ve.macroModeState,z=I.selectedCharacter;Ve.registerController.isValidRegister(z)&&S.enterMacroRecordMode(b,z)},toggleOverwrite:function(b){b.state.overwrite?(b.toggleOverwrite(!1),b.setOption("keyMap","vim-insert"),Ue.signal(b,"vim-mode-change",{mode:"insert"})):(b.toggleOverwrite(!0),b.setOption("keyMap","vim-replace"),Ue.signal(b,"vim-mode-change",{mode:"replace"}))},enterInsertMode:function(b,I,S){if(!b.getOption("readOnly")){S.insertMode=!0,S.insertModeRepeat=I&&I.repeat||1;var z=I?I.insertAt:null,F=S.sel,W=I.head||b.getCursor("head"),G=b.listSelections().length;if(z=="eol")W=new Fe(W.line,Ie(b,W.line));else if(z=="bol")W=new Fe(W.line,0);else if(z=="charAfter"){var K=v(b,W,ee(W,0,1));W=K.end}else if(z=="firstNonBlank"){var K=v(b,W,Qn.moveToFirstNonWhiteSpaceCharacter(b,W));W=K.end}else if(z=="startOfSelectedArea"){if(!S.visualMode)return;S.visualBlock?(W=new Fe(Math.min(F.head.line,F.anchor.line),Math.min(F.head.ch,F.anchor.ch)),G=Math.abs(F.head.line-F.anchor.line)+1):F.head.line<F.anchor.line?W=F.head:W=new Fe(F.anchor.line,0)}else if(z=="endOfSelectedArea"){if(!S.visualMode)return;S.visualBlock?(W=new Fe(Math.min(F.head.line,F.anchor.line),Math.max(F.head.ch,F.anchor.ch)+1),G=Math.abs(F.head.line-F.anchor.line)+1):F.head.line>=F.anchor.line?W=ee(F.head,0,1):W=new Fe(F.anchor.line,0)}else if(z=="inplace"){if(S.visualMode)return}else z=="lastEdit"&&(W=Do(b)||W);b.setOption("disableInput",!1),I&&I.replace?(b.toggleOverwrite(!0),b.setOption("keyMap","vim-replace"),Ue.signal(b,"vim-mode-change",{mode:"replace"})):(b.toggleOverwrite(!1),b.setOption("keyMap","vim-insert"),Ue.signal(b,"vim-mode-change",{mode:"insert"})),Ve.macroModeState.isPlaying||(b.on("change",Qo),S.insertEnd&&S.insertEnd.clear(),S.insertEnd=b.setBookmark(W,{insertLeft:!0}),Ue.on(b.getInputField(),"keydown",Bo)),S.visualMode&&Ln(b),$n(b,W,G)}},toggleVisualMode:function(b,I,S){var z=I.repeat,F=b.getCursor(),W;if(S.visualMode)S.visualLine^I.linewise||S.visualBlock^I.blockwise?(S.visualLine=!!I.linewise,S.visualBlock=!!I.blockwise,Ue.signal(b,"vim-mode-change",{mode:"visual",subMode:S.visualLine?"linewise":S.visualBlock?"blockwise":""}),Sn(b)):Ln(b);else{S.visualMode=!0,S.visualLine=!!I.linewise,S.visualBlock=!!I.blockwise,W=he(b,new Fe(F.line,F.ch+z-1));var G=v(b,F,W);S.sel={anchor:G.start,head:G.end},Ue.signal(b,"vim-mode-change",{mode:"visual",subMode:S.visualLine?"linewise":S.visualBlock?"blockwise":""}),Sn(b),ur(b,S,"<",at(F,W)),ur(b,S,">",ct(F,W))}},reselectLastSelection:function(b,I,S){var z=S.lastSelection;if(S.visualMode&&Gt(b,S),z){var F=z.anchorMark.find(),W=z.headMark.find();if(!F||!W)return;S.sel={anchor:F,head:W},S.visualMode=!0,S.visualLine=z.visualLine,S.visualBlock=z.visualBlock,Sn(b),ur(b,S,"<",at(F,W)),ur(b,S,">",ct(F,W)),Ue.signal(b,"vim-mode-change",{mode:"visual",subMode:S.visualLine?"linewise":S.visualBlock?"blockwise":""})}},joinLines:function(b,I,S){var z,F;if(S.visualMode){if(z=b.getCursor("anchor"),F=b.getCursor("head"),Ze(F,z)){var W=F;F=z,z=W}F.ch=Ie(b,F.line)-1}else{var G=Math.max(I.repeat,2);z=b.getCursor(),F=he(b,new Fe(z.line+G-1,1/0))}for(var K=0,Z=z.line;Z<F.line;Z++){K=Ie(b,z.line);var se="",de=0;if(!I.keepSpaces){var ke=b.getLine(z.line+1);de=ke.search(/\S/),de==-1?de=ke.length:se=" "}b.replaceRange(se,new Fe(z.line,K),new Fe(z.line+1,de))}var Te=he(b,new Fe(z.line,K));S.visualMode&&Ln(b,!1),b.setCursor(Te)},newLineAndEnterInsertMode:function(b,I,S){S.insertMode=!0;var z=ze(b.getCursor());if(z.line===b.firstLine()&&!I.after)b.replaceRange(`
1442
+ `,new Fe(b.firstLine(),0)),b.setCursor(b.firstLine(),0);else{z.line=I.after?z.line:z.line-1,z.ch=Ie(b,z.line),b.setCursor(z);var F=Ue.commands.newlineAndIndentContinueComment||Ue.commands.newlineAndIndent;F(b)}this.enterInsertMode(b,{repeat:I.repeat},S)},paste:function(b,I,S){var z=this,F=Ve.registerController.getRegister(I.registerName),W=function(){var G=F.toString();z.continuePaste(b,I,S,G,F)};I.registerName==="+"&&typeof navigator<"u"&&typeof navigator.clipboard<"u"&&typeof navigator.clipboard.readText=="function"?navigator.clipboard.readText().then(function(G){z.continuePaste(b,I,S,G,F)},function(){W()}):W()},continuePaste:function(b,I,S,z,F){var W=ze(b.getCursor());if(z){if(I.matchIndent){var G=b.getOption("tabSize"),K=function(Zn){var V=Zn.split(" ").length-1,J=Zn.split(" ").length-1;return V*G+J*1},Z=b.getLine(b.getCursor().line),se=K(Z.match(/^\s*/)[0]),de=z.replace(/\n$/,""),ke=z!==de,Te=K(z.match(/^\s*/)[0]),z=de.replace(/^\s*/gm,function(Zn){var V=se+(K(Zn)-Te);if(V<0)return"";if(b.getOption("indentWithTabs")){var J=Math.floor(V/G);return Array(J+1).join(" ")}return Array(V+1).join(" ")});z+=ke?`
1443
+ `:""}if(I.repeat>1)var z=Array(I.repeat+1).join(z);var Ce=F.linewise,$e=F.blockwise;if($e){z=z.split(`
1444
+ `),Ce&&z.pop();for(var Be=0;Be<z.length;Be++)z[Be]=z[Be]==""?" ":z[Be];W.ch+=I.after?1:0,W.ch=Math.min(Ie(b,W.line),W.ch)}else Ce?S.visualMode?z=S.visualLine?z.slice(0,-1):`
1445
+ `+z.slice(0,z.length-1)+`
1446
+ `:I.after?(z=`
1447
+ `+z.slice(0,z.length-1),W.ch=Ie(b,W.line)):W.ch=0:W.ch+=I.after?1:0;var De;if(S.visualMode){S.lastPastedText=z;var et,kt=it(b,S),ut=kt[0],pt=kt[1],Hn=b.getSelection(),Rt=b.listSelections(),cn=new Array(Rt.length).join("1").split("1");S.lastSelection&&(et=S.lastSelection.headMark.find()),Ve.registerController.unnamedRegister.setText(Hn),$e?(b.replaceSelections(cn),pt=new Fe(ut.line+z.length-1,ut.ch),b.setCursor(ut),hn(b,pt),b.replaceSelections(z),De=ut):S.visualBlock?(b.replaceSelections(cn),b.setCursor(ut),b.replaceRange(z,ut,ut),De=ut):(b.replaceRange(z,ut,pt),De=b.posFromIndex(b.indexFromPos(ut)+z.length-1)),et&&(S.lastSelection.headMark=b.setBookmark(et)),Ce&&(De.ch=0)}else if($e){b.setCursor(W);for(var Be=0;Be<z.length;Be++){var Bt=W.line+Be;Bt>b.lastLine()&&b.replaceRange(`
1448
+ `,new Fe(Bt,0));var Ot=Ie(b,Bt);Ot<W.ch&&Vt(b,Bt,W.ch)}b.setCursor(W),hn(b,new Fe(W.line+z.length-1,W.ch)),b.replaceSelections(z),De=W}else if(b.replaceRange(z,W),Ce){var Bt=I.after?W.line+1:W.line;De=new Fe(Bt,dn(b.getLine(Bt)))}else De=ze(W),/\n/.test(z)||(De.ch+=z.length-(I.after?1:0));S.visualMode&&Ln(b,!1),b.setCursor(De)}},undo:function(b,I){b.operation(function(){Je(b,Ue.commands.undo,I.repeat)(),b.setCursor(he(b,b.getCursor("start")))})},redo:function(b,I){Je(b,Ue.commands.redo,I.repeat)()},setRegister:function(b,I,S){S.inputState.registerName=I.selectedCharacter},insertRegister:function(b,I,S){var z=I.selectedCharacter,F=Ve.registerController.getRegister(z),W=F&&F.toString();W&&b.replaceSelection(W)},oneNormalCommand:function(b,I,S){Dr(b,!0),S.insertModeReturn=!0,Ue.on(b,"vim-command-done",function z(){S.visualMode||(S.insertModeReturn&&(S.insertModeReturn=!1,S.insertMode||sr.enterInsertMode(b,{},S)),Ue.off(b,"vim-command-done",z))})},setMark:function(b,I,S){var z=I.selectedCharacter;ur(b,S,z,b.getCursor())},replace:function(b,I,S){var z=I.selectedCharacter,F=b.getCursor(),W,G,K=b.listSelections();if(S.visualMode)F=b.getCursor("start"),G=b.getCursor("end");else{var Z=b.getLine(F.line);W=F.ch+I.repeat,W>Z.length&&(W=Z.length),G=new Fe(F.line,W)}var se=v(b,F,G);if(F=se.start,G=se.end,z==`
1449
+ `)S.visualMode||b.replaceRange("",F,G),(Ue.commands.newlineAndIndentContinueComment||Ue.commands.newlineAndIndent)(b);else{var de=b.getRange(F,G);if(de=de.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,z),de=de.replace(/[^\n]/g,z),S.visualBlock){var ke=new Array(b.getOption("tabSize")+1).join(" ");de=b.getSelection(),de=de.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,z),de=de.replace(/\t/g,ke).replace(/[^\n]/g,z).split(`
1450
+ `),b.replaceSelections(de)}else b.replaceRange(de,F,G);S.visualMode?(F=Ze(K[0].anchor,K[0].head)?K[0].anchor:K[0].head,b.setCursor(F),Ln(b,!1)):b.setCursor(ee(G,0,-1))}},incrementNumberToken:function(b,I){for(var S=b.getCursor(),z=b.getLine(S.line),F=/(-?)(?:(0x)([\da-f]+)|(0b|0|)(\d+))/gi,W,G,K,Z;(W=F.exec(z))!==null&&(G=W.index,K=G+W[0].length,!(S.ch<K)););if(!(!I.backtrack&&K<=S.ch)&&W){var se=W[2]||W[4],de=W[3]||W[5],ke=I.increase?1:-1,Te={"0b":2,0:8,"":10,"0x":16}[se.toLowerCase()],Ce=parseInt(W[1]+de,Te)+ke*I.repeat;Z=Ce.toString(Te);var $e=se?new Array(de.length-Z.length+1+W[1].length).join("0"):"";Z.charAt(0)==="-"?Z="-"+se+$e+Z.substr(1):Z=se+$e+Z;var Be=new Fe(S.line,G),De=new Fe(S.line,K);b.replaceRange(Z,Be,De),b.setCursor(new Fe(S.line,G+Z.length-1))}},repeatLastEdit:function(b,I,S){var z=S.lastEditInputState;if(z){var F=I.repeat;F&&I.repeatIsExplicit?S.lastEditInputState.repeatOverride=F:F=S.lastEditInputState.repeatOverride||F,Cs(b,S,F,!1)}},indent:function(b,I){b.indentLine(b.getCursor().line,I.indentRight)},exitInsertMode:Dr},to={"(":"bracket",")":"bracket","{":"bracket","}":"bracket","[":"section","]":"section","*":"comment","/":"comment",m:"method",M:"method","#":"preprocess"},no={bracket:{isComplete:function(b){if(b.nextCh===b.symb){if(b.depth++,b.depth>=1)return!0}else b.nextCh===b.reverseSymb&&b.depth--;return!1}},section:{init:function(b){b.curMoveThrough=!0,b.symb=(b.forward?"]":"[")===b.symb?"{":"}"},isComplete:function(b){return b.index===0&&b.nextCh===b.symb}},comment:{isComplete:function(b){var I=b.lastCh==="*"&&b.nextCh==="/";return b.lastCh=b.nextCh,I}},method:{init:function(b){b.symb=b.symb==="m"?"{":"}",b.reverseSymb=b.symb==="{"?"}":"{"},isComplete:function(b){return b.nextCh===b.symb}},preprocess:{init:function(b){b.index=0},isComplete:function(b){if(b.nextCh==="#"){var I=b.lineText.match(/^#(\w+)/)[1];if(I==="endif"){if(b.forward&&b.depth===0)return!0;b.depth++}else if(I==="if"){if(!b.forward&&b.depth===0)return!0;b.depth--}if(I==="else"&&b.depth===0)return!0}return!1}}};R("pcre",!0,"boolean"),Or.prototype={getQuery:function(){return Ve.query},setQuery:function(b){Ve.query=b},getOverlay:function(){return this.searchOverlay},setOverlay:function(b){this.searchOverlay=b},isReversed:function(){return Ve.isReversed},setReversed:function(b){Ve.isReversed=b},getScrollbarAnnotate:function(){return this.annotate},setScrollbarAnnotate:function(b){this.annotate=b}};var Co={"\\n":`
1451
+ `,"\\r":"\r","\\t":" "},Ea={"\\/":"/","\\\\":"\\","\\n":`
1452
+ `,"\\r":"\r","\\t":" ","\\&":"&"},xn=0,bl=function(){this.buildCommandMap_()};bl.prototype={processCommand:function(b,I,S){var z=this;b.operation(function(){b.curOp.isVimOp=!0,z._processCommand(b,I,S)})},_processCommand:function(b,I,S){var z=b.state.vim,F=Ve.registerController.getRegister(":"),W=F.toString(),G=new Ue.StringStream(I);F.setText(I);var K=S||{};K.input=I;try{this.parseInput_(b,G,K)}catch(de){throw Dt(b,de.toString()),de}z.visualMode&&Ln(b);var Z,se;if(!K.commandName)K.line!==void 0&&(se="move");else if(Z=this.matchCommand_(K.commandName),Z){if(se=Z.name,Z.excludeFromCommandHistory&&F.setText(W),this.parseCommandArgs_(G,K,Z),Z.type=="exToKey"){k(b,Z.toKeys,Z);return}if(Z.type=="exToEx"){this.processCommand(b,Z.toInput);return}}if(!se){Dt(b,'Not an editor command ":'+I+'"');return}try{Sr[se](b,K),(!Z||!Z.possiblyAsync)&&K.callback&&K.callback()}catch(de){throw Dt(b,de.toString()),de}},parseInput_:function(b,I,S){if(I.eatWhile(":"),I.eat("%")?(S.line=b.firstLine(),S.lineEnd=b.lastLine()):(S.line=this.parseLineSpec_(b,I),S.line!==void 0&&I.eat(",")&&(S.lineEnd=this.parseLineSpec_(b,I))),S.line==null)if(b.state.vim.visualMode){var z=fi(b,b.state.vim,"<");S.selectionLine=z&&z.line,z=fi(b,b.state.vim,">"),S.selectionLineEnd=z&&z.line}else S.selectionLine=b.getCursor().line;else S.selectionLine=S.line,S.selectionLineEnd=S.lineEnd;var F=I.match(/^(\w+|!!|@@|[!#&*<=>@~])/);return F?S.commandName=F[1]:S.commandName=I.match(/.*/)[0],S},parseLineSpec_:function(b,I){var S=I.match(/^(\d+)/);if(S)return parseInt(S[1],10)-1;switch(I.next()){case".":return this.parseLineSpecOffset_(I,b.getCursor().line);case"$":return this.parseLineSpecOffset_(I,b.lastLine());case"'":var z=I.next(),F=fi(b,b.state.vim,z);if(!F)throw new Error("Mark not set");return this.parseLineSpecOffset_(I,F.line);case"-":case"+":return I.backUp(1),this.parseLineSpecOffset_(I,b.getCursor().line);default:return I.backUp(1),void 0}},parseLineSpecOffset_:function(b,I){var S=b.match(/^([+-])?(\d+)/);if(S){var z=parseInt(S[2],10);S[1]=="-"?I-=z:I+=z}return I},parseCommandArgs_:function(b,I,S){if(!b.eol()){I.argString=b.match(/.*/)[0];var z=S.argDelimiter||/\s+/,F=Ct(I.argString).split(z);F.length&&F[0]&&(I.args=F)}},matchCommand_:function(b){for(var I=b.length;I>0;I--){var S=b.substring(0,I);if(this.commandMap_[S]){var z=this.commandMap_[S];if(z.name.indexOf(b)===0)return z}}return null},buildCommandMap_:function(){this.commandMap_={};for(var b=0;b<gi.length;b++){var I=gi[b],S=I.shortName||I.name;this.commandMap_[S]=I}},map:function(b,I,S,z){if(b!=":"&&b.charAt(0)==":"){if(S)throw Error("Mode not supported for ex mappings");var F=b.substring(1);I!=":"&&I.charAt(0)==":"?this.commandMap_[F]={name:F,type:"exToEx",toInput:I.substring(1),user:!0}:this.commandMap_[F]={name:F,type:"exToKey",toKeys:I,user:!0}}else{var W={keys:b,type:"keyToKey",toKeys:I,noremap:!!z};S&&(W.context=S),Wn.unshift(W)}},unmap:function(b,I){if(b!=":"&&b.charAt(0)==":"){if(I)throw Error("Mode not supported for ex mappings");var S=b.substring(1);if(this.commandMap_[S]&&this.commandMap_[S].user)return delete this.commandMap_[S],!0}else for(var z=b,F=0;F<Wn.length;F++)if(z==Wn[F].keys&&Wn[F].context===I)return Wn.splice(F,1),!0}};var Sr={colorscheme:function(b,I){if(!I.args||I.args.length<1){Dt(b,b.getOption("theme"));return}b.setOption("theme",I.args[0])},map:function(b,I,S,z){var F=I.args;if(!F||F.length<2){b&&Dt(b,"Invalid mapping: "+I.input);return}ii.map(F[0],F[1],S,z)},imap:function(b,I){this.map(b,I,"insert")},nmap:function(b,I){this.map(b,I,"normal")},vmap:function(b,I){this.map(b,I,"visual")},omap:function(b,I){this.map(b,I,"operatorPending")},noremap:function(b,I){this.map(b,I,void 0,!0)},inoremap:function(b,I){this.map(b,I,"insert",!0)},nnoremap:function(b,I){this.map(b,I,"normal",!0)},vnoremap:function(b,I){this.map(b,I,"visual",!0)},onoremap:function(b,I){this.map(b,I,"operatorPending",!0)},unmap:function(b,I,S){var z=I.args;(!z||z.length<1||!ii.unmap(z[0],S))&&b&&Dt(b,"No such mapping: "+I.input)},mapclear:function(b,I){xt.mapclear()},imapclear:function(b,I){xt.mapclear("insert")},nmapclear:function(b,I){xt.mapclear("normal")},vmapclear:function(b,I){xt.mapclear("visual")},omapclear:function(b,I){xt.mapclear("operatorPending")},move:function(b,I){eo.processCommand(b,b.state.vim,{type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!1,explicitRepeat:!0,linewise:!0},repeatOverride:I.line+1})},set:function(b,I){var S=I.args,z=I.setCfg||{};if(!S||S.length<1){b&&Dt(b,"Invalid mapping: "+I.input);return}var F=S[0].split("="),W=F[0],G=F[1],K=!1,Z=!1;if(W.charAt(W.length-1)=="?"){if(G)throw Error("Trailing characters: "+I.argString);W=W.substring(0,W.length-1),K=!0}else W.charAt(W.length-1)=="!"&&(W=W.substring(0,W.length-1),Z=!0);G===void 0&&W.substring(0,2)=="no"&&(W=W.substring(2),G=!1);var se=rt[W]&&rt[W].type=="boolean";if(se&&(Z?G=!_(W,b,z):G==null&&(G=!0)),!se&&G===void 0||K){var de=_(W,b,z);de instanceof Error?Dt(b,de.message):de===!0||de===!1?Dt(b," "+(de?"":"no")+W):Dt(b," "+W+"="+de)}else{var ke=T(W,G,b,z);ke instanceof Error&&Dt(b,ke.message)}},setlocal:function(b,I){I.setCfg={scope:"local"},this.set(b,I)},setglobal:function(b,I){I.setCfg={scope:"global"},this.set(b,I)},registers:function(b,I){var S=I.args,z=Ve.registerController.registers,F=`----------Registers----------
1453
+
1454
+ `;if(S){var W;S=S.join("");for(var G=0;G<S.length;G++)if(W=S.charAt(G),!!Ve.registerController.isValidRegister(W)){var K=z[W]||new j;F+='"'+W+" "+K.toString()+`
1455
+ `}}else for(var W in z){var Z=z[W].toString();Z.length&&(F+='"'+W+" "+Z+`
1456
+ `)}Dt(b,F)},sort:function(b,I){function S(){if(I.argString){var Bt=new Ue.StringStream(I.argString);if(Bt.eat("!")&&(W=!0),Bt.eol())return;if(!Bt.eatSpace())return"Invalid arguments";var Ot=Bt.match(/([dinuox]+)?\s*(\/.+\/)?\s*/);if(!Ot&&!Bt.eol())return"Invalid arguments";if(Ot[1]){G=Ot[1].indexOf("i")!=-1,K=Ot[1].indexOf("u")!=-1;var br=Ot[1].indexOf("d")!=-1||Ot[1].indexOf("n")!=-1&&1,Tr=Ot[1].indexOf("x")!=-1&&1,Zn=Ot[1].indexOf("o")!=-1&&1;if(br+Tr+Zn>1)return"Invalid arguments";Z=br&&"decimal"||Tr&&"hex"||Zn&&"octal"}Ot[2]&&(se=new RegExp(Ot[2].substr(1,Ot[2].length-2),G?"i":""))}}function z(Bt,Ot){if(W){var br;br=Bt,Bt=Ot,Ot=br}G&&(Bt=Bt.toLowerCase(),Ot=Ot.toLowerCase());var Tr=Z&&De.exec(Bt),Zn=Z&&De.exec(Ot);return Tr?(Tr=parseInt((Tr[1]+Tr[2]).toLowerCase(),et),Zn=parseInt((Zn[1]+Zn[2]).toLowerCase(),et),Tr-Zn):Bt<Ot?-1:1}function F(Bt,Ot){if(W){var br;br=Bt,Bt=Ot,Ot=br}return G&&(Bt[0]=Bt[0].toLowerCase(),Ot[0]=Ot[0].toLowerCase()),Bt[0]<Ot[0]?-1:1}var W,G,K,Z,se,de=S();if(de){Dt(b,de+": "+I.argString);return}var ke=I.line||b.firstLine(),Te=I.lineEnd||I.line||b.lastLine();if(ke!=Te){var Ce=new Fe(ke,0),$e=new Fe(Te,Ie(b,Te)),Be=b.getRange(Ce,$e).split(`
1457
+ `),De=se||(Z=="decimal"?/(-?)([\d]+)/:Z=="hex"?/(-?)(?:0x)?([0-9a-f]+)/i:Z=="octal"?/([0-7]+)/:null),et=Z=="decimal"?10:Z=="hex"?16:Z=="octal"?8:null,kt=[],ut=[];if(Z||se)for(var pt=0;pt<Be.length;pt++){var Hn=se?Be[pt].match(se):null;Hn&&Hn[0]!=""?kt.push(Hn):!se&&De.exec(Be[pt])?kt.push(Be[pt]):ut.push(Be[pt])}else ut=Be;if(kt.sort(se?F:z),se)for(var pt=0;pt<kt.length;pt++)kt[pt]=kt[pt].input;else Z||ut.sort(z);if(Be=W?kt.concat(ut):ut.concat(kt),K){var Rt=Be,cn;Be=[];for(var pt=0;pt<Rt.length;pt++)Rt[pt]!=cn&&Be.push(Rt[pt]),cn=Rt[pt]}b.replaceRange(Be.join(`
1458
+ `),Ce,$e)}},vglobal:function(b,I){this.global(b,I)},normal:function(b,I){var S=I.argString;if(S&&S[0]=="!"&&(S=S.slice(1),mi=!0),S=S.trimStart(),!S){Dt(b,"Argument is required.");return}var z=I.line;if(typeof z=="number")for(var F=isNaN(I.lineEnd)?z:I.lineEnd,W=z;W<=F;W++)b.setCursor(W,0),k(b,I.argString.trimStart()),b.state.vim.insertMode&&Dr(b,!0);else k(b,I.argString.trimStart()),b.state.vim.insertMode&&Dr(b,!0)},global:function(b,I){var S=I.argString;if(!S){Dt(b,"Regular Expression missing from global");return}var z=I.commandName[0]==="v";S[0]==="!"&&I.commandName[0]==="g"&&(z=!0,S=S.slice(1));var F=I.line!==void 0?I.line:b.firstLine(),W=I.lineEnd||I.line||b.lastLine(),G=jn(S),K=S,Z;if(G.length&&(K=G[0],Z=G.slice(1,G.length).join("/")),K)try{fn(b,K,!0,!0)}catch{Dt(b,"Invalid regex: "+K);return}for(var se=mn(b).getQuery(),de=[],ke=F;ke<=W;ke++){var Te=b.getLine(ke),Ce=se.test(Te);Ce!==z&&de.push(Z?b.getLineHandle(ke):Te)}if(!Z){Dt(b,de.join(`
1459
+ `));return}var $e=0,Be=function(){if($e<de.length){var De=de[$e++],et=b.getLineNumber(De);if(et==null){Be();return}var kt=et+1+Z;ii.processCommand(b,kt,{callback:Be})}else b.releaseLineHandles&&b.releaseLineHandles()};Be()},substitute:function(b,I){if(!b.getSearchCursor)throw new Error("Search feature not available. Requires searchcursor.js or any other getSearchCursor implementation.");var S=I.argString,z=S?hi(S,S[0]):[],F,W="",G,K,Z,se=!1,de=!1;if(z.length)F=z[0],_("pcre")&&F!==""&&(F=new RegExp(F).source),W=z[1],W!==void 0&&(_("pcre")?W=bs(W.replace(/([^\\])&/g,"$1$$&")):W=ys(W),Ve.lastSubstituteReplacePart=W),G=z[2]?z[2].split(" "):[];else if(S&&S.length){Dt(b,"Substitutions should be of the form :s/pattern/replace/");return}if(G&&(K=G[0],Z=parseInt(G[1]),K&&(K.indexOf("c")!=-1&&(se=!0),K.indexOf("g")!=-1&&(de=!0),_("pcre")?F=F+"/"+K:F=F.replace(/\//g,"\\/")+"/"+K)),F)try{fn(b,F,!0,!0)}catch{Dt(b,"Invalid regex: "+F);return}if(W=W||Ve.lastSubstituteReplacePart,W===void 0){Dt(b,"No previous substitute regular expression");return}var ke=mn(b),Te=ke.getQuery(),Ce=I.line!==void 0?I.line:b.getCursor().line,$e=I.lineEnd||Ce;Ce==b.firstLine()&&$e==b.lastLine()&&($e=1/0),Z&&(Ce=$e,$e=Ce+Z-1);var Be=he(b,new Fe(Ce,0)),De=b.getSearchCursor(Te,Be);ti(b,se,de,Ce,$e,De,Te,W,I.callback)},startinsert:function(b,I){k(b,I.argString=="!"?"A":"i",{})},redo:Ue.commands.redo,undo:Ue.commands.undo,write:function(b){Ue.commands.save?Ue.commands.save(b):b.save&&b.save()},nohlsearch:function(b){Li(b)},yank:function(b){var I=ze(b.getCursor()),S=I.line,z=b.getLine(S);Ve.registerController.pushText("0","yank",z,!0,!0)},delete:function(b,I){var S=I.selectionLine,z=isNaN(I.selectionLineEnd)?S:I.selectionLineEnd;Vs.delete(b,{linewise:!0},[{anchor:new Fe(S,0),head:new Fe(z+1,0)}])},join:function(b,I){var S=I.selectionLine,z=isNaN(I.selectionLineEnd)?S:I.selectionLineEnd;b.setCursor(new Fe(S,0)),sr.joinLines(b,{repeat:z-S},b.state.vim)},delmarks:function(b,I){if(!I.argString||!Ct(I.argString)){Dt(b,"Argument required");return}for(var S=b.state.vim,z=new Ue.StringStream(Ct(I.argString));!z.eol();){z.eatSpace();var F=z.pos;if(!z.match(/[a-zA-Z]/,!1)){Dt(b,"Invalid argument: "+I.argString.substring(F));return}var W=z.next();if(z.match("-",!0)){if(!z.match(/[a-zA-Z]/,!1)){Dt(b,"Invalid argument: "+I.argString.substring(F));return}var G=W,K=z.next();if(!(u(G)&&u(K)||f(G)&&f(K))){Dt(b,"Invalid argument: "+G+"-");return}var Z=G.charCodeAt(0),se=K.charCodeAt(0);if(Z>=se){Dt(b,"Invalid argument: "+I.argString.substring(F));return}for(var de=0;de<=se-Z;de++){var ke=String.fromCharCode(Z+de);delete S.marks[ke]}}else delete S.marks[W]}}},ii=new bl;R("insertModeEscKeysTimeout",200,"number"),Ue.Vim=xt;var os={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"},Hr=xt.handleKey.bind(xt);xt.handleKey=function(b,I,S){return b.operation(function(){return Hr(b,I,S)},!0)},O(),r.CodeMirror=Ue;var Di=xt.maybeInitVimState_;r.handler={$id:"ace/keyboard/vim",drawCursor:function(b,I,S,z,F){var W=this.state.vim||{},G=I.width||S.characterWidth,K=S.lineHeight,Z=I.top,se=I.left;if(!W.insertMode){var de=z.cursor?or.comparePoints(z.cursor,z.start)<=0:F.selection.isBackwards()||F.selection.isEmpty();!de&&se>G&&(se-=G)}!W.insertMode&&W.status&&(K/=2,Z+=K),Jn.translate(b,se,Z),Jn.setStyle(b.style,"width",G+"px"),Jn.setStyle(b.style,"height",K+"px")},$getDirectionForHighlight:function(b){var I=b.state.cm,S=Di(I);if(!S.insertMode)return b.session.selection.isBackwards()||b.session.selection.isEmpty()},handleKeyboard:function(b,I,S,z,F){var W=b.editor,G=W.state.cm,K=Di(G);if(z!=-1){if(K.insertMode||(I==-1?(S.charCodeAt(0)>255&&b.inputKey&&(S=b.inputKey,S&&b.inputHash==4&&(S=S.toUpperCase())),b.inputChar=S):I==4||I==0?b.inputKey==S&&b.inputHash==I&&b.inputChar?(S=b.inputChar,I=-1):(b.inputChar=null,b.inputKey=S,b.inputHash=I):b.inputChar=b.inputKey=null),G.state.overwrite&&K.insertMode&&S=="backspace"&&I==0)return{command:"gotoleft"};if(S=="c"&&I==1&&!Fo.isMac&&W.getCopyText())return W.once("copy",function(){K.insertMode?W.selection.clearSelection():G.operation(function(){Ln(G)})}),{command:"null",passEvent:!0};if(S=="esc"&&!K.insertMode&&!K.visualMode&&!G.ace.inMultiSelectMode){var Z=mn(G),se=Z.getOverlay();se&&G.removeOverlay(se)}if(I==-1||I&1||I===0&&S.length>1){var de=K.insertMode,ke=ks(I,S,F||{},K);K.status==null&&(K.status="");var Te=Zi(G,ke,"user");return K=Di(G),Te&&K.status!=null?K.status+=ke:K.status==null&&(K.status=""),G._signal("changeStatus"),!Te&&(I!=-1||de)?void 0:{command:"null",passEvent:!Te}}}},attach:function(b){function I(){var z=Di(S).insertMode;S.ace.renderer.setStyle("normal-mode",!z),b.textInput.setCommandMode(!z),b.renderer.$keepTextAreaAtCursor=z,b.renderer.$blockCursor=!z}b.state||(b.state={});var S=new Ue(b);b.state.cm=S,b.$vimModeHandler=this,s(S),Di(S).status=null,S.on("vim-command-done",function(){S.virtualSelectionMode()||(Di(S).status=null,S.ace._signal("changeStatus"),S.ace.session.markUndoGroup())}),S.on("changeStatus",function(){S.ace.renderer.updateCursor(),S.ace._signal("changeStatus")}),S.on("vim-mode-change",function(){S.virtualSelectionMode()||(I(),S._signal("changeStatus"))}),I(),b.renderer.$cursorLayer.drawCursor=this.drawCursor.bind(S)},detach:function(b){var I=b.state.cm;p(I),I.destroy(),b.state.cm=null,b.$vimModeHandler=null,b.renderer.$cursorLayer.drawCursor=null,b.renderer.setStyle("normal-mode",!1),b.textInput.setCommandMode(!1),b.renderer.$keepTextAreaAtCursor=!0},getStatusText:function(b){var I=b.state.cm,S=Di(I);if(S.insertMode)return"INSERT";var z="";return S.visualMode&&(z+="VISUAL",S.visualLine&&(z+=" LINE"),S.visualBlock&&(z+=" BLOCK")),S.status&&(z+=(z?" ":"")+S.status),z}},xt.defineOption({name:"wrap",set:function(b,I){I&&I.ace.setOption("wrap",b)},type:"boolean"},!1),xt.defineEx("write","w",function(){console.log(":write is not implemented")}),Wn.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"}}),Wn.push({keys:"gq",type:"operator",operator:"hardWrap"}),xt.defineOperator("hardWrap",function(b,I,S,z,F){var W=S[0].anchor.line,G=S[0].head.line;return I.linewise&&G--,Xi(b.ace,{startRow:W,endRow:G}),Fe(G,0)}),R("textwidth",void 0,"number",["tw"],function(b,I){if(I!==void 0){if(b===void 0){var S=I.ace.getOption("printMarginColumn");return S}var z=Math.round(b);z>1&&I.ace.setOption("printMarginColumn",z)}}),sr.aceCommand=function(b,I,S){b.vimCmd=I,b.ace.inVirtualSelectionMode?b.ace.on("beforeEndOperation",pi):pi(null,b.ace)},sr.fold=function(b,I,S){b.ace.execCommand(["toggleFoldWidget","toggleFoldWidget","foldOther","unfoldall"][(I.all?2:0)+(I.open?1:0)])},xo=Wn.length,r.handler.defaultKeymap=Wn,r.handler.actions=sr,r.Vim=xt}),(function(){ace.require(["ace/keyboard/vim"],function(t){e&&(e.exports=t)})})()})(fy)),fy.exports}cT();var gy={},my;function uT(){return my||(my=1,(function(e){(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 t(v){return c(g(v),arguments)}function r(v,s){return t.apply(null,[v].concat(s||[]))}function c(v,s){var p=1,a=v.length,l,u="",d,o,f,m,w,x,R,T;for(d=0;d<a;d++)if(typeof v[d]=="string")u+=v[d];else if(typeof v[d]=="object"){if(f=v[d],f.keys)for(l=s[p],o=0;o<f.keys.length;o++){if(l==null)throw new Error(t('[sprintf] Cannot access property "%s" of undefined value "%s"',f.keys[o],f.keys[o-1]));l=l[f.keys[o]]}else f.param_no?l=s[f.param_no]:l=s[p++];if(n.not_type.test(f.type)&&n.not_primitive.test(f.type)&&l instanceof Function&&(l=l()),n.numeric_arg.test(f.type)&&typeof l!="number"&&isNaN(l))throw new TypeError(t("[sprintf] expecting number but found %T",l));switch(n.number.test(f.type)&&(R=l>=0),f.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,f.width?parseInt(f.width):0);break;case"e":l=f.precision?parseFloat(l).toExponential(f.precision):parseFloat(l).toExponential();break;case"f":l=f.precision?parseFloat(l).toFixed(f.precision):parseFloat(l);break;case"g":l=f.precision?String(Number(l.toPrecision(f.precision))):parseFloat(l);break;case"o":l=(parseInt(l,10)>>>0).toString(8);break;case"s":l=String(l),l=f.precision?l.substring(0,f.precision):l;break;case"t":l=String(!!l),l=f.precision?l.substring(0,f.precision):l;break;case"T":l=Object.prototype.toString.call(l).slice(8,-1).toLowerCase(),l=f.precision?l.substring(0,f.precision):l;break;case"u":l=parseInt(l,10)>>>0;break;case"v":l=l.valueOf(),l=f.precision?l.substring(0,f.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(f.type)?u+=l:(n.number.test(f.type)&&(!R||f.sign)?(T=R?"+":"-",l=l.toString().replace(n.sign,"")):T="",w=f.pad_char?f.pad_char==="0"?"0":f.pad_char.charAt(1):" ",x=f.width-(T+l).length,m=f.width&&x>0?w.repeat(x):"",u+=f.align?T+l+m:w==="0"?T+m+l:m+T+l)}return u}var h=Object.create(null);function g(v){if(h[v])return h[v];for(var s=v,p,a=[],l=0;s;){if((p=n.text.exec(s))!==null)a.push(p[0]);else if((p=n.modulo.exec(s))!==null)a.push("%");else if((p=n.placeholder.exec(s))!==null){if(p[2]){l|=1;var u=[],d=p[2],o=[];if((o=n.key.exec(d))!==null)for(u.push(o[1]);(d=d.substring(o[0].length))!=="";)if((o=n.key_access.exec(d))!==null)u.push(o[1]);else if((o=n.index_access.exec(d))!==null)u.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");p[2]=u}else l|=2;if(l===3)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");a.push({placeholder:p[0],param_no:p[1],keys:p[2],sign:p[3],pad_char:p[4],align:p[5],width:p[6],precision:p[7],type:p[8]})}else throw new SyntaxError("[sprintf] unexpected placeholder");s=s.substring(p[0].length)}return h[v]=a}e.sprintf=t,e.vsprintf=r,typeof window<"u"&&(window.sprintf=t,window.vsprintf=r)})()})(gy)),gy}uT();var au={exports:{}},hT=au.exports,vy;function dT(){return vy||(vy=1,(function(e,n){(function(){var t,r="4.18.1",c=200,h="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",g="Expected a function",v="Invalid `variable` option passed into `_.template`",s="Invalid `imports` option passed into `_.template`",p="__lodash_hash_undefined__",a=500,l="__lodash_placeholder__",u=1,d=2,o=4,f=1,m=2,w=1,x=2,R=4,T=8,_=16,C=32,P=64,O=128,E=256,k=512,B=30,N="...",M=800,$=16,A=1,D=2,j=3,U=1/0,q=9007199254740991,Q=17976931348623157e292,re=NaN,le=4294967295,ne=le-1,ue=le>>>1,he=[["ary",O],["bind",w],["bindKey",x],["curry",T],["curryRight",_],["flip",k],["partial",C],["partialRight",P],["rearg",E]],oe="[object Arguments]",ee="[object Array]",ye="[object AsyncFunction]",we="[object Boolean]",Ae="[object Date]",Je="[object DOMException]",ze="[object Error]",Ye="[object Function]",Ze="[object GeneratorFunction]",at="[object Map]",ct="[object Number]",Ft="[object Null]",Ie="[object Object]",Ct="[object Promise]",St="[object Proxy]",Vt="[object RegExp]",hn="[object Set]",$n="[object String]",mt="[object Symbol]",it="[object Undefined]",Gt="[object WeakMap]",Fn="[object WeakSet]",Sn="[object ArrayBuffer]",Dn="[object DataView]",Gn="[object Float32Array]",Ln="[object Float64Array]",qn="[object Int8Array]",tr="[object Int16Array]",dn="[object Int32Array]",Pn="[object Uint8Array]",Ti="[object Uint8ClampedArray]",Xr="[object Uint16Array]",ei="[object Uint32Array]",Ei=/\b__p \+= '';/g,fo=/\b(__p \+=) '' \+/g,vr=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Ji=/&(?:amp|lt|gt|quot|#39);/g,jr=/[&<>"']/g,po=RegExp(Ji.source),ur=RegExp(jr.source),Hs=/<%-([\s\S]+?)%>/g,gs=/<%([\s\S]+?)%>/g,Ko=/<%=([\s\S]+?)%>/g,Ii=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Yn=/^\w*$/,$r=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Or=/[\\^$.*+?()[\]{}|]/g,mn=RegExp(Or.source),jn=/^\s+/,Mi=/\s/,hi=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ms=/\{\n\/\* \[wrapped with (.+)\] \*/,vs=/,? & /,ys=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,bs=/[()=,{}\[\]\/\s]/,di=/\\(\\)?/g,Ri=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Dt=/\w*$/,Us=/^[-+]0x[0-9a-f]+$/i,Nr=/^0b[01]+$/i,Pt=/^\[object .+?Constructor\]$/,fn=/^0o[0-7]+$/i,Kn=/^(?:0|[1-9]\d*)$/,go=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,nr=/($^)/,mo=/['\n\r\u2028\u2029\\]/g,Li="\\ud800-\\udfff",ws="\\u0300-\\u036f",vo="\\ufe20-\\ufe2f",fi="\\u20d0-\\u20ff",Do=ws+vo+fi,ti="\\u2700-\\u27bf",Dr="a-z\\xdf-\\xf6\\xf8-\\xff",yo="\\xac\\xb1\\xd7\\xf7",Oi="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Jo="\\u2000-\\u206f",Po=" \\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",rr="A-Z\\xc0-\\xd6\\xd8-\\xde",zo="\\ufe0e\\ufe0f",Qo=yo+Oi+Jo+Po,Qi="['’]",xs="["+Li+"]",Zo="["+Qo+"]",Bo="["+Do+"]",Cs="\\d+",Xo="["+ti+"]",es="["+Dr+"]",ks="[^"+Li+Qo+Cs+ti+Dr+rr+"]",Ni="\\ud83c[\\udffb-\\udfff]",Zi="(?:"+Bo+"|"+Ni+")",pi="[^"+Li+"]",or="(?:\\ud83c[\\udde6-\\uddff]){2}",bo="[\\ud800-\\udbff][\\udc00-\\udfff]",Jn="["+rr+"]",wo="\\u200d",Pr="(?:"+es+"|"+ks+")",ts="(?:"+Jn+"|"+ks+")",ni="(?:"+Qi+"(?:d|ll|m|re|s|t|ve))?",Fo="(?:"+Qi+"(?:D|LL|M|RE|S|T|VE))?",jo=Zi+"?",Wr="["+zo+"]?",ns="(?:"+wo+"(?:"+[pi,or,bo].join("|")+")"+Wr+jo+")*",Xi="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Ue="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",rs=Wr+jo+ns,Fe="(?:"+[Xo,or,bo].join("|")+")"+rs,Wn="(?:"+[pi+Bo+"?",Bo,or,bo,xs].join("|")+")",xo=RegExp(Qi,"g"),gi=RegExp(Bo,"g"),Tn=RegExp(Ni+"(?="+Ni+")|"+Wn+rs,"g"),is=RegExp([Jn+"?"+es+"+"+ni+"(?="+[Zo,Jn,"$"].join("|")+")",ts+"+"+Fo+"(?="+[Zo,Jn+Pr,"$"].join("|")+")",Jn+"?"+Pr+"+"+ni,Jn+"+"+Fo,Ue,Xi,Cs,Fe].join("|"),"g"),X=RegExp("["+wo+Li+Do+zo+"]"),xe=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Me=["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"],Oe=-1,Ke={};Ke[Gn]=Ke[Ln]=Ke[qn]=Ke[tr]=Ke[dn]=Ke[Pn]=Ke[Ti]=Ke[Xr]=Ke[ei]=!0,Ke[oe]=Ke[ee]=Ke[Sn]=Ke[we]=Ke[Dn]=Ke[Ae]=Ke[ze]=Ke[Ye]=Ke[at]=Ke[ct]=Ke[Ie]=Ke[Vt]=Ke[hn]=Ke[$n]=Ke[Gt]=!1;var We={};We[oe]=We[ee]=We[Sn]=We[Dn]=We[we]=We[Ae]=We[Gn]=We[Ln]=We[qn]=We[tr]=We[dn]=We[at]=We[ct]=We[Ie]=We[Vt]=We[hn]=We[$n]=We[mt]=We[Pn]=We[Ti]=We[Xr]=We[ei]=!0,We[ze]=We[Ye]=We[Gt]=!1;var rt={À:"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"},rn={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},bn={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},Ve={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},jt=parseFloat,xt=parseInt,ln=typeof Ps=="object"&&Ps&&Ps.Object===Object&&Ps,mi=typeof self=="object"&&self&&self.Object===Object&&self,qt=ln||mi||Function("return this")(),ri=n&&!n.nodeType&&n,yr=ri&&!0&&e&&!e.nodeType&&e,Wo=yr&&yr.exports===ri,eo=Wo&&ln.process,Qn=(function(){try{var be=yr&&yr.require&&yr.require("util").types;return be||eo&&eo.binding&&eo.binding("util")}catch{}})(),Vs=Qn&&Qn.isArrayBuffer,sr=Qn&&Qn.isDate,to=Qn&&Qn.isMap,no=Qn&&Qn.isRegExp,Co=Qn&&Qn.isSet,Ea=Qn&&Qn.isTypedArray;function xn(be,Re,Ee){switch(Ee.length){case 0:return be.call(Re);case 1:return be.call(Re,Ee[0]);case 2:return be.call(Re,Ee[0],Ee[1]);case 3:return be.call(Re,Ee[0],Ee[1],Ee[2])}return be.apply(Re,Ee)}function bl(be,Re,Ee,Xe){for(var _t=-1,Nt=be==null?0:be.length;++_t<Nt;){var vn=be[_t];Re(Xe,vn,Ee(vn),be)}return Xe}function Sr(be,Re){for(var Ee=-1,Xe=be==null?0:be.length;++Ee<Xe&&Re(be[Ee],Ee,be)!==!1;);return be}function ii(be,Re){for(var Ee=be==null?0:be.length;Ee--&&Re(be[Ee],Ee,be)!==!1;);return be}function os(be,Re){for(var Ee=-1,Xe=be==null?0:be.length;++Ee<Xe;)if(!Re(be[Ee],Ee,be))return!1;return!0}function Hr(be,Re){for(var Ee=-1,Xe=be==null?0:be.length,_t=0,Nt=[];++Ee<Xe;){var vn=be[Ee];Re(vn,Ee,be)&&(Nt[_t++]=vn)}return Nt}function Di(be,Re){var Ee=be==null?0:be.length;return!!Ee&&ke(be,Re,0)>-1}function b(be,Re,Ee){for(var Xe=-1,_t=be==null?0:be.length;++Xe<_t;)if(Ee(Re,be[Xe]))return!0;return!1}function I(be,Re){for(var Ee=-1,Xe=be==null?0:be.length,_t=Array(Xe);++Ee<Xe;)_t[Ee]=Re(be[Ee],Ee,be);return _t}function S(be,Re){for(var Ee=-1,Xe=Re.length,_t=be.length;++Ee<Xe;)be[_t+Ee]=Re[Ee];return be}function z(be,Re,Ee,Xe){var _t=-1,Nt=be==null?0:be.length;for(Xe&&Nt&&(Ee=be[++_t]);++_t<Nt;)Ee=Re(Ee,be[_t],_t,be);return Ee}function F(be,Re,Ee,Xe){var _t=be==null?0:be.length;for(Xe&&_t&&(Ee=be[--_t]);_t--;)Ee=Re(Ee,be[_t],_t,be);return Ee}function W(be,Re){for(var Ee=-1,Xe=be==null?0:be.length;++Ee<Xe;)if(Re(be[Ee],Ee,be))return!0;return!1}var G=Be("length");function K(be){return be.split("")}function Z(be){return be.match(ys)||[]}function se(be,Re,Ee){var Xe;return Ee(be,function(_t,Nt,vn){if(Re(_t,Nt,vn))return Xe=Nt,!1}),Xe}function de(be,Re,Ee,Xe){for(var _t=be.length,Nt=Ee+(Xe?1:-1);Xe?Nt--:++Nt<_t;)if(Re(be[Nt],Nt,be))return Nt;return-1}function ke(be,Re,Ee){return Re===Re?Mt(be,Re,Ee):de(be,Ce,Ee)}function Te(be,Re,Ee,Xe){for(var _t=Ee-1,Nt=be.length;++_t<Nt;)if(Xe(be[_t],Re))return _t;return-1}function Ce(be){return be!==be}function $e(be,Re){var Ee=be==null?0:be.length;return Ee?ut(be,Re)/Ee:re}function Be(be){return function(Re){return Re==null?t:Re[be]}}function De(be){return function(Re){return be==null?t:be[Re]}}function et(be,Re,Ee,Xe,_t){return _t(be,function(Nt,vn,Kt){Ee=Xe?(Xe=!1,Nt):Re(Ee,Nt,vn,Kt)}),Ee}function kt(be,Re){var Ee=be.length;for(be.sort(Re);Ee--;)be[Ee]=be[Ee].value;return be}function ut(be,Re){for(var Ee,Xe=-1,_t=be.length;++Xe<_t;){var Nt=Re(be[Xe]);Nt!==t&&(Ee=Ee===t?Nt:Ee+Nt)}return Ee}function pt(be,Re){for(var Ee=-1,Xe=Array(be);++Ee<be;)Xe[Ee]=Re(Ee);return Xe}function Hn(be,Re){return I(Re,function(Ee){return[Ee,be[Ee]]})}function Rt(be){return be&&be.slice(0,At(be)+1).replace(jn,"")}function cn(be){return function(Re){return be(Re)}}function Bt(be,Re){return I(Re,function(Ee){return be[Ee]})}function Ot(be,Re){return be.has(Re)}function br(be,Re){for(var Ee=-1,Xe=be.length;++Ee<Xe&&ke(Re,be[Ee],0)>-1;);return Ee}function Tr(be,Re){for(var Ee=be.length;Ee--&&ke(Re,be[Ee],0)>-1;);return Ee}function Zn(be,Re){for(var Ee=be.length,Xe=0;Ee--;)be[Ee]===Re&&++Xe;return Xe}var V=De(rt),J=De(rn);function ae(be){return"\\"+Ve[be]}function ce(be,Re){return be==null?t:be[Re]}function ge(be){return X.test(be)}function Se(be){return xe.test(be)}function Le(be){for(var Re,Ee=[];!(Re=be.next()).done;)Ee.push(Re.value);return Ee}function He(be){var Re=-1,Ee=Array(be.size);return be.forEach(function(Xe,_t){Ee[++Re]=[_t,Xe]}),Ee}function qe(be,Re){return function(Ee){return be(Re(Ee))}}function Qe(be,Re){for(var Ee=-1,Xe=be.length,_t=0,Nt=[];++Ee<Xe;){var vn=be[Ee];(vn===Re||vn===l)&&(be[Ee]=l,Nt[_t++]=Ee)}return Nt}function ot(be){var Re=-1,Ee=Array(be.size);return be.forEach(function(Xe){Ee[++Re]=Xe}),Ee}function ft(be){var Re=-1,Ee=Array(be.size);return be.forEach(function(Xe){Ee[++Re]=[Xe,Xe]}),Ee}function Mt(be,Re,Ee){for(var Xe=Ee-1,_t=be.length;++Xe<_t;)if(be[Xe]===Re)return Xe;return-1}function pn(be,Re,Ee){for(var Xe=Ee+1;Xe--;)if(be[Xe]===Re)return Xe;return Xe}function Yt(be){return ge(be)?On(be):G(be)}function It(be){return ge(be)?Xn(be):K(be)}function At(be){for(var Re=be.length;Re--&&Mi.test(be.charAt(Re)););return Re}var bt=De(bn);function On(be){for(var Re=Tn.lastIndex=0;Tn.test(be);)++Re;return Re}function Xn(be){return be.match(Tn)||[]}function wr(be){return be.match(is)||[]}var Cn=(function be(Re){Re=Re==null?qt:En.defaults(qt.Object(),Re,En.pick(qt,Me));var Ee=Re.Array,Xe=Re.Date,_t=Re.Error,Nt=Re.Function,vn=Re.Math,Kt=Re.Object,Pi=Re.RegExp,Ur=Re.String,zn=Re.TypeError,ko=Ee.prototype,Vr=Nt.prototype,_s=Kt.prototype,ah=Re["__core-js_shared__"],lh=Vr.toString,kn=_s.hasOwnProperty,GD=0,g1=(function(){var i=/[^.]+$/.exec(ah&&ah.keys&&ah.keys.IE_PROTO||"");return i?"Symbol(src)_1."+i:""})(),ch=_s.toString,qD=lh.call(Kt),YD=qt._,KD=Pi("^"+lh.call(kn).replace(Or,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),uh=Wo?Re.Buffer:t,Gs=Re.Symbol,hh=Re.Uint8Array,m1=uh?uh.allocUnsafe:t,dh=qe(Kt.getPrototypeOf,Kt),v1=Kt.create,y1=_s.propertyIsEnumerable,fh=ko.splice,b1=Gs?Gs.isConcatSpreadable:t,$c=Gs?Gs.iterator:t,Ia=Gs?Gs.toStringTag:t,ph=(function(){try{var i=Na(Kt,"defineProperty");return i({},"",{}),i}catch{}})(),JD=Re.clearTimeout!==qt.clearTimeout&&Re.clearTimeout,QD=Xe&&Xe.now!==qt.Date.now&&Xe.now,ZD=Re.setTimeout!==qt.setTimeout&&Re.setTimeout,gh=vn.ceil,mh=vn.floor,Gp=Kt.getOwnPropertySymbols,XD=uh?uh.isBuffer:t,w1=Re.isFinite,eP=ko.join,tP=qe(Kt.keys,Kt),Er=vn.max,oi=vn.min,nP=Xe.now,rP=Re.parseInt,x1=vn.random,iP=ko.reverse,qp=Na(Re,"DataView"),Sc=Na(Re,"Map"),Yp=Na(Re,"Promise"),wl=Na(Re,"Set"),Tc=Na(Re,"WeakMap"),Ec=Na(Kt,"create"),vh=Tc&&new Tc,xl={},oP=Da(qp),sP=Da(Sc),aP=Da(Yp),lP=Da(wl),cP=Da(Tc),yh=Gs?Gs.prototype:t,Ic=yh?yh.valueOf:t,C1=yh?yh.toString:t;function te(i){if(ar(i)&&!zt(i)&&!(i instanceof tn)){if(i instanceof _o)return i;if(kn.call(i,"__wrapped__"))return kC(i)}return new _o(i)}var Cl=(function(){function i(){}return function(y){if(!ir(y))return{};if(v1)return v1(y);i.prototype=y;var L=new i;return i.prototype=t,L}})();function bh(){}function _o(i,y){this.__wrapped__=i,this.__actions__=[],this.__chain__=!!y,this.__index__=0,this.__values__=t}te.templateSettings={escape:Hs,evaluate:gs,interpolate:Ko,variable:"",imports:{_:te}},te.prototype=bh.prototype,te.prototype.constructor=te,_o.prototype=Cl(bh.prototype),_o.prototype.constructor=_o;function tn(i){this.__wrapped__=i,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=le,this.__views__=[]}function uP(){var i=new tn(this.__wrapped__);return i.__actions__=zi(this.__actions__),i.__dir__=this.__dir__,i.__filtered__=this.__filtered__,i.__iteratees__=zi(this.__iteratees__),i.__takeCount__=this.__takeCount__,i.__views__=zi(this.__views__),i}function hP(){if(this.__filtered__){var i=new tn(this);i.__dir__=-1,i.__filtered__=!0}else i=this.clone(),i.__dir__*=-1;return i}function dP(){var i=this.__wrapped__.value(),y=this.__dir__,L=zt(i),H=y<0,Y=L?i.length:0,ie=_z(0,Y,this.__views__),fe=ie.start,pe=ie.end,_e=pe-fe,Ne=H?pe:fe-1,Pe=this.__iteratees__,je=Pe.length,st=0,yt=oi(_e,this.__takeCount__);if(!L||!H&&Y==_e&&yt==_e)return G1(i,this.__actions__);var Et=[];e:for(;_e--&&st<yt;){Ne+=y;for(var Ut=-1,$t=i[Ne];++Ut<je;){var Zt=Pe[Ut],on=Zt.iteratee,oo=Zt.type,bi=on($t);if(oo==D)$t=bi;else if(!bi){if(oo==A)continue e;break e}}Et[st++]=$t}return Et}tn.prototype=Cl(bh.prototype),tn.prototype.constructor=tn;function Ma(i){var y=-1,L=i==null?0:i.length;for(this.clear();++y<L;){var H=i[y];this.set(H[0],H[1])}}function fP(){this.__data__=Ec?Ec(null):{},this.size=0}function pP(i){var y=this.has(i)&&delete this.__data__[i];return this.size-=y?1:0,y}function gP(i){var y=this.__data__;if(Ec){var L=y[i];return L===p?t:L}return kn.call(y,i)?y[i]:t}function mP(i){var y=this.__data__;return Ec?y[i]!==t:kn.call(y,i)}function vP(i,y){var L=this.__data__;return this.size+=this.has(i)?0:1,L[i]=Ec&&y===t?p:y,this}Ma.prototype.clear=fP,Ma.prototype.delete=pP,Ma.prototype.get=gP,Ma.prototype.has=mP,Ma.prototype.set=vP;function As(i){var y=-1,L=i==null?0:i.length;for(this.clear();++y<L;){var H=i[y];this.set(H[0],H[1])}}function yP(){this.__data__=[],this.size=0}function bP(i){var y=this.__data__,L=wh(y,i);if(L<0)return!1;var H=y.length-1;return L==H?y.pop():fh.call(y,L,1),--this.size,!0}function wP(i){var y=this.__data__,L=wh(y,i);return L<0?t:y[L][1]}function xP(i){return wh(this.__data__,i)>-1}function CP(i,y){var L=this.__data__,H=wh(L,i);return H<0?(++this.size,L.push([i,y])):L[H][1]=y,this}As.prototype.clear=yP,As.prototype.delete=bP,As.prototype.get=wP,As.prototype.has=xP,As.prototype.set=CP;function $s(i){var y=-1,L=i==null?0:i.length;for(this.clear();++y<L;){var H=i[y];this.set(H[0],H[1])}}function kP(){this.size=0,this.__data__={hash:new Ma,map:new(Sc||As),string:new Ma}}function _P(i){var y=Rh(this,i).delete(i);return this.size-=y?1:0,y}function AP(i){return Rh(this,i).get(i)}function $P(i){return Rh(this,i).has(i)}function SP(i,y){var L=Rh(this,i),H=L.size;return L.set(i,y),this.size+=L.size==H?0:1,this}$s.prototype.clear=kP,$s.prototype.delete=_P,$s.prototype.get=AP,$s.prototype.has=$P,$s.prototype.set=SP;function Ra(i){var y=-1,L=i==null?0:i.length;for(this.__data__=new $s;++y<L;)this.add(i[y])}function TP(i){return this.__data__.set(i,p),this}function EP(i){return this.__data__.has(i)}Ra.prototype.add=Ra.prototype.push=TP,Ra.prototype.has=EP;function Ho(i){var y=this.__data__=new As(i);this.size=y.size}function IP(){this.__data__=new As,this.size=0}function MP(i){var y=this.__data__,L=y.delete(i);return this.size=y.size,L}function RP(i){return this.__data__.get(i)}function LP(i){return this.__data__.has(i)}function OP(i,y){var L=this.__data__;if(L instanceof As){var H=L.__data__;if(!Sc||H.length<c-1)return H.push([i,y]),this.size=++L.size,this;L=this.__data__=new $s(H)}return L.set(i,y),this.size=L.size,this}Ho.prototype.clear=IP,Ho.prototype.delete=MP,Ho.prototype.get=RP,Ho.prototype.has=LP,Ho.prototype.set=OP;function k1(i,y){var L=zt(i),H=!L&&Pa(i),Y=!L&&!H&&Qs(i),ie=!L&&!H&&!Y&&$l(i),fe=L||H||Y||ie,pe=fe?pt(i.length,Ur):[],_e=pe.length;for(var Ne in i)(y||kn.call(i,Ne))&&!(fe&&(Ne=="length"||Y&&(Ne=="offset"||Ne=="parent")||ie&&(Ne=="buffer"||Ne=="byteLength"||Ne=="byteOffset")||Es(Ne,_e)))&&pe.push(Ne);return pe}function _1(i){var y=i.length;return y?i[og(0,y-1)]:t}function NP(i,y){return Lh(zi(i),La(y,0,i.length))}function DP(i){return Lh(zi(i))}function Kp(i,y,L){(L!==t&&!Vo(i[y],L)||L===t&&!(y in i))&&ss(i,y,L)}function Mc(i,y,L){var H=i[y];(!(kn.call(i,y)&&Vo(H,L))||L===t&&!(y in i))&&ss(i,y,L)}function wh(i,y){for(var L=i.length;L--;)if(Vo(i[L][0],y))return L;return-1}function PP(i,y,L,H){return qs(i,function(Y,ie,fe){y(H,Y,L(Y),fe)}),H}function A1(i,y){return i&&ls(y,zr(y),i)}function zP(i,y){return i&&ls(y,Fi(y),i)}function ss(i,y,L){y=="__proto__"&&ph?ph(i,y,{configurable:!0,enumerable:!0,value:L,writable:!0}):i[y]=L}function Jp(i,y){for(var L=-1,H=y.length,Y=Ee(H),ie=i==null;++L<H;)Y[L]=ie?t:Mg(i,y[L]);return Y}function La(i,y,L){return i===i&&(L!==t&&(i=i<=L?i:L),y!==t&&(i=i>=y?i:y)),i}function Ao(i,y,L,H,Y,ie){var fe,pe=y&u,_e=y&d,Ne=y&o;if(L&&(fe=Y?L(i,H,Y,ie):L(i)),fe!==t)return fe;if(!ir(i))return i;var Pe=zt(i);if(Pe){if(fe=$z(i),!pe)return zi(i,fe)}else{var je=si(i),st=je==Ye||je==Ze;if(Qs(i))return K1(i,pe);if(je==Ie||je==oe||st&&!Y){if(fe=_e||st?{}:pC(i),!pe)return _e?gz(i,zP(fe,i)):pz(i,A1(fe,i))}else{if(!We[je])return Y?i:{};fe=Sz(i,je,pe)}}ie||(ie=new Ho);var yt=ie.get(i);if(yt)return yt;ie.set(i,fe),HC(i)?i.forEach(function($t){fe.add(Ao($t,y,L,$t,i,ie))}):jC(i)&&i.forEach(function($t,Zt){fe.set(Zt,Ao($t,y,L,Zt,i,ie))});var Et=Ne?_e?mg:gg:_e?Fi:zr,Ut=Pe?t:Et(i);return Sr(Ut||i,function($t,Zt){Ut&&(Zt=$t,$t=i[Zt]),Mc(fe,Zt,Ao($t,y,L,Zt,i,ie))}),fe}function BP(i){var y=zr(i);return function(L){return $1(L,i,y)}}function $1(i,y,L){var H=L.length;if(i==null)return!H;for(i=Kt(i);H--;){var Y=L[H],ie=y[Y],fe=i[Y];if(fe===t&&!(Y in i)||!ie(fe))return!1}return!0}function S1(i,y,L){if(typeof i!="function")throw new zn(g);return zc(function(){i.apply(t,L)},y)}function Rc(i,y,L,H){var Y=-1,ie=Di,fe=!0,pe=i.length,_e=[],Ne=y.length;if(!pe)return _e;L&&(y=I(y,cn(L))),H?(ie=b,fe=!1):y.length>=c&&(ie=Ot,fe=!1,y=new Ra(y));e:for(;++Y<pe;){var Pe=i[Y],je=L==null?Pe:L(Pe);if(Pe=H||Pe!==0?Pe:0,fe&&je===je){for(var st=Ne;st--;)if(y[st]===je)continue e;_e.push(Pe)}else ie(y,je,H)||_e.push(Pe)}return _e}var qs=eC(as),T1=eC(Zp,!0);function FP(i,y){var L=!0;return qs(i,function(H,Y,ie){return L=!!y(H,Y,ie),L}),L}function xh(i,y,L){for(var H=-1,Y=i.length;++H<Y;){var ie=i[H],fe=y(ie);if(fe!=null&&(pe===t?fe===fe&&!io(fe):L(fe,pe)))var pe=fe,_e=ie}return _e}function jP(i,y,L,H){var Y=i.length;for(L=Wt(L),L<0&&(L=-L>Y?0:Y+L),H=H===t||H>Y?Y:Wt(H),H<0&&(H+=Y),H=L>H?0:VC(H);L<H;)i[L++]=y;return i}function E1(i,y){var L=[];return qs(i,function(H,Y,ie){y(H,Y,ie)&&L.push(H)}),L}function Gr(i,y,L,H,Y){var ie=-1,fe=i.length;for(L||(L=Ez),Y||(Y=[]);++ie<fe;){var pe=i[ie];y>0&&L(pe)?y>1?Gr(pe,y-1,L,H,Y):S(Y,pe):H||(Y[Y.length]=pe)}return Y}var Qp=tC(),I1=tC(!0);function as(i,y){return i&&Qp(i,y,zr)}function Zp(i,y){return i&&I1(i,y,zr)}function Ch(i,y){return Hr(y,function(L){return Is(i[L])})}function Oa(i,y){y=Ks(y,i);for(var L=0,H=y.length;i!=null&&L<H;)i=i[Uo(y[L++])];return L&&L==H?i:t}function M1(i,y,L){var H=y(i);return zt(i)?H:S(H,L(i))}function vi(i){return i==null?i===t?it:Ft:Ia&&Ia in Kt(i)?kz(i):Dz(i)}function Xp(i,y){return i>y}function WP(i,y){return i!=null&&kn.call(i,y)}function HP(i,y){return i!=null&&y in Kt(i)}function UP(i,y,L){return i>=oi(y,L)&&i<Er(y,L)}function eg(i,y,L){for(var H=L?b:Di,Y=i[0].length,ie=i.length,fe=ie,pe=Ee(ie),_e=1/0,Ne=[];fe--;){var Pe=i[fe];fe&&y&&(Pe=I(Pe,cn(y))),_e=oi(Pe.length,_e),pe[fe]=!L&&(y||Y>=120&&Pe.length>=120)?new Ra(fe&&Pe):t}Pe=i[0];var je=-1,st=pe[0];e:for(;++je<Y&&Ne.length<_e;){var yt=Pe[je],Et=y?y(yt):yt;if(yt=L||yt!==0?yt:0,!(st?Ot(st,Et):H(Ne,Et,L))){for(fe=ie;--fe;){var Ut=pe[fe];if(!(Ut?Ot(Ut,Et):H(i[fe],Et,L)))continue e}st&&st.push(Et),Ne.push(yt)}}return Ne}function VP(i,y,L,H){return as(i,function(Y,ie,fe){y(H,L(Y),ie,fe)}),H}function Lc(i,y,L){y=Ks(y,i),i=yC(i,y);var H=i==null?i:i[Uo(So(y))];return H==null?t:xn(H,i,L)}function R1(i){return ar(i)&&vi(i)==oe}function GP(i){return ar(i)&&vi(i)==Sn}function qP(i){return ar(i)&&vi(i)==Ae}function Oc(i,y,L,H,Y){return i===y?!0:i==null||y==null||!ar(i)&&!ar(y)?i!==i&&y!==y:YP(i,y,L,H,Oc,Y)}function YP(i,y,L,H,Y,ie){var fe=zt(i),pe=zt(y),_e=fe?ee:si(i),Ne=pe?ee:si(y);_e=_e==oe?Ie:_e,Ne=Ne==oe?Ie:Ne;var Pe=_e==Ie,je=Ne==Ie,st=_e==Ne;if(st&&Qs(i)){if(!Qs(y))return!1;fe=!0,Pe=!1}if(st&&!Pe)return ie||(ie=new Ho),fe||$l(i)?hC(i,y,L,H,Y,ie):xz(i,y,_e,L,H,Y,ie);if(!(L&f)){var yt=Pe&&kn.call(i,"__wrapped__"),Et=je&&kn.call(y,"__wrapped__");if(yt||Et){var Ut=yt?i.value():i,$t=Et?y.value():y;return ie||(ie=new Ho),Y(Ut,$t,L,H,ie)}}return st?(ie||(ie=new Ho),Cz(i,y,L,H,Y,ie)):!1}function KP(i){return ar(i)&&si(i)==at}function tg(i,y,L,H){var Y=L.length,ie=Y,fe=!H;if(i==null)return!ie;for(i=Kt(i);Y--;){var pe=L[Y];if(fe&&pe[2]?pe[1]!==i[pe[0]]:!(pe[0]in i))return!1}for(;++Y<ie;){pe=L[Y];var _e=pe[0],Ne=i[_e],Pe=pe[1];if(fe&&pe[2]){if(Ne===t&&!(_e in i))return!1}else{var je=new Ho;if(H)var st=H(Ne,Pe,_e,i,y,je);if(!(st===t?Oc(Pe,Ne,f|m,H,je):st))return!1}}return!0}function L1(i){if(!ir(i)||Mz(i))return!1;var y=Is(i)?KD:Pt;return y.test(Da(i))}function JP(i){return ar(i)&&vi(i)==Vt}function QP(i){return ar(i)&&si(i)==hn}function ZP(i){return ar(i)&&Bh(i.length)&&!!Ke[vi(i)]}function O1(i){return typeof i=="function"?i:i==null?ji:typeof i=="object"?zt(i)?P1(i[0],i[1]):D1(i):rk(i)}function ng(i){if(!Pc(i))return tP(i);var y=[];for(var L in Kt(i))kn.call(i,L)&&L!="constructor"&&y.push(L);return y}function XP(i){if(!ir(i))return Nz(i);var y=Pc(i),L=[];for(var H in i)H=="constructor"&&(y||!kn.call(i,H))||L.push(H);return L}function rg(i,y){return i<y}function N1(i,y){var L=-1,H=Bi(i)?Ee(i.length):[];return qs(i,function(Y,ie,fe){H[++L]=y(Y,ie,fe)}),H}function D1(i){var y=yg(i);return y.length==1&&y[0][2]?mC(y[0][0],y[0][1]):function(L){return L===i||tg(L,i,y)}}function P1(i,y){return wg(i)&&gC(y)?mC(Uo(i),y):function(L){var H=Mg(L,i);return H===t&&H===y?Rg(L,i):Oc(y,H,f|m)}}function kh(i,y,L,H,Y){i!==y&&Qp(y,function(ie,fe){if(Y||(Y=new Ho),ir(ie))ez(i,y,fe,L,kh,H,Y);else{var pe=H?H(Cg(i,fe),ie,fe+"",i,y,Y):t;pe===t&&(pe=ie),Kp(i,fe,pe)}},Fi)}function ez(i,y,L,H,Y,ie,fe){var pe=Cg(i,L),_e=Cg(y,L),Ne=fe.get(_e);if(Ne){Kp(i,L,Ne);return}var Pe=ie?ie(pe,_e,L+"",i,y,fe):t,je=Pe===t;if(je){var st=zt(_e),yt=!st&&Qs(_e),Et=!st&&!yt&&$l(_e);Pe=_e,st||yt||Et?zt(pe)?Pe=pe:hr(pe)?Pe=zi(pe):yt?(je=!1,Pe=K1(_e,!0)):Et?(je=!1,Pe=J1(_e,!0)):Pe=[]:Bc(_e)||Pa(_e)?(Pe=pe,Pa(pe)?Pe=GC(pe):(!ir(pe)||Is(pe))&&(Pe=pC(_e))):je=!1}je&&(fe.set(_e,Pe),Y(Pe,_e,H,ie,fe),fe.delete(_e)),Kp(i,L,Pe)}function z1(i,y){var L=i.length;if(L)return y+=y<0?L:0,Es(y,L)?i[y]:t}function B1(i,y,L){y.length?y=I(y,function(ie){return zt(ie)?function(fe){return Oa(fe,ie.length===1?ie[0]:ie)}:ie}):y=[ji];var H=-1;y=I(y,cn(Tt()));var Y=N1(i,function(ie,fe,pe){var _e=I(y,function(Ne){return Ne(ie)});return{criteria:_e,index:++H,value:ie}});return kt(Y,function(ie,fe){return fz(ie,fe,L)})}function tz(i,y){return F1(i,y,function(L,H){return Rg(i,H)})}function F1(i,y,L){for(var H=-1,Y=y.length,ie={};++H<Y;){var fe=y[H],pe=Oa(i,fe);L(pe,fe)&&Nc(ie,Ks(fe,i),pe)}return ie}function nz(i){return function(y){return Oa(y,i)}}function ig(i,y,L,H){var Y=H?Te:ke,ie=-1,fe=y.length,pe=i;for(i===y&&(y=zi(y)),L&&(pe=I(i,cn(L)));++ie<fe;)for(var _e=0,Ne=y[ie],Pe=L?L(Ne):Ne;(_e=Y(pe,Pe,_e,H))>-1;)pe!==i&&fh.call(pe,_e,1),fh.call(i,_e,1);return i}function j1(i,y){for(var L=i?y.length:0,H=L-1;L--;){var Y=y[L];if(L==H||Y!==ie){var ie=Y;Es(Y)?fh.call(i,Y,1):lg(i,Y)}}return i}function og(i,y){return i+mh(x1()*(y-i+1))}function rz(i,y,L,H){for(var Y=-1,ie=Er(gh((y-i)/(L||1)),0),fe=Ee(ie);ie--;)fe[H?ie:++Y]=i,i+=L;return fe}function sg(i,y){var L="";if(!i||y<1||y>q)return L;do y%2&&(L+=i),y=mh(y/2),y&&(i+=i);while(y);return L}function Jt(i,y){return kg(vC(i,y,ji),i+"")}function iz(i){return _1(Sl(i))}function oz(i,y){var L=Sl(i);return Lh(L,La(y,0,L.length))}function Nc(i,y,L,H){if(!ir(i))return i;y=Ks(y,i);for(var Y=-1,ie=y.length,fe=ie-1,pe=i;pe!=null&&++Y<ie;){var _e=Uo(y[Y]),Ne=L;if(_e==="__proto__"||_e==="constructor"||_e==="prototype")return i;if(Y!=fe){var Pe=pe[_e];Ne=H?H(Pe,_e,pe):t,Ne===t&&(Ne=ir(Pe)?Pe:Es(y[Y+1])?[]:{})}Mc(pe,_e,Ne),pe=pe[_e]}return i}var W1=vh?function(i,y){return vh.set(i,y),i}:ji,sz=ph?function(i,y){return ph(i,"toString",{configurable:!0,enumerable:!1,value:Og(y),writable:!0})}:ji;function az(i){return Lh(Sl(i))}function $o(i,y,L){var H=-1,Y=i.length;y<0&&(y=-y>Y?0:Y+y),L=L>Y?Y:L,L<0&&(L+=Y),Y=y>L?0:L-y>>>0,y>>>=0;for(var ie=Ee(Y);++H<Y;)ie[H]=i[H+y];return ie}function lz(i,y){var L;return qs(i,function(H,Y,ie){return L=y(H,Y,ie),!L}),!!L}function _h(i,y,L){var H=0,Y=i==null?H:i.length;if(typeof y=="number"&&y===y&&Y<=ue){for(;H<Y;){var ie=H+Y>>>1,fe=i[ie];fe!==null&&!io(fe)&&(L?fe<=y:fe<y)?H=ie+1:Y=ie}return Y}return ag(i,y,ji,L)}function ag(i,y,L,H){var Y=0,ie=i==null?0:i.length;if(ie===0)return 0;y=L(y);for(var fe=y!==y,pe=y===null,_e=io(y),Ne=y===t;Y<ie;){var Pe=mh((Y+ie)/2),je=L(i[Pe]),st=je!==t,yt=je===null,Et=je===je,Ut=io(je);if(fe)var $t=H||Et;else Ne?$t=Et&&(H||st):pe?$t=Et&&st&&(H||!yt):_e?$t=Et&&st&&!yt&&(H||!Ut):yt||Ut?$t=!1:$t=H?je<=y:je<y;$t?Y=Pe+1:ie=Pe}return oi(ie,ne)}function H1(i,y){for(var L=-1,H=i.length,Y=0,ie=[];++L<H;){var fe=i[L],pe=y?y(fe):fe;if(!L||!Vo(pe,_e)){var _e=pe;ie[Y++]=fe===0?0:fe}}return ie}function U1(i){return typeof i=="number"?i:io(i)?re:+i}function ro(i){if(typeof i=="string")return i;if(zt(i))return I(i,ro)+"";if(io(i))return C1?C1.call(i):"";var y=i+"";return y=="0"&&1/i==-U?"-0":y}function Ys(i,y,L){var H=-1,Y=Di,ie=i.length,fe=!0,pe=[],_e=pe;if(L)fe=!1,Y=b;else if(ie>=c){var Ne=y?null:bz(i);if(Ne)return ot(Ne);fe=!1,Y=Ot,_e=new Ra}else _e=y?[]:pe;e:for(;++H<ie;){var Pe=i[H],je=y?y(Pe):Pe;if(Pe=L||Pe!==0?Pe:0,fe&&je===je){for(var st=_e.length;st--;)if(_e[st]===je)continue e;y&&_e.push(je),pe.push(Pe)}else Y(_e,je,L)||(_e!==pe&&_e.push(je),pe.push(Pe))}return pe}function lg(i,y){y=Ks(y,i);var L=-1,H=y.length;if(!H)return!0;for(;++L<H;){var Y=Uo(y[L]);if(Y==="__proto__"&&!kn.call(i,"__proto__")||(Y==="constructor"||Y==="prototype")&&L<H-1)return!1}var ie=yC(i,y);return ie==null||delete ie[Uo(So(y))]}function V1(i,y,L,H){return Nc(i,y,L(Oa(i,y)),H)}function Ah(i,y,L,H){for(var Y=i.length,ie=H?Y:-1;(H?ie--:++ie<Y)&&y(i[ie],ie,i););return L?$o(i,H?0:ie,H?ie+1:Y):$o(i,H?ie+1:0,H?Y:ie)}function G1(i,y){var L=i;return L instanceof tn&&(L=L.value()),z(y,function(H,Y){return Y.func.apply(Y.thisArg,S([H],Y.args))},L)}function cg(i,y,L){var H=i.length;if(H<2)return H?Ys(i[0]):[];for(var Y=-1,ie=Ee(H);++Y<H;)for(var fe=i[Y],pe=-1;++pe<H;)pe!=Y&&(ie[Y]=Rc(ie[Y]||fe,i[pe],y,L));return Ys(Gr(ie,1),y,L)}function q1(i,y,L){for(var H=-1,Y=i.length,ie=y.length,fe={};++H<Y;){var pe=H<ie?y[H]:t;L(fe,i[H],pe)}return fe}function ug(i){return hr(i)?i:[]}function hg(i){return typeof i=="function"?i:ji}function Ks(i,y){return zt(i)?i:wg(i,y)?[i]:CC(_n(i))}var cz=Jt;function Js(i,y,L){var H=i.length;return L=L===t?H:L,!y&&L>=H?i:$o(i,y,L)}var Y1=JD||function(i){return qt.clearTimeout(i)};function K1(i,y){if(y)return i.slice();var L=i.length,H=m1?m1(L):new i.constructor(L);return i.copy(H),H}function dg(i){var y=new i.constructor(i.byteLength);return new hh(y).set(new hh(i)),y}function uz(i,y){var L=y?dg(i.buffer):i.buffer;return new i.constructor(L,i.byteOffset,i.byteLength)}function hz(i){var y=new i.constructor(i.source,Dt.exec(i));return y.lastIndex=i.lastIndex,y}function dz(i){return Ic?Kt(Ic.call(i)):{}}function J1(i,y){var L=y?dg(i.buffer):i.buffer;return new i.constructor(L,i.byteOffset,i.length)}function Q1(i,y){if(i!==y){var L=i!==t,H=i===null,Y=i===i,ie=io(i),fe=y!==t,pe=y===null,_e=y===y,Ne=io(y);if(!pe&&!Ne&&!ie&&i>y||ie&&fe&&_e&&!pe&&!Ne||H&&fe&&_e||!L&&_e||!Y)return 1;if(!H&&!ie&&!Ne&&i<y||Ne&&L&&Y&&!H&&!ie||pe&&L&&Y||!fe&&Y||!_e)return-1}return 0}function fz(i,y,L){for(var H=-1,Y=i.criteria,ie=y.criteria,fe=Y.length,pe=L.length;++H<fe;){var _e=Q1(Y[H],ie[H]);if(_e){if(H>=pe)return _e;var Ne=L[H];return _e*(Ne=="desc"?-1:1)}}return i.index-y.index}function Z1(i,y,L,H){for(var Y=-1,ie=i.length,fe=L.length,pe=-1,_e=y.length,Ne=Er(ie-fe,0),Pe=Ee(_e+Ne),je=!H;++pe<_e;)Pe[pe]=y[pe];for(;++Y<fe;)(je||Y<ie)&&(Pe[L[Y]]=i[Y]);for(;Ne--;)Pe[pe++]=i[Y++];return Pe}function X1(i,y,L,H){for(var Y=-1,ie=i.length,fe=-1,pe=L.length,_e=-1,Ne=y.length,Pe=Er(ie-pe,0),je=Ee(Pe+Ne),st=!H;++Y<Pe;)je[Y]=i[Y];for(var yt=Y;++_e<Ne;)je[yt+_e]=y[_e];for(;++fe<pe;)(st||Y<ie)&&(je[yt+L[fe]]=i[Y++]);return je}function zi(i,y){var L=-1,H=i.length;for(y||(y=Ee(H));++L<H;)y[L]=i[L];return y}function ls(i,y,L,H){var Y=!L;L||(L={});for(var ie=-1,fe=y.length;++ie<fe;){var pe=y[ie],_e=H?H(L[pe],i[pe],pe,L,i):t;_e===t&&(_e=i[pe]),Y?ss(L,pe,_e):Mc(L,pe,_e)}return L}function pz(i,y){return ls(i,bg(i),y)}function gz(i,y){return ls(i,dC(i),y)}function $h(i,y){return function(L,H){var Y=zt(L)?bl:PP,ie=y?y():{};return Y(L,i,Tt(H,2),ie)}}function kl(i){return Jt(function(y,L){var H=-1,Y=L.length,ie=Y>1?L[Y-1]:t,fe=Y>2?L[2]:t;for(ie=i.length>3&&typeof ie=="function"?(Y--,ie):t,fe&&yi(L[0],L[1],fe)&&(ie=Y<3?t:ie,Y=1),y=Kt(y);++H<Y;){var pe=L[H];pe&&i(y,pe,H,ie)}return y})}function eC(i,y){return function(L,H){if(L==null)return L;if(!Bi(L))return i(L,H);for(var Y=L.length,ie=y?Y:-1,fe=Kt(L);(y?ie--:++ie<Y)&&H(fe[ie],ie,fe)!==!1;);return L}}function tC(i){return function(y,L,H){for(var Y=-1,ie=Kt(y),fe=H(y),pe=fe.length;pe--;){var _e=fe[i?pe:++Y];if(L(ie[_e],_e,ie)===!1)break}return y}}function mz(i,y,L){var H=y&w,Y=Dc(i);function ie(){var fe=this&&this!==qt&&this instanceof ie?Y:i;return fe.apply(H?L:this,arguments)}return ie}function nC(i){return function(y){y=_n(y);var L=ge(y)?It(y):t,H=L?L[0]:y.charAt(0),Y=L?Js(L,1).join(""):y.slice(1);return H[i]()+Y}}function _l(i){return function(y){return z(tk(ek(y).replace(xo,"")),i,"")}}function Dc(i){return function(){var y=arguments;switch(y.length){case 0:return new i;case 1:return new i(y[0]);case 2:return new i(y[0],y[1]);case 3:return new i(y[0],y[1],y[2]);case 4:return new i(y[0],y[1],y[2],y[3]);case 5:return new i(y[0],y[1],y[2],y[3],y[4]);case 6:return new i(y[0],y[1],y[2],y[3],y[4],y[5]);case 7:return new i(y[0],y[1],y[2],y[3],y[4],y[5],y[6])}var L=Cl(i.prototype),H=i.apply(L,y);return ir(H)?H:L}}function vz(i,y,L){var H=Dc(i);function Y(){for(var ie=arguments.length,fe=Ee(ie),pe=ie,_e=Al(Y);pe--;)fe[pe]=arguments[pe];var Ne=ie<3&&fe[0]!==_e&&fe[ie-1]!==_e?[]:Qe(fe,_e);if(ie-=Ne.length,ie<L)return aC(i,y,Sh,Y.placeholder,t,fe,Ne,t,t,L-ie);var Pe=this&&this!==qt&&this instanceof Y?H:i;return xn(Pe,this,fe)}return Y}function rC(i){return function(y,L,H){var Y=Kt(y);if(!Bi(y)){var ie=Tt(L,3);y=zr(y),L=function(pe){return ie(Y[pe],pe,Y)}}var fe=i(y,L,H);return fe>-1?Y[ie?y[fe]:fe]:t}}function iC(i){return Ts(function(y){var L=y.length,H=L,Y=_o.prototype.thru;for(i&&y.reverse();H--;){var ie=y[H];if(typeof ie!="function")throw new zn(g);if(Y&&!fe&&Mh(ie)=="wrapper")var fe=new _o([],!0)}for(H=fe?H:L;++H<L;){ie=y[H];var pe=Mh(ie),_e=pe=="wrapper"?vg(ie):t;_e&&xg(_e[0])&&_e[1]==(O|T|C|E)&&!_e[4].length&&_e[9]==1?fe=fe[Mh(_e[0])].apply(fe,_e[3]):fe=ie.length==1&&xg(ie)?fe[pe]():fe.thru(ie)}return function(){var Ne=arguments,Pe=Ne[0];if(fe&&Ne.length==1&&zt(Pe))return fe.plant(Pe).value();for(var je=0,st=L?y[je].apply(this,Ne):Pe;++je<L;)st=y[je].call(this,st);return st}})}function Sh(i,y,L,H,Y,ie,fe,pe,_e,Ne){var Pe=y&O,je=y&w,st=y&x,yt=y&(T|_),Et=y&k,Ut=st?t:Dc(i);function $t(){for(var Zt=arguments.length,on=Ee(Zt),oo=Zt;oo--;)on[oo]=arguments[oo];if(yt)var bi=Al($t),so=Zn(on,bi);if(H&&(on=Z1(on,H,Y,yt)),ie&&(on=X1(on,ie,fe,yt)),Zt-=so,yt&&Zt<Ne){var dr=Qe(on,bi);return aC(i,y,Sh,$t.placeholder,L,on,dr,pe,_e,Ne-Zt)}var Go=je?L:this,Rs=st?Go[i]:i;return Zt=on.length,pe?on=Pz(on,pe):Et&&Zt>1&&on.reverse(),Pe&&_e<Zt&&(on.length=_e),this&&this!==qt&&this instanceof $t&&(Rs=Ut||Dc(Rs)),Rs.apply(Go,on)}return $t}function oC(i,y){return function(L,H){return VP(L,i,y(H),{})}}function Th(i,y){return function(L,H){var Y;if(L===t&&H===t)return y;if(L!==t&&(Y=L),H!==t){if(Y===t)return H;typeof L=="string"||typeof H=="string"?(L=ro(L),H=ro(H)):(L=U1(L),H=U1(H)),Y=i(L,H)}return Y}}function fg(i){return Ts(function(y){return y=I(y,cn(Tt())),Jt(function(L){var H=this;return i(y,function(Y){return xn(Y,H,L)})})})}function Eh(i,y){y=y===t?" ":ro(y);var L=y.length;if(L<2)return L?sg(y,i):y;var H=sg(y,gh(i/Yt(y)));return ge(y)?Js(It(H),0,i).join(""):H.slice(0,i)}function yz(i,y,L,H){var Y=y&w,ie=Dc(i);function fe(){for(var pe=-1,_e=arguments.length,Ne=-1,Pe=H.length,je=Ee(Pe+_e),st=this&&this!==qt&&this instanceof fe?ie:i;++Ne<Pe;)je[Ne]=H[Ne];for(;_e--;)je[Ne++]=arguments[++pe];return xn(st,Y?L:this,je)}return fe}function sC(i){return function(y,L,H){return H&&typeof H!="number"&&yi(y,L,H)&&(L=H=t),y=Ms(y),L===t?(L=y,y=0):L=Ms(L),H=H===t?y<L?1:-1:Ms(H),rz(y,L,H,i)}}function Ih(i){return function(y,L){return typeof y=="string"&&typeof L=="string"||(y=To(y),L=To(L)),i(y,L)}}function aC(i,y,L,H,Y,ie,fe,pe,_e,Ne){var Pe=y&T,je=Pe?fe:t,st=Pe?t:fe,yt=Pe?ie:t,Et=Pe?t:ie;y|=Pe?C:P,y&=~(Pe?P:C),y&R||(y&=-4);var Ut=[i,y,Y,yt,je,Et,st,pe,_e,Ne],$t=L.apply(t,Ut);return xg(i)&&bC($t,Ut),$t.placeholder=H,wC($t,i,y)}function pg(i){var y=vn[i];return function(L,H){if(L=To(L),H=H==null?0:oi(Wt(H),292),H&&w1(L)){var Y=(_n(L)+"e").split("e"),ie=y(Y[0]+"e"+(+Y[1]+H));return Y=(_n(ie)+"e").split("e"),+(Y[0]+"e"+(+Y[1]-H))}return y(L)}}var bz=wl&&1/ot(new wl([,-0]))[1]==U?function(i){return new wl(i)}:Pg;function lC(i){return function(y){var L=si(y);return L==at?He(y):L==hn?ft(y):Hn(y,i(y))}}function Ss(i,y,L,H,Y,ie,fe,pe){var _e=y&x;if(!_e&&typeof i!="function")throw new zn(g);var Ne=H?H.length:0;if(Ne||(y&=-97,H=Y=t),fe=fe===t?fe:Er(Wt(fe),0),pe=pe===t?pe:Wt(pe),Ne-=Y?Y.length:0,y&P){var Pe=H,je=Y;H=Y=t}var st=_e?t:vg(i),yt=[i,y,L,H,Y,Pe,je,ie,fe,pe];if(st&&Oz(yt,st),i=yt[0],y=yt[1],L=yt[2],H=yt[3],Y=yt[4],pe=yt[9]=yt[9]===t?_e?0:i.length:Er(yt[9]-Ne,0),!pe&&y&(T|_)&&(y&=-25),!y||y==w)var Et=mz(i,y,L);else y==T||y==_?Et=vz(i,y,pe):(y==C||y==(w|C))&&!Y.length?Et=yz(i,y,L,H):Et=Sh.apply(t,yt);var Ut=st?W1:bC;return wC(Ut(Et,yt),i,y)}function cC(i,y,L,H){return i===t||Vo(i,_s[L])&&!kn.call(H,L)?y:i}function uC(i,y,L,H,Y,ie){return ir(i)&&ir(y)&&(ie.set(y,i),kh(i,y,t,uC,ie),ie.delete(y)),i}function wz(i){return Bc(i)?t:i}function hC(i,y,L,H,Y,ie){var fe=L&f,pe=i.length,_e=y.length;if(pe!=_e&&!(fe&&_e>pe))return!1;var Ne=ie.get(i),Pe=ie.get(y);if(Ne&&Pe)return Ne==y&&Pe==i;var je=-1,st=!0,yt=L&m?new Ra:t;for(ie.set(i,y),ie.set(y,i);++je<pe;){var Et=i[je],Ut=y[je];if(H)var $t=fe?H(Ut,Et,je,y,i,ie):H(Et,Ut,je,i,y,ie);if($t!==t){if($t)continue;st=!1;break}if(yt){if(!W(y,function(Zt,on){if(!Ot(yt,on)&&(Et===Zt||Y(Et,Zt,L,H,ie)))return yt.push(on)})){st=!1;break}}else if(!(Et===Ut||Y(Et,Ut,L,H,ie))){st=!1;break}}return ie.delete(i),ie.delete(y),st}function xz(i,y,L,H,Y,ie,fe){switch(L){case Dn:if(i.byteLength!=y.byteLength||i.byteOffset!=y.byteOffset)return!1;i=i.buffer,y=y.buffer;case Sn:return!(i.byteLength!=y.byteLength||!ie(new hh(i),new hh(y)));case we:case Ae:case ct:return Vo(+i,+y);case ze:return i.name==y.name&&i.message==y.message;case Vt:case $n:return i==y+"";case at:var pe=He;case hn:var _e=H&f;if(pe||(pe=ot),i.size!=y.size&&!_e)return!1;var Ne=fe.get(i);if(Ne)return Ne==y;H|=m,fe.set(i,y);var Pe=hC(pe(i),pe(y),H,Y,ie,fe);return fe.delete(i),Pe;case mt:if(Ic)return Ic.call(i)==Ic.call(y)}return!1}function Cz(i,y,L,H,Y,ie){var fe=L&f,pe=gg(i),_e=pe.length,Ne=gg(y),Pe=Ne.length;if(_e!=Pe&&!fe)return!1;for(var je=_e;je--;){var st=pe[je];if(!(fe?st in y:kn.call(y,st)))return!1}var yt=ie.get(i),Et=ie.get(y);if(yt&&Et)return yt==y&&Et==i;var Ut=!0;ie.set(i,y),ie.set(y,i);for(var $t=fe;++je<_e;){st=pe[je];var Zt=i[st],on=y[st];if(H)var oo=fe?H(on,Zt,st,y,i,ie):H(Zt,on,st,i,y,ie);if(!(oo===t?Zt===on||Y(Zt,on,L,H,ie):oo)){Ut=!1;break}$t||($t=st=="constructor")}if(Ut&&!$t){var bi=i.constructor,so=y.constructor;bi!=so&&"constructor"in i&&"constructor"in y&&!(typeof bi=="function"&&bi instanceof bi&&typeof so=="function"&&so instanceof so)&&(Ut=!1)}return ie.delete(i),ie.delete(y),Ut}function Ts(i){return kg(vC(i,t,$C),i+"")}function gg(i){return M1(i,zr,bg)}function mg(i){return M1(i,Fi,dC)}var vg=vh?function(i){return vh.get(i)}:Pg;function Mh(i){for(var y=i.name+"",L=xl[y],H=kn.call(xl,y)?L.length:0;H--;){var Y=L[H],ie=Y.func;if(ie==null||ie==i)return Y.name}return y}function Al(i){var y=kn.call(te,"placeholder")?te:i;return y.placeholder}function Tt(){var i=te.iteratee||Ng;return i=i===Ng?O1:i,arguments.length?i(arguments[0],arguments[1]):i}function Rh(i,y){var L=i.__data__;return Iz(y)?L[typeof y=="string"?"string":"hash"]:L.map}function yg(i){for(var y=zr(i),L=y.length;L--;){var H=y[L],Y=i[H];y[L]=[H,Y,gC(Y)]}return y}function Na(i,y){var L=ce(i,y);return L1(L)?L:t}function kz(i){var y=kn.call(i,Ia),L=i[Ia];try{i[Ia]=t;var H=!0}catch{}var Y=ch.call(i);return H&&(y?i[Ia]=L:delete i[Ia]),Y}var bg=Gp?function(i){return i==null?[]:(i=Kt(i),Hr(Gp(i),function(y){return y1.call(i,y)}))}:zg,dC=Gp?function(i){for(var y=[];i;)S(y,bg(i)),i=dh(i);return y}:zg,si=vi;(qp&&si(new qp(new ArrayBuffer(1)))!=Dn||Sc&&si(new Sc)!=at||Yp&&si(Yp.resolve())!=Ct||wl&&si(new wl)!=hn||Tc&&si(new Tc)!=Gt)&&(si=function(i){var y=vi(i),L=y==Ie?i.constructor:t,H=L?Da(L):"";if(H)switch(H){case oP:return Dn;case sP:return at;case aP:return Ct;case lP:return hn;case cP:return Gt}return y});function _z(i,y,L){for(var H=-1,Y=L.length;++H<Y;){var ie=L[H],fe=ie.size;switch(ie.type){case"drop":i+=fe;break;case"dropRight":y-=fe;break;case"take":y=oi(y,i+fe);break;case"takeRight":i=Er(i,y-fe);break}}return{start:i,end:y}}function Az(i){var y=i.match(ms);return y?y[1].split(vs):[]}function fC(i,y,L){y=Ks(y,i);for(var H=-1,Y=y.length,ie=!1;++H<Y;){var fe=Uo(y[H]);if(!(ie=i!=null&&L(i,fe)))break;i=i[fe]}return ie||++H!=Y?ie:(Y=i==null?0:i.length,!!Y&&Bh(Y)&&Es(fe,Y)&&(zt(i)||Pa(i)))}function $z(i){var y=i.length,L=new i.constructor(y);return y&&typeof i[0]=="string"&&kn.call(i,"index")&&(L.index=i.index,L.input=i.input),L}function pC(i){return typeof i.constructor=="function"&&!Pc(i)?Cl(dh(i)):{}}function Sz(i,y,L){var H=i.constructor;switch(y){case Sn:return dg(i);case we:case Ae:return new H(+i);case Dn:return uz(i,L);case Gn:case Ln:case qn:case tr:case dn:case Pn:case Ti:case Xr:case ei:return J1(i,L);case at:return new H;case ct:case $n:return new H(i);case Vt:return hz(i);case hn:return new H;case mt:return dz(i)}}function Tz(i,y){var L=y.length;if(!L)return i;var H=L-1;return y[H]=(L>1?"& ":"")+y[H],y=y.join(L>2?", ":" "),i.replace(hi,`{
1460
+ /* [wrapped with `+y+`] */
1461
+ `)}function Ez(i){return zt(i)||Pa(i)||!!(b1&&i&&i[b1])}function Es(i,y){var L=typeof i;return y=y??q,!!y&&(L=="number"||L!="symbol"&&Kn.test(i))&&i>-1&&i%1==0&&i<y}function yi(i,y,L){if(!ir(L))return!1;var H=typeof y;return(H=="number"?Bi(L)&&Es(y,L.length):H=="string"&&y in L)?Vo(L[y],i):!1}function wg(i,y){if(zt(i))return!1;var L=typeof i;return L=="number"||L=="symbol"||L=="boolean"||i==null||io(i)?!0:Yn.test(i)||!Ii.test(i)||y!=null&&i in Kt(y)}function Iz(i){var y=typeof i;return y=="string"||y=="number"||y=="symbol"||y=="boolean"?i!=="__proto__":i===null}function xg(i){var y=Mh(i),L=te[y];if(typeof L!="function"||!(y in tn.prototype))return!1;if(i===L)return!0;var H=vg(L);return!!H&&i===H[0]}function Mz(i){return!!g1&&g1 in i}var Rz=ah?Is:Bg;function Pc(i){var y=i&&i.constructor,L=typeof y=="function"&&y.prototype||_s;return i===L}function gC(i){return i===i&&!ir(i)}function mC(i,y){return function(L){return L==null?!1:L[i]===y&&(y!==t||i in Kt(L))}}function Lz(i){var y=Ph(i,function(H){return L.size===a&&L.clear(),H}),L=y.cache;return y}function Oz(i,y){var L=i[1],H=y[1],Y=L|H,ie=Y<(w|x|O),fe=H==O&&L==T||H==O&&L==E&&i[7].length<=y[8]||H==(O|E)&&y[7].length<=y[8]&&L==T;if(!(ie||fe))return i;H&w&&(i[2]=y[2],Y|=L&w?0:R);var pe=y[3];if(pe){var _e=i[3];i[3]=_e?Z1(_e,pe,y[4]):pe,i[4]=_e?Qe(i[3],l):y[4]}return pe=y[5],pe&&(_e=i[5],i[5]=_e?X1(_e,pe,y[6]):pe,i[6]=_e?Qe(i[5],l):y[6]),pe=y[7],pe&&(i[7]=pe),H&O&&(i[8]=i[8]==null?y[8]:oi(i[8],y[8])),i[9]==null&&(i[9]=y[9]),i[0]=y[0],i[1]=Y,i}function Nz(i){var y=[];if(i!=null)for(var L in Kt(i))y.push(L);return y}function Dz(i){return ch.call(i)}function vC(i,y,L){return y=Er(y===t?i.length-1:y,0),function(){for(var H=arguments,Y=-1,ie=Er(H.length-y,0),fe=Ee(ie);++Y<ie;)fe[Y]=H[y+Y];Y=-1;for(var pe=Ee(y+1);++Y<y;)pe[Y]=H[Y];return pe[y]=L(fe),xn(i,this,pe)}}function yC(i,y){return y.length<2?i:Oa(i,$o(y,0,-1))}function Pz(i,y){for(var L=i.length,H=oi(y.length,L),Y=zi(i);H--;){var ie=y[H];i[H]=Es(ie,L)?Y[ie]:t}return i}function Cg(i,y){if(!(y==="constructor"&&typeof i[y]=="function")&&y!="__proto__")return i[y]}var bC=xC(W1),zc=ZD||function(i,y){return qt.setTimeout(i,y)},kg=xC(sz);function wC(i,y,L){var H=y+"";return kg(i,Tz(H,zz(Az(H),L)))}function xC(i){var y=0,L=0;return function(){var H=nP(),Y=$-(H-L);if(L=H,Y>0){if(++y>=M)return arguments[0]}else y=0;return i.apply(t,arguments)}}function Lh(i,y){var L=-1,H=i.length,Y=H-1;for(y=y===t?H:y;++L<y;){var ie=og(L,Y),fe=i[ie];i[ie]=i[L],i[L]=fe}return i.length=y,i}var CC=Lz(function(i){var y=[];return i.charCodeAt(0)===46&&y.push(""),i.replace($r,function(L,H,Y,ie){y.push(Y?ie.replace(di,"$1"):H||L)}),y});function Uo(i){if(typeof i=="string"||io(i))return i;var y=i+"";return y=="0"&&1/i==-U?"-0":y}function Da(i){if(i!=null){try{return lh.call(i)}catch{}try{return i+""}catch{}}return""}function zz(i,y){return Sr(he,function(L){var H="_."+L[0];y&L[1]&&!Di(i,H)&&i.push(H)}),i.sort()}function kC(i){if(i instanceof tn)return i.clone();var y=new _o(i.__wrapped__,i.__chain__);return y.__actions__=zi(i.__actions__),y.__index__=i.__index__,y.__values__=i.__values__,y}function Bz(i,y,L){(L?yi(i,y,L):y===t)?y=1:y=Er(Wt(y),0);var H=i==null?0:i.length;if(!H||y<1)return[];for(var Y=0,ie=0,fe=Ee(gh(H/y));Y<H;)fe[ie++]=$o(i,Y,Y+=y);return fe}function Fz(i){for(var y=-1,L=i==null?0:i.length,H=0,Y=[];++y<L;){var ie=i[y];ie&&(Y[H++]=ie)}return Y}function jz(){var i=arguments.length;if(!i)return[];for(var y=Ee(i-1),L=arguments[0],H=i;H--;)y[H-1]=arguments[H];return S(zt(L)?zi(L):[L],Gr(y,1))}var Wz=Jt(function(i,y){return hr(i)?Rc(i,Gr(y,1,hr,!0)):[]}),Hz=Jt(function(i,y){var L=So(y);return hr(L)&&(L=t),hr(i)?Rc(i,Gr(y,1,hr,!0),Tt(L,2)):[]}),Uz=Jt(function(i,y){var L=So(y);return hr(L)&&(L=t),hr(i)?Rc(i,Gr(y,1,hr,!0),t,L):[]});function Vz(i,y,L){var H=i==null?0:i.length;return H?(y=L||y===t?1:Wt(y),$o(i,y<0?0:y,H)):[]}function Gz(i,y,L){var H=i==null?0:i.length;return H?(y=L||y===t?1:Wt(y),y=H-y,$o(i,0,y<0?0:y)):[]}function qz(i,y){return i&&i.length?Ah(i,Tt(y,3),!0,!0):[]}function Yz(i,y){return i&&i.length?Ah(i,Tt(y,3),!0):[]}function Kz(i,y,L,H){var Y=i==null?0:i.length;return Y?(L&&typeof L!="number"&&yi(i,y,L)&&(L=0,H=Y),jP(i,y,L,H)):[]}function _C(i,y,L){var H=i==null?0:i.length;if(!H)return-1;var Y=L==null?0:Wt(L);return Y<0&&(Y=Er(H+Y,0)),de(i,Tt(y,3),Y)}function AC(i,y,L){var H=i==null?0:i.length;if(!H)return-1;var Y=H-1;return L!==t&&(Y=Wt(L),Y=L<0?Er(H+Y,0):oi(Y,H-1)),de(i,Tt(y,3),Y,!0)}function $C(i){var y=i==null?0:i.length;return y?Gr(i,1):[]}function Jz(i){var y=i==null?0:i.length;return y?Gr(i,U):[]}function Qz(i,y){var L=i==null?0:i.length;return L?(y=y===t?1:Wt(y),Gr(i,y)):[]}function Zz(i){for(var y=-1,L=i==null?0:i.length,H={};++y<L;){var Y=i[y];ss(H,Y[0],Y[1])}return H}function SC(i){return i&&i.length?i[0]:t}function Xz(i,y,L){var H=i==null?0:i.length;if(!H)return-1;var Y=L==null?0:Wt(L);return Y<0&&(Y=Er(H+Y,0)),ke(i,y,Y)}function eB(i){var y=i==null?0:i.length;return y?$o(i,0,-1):[]}var tB=Jt(function(i){var y=I(i,ug);return y.length&&y[0]===i[0]?eg(y):[]}),nB=Jt(function(i){var y=So(i),L=I(i,ug);return y===So(L)?y=t:L.pop(),L.length&&L[0]===i[0]?eg(L,Tt(y,2)):[]}),rB=Jt(function(i){var y=So(i),L=I(i,ug);return y=typeof y=="function"?y:t,y&&L.pop(),L.length&&L[0]===i[0]?eg(L,t,y):[]});function iB(i,y){return i==null?"":eP.call(i,y)}function So(i){var y=i==null?0:i.length;return y?i[y-1]:t}function oB(i,y,L){var H=i==null?0:i.length;if(!H)return-1;var Y=H;return L!==t&&(Y=Wt(L),Y=Y<0?Er(H+Y,0):oi(Y,H-1)),y===y?pn(i,y,Y):de(i,Ce,Y,!0)}function sB(i,y){return i&&i.length?z1(i,Wt(y)):t}var aB=Jt(TC);function TC(i,y){return i&&i.length&&y&&y.length?ig(i,y):i}function lB(i,y,L){return i&&i.length&&y&&y.length?ig(i,y,Tt(L,2)):i}function cB(i,y,L){return i&&i.length&&y&&y.length?ig(i,y,t,L):i}var uB=Ts(function(i,y){var L=i==null?0:i.length,H=Jp(i,y);return j1(i,I(y,function(Y){return Es(Y,L)?+Y:Y}).sort(Q1)),H});function hB(i,y){var L=[];if(!(i&&i.length))return L;var H=-1,Y=[],ie=i.length;for(y=Tt(y,3);++H<ie;){var fe=i[H];y(fe,H,i)&&(L.push(fe),Y.push(H))}return j1(i,Y),L}function _g(i){return i==null?i:iP.call(i)}function dB(i,y,L){var H=i==null?0:i.length;return H?(L&&typeof L!="number"&&yi(i,y,L)?(y=0,L=H):(y=y==null?0:Wt(y),L=L===t?H:Wt(L)),$o(i,y,L)):[]}function fB(i,y){return _h(i,y)}function pB(i,y,L){return ag(i,y,Tt(L,2))}function gB(i,y){var L=i==null?0:i.length;if(L){var H=_h(i,y);if(H<L&&Vo(i[H],y))return H}return-1}function mB(i,y){return _h(i,y,!0)}function vB(i,y,L){return ag(i,y,Tt(L,2),!0)}function yB(i,y){var L=i==null?0:i.length;if(L){var H=_h(i,y,!0)-1;if(Vo(i[H],y))return H}return-1}function bB(i){return i&&i.length?H1(i):[]}function wB(i,y){return i&&i.length?H1(i,Tt(y,2)):[]}function xB(i){var y=i==null?0:i.length;return y?$o(i,1,y):[]}function CB(i,y,L){return i&&i.length?(y=L||y===t?1:Wt(y),$o(i,0,y<0?0:y)):[]}function kB(i,y,L){var H=i==null?0:i.length;return H?(y=L||y===t?1:Wt(y),y=H-y,$o(i,y<0?0:y,H)):[]}function _B(i,y){return i&&i.length?Ah(i,Tt(y,3),!1,!0):[]}function AB(i,y){return i&&i.length?Ah(i,Tt(y,3)):[]}var $B=Jt(function(i){return Ys(Gr(i,1,hr,!0))}),SB=Jt(function(i){var y=So(i);return hr(y)&&(y=t),Ys(Gr(i,1,hr,!0),Tt(y,2))}),TB=Jt(function(i){var y=So(i);return y=typeof y=="function"?y:t,Ys(Gr(i,1,hr,!0),t,y)});function EB(i){return i&&i.length?Ys(i):[]}function IB(i,y){return i&&i.length?Ys(i,Tt(y,2)):[]}function MB(i,y){return y=typeof y=="function"?y:t,i&&i.length?Ys(i,t,y):[]}function Ag(i){if(!(i&&i.length))return[];var y=0;return i=Hr(i,function(L){if(hr(L))return y=Er(L.length,y),!0}),pt(y,function(L){return I(i,Be(L))})}function EC(i,y){if(!(i&&i.length))return[];var L=Ag(i);return y==null?L:I(L,function(H){return xn(y,t,H)})}var RB=Jt(function(i,y){return hr(i)?Rc(i,y):[]}),LB=Jt(function(i){return cg(Hr(i,hr))}),OB=Jt(function(i){var y=So(i);return hr(y)&&(y=t),cg(Hr(i,hr),Tt(y,2))}),NB=Jt(function(i){var y=So(i);return y=typeof y=="function"?y:t,cg(Hr(i,hr),t,y)}),DB=Jt(Ag);function PB(i,y){return q1(i||[],y||[],Mc)}function zB(i,y){return q1(i||[],y||[],Nc)}var BB=Jt(function(i){var y=i.length,L=y>1?i[y-1]:t;return L=typeof L=="function"?(i.pop(),L):t,EC(i,L)});function IC(i){var y=te(i);return y.__chain__=!0,y}function FB(i,y){return y(i),i}function Oh(i,y){return y(i)}var jB=Ts(function(i){var y=i.length,L=y?i[0]:0,H=this.__wrapped__,Y=function(ie){return Jp(ie,i)};return y>1||this.__actions__.length||!(H instanceof tn)||!Es(L)?this.thru(Y):(H=H.slice(L,+L+(y?1:0)),H.__actions__.push({func:Oh,args:[Y],thisArg:t}),new _o(H,this.__chain__).thru(function(ie){return y&&!ie.length&&ie.push(t),ie}))});function WB(){return IC(this)}function HB(){return new _o(this.value(),this.__chain__)}function UB(){this.__values__===t&&(this.__values__=UC(this.value()));var i=this.__index__>=this.__values__.length,y=i?t:this.__values__[this.__index__++];return{done:i,value:y}}function VB(){return this}function GB(i){for(var y,L=this;L instanceof bh;){var H=kC(L);H.__index__=0,H.__values__=t,y?Y.__wrapped__=H:y=H;var Y=H;L=L.__wrapped__}return Y.__wrapped__=i,y}function qB(){var i=this.__wrapped__;if(i instanceof tn){var y=i;return this.__actions__.length&&(y=new tn(this)),y=y.reverse(),y.__actions__.push({func:Oh,args:[_g],thisArg:t}),new _o(y,this.__chain__)}return this.thru(_g)}function YB(){return G1(this.__wrapped__,this.__actions__)}var KB=$h(function(i,y,L){kn.call(i,L)?++i[L]:ss(i,L,1)});function JB(i,y,L){var H=zt(i)?os:FP;return L&&yi(i,y,L)&&(y=t),H(i,Tt(y,3))}function QB(i,y){var L=zt(i)?Hr:E1;return L(i,Tt(y,3))}var ZB=rC(_C),XB=rC(AC);function eF(i,y){return Gr(Nh(i,y),1)}function tF(i,y){return Gr(Nh(i,y),U)}function nF(i,y,L){return L=L===t?1:Wt(L),Gr(Nh(i,y),L)}function MC(i,y){var L=zt(i)?Sr:qs;return L(i,Tt(y,3))}function RC(i,y){var L=zt(i)?ii:T1;return L(i,Tt(y,3))}var rF=$h(function(i,y,L){kn.call(i,L)?i[L].push(y):ss(i,L,[y])});function iF(i,y,L,H){i=Bi(i)?i:Sl(i),L=L&&!H?Wt(L):0;var Y=i.length;return L<0&&(L=Er(Y+L,0)),Fh(i)?L<=Y&&i.indexOf(y,L)>-1:!!Y&&ke(i,y,L)>-1}var oF=Jt(function(i,y,L){var H=-1,Y=typeof y=="function",ie=Bi(i)?Ee(i.length):[];return qs(i,function(fe){ie[++H]=Y?xn(y,fe,L):Lc(fe,y,L)}),ie}),sF=$h(function(i,y,L){ss(i,L,y)});function Nh(i,y){var L=zt(i)?I:N1;return L(i,Tt(y,3))}function aF(i,y,L,H){return i==null?[]:(zt(y)||(y=y==null?[]:[y]),L=H?t:L,zt(L)||(L=L==null?[]:[L]),B1(i,y,L))}var lF=$h(function(i,y,L){i[L?0:1].push(y)},function(){return[[],[]]});function cF(i,y,L){var H=zt(i)?z:et,Y=arguments.length<3;return H(i,Tt(y,4),L,Y,qs)}function uF(i,y,L){var H=zt(i)?F:et,Y=arguments.length<3;return H(i,Tt(y,4),L,Y,T1)}function hF(i,y){var L=zt(i)?Hr:E1;return L(i,zh(Tt(y,3)))}function dF(i){var y=zt(i)?_1:iz;return y(i)}function fF(i,y,L){(L?yi(i,y,L):y===t)?y=1:y=Wt(y);var H=zt(i)?NP:oz;return H(i,y)}function pF(i){var y=zt(i)?DP:az;return y(i)}function gF(i){if(i==null)return 0;if(Bi(i))return Fh(i)?Yt(i):i.length;var y=si(i);return y==at||y==hn?i.size:ng(i).length}function mF(i,y,L){var H=zt(i)?W:lz;return L&&yi(i,y,L)&&(y=t),H(i,Tt(y,3))}var vF=Jt(function(i,y){if(i==null)return[];var L=y.length;return L>1&&yi(i,y[0],y[1])?y=[]:L>2&&yi(y[0],y[1],y[2])&&(y=[y[0]]),B1(i,Gr(y,1),[])}),Dh=QD||function(){return qt.Date.now()};function yF(i,y){if(typeof y!="function")throw new zn(g);return i=Wt(i),function(){if(--i<1)return y.apply(this,arguments)}}function LC(i,y,L){return y=L?t:y,y=i&&y==null?i.length:y,Ss(i,O,t,t,t,t,y)}function OC(i,y){var L;if(typeof y!="function")throw new zn(g);return i=Wt(i),function(){return--i>0&&(L=y.apply(this,arguments)),i<=1&&(y=t),L}}var $g=Jt(function(i,y,L){var H=w;if(L.length){var Y=Qe(L,Al($g));H|=C}return Ss(i,H,y,L,Y)}),NC=Jt(function(i,y,L){var H=w|x;if(L.length){var Y=Qe(L,Al(NC));H|=C}return Ss(y,H,i,L,Y)});function DC(i,y,L){y=L?t:y;var H=Ss(i,T,t,t,t,t,t,y);return H.placeholder=DC.placeholder,H}function PC(i,y,L){y=L?t:y;var H=Ss(i,_,t,t,t,t,t,y);return H.placeholder=PC.placeholder,H}function zC(i,y,L){var H,Y,ie,fe,pe,_e,Ne=0,Pe=!1,je=!1,st=!0;if(typeof i!="function")throw new zn(g);y=To(y)||0,ir(L)&&(Pe=!!L.leading,je="maxWait"in L,ie=je?Er(To(L.maxWait)||0,y):ie,st="trailing"in L?!!L.trailing:st);function yt(dr){var Go=H,Rs=Y;return H=Y=t,Ne=dr,fe=i.apply(Rs,Go),fe}function Et(dr){return Ne=dr,pe=zc(Zt,y),Pe?yt(dr):fe}function Ut(dr){var Go=dr-_e,Rs=dr-Ne,ik=y-Go;return je?oi(ik,ie-Rs):ik}function $t(dr){var Go=dr-_e,Rs=dr-Ne;return _e===t||Go>=y||Go<0||je&&Rs>=ie}function Zt(){var dr=Dh();if($t(dr))return on(dr);pe=zc(Zt,Ut(dr))}function on(dr){return pe=t,st&&H?yt(dr):(H=Y=t,fe)}function oo(){pe!==t&&Y1(pe),Ne=0,H=_e=Y=pe=t}function bi(){return pe===t?fe:on(Dh())}function so(){var dr=Dh(),Go=$t(dr);if(H=arguments,Y=this,_e=dr,Go){if(pe===t)return Et(_e);if(je)return Y1(pe),pe=zc(Zt,y),yt(_e)}return pe===t&&(pe=zc(Zt,y)),fe}return so.cancel=oo,so.flush=bi,so}var bF=Jt(function(i,y){return S1(i,1,y)}),wF=Jt(function(i,y,L){return S1(i,To(y)||0,L)});function xF(i){return Ss(i,k)}function Ph(i,y){if(typeof i!="function"||y!=null&&typeof y!="function")throw new zn(g);var L=function(){var H=arguments,Y=y?y.apply(this,H):H[0],ie=L.cache;if(ie.has(Y))return ie.get(Y);var fe=i.apply(this,H);return L.cache=ie.set(Y,fe)||ie,fe};return L.cache=new(Ph.Cache||$s),L}Ph.Cache=$s;function zh(i){if(typeof i!="function")throw new zn(g);return function(){var y=arguments;switch(y.length){case 0:return!i.call(this);case 1:return!i.call(this,y[0]);case 2:return!i.call(this,y[0],y[1]);case 3:return!i.call(this,y[0],y[1],y[2])}return!i.apply(this,y)}}function CF(i){return OC(2,i)}var kF=cz(function(i,y){y=y.length==1&&zt(y[0])?I(y[0],cn(Tt())):I(Gr(y,1),cn(Tt()));var L=y.length;return Jt(function(H){for(var Y=-1,ie=oi(H.length,L);++Y<ie;)H[Y]=y[Y].call(this,H[Y]);return xn(i,this,H)})}),Sg=Jt(function(i,y){var L=Qe(y,Al(Sg));return Ss(i,C,t,y,L)}),BC=Jt(function(i,y){var L=Qe(y,Al(BC));return Ss(i,P,t,y,L)}),_F=Ts(function(i,y){return Ss(i,E,t,t,t,y)});function AF(i,y){if(typeof i!="function")throw new zn(g);return y=y===t?y:Wt(y),Jt(i,y)}function $F(i,y){if(typeof i!="function")throw new zn(g);return y=y==null?0:Er(Wt(y),0),Jt(function(L){var H=L[y],Y=Js(L,0,y);return H&&S(Y,H),xn(i,this,Y)})}function SF(i,y,L){var H=!0,Y=!0;if(typeof i!="function")throw new zn(g);return ir(L)&&(H="leading"in L?!!L.leading:H,Y="trailing"in L?!!L.trailing:Y),zC(i,y,{leading:H,maxWait:y,trailing:Y})}function TF(i){return LC(i,1)}function EF(i,y){return Sg(hg(y),i)}function IF(){if(!arguments.length)return[];var i=arguments[0];return zt(i)?i:[i]}function MF(i){return Ao(i,o)}function RF(i,y){return y=typeof y=="function"?y:t,Ao(i,o,y)}function LF(i){return Ao(i,u|o)}function OF(i,y){return y=typeof y=="function"?y:t,Ao(i,u|o,y)}function NF(i,y){return y==null||$1(i,y,zr(y))}function Vo(i,y){return i===y||i!==i&&y!==y}var DF=Ih(Xp),PF=Ih(function(i,y){return i>=y}),Pa=R1((function(){return arguments})())?R1:function(i){return ar(i)&&kn.call(i,"callee")&&!y1.call(i,"callee")},zt=Ee.isArray,zF=Vs?cn(Vs):GP;function Bi(i){return i!=null&&Bh(i.length)&&!Is(i)}function hr(i){return ar(i)&&Bi(i)}function BF(i){return i===!0||i===!1||ar(i)&&vi(i)==we}var Qs=XD||Bg,FF=sr?cn(sr):qP;function jF(i){return ar(i)&&i.nodeType===1&&!Bc(i)}function WF(i){if(i==null)return!0;if(Bi(i)&&(zt(i)||typeof i=="string"||typeof i.splice=="function"||Qs(i)||$l(i)||Pa(i)))return!i.length;var y=si(i);if(y==at||y==hn)return!i.size;if(Pc(i))return!ng(i).length;for(var L in i)if(kn.call(i,L))return!1;return!0}function HF(i,y){return Oc(i,y)}function UF(i,y,L){L=typeof L=="function"?L:t;var H=L?L(i,y):t;return H===t?Oc(i,y,t,L):!!H}function Tg(i){if(!ar(i))return!1;var y=vi(i);return y==ze||y==Je||typeof i.message=="string"&&typeof i.name=="string"&&!Bc(i)}function VF(i){return typeof i=="number"&&w1(i)}function Is(i){if(!ir(i))return!1;var y=vi(i);return y==Ye||y==Ze||y==ye||y==St}function FC(i){return typeof i=="number"&&i==Wt(i)}function Bh(i){return typeof i=="number"&&i>-1&&i%1==0&&i<=q}function ir(i){var y=typeof i;return i!=null&&(y=="object"||y=="function")}function ar(i){return i!=null&&typeof i=="object"}var jC=to?cn(to):KP;function GF(i,y){return i===y||tg(i,y,yg(y))}function qF(i,y,L){return L=typeof L=="function"?L:t,tg(i,y,yg(y),L)}function YF(i){return WC(i)&&i!=+i}function KF(i){if(Rz(i))throw new _t(h);return L1(i)}function JF(i){return i===null}function QF(i){return i==null}function WC(i){return typeof i=="number"||ar(i)&&vi(i)==ct}function Bc(i){if(!ar(i)||vi(i)!=Ie)return!1;var y=dh(i);if(y===null)return!0;var L=kn.call(y,"constructor")&&y.constructor;return typeof L=="function"&&L instanceof L&&lh.call(L)==qD}var Eg=no?cn(no):JP;function ZF(i){return FC(i)&&i>=-q&&i<=q}var HC=Co?cn(Co):QP;function Fh(i){return typeof i=="string"||!zt(i)&&ar(i)&&vi(i)==$n}function io(i){return typeof i=="symbol"||ar(i)&&vi(i)==mt}var $l=Ea?cn(Ea):ZP;function XF(i){return i===t}function ej(i){return ar(i)&&si(i)==Gt}function tj(i){return ar(i)&&vi(i)==Fn}var nj=Ih(rg),rj=Ih(function(i,y){return i<=y});function UC(i){if(!i)return[];if(Bi(i))return Fh(i)?It(i):zi(i);if($c&&i[$c])return Le(i[$c]());var y=si(i),L=y==at?He:y==hn?ot:Sl;return L(i)}function Ms(i){if(!i)return i===0?i:0;if(i=To(i),i===U||i===-U){var y=i<0?-1:1;return y*Q}return i===i?i:0}function Wt(i){var y=Ms(i),L=y%1;return y===y?L?y-L:y:0}function VC(i){return i?La(Wt(i),0,le):0}function To(i){if(typeof i=="number")return i;if(io(i))return re;if(ir(i)){var y=typeof i.valueOf=="function"?i.valueOf():i;i=ir(y)?y+"":y}if(typeof i!="string")return i===0?i:+i;i=Rt(i);var L=Nr.test(i);return L||fn.test(i)?xt(i.slice(2),L?2:8):Us.test(i)?re:+i}function GC(i){return ls(i,Fi(i))}function ij(i){return i?La(Wt(i),-q,q):i===0?i:0}function _n(i){return i==null?"":ro(i)}var oj=kl(function(i,y){if(Pc(y)||Bi(y)){ls(y,zr(y),i);return}for(var L in y)kn.call(y,L)&&Mc(i,L,y[L])}),qC=kl(function(i,y){ls(y,Fi(y),i)}),YC=kl(function(i,y,L,H){ls(y,Fi(y),i,H)}),Ig=kl(function(i,y,L,H){ls(y,zr(y),i,H)}),sj=Ts(Jp);function aj(i,y){var L=Cl(i);return y==null?L:A1(L,y)}var lj=Jt(function(i,y){i=Kt(i);var L=-1,H=y.length,Y=H>2?y[2]:t;for(Y&&yi(y[0],y[1],Y)&&(H=1);++L<H;)for(var ie=y[L],fe=Fi(ie),pe=-1,_e=fe.length;++pe<_e;){var Ne=fe[pe],Pe=i[Ne];(Pe===t||Vo(Pe,_s[Ne])&&!kn.call(i,Ne))&&(i[Ne]=ie[Ne])}return i}),cj=Jt(function(i){return i.push(t,uC),xn(KC,t,i)});function uj(i,y){return se(i,Tt(y,3),as)}function hj(i,y){return se(i,Tt(y,3),Zp)}function dj(i,y){return i==null?i:Qp(i,Tt(y,3),Fi)}function fj(i,y){return i==null?i:I1(i,Tt(y,3),Fi)}function pj(i,y){return i&&as(i,Tt(y,3))}function gj(i,y){return i&&Zp(i,Tt(y,3))}function mj(i){return i==null?[]:Ch(i,zr(i))}function vj(i){return i==null?[]:Ch(i,Fi(i))}function Mg(i,y,L){var H=i==null?t:Oa(i,y);return H===t?L:H}function yj(i,y){return i!=null&&fC(i,y,WP)}function Rg(i,y){return i!=null&&fC(i,y,HP)}var bj=oC(function(i,y,L){y!=null&&typeof y.toString!="function"&&(y=ch.call(y)),i[y]=L},Og(ji)),wj=oC(function(i,y,L){y!=null&&typeof y.toString!="function"&&(y=ch.call(y)),kn.call(i,y)?i[y].push(L):i[y]=[L]},Tt),xj=Jt(Lc);function zr(i){return Bi(i)?k1(i):ng(i)}function Fi(i){return Bi(i)?k1(i,!0):XP(i)}function Cj(i,y){var L={};return y=Tt(y,3),as(i,function(H,Y,ie){ss(L,y(H,Y,ie),H)}),L}function kj(i,y){var L={};return y=Tt(y,3),as(i,function(H,Y,ie){ss(L,Y,y(H,Y,ie))}),L}var _j=kl(function(i,y,L){kh(i,y,L)}),KC=kl(function(i,y,L,H){kh(i,y,L,H)}),Aj=Ts(function(i,y){var L={};if(i==null)return L;var H=!1;y=I(y,function(ie){return ie=Ks(ie,i),H||(H=ie.length>1),ie}),ls(i,mg(i),L),H&&(L=Ao(L,u|d|o,wz));for(var Y=y.length;Y--;)lg(L,y[Y]);return L});function $j(i,y){return JC(i,zh(Tt(y)))}var Sj=Ts(function(i,y){return i==null?{}:tz(i,y)});function JC(i,y){if(i==null)return{};var L=I(mg(i),function(H){return[H]});return y=Tt(y),F1(i,L,function(H,Y){return y(H,Y[0])})}function Tj(i,y,L){y=Ks(y,i);var H=-1,Y=y.length;for(Y||(Y=1,i=t);++H<Y;){var ie=i==null?t:i[Uo(y[H])];ie===t&&(H=Y,ie=L),i=Is(ie)?ie.call(i):ie}return i}function Ej(i,y,L){return i==null?i:Nc(i,y,L)}function Ij(i,y,L,H){return H=typeof H=="function"?H:t,i==null?i:Nc(i,y,L,H)}var QC=lC(zr),ZC=lC(Fi);function Mj(i,y,L){var H=zt(i),Y=H||Qs(i)||$l(i);if(y=Tt(y,4),L==null){var ie=i&&i.constructor;Y?L=H?new ie:[]:ir(i)?L=Is(ie)?Cl(dh(i)):{}:L={}}return(Y?Sr:as)(i,function(fe,pe,_e){return y(L,fe,pe,_e)}),L}function Rj(i,y){return i==null?!0:lg(i,y)}function Lj(i,y,L){return i==null?i:V1(i,y,hg(L))}function Oj(i,y,L,H){return H=typeof H=="function"?H:t,i==null?i:V1(i,y,hg(L),H)}function Sl(i){return i==null?[]:Bt(i,zr(i))}function Nj(i){return i==null?[]:Bt(i,Fi(i))}function Dj(i,y,L){return L===t&&(L=y,y=t),L!==t&&(L=To(L),L=L===L?L:0),y!==t&&(y=To(y),y=y===y?y:0),La(To(i),y,L)}function Pj(i,y,L){return y=Ms(y),L===t?(L=y,y=0):L=Ms(L),i=To(i),UP(i,y,L)}function zj(i,y,L){if(L&&typeof L!="boolean"&&yi(i,y,L)&&(y=L=t),L===t&&(typeof y=="boolean"?(L=y,y=t):typeof i=="boolean"&&(L=i,i=t)),i===t&&y===t?(i=0,y=1):(i=Ms(i),y===t?(y=i,i=0):y=Ms(y)),i>y){var H=i;i=y,y=H}if(L||i%1||y%1){var Y=x1();return oi(i+Y*(y-i+jt("1e-"+((Y+"").length-1))),y)}return og(i,y)}var Bj=_l(function(i,y,L){return y=y.toLowerCase(),i+(L?XC(y):y)});function XC(i){return Lg(_n(i).toLowerCase())}function ek(i){return i=_n(i),i&&i.replace(go,V).replace(gi,"")}function Fj(i,y,L){i=_n(i),y=ro(y);var H=i.length;L=L===t?H:La(Wt(L),0,H);var Y=L;return L-=y.length,L>=0&&i.slice(L,Y)==y}function jj(i){return i=_n(i),i&&ur.test(i)?i.replace(jr,J):i}function Wj(i){return i=_n(i),i&&mn.test(i)?i.replace(Or,"\\$&"):i}var Hj=_l(function(i,y,L){return i+(L?"-":"")+y.toLowerCase()}),Uj=_l(function(i,y,L){return i+(L?" ":"")+y.toLowerCase()}),Vj=nC("toLowerCase");function Gj(i,y,L){i=_n(i),y=Wt(y);var H=y?Yt(i):0;if(!y||H>=y)return i;var Y=(y-H)/2;return Eh(mh(Y),L)+i+Eh(gh(Y),L)}function qj(i,y,L){i=_n(i),y=Wt(y);var H=y?Yt(i):0;return y&&H<y?i+Eh(y-H,L):i}function Yj(i,y,L){i=_n(i),y=Wt(y);var H=y?Yt(i):0;return y&&H<y?Eh(y-H,L)+i:i}function Kj(i,y,L){return L||y==null?y=0:y&&(y=+y),rP(_n(i).replace(jn,""),y||0)}function Jj(i,y,L){return(L?yi(i,y,L):y===t)?y=1:y=Wt(y),sg(_n(i),y)}function Qj(){var i=arguments,y=_n(i[0]);return i.length<3?y:y.replace(i[1],i[2])}var Zj=_l(function(i,y,L){return i+(L?"_":"")+y.toLowerCase()});function Xj(i,y,L){return L&&typeof L!="number"&&yi(i,y,L)&&(y=L=t),L=L===t?le:L>>>0,L?(i=_n(i),i&&(typeof y=="string"||y!=null&&!Eg(y))&&(y=ro(y),!y&&ge(i))?Js(It(i),0,L):i.split(y,L)):[]}var eW=_l(function(i,y,L){return i+(L?" ":"")+Lg(y)});function tW(i,y,L){return i=_n(i),L=L==null?0:La(Wt(L),0,i.length),y=ro(y),i.slice(L,L+y.length)==y}function nW(i,y,L){var H=te.templateSettings;L&&yi(i,y,L)&&(y=t),i=_n(i),y=Ig({},y,H,cC);var Y=Ig({},y.imports,H.imports,cC),ie=zr(Y),fe=Bt(Y,ie);Sr(ie,function($t){if(bs.test($t))throw new _t(s)});var pe,_e,Ne=0,Pe=y.interpolate||nr,je="__p += '",st=Pi((y.escape||nr).source+"|"+Pe.source+"|"+(Pe===Ko?Ri:nr).source+"|"+(y.evaluate||nr).source+"|$","g"),yt="//# sourceURL="+(kn.call(y,"sourceURL")?(y.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Oe+"]")+`
1462
+ `;i.replace(st,function($t,Zt,on,oo,bi,so){return on||(on=oo),je+=i.slice(Ne,so).replace(mo,ae),Zt&&(pe=!0,je+=`' +
1463
+ __e(`+Zt+`) +
1464
+ '`),bi&&(_e=!0,je+=`';
1465
+ `+bi+`;
1466
+ __p += '`),on&&(je+=`' +
1467
+ ((__t = (`+on+`)) == null ? '' : __t) +
1468
+ '`),Ne=so+$t.length,$t}),je+=`';
1469
+ `;var Et=kn.call(y,"variable")&&y.variable;if(!Et)je=`with (obj) {
1470
+ `+je+`
1471
+ }
1472
+ `;else if(bs.test(Et))throw new _t(v);je=(_e?je.replace(Ei,""):je).replace(fo,"$1").replace(vr,"$1;"),je="function("+(Et||"obj")+`) {
1473
+ `+(Et?"":`obj || (obj = {});
1474
+ `)+"var __t, __p = ''"+(pe?", __e = _.escape":"")+(_e?`, __j = Array.prototype.join;
1475
+ function print() { __p += __j.call(arguments, '') }
1476
+ `:`;
1477
+ `)+je+`return __p
1478
+ }`;var Ut=nk(function(){return Nt(ie,yt+"return "+je).apply(t,fe)});if(Ut.source=je,Tg(Ut))throw Ut;return Ut}function rW(i){return _n(i).toLowerCase()}function iW(i){return _n(i).toUpperCase()}function oW(i,y,L){if(i=_n(i),i&&(L||y===t))return Rt(i);if(!i||!(y=ro(y)))return i;var H=It(i),Y=It(y),ie=br(H,Y),fe=Tr(H,Y)+1;return Js(H,ie,fe).join("")}function sW(i,y,L){if(i=_n(i),i&&(L||y===t))return i.slice(0,At(i)+1);if(!i||!(y=ro(y)))return i;var H=It(i),Y=Tr(H,It(y))+1;return Js(H,0,Y).join("")}function aW(i,y,L){if(i=_n(i),i&&(L||y===t))return i.replace(jn,"");if(!i||!(y=ro(y)))return i;var H=It(i),Y=br(H,It(y));return Js(H,Y).join("")}function lW(i,y){var L=B,H=N;if(ir(y)){var Y="separator"in y?y.separator:Y;L="length"in y?Wt(y.length):L,H="omission"in y?ro(y.omission):H}i=_n(i);var ie=i.length;if(ge(i)){var fe=It(i);ie=fe.length}if(L>=ie)return i;var pe=L-Yt(H);if(pe<1)return H;var _e=fe?Js(fe,0,pe).join(""):i.slice(0,pe);if(Y===t)return _e+H;if(fe&&(pe+=_e.length-pe),Eg(Y)){if(i.slice(pe).search(Y)){var Ne,Pe=_e;for(Y.global||(Y=Pi(Y.source,_n(Dt.exec(Y))+"g")),Y.lastIndex=0;Ne=Y.exec(Pe);)var je=Ne.index;_e=_e.slice(0,je===t?pe:je)}}else if(i.indexOf(ro(Y),pe)!=pe){var st=_e.lastIndexOf(Y);st>-1&&(_e=_e.slice(0,st))}return _e+H}function cW(i){return i=_n(i),i&&po.test(i)?i.replace(Ji,bt):i}var uW=_l(function(i,y,L){return i+(L?" ":"")+y.toUpperCase()}),Lg=nC("toUpperCase");function tk(i,y,L){return i=_n(i),y=L?t:y,y===t?Se(i)?wr(i):Z(i):i.match(y)||[]}var nk=Jt(function(i,y){try{return xn(i,t,y)}catch(L){return Tg(L)?L:new _t(L)}}),hW=Ts(function(i,y){return Sr(y,function(L){L=Uo(L),ss(i,L,$g(i[L],i))}),i});function dW(i){var y=i==null?0:i.length,L=Tt();return i=y?I(i,function(H){if(typeof H[1]!="function")throw new zn(g);return[L(H[0]),H[1]]}):[],Jt(function(H){for(var Y=-1;++Y<y;){var ie=i[Y];if(xn(ie[0],this,H))return xn(ie[1],this,H)}})}function fW(i){return BP(Ao(i,u))}function Og(i){return function(){return i}}function pW(i,y){return i==null||i!==i?y:i}var gW=iC(),mW=iC(!0);function ji(i){return i}function Ng(i){return O1(typeof i=="function"?i:Ao(i,u))}function vW(i){return D1(Ao(i,u))}function yW(i,y){return P1(i,Ao(y,u))}var bW=Jt(function(i,y){return function(L){return Lc(L,i,y)}}),wW=Jt(function(i,y){return function(L){return Lc(i,L,y)}});function Dg(i,y,L){var H=zr(y),Y=Ch(y,H);L==null&&!(ir(y)&&(Y.length||!H.length))&&(L=y,y=i,i=this,Y=Ch(y,zr(y)));var ie=!(ir(L)&&"chain"in L)||!!L.chain,fe=Is(i);return Sr(Y,function(pe){var _e=y[pe];i[pe]=_e,fe&&(i.prototype[pe]=function(){var Ne=this.__chain__;if(ie||Ne){var Pe=i(this.__wrapped__),je=Pe.__actions__=zi(this.__actions__);return je.push({func:_e,args:arguments,thisArg:i}),Pe.__chain__=Ne,Pe}return _e.apply(i,S([this.value()],arguments))})}),i}function xW(){return qt._===this&&(qt._=YD),this}function Pg(){}function CW(i){return i=Wt(i),Jt(function(y){return z1(y,i)})}var kW=fg(I),_W=fg(os),AW=fg(W);function rk(i){return wg(i)?Be(Uo(i)):nz(i)}function $W(i){return function(y){return i==null?t:Oa(i,y)}}var SW=sC(),TW=sC(!0);function zg(){return[]}function Bg(){return!1}function EW(){return{}}function IW(){return""}function MW(){return!0}function RW(i,y){if(i=Wt(i),i<1||i>q)return[];var L=le,H=oi(i,le);y=Tt(y),i-=le;for(var Y=pt(H,y);++L<i;)y(L);return Y}function LW(i){return zt(i)?I(i,Uo):io(i)?[i]:zi(CC(_n(i)))}function OW(i){var y=++GD;return _n(i)+y}var NW=Th(function(i,y){return i+y},0),DW=pg("ceil"),PW=Th(function(i,y){return i/y},1),zW=pg("floor");function BW(i){return i&&i.length?xh(i,ji,Xp):t}function FW(i,y){return i&&i.length?xh(i,Tt(y,2),Xp):t}function jW(i){return $e(i,ji)}function WW(i,y){return $e(i,Tt(y,2))}function HW(i){return i&&i.length?xh(i,ji,rg):t}function UW(i,y){return i&&i.length?xh(i,Tt(y,2),rg):t}var VW=Th(function(i,y){return i*y},1),GW=pg("round"),qW=Th(function(i,y){return i-y},0);function YW(i){return i&&i.length?ut(i,ji):0}function KW(i,y){return i&&i.length?ut(i,Tt(y,2)):0}return te.after=yF,te.ary=LC,te.assign=oj,te.assignIn=qC,te.assignInWith=YC,te.assignWith=Ig,te.at=sj,te.before=OC,te.bind=$g,te.bindAll=hW,te.bindKey=NC,te.castArray=IF,te.chain=IC,te.chunk=Bz,te.compact=Fz,te.concat=jz,te.cond=dW,te.conforms=fW,te.constant=Og,te.countBy=KB,te.create=aj,te.curry=DC,te.curryRight=PC,te.debounce=zC,te.defaults=lj,te.defaultsDeep=cj,te.defer=bF,te.delay=wF,te.difference=Wz,te.differenceBy=Hz,te.differenceWith=Uz,te.drop=Vz,te.dropRight=Gz,te.dropRightWhile=qz,te.dropWhile=Yz,te.fill=Kz,te.filter=QB,te.flatMap=eF,te.flatMapDeep=tF,te.flatMapDepth=nF,te.flatten=$C,te.flattenDeep=Jz,te.flattenDepth=Qz,te.flip=xF,te.flow=gW,te.flowRight=mW,te.fromPairs=Zz,te.functions=mj,te.functionsIn=vj,te.groupBy=rF,te.initial=eB,te.intersection=tB,te.intersectionBy=nB,te.intersectionWith=rB,te.invert=bj,te.invertBy=wj,te.invokeMap=oF,te.iteratee=Ng,te.keyBy=sF,te.keys=zr,te.keysIn=Fi,te.map=Nh,te.mapKeys=Cj,te.mapValues=kj,te.matches=vW,te.matchesProperty=yW,te.memoize=Ph,te.merge=_j,te.mergeWith=KC,te.method=bW,te.methodOf=wW,te.mixin=Dg,te.negate=zh,te.nthArg=CW,te.omit=Aj,te.omitBy=$j,te.once=CF,te.orderBy=aF,te.over=kW,te.overArgs=kF,te.overEvery=_W,te.overSome=AW,te.partial=Sg,te.partialRight=BC,te.partition=lF,te.pick=Sj,te.pickBy=JC,te.property=rk,te.propertyOf=$W,te.pull=aB,te.pullAll=TC,te.pullAllBy=lB,te.pullAllWith=cB,te.pullAt=uB,te.range=SW,te.rangeRight=TW,te.rearg=_F,te.reject=hF,te.remove=hB,te.rest=AF,te.reverse=_g,te.sampleSize=fF,te.set=Ej,te.setWith=Ij,te.shuffle=pF,te.slice=dB,te.sortBy=vF,te.sortedUniq=bB,te.sortedUniqBy=wB,te.split=Xj,te.spread=$F,te.tail=xB,te.take=CB,te.takeRight=kB,te.takeRightWhile=_B,te.takeWhile=AB,te.tap=FB,te.throttle=SF,te.thru=Oh,te.toArray=UC,te.toPairs=QC,te.toPairsIn=ZC,te.toPath=LW,te.toPlainObject=GC,te.transform=Mj,te.unary=TF,te.union=$B,te.unionBy=SB,te.unionWith=TB,te.uniq=EB,te.uniqBy=IB,te.uniqWith=MB,te.unset=Rj,te.unzip=Ag,te.unzipWith=EC,te.update=Lj,te.updateWith=Oj,te.values=Sl,te.valuesIn=Nj,te.without=RB,te.words=tk,te.wrap=EF,te.xor=LB,te.xorBy=OB,te.xorWith=NB,te.zip=DB,te.zipObject=PB,te.zipObjectDeep=zB,te.zipWith=BB,te.entries=QC,te.entriesIn=ZC,te.extend=qC,te.extendWith=YC,Dg(te,te),te.add=NW,te.attempt=nk,te.camelCase=Bj,te.capitalize=XC,te.ceil=DW,te.clamp=Dj,te.clone=MF,te.cloneDeep=LF,te.cloneDeepWith=OF,te.cloneWith=RF,te.conformsTo=NF,te.deburr=ek,te.defaultTo=pW,te.divide=PW,te.endsWith=Fj,te.eq=Vo,te.escape=jj,te.escapeRegExp=Wj,te.every=JB,te.find=ZB,te.findIndex=_C,te.findKey=uj,te.findLast=XB,te.findLastIndex=AC,te.findLastKey=hj,te.floor=zW,te.forEach=MC,te.forEachRight=RC,te.forIn=dj,te.forInRight=fj,te.forOwn=pj,te.forOwnRight=gj,te.get=Mg,te.gt=DF,te.gte=PF,te.has=yj,te.hasIn=Rg,te.head=SC,te.identity=ji,te.includes=iF,te.indexOf=Xz,te.inRange=Pj,te.invoke=xj,te.isArguments=Pa,te.isArray=zt,te.isArrayBuffer=zF,te.isArrayLike=Bi,te.isArrayLikeObject=hr,te.isBoolean=BF,te.isBuffer=Qs,te.isDate=FF,te.isElement=jF,te.isEmpty=WF,te.isEqual=HF,te.isEqualWith=UF,te.isError=Tg,te.isFinite=VF,te.isFunction=Is,te.isInteger=FC,te.isLength=Bh,te.isMap=jC,te.isMatch=GF,te.isMatchWith=qF,te.isNaN=YF,te.isNative=KF,te.isNil=QF,te.isNull=JF,te.isNumber=WC,te.isObject=ir,te.isObjectLike=ar,te.isPlainObject=Bc,te.isRegExp=Eg,te.isSafeInteger=ZF,te.isSet=HC,te.isString=Fh,te.isSymbol=io,te.isTypedArray=$l,te.isUndefined=XF,te.isWeakMap=ej,te.isWeakSet=tj,te.join=iB,te.kebabCase=Hj,te.last=So,te.lastIndexOf=oB,te.lowerCase=Uj,te.lowerFirst=Vj,te.lt=nj,te.lte=rj,te.max=BW,te.maxBy=FW,te.mean=jW,te.meanBy=WW,te.min=HW,te.minBy=UW,te.stubArray=zg,te.stubFalse=Bg,te.stubObject=EW,te.stubString=IW,te.stubTrue=MW,te.multiply=VW,te.nth=sB,te.noConflict=xW,te.noop=Pg,te.now=Dh,te.pad=Gj,te.padEnd=qj,te.padStart=Yj,te.parseInt=Kj,te.random=zj,te.reduce=cF,te.reduceRight=uF,te.repeat=Jj,te.replace=Qj,te.result=Tj,te.round=GW,te.runInContext=be,te.sample=dF,te.size=gF,te.snakeCase=Zj,te.some=mF,te.sortedIndex=fB,te.sortedIndexBy=pB,te.sortedIndexOf=gB,te.sortedLastIndex=mB,te.sortedLastIndexBy=vB,te.sortedLastIndexOf=yB,te.startCase=eW,te.startsWith=tW,te.subtract=qW,te.sum=YW,te.sumBy=KW,te.template=nW,te.times=RW,te.toFinite=Ms,te.toInteger=Wt,te.toLength=VC,te.toLower=rW,te.toNumber=To,te.toSafeInteger=ij,te.toString=_n,te.toUpper=iW,te.trim=oW,te.trimEnd=sW,te.trimStart=aW,te.truncate=lW,te.unescape=cW,te.uniqueId=OW,te.upperCase=uW,te.upperFirst=Lg,te.each=MC,te.eachRight=RC,te.first=SC,Dg(te,(function(){var i={};return as(te,function(y,L){kn.call(te.prototype,L)||(i[L]=y)}),i})(),{chain:!1}),te.VERSION=r,Sr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(i){te[i].placeholder=te}),Sr(["drop","take"],function(i,y){tn.prototype[i]=function(L){L=L===t?1:Er(Wt(L),0);var H=this.__filtered__&&!y?new tn(this):this.clone();return H.__filtered__?H.__takeCount__=oi(L,H.__takeCount__):H.__views__.push({size:oi(L,le),type:i+(H.__dir__<0?"Right":"")}),H},tn.prototype[i+"Right"]=function(L){return this.reverse()[i](L).reverse()}}),Sr(["filter","map","takeWhile"],function(i,y){var L=y+1,H=L==A||L==j;tn.prototype[i]=function(Y){var ie=this.clone();return ie.__iteratees__.push({iteratee:Tt(Y,3),type:L}),ie.__filtered__=ie.__filtered__||H,ie}}),Sr(["head","last"],function(i,y){var L="take"+(y?"Right":"");tn.prototype[i]=function(){return this[L](1).value()[0]}}),Sr(["initial","tail"],function(i,y){var L="drop"+(y?"":"Right");tn.prototype[i]=function(){return this.__filtered__?new tn(this):this[L](1)}}),tn.prototype.compact=function(){return this.filter(ji)},tn.prototype.find=function(i){return this.filter(i).head()},tn.prototype.findLast=function(i){return this.reverse().find(i)},tn.prototype.invokeMap=Jt(function(i,y){return typeof i=="function"?new tn(this):this.map(function(L){return Lc(L,i,y)})}),tn.prototype.reject=function(i){return this.filter(zh(Tt(i)))},tn.prototype.slice=function(i,y){i=Wt(i);var L=this;return L.__filtered__&&(i>0||y<0)?new tn(L):(i<0?L=L.takeRight(-i):i&&(L=L.drop(i)),y!==t&&(y=Wt(y),L=y<0?L.dropRight(-y):L.take(y-i)),L)},tn.prototype.takeRightWhile=function(i){return this.reverse().takeWhile(i).reverse()},tn.prototype.toArray=function(){return this.take(le)},as(tn.prototype,function(i,y){var L=/^(?:filter|find|map|reject)|While$/.test(y),H=/^(?:head|last)$/.test(y),Y=te[H?"take"+(y=="last"?"Right":""):y],ie=H||/^find/.test(y);Y&&(te.prototype[y]=function(){var fe=this.__wrapped__,pe=H?[1]:arguments,_e=fe instanceof tn,Ne=pe[0],Pe=_e||zt(fe),je=function(Zt){var on=Y.apply(te,S([Zt],pe));return H&&st?on[0]:on};Pe&&L&&typeof Ne=="function"&&Ne.length!=1&&(_e=Pe=!1);var st=this.__chain__,yt=!!this.__actions__.length,Et=ie&&!st,Ut=_e&&!yt;if(!ie&&Pe){fe=Ut?fe:new tn(this);var $t=i.apply(fe,pe);return $t.__actions__.push({func:Oh,args:[je],thisArg:t}),new _o($t,st)}return Et&&Ut?i.apply(this,pe):($t=this.thru(je),Et?H?$t.value()[0]:$t.value():$t)})}),Sr(["pop","push","shift","sort","splice","unshift"],function(i){var y=ko[i],L=/^(?:push|sort|unshift)$/.test(i)?"tap":"thru",H=/^(?:pop|shift)$/.test(i);te.prototype[i]=function(){var Y=arguments;if(H&&!this.__chain__){var ie=this.value();return y.apply(zt(ie)?ie:[],Y)}return this[L](function(fe){return y.apply(zt(fe)?fe:[],Y)})}}),as(tn.prototype,function(i,y){var L=te[y];if(L){var H=L.name+"";kn.call(xl,H)||(xl[H]=[]),xl[H].push({name:y,func:L})}}),xl[Sh(t,x).name]=[{name:"wrapper",func:t}],tn.prototype.clone=uP,tn.prototype.reverse=hP,tn.prototype.value=dP,te.prototype.at=jB,te.prototype.chain=WB,te.prototype.commit=HB,te.prototype.next=UB,te.prototype.plant=GB,te.prototype.reverse=qB,te.prototype.toJSON=te.prototype.valueOf=te.prototype.value=YB,te.prototype.first=te.prototype.head,$c&&(te.prototype[$c]=VB),te}),En=Cn();yr?((yr.exports=En)._=En,ri._=En):qt._=En}).call(hT)})(au,au.exports)),au.exports}var fT=dT();lr("T",su(fT)).debounce(function(){this.rebuildDisplayText()},300);var yy={exports:{}},by;function pT(){return by||(by=1,(function(e,n){(function(){ace.require(["ace/mode/text"],function(t){e&&(e.exports=t)})})()})(yy)),yy.exports}pT();const gT=!0,Cr="u-",mT="uplot",vT=Cr+"hz",yT=Cr+"vt",bT=Cr+"title",wT=Cr+"wrap",xT=Cr+"under",CT=Cr+"over",kT=Cr+"axis",da=Cr+"off",_T=Cr+"select",AT=Cr+"cursor-x",$T=Cr+"cursor-y",ST=Cr+"cursor-pt",TT=Cr+"legend",ET=Cr+"live",IT=Cr+"inline",MT=Cr+"series",RT=Cr+"marker",wy=Cr+"label",LT=Cr+"value",Yl="width",Kl="height",Jl="top",xy="bottom",Ka="left",kd="right",_d="#000",Cy=_d+"0",Ad="mousemove",ky="mousedown",$d="mouseup",_y="mouseenter",Ay="mouseleave",$y="dblclick",OT="resize",NT="scroll",Sy="change",lu="dppxchange",Sd="--",Ja=typeof window<"u",Td=Ja?document:null,Qa=Ja?window:null,DT=Ja?navigator:null;let yn,cu;function Ed(){let e=devicePixelRatio;yn!=e&&(yn=e,cu&&Rd(Sy,cu,Ed),cu=matchMedia(`(min-resolution: ${yn-.001}dppx) and (max-resolution: ${yn+.001}dppx)`),fa(Sy,cu,Ed),Qa.dispatchEvent(new CustomEvent(lu)))}function Ui(e,n){if(n!=null){let t=e.classList;!t.contains(n)&&t.add(n)}}function Id(e,n){let t=e.classList;t.contains(n)&&t.remove(n)}function Bn(e,n,t){e.style[n]=t+"px"}function Mo(e,n,t,r){let c=Td.createElement(e);return n!=null&&Ui(c,n),t?.insertBefore(c,r),c}function lo(e,n){return Mo("div",e,n)}const Ty=new WeakMap;function Yo(e,n,t,r,c){let h="translate("+n+"px,"+t+"px)",g=Ty.get(e);h!=g&&(e.style.transform=h,Ty.set(e,h),n<0||t<0||n>r||t>c?Ui(e,da):Id(e,da))}const Ey=new WeakMap;function Iy(e,n,t){let r=n+t,c=Ey.get(e);r!=c&&(Ey.set(e,r),e.style.background=n,e.style.borderColor=t)}const My=new WeakMap;function Ry(e,n,t,r){let c=n+""+t,h=My.get(e);c!=h&&(My.set(e,c),e.style.height=t+"px",e.style.width=n+"px",e.style.marginLeft=r?-n/2+"px":0,e.style.marginTop=r?-t/2+"px":0)}const Md={passive:!0},PT={...Md,capture:!0};function fa(e,n,t,r){n.addEventListener(e,t,r?PT:Md)}function Rd(e,n,t,r){n.removeEventListener(e,t,Md)}Ja&&Ed();function Ro(e,n,t,r){let c;t=t||0,r=r||n.length-1;let h=r<=2147483647;for(;r-t>1;)c=h?t+r>>1:Gi((t+r)/2),n[c]<e?t=c:r=c;return e-n[t]<=n[r]-e?t:r}function Ly(e){return(n,t,r)=>{let c=-1,h=-1;for(let g=t;g<=r;g++)if(e(n[g])){c=g;break}for(let g=r;g>=t;g--)if(e(n[g])){h=g;break}return[c,h]}}const Oy=e=>e!=null,Ny=e=>e!=null&&e>0,uu=Ly(Oy),zT=Ly(Ny);function BT(e,n,t,r=0,c=!1){let h=c?zT:uu,g=c?Ny:Oy;[n,t]=h(e,n,t);let v=e[n],s=e[n];if(n>-1)if(r==1)v=e[n],s=e[t];else if(r==-1)v=e[t],s=e[n];else for(let p=n;p<=t;p++){let a=e[p];g(a)&&(a<v?v=a:a>s&&(s=a))}return[v??Mn,s??-Mn]}function hu(e,n,t,r){let c=zy(e),h=zy(n);e==n&&(c==-1?(e*=t,n/=t):(e/=t,n*=t));let g=t==10?us:By,v=c==1?Gi:co,s=h==1?co:Gi,p=v(g(kr(e))),a=s(g(kr(n))),l=Za(t,p),u=Za(t,a);return t==10&&(p<0&&(l=Rn(l,-p)),a<0&&(u=Rn(u,-a))),r||t==2?(e=l*c,n=u*h):(e=Gy(e,l),n=pu(n,u)),[e,n]}function Ld(e,n,t,r){let c=hu(e,n,t,r);return e==0&&(c[0]=0),n==0&&(c[1]=0),c}const Od=.1,Dy={mode:3,pad:Od},Ql={pad:0,soft:null,mode:0},FT={min:Ql,max:Ql};function du(e,n,t,r){return gu(t)?Py(e,n,t):(Ql.pad=t,Ql.soft=r?0:null,Ql.mode=r?3:0,Py(e,n,FT))}function gn(e,n){return e??n}function jT(e,n,t){for(n=gn(n,0),t=gn(t,e.length-1);n<=t;){if(e[n]!=null)return!0;n++}return!1}function Py(e,n,t){let r=t.min,c=t.max,h=gn(r.pad,0),g=gn(c.pad,0),v=gn(r.hard,-Mn),s=gn(c.hard,Mn),p=gn(r.soft,Mn),a=gn(c.soft,-Mn),l=gn(r.mode,0),u=gn(c.mode,0),d=n-e,o=us(d),f=ci(kr(e),kr(n)),m=us(f),w=kr(m-o);(d<1e-24||w>10)&&(d=0,(e==0||n==0)&&(d=1e-24,l==2&&p!=Mn&&(h=0),u==2&&a!=-Mn&&(g=0)));let x=d||f||1e3,R=us(x),T=Za(10,Gi(R)),_=x*(d==0?e==0?.1:1:h),C=Rn(Gy(e-_,T/10),24),P=e>=p&&(l==1||l==3&&C<=p||l==2&&C>=p)?p:Mn,O=ci(v,C<P&&e>=P?P:Lo(P,C)),E=x*(d==0?n==0?.1:1:g),k=Rn(pu(n+E,T/10),24),B=n<=a&&(u==1||u==3&&k>=a||u==2&&k<=a)?a:-Mn,N=Lo(s,k>B&&n<=B?B:ci(B,k));return O==N&&O==0&&(N=100),[O,N]}const WT=new Intl.NumberFormat(Ja?DT.language:"en-US"),Nd=e=>WT.format(e),Vi=Math,fu=Vi.PI,kr=Vi.abs,Gi=Vi.floor,_r=Vi.round,co=Vi.ceil,Lo=Vi.min,ci=Vi.max,Za=Vi.pow,zy=Vi.sign,us=Vi.log10,By=Vi.log2,HT=(e,n=1)=>Vi.sinh(e)*n,Dd=(e,n=1)=>Vi.asinh(e/n),Mn=1/0;function Fy(e){return(us((e^e>>31)-(e>>31))|0)+1}function Pd(e,n,t){return Lo(ci(e,n),t)}function jy(e){return typeof e=="function"}function en(e){return jy(e)?e:()=>e}const UT=()=>{},Wy=e=>e,Hy=(e,n)=>n,VT=e=>null,Uy=e=>!0,Vy=(e,n)=>e==n,GT=/\.\d*?(?=9{6,}|0{6,})/gm,pa=e=>{if(Yy(e)||zs.has(e))return e;const n=`${e}`,t=n.match(GT);if(t==null)return e;let r=t[0].length-1;if(n.indexOf("e-")!=-1){let[c,h]=n.split("e");return+`${pa(c)}e${h}`}return Rn(e,r)};function ga(e,n){return pa(Rn(pa(e/n))*n)}function pu(e,n){return pa(co(pa(e/n))*n)}function Gy(e,n){return pa(Gi(pa(e/n))*n)}function Rn(e,n=0){if(Yy(e))return e;let t=10**n,r=e*t*(1+Number.EPSILON);return _r(r)/t}const zs=new Map;function qy(e){return((""+e).split(".")[1]||"").length}function Zl(e,n,t,r){let c=[],h=r.map(qy);for(let g=n;g<t;g++){let v=kr(g),s=Rn(Za(e,g),v);for(let p=0;p<r.length;p++){let a=e==10?+`${r[p]}e${g}`:r[p]*s,l=(g>=0?0:v)+(g>=h[p]?0:h[p]),u=e==10?a:Rn(a,l);c.push(u),zs.set(u,l)}}return c}const Xl={},zd=[],Xa=[null,null],Bs=Array.isArray,Yy=Number.isInteger,qT=e=>e===void 0;function Ky(e){return typeof e=="string"}function gu(e){let n=!1;if(e!=null){let t=e.constructor;n=t==null||t==Object}return n}function YT(e){return e!=null&&typeof e=="object"}const KT=Object.getPrototypeOf(Uint8Array),Jy="__proto__";function el(e,n=gu){let t;if(Bs(e)){let r=e.find(c=>c!=null);if(Bs(r)||n(r)){t=Array(e.length);for(let c=0;c<e.length;c++)t[c]=el(e[c],n)}else t=e.slice()}else if(e instanceof KT)t=e.slice();else if(n(e)){t={};for(let r in e)r!=Jy&&(t[r]=el(e[r],n))}else t=e;return t}function pr(e){let n=arguments;for(let t=1;t<n.length;t++){let r=n[t];for(let c in r)c!=Jy&&(gu(e[c])?pr(e[c],el(r[c])):e[c]=el(r[c]))}return e}const JT=0,QT=1,ZT=2;function XT(e,n,t){for(let r=0,c,h=-1;r<n.length;r++){let g=n[r];if(g>h){for(c=g-1;c>=0&&e[c]==null;)e[c--]=null;for(c=g+1;c<t&&e[c]==null;)e[h=c++]=null}}}function eE(e,n){if(rE(e)){let g=e[0].slice();for(let v=1;v<e.length;v++)g.push(...e[v].slice(1));return iE(g[0])||(g=nE(g)),g}let t=new Set;for(let g=0;g<e.length;g++){let v=e[g][0],s=v.length;for(let p=0;p<s;p++)t.add(v[p])}let r=[Array.from(t).sort((g,v)=>g-v)],c=r[0].length,h=new Map;for(let g=0;g<c;g++)h.set(r[0][g],g);for(let g=0;g<e.length;g++){let v=e[g],s=v[0];for(let p=1;p<v.length;p++){let a=v[p],l=Array(c).fill(void 0),u=n?n[g][p]:QT,d=[];for(let o=0;o<a.length;o++){let f=a[o],m=h.get(s[o]);f===null?u!=JT&&(l[m]=f,u==ZT&&d.push(m)):l[m]=f}XT(l,d,c),r.push(l)}}return r}const tE=typeof queueMicrotask>"u"?e=>Promise.resolve().then(e):queueMicrotask;function nE(e){let n=e[0],t=n.length,r=Array(t);for(let h=0;h<r.length;h++)r[h]=h;r.sort((h,g)=>n[h]-n[g]);let c=[];for(let h=0;h<e.length;h++){let g=e[h],v=Array(t);for(let s=0;s<t;s++)v[s]=g[r[s]];c.push(v)}return c}function rE(e){let n=e[0][0],t=n.length;for(let r=1;r<e.length;r++){let c=e[r][0];if(c.length!=t)return!1;if(c!=n){for(let h=0;h<t;h++)if(c[h]!=n[h])return!1}}return!0}function iE(e,n=100){const t=e.length;if(t<=1)return!0;let r=0,c=t-1;for(;r<=c&&e[r]==null;)r++;for(;c>=r&&e[c]==null;)c--;if(c<=r)return!0;const h=ci(1,Gi((c-r+1)/n));for(let g=e[r],v=r+h;v<=c;v+=h){const s=e[v];if(s!=null){if(s<=g)return!1;g=s}}return!0}const Qy=["January","February","March","April","May","June","July","August","September","October","November","December"],Zy=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function Xy(e){return e.slice(0,3)}const oE=Zy.map(Xy),sE=Qy.map(Xy),aE={MMMM:Qy,MMM:sE,WWWW:Zy,WWW:oE};function ec(e){return(e<10?"0":"")+e}function lE(e){return(e<10?"00":e<100?"0":"")+e}const cE={YYYY:e=>e.getFullYear(),YY:e=>(e.getFullYear()+"").slice(2),MMMM:(e,n)=>n.MMMM[e.getMonth()],MMM:(e,n)=>n.MMM[e.getMonth()],MM:e=>ec(e.getMonth()+1),M:e=>e.getMonth()+1,DD:e=>ec(e.getDate()),D:e=>e.getDate(),WWWW:(e,n)=>n.WWWW[e.getDay()],WWW:(e,n)=>n.WWW[e.getDay()],HH:e=>ec(e.getHours()),H:e=>e.getHours(),h:e=>{let n=e.getHours();return n==0?12:n>12?n-12:n},AA:e=>e.getHours()>=12?"PM":"AM",aa:e=>e.getHours()>=12?"pm":"am",a:e=>e.getHours()>=12?"p":"a",mm:e=>ec(e.getMinutes()),m:e=>e.getMinutes(),ss:e=>ec(e.getSeconds()),s:e=>e.getSeconds(),fff:e=>lE(e.getMilliseconds())};function Bd(e,n){n=n||aE;let t=[],r=/\{([a-z]+)\}|[^{]+/gi,c;for(;c=r.exec(e);)t.push(c[0][0]=="{"?cE[c[1]]:c[0]);return h=>{let g="";for(let v=0;v<t.length;v++)g+=typeof t[v]=="string"?t[v]:t[v](h,n);return g}}const uE=new Intl.DateTimeFormat().resolvedOptions().timeZone;function hE(e,n){let t;return n=="UTC"||n=="Etc/UTC"?t=new Date(+e+e.getTimezoneOffset()*6e4):n==uE?t=e:(t=new Date(e.toLocaleString("en-US",{timeZone:n})),t.setMilliseconds(e.getMilliseconds())),t}const eb=e=>e%1==0,mu=[1,2,2.5,5],dE=Zl(10,-32,0,mu),tb=Zl(10,0,32,mu),fE=tb.filter(eb),ma=dE.concat(tb),Fd=`
1479
+ `,nb="{YYYY}",rb=Fd+nb,ib="{M}/{D}",tc=Fd+ib,vu=tc+"/{YY}",ob="{aa}",pE="{h}:{mm}",tl=pE+ob,sb=Fd+tl,ab=":{ss}",wn=null;function lb(e){let n=e*1e3,t=n*60,r=t*60,c=r*24,h=c*30,g=c*365,v=(e==1?Zl(10,0,3,mu).filter(eb):Zl(10,-3,0,mu)).concat([n,n*5,n*10,n*15,n*30,t,t*5,t*10,t*15,t*30,r,r*2,r*3,r*4,r*6,r*8,r*12,c,c*2,c*3,c*4,c*5,c*6,c*7,c*8,c*9,c*10,c*15,h,h*2,h*3,h*4,h*6,g,g*2,g*5,g*10,g*25,g*50,g*100]);const s=[[g,nb,wn,wn,wn,wn,wn,wn,1],[c*28,"{MMM}",rb,wn,wn,wn,wn,wn,1],[c,ib,rb,wn,wn,wn,wn,wn,1],[r,"{h}"+ob,vu,wn,tc,wn,wn,wn,1],[t,tl,vu,wn,tc,wn,wn,wn,1],[n,ab,vu+" "+tl,wn,tc+" "+tl,wn,sb,wn,1],[e,ab+".{fff}",vu+" "+tl,wn,tc+" "+tl,wn,sb,wn,1]];function p(a){return(l,u,d,o,f,m)=>{let w=[],x=f>=g,R=f>=h&&f<g,T=a(d),_=Rn(T*e,3),C=jd(T.getFullYear(),x?0:T.getMonth(),R||x?1:T.getDate()),P=Rn(C*e,3);if(R||x){let O=R?f/h:0,E=x?f/g:0,k=_==P?_:Rn(jd(C.getFullYear()+E,C.getMonth()+O,1)*e,3),B=new Date(_r(k/e)),N=B.getFullYear(),M=B.getMonth();for(let $=0;k<=o;$++){let A=jd(N+E*$,M+O*$,1),D=A-a(Rn(A*e,3));k=Rn((+A+D)*e,3),k<=o&&w.push(k)}}else{let O=f>=c?c:f,E=Gi(d)-Gi(_),k=P+E+pu(_-P,O);w.push(k);let B=a(k),N=B.getHours()+B.getMinutes()/t+B.getSeconds()/r,M=f/r,$=l.axes[u]._space,A=m/$;for(;k=Rn(k+f,e==1?0:3),!(k>o);)if(M>1){let D=Gi(Rn(N+M,6))%24,j=a(k).getHours()-D;j>1&&(j=-1),k-=j*r,N=(N+M)%24;let U=w[w.length-1];Rn((k-U)/f,3)*A>=.7&&w.push(k)}else w.push(k)}return w}}return[v,s,p]}const[gE,mE,vE]=lb(1),[yE,bE,wE]=lb(.001);Zl(2,-53,53,[1]);function cb(e,n){return e.map(t=>t.map((r,c)=>c==0||c==8||r==null?r:n(c==1||t[8]==0?r:t[1]+r)))}function ub(e,n){return(t,r,c,h,g)=>{let v=n.find(o=>g>=o[0])||n[n.length-1],s,p,a,l,u,d;return r.map(o=>{let f=e(o),m=f.getFullYear(),w=f.getMonth(),x=f.getDate(),R=f.getHours(),T=f.getMinutes(),_=f.getSeconds(),C=m!=s&&v[2]||w!=p&&v[3]||x!=a&&v[4]||R!=l&&v[5]||T!=u&&v[6]||_!=d&&v[7]||v[1];return s=m,p=w,a=x,l=R,u=T,d=_,C(f)})}}function xE(e,n){let t=Bd(n);return(r,c,h,g,v)=>c.map(s=>t(e(s)))}function jd(e,n,t){return new Date(e,n,t)}function hb(e,n){return n(e)}const CE="{YYYY}-{MM}-{DD} {h}:{mm}{aa}";function db(e,n){return(t,r,c,h)=>h==null?Sd:n(e(r))}function kE(e,n){let t=e.series[n];return t.width?t.stroke(e,n):t.points.width?t.points.stroke(e,n):null}function _E(e,n){return e.series[n].fill(e,n)}const AE={show:!0,live:!0,isolate:!1,mount:UT,markers:{show:!0,width:2,stroke:kE,fill:_E,dash:"solid"},idx:null,idxs:null,values:[]};function $E(e,n){let t=e.cursor.points,r=lo(),c=t.size(e,n);Bn(r,Yl,c),Bn(r,Kl,c);let h=c/-2;Bn(r,"marginLeft",h),Bn(r,"marginTop",h);let g=t.width(e,n,c);return g&&Bn(r,"borderWidth",g),r}function SE(e,n){let t=e.series[n].points;return t._fill||t._stroke}function TE(e,n){let t=e.series[n].points;return t._stroke||t._fill}function EE(e,n){return e.series[n].points.size}const Wd=[0,0];function IE(e,n,t){return Wd[0]=n,Wd[1]=t,Wd}function yu(e,n,t,r=!0){return c=>{c.button==0&&(!r||c.target==n)&&t(c)}}function Hd(e,n,t,r=!0){return c=>{(!r||c.target==n)&&t(c)}}const ME={show:!0,x:!0,y:!0,lock:!1,move:IE,points:{one:!1,show:$E,size:EE,width:0,stroke:TE,fill:SE},bind:{mousedown:yu,mouseup:yu,click:yu,dblclick:yu,mousemove:Hd,mouseleave:Hd,mouseenter:Hd},drag:{setScale:!0,x:!0,y:!1,dist:0,uni:null,click:(e,n)=>{n.stopPropagation(),n.stopImmediatePropagation()},_x:!1,_y:!1},focus:{dist:(e,n,t,r,c)=>r-c,prox:-1,bias:0},hover:{skip:[void 0],prox:null,bias:0},left:-10,top:-10,idx:null,dataIdx:null,idxs:null,event:null},fb={show:!0,stroke:"rgba(0,0,0,0.07)",width:2},Ud=pr({},fb,{filter:Hy}),pb=pr({},Ud,{size:10}),gb=pr({},fb,{show:!1}),Vd='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"',mb="bold "+Vd,vb=1.5,yb={show:!0,scale:"x",stroke:_d,space:50,gap:5,alignTo:1,size:50,labelGap:0,labelSize:30,labelFont:mb,side:2,grid:Ud,ticks:pb,border:gb,font:Vd,lineGap:vb,rotate:0},RE="Value",LE="Time",bb={show:!0,scale:"x",auto:!1,sorted:1,min:Mn,max:-Mn,idxs:[]};function OE(e,n,t,r,c){return n.map(h=>h==null?"":Nd(h))}function NE(e,n,t,r,c,h,g){let v=[],s=zs.get(c)||0;t=g?t:Rn(pu(t,c),s);for(let p=t;p<=r;p=Rn(p+c,s))v.push(Object.is(p,-0)?0:p);return v}function Gd(e,n,t,r,c,h,g){const v=[],s=e.scales[e.axes[n].scale].log,p=s==10?us:By,a=Gi(p(t));c=Za(s,a),s==10&&(c=ma[Ro(c,ma)]);let l=t,u=c*s;s==10&&(u=ma[Ro(u,ma)]);do v.push(l),l=l+c,s==10&&!zs.has(l)&&(l=Rn(l,zs.get(c))),l>=u&&(c=l,u=c*s,s==10&&(u=ma[Ro(u,ma)]));while(l<=r);return v}function DE(e,n,t,r,c,h,g){let v=e.scales[e.axes[n].scale].asinh,s=r>v?Gd(e,n,ci(v,t),r,c):[v],p=r>=0&&t<=0?[0]:[];return(t<-v?Gd(e,n,ci(v,-r),-t,c):[v]).reverse().map(a=>-a).concat(p,s)}const wb=/./,PE=/[12357]/,zE=/[125]/,xb=/1/,qd=(e,n,t,r)=>e.map((c,h)=>n==4&&c==0||h%r==0&&t.test(c.toExponential()[c<0?1:0])?c:null);function BE(e,n,t,r,c){let h=e.axes[t],g=h.scale,v=e.scales[g],s=e.valToPos,p=h._space,a=s(10,g),l=s(9,g)-a>=p?wb:s(7,g)-a>=p?PE:s(5,g)-a>=p?zE:xb;if(l==xb){let u=kr(s(1,g)-a);if(u<p)return qd(n.slice().reverse(),v.distr,l,co(p/u)).reverse()}return qd(n,v.distr,l,1)}function FE(e,n,t,r,c){let h=e.axes[t],g=h.scale,v=h._space,s=e.valToPos,p=kr(s(1,g)-s(2,g));return p<v?qd(n.slice().reverse(),3,wb,co(v/p)).reverse():n}function jE(e,n,t,r){return r==null?Sd:n==null?"":Nd(n)}const Cb={show:!0,scale:"y",stroke:_d,space:30,gap:5,alignTo:1,size:50,labelGap:0,labelSize:30,labelFont:mb,side:3,grid:Ud,ticks:pb,border:gb,font:Vd,lineGap:vb,rotate:0};function WE(e,n){let t=3+(e||1)*2;return Rn(t*n,3)}function HE(e,n){let{scale:t,idxs:r}=e.series[0],c=e._data[0],h=e.valToPos(c[r[0]],t,!0),g=e.valToPos(c[r[1]],t,!0),v=kr(g-h),s=e.series[n],p=v/(s.points.space*yn);return r[1]-r[0]<=p}const kb={scale:null,auto:!0,sorted:0,min:Mn,max:-Mn},_b=(e,n,t,r,c)=>c,Ab={show:!0,auto:!0,sorted:0,gaps:_b,alpha:1,facets:[pr({},kb,{scale:"x"}),pr({},kb,{scale:"y"})]},$b={scale:"y",auto:!0,sorted:0,show:!0,spanGaps:!1,gaps:_b,alpha:1,points:{show:HE,filter:null},values:null,min:Mn,max:-Mn,idxs:[],path:null,clip:null};function UE(e,n,t,r,c){return t/10}const Sb={time:gT,auto:!0,distr:1,log:10,asinh:1,min:null,max:null,dir:1,ori:0},VE=pr({},Sb,{time:!1,ori:1}),Tb={};function Eb(e,n){let t=Tb[e];return t||(t={key:e,plots:[],sub(r){t.plots.push(r)},unsub(r){t.plots=t.plots.filter(c=>c!=r)},pub(r,c,h,g,v,s,p){for(let a=0;a<t.plots.length;a++)t.plots[a]!=c&&t.plots[a].pub(r,c,h,g,v,s,p)}},e!=null&&(Tb[e]=t)),t}const nl=1,Yd=2;function va(e,n,t){const r=e.mode,c=e.series[n],h=r==2?e._data[n]:e._data,g=e.scales,v=e.bbox;let s=h[0],p=r==2?h[1]:h[n],a=r==2?g[c.facets[0].scale]:g[e.series[0].scale],l=r==2?g[c.facets[1].scale]:g[c.scale],u=v.left,d=v.top,o=v.width,f=v.height,m=e.valToPosH,w=e.valToPosV;return a.ori==0?t(c,s,p,a,l,m,w,u,d,o,f,wu,rl,Cu,Rb,Ob):t(c,s,p,a,l,w,m,d,u,f,o,xu,il,Qd,Lb,Nb)}function Kd(e,n){let t=0,r=0,c=gn(e.bands,zd);for(let h=0;h<c.length;h++){let g=c[h];g.series[0]==n?t=g.dir:g.series[1]==n&&(g.dir==1?r|=1:r|=2)}return[t,r==1?-1:r==2?1:r==3?2:0]}function GE(e,n,t,r,c){let h=e.mode,g=e.series[n],v=h==2?g.facets[1].scale:g.scale,s=e.scales[v];return c==-1?s.min:c==1?s.max:s.distr==3?s.dir==1?s.min:s.max:0}function hs(e,n,t,r,c,h){return va(e,n,(g,v,s,p,a,l,u,d,o,f,m)=>{let w=g.pxRound;const x=p.dir*(p.ori==0?1:-1),R=p.ori==0?rl:il;let T,_;x==1?(T=t,_=r):(T=r,_=t);let C=w(l(v[T],p,f,d)),P=w(u(s[T],a,m,o)),O=w(l(v[_],p,f,d)),E=w(u(h==1?a.max:a.min,a,m,o)),k=new Path2D(c);return R(k,O,E),R(k,C,E),R(k,C,P),k})}function bu(e,n,t,r,c,h){let g=null;if(e.length>0){g=new Path2D;const v=n==0?Cu:Qd;let s=t;for(let l=0;l<e.length;l++){let u=e[l];if(u[1]>u[0]){let d=u[0]-s;d>0&&v(g,s,r,d,r+h),s=u[1]}}let p=t+c-s,a=10;p>0&&v(g,s,r-a/2,p,r+h+a)}return g}function qE(e,n,t){let r=e[e.length-1];r&&r[0]==n?r[1]=t:e.push([n,t])}function Jd(e,n,t,r,c,h,g){let v=[],s=e.length;for(let p=c==1?t:r;p>=t&&p<=r;p+=c)if(n[p]===null){let a=p,l=p;if(c==1)for(;++p<=r&&n[p]===null;)l=p;else for(;--p>=t&&n[p]===null;)l=p;let u=h(e[a]),d=l==a?u:h(e[l]),o=a-c;u=g<=0&&o>=0&&o<s?h(e[o]):u;let f=l+c;d=g>=0&&f>=0&&f<s?h(e[f]):d,d>=u&&v.push([u,d])}return v}function Ib(e){return e==0?Wy:e==1?_r:n=>ga(n,e)}function Mb(e){let n=e==0?wu:xu,t=e==0?(c,h,g,v,s,p)=>{c.arcTo(h,g,v,s,p)}:(c,h,g,v,s,p)=>{c.arcTo(g,h,s,v,p)},r=e==0?(c,h,g,v,s)=>{c.rect(h,g,v,s)}:(c,h,g,v,s)=>{c.rect(g,h,s,v)};return(c,h,g,v,s,p=0,a=0)=>{p==0&&a==0?r(c,h,g,v,s):(p=Lo(p,v/2,s/2),a=Lo(a,v/2,s/2),n(c,h+p,g),t(c,h+v,g,h+v,g+s,p),t(c,h+v,g+s,h,g+s,a),t(c,h,g+s,h,g,a),t(c,h,g,h+v,g,p),c.closePath())}}const wu=(e,n,t)=>{e.moveTo(n,t)},xu=(e,n,t)=>{e.moveTo(t,n)},rl=(e,n,t)=>{e.lineTo(n,t)},il=(e,n,t)=>{e.lineTo(t,n)},Cu=Mb(0),Qd=Mb(1),Rb=(e,n,t,r,c,h)=>{e.arc(n,t,r,c,h)},Lb=(e,n,t,r,c,h)=>{e.arc(t,n,r,c,h)},Ob=(e,n,t,r,c,h,g)=>{e.bezierCurveTo(n,t,r,c,h,g)},Nb=(e,n,t,r,c,h,g)=>{e.bezierCurveTo(t,n,c,r,g,h)};function Db(e){return(n,t,r,c,h)=>va(n,t,(g,v,s,p,a,l,u,d,o,f,m)=>{let{pxRound:w,points:x}=g,R,T;p.ori==0?(R=wu,T=Rb):(R=xu,T=Lb);const _=Rn(x.width*yn,3);let C=(x.size-x.width)/2*yn,P=Rn(C*2,3),O=new Path2D,E=new Path2D,{left:k,top:B,width:N,height:M}=n.bbox;Cu(E,k-P,B-P,N+P*2,M+P*2);const $=A=>{if(s[A]!=null){let D=w(l(v[A],p,f,d)),j=w(u(s[A],a,m,o));R(O,D+C,j),T(O,D,j,C,0,fu*2)}};if(h)h.forEach($);else for(let A=r;A<=c;A++)$(A);return{stroke:_>0?O:null,fill:O,clip:E,flags:nl|Yd}})}function Pb(e){return(n,t,r,c,h,g)=>{r!=c&&(h!=r&&g!=r&&e(n,t,r),h!=c&&g!=c&&e(n,t,c),e(n,t,g))}}const YE=Pb(rl),KE=Pb(il);function zb(e){const n=gn(e?.alignGaps,0);return(t,r,c,h)=>va(t,r,(g,v,s,p,a,l,u,d,o,f,m)=>{[c,h]=uu(s,c,h);let w=g.pxRound,x=N=>w(l(N,p,f,d)),R=N=>w(u(N,a,m,o)),T,_;p.ori==0?(T=rl,_=YE):(T=il,_=KE);const C=p.dir*(p.ori==0?1:-1),P={stroke:new Path2D,fill:null,clip:null,band:null,gaps:null,flags:nl},O=P.stroke;let E=!1;if(h-c>=f*4){let N=le=>t.posToVal(le,p.key,!0),M=null,$=null,A,D,j,U=x(v[C==1?c:h]),q=x(v[c]),Q=x(v[h]),re=N(C==1?q+1:Q-1);for(let le=C==1?c:h;le>=c&&le<=h;le+=C){let ne=v[le],ue=(C==1?ne<re:ne>re)?U:x(ne),he=s[le];ue==U?he!=null?(D=he,M==null?(T(O,ue,R(D)),A=M=$=D):D<M?M=D:D>$&&($=D)):he===null&&(E=!0):(M!=null&&_(O,U,R(M),R($),R(A),R(D)),he!=null?(D=he,T(O,ue,R(D)),M=$=A=D):(M=$=null,he===null&&(E=!0)),U=ue,re=N(U+C))}M!=null&&M!=$&&j!=U&&_(O,U,R(M),R($),R(A),R(D))}else for(let N=C==1?c:h;N>=c&&N<=h;N+=C){let M=s[N];M===null?E=!0:M!=null&&T(O,x(v[N]),R(M))}let[k,B]=Kd(t,r);if(g.fill!=null||k!=0){let N=P.fill=new Path2D(O),M=g.fillTo(t,r,g.min,g.max,k),$=R(M),A=x(v[c]),D=x(v[h]);C==-1&&([D,A]=[A,D]),T(N,D,$),T(N,A,$)}if(!g.spanGaps){let N=[];E&&N.push(...Jd(v,s,c,h,C,x,n)),P.gaps=N=g.gaps(t,r,c,h,N),P.clip=bu(N,p.ori,d,o,f,m)}return B!=0&&(P.band=B==2?[hs(t,r,c,h,O,-1),hs(t,r,c,h,O,1)]:hs(t,r,c,h,O,B)),P})}function JE(e){const n=gn(e.align,1),t=gn(e.ascDesc,!1),r=gn(e.alignGaps,0),c=gn(e.extend,!1);return(h,g,v,s)=>va(h,g,(p,a,l,u,d,o,f,m,w,x,R)=>{[v,s]=uu(l,v,s);let T=p.pxRound,{left:_,width:C}=h.bbox,P=Q=>T(o(Q,u,x,m)),O=Q=>T(f(Q,d,R,w)),E=u.ori==0?rl:il;const k={stroke:new Path2D,fill:null,clip:null,band:null,gaps:null,flags:nl},B=k.stroke,N=u.dir*(u.ori==0?1:-1);let M=O(l[N==1?v:s]),$=P(a[N==1?v:s]),A=$,D=$;c&&n==-1&&(D=_,E(B,D,M)),E(B,$,M);for(let Q=N==1?v:s;Q>=v&&Q<=s;Q+=N){let re=l[Q];if(re==null)continue;let le=P(a[Q]),ne=O(re);n==1?E(B,le,M):E(B,A,ne),E(B,le,ne),M=ne,A=le}let j=A;c&&n==1&&(j=_+C,E(B,j,M));let[U,q]=Kd(h,g);if(p.fill!=null||U!=0){let Q=k.fill=new Path2D(B),re=p.fillTo(h,g,p.min,p.max,U),le=O(re);E(Q,j,le),E(Q,D,le)}if(!p.spanGaps){let Q=[];Q.push(...Jd(a,l,v,s,N,P,r));let re=p.width*yn/2,le=t||n==1?re:-re,ne=t||n==-1?-re:re;Q.forEach(ue=>{ue[0]+=le,ue[1]+=ne}),k.gaps=Q=p.gaps(h,g,v,s,Q),k.clip=bu(Q,u.ori,m,w,x,R)}return q!=0&&(k.band=q==2?[hs(h,g,v,s,B,-1),hs(h,g,v,s,B,1)]:hs(h,g,v,s,B,q)),k})}function Bb(e,n,t,r,c,h,g=Mn){if(e.length>1){let v=null;for(let s=0,p=1/0;s<e.length;s++)if(n[s]!==void 0){if(v!=null){let a=kr(e[s]-e[v]);a<p&&(p=a,g=kr(t(e[s],r,c,h)-t(e[v],r,c,h)))}v=s}}return g}function QE(e){e=e||Xl;const n=gn(e.size,[.6,Mn,1]),t=e.align||0,r=e.gap||0;let c=e.radius;c=c==null?[0,0]:typeof c=="number"?[c,0]:c;const h=en(c),g=1-n[0],v=gn(n[1],Mn),s=gn(n[2],1),p=gn(e.disp,Xl),a=gn(e.each,d=>{}),{fill:l,stroke:u}=p;return(d,o,f,m)=>va(d,o,(w,x,R,T,_,C,P,O,E,k,B)=>{let N=w.pxRound,M=t,$=r*yn,A=v*yn,D=s*yn,j,U;T.ori==0?[j,U]=h(d,o):[U,j]=h(d,o);const q=T.dir*(T.ori==0?1:-1);let Q=T.ori==0?Cu:Qd,re=T.ori==0?a:(it,Gt,Fn,Sn,Dn,Gn,Ln)=>{a(it,Gt,Fn,Dn,Sn,Ln,Gn)},le=gn(d.bands,zd).find(it=>it.series[0]==o),ne=le!=null?le.dir:0,ue=w.fillTo(d,o,w.min,w.max,ne),he=N(P(ue,_,B,E)),oe,ee,ye,we=k,Ae=N(w.width*yn),Je=!1,ze=null,Ye=null,Ze=null,at=null;l!=null&&(Ae==0||u!=null)&&(Je=!0,ze=l.values(d,o,f,m),Ye=new Map,new Set(ze).forEach(it=>{it!=null&&Ye.set(it,new Path2D)}),Ae>0&&(Ze=u.values(d,o,f,m),at=new Map,new Set(Ze).forEach(it=>{it!=null&&at.set(it,new Path2D)})));let{x0:ct,size:Ft}=p;if(ct!=null&&Ft!=null){M=1,x=ct.values(d,o,f,m),ct.unit==2&&(x=x.map(Gt=>d.posToVal(O+Gt*k,T.key,!0)));let it=Ft.values(d,o,f,m);Ft.unit==2?ee=it[0]*k:ee=C(it[0],T,k,O)-C(0,T,k,O),we=Bb(x,R,C,T,k,O,we),ye=we-ee+$}else we=Bb(x,R,C,T,k,O,we),ye=we*g+$,ee=we-ye;ye<1&&(ye=0),Ae>=ee/2&&(Ae=0),ye<5&&(N=Wy);let Ie=ye>0,Ct=we-ye-(Ie?Ae:0);ee=N(Pd(Ct,D,A)),oe=(M==0?ee/2:M==q?0:ee)-M*q*((M==0?$/2:0)+(Ie?Ae/2:0));const St={stroke:null,fill:null,clip:null,band:null,gaps:null,flags:0},Vt=Je?null:new Path2D;let hn=null;if(le!=null)hn=d.data[le.series[1]];else{let{y0:it,y1:Gt}=p;it!=null&&Gt!=null&&(R=Gt.values(d,o,f,m),hn=it.values(d,o,f,m))}let $n=j*ee,mt=U*ee;for(let it=q==1?f:m;it>=f&&it<=m;it+=q){let Gt=R[it];if(Gt==null)continue;if(hn!=null){let dn=hn[it]??0;if(Gt-dn==0)continue;he=P(dn,_,B,E)}let Fn=T.distr!=2||p!=null?x[it]:it,Sn=C(Fn,T,k,O),Dn=P(gn(Gt,ue),_,B,E),Gn=N(Sn-oe),Ln=N(ci(Dn,he)),qn=N(Lo(Dn,he)),tr=Ln-qn;if(Gt!=null){let dn=Gt<0?mt:$n,Pn=Gt<0?$n:mt;Je?(Ae>0&&Ze[it]!=null&&Q(at.get(Ze[it]),Gn,qn+Gi(Ae/2),ee,ci(0,tr-Ae),dn,Pn),ze[it]!=null&&Q(Ye.get(ze[it]),Gn,qn+Gi(Ae/2),ee,ci(0,tr-Ae),dn,Pn)):Q(Vt,Gn,qn+Gi(Ae/2),ee,ci(0,tr-Ae),dn,Pn),re(d,o,it,Gn-Ae/2,qn,ee+Ae,tr)}}return Ae>0?St.stroke=Je?at:Vt:Je||(St._fill=w.width==0?w._fill:w._stroke??w._fill,St.width=0),St.fill=Je?Ye:Vt,St})}function ZE(e,n){const t=gn(n?.alignGaps,0);return(r,c,h,g)=>va(r,c,(v,s,p,a,l,u,d,o,f,m,w)=>{[h,g]=uu(p,h,g);let x=v.pxRound,R=j=>x(u(j,a,m,o)),T=j=>x(d(j,l,w,f)),_,C,P;a.ori==0?(_=wu,P=rl,C=Ob):(_=xu,P=il,C=Nb);const O=a.dir*(a.ori==0?1:-1);let E=R(s[O==1?h:g]),k=E,B=[],N=[];for(let j=O==1?h:g;j>=h&&j<=g;j+=O)if(p[j]!=null){let U=s[j],q=R(U);B.push(k=q),N.push(T(p[j]))}const M={stroke:e(B,N,_,P,C,x),fill:null,clip:null,band:null,gaps:null,flags:nl},$=M.stroke;let[A,D]=Kd(r,c);if(v.fill!=null||A!=0){let j=M.fill=new Path2D($),U=v.fillTo(r,c,v.min,v.max,A),q=T(U);P(j,k,q),P(j,E,q)}if(!v.spanGaps){let j=[];j.push(...Jd(s,p,h,g,O,R,t)),M.gaps=j=v.gaps(r,c,h,g,j),M.clip=bu(j,a.ori,o,f,m,w)}return D!=0&&(M.band=D==2?[hs(r,c,h,g,$,-1),hs(r,c,h,g,$,1)]:hs(r,c,h,g,$,D)),M})}function XE(e){return ZE(eI,e)}function eI(e,n,t,r,c,h){const g=e.length;if(g<2)return null;const v=new Path2D;if(t(v,e[0],n[0]),g==2)r(v,e[1],n[1]);else{let s=Array(g),p=Array(g-1),a=Array(g-1),l=Array(g-1);for(let u=0;u<g-1;u++)a[u]=n[u+1]-n[u],l[u]=e[u+1]-e[u],p[u]=a[u]/l[u];s[0]=p[0];for(let u=1;u<g-1;u++)p[u]===0||p[u-1]===0||p[u-1]>0!=p[u]>0?s[u]=0:(s[u]=3*(l[u-1]+l[u])/((2*l[u]+l[u-1])/p[u-1]+(l[u]+2*l[u-1])/p[u]),isFinite(s[u])||(s[u]=0));s[g-1]=p[g-2];for(let u=0;u<g-1;u++)c(v,e[u]+l[u]/3,n[u]+s[u]*l[u]/3,e[u+1]-l[u]/3,n[u+1]-s[u+1]*l[u]/3,e[u+1],n[u+1])}return v}const Zd=new Set;function Fb(){for(let e of Zd)e.syncRect(!0)}Ja&&(fa(OT,Qa,Fb),fa(NT,Qa,Fb,!0),fa(lu,Qa,()=>{Jr.pxRatio=yn}));const tI=zb(),nI=Db();function jb(e,n,t,r){return(r?[e[0],e[1]].concat(e.slice(2)):[e[0]].concat(e.slice(1))).map((c,h)=>Xd(c,h,n,t))}function rI(e,n){return e.map((t,r)=>r==0?{}:pr({},n,t))}function Xd(e,n,t,r){return pr({},n==0?t:r,e)}function Wb(e,n,t){return n==null?Xa:[n,t]}const iI=Wb;function oI(e,n,t){return n==null?Xa:du(n,t,Od,!0)}function Hb(e,n,t,r){return n==null?Xa:hu(n,t,e.scales[r].log,!1)}const sI=Hb;function Ub(e,n,t,r){return n==null?Xa:Ld(n,t,e.scales[r].log,!1)}const aI=Ub;function lI(e,n,t,r,c){let h=ci(Fy(e),Fy(n)),g=n-e,v=Ro(c/r*g,t);do{let s=t[v],p=r*s/g;if(p>=c&&h+(s<5?zs.get(s):0)<=17)return[s,p]}while(++v<t.length);return[0,0]}function Vb(e){let n,t;return e=e.replace(/(\d+)px/,(r,c)=>(n=_r((t=+c)*yn))+"px"),[e,n,t]}function cI(e){e.show&&[e.font,e.labelFont].forEach(n=>{let t=Rn(n[2]*yn,1);n[0]=n[0].replace(/[0-9.]+px/,t+"px"),n[1]=t})}function Jr(e,n,t){const r={mode:gn(e.mode,1)},c=r.mode;function h(V,J,ae,ce){let ge=J.valToPct(V);return ce+ae*(J.dir==-1?1-ge:ge)}function g(V,J,ae,ce){let ge=J.valToPct(V);return ce+ae*(J.dir==-1?ge:1-ge)}function v(V,J,ae,ce){return J.ori==0?h(V,J,ae,ce):g(V,J,ae,ce)}r.valToPosH=h,r.valToPosV=g;let s=!1;r.status=0;const p=r.root=lo(mT);if(e.id!=null&&(p.id=e.id),Ui(p,e.class),e.title){let V=lo(bT,p);V.textContent=e.title}const a=Mo("canvas"),l=r.ctx=a.getContext("2d"),u=lo(wT,p);fa("click",u,V=>{V.target===o&&(We!=xe||rt!=Me)&&bn.click(r,V)},!0);const d=r.under=lo(xT,u);u.appendChild(a);const o=r.over=lo(CT,u);e=el(e);const f=+gn(e.pxAlign,1),m=Ib(f);(e.plugins||[]).forEach(V=>{V.opts&&(e=V.opts(r,e)||e)});const w=e.ms||.001,x=r.series=c==1?jb(e.series||[],bb,$b,!1):rI(e.series||[null],Ab),R=r.axes=jb(e.axes||[],yb,Cb,!0),T=r.scales={},_=r.bands=e.bands||[];_.forEach(V=>{V.fill=en(V.fill||null),V.dir=gn(V.dir,-1)});const C=c==2?x[1].facets[0].scale:x[0].scale,P={axes:ts,series:Cs},O=(e.drawOrder||["axes","series"]).map(V=>P[V]);function E(V){const J=V.distr==3?ae=>us(ae>0?ae:V.clamp(r,ae,V.min,V.max,V.key)):V.distr==4?ae=>Dd(ae,V.asinh):V.distr==100?ae=>V.fwd(ae):ae=>ae;return ae=>{let ce=J(ae),{_min:ge,_max:Se}=V,Le=Se-ge;return(ce-ge)/Le}}function k(V){let J=T[V];if(J==null){let ae=(e.scales||Xl)[V]||Xl;if(ae.from!=null){k(ae.from);let ce=pr({},T[ae.from],ae,{key:V});ce.valToPct=E(ce),T[V]=ce}else{J=T[V]=pr({},V==C?Sb:VE,ae),J.key=V;let ce=J.time,ge=J.range,Se=Bs(ge);if((V!=C||c==2&&!ce)&&(Se&&(ge[0]==null||ge[1]==null)&&(ge={min:ge[0]==null?Dy:{mode:1,hard:ge[0],soft:ge[0]},max:ge[1]==null?Dy:{mode:1,hard:ge[1],soft:ge[1]}},Se=!1),!Se&&gu(ge))){let Le=ge;ge=(He,qe,Qe)=>qe==null?Xa:du(qe,Qe,Le)}J.range=en(ge||(ce?iI:V==C?J.distr==3?sI:J.distr==4?aI:Wb:J.distr==3?Hb:J.distr==4?Ub:oI)),J.auto=en(Se?!1:J.auto),J.clamp=en(J.clamp||UE),J._min=J._max=null,J.valToPct=E(J)}}}k("x"),k("y"),c==1&&x.forEach(V=>{k(V.scale)}),R.forEach(V=>{k(V.scale)});for(let V in e.scales)k(V);const B=T[C],N=B.distr;let M,$;B.ori==0?(Ui(p,vT),M=h,$=g):(Ui(p,yT),M=g,$=h);const A={};for(let V in T){let J=T[V];(J.min!=null||J.max!=null)&&(A[V]={min:J.min,max:J.max},J.min=J.max=null)}const D=e.tzDate||(V=>new Date(_r(V/w))),j=e.fmtDate||Bd,U=w==1?vE(D):wE(D),q=ub(D,cb(w==1?mE:bE,j)),Q=db(D,hb(CE,j)),re=[],le=r.legend=pr({},AE,e.legend),ne=r.cursor=pr({},ME,{drag:{y:c==2}},e.cursor),ue=le.show,he=ne.show,oe=le.markers;le.idxs=re,oe.width=en(oe.width),oe.dash=en(oe.dash),oe.stroke=en(oe.stroke),oe.fill=en(oe.fill);let ee,ye,we,Ae=[],Je=[],ze,Ye=!1,Ze={};if(le.live){const V=x[1]?x[1].values:null;Ye=V!=null,ze=Ye?V(r,1,0):{_:0};for(let J in ze)Ze[J]=Sd}if(ue)if(ee=Mo("table",TT,p),we=Mo("tbody",null,ee),le.mount(r,ee),Ye){ye=Mo("thead",null,ee,we);let V=Mo("tr",null,ye);Mo("th",null,V);for(var at in ze)Mo("th",wy,V).textContent=at}else Ui(ee,IT),le.live&&Ui(ee,ET);const ct={show:!0},Ft={show:!1};function Ie(V,J){if(J==0&&(Ye||!le.live||c==2))return Xa;let ae=[],ce=Mo("tr",MT,we,we.childNodes[J]);Ui(ce,V.class),V.show||Ui(ce,da);let ge=Mo("th",null,ce);if(oe.show){let He=lo(RT,ge);if(J>0){let qe=oe.width(r,J);qe&&(He.style.border=qe+"px "+oe.dash(r,J)+" "+oe.stroke(r,J)),He.style.background=oe.fill(r,J)}}let Se=lo(wy,ge);V.label instanceof HTMLElement?Se.appendChild(V.label):Se.textContent=V.label,J>0&&(oe.show||(Se.style.color=V.width>0?oe.stroke(r,J):oe.fill(r,J)),St("click",ge,He=>{if(ne._lock)return;Ii(He);let qe=x.indexOf(V);if((He.ctrlKey||He.metaKey)!=le.isolate){let Qe=x.some((ot,ft)=>ft>0&&ft!=qe&&ot.show);x.forEach((ot,ft)=>{ft>0&&yr(ft,Qe?ft==qe?ct:Ft:ct,!0,Rt.setSeries)})}else yr(qe,{show:!V.show},!0,Rt.setSeries)},!1),Or&&St(_y,ge,He=>{ne._lock||(Ii(He),yr(x.indexOf(V),Co,!0,Rt.setSeries))},!1));for(var Le in ze){let He=Mo("td",LT,ce);He.textContent="--",ae.push(He)}return[ce,ae]}const Ct=new Map;function St(V,J,ae,ce=!0){const ge=Ct.get(J)||{},Se=ne.bind[V](r,J,ae,ce);Se&&(fa(V,J,ge[V]=Se),Ct.set(J,ge))}function Vt(V,J,ae){const ce=Ct.get(J)||{};for(let ge in ce)(V==null||ge==V)&&(Rd(ge,J,ce[ge]),delete ce[ge]);V==null&&Ct.delete(J)}let hn=0,$n=0,mt=0,it=0,Gt=0,Fn=0,Sn=Gt,Dn=Fn,Gn=mt,Ln=it,qn=0,tr=0,dn=0,Pn=0;r.bbox={};let Ti=!1,Xr=!1,ei=!1,Ei=!1,fo=!1,vr=!1;function Ji(V,J,ae){(ae||V!=r.width||J!=r.height)&&jr(V,J),ni(!1),ei=!0,Xr=!0,Xi()}function jr(V,J){r.width=hn=mt=V,r.height=$n=it=J,Gt=Fn=0,gs(),Ko();let ae=r.bbox;qn=ae.left=ga(Gt*yn,.5),tr=ae.top=ga(Fn*yn,.5),dn=ae.width=ga(mt*yn,.5),Pn=ae.height=ga(it*yn,.5)}const po=3;function ur(){let V=!1,J=0;for(;!V;){J++;let ae=wo(J),ce=Pr(J);V=J==po||ae&&ce,V||(jr(r.width,r.height),Xr=!0)}}function Hs({width:V,height:J}){Ji(V,J)}r.setSize=Hs;function gs(){let V=!1,J=!1,ae=!1,ce=!1;R.forEach((ge,Se)=>{if(ge.show&&ge._show){let{side:Le,_size:He}=ge,qe=Le%2,Qe=ge.label!=null?ge.labelSize:0,ot=He+Qe;ot>0&&(qe?(mt-=ot,Le==3?(Gt+=ot,ce=!0):ae=!0):(it-=ot,Le==0?(Fn+=ot,V=!0):J=!0))}}),di[0]=V,di[1]=ae,di[2]=J,di[3]=ce,mt-=Nr[1]+Nr[3],Gt+=Nr[3],it-=Nr[2]+Nr[0],Fn+=Nr[0]}function Ko(){let V=Gt+mt,J=Fn+it,ae=Gt,ce=Fn;function ge(Se,Le){switch(Se){case 1:return V+=Le,V-Le;case 2:return J+=Le,J-Le;case 3:return ae-=Le,ae+Le;case 0:return ce-=Le,ce+Le}}R.forEach((Se,Le)=>{if(Se.show&&Se._show){let He=Se.side;Se._pos=ge(He,Se._size),Se.label!=null&&(Se._lpos=ge(He,Se.labelSize))}})}if(ne.dataIdx==null){let V=ne.hover,J=V.skip=new Set(V.skip??[]);J.add(void 0);let ae=V.prox=en(V.prox),ce=V.bias??=0;ne.dataIdx=(ge,Se,Le,He)=>{if(Se==0)return Le;let qe=Le,Qe=ae(ge,Se,Le,He)??Mn,ot=Qe>=0&&Qe<Mn,ft=B.ori==0?mt:it,Mt=ne.left,pn=n[0],Yt=n[Se];if(J.has(Yt[Le])){qe=null;let It=null,At=null,bt;if(ce==0||ce==-1)for(bt=Le;It==null&&bt-- >0;)J.has(Yt[bt])||(It=bt);if(ce==0||ce==1)for(bt=Le;At==null&&bt++<Yt.length;)J.has(Yt[bt])||(At=bt);if(It!=null||At!=null)if(ot){let On=It==null?-1/0:M(pn[It],B,ft,0),Xn=At==null?1/0:M(pn[At],B,ft,0),wr=Mt-On,Cn=Xn-Mt;wr<=Cn?wr<=Qe&&(qe=It):Cn<=Qe&&(qe=At)}else qe=At==null?It:It==null?At:Le-It<=At-Le?It:At}else ot&&kr(Mt-M(pn[Le],B,ft,0))>Qe&&(qe=null);return qe}}const Ii=V=>{ne.event=V};ne.idxs=re,ne._lock=!1;let Yn=ne.points;Yn.show=en(Yn.show),Yn.size=en(Yn.size),Yn.stroke=en(Yn.stroke),Yn.width=en(Yn.width),Yn.fill=en(Yn.fill);const $r=r.focus=pr({},e.focus||{alpha:.3},ne.focus),Or=$r.prox>=0,mn=Or&&Yn.one;let jn=[],Mi=[],hi=[];function ms(V,J){let ae=Yn.show(r,J);if(ae instanceof HTMLElement)return Ui(ae,ST),Ui(ae,V.class),Yo(ae,-10,-10,mt,it),o.insertBefore(ae,jn[J]),ae}function vs(V,J){if(c==1||J>0){let ae=c==1&&T[V.scale].time,ce=V.value;V.value=ae?Ky(ce)?db(D,hb(ce,j)):ce||Q:ce||jE,V.label=V.label||(ae?LE:RE)}if(mn||J>0){V.width=V.width==null?1:V.width,V.paths=V.paths||tI||VT,V.fillTo=en(V.fillTo||GE),V.pxAlign=+gn(V.pxAlign,f),V.pxRound=Ib(V.pxAlign),V.stroke=en(V.stroke||null),V.fill=en(V.fill||null),V._stroke=V._fill=V._paths=V._focus=null;let ae=WE(ci(1,V.width),1),ce=V.points=pr({},{size:ae,width:ci(1,ae*.2),stroke:V.stroke,space:ae*2,paths:nI,_stroke:null,_fill:null},V.points);ce.show=en(ce.show),ce.filter=en(ce.filter),ce.fill=en(ce.fill),ce.stroke=en(ce.stroke),ce.paths=en(ce.paths),ce.pxAlign=V.pxAlign}if(ue){let ae=Ie(V,J);Ae.splice(J,0,ae[0]),Je.splice(J,0,ae[1]),le.values.push(null)}if(he){re.splice(J,0,null);let ae=null;mn?J==0&&(ae=ms(V,J)):J>0&&(ae=ms(V,J)),jn.splice(J,0,ae),Mi.splice(J,0,0),hi.splice(J,0,0)}pt("addSeries",J)}function ys(V,J){J=J??x.length,V=c==1?Xd(V,J,bb,$b):Xd(V,J,{},Ab),x.splice(J,0,V),vs(x[J],J)}r.addSeries=ys;function bs(V){if(x.splice(V,1),ue){le.values.splice(V,1),Je.splice(V,1);let J=Ae.splice(V,1)[0];Vt(null,J.firstChild),J.remove()}he&&(re.splice(V,1),jn.splice(V,1)[0].remove(),Mi.splice(V,1),hi.splice(V,1)),pt("delSeries",V)}r.delSeries=bs;const di=[!1,!1,!1,!1];function Ri(V,J){if(V._show=V.show,V.show){let ae=V.side%2,ce=T[V.scale];ce==null&&(V.scale=ae?x[1].scale:C,ce=T[V.scale]);let ge=ce.time;V.size=en(V.size),V.space=en(V.space),V.rotate=en(V.rotate),Bs(V.incrs)&&V.incrs.forEach(Le=>{!zs.has(Le)&&zs.set(Le,qy(Le))}),V.incrs=en(V.incrs||(ce.distr==2?fE:ge?w==1?gE:yE:ma)),V.splits=en(V.splits||(ge&&ce.distr==1?U:ce.distr==3?Gd:ce.distr==4?DE:NE)),V.stroke=en(V.stroke),V.grid.stroke=en(V.grid.stroke),V.ticks.stroke=en(V.ticks.stroke),V.border.stroke=en(V.border.stroke);let Se=V.values;V.values=Bs(Se)&&!Bs(Se[0])?en(Se):ge?Bs(Se)?ub(D,cb(Se,j)):Ky(Se)?xE(D,Se):Se||q:Se||OE,V.filter=en(V.filter||(ce.distr>=3&&ce.log==10?BE:ce.distr==3&&ce.log==2?FE:Hy)),V.font=Vb(V.font),V.labelFont=Vb(V.labelFont),V._size=V.size(r,null,J,0),V._space=V._rotate=V._incrs=V._found=V._splits=V._values=null,V._size>0&&(di[J]=!0,V._el=lo(kT,u))}}function Dt(V,J,ae,ce){let[ge,Se,Le,He]=ae,qe=J%2,Qe=0;return qe==0&&(He||Se)&&(Qe=J==0&&!ge||J==2&&!Le?_r(yb.size/3):0),qe==1&&(ge||Le)&&(Qe=J==1&&!Se||J==3&&!He?_r(Cb.size/2):0),Qe}const Us=r.padding=(e.padding||[Dt,Dt,Dt,Dt]).map(V=>en(gn(V,Dt))),Nr=r._padding=Us.map((V,J)=>V(r,J,di,0));let Pt,fn=null,Kn=null;const go=c==1?x[0].idxs:null;let nr=null,mo=!1;function Li(V,J){if(n=V??[],r.data=r._data=n,c==2){Pt=0;for(let ae=1;ae<x.length;ae++)Pt+=n[ae][0].length}else{n.length==0&&(r.data=r._data=n=[[]]),nr=n[0],Pt=nr.length;let ae=n;if(N==2){ae=n.slice();let ce=ae[0]=Array(Pt);for(let ge=0;ge<Pt;ge++)ce[ge]=ge}r._data=n=ae}if(ni(!0),pt("setData"),N==2&&(ei=!0),J!==!1){let ae=B;ae.auto(r,mo)?ws():ri(C,ae.min,ae.max),Ei=Ei||ne.left>=0,vr=!0,Xi()}}r.setData=Li;function ws(){mo=!0;let V,J;c==1&&(Pt>0?(fn=go[0]=0,Kn=go[1]=Pt-1,V=n[0][fn],J=n[0][Kn],N==2?(V=fn,J=Kn):V==J&&(N==3?[V,J]=hu(V,V,B.log,!1):N==4?[V,J]=Ld(V,V,B.log,!1):B.time?J=V+_r(86400/w):[V,J]=du(V,J,Od,!0))):(fn=go[0]=V=null,Kn=go[1]=J=null)),ri(C,V,J)}let vo,fi,Do,ti,Dr,yo,Oi,Jo,Po,rr;function zo(V,J,ae,ce,ge,Se){V??=Cy,ae??=zd,ce??="butt",ge??=Cy,Se??="round",V!=vo&&(l.strokeStyle=vo=V),ge!=fi&&(l.fillStyle=fi=ge),J!=Do&&(l.lineWidth=Do=J),Se!=Dr&&(l.lineJoin=Dr=Se),ce!=yo&&(l.lineCap=yo=ce),ae!=ti&&l.setLineDash(ti=ae)}function Qo(V,J,ae,ce){J!=fi&&(l.fillStyle=fi=J),V!=Oi&&(l.font=Oi=V),ae!=Jo&&(l.textAlign=Jo=ae),ce!=Po&&(l.textBaseline=Po=ce)}function Qi(V,J,ae,ce,ge=0){if(ce.length>0&&V.auto(r,mo)&&(J==null||J.min==null)){let Se=gn(fn,0),Le=gn(Kn,ce.length-1),He=ae.min==null?BT(ce,Se,Le,ge,V.distr==3):[ae.min,ae.max];V.min=Lo(V.min,ae.min=He[0]),V.max=ci(V.max,ae.max=He[1])}}const xs={min:null,max:null};function Zo(){for(let ce in T){let ge=T[ce];A[ce]==null&&(ge.min==null||A[C]!=null&&ge.auto(r,mo))&&(A[ce]=xs)}for(let ce in T){let ge=T[ce];A[ce]==null&&ge.from!=null&&A[ge.from]!=null&&(A[ce]=xs)}A[C]!=null&&ni(!0);let V={};for(let ce in A){let ge=A[ce];if(ge!=null){let Se=V[ce]=el(T[ce],YT);if(ge.min!=null)pr(Se,ge);else if(ce!=C||c==2)if(Pt==0&&Se.from==null){let Le=Se.range(r,null,null,ce);Se.min=Le[0],Se.max=Le[1]}else Se.min=Mn,Se.max=-Mn}}if(Pt>0){x.forEach((ce,ge)=>{if(c==1){let Se=ce.scale,Le=A[Se];if(Le==null)return;let He=V[Se];if(ge==0){let qe=He.range(r,He.min,He.max,Se);He.min=qe[0],He.max=qe[1],fn=Ro(He.min,n[0]),Kn=Ro(He.max,n[0]),Kn-fn>1&&(n[0][fn]<He.min&&fn++,n[0][Kn]>He.max&&Kn--),ce.min=nr[fn],ce.max=nr[Kn]}else ce.show&&ce.auto&&Qi(He,Le,ce,n[ge],ce.sorted);ce.idxs[0]=fn,ce.idxs[1]=Kn}else if(ge>0&&ce.show&&ce.auto){let[Se,Le]=ce.facets,He=Se.scale,qe=Le.scale,[Qe,ot]=n[ge],ft=V[He],Mt=V[qe];ft!=null&&Qi(ft,A[He],Se,Qe,Se.sorted),Mt!=null&&Qi(Mt,A[qe],Le,ot,Le.sorted),ce.min=Le.min,ce.max=Le.max}});for(let ce in V){let ge=V[ce],Se=A[ce];if(ge.from==null&&(Se==null||Se.min==null)){let Le=ge.range(r,ge.min==Mn?null:ge.min,ge.max==-Mn?null:ge.max,ce);ge.min=Le[0],ge.max=Le[1]}}}for(let ce in V){let ge=V[ce];if(ge.from!=null){let Se=V[ge.from];if(Se.min==null)ge.min=ge.max=null;else{let Le=ge.range(r,Se.min,Se.max,ce);ge.min=Le[0],ge.max=Le[1]}}}let J={},ae=!1;for(let ce in V){let ge=V[ce],Se=T[ce];if(Se.min!=ge.min||Se.max!=ge.max){Se.min=ge.min,Se.max=ge.max;let Le=Se.distr;Se._min=Le==3?us(Se.min):Le==4?Dd(Se.min,Se.asinh):Le==100?Se.fwd(Se.min):Se.min,Se._max=Le==3?us(Se.max):Le==4?Dd(Se.max,Se.asinh):Le==100?Se.fwd(Se.max):Se.max,J[ce]=ae=!0}}if(ae){x.forEach((ce,ge)=>{c==2?ge>0&&J.y&&(ce._paths=null):J[ce.scale]&&(ce._paths=null)});for(let ce in J)ei=!0,pt("setScale",ce);he&&ne.left>=0&&(Ei=vr=!0)}for(let ce in A)A[ce]=null}function Bo(V){let J=Pd(fn-1,0,Pt-1),ae=Pd(Kn+1,0,Pt-1);for(;V[J]==null&&J>0;)J--;for(;V[ae]==null&&ae<Pt-1;)ae++;return[J,ae]}function Cs(){if(Pt>0){let V=x.some(J=>J._focus)&&rr!=$r.alpha;V&&(l.globalAlpha=rr=$r.alpha),x.forEach((J,ae)=>{if(ae>0&&J.show&&(Xo(ae,!1),Xo(ae,!0),J._paths==null)){let ce=rr;rr!=J.alpha&&(l.globalAlpha=rr=J.alpha);let ge=c==2?[0,n[ae][0].length-1]:Bo(n[ae]);J._paths=J.paths(r,ae,ge[0],ge[1]),rr!=ce&&(l.globalAlpha=rr=ce)}}),x.forEach((J,ae)=>{if(ae>0&&J.show){let ce=rr;rr!=J.alpha&&(l.globalAlpha=rr=J.alpha),J._paths!=null&&es(ae,!1);{let ge=J._paths!=null?J._paths.gaps:null,Se=J.points.show(r,ae,fn,Kn,ge),Le=J.points.filter(r,ae,Se,ge);(Se||Le)&&(J.points._paths=J.points.paths(r,ae,fn,Kn,Le),es(ae,!0))}rr!=ce&&(l.globalAlpha=rr=ce),pt("drawSeries",ae)}}),V&&(l.globalAlpha=rr=1)}}function Xo(V,J){let ae=J?x[V].points:x[V];ae._stroke=ae.stroke(r,V),ae._fill=ae.fill(r,V)}function es(V,J){let ae=J?x[V].points:x[V],{stroke:ce,fill:ge,clip:Se,flags:Le,_stroke:He=ae._stroke,_fill:qe=ae._fill,_width:Qe=ae.width}=ae._paths;Qe=Rn(Qe*yn,3);let ot=null,ft=Qe%2/2;J&&qe==null&&(qe=Qe>0?"#fff":He);let Mt=ae.pxAlign==1&&ft>0;if(Mt&&l.translate(ft,ft),!J){let pn=qn-Qe/2,Yt=tr-Qe/2,It=dn+Qe,At=Pn+Qe;ot=new Path2D,ot.rect(pn,Yt,It,At)}J?Zi(He,Qe,ae.dash,ae.cap,qe,ce,ge,Le,Se):ks(V,He,Qe,ae.dash,ae.cap,qe,ce,ge,Le,ot,Se),Mt&&l.translate(-ft,-ft)}function ks(V,J,ae,ce,ge,Se,Le,He,qe,Qe,ot){let ft=!1;qe!=0&&_.forEach((Mt,pn)=>{if(Mt.series[0]==V){let Yt=x[Mt.series[1]],It=n[Mt.series[1]],At=(Yt._paths||Xl).band;Bs(At)&&(At=Mt.dir==1?At[0]:At[1]);let bt,On=null;Yt.show&&At&&jT(It,fn,Kn)?(On=Mt.fill(r,pn)||Se,bt=Yt._paths.clip):At=null,Zi(J,ae,ce,ge,On,Le,He,qe,Qe,ot,bt,At),ft=!0}}),ft||Zi(J,ae,ce,ge,Se,Le,He,qe,Qe,ot)}const Ni=nl|Yd;function Zi(V,J,ae,ce,ge,Se,Le,He,qe,Qe,ot,ft){zo(V,J,ae,ce,ge),(qe||Qe||ft)&&(l.save(),qe&&l.clip(qe),Qe&&l.clip(Qe)),ft?(He&Ni)==Ni?(l.clip(ft),ot&&l.clip(ot),or(ge,Le),pi(V,Se,J)):He&Yd?(or(ge,Le),l.clip(ft),pi(V,Se,J)):He&nl&&(l.save(),l.clip(ft),ot&&l.clip(ot),or(ge,Le),l.restore(),pi(V,Se,J)):(or(ge,Le),pi(V,Se,J)),(qe||Qe||ft)&&l.restore()}function pi(V,J,ae){ae>0&&(J instanceof Map?J.forEach((ce,ge)=>{l.strokeStyle=vo=ge,l.stroke(ce)}):J!=null&&V&&l.stroke(J))}function or(V,J){J instanceof Map?J.forEach((ae,ce)=>{l.fillStyle=fi=ce,l.fill(ae)}):J!=null&&V&&l.fill(J)}function bo(V,J,ae,ce){let ge=R[V],Se;if(ce<=0)Se=[0,0];else{let Le=ge._space=ge.space(r,V,J,ae,ce),He=ge._incrs=ge.incrs(r,V,J,ae,ce,Le);Se=lI(J,ae,He,ce,Le)}return ge._found=Se}function Jn(V,J,ae,ce,ge,Se,Le,He,qe,Qe){let ot=Le%2/2;f==1&&l.translate(ot,ot),zo(He,Le,qe,Qe,He),l.beginPath();let ft,Mt,pn,Yt,It=ge+(ce==0||ce==3?-Se:Se);ae==0?(Mt=ge,Yt=It):(ft=ge,pn=It);for(let At=0;At<V.length;At++)J[At]!=null&&(ae==0?ft=pn=V[At]:Mt=Yt=V[At],l.moveTo(ft,Mt),l.lineTo(pn,Yt));l.stroke(),f==1&&l.translate(-ot,-ot)}function wo(V){let J=!0;return R.forEach((ae,ce)=>{if(!ae.show)return;let ge=T[ae.scale];if(ge.min==null){ae._show&&(J=!1,ae._show=!1,ni(!1));return}else ae._show||(J=!1,ae._show=!0,ni(!1));let Se=ae.side,Le=Se%2,{min:He,max:qe}=ge,[Qe,ot]=bo(ce,He,qe,Le==0?mt:it);if(ot==0)return;let ft=ge.distr==2,Mt=ae._splits=ae.splits(r,ce,He,qe,Qe,ot,ft),pn=ge.distr==2?Mt.map(bt=>nr[bt]):Mt,Yt=ge.distr==2?nr[Mt[1]]-nr[Mt[0]]:Qe,It=ae._values=ae.values(r,ae.filter(r,pn,ce,ot,Yt),ce,ot,Yt);ae._rotate=Se==2?ae.rotate(r,It,ce,ot):0;let At=ae._size;ae._size=co(ae.size(r,It,ce,V)),At!=null&&ae._size!=At&&(J=!1)}),J}function Pr(V){let J=!0;return Us.forEach((ae,ce)=>{let ge=ae(r,ce,di,V);ge!=Nr[ce]&&(J=!1),Nr[ce]=ge}),J}function ts(){for(let V=0;V<R.length;V++){let J=R[V];if(!J.show||!J._show)continue;let ae=J.side,ce=ae%2,ge,Se,Le=J.stroke(r,V),He=ae==0||ae==3?-1:1,[qe,Qe]=J._found;if(J.label!=null){let Ur=J.labelGap*He,zn=_r((J._lpos+Ur)*yn);Qo(J.labelFont[0],Le,"center",ae==2?Jl:xy),l.save(),ce==1?(ge=Se=0,l.translate(zn,_r(tr+Pn/2)),l.rotate((ae==3?-fu:fu)/2)):(ge=_r(qn+dn/2),Se=zn);let ko=jy(J.label)?J.label(r,V,qe,Qe):J.label;l.fillText(ko,ge,Se),l.restore()}if(Qe==0)continue;let ot=T[J.scale],ft=ce==0?dn:Pn,Mt=ce==0?qn:tr,pn=J._splits,Yt=ot.distr==2?pn.map(Ur=>nr[Ur]):pn,It=ot.distr==2?nr[pn[1]]-nr[pn[0]]:qe,At=J.ticks,bt=J.border,On=At.show?At.size:0,Xn=_r(On*yn),wr=_r((J.alignTo==2?J._size-On-J.gap:J.gap)*yn),Cn=J._rotate*-fu/180,En=m(J._pos*yn),be=(Xn+wr)*He,Re=En+be;Se=ce==0?Re:0,ge=ce==1?Re:0;let Ee=J.font[0],Xe=J.align==1?Ka:J.align==2?kd:Cn>0?Ka:Cn<0?kd:ce==0?"center":ae==3?kd:Ka,_t=Cn||ce==1?"middle":ae==2?Jl:xy;Qo(Ee,Le,Xe,_t);let Nt=J.font[1]*J.lineGap,vn=pn.map(Ur=>m(v(Ur,ot,ft,Mt))),Kt=J._values;for(let Ur=0;Ur<Kt.length;Ur++){let zn=Kt[Ur];if(zn!=null){ce==0?ge=vn[Ur]:Se=vn[Ur],zn=""+zn;let ko=zn.indexOf(`
1480
+ `)==-1?[zn]:zn.split(/\n/gm);for(let Vr=0;Vr<ko.length;Vr++){let _s=ko[Vr];Cn?(l.save(),l.translate(ge,Se+Vr*Nt),l.rotate(Cn),l.fillText(_s,0,0),l.restore()):l.fillText(_s,ge,Se+Vr*Nt)}}}At.show&&Jn(vn,At.filter(r,Yt,V,Qe,It),ce,ae,En,Xn,Rn(At.width*yn,3),At.stroke(r,V),At.dash,At.cap);let Pi=J.grid;Pi.show&&Jn(vn,Pi.filter(r,Yt,V,Qe,It),ce,ce==0?2:1,ce==0?tr:qn,ce==0?Pn:dn,Rn(Pi.width*yn,3),Pi.stroke(r,V),Pi.dash,Pi.cap),bt.show&&Jn([En],[1],ce==0?1:0,ce==0?1:2,ce==1?tr:qn,ce==1?Pn:dn,Rn(bt.width*yn,3),bt.stroke(r,V),bt.dash,bt.cap)}pt("drawAxes")}function ni(V){x.forEach((J,ae)=>{ae>0&&(J._paths=null,V&&(c==1?(J.min=null,J.max=null):J.facets.forEach(ce=>{ce.min=null,ce.max=null})))})}let Fo=!1,jo=!1,Wr=[];function ns(){jo=!1;for(let V=0;V<Wr.length;V++)pt(...Wr[V]);Wr.length=0}function Xi(){Fo||(tE(rs),Fo=!0)}function Ue(V,J=!1){Fo=!0,jo=J,V(r),rs(),J&&Wr.length>0&&queueMicrotask(ns)}r.batch=Ue;function rs(){if(Ti&&(Zo(),Ti=!1),ei&&(ur(),ei=!1),Xr){if(Bn(d,Ka,Gt),Bn(d,Jl,Fn),Bn(d,Yl,mt),Bn(d,Kl,it),Bn(o,Ka,Gt),Bn(o,Jl,Fn),Bn(o,Yl,mt),Bn(o,Kl,it),Bn(u,Yl,hn),Bn(u,Kl,$n),a.width=_r(hn*yn),a.height=_r($n*yn),R.forEach(({_el:V,_show:J,_size:ae,_pos:ce,side:ge})=>{if(V!=null)if(J){let Se=ge===3||ge===0?ae:0,Le=ge%2==1;Bn(V,Le?"left":"top",ce-Se),Bn(V,Le?"width":"height",ae),Bn(V,Le?"top":"left",Le?Fn:Gt),Bn(V,Le?"height":"width",Le?it:mt),Id(V,da)}else Ui(V,da)}),vo=fi=Do=Dr=yo=Oi=Jo=Po=ti=null,rr=1,F(!0),Gt!=Sn||Fn!=Dn||mt!=Gn||it!=Ln){ni(!1);let V=mt/Gn,J=it/Ln;if(he&&!Ei&&ne.left>=0){ne.left*=V,ne.top*=J,gi&&Yo(gi,_r(ne.left),0,mt,it),Tn&&Yo(Tn,0,_r(ne.top),mt,it);for(let ae=0;ae<jn.length;ae++){let ce=jn[ae];ce!=null&&(Mi[ae]*=V,hi[ae]*=J,Yo(ce,co(Mi[ae]),co(hi[ae]),mt,it))}}if(xt.show&&!fo&&xt.left>=0&&xt.width>0){xt.left*=V,xt.width*=V,xt.top*=J,xt.height*=J;for(let ae in K)Bn(ln,ae,xt[ae])}Sn=Gt,Dn=Fn,Gn=mt,Ln=it}pt("setSize"),Xr=!1}hn>0&&$n>0&&(l.clearRect(0,0,a.width,a.height),pt("drawClear"),O.forEach(V=>V()),pt("draw")),xt.show&&fo&&(mi(xt),fo=!1),he&&Ei&&(S(null,!0,!1),Ei=!1),le.show&&le.live&&vr&&(b(),vr=!1),s||(s=!0,r.status=1,pt("ready")),mo=!1,Fo=!1}r.redraw=(V,J)=>{ei=J||!1,V!==!1?ri(C,B.min,B.max):Xi()};function Fe(V,J){let ae=T[V];if(ae.from==null){if(Pt==0){let ce=ae.range(r,J.min,J.max,V);J.min=ce[0],J.max=ce[1]}if(J.min>J.max){let ce=J.min;J.min=J.max,J.max=ce}if(Pt>1&&J.min!=null&&J.max!=null&&J.max-J.min<1e-16)return;V==C&&ae.distr==2&&Pt>0&&(J.min=Ro(J.min,n[0]),J.max=Ro(J.max,n[0]),J.min==J.max&&J.max++),A[V]=J,Ti=!0,Xi()}}r.setScale=Fe;let Wn,xo,gi,Tn,is,X,xe,Me,Oe,Ke,We,rt,rn=!1;const bn=ne.drag;let Ve=bn.x,jt=bn.y;he&&(ne.x&&(Wn=lo(AT,o)),ne.y&&(xo=lo($T,o)),B.ori==0?(gi=Wn,Tn=xo):(gi=xo,Tn=Wn),We=ne.left,rt=ne.top);const xt=r.select=pr({show:!0,over:!0,left:0,width:0,top:0,height:0},e.select),ln=xt.show?lo(_T,xt.over?o:d):null;function mi(V,J){if(xt.show){for(let ae in V)xt[ae]=V[ae],ae in K&&Bn(ln,ae,V[ae]);J!==!1&&pt("setSelect")}}r.setSelect=mi;function qt(V){if(x[V].show)ue&&Id(Ae[V],da);else if(ue&&Ui(Ae[V],da),he){let J=mn?jn[0]:jn[V];J!=null&&Yo(J,-10,-10,mt,it)}}function ri(V,J,ae){Fe(V,{min:J,max:ae})}function yr(V,J,ae,ce){J.focus!=null&&Ea(V),J.show!=null&&x.forEach((ge,Se)=>{Se>0&&(V==Se||V==null)&&(ge.show=J.show,qt(Se),c==2?(ri(ge.facets[0].scale,null,null),ri(ge.facets[1].scale,null,null)):ri(ge.scale,null,null),Xi())}),ae!==!1&&pt("setSeries",V,J),ce&&Ot("setSeries",r,V,J)}r.setSeries=yr;function Wo(V,J){pr(_[V],J)}function eo(V,J){V.fill=en(V.fill||null),V.dir=gn(V.dir,-1),J=J??_.length,_.splice(J,0,V)}function Qn(V){V==null?_.length=0:_.splice(V,1)}r.addBand=eo,r.setBand=Wo,r.delBand=Qn;function Vs(V,J){x[V].alpha=J,he&&jn[V]!=null&&(jn[V].style.opacity=J),ue&&Ae[V]&&(Ae[V].style.opacity=J)}let sr,to,no;const Co={focus:!0};function Ea(V){if(V!=no){let J=V==null,ae=$r.alpha!=1;x.forEach((ce,ge)=>{if(c==1||ge>0){let Se=J||ge==0||ge==V;ce._focus=J?null:Se,ae&&Vs(ge,Se?1:$r.alpha)}}),no=V,ae&&Xi()}}ue&&Or&&St(Ay,ee,V=>{ne._lock||(Ii(V),no!=null&&yr(null,Co,!0,Rt.setSeries))});function xn(V,J,ae){let ce=T[J];ae&&(V=V/yn-(ce.ori==1?Fn:Gt));let ge=mt;ce.ori==1&&(ge=it,V=ge-V),ce.dir==-1&&(V=ge-V);let Se=ce._min,Le=ce._max,He=V/ge,qe=Se+(Le-Se)*He,Qe=ce.distr;return Qe==3?Za(10,qe):Qe==4?HT(qe,ce.asinh):Qe==100?ce.bwd(qe):qe}function bl(V,J){let ae=xn(V,C,J);return Ro(ae,n[0],fn,Kn)}r.valToIdx=V=>Ro(V,n[0]),r.posToIdx=bl,r.posToVal=xn,r.valToPos=(V,J,ae)=>T[J].ori==0?h(V,T[J],ae?dn:mt,ae?qn:0):g(V,T[J],ae?Pn:it,ae?tr:0),r.setCursor=(V,J,ae)=>{We=V.left,rt=V.top,S(null,J,ae)};function Sr(V,J){Bn(ln,Ka,xt.left=V),Bn(ln,Yl,xt.width=J)}function ii(V,J){Bn(ln,Jl,xt.top=V),Bn(ln,Kl,xt.height=J)}let os=B.ori==0?Sr:ii,Hr=B.ori==1?Sr:ii;function Di(){if(ue&&le.live)for(let V=c==2?1:0;V<x.length;V++){if(V==0&&Ye)continue;let J=le.values[V],ae=0;for(let ce in J)Je[V][ae++].firstChild.nodeValue=J[ce]}}function b(V,J){if(V!=null&&(V.idxs?V.idxs.forEach((ae,ce)=>{re[ce]=ae}):qT(V.idx)||re.fill(V.idx),le.idx=re[0]),ue&&le.live){for(let ae=0;ae<x.length;ae++)(ae>0||c==1&&!Ye)&&I(ae,re[ae]);Di()}vr=!1,J!==!1&&pt("setLegend")}r.setLegend=b;function I(V,J){let ae=x[V],ce=V==0&&N==2?nr:n[V],ge;Ye?ge=ae.values(r,V,J)??Ze:(ge=ae.value(r,J==null?null:ce[J],V,J),ge=ge==null?Ze:{_:ge}),le.values[V]=ge}function S(V,J,ae){Oe=We,Ke=rt,[We,rt]=ne.move(r,We,rt),ne.left=We,ne.top=rt,he&&(gi&&Yo(gi,_r(We),0,mt,it),Tn&&Yo(Tn,0,_r(rt),mt,it));let ce,ge=fn>Kn;sr=Mn,to=null;let Se=B.ori==0?mt:it,Le=B.ori==1?mt:it;if(We<0||Pt==0||ge){ce=ne.idx=null;for(let He=0;He<x.length;He++){let qe=jn[He];qe!=null&&Yo(qe,-10,-10,mt,it)}Or&&yr(null,Co,!0,V==null&&Rt.setSeries),le.live&&(re.fill(ce),vr=!0)}else{let He,qe,Qe;c==1&&(He=B.ori==0?We:rt,qe=xn(He,C),ce=ne.idx=Ro(qe,n[0],fn,Kn),Qe=M(n[0][ce],B,Se,0));let ot=-10,ft=-10,Mt=0,pn=0,Yt=!0,It="",At="";for(let bt=c==2?1:0;bt<x.length;bt++){let On=x[bt],Xn=re[bt],wr=Xn==null?null:c==1?n[bt][Xn]:n[bt][1][Xn],Cn=ne.dataIdx(r,bt,ce,qe),En=Cn==null?null:c==1?n[bt][Cn]:n[bt][1][Cn];if(vr=vr||En!=wr||Cn!=Xn,re[bt]=Cn,bt>0&&On.show){let be=Cn==null?-10:Cn==ce?Qe:M(c==1?n[0][Cn]:n[bt][0][Cn],B,Se,0),Re=En==null?-10:$(En,c==1?T[On.scale]:T[On.facets[1].scale],Le,0);if(Or&&En!=null){let Ee=B.ori==1?We:rt,Xe=kr($r.dist(r,bt,Cn,Re,Ee));if(Xe<sr){let _t=$r.bias;if(_t!=0){let Nt=xn(Ee,On.scale),vn=En>=0?1:-1,Kt=Nt>=0?1:-1;Kt==vn&&(Kt==1?_t==1?En>=Nt:En<=Nt:_t==1?En<=Nt:En>=Nt)&&(sr=Xe,to=bt)}else sr=Xe,to=bt}}if(vr||mn){let Ee,Xe;B.ori==0?(Ee=be,Xe=Re):(Ee=Re,Xe=be);let _t,Nt,vn,Kt,Pi,Ur,zn=!0,ko=Yn.bbox;if(ko!=null){zn=!1;let Vr=ko(r,bt);vn=Vr.left,Kt=Vr.top,_t=Vr.width,Nt=Vr.height}else vn=Ee,Kt=Xe,_t=Nt=Yn.size(r,bt);if(Ur=Yn.fill(r,bt),Pi=Yn.stroke(r,bt),mn)bt==to&&sr<=$r.prox&&(ot=vn,ft=Kt,Mt=_t,pn=Nt,Yt=zn,It=Ur,At=Pi);else{let Vr=jn[bt];Vr!=null&&(Mi[bt]=vn,hi[bt]=Kt,Ry(Vr,_t,Nt,zn),Iy(Vr,Ur,Pi),Yo(Vr,co(vn),co(Kt),mt,it))}}}}if(mn){let bt=$r.prox,On=no==null?sr<=bt:sr>bt||to!=no;if(vr||On){let Xn=jn[0];Xn!=null&&(Mi[0]=ot,hi[0]=ft,Ry(Xn,Mt,pn,Yt),Iy(Xn,It,At),Yo(Xn,co(ot),co(ft),mt,it))}}}if(xt.show&&rn)if(V!=null){let[He,qe]=Rt.scales,[Qe,ot]=Rt.match,[ft,Mt]=V.cursor.sync.scales,pn=V.cursor.drag;if(Ve=pn._x,jt=pn._y,Ve||jt){let{left:Yt,top:It,width:At,height:bt}=V.select,On=V.scales[ft].ori,Xn=V.posToVal,wr,Cn,En,be,Re,Ee=He!=null&&Qe(He,ft),Xe=qe!=null&&ot(qe,Mt);Ee&&Ve?(On==0?(wr=Yt,Cn=At):(wr=It,Cn=bt),En=T[He],be=M(Xn(wr,ft),En,Se,0),Re=M(Xn(wr+Cn,ft),En,Se,0),os(Lo(be,Re),kr(Re-be))):os(0,Se),Xe&&jt?(On==1?(wr=Yt,Cn=At):(wr=It,Cn=bt),En=T[qe],be=$(Xn(wr,Mt),En,Le,0),Re=$(Xn(wr+Cn,Mt),En,Le,0),Hr(Lo(be,Re),kr(Re-be))):Hr(0,Le)}else Z()}else{let He=kr(Oe-is),qe=kr(Ke-X);if(B.ori==1){let Mt=He;He=qe,qe=Mt}Ve=bn.x&&He>=bn.dist,jt=bn.y&&qe>=bn.dist;let Qe=bn.uni;Qe!=null?Ve&&jt&&(Ve=He>=Qe,jt=qe>=Qe,!Ve&&!jt&&(qe>He?jt=!0:Ve=!0)):bn.x&&bn.y&&(Ve||jt)&&(Ve=jt=!0);let ot,ft;Ve&&(B.ori==0?(ot=xe,ft=We):(ot=Me,ft=rt),os(Lo(ot,ft),kr(ft-ot)),jt||Hr(0,Le)),jt&&(B.ori==1?(ot=xe,ft=We):(ot=Me,ft=rt),Hr(Lo(ot,ft),kr(ft-ot)),Ve||os(0,Se)),!Ve&&!jt&&(os(0,0),Hr(0,0))}if(bn._x=Ve,bn._y=jt,V==null){if(ae){if(cn!=null){let[He,qe]=Rt.scales;Rt.values[0]=He!=null?xn(B.ori==0?We:rt,He):null,Rt.values[1]=qe!=null?xn(B.ori==1?We:rt,qe):null}Ot(Ad,r,We,rt,mt,it,ce)}if(Or){let He=ae&&Rt.setSeries,qe=$r.prox;no==null?sr<=qe&&yr(to,Co,!0,He):sr>qe?yr(null,Co,!0,He):to!=no&&yr(to,Co,!0,He)}}vr&&(le.idx=ce,b()),J!==!1&&pt("setCursor")}let z=null;Object.defineProperty(r,"rect",{get(){return z==null&&F(!1),z}});function F(V=!1){V?z=null:(z=o.getBoundingClientRect(),pt("syncRect",z))}function W(V,J,ae,ce,ge,Se,Le){ne._lock||rn&&V!=null&&V.movementX==0&&V.movementY==0||(G(V,J,ae,ce,ge,Se,Le,!1,V!=null),V!=null?S(null,!0,!0):S(J,!0,!1))}function G(V,J,ae,ce,ge,Se,Le,He,qe){if(z==null&&F(!1),Ii(V),V!=null)ae=V.clientX-z.left,ce=V.clientY-z.top;else{if(ae<0||ce<0){We=-10,rt=-10;return}let[Qe,ot]=Rt.scales,ft=J.cursor.sync,[Mt,pn]=ft.values,[Yt,It]=ft.scales,[At,bt]=Rt.match,On=J.axes[0].side%2==1,Xn=B.ori==0?mt:it,wr=B.ori==1?mt:it,Cn=On?Se:ge,En=On?ge:Se,be=On?ce:ae,Re=On?ae:ce;if(Yt!=null?ae=At(Qe,Yt)?v(Mt,T[Qe],Xn,0):-10:ae=Xn*(be/Cn),It!=null?ce=bt(ot,It)?v(pn,T[ot],wr,0):-10:ce=wr*(Re/En),B.ori==1){let Ee=ae;ae=ce,ce=Ee}}qe&&(J==null||J.cursor.event.type==Ad)&&((ae<=1||ae>=mt-1)&&(ae=ga(ae,mt)),(ce<=1||ce>=it-1)&&(ce=ga(ce,it))),He?(is=ae,X=ce,[xe,Me]=ne.move(r,ae,ce)):(We=ae,rt=ce)}const K={width:0,height:0,left:0,top:0};function Z(){mi(K,!1)}let se,de,ke,Te;function Ce(V,J,ae,ce,ge,Se,Le){rn=!0,Ve=jt=bn._x=bn._y=!1,G(V,J,ae,ce,ge,Se,Le,!0,!1),V!=null&&(St($d,Td,$e,!1),Ot(ky,r,xe,Me,mt,it,null));let{left:He,top:qe,width:Qe,height:ot}=xt;se=He,de=qe,ke=Qe,Te=ot}function $e(V,J,ae,ce,ge,Se,Le){rn=bn._x=bn._y=!1,G(V,J,ae,ce,ge,Se,Le,!1,!0);let{left:He,top:qe,width:Qe,height:ot}=xt,ft=Qe>0||ot>0,Mt=se!=He||de!=qe||ke!=Qe||Te!=ot;if(ft&&Mt&&mi(xt),bn.setScale&&ft&&Mt){let pn=He,Yt=Qe,It=qe,At=ot;if(B.ori==1&&(pn=qe,Yt=ot,It=He,At=Qe),Ve&&ri(C,xn(pn,C),xn(pn+Yt,C)),jt)for(let bt in T){let On=T[bt];bt!=C&&On.from==null&&On.min!=Mn&&ri(bt,xn(It+At,bt),xn(It,bt))}Z()}else ne.lock&&(ne._lock=!ne._lock,S(J,!0,V!=null));V!=null&&(Vt($d,Td),Ot($d,r,We,rt,mt,it,null))}function Be(V,J,ae,ce,ge,Se,Le){if(ne._lock)return;Ii(V);let He=rn;if(rn){let qe=!0,Qe=!0,ot=10,ft,Mt;B.ori==0?(ft=Ve,Mt=jt):(ft=jt,Mt=Ve),ft&&Mt&&(qe=We<=ot||We>=mt-ot,Qe=rt<=ot||rt>=it-ot),ft&&qe&&(We=We<xe?0:mt),Mt&&Qe&&(rt=rt<Me?0:it),S(null,!0,!0),rn=!1}We=-10,rt=-10,re.fill(null),S(null,!0,!0),He&&(rn=He)}function De(V,J,ae,ce,ge,Se,Le){ne._lock||(Ii(V),ws(),Z(),V!=null&&Ot($y,r,We,rt,mt,it,null))}function et(){R.forEach(cI),Ji(r.width,r.height,!0)}fa(lu,Qa,et);const kt={};kt.mousedown=Ce,kt.mousemove=W,kt.mouseup=$e,kt.dblclick=De,kt.setSeries=(V,J,ae,ce)=>{let ge=Rt.match[2];ae=ge(r,J,ae),ae!=-1&&yr(ae,ce,!0,!1)},he&&(St(ky,o,Ce),St(Ad,o,W),St(_y,o,V=>{Ii(V),F(!1)}),St(Ay,o,Be),St($y,o,De),Zd.add(r),r.syncRect=F);const ut=r.hooks=e.hooks||{};function pt(V,J,ae){jo?Wr.push([V,J,ae]):V in ut&&ut[V].forEach(ce=>{ce.call(null,r,J,ae)})}(e.plugins||[]).forEach(V=>{for(let J in V.hooks)ut[J]=(ut[J]||[]).concat(V.hooks[J])});const Hn=(V,J,ae)=>ae,Rt=pr({key:null,setSeries:!1,filters:{pub:Uy,sub:Uy},scales:[C,x[1]?x[1].scale:null],match:[Vy,Vy,Hn],values:[null,null]},ne.sync);Rt.match.length==2&&Rt.match.push(Hn),ne.sync=Rt;const cn=Rt.key,Bt=Eb(cn);function Ot(V,J,ae,ce,ge,Se,Le){Rt.filters.pub(V,J,ae,ce,ge,Se,Le)&&Bt.pub(V,J,ae,ce,ge,Se,Le)}Bt.sub(r);function br(V,J,ae,ce,ge,Se,Le){Rt.filters.sub(V,J,ae,ce,ge,Se,Le)&&kt[V](null,J,ae,ce,ge,Se,Le)}r.pub=br;function Tr(){Bt.unsub(r),Zd.delete(r),Ct.clear(),Rd(lu,Qa,et),p.remove(),ee?.remove(),pt("destroy")}r.destroy=Tr;function Zn(){pt("init",e,n),Li(n||e.data,!1),A[C]?Fe(C,A[C]):ws(),fo=xt.show&&(xt.width>0||xt.height>0),Ei=vr=!0,Ji(e.width,e.height)}return x.forEach(vs),R.forEach(Ri),t?t instanceof HTMLElement?(t.appendChild(p),Zn()):t(r,Zn):Zn(),r}Jr.assign=pr,Jr.fmtNum=Nd,Jr.rangeNum=du,Jr.rangeLog=hu,Jr.rangeAsinh=Ld,Jr.orient=va,Jr.pxRatio=yn,Jr.join=eE,Jr.fmtDate=Bd,Jr.tzDate=hE,Jr.sync=Eb;{Jr.addGap=qE,Jr.clipGaps=bu;let e=Jr.paths={points:Db};e.linear=zb,e.stepped=JE,e.bars=QE,e.spline=XE}var Gb,qb;function uI(){return qb||(qb=1,Gb=function(e,n,t,r,c){var h,g;if(r===void 0)r=0;else if(r=r|0,r<0||r>=e.length)throw new RangeError("invalid lower bound");if(c===void 0)c=e.length-1;else if(c=c|0,c<r||c>=e.length)throw new RangeError("invalid upper bound");for(;r<=c;)if(h=r+(c-r>>>1),g=+t(e[h],n,h,e),g<0)r=h+1;else if(g>0)c=h-1;else return h;return~r}),Gb}var hI=uI();const x3=lr("y",su(hI));var ef,Yb;function dI(){if(Yb)return ef;Yb=1;function e(n,t,r){var c=-1,h=n.length;t<0&&(t=-t>h?0:h+t),r=r>h?h:r,r<0&&(r+=h),h=t>r?0:r-t>>>0,t>>>=0;for(var g=Array(h);++c<h;)g[c]=n[c+t];return g}return ef=e,ef}var tf,Kb;function fI(){if(Kb)return tf;Kb=1;var e=dI();function n(t,r,c){var h=t.length;return c=c===void 0?h:c,!r&&c>=h?t:e(t,r,c)}return tf=n,tf}var nf,Jb;function Qb(){if(Jb)return nf;Jb=1;var e="\\ud800-\\udfff",n="\\u0300-\\u036f",t="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",c=n+t+r,h="\\ufe0e\\ufe0f",g="\\u200d",v=RegExp("["+g+e+c+h+"]");function s(p){return v.test(p)}return nf=s,nf}var rf,Zb;function pI(){if(Zb)return rf;Zb=1;function e(n){return n.split("")}return rf=e,rf}var of,Xb;function gI(){if(Xb)return of;Xb=1;var e="\\ud800-\\udfff",n="\\u0300-\\u036f",t="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",c=n+t+r,h="\\ufe0e\\ufe0f",g="["+e+"]",v="["+c+"]",s="\\ud83c[\\udffb-\\udfff]",p="(?:"+v+"|"+s+")",a="[^"+e+"]",l="(?:\\ud83c[\\udde6-\\uddff]){2}",u="[\\ud800-\\udbff][\\udc00-\\udfff]",d="\\u200d",o=p+"?",f="["+h+"]?",m="(?:"+d+"(?:"+[a,l,u].join("|")+")"+f+o+")*",w=f+o+m,x="(?:"+[a+v+"?",v,l,u,g].join("|")+")",R=RegExp(s+"(?="+s+")|"+x+w,"g");function T(_){return _.match(R)||[]}return of=T,of}var sf,e0;function mI(){if(e0)return sf;e0=1;var e=pI(),n=Qb(),t=gI();function r(c){return n(c)?t(c):e(c)}return sf=r,sf}var af,t0;function vI(){if(t0)return af;t0=1;var e=typeof Ps=="object"&&Ps&&Ps.Object===Object&&Ps;return af=e,af}var lf,n0;function yI(){if(n0)return lf;n0=1;var e=vI(),n=typeof self=="object"&&self&&self.Object===Object&&self,t=e||n||Function("return this")();return lf=t,lf}var cf,r0;function uf(){if(r0)return cf;r0=1;var e=yI(),n=e.Symbol;return cf=n,cf}var hf,i0;function bI(){if(i0)return hf;i0=1;function e(n,t){for(var r=-1,c=n==null?0:n.length,h=Array(c);++r<c;)h[r]=t(n[r],r,n);return h}return hf=e,hf}var df,o0;function wI(){if(o0)return df;o0=1;var e=Array.isArray;return df=e,df}var ff,s0;function xI(){if(s0)return ff;s0=1;var e=uf(),n=Object.prototype,t=n.hasOwnProperty,r=n.toString,c=e?e.toStringTag:void 0;function h(g){var v=t.call(g,c),s=g[c];try{g[c]=void 0;var p=!0}catch{}var a=r.call(g);return p&&(v?g[c]=s:delete g[c]),a}return ff=h,ff}var pf,a0;function CI(){if(a0)return pf;a0=1;var e=Object.prototype,n=e.toString;function t(r){return n.call(r)}return pf=t,pf}var gf,l0;function kI(){if(l0)return gf;l0=1;var e=uf(),n=xI(),t=CI(),r="[object Null]",c="[object Undefined]",h=e?e.toStringTag:void 0;function g(v){return v==null?v===void 0?c:r:h&&h in Object(v)?n(v):t(v)}return gf=g,gf}var mf,c0;function _I(){if(c0)return mf;c0=1;function e(n){return n!=null&&typeof n=="object"}return mf=e,mf}var vf,u0;function AI(){if(u0)return vf;u0=1;var e=kI(),n=_I(),t="[object Symbol]";function r(c){return typeof c=="symbol"||n(c)&&e(c)==t}return vf=r,vf}var yf,h0;function $I(){if(h0)return yf;h0=1;var e=uf(),n=bI(),t=wI(),r=AI(),c=e?e.prototype:void 0,h=c?c.toString:void 0;function g(v){if(typeof v=="string")return v;if(t(v))return n(v,g)+"";if(r(v))return h?h.call(v):"";var s=v+"";return s=="0"&&1/v==-1/0?"-0":s}return yf=g,yf}var bf,d0;function ku(){if(d0)return bf;d0=1;var e=$I();function n(t){return t==null?"":e(t)}return bf=n,bf}var wf,f0;function SI(){if(f0)return wf;f0=1;var e=fI(),n=Qb(),t=mI(),r=ku();function c(h){return function(g){g=r(g);var v=n(g)?t(g):void 0,s=v?v[0]:g.charAt(0),p=v?e(v,1).join(""):g.slice(1);return s[h]()+p}}return wf=c,wf}var xf,p0;function g0(){if(p0)return xf;p0=1;var e=SI(),n=e("toUpperCase");return xf=n,xf}var TI=g0();const EI=su(TI);var Cf,m0;function II(){if(m0)return Cf;m0=1;var e=ku(),n=g0();function t(r){return n(e(r).toLowerCase())}return Cf=t,Cf}var kf,v0;function MI(){if(v0)return kf;v0=1;function e(n,t,r,c){var h=-1,g=n==null?0:n.length;for(c&&g&&(r=n[++h]);++h<g;)r=t(r,n[h],h,n);return r}return kf=e,kf}var _f,y0;function RI(){if(y0)return _f;y0=1;function e(n){return function(t){return n?.[t]}}return _f=e,_f}var Af,b0;function LI(){if(b0)return Af;b0=1;var e=RI(),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"},t=e(n);return Af=t,Af}var $f,w0;function OI(){if(w0)return $f;w0=1;var e=LI(),n=ku(),t=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,r="\\u0300-\\u036f",c="\\ufe20-\\ufe2f",h="\\u20d0-\\u20ff",g=r+c+h,v="["+g+"]",s=RegExp(v,"g");function p(a){return a=n(a),a&&a.replace(t,e).replace(s,"")}return $f=p,$f}var Sf,x0;function NI(){if(x0)return Sf;x0=1;var e=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function n(t){return t.match(e)||[]}return Sf=n,Sf}var Tf,C0;function DI(){if(C0)return Tf;C0=1;var e=/[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(t){return e.test(t)}return Tf=n,Tf}var Ef,k0;function PI(){if(k0)return Ef;k0=1;var e="\\ud800-\\udfff",n="\\u0300-\\u036f",t="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",c=n+t+r,h="\\u2700-\\u27bf",g="a-z\\xdf-\\xf6\\xf8-\\xff",v="\\xac\\xb1\\xd7\\xf7",s="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",p="\\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",u="\\ufe0e\\ufe0f",d=v+s+p+a,o="['’]",f="["+d+"]",m="["+c+"]",w="\\d+",x="["+h+"]",R="["+g+"]",T="[^"+e+d+w+h+g+l+"]",_="\\ud83c[\\udffb-\\udfff]",C="(?:"+m+"|"+_+")",P="[^"+e+"]",O="(?:\\ud83c[\\udde6-\\uddff]){2}",E="[\\ud800-\\udbff][\\udc00-\\udfff]",k="["+l+"]",B="\\u200d",N="(?:"+R+"|"+T+")",M="(?:"+k+"|"+T+")",$="(?:"+o+"(?:d|ll|m|re|s|t|ve))?",A="(?:"+o+"(?:D|LL|M|RE|S|T|VE))?",D=C+"?",j="["+u+"]?",U="(?:"+B+"(?:"+[P,O,E].join("|")+")"+j+D+")*",q="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Q="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",re=j+D+U,le="(?:"+[x,O,E].join("|")+")"+re,ne=RegExp([k+"?"+R+"+"+$+"(?="+[f,k,"$"].join("|")+")",M+"+"+A+"(?="+[f,k+N,"$"].join("|")+")",k+"?"+N+"+"+$,k+"+"+A,Q,q,w,le].join("|"),"g");function ue(he){return he.match(ne)||[]}return Ef=ue,Ef}var If,_0;function zI(){if(_0)return If;_0=1;var e=NI(),n=DI(),t=ku(),r=PI();function c(h,g,v){return h=t(h),g=v?void 0:g,g===void 0?n(h)?r(h):e(h):h.match(g)||[]}return If=c,If}var Mf,A0;function BI(){if(A0)return Mf;A0=1;var e=MI(),n=OI(),t=zI(),r="['’]",c=RegExp(r,"g");function h(g){return function(v){return e(t(n(v).replace(c,"")),g,"")}}return Mf=h,Mf}var Rf,$0;function FI(){if($0)return Rf;$0=1;var e=II(),n=BI(),t=n(function(r,c,h){return c=c.toLowerCase(),r+(h?e(c):c)});return Rf=t,Rf}var jI=FI();const WI=su(jI),HI=Object.assign({"./ArrayWidget.vue":()=>dt(()=>ht.import("./ArrayWidget-9OSo49r--717a71fa5a93a4306ec7.js"),void 0),"./ArrayplotWidget.vue":()=>dt(()=>ht.import("./ArrayplotWidget-D5C_WTX2-8ef1f79db3f1944b9c0b.js"),void 0),"./BlockWidget.vue":()=>dt(()=>ht.import("./BlockWidget-DuEDZ4dJ-967eda15c1451fca34fa.js"),void 0),"./ButtonWidget.vue":()=>dt(()=>ht.import("./ButtonWidget-CZIUtd9z-61acef92520109286c0d.js"),void 0),"./CanvasWidget.vue":()=>dt(()=>ht.import("./CanvasWidget-C4-pXiKY-264004bbfd5904f1e69d.js"),void 0),"./CanvasdotWidget.vue":()=>dt(()=>ht.import("./CanvasdotWidget-Bh0HHx67-b6476c69d59257ab08bc.js"),void 0),"./CanvasimageWidget.vue":()=>dt(()=>ht.import("./CanvasimageWidget-Bu5NmsDs-cda2f1f9742ea195853b.js"),void 0),"./CanvasimagevalueWidget.vue":()=>dt(()=>ht.import("./CanvasimagevalueWidget-Dv8dQrnj-0b0689a4caece450db22.js"),void 0),"./CanvaslabelWidget.vue":()=>dt(()=>ht.import("./CanvaslabelWidget-68IeeM3a-d8ee974f80ae555b6320.js"),void 0),"./CanvaslabelvalueWidget.vue":()=>dt(()=>ht.import("./CanvaslabelvalueWidget-C6j_A4z6-2d9163c26db0115868c1.js"),void 0),"./CanvaslineWidget.vue":()=>dt(()=>ht.import("./CanvaslineWidget-BgQ6wLDv-6f3059055f7afe642488.js"),void 0),"./CanvaslinevalueWidget.vue":()=>dt(()=>ht.import("./CanvaslinevalueWidget-C6-HkTJp-5717f7b45d0b57a344a4.js"),void 0),"./CheckbuttonWidget.vue":()=>dt(()=>ht.import("./CheckbuttonWidget-DJmT73t9-dc118daa630bbe52aa2d.js"),void 0),"./ComboboxWidget.vue":()=>dt(()=>ht.import("./ComboboxWidget-vTtsjxRm-a15e957bce84abaae94e.js"),void 0),"./DateWidget.vue":()=>dt(()=>ht.import("./DateWidget-BjKIDtsf-a0a25d555d3032f182ea.js"),void 0),"./DynamicWidget.vue":()=>dt(()=>ht.import("./DynamicWidget-yna_ejyc-303515b4f32d2d98c6ee.js"),void 0),"./FilechecksumWidget.vue":()=>dt(()=>ht.import("./FilechecksumWidget-obppYSP4-700a6df90c74ce721080.js"),void 0),"./FiledisplayWidget.vue":()=>dt(()=>ht.import("./FiledisplayWidget-BstroKFo-1648b09c912608be064e.js"),void 0),"./FormatvalueWidget.vue":()=>dt(()=>ht.import("./FormatvalueWidget-MJIJg6Bf-0cd3eaea15a6bcd3ae72.js"),void 0),"./HorizontalWidget.vue":()=>dt(()=>ht.import("./HorizontalWidget-Cn9qnYVh-badf3d172451b91a6d6f.js"),void 0),"./HorizontalboxWidget.vue":()=>dt(()=>ht.import("./HorizontalboxWidget-gz8uYYFZ-96c1c64165978ab6eb9e.js"),void 0),"./HorizontallineWidget.vue":()=>dt(()=>ht.import("./HorizontallineWidget-CrDua5-L-debe3a4eea3dca880b37.js"),void 0),"./IframeWidget.vue":()=>dt(()=>ht.import("./IframeWidget-CtS7MjKL-d9da1888b15c35e9c70b.js"),void 0),"./ImageviewerWidget.vue":()=>dt(()=>ht.import("./ImageviewerWidget-Kmzt8wuP-cc3b7e2f8ed939331fe4.js"),void 0),"./LabelWidget.vue":()=>dt(()=>ht.import("./LabelWidget-DIZpHxYX-271eae93ef3508c18934.js"),void 0),"./LabelledWidget.vue":()=>dt(()=>ht.import("./LabelledWidget-CGxDI8XZ-eaf078ad95a37f4eeb80.js"),void 0),"./LabelprogressbarWidget.vue":()=>dt(()=>ht.import("./LabelprogressbarWidget-CXOc5p8G-b43b9d95abd873ade105.js"),void 0),"./LabelsparklineWidget.vue":()=>dt(()=>ht.import("./LabelsparklineWidget-B_LuqFcA-1606a15bb9d50691d10e.js"),void 0),"./LabelvalueWidget.vue":()=>dt(()=>ht.import("./LabelvalueWidget--G4wHMZL-160516ab83399994b95e.js"),void 0),"./LabelvaluedescWidget.vue":()=>dt(()=>ht.import("./LabelvaluedescWidget-DqLK0wvi-b6d7c8ef799c34a4fb16.js"),void 0),"./LabelvaluelimitsbarWidget.vue":()=>dt(()=>ht.import("./LabelvaluelimitsbarWidget-BWOQJkLP-e669bc66e0d31684a5b1.js"),void 0),"./LabelvaluelimitscolumnWidget.vue":()=>dt(()=>ht.import("./LabelvaluelimitscolumnWidget-BfF73Y2F-191505c7e8b4e463139d.js"),void 0),"./LabelvaluerangebarWidget.vue":()=>dt(()=>ht.import("./LabelvaluerangebarWidget-CKsFRW6t-5d1f6dbda4b998ccdabd.js"),void 0),"./LedWidget.vue":()=>dt(()=>ht.import("./LedWidget-DrAJ8_fN-c3588bb9b46e0569d22d.js"),void 0),"./LimitsbarWidget.vue":()=>dt(()=>ht.import("./LimitsbarWidget-1IayV5D7-e6979d0bff067d206a17.js"),void 0),"./LimitscolorWidget.vue":()=>dt(()=>ht.import("./LimitscolorWidget-C7LY3BQ7-a99b7c32677dc6dd0e0c.js"),void 0),"./LimitscolumnWidget.vue":()=>dt(()=>ht.import("./LimitscolumnWidget-JhIc5Sjl-3b17971ca7ecfc14b21e.js"),void 0),"./LinegraphWidget.vue":()=>dt(()=>ht.import("./LinegraphWidget-BaROxuUn-59d99dd742687e40b25c.js"),void 0),"./MatrixbycolumnsWidget.vue":()=>dt(()=>ht.import("./MatrixbycolumnsWidget-i0gGPMOV-10eb0a46073fb0d00269.js"),void 0),"./ProgressbarWidget.vue":()=>dt(()=>ht.import("./ProgressbarWidget-QxEq8C4A-6708ed1493b466f3ad73.js"),void 0),"./RadiobuttonWidget.vue":()=>dt(()=>ht.import("./RadiobuttonWidget-DYf3qvBq-c45fbd59c85839b1c318.js"),void 0),"./RadiogroupWidget.vue":()=>dt(()=>ht.import("./RadiogroupWidget-C0b_ckej-49f9b3ab6551820edc3b.js"),void 0),"./RangebarWidget.vue":()=>dt(()=>ht.import("./RangebarWidget-DcSEHktI-3e039851d9a494b6e2ae.js"),void 0),"./RollupWidget.vue":()=>dt(()=>ht.import("./RollupWidget-AVS4drYX-b0a691257195289fcde6.js"),void 0),"./ScrollwindowWidget.vue":()=>dt(()=>ht.import("./ScrollwindowWidget-Dpf3BScA-1f5fbe37bb33cad8cf87.js"),void 0),"./SignalWidget.vue":()=>dt(()=>ht.import("./SignalWidget-Q1YtPsNw-e755da3f6cb293fbfb21.js"),void 0),"./SpacerWidget.vue":()=>dt(()=>ht.import("./SpacerWidget-DGEOqhu_-b6e91ca4474e9fced162.js"),void 0),"./SparklineWidget.vue":()=>dt(()=>ht.import("./SparklineWidget-DbNWbNzY-7b515c109437aabe3fd7.js"),void 0),"./TabbookWidget.vue":()=>dt(()=>ht.import("./TabbookWidget-CrkPPZIF-e6f81964bd00b58621c6.js"),void 0),"./TextboxWidget.vue":()=>dt(()=>ht.import("./TextboxWidget-CfQEzaRr-e866fabef32754083217.js"),void 0),"./TextfieldWidget.vue":()=>dt(()=>ht.import("./TextfieldWidget-BQL8dOTg-c36896326e3dd7157a9b.js"),void 0),"./TimeWidget.vue":()=>dt(()=>ht.import("./TimeWidget-DiE_oc7J-bb6ed7460bd103205f07.js"),void 0),"./TitleWidget.vue":()=>dt(()=>ht.import("./TitleWidget-C5a_ZsqM-2cd2d562e7df0e7c2632.js"),void 0),"./ValueWidget.vue":()=>dt(()=>ht.import("./ValueWidget-9JNo-Sk8-ad0f7e86109c8aa425a5.js"),void 0),"./ValuelimitsbarWidget.vue":()=>dt(()=>ht.import("./ValuelimitsbarWidget-CqiFVnaT-548886eac7b4e05b16a7.js"),void 0),"./ValuelimitscolumnWidget.vue":()=>dt(()=>ht.import("./ValuelimitscolumnWidget-DWDFVRNg-27123b8e5c3ac13ee8c8.js"),void 0),"./ValuerangebarWidget.vue":()=>dt(()=>ht.import("./ValuerangebarWidget-BAVMrD0L-ab4e3bf7f05c9ddde140.js"),void 0),"./VerticalWidget.vue":()=>dt(()=>ht.import("./VerticalWidget-Dw0j42K2-a0e847b1aea8f4d4919f.js"),void 0),"./VerticalboxWidget.vue":()=>dt(()=>ht.import("./VerticalboxWidget-xusQtXo0-16edecad2b21c8c04312.js"),void 0)}),UI=Object.entries(HI).reduce((e,[n,t])=>{n=n.split("/").pop();const r=EI(WI(n.replace(/\.\w+$/,"")));return{...e,[r]:jg(t)}},{}),C3=lr("w",{components:UI});function S0(){return Object.assign({},Ga())}function VI(e,n,t){const r=li(e,t?.in);return r.setTime(r.getTime()+n*ou),r}function GI(e,n){const t=()=>qo(n?.in,NaN),r=JI(e);let c;if(r.date){const s=QI(r.date,2);c=ZI(s.restDateString,s.year)}if(!c||isNaN(+c))return t();const h=+c;let g=0,v;if(r.time&&(g=XI(r.time),isNaN(g)))return t();if(r.timezone){if(v=eM(r.timezone),isNaN(v))return t()}else{const s=new Date(h+g),p=li(0,n?.in);return p.setFullYear(s.getUTCFullYear(),s.getUTCMonth(),s.getUTCDate()),p.setHours(s.getUTCHours(),s.getUTCMinutes(),s.getUTCSeconds(),s.getUTCMilliseconds()),p}return li(h+g+v,n?.in)}const _u={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},qI=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,YI=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,KI=/^([+-])(\d{2})(?::?(\d{2}))?$/;function JI(e){const n={},t=e.split(_u.dateTimeDelimiter);let r;if(t.length>2)return n;if(/:/.test(t[0])?r=t[0]:(n.date=t[0],r=t[1],_u.timeZoneDelimiter.test(n.date)&&(n.date=e.split(_u.timeZoneDelimiter)[0],r=e.substr(n.date.length,e.length))),r){const c=_u.timezone.exec(r);c?(n.time=r.replace(c[1],""),n.timezone=c[1]):n.time=r}return n}function QI(e,n){const t=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+n)+"})|(\\d{2}|[+-]\\d{"+(2+n)+"})$)"),r=e.match(t);if(!r)return{year:NaN,restDateString:""};const c=r[1]?parseInt(r[1]):null,h=r[2]?parseInt(r[2]):null;return{year:h===null?c:h*100,restDateString:e.slice((r[1]||r[2]).length)}}function ZI(e,n){if(n===null)return new Date(NaN);const t=e.match(qI);if(!t)return new Date(NaN);const r=!!t[4],c=nc(t[1]),h=nc(t[2])-1,g=nc(t[3]),v=nc(t[4]),s=nc(t[5])-1;if(r)return oM(n,v,s)?tM(n,v,s):new Date(NaN);{const p=new Date(0);return!rM(n,h,g)||!iM(n,c)?new Date(NaN):(p.setUTCFullYear(n,h,Math.max(c,g)),p)}}function nc(e){return e?parseInt(e):1}function XI(e){const n=e.match(YI);if(!n)return NaN;const t=Lf(n[1]),r=Lf(n[2]),c=Lf(n[3]);return sM(t,r,c)?t*bd+r*ou+c*1e3:NaN}function Lf(e){return e&&parseFloat(e.replace(",","."))||0}function eM(e){if(e==="Z")return 0;const n=e.match(KI);if(!n)return 0;const t=n[1]==="+"?-1:1,r=parseInt(n[2]),c=n[3]&&parseInt(n[3])||0;return aM(r,c)?t*(r*bd+c*ou):NaN}function tM(e,n,t){const r=new Date(0);r.setUTCFullYear(e,0,4);const c=r.getUTCDay()||7,h=(n-1)*7+t+1-c;return r.setUTCDate(r.getUTCDate()+h),r}const nM=[31,null,31,30,31,30,31,31,30,31,30,31];function T0(e){return e%400===0||e%4===0&&e%100!==0}function rM(e,n,t){return n>=0&&n<=11&&t>=1&&t<=(nM[n]||(T0(e)?29:28))}function iM(e,n){return n>=1&&n<=(T0(e)?366:365)}function oM(e,n,t){return n>=1&&n<=53&&t>=0&&t<=6}function sM(e,n,t){return e===24?n===0&&t===0:t>=0&&t<60&&n>=0&&n<60&&e>=0&&e<25}function aM(e,n){return n>=0&&n<=59}function lM(e,n,t){return VI(e,-n,t)}function E0(e,n,t){const r=S0(),c=hM(e,t.timeZone,t.locale??r.locale);return"formatToParts"in c?cM(c,n):uM(c,n)}function cM(e,n){const t=e.formatToParts(n);for(let r=t.length-1;r>=0;--r)if(t[r].type==="timeZoneName")return t[r].value}function uM(e,n){const t=e.format(n).replace(/\u200E/g,""),r=/ [\w-+ ]+$/.exec(t);return r?r[0].substr(1):""}function hM(e,n,t){return new Intl.DateTimeFormat(t?[t.code,"en-US"]:void 0,{timeZone:n,timeZoneName:e})}function dM(e,n){const t=vM(n);return"formatToParts"in t?pM(t,e):gM(t,e)}const fM={year:0,month:1,day:2,hour:3,minute:4,second:5};function pM(e,n){try{const t=e.formatToParts(n),r=[];for(let c=0;c<t.length;c++){const h=fM[t[c].type];h!==void 0&&(r[h]=parseInt(t[c].value,10))}return r}catch(t){if(t instanceof RangeError)return[NaN];throw t}}function gM(e,n){const t=e.format(n),r=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(t);return[parseInt(r[3],10),parseInt(r[1],10),parseInt(r[2],10),parseInt(r[4],10),parseInt(r[5],10),parseInt(r[6],10)]}const Of={},I0=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")),mM=I0==="06/25/2014, 00:00:00"||I0==="‎06‎/‎25‎/‎2014‎ ‎00‎:‎00‎:‎00";function vM(e){return Of[e]||(Of[e]=mM?new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})),Of[e]}function M0(e,n,t,r,c,h,g){const v=new Date(0);return v.setUTCFullYear(e,n,t),v.setUTCHours(r,c,h,g),v}const R0=36e5,yM=6e4,Nf={timezoneZ:/^(Z)$/,timezoneHH:/^([+-]\d{2})$/,timezoneHHMM:/^([+-])(\d{2}):?(\d{2})$/};function Df(e,n,t){if(!e)return 0;let r=Nf.timezoneZ.exec(e);if(r)return 0;let c,h;if(r=Nf.timezoneHH.exec(e),r)return c=parseInt(r[1],10),L0(c)?-(c*R0):NaN;if(r=Nf.timezoneHHMM.exec(e),r){c=parseInt(r[2],10);const g=parseInt(r[3],10);return L0(c,g)?(h=Math.abs(c)*R0+g*yM,r[1]==="+"?-h:h):NaN}if(xM(e)){n=new Date(n||Date.now());const g=t?n:bM(n),v=Pf(g,e);return-(t?v:wM(n,v,e))}return NaN}function bM(e){return M0(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}function Pf(e,n){const t=dM(e,n),r=M0(t[0],t[1]-1,t[2],t[3]%24,t[4],t[5],0).getTime();let c=e.getTime();const h=c%1e3;return c-=h>=0?h:1e3+h,r-c}function wM(e,n,t){let r=e.getTime()-n;const c=Pf(new Date(r),t);if(n===c)return n;r-=c-n;const h=Pf(new Date(r),t);return c===h?c:Math.max(c,h)}function L0(e,n){return-23<=e&&e<=23&&(n==null||0<=n&&n<=59)}const O0={};function xM(e){if(O0[e])return!0;try{return new Intl.DateTimeFormat(void 0,{timeZone:e}),O0[e]=!0,!0}catch{return!1}}const CM=60*1e3,kM={X:function(e,n,t){const r=zf(t.timeZone,e);if(r===0)return"Z";switch(n){case"X":return N0(r);case"XXXX":case"XX":return ol(r);default:return ol(r,":")}},x:function(e,n,t){const r=zf(t.timeZone,e);switch(n){case"x":return N0(r);case"xxxx":case"xx":return ol(r);default:return ol(r,":")}},O:function(e,n,t){const r=zf(t.timeZone,e);switch(n){case"O":case"OO":case"OOO":return"GMT"+_M(r,":");default:return"GMT"+ol(r,":")}},z:function(e,n,t){switch(n){case"z":case"zz":case"zzz":return E0("short",e,t);default:return E0("long",e,t)}}};function zf(e,n){const t=e?Df(e,n,!0)/CM:n?.getTimezoneOffset()??0;if(Number.isNaN(t))throw new RangeError("Invalid time zone specified: "+e);return t}function Au(e,n){const t=e<0?"-":"";let r=Math.abs(e).toString();for(;r.length<n;)r="0"+r;return t+r}function ol(e,n=""){const t=e>0?"-":"+",r=Math.abs(e),c=Au(Math.floor(r/60),2),h=Au(Math.floor(r%60),2);return t+c+n+h}function N0(e,n){return e%60===0?(e>0?"-":"+")+Au(Math.abs(e)/60,2):ol(e,n)}function _M(e,n=""){const t=e>0?"-":"+",r=Math.abs(e),c=Math.floor(r/60),h=r%60;return h===0?t+String(c):t+String(c)+n+Au(h,2)}function D0(e){const n=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return n.setUTCFullYear(e.getFullYear()),+e-+n}const AM=/(Z|[+-]\d{2}(?::?\d{2})?| UTC| [a-zA-Z]+\/[a-zA-Z_]+(?:\/[a-zA-Z_]+)?)$/,Bf=36e5,P0=6e4,$M=2,ui={dateTimePattern:/^([0-9W+-]+)(T| )(.*)/,datePattern:/^([0-9W+-]+)(.*)/,YY:/^(\d{2})$/,YYY:[/^([+-]\d{2})$/,/^([+-]\d{3})$/,/^([+-]\d{4})$/],YYYY:/^(\d{4})/,YYYYY:[/^([+-]\d{4})/,/^([+-]\d{5})/,/^([+-]\d{6})/],MM:/^-(\d{2})$/,DDD:/^-?(\d{3})$/,MMDD:/^-?(\d{2})-?(\d{2})$/,Www:/^-?W(\d{2})$/,WwwD:/^-?W(\d{2})-?(\d{1})$/,HH:/^(\d{2}([.,]\d*)?)$/,HHMM:/^(\d{2}):?(\d{2}([.,]\d*)?)$/,HHMMSS:/^(\d{2}):?(\d{2}):?(\d{2}([.,]\d*)?)$/,timeZone:AM};function z0(e,n={}){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");if(e===null)return new Date(NaN);const t=n.additionalDigits==null?$M:Number(n.additionalDigits);if(t!==2&&t!==1&&t!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]")return new Date(e.getTime());if(typeof e=="number"||Object.prototype.toString.call(e)==="[object Number]")return new Date(e);if(Object.prototype.toString.call(e)!=="[object String]")return new Date(NaN);const r=SM(e),{year:c,restDateString:h}=TM(r.date,t),g=EM(h,c);if(g===null||isNaN(g.getTime()))return new Date(NaN);if(g){const v=g.getTime();let s=0,p;if(r.time&&(s=IM(r.time),s===null||isNaN(s)))return new Date(NaN);if(r.timeZone||n.timeZone){if(p=Df(r.timeZone||n.timeZone,new Date(v+s)),isNaN(p))return new Date(NaN)}else p=D0(new Date(v+s)),p=D0(new Date(v+s+p));return new Date(v+s+p)}else return new Date(NaN)}function SM(e){const n={};let t=ui.dateTimePattern.exec(e),r;if(t?(n.date=t[1],r=t[3]):(t=ui.datePattern.exec(e),t?(n.date=t[1],r=t[2]):(n.date=null,r=e)),r){const c=ui.timeZone.exec(r);c?(n.time=r.replace(c[1],""),n.timeZone=c[1].trim()):n.time=r}return n}function TM(e,n){if(e){const t=ui.YYY[n],r=ui.YYYYY[n];let c=ui.YYYY.exec(e)||r.exec(e);if(c){const h=c[1];return{year:parseInt(h,10),restDateString:e.slice(h.length)}}if(c=ui.YY.exec(e)||t.exec(e),c){const h=c[1];return{year:parseInt(h,10)*100,restDateString:e.slice(h.length)}}}return{year:null}}function EM(e,n){if(n===null)return null;let t,r,c;if(!e||!e.length)return t=new Date(0),t.setUTCFullYear(n),t;let h=ui.MM.exec(e);if(h)return t=new Date(0),r=parseInt(h[1],10)-1,j0(n,r)?(t.setUTCFullYear(n,r),t):new Date(NaN);if(h=ui.DDD.exec(e),h){t=new Date(0);const g=parseInt(h[1],10);return LM(n,g)?(t.setUTCFullYear(n,0,g),t):new Date(NaN)}if(h=ui.MMDD.exec(e),h){t=new Date(0),r=parseInt(h[1],10)-1;const g=parseInt(h[2],10);return j0(n,r,g)?(t.setUTCFullYear(n,r,g),t):new Date(NaN)}if(h=ui.Www.exec(e),h)return c=parseInt(h[1],10)-1,W0(c)?B0(n,c):new Date(NaN);if(h=ui.WwwD.exec(e),h){c=parseInt(h[1],10)-1;const g=parseInt(h[2],10)-1;return W0(c,g)?B0(n,c,g):new Date(NaN)}return null}function IM(e){let n,t,r=ui.HH.exec(e);if(r)return n=parseFloat(r[1].replace(",",".")),Ff(n)?n%24*Bf:NaN;if(r=ui.HHMM.exec(e),r)return n=parseInt(r[1],10),t=parseFloat(r[2].replace(",",".")),Ff(n,t)?n%24*Bf+t*P0:NaN;if(r=ui.HHMMSS.exec(e),r){n=parseInt(r[1],10),t=parseInt(r[2],10);const c=parseFloat(r[3].replace(",","."));return Ff(n,t,c)?n%24*Bf+t*P0+c*1e3:NaN}return null}function B0(e,n,t){n=n||0,t=t||0;const r=new Date(0);r.setUTCFullYear(e,0,4);const c=r.getUTCDay()||7,h=n*7+t+1-c;return r.setUTCDate(r.getUTCDate()+h),r}const MM=[31,28,31,30,31,30,31,31,30,31,30,31],RM=[31,29,31,30,31,30,31,31,30,31,30,31];function F0(e){return e%400===0||e%4===0&&e%100!==0}function j0(e,n,t){if(n<0||n>11)return!1;if(t!=null){if(t<1)return!1;const r=F0(e);if(r&&t>RM[n]||!r&&t>MM[n])return!1}return!0}function LM(e,n){if(n<1)return!1;const t=F0(e);return!(t&&n>366||!t&&n>365)}function W0(e,n){return!(e<0||e>52||n!=null&&(n<0||n>6))}function Ff(e,n,t){return!(e<0||e>=25||n!=null&&(n<0||n>=60)||t!=null&&(t<0||t>=60))}const OM=/([xXOz]+)|''|'(''|[^'])+('|$)/g;function NM(e,n,t={}){n=String(n);const r=n.match(OM);if(r){const c=z0(t.originalDate||e,t);n=r.reduce(function(h,g){if(g[0]==="'")return h;const v=h.indexOf(g),s=h[v-1]==="'",p=h.replace(g,"'"+kM[g[0]](c,g,t)+"'");return s?p.substring(0,v-1)+p.substring(v+1):p},n)}return Ds(e,n,t)}function DM(e,n,t){e=z0(e,t);const r=Df(n,e,!0),c=new Date(e.getTime()-r),h=new Date(0);return h.setFullYear(c.getUTCFullYear(),c.getUTCMonth(),c.getUTCDate()),h.setHours(c.getUTCHours(),c.getUTCMinutes(),c.getUTCSeconds(),c.getUTCMilliseconds()),h}function $u(e,n,t,r){return r={...r,timeZone:n,originalDate:e},NM(DM(e,n,{timeZone:r.timeZone}),t,r)}const Su="yyyy-MM-dd",H0="HH:mm:ss.SSS",U0="HH:mm:ss",Tu=`${Su} ${H0}`,V0=`${Su} ${U0}`,PM=lr("c",{methods:{parseDateTime(e,n){return e.includes(" ")&&(e=e.replace(" ","T")),n&&n==="UTC"&&(e+="Z"),Date.parse(e)},formatUtcToLocal(e,n){return Ds(!n||n==="local"?lM(e,e.getTimezoneOffset()):e,Tu)},formatDateTime(e,n){return!n||n==="local"?Ds(e,Tu):$u(e,n,Tu)},formatDateTimeHMS(e,n){return!n||n==="local"?Ds(e,V0):$u(e,n,V0)},formatDate:function(e,n){return!n||n==="local"?Ds(e,Su):$u(e,this.timeZone,Su)},formatTime:function(e,n,t=H0){return!n||n==="local"?Ds(e,t):$u(e,this.timeZone,t)},formatTimeHMS:function(e,n){return this.formatTime(e,n,U0)},formatTimestamp(e,n){return this.formatDateTime(GI(e),n)},formatSeconds(e,n){return this.formatDateTime(new Date(e*1e3),n)},formatNanoseconds(e,n){return this.formatDateTime(new Date(parseInt(e)/1e6),n)}}}),G0=100,q0=lr("g",im("app",{state:()=>({notifyHistory:[],namedWidgets:{},playback:{playbackMode:null,playbackDateTime:null,playbackStep:1,playbackLoading:0}}),getters:{namedWidget:e=>n=>e.namedWidgets[n]},actions:{notifyAddHistory(e){this.notifyHistory.length>=G0&&(this.notifyHistory.length=G0-1),this.notifyHistory.unshift(e)},notifyClearHistory(){this.notifyHistory=[]},setNamedWidget(e){Object.assign(this.namedWidgets,e)},clearNamedWidget(e){delete this.namedWidgets[e]},updatePlayback(e){Object.assign(this.playback,e)}}})),sl=om();sl.use(({store:e})=>{e.commit=(n,t)=>{typeof e[n]=="function"&&e[n](t)},e.dispatch=(n,t)=>{if(typeof e[n]=="function")return e[n](t)}});const zM=sl.install.bind(sl);sl.install=e=>{zM(e);const n=q0(sl);e.config.globalProperties.$store={state:new Proxy({},{get(t,r){return n.$state}}),getters:new Proxy({},{get(t,r){if(r.includes("/")){const[,c]=r.split("/");return n[c]}return n[r]}}),commit(t,r){if(t.includes("/")){const[,c]=t.split("/");n[c]?.(r)}else n[t]?.(r)},dispatch(t,r){if(t.includes("/")){const[,c]=t.split("/");return n[c]?.(r)}else return n[t]?.(r)}}};function Y0(e,n){return function(){return e.apply(n,arguments)}}const{toString:BM}=Object.prototype,{getPrototypeOf:Fs}=Object,{iterator:rc,toStringTag:K0}=Symbol,ic=(({hasOwnProperty:e})=>(n,t)=>e.call(n,t))(Object.prototype),J0=e=>typeof e=="string"&&(e==="__proto__"||e==="constructor"||e==="prototype"),Q0=(e,n,t)=>e===Object.prototype||!t&&n===null,FM=e=>{if(!Object.isExtensible(e))return!1;const n=Object.getOwnPropertyNames(e);return Object.getOwnPropertySymbols&&n.push(...Object.getOwnPropertySymbols(e)),n.every(t=>{if(J0(t))return!1;const r=Object.getOwnPropertyDescriptor(e,t);return!!r&&r.configurable&&r.writable===!0})},oc=(e,n)=>{let t=e;const r=[];for(;t!=null;){if(r.indexOf(t)!==-1)return!1;r.push(t);const c=Fs(t);if(Q0(t,c,t===e))return!1;if(ic(t,n))return!0;t=c}return!1},jM=(e,n)=>e!=null&&oc(e,n)?e[n]:void 0,WM=e=>{if(e==null||typeof e!="object"&&typeof e!="function")return e;const n=Fs(e);if(n===null&&FM(e))return e;const t=Object.create(null),r=Object.create(null),c=[];let h=e;for(;h!=null&&c.indexOf(h)===-1;){c.push(h);const g=h===e?n:Fs(h);if(Q0(h,g,h===e))break;const v=Object.getOwnPropertyNames(h);Object.getOwnPropertySymbols&&v.push(...Object.getOwnPropertySymbols(h));for(const s of v)J0(s)||ic(r,s)||(t[s]=e[s],r[s]=!0);h=g}return t},jf=(e=>n=>{const t=BM.call(n);return e[t]||(e[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),uo=e=>(e=e.toLowerCase(),n=>jf(n)===e),Eu=e=>n=>typeof n===e,{isArray:ya}=Array,ba=Eu("undefined");function al(e){return e!==null&&!ba(e)&&e.constructor!==null&&!ba(e.constructor)&&ki(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Z0=uo("ArrayBuffer");function HM(e){let n;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?n=ArrayBuffer.isView(e):n=e&&e.buffer&&Z0(e.buffer),n}const UM=Eu("string"),ki=Eu("function"),X0=Eu("number"),ll=e=>e!==null&&typeof e=="object",VM=e=>e===!0||e===!1,Iu=e=>{if(!ll(e))return!1;const n=Fs(e);return(n===null||n===Object.prototype||Fs(n)===null)&&!oc(e,K0)&&!oc(e,rc)},GM=e=>{if(!ll(e)||al(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},qM=uo("Date"),YM=uo("File"),KM=e=>!!(e&&typeof e.uri<"u"),JM=e=>e&&typeof e.getParts<"u",QM=uo("Blob"),ZM=uo("FileList"),XM=uo("Set"),eR=e=>ll(e)&&ki(e.pipe);function tR(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}const ew=tR(),tw=typeof ew.FormData<"u"?ew.FormData:void 0,nR=e=>{if(!e)return!1;if(tw&&e instanceof tw)return!0;const n=Fs(e);if(!n||n===Object.prototype||!ki(e.append))return!1;const t=jf(e);return t==="formdata"||t==="object"&&ki(e.toString)&&e.toString()==="[object FormData]"},rR=uo("URLSearchParams"),[iR,oR,sR,aR]=["ReadableStream","Request","Response","Headers"].map(uo),lR=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function sc(e,n,{allOwnKeys:t=!1}={}){if(e===null||typeof e>"u")return;let r,c;if(typeof e!="object"&&(e=[e]),ya(e))for(r=0,c=e.length;r<c;r++)n.call(null,e[r],r,e);else{if(al(e))return;const h=t?Object.getOwnPropertyNames(e):Object.keys(e),g=h.length;let v;for(r=0;r<g;r++)v=h[r],n.call(null,e[v],v,e)}}function nw(e,n){if(al(e))return null;n=n.toLowerCase();const t=Object.keys(e);let r=t.length,c;for(;r-- >0;)if(c=t[r],n===c.toLowerCase())return c;return null}const wa=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,rw=e=>!ba(e)&&e!==wa;function Wf(...e){const{caseless:n,skipUndefined:t}=rw(this)&&this||{},r={},c=(h,g)=>{if(g==="__proto__"||g==="constructor"||g==="prototype")return;const v=n&&typeof g=="string"&&nw(r,g)||g,s=ic(r,v)?r[v]:void 0;Iu(s)&&Iu(h)?r[v]=Wf(s,h):Iu(h)?r[v]=Wf({},h):ya(h)?r[v]=h.slice():(!t||!ba(h))&&(r[v]=h)};for(let h=0,g=e.length;h<g;h++){const v=e[h];if(!v||al(v)||(sc(v,c),typeof v!="object"||ya(v)))continue;const s=Object.getOwnPropertySymbols(v);for(let p=0;p<s.length;p++){const a=s[p];wR.call(v,a)&&c(v[a],a)}}return r}const cR=(e,n,t,{allOwnKeys:r}={})=>(sc(n,(c,h)=>{t&&ki(c)?Object.defineProperty(e,h,{__proto__:null,value:Y0(c,t),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,h,{__proto__:null,value:c,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),uR=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),hR=(e,n,t,r)=>{e.prototype=Object.create(n.prototype,r),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:n.prototype}),t&&Object.assign(e.prototype,t)},dR=(e,n,t,r)=>{let c,h,g;const v={};if(n=n||{},e==null)return n;do{for(c=Object.getOwnPropertyNames(e),h=c.length;h-- >0;)g=c[h],(!r||r(g,e,n))&&!v[g]&&(n[g]=e[g],v[g]=!0);e=t!==!1&&Fs(e)}while(e&&(!t||t(e,n))&&e!==Object.prototype);return n},fR=(e,n,t)=>{e=String(e),(t===void 0||t>e.length)&&(t=e.length),t-=n.length;const r=e.indexOf(n,t);return r!==-1&&r===t},pR=e=>{if(!e)return null;if(ya(e))return e;let n=e.length;if(!X0(n))return null;const t=new Array(n);for(;n-- >0;)t[n]=e[n];return t},gR=(e=>n=>e&&n instanceof e)(typeof Uint8Array<"u"&&Fs(Uint8Array)),mR=(e,n)=>{const t=(e&&e[rc]).call(e);let r;for(;(r=t.next())&&!r.done;){const c=r.value;n.call(e,c[0],c[1])}},vR=(e,n)=>{let t;const r=[];for(;(t=e.exec(n))!==null;)r.push(t);return r},yR=uo("HTMLFormElement"),bR=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,t,r){return t.toUpperCase()+r}),{propertyIsEnumerable:wR}=Object.prototype,xR=uo("RegExp"),iw=(e,n)=>{const t=Object.getOwnPropertyDescriptors(e),r={};sc(t,(c,h)=>{let g;(g=n(c,h,e))!==!1&&(r[h]=g||c)}),Object.defineProperties(e,r)},CR=e=>{iw(e,(n,t)=>{if(ki(e)&&["arguments","caller","callee"].includes(t))return!1;const r=e[t];if(ki(r)){if(n.enumerable=!1,"writable"in n){n.writable=!1;return}n.set||(n.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},kR=(e,n)=>{const t={},r=c=>{c.forEach(h=>{t[h]=!0})};return ya(e)?r(e):r(String(e).split(n)),t},_R=()=>{},AR=(e,n)=>e!=null&&Number.isFinite(e=+e)?e:n;function $R(e){return!!(e&&ki(e.append)&&e[K0]==="FormData"&&e[rc])}const SR=e=>{const n=new WeakSet,t=r=>{if(ll(r)){if(n.has(r))return;if(al(r))return r;if(!("toJSON"in r)){n.add(r);let c;if(XM(r)){c=[];for(const h of r){const g=t(h);!ba(g)&&c.push(g)}}else c=ya(r)?[]:{},sc(r,(h,g)=>{const v=t(h);!ba(v)&&(c[g]=v)});return n.delete(r),c}}return r};return t(e)},TR=uo("AsyncFunction"),ER=e=>e&&(ll(e)||ki(e))&&ki(e.then)&&ki(e.catch),ow=((e,n)=>e?setImmediate:n?((t,r)=>(wa.addEventListener("message",({source:c,data:h})=>{c===wa&&h===t&&r.length&&r.shift()()},!1),c=>{r.push(c),wa.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",ki(wa.postMessage)),IR=typeof queueMicrotask<"u"?queueMicrotask.bind(wa):typeof process<"u"&&process.nextTick||ow,sw=e=>e!=null&&ki(e[rc]),MR=e=>e!=null&&oc(e,rc)&&sw(e),ve={isArray:ya,isArrayBuffer:Z0,isBuffer:al,isFormData:nR,isArrayBufferView:HM,isString:UM,isNumber:X0,isBoolean:VM,isObject:ll,isPlainObject:Iu,isEmptyObject:GM,isReadableStream:iR,isRequest:oR,isResponse:sR,isHeaders:aR,isUndefined:ba,isDate:qM,isFile:YM,isReactNativeBlob:KM,isReactNative:JM,isBlob:QM,isRegExp:xR,isFunction:ki,isStream:eR,isURLSearchParams:rR,isTypedArray:gR,isFileList:ZM,forEach:sc,merge:Wf,extend:cR,trim:lR,stripBOM:uR,inherits:hR,toFlatObject:dR,kindOf:jf,kindOfTest:uo,endsWith:fR,toArray:pR,forEachEntry:mR,matchAll:vR,isHTMLForm:yR,hasOwnProperty:ic,hasOwnProp:ic,hasOwnInPrototypeChain:oc,getSafeProp:jM,toSafeFlatObject:WM,reduceDescriptors:iw,freezeMethods:CR,toObjectSet:kR,toCamelCase:bR,noop:_R,toFiniteNumber:AR,findKey:nw,global:wa,isContextDefined:rw,isSpecCompliantForm:$R,toJSONObject:SR,isAsyncFn:TR,isThenable:ER,setImmediate:ow,asap:IR,isIterable:sw,isSafeIterable:MR},RR=ve.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"]),LR=e=>{const n={};let t,r,c;return e&&e.split(`
1481
+ `).forEach(function(h){c=h.indexOf(":"),t=h.substring(0,c).trim().toLowerCase(),r=h.substring(c+1).trim();const g=ve.hasOwnProp(n,t);!t||g&&ve.hasOwnProp(RR,t)||(t==="set-cookie"?g?n[t].push(r):n[t]=[r]:n[t]=g?n[t]+", "+r:r)}),n};function OR(e){let n=0,t=e.length;for(;n<t;){const r=e.charCodeAt(n);if(r!==9&&r!==32)break;n+=1}for(;t>n;){const r=e.charCodeAt(t-1);if(r!==9&&r!==32)break;t-=1}return n===0&&t===e.length?e:e.slice(n,t)}const NR=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),DR=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function Hf(e,n){return ve.isArray(e)?e.map(t=>Hf(t,n)):OR(String(e).replace(n,""))}const PR=e=>Hf(e,NR),zR=e=>Hf(e,DR);function aw(e){const n=Object.create(null);return ve.forEach(e.toJSON(),(t,r)=>{n[r]=zR(t)}),n}const lw=Symbol("internals");function ac(e){return e&&String(e).trim().toLowerCase()}function Mu(e){return e===!1||e==null?e:ve.isArray(e)?e.map(Mu):PR(String(e))}function BR(e){const n=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=t.exec(e);)n[r[1]]=r[2];return n}const FR=/^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/;function Uf(e){let n=0,t=e.length;for(;n<t;){const r=e.charCodeAt(n);if(r!==9&&r!==32)break;n+=1}for(;t>n;){const r=e.charCodeAt(t-1);if(r!==9&&r!==32)break;t-=1}return n===0&&t===e.length?e:e.slice(n,t)}function jR(e){const n=e.length-1;if(n<1||e.charCodeAt(0)!==34||e.charCodeAt(n)!==34)return e;let t="";for(let r=1;r<n;r++){const c=e.charCodeAt(r);if(c===34||c===92&&(r+=1,r>=n))return e;t+=e[r]}return t}function WR(e){const n=Object.create(null),t=String(e);let r=0,c=!1,h=!1;function g(v){const s=Uf(t.slice(r,v)),p=s.indexOf("=");if(p<1)return;const a=Uf(s.slice(0,p));if(!FR.test(a))return;const l=a.toLowerCase();if(l==="__proto__"||l==="constructor"||l==="prototype")return;const u=Uf(s.slice(p+1));n[l]=jR(u)}for(let v=0;v<t.length;v++){const s=t.charCodeAt(v);c?h?h=!1:s===92?h=!0:s===34&&(c=!1):s===34?c=!0:(s===44||s===59)&&(g(v),r=v+1)}return g(t.length),n}const HR=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Vf(e,n,t,r,c){if(ve.isFunction(r))return r.call(this,n,t);if(c&&(n=t),!!ve.isString(n)){if(ve.isString(r))return n.indexOf(r)!==-1;if(ve.isRegExp(r))return r.test(n)}}function UR(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(n,t,r)=>t.toUpperCase()+r)}function VR(e,n){const t=ve.toCamelCase(" "+n);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+t,{__proto__:null,value:function(c,h,g){return this[r].call(this,n,c,h,g)},configurable:!0})})}let Qr=class{constructor(e){e&&this.set(e)}set(e,n,t){const r=this;function c(g,v,s){const p=ac(v);if(!p)return;const a=ve.findKey(r,p);(!a||r[a]===void 0||s===!0||s===void 0&&r[a]!==!1)&&(r[a||v]=Mu(g))}const h=(g,v)=>ve.forEach(g,(s,p)=>c(s,p,v));if(ve.isPlainObject(e)||e instanceof this.constructor)h(e,n);else if(ve.isString(e)&&(e=e.trim())&&!HR(e))h(LR(e),n);else if(ve.isObject(e)&&ve.isSafeIterable(e)){let g=Object.create(null),v,s;for(const p of e){if(!ve.isArray(p))throw new TypeError("Object iterator must return a key-value pair");s=p[0],ve.hasOwnProp(g,s)?(v=g[s],g[s]=ve.isArray(v)?[...v,p[1]]:[v,p[1]]):g[s]=p[1]}h(g,n)}else e!=null&&c(n,e,t);return this}get(e,n){if(e=ac(e),e){const t=ve.findKey(this,e);if(t){const r=this[t];if(!n)return r;if(n===!0)return BR(r);if(ve.isFunction(n))return n.call(this,r,t);if(ve.isRegExp(n))return n.exec(r);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,n){if(e=ac(e),e){const t=ve.findKey(this,e);return!!(t&&this[t]!==void 0&&(!n||Vf(this,this[t],t,n)))}return!1}delete(e,n){const t=this;let r=!1;function c(h){if(h=ac(h),h){const g=ve.findKey(t,h);g&&(!n||Vf(t,t[g],g,n))&&(delete t[g],r=!0)}}return ve.isArray(e)?e.forEach(c):c(e),r}clear(e){const n=Object.keys(this);let t=n.length,r=!1;for(;t--;){const c=n[t];(!e||Vf(this,this[c],c,e,!0))&&(delete this[c],r=!0)}return r}normalize(e){const n=this,t={};return ve.forEach(this,(r,c)=>{const h=ve.findKey(t,c);if(h){n[h]=Mu(r),delete n[c];return}const g=e?UR(c):String(c).trim();g!==c&&delete n[c],n[g]=Mu(r),t[g]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const n=Object.create(null);return ve.forEach(this,(t,r)=>{t!=null&&t!==!1&&(n[r]=e&&ve.isArray(t)?t.join(", "):t)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,n])=>e+": "+n).join(`
1482
+ `)}getSetCookie(){const e=this.get("set-cookie");return ve.isArray(e)?e:e==null||e===!1?[]:[e]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static parseParameters(e){return WR(e)}static concat(e,...n){const t=new this(e);return n.forEach(r=>t.set(r)),t}static accessor(e){const n=(this[lw]=this[lw]={accessors:{}}).accessors,t=this.prototype;function r(c){const h=ac(c);n[h]||(VR(t,c),n[h]=!0)}return ve.isArray(e)?e.forEach(r):r(e),this}};Qr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),ve.reduceDescriptors(Qr.prototype,({value:e},n)=>{let t=n[0].toUpperCase()+n.slice(1);return{get:()=>e,set(r){this[t]=r}}}),ve.freezeMethods(Qr);const Ru="[REDACTED ****]";function GR(e){if(ve.hasOwnProp(e,"toJSON"))return!0;let n=Object.getPrototypeOf(e);for(;n&&n!==Object.prototype;){if(ve.hasOwnProp(n,"toJSON"))return!0;n=Object.getPrototypeOf(n)}return!1}function qR(e,n){const t=new Set(n.map(h=>String(h).toLowerCase())),r=[],c=h=>{if(h===null||typeof h!="object"||ve.isBuffer(h))return h;if(r.indexOf(h)!==-1)return;h instanceof Qr&&(h=h.toJSON()),r.push(h);let g;if(ve.isArray(h))g=[],h.forEach((v,s)=>{const p=c(v);ve.isUndefined(p)||(g[s]=p)});else{if(!ve.isPlainObject(h)&&GR(h))return r.pop(),h;g=Object.create(null);for(const[v,s]of Object.entries(h)){const p=t.has(v.toLowerCase())?Ru:c(s);ve.isUndefined(p)||(g[v]=p)}}return r.pop(),g};return c(e)}function cw(e){try{return String(e)}catch{return""}}function YR(e){return e.errors.map(n=>{try{return n&&n.message?cw(n.message):cw(n)}catch{return""}}).filter(Boolean).join("; ")||e.name||"AggregateError"}let nt=class ak extends Error{static from(n,t,r,c,h,g){let v=n.message;!v&&ve.isArray(n.errors)&&n.errors.length&&(v=YR(n));const s=new ak(v,t||n.code,r,c,h);return Object.defineProperty(s,"cause",{__proto__:null,value:n,writable:!0,enumerable:!1,configurable:!0}),s.name=n.name,n.status!=null&&s.status==null&&(s.status=n.status),g&&Object.assign(s,g),s}constructor(n,t,r,c,h){super(n),Object.defineProperty(this,"message",{__proto__:null,value:n,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),r&&(this.config=r),c&&(this.request=c),h&&(this.response=h,this.status=h.status)}toJSON(){const n=this.config,t=n&&ve.hasOwnProp(n,"redact")?n.redact:void 0,r=ve.isArray(t)&&t.length>0?qR(n,t):ve.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 KR=null,uw=100;function Gf(e){return ve.isPlainObject(e)||ve.isArray(e)}function hw(e){return ve.endsWith(e,"[]")?e.slice(0,-2):e}function qf(e,n,t){return e?e.concat(n).map(function(r,c){return r=hw(r),!t&&c?"["+r+"]":r}).join(t?".":""):n}function JR(e){return ve.isArray(e)&&!e.some(Gf)}const QR=ve.toFlatObject(ve,{},null,function(e){return/^is[A-Z]/.test(e)});function Lu(e,n,t){if(!ve.isObject(e))throw new TypeError("target must be an object");n=n||new FormData;const r=(x,R)=>{const T=ve.getSafeProp(t,x);return ve.isUndefined(T)?R:T},c=r("metaTokens",!0),h=r("visitor")||f,g=r("dots",!1),v=r("indexes",!1),s=r("Blob")||typeof Blob<"u"&&Blob,p=r("maxDepth",uw),a=s&&ve.isSpecCompliantForm(n),l=[];if(!ve.isFunction(h))throw new TypeError("visitor must be a function");function u(x){if(x===null)return"";if(ve.isDate(x))return x.toISOString();if(ve.isBoolean(x))return x.toString();if(!a&&ve.isBlob(x))throw new nt("Blob is not supported. Use a Buffer instead.");if(ve.isArrayBuffer(x)||ve.isTypedArray(x)){if(a&&typeof s=="function")return new s([x]);throw new nt("Blob is not supported. Use a Buffer instead.",nt.ERR_NOT_SUPPORT)}return x}function d(x){if(x>p)throw new nt("Object is too deeply nested ("+x+" levels). Max depth: "+p,nt.ERR_FORM_DATA_DEPTH_EXCEEDED)}function o(x,R){if(p===1/0)return JSON.stringify(x);const T=[];return JSON.stringify(x,function(_,C){if(!ve.isObject(C))return C;for(;T.length&&T[T.length-1]!==this;)T.pop();return T.push(C),d(R+T.length-1),C})}function f(x,R,T){let _=x;if(ve.isReactNative(n)&&ve.isReactNativeBlob(x))return n.append(qf(T,R,g),u(x)),!1;if(x&&!T&&typeof x=="object"){if(ve.endsWith(R,"{}"))R=c?R:R.slice(0,-2),x=o(x,1);else if(ve.isArray(x)&&JR(x)||(ve.isFileList(x)||ve.endsWith(R,"[]"))&&(_=ve.toArray(x)))return R=hw(R),_.forEach(function(C,P){!(ve.isUndefined(C)||C===null)&&n.append(v===!0?qf([R],P,g):v===null?R:R+"[]",u(C))}),!1}return Gf(x)?!0:(n.append(qf(T,R,g),u(x)),!1)}const m=Object.assign(QR,{defaultVisitor:f,convertValue:u,isVisitable:Gf});function w(x,R,T=0){if(!ve.isUndefined(x)){if(d(T),l.indexOf(x)!==-1)throw new Error("Circular reference detected in "+R.join("."));l.push(x),ve.forEach(x,function(_,C){(!(ve.isUndefined(_)||_===null)&&h.call(n,_,ve.isString(C)?C.trim():C,R,m))===!0&&w(_,R?R.concat(C):[C],T+1)}),l.pop()}}if(!ve.isObject(e))throw new TypeError("data must be an object");return w(e),n}function dw(e){const n={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(t){return n[t]})}function Yf(e,n){this._pairs=[],e&&Lu(e,this,n)}const fw=Yf.prototype;fw.append=function(e,n){this._pairs.push([e,n])},fw.toString=function(e){const n=e?t=>e.call(this,t,dw):dw;return this._pairs.map(function(t){return n(t[0])+"="+n(t[1])},"").join("&")};function ZR(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function pw(e,n,t){if(!n)return e;e=e||"";const r=ve.isFunction(t)?{serialize:t}:t,c=ve.getSafeProp(r,"encode")||ZR,h=ve.getSafeProp(r,"serialize");let g;if(h?g=h(n,r):g=ve.isURLSearchParams(n)?n.toString():new Yf(n,r).toString(c),g){const v=e.indexOf("#");v!==-1&&(e=e.slice(0,v)),e+=(e.indexOf("?")===-1?"?":"&")+g}return e}const lc=Symbol("internals");function gw(e){return e?e.length:0}function mw(e){if(e)for(;e.length&&e[e.length-1]===null;)e.pop()}function cc(e,n){const t=e.handlers,r=gw(t);t!==n.handlersRef?(n.handlersRef=t,n.handlerEntries.clear()):r!==n.handlersLength&&(r?n.handlerEntries.forEach(function(c,h){t[c.index]!==c.handler&&n.handlerEntries.delete(h)}):n.handlerEntries.clear()),n.handlersLength=r}let vw=class{constructor(){this.handlers=[],this[lc]={handlersRef:this.handlers,handlersLength:this.handlers.length,handlerEntries:new Map,iterationDepth:0,nextId:0}}use(n,t,r){const c={fulfilled:n,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null},h=this[lc];this.handlers==null&&(this.handlers=[]),cc(this,h);const g=h.nextId++;return this.handlers.push(c),h.handlerEntries.set(g,{handler:c,index:this.handlers.length-1}),h.handlersLength=this.handlers.length,g}eject(n){const t=this[lc];cc(this,t);const r=t.handlerEntries.get(n);if(r){if(t.handlerEntries.delete(n),this.handlers[r.index]!==r.handler)return;this.handlers[r.index]=null,t.iterationDepth||(mw(this.handlers),t.handlersLength=this.handlers.length)}}clear(){this.handlers&&(this.handlers=[],cc(this,this[lc]))}forEach(n){const t=this[lc];cc(this,t),t.iterationDepth++;try{ve.forEach(this.handlers,function(r){r!==null&&n(r)})}finally{--t.iterationDepth||(cc(this,t),mw(this.handlers),t.handlersLength=gw(this.handlers))}}};const Kf={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0,advertiseZstdAcceptEncoding:!1,validateStatusUndefinedResolves:!0},XR=typeof URLSearchParams<"u"?URLSearchParams:Yf,eL=typeof FormData<"u"?FormData:null,tL=typeof Blob<"u"?Blob:null,nL={isBrowser:!0,classes:{URLSearchParams:XR,FormData:eL,Blob:tL},protocols:["http","https","file","blob","url","data"]},Jf=typeof window<"u"&&typeof document<"u",Qf=typeof navigator=="object"&&navigator||void 0,rL=Jf&&(!Qf||["ReactNative","NativeScript","NS"].indexOf(Qf.product)<0),iL=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",oL=Jf&&window.location.href||"http://localhost",sL=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Jf,hasStandardBrowserEnv:rL,hasStandardBrowserWebWorkerEnv:iL,navigator:Qf,origin:oL},Symbol.toStringTag,{value:"Module"})),Rr={...sL,...nL};function aL(e,n){return Lu(e,new Rr.classes.URLSearchParams,{visitor:function(t,r,c,h){return Rr.isNode&&ve.isBuffer(t)?(this.append(r,t.toString("base64")),!1):h.defaultVisitor.apply(this,arguments)},...n})}const yw=uw;function bw(e){if(e>yw)throw new nt("FormData field is too deeply nested ("+e+" levels). Max depth: "+yw,nt.ERR_FORM_DATA_DEPTH_EXCEEDED)}function lL(e){const n=[],t=/[^.[\]]+|\[([^.[\]]*)]/g;let r;for(;(r=t.exec(e))!==null;)bw(n.length),n.push(r[0]==="[]"?"":r[1]||r[0]);return n}function cL(e){const n={},t=Object.keys(e);let r;const c=t.length;let h;for(r=0;r<c;r++)h=t[r],n[h]=e[h];return n}function ww(e){function n(t,r,c,h){bw(h);let g=t[h++];if(g==="__proto__")return!0;const v=Number.isFinite(+g),s=h>=t.length;return g=!g&&ve.isArray(c)?c.length:g,s?(ve.hasOwnProp(c,g)?c[g]=ve.isArray(c[g])?c[g].concat(r):[c[g],r]:c[g]=r,!v):((!ve.hasOwnProp(c,g)||!ve.isObject(c[g]))&&(c[g]=[]),n(t,r,c[g],h)&&ve.isArray(c[g])&&(c[g]=cL(c[g])),!v)}if(ve.isFormData(e)&&ve.isFunction(e.entries)){const t={};return ve.forEachEntry(e,(r,c)=>{n(lL(r),c,t,0)}),t}return null}const xw=Object.freeze(["get","delete","head","options","post","put","patch","purge","link","unlink","query"]),cl=(e,n)=>e!=null&&ve.hasOwnProp(e,n)?e[n]:void 0;function uL(e,n,t){if(ve.isString(e))try{return(n||JSON.parse)(e),ve.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(t||JSON.stringify)(e)}const uc={transitional:Kf,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const t=n.getContentType()||"",r=t.indexOf("application/json")>-1,c=ve.isObject(e);if(c&&ve.isHTMLForm(e)&&(e=new FormData(e)),ve.isFormData(e))return r?JSON.stringify(ww(e)):e;if(ve.isArrayBuffer(e)||ve.isBuffer(e)||ve.isStream(e)||ve.isFile(e)||ve.isBlob(e)||ve.isReadableStream(e))return e;if(ve.isArrayBufferView(e))return e.buffer;if(ve.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let h;if(c){const g=cl(this,"formSerializer");if(t.indexOf("application/x-www-form-urlencoded")>-1)return aL(e,g).toString();if((h=ve.isFileList(e))||t.indexOf("multipart/form-data")>-1){const v=cl(this,"env"),s=v&&v.FormData;return Lu(h?{"files[]":e}:e,s&&new s,g)}}return c||r?(n.setContentType("application/json",!1),uL(e)):e}],transformResponse:[function(e){const n=cl(this,"transitional")||uc.transitional,t=n&&n.forcedJSONParsing,r=cl(this,"responseType"),c=r==="json";if(ve.isResponse(e)||ve.isReadableStream(e))return e;if(e&&ve.isString(e)&&(t&&!r||c)){const h=!(n&&n.silentJSONParsing)&&c;try{return JSON.parse(e,cl(this,"parseReviver"))}catch(g){if(h)throw g.name==="SyntaxError"?nt.from(g,nt.ERR_BAD_RESPONSE,this,null,cl(this,"response")):g}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Rr.classes.FormData,Blob:Rr.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};ve.forEach(xw,e=>{uc.headers[e]={}});function Zf(e,n){const t=this||uc,r=n||t,c=Qr.from(r.headers);let h=r.data;return ve.forEach(e,function(g){h=g.call(t,h,c.normalize(),n?n.status:void 0)}),c.normalize(),h}function Cw(e){return!!(e&&e.__CANCEL__)}let hc=class extends nt{constructor(n,t,r){super(n??"canceled",nt.ERR_CANCELED,t,r),this.name="CanceledError",this.__CANCEL__=!0}};function kw(e,n,t){const r=t.config.validateStatus;!t.status||!r||r(t.status)?e(t):n(new nt("Request failed with status code "+t.status,t.status>=400&&t.status<500?nt.ERR_BAD_REQUEST:nt.ERR_BAD_RESPONSE,t.config,t.request,t))}const hL=/[\t\n\r]/g;function _w(e){if(typeof e!="string")return e;let n=0;for(;n<e.length&&e.charCodeAt(n)<=32;)n++;return e.slice(n).replace(hL,"")}function Xf(e){const n=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return n&&n[1]||""}function dL(e,n){e=e||10;const t=new Array(e),r=new Array(e);let c=0,h=0,g;return n=n!==void 0?n:1e3,function(v){const s=Date.now(),p=r[h];g||(g=s),t[c]=v,r[c]=s;let a=h,l=0;for(;a!==c;)l+=t[a++],a=a%e;if(c=(c+1)%e,c===h&&(h=(h+1)%e),s-g<n)return;const u=p&&s-p;return u?Math.round(l*1e3/u):void 0}}function fL(e,n){let t=0,r=1e3/n,c,h;const g=(v,s=Date.now())=>{t=s,c=null,h&&(clearTimeout(h),h=null),e(...v)};return[(...v)=>{const s=Date.now(),p=s-t;p>=r?g(v,s):(c=v,h||(h=setTimeout(()=>{h=null,g(c)},r-p)))},()=>c&&g(c),(...v)=>g(v)]}const Ou=(e,n,t=3)=>{let r=0;const c=dL(50,250);return fL(h=>{if(!h||!ve.isNumber(h.loaded))return;const g=h.loaded,v=h.lengthComputable?h.total:void 0,s=Math.max(0,v!=null?Math.min(g,v):g),p=Math.max(0,s-r),a=c(p);r=Math.max(r,s);const l={loaded:s,total:v,progress:v?s/v:void 0,bytes:p,rate:a||void 0,estimated:a&&v?(v-s)/a:void 0,event:h,lengthComputable:v!=null,[n?"download":"upload"]:!0};e(l)},t)},Aw=(e,n)=>{const t=e!=null;return[r=>n[0]({lengthComputable:t,total:e,loaded:r}),n[1]]},$w=(e,n=ve.asap)=>(...t)=>n(()=>e(...t)),pL=Rr.hasStandardBrowserEnv?((e,n)=>t=>(t=new URL(t,Rr.origin),e.protocol===t.protocol&&e.host===t.host&&(n||e.port===t.port)))(new URL(Rr.origin),Rr.navigator&&/(msie|trident)/i.test(Rr.navigator.userAgent)):()=>!0,gL=Rr.hasStandardBrowserEnv?{write(e,n,t,r,c,h,g){if(typeof document>"u")return;const v=[`${e}=${encodeURIComponent(n)}`];ve.isNumber(t)&&v.push(`expires=${new Date(t).toUTCString()}`),ve.isString(r)&&v.push(`path=${r}`),ve.isString(c)&&v.push(`domain=${c}`),h===!0&&v.push("secure"),ve.isString(g)&&v.push(`SameSite=${g}`),document.cookie=v.join("; ")},read(e){if(typeof document>"u")return null;const n=document.cookie.split(";");for(let t=0;t<n.length;t++){const r=n[t].replace(/^\s+/,""),c=r.indexOf("=");if(c!==-1&&r.slice(0,c)===e)try{return decodeURIComponent(r.slice(c+1))}catch{return r.slice(c+1)}}return null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function mL(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function vL(e,n){if(!n)return e;let t=e.length;for(;t>0&&e.charCodeAt(t-1)===47;)t--;return e.slice(0,t)+"/"+n.replace(/^\/+/,"")}const yL=/^https?:(?!\/\/)/i;function bL(e){return e&&e.replace(/(^|&)([^=&]*=)?[^&]+/g,(n,t,r="")=>`${t}${r}${Ru}`)}function wL(e){const n=e.replace(/^(https?:\/{0,2})[^/?#]*@/i,`$1${Ru}@`),t=n.indexOf("#"),r=(t===-1?n:n.slice(0,t)).replace(/([?&][^=&#]*=)[^&#]*/g,`$1${Ru}`);return t===-1?r:`${r}#${bL(n.slice(t+1))}`}function Sw(e,n){if(typeof e=="string"){const t=_w(e);if(yL.test(t))throw new nt(`Invalid URL ${JSON.stringify(wL(t))}: missing "//" after protocol`,nt.ERR_INVALID_URL,n)}}function Tw(e,n,t,r){Sw(n,r);let c=!mL(n);return e&&(c||t===!1)?(Sw(e,r),vL(e,n)):n}const Ew=e=>e instanceof Qr?{...e}:e,xL=e=>Object.getOwnPropertySymbols&&Object.getOwnPropertyDescriptor?Object.keys(e).concat(Object.getOwnPropertySymbols(e).filter(n=>Object.getOwnPropertyDescriptor(e,n).enumerable)):Object.keys(e);function xa(e,n){e=e||{},n=n||{};const t=Object.create(null);Object.defineProperty(t,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function r(a,l,u,d){return ve.isPlainObject(a)&&ve.isPlainObject(l)?ve.merge.call({caseless:d},a,l):ve.isPlainObject(l)?ve.merge({},l):ve.isArray(l)?l.slice():l}function c(a,l,u,d){if(ve.isUndefined(l)){if(!ve.isUndefined(a))return r(void 0,a,u,d)}else return r(a,l,u,d)}function h(a,l){if(!ve.isUndefined(l))return r(void 0,l)}function g(a,l){if(ve.isUndefined(l)){if(!ve.isUndefined(a))return r(void 0,a)}else return r(void 0,l)}function v(a){const l=ve.hasOwnProp(n,"transitional")?n.transitional:void 0;if(!ve.isUndefined(l))if(ve.isPlainObject(l)){if(ve.hasOwnProp(l,a))return l[a]}else return;const u=ve.hasOwnProp(e,"transitional")?e.transitional:void 0;if(ve.isPlainObject(u)&&ve.hasOwnProp(u,a))return u[a]}function s(a,l,u){if(ve.hasOwnProp(n,u))return r(a,l);if(ve.hasOwnProp(e,u))return r(void 0,a)}const p={url:h,method:h,data:h,baseURL:g,transformRequest:g,transformResponse:g,paramsSerializer:g,timeout:g,timeoutErrorMessage: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:s,headers:(a,l,u)=>c(Ew(a),Ew(l),u,!0)};return ve.forEach(xL({...e,...n}),function(a){if(a==="__proto__"||a==="constructor"||a==="prototype")return;const l=ve.hasOwnProp(p,a)?p[a]:c,u=ve.hasOwnProp(e,a)?e[a]:void 0,d=ve.hasOwnProp(n,a)?n[a]:void 0,o=l(u,d,a);ve.isUndefined(o)&&l!==s||(t[a]=o)}),ve.hasOwnProp(n,"validateStatus")&&ve.isUndefined(n.validateStatus)&&v("validateStatusUndefinedResolves")===!1&&(ve.hasOwnProp(e,"validateStatus")?t.validateStatus=r(void 0,e.validateStatus):delete t.validateStatus),t}const CL=["content-type","content-length"];function kL(e,n,t){if(t!=="content-only"){e.set(n);return}Object.entries(n||{}).forEach(([r,c])=>{CL.includes(r.toLowerCase())&&e.set(r,c)})}const _L=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(n,t)=>String.fromCharCode(parseInt(t,16)));function Iw(e){const n=xa({},e),t=u=>ve.hasOwnProp(n,u)?n[u]:void 0,r=t("data");let c=t("withXSRFToken");const h=t("xsrfHeaderName"),g=t("xsrfCookieName");let v=t("headers");const s=t("auth"),p=t("baseURL"),a=t("allowAbsoluteUrls"),l=t("url");if(n.headers=v=Qr.from(v),n.url=pw(Tw(p,l,a,n),t("params"),t("paramsSerializer")),s){const u=ve.getSafeProp(s,"username")||"",d=ve.getSafeProp(s,"password")||"";try{v.set("Authorization","Basic "+btoa(u+":"+(d?_L(d):"")))}catch(o){throw nt.from(o,nt.ERR_BAD_OPTION_VALUE,e)}}if(ve.isFormData(r)){const u=ve.getSafeProp(r,"getHeaders");Rr.hasStandardBrowserEnv||Rr.hasStandardBrowserWebWorkerEnv||ve.isReactNative(r)?v.setContentType(void 0):ve.isFunction(u)&&kL(v,u.call(r),t("formDataHeaderPolicy"))}if(Rr.hasStandardBrowserEnv&&(ve.isFunction(c)&&(c=c(n)),c===!0||c==null&&pL(n.url))){const u=h&&g&&gL.read(g);u&&v.set(h,u)}return n}const AL=typeof XMLHttpRequest<"u",$L=AL&&function(e){return new Promise(function(n,t){const r=Iw(e);let c=r.data;const h=Qr.from(r.headers).normalize();let{responseType:g,onUploadProgress:v,onDownloadProgress:s}=r,p,a,l,u,d,o;function f(){u&&u(),d&&d(),r.cancelToken&&r.cancelToken.unsubscribe(p),r.signal&&r.signal.removeEventListener("abort",p)}let m=new XMLHttpRequest;m.open(r.method.toUpperCase(),r.url,!0),m.timeout=r.timeout;function w(R){if(!m)return;if(m.status===0&&(Xf(_w(r.url))||Xf(Rr.origin))!=="file"&&!(m.responseURL&&m.responseURL.startsWith("file:"))){t(new nt("Request aborted",nt.ECONNABORTED,e,m)),f(),m=null;return}try{R?o&&o(R):d&&d()}catch(C){setTimeout(()=>{throw C})}if(!m)return;const T=Qr.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders()),_={data:!g||g==="text"||g==="json"?m.responseText:m.response,status:m.status,statusText:m.statusText,headers:T,config:e,request:m};kw(function(C){n(C),f()},function(C){t(C),f()},_),m=null}"onloadend"in m?m.onloadend=w:m.onreadystatechange=function(){!m||m.readyState!==4||m.status===0&&!(m.responseURL&&m.responseURL.startsWith("file:"))||setTimeout(w)},m.onabort=function(){m&&(t(new nt("Request aborted",nt.ECONNABORTED,e,m)),f(),m=null)},m.onerror=function(R){const T=R&&R.message?R.message:"Network Error",_=new nt(T,nt.ERR_NETWORK,e,m);_.event=R||null,t(_),f(),m=null},m.ontimeout=function(){let R=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const T=r.transitional||Kf;r.timeoutErrorMessage&&(R=r.timeoutErrorMessage),t(new nt(R,T.clarifyTimeoutError?nt.ETIMEDOUT:nt.ECONNABORTED,e,m)),f(),m=null},c===void 0&&h.setContentType(null),"setRequestHeader"in m&&ve.forEach(aw(h),function(R,T){m.setRequestHeader(T,R)}),ve.isUndefined(r.withCredentials)||(m.withCredentials=!!r.withCredentials),g&&g!=="json"&&(m.responseType=r.responseType),s&&([l,d,o]=Ou(s,!0),m.addEventListener("progress",l)),v&&m.upload&&([a,u]=Ou(v),m.upload.addEventListener("progress",a),m.upload.addEventListener("loadend",u)),(r.cancelToken||r.signal)&&(p=R=>{m&&(t(!R||R.type?new hc(null,e,m):R),m.abort(),f(),m=null)},r.cancelToken&&r.cancelToken.subscribe(p),r.signal&&(r.signal.aborted?p():r.signal.addEventListener("abort",p)));const x=Xf(r.url);if(x&&!Rr.protocols.includes(x)){t(new nt("Unsupported protocol "+x+":",nt.ERR_BAD_REQUEST,e)),f();return}m.send(c||null)})},SL=(e,n)=>{if(e=e?e.filter(Boolean):[],!n&&!e.length)return;const t=new AbortController;let r=!1;const c=function(s){if(!r){r=!0,g();const p=s instanceof Error?s:this.reason;t.abort(p instanceof nt?p:new hc(p instanceof Error?p.message:p))}};let h=n&&setTimeout(()=>{h=null,c(new nt(`timeout of ${n}ms exceeded`,nt.ETIMEDOUT))},n);const g=()=>{e&&(h&&clearTimeout(h),h=null,e.forEach(s=>{s.unsubscribe?s.unsubscribe(c):s.removeEventListener("abort",c)}),e=null)};e.forEach(s=>{if(!r){if(s.aborted){c.call(s);return}s.addEventListener("abort",c,{once:!0})}});const{signal:v}=t;return v.unsubscribe=()=>ve.asap(g),v},TL=function*(e,n){let t=e.byteLength;if(t<n){yield e;return}let r=0,c;for(;r<t;)c=r+n,yield e.slice(r,c),r=c},EL=async function*(e,n){for await(const t of IL(e))yield*TL(t,n)},IL=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const n=e.getReader();try{for(;;){const{done:t,value:r}=await n.read();if(t)break;yield r}}finally{await n.cancel()}},Mw=(e,n,t,r)=>{const c=EL(e,n);let h=0,g,v=s=>{g||(g=!0,r&&r(s))};return new ReadableStream({async pull(s){try{const{done:p,value:a}=await c.next();if(p){v(),s.close();return}let l=a.byteLength;if(t){let u=h+=l;t(u)}s.enqueue(new Uint8Array(a))}catch(p){throw v(p),p}},cancel(s){return v(s),c.return()}},{highWaterMark:2})},Rw=e=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102,Lw=(e,n,t)=>n+2<t&&Rw(e.charCodeAt(n+1))&&Rw(e.charCodeAt(n+2)),Ow=e=>e<=57?e-48:(e&223)-55,ML=e=>e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||e===43||e===47||e===45||e===95,RL=e=>e===9||e===10||e===12||e===13||e===32,LL=e=>{const n=Math.floor(e/4),t=e%4;return n*3+(t===2?1:t===3?2:0)},OL=e=>{const n=e.length;let t=0;return n>0&&e.charCodeAt(n-1)===61&&(t++,n>1&&e.charCodeAt(n-2)===61&&t++),Math.floor((n-t)*3/4)},NL=e=>{const n=e.length;let t=0,r=0,c=!1;for(let h=0;h<n;h++){let g=e.charCodeAt(h);if(g===37&&Lw(e,h,n)&&(g=Ow(e.charCodeAt(h+1))*16+Ow(e.charCodeAt(h+2)),h+=2),!RL(g)){if(g===61){r++;continue}if(!ML(g)||r>0){c=!0;continue}t++}}return c||r>2||r>0&&(t+r)%4!==0||t%4===1?OL(e):LL(t)},DL=(e,n)=>{if(!e||typeof e!="string"||!e.startsWith("data:"))return 0;const t=e.indexOf(",");if(t<0)return 0;const r=e.slice(5,t),c=e.slice(t+1);if(/;base64/i.test(r))return n(c);let h=0;for(let g=0,v=c.length;g<v;g++){const s=c.charCodeAt(g);if(s===37&&Lw(c,g,v))h+=1,g+=2;else if(s<128)h+=1;else if(s<2048)h+=2;else if(s>=55296&&s<=56319&&g+1<v){const p=c.charCodeAt(g+1);p>=56320&&p<=57343?(h+=4,g++):h+=3}else h+=3}return h};function PL(e){const n=typeof e=="string"?e.indexOf("#"):-1;return DL(n===-1?e:e.slice(0,n),NL)}const ep="1.20.0",Nw=64*1024,zL={cache:"default",redirect:"follow",referrer:"about:client",referrerPolicy:"",mode:"cors",integrity:"",keepalive:!1,priority:"auto",window:null},{isFunction:Nu}=ve,BL=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(n,t)=>String.fromCharCode(parseInt(t,16))),Dw=e=>{if(!ve.isString(e))return e;try{return decodeURIComponent(e)}catch{return e}},Pw=(e,...n)=>{try{return!!e(...n)}catch{return!1}},FL=e=>{const n=e.indexOf("://");let t=e;return n!==-1&&(t=t.slice(n+3)),t.includes("@")||t.includes(":")},jL=e=>{const n=ve.global!==void 0&&ve.global!==null?ve.global:globalThis,{ReadableStream:t,TextEncoder:r}=n;e=ve.merge.call({skipUndefined:!0},{Request:n.Request,Response:n.Response},e);const{fetch:c,Request:h,Response:g}=e,v=c?Nu(c):typeof fetch=="function",s=Nu(h),p=Nu(g);if(!v)return!1;const a=v&&Nu(t),l=v&&(typeof r=="function"?(w=>x=>w.encode(x))(new r):async w=>new Uint8Array(await new h(w).arrayBuffer())),u=s&&a&&Pw(()=>{let w=!1;const x=new h(Rr.origin,{body:new t,method:"POST",get duplex(){return w=!0,"half"}}),R=x.headers.has("Content-Type");return x.body!=null&&x.body.cancel(),w&&!R}),d=p&&a&&Pw(()=>ve.isReadableStream(new g("").body)),o={stream:d&&(w=>w.body)};v&&["text","arrayBuffer","blob","formData","stream"].forEach(w=>{!o[w]&&(o[w]=(x,R)=>{let T=x&&x[w];if(T)return T.call(x);throw new nt(`Response type '${w}' is not supported`,nt.ERR_NOT_SUPPORT,R)})});const f=async w=>{if(w==null)return 0;if(ve.isBlob(w))return w.size;if(ve.isSpecCompliantForm(w))return(await new h(Rr.origin,{method:"POST",body:w}).arrayBuffer()).byteLength;if(ve.isArrayBufferView(w)||ve.isArrayBuffer(w))return w.byteLength;if(ve.isURLSearchParams(w)&&(w=w+""),ve.isString(w))return(await l(w)).byteLength},m=async(w,x)=>ve.toFiniteNumber(w.getContentLength())??f(x);return async w=>{let{url:x,method:R,data:T,signal:_,cancelToken:C,timeout:P,onDownloadProgress:O,onUploadProgress:E,responseType:k,headers:B,withCredentials:N="same-origin",fetchOptions:M,maxContentLength:$,maxBodyLength:A,maxRedirects:D}=Iw(w);const j=ve.isNumber($)&&$>-1,U=ve.isNumber(A)&&A>-1,q=ee=>ve.hasOwnProp(w,ee)?w[ee]:void 0;let Q=c||fetch;k=k?(k+"").toLowerCase():"text";let re=SL([_,C&&C.toAbortSignal()],P),le=null;const ne=re&&re.unsubscribe&&(()=>{re.unsubscribe()});let ue,he=null;const oe=()=>new nt("Request body larger than maxBodyLength limit",nt.ERR_BAD_REQUEST,w,le);try{let ee;const ye=q("auth");if(ye){const Ie=ve.getSafeProp(ye,"username")||"",Ct=ve.getSafeProp(ye,"password")||"";ee={username:Ie,password:Ct}}if(FL(x)){const Ie=new URL(x,Rr.origin);if(!ee&&(Ie.username||Ie.password)){const Ct=Dw(Ie.username),St=Dw(Ie.password);ee={username:Ct,password:St}}(Ie.username||Ie.password)&&(Ie.username="",Ie.password="",x=Ie.href)}if(ee&&(B.delete("authorization"),B.set("Authorization","Basic "+btoa(BL((ee.username||"")+":"+(ee.password||""))))),j&&typeof x=="string"&&x.startsWith("data:")&&PL(x)>$)throw new nt("maxContentLength size of "+$+" exceeded",nt.ERR_BAD_RESPONSE,w,le);if(U&&R!=="get"&&R!=="head"){const Ie=await f(T);if(typeof Ie=="number"&&isFinite(Ie)&&(ue=Ie,Ie>A))throw oe()}const we=U&&(ve.isReadableStream(T)||ve.isStream(T)),Ae=(Ie,Ct,St)=>Mw(Ie,Nw,Vt=>{if(U&&Vt>A)throw he=oe();Ct&&Ct(Vt)},St);if(u&&R!=="get"&&R!=="head"&&(E||we)){if(ue=ue??await m(B,T),ue!==0||we){let Ie=new h(x,{method:"POST",body:T,duplex:"half"}),Ct;if(ve.isFormData(T)&&(Ct=Ie.headers.get("content-type"))&&B.setContentType(Ct),Ie.body){const[St,Vt]=E&&Aw(ue,Ou($w(E)))||[];T=Ae(Ie.body,St,Vt)}}}else if(we&&!s&&a&&R!=="get"&&R!=="head")T=Ae(T);else if(we&&s&&!u&&R!=="get"&&R!=="head")throw new nt("Stream request bodies are not supported by the current fetch implementation",nt.ERR_NOT_SUPPORT,w,le);ve.isString(N)||(N=N?"include":"omit");const Je=s&&"credentials"in h.prototype;if(ve.isFormData(T)){const Ie=B.getContentType();Ie&&/^multipart\/form-data/i.test(Ie)&&!/boundary=/i.test(Ie)&&B.delete("content-type")}B.set("User-Agent","axios/"+ep,!1);const ze=M==null?M:Object.assign(Object.create(null),M);ze&&(delete ze.body,delete ze.headers,delete ze.method,delete ze.signal,delete ze.duplex,delete ze.credentials);const Ye=Object.assign(Object.create(null),ze,{signal:re,method:R.toUpperCase(),headers:aw(B.normalize()),body:T,duplex:"half",credentials:Je?N:void 0});s&&(ve.forEach(zL,(Ie,Ct)=>{Ye[Ct]===void 0&&(Ye[Ct]=Ie)}),Ye.signal===void 0&&(Ye.signal=null),Ye.body===void 0&&(Ye.body=null)),D===0&&(Ye.redirect="manual",ze&&(ze.redirect="manual")),le=s&&new h(x,Ye);let Ze=await(s?Q(le,ze):Q(x,Ye));const at=Qr.from(Ze.headers);if(j){const Ie=ve.toFiniteNumber(at.getContentLength());if(Ie!=null&&Ie>$)throw new nt("maxContentLength size of "+$+" exceeded",nt.ERR_BAD_RESPONSE,w,le)}const ct=d&&(k==="stream"||k==="response");if(d&&Ze.body&&(O||j||ct&&ne)){const Ie={};["status","statusText","headers"].forEach(mt=>{Ie[mt]=Ze[mt]});const Ct=ve.toFiniteNumber(at.getContentLength()),[St,Vt]=O&&Aw(Ct,Ou($w(O),!0))||[];let hn=0;const $n=mt=>{if(j&&(hn=mt,hn>$))throw new nt("maxContentLength size of "+$+" exceeded",nt.ERR_BAD_RESPONSE,w,le);St&&St(mt)};Ze=new g(Mw(Ze.body,Nw,$n,()=>{Vt&&Vt(),ne&&ne()}),Ie)}k=k||"text";let Ft=await o[ve.findKey(o,k)||"text"](Ze,w);if(j&&!d&&!ct){let Ie;if(Ft!=null&&(typeof Ft.byteLength=="number"?Ie=Ft.byteLength:typeof Ft.size=="number"?Ie=Ft.size:typeof Ft=="string"&&(Ie=typeof r=="function"?new r().encode(Ft).byteLength:Ft.length)),typeof Ie=="number"&&Ie>$)throw new nt("maxContentLength size of "+$+" exceeded",nt.ERR_BAD_RESPONSE,w,le)}return!ct&&ne&&ne(),await new Promise((Ie,Ct)=>{kw(Ie,Ct,{data:Ft,headers:Qr.from(Ze.headers),status:Ze.status,statusText:Ze.statusText,config:w,request:le})})}catch(ee){if(ne&&ne(),re&&re.aborted&&re.reason instanceof nt){const ye=re.reason;throw ye.config=w,le&&(ye.request=le),ee!==ye&&Object.defineProperty(ye,"cause",{__proto__:null,value:ee,writable:!0,enumerable:!1,configurable:!0}),ye}if(he)throw le&&!he.request&&(he.request=le),he;if(ee instanceof nt)throw le&&!ee.request&&(ee.request=le),ee;if(ee&&ee.name==="TypeError"&&/Load failed|fetch/i.test(ee.message)){const ye=new nt("Network Error",nt.ERR_NETWORK,w,le,ee&&ee.response);throw Object.defineProperty(ye,"cause",{__proto__:null,value:ee.cause||ee,writable:!0,enumerable:!1,configurable:!0}),ye}throw nt.from(ee,ee&&ee.code,w,le,ee&&ee.response)}}},WL=new Map,zw=e=>{let n=e&&e.env||{};const{fetch:t,Request:r,Response:c}=n,h=[r,c,t];let g=h.length,v=g,s,p,a=WL;for(;v--;)s=h[v],p=a.get(s),p===void 0&&a.set(s,p=v?new Map:jL(n)),a=p;return p};zw();const tp={http:KR,xhr:$L,fetch:{get:zw}};ve.forEach(tp,(e,n)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:n})}catch{}Object.defineProperty(e,"adapterName",{__proto__:null,value:n})}});const Bw=e=>`- ${e}`,HL=e=>ve.isFunction(e)||e===null||e===!1;function UL(e,n){e=ve.isArray(e)?e:[e];const{length:t}=e;let r,c;const h={};for(let g=0;g<t;g++){r=e[g];let v;if(c=r,!HL(r)&&(c=tp[(v=String(r)).toLowerCase()],c===void 0))throw new nt(`Unknown adapter '${v}'`);if(c&&(ve.isFunction(c)||(c=c.get(n))))break;h[v||"#"+g]=c}if(!c){const g=Object.entries(h).map(([s,p])=>`adapter ${s} `+(p===!1?"is not supported by the environment":"is not available in the build"));let v=t?g.length>1?`since :
1483
+ `+g.map(Bw).join(`
1484
+ `):" "+Bw(g[0]):"as no adapter specified";throw new nt("There is no suitable adapter to dispatch the request "+v,nt.ERR_NOT_SUPPORT)}return c}const Fw={getAdapter:UL,adapters:tp};function np(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new hc(null,e)}function rp(e){const n=ve.toSafeFlatObject(e);return np(n),n.headers=Qr.from(ve.getSafeProp(n,"headers")),n.data=Zf.call(n,n.transformRequest),["post","put","patch"].indexOf(n.method)!==-1&&n.headers.setContentType("application/x-www-form-urlencoded",!1),Fw.getAdapter(n.adapter||uc.adapter,n)(n).then(function(t){np(n),n.response=t;try{t.data=Zf.call(n,n.transformResponse,t)}finally{delete n.response}return t.headers=Qr.from(t.headers),t},function(t){if(!Cw(t)&&(np(n),t&&t.response)){n.response=t.response;try{t.response.data=Zf.call(n,n.transformResponse,t.response)}finally{delete n.response}t.response.headers=Qr.from(t.response.headers)}return Promise.reject(t)})}const Du={};["object","boolean","number","function","string","symbol"].forEach((e,n)=>{Du[e]=function(t){return typeof t===e||"a"+(n<1?"n ":" ")+e}});const jw={};Du.transitional=function(e,n,t){function r(c,h){return"[Axios v"+ep+"] Transitional option '"+c+"'"+h+(t?". "+t:"")}return(c,h,g)=>{if(e===!1)throw new nt(r(h," has been removed"+(n?" in "+n:"")),nt.ERR_DEPRECATED);return n&&!jw[h]&&(jw[h]=!0,console.warn(r(h," has been deprecated since v"+n+" and will be removed in the near future"))),e?e(c,h,g):!0}},Du.spelling=function(e){return(n,t)=>(console.warn(`${t} is likely a misspelling of ${e}`),!0)};function VL(e,n,t){if(typeof e!="object"||e===null)throw new nt("options must be an object",nt.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let c=r.length;for(;c-- >0;){const h=r[c],g=Object.prototype.hasOwnProperty.call(n,h)?n[h]:void 0;if(g){const v=e[h],s=v===void 0||g(v,h,e);if(s!==!0)throw new nt("option "+h+" must be "+s,nt.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new nt("Unknown option "+h,nt.ERR_BAD_OPTION)}}const Pu={assertOptions:VL,validators:Du},Zr=Pu.validators;let Ca=class{constructor(e){this.defaults=e||{},this.interceptors={request:new vw,response:new vw}}async request(e,n){try{return await this._request(e,n)}catch(t){if(t instanceof Error)try{let r={};Error.captureStackTrace?Error.captureStackTrace(r):r=new Error;const c=r.stack;let h="";if(typeof c=="string"){const g=c.indexOf(`
1485
+ `);h=g===-1?"":c.slice(g+1)}if(!t.stack)t.stack=h;else if(h){const g=h.indexOf(`
1486
+ `),v=g===-1?-1:h.indexOf(`
1487
+ `,g+1),s=v===-1?"":h.slice(v+1);String(t.stack).endsWith(s)||(t.stack+=`
1488
+ `+h)}}catch{}throw t}}_request(e,n){typeof e=="string"?(n=n||{},n.url=e):n=e||{},n=xa(this.defaults,n);const{transitional:t,paramsSerializer:r,headers:c}=n;t!==void 0&&Pu.assertOptions(t,{silentJSONParsing:Zr.transitional(Zr.boolean),forcedJSONParsing:Zr.transitional(Zr.boolean),clarifyTimeoutError:Zr.transitional(Zr.boolean),legacyInterceptorReqResOrdering:Zr.transitional(Zr.boolean),advertiseZstdAcceptEncoding:Zr.transitional(Zr.boolean),validateStatusUndefinedResolves:Zr.transitional(Zr.boolean)},!1),r!=null&&(ve.isFunction(r)?n.paramsSerializer={serialize:r}:Pu.assertOptions(r,{encode:Zr.function,serialize:Zr.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),Pu.assertOptions(n,{baseUrl:Zr.spelling("baseURL"),withXsrfToken:Zr.spelling("withXSRFToken")},!0),n.method=(ve.getSafeProp(n,"method")||ve.getSafeProp(this.defaults,"method")||"get").toLowerCase();let h=c&&ve.merge(c.common,c[n.method]);c&&ve.forEach(xw.concat("common"),d=>{delete c[d]}),n.headers=Qr.concat(h,c);const g=[];let v=!0;this.interceptors.request.forEach(function(d){if(typeof d.runWhen=="function"&&d.runWhen(n)===!1)return;v=v&&d.synchronous;const o=n.transitional||Kf;o&&o.legacyInterceptorReqResOrdering?g.unshift(d.fulfilled,d.rejected):g.push(d.fulfilled,d.rejected)});const s=[];this.interceptors.response.forEach(function(d){s.push(d.fulfilled,d.rejected)});let p,a=0,l;if(!v){const d=[rp.bind(this),void 0];for(d.unshift(...g),d.push(...s),l=d.length,p=Promise.resolve(n);a<l;)p=p.then(d[a++],d[a++]);return p}l=g.length;let u=n;for(;a<l;){const d=g[a++],o=g[a++];try{u=d?d(u):u}catch(f){if(!o){p=Promise.reject(f);break}try{const m=o.call(this,f);ve.isThenable(m)&&(p=Promise.resolve(m).then(()=>rp.call(this,u)))}catch(m){p=Promise.reject(m)}break}}if(!p)try{p=rp.call(this,u)}catch(d){p=Promise.reject(d)}for(a=0,l=s.length;a<l;)p=p.then(s[a++],s[a++]);return p}getUri(e){e=xa(this.defaults,e);const n=Tw(e.baseURL,e.url,e.allowAbsoluteUrls,e);return pw(n,e.params,e.paramsSerializer)}};ve.forEach(["delete","get","head","options"],function(e){Ca.prototype[e]=function(n,t){return this.request(xa(t||{},{method:e,url:n,data:t&&ve.hasOwnProp(t,"data")?t.data:void 0}))}}),ve.forEach(["post","put","patch","query"],function(e){function n(t){return function(r,c,h){return this.request(xa(h||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:c}))}}Ca.prototype[e]=n(),e!=="query"&&(Ca.prototype[e+"Form"]=n(!0))});let GL=class lk{constructor(n){if(typeof n!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(c){t=c});const r=this;this.promise.then(c=>{if(!r._listeners)return;let h=r._listeners.length;for(;h-- >0;)r._listeners[h](c);r._listeners=null}),this.promise.then=c=>{let h;const g=new Promise(v=>{r.subscribe(v),h=v}).then(c);return g.cancel=function(){r.unsubscribe(h)},g},n(function(c,h,g){r.reason||(r.reason=new hc(c,h,g),t(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 t=this._listeners.indexOf(n);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const n=new AbortController,t=r=>{n.abort(r)};return this.subscribe(t),n.signal.unsubscribe=()=>this.unsubscribe(t),n.signal}static source(){let n;return{token:new lk(function(t){n=t}),cancel:n}}};function qL(e){return function(n){return e.apply(null,n)}}function YL(e){return ve.isObject(e)&&e.isAxiosError===!0}const zu={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,ContentTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,UnprocessableContent: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,WebServerReturnsAnUnknownError:520,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(zu).forEach(([e,n])=>{zu[n]===void 0&&(zu[n]=e)});function Ww(e){const n=new Ca(e),t=Y0(Ca.prototype.request,n);return ve.extend(t,Ca.prototype,n,{allOwnKeys:!0}),ve.extend(t,n,null,{allOwnKeys:!0}),t.create=function(r){return Ww(xa(e,r))},t}const gr=lr("A",Ww(uc));gr.Axios=Ca,gr.CanceledError=hc,gr.CancelToken=GL,gr.isCancel=Cw,gr.VERSION=ep,gr.toFormData=Lu,gr.AxiosError=nt,gr.Cancel=gr.CanceledError,gr.all=function(e){return Promise.all(e)},gr.spread=qL,gr.isAxiosError=YL,gr.mergeConfig=xa,gr.AxiosHeaders=Qr,gr.formToJSON=e=>ww(ve.isHTMLForm(e)?new FormData(e):e),gr.getAdapter=Fw.getAdapter,gr.HttpStatusCode=zu,gr.default=gr;const{Axios:k3,AxiosError:_3,CanceledError:A3,isCancel:$3,CancelToken:S3,VERSION:T3,all:E3,Cancel:I3,isAxiosError:M3,spread:R3,toFormData:L3,AxiosHeaders:O3,HttpStatusCode:N3,formToJSON:D3,getAdapter:P3,mergeConfig:z3,create:B3}=gr,KL="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=",JL={props:{status:{type:String,required:!0},large:{type:Boolean},small:{type:Boolean},scale:{type:Number,default:1}},computed:{icons:function(){return KL},scaleFactor:function(){return this.scale?this.scale:this.large?1:this.small?.3:.5},iconStyle:function(){const e=rO.indexOf(dc[this.status]),n=1-(e-1)*.05,t=224*this.scaleFactor*n,r=32*this.scaleFactor*n,c=32*this.scaleFactor*n;return[`background-image: url(${this.icons});`,`background-position-x: -${e*c}px;`,`background-size: ${t}px ${r}px;`,`height: ${c}px;`,`width: ${c}px;`,`padding-top: ${e-1}px;`].join("")}}};function QL(e,n,t,r,c,h){return wt(),Xt("div",{style:Un(h.iconStyle)},null,4)}const ZL=ra(JL,[["render",QL]]),XL={props:{icon:{type:String,default:null},size:{type:String,default:"small"},color:{type:String,default:"white"}},computed:{colorStyle:function(){return{"--iconColor":this.color}}}};function eO(e,n,t,r,c,h){const g=In("rux-icon");return wt(),er(g,{size:t.size,icon:t.icon,style:Un(h.colorStyle)},null,8,["size","icon","style"])}const tO=ra(XL,[["render",eO],["__scopeId","data-v-bb4cd487"]]),dc={fatal:"fatal",FATAL:"fatal",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"},fc={fatal:"#ff69B4",critical:"#ff3838",serious:"#ffb302",caution:"#fce83a",normal:"#56f000",standby:"#2dccff",off:"#a4abb6"},nO=function(e){const n="#000000",t="#ffffff",r=fc[dc[e]];if(r){const c=+`0x${r.slice(1,3)}`,h=+`0x${r.slice(3,5)}`,g=+`0x${r.slice(5,7)}`;if((c*299+h*587+g*114)/1e3>128)return n}return t},rO=Object.keys(fc),iO={astro:{component:e=>Eo(tO,{...e})},"astro-status":{component:e=>Eo(ZL,{...e,status:e.icon})}},oO={extras:{component:e=>Eo(Ak,{...e})}},sO={mixins:[PM],props:{historyCount:{type:Number,default:200},timeZone:{type:String,default:"local"}},data(){return{AstroStatusColors:fc,data:[],shownData:[],logLevels:["DEBUG","INFO","WARN","ERROR","FATAL"],logLevel:"INFO",search:"",headers:[{title:"Time",value:"timestamp",nowrap:!0},{title:"Level",value:"level"},{title:"Source",value:"microservice_name"},{title:"Message",value:"message"}],cable:new Av,subscription:null,paused:!1}},computed:{buttonIcon:function(){return this.paused?"mdi-play":"mdi-pause"}},watch:{logLevel:function(e,n){this.createSubscription()}},created(){this.createSubscription()},unmounted(){this.subscription&&this.subscription.unsubscribe(),this.cable.disconnect()},methods:{pause:function(){this.paused=!this.paused},createSubscription(){this.subscription&&(this.subscription.unsubscribe(),this.data=[],this.shownData=this.data),this.cable.createSubscription("MessagesChannel",window.openc3Scope,{received:e=>{this.cable.recordPing(),e.length>this.historyCount&&e.splice(0,e.length-this.historyCount),e=e.filter(n=>{switch(this.logLevel){case"DEBUG":return!0;case"INFO":if(n.level!=="DEBUG")return!0;break;case"WARN":if(n.level!=="DEBUG"&&n.level!=="INFO")return!0;break;case"ERROR":if(n.level!=="DEBUG"&&n.level!=="INFO"&&n.level!=="WARN")return!0;break;case"FATAL":if(n.level!=="DEBUG"&&n.level!=="INFO"&&n.level!=="WARN"&&n.level!=="ERROR")return!0;break}return!1}),e.map(n=>{if(n.timestamp=this.formatTimestamp(n["@timestamp"],this.timeZone),n.message.raw&&n.message.json_class==="String"){let t="0x";for(let r=0;r<n.message.raw.length;r++)t+=n.message.raw[r].toString(16).padStart(2,"0").toUpperCase();n.message=t}else n.message=n.message.replaceAll("\\n",`
1489
+ `)}),this.data=e.reverse().concat(this.data),this.data.length>this.historyCount&&(this.data.length=this.historyCount),this.paused||(this.shownData=this.data)}},{history_count:this.historyCount,types:["log","notification","alert"]}).then(e=>{this.subscription=e})},getColor(e){return fc[dc[e]]},getStatus(e){return dc[e]},downloadLog(){const e=this.shownData.sort((r,c)=>r.time-c.time).map(r=>`${r.timestamp} | ${r.level} | ${r.microservice_name} | ${r.message}`).join(`
1490
+ `),n=new Blob([e],{type:"text/plain"}),t=document.createElement("a");t.href=URL.createObjectURL(n),t.setAttribute("download",Ds(Date.now(),"yyyy_MM_dd_HH_mm_ss")+"_message_log.txt"),t.click()},clearLog:function(){this.$dialog.confirm("Are you sure you want to clear the log?",{okText:"Clear",cancelText:"Cancel"}).then(e=>{this.data=[],this.shownData=[]}).catch(function(e){})}}},aO={class:"d-flex align-baseline"},lO=["title","datetime"],cO={style:{"white-space":"pre-wrap"}};function uO(e,n,t,r,c,h){const g=In("v-btn"),v=In("v-spacer"),s=In("v-select"),p=In("v-text-field"),a=In("v-card-title"),l=In("v-icon"),u=In("rux-status"),d=In("v-data-table"),o=In("v-card");return wt(),er(o,null,{default:sn(()=>[Ge(a,{class:"d-flex align-center justify-content-space-between"},{default:sn(()=>[gt("div",aO,[Ge(g,{icon:"mdi-download",variant:"text",size:"small",class:"mr-2","data-test":"download-log",onClick:h.downloadLog},null,8,["onClick"]),n[2]||(n[2]=gt("span",null," Log Messages ",-1)),Ge(g,{icon:h.buttonIcon,variant:"text","data-test":"pause",onClick:h.pause},null,8,["icon","onClick"])]),Ge(v),Ge(s,{modelValue:c.logLevel,"onUpdate:modelValue":n[0]||(n[0]=f=>c.logLevel=f),label:"Filter by log level","hide-details":"",variant:"outlined",density:"compact",items:c.logLevels,class:"mr-2",style:{"max-width":"150px"},"data-test":"log-messages-level"},null,8,["modelValue","items"]),Ge(v),Ge(p,{modelValue:c.search,"onUpdate:modelValue":n[1]||(n[1]=f=>c.search=f),label:"Search","prepend-inner-icon":"mdi-magnify",clearable:"",variant:"outlined",density:"compact","single-line":"","hide-details":"",style:{"max-width":"300px"},class:"search","data-test":"search-log-messages"},null,8,["modelValue"]),Ge(g,{icon:"mdi-delete-sweep",variant:"text",class:"ml-2","data-test":"clear-log",onClick:h.clearLog},null,8,["onClick"])]),_:1}),Ge(d,{headers:c.headers,items:c.shownData,search:c.search,"items-per-page":-1,"hide-default-footer":"","sort-by":[{key:"time",order:"desc"}],density:"compact","fixed-header":"",hover:"","data-test":"log-messages"},{"item.timestamp":sn(({item:f})=>[gt("time",{title:f.timestamp,datetime:f.timestamp},xr(f.timestamp),9,lO)]),"item.level":sn(({item:f})=>[gt("span",{style:Un("display: inline-flex; align-items: center; color:"+h.getColor(f.level))},[f.level==="FATAL"?(wt(),er(l,{key:0,size:"16",class:"mr-1",style:{"margin-left":"-2px"}},{default:sn(()=>[...n[3]||(n[3]=[Wi(" mdi-alert-octagon ",-1)])]),_:1})):(wt(),er(u,{key:1,class:"mr-1",status:h.getStatus(f.level)},null,8,["status"])),Wi(" "+xr(f.level),1)],4)]),"item.message":sn(({item:f})=>[gt("div",cO,xr(f.message),1)]),_:1},8,["headers","items","search"])]),_:1})}const F3=lr("R",ra(sO,[["render",uO],["__scopeId","data-v-e8d11557"]])),hO=50,dO=2e3,Hw="single-spa:app-change",fO={data(){return{appsMounted:!1,show:!1,hideSpinner:!1,pollInterval:null}},computed:{showSpinner:function(){return!this.hideSpinner&&!this.show}},created(){window.addEventListener(Hw,this.handleAppChange)},mounted(){this.pollForMountedApps(),setTimeout(()=>{this.appsMounted||(this.show=!0,this.pollInterval&&clearInterval(this.pollInterval))},dO)},unmounted(){window.removeEventListener(Hw,this.handleAppChange),this.pollInterval&&clearInterval(this.pollInterval)},methods:{handleAppChange:function(e){this.show=!e.detail.appsByNewStatus.MOUNTED,this.hideSpinner=!0},pollForMountedApps:function(){this.pollInterval=setInterval(()=>{this.appsMounted=Vh().length>0,Vh().length>0&&(this.hideSpinner=!0,clearInterval(this.pollInterval))},hO)}}},pO={class:"mx-1"},gO={key:1,class:"d-flex justify-center align-center"};function mO(e,n,t,r,c,h){const g=In("v-card-title"),v=In("v-card-text"),s=In("v-card"),p=In("v-progress-circular");return wt(),Xt(Ir,null,[c.show?(wt(),er(s,{key:0},{default:sn(()=>[Ge(g,null,{default:sn(()=>[...n[0]||(n[0]=[Wi(" 404 Not Found ",-1)])]),_:1}),Ge(v,{class:"d-flex align-center mt-3"},{default:sn(()=>[n[1]||(n[1]=Wi(" The requested URL ",-1)),gt("code",pO,xr(e.$route.fullPath),1),n[2]||(n[2]=Wi(" was not routable. ",-1)),n[3]||(n[3]=gt("span",{class:"text-h3 mx-1"}," 🦄 ",-1))]),_:1})]),_:1})):qr("",!0),h.showSpinner?(wt(),Xt("div",gO,[Ge(p,{indeterminate:""})])):qr("",!0)],64)}const Uw=[{path:"",component:()=>dt(()=>ht.import("./CmdTlmServer-af3b7b8e2ea9bae2b3bd.js"),void 0),children:[{component:()=>dt(()=>ht.import("./InterfacesTab-06eb69d86c8c7763e5cf.js"),void 0),path:""},{component:()=>dt(()=>ht.import("./InterfacesTab-06eb69d86c8c7763e5cf.js"),void 0),name:"InterfacesTab",path:"interfaces"},{component:()=>dt(()=>ht.import("./TargetsTab-266cdd09e5f9024e2e14.js"),void 0),name:"TargetsTab",path:"targets"},{component:()=>dt(()=>ht.import("./CmdPacketsTab-6f0b12d43c14a7da6718.js"),void 0),name:"CmdPacketsTab",path:"cmd-packets"},{component:()=>dt(()=>ht.import("./TlmPacketsTab-a593eaef44a42f06465a.js"),void 0),name:"TlmPacketsTab",path:"tlm-packets"},{component:()=>dt(()=>ht.import("./RoutersTab-516132811cc284689266.js"),void 0),name:"RoutersTab",path:"routers"},{component:()=>dt(()=>ht.import("./DataFlowsTab-11ed530e003aefd013b6.js"),void 0),name:"DataFlowsTab",path:"data-flows"},{component:()=>dt(()=>ht.import("./StatusTab-8631fd8a07a20ba8efba.js"),void 0),name:"StatusTab",props:{refreshInterval:5e3},path:"status"}]},{path:"/:pathMatch(.*)*",name:"NotFound",component:ra(fO,[["render",mO]])}];Uw.forEach(e=>lm(e));const vO=nm({history:rm(),routes:Uw});function Vw(e,n){(n==null||n>e.length)&&(n=e.length);for(var t=0,r=Array(n);t<n;t++)r[t]=e[t];return r}function yO(e){if(Array.isArray(e))return e}function bO(e,n){var t=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(t!=null){var r,c,h,g,v=[],s=!0,p=!1;try{if(h=(t=t.call(e)).next,n!==0)for(;!(s=(r=h.call(t)).done)&&(v.push(r.value),v.length!==n);s=!0);}catch(a){p=!0,c=a}finally{try{if(!s&&t.return!=null&&(g=t.return(),Object(g)!==g))return}finally{if(p)throw c}}return v}}function wO(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
1491
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xO(e,n){return yO(e)||bO(e,n)||CO(e,n)||wO()}function CO(e,n){if(e){if(typeof e=="string")return Vw(e,n);var t={}.toString.call(e).slice(8,-1);return t==="Object"&&e.constructor&&(t=e.constructor.name),t==="Map"||t==="Set"?Array.from(e):t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?Vw(e,n):void 0}}const Gw=Object.entries,qw=Object.setPrototypeOf,kO=Object.isFrozen,Yw=Object.getPrototypeOf,Kw=Object.getOwnPropertyDescriptor;let Lr=Object.freeze,Br=Object.seal,ul=Object.create,Jw=typeof Reflect<"u"&&Reflect,ip=Jw.apply,op=Jw.construct;Lr||(Lr=function(e){return e}),Br||(Br=function(e){return e}),ip||(ip=function(e,n){for(var t=arguments.length,r=new Array(t>2?t-2:0),c=2;c<t;c++)r[c-2]=arguments[c];return e.apply(n,r)}),op||(op=function(e){for(var n=arguments.length,t=new Array(n>1?n-1:0),r=1;r<n;r++)t[r-1]=arguments[r];return new e(...t)});const ds=Vn(Array.prototype.forEach),_O=Vn(Array.prototype.lastIndexOf),Qw=Vn(Array.prototype.pop),pc=Vn(Array.prototype.push),AO=Vn(Array.prototype.slice),$O=Vn(Array.prototype.splice),hl=Array.isArray,sp=nx(Set),ap=Vn(Set.prototype.add),gc=Vn(Set.prototype.has),ka=Vn(String.prototype.toLowerCase),lp=Vn(String.prototype.toString),Zw=Vn(String.prototype.match),mc=Vn(String.prototype.replace),Xw=Vn(String.prototype.indexOf),SO=Vn(String.prototype.trim),TO=Vn(Number.prototype.toString),EO=Vn(Boolean.prototype.toString),ex=typeof BigInt>"u"?null:Vn(BigInt.prototype.toString),tx=typeof Symbol>"u"?null:Vn(Symbol.prototype.toString),_i=Vn(Object.prototype.hasOwnProperty),vc=Vn(Object.prototype.toString),Fr=Vn(RegExp.prototype.test),fs=nx(TypeError);function Vn(e){return function(n){n instanceof RegExp&&(n.lastIndex=0);for(var t=arguments.length,r=new Array(t>1?t-1:0),c=1;c<t;c++)r[c-1]=arguments[c];return ip(e,n,r)}}function nx(e){return function(){for(var n=arguments.length,t=new Array(n),r=0;r<n;r++)t[r]=arguments[r];return op(e,t)}}function un(e,n){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ka;if(qw&&qw(e,null),!hl(n))return e;let r=n.length;for(;r--;){let c=n[r];if(typeof c=="string"){const h=t(c);h!==c&&(kO(n)||(n[r]=h),c=h)}e[c]=!0}return e}function IO(e){for(let n=0;n<e.length;n++)_i(e,n)||(e[n]=null);return e}function qi(e){const n=ul(null);for(const r of Gw(e)){var t=xO(r,2);const c=t[0],h=t[1];_i(e,c)&&(hl(h)?n[c]=IO(h):h&&typeof h=="object"&&h.constructor===Object?n[c]=qi(h):n[c]=h)}return n}function MO(e){switch(typeof e){case"string":return e;case"number":return TO(e);case"boolean":return EO(e);case"bigint":return ex?ex(e):"0";case"symbol":return tx?tx(e):"Symbol()";case"undefined":return vc(e);case"function":case"object":{if(e===null)return vc(e);const n=e,t=ho(n,"toString");if(typeof t=="function"){const r=t(n);return typeof r=="string"?r:vc(r)}return vc(e)}default:return vc(e)}}function ho(e,n){for(;e!==null;){const r=Kw(e,n);if(r){if(r.get)return Vn(r.get);if(typeof r.value=="function")return Vn(r.value)}e=Yw(e)}function t(){return null}return t}function RO(e,n){for(;e!==null;){const t=Kw(e,n);if(t)return t.get?Vn(t.get):null;e=Yw(e)}return null}function LO(e){try{return Fr(e,""),!0}catch{return!1}}const rx=Lr(["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"]),cp=Lr(["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"]),up=Lr(["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"]),OO=Lr(["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"]),hp=Lr(["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"]),NO=Lr(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),ix=Lr(["#text"]),ox=Lr(["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"]),dp=Lr(["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","dominant-baseline","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","pointer-events","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-orientation","text-rendering","textlength","type","u1","u2","unicode","values","vector-effect","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"]),sx=Lr(["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"]),Bu=Lr(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),DO=Br(/{{[\w\W]*|^[\w\W]*}}/g),PO=Br(/<%[\w\W]*|^[\w\W]*%>/g),zO=Br(/\${[\w\W]*/g),BO=Br(/^data-[\-\w.\u00B7-\uFFFF]+$/),FO=Br(/^aria-[\-\w]+$/),ax=Br(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),jO=Br(/^(?:\w+script|data):/i),WO=Br(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),HO=Br(/^html$/i),UO=Br(/^[a-z][.\w]*(-[.\w]+)+$/i),fp=Br(/<[/\w!]/g),lx=Br(/<[/\w]/g),VO=Br(/<\/no(script|embed|frames)/i),cx=Br(/\/>/i),mr={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},GO=Lr(un({},["style","script","xmp","iframe","noembed","noframes","plaintext","noscript"])),qO=function(){return typeof window>"u"?null:window},YO=function(e,n){if(typeof e!="object"||typeof e.createPolicy!="function")return null;let t=null;const r="data-tt-policy-suffix";n&&n.hasAttribute(r)&&(t=n.getAttribute(r));const c="dompurify"+(t?"#"+t:"");try{return e.createPolicy(c,{createHTML(h){return h},createScriptURL(h){return h}})}catch{return console.warn("TrustedTypes policy "+c+" could not be created."),null}},ux=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},js=function(e,n,t,r){return _i(e,n)&&hl(e[n])?un(r.base?qi(r.base):{},e[n],r.transform):t},pp=function(e,n,t){const r=_i(e,n)?e[n]:void 0;return r&&typeof r=="object"?qi(r):t()};function hx(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:qO();const n=X=>hx(X);if(n.version="3.4.17",n.removed=[],!e||!e.document||e.document.nodeType!==mr.document||!e.Element)return n.isSupported=!1,n;let t=e.document;const r=t,c=r.currentScript;e.DocumentFragment;const h=e.HTMLTemplateElement,g=e.Node,v=e.Element,s=e.NodeFilter;e.NamedNodeMap===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;const p=e.DOMParser,a=e.trustedTypes,l=v.prototype,u=ho(l,"cloneNode"),d=ho(l,"remove"),o=ho(l,"removeAttributeNode"),f=ho(l,"nextSibling"),m=ho(l,"childNodes"),w=ho(l,"parentNode"),x=ho(l,"shadowRoot"),R=ho(l,"attributes"),T=g&&g.prototype?ho(g.prototype,"nodeType"):null,_=g&&g.prototype?ho(g.prototype,"nodeName"):null,C=g&&g.prototype?ho(g.prototype,"ownerDocument"):null,P=function(X){return T?T(X):X.nodeType},O=function(X){return _?_(X):X.nodeName},E=RO(l,"namespaceURI"),k=function(X){return E?E(X):X.namespaceURI};if(typeof h=="function"){const X=t.createElement("template");X.content&&X.content.ownerDocument&&(t=X.content.ownerDocument)}let B,N="",M,$=!1,A=0;const D=function(){if(A>0)throw fs('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},j=function(X){D(),A++;try{return B.createHTML(X)}finally{A--}},U=function(X){D(),A++;try{return B.createScriptURL(X)}finally{A--}},q=function(){return $||(M=YO(a,c),$=!0),M},Q=t,re=Q.implementation,le=Q.createNodeIterator,ne=Q.createDocumentFragment,ue=Q.getElementsByTagName,he=r.importNode;let oe=ux();n.isSupported=typeof Gw=="function"&&typeof w=="function"&&re&&re.createHTMLDocument!==void 0;const ee=DO,ye=PO,we=zO,Ae=BO,Je=FO,ze=jO,Ye=WO,Ze=UO;let at=ax,ct=null;const Ft=un({},[...rx,...cp,...up,...hp,...ix]);let Ie=null;const Ct=un({},[...ox,...dp,...sx,...Bu]);let St=Object.seal(ul(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}})),Vt=null,hn=null;const $n=Object.seal(ul(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let mt=!0,it=!0,Gt=!1,Fn=!0,Sn=!1,Dn=!0,Gn=!1,Ln=!1,qn=null,tr=null,dn=!1,Pn=!1,Ti=!1,Xr=!1,ei=!0,Ei=!1;const fo="user-content-";let vr=!0,Ji=!1,jr=null,po={},ur=null;const Hs=un({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]);let gs=null;const Ko=un({},["audio","video","img","source","image","track"]);let Ii=null;const Yn=un({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),$r="http://www.w3.org/1998/Math/MathML",Or="http://www.w3.org/2000/svg",mn="http://www.w3.org/1999/xhtml";let jn=mn,Mi=!1,hi=null;const ms=un({},[$r,Or,mn],lp),vs=Lr(["mi","mo","mn","ms","mtext"]);let ys=un({},vs);const bs=Lr(["annotation-xml"]);let di=un({},bs);const Ri=un({},["title","style","font","a","script"]);let Dt=null;const Us=["application/xhtml+xml","text/html"],Nr="text/html";let Pt=null,fn=null;const Kn=t.createElement("form"),go=function(X){return X instanceof RegExp||X instanceof Function},nr=function(){let X=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(fn&&fn===X)return;(!X||typeof X!="object")&&(X={}),X=qi(X),Dt=Us.indexOf(X.PARSER_MEDIA_TYPE)===-1?Nr:X.PARSER_MEDIA_TYPE,Pt=Dt==="application/xhtml+xml"?lp:ka,ct=js(X,"ALLOWED_TAGS",Ft,{transform:Pt}),Ie=js(X,"ALLOWED_ATTR",Ct,{transform:Pt}),hi=js(X,"ALLOWED_NAMESPACES",ms,{transform:lp}),Ii=js(X,"ADD_URI_SAFE_ATTR",Yn,{transform:Pt,base:Yn}),gs=js(X,"ADD_DATA_URI_TAGS",Ko,{transform:Pt,base:Ko}),ur=js(X,"FORBID_CONTENTS",Hs,{transform:Pt}),Vt=js(X,"FORBID_TAGS",qi({}),{transform:Pt}),hn=js(X,"FORBID_ATTR",qi({}),{transform:Pt}),po=_i(X,"USE_PROFILES")?X.USE_PROFILES&&typeof X.USE_PROFILES=="object"?qi(X.USE_PROFILES):X.USE_PROFILES:!1,mt=X.ALLOW_ARIA_ATTR!==!1,it=X.ALLOW_DATA_ATTR!==!1,Gt=X.ALLOW_UNKNOWN_PROTOCOLS||!1,Fn=X.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Sn=X.SAFE_FOR_TEMPLATES||!1,Dn=X.SAFE_FOR_XML!==!1,Gn=X.WHOLE_DOCUMENT||!1,Pn=X.RETURN_DOM||!1,Ti=X.RETURN_DOM_FRAGMENT||!1,Xr=X.RETURN_TRUSTED_TYPE||!1,dn=X.FORCE_BODY||!1,ei=X.SANITIZE_DOM!==!1,Ei=X.SANITIZE_NAMED_PROPS||!1,vr=X.KEEP_CONTENT!==!1,Ji=X.IN_PLACE||!1,at=LO(X.ALLOWED_URI_REGEXP)?X.ALLOWED_URI_REGEXP:ax,jn=typeof X.NAMESPACE=="string"?X.NAMESPACE:mn,ys=pp(X,"MATHML_TEXT_INTEGRATION_POINTS",()=>un({},vs)),di=pp(X,"HTML_INTEGRATION_POINTS",()=>un({},bs));const xe=pp(X,"CUSTOM_ELEMENT_HANDLING",()=>ul(null));if(St=ul(null),_i(xe,"tagNameCheck")&&go(xe.tagNameCheck)&&(St.tagNameCheck=xe.tagNameCheck),_i(xe,"attributeNameCheck")&&go(xe.attributeNameCheck)&&(St.attributeNameCheck=xe.attributeNameCheck),_i(xe,"allowCustomizedBuiltInElements")&&typeof xe.allowCustomizedBuiltInElements=="boolean"&&(St.allowCustomizedBuiltInElements=xe.allowCustomizedBuiltInElements),Br(St),Sn&&(it=!1),Ti&&(Pn=!0),po&&(ct=un({},ix),Ie=ul(null),po.html===!0&&(un(ct,rx),un(Ie,ox)),po.svg===!0&&(un(ct,cp),un(Ie,dp),un(Ie,Bu)),po.svgFilters===!0&&(un(ct,up),un(Ie,dp),un(Ie,Bu)),po.mathMl===!0&&(un(ct,hp),un(Ie,sx),un(Ie,Bu))),$n.tagCheck=null,$n.attributeCheck=null,_i(X,"ADD_TAGS")&&(typeof X.ADD_TAGS=="function"?$n.tagCheck=X.ADD_TAGS:hl(X.ADD_TAGS)&&(ct===Ft&&(ct=qi(ct)),un(ct,X.ADD_TAGS,Pt))),_i(X,"ADD_ATTR")&&(typeof X.ADD_ATTR=="function"?$n.attributeCheck=X.ADD_ATTR:hl(X.ADD_ATTR)&&(Ie===Ct&&(Ie=qi(Ie)),un(Ie,X.ADD_ATTR,Pt))),_i(X,"ADD_FORBID_CONTENTS")&&hl(X.ADD_FORBID_CONTENTS)&&(ur===Hs&&(ur=qi(ur)),un(ur,X.ADD_FORBID_CONTENTS,Pt)),vr&&(ct["#text"]=!0),Gn&&un(ct,["html","head","body"]),ct.table&&(un(ct,["tbody"]),delete Vt.tbody),X.TRUSTED_TYPES_POLICY){if(typeof X.TRUSTED_TYPES_POLICY.createHTML!="function")throw fs('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof X.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw fs('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');const Me=B;B=X.TRUSTED_TYPES_POLICY;try{N=j("")}catch(Oe){throw B=Me,Oe}}else X.TRUSTED_TYPES_POLICY===null?(B=void 0,N=""):(B===void 0&&(B=q()),B&&typeof N=="string"&&(N=j("")));Lr&&Lr(X),fn=X},mo=un({},[...cp,...up,...OO]),Li=un({},[...hp,...NO]),ws=function(X,xe,Me){return xe.namespaceURI===mn?X==="svg":xe.namespaceURI===$r?X==="svg"&&(Me==="annotation-xml"||ys[Me]):!!mo[X]},vo=function(X,xe,Me){return xe.namespaceURI===mn?X==="math":xe.namespaceURI===Or?X==="math"&&di[Me]:!!Li[X]},fi=function(X,xe,Me){return xe.namespaceURI===Or&&!di[Me]||xe.namespaceURI===$r&&!ys[Me]?!1:!Li[X]&&(Ri[X]||!mo[X])},Do=function(X){const xe=k(X),Me=ka(O(X)),Oe=w(X);let Ke,We;return Oe&&P(Oe)===mr.element?(Ke={namespaceURI:k(Oe)},We=ka(O(Oe))):(Ke={namespaceURI:jn},We="template"),hi[xe]?xe===Or?ws(Me,Ke,We):xe===$r?vo(Me,Ke,We):xe===mn?fi(Me,Ke,We):!!(Dt==="application/xhtml+xml"&&hi[xe]):!1},ti=function(X){pc(n.removed,{element:X});try{w(X).removeChild(X)}catch{if(d(X),!w(X))throw fs("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},Dr=function(X,xe,Me){try{o(X,xe)}catch{try{X.removeAttribute(Me)}catch{}}},yo=function(X){rr(X);const xe=m(X);xe&&ds(AO(xe),Oe=>{try{d(Oe)}catch{}});const Me=P(X)===mr.element?R(X):null;if(Me)for(let Oe=Me.length-1;Oe>=0;--Oe){const Ke=Me[Oe],We=Ke&&Ke.name;typeof We=="string"&&Dr(X,Ke,We)}},Oi=function(X,xe,Me){if(!Me)try{Me=xe.getAttributeNode(X)}catch{Me=null}pc(n.removed,{attribute:Me||null,from:xe});try{Me?o(xe,Me):xe.removeAttribute(X)}catch{try{xe.removeAttribute(X)}catch{}}if(X==="is")if(Pn||Ti)try{ti(xe)}catch{}else try{xe.setAttribute(X,"")}catch{}},Jo=function(X){const xe=R(X);if(xe)for(let Me=xe.length-1;Me>=0;--Me){const Oe=xe[Me],Ke=Oe&&Oe.name;typeof Ke!="string"||Ie[Pt(Ke)]||Dr(X,Oe,Ke)}},Po=function(X,xe){let Me=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;const Oe=[X];for(;Oe.length>0;){const Ke=Oe.pop();if(xe(Ke)===!1)continue;if(Me&&P(Ke)===mr.element){const rt=x(Ke);Jn(rt)&&Oe.push(rt)}const We=m(Ke);if(We)for(let rt=We.length-1;rt>=0;--rt)Oe.push(We[rt])}},rr=function(X){Po(X,xe=>{P(xe)===mr.element&&Jo(xe)})},zo=function(X){const xe=[];return Po(X,Me=>{xe.push(Me)},!0),xe},Qo=function(X,xe){const Me=sp();ds(zo(X),Oe=>{P(Oe)===mr.element&&ap(Me,Oe)}),ds(xe,Oe=>{P(Oe)===mr.element&&!gc(Me,Oe)&&Jo(Oe)})},Qi=function(X,xe){let Me=!1;return ds(n.removed,Oe=>{Oe.element&&(Me=Me||Oe.element===X,rr(Oe.element))}),Qo(X,xe),Me},xs=8,Zo=function(X,xe){const Me=jr;let Oe=null;const Ke=()=>(Oe||(Oe=sp(),ds(xe,We=>{ap(Oe,We)})),Oe);for(let We=0;;We++){const rt=zo(X),rn=[X];let bn=!1;if(ds(rt,Ve=>{P(Ve)===mr.documentFragment?pc(rn,Ve):!bn&&!gc(Me,Ve)&&(bn=gc(Ke(),Ve))}),!bn)return;if(We>=xs)throw fs("the tree kept changing during in-place sanitization; refusing to return it");ds(rn,(Ve,jt)=>{Bo(Ve,jt>0,X,Ke())})}},Bo=function(X,xe,Me,Oe){const Ke=Ni(X);let We;for(;We=Ke.nextNode();)!gc(Oe,We)||gc(jr,We)||(xe&&Pr(oe.uponSanitizeShadowNode,We,null),ns(We,Me),gi(We,Me),Jn(We.content)&&Tn(We.content))},Cs=function(X){jr&&ap(jr,X)},Xo=function(X,xe){return Dn?X==="patchsrc"?!0:X==="for"&&xe!=="label"&&xe!=="output":!1},es=function(X){Dn&&Po(X,xe=>{const Me=P(xe);if(Me===mr.processingInstruction||Me===mr.comment&&Fr(lx,xe.data)){try{d(xe)}catch{}return!1}if(Me===mr.element){const Oe=xe,Ke=Pt(O(xe));try{Oe.hasAttribute&&Oe.hasAttribute("patchsrc")&&Oe.removeAttribute("patchsrc"),Oe.hasAttribute&&Oe.hasAttribute("for")&&Xo("for",Ke)&&Oe.removeAttribute("for")}catch{}}return!0})},ks=function(X){let xe=null,Me=null;if(dn)X="<remove></remove>"+X;else{const We=Zw(X,/^[\r\n\t ]+/);Me=We&&We[0]}Dt==="application/xhtml+xml"&&jn===mn&&(X='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+X+"</body></html>");const Oe=B?j(X):X;if(jn===mn)try{xe=new p().parseFromString(Oe,Dt)}catch{}if(!xe||!xe.documentElement){xe=re.createDocument(jn,"template",null);try{xe.documentElement.innerHTML=Mi?N:Oe}catch{}}const Ke=xe.body||xe.documentElement;return X&&Me&&Ke.insertBefore(t.createTextNode(Me),Ke.childNodes[0]||null),jn===mn?ue.call(xe,Gn?"html":"body")[0]:Gn?xe.documentElement:Ke},Ni=function(X){const xe=C?C(X):X.ownerDocument;return le.call(xe||X,X,s.SHOW_ELEMENT|s.SHOW_COMMENT|s.SHOW_TEXT|s.SHOW_PROCESSING_INSTRUCTION|s.SHOW_CDATA_SECTION,null)},Zi=function(X){return X=mc(X,ee," "),X=mc(X,ye," "),X=mc(X,we," "),X},pi=function(X){var xe;or(X);const Me=(xe=X.querySelectorAll)===null||xe===void 0?void 0:xe.call(X,"template");Me&&ds(Me,Oe=>{Jn(Oe.content)&&pi(Oe.content)})},or=function(X){X.normalize();const xe=C?C(X):X.ownerDocument,Me=le.call(xe||X,X,s.SHOW_TEXT|s.SHOW_COMMENT|s.SHOW_CDATA_SECTION|s.SHOW_PROCESSING_INSTRUCTION,null);let Oe=Me.nextNode();for(;Oe;)Oe.data=Zi(Oe.data),Oe=Me.nextNode()},bo=function(X){const xe=_?_(X):null;return typeof xe!="string"||Pt(xe)!=="form"?!1:typeof X.nodeName!="string"||typeof X.textContent!="string"||typeof X.removeChild!="function"||X.attributes!==R(X)||typeof X.removeAttribute!="function"||typeof X.removeAttributeNode!="function"||typeof X.getAttributeNode!="function"||typeof X.setAttribute!="function"||typeof X.namespaceURI!="string"||typeof X.insertBefore!="function"||typeof X.hasChildNodes!="function"||X.nodeType!==T(X)||X.childNodes!==m(X)},Jn=function(X){if(!T||typeof X!="object"||X===null)return!1;try{return T(X)===mr.documentFragment}catch{return!1}},wo=function(X){if(!T||typeof X!="object"||X===null)return!1;try{return typeof T(X)=="number"}catch{return!1}};function Pr(X,xe,Me){X.length!==0&&ds(X,Oe=>{Oe.call(n,xe,Me,fn)})}const ts=function(X,xe){return!!(Dn&&X.hasChildNodes()&&!wo(X.firstElementChild)&&Fr(fp,X.textContent)&&Fr(fp,X.innerHTML)||Dn&&GO[xe]&&P(X)===mr.element&&k(X)===mn&&(wo(X.firstElementChild)||typeof X.textContent=="string"&&Fr(fp,X.textContent))||X.nodeType===mr.processingInstruction||Dn&&X.nodeType===mr.comment&&Fr(lx,X.data))},ni=function(X,xe){if(X instanceof RegExp)return Fr(X,xe);if(X instanceof Function){for(var Me=arguments.length,Oe=new Array(Me>2?Me-2:0),Ke=2;Ke<Me;Ke++)Oe[Ke-2]=arguments[Ke];return!!X(xe,...Oe)}return!1},Fo=function(X,xe,Me){if(!Vt[xe]&&rs(xe)&&ni(St.tagNameCheck,xe))return!1;if(vr&&!ur[xe]&&!ur[ka(xe)]){const Oe=w(X),Ke=m(X);if(Ke&&Oe){const We=Ke.length;for(let rt=We-1;rt>=0;--rt){const rn=X===Me?u(Ke[rt],!0):Ke[rt];Oe.insertBefore(rn,f(X))}}}return ti(X),!0},jo=function(X,xe,Me,Oe){return X.length===0?xe:xe===Me||xe===Oe?qi(xe):xe},Wr=function(X,xe){return X===xe||w(X)!==null?!1:(Ji&&rr(X),!0)},ns=function(X,xe){if(Cs(X),Pr(oe.beforeSanitizeElements,X,null),Wr(X,xe))return!0;if(bo(X))return ti(X),!0;const Me=Pt(O(X));if(ct=jo(oe.uponSanitizeElement,ct,Ft,qn),Pr(oe.uponSanitizeElement,X,{tagName:Me,allowedTags:ct}),Wr(X,xe))return!0;if(ts(X,Me))return ti(X),!0;if(Vt[Me]||!($n.tagCheck instanceof Function&&$n.tagCheck(Me))&&!ct[Me]){const Oe=Fo(X,Me,xe);return Oe===!1&&(Pr(oe.afterSanitizeElements,X,null),Wr(X,xe))?!0:Oe}if(P(X)===mr.element&&!Do(X)||(Me==="noscript"||Me==="noembed"||Me==="noframes")&&Fr(VO,X.innerHTML))return ti(X),!0;if(Sn&&X.nodeType===mr.text){const Oe=Zi(X.textContent);X.textContent!==Oe&&(pc(n.removed,{element:X.cloneNode()}),X.textContent=Oe)}return Pr(oe.afterSanitizeElements,X,null),Wr(X,xe)},Xi=function(X,xe,Me){if(hn[xe]||Xo(xe,X)||ei&&(xe==="id"||xe==="name")&&(Me in t||Me in Kn))return!1;const Oe=Ie[xe]||$n.attributeCheck instanceof Function&&$n.attributeCheck(xe,X);return it&&Fr(Ae,xe)||mt&&Fr(Je,xe)?!0:Oe?Ii[xe]||Fr(at,mc(Me,Ye,""))||(xe==="src"||xe==="xlink:href"||xe==="href")&&X!=="script"&&Xw(Me,"data:")===0&&gs[X]||Gt&&!Fr(ze,mc(Me,Ye,""))?!0:!Me:rs(X)&&ni(St.tagNameCheck,X)&&ni(St.attributeNameCheck,xe,X)||xe==="is"&&St.allowCustomizedBuiltInElements&&ni(St.tagNameCheck,Me)},Ue=un({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),rs=function(X){return!Ue[ka(X)]&&Fr(Ze,X)},Fe=function(X,xe,Me,Oe){if(B&&typeof a=="object"&&typeof a.getAttributeType=="function"&&!Me)switch(a.getAttributeType(X,xe)){case"TrustedHTML":return j(Oe);case"TrustedScriptURL":return U(Oe)}return Oe},Wn=function(X,xe,Me,Oe){try{return Me?X.setAttributeNS(Me,xe,Oe):X.setAttribute(xe,Oe),bo(X)?(ti(X),!1):!0}catch{return Oi(xe,X),!1}},xo=function(X,xe){return Dn&&Fr(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,xe)?!0:ka(X)==="attributename"&&Zw(xe,"href")!==null},gi=function(X,xe){if(Pr(oe.beforeSanitizeAttributes,X,null),Wr(X,xe))return;const Me=X.attributes;if(!Me||bo(X))return;Ie=jo(oe.uponSanitizeAttribute,Ie,Ct,tr);const Oe={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:Ie,forceKeepAttr:void 0};let Ke=Me.length;const We=Pt(X.nodeName);for(;Ke--;){const rt=Me[Ke],rn=rt.name,bn=rt.namespaceURI,Ve=rt.value,jt=Pt(rn),xt=Ve;let ln=rn==="value"?xt:SO(xt),mi=!1;if(Oe.attrName=jt,Oe.attrValue=ln,Oe.keepAttr=!0,Oe.forceKeepAttr=void 0,Pr(oe.uponSanitizeAttribute,X,Oe),ln=Oe.attrValue,Ei&&(jt==="id"||jt==="name")&&Xw(ln,fo)!==0&&(Oi(rn,X,rt),ln=fo+ln,mi=!0),xo(rn,ln)){Oi(rn,X,rt);continue}if(!Oe.forceKeepAttr){if(!Oe.keepAttr){Oi(rn,X,rt);continue}if(!Fn&&Fr(cx,ln)){Oi(rn,X,rt);continue}if(Sn&&(ln=Zi(ln)),!Xi(We,jt,ln)){Oi(rn,X,rt);continue}ln=Fe(We,jt,bn,ln),ln!==xt&&Wn(X,rn,bn,ln)&&mi&&Qw(n.removed)}}Pr(oe.afterSanitizeAttributes,X,null),Wr(X,xe)},Tn=function(X){let xe=null;const Me=Ni(X);for(Pr(oe.beforeSanitizeShadowDOM,X,null);xe=Me.nextNode();)if(Pr(oe.uponSanitizeShadowNode,xe,null),ns(xe,X),gi(xe,X),Jn(xe.content)&&Tn(xe.content),P(xe)===mr.element){const Oe=x(xe);Jn(Oe)&&(is(Oe),Tn(Oe))}Sn&&or(X),Pr(oe.afterSanitizeShadowDOM,X,null)},is=function(X){const xe=[{node:X,shadow:null}];for(;xe.length>0;){const Me=xe.pop();if(Me.shadow){Tn(Me.shadow);continue}const Oe=Me.node,Ke=P(Oe)===mr.element,We=m(Oe);if(We)for(let rt=We.length-1;rt>=0;--rt)xe.push({node:We[rt],shadow:null});if(Ke){const rt=_?_(Oe):null;if(typeof rt=="string"&&Pt(rt)==="template"){const rn=Oe.content;Jn(rn)&&xe.push({node:rn,shadow:null})}}if(Ke){const rt=x(Oe);Jn(rt)&&xe.push({node:null,shadow:rt},{node:rt,shadow:null})}}};return n.sanitize=function(X){let xe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Me=null,Oe=null,Ke=null,We=null;if(Mi=!X,Mi&&(X="<!-->"),typeof X!="string"&&!wo(X)&&(X=MO(X),typeof X!="string"))throw fs("dirty is not a string, aborting");if(!n.isSupported)return X;Ln?(ct=qn,Ie=tr):nr(xe),(oe.uponSanitizeElement.length>0||oe.uponSanitizeAttribute.length>0)&&(ct=qi(ct)),oe.uponSanitizeAttribute.length>0&&(Ie=qi(Ie)),n.removed=[];const rt=Ji&&typeof X!="string"&&wo(X);let rn=[];const bn=jr;if(rt){es(X);const xt=O(X);if(typeof xt=="string"){const ln=Pt(xt);if(!ct[ln]||Vt[ln])throw yo(X),fs("root node is forbidden and cannot be sanitized in-place")}if(bo(X))throw yo(X),fs("root node is clobbered and cannot be sanitized in-place");rn=zo(X),jr=sp()}else if(wo(X))Me=ks("<!---->"),Oe=Me.ownerDocument.importNode(X,!0),Oe.nodeType===mr.element&&Oe.nodeName==="BODY"||Oe.nodeName==="HTML"?Me=Oe:Me.appendChild(Oe),is(Me);else{if(!Pn&&!Sn&&!Gn&&X.indexOf("<")===-1)return B&&Xr?j(X):X;if(Me=ks(X),!Me)return Pn?null:Xr?N:""}Me&&dn&&ti(Me.firstChild);const Ve=rt?X:Me;try{rt&&is(X);const xt=Ni(Ve);for(;Ke=xt.nextNode();)ns(Ke,Ve),gi(Ke,Ve),Jn(Ke.content)&&Tn(Ke.content);rt&&Zo(X,rn)}catch(xt){throw rt&&(yo(X),Qi(X,rn)),xt}finally{jr=bn}if(rt){if(Qi(X,rn))throw fs("a node selected for removal could not be safely returned; refusing to sanitize in place");return Sn&&pi(X),X}if(Pn){if(Sn&&pi(Me),Ti)for(We=ne.call(Me.ownerDocument);Me.firstChild;)We.appendChild(Me.firstChild);else We=Me;return(Ie.shadowroot||Ie.shadowrootmode)&&(We=he.call(r,We,!0)),We}let jt=Gn?Me.outerHTML:Me.innerHTML;return Gn&&ct["!doctype"]&&Me.ownerDocument&&Me.ownerDocument.doctype&&Me.ownerDocument.doctype.name&&Fr(HO,Me.ownerDocument.doctype.name)&&(jt="<!DOCTYPE "+Me.ownerDocument.doctype.name+`>
1492
+ `+jt),Sn&&(jt=Zi(jt)),B&&Xr?j(jt):jt},n.setConfig=function(){let X=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};nr(X),Ln=!0,qn=ct,tr=Ie},n.clearConfig=function(){fn=null,Ln=!1,qn=null,tr=null,B=M,N=""},n.isValidAttribute=function(X,xe,Me){fn||nr({});const Oe=Pt(X),Ke=Pt(xe);return typeof Me=="string"&&(xo(xe,Me)||!Fn&&Fr(cx,Me))?!1:Xi(Oe,Ke,Me)},n.addHook=function(X,xe){typeof xe=="function"&&_i(oe,X)&&pc(oe[X],xe)},n.removeHook=function(X,xe){if(_i(oe,X)){if(xe!==void 0){const Me=_O(oe[X],xe);return Me===-1?void 0:$O(oe[X],Me,1)[0]}return Qw(oe[X])}},n.removeHooks=function(X){_i(oe,X)&&(oe[X]=[])},n.removeAllHooks=function(){oe=ux()},n}var dx=hx();const KO={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"}},JO={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:e=>!!e||"Required.",match:e=>e===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 dx.sanitize(this.params.text)}},methods:{dialog:function(e,n,t){this.params=e,this.show=!0,this.resolve=n,this.reject=t},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=""}}},QO=["innerHTML"],ZO={key:2},XO={key:3,class:"validate mt-4"};function e2(e,n,t,r,c,h){const g=In("v-spacer"),v=In("v-toolbar"),s=In("v-icon"),p=In("v-text-field"),a=In("v-card-text"),l=In("v-btn"),u=In("v-card-actions"),d=In("v-card"),o=In("v-dialog"),f=In("v-app");return wt(),er(f,null,{default:sn(()=>[Ge(o,{modelValue:e.show,"onUpdate:modelValue":n[1]||(n[1]=m=>e.show=m),persistent:"",width:"600",onKeydown:Xg(h.cancel,["esc"])},{default:sn(()=>[Ge(d,null,{default:sn(()=>[Ge(v,{height:"24"},{default:sn(()=>[Ge(g),gt("span",null,xr(e.params.title),1),Ge(g)]),_:1}),Ge(a,{class:"mt-4 pa-3"},{default:sn(()=>[e.params.validateText?(wt(),er(s,{key:0,class:"mr-2"},{default:sn(()=>[...n[2]||(n[2]=[Wi(" mdi-alert ",-1)])]),_:1})):qr("",!0),e.params.html?(wt(),Xt("span",{key:1,innerHTML:h.sanitizedText},null,8,QO)):(wt(),Xt("span",ZO,xr(h.sanitizedText),1)),e.params.validateText?(wt(),Xt("div",XO,[Wi(" Enter "+xr(e.params.validateText)+" to confirm! ",1),Ge(p,{modelValue:e.validationText,"onUpdate:modelValue":n[0]||(n[0]=m=>e.validationText=m),variant:"solo",density:"compact","single-line":"",rules:[e.rules.required,e.rules.match],"data-test":"confirm-dialog-validate"},null,8,["modelValue","rules"])])):qr("",!0)]),_:1}),Ge(u,{class:"px-2"},{default:sn(()=>[Ge(g),e.params.cancelText?(wt(),er(l,{key:0,variant:"outlined","data-test":h.dataTestCancel,onClick:h.cancel},{default:sn(()=>[Wi(xr(e.params.cancelText),1)]),_:1},8,["data-test","onClick"])):qr("",!0),Ge(l,{variant:"flat",color:e.params.okClass,"data-test":h.dataTestOk,onClick:h.ok},{default:sn(()=>[Wi(xr(e.params.okText),1)]),_:1},8,["color","data-test","onClick"])]),_:1})]),_:1})]),_:1},8,["modelValue","onKeydown"])]),_:1})}const t2=ra(JO,[["render",e2],["__scopeId","data-v-53691296"]]);class n2{constructor(){this.mounted=!1,this.$root=null}mount(){if(this.mounted)return;const n=window.Vue.createApp(t2);n.use(Up);const t=document.createElement("div");document.querySelector("#openc3-app-toolbar > div").appendChild(t),this.$root=n.mount(t),this.mounted=!0}open({title:n,text:t,okText:r,okClass:c,validateText:h,cancelText:g,html:v}){return this.mount(),new Promise((s,p)=>{this.$root.dialog({title:n,text:t,okText:r,okClass:c,validateText:h,cancelText:g,html:v},s,p)})}confirm(n,{okText:t="Ok",cancelText:r="Cancel",okClass:c="primary"}){return this.open({title:"Confirm",text:n,okText:t,okClass:c,validateText:null,cancelText:r,html:!1})}alert(n,{okText:t="Ok",html:r=!1,okClass:c="primary"}){return this.open({title:"Alert",text:n,okText:t,okClass:c,validateText:null,cancelText:null,html:r})}validate(n,{okText:t="Ok",validateText:r="CONFIRM",cancelText:c="Cancel",okClass:h="primary"}){return this.open({title:"Confirm",text:n,okText:t,okClass:h,validateText:r,cancelText:c,html:!1})}}const r2={install(e,n){const t=new n2;e.provide("dialog",t),e.config.globalProperties.hasOwnProperty("$dialog")||(e.config.globalProperties.$dialog=t)}};let gp=1;var i2=class{subscribers;toasts;dismissedToasts;constructor(){this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}subscribe=e=>(this.subscribers.push(e),()=>{const n=this.subscribers.indexOf(e);this.subscribers.splice(n,1)});publish=e=>{this.subscribers.forEach(n=>n(e))};addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]};create=e=>{const{message:n,...t}=e,r=typeof e.id=="number"||e.id&&e.id?.length>0?e.id:gp++,c=this.toasts.find(g=>g.id===r),h=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(r)&&this.dismissedToasts.delete(r),c?this.toasts=this.toasts.map(g=>g.id===r?(this.publish({...g,...e,id:r,title:n}),{...g,...e,id:r,dismissible:h,title:n}):g):this.addToast({title:n,...t,dismissible:h,id:r}),r};dismiss=e=>(e?(this.dismissedToasts.add(e),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:e,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(t=>t({id:n.id,dismiss:!0}))}),e);message=(e,n)=>this.create({...n,message:e,type:"default"});error=(e,n)=>this.create({...n,type:"error",message:e});success=(e,n)=>this.create({...n,type:"success",message:e});info=(e,n)=>this.create({...n,type:"info",message:e});warning=(e,n)=>this.create({...n,type:"warning",message:e});loading=(e,n)=>this.create({...n,type:"loading",message:e});promise=(e,n)=>{if(!n)return;let t;n.loading!==void 0&&(t=this.create({...n,promise:e,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const r=Promise.resolve(e instanceof Function?e():e);let c=t!==void 0,h;const g=r.then(async s=>{if(h=["resolve",s],za(s))c=!1,this.create({id:t,type:"default",message:s});else if(s2(s)&&!s.ok){c=!1;const p=typeof n.error=="function"?await n.error(`HTTP error! status: ${s.status}`):n.error,a=typeof n.description=="function"?await n.description(`HTTP error! status: ${s.status}`):n.description,l=typeof p=="object"&&!za(p)?p:{message:p||"",id:t||""};this.create({id:t,type:"error",description:a,...l})}else if(s instanceof Error){c=!1;const p=typeof n.error=="function"?await n.error(s):n.error,a=typeof n.description=="function"?await n.description(s):n.description,l=typeof p=="object"&&!za(p)?p:{message:p||"",id:t||""};this.create({id:t,type:"error",description:a,...l})}else if(n.success!==void 0){c=!1;const p=typeof n.success=="function"?await n.success(s):n.success,a=typeof n.description=="function"?await n.description(s):n.description,l=typeof p=="object"&&!za(p)?p:{message:p||"",id:t||""};this.create({id:t,type:"success",description:a,...l})}}).catch(async s=>{if(h=["reject",s],n.error!==void 0){c=!1;const p=typeof n.error=="function"?await n.error(s):n.error,a=typeof n.description=="function"?await n.description(s):n.description,l=typeof p=="object"&&!za(p)?p:{message:p||"",id:t||""};this.create({id:t,type:"error",description:a,...l})}}).finally(()=>{c&&(this.dismiss(t),t=void 0),n.finally?.()}),v=()=>new Promise((s,p)=>g.then(()=>h[0]==="reject"?p(h[1]):s(h[1])).catch(p));return typeof t!="string"&&typeof t!="number"?{unwrap:v}:Object.assign(t,{unwrap:v})};custom=(e,n)=>{const t=n?.id||gp++,r=this.toasts.find(h=>h.id===t),c=n?.dismissible===void 0?!0:n.dismissible;return this.dismissedToasts.has(t)&&this.dismissedToasts.delete(t),r?this.toasts=this.toasts.map(h=>h.id===t?(this.publish({...h,component:e,dismissible:c,id:t,...n}),{...h,component:e,dismissible:c,id:t,...n}):h):this.addToast({component:e,dismissible:c,id:t,...n}),t};getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id))};const Ai=new i2;function o2(e,n){const t=n?.id||gp++;return Ai.create({message:e,id:t,type:"default",...n}),t}const s2=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",a2=o2,l2=()=>Ai.toasts,c2=()=>Ai.getActiveToasts(),mp=Object.assign(a2,{success:Ai.success,info:Ai.info,warning:Ai.warning,error:Ai.error,custom:Ai.custom,message:Ai.message,promise:Ai.promise,dismiss:Ai.dismiss,loading:Ai.loading},{getHistory:l2,getToasts:c2});function Fu(e){return e.label!==void 0}const u2=3,fx="24px",px="16px",gx=4e3,h2=356,d2=14,f2=45,mx=200;function p2(){const e=nn(!1);return ai(()=>{const n=()=>{e.value=document.hidden};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)}),{isDocumentHidden:e}}function Ws(...e){return e.filter(Boolean).join(" ")}function g2(e){const[n,t]=e.split("-"),r=[];return n&&r.push(n),t&&r.push(t),r}function m2(e,n){const t={};return[e,n].forEach((r,c)=>{const h=c===1,g=h?"--mobile-offset":"--offset",v=h?px:fx;function s(p){["top","right","bottom","left"].forEach(a=>{t[`${g}-${a}`]=typeof p=="number"?`${p}px`:p})}typeof r=="number"||typeof r=="string"?s(r):typeof r=="object"?["top","right","bottom","left"].forEach(p=>{r[p]===void 0?t[`${g}-${p}`]=v:t[`${g}-${p}`]=typeof r[p]=="number"?`${r[p]}px`:r[p]}):s(v)}),t}const v2=["data-rich-colors","data-styled","data-mounted","data-promise","data-swiped","data-removed","data-visible","data-y-position","data-x-position","data-index","data-front","data-swiping","data-dismissible","data-type","data-invert","data-swipe-out","data-swipe-direction","data-expanded","data-testid"],y2=["aria-label","data-disabled","data-close-button-position"];var b2=Ls({__name:"Toast",props:{toast:{},toasts:{},index:{},swipeDirections:{},expanded:{type:Boolean},invert:{type:Boolean},heights:{},gap:{},position:{},closeButtonPosition:{},visibleToasts:{},expandByDefault:{type:Boolean},closeButton:{type:Boolean},interacting:{type:Boolean},style:{},cancelButtonStyle:{},actionButtonStyle:{},duration:{},class:{},unstyled:{type:Boolean},descriptionClass:{},loadingIcon:{},classes:{},icons:{},closeButtonAriaLabel:{},defaultRichColors:{type:Boolean}},emits:["update:heights","update:height","removeToast"],setup(e,{emit:n}){const t=e,r=n,c=nn(null),h=nn(null),g=nn(!1),v=nn(!1),s=nn(!1),p=nn(!1),a=nn(!1),l=nn(0),u=nn(0),d=nn(t.toast.duration||t.duration||gx),o=nn(null),f=nn(null),m=vt(()=>t.index===0),w=vt(()=>t.index+1<=t.visibleToasts),x=vt(()=>t.toast.type),R=vt(()=>t.toast.dismissible!==!1),T=vt(()=>t.toast.class||""),_=vt(()=>t.descriptionClass||""),C=vt(()=>{const ee=t.toast.position||t.position,ye=t.heights.filter(we=>we.position===ee).findIndex(we=>we.toastId===t.toast.id);return ye>=0?ye:0}),P=vt(()=>{const ee=t.toast.position||t.position;return t.heights.filter(ye=>ye.position===ee).reduce((ye,we,Ae)=>Ae>=C.value?ye:ye+we.height,0)}),O=vt(()=>C.value*t.gap+P.value||0),E=vt(()=>t.toast.closeButton??t.closeButton),k=vt(()=>t.toast.duration||t.duration||gx),B=nn(0),N=nn(0),M=nn(null),$=vt(()=>t.position.split("-")),A=vt(()=>$.value[0]),D=vt(()=>$.value[1]),j=vt(()=>typeof t.toast.title!="string"),U=vt(()=>typeof t.toast.description!="string"),{isDocumentHidden:q}=p2(),Q=vt(()=>x.value&&x.value==="loading");Fa(()=>{g.value=!0,d.value=k.value}),ai(async()=>{if(!g.value||!f.value)return;await Tl();const ee=f.value,ye=ee.style.height;ee.style.height="auto";const we=ee.getBoundingClientRect().height;ee.style.height=ye,u.value=we,r("update:height",{toastId:t.toast.id,height:we,position:t.toast.position||t.position})});function re(){v.value=!0,l.value=O.value,setTimeout(()=>{r("removeToast",t.toast)},mx)}function le(){if(Q.value||!R.value)return{};re(),t.toast.onDismiss?.(t.toast)}function ne(ee){ee.button!==2&&(Q.value||!R.value||(o.value=new Date,l.value=O.value,ee.target.setPointerCapture(ee.pointerId),ee.target.tagName!=="BUTTON"&&(s.value=!0,M.value={x:ee.clientX,y:ee.clientY})))}function ue(){if(p.value||!R.value)return;M.value=null;const ee=Number(f.value?.style.getPropertyValue("--swipe-amount-x").replace("px","")||0),ye=Number(f.value?.style.getPropertyValue("--swipe-amount-y").replace("px","")||0),we=new Date().getTime()-(o.value?.getTime()||0),Ae=c.value==="x"?ee:ye,Je=Math.abs(Ae)/we;if(Math.abs(Ae)>=f2||Je>.11){l.value=O.value,t.toast.onDismiss?.(t.toast),c.value==="x"?h.value=ee>0?"right":"left":h.value=ye>0?"down":"up",re(),p.value=!0;return}else f.value?.style.setProperty("--swipe-amount-x","0px"),f.value?.style.setProperty("--swipe-amount-y","0px");a.value=!1,s.value=!1,c.value=null}function he(ee){if(!M.value||!R.value||(window?.getSelection()?.toString()?.length??!1))return;const ye=ee.clientY-M.value.y,we=ee.clientX-M.value.x,Ae=t.swipeDirections??g2(t.position);!c.value&&(Math.abs(we)>1||Math.abs(ye)>1)&&(c.value=Math.abs(we)>Math.abs(ye)?"x":"y");let Je={x:0,y:0};const ze=Ye=>1/(1.5+Math.abs(Ye)/20);if(c.value==="y"){if(Ae.includes("top")||Ae.includes("bottom"))if(Ae.includes("top")&&ye<0||Ae.includes("bottom")&&ye>0)Je.y=ye;else{const Ye=ye*ze(ye);Je.y=Math.abs(Ye)<Math.abs(ye)?Ye:ye}}else if(c.value==="x"&&(Ae.includes("left")||Ae.includes("right")))if(Ae.includes("left")&&we<0||Ae.includes("right")&&we>0)Je.x=we;else{const Ye=we*ze(we);Je.x=Math.abs(Ye)<Math.abs(we)?Ye:we}(Math.abs(Je.x)>0||Math.abs(Je.y)>0)&&(a.value=!0),f.value?.style.setProperty("--swipe-amount-x",`${Je.x}px`),f.value?.style.setProperty("--swipe-amount-y",`${Je.y}px`)}Fa(()=>{if(g.value=!0,!f.value)return;const ee=f.value.getBoundingClientRect().height;u.value=ee;const ye=[{toastId:t.toast.id,height:ee,position:t.toast.position},...t.heights];r("update:heights",ye)}),Zs(()=>{f.value&&r("removeToast",t.toast)}),ai(ee=>{if(t.toast.promise&&x.value==="loading"||t.toast.duration===1/0||t.toast.type==="loading")return;let ye;const we=()=>{if(N.value<B.value){const Je=new Date().getTime()-B.value;d.value=d.value-Je}N.value=new Date().getTime()},Ae=()=>{d.value!==1/0&&(B.value=new Date().getTime(),ye=setTimeout(()=>{t.toast.onAutoClose?.(t.toast),re()},d.value))};t.expanded||t.interacting||q.value?we():Ae(),ee(()=>{clearTimeout(ye)})}),wi(()=>t.toast.delete,ee=>{ee!==void 0&&ee&&(re(),t.toast.onDismiss?.(t.toast))},{deep:!0});function oe(){s.value=!1,c.value=null,M.value=null}return(ee,ye)=>(wt(),Xt("li",{tabindex:"0",ref_key:"toastRef",ref:f,class:an(Ht(Ws)(t.class,T.value,ee.classes?.toast,ee.toast.classes?.toast,ee.classes?.[x.value],ee.toast?.classes?.[x.value])),"data-sonner-toast":"","data-rich-colors":ee.toast.richColors??ee.defaultRichColors,"data-styled":!(ee.toast.component||ee.toast?.unstyled||ee.unstyled),"data-mounted":g.value,"data-promise":!!ee.toast.promise,"data-swiped":a.value,"data-removed":v.value,"data-visible":w.value,"data-y-position":A.value,"data-x-position":D.value,"data-index":ee.index,"data-front":m.value,"data-swiping":s.value,"data-dismissible":R.value,"data-type":x.value,"data-invert":ee.toast.invert||ee.invert,"data-swipe-out":p.value,"data-swipe-direction":h.value,"data-expanded":!!(ee.expanded||ee.expandByDefault&&g.value),"data-testid":ee.toast.testId,style:Un({"--index":ee.index,"--toasts-before":ee.index,"--z-index":ee.toasts.length-ee.index,"--offset":`${v.value?l.value:O.value}px`,"--initial-height":ee.expandByDefault?"auto":`${u.value}px`,...ee.style,...t.toast.style}),onDragend:oe,onPointerdown:ne,onPointerup:ue,onPointermove:he},[E.value&&!ee.toast.component&&x.value!=="loading"?(wt(),Xt("button",{key:0,"aria-label":ee.closeButtonAriaLabel||"Close toast","data-disabled":Q.value,"data-close-button":"true","data-close-button-position":ee.closeButtonPosition,class:an(Ht(Ws)(ee.classes?.closeButton,ee.toast?.classes?.closeButton)),onClick:le},[ee.icons?.close?(wt(),er(ea(ee.icons?.close),{key:0})):xi(ee.$slots,"close-icon",{key:1})],10,y2)):qr("v-if",!0),ee.toast.component?(wt(),er(ea(ee.toast.component),fr({key:1},ee.toast.componentProps,{onCloseToast:le,isPaused:ee.$props.expanded||ee.$props.interacting||Ht(q)}),null,16,["isPaused"])):(wt(),Xt(Ir,{key:2},[x.value!=="default"||ee.toast.icon||ee.toast.promise?(wt(),Xt("div",{key:0,"data-icon":"",class:an(Ht(Ws)(ee.classes?.icon,ee.toast?.classes?.icon))},[ee.toast.icon?(wt(),er(ea(ee.toast.icon),{key:0})):(wt(),Xt(Ir,{key:1},[x.value==="loading"?xi(ee.$slots,"loading-icon",{key:0}):x.value==="success"?xi(ee.$slots,"success-icon",{key:1}):x.value==="error"?xi(ee.$slots,"error-icon",{key:2}):x.value==="warning"?xi(ee.$slots,"warning-icon",{key:3}):x.value==="info"?xi(ee.$slots,"info-icon",{key:4}):qr("v-if",!0)],64))],2)):qr("v-if",!0),gt("div",{"data-content":"",class:an(Ht(Ws)(ee.classes?.content,ee.toast?.classes?.content))},[gt("div",{"data-title":"",class:an(Ht(Ws)(ee.classes?.title,ee.toast.classes?.title))},[j.value?(wt(),er(ea(ee.toast.title),Wc(fr({key:0},ee.toast.componentProps)),null,16)):(wt(),Xt(Ir,{key:1},[Wi(xr(ee.toast.title),1)],64))],2),ee.toast.description?(wt(),Xt("div",{key:0,"data-description":"",class:an(Ht(Ws)(ee.descriptionClass,_.value,ee.classes?.description,ee.toast.classes?.description))},[U.value?(wt(),er(ea(ee.toast.description),Wc(fr({key:0},ee.toast.componentProps)),null,16)):(wt(),Xt(Ir,{key:1},[Wi(xr(ee.toast.description),1)],64))],2)):qr("v-if",!0)],2),ee.toast.cancel?(wt(),Xt("button",{key:1,style:Un(ee.toast.cancelButtonStyle||ee.cancelButtonStyle),class:an(Ht(Ws)(ee.classes?.cancelButton,ee.toast.classes?.cancelButton)),"data-button":"","data-cancel":"",onClick:ye[0]||(ye[0]=we=>{Ht(Fu)(ee.toast.cancel)&&R.value&&(ee.toast.cancel.onClick?.(we),re())})},xr(Ht(Fu)(ee.toast.cancel)?ee.toast.cancel?.label:ee.toast.cancel),7)):qr("v-if",!0),ee.toast.action?(wt(),Xt("button",{key:2,style:Un(ee.toast.actionButtonStyle||ee.actionButtonStyle),class:an(Ht(Ws)(ee.classes?.actionButton,ee.toast.classes?.actionButton)),"data-button":"","data-action":"",onClick:ye[1]||(ye[1]=we=>{Ht(Fu)(ee.toast.action)&&(ee.toast.action.onClick?.(we),!we.defaultPrevented&&re())})},xr(Ht(Fu)(ee.toast.action)?ee.toast.action?.label:ee.toast.action),7)):qr("v-if",!0)],64))],46,v2))}}),w2=b2,yc=(e,n)=>{const t=e.__vccOpts||e;for(const[r,c]of n)t[r]=c;return t};const x2={},C2={xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stoke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"};function k2(e,n){return wt(),Xt("svg",C2,n[0]||(n[0]=[gt("line",{x1:"18",y1:"6",x2:"6",y2:"18"},null,-1),gt("line",{x1:"6",y1:"6",x2:"18",y2:"18"},null,-1)]))}var _2=yc(x2,[["render",k2]]);const A2=["data-visible"],$2={class:"sonner-spinner"};var S2=Ls({__name:"Loader",props:{visible:{type:Boolean}},setup(e){const n=Array(12).fill(0);return(t,r)=>(wt(),Xt("div",{class:"sonner-loading-wrapper","data-visible":t.visible},[gt("div",$2,[(wt(!0),Xt(Ir,null,Ml(Ht(n),c=>(wt(),Xt("div",{key:`spinner-bar-${c}`,class:"sonner-loading-bar"}))),128))])],8,A2))}}),T2=S2;const E2={},I2={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"};function M2(e,n){return wt(),Xt("svg",I2,n[0]||(n[0]=[gt("path",{"fill-rule":"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z","clip-rule":"evenodd"},null,-1)]))}var R2=yc(E2,[["render",M2]]);const L2={},O2={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"};function N2(e,n){return wt(),Xt("svg",O2,n[0]||(n[0]=[gt("path",{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z","clip-rule":"evenodd"},null,-1)]))}var D2=yc(L2,[["render",N2]]);const P2={},z2={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"};function B2(e,n){return wt(),Xt("svg",z2,n[0]||(n[0]=[gt("path",{"fill-rule":"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z","clip-rule":"evenodd"},null,-1)]))}var F2=yc(P2,[["render",B2]]);const j2={},W2={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"};function H2(e,n){return wt(),Xt("svg",W2,n[0]||(n[0]=[gt("path",{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z","clip-rule":"evenodd"},null,-1)]))}var U2=yc(j2,[["render",H2]]);const V2=["aria-label"],G2=["data-sonner-theme","dir","data-theme","data-rich-colors","data-y-position","data-x-position"],q2=typeof window<"u"&&typeof document<"u";function Y2(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}var K2=Ls({name:"Toaster",inheritAttrs:!1,__name:"Toaster",props:{id:{},invert:{type:Boolean,default:!1},theme:{default:"light"},position:{default:"bottom-right"},closeButtonPosition:{default:"top-left"},hotkey:{default:()=>["altKey","KeyT"]},richColors:{type:Boolean,default:!1},expand:{type:Boolean,default:!1},duration:{},gap:{default:d2},visibleToasts:{default:u2},closeButton:{type:Boolean,default:!1},toastOptions:{default:()=>({})},class:{default:""},style:{},offset:{default:fx},mobileOffset:{default:px},dir:{default:"auto"},swipeDirections:{},icons:{},containerAriaLabel:{default:"Notifications"}},setup(e){const n=e,t=em(),r=nn([]),c=vt(()=>n.id?r.value.filter(k=>k.toasterId===n.id):r.value.filter(k=>!k.toasterId));function h(k,B){return c.value.filter(N=>!N.position&&B===0||N.position===k)}const g=vt(()=>{const k=c.value.filter(B=>B.position).map(B=>B.position);return k.length>0?Array.from(new Set([n.position].concat(k))):[n.position]}),v=vt(()=>{const k={};return g.value.forEach(B=>{k[B]=r.value.filter(N=>N.position===B)}),k}),s=nn([]),p=nn({}),a=nn(!1);ai(()=>{g.value.forEach(k=>{k in p.value||(p.value[k]=!1)})});const l=nn(n.theme!=="system"?n.theme:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),u=nn(null),d=nn(null),o=nn(!1),f=n.hotkey.join("+").replace(/Key/g,"").replace(/Digit/g,"");function m(k){r.value.find(B=>B.id===k.id)?.delete||Ai.dismiss(k.id),r.value=r.value.filter(({id:B})=>B!==k.id),setTimeout(()=>{r.value.find(B=>B.id===k.id)||(s.value=s.value.filter(B=>B.toastId!==k.id))},mx+50)}function w(k){o.value&&!k.currentTarget?.contains?.(k.relatedTarget)&&(o.value=!1,d.value&&(d.value.focus({preventScroll:!0}),d.value=null))}function x(k){k.target instanceof HTMLElement&&k.target.dataset.dismissible==="false"||o.value||(o.value=!0,d.value=k.relatedTarget)}function R(k){k.target&&k.target instanceof HTMLElement&&k.target.dataset.dismissible==="false"||(a.value=!0)}ai(k=>{const B=Ai.subscribe(N=>{if(N.dismiss){requestAnimationFrame(()=>{r.value=r.value.map(M=>M.id===N.id?{...M,delete:!0}:M)});return}Tl(()=>{const M=r.value.findIndex($=>$.id===N.id);M!==-1?r.value=[...r.value.slice(0,M),{...r.value[M],...N},...r.value.slice(M+1)]:r.value=[N,...r.value]})});k(B)}),ai(k=>{if(typeof window>"u")return;if(n.theme!=="system"){l.value=n.theme;return}const B=window.matchMedia("(prefers-color-scheme: dark)"),N=$=>{l.value=$?"dark":"light"};N(B.matches);const M=$=>{N($.matches)};try{B.addEventListener("change",M)}catch{B.addListener(M)}k(()=>{try{B.removeEventListener("change",M)}catch{B.removeListener(M)}})}),ai(()=>{u.value&&d.value&&(d.value.focus({preventScroll:!0}),d.value=null,o.value=!1)}),ai(()=>{r.value.length<=1&&Object.keys(p.value).forEach(k=>{p.value[k]=!1})}),ai(k=>{function B(N){const M=n.hotkey.every(D=>N[D]||N.code===D),$=Array.isArray(u.value)?u.value[0]:u.value;M&&(g.value.forEach(D=>{p.value[D]=!0}),$?.focus());const A=document.activeElement===u.value||$?.contains(document.activeElement);N.code==="Escape"&&A&&g.value.forEach(D=>{p.value[D]=!1})}q2&&(document.addEventListener("keydown",B),k(()=>{document.removeEventListener("keydown",B)}))});function T(k){const B=k.currentTarget,N=B.getAttribute("data-y-position")+"-"+B.getAttribute("data-x-position");p.value[N]=!0}function _(k){if(!a.value){const B=k.currentTarget,N=B.getAttribute("data-y-position")+"-"+B.getAttribute("data-x-position");p.value[N]=!1}}function C(){Object.keys(p.value).forEach(k=>{p.value[k]=!1})}function P(){a.value=!1}function O(k){s.value=k}function E(k){const B=s.value.findIndex(N=>N.toastId===k.toastId);if(B!==-1)s.value[B]=k;else{const N=s.value.findIndex(M=>M.position===k.position);N!==-1?s.value.splice(N,0,k):s.value.unshift(k)}}return(k,B)=>(wt(),Xt(Ir,null,[qr(" Remove item from normal navigation flow, only available via hotkey "),gt("section",{"aria-label":`${k.containerAriaLabel} ${Ht(f)}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false"},[(wt(!0),Xt(Ir,null,Ml(g.value,(N,M)=>(wt(),Xt("ol",fr({key:N,ref_for:!0,ref_key:"listRef",ref:u,"data-sonner-toaster":"","data-sonner-theme":l.value,class:n.class,dir:k.dir==="auto"?Y2():k.dir,tabIndex:-1,"data-theme":k.theme,"data-rich-colors":k.richColors,"data-y-position":N.split("-")[0],"data-x-position":N.split("-")[1],style:{"--front-toast-height":`${s.value[0]?.height||0}px`,"--width":`${Ht(h2)}px`,"--gap":`${k.gap}px`,...k.style,...Ht(t).style,...Ht(m2)(k.offset,k.mobileOffset)}},{ref_for:!0},k.$attrs,{onBlur:w,onFocus:x,onMouseenter:T,onMousemove:T,onMouseleave:_,onDragend:C,onPointerdown:R,onPointerup:P}),[(wt(!0),Xt(Ir,null,Ml(h(N,M),($,A)=>(wt(),er(w2,{key:$.id,heights:s.value,icons:k.icons,index:A,toast:$,defaultRichColors:k.richColors,duration:k.toastOptions?.duration??k.duration,class:an(k.toastOptions?.class??""),descriptionClass:k.toastOptions?.descriptionClass,invert:k.invert,visibleToasts:k.visibleToasts,closeButton:k.toastOptions?.closeButton??k.closeButton,interacting:a.value,position:N,closeButtonPosition:k.toastOptions?.closeButtonPosition??k.closeButtonPosition,style:Un(k.toastOptions?.style),unstyled:k.toastOptions?.unstyled,classes:k.toastOptions?.classes,cancelButtonStyle:k.toastOptions?.cancelButtonStyle,actionButtonStyle:k.toastOptions?.actionButtonStyle,"close-button-aria-label":k.toastOptions?.closeButtonAriaLabel,toasts:v.value[N],expandByDefault:k.expand,gap:k.gap,expanded:p.value[N]||!1,swipeDirections:n.swipeDirections,"onUpdate:heights":O,"onUpdate:height":E,onRemoveToast:m},{"close-icon":sn(()=>[xi(k.$slots,"close-icon",{},()=>[Ge(_2)])]),"loading-icon":sn(()=>[xi(k.$slots,"loading-icon",{},()=>[Ge(T2,{visible:$.type==="loading"},null,8,["visible"])])]),"success-icon":sn(()=>[xi(k.$slots,"success-icon",{},()=>[Ge(R2)])]),"error-icon":sn(()=>[xi(k.$slots,"error-icon",{},()=>[Ge(U2)])]),"warning-icon":sn(()=>[xi(k.$slots,"warning-icon",{},()=>[Ge(F2)])]),"info-icon":sn(()=>[xi(k.$slots,"info-icon",{},()=>[Ge(D2)])]),_:2},1032,["heights","icons","index","toast","defaultRichColors","duration","class","descriptionClass","invert","visibleToasts","closeButton","interacting","position","closeButtonPosition","style","unstyled","classes","cancelButtonStyle","actionButtonStyle","close-button-aria-label","toasts","expandByDefault","gap","expanded","swipeDirections"]))),128))],16,G2))),128))],8,V2)],2112))}}),J2=K2;function Qt(e,n){return t=>Object.keys(e).reduce((r,c)=>{const h=typeof e[c]=="object"&&e[c]!=null&&!Array.isArray(e[c])?e[c]:{type:e[c]};return t&&c in t?r[c]={...h,default:t[c]}:r[c]=h,n&&!r[c].source&&(r[c].source=n),r},{})}const $i=Qt({class:[String,Array,Object],style:{type:[String,Array,Object],default:null}},"component");function dl(e){Qg(`Vuetify: ${e}`)}const ju=typeof window<"u",vp=ju&&"IntersectionObserver"in window,Q2=ju&&"matchMedia"in window&&typeof window.matchMedia=="function",vx=()=>Q2&&window.matchMedia("(prefers-reduced-motion: reduce)").matches;ju&&CSS?.supports?.("-webkit-backdrop-filter","none");function Nn(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"px";if(e==null||e==="")return;const t=Number(e);return isNaN(t)?String(e):isFinite(t)?`${t}${n}`:void 0}function yp(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function yx(e){let n;return e!==null&&typeof e=="object"&&((n=Object.getPrototypeOf(e))===Object.prototype||n===null)}function Z2(e){if(e&&"$el"in e){const n=e.$el;return n?.nodeType===Node.TEXT_NODE?n.nextElementSibling:n}return e}function bp(e,n){return n.every(t=>e.hasOwnProperty(t))}function X2(e,n){const t={};for(const r of n)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}function eN(e){return e==null?[]:Array.isArray(e)?e:[e]}function Wu(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.max(n,Math.min(t,e))}function bx(e,n){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0";return e+t.repeat(Math.max(0,n-e.length))}function tN(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;const t=[];let r=0;for(;r<e.length;)t.push(e.substr(r,n)),r+=n;return t}function fl(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},t=arguments.length>2?arguments[2]:void 0;const r={};for(const c in e)r[c]=e[c];for(const c in n){const h=e[c],g=n[c];if(yx(h)&&yx(g)){r[c]=fl(h,g,t);continue}if(t&&Array.isArray(h)&&Array.isArray(g)){r[c]=t(h,g);continue}r[c]=g}return r}function wx(e){return e.map(n=>n.type===Ir?wx(n.children):n).flat()}function _a(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(_a.cache.has(e))return _a.cache.get(e);const n=e.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return _a.cache.set(e,n),n}_a.cache=new Map;function bc(e,n){if(!n||typeof n!="object")return[];if(Array.isArray(n))return n.map(t=>bc(e,t)).flat(1);if(n.suspense)return bc(e,n.ssContent);if(Array.isArray(n.children))return n.children.map(t=>bc(e,t)).flat(1);if(n.component){if(Object.getOwnPropertyDescriptor(n.component.provides,e))return[n.component];if(n.component.subTree)return bc(e,n.component.subTree).flat(1)}return[]}function xx(e){const n=Il({});ai(()=>{const r=e();for(const c in r)n[c]=r[c]},{flush:"sync"});const t={};for(const r in n)t[r]=Lt(()=>n[r]);return t}function wp(e,n){return e.includes(n)}function Cx(e,n){return n="on"+Wh(n),!!(e[n]||e[`${n}Once`]||e[`${n}Capture`]||e[`${n}OnceCapture`]||e[`${n}CaptureOnce`])}function nN(){const e=Hi(),n=t=>{e.value=t};return Object.defineProperty(n,"value",{enumerable:!0,get:()=>e.value,set:t=>e.value=t}),Object.defineProperty(n,"el",{enumerable:!0,get:()=>Z2(e.value)}),n}function Hu(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"||typeof e=="bigint"}function rN(e){const n=["checked","disabled"];return Object.fromEntries(Object.entries(e).filter(t=>{let[r,c]=t;return n.includes(r)?!!c:c!==void 0}))}const iN=["top","bottom"],oN=["start","end","left","right"];function sN(e,n){let[t,r]=e.split(" ");return r||(r=wp(iN,t)?"start":wp(oN,t)?"top":"center"),{side:kx(t,n),align:kx(r,n)}}function kx(e,n){return e==="start"?n?"right":"left":e==="end"?n?"left":"right":e}class xp{constructor(n){const t=document.body.currentCSSZoom??1,r=n instanceof Element,c=r?1+(1-t)/t:1,{x:h,y:g,width:v,height:s}=r?n.getBoundingClientRect():n;this.x=h*c,this.y=g*c,this.width=v*c,this.height=s*c}get top(){return this.y}get bottom(){return this.y+this.height}get left(){return this.x}get right(){return this.x+this.width}}function aN(e){if(Array.isArray(e)){const n=document.body.currentCSSZoom??1,t=1+(1-n)/n;return new xp({x:e[0]*t,y:e[1]*t,width:0*t,height:0*t})}else return new xp(e)}const pl=2.4,_x=.2126729,Ax=.7151522,$x=.072175,lN=.55,cN=.58,uN=.57,hN=.62,Uu=.03,Sx=1.45,dN=5e-4,fN=1.25,pN=1.25,Tx=.078,Ex=12.82051282051282,Vu=.06,Ix=.001;function Mx(e,n){const t=(e.r/255)**pl,r=(e.g/255)**pl,c=(e.b/255)**pl,h=(n.r/255)**pl,g=(n.g/255)**pl,v=(n.b/255)**pl;let s=t*_x+r*Ax+c*$x,p=h*_x+g*Ax+v*$x;if(s<=Uu&&(s+=(Uu-s)**Sx),p<=Uu&&(p+=(Uu-p)**Sx),Math.abs(p-s)<dN)return 0;let a;if(p>s){const l=(p**lN-s**cN)*fN;a=l<Ix?0:l<Tx?l-l*Ex*Vu:l-Vu}else{const l=(p**hN-s**uN)*pN;a=l>-Ix?0:l>-Tx?l-l*Ex*Vu:l+Vu}return a*100}function Cp(e){return!!e&&/^(#|var\(--|(rgb|hsl)a?\()/.test(e)}function gN(e){return Cp(e)&&!/^((rgb|hsl)a?\()?var\(--/.test(e)}const Rx=/^(?<fn>(?:rgb|hsl)a?)\((?<values>.+)\)/,mN={rgb:(e,n,t,r)=>({r:e,g:n,b:t,a:r}),rgba:(e,n,t,r)=>({r:e,g:n,b:t,a:r}),hsl:(e,n,t,r)=>Lx({h:e,s:n,l:t,a:r}),hsla:(e,n,t,r)=>Lx({h:e,s:n,l:t,a:r}),hsv:(e,n,t,r)=>xc({h:e,s:n,v:t,a:r}),hsva:(e,n,t,r)=>xc({h:e,s:n,v:t,a:r})};function wc(e){if(typeof e=="number")return(isNaN(e)||e<0||e>16777215)&&dl(`'${e}' is not a valid hex color`),{r:(e&16711680)>>16,g:(e&65280)>>8,b:e&255};if(typeof e=="string"&&Rx.test(e)){const{groups:n}=e.match(Rx),{fn:t,values:r}=n,c=r.split(/,\s*|\s*\/\s*|\s+/).map((h,g)=>h.endsWith("%")||g>0&&g<3&&["hsl","hsla","hsv","hsva"].includes(t)?parseFloat(h)/100:parseFloat(h));return mN[t](...c)}else if(typeof e=="string"){let n=e.startsWith("#")?e.slice(1):e;[3,4].includes(n.length)?n=n.split("").map(r=>r+r).join(""):[6,8].includes(n.length)||dl(`'${e}' is not a valid hex(a) color`);const t=parseInt(n,16);return(isNaN(t)||t<0||t>4294967295)&&dl(`'${e}' is not a valid hex(a) color`),vN(n)}else if(typeof e=="object"){if(bp(e,["r","g","b"]))return e;if(bp(e,["h","s","l"]))return xc(Ox(e));if(bp(e,["h","s","v"]))return xc(e)}throw new TypeError(`Invalid color: ${e==null?e:String(e)||e.constructor.name}
1493
+ Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function xc(e){const{h:n,s:t,v:r,a:c}=e,h=v=>{const s=(v+n/60)%6;return r-r*t*Math.max(Math.min(s,4-s,1),0)},g=[h(5),h(3),h(1)].map(v=>Math.round(v*255));return{r:g[0],g:g[1],b:g[2],a:c}}function Lx(e){return xc(Ox(e))}function Ox(e){const{h:n,s:t,l:r,a:c}=e,h=r+t*Math.min(r,1-r),g=h===0?0:2-2*r/h;return{h:n,s:g,v:h,a:c}}function vN(e){e=yN(e);let[n,t,r,c]=tN(e,2).map(h=>parseInt(h,16));return c=c===void 0?c:c/255,{r:n,g:t,b:r,a:c}}function yN(e){return e.startsWith("#")&&(e=e.slice(1)),e=e.replace(/([^0-9a-f])/gi,"F"),(e.length===3||e.length===4)&&(e=e.split("").map(n=>n+n).join("")),e.length!==6&&(e=bx(bx(e,6),8,"F")),e}function bN(e){const n=Math.abs(Mx(wc(0),wc(e)));return Math.abs(Mx(wc(16777215),wc(e)))>Math.min(n,50)?"#fff":"#000"}function Oo(e,n){const t=Ug();if(!t)throw new Error(`[Vuetify] ${e} must be called from inside a setup function`);return t}function Aa(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"composables";const n=Oo(e).type;return _a(n?.aliasName||n?.name)}function wN(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Oo("injectSelf");const{provides:t}=n;if(t&&e in t)return t[e]}const Gu=Symbol.for("vuetify:defaults");function kp(){const e=Xs(Gu);if(!e)throw new Error("[Vuetify] Could not find defaults instance");return e}function _p(e,n){const t=kp(),r=nn(e),c=vt(()=>{if(Ht(n?.disabled))return t.value;const h=Ht(n?.scoped),g=Ht(n?.reset),v=Ht(n?.root);if(r.value==null&&!(h||g||v))return t.value;let s=fl(r.value,{prev:t.value});if(h)return s;if(g||v){const p=Number(g||1/0);for(let a=0;a<=p&&!(!s||!("prev"in s));a++)s=s.prev;return s&&typeof v=="string"&&v in s&&(s=fl(fl(s,{prev:s}),s[v])),s}return s.prev?fl(s.prev,s):s});return Ba(Gu,c),c}function xN(e,n){return e.props&&(typeof e.props[n]<"u"||typeof e.props[_a(n)]<"u")}function CN(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0,t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:kp();const r=Oo("useDefaults");if(n=n??r.type.name??r.type.__name,!n)throw new Error("[Vuetify] Could not determine component name");const c=vt(()=>t.value?.[e._as??n]),h=new Proxy(e,{get(s,p){const a=Reflect.get(s,p);if(p==="class"||p==="style")return[c.value?.[p],a].filter(d=>d!=null);if(xN(r.vnode,p))return a;const l=c.value?.[p];if(l!==void 0)return l;const u=t.value?.global?.[p];return u!==void 0?u:a}}),g=Hi();ai(()=>{if(c.value){const s=Object.entries(c.value).filter(p=>{let[a]=p;return a.startsWith(a[0].toUpperCase())});g.value=s.length?Object.fromEntries(s):void 0}else g.value=void 0});function v(){const s=wN(Gu,r);Ba(Gu,vt(()=>g.value?fl(s?.value??{},g.value):s?.value))}return{props:h,provideSubDefaults:v}}function qu(e){if(e._setup=e._setup??e.setup,!e.name)return dl("The component is missing an explicit name, unable to generate default prop value"),e;if(e._setup){e.props=Qt(e.props??{},e.name)();const n=Object.keys(e.props).filter(t=>t!=="class"&&t!=="style");e.filterProps=function(t){return X2(t,n)},e.props._as=String,e.setup=function(t,r){const c=kp();if(!c.value)return e._setup(t,r);const{props:h,provideSubDefaults:g}=CN(t,t._as??e.name,c),v=e._setup(h,r);return g(),v}}return e}function Ar(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return n=>(e?qu:Ls)(n)}function Nx(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"div",t=arguments.length>2?arguments[2]:void 0;return Ar()({name:t??Wh(Kg(e.replace(/__/g,"-"))),props:{tag:{type:String,default:n},...$i()},setup(r,c){let{slots:h}=c;return()=>Eo(r.tag,{class:[e,r.class],style:r.style},h.default?.())}})}function kN(e,n,t,r){if(!t||Hu(e)||Hu(n))return;const c=t.get(e);if(c)c.set(n,r);else{const h=new WeakMap;h.set(n,r),t.set(e,h)}}function _N(e,n,t){if(!t||Hu(e)||Hu(n))return null;const r=t.get(e)?.get(n);if(typeof r=="boolean")return r;const c=t.get(n)?.get(e);return typeof c=="boolean"?c:null}function Ap(e,n){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:new WeakMap;if(e===n)return!0;if(e instanceof Date&&n instanceof Date&&e.getTime()!==n.getTime()||e!==Object(e)||n!==Object(n))return!1;const r=Object.keys(e);return r.length!==Object.keys(n).length?!1:_N(e,n,t)||(kN(e,n,t,!0),r.every(h=>Ap(e[h],n[h],t)))}function Si(e){const n=Oo("useRender");n.render=e}function Dx(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"content";const t=nN(),r=nn();if(ju){const c=new ResizeObserver(h=>{e?.(h,c),h.length&&(n==="content"?r.value=h[0].contentRect:r.value=h[0].target.getBoundingClientRect())});Zs(()=>{c.disconnect()}),wi(()=>t.el,(h,g)=>{g&&(c.unobserve(g),r.value=void 0),h&&c.observe(h)},{flush:"post"})}return{resizeRef:t,contentRect:Gg(r)}}function Px(e,n){let t;function r(){t=Zg(),t.run(()=>n.length?n(()=>{t?.stop(),r()}):n())}wi(e,c=>{c&&!t?r():c||(t?.stop(),t=void 0)},{immediate:!0}),jh(()=>{t?.stop()})}function zx(e,n,t){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:a=>a,c=arguments.length>4&&arguments[4]!==void 0?arguments[4]:a=>a;const h=Oo("useProxiedModel"),g=nn(e[n]!==void 0?e[n]:t),v=_a(n),s=vt(v!==n?()=>(e[n],!!((h.vnode.props?.hasOwnProperty(n)||h.vnode.props?.hasOwnProperty(v))&&(h.vnode.props?.hasOwnProperty(`onUpdate:${n}`)||h.vnode.props?.hasOwnProperty(`onUpdate:${v}`)))):()=>(e[n],!!(h.vnode.props?.hasOwnProperty(n)&&h.vnode.props?.hasOwnProperty(`onUpdate:${n}`))));Px(()=>!s.value,()=>{wi(()=>e[n],a=>{g.value=a})});const p=vt({get(){const a=e[n];return r(s.value?a:g.value)},set(a){const l=c(a),u=qg(s.value?e[n]:g.value);u===l||r(u)===a||(g.value=l,h?.emit(`update:${n}`,l))}});return Object.defineProperty(p,"externalValue",{get:()=>s.value?e[n]:g.value}),p}const AN=Symbol.for("vuetify:locale");function Bx(){const e=Xs(AN);if(!e)throw new Error("[Vuetify] Could not find injected rtl instance");return{isRtl:e.isRtl,rtlClasses:e.rtlClasses}}const $p=Symbol.for("vuetify:theme"),$a=Qt({theme:String},"theme");function gl(e){Oo("provideTheme");const n=Xs($p,null);if(!n)throw new Error("Could not find Vuetify theme injection");const t=Lt(()=>e.theme??n.name.value),r=Lt(()=>n.themes.value[t.value]),c=Lt(()=>n.isDisabled?void 0:`${n.prefix}theme--${t.value}`),h={...n,name:t,current:r,themeClasses:c};return Ba($p,h),h}function $N(){Oo("useTheme");const e=Xs($p,null);if(!e)throw new Error("Could not find Vuetify theme injection");return e}const No=Qt({tag:{type:[String,Object,Function],default:"div"}},"tag"),SN=Qt({disabled:Boolean,group:Boolean,hideOnLeave:Boolean,leaveAbsolute:Boolean,mode:String,origin:String},"transition");function Yi(e,n,t){return Ar()({name:e,props:SN({mode:t,origin:n}),setup(r,c){let{slots:h}=c;const g={onBeforeEnter(v){r.origin&&(v.style.transformOrigin=r.origin)},onLeave(v){if(r.leaveAbsolute){const{offsetTop:s,offsetLeft:p,offsetWidth:a,offsetHeight:l}=v;v._transitionInitialStyles={position:v.style.position,top:v.style.top,left:v.style.left,width:v.style.width,height:v.style.height},v.style.position="absolute",v.style.top=`${s}px`,v.style.left=`${p}px`,v.style.width=`${a}px`,v.style.height=`${l}px`}r.hideOnLeave&&v.style.setProperty("display","none","important")},onAfterLeave(v){if(r.leaveAbsolute&&v?._transitionInitialStyles){const{position:s,top:p,left:a,width:l,height:u}=v._transitionInitialStyles;delete v._transitionInitialStyles,v.style.position=s||"",v.style.top=p||"",v.style.left=a||"",v.style.width=l||"",v.style.height=u||""}}};return()=>{const v=r.group?Fc:El;return Eo(v,{name:r.disabled?"":e,css:!r.disabled,...r.group?void 0:{mode:r.mode},...r.disabled?{}:g},h.default)}}})}function Sp(e,n){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"in-out";return Ar()({name:e,props:{mode:{type:String,default:t},disabled:{type:Boolean,default:vx()},group:Boolean,hideOnLeave:Boolean},setup(r,c){let{slots:h}=c;const g=r.group?Fc:El;return()=>Eo(g,{name:r.disabled?"":e,css:!r.disabled,...r.disabled?{}:{...n,onLeave:v=>{r.hideOnLeave?v.style.setProperty("display","none","important"):n.onLeave?.(v)}}},h.default)}})}function Tp(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"y";return{onBeforeEnter(c){c._parent=c.parentNode,c._initialStyle={transition:c.style.transition,overflow:c.style.overflow,width:c.style.width,height:c.style.height}},onEnter(c){const h=c._initialStyle;if(!h)return;c.style.setProperty("transition","none","important"),c.style.overflow="hidden";const g=`${c.offsetWidth}px`,v=`${c.offsetHeight}px`;["x","both"].includes(n)&&(c.style.width="0"),["y","both"].includes(n)&&(c.style.height="0"),c.offsetHeight,c.style.transition=h.transition,e&&c._parent&&c._parent.classList.add(e),requestAnimationFrame(()=>{["x","both"].includes(n)&&(c.style.width=g),["y","both"].includes(n)&&(c.style.height=v)})},onAfterEnter:r,onEnterCancelled:r,onLeave(c){c._initialStyle={transition:"",overflow:c.style.overflow,width:c.style.width,height:c.style.height},c.style.overflow="hidden",["x","both"].includes(n)&&(c.style.width=`${c.offsetWidth}px`),["y","both"].includes(n)&&(c.style.height=`${c.offsetHeight}px`),c.offsetHeight,requestAnimationFrame(()=>{["x","both"].includes(n)&&(c.style.width="0"),["y","both"].includes(n)&&(c.style.height="0")})},onAfterLeave:t,onLeaveCancelled:t};function t(c){e&&c._parent&&c._parent.classList.remove(e),r(c)}function r(c){if(!c._initialStyle)return;const{width:h,height:g}=c._initialStyle;c.style.overflow=c._initialStyle.overflow,h!=null&&["x","both"].includes(n)&&(c.style.width=h),g!=null&&["y","both"].includes(n)&&(c.style.height=g),delete c._initialStyle}}Yi("fab-transition","center center","out-in"),Yi("dialog-bottom-transition"),Yi("dialog-top-transition"),Yi("fade-transition"),Yi("scale-transition"),Yi("scroll-x-transition"),Yi("scroll-x-reverse-transition"),Yi("scroll-y-transition"),Yi("scroll-y-reverse-transition"),Yi("slide-x-transition"),Yi("slide-x-reverse-transition"),Yi("slide-y-transition"),Yi("slide-y-reverse-transition");const TN=Sp("expand-transition",Tp());Sp("expand-x-transition",Tp("","x")),Sp("expand-both-transition",Tp("","both"));const EN=Qt({defaults:Object,disabled:Boolean,reset:[Number,String],root:[Boolean,String],scoped:Boolean},"VDefaultsProvider"),Sa=Ar(!1)({name:"VDefaultsProvider",props:EN(),setup(e,n){let{slots:t}=n;const{defaults:r,disabled:c,reset:h,root:g,scoped:v}=Wg(e);return _p(r,{reset:h,root:g,scoped:v,disabled:c}),()=>t.default?.()}}),Ep=Qt({height:[Number,String],maxHeight:[Number,String],maxWidth:[Number,String],minHeight:[Number,String],minWidth:[Number,String],width:[Number,String]},"dimension");function Ip(e){return{dimensionStyles:vt(()=>{const n={},t=Nn(e.height),r=Nn(e.maxHeight),c=Nn(e.maxWidth),h=Nn(e.minHeight),g=Nn(e.minWidth),v=Nn(e.width);return t!=null&&(n.height=t),r!=null&&(n.maxHeight=r),c!=null&&(n.maxWidth=c),h!=null&&(n.minHeight=h),g!=null&&(n.minWidth=g),v!=null&&(n.width=v),n})}}function IN(e){return{aspectStyles:vt(()=>{const n=Number(e.aspectRatio);return n?{paddingBottom:String(1/n*100)+"%"}:void 0})}}const Fx=Qt({aspectRatio:[String,Number],contentClass:null,inline:Boolean,...$i(),...Ep()},"VResponsive"),jx=Ar()({name:"VResponsive",props:Fx(),setup(e,n){let{slots:t}=n;const{aspectStyles:r}=IN(e),{dimensionStyles:c}=Ip(e);return Si(()=>gt("div",{class:an(["v-responsive",{"v-responsive--inline":e.inline},e.class]),style:Un([c.value,e.style])},[gt("div",{class:"v-responsive__sizer",style:Un(r.value)},null),t.additional?.(),t.default&&gt("div",{class:an(["v-responsive__content",e.contentClass])},[t.default()])])),{}}});function Mp(e){return xx(()=>{const{class:n,style:t}=RN(e);return{colorClasses:n,colorStyles:t}})}function Yu(e){const{colorClasses:n,colorStyles:t}=Mp(()=>({text:cs(e)}));return{textColorClasses:n,textColorStyles:t}}function Ku(e){const{colorClasses:n,colorStyles:t}=Mp(()=>({background:cs(e)}));return{backgroundColorClasses:n,backgroundColorStyles:t}}function MN(e){return{text:typeof e.text=="string"?e.text.replace(/^text-/,""):e.text,background:typeof e.background=="string"?e.background.replace(/^bg-/,""):e.background}}function RN(e){const n=MN(cs(e)),t=[],r={};if(n.background)if(Cp(n.background)){if(r.backgroundColor=n.background,!n.text&&gN(n.background)){const c=wc(n.background);if(c.a==null||c.a===1){const h=bN(c);r.color=h,r.caretColor=h}}}else t.push(`bg-${n.background}`);return n.text&&(Cp(n.text)?(r.color=n.text,r.caretColor=n.text):t.push(`text-${n.text}`)),{class:t,style:r}}const ml=Qt({rounded:{type:[Boolean,Number,String],default:void 0},tile:Boolean},"rounded");function vl(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Aa();return{roundedClasses:vt(()=>{const t=jc(e)?e.value:e.rounded,r=jc(e)?!1:e.tile,c=[];if(r||t===!1)c.push("rounded-0");else if(t===!0||t==="")c.push(`${n}--rounded`);else if(typeof t=="string"||t===0)for(const h of String(t).split(" "))c.push(`rounded-${h}`);return c})}}const LN=Qt({transition:{type:null,default:"fade-transition",validator:e=>e!==!0}},"transition"),Ju=(e,n)=>{let{slots:t}=n;const{transition:r,disabled:c,group:h,target:g,...v}=e,{component:s=h?Fc:El,...p}=yp(r)?r:{};let a;return yp(r)?a=fr(p,rN({disabled:c,group:h,target:g}),v):a=fr({name:c||!r?"":r},v),Eo(s,a,t)};function Wx(e,n){if(!vp)return;const t=n.modifiers||{},r=n.value,{handler:c,options:h}=typeof r=="object"?r:{handler:r,options:{}},g=new IntersectionObserver(function(){let v=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],s=arguments.length>1?arguments[1]:void 0;const p=e._observe?.[n.instance.$.uid];if(!p)return;const a=v.some(l=>l.isIntersecting);c&&(!t.quiet||p.init)&&(!t.once||a||p.init)&&c(a,v,s),a&&t.once?Rp(e,n):p.init=!0},h);e._observe=Object(e._observe),e._observe[n.instance.$.uid]={init:!1,observer:g},g.observe(e)}function Rp(e,n){const t=e._observe?.[n.instance.$.uid];t&&(t.observer.unobserve(e),delete e._observe[n.instance.$.uid])}const Hx={mounted:Wx,unmounted:Rp,updated:(e,n)=>{e._observe?.[n.instance.$.uid]&&(Rp(e,n),Wx(e,n))}},ON=Qt({absolute:Boolean,alt:String,cover:Boolean,color:String,draggable:{type:[Boolean,String],default:void 0},eager:Boolean,gradient:String,imageClass:null,lazySrc:String,options:{type:Object,default:()=>({root:void 0,rootMargin:void 0,threshold:void 0})},sizes:String,src:{type:[String,Object],default:""},crossorigin:String,referrerpolicy:String,srcset:String,position:String,...Fx(),...$i(),...ml(),...LN()},"VImg"),Qu=Ar()({name:"VImg",directives:{vIntersect:Hx},props:ON(),emits:{loadstart:e=>!0,load:e=>!0,error:e=>!0},setup(e,n){let{emit:t,slots:r}=n;const{backgroundColorClasses:c,backgroundColorStyles:h}=Ku(()=>e.color),{roundedClasses:g}=vl(e),v=Oo("VImg"),s=Hi(""),p=nn(),a=Hi(e.eager?"loading":"idle"),l=Hi(),u=Hi();let d=!1;const o=vt(()=>e.src&&typeof e.src=="object"?{src:e.src.src,srcset:e.srcset||e.src.srcset,lazySrc:e.lazySrc||e.src.lazySrc,aspect:Number(e.aspectRatio||e.src.aspect||0)}:{src:e.src,srcset:e.srcset,lazySrc:e.lazySrc,aspect:Number(e.aspectRatio||0)}),f=vt(()=>o.value.aspect||l.value/u.value||0);wi(()=>e.src,()=>{m(a.value!=="idle")}),wi(f,(M,$)=>{!M&&$&&p.value&&_(p.value)}),wi(p,M=>{!M||a.value==="idle"||(f.value||_(M),R(M),d&&(d=!1,t("load",M.currentSrc||o.value.src)))}),Hg(()=>m());function m(M){if(!(e.eager&&M)&&!(vp&&!M&&!e.eager)){if(a.value="loading",o.value.lazySrc){const $=new Image;$.src=o.value.lazySrc,_($,null)}o.value.src&&Tl(()=>{t("loadstart",p.value?.currentSrc||o.value.src),setTimeout(()=>{if(!v.isUnmounted)if(p.value?.complete){if(p.value.naturalWidth||x(),a.value==="error")return;f.value||_(p.value,null),a.value==="loading"&&w()}else p.value&&(f.value||_(p.value),R(p.value))})})}}function w(){v.isUnmounted||(p.value?(R(p.value),_(p.value),t("load",p.value.currentSrc||o.value.src)):d=!0,a.value="loaded")}function x(){v.isUnmounted||(a.value="error",t("error",p.value?.currentSrc||o.value.src))}function R(M){s.value=M.currentSrc||M.src}let T=-1;Zs(()=>{clearTimeout(T)});function _(M){let $=arguments.length>1&&arguments[1]!==void 0?arguments[1]:100;const A=()=>{if(clearTimeout(T),v.isUnmounted)return;const{naturalHeight:D,naturalWidth:j}=M;D||j?(l.value=j,u.value=D):!M.complete&&a.value==="loading"&&$!=null?T=window.setTimeout(A,$):(M.currentSrc.endsWith(".svg")||M.currentSrc.startsWith("data:image/svg+xml"))&&(l.value=1,u.value=1)};A()}const C=Lt(()=>({"v-img__img--cover":e.cover,"v-img__img--contain":!e.cover})),P=()=>{if(!o.value.src||a.value==="idle")return null;const M=gt("img",{class:an(["v-img__img",C.value,e.imageClass]),style:{objectPosition:e.position},crossorigin:e.crossorigin,src:o.value.src,srcset:o.value.srcset,alt:e.alt,referrerpolicy:e.referrerpolicy,draggable:e.draggable,sizes:e.sizes,ref:p,onLoad:w,onError:x},null),$=r.sources?.();return Ge(Ju,{transition:e.transition,appear:!0},{default:()=>[ja($?gt("picture",{class:"v-img__picture"},[$,M]):M,[[Uh,a.value==="loaded"]])]})},O=()=>Ge(Ju,{transition:e.transition},{default:()=>[o.value.lazySrc&&a.value!=="loaded"&&gt("img",{class:an(["v-img__img","v-img__img--preload",C.value]),style:{objectPosition:e.position},crossorigin:e.crossorigin,src:o.value.lazySrc,alt:e.alt,referrerpolicy:e.referrerpolicy,draggable:e.draggable},null)]}),E=()=>r.placeholder?Ge(Ju,{transition:e.transition,appear:!0},{default:()=>[(a.value==="loading"||a.value==="error"&&!r.error)&&gt("div",{class:"v-img__placeholder"},[r.placeholder()])]}):null,k=()=>r.error?Ge(Ju,{transition:e.transition,appear:!0},{default:()=>[a.value==="error"&&gt("div",{class:"v-img__error"},[r.error()])]}):null,B=()=>e.gradient?gt("div",{class:"v-img__gradient",style:{backgroundImage:`linear-gradient(${e.gradient})`}},null):null,N=Hi(!1);{const M=wi(f,$=>{$&&(requestAnimationFrame(()=>{requestAnimationFrame(()=>{N.value=!0})}),M())})}return Si(()=>{const M=jx.filterProps(e);return ja(Ge(jx,fr({class:["v-img",{"v-img--absolute":e.absolute,"v-img--booting":!N.value,"v-img--fit-content":e.width==="fit-content"},c.value,g.value,e.class],style:[{width:Nn(e.width==="auto"?l.value:e.width)},h.value,e.style]},M,{aspectRatio:f.value,"aria-label":e.alt,role:e.alt?"img":void 0}),{additional:()=>gt(Ir,null,[Ge(P,null,null),Ge(O,null,null),Ge(B,null,null),Ge(E,null,null),Ge(k,null,null)]),default:r.default}),[[Hx,{handler:m,options:e.options},null,{once:!0}]])}),{currentSrc:s,image:p,state:a,naturalWidth:l,naturalHeight:u}}}),Zu=Qt({border:[Boolean,Number,String]},"border");function Xu(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Aa();return{borderClasses:vt(()=>{const t=e.border;return t===!0||t===""?`${n}--border`:typeof t=="string"||t===0?String(t).split(" ").map(r=>`border-${r}`):[]})}}const Lp=Qt({elevation:{type:[Number,String],validator(e){const n=parseInt(e);return!isNaN(n)&&n>=0&&n<=24}}},"elevation");function Op(e){return{elevationClasses:Lt(()=>{const n=jc(e)?e.value:e.elevation;return n==null?[]:[`elevation-${n}`]})}}const Ux={center:"center",top:"bottom",bottom:"top",left:"right",right:"left"},Np=Qt({location:String},"location");function Dp(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,t=arguments.length>2?arguments[2]:void 0;const{isRtl:r}=Bx();return{locationStyles:vt(()=>{if(!e.location)return{};const{side:c,align:h}=sN(e.location.split(" ").length>1?e.location:`${e.location} center`,r.value);function g(s){return t?t(s):0}const v={};return c!=="center"&&(n?v[Ux[c]]=`calc(100% - ${g(c)}px)`:v[c]=0),h!=="center"?n?v[Ux[h]]=`calc(100% - ${g(h)}px)`:v[h]=0:(c==="center"?v.top=v.left="50%":v[{top:"left",bottom:"left",left:"top",right:"top"}[c]]="50%",v.transform={top:"translateX(-50%)",bottom:"translateX(-50%)",left:"translateY(-50%)",right:"translateY(-50%)",center:"translate(-50%, -50%)"}[c]),v})}}const NN=[null,"default","comfortable","compact"],Cc=Qt({density:{type:String,default:"default",validator:e=>NN.includes(e)}},"density");function eh(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Aa();return{densityClasses:Lt(()=>`${n}--density-${e.density}`)}}const DN=["x-small","small","default","large","x-large"],kc=Qt({size:{type:[String,Number],default:"default"}},"size");function th(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Aa();return xx(()=>{const t=e.size;let r,c;return wp(DN,t)?r=`${n}--size-${t}`:t&&(c={width:Nn(t),height:Nn(t)}),{sizeClasses:r,sizeStyles:c}})}const PN=["elevated","flat","tonal","outlined","text","plain"];function Pp(e,n){return gt(Ir,null,[e&&gt("span",{key:"overlay",class:an(`${n}__overlay`)},null),gt("span",{key:"underlay",class:an(`${n}__underlay`)},null)])}const nh=Qt({color:String,variant:{type:String,default:"elevated",validator:e=>PN.includes(e)}},"variant");function zp(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Aa();const t=Lt(()=>{const{variant:h}=cs(e);return`${n}--variant-${h}`}),{colorClasses:r,colorStyles:c}=Mp(()=>{const{variant:h,color:g}=cs(e);return{[["elevated","flat"].includes(h)?"background":"text"]:g}});return{colorClasses:r,colorStyles:c,variantClasses:t}}const Vx=Qt({baseColor:String,divided:Boolean,direction:{type:String,default:"horizontal"},...Zu(),...$i(),...Cc(),...Lp(),...ml(),...kc({size:void 0}),...No(),...$a(),...nh()},"VBtnGroup"),Gx=Ar()({name:"VBtnGroup",props:Vx(),setup(e,n){let{slots:t}=n;const{themeClasses:r}=gl(e),{densityClasses:c}=eh(e),{borderClasses:h}=Xu(e),{elevationClasses:g}=Op(e),{roundedClasses:v}=vl(e);_p({VBtn:{height:Lt(()=>e.direction==="horizontal"&&e.size==null?"auto":null),baseColor:Lt(()=>e.baseColor),color:Lt(()=>e.color),density:Lt(()=>e.density),flat:!0,size:Lt(()=>e.size),variant:Lt(()=>e.variant)}}),Si(()=>Ge(e.tag,{class:an(["v-btn-group",`v-btn-group--${e.direction}`,{"v-btn-group--divided":e.divided,"v-btn-group--has-size":e.size!=null},r.value,h.value,c.value,g.value,v.value,e.class]),style:Un(e.style)},t))}}),zN=Qt({modelValue:{type:null,default:void 0},multiple:Boolean,mandatory:[Boolean,String],max:Number,selectedClass:String,disabled:Boolean},"group"),BN=Qt({value:null,disabled:Boolean,selectedClass:String},"group-item");function FN(e,n){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;const r=Oo("useGroupItem");if(!r)throw new Error("[Vuetify] useGroupItem composable must be used inside a component setup function");const c=Yg();Ba(Symbol.for(`${n.description}:id`),c);const h=Xs(n,null);if(!h){if(!t)return h;throw new Error(`[Vuetify] Could not find useGroup injection with symbol ${n.description}`)}const g=Lt(()=>e.value),v=vt(()=>!!(h.disabled.value||e.disabled));function s(){h?.register({id:c,value:g,disabled:v},r)}function p(){h?.unregister(c)}s(),Zs(()=>p());const a=vt(()=>h.isSelected(c)),l=vt(()=>h.items.value[0].id===c),u=vt(()=>h.items.value[h.items.value.length-1].id===c),d=vt(()=>a.value&&[h.selectedClass.value,e.selectedClass]);return wi(a,o=>{r.emit("group:selected",{value:o})},{flush:"sync"}),{id:c,isSelected:a,isFirst:l,isLast:u,toggle:()=>h.select(c,!a.value),select:o=>h.select(c,o),selectedClass:d,value:g,disabled:v,group:h,register:s,unregister:p}}function jN(e,n){let t=!1;const r=Il([]),c=zx(e,"modelValue",[],u=>u===void 0?[]:qx(r,u===null?[null]:eN(u)),u=>{const d=HN(r,u);return e.multiple?d:d[0]}),h=Oo("useGroup");function g(u,d){const o=u,f=Symbol.for(`${n.description}:id`),m=bc(f,h?.vnode).indexOf(d);Ht(o.value)===void 0&&(o.value=m,o.useIndexAsValue=!0),m>-1?r.splice(m,0,o):r.push(o)}function v(u){if(t)return;s();const d=r.findIndex(o=>o.id===u);r.splice(d,1)}function s(){const u=r.find(d=>!d.disabled);u&&e.mandatory==="force"&&!c.value.length&&(c.value=[u.id])}Fa(()=>{s()}),Zs(()=>{t=!0}),Vg(()=>{for(let u=0;u<r.length;u++)r[u].useIndexAsValue&&(r[u].value=u)});function p(u,d){const o=r.find(f=>f.id===u);if(!(d&&o?.disabled))if(e.multiple){const f=c.value.slice(),m=f.findIndex(x=>x===u),w=~m;if(d=d??!w,w&&e.mandatory&&f.length<=1||!w&&e.max!=null&&f.length+1>e.max)return;m<0&&d?f.push(u):m>=0&&!d&&f.splice(m,1),c.value=f}else{const f=c.value.includes(u);if(e.mandatory&&f||!f&&!d)return;c.value=d??!f?[u]:[]}}function a(u){if(e.multiple&&dl('This method is not supported when using "multiple" prop'),c.value.length){const d=c.value[0],o=r.findIndex(w=>w.id===d);let f=(o+u)%r.length,m=r[f];for(;m.disabled&&f!==o;)f=(f+u)%r.length,m=r[f];if(m.disabled)return;c.value=[r[f].id]}else{const d=r.find(o=>!o.disabled);d&&(c.value=[d.id])}}const l={register:g,unregister:v,selected:c,select:p,disabled:Lt(()=>e.disabled),prev:()=>a(r.length-1),next:()=>a(1),isSelected:u=>c.value.includes(u),selectedClass:Lt(()=>e.selectedClass),items:Lt(()=>r),getItemIndex:u=>WN(r,u)};return Ba(n,l),l}function WN(e,n){const t=qx(e,[n]);return t.length?e.findIndex(r=>r.id===t[0]):-1}function qx(e,n){const t=[];return n.forEach(r=>{const c=e.find(g=>Ap(r,g.value)),h=e[r];c?.value!==void 0?t.push(c.id):h?.useIndexAsValue&&t.push(h.id)}),t}function HN(e,n){const t=[];return n.forEach(r=>{const c=e.findIndex(h=>h.id===r);if(~c){const h=e[c];t.push(h.value!==void 0?h.value:c)}}),t}const Yx=Symbol.for("vuetify:v-btn-toggle"),UN=Qt({...Vx(),...zN()},"VBtnToggle");Ar()({name:"VBtnToggle",props:UN(),emits:{"update:modelValue":e=>!0},setup(e,n){let{slots:t}=n;const{isSelected:r,next:c,prev:h,select:g,selected:v}=jN(e,Yx);return Si(()=>{const s=Gx.filterProps(e);return Ge(Gx,fr({class:["v-btn-toggle",e.class]},s,{style:e.style}),{default:()=>[t.default?.({isSelected:r,next:c,prev:h,select:g,selected:v})]})}),{next:c,prev:h,select:g}}});const ps=[String,Function,Object,Array],VN=Symbol.for("vuetify:icons"),rh=Qt({icon:{type:ps},tag:{type:[String,Object,Function],required:!0}},"icon"),Kx=Ar()({name:"VComponentIcon",props:rh(),setup(e,n){let{slots:t}=n;return()=>{const r=e.icon;return Ge(e.tag,null,{default:()=>[e.icon?Ge(r,null,null):t.default?.()]})}}}),GN=qu({name:"VSvgIcon",inheritAttrs:!1,props:rh(),setup(e,n){let{attrs:t}=n;return()=>Ge(e.tag,fr(t,{style:null}),{default:()=>[gt("svg",{class:"v-icon__svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true"},[Array.isArray(e.icon)?e.icon.map(r=>Array.isArray(r)?gt("path",{d:r[0],"fill-opacity":r[1]},null):gt("path",{d:r},null)):gt("path",{d:e.icon},null)])]})}});qu({name:"VLigatureIcon",props:rh(),setup(e){return()=>Ge(e.tag,null,{default:()=>[e.icon]})}});const qN=qu({name:"VClassIcon",props:rh(),setup(e){return()=>Ge(e.tag,{class:an(e.icon)},null)}}),YN=e=>{const n=Xs(VN);if(!n)throw new Error("Missing Vuetify Icons provide!");return{iconData:vt(()=>{const t=cs(e);if(!t)return{component:Kx};let r=t;if(typeof r=="string"&&(r=r.trim(),r.startsWith("$")&&(r=n.aliases?.[r.slice(1)])),r||dl(`Could not find aliased icon "${t}"`),Array.isArray(r))return{component:GN,icon:r};if(typeof r!="string")return{component:Kx,icon:r};const c=Object.keys(n.sets).find(g=>typeof r=="string"&&r.startsWith(`${g}:`)),h=c?r.slice(c.length+1):r;return{component:n.sets[c??n.defaultSet].component,icon:h}})}},KN=Qt({color:String,disabled:Boolean,start:Boolean,end:Boolean,icon:ps,opacity:[String,Number],...$i(),...kc(),...No({tag:"i"}),...$a()},"VIcon"),Ta=Ar()({name:"VIcon",props:KN(),setup(e,n){let{attrs:t,slots:r}=n;const c=Hi(),{themeClasses:h}=$N(),{iconData:g}=YN(()=>c.value||e.icon),{sizeClasses:v}=th(e),{textColorClasses:s,textColorStyles:p}=Yu(()=>e.color);return Si(()=>{const a=r.default?.();a&&(c.value=wx(a).filter(u=>u.type===tm&&u.children&&typeof u.children=="string")[0]?.children);const l=!!(t.onClick||t.onClickOnce);return Ge(g.value.component,{tag:e.tag,icon:g.value.icon,class:an(["v-icon","notranslate",h.value,v.value,s.value,{"v-icon--clickable":l,"v-icon--disabled":e.disabled,"v-icon--start":e.start,"v-icon--end":e.end},e.class]),style:Un([{"--v-icon-opacity":e.opacity},v.value?void 0:{fontSize:Nn(e.size),height:Nn(e.size),width:Nn(e.size)},p.value,e.style]),role:l?"button":void 0,"aria-hidden":!l,tabindex:l?e.disabled?-1:0:void 0},{default:()=>[a]})}),{}}});function Jx(e,n){const t=nn(),r=Hi(!1);if(vp){const c=new IntersectionObserver(h=>{r.value=!!h.find(g=>g.isIntersecting)},n);jh(()=>{c.disconnect()}),wi(t,(h,g)=>{g&&(c.unobserve(g),r.value=!1),h&&c.observe(h)},{flush:"post"})}return{intersectionRef:t,isIntersecting:r}}const JN=Qt({reveal:{type:[Boolean,Object],default:!1}},"reveal");function QN(e){const n=Lt(()=>typeof e.reveal=="object"?Math.max(0,Number(e.reveal.duration??900)):900),t=Hi(e.reveal?"initial":"disabled");return Fa(async()=>{e.reveal&&(t.value="initial",await new Promise(r=>requestAnimationFrame(r)),t.value="pending",await new Promise(r=>setTimeout(r,n.value)),t.value="done")}),{duration:n,state:t}}const ZN=Qt({bgColor:String,color:String,indeterminate:[Boolean,String],rounded:Boolean,modelValue:{type:[Number,String],default:0},rotate:{type:[Number,String],default:0},width:{type:[Number,String],default:4},...$i(),...JN(),...kc(),...No({tag:"div"}),...$a()},"VProgressCircular"),Bp=Ar()({name:"VProgressCircular",props:ZN(),setup(e,n){let{slots:t}=n;const r=20,c=2*Math.PI*r,h=nn(),{themeClasses:g}=gl(e),{sizeClasses:v,sizeStyles:s}=th(e),{textColorClasses:p,textColorStyles:a}=Yu(()=>e.color),{textColorClasses:l,textColorStyles:u}=Yu(()=>e.bgColor),{intersectionRef:d,isIntersecting:o}=Jx(),{resizeRef:f,contentRect:m}=Dx(),{state:w,duration:x}=QN(e),R=Lt(()=>w.value==="initial"?0:Wu(parseFloat(e.modelValue),0,100)),T=Lt(()=>Number(e.width)),_=Lt(()=>s.value?Number(e.size):m.value?m.value.width:Math.max(T.value,32)),C=Lt(()=>r/(1-T.value/_.value)*2),P=Lt(()=>T.value/_.value*C.value),O=Lt(()=>{const k=(100-R.value)/100*c;return e.rounded&&R.value>0&&R.value<100?Nn(Math.min(c-.01,k+P.value)):Nn(k)}),E=vt(()=>{const k=Number(e.rotate);return e.rounded?k+P.value/2/c*360:k});return ai(()=>{d.value=h.value,f.value=h.value}),Si(()=>Ge(e.tag,{ref:h,class:an(["v-progress-circular",{"v-progress-circular--indeterminate":!!e.indeterminate,"v-progress-circular--visible":o.value,"v-progress-circular--disable-shrink":e.indeterminate&&(e.indeterminate==="disable-shrink"||vx()),"v-progress-circular--revealing":["initial","pending"].includes(w.value)},g.value,v.value,p.value,e.class]),style:Un([s.value,a.value,{"--progress-reveal-duration":`${x.value}ms`},e.style]),role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.indeterminate?void 0:R.value},{default:()=>[gt("svg",{style:{transform:`rotate(calc(-90deg + ${E.value}deg))`},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${C.value} ${C.value}`},[gt("circle",{class:an(["v-progress-circular__underlay",l.value]),style:Un(u.value),fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":P.value,"stroke-dasharray":c,"stroke-dashoffset":0},null),gt("circle",{class:"v-progress-circular__overlay",fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":P.value,"stroke-dasharray":c,"stroke-dashoffset":O.value,"stroke-linecap":e.rounded?"round":void 0},null)]),t.default&&gt("div",{class:"v-progress-circular__content"},[t.default({value:R.value})])]})),{}}}),XN=Qt({chunkCount:{type:[Number,String],default:null},chunkWidth:{type:[Number,String],default:null},chunkGap:{type:[Number,String],default:4}},"chunks");function eD(e,n){const t=Lt(()=>!!e.chunkCount||!!e.chunkWidth),r=vt(()=>{const v=cs(n);if(!v)return 0;if(!e.chunkCount)return Number(e.chunkWidth);const s=Number(e.chunkCount);return(v-Number(e.chunkGap)*(s-1))/s}),c=Lt(()=>Number(e.chunkGap)),h=vt(()=>{if(!t.value)return{};const v=Nn(c.value),s=Nn(r.value);return{maskRepeat:"repeat-x",maskImage:`linear-gradient(90deg, #000, #000 ${s}, transparent ${s}, transparent)`,maskSize:`calc(${s} + ${v}) 100%`}});function g(v){const s=cs(n);if(!s)return v;const p=100*c.value/s,a=100*(r.value+c.value)/s,l=Math.floor((v+p)/a+1e-9);return Wu(l*a-p/2,0,100)}return{hasChunks:t,chunksMaskStyles:h,snapValueToChunk:g}}const tD=Qt({absolute:Boolean,active:{type:Boolean,default:!0},bgColor:String,bgOpacity:[Number,String],bufferValue:{type:[Number,String],default:0},bufferColor:String,bufferOpacity:[Number,String],clickable:Boolean,color:String,height:{type:[Number,String],default:4},indeterminate:Boolean,max:{type:[Number,String],default:100},modelValue:{type:[Number,String],default:0},opacity:[Number,String],reverse:Boolean,stream:Boolean,striped:Boolean,roundedBar:Boolean,...XN(),...$i(),...Np({location:"top"}),...ml(),...No(),...$a()},"VProgressLinear"),Qx=Ar()({name:"VProgressLinear",props:tD(),emits:{"update:modelValue":e=>!0},setup(e,n){let{slots:t}=n;const r=nn(),c=zx(e,"modelValue"),{isRtl:h,rtlClasses:g}=Bx(),{themeClasses:v}=gl(e),{locationStyles:s}=Dp(e),{textColorClasses:p,textColorStyles:a}=Yu(()=>e.color),{backgroundColorClasses:l,backgroundColorStyles:u}=Ku(()=>e.bgColor||e.color),{backgroundColorClasses:d,backgroundColorStyles:o}=Ku(()=>e.bufferColor||e.bgColor||e.color),{backgroundColorClasses:f,backgroundColorStyles:m}=Ku(()=>e.color),{roundedClasses:w}=vl(e),{intersectionRef:x,isIntersecting:R}=Jx(),T=vt(()=>parseFloat(e.max)),_=vt(()=>parseFloat(e.height)),C=vt(()=>Wu(parseFloat(e.bufferValue)/T.value*100,0,100)),P=vt(()=>Wu(parseFloat(c.value)/T.value*100,0,100)),O=vt(()=>h.value!==e.reverse),E=vt(()=>e.indeterminate?"fade-transition":"slide-x-transition"),k=Hi(0),{hasChunks:B,chunksMaskStyles:N,snapValueToChunk:M}=eD(e,k);Px(B,()=>{const{resizeRef:j}=Dx(U=>k.value=U[0].contentRect.width);ai(()=>j.value=r.value)});const $=vt(()=>B.value?M(C.value):C.value),A=vt(()=>B.value?M(P.value):P.value);function D(j){if(!x.value)return;const{left:U,right:q,width:Q}=x.value.getBoundingClientRect(),re=O.value?Q-j.clientX+(q-Q):j.clientX-U;c.value=Math.round(re/Q*T.value)}return ai(()=>{x.value=r.value}),Si(()=>Ge(e.tag,{ref:r,class:an(["v-progress-linear",{"v-progress-linear--absolute":e.absolute,"v-progress-linear--active":e.active&&R.value,"v-progress-linear--reverse":O.value,"v-progress-linear--rounded":e.rounded,"v-progress-linear--rounded-bar":e.roundedBar,"v-progress-linear--striped":e.striped,"v-progress-linear--clickable":e.clickable},w.value,v.value,g.value,e.class]),style:Un([{bottom:e.location==="bottom"?0:void 0,top:e.location==="top"?0:void 0,height:e.active?Nn(_.value):0,"--v-progress-linear-height":Nn(_.value),...e.absolute?s.value:{}},N.value,e.style]),role:"progressbar","aria-hidden":e.active?"false":"true","aria-valuemin":"0","aria-valuemax":e.max,"aria-valuenow":e.indeterminate?void 0:Math.min(parseFloat(c.value),T.value),onClick:e.clickable&&D},{default:()=>[e.stream&&gt("div",{key:"stream",class:an(["v-progress-linear__stream",p.value]),style:{...a.value,[O.value?"left":"right"]:Nn(-_.value),borderTop:`${Nn(_.value/2)} dotted`,opacity:e.bufferOpacity!=null?parseFloat(e.bufferOpacity):void 0,top:`calc(50% - ${Nn(_.value/4)})`,width:Nn(100-C.value,"%"),"--v-progress-linear-stream-to":Nn(_.value*(O.value?1:-1))}},null),gt("div",{class:an(["v-progress-linear__background",l.value]),style:Un([u.value,{opacity:e.bgOpacity!=null?parseFloat(e.bgOpacity):void 0,width:e.stream?0:void 0}])},null),gt("div",{class:an(["v-progress-linear__buffer",d.value]),style:Un([o.value,{opacity:e.bufferOpacity!=null?parseFloat(e.bufferOpacity):void 0,width:Nn($.value,"%")}])},null),Ge(El,{name:E.value},{default:()=>[e.indeterminate?gt("div",{class:"v-progress-linear__indeterminate"},[["long","short"].map(j=>gt("div",{key:j,class:an(["v-progress-linear__indeterminate",j,f.value]),style:Un(m.value)},null))]):gt("div",{class:an(["v-progress-linear__determinate",f.value]),style:Un([m.value,{width:Nn(A.value,"%")}])},null)]}),t.default&&gt("div",{class:"v-progress-linear__content"},[t.default({value:P.value,buffer:C.value})])]})),{}}}),Zx=Qt({loading:[Boolean,String]},"loader");function Xx(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Aa();return{loaderClasses:Lt(()=>({[`${n}--loading`]:e.loading}))}}function nD(e,n){let{slots:t}=n;return gt("div",{class:an(`${e.name}__loader`)},[t.default?.({color:e.color,isActive:e.active})||Ge(Qx,{absolute:e.absolute,active:e.active,color:e.color,height:"2",indeterminate:!0},null)])}const rD=["static","relative","fixed","absolute","sticky"],e1=Qt({position:{type:String,validator:(e=>rD.includes(e))}},"position");function t1(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Aa();return{positionClasses:Lt(()=>e.position?`${n}--${e.position}`:void 0)}}function iD(){const e=Oo("useRoute");return vt(()=>e?.proxy?.$route)}function n1(e,n){const t=ea("RouterLink"),r=Lt(()=>!!(e.href||e.to)),c=vt(()=>r?.value||Cx(n,"click")||Cx(e,"click"));if(typeof t=="string"||!("useLink"in t)){const l=Lt(()=>e.href);return{isLink:r,isRouterLink:Lt(()=>!1),isClickable:c,href:l,linkProps:Il({href:l}),route:Lt(()=>{}),navigate:Lt(()=>{})}}const h=t.useLink({to:Lt(()=>e.to||""),replace:Lt(()=>e.replace)}),g=vt(()=>e.to?h:void 0),v=iD(),s=vt(()=>g.value?e.exact?v.value?g.value.isExactActive?.value&&Ap(g.value.route.value.query,v.value.query):g.value.isExactActive?.value??!1:g.value.isActive?.value??!1:!1),p=vt(()=>e.to?g.value?.route.value.href:e.href),a=Lt(()=>!!e.to);return{isLink:r,isRouterLink:a,isClickable:c,isActive:s,route:Lt(()=>g.value?.route.value),navigate:Lt(()=>g.value?.navigate),href:p,linkProps:Il({href:p,"aria-current":Lt(()=>s.value?"page":void 0),"aria-disabled":Lt(()=>e.disabled&&r.value?"true":void 0),tabindex:Lt(()=>e.disabled&&r.value?"-1":void 0)})}}const r1=Qt({href:String,replace:Boolean,to:[String,Object],exact:Boolean},"router");function oD(e,n){wi(()=>e.isActive?.value,t=>{e.isLink.value&&t!=null&&n&&Tl(()=>{n(t)})},{immediate:!0})}const Fp=Symbol("rippleStop"),sD=80;function i1(e,n){e.style.transform=n,e.style.webkitTransform=n}function jp(e){return e.constructor.name==="TouchEvent"}function o1(e){return e.constructor.name==="KeyboardEvent"}const aD=function(e,n){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=0,c=0;if(!o1(e)){const l=new xp(n),u=jp(e)?e.touches[e.touches.length-1]:e,d=aN([u.clientX,u.clientY]);r=d.x-l.left,c=d.y-l.top}let h=0,g=.3;n._ripple?.circle?(g=.15,h=n.clientWidth/2,h=t.center?h:h+Math.sqrt((r-h)**2+(c-h)**2)/4):h=Math.sqrt(n.clientWidth**2+n.clientHeight**2)/2;const v=`${(n.clientWidth-h*2)/2}px`,s=`${(n.clientHeight-h*2)/2}px`,p=t.center?v:`${r-h}px`,a=t.center?s:`${c-h}px`;return{radius:h,scale:g,x:p,y:a,centerX:v,centerY:s}},ih={show(e,n){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!n?._ripple?.enabled)return;const r=document.createElement("span"),c=document.createElement("span");r.appendChild(c),r.className="v-ripple__container",t.class&&(r.className+=` ${t.class}`);const{radius:h,scale:g,x:v,y:s,centerX:p,centerY:a}=aD(e,n,t),l=`${h*2}px`;c.className="v-ripple__animation",c.style.width=l,c.style.height=l,n.appendChild(r);const u=window.getComputedStyle(n);u&&u.position==="static"&&(n.style.position="relative",n.dataset.previousPosition="static"),c.classList.add("v-ripple__animation--enter"),c.classList.add("v-ripple__animation--visible"),i1(c,`translate(${v}, ${s}) scale3d(${g},${g},${g})`),c.dataset.activated=String(performance.now()),requestAnimationFrame(()=>{requestAnimationFrame(()=>{c.classList.remove("v-ripple__animation--enter"),c.classList.add("v-ripple__animation--in"),i1(c,`translate(${p}, ${a}) scale3d(1,1,1)`)})})},hide(e){if(!e?._ripple?.enabled)return;const n=e.getElementsByClassName("v-ripple__animation");if(n.length===0)return;const t=Array.from(n).findLast(h=>!h.dataset.isHiding);if(t)t.dataset.isHiding="true";else return;const r=performance.now()-Number(t.dataset.activated),c=Math.max(250-r,0);setTimeout(()=>{t.classList.remove("v-ripple__animation--in"),t.classList.add("v-ripple__animation--out"),setTimeout(()=>{e.getElementsByClassName("v-ripple__animation").length===1&&e.dataset.previousPosition&&(e.style.position=e.dataset.previousPosition,delete e.dataset.previousPosition),t.parentNode?.parentNode===e&&e.removeChild(t.parentNode)},300)},c)}};function s1(e){return typeof e>"u"||!!e}function _c(e){const n={},t=e.currentTarget;if(!(!t?._ripple||t._ripple.touched||e[Fp])){if(e[Fp]=!0,jp(e))t._ripple.touched=!0,t._ripple.isTouch=!0;else if(t._ripple.isTouch)return;if(n.center=t._ripple.centered||o1(e),t._ripple.class&&(n.class=t._ripple.class),jp(e)){if(t._ripple.showTimerCommit)return;t._ripple.showTimerCommit=()=>{ih.show(e,t,n)},t._ripple.showTimer=window.setTimeout(()=>{t?._ripple?.showTimerCommit&&(t._ripple.showTimerCommit(),t._ripple.showTimerCommit=null)},sD)}else ih.show(e,t,n)}}function oh(e){e[Fp]=!0}function Ki(e){const n=e.currentTarget;if(n?._ripple){if(window.clearTimeout(n._ripple.showTimer),e.type==="touchend"&&n._ripple.showTimerCommit){n._ripple.showTimerCommit(),n._ripple.showTimerCommit=null,n._ripple.showTimer=window.setTimeout(()=>{Ki(e)});return}window.setTimeout(()=>{n._ripple&&(n._ripple.touched=!1)}),ih.hide(n)}}function a1(e){const n=e.currentTarget;n?._ripple&&(n._ripple.showTimerCommit&&(n._ripple.showTimerCommit=null),window.clearTimeout(n._ripple.showTimer))}let Ac=!1;function lD(e,n){!Ac&&n.includes(e.key)&&(Ac=!0,_c(e))}function l1(e){Ac=!1,Ki(e)}function c1(e){Ac&&(Ac=!1,Ki(e))}function u1(e,n,t){const{value:r,modifiers:c}=n,h=s1(r);h||ih.hide(e),e._ripple=e._ripple??{},e._ripple.enabled=h,e._ripple.centered=c.center,e._ripple.circle=c.circle;const g=yp(r)?r:{};g.class&&(e._ripple.class=g.class);const v=g.keys??["Enter","Space"];if(e._ripple.keyDownHandler=s=>lD(s,v),h&&!t){if(c.stop){e.addEventListener("touchstart",oh,{passive:!0}),e.addEventListener("mousedown",oh);return}e.addEventListener("touchstart",_c,{passive:!0}),e.addEventListener("touchend",Ki,{passive:!0}),e.addEventListener("touchmove",a1,{passive:!0}),e.addEventListener("touchcancel",Ki),e.addEventListener("mousedown",_c),e.addEventListener("mouseup",Ki),e.addEventListener("mouseleave",Ki),e.addEventListener("keydown",e._ripple.keyDownHandler),e.addEventListener("keyup",l1),e.addEventListener("blur",c1),e.addEventListener("dragstart",Ki,{passive:!0})}else!h&&t&&h1(e)}function h1(e){e.removeEventListener("touchstart",oh),e.removeEventListener("mousedown",oh),e.removeEventListener("touchstart",_c),e.removeEventListener("touchend",Ki),e.removeEventListener("touchmove",a1),e.removeEventListener("touchcancel",Ki),e.removeEventListener("mousedown",_c),e.removeEventListener("mouseup",Ki),e.removeEventListener("mouseleave",Ki),e._ripple?.keyDownHandler&&e.removeEventListener("keydown",e._ripple.keyDownHandler),e.removeEventListener("keyup",l1),e.removeEventListener("blur",c1),e.removeEventListener("dragstart",Ki)}function cD(e,n){u1(e,n,!1)}function uD(e){h1(e),delete e._ripple}function hD(e,n){if(n.value===n.oldValue)return;const t=s1(n.oldValue);u1(e,n,t)}const Wp={mounted:cD,unmounted:uD,updated:hD},dD=Qt({active:{type:Boolean,default:void 0},activeColor:String,baseColor:String,symbol:{type:null,default:Yx},flat:Boolean,icon:[Boolean,String,Function,Object],prependIcon:ps,appendIcon:ps,block:Boolean,readonly:Boolean,slim:Boolean,stacked:Boolean,spaced:String,ripple:{type:[Boolean,Object],default:!0},text:{type:[String,Number,Boolean],default:void 0},...Zu(),...$i(),...Cc(),...Ep(),...Lp(),...BN(),...Zx(),...Np(),...e1(),...ml(),...r1(),...kc(),...No({tag:"button"}),...$a(),...nh({variant:"elevated"})},"VBtn"),fD=Ar()({name:"VBtn",props:dD(),emits:{"group:selected":e=>!0},setup(e,n){let{attrs:t,slots:r}=n;const{themeClasses:c}=gl(e),{borderClasses:h}=Xu(e),{densityClasses:g}=eh(e),{dimensionStyles:v}=Ip(e),{elevationClasses:s}=Op(e),{loaderClasses:p}=Xx(e),{locationStyles:a}=Dp(e),{positionClasses:l}=t1(e),{roundedClasses:u}=vl(e),{sizeClasses:d,sizeStyles:o}=th(e),f=FN(e,e.symbol,!1),m=n1(e,t),w=vt(()=>e.active!==void 0?e.active:m.isRouterLink.value?m.isActive?.value:f?.isSelected.value),x=Lt(()=>w.value?e.activeColor??e.color:e.color),R=vt(()=>({color:f?.isSelected.value&&(!m.isLink.value||m.isActive?.value)||!f||m.isActive?.value?x.value??e.baseColor:e.baseColor,variant:e.variant})),{colorClasses:T,colorStyles:_,variantClasses:C}=zp(R),P=vt(()=>f?.disabled.value||e.disabled),O=Lt(()=>e.variant==="elevated"&&!(e.disabled||e.flat||e.border)),E=vt(()=>{if(!(e.value===void 0||typeof e.value=="symbol"))return Object(e.value)===e.value?JSON.stringify(e.value,null,0):e.value});function k(B){P.value||m.isLink.value&&(B.metaKey||B.ctrlKey||B.shiftKey||B.button!==0||t.target==="_blank")||(m.isRouterLink.value?m.navigate.value?.(B):f?.toggle())}return oD(m,f?.select),Si(()=>{const B=m.isLink.value?"a":e.tag,N=!!(e.prependIcon||r.prepend),M=!!(e.appendIcon||r.append),$=!!(e.icon&&e.icon!==!0);return ja(Ge(B,fr(m.linkProps,{type:B==="a"?void 0:"button",class:["v-btn",f?.selectedClass.value,{"v-btn--active":w.value,"v-btn--block":e.block,"v-btn--disabled":P.value,"v-btn--elevated":O.value,"v-btn--flat":e.flat,"v-btn--icon":!!e.icon,"v-btn--loading":e.loading,"v-btn--readonly":e.readonly,"v-btn--slim":e.slim,"v-btn--stacked":e.stacked},e.spaced?["v-btn--spaced",`v-btn--spaced-${e.spaced}`]:[],c.value,h.value,T.value,g.value,s.value,p.value,l.value,u.value,d.value,C.value,e.class],style:[_.value,v.value,a.value,o.value,e.style],"aria-busy":e.loading?!0:void 0,disabled:P.value&&B!=="a"||void 0,tabindex:e.loading||e.readonly?-1:void 0,onClick:k,value:E.value}),{default:()=>[Pp(!0,"v-btn"),!e.icon&&N&&gt("span",{key:"prepend",class:"v-btn__prepend"},[r.prepend?Ge(Sa,{key:"prepend-defaults",disabled:!e.prependIcon,defaults:{VIcon:{icon:e.prependIcon}}},r.prepend):Ge(Ta,{key:"prepend-icon",icon:e.prependIcon},null)]),gt("span",{class:"v-btn__content","data-no-activator":""},[!r.default&&$?Ge(Ta,{key:"content-icon",icon:e.icon},null):Ge(Sa,{key:"content-defaults",disabled:!$,defaults:{VIcon:{icon:e.icon}}},{default:()=>[r.default?.()??xr(e.text)]})]),!e.icon&&M&&gt("span",{key:"append",class:"v-btn__append"},[r.append?Ge(Sa,{key:"append-defaults",disabled:!e.appendIcon,defaults:{VIcon:{icon:e.appendIcon}}},r.append):Ge(Ta,{key:"append-icon",icon:e.appendIcon},null)]),!!e.loading&&gt("span",{key:"loader",class:"v-btn__loader"},[r.loader?.()??Ge(Bp,{color:typeof e.loading=="boolean"?void 0:e.loading,indeterminate:!0,width:"2"},null)])]}),[[Wp,!P.value&&e.ripple,"",{center:!!e.icon}]])}),{group:f}}}),pD=Qt({start:Boolean,end:Boolean,icon:ps,image:String,text:String,...Zu(),...$i(),...Cc(),...ml(),...kc(),...No(),...$a(),...nh({variant:"flat"})},"VAvatar"),sh=Ar()({name:"VAvatar",props:pD(),setup(e,n){let{slots:t}=n;const{themeClasses:r}=gl(e),{borderClasses:c}=Xu(e),{colorClasses:h,colorStyles:g,variantClasses:v}=zp(e),{densityClasses:s}=eh(e),{roundedClasses:p}=vl(e),{sizeClasses:a,sizeStyles:l}=th(e);return Si(()=>Ge(e.tag,{class:an(["v-avatar",{"v-avatar--start":e.start,"v-avatar--end":e.end},r.value,c.value,h.value,s.value,p.value,a.value,v.value,e.class]),style:Un([g.value,l.value,e.style])},{default:()=>[t.default?Ge(Sa,{key:"content-defaults",defaults:{VImg:{cover:!0,src:e.image},VIcon:{icon:e.icon}}},{default:()=>[t.default()]}):e.image?Ge(Qu,{key:"image",src:e.image,alt:"",cover:!0},null):e.icon?Ge(Ta,{key:"icon",icon:e.icon},null):e.text,Pp(!1,"v-avatar")]})),{}}}),gD=Qt({...$i(),...No()},"VCardActions"),d1=Ar()({name:"VCardActions",props:gD(),setup(e,n){let{slots:t}=n;return _p({VBtn:{slim:!0,variant:"text"}}),Si(()=>Ge(e.tag,{class:an(["v-card-actions",e.class]),style:Un(e.style)},t)),{}}}),mD=Qt({opacity:[Number,String],...$i(),...No()},"VCardSubtitle"),vD=Ar()({name:"VCardSubtitle",props:mD(),setup(e,n){let{slots:t}=n;return Si(()=>Ge(e.tag,{class:an(["v-card-subtitle",e.class]),style:Un([{"--v-card-subtitle-opacity":e.opacity},e.style])},t)),{}}}),yD=Nx("v-card-title"),bD=Qt({appendAvatar:String,appendIcon:ps,prependAvatar:String,prependIcon:ps,subtitle:{type:[String,Number,Boolean],default:void 0},title:{type:[String,Number,Boolean],default:void 0},...$i(),...Cc(),...No()},"VCardItem"),wD=Ar()({name:"VCardItem",props:bD(),setup(e,n){let{slots:t}=n;return Si(()=>{const r=!!(e.prependAvatar||e.prependIcon),c=!!(r||t.prepend),h=!!(e.appendAvatar||e.appendIcon),g=!!(h||t.append),v=!!(e.title!=null||t.title),s=!!(e.subtitle!=null||t.subtitle);return Ge(e.tag,{class:an(["v-card-item",e.class]),style:Un(e.style)},{default:()=>[c&&gt("div",{key:"prepend",class:"v-card-item__prepend"},[t.prepend?Ge(Sa,{key:"prepend-defaults",disabled:!r,defaults:{VAvatar:{density:e.density,image:e.prependAvatar},VIcon:{density:e.density,icon:e.prependIcon}}},t.prepend):gt(Ir,null,[e.prependAvatar&&Ge(sh,{key:"prepend-avatar",density:e.density,image:e.prependAvatar},null),e.prependIcon&&Ge(Ta,{key:"prepend-icon",density:e.density,icon:e.prependIcon},null)])]),gt("div",{class:"v-card-item__content"},[v&&Ge(yD,{key:"title"},{default:()=>[t.title?.()??xr(e.title)]}),s&&Ge(vD,{key:"subtitle"},{default:()=>[t.subtitle?.()??xr(e.subtitle)]}),t.default?.()]),g&&gt("div",{key:"append",class:"v-card-item__append"},[t.append?Ge(Sa,{key:"append-defaults",disabled:!h,defaults:{VAvatar:{density:e.density,image:e.appendAvatar},VIcon:{density:e.density,icon:e.appendIcon}}},t.append):gt(Ir,null,[e.appendIcon&&Ge(Ta,{key:"append-icon",density:e.density,icon:e.appendIcon},null),e.appendAvatar&&Ge(sh,{key:"append-avatar",density:e.density,image:e.appendAvatar},null)])])]})}),{}}}),xD=Qt({opacity:[Number,String],...$i(),...No()},"VCardText"),f1=Ar()({name:"VCardText",props:xD(),setup(e,n){let{slots:t}=n;return Si(()=>Ge(e.tag,{class:an(["v-card-text",e.class]),style:Un([{"--v-card-text-opacity":e.opacity},e.style])},t)),{}}}),CD=Qt({appendAvatar:String,appendIcon:ps,disabled:Boolean,flat:Boolean,hover:Boolean,image:String,link:{type:Boolean,default:void 0},prependAvatar:String,prependIcon:ps,ripple:{type:[Boolean,Object],default:!0},subtitle:{type:[String,Number,Boolean],default:void 0},text:{type:[String,Number,Boolean],default:void 0},title:{type:[String,Number,Boolean],default:void 0},...Zu(),...$i(),...Cc(),...Ep(),...Lp(),...Zx(),...Np(),...e1(),...ml(),...r1(),...No(),...$a(),...nh({variant:"elevated"})},"VCard"),kD=Ar()({name:"VCard",directives:{vRipple:Wp},props:CD(),setup(e,n){let{attrs:t,slots:r}=n;const{themeClasses:c}=gl(e),{borderClasses:h}=Xu(e),{colorClasses:g,colorStyles:v,variantClasses:s}=zp(e),{densityClasses:p}=eh(e),{dimensionStyles:a}=Ip(e),{elevationClasses:l}=Op(e),{loaderClasses:u}=Xx(e),{locationStyles:d}=Dp(e),{positionClasses:o}=t1(e),{roundedClasses:f}=vl(e),m=n1(e,t),w=Hi(void 0);return wi(()=>e.loading,(x,R)=>{w.value=!x&&typeof R=="string"?R:typeof x=="boolean"?void 0:x},{immediate:!0}),Si(()=>{const x=e.link!==!1&&m.isLink.value,R=!e.disabled&&e.link!==!1&&(e.link||m.isClickable.value),T=x?"a":e.tag,_=!!(r.title||e.title!=null),C=!!(r.subtitle||e.subtitle!=null),P=_||C,O=!!(r.append||e.appendAvatar||e.appendIcon),E=!!(r.prepend||e.prependAvatar||e.prependIcon),k=!!(r.image||e.image),B=P||E||O,N=!!(r.text||e.text!=null);return ja(Ge(T,fr(m.linkProps,{class:["v-card",{"v-card--disabled":e.disabled,"v-card--flat":e.flat,"v-card--hover":e.hover&&!(e.disabled||e.flat),"v-card--link":R},c.value,h.value,g.value,p.value,l.value,u.value,o.value,f.value,s.value,e.class],style:[v.value,a.value,d.value,{"--v-card-height":Nn(e.height)},e.style],onClick:R&&m.navigate.value,tabindex:e.disabled?-1:void 0}),{default:()=>[k&&gt("div",{key:"image",class:"v-card__image"},[r.image?Ge(Sa,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{cover:!0,src:e.image}}},r.image):Ge(Qu,{key:"image-img",cover:!0,src:e.image},null)]),Ge(nD,{name:"v-card",active:!!e.loading,color:w.value},{default:r.loader}),B&&Ge(wD,{key:"item",prependAvatar:e.prependAvatar,prependIcon:e.prependIcon,title:e.title,subtitle:e.subtitle,appendAvatar:e.appendAvatar,appendIcon:e.appendIcon},{default:r.item,prepend:r.prepend,title:r.title,subtitle:r.subtitle,append:r.append}),N&&Ge(f1,{key:"text"},{default:()=>[r.text?.()??e.text]}),r.default?.(),r.actions&&Ge(d1,null,{default:r.actions}),Pp(R,"v-card")]}),[[Wp,R&&e.ripple]])}),{}}}),_D=Nx("v-spacer","div","VSpacer"),AD=Ls({__name:"VSonner",props:{id:{},invert:{type:Boolean},position:{default:"bottom-center"},closeButtonPosition:{},hotkey:{default:()=>["altKey","KeyT"]},expand:{type:Boolean,default:!1},duration:{},gap:{},visibleToasts:{default:3},toastOptions:{},class:{},offset:{default:32},mobileOffset:{},dir:{},swipeDirections:{},icons:{},containerAriaLabel:{}},setup(e){return(n,t)=>(wt(),Xt(Ir,null,[Ge(Ht(J2),{position:e.position,hotkey:e.hotkey,expand:e.expand,"visible-toasts":e.visibleToasts,duration:e.duration,"toast-options":e.toastOptions,offset:e.offset},null,8,["position","hotkey","expand","visible-toasts","duration","toast-options","offset"]),xi(n.$slots,"default")],64))}}),$D=Ls({__name:"ProgressBar",props:{duration:{default:5e3},progressBarProps:{},isPaused:{type:Boolean,default:!1},reverseProgressBar:{type:Boolean,default:!1}},setup(e){const n=e,t=n.reverseProgressBar?nn(0):nn(5e3);let r;wi(()=>n.isPaused,h=>{!h&&!n.progressBarProps?.indeterminate&&c()});function c(){r=setTimeout(()=>{n.isPaused||(n.reverseProgressBar?t.value+=120:t.value-=120,t.value<=0&&!n.reverseProgressBar?(t.value=0,clearInterval(r)):t.value>=n.duration&&n.reverseProgressBar?(t.value=n.duration,clearInterval(r)):c())},100)}return Fa(()=>{n.progressBarProps?.indeterminate||(t.value=n.reverseProgressBar?0:n.duration,c())}),Zs(()=>{clearInterval(r)}),(h,g)=>(wt(),er(Ht(Qx),fr(n.progressBarProps,{"model-value":Math.floor(100*(Ht(t)/n.duration))}),null,16,["model-value"]))}}),SD={class:"d-flex align-center justify-center fill-height"},TD={key:1,class:"d-flex align-center mr-8"},ED={class:"d-flex align-center justify-center fill-height"},ID={key:3},MD={class:"pb-1"},RD=["innerHTML"],LD=Ls({inheritAttrs:!1,__name:"Toast",props:{text:{},description:{},vertical:{type:Boolean,default:!1},cardProps:{},cardTextProps:{},cardActionsProps:{default:()=>({})},action:{},prependIcon:{},prependIconProps:{},avatar:{},multipleAvatars:{},avatarProps:{},progressBar:{type:Boolean,default:!1},reverseProgressBar:{type:Boolean},progressDuration:{default:5e3},progressBarProps:{},loading:{type:Boolean}},emits:["closeToast"],setup(e){const n=nn(!1);return(t,r)=>(wt(),er(Ht(kD),fr({class:"card-snackbar"},e.cardProps,{onMouseenter:r[1]||(r[1]=c=>n.value=!0),onMouseleave:r[2]||(r[2]=c=>n.value=!1)}),{default:sn(()=>[gt("div",{class:an({"d-flex flex-no-wrap justify-space-between":!e.vertical})},[Ge(Ht(f1),fr(e.cardTextProps,{class:{"d-flex align-center":e.prependIcon||e.avatar||e.multipleAvatars}}),{default:sn(()=>[e.avatar?(wt(),er(Ht(sh),fr({key:0,class:"mr-2"},e.avatarProps),{default:sn(()=>[Ge(Ht(Qu),{src:e.avatar,cover:""},{placeholder:sn(()=>[gt("div",SD,[Ge(Ht(Bp),{color:"grey-lighten-2",indeterminate:""})])]),_:1},8,["src"])]),_:1},16)):e.multipleAvatars?(wt(),Xt("div",TD,[(wt(!0),Xt(Ir,null,Ml(e.multipleAvatars.length<=5?e.multipleAvatars:e.multipleAvatars.slice(0,5),(c,h)=>(wt(),er(Ht(sh),fr({ref_for:!0},e.avatarProps,{key:h,class:"mr-n6",style:{zIndex:5-h}}),{default:sn(()=>[Ge(Ht(Qu),{src:c,cover:""},{placeholder:sn(()=>[gt("div",ED,[Ge(Ht(Bp),{color:"grey-lighten-2",indeterminate:""})])]),_:1},8,["src"])]),_:2},1040,["style"]))),128))])):qr("",!0),e.prependIcon?(wt(),er(Ht(Ta),fr({key:2,class:"mr-2",icon:e.prependIcon},e.prependIconProps),null,16,["icon"])):qr("",!0),e.description?(wt(),Xt("div",ID,[gt("div",MD,xr(e.text),1),gt("p",{class:"font-weight-light",innerHTML:e.description},null,8,RD)])):(wt(),Xt(Ir,{key:4},[Wi(xr(e.text),1)],64))]),_:1},16,["class"]),e.action?(wt(),er(Ht(d1),Wc(fr({key:0},e.cardActionsProps)),{default:sn(()=>[Ge(Ht(_D)),Ge(Ht(fD),fr(e.action.buttonProps,{text:e.action.label,onClick:r[0]||(r[0]=()=>{t.$emit("closeToast"),e.action?.onClick?.()})}),null,16,["text"])]),_:1},16)):qr("",!0)],2),Ge(Ht(TN),null,{default:sn(()=>[ja(Ge($D,{duration:e.progressDuration,"progress-bar-props":e.progressBarProps,"is-paused":n.value,"reverse-progress-bar":e.reverseProgressBar},null,8,["duration","progress-bar-props","is-paused","reverse-progress-bar"]),[[Uh,e.progressBar]])]),_:1})]),_:1},16))}}),OD=(e,n)=>{const t=e.__vccOpts||e;for(const[r,c]of n)t[r]=c;return t},ND=OD(LD,[["__scopeId","data-v-c014bbd8"]]);function p1(e,n){const{description:t,action:r,...c}=n||{};return mp.custom(Jg(Eo(ND,{...c,progressBar:n?.progressBar??!1,progressDuration:n?.duration??5e3,progressBarProps:{...n?.progressBarProps,indeterminate:n?.loading},description:t,action:r,text:e})),{...c,unstyled:!0})}function yl(e,n){return function(t,r){return p1(t,{prependIcon:n,cardProps:{color:e,...r?.cardProps},...r})}}const Hp=Object.assign(p1,{success:yl("success","mdi-check-circle"),error:yl("error","mdi-cancel"),warning:yl("warning","mdi-alert"),info:yl("info","mdi-alert-circle"),primary:yl("primary","mdi-bell"),secondary:yl("secondary","mdi-bell"),dismiss(e){return mp.dismiss(e)},toastOriginal:mp}),DD={components:{VSonner:AD},data:function(){return{active:new Map,nextId:0,noToastPaths:["/login"],position:localStorage.toastPosition==="bottom"?"bottom":"top"}},created:function(){window.addEventListener("openc3-toast-position",this.onPositionChange)},unmounted:function(){window.removeEventListener("openc3-toast-position",this.onPositionChange)},methods:{onPositionChange:function(e){const n=e.detail?.position;(n==="top"||n==="bottom")&&(this.position=n)},toast:function(e,n){if(this.noToastPaths.includes(window.location.pathname))return;n===void 0&&(n=5e3);const t=!n,r=`openc3-toast-${this.nextId++}`;this.active.set(r,e);const c=nO(e.level),h=fc[dc[e.level]];Hp(this.toastText(e),{id:r,description:this.toastDescription(e),duration:t?1/0:n,prependIcon:this.toastNotificationIcon(e),prependIconProps:{style:`color:${c}`},cardProps:{style:`background-color:${h}!important;color:${c}!important;`,"data-test":"toast"},action:{label:t?"Acknowledge":"Dismiss",buttonProps:{variant:"text",style:`color:${c}`,"data-test":"dismiss-toast","aria-label":t?"Acknowledge":"Dismiss"},onClick:()=>{t&&e.msg_id&&window.dispatchEvent(new CustomEvent("openc3-ack-alert",{detail:{msg_id:e.msg_id}}))}},onDismiss:()=>this.active.delete(r),onAutoClose:()=>this.active.delete(r)})},dismissAll:function(){Hp.dismiss(),this.active.clear()},dismissMatching:function(e){for(const[n,t]of this.active)e(t)&&(Hp.dismiss(n),this.active.delete(n))},toastText:function(e){return e.title||e.message||e.body||""},toastDescription:function(e){const n=this.toastText(e),t=[];e.body&&e.body!==n&&t.push(e.body),e.message&&e.message!==n&&t.push(e.message);const r=this.toastTime(e);if(r&&t.push(r),!!t.length)return dx.sanitize(t.join("<br>"))},toastTime:function(e){return e["@timestamp"]?e["@timestamp"]:e.time?new Date(e.time/1e6).toISOString():""},toastNotificationIcon:function(e){switch(String(e.level).toUpperCase()){case"FATAL":return"mdi-alert-octagon";case"ERROR":return"mdi-alert-circle";case"WARN":return"mdi-alert";default:return"mdi-information"}}}};function PD(e,n,t,r,c,h){const g=In("VSonner");return wt(),er(g,{position:e.position==="bottom"?"bottom-center":"top-center","visible-toasts":3},null,8,["position"])}const zD=ra(DD,[["render",PD]]);class BD{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=q0()),this.store}mount(){if(this.mounted)return;const n=Hh(zD);n.use(Up);const t=document.createElement("div");document.body.appendChild(t),this.$root=n.mount(t),this.mounted=!0}open({method:n,title:t,body:r,message:c,level:h,duration:g,type:v="alert",logToConsole:s=!1,saveToHistory:p=!0,...a}){this.mount(),s&&console.log(c?`${h.toUpperCase()} - ${c}`:`${h.toUpperCase()} - ${t}: ${r}`),p&&this.getStore().notifyAddHistory({title:t,body:r,message:c,level:h}),this[n]({title:t,body:r,message:c,level:h,duration:g,type:v,...a})}toast({title:n,body:t,message:r,level:c,duration:h,type:g,...v}){this.$root.toast({title:n,body:t,message:r,level:c,type:g,...v},h)}critical(n){this.open({...n,method:"toast",level:"critical"})}FATAL(n){this.critical(n)}ERROR(n){this.critical(n)}serious(n){this.open({...n,method:"toast",level:"serious"})}caution(n){this.open({...n,method:"toast",level:"caution"})}WARN(n){this.caution(n)}normal(n){this.open({...n,method:"toast",level:"normal"})}INFO(n){this.normal(n)}DEBUG(n){this.normal(n)}standby(n){this.open({...n,method:"toast",level:"standby"})}off(n){this.open({...n,method:"toast",level:"off"})}dismissAll(){this.$root?.dismissAll()}dismiss(n){this.$root?.dismissMatching(n)}}const FD={install(e,n){const t=new BD(n);e.provide("notify",t),e.config.globalProperties.hasOwnProperty("$notify")||(e.config.globalProperties.$notify=t)}},jD={component:e=>Eo(qN,{...e,class:"mdi"})},WD={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"}},HD={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"}},UD={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"}},VD={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"}},Up=sm({theme:{defaultTheme:"cosmosDark",themes:{cosmosDark:KO,cosmosDarkCobalt:WD,cosmosDarkIndigo:HD,cosmosDarkSlate:UD,cosmosDarkEmerald:VD}},defaults:{VCheckbox:{color:"secondary"},VCheckboxBtn:{color:"secondary"},VRadio:{color:"secondary"},VRadioGroup:{color:"secondary"},VSwitch:{color:"secondary"}},icons:{defaultSet:"mdi",sets:{mdi:jD,...iO,...oO}}}),Vp=hk({createApp:Hh,appOptions:{render(){return Eo(bk,{})},el:"#openc3-tool"},handleInstance:e=>{e.use(vO),e.use(sl),e.use(Up),e.use(r2),e.use(FD)}}),W3=lr("f",Vp.bootstrap),H3=lr("i",Vp.mount),U3=lr("u",Vp.unmount)})}}));