dgz-ui 1.4.11 → 1.4.13

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 (172) hide show
  1. package/dist/accordion/index.cjs.js +1 -1
  2. package/dist/accordion/index.es.js +1 -1
  3. package/dist/alert/index.cjs.js +1 -1
  4. package/dist/alert/index.es.js +1 -1
  5. package/dist/alert-dialog/index.cjs.js +1 -1
  6. package/dist/alert-dialog/index.es.js +1 -1
  7. package/dist/avatar/index.cjs.js +1 -1
  8. package/dist/avatar/index.es.js +1 -1
  9. package/dist/badge/index.cjs.js +1 -1
  10. package/dist/badge/index.es.js +1 -1
  11. package/dist/breadcrumb/index.cjs.js +1 -1
  12. package/dist/breadcrumb/index.es.js +1 -1
  13. package/dist/button/index.cjs.js +1 -1
  14. package/dist/button/index.es.js +2 -2
  15. package/dist/calendar/index.cjs.js +1 -1
  16. package/dist/calendar/index.es.js +1 -1
  17. package/dist/card/index.cjs.js +1 -1
  18. package/dist/card/index.es.js +1 -1
  19. package/dist/carousel/index.cjs.js +1 -1
  20. package/dist/carousel/index.es.js +2 -2
  21. package/dist/chunks/_commonjsHelpers-DKOUU3wS.cjs.js +2 -0
  22. package/dist/chunks/_commonjsHelpers-DKOUU3wS.cjs.js.map +1 -0
  23. package/dist/chunks/_commonjsHelpers-DaMA6jEr.es.js +9 -0
  24. package/dist/chunks/_commonjsHelpers-DaMA6jEr.es.js.map +1 -0
  25. package/dist/chunks/{alert-BX7k7R2a.es.js → alert-B9rImkiX.es.js} +3 -3
  26. package/dist/chunks/{alert-BX7k7R2a.es.js.map → alert-B9rImkiX.es.js.map} +1 -1
  27. package/dist/chunks/alert-BNcf_eJn.cjs.js +2 -0
  28. package/dist/chunks/{alert-BxS8Cjkv.cjs.js.map → alert-BNcf_eJn.cjs.js.map} +1 -1
  29. package/dist/chunks/{alert-dialog-CYT3LDhH.cjs.js → alert-dialog-BfBtlIHj.cjs.js} +2 -2
  30. package/dist/chunks/{alert-dialog-CYT3LDhH.cjs.js.map → alert-dialog-BfBtlIHj.cjs.js.map} +1 -1
  31. package/dist/chunks/{alert-dialog-CI_hZyxN.es.js → alert-dialog-BrCPhmhd.es.js} +3 -3
  32. package/dist/chunks/{alert-dialog-CI_hZyxN.es.js.map → alert-dialog-BrCPhmhd.es.js.map} +1 -1
  33. package/dist/chunks/{avatar-Djf5Tj2g.cjs.js → avatar-CQMWDnOM.cjs.js} +2 -2
  34. package/dist/chunks/{avatar-Djf5Tj2g.cjs.js.map → avatar-CQMWDnOM.cjs.js.map} +1 -1
  35. package/dist/chunks/{avatar-CYP7jfXP.es.js → avatar-zl4cf4c2.es.js} +3 -3
  36. package/dist/chunks/{avatar-CYP7jfXP.es.js.map → avatar-zl4cf4c2.es.js.map} +1 -1
  37. package/dist/chunks/{badge-B8BYFX2h.cjs.js → badge-1ocx6hox.cjs.js} +2 -2
  38. package/dist/chunks/{badge-B8BYFX2h.cjs.js.map → badge-1ocx6hox.cjs.js.map} +1 -1
  39. package/dist/chunks/{badge-HxjENCrW.es.js → badge-CPzxgRrM.es.js} +3 -3
  40. package/dist/chunks/{badge-HxjENCrW.es.js.map → badge-CPzxgRrM.es.js.map} +1 -1
  41. package/dist/chunks/{breadcrumb-BtO0mD2u.es.js → breadcrumb-BrMrkZfa.es.js} +2 -2
  42. package/dist/chunks/{breadcrumb-BtO0mD2u.es.js.map → breadcrumb-BrMrkZfa.es.js.map} +1 -1
  43. package/dist/chunks/{breadcrumb-DKVYizoh.cjs.js → breadcrumb-iPT-f06l.cjs.js} +2 -2
  44. package/dist/chunks/{breadcrumb-DKVYizoh.cjs.js.map → breadcrumb-iPT-f06l.cjs.js.map} +1 -1
  45. package/dist/chunks/{button-DLexbK7C.cjs.js → button-CpKtD3qG.cjs.js} +2 -2
  46. package/dist/chunks/{button-DLexbK7C.cjs.js.map → button-CpKtD3qG.cjs.js.map} +1 -1
  47. package/dist/chunks/{button-Bmtxy091.es.js → button-DTRIYqDb.es.js} +3 -3
  48. package/dist/chunks/{button-Bmtxy091.es.js.map → button-DTRIYqDb.es.js.map} +1 -1
  49. package/dist/chunks/{button-group-X3ovdyZa.es.js → button-group-B4h4-5eB.es.js} +4 -4
  50. package/dist/chunks/{button-group-X3ovdyZa.es.js.map → button-group-B4h4-5eB.es.js.map} +1 -1
  51. package/dist/chunks/{button-group-CJy5raYG.cjs.js → button-group-CaFYso6b.cjs.js} +2 -2
  52. package/dist/chunks/{button-group-CJy5raYG.cjs.js.map → button-group-CaFYso6b.cjs.js.map} +1 -1
  53. package/dist/chunks/{card-Dokrjefn.cjs.js → card-B1sx5mON.cjs.js} +2 -2
  54. package/dist/chunks/{card-Dokrjefn.cjs.js.map → card-B1sx5mON.cjs.js.map} +1 -1
  55. package/dist/chunks/{card-B87RYuvO.es.js → card-BJ0eqFqO.es.js} +2 -2
  56. package/dist/chunks/{card-B87RYuvO.es.js.map → card-BJ0eqFqO.es.js.map} +1 -1
  57. package/dist/chunks/{dialog-pRz31cHo.cjs.js → dialog-BWF5BkHj.cjs.js} +2 -2
  58. package/dist/chunks/{dialog-pRz31cHo.cjs.js.map → dialog-BWF5BkHj.cjs.js.map} +1 -1
  59. package/dist/chunks/{dialog-Cb_DS5IV.es.js → dialog-D9BMBoAJ.es.js} +2 -2
  60. package/dist/chunks/{dialog-Cb_DS5IV.es.js.map → dialog-D9BMBoAJ.es.js.map} +1 -1
  61. package/dist/chunks/{dropdown-menu-CJTcrFP2.es.js → dropdown-menu-BUaCITEG.es.js} +2 -2
  62. package/dist/chunks/{dropdown-menu-CJTcrFP2.es.js.map → dropdown-menu-BUaCITEG.es.js.map} +1 -1
  63. package/dist/chunks/{dropdown-menu-BNURsvIJ.cjs.js → dropdown-menu-D52NH0Di.cjs.js} +2 -2
  64. package/dist/chunks/{dropdown-menu-BNURsvIJ.cjs.js.map → dropdown-menu-D52NH0Di.cjs.js.map} +1 -1
  65. package/dist/chunks/{index-CjQdyVZP.es.js → index-xA4mlFw5.es.js} +2 -2
  66. package/dist/chunks/{index-CjQdyVZP.es.js.map → index-xA4mlFw5.es.js.map} +1 -1
  67. package/dist/chunks/{index-DYLHhjdc.cjs.js → index-x_Mxo00P.cjs.js} +2 -2
  68. package/dist/chunks/{index-DYLHhjdc.cjs.js.map → index-x_Mxo00P.cjs.js.map} +1 -1
  69. package/dist/chunks/{pagination-aJ9Z0Ux9.es.js → pagination-DFYeehFF.es.js} +3 -3
  70. package/dist/chunks/{pagination-aJ9Z0Ux9.es.js.map → pagination-DFYeehFF.es.js.map} +1 -1
  71. package/dist/chunks/{pagination-CJiUbpUN.cjs.js → pagination-LHTb7tXo.cjs.js} +2 -2
  72. package/dist/chunks/{pagination-CJiUbpUN.cjs.js.map → pagination-LHTb7tXo.cjs.js.map} +1 -1
  73. package/dist/chunks/{popover-cRDGBSyg.cjs.js → popover-Bh6emR_J.cjs.js} +2 -2
  74. package/dist/chunks/{popover-cRDGBSyg.cjs.js.map → popover-Bh6emR_J.cjs.js.map} +1 -1
  75. package/dist/chunks/{popover-ChtTV2vy.es.js → popover-BredK0sg.es.js} +2 -2
  76. package/dist/chunks/{popover-ChtTV2vy.es.js.map → popover-BredK0sg.es.js.map} +1 -1
  77. package/dist/chunks/{react-select-B7OjIwAI.es.js → react-select-BDoLUa8t.es.js} +136 -142
  78. package/dist/chunks/{react-select-B7OjIwAI.es.js.map → react-select-BDoLUa8t.es.js.map} +1 -1
  79. package/dist/chunks/{react-select-DocP3pOa.cjs.js → react-select-DvBVNVXL.cjs.js} +7 -7
  80. package/dist/chunks/{react-select-DocP3pOa.cjs.js.map → react-select-DvBVNVXL.cjs.js.map} +1 -1
  81. package/dist/chunks/{scroll-area-x2hiTYmL.es.js → scroll-area-CwWjTiks.es.js} +2 -2
  82. package/dist/chunks/{scroll-area-x2hiTYmL.es.js.map → scroll-area-CwWjTiks.es.js.map} +1 -1
  83. package/dist/chunks/{scroll-area-sLp4wPce.cjs.js → scroll-area-Nj6J9MqV.cjs.js} +2 -2
  84. package/dist/chunks/{scroll-area-sLp4wPce.cjs.js.map → scroll-area-Nj6J9MqV.cjs.js.map} +1 -1
  85. package/dist/chunks/separator-CGvV-BlI.cjs.js +2 -0
  86. package/dist/chunks/{separator-uzP1VAwc.cjs.js.map → separator-CGvV-BlI.cjs.js.map} +1 -1
  87. package/dist/chunks/{separator-DndNTVv8.es.js → separator-CgP4OHOF.es.js} +2 -2
  88. package/dist/chunks/{separator-DndNTVv8.es.js.map → separator-CgP4OHOF.es.js.map} +1 -1
  89. package/dist/chunks/{sheet-BXSDa9XT.cjs.js → sheet-BL1AP0aU.cjs.js} +2 -2
  90. package/dist/chunks/{sheet-BXSDa9XT.cjs.js.map → sheet-BL1AP0aU.cjs.js.map} +1 -1
  91. package/dist/chunks/{sheet-hwgCcvpv.es.js → sheet-CKsRhiVy.es.js} +2 -2
  92. package/dist/chunks/{sheet-hwgCcvpv.es.js.map → sheet-CKsRhiVy.es.js.map} +1 -1
  93. package/dist/chunks/skeleton-C7pnV7bc.cjs.js +2 -0
  94. package/dist/chunks/{skeleton-ZHnXbbz7.cjs.js.map → skeleton-C7pnV7bc.cjs.js.map} +1 -1
  95. package/dist/chunks/{skeleton-DV_2OytH.es.js → skeleton-DKbF2Fso.es.js} +2 -2
  96. package/dist/chunks/{skeleton-DV_2OytH.es.js.map → skeleton-DKbF2Fso.es.js.map} +1 -1
  97. package/dist/chunks/{table-QbNlEa1M.es.js → table-BTb0KUhR.es.js} +2 -2
  98. package/dist/chunks/{table-QbNlEa1M.es.js.map → table-BTb0KUhR.es.js.map} +1 -1
  99. package/dist/chunks/{table-C-g7CjMt.cjs.js → table-Dxainp0Z.cjs.js} +2 -2
  100. package/dist/chunks/{table-C-g7CjMt.cjs.js.map → table-Dxainp0Z.cjs.js.map} +1 -1
  101. package/dist/chunks/{tabs-DUuliV4A.es.js → tabs-BnamvF0S.es.js} +4 -4
  102. package/dist/chunks/{tabs-DUuliV4A.es.js.map → tabs-BnamvF0S.es.js.map} +1 -1
  103. package/dist/chunks/{tabs-BNEY7wMF.cjs.js → tabs-CDt2LiNL.cjs.js} +2 -2
  104. package/dist/chunks/{tabs-BNEY7wMF.cjs.js.map → tabs-CDt2LiNL.cjs.js.map} +1 -1
  105. package/dist/chunks/{textarea-D9gE4ALW.es.js → textarea-BnUWlaPx.es.js} +5827 -5785
  106. package/dist/chunks/textarea-BnUWlaPx.es.js.map +1 -0
  107. package/dist/chunks/textarea-EPWY09og.cjs.js +173 -0
  108. package/dist/chunks/textarea-EPWY09og.cjs.js.map +1 -0
  109. package/dist/chunks/timepicker-Ca0gLbqn.es.js +3385 -0
  110. package/dist/chunks/timepicker-Ca0gLbqn.es.js.map +1 -0
  111. package/dist/chunks/timepicker-CuuVE0le.cjs.js +7 -0
  112. package/dist/chunks/timepicker-CuuVE0le.cjs.js.map +1 -0
  113. package/dist/chunks/{tooltip-DD-snel0.cjs.js → tooltip-CsZB0nVr.cjs.js} +2 -2
  114. package/dist/chunks/{tooltip-DD-snel0.cjs.js.map → tooltip-CsZB0nVr.cjs.js.map} +1 -1
  115. package/dist/chunks/{tooltip-DHg9332v.es.js → tooltip-Dtzkuphk.es.js} +2 -2
  116. package/dist/chunks/{tooltip-DHg9332v.es.js.map → tooltip-Dtzkuphk.es.js.map} +1 -1
  117. package/dist/chunks/utils-C4d7Ql9-.cjs.js +2 -0
  118. package/dist/chunks/utils-C4d7Ql9-.cjs.js.map +1 -0
  119. package/dist/chunks/{index-D6dQK9i-.es.js → utils-CnvKSirc.es.js} +157 -157
  120. package/dist/chunks/utils-CnvKSirc.es.js.map +1 -0
  121. package/dist/dialog/index.cjs.js +1 -1
  122. package/dist/dialog/index.es.js +1 -1
  123. package/dist/dropdown/index.cjs.js +1 -1
  124. package/dist/dropdown/index.es.js +1 -1
  125. package/dist/form/index.cjs.js +1 -1
  126. package/dist/form/index.es.js +2 -2
  127. package/dist/index.cjs.js +1 -1
  128. package/dist/index.es.js +23 -23
  129. package/dist/pagination/index.cjs.js +1 -1
  130. package/dist/pagination/index.es.js +1 -1
  131. package/dist/popover/index.cjs.js +1 -1
  132. package/dist/popover/index.es.js +1 -1
  133. package/dist/progress/index.cjs.js +1 -1
  134. package/dist/progress/index.es.js +1 -1
  135. package/dist/scroll-area/index.cjs.js +1 -1
  136. package/dist/scroll-area/index.es.js +1 -1
  137. package/dist/separator/index.cjs.js +1 -1
  138. package/dist/separator/index.es.js +1 -1
  139. package/dist/sheet/index.cjs.js +1 -1
  140. package/dist/sheet/index.es.js +1 -1
  141. package/dist/skeleton/index.cjs.js +1 -1
  142. package/dist/skeleton/index.es.js +1 -1
  143. package/dist/styles.css +2 -2
  144. package/dist/tab/index.cjs.js +1 -1
  145. package/dist/tab/index.es.js +1 -1
  146. package/dist/table/index.cjs.js +1 -1
  147. package/dist/table/index.es.js +1 -1
  148. package/dist/tooltip/index.cjs.js +1 -1
  149. package/dist/tooltip/index.es.js +1 -1
  150. package/dist/types/App.d.ts.map +1 -1
  151. package/dist/types/lib/index.d.ts +1 -0
  152. package/dist/types/lib/index.d.ts.map +1 -1
  153. package/dist/types/ui/form/html-editor.d.ts +5 -3
  154. package/dist/types/ui/form/html-editor.d.ts.map +1 -1
  155. package/dist/utils/index.cjs.js +1 -1
  156. package/dist/utils/index.cjs.js.map +1 -1
  157. package/dist/utils/index.es.js +284 -2
  158. package/dist/utils/index.es.js.map +1 -1
  159. package/package.json +5 -2
  160. package/dist/chunks/alert-BxS8Cjkv.cjs.js +0 -2
  161. package/dist/chunks/index-BWS4jvS6.cjs.js +0 -2
  162. package/dist/chunks/index-BWS4jvS6.cjs.js.map +0 -1
  163. package/dist/chunks/index-D6dQK9i-.es.js.map +0 -1
  164. package/dist/chunks/separator-uzP1VAwc.cjs.js +0 -2
  165. package/dist/chunks/skeleton-ZHnXbbz7.cjs.js +0 -2
  166. package/dist/chunks/textarea-C2I19p_j.cjs.js +0 -186
  167. package/dist/chunks/textarea-C2I19p_j.cjs.js.map +0 -1
  168. package/dist/chunks/textarea-D9gE4ALW.es.js.map +0 -1
  169. package/dist/chunks/timepicker-BdDhd6Ax.es.js +0 -3790
  170. package/dist/chunks/timepicker-BdDhd6Ax.es.js.map +0 -1
  171. package/dist/chunks/timepicker-C67I2BIy.cjs.js +0 -7
  172. package/dist/chunks/timepicker-C67I2BIy.cjs.js.map +0 -1
@@ -1,186 +0,0 @@
1
- "use strict";var Af=Object.defineProperty;var Cf=(n,e,t)=>e in n?Af(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t;var J=(n,e,t)=>Cf(n,typeof e!="symbol"?e+"":e,t);const O=require("react/jsx-runtime"),We=require("react"),Oe=require("./index-jFOWwfD3.cjs.js"),le=require("./index-D9zW9Tk7.cjs.js"),Qt=require("./index-BruMW80s.cjs.js"),jt=require("./index-CGLGXpw0.cjs.js"),Ws=require("./index-is755vrc.cjs.js"),Ce=require("./index-BWS4jvS6.cjs.js"),rc=require("./index-CMEUY8i_.cjs.js"),Ra=require("react-hook-form"),Tf=require("react-dom"),Oa=require("./index-DYLHhjdc.cjs.js"),De=require("./react-select-DocP3pOa.cjs.js"),Te=require("./index-DG15yxNP.cjs.js"),ii=require("./index-DGEvZwN5.cjs.js"),nc=require("./index-DnRKXUWD.cjs.js"),sc=require("./circle-CKMW6wiB.cjs.js"),gl=require("./index-C8ni3LLa.cjs.js"),kf=require("./index-pF_O2Ico.cjs.js"),Nf=require("./index-CItoM52t.cjs.js"),If=require("./index-CN4RxFxN.cjs.js"),rr=require("./index-pQxT4IlV.cjs.js"),Rf=require("./index-C28jaZCP.cjs.js"),ic=require("./chevron-down-T-PkxHnH.cjs.js"),Of=require("./createLucideIcon-HtK0p34L.cjs.js"),Lf=require("./button-DLexbK7C.cjs.js");function oc(n){if(n&&n.__esModule)return n;const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const t in n)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(n,t);Object.defineProperty(e,t,r.get?r:{enumerable:!0,get:()=>n[t]})}}return e.default=n,Object.freeze(e)}const C=oc(We),ac=oc(Tf);/**
2
- * @license lucide-react v0.563.0 - ISC
3
- *
4
- * This source code is licensed under the ISC license.
5
- * See the LICENSE file in the root directory of this source tree.
6
- */const Mf=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],Df=Of.createLucideIcon("chevron-up",Mf);function oi(n){const e=C.useRef({value:n,previous:n});return C.useMemo(()=>(e.current.value!==n&&(e.current.previous=e.current.value,e.current.value=n),e.current.previous),[n])}var ai="Checkbox",[Pf]=le.createContextScope(ai),[Bf,La]=Pf(ai);function qf(n){const{__scopeCheckbox:e,checked:t,children:r,defaultChecked:s,disabled:i,form:o,name:a,onCheckedChange:u,required:c,value:h="on",internal_do_not_use_render:g}=n,[d,m]=Qt.useControllableState({prop:t,defaultProp:s??!1,onChange:u,caller:ai}),[v,p]=C.useState(null),[y,E]=C.useState(null),S=C.useRef(!1),x=v?!!o||!!v.closest("form"):!0,N={checked:d,disabled:i,setChecked:m,control:v,setControl:p,name:a,form:o,value:h,hasConsumerStoppedPropagationRef:S,required:c,defaultChecked:Jt(s)?!1:s,isFormControl:x,bubbleInput:y,setBubbleInput:E};return O.jsx(Bf,{scope:e,...N,children:Ff(g)?g(N):r})}var lc="CheckboxTrigger",uc=C.forwardRef(({__scopeCheckbox:n,onKeyDown:e,onClick:t,...r},s)=>{const{control:i,value:o,disabled:a,checked:u,required:c,setControl:h,setChecked:g,hasConsumerStoppedPropagationRef:d,isFormControl:m,bubbleInput:v}=La(lc,n),p=Oe.useComposedRefs(s,h),y=C.useRef(u);return C.useEffect(()=>{const E=i==null?void 0:i.form;if(E){const S=()=>g(y.current);return E.addEventListener("reset",S),()=>E.removeEventListener("reset",S)}},[i,g]),O.jsx(le.Primitive.button,{type:"button",role:"checkbox","aria-checked":Jt(u)?"mixed":u,"aria-required":c,"data-state":pc(u),"data-disabled":a?"":void 0,disabled:a,value:o,...r,ref:p,onKeyDown:le.composeEventHandlers(e,E=>{E.key==="Enter"&&E.preventDefault()}),onClick:le.composeEventHandlers(t,E=>{g(S=>Jt(S)?!0:!S),v&&m&&(d.current=E.isPropagationStopped(),d.current||E.stopPropagation())})})});uc.displayName=lc;var Ma=C.forwardRef((n,e)=>{const{__scopeCheckbox:t,name:r,checked:s,defaultChecked:i,required:o,disabled:a,value:u,onCheckedChange:c,form:h,...g}=n;return O.jsx(qf,{__scopeCheckbox:t,checked:s,defaultChecked:i,disabled:a,required:o,onCheckedChange:c,name:r,form:h,value:u,internal_do_not_use_render:({isFormControl:d})=>O.jsxs(O.Fragment,{children:[O.jsx(uc,{...g,ref:e,__scopeCheckbox:t}),d&&O.jsx(fc,{__scopeCheckbox:t})]})})});Ma.displayName=ai;var cc="CheckboxIndicator",hc=C.forwardRef((n,e)=>{const{__scopeCheckbox:t,forceMount:r,...s}=n,i=La(cc,t);return O.jsx(le.Presence,{present:r||Jt(i.checked)||i.checked===!0,children:O.jsx(le.Primitive.span,{"data-state":pc(i.checked),"data-disabled":i.disabled?"":void 0,...s,ref:e,style:{pointerEvents:"none",...n.style}})})});hc.displayName=cc;var dc="CheckboxBubbleInput",fc=C.forwardRef(({__scopeCheckbox:n,...e},t)=>{const{control:r,hasConsumerStoppedPropagationRef:s,checked:i,defaultChecked:o,required:a,disabled:u,name:c,value:h,form:g,bubbleInput:d,setBubbleInput:m}=La(dc,n),v=Oe.useComposedRefs(t,m),p=oi(i),y=jt.useSize(r);C.useEffect(()=>{const S=d;if(!S)return;const x=window.HTMLInputElement.prototype,_=Object.getOwnPropertyDescriptor(x,"checked").set,P=!s.current;if(p!==i&&_){const I=new Event("click",{bubbles:P});S.indeterminate=Jt(i),_.call(S,Jt(i)?!1:i),S.dispatchEvent(I)}},[d,p,i,s]);const E=C.useRef(Jt(i)?!1:i);return O.jsx(le.Primitive.input,{type:"checkbox","aria-hidden":!0,defaultChecked:o??E.current,required:a,disabled:u,name:c,value:h,form:g,...e,tabIndex:-1,ref:v,style:{...e.style,...y,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});fc.displayName=dc;function Ff(n){return typeof n=="function"}function Jt(n){return n==="indeterminate"}function pc(n){return Jt(n)?"indeterminate":n?"checked":"unchecked"}const gc=C.forwardRef(({className:n,...e},t)=>O.jsx(Ma,{ref:t,className:Ce.cn("peer border-border-alpha-strong ring-offset-background size-4 shrink-0 cursor-pointer rounded-sm border disabled:cursor-not-allowed disabled:opacity-50","data-[state=checked]:text-primary data-[state=checked]:bg-item-primary",n),...e,children:O.jsx(hc,{className:Ce.cn("flex size-4 items-center justify-center text-current"),children:e.checked==="indeterminate"?O.jsx(Ws.RN,{className:"mr-0.5 mb-0.5 size-3.5 text-white"}):O.jsx(Ws.s7,{className:"mr-0.5 mb-0.5 size-3.5 text-white"})})}));gc.displayName=Ma.displayName;var jf=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,$f=De.memoize(function(n){return jf.test(n)||n.charCodeAt(0)===111&&n.charCodeAt(1)===110&&n.charCodeAt(2)<91}),_e="-ms-",Fn="-moz-",ye="-webkit-",mc="comm",li="rule",Da="decl",Vf="@import",Uf="@namespace",vc="@keyframes",Hf="@layer",yc=Math.abs,Pa=String.fromCharCode,Wo=Object.assign;function zf(n,e){return Re(n,0)^45?(((e<<2^Re(n,0))<<2^Re(n,1))<<2^Re(n,2))<<2^Re(n,3):0}function bc(n){return n.trim()}function Mt(n,e){return(n=e.exec(n))?n[0]:n}function fe(n,e,t){return n.replace(e,t)}function Bs(n,e,t){return n.indexOf(e,t)}function Re(n,e){return n.charCodeAt(e)|0}function br(n,e,t){return n.slice(e,t)}function lt(n){return n.length}function Ec(n){return n.length}function Ln(n,e){return e.push(n),n}function Gf(n,e){return n.map(e).join("")}function ml(n,e){return n.filter(function(t){return!Mt(t,e)})}var ui=1,rn=1,wc=0,rt=0,Ne=0,dn="";function ci(n,e,t,r,s,i,o,a){return{value:n,root:e,parent:t,type:r,props:s,children:i,line:ui,column:rn,length:o,return:"",siblings:a}}function Gt(n,e){return Wo(ci("",null,null,"",null,null,0,n.siblings),n,{length:-n.length},e)}function Hr(n){for(;n.root;)n=Gt(n.root,{children:[n]});Ln(n,n.siblings)}function Kf(){return Ne}function Wf(){return Ne=rt>0?Re(dn,--rt):0,rn--,Ne===10&&(rn=1,ui--),Ne}function ht(){return Ne=rt<wc?Re(dn,rt++):0,rn++,Ne===10&&(rn=1,ui++),Ne}function Yt(){return Re(dn,rt)}function qs(){return rt}function hi(n,e){return br(dn,n,e)}function Hn(n){switch(n){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function Yf(n){return ui=rn=1,wc=lt(dn=n),rt=0,[]}function Zf(n){return dn="",n}function wo(n){return bc(hi(rt-1,Yo(n===91?n+2:n===40?n+1:n)))}function Xf(n){for(;(Ne=Yt())&&Ne<33;)ht();return Hn(n)>2||Hn(Ne)>3?"":" "}function Qf(n,e){for(;--e&&ht()&&!(Ne<48||Ne>102||Ne>57&&Ne<65||Ne>70&&Ne<97););return hi(n,qs()+(e<6&&Yt()==32&&ht()==32))}function Yo(n){for(;ht();)switch(Ne){case n:return rt;case 34:case 39:n!==34&&n!==39&&Yo(Ne);break;case 40:n===41&&Yo(n);break;case 92:ht();break}return rt}function Jf(n,e){for(;ht()&&n+Ne!==57;)if(n+Ne===84&&Yt()===47)break;return"/*"+hi(e,rt-1)+"*"+Pa(n===47?n:ht())}function ep(n){for(;!Hn(Yt());)ht();return hi(n,rt)}function tp(n){return Zf(Fs("",null,null,null,[""],n=Yf(n),0,[0],n))}function Fs(n,e,t,r,s,i,o,a,u){for(var c=0,h=0,g=o,d=0,m=0,v=0,p=1,y=1,E=1,S=0,x="",N=s,_=i,P=r,I=x;y;)switch(v=S,S=ht()){case 40:if(v!=108&&Re(I,g-1)==58){Bs(I+=fe(wo(S),"&","&\f"),"&\f",yc(c?a[c-1]:0))!=-1&&(E=-1);break}case 34:case 39:case 91:I+=wo(S);break;case 9:case 10:case 13:case 32:I+=Xf(v);break;case 92:I+=Qf(qs()-1,7);continue;case 47:switch(Yt()){case 42:case 47:Ln(rp(Jf(ht(),qs()),e,t,u),u),(Hn(v||1)==5||Hn(Yt()||1)==5)&&lt(I)&&br(I,-1,void 0)!==" "&&(I+=" ");break;default:I+="/"}break;case 123*p:a[c++]=lt(I)*E;case 125*p:case 59:case 0:switch(S){case 0:case 125:y=0;case 59+h:E==-1&&(I=fe(I,/\f/g,"")),m>0&&(lt(I)-g||p===0&&v===47)&&Ln(m>32?yl(I+";",r,t,g-1,u):yl(fe(I," ","")+";",r,t,g-2,u),u);break;case 59:I+=";";default:if(Ln(P=vl(I,e,t,c,h,s,a,x,N=[],_=[],g,i),i),S===123)if(h===0)Fs(I,e,P,P,N,i,g,a,_);else{switch(d){case 99:if(Re(I,3)===110)break;case 108:if(Re(I,2)===97)break;default:h=0;case 100:case 109:case 115:}h?Fs(n,P,P,r&&Ln(vl(n,P,P,0,0,s,a,x,s,N=[],g,_),_),s,_,g,a,r?N:_):Fs(I,P,P,P,[""],_,0,a,_)}}c=h=m=0,p=E=1,x=I="",g=o;break;case 58:g=1+lt(I),m=v;default:if(p<1){if(S==123)--p;else if(S==125&&p++==0&&Wf()==125)continue}switch(I+=Pa(S),S*p){case 38:E=h>0?1:(I+="\f",-1);break;case 44:a[c++]=(lt(I)-1)*E,E=1;break;case 64:Yt()===45&&(I+=wo(ht())),d=Yt(),h=g=lt(x=I+=ep(qs())),S++;break;case 45:v===45&&lt(I)==2&&(p=0)}}return i}function vl(n,e,t,r,s,i,o,a,u,c,h,g){for(var d=s-1,m=s===0?i:[""],v=Ec(m),p=0,y=0,E=0;p<r;++p)for(var S=0,x=br(n,d+1,d=yc(y=o[p])),N=n;S<v;++S)(N=bc(y>0?m[S]+" "+x:fe(x,/&\f/g,m[S])))&&(u[E++]=N);return ci(n,e,t,s===0?li:a,u,c,h,g)}function rp(n,e,t,r){return ci(n,e,t,mc,Pa(Kf()),br(n,2,-2),0,r)}function yl(n,e,t,r,s){return ci(n,e,t,Da,br(n,0,r),br(n,r+1,-1),r,s)}function xc(n,e,t){switch(zf(n,e)){case 5103:return ye+"print-"+n+n;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:case 6391:case 5879:case 5623:case 6135:case 4599:return ye+n+n;case 4855:return ye+n.replace("add","source-over").replace("substract","source-out").replace("intersect","source-in").replace("exclude","xor")+n;case 4789:return Fn+n+n;case 5349:case 4246:case 4810:case 6968:case 2756:return ye+n+Fn+n+_e+n+n;case 5936:switch(Re(n,e+11)){case 114:return ye+n+_e+fe(n,/[svh]\w+-[tblr]{2}/,"tb")+n;case 108:return ye+n+_e+fe(n,/[svh]\w+-[tblr]{2}/,"tb-rl")+n;case 45:return ye+n+_e+fe(n,/[svh]\w+-[tblr]{2}/,"lr")+n}case 6828:case 4268:case 2903:return ye+n+_e+n+n;case 6165:return ye+n+_e+"flex-"+n+n;case 5187:return ye+n+fe(n,/(\w+).+(:[^]+)/,ye+"box-$1$2"+_e+"flex-$1$2")+n;case 5443:return ye+n+_e+"flex-item-"+fe(n,/flex-|-self/g,"")+(Mt(n,/flex-|baseline/)?"":_e+"grid-row-"+fe(n,/flex-|-self/g,""))+n;case 4675:return ye+n+_e+"flex-line-pack"+fe(n,/align-content|flex-|-self/g,"")+n;case 5548:return ye+n+_e+fe(n,"shrink","negative")+n;case 5292:return ye+n+_e+fe(n,"basis","preferred-size")+n;case 6060:return ye+"box-"+fe(n,"-grow","")+ye+n+_e+fe(n,"grow","positive")+n;case 4554:return ye+fe(n,/([^-])(transform)/g,"$1"+ye+"$2")+n;case 6187:return fe(fe(fe(n,/(zoom-|grab)/,ye+"$1"),/(image-set)/,ye+"$1"),n,"")+n;case 5495:case 3959:return fe(n,/(image-set\([^]*)/,ye+"$1$`$1");case 4968:return fe(fe(n,/(.+:)(flex-)?(.*)/,ye+"box-pack:$3"+_e+"flex-pack:$3"),/space-between/,"justify")+ye+n+n;case 4200:if(!Mt(n,/flex-|baseline/))return _e+"grid-column-align"+br(n,e)+n;break;case 2592:case 3360:return _e+fe(n,"template-","")+n;case 4384:case 3616:return t&&t.some(function(r,s){return e=s,Mt(r.props,/grid-\w+-end/)})?~Bs(n+(t=t[e].value),"span",0)?n:_e+fe(n,"-start","")+n+_e+"grid-row-span:"+(~Bs(t,"span",0)?Mt(t,/\d+/):+Mt(t,/\d+/)-+Mt(n,/\d+/))+";":_e+fe(n,"-start","")+n;case 4896:case 4128:return t&&t.some(function(r){return Mt(r.props,/grid-\w+-start/)})?n:_e+fe(fe(n,"-end","-span"),"span ","")+n;case 4095:case 3583:case 4068:case 2532:return fe(n,/(.+)-inline(.+)/,ye+"$1$2")+n;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(lt(n)-1-e>6)switch(Re(n,e+1)){case 109:if(Re(n,e+4)!==45)break;case 102:return fe(n,/(.+:)(.+)-([^]+)/,"$1"+ye+"$2-$3$1"+Fn+(Re(n,e+3)==108?"$3":"$2-$3"))+n;case 115:return~Bs(n,"stretch",0)?xc(fe(n,"stretch","fill-available"),e,t)+n:n}break;case 5152:case 5920:return fe(n,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(r,s,i,o,a,u,c){return _e+s+":"+i+c+(o?_e+s+"-span:"+(a?u:+u-+i)+c:"")+n});case 4949:if(Re(n,e+6)===121)return fe(n,":",":"+ye)+n;break;case 6444:switch(Re(n,Re(n,14)===45?18:11)){case 120:return fe(n,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+ye+(Re(n,14)===45?"inline-":"")+"box$3$1"+ye+"$2$3$1"+_e+"$2box$3")+n;case 100:return fe(n,":",":"+_e)+n}break;case 5719:case 2647:case 2135:case 3927:case 2391:return fe(n,"scroll-","scroll-snap-")+n}return n}function Ys(n,e){for(var t="",r=0;r<n.length;r++)t+=e(n[r],r,n,e)||"";return t}function np(n,e,t,r){switch(n.type){case Hf:if(n.children.length)break;case Vf:case Uf:case Da:return n.return=n.return||n.value;case mc:return"";case vc:return n.return=n.value+"{"+Ys(n.children,r)+"}";case li:if(!lt(n.value=n.props.join(",")))return""}return lt(t=Ys(n.children,r))?n.return=n.value+"{"+t+"}":""}function sp(n){var e=Ec(n);return function(t,r,s,i){for(var o="",a=0;a<e;a++)o+=n[a](t,r,s,i)||"";return o}}function ip(n){return function(e){e.root||(e=e.return)&&n(e)}}function op(n,e,t,r){if(n.length>-1&&!n.return)switch(n.type){case Da:n.return=xc(n.value,n.length,t);return;case vc:return Ys([Gt(n,{value:fe(n.value,"@","@"+ye)})],r);case li:if(n.length)return Gf(t=n.props,function(s){switch(Mt(s,r=/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":Hr(Gt(n,{props:[fe(s,/:(read-\w+)/,":"+Fn+"$1")]})),Hr(Gt(n,{props:[s]})),Wo(n,{props:ml(t,r)});break;case"::placeholder":Hr(Gt(n,{props:[fe(s,/:(plac\w+)/,":"+ye+"input-$1")]})),Hr(Gt(n,{props:[fe(s,/:(plac\w+)/,":"+Fn+"$1")]})),Hr(Gt(n,{props:[fe(s,/:(plac\w+)/,_e+"input-$1")]})),Hr(Gt(n,{props:[s]})),Wo(n,{props:ml(t,r)});break}return""})}}var Er=typeof process<"u"&&process.env!==void 0&&(process.env.REACT_APP_SC_ATTR||process.env.SC_ATTR)||"data-styled",Sc="active",_c="data-styled-version",di="6.3.8",Ba=`/*!sc*/
7
- `,Zs=typeof window<"u"&&typeof document<"u",wr=C.default.createContext===void 0,ap=!!(typeof SC_DISABLE_SPEEDY=="boolean"?SC_DISABLE_SPEEDY:typeof process<"u"&&process.env!==void 0&&process.env.REACT_APP_SC_DISABLE_SPEEDY!==void 0&&process.env.REACT_APP_SC_DISABLE_SPEEDY!==""?process.env.REACT_APP_SC_DISABLE_SPEEDY!=="false"&&process.env.REACT_APP_SC_DISABLE_SPEEDY:typeof process<"u"&&process.env!==void 0&&process.env.SC_DISABLE_SPEEDY!==void 0&&process.env.SC_DISABLE_SPEEDY!==""?process.env.SC_DISABLE_SPEEDY!=="false"&&process.env.SC_DISABLE_SPEEDY:process.env.NODE_ENV!=="production"),bl=/invalid hook call/i,Ss=new Set,lp=function(n,e){if(process.env.NODE_ENV!=="production"){if(wr)return;var t=e?' with the id of "'.concat(e,'"'):"",r="The component ".concat(n).concat(t,` has been created dynamically.
8
- `)+`You may see this warning because you've called styled inside another component.
9
- To resolve this only create new StyledComponents outside of any render method and function component.
10
- See https://styled-components.com/docs/basics#define-styled-components-outside-of-the-render-method for more info.
11
- `,s=console.error;try{var i=!0;console.error=function(o){for(var a=[],u=1;u<arguments.length;u++)a[u-1]=arguments[u];bl.test(o)?(i=!1,Ss.delete(r)):s.apply(void 0,Te.__spreadArray([o],a,!1))},typeof C.default.useState=="function"&&C.default.useState(null),i&&!Ss.has(r)&&(console.warn(r),Ss.add(r))}catch(o){bl.test(o.message)&&Ss.delete(r)}finally{console.error=s}}},fi=Object.freeze([]),nn=Object.freeze({});function up(n,e,t){return t===void 0&&(t=nn),n.theme!==t.theme&&n.theme||e||t.theme}var Zo=new Set(["a","abbr","address","area","article","aside","audio","b","bdi","bdo","blockquote","body","button","br","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","label","legend","li","main","map","mark","menu","meter","nav","object","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","slot","small","span","strong","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","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","filter","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","switch","symbol","text","textPath","tspan","use"]),cp=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,hp=/(^-|-$)/g;function El(n){return n.replace(cp,"-").replace(hp,"")}var dp=/(a)(d)/gi,wl=function(n){return String.fromCharCode(n+(n>25?39:97))};function Xo(n){var e,t="";for(e=Math.abs(n);e>52;e=e/52|0)t=wl(e%52)+t;return(wl(e%52)+t).replace(dp,"$1-$2")}var xo,gr=function(n,e){for(var t=e.length;t;)n=33*n^e.charCodeAt(--t);return n},Ac=function(n){return gr(5381,n)};function fp(n){return Xo(Ac(n)>>>0)}function Cc(n){return process.env.NODE_ENV!=="production"&&typeof n=="string"&&n||n.displayName||n.name||"Component"}function So(n){return typeof n=="string"&&(process.env.NODE_ENV==="production"||n.charAt(0)===n.charAt(0).toLowerCase())}var Tc=typeof Symbol=="function"&&Symbol.for,kc=Tc?Symbol.for("react.memo"):60115,pp=Tc?Symbol.for("react.forward_ref"):60112,gp={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},mp={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},Nc={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},vp=((xo={})[pp]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},xo[kc]=Nc,xo);function xl(n){return("type"in(e=n)&&e.type.$$typeof)===kc?Nc:"$$typeof"in n?vp[n.$$typeof]:gp;var e}var yp=Object.defineProperty,bp=Object.getOwnPropertyNames,Sl=Object.getOwnPropertySymbols,Ep=Object.getOwnPropertyDescriptor,wp=Object.getPrototypeOf,_l=Object.prototype;function Ic(n,e,t){if(typeof e!="string"){if(_l){var r=wp(e);r&&r!==_l&&Ic(n,r,t)}var s=bp(e);Sl&&(s=s.concat(Sl(e)));for(var i=xl(n),o=xl(e),a=0;a<s.length;++a){var u=s[a];if(!(u in mp||t&&t[u]||o&&u in o||i&&u in i)){var c=Ep(e,u);try{yp(n,u,c)}catch{}}}}return n}function sn(n){return typeof n=="function"}function qa(n){return typeof n=="object"&&"styledComponentId"in n}function mr(n,e){return n&&e?"".concat(n," ").concat(e):n||e||""}function Al(n,e){if(n.length===0)return"";for(var t=n[0],r=1;r<n.length;r++)t+=n[r];return t}function on(n){return n!==null&&typeof n=="object"&&n.constructor.name===Object.name&&!("props"in n&&n.$$typeof)}function Qo(n,e,t){if(t===void 0&&(t=!1),!t&&!on(n)&&!Array.isArray(n))return e;if(Array.isArray(e))for(var r=0;r<e.length;r++)n[r]=Qo(n[r],e[r]);else if(on(e))for(var r in e)n[r]=Qo(n[r],e[r]);return n}function Fa(n,e){Object.defineProperty(n,"toString",{value:e})}var xp=process.env.NODE_ENV!=="production"?{1:`Cannot create styled-component for component: %s.
12
-
13
- `,2:`Can't collect styles once you've consumed a \`ServerStyleSheet\`'s styles! \`ServerStyleSheet\` is a one off instance for each server-side render cycle.
14
-
15
- - Are you trying to reuse it across renders?
16
- - Are you accidentally calling collectStyles twice?
17
-
18
- `,3:`Streaming SSR is only supported in a Node.js environment; Please do not try to call this method in the browser.
19
-
20
- `,4:`The \`StyleSheetManager\` expects a valid target or sheet prop!
21
-
22
- - Does this error occur on the client and is your target falsy?
23
- - Does this error occur on the server and is the sheet falsy?
24
-
25
- `,5:`The clone method cannot be used on the client!
26
-
27
- - Are you running in a client-like environment on the server?
28
- - Are you trying to run SSR on the client?
29
-
30
- `,6:`Trying to insert a new style tag, but the given Node is unmounted!
31
-
32
- - Are you using a custom target that isn't mounted?
33
- - Does your document not have a valid head element?
34
- - Have you accidentally removed a style tag manually?
35
-
36
- `,7:'ThemeProvider: Please return an object from your "theme" prop function, e.g.\n\n```js\ntheme={() => ({})}\n```\n\n',8:`ThemeProvider: Please make your "theme" prop an object.
37
-
38
- `,9:"Missing document `<head>`\n\n",10:`Cannot find a StyleSheet instance. Usually this happens if there are multiple copies of styled-components loaded at once. Check out this issue for how to troubleshoot and fix the common cases where this situation can happen: https://github.com/styled-components/styled-components/issues/1941#issuecomment-417862021
39
-
40
- `,11:`_This error was replaced with a dev-time warning, it will be deleted for v4 final._ [createGlobalStyle] received children which will not be rendered. Please use the component without passing children elements.
41
-
42
- `,12:"It seems you are interpolating a keyframe declaration (%s) into an untagged string. This was supported in styled-components v3, but is not longer supported in v4 as keyframes are now injected on-demand. Please wrap your string in the css\\`\\` helper which ensures the styles are injected correctly. See https://www.styled-components.com/docs/api#css\n\n",13:`%s is not a styled component and cannot be referred to via component selector. See https://www.styled-components.com/docs/advanced#referring-to-other-components for more details.
43
-
44
- `,14:`ThemeProvider: "theme" prop is required.
45
-
46
- `,15:"A stylis plugin has been supplied that is not named. We need a name for each plugin to be able to prevent styling collisions between different stylis configurations within the same app. Before you pass your plugin to `<StyleSheetManager stylisPlugins={[]}>`, please make sure each plugin is uniquely-named, e.g.\n\n```js\nObject.defineProperty(importedPlugin, 'name', { value: 'some-unique-name' });\n```\n\n",16:`Reached the limit of how many styled components may be created at group %s.
47
- You may only create up to 1,073,741,824 components. If you're creating components dynamically,
48
- as for instance in your render method then you may be running into this limitation.
49
-
50
- `,17:`CSSStyleSheet could not be found on HTMLStyleElement.
51
- Has styled-components' style tag been unmounted or altered by another script?
52
- `,18:"ThemeProvider: Please make sure your useTheme hook is within a `<ThemeProvider>`"}:{};function Sp(){for(var n=[],e=0;e<arguments.length;e++)n[e]=arguments[e];for(var t=n[0],r=[],s=1,i=n.length;s<i;s+=1)r.push(n[s]);return r.forEach(function(o){t=t.replace(/%[a-z]/,o)}),t}function fn(n){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return process.env.NODE_ENV==="production"?new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(n," for more information.").concat(e.length>0?" Args: ".concat(e.join(", ")):"")):new Error(Sp.apply(void 0,Te.__spreadArray([xp[n]],e,!1)).trim())}var _p=(function(){function n(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}return n.prototype.indexOfGroup=function(e){for(var t=0,r=0;r<e;r++)t+=this.groupSizes[r];return t},n.prototype.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var r=this.groupSizes,s=r.length,i=s;e>=i;)if((i<<=1)<0)throw fn(16,"".concat(e));this.groupSizes=new Uint32Array(i),this.groupSizes.set(r),this.length=i;for(var o=s;o<i;o++)this.groupSizes[o]=0}for(var a=this.indexOfGroup(e+1),u=(o=0,t.length);o<u;o++)this.tag.insertRule(a,t[o])&&(this.groupSizes[e]++,a++)},n.prototype.clearGroup=function(e){if(e<this.length){var t=this.groupSizes[e],r=this.indexOfGroup(e),s=r+t;this.groupSizes[e]=0;for(var i=r;i<s;i++)this.tag.deleteRule(r)}},n.prototype.getGroup=function(e){var t="";if(e>=this.length||this.groupSizes[e]===0)return t;for(var r=this.groupSizes[e],s=this.indexOfGroup(e),i=s+r,o=s;o<i;o++)t+="".concat(this.tag.getRule(o)).concat(Ba);return t},n})(),Ap=1<<30,js=new Map,Xs=new Map,$s=1,Mn=function(n){if(js.has(n))return js.get(n);for(;Xs.has($s);)$s++;var e=$s++;if(process.env.NODE_ENV!=="production"&&((0|e)<0||e>Ap))throw fn(16,"".concat(e));return js.set(n,e),Xs.set(e,n),e},Cp=function(n,e){$s=e+1,js.set(n,e),Xs.set(e,n)},Tp="style[".concat(Er,"][").concat(_c,'="').concat(di,'"]'),kp=new RegExp("^".concat(Er,'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')),Np=function(n,e,t){for(var r,s=t.split(","),i=0,o=s.length;i<o;i++)(r=s[i])&&n.registerName(e,r)},Ip=function(n,e){for(var t,r=((t=e.textContent)!==null&&t!==void 0?t:"").split(Ba),s=[],i=0,o=r.length;i<o;i++){var a=r[i].trim();if(a){var u=a.match(kp);if(u){var c=0|parseInt(u[1],10),h=u[2];c!==0&&(Cp(h,c),Np(n,h,u[3]),n.getTag().insertRules(c,s)),s.length=0}else s.push(a)}}},Cl=function(n){for(var e=document.querySelectorAll(Tp),t=0,r=e.length;t<r;t++){var s=e[t];s&&s.getAttribute(Er)!==Sc&&(Ip(n,s),s.parentNode&&s.parentNode.removeChild(s))}};function Rp(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:null}var Rc=function(n){var e=document.head,t=n||e,r=document.createElement("style"),s=(function(a){var u=Array.from(a.querySelectorAll("style[".concat(Er,"]")));return u[u.length-1]})(t),i=s!==void 0?s.nextSibling:null;r.setAttribute(Er,Sc),r.setAttribute(_c,di);var o=Rp();return o&&r.setAttribute("nonce",o),t.insertBefore(r,i),r},Op=(function(){function n(e){this.element=Rc(e),this.element.appendChild(document.createTextNode("")),this.sheet=(function(t){if(t.sheet)return t.sheet;for(var r=document.styleSheets,s=0,i=r.length;s<i;s++){var o=r[s];if(o.ownerNode===t)return o}throw fn(17)})(this.element),this.length=0}return n.prototype.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch{return!1}},n.prototype.deleteRule=function(e){this.sheet.deleteRule(e),this.length--},n.prototype.getRule=function(e){var t=this.sheet.cssRules[e];return t&&t.cssText?t.cssText:""},n})(),Lp=(function(){function n(e){this.element=Rc(e),this.nodes=this.element.childNodes,this.length=0}return n.prototype.insertRule=function(e,t){if(e<=this.length&&e>=0){var r=document.createTextNode(t);return this.element.insertBefore(r,this.nodes[e]||null),this.length++,!0}return!1},n.prototype.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},n.prototype.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},n})(),Mp=(function(){function n(e){this.rules=[],this.length=0}return n.prototype.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,!0)},n.prototype.deleteRule=function(e){this.rules.splice(e,1),this.length--},n.prototype.getRule=function(e){return e<this.length?this.rules[e]:""},n})(),Tl=Zs,Dp={isServer:!Zs,useCSSOMInjection:!ap},Oc=(function(){function n(e,t,r){e===void 0&&(e=nn),t===void 0&&(t={});var s=this;this.options=Te.__assign(Te.__assign({},Dp),e),this.gs=t,this.names=new Map(r),this.server=!!e.isServer,!this.server&&Zs&&Tl&&(Tl=!1,Cl(this)),Fa(this,function(){return(function(i){for(var o=i.getTag(),a=o.length,u="",c=function(g){var d=(function(E){return Xs.get(E)})(g);if(d===void 0)return"continue";var m=i.names.get(d),v=o.getGroup(g);if(m===void 0||!m.size||v.length===0)return"continue";var p="".concat(Er,".g").concat(g,'[id="').concat(d,'"]'),y="";m!==void 0&&m.forEach(function(E){E.length>0&&(y+="".concat(E,","))}),u+="".concat(v).concat(p,'{content:"').concat(y,'"}').concat(Ba)},h=0;h<a;h++)c(h);return u})(s)})}return n.registerId=function(e){return Mn(e)},n.prototype.rehydrate=function(){!this.server&&Zs&&Cl(this)},n.prototype.reconstructWithOptions=function(e,t){return t===void 0&&(t=!0),new n(Te.__assign(Te.__assign({},this.options),e),this.gs,t&&this.names||void 0)},n.prototype.allocateGSInstance=function(e){return this.gs[e]=(this.gs[e]||0)+1},n.prototype.getTag=function(){return this.tag||(this.tag=(e=(function(t){var r=t.useCSSOMInjection,s=t.target;return t.isServer?new Mp(s):r?new Op(s):new Lp(s)})(this.options),new _p(e)));var e},n.prototype.hasNameForId=function(e,t){return this.names.has(e)&&this.names.get(e).has(t)},n.prototype.registerName=function(e,t){if(Mn(e),this.names.has(e))this.names.get(e).add(t);else{var r=new Set;r.add(t),this.names.set(e,r)}},n.prototype.insertRules=function(e,t,r){this.registerName(e,t),this.getTag().insertRules(Mn(e),r)},n.prototype.clearNames=function(e){this.names.has(e)&&this.names.get(e).clear()},n.prototype.clearRules=function(e){this.getTag().clearGroup(Mn(e)),this.clearNames(e)},n.prototype.clearTag=function(){this.tag=void 0},n})(),Pp=/&/g,Qr=47;function kl(n){if(n.indexOf("}")===-1)return!1;for(var e=n.length,t=0,r=0,s=!1,i=0;i<e;i++){var o=n.charCodeAt(i);if(r!==0||s||o!==Qr||n.charCodeAt(i+1)!==42)if(s)o===42&&n.charCodeAt(i+1)===Qr&&(s=!1,i++);else if(o!==34&&o!==39||i!==0&&n.charCodeAt(i-1)===92){if(r===0){if(o===123)t++;else if(o===125&&--t<0)return!0}}else r===0?r=o:r===o&&(r=0);else s=!0,i++}return t!==0||r!==0}function Lc(n,e){return n.map(function(t){return t.type==="rule"&&(t.value="".concat(e," ").concat(t.value),t.value=t.value.replaceAll(",",",".concat(e," ")),t.props=t.props.map(function(r){return"".concat(e," ").concat(r)})),Array.isArray(t.children)&&t.type!=="@keyframes"&&(t.children=Lc(t.children,e)),t})}function Bp(n){var e,t,r,s=nn,i=s.options,o=i===void 0?nn:i,a=s.plugins,u=a===void 0?fi:a,c=function(d,m,v){return v.startsWith(t)&&v.endsWith(t)&&v.replaceAll(t,"").length>0?".".concat(e):d},h=u.slice();h.push(function(d){d.type===li&&d.value.includes("&")&&(d.props[0]=d.props[0].replace(Pp,t).replace(r,c))}),o.prefix&&h.push(op),h.push(np);var g=function(d,m,v,p){m===void 0&&(m=""),v===void 0&&(v=""),p===void 0&&(p="&"),e=p,t=m,r=new RegExp("\\".concat(t,"\\b"),"g");var y=(function(x){if(!kl(x))return x;for(var N=x.length,_="",P=0,I=0,te=0,ue=!1,ie=0;ie<N;ie++){var b=x.charCodeAt(ie);if(te!==0||ue||b!==Qr||x.charCodeAt(ie+1)!==42)if(ue)b===42&&x.charCodeAt(ie+1)===Qr&&(ue=!1,ie++);else if(b!==34&&b!==39||ie!==0&&x.charCodeAt(ie-1)===92){if(te===0)if(b===123)I++;else if(b===125){if(--I<0){for(var M=ie+1;M<N;){var A=x.charCodeAt(M);if(A===59||A===10)break;M++}M<N&&x.charCodeAt(M)===59&&M++,I=0,ie=M-1,P=M;continue}I===0&&(_+=x.substring(P,ie+1),P=ie+1)}else b===59&&I===0&&(_+=x.substring(P,ie+1),P=ie+1)}else te===0?te=b:te===b&&(te=0);else ue=!0,ie++}if(P<N){var $=x.substring(P);kl($)||(_+=$)}return _})((function(x){if(x.indexOf("//")===-1)return x;for(var N=x.length,_=[],P=0,I=0,te=0,ue=0;I<N;){var ie=x.charCodeAt(I);if(ie!==34&&ie!==39||I!==0&&x.charCodeAt(I-1)===92)if(te===0)if(ie===40&&I>=3&&(32|x.charCodeAt(I-1))==108&&(32|x.charCodeAt(I-2))==114&&(32|x.charCodeAt(I-3))==117)ue=1,I++;else if(ue>0)ie===41?ue--:ie===40&&ue++,I++;else if(ie===Qr&&I+1<N&&x.charCodeAt(I+1)===Qr){for(I>P&&_.push(x.substring(P,I));I<N&&x.charCodeAt(I)!==10;)I++;P=I}else I++;else I++;else te===0?te=ie:te===ie&&(te=0),I++}return P===0?x:(P<N&&_.push(x.substring(P)),_.join(""))})(d)),E=tp(v||m?"".concat(v," ").concat(m," { ").concat(y," }"):y);o.namespace&&(E=Lc(E,o.namespace));var S=[];return Ys(E,sp(h.concat(ip(function(x){return S.push(x)})))),S};return g.hash=u.length?u.reduce(function(d,m){return m.name||fn(15),gr(d,m.name)},5381).toString():"",g}var qp=new Oc,Jo=Bp(),ea={shouldForwardProp:void 0,styleSheet:qp,stylis:Jo},Mc=wr?{Provider:function(n){return n.children},Consumer:function(n){return(0,n.children)(ea)}}:C.default.createContext(ea);Mc.Consumer;wr||C.default.createContext(void 0);function Nl(){return wr?ea:C.default.useContext(Mc)}var Il=(function(){function n(e,t){var r=this;this.inject=function(s,i){i===void 0&&(i=Jo);var o=r.name+i.hash;s.hasNameForId(r.id,o)||s.insertRules(r.id,o,i(r.rules,o,"@keyframes"))},this.name=e,this.id="sc-keyframes-".concat(e),this.rules=t,Fa(this,function(){throw fn(12,String(r.name))})}return n.prototype.getName=function(e){return e===void 0&&(e=Jo),this.name+e.hash},n})();function Fp(n,e){return e==null||typeof e=="boolean"||e===""?"":typeof e!="number"||e===0||n in De.unitlessKeys||n.startsWith("--")?String(e).trim():"".concat(e,"px")}var jp=function(n){return n>="A"&&n<="Z"};function Rl(n){for(var e="",t=0;t<n.length;t++){var r=n[t];if(t===1&&r==="-"&&n[0]==="-")return n;jp(r)?e+="-"+r.toLowerCase():e+=r}return e.startsWith("ms-")?"-"+e:e}var Dc=function(n){return n==null||n===!1||n===""},Pc=function(n){var e=[];for(var t in n){var r=n[t];n.hasOwnProperty(t)&&!Dc(r)&&(Array.isArray(r)&&r.isCss||sn(r)?e.push("".concat(Rl(t),":"),r,";"):on(r)?e.push.apply(e,Te.__spreadArray(Te.__spreadArray(["".concat(t," {")],Pc(r),!1),["}"],!1)):e.push("".concat(Rl(t),": ").concat(Fp(t,r),";")))}return e};function yr(n,e,t,r){if(Dc(n))return[];if(qa(n))return[".".concat(n.styledComponentId)];if(sn(n)){if(!sn(i=n)||i.prototype&&i.prototype.isReactComponent||!e)return[n];var s=n(e);return process.env.NODE_ENV==="production"||typeof s!="object"||Array.isArray(s)||s instanceof Il||on(s)||s===null||console.error("".concat(Cc(n)," is not a styled component and cannot be referred to via component selector. See https://www.styled-components.com/docs/advanced#referring-to-other-components for more details.")),yr(s,e,t,r)}var i;return n instanceof Il?t?(n.inject(t,r),[n.getName(r)]):[n]:on(n)?Pc(n):Array.isArray(n)?Array.prototype.concat.apply(fi,n.map(function(o){return yr(o,e,t,r)})):[n.toString()]}function $p(n){for(var e=0;e<n.length;e+=1){var t=n[e];if(sn(t)&&!qa(t))return!1}return!0}var Vp=Ac(di),Up=(function(){function n(e,t,r){this.rules=e,this.staticRulesId="",this.isStatic=process.env.NODE_ENV==="production"&&(r===void 0||r.isStatic)&&$p(e),this.componentId=t,this.baseHash=gr(Vp,t),this.baseStyle=r,Oc.registerId(t)}return n.prototype.generateAndInjectStyles=function(e,t,r){var s=this.baseStyle?this.baseStyle.generateAndInjectStyles(e,t,r).className:"";if(this.isStatic&&!r.hash)if(this.staticRulesId&&t.hasNameForId(this.componentId,this.staticRulesId))s=mr(s,this.staticRulesId);else{var i=Al(yr(this.rules,e,t,r)),o=Xo(gr(this.baseHash,i)>>>0);if(!t.hasNameForId(this.componentId,o)){var a=r(i,".".concat(o),void 0,this.componentId);t.insertRules(this.componentId,o,a)}s=mr(s,o),this.staticRulesId=o}else{for(var u=gr(this.baseHash,r.hash),c="",h=0;h<this.rules.length;h++){var g=this.rules[h];if(typeof g=="string")c+=g,process.env.NODE_ENV!=="production"&&(u=gr(u,g));else if(g){var d=Al(yr(g,e,t,r));u=gr(u,d+h),c+=d}}if(c){var m=Xo(u>>>0);if(!t.hasNameForId(this.componentId,m)){var v=r(c,".".concat(m),void 0,this.componentId);t.insertRules(this.componentId,m,v)}s=mr(s,m)}}return{className:s,css:typeof window>"u"?t.getTag().getGroup(Mn(this.componentId)):""}},n})(),Bc=wr?{Provider:function(n){return n.children},Consumer:function(n){return(0,n.children)(void 0)}}:C.default.createContext(void 0);Bc.Consumer;var _o={},Ol=new Set;function Hp(n,e,t){var r=qa(n),s=n,i=!So(n),o=e.attrs,a=o===void 0?fi:o,u=e.componentId,c=u===void 0?(function(N,_){var P=typeof N!="string"?"sc":El(N);_o[P]=(_o[P]||0)+1;var I="".concat(P,"-").concat(fp(di+P+_o[P]));return _?"".concat(_,"-").concat(I):I})(e.displayName,e.parentComponentId):u,h=e.displayName,g=h===void 0?(function(N){return So(N)?"styled.".concat(N):"Styled(".concat(Cc(N),")")})(n):h,d=e.displayName&&e.componentId?"".concat(El(e.displayName),"-").concat(e.componentId):e.componentId||c,m=r&&s.attrs?s.attrs.concat(a).filter(Boolean):a,v=e.shouldForwardProp;if(r&&s.shouldForwardProp){var p=s.shouldForwardProp;if(e.shouldForwardProp){var y=e.shouldForwardProp;v=function(N,_){return p(N,_)&&y(N,_)}}else v=p}var E=new Up(t,d,r?s.componentStyle:void 0);function S(N,_){return(function(P,I,te){var ue=P.attrs,ie=P.componentStyle,b=P.defaultProps,M=P.foldedComponentIds,A=P.styledComponentId,$=P.target,V=wr?void 0:C.default.useContext(Bc),R=Nl(),q=P.shouldForwardProp||R.shouldForwardProp;process.env.NODE_ENV!=="production"&&C.default.useDebugValue&&C.default.useDebugValue(A);var W=up(I,V,b)||nn,Y=(function(j,Z,G){for(var X,k=Te.__assign(Te.__assign({},Z),{className:void 0,theme:G}),ce=0;ce<j.length;ce+=1){var ge=sn(X=j[ce])?X(k):X;for(var be in ge)be==="className"?k.className=mr(k.className,ge[be]):be==="style"?k.style=Te.__assign(Te.__assign({},k.style),ge[be]):k[be]=ge[be]}return"className"in Z&&typeof Z.className=="string"&&(k.className=mr(k.className,Z.className)),k})(ue,I,W),T=Y.as||$,D={};for(var U in Y)Y[U]===void 0||U[0]==="$"||U==="as"||U==="theme"&&Y.theme===W||(U==="forwardedAs"?D.as=Y.forwardedAs:q&&!q(U,T)||(D[U]=Y[U],q||process.env.NODE_ENV!=="development"||$f(U)||Ol.has(U)||!Zo.has(T)||(Ol.add(U),console.warn('styled-components: it looks like an unknown prop "'.concat(U,'" is being sent through to the DOM, which will likely trigger a React console error. If you would like automatic filtering of unknown props, you can opt-into that behavior via `<StyleSheetManager shouldForwardProp={...}>` (connect an API like `@emotion/is-prop-valid`) or consider using transient props (`$` prefix for automatic filtering.)')))));var K=(function(j,Z){var G=Nl(),X=j.generateAndInjectStyles(Z,G.styleSheet,G.stylis);return process.env.NODE_ENV!=="production"&&C.default.useDebugValue&&C.default.useDebugValue(X.className),X})(ie,Y),z=K.className,H=K.css;process.env.NODE_ENV!=="production"&&P.warnTooManyClasses&&P.warnTooManyClasses(z);var Q=mr(M,A);z&&(Q+=" "+z),Y.className&&(Q+=" "+Y.className),D[So(T)&&!Zo.has(T)?"class":"className"]=Q,te&&(D.ref=te);var F=We.createElement(T,D);return wr&&H?C.default.createElement(C.default.Fragment,null,C.default.createElement("style",{precedence:"styled-components",href:"sc-".concat(A,"-").concat(z),children:H}),F):F})(x,N,_)}S.displayName=g;var x=C.default.forwardRef(S);return x.attrs=m,x.componentStyle=E,x.displayName=g,x.shouldForwardProp=v,x.foldedComponentIds=r?mr(s.foldedComponentIds,s.styledComponentId):"",x.styledComponentId=d,x.target=r?s.target:n,Object.defineProperty(x,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(N){this._foldedDefaultProps=r?(function(_){for(var P=[],I=1;I<arguments.length;I++)P[I-1]=arguments[I];for(var te=0,ue=P;te<ue.length;te++)Qo(_,ue[te],!0);return _})({},s.defaultProps,N):N}}),process.env.NODE_ENV!=="production"&&(lp(g,d),x.warnTooManyClasses=(function(N,_){var P={},I=!1;return function(te){if(!I&&(P[te]=!0,Object.keys(P).length>=200)){var ue=_?' with the id of "'.concat(_,'"'):"";console.warn("Over ".concat(200," classes were generated for component ").concat(N).concat(ue,`.
53
- `)+`Consider using the attrs method, together with a style object for frequently changed styles.
54
- Example:
55
- const Component = styled.div.attrs(props => ({
56
- style: {
57
- background: props.background,
58
- },
59
- }))\`width: 100%;\`
60
-
61
- <Component />`),I=!0,P={}}}})(g,d)),Fa(x,function(){return".".concat(x.styledComponentId)}),i&&Ic(x,n,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0}),x}function Ll(n,e){for(var t=[n[0]],r=0,s=e.length;r<s;r+=1)t.push(e[r],n[r+1]);return t}var Ml=function(n){return Object.assign(n,{isCss:!0})};function zp(n){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];if(sn(n)||on(n))return Ml(yr(Ll(fi,Te.__spreadArray([n],e,!0))));var r=n;return e.length===0&&r.length===1&&typeof r[0]=="string"?yr(r):Ml(yr(Ll(r,e)))}function ta(n,e,t){if(t===void 0&&(t=nn),!e)throw fn(1,e);var r=function(s){for(var i=[],o=1;o<arguments.length;o++)i[o-1]=arguments[o];return n(e,t,zp.apply(void 0,Te.__spreadArray([s],i,!1)))};return r.attrs=function(s){return ta(n,e,Te.__assign(Te.__assign({},t),{attrs:Array.prototype.concat(t.attrs,s).filter(Boolean)}))},r.withConfig=function(s){return ta(n,e,Te.__assign(Te.__assign({},t),s))},r}var qc=function(n){return ta(Hp,n)},ja=qc;Zo.forEach(function(n){ja[n]=qc(n)});process.env.NODE_ENV!=="production"&&typeof navigator<"u"&&navigator.product==="ReactNative"&&console.warn(`It looks like you've imported 'styled-components' on React Native.
62
- Perhaps you're looking to import 'styled-components/native'?
63
- Read more about this at https://www.styled-components.com/docs/basics#react-native`);var _s="__sc-".concat(Er,"__");process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&typeof window<"u"&&(window[_s]||(window[_s]=0),window[_s]===1&&console.warn(`It looks like there are several instances of 'styled-components' initialized in this application. This may cause dynamic styles to not render properly, errors during the rehydration process, a missing theme prop, and makes your application bigger without good reason.
64
-
65
- See https://styled-components.com/docs/faqs#why-am-i-getting-a-warning-about-several-instances-of-module-on-the-page for more info.`),window[_s]+=1);const Gp=ja.div`
66
- .filepond {
67
- &--drop-label {
68
- label {
69
- color: ${({$invalid:n})=>n?"var(--color-item-primary-destructive)":"inherit"} !important;
70
- }
71
- }
72
-
73
- &--root {
74
- margin-bottom: 0.5rem;
75
- border-radius: 0.75rem;
76
- }
77
-
78
- &--panel {
79
- border-radius: 0.8rem;
80
- overflow: hidden;
81
-
82
- &-root {
83
- background-color: transparent;
84
- }
85
- }
86
-
87
- &--drip {
88
- border: 1px solid
89
- ${({$invalid:n})=>n?"var(--color-item-primary-destructive)":"var(--color-border-alpha-strong)"};
90
- background-color: transparent;
91
- opacity: 1;
92
- outline-offset: 2px;
93
- border-radius: 0.75rem;
94
- }
95
- }
96
-
97
- &:focus-within {
98
- .filepond {
99
- &--drip {
100
- outline: 2px solid
101
- ${({$invalid:n})=>n?"var(--color-item-primary-destructive)":"var(--color-item-primary-primary)"};
102
- }
103
- }
104
- }
105
- `;function Fc({variant:n="default",...e}){return O.jsx(Gp,{$invalid:n==="failure",...e})}Fc.displayName="FilepondContainer";var Kp=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Wp=Kp.reduce((n,e)=>{const t=rc.createSlot(`Primitive.${e}`),r=C.forwardRef((s,i)=>{const{asChild:o,...a}=s,u=o?t:e;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),O.jsx(u,{...a,ref:i})});return r.displayName=`Primitive.${e}`,{...n,[e]:r}},{}),Yp="Label",jc=C.forwardRef((n,e)=>O.jsx(Wp.label,{...n,ref:e,onMouseDown:t=>{var s;t.target.closest("button, input, select, textarea")||((s=n.onMouseDown)==null||s.call(n,t),!t.defaultPrevented&&t.detail>1&&t.preventDefault())}}));jc.displayName=Yp;var $c=jc;const Zp=Oa.cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),$a=C.forwardRef(({className:n,...e},t)=>O.jsx($c,{ref:t,className:Ce.cn(Zp(),n),...e}));$a.displayName=$c.displayName;const Xp=Ra.FormProvider,Vc=C.createContext({}),Qp=({...n})=>O.jsx(Vc.Provider,{value:{name:n.name},children:O.jsx(Ra.Controller,{...n})}),Jn=()=>{const n=C.useContext(Vc),e=C.useContext(Uc),{getFieldState:t,formState:r}=Ra.useFormContext(),s=t(n.name,r);if(!n)throw new Error("useFormField should be used within <FormField>");const{id:i}=e;return{id:i,name:n.name,formItemId:`${i}-form-item`,formDescriptionId:`${i}-form-item-description`,formMessageId:`${i}-form-item-message`,...s}},Uc=C.createContext({}),Hc=C.forwardRef(({className:n,...e},t)=>{const r=C.useId();return O.jsx(Uc.Provider,{value:{id:r},children:O.jsx("div",{ref:t,className:Ce.cn("relative space-y-3",n),...e})})});Hc.displayName="FormItem";const zc=C.forwardRef(({className:n,...e},t)=>{const{error:r,formItemId:s}=Jn();return O.jsx($a,{ref:t,className:Ce.cn("!text-body-xs-medium",n,r&&"text-destructive"),htmlFor:s,...e})});zc.displayName="FormLabel";const Gc=C.forwardRef(({...n},e)=>{const{error:t,formItemId:r,formDescriptionId:s,formMessageId:i}=Jn();return O.jsx(rc.Slot,{ref:e,id:r,"aria-describedby":t?`${s} ${i}`:`${s}`,"aria-invalid":!!t,...n})});Gc.displayName="FormControl";const Kc=C.forwardRef(({className:n,...e},t)=>{const{formDescriptionId:r}=Jn();return O.jsx("p",{ref:t,id:r,className:Ce.cn("text-muted-foreground text-sm",n),...e})});Kc.displayName="FormDescription";const Wc=C.forwardRef(({className:n,children:e,...t},r)=>{const{error:s,formMessageId:i}=Jn(),o=s?String(s==null?void 0:s.message):e;return o?O.jsx("p",{ref:r,id:i,className:Ce.cn("!text-body-xs-medium text-destructive",n),...t,children:o}):null});Wc.displayName="FormMessage";var Yc=typeof global=="object"&&global&&global.Object===Object&&global,Jp=typeof self=="object"&&self&&self.Object===Object&&self,Tt=Yc||Jp||Function("return this")(),nr=Tt.Symbol,Zc=Object.prototype,eg=Zc.hasOwnProperty,tg=Zc.toString,Rn=nr?nr.toStringTag:void 0;function rg(n){var e=eg.call(n,Rn),t=n[Rn];try{n[Rn]=void 0;var r=!0}catch{}var s=tg.call(n);return r&&(e?n[Rn]=t:delete n[Rn]),s}var ng=Object.prototype,sg=ng.toString;function ig(n){return sg.call(n)}var og="[object Null]",ag="[object Undefined]",Dl=nr?nr.toStringTag:void 0;function pn(n){return n==null?n===void 0?ag:og:Dl&&Dl in Object(n)?rg(n):ig(n)}function Pt(n){return n!=null&&typeof n=="object"}var xr=Array.isArray;function sr(n){var e=typeof n;return n!=null&&(e=="object"||e=="function")}function Xc(n){return n}var lg="[object AsyncFunction]",ug="[object Function]",cg="[object GeneratorFunction]",hg="[object Proxy]";function Va(n){if(!sr(n))return!1;var e=pn(n);return e==ug||e==cg||e==lg||e==hg}var Ao=Tt["__core-js_shared__"],Pl=(function(){var n=/[^.]+$/.exec(Ao&&Ao.keys&&Ao.keys.IE_PROTO||"");return n?"Symbol(src)_1."+n:""})();function dg(n){return!!Pl&&Pl in n}var fg=Function.prototype,pg=fg.toString;function Tr(n){if(n!=null){try{return pg.call(n)}catch{}try{return n+""}catch{}}return""}var gg=/[\\^$.*+?()[\]{}|]/g,mg=/^\[object .+?Constructor\]$/,vg=Function.prototype,yg=Object.prototype,bg=vg.toString,Eg=yg.hasOwnProperty,wg=RegExp("^"+bg.call(Eg).replace(gg,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function xg(n){if(!sr(n)||dg(n))return!1;var e=Va(n)?wg:mg;return e.test(Tr(n))}function Sg(n,e){return n==null?void 0:n[e]}function kr(n,e){var t=Sg(n,e);return xg(t)?t:void 0}var ra=kr(Tt,"WeakMap"),Bl=Object.create,_g=(function(){function n(){}return function(e){if(!sr(e))return{};if(Bl)return Bl(e);n.prototype=e;var t=new n;return n.prototype=void 0,t}})();function Ag(n,e,t){switch(t.length){case 0:return n.call(e);case 1:return n.call(e,t[0]);case 2:return n.call(e,t[0],t[1]);case 3:return n.call(e,t[0],t[1],t[2])}return n.apply(e,t)}function Cg(n,e){var t=-1,r=n.length;for(e||(e=Array(r));++t<r;)e[t]=n[t];return e}var Tg=800,kg=16,Ng=Date.now;function Ig(n){var e=0,t=0;return function(){var r=Ng(),s=kg-(r-t);if(t=r,s>0){if(++e>=Tg)return arguments[0]}else e=0;return n.apply(void 0,arguments)}}function Rg(n){return function(){return n}}var Qs=(function(){try{var n=kr(Object,"defineProperty");return n({},"",{}),n}catch{}})(),Og=Qs?function(n,e){return Qs(n,"toString",{configurable:!0,enumerable:!1,value:Rg(e),writable:!0})}:Xc,Lg=Ig(Og);function Mg(n,e){for(var t=-1,r=n==null?0:n.length;++t<r&&e(n[t],t,n)!==!1;);return n}var Dg=9007199254740991,Pg=/^(?:0|[1-9]\d*)$/;function Qc(n,e){var t=typeof n;return e=e??Dg,!!e&&(t=="number"||t!="symbol"&&Pg.test(n))&&n>-1&&n%1==0&&n<e}function Ua(n,e,t){e=="__proto__"&&Qs?Qs(n,e,{configurable:!0,enumerable:!0,value:t,writable:!0}):n[e]=t}function es(n,e){return n===e||n!==n&&e!==e}var Bg=Object.prototype,qg=Bg.hasOwnProperty;function Jc(n,e,t){var r=n[e];(!(qg.call(n,e)&&es(r,t))||t===void 0&&!(e in n))&&Ua(n,e,t)}function Fg(n,e,t,r){var s=!t;t||(t={});for(var i=-1,o=e.length;++i<o;){var a=e[i],u=void 0;u===void 0&&(u=n[a]),s?Ua(t,a,u):Jc(t,a,u)}return t}var ql=Math.max;function jg(n,e,t){return e=ql(e===void 0?n.length-1:e,0),function(){for(var r=arguments,s=-1,i=ql(r.length-e,0),o=Array(i);++s<i;)o[s]=r[e+s];s=-1;for(var a=Array(e+1);++s<e;)a[s]=r[s];return a[e]=t(o),Ag(n,this,a)}}function $g(n,e){return Lg(jg(n,e,Xc),n+"")}var Vg=9007199254740991;function eh(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=Vg}function pi(n){return n!=null&&eh(n.length)&&!Va(n)}function Ug(n,e,t){if(!sr(t))return!1;var r=typeof e;return(r=="number"?pi(t)&&Qc(e,t.length):r=="string"&&e in t)?es(t[e],n):!1}function Hg(n){return $g(function(e,t){var r=-1,s=t.length,i=s>1?t[s-1]:void 0,o=s>2?t[2]:void 0;for(i=n.length>3&&typeof i=="function"?(s--,i):void 0,o&&Ug(t[0],t[1],o)&&(i=s<3?void 0:i,s=1),e=Object(e);++r<s;){var a=t[r];a&&n(e,a,r,i)}return e})}var zg=Object.prototype;function Ha(n){var e=n&&n.constructor,t=typeof e=="function"&&e.prototype||zg;return n===t}function Gg(n,e){for(var t=-1,r=Array(n);++t<n;)r[t]=e(t);return r}var Kg="[object Arguments]";function Fl(n){return Pt(n)&&pn(n)==Kg}var th=Object.prototype,Wg=th.hasOwnProperty,Yg=th.propertyIsEnumerable,na=Fl((function(){return arguments})())?Fl:function(n){return Pt(n)&&Wg.call(n,"callee")&&!Yg.call(n,"callee")};function Zg(){return!1}var rh=typeof exports=="object"&&exports&&!exports.nodeType&&exports,jl=rh&&typeof module=="object"&&module&&!module.nodeType&&module,Xg=jl&&jl.exports===rh,$l=Xg?Tt.Buffer:void 0,Qg=$l?$l.isBuffer:void 0,zn=Qg||Zg,Jg="[object Arguments]",em="[object Array]",tm="[object Boolean]",rm="[object Date]",nm="[object Error]",sm="[object Function]",im="[object Map]",om="[object Number]",am="[object Object]",lm="[object RegExp]",um="[object Set]",cm="[object String]",hm="[object WeakMap]",dm="[object ArrayBuffer]",fm="[object DataView]",pm="[object Float32Array]",gm="[object Float64Array]",mm="[object Int8Array]",vm="[object Int16Array]",ym="[object Int32Array]",bm="[object Uint8Array]",Em="[object Uint8ClampedArray]",wm="[object Uint16Array]",xm="[object Uint32Array]",Ae={};Ae[pm]=Ae[gm]=Ae[mm]=Ae[vm]=Ae[ym]=Ae[bm]=Ae[Em]=Ae[wm]=Ae[xm]=!0;Ae[Jg]=Ae[em]=Ae[dm]=Ae[tm]=Ae[fm]=Ae[rm]=Ae[nm]=Ae[sm]=Ae[im]=Ae[om]=Ae[am]=Ae[lm]=Ae[um]=Ae[cm]=Ae[hm]=!1;function Sm(n){return Pt(n)&&eh(n.length)&&!!Ae[pn(n)]}function za(n){return function(e){return n(e)}}var nh=typeof exports=="object"&&exports&&!exports.nodeType&&exports,jn=nh&&typeof module=="object"&&module&&!module.nodeType&&module,_m=jn&&jn.exports===nh,Co=_m&&Yc.process,an=(function(){try{var n=jn&&jn.require&&jn.require("util").types;return n||Co&&Co.binding&&Co.binding("util")}catch{}})(),Vl=an&&an.isTypedArray,Ga=Vl?za(Vl):Sm,Am=Object.prototype,Cm=Am.hasOwnProperty;function sh(n,e){var t=xr(n),r=!t&&na(n),s=!t&&!r&&zn(n),i=!t&&!r&&!s&&Ga(n),o=t||r||s||i,a=o?Gg(n.length,String):[],u=a.length;for(var c in n)(e||Cm.call(n,c))&&!(o&&(c=="length"||s&&(c=="offset"||c=="parent")||i&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Qc(c,u)))&&a.push(c);return a}function ih(n,e){return function(t){return n(e(t))}}var Tm=ih(Object.keys,Object),km=Object.prototype,Nm=km.hasOwnProperty;function Im(n){if(!Ha(n))return Tm(n);var e=[];for(var t in Object(n))Nm.call(n,t)&&t!="constructor"&&e.push(t);return e}function Rm(n){return pi(n)?sh(n):Im(n)}function Om(n){var e=[];if(n!=null)for(var t in Object(n))e.push(t);return e}var Lm=Object.prototype,Mm=Lm.hasOwnProperty;function Dm(n){if(!sr(n))return Om(n);var e=Ha(n),t=[];for(var r in n)r=="constructor"&&(e||!Mm.call(n,r))||t.push(r);return t}function oh(n){return pi(n)?sh(n,!0):Dm(n)}var Gn=kr(Object,"create");function Pm(){this.__data__=Gn?Gn(null):{},this.size=0}function Bm(n){var e=this.has(n)&&delete this.__data__[n];return this.size-=e?1:0,e}var qm="__lodash_hash_undefined__",Fm=Object.prototype,jm=Fm.hasOwnProperty;function $m(n){var e=this.__data__;if(Gn){var t=e[n];return t===qm?void 0:t}return jm.call(e,n)?e[n]:void 0}var Vm=Object.prototype,Um=Vm.hasOwnProperty;function Hm(n){var e=this.__data__;return Gn?e[n]!==void 0:Um.call(e,n)}var zm="__lodash_hash_undefined__";function Gm(n,e){var t=this.__data__;return this.size+=this.has(n)?0:1,t[n]=Gn&&e===void 0?zm:e,this}function Sr(n){var e=-1,t=n==null?0:n.length;for(this.clear();++e<t;){var r=n[e];this.set(r[0],r[1])}}Sr.prototype.clear=Pm;Sr.prototype.delete=Bm;Sr.prototype.get=$m;Sr.prototype.has=Hm;Sr.prototype.set=Gm;function Km(){this.__data__=[],this.size=0}function gi(n,e){for(var t=n.length;t--;)if(es(n[t][0],e))return t;return-1}var Wm=Array.prototype,Ym=Wm.splice;function Zm(n){var e=this.__data__,t=gi(e,n);if(t<0)return!1;var r=e.length-1;return t==r?e.pop():Ym.call(e,t,1),--this.size,!0}function Xm(n){var e=this.__data__,t=gi(e,n);return t<0?void 0:e[t][1]}function Qm(n){return gi(this.__data__,n)>-1}function Jm(n,e){var t=this.__data__,r=gi(t,n);return r<0?(++this.size,t.push([n,e])):t[r][1]=e,this}function $t(n){var e=-1,t=n==null?0:n.length;for(this.clear();++e<t;){var r=n[e];this.set(r[0],r[1])}}$t.prototype.clear=Km;$t.prototype.delete=Zm;$t.prototype.get=Xm;$t.prototype.has=Qm;$t.prototype.set=Jm;var Kn=kr(Tt,"Map");function e0(){this.size=0,this.__data__={hash:new Sr,map:new(Kn||$t),string:new Sr}}function t0(n){var e=typeof n;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?n!=="__proto__":n===null}function mi(n,e){var t=n.__data__;return t0(e)?t[typeof e=="string"?"string":"hash"]:t.map}function r0(n){var e=mi(this,n).delete(n);return this.size-=e?1:0,e}function n0(n){return mi(this,n).get(n)}function s0(n){return mi(this,n).has(n)}function i0(n,e){var t=mi(this,n),r=t.size;return t.set(n,e),this.size+=t.size==r?0:1,this}function Nr(n){var e=-1,t=n==null?0:n.length;for(this.clear();++e<t;){var r=n[e];this.set(r[0],r[1])}}Nr.prototype.clear=e0;Nr.prototype.delete=r0;Nr.prototype.get=n0;Nr.prototype.has=s0;Nr.prototype.set=i0;function o0(n,e){for(var t=-1,r=e.length,s=n.length;++t<r;)n[s+t]=e[t];return n}var ah=ih(Object.getPrototypeOf,Object),a0="[object Object]",l0=Function.prototype,u0=Object.prototype,lh=l0.toString,c0=u0.hasOwnProperty,h0=lh.call(Object);function d0(n){if(!Pt(n)||pn(n)!=a0)return!1;var e=ah(n);if(e===null)return!0;var t=c0.call(e,"constructor")&&e.constructor;return typeof t=="function"&&t instanceof t&&lh.call(t)==h0}function f0(){this.__data__=new $t,this.size=0}function p0(n){var e=this.__data__,t=e.delete(n);return this.size=e.size,t}function g0(n){return this.__data__.get(n)}function m0(n){return this.__data__.has(n)}var v0=200;function y0(n,e){var t=this.__data__;if(t instanceof $t){var r=t.__data__;if(!Kn||r.length<v0-1)return r.push([n,e]),this.size=++t.size,this;t=this.__data__=new Nr(r)}return t.set(n,e),this.size=t.size,this}function St(n){var e=this.__data__=new $t(n);this.size=e.size}St.prototype.clear=f0;St.prototype.delete=p0;St.prototype.get=g0;St.prototype.has=m0;St.prototype.set=y0;var uh=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Ul=uh&&typeof module=="object"&&module&&!module.nodeType&&module,b0=Ul&&Ul.exports===uh,Hl=b0?Tt.Buffer:void 0,zl=Hl?Hl.allocUnsafe:void 0;function ch(n,e){if(e)return n.slice();var t=n.length,r=zl?zl(t):new n.constructor(t);return n.copy(r),r}function E0(n,e){for(var t=-1,r=n==null?0:n.length,s=0,i=[];++t<r;){var o=n[t];e(o,t,n)&&(i[s++]=o)}return i}function w0(){return[]}var x0=Object.prototype,S0=x0.propertyIsEnumerable,Gl=Object.getOwnPropertySymbols,_0=Gl?function(n){return n==null?[]:(n=Object(n),E0(Gl(n),function(e){return S0.call(n,e)}))}:w0;function A0(n,e,t){var r=e(n);return xr(n)?r:o0(r,t(n))}function sa(n){return A0(n,Rm,_0)}var ia=kr(Tt,"DataView"),oa=kr(Tt,"Promise"),aa=kr(Tt,"Set"),Kl="[object Map]",C0="[object Object]",Wl="[object Promise]",Yl="[object Set]",Zl="[object WeakMap]",Xl="[object DataView]",T0=Tr(ia),k0=Tr(Kn),N0=Tr(oa),I0=Tr(aa),R0=Tr(ra),ut=pn;(ia&&ut(new ia(new ArrayBuffer(1)))!=Xl||Kn&&ut(new Kn)!=Kl||oa&&ut(oa.resolve())!=Wl||aa&&ut(new aa)!=Yl||ra&&ut(new ra)!=Zl)&&(ut=function(n){var e=pn(n),t=e==C0?n.constructor:void 0,r=t?Tr(t):"";if(r)switch(r){case T0:return Xl;case k0:return Kl;case N0:return Wl;case I0:return Yl;case R0:return Zl}return e});var O0=Object.prototype,L0=O0.hasOwnProperty;function M0(n){var e=n.length,t=new n.constructor(e);return e&&typeof n[0]=="string"&&L0.call(n,"index")&&(t.index=n.index,t.input=n.input),t}var Js=Tt.Uint8Array;function Ka(n){var e=new n.constructor(n.byteLength);return new Js(e).set(new Js(n)),e}function D0(n,e){var t=Ka(n.buffer);return new n.constructor(t,n.byteOffset,n.byteLength)}var P0=/\w*$/;function B0(n){var e=new n.constructor(n.source,P0.exec(n));return e.lastIndex=n.lastIndex,e}var Ql=nr?nr.prototype:void 0,Jl=Ql?Ql.valueOf:void 0;function q0(n){return Jl?Object(Jl.call(n)):{}}function hh(n,e){var t=e?Ka(n.buffer):n.buffer;return new n.constructor(t,n.byteOffset,n.length)}var F0="[object Boolean]",j0="[object Date]",$0="[object Map]",V0="[object Number]",U0="[object RegExp]",H0="[object Set]",z0="[object String]",G0="[object Symbol]",K0="[object ArrayBuffer]",W0="[object DataView]",Y0="[object Float32Array]",Z0="[object Float64Array]",X0="[object Int8Array]",Q0="[object Int16Array]",J0="[object Int32Array]",e1="[object Uint8Array]",t1="[object Uint8ClampedArray]",r1="[object Uint16Array]",n1="[object Uint32Array]";function s1(n,e,t){var r=n.constructor;switch(e){case K0:return Ka(n);case F0:case j0:return new r(+n);case W0:return D0(n);case Y0:case Z0:case X0:case Q0:case J0:case e1:case t1:case r1:case n1:return hh(n,t);case $0:return new r;case V0:case z0:return new r(n);case U0:return B0(n);case H0:return new r;case G0:return q0(n)}}function dh(n){return typeof n.constructor=="function"&&!Ha(n)?_g(ah(n)):{}}var i1="[object Map]";function o1(n){return Pt(n)&&ut(n)==i1}var eu=an&&an.isMap,a1=eu?za(eu):o1,l1="[object Set]";function u1(n){return Pt(n)&&ut(n)==l1}var tu=an&&an.isSet,c1=tu?za(tu):u1,h1=1,fh="[object Arguments]",d1="[object Array]",f1="[object Boolean]",p1="[object Date]",g1="[object Error]",ph="[object Function]",m1="[object GeneratorFunction]",v1="[object Map]",y1="[object Number]",gh="[object Object]",b1="[object RegExp]",E1="[object Set]",w1="[object String]",x1="[object Symbol]",S1="[object WeakMap]",_1="[object ArrayBuffer]",A1="[object DataView]",C1="[object Float32Array]",T1="[object Float64Array]",k1="[object Int8Array]",N1="[object Int16Array]",I1="[object Int32Array]",R1="[object Uint8Array]",O1="[object Uint8ClampedArray]",L1="[object Uint16Array]",M1="[object Uint32Array]",Se={};Se[fh]=Se[d1]=Se[_1]=Se[A1]=Se[f1]=Se[p1]=Se[C1]=Se[T1]=Se[k1]=Se[N1]=Se[I1]=Se[v1]=Se[y1]=Se[gh]=Se[b1]=Se[E1]=Se[w1]=Se[x1]=Se[R1]=Se[O1]=Se[L1]=Se[M1]=!0;Se[g1]=Se[ph]=Se[S1]=!1;function Vs(n,e,t,r,s,i){var o,a=e&h1;if(o!==void 0)return o;if(!sr(n))return n;var u=xr(n);if(u)o=M0(n);else{var c=ut(n),h=c==ph||c==m1;if(zn(n))return ch(n,a);if(c==gh||c==fh||h&&!s)o=h?{}:dh(n);else{if(!Se[c])return s?n:{};o=s1(n,c,a)}}i||(i=new St);var g=i.get(n);if(g)return g;i.set(n,o),c1(n)?n.forEach(function(v){o.add(Vs(v,e,t,v,n,i))}):a1(n)&&n.forEach(function(v,p){o.set(p,Vs(v,e,t,p,n,i))});var d=sa,m=u?void 0:d(n);return Mg(m||n,function(v,p){m&&(p=v,v=n[p]),Jc(o,p,Vs(v,e,t,p,n,i))}),o}var D1=1,P1=4;function Jr(n){return Vs(n,D1|P1)}var B1="__lodash_hash_undefined__";function q1(n){return this.__data__.set(n,B1),this}function F1(n){return this.__data__.has(n)}function ei(n){var e=-1,t=n==null?0:n.length;for(this.__data__=new Nr;++e<t;)this.add(n[e])}ei.prototype.add=ei.prototype.push=q1;ei.prototype.has=F1;function j1(n,e){for(var t=-1,r=n==null?0:n.length;++t<r;)if(e(n[t],t,n))return!0;return!1}function $1(n,e){return n.has(e)}var V1=1,U1=2;function mh(n,e,t,r,s,i){var o=t&V1,a=n.length,u=e.length;if(a!=u&&!(o&&u>a))return!1;var c=i.get(n),h=i.get(e);if(c&&h)return c==e&&h==n;var g=-1,d=!0,m=t&U1?new ei:void 0;for(i.set(n,e),i.set(e,n);++g<a;){var v=n[g],p=e[g];if(r)var y=o?r(p,v,g,e,n,i):r(v,p,g,n,e,i);if(y!==void 0){if(y)continue;d=!1;break}if(m){if(!j1(e,function(E,S){if(!$1(m,S)&&(v===E||s(v,E,t,r,i)))return m.push(S)})){d=!1;break}}else if(!(v===p||s(v,p,t,r,i))){d=!1;break}}return i.delete(n),i.delete(e),d}function H1(n){var e=-1,t=Array(n.size);return n.forEach(function(r,s){t[++e]=[s,r]}),t}function z1(n){var e=-1,t=Array(n.size);return n.forEach(function(r){t[++e]=r}),t}var G1=1,K1=2,W1="[object Boolean]",Y1="[object Date]",Z1="[object Error]",X1="[object Map]",Q1="[object Number]",J1="[object RegExp]",ev="[object Set]",tv="[object String]",rv="[object Symbol]",nv="[object ArrayBuffer]",sv="[object DataView]",ru=nr?nr.prototype:void 0,To=ru?ru.valueOf:void 0;function iv(n,e,t,r,s,i,o){switch(t){case sv:if(n.byteLength!=e.byteLength||n.byteOffset!=e.byteOffset)return!1;n=n.buffer,e=e.buffer;case nv:return!(n.byteLength!=e.byteLength||!i(new Js(n),new Js(e)));case W1:case Y1:case Q1:return es(+n,+e);case Z1:return n.name==e.name&&n.message==e.message;case J1:case tv:return n==e+"";case X1:var a=H1;case ev:var u=r&G1;if(a||(a=z1),n.size!=e.size&&!u)return!1;var c=o.get(n);if(c)return c==e;r|=K1,o.set(n,e);var h=mh(a(n),a(e),r,s,i,o);return o.delete(n),h;case rv:if(To)return To.call(n)==To.call(e)}return!1}var ov=1,av=Object.prototype,lv=av.hasOwnProperty;function uv(n,e,t,r,s,i){var o=t&ov,a=sa(n),u=a.length,c=sa(e),h=c.length;if(u!=h&&!o)return!1;for(var g=u;g--;){var d=a[g];if(!(o?d in e:lv.call(e,d)))return!1}var m=i.get(n),v=i.get(e);if(m&&v)return m==e&&v==n;var p=!0;i.set(n,e),i.set(e,n);for(var y=o;++g<u;){d=a[g];var E=n[d],S=e[d];if(r)var x=o?r(S,E,d,e,n,i):r(E,S,d,n,e,i);if(!(x===void 0?E===S||s(E,S,t,r,i):x)){p=!1;break}y||(y=d=="constructor")}if(p&&!y){var N=n.constructor,_=e.constructor;N!=_&&"constructor"in n&&"constructor"in e&&!(typeof N=="function"&&N instanceof N&&typeof _=="function"&&_ instanceof _)&&(p=!1)}return i.delete(n),i.delete(e),p}var cv=1,nu="[object Arguments]",su="[object Array]",As="[object Object]",hv=Object.prototype,iu=hv.hasOwnProperty;function dv(n,e,t,r,s,i){var o=xr(n),a=xr(e),u=o?su:ut(n),c=a?su:ut(e);u=u==nu?As:u,c=c==nu?As:c;var h=u==As,g=c==As,d=u==c;if(d&&zn(n)){if(!zn(e))return!1;o=!0,h=!1}if(d&&!h)return i||(i=new St),o||Ga(n)?mh(n,e,t,r,s,i):iv(n,e,u,t,r,s,i);if(!(t&cv)){var m=h&&iu.call(n,"__wrapped__"),v=g&&iu.call(e,"__wrapped__");if(m||v){var p=m?n.value():n,y=v?e.value():e;return i||(i=new St),s(p,y,t,r,i)}}return d?(i||(i=new St),uv(n,e,t,r,s,i)):!1}function vh(n,e,t,r,s){return n===e?!0:n==null||e==null||!Pt(n)&&!Pt(e)?n!==n&&e!==e:dv(n,e,t,r,vh,s)}function fv(n){return function(e,t,r){for(var s=-1,i=Object(e),o=r(e),a=o.length;a--;){var u=o[++s];if(t(i[u],u,i)===!1)break}return e}}var pv=fv();function la(n,e,t){(t!==void 0&&!es(n[e],t)||t===void 0&&!(e in n))&&Ua(n,e,t)}function gv(n){return Pt(n)&&pi(n)}function ua(n,e){if(!(e==="constructor"&&typeof n[e]=="function")&&e!="__proto__")return n[e]}function mv(n){return Fg(n,oh(n))}function vv(n,e,t,r,s,i,o){var a=ua(n,t),u=ua(e,t),c=o.get(u);if(c){la(n,t,c);return}var h=i?i(a,u,t+"",n,e,o):void 0,g=h===void 0;if(g){var d=xr(u),m=!d&&zn(u),v=!d&&!m&&Ga(u);h=u,d||m||v?xr(a)?h=a:gv(a)?h=Cg(a):m?(g=!1,h=ch(u,!0)):v?(g=!1,h=hh(u,!0)):h=[]:d0(u)||na(u)?(h=a,na(a)?h=mv(a):(!sr(a)||Va(a))&&(h=dh(u))):g=!1}g&&(o.set(u,h),s(h,u,r,i,o),o.delete(u)),la(n,t,h)}function yh(n,e,t,r,s){n!==e&&pv(e,function(i,o){if(s||(s=new St),sr(i))vv(n,e,o,t,yh,r,s);else{var a=r?r(ua(n,o),i,o+"",n,e,s):void 0;a===void 0&&(a=i),la(n,o,a)}},oh)}function Wt(n,e){return vh(n,e)}var er=Hg(function(n,e,t){yh(n,e,t)}),ne=(n=>(n[n.TYPE=3]="TYPE",n[n.LEVEL=12]="LEVEL",n[n.ATTRIBUTE=13]="ATTRIBUTE",n[n.BLOT=14]="BLOT",n[n.INLINE=7]="INLINE",n[n.BLOCK=11]="BLOCK",n[n.BLOCK_BLOT=10]="BLOCK_BLOT",n[n.INLINE_BLOT=6]="INLINE_BLOT",n[n.BLOCK_ATTRIBUTE=9]="BLOCK_ATTRIBUTE",n[n.INLINE_ATTRIBUTE=5]="INLINE_ATTRIBUTE",n[n.ANY=15]="ANY",n))(ne||{});class At{constructor(e,t,r={}){this.attrName=e,this.keyName=t;const s=ne.TYPE&ne.ATTRIBUTE;this.scope=r.scope!=null?r.scope&ne.LEVEL|s:ne.ATTRIBUTE,r.whitelist!=null&&(this.whitelist=r.whitelist)}static keys(e){return Array.from(e.attributes).map(t=>t.name)}add(e,t){return this.canAdd(e,t)?(e.setAttribute(this.keyName,t),!0):!1}canAdd(e,t){return this.whitelist==null?!0:typeof t=="string"?this.whitelist.indexOf(t.replace(/["']/g,""))>-1:this.whitelist.indexOf(t)>-1}remove(e){e.removeAttribute(this.keyName)}value(e){const t=e.getAttribute(this.keyName);return this.canAdd(e,t)&&t?t:""}}class en extends Error{constructor(e){e="[Parchment] "+e,super(e),this.message=e,this.name=this.constructor.name}}const bh=class ca{constructor(){this.attributes={},this.classes={},this.tags={},this.types={}}static find(e,t=!1){if(e==null)return null;if(this.blots.has(e))return this.blots.get(e)||null;if(t){let r=null;try{r=e.parentNode}catch{return null}return this.find(r,t)}return null}create(e,t,r){const s=this.query(t);if(s==null)throw new en(`Unable to create ${t} blot`);const i=s,o=t instanceof Node||t.nodeType===Node.TEXT_NODE?t:i.create(r),a=new i(e,o,r);return ca.blots.set(a.domNode,a),a}find(e,t=!1){return ca.find(e,t)}query(e,t=ne.ANY){let r;return typeof e=="string"?r=this.types[e]||this.attributes[e]:e instanceof Text||e.nodeType===Node.TEXT_NODE?r=this.types.text:typeof e=="number"?e&ne.LEVEL&ne.BLOCK?r=this.types.block:e&ne.LEVEL&ne.INLINE&&(r=this.types.inline):e instanceof Element&&((e.getAttribute("class")||"").split(/\s+/).some(s=>(r=this.classes[s],!!r)),r=r||this.tags[e.tagName]),r==null?null:"scope"in r&&t&ne.LEVEL&r.scope&&t&ne.TYPE&r.scope?r:null}register(...e){return e.map(t=>{const r="blotName"in t,s="attrName"in t;if(!r&&!s)throw new en("Invalid definition");if(r&&t.blotName==="abstract")throw new en("Cannot register abstract class");const i=r?t.blotName:s?t.attrName:void 0;return this.types[i]=t,s?typeof t.keyName=="string"&&(this.attributes[t.keyName]=t):r&&(t.className&&(this.classes[t.className]=t),t.tagName&&(Array.isArray(t.tagName)?t.tagName=t.tagName.map(o=>o.toUpperCase()):t.tagName=t.tagName.toUpperCase(),(Array.isArray(t.tagName)?t.tagName:[t.tagName]).forEach(o=>{(this.tags[o]==null||t.className==null)&&(this.tags[o]=t)}))),t})}};bh.blots=new WeakMap;let ln=bh;function ou(n,e){return(n.getAttribute("class")||"").split(/\s+/).filter(t=>t.indexOf(`${e}-`)===0)}class yv extends At{static keys(e){return(e.getAttribute("class")||"").split(/\s+/).map(t=>t.split("-").slice(0,-1).join("-"))}add(e,t){return this.canAdd(e,t)?(this.remove(e),e.classList.add(`${this.keyName}-${t}`),!0):!1}remove(e){ou(e,this.keyName).forEach(t=>{e.classList.remove(t)}),e.classList.length===0&&e.removeAttribute("class")}value(e){const t=(ou(e,this.keyName)[0]||"").slice(this.keyName.length+1);return this.canAdd(e,t)?t:""}}const pt=yv;function ko(n){const e=n.split("-"),t=e.slice(1).map(r=>r[0].toUpperCase()+r.slice(1)).join("");return e[0]+t}class bv extends At{static keys(e){return(e.getAttribute("style")||"").split(";").map(t=>t.split(":")[0].trim())}add(e,t){return this.canAdd(e,t)?(e.style[ko(this.keyName)]=t,!0):!1}remove(e){e.style[ko(this.keyName)]="",e.getAttribute("style")||e.removeAttribute("style")}value(e){const t=e.style[ko(this.keyName)];return this.canAdd(e,t)?t:""}}const ir=bv;class Ev{constructor(e){this.attributes={},this.domNode=e,this.build()}attribute(e,t){t?e.add(this.domNode,t)&&(e.value(this.domNode)!=null?this.attributes[e.attrName]=e:delete this.attributes[e.attrName]):(e.remove(this.domNode),delete this.attributes[e.attrName])}build(){this.attributes={};const e=ln.find(this.domNode);if(e==null)return;const t=At.keys(this.domNode),r=pt.keys(this.domNode),s=ir.keys(this.domNode);t.concat(r).concat(s).forEach(i=>{const o=e.scroll.query(i,ne.ATTRIBUTE);o instanceof At&&(this.attributes[o.attrName]=o)})}copy(e){Object.keys(this.attributes).forEach(t=>{const r=this.attributes[t].value(this.domNode);e.format(t,r)})}move(e){this.copy(e),Object.keys(this.attributes).forEach(t=>{this.attributes[t].remove(this.domNode)}),this.attributes={}}values(){return Object.keys(this.attributes).reduce((e,t)=>(e[t]=this.attributes[t].value(this.domNode),e),{})}}const vi=Ev,Eh=class{constructor(e,t){this.scroll=e,this.domNode=t,ln.blots.set(t,this),this.prev=null,this.next=null}static create(e){if(this.tagName==null)throw new en("Blot definition missing tagName");let t,r;return Array.isArray(this.tagName)?(typeof e=="string"?(r=e.toUpperCase(),parseInt(r,10).toString()===r&&(r=parseInt(r,10))):typeof e=="number"&&(r=e),typeof r=="number"?t=document.createElement(this.tagName[r-1]):r&&this.tagName.indexOf(r)>-1?t=document.createElement(r):t=document.createElement(this.tagName[0])):t=document.createElement(this.tagName),this.className&&t.classList.add(this.className),t}get statics(){return this.constructor}attach(){}clone(){const e=this.domNode.cloneNode(!1);return this.scroll.create(e)}detach(){this.parent!=null&&this.parent.removeChild(this),ln.blots.delete(this.domNode)}deleteAt(e,t){this.isolate(e,t).remove()}formatAt(e,t,r,s){const i=this.isolate(e,t);if(this.scroll.query(r,ne.BLOT)!=null&&s)i.wrap(r,s);else if(this.scroll.query(r,ne.ATTRIBUTE)!=null){const o=this.scroll.create(this.statics.scope);i.wrap(o),o.format(r,s)}}insertAt(e,t,r){const s=r==null?this.scroll.create("text",t):this.scroll.create(t,r),i=this.split(e);this.parent.insertBefore(s,i||void 0)}isolate(e,t){const r=this.split(e);if(r==null)throw new Error("Attempt to isolate at end");return r.split(t),r}length(){return 1}offset(e=this.parent){return this.parent==null||this===e?0:this.parent.children.offset(this)+this.parent.offset(e)}optimize(e){this.statics.requiredContainer&&!(this.parent instanceof this.statics.requiredContainer)&&this.wrap(this.statics.requiredContainer.blotName)}remove(){this.domNode.parentNode!=null&&this.domNode.parentNode.removeChild(this.domNode),this.detach()}replaceWith(e,t){const r=typeof e=="string"?this.scroll.create(e,t):e;return this.parent!=null&&(this.parent.insertBefore(r,this.next||void 0),this.remove()),r}split(e,t){return e===0?this:this.next}update(e,t){}wrap(e,t){const r=typeof e=="string"?this.scroll.create(e,t):e;if(this.parent!=null&&this.parent.insertBefore(r,this.next||void 0),typeof r.appendChild!="function")throw new en(`Cannot wrap ${e}`);return r.appendChild(this),r}};Eh.blotName="abstract";let wh=Eh;const xh=class extends wh{static value(e){return!0}index(e,t){return this.domNode===e||this.domNode.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(t,1):-1}position(e,t){let r=Array.from(this.parent.domNode.childNodes).indexOf(this.domNode);return e>0&&(r+=1),[this.parent.domNode,r]}value(){return{[this.statics.blotName]:this.statics.value(this.domNode)||!0}}};xh.scope=ne.INLINE_BLOT;let wv=xh;const je=wv;class xv{constructor(){this.head=null,this.tail=null,this.length=0}append(...e){if(this.insertBefore(e[0],null),e.length>1){const t=e.slice(1);this.append(...t)}}at(e){const t=this.iterator();let r=t();for(;r&&e>0;)e-=1,r=t();return r}contains(e){const t=this.iterator();let r=t();for(;r;){if(r===e)return!0;r=t()}return!1}indexOf(e){const t=this.iterator();let r=t(),s=0;for(;r;){if(r===e)return s;s+=1,r=t()}return-1}insertBefore(e,t){e!=null&&(this.remove(e),e.next=t,t!=null?(e.prev=t.prev,t.prev!=null&&(t.prev.next=e),t.prev=e,t===this.head&&(this.head=e)):this.tail!=null?(this.tail.next=e,e.prev=this.tail,this.tail=e):(e.prev=null,this.head=this.tail=e),this.length+=1)}offset(e){let t=0,r=this.head;for(;r!=null;){if(r===e)return t;t+=r.length(),r=r.next}return-1}remove(e){this.contains(e)&&(e.prev!=null&&(e.prev.next=e.next),e.next!=null&&(e.next.prev=e.prev),e===this.head&&(this.head=e.next),e===this.tail&&(this.tail=e.prev),this.length-=1)}iterator(e=this.head){return()=>{const t=e;return e!=null&&(e=e.next),t}}find(e,t=!1){const r=this.iterator();let s=r();for(;s;){const i=s.length();if(e<i||t&&e===i&&(s.next==null||s.next.length()!==0))return[s,e];e-=i,s=r()}return[null,0]}forEach(e){const t=this.iterator();let r=t();for(;r;)e(r),r=t()}forEachAt(e,t,r){if(t<=0)return;const[s,i]=this.find(e);let o=e-i;const a=this.iterator(s);let u=a();for(;u&&o<e+t;){const c=u.length();e>o?r(u,e-o,Math.min(t,o+c-e)):r(u,0,Math.min(c,e+t-o)),o+=c,u=a()}}map(e){return this.reduce((t,r)=>(t.push(e(r)),t),[])}reduce(e,t){const r=this.iterator();let s=r();for(;s;)t=e(t,s),s=r();return t}}function au(n,e){const t=e.find(n);if(t)return t;try{return e.create(n)}catch{const r=e.create(ne.INLINE);return Array.from(n.childNodes).forEach(s=>{r.domNode.appendChild(s)}),n.parentNode&&n.parentNode.replaceChild(r.domNode,n),r.attach(),r}}const Sh=class Kt extends wh{constructor(e,t){super(e,t),this.uiNode=null,this.build()}appendChild(e){this.insertBefore(e)}attach(){super.attach(),this.children.forEach(e=>{e.attach()})}attachUI(e){this.uiNode!=null&&this.uiNode.remove(),this.uiNode=e,Kt.uiClass&&this.uiNode.classList.add(Kt.uiClass),this.uiNode.setAttribute("contenteditable","false"),this.domNode.insertBefore(this.uiNode,this.domNode.firstChild)}build(){this.children=new xv,Array.from(this.domNode.childNodes).filter(e=>e!==this.uiNode).reverse().forEach(e=>{try{const t=au(e,this.scroll);this.insertBefore(t,this.children.head||void 0)}catch(t){if(t instanceof en)return;throw t}})}deleteAt(e,t){if(e===0&&t===this.length())return this.remove();this.children.forEachAt(e,t,(r,s,i)=>{r.deleteAt(s,i)})}descendant(e,t=0){const[r,s]=this.children.find(t);return e.blotName==null&&e(r)||e.blotName!=null&&r instanceof e?[r,s]:r instanceof Kt?r.descendant(e,s):[null,-1]}descendants(e,t=0,r=Number.MAX_VALUE){let s=[],i=r;return this.children.forEachAt(t,r,(o,a,u)=>{(e.blotName==null&&e(o)||e.blotName!=null&&o instanceof e)&&s.push(o),o instanceof Kt&&(s=s.concat(o.descendants(e,a,i))),i-=u}),s}detach(){this.children.forEach(e=>{e.detach()}),super.detach()}enforceAllowedChildren(){let e=!1;this.children.forEach(t=>{e||this.statics.allowedChildren.some(r=>t instanceof r)||(t.statics.scope===ne.BLOCK_BLOT?(t.next!=null&&this.splitAfter(t),t.prev!=null&&this.splitAfter(t.prev),t.parent.unwrap(),e=!0):t instanceof Kt?t.unwrap():t.remove())})}formatAt(e,t,r,s){this.children.forEachAt(e,t,(i,o,a)=>{i.formatAt(o,a,r,s)})}insertAt(e,t,r){const[s,i]=this.children.find(e);if(s)s.insertAt(i,t,r);else{const o=r==null?this.scroll.create("text",t):this.scroll.create(t,r);this.appendChild(o)}}insertBefore(e,t){e.parent!=null&&e.parent.children.remove(e);let r=null;this.children.insertBefore(e,t||null),e.parent=this,t!=null&&(r=t.domNode),(this.domNode.parentNode!==e.domNode||this.domNode.nextSibling!==r)&&this.domNode.insertBefore(e.domNode,r),e.attach()}length(){return this.children.reduce((e,t)=>e+t.length(),0)}moveChildren(e,t){this.children.forEach(r=>{e.insertBefore(r,t)})}optimize(e){if(super.optimize(e),this.enforceAllowedChildren(),this.uiNode!=null&&this.uiNode!==this.domNode.firstChild&&this.domNode.insertBefore(this.uiNode,this.domNode.firstChild),this.children.length===0)if(this.statics.defaultChild!=null){const t=this.scroll.create(this.statics.defaultChild.blotName);this.appendChild(t)}else this.remove()}path(e,t=!1){const[r,s]=this.children.find(e,t),i=[[this,e]];return r instanceof Kt?i.concat(r.path(s,t)):(r!=null&&i.push([r,s]),i)}removeChild(e){this.children.remove(e)}replaceWith(e,t){const r=typeof e=="string"?this.scroll.create(e,t):e;return r instanceof Kt&&this.moveChildren(r),super.replaceWith(r)}split(e,t=!1){if(!t){if(e===0)return this;if(e===this.length())return this.next}const r=this.clone();return this.parent&&this.parent.insertBefore(r,this.next||void 0),this.children.forEachAt(e,this.length(),(s,i,o)=>{const a=s.split(i,t);a!=null&&r.appendChild(a)}),r}splitAfter(e){const t=this.clone();for(;e.next!=null;)t.appendChild(e.next);return this.parent&&this.parent.insertBefore(t,this.next||void 0),t}unwrap(){this.parent&&this.moveChildren(this.parent,this.next||void 0),this.remove()}update(e,t){const r=[],s=[];e.forEach(i=>{i.target===this.domNode&&i.type==="childList"&&(r.push(...i.addedNodes),s.push(...i.removedNodes))}),s.forEach(i=>{if(i.parentNode!=null&&i.tagName!=="IFRAME"&&document.body.compareDocumentPosition(i)&Node.DOCUMENT_POSITION_CONTAINED_BY)return;const o=this.scroll.find(i);o!=null&&(o.domNode.parentNode==null||o.domNode.parentNode===this.domNode)&&o.detach()}),r.filter(i=>i.parentNode===this.domNode&&i!==this.uiNode).sort((i,o)=>i===o?0:i.compareDocumentPosition(o)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1).forEach(i=>{let o=null;i.nextSibling!=null&&(o=this.scroll.find(i.nextSibling));const a=au(i,this.scroll);(a.next!==o||a.next==null)&&(a.parent!=null&&a.parent.removeChild(this),this.insertBefore(a,o||void 0))}),this.enforceAllowedChildren()}};Sh.uiClass="";let Sv=Sh;const dt=Sv;function _v(n,e){if(Object.keys(n).length!==Object.keys(e).length)return!1;for(const t in n)if(n[t]!==e[t])return!1;return!0}const Gr=class Kr extends dt{static create(e){return super.create(e)}static formats(e,t){const r=t.query(Kr.blotName);if(!(r!=null&&e.tagName===r.tagName)){if(typeof this.tagName=="string")return!0;if(Array.isArray(this.tagName))return e.tagName.toLowerCase()}}constructor(e,t){super(e,t),this.attributes=new vi(this.domNode)}format(e,t){if(e===this.statics.blotName&&!t)this.children.forEach(r=>{r instanceof Kr||(r=r.wrap(Kr.blotName,!0)),this.attributes.copy(r)}),this.unwrap();else{const r=this.scroll.query(e,ne.INLINE);if(r==null)return;r instanceof At?this.attributes.attribute(r,t):t&&(e!==this.statics.blotName||this.formats()[e]!==t)&&this.replaceWith(e,t)}}formats(){const e=this.attributes.values(),t=this.statics.formats(this.domNode,this.scroll);return t!=null&&(e[this.statics.blotName]=t),e}formatAt(e,t,r,s){this.formats()[r]!=null||this.scroll.query(r,ne.ATTRIBUTE)?this.isolate(e,t).format(r,s):super.formatAt(e,t,r,s)}optimize(e){super.optimize(e);const t=this.formats();if(Object.keys(t).length===0)return this.unwrap();const r=this.next;r instanceof Kr&&r.prev===this&&_v(t,r.formats())&&(r.moveChildren(this),r.remove())}replaceWith(e,t){const r=super.replaceWith(e,t);return this.attributes.copy(r),r}update(e,t){super.update(e,t),e.some(r=>r.target===this.domNode&&r.type==="attributes")&&this.attributes.build()}wrap(e,t){const r=super.wrap(e,t);return r instanceof Kr&&this.attributes.move(r),r}};Gr.allowedChildren=[Gr,je],Gr.blotName="inline",Gr.scope=ne.INLINE_BLOT,Gr.tagName="SPAN";let Av=Gr;const Wa=Av,Wr=class ha extends dt{static create(e){return super.create(e)}static formats(e,t){const r=t.query(ha.blotName);if(!(r!=null&&e.tagName===r.tagName)){if(typeof this.tagName=="string")return!0;if(Array.isArray(this.tagName))return e.tagName.toLowerCase()}}constructor(e,t){super(e,t),this.attributes=new vi(this.domNode)}format(e,t){const r=this.scroll.query(e,ne.BLOCK);r!=null&&(r instanceof At?this.attributes.attribute(r,t):e===this.statics.blotName&&!t?this.replaceWith(ha.blotName):t&&(e!==this.statics.blotName||this.formats()[e]!==t)&&this.replaceWith(e,t))}formats(){const e=this.attributes.values(),t=this.statics.formats(this.domNode,this.scroll);return t!=null&&(e[this.statics.blotName]=t),e}formatAt(e,t,r,s){this.scroll.query(r,ne.BLOCK)!=null?this.format(r,s):super.formatAt(e,t,r,s)}insertAt(e,t,r){if(r==null||this.scroll.query(t,ne.INLINE)!=null)super.insertAt(e,t,r);else{const s=this.split(e);if(s!=null){const i=this.scroll.create(t,r);s.parent.insertBefore(i,s)}else throw new Error("Attempt to insertAt after block boundaries")}}replaceWith(e,t){const r=super.replaceWith(e,t);return this.attributes.copy(r),r}update(e,t){super.update(e,t),e.some(r=>r.target===this.domNode&&r.type==="attributes")&&this.attributes.build()}};Wr.blotName="block",Wr.scope=ne.BLOCK_BLOT,Wr.tagName="P",Wr.allowedChildren=[Wa,Wr,je];let Cv=Wr;const Wn=Cv,da=class extends dt{checkMerge(){return this.next!==null&&this.next.statics.blotName===this.statics.blotName}deleteAt(e,t){super.deleteAt(e,t),this.enforceAllowedChildren()}formatAt(e,t,r,s){super.formatAt(e,t,r,s),this.enforceAllowedChildren()}insertAt(e,t,r){super.insertAt(e,t,r),this.enforceAllowedChildren()}optimize(e){super.optimize(e),this.children.length>0&&this.next!=null&&this.checkMerge()&&(this.next.moveChildren(this),this.next.remove())}};da.blotName="container",da.scope=ne.BLOCK_BLOT;let Tv=da;const yi=Tv;class kv extends je{static formats(e,t){}format(e,t){super.formatAt(0,this.length(),e,t)}formatAt(e,t,r,s){e===0&&t===this.length()?this.format(r,s):super.formatAt(e,t,r,s)}formats(){return this.statics.formats(this.domNode,this.scroll)}}const Ye=kv,Nv={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},Iv=100,Yr=class extends dt{constructor(e,t){super(null,t),this.registry=e,this.scroll=this,this.build(),this.observer=new MutationObserver(r=>{this.update(r)}),this.observer.observe(this.domNode,Nv),this.attach()}create(e,t){return this.registry.create(this,e,t)}find(e,t=!1){const r=this.registry.find(e,t);return r?r.scroll===this?r:t?this.find(r.scroll.domNode.parentNode,!0):null:null}query(e,t=ne.ANY){return this.registry.query(e,t)}register(...e){return this.registry.register(...e)}build(){this.scroll!=null&&super.build()}detach(){super.detach(),this.observer.disconnect()}deleteAt(e,t){this.update(),e===0&&t===this.length()?this.children.forEach(r=>{r.remove()}):super.deleteAt(e,t)}formatAt(e,t,r,s){this.update(),super.formatAt(e,t,r,s)}insertAt(e,t,r){this.update(),super.insertAt(e,t,r)}optimize(e=[],t={}){super.optimize(t);const r=t.mutationsMap||new WeakMap;let s=Array.from(this.observer.takeRecords());for(;s.length>0;)e.push(s.pop());const i=(u,c=!0)=>{u==null||u===this||u.domNode.parentNode!=null&&(r.has(u.domNode)||r.set(u.domNode,[]),c&&i(u.parent))},o=u=>{r.has(u.domNode)&&(u instanceof dt&&u.children.forEach(o),r.delete(u.domNode),u.optimize(t))};let a=e;for(let u=0;a.length>0;u+=1){if(u>=Iv)throw new Error("[Parchment] Maximum optimize iterations reached");for(a.forEach(c=>{const h=this.find(c.target,!0);h!=null&&(h.domNode===c.target&&(c.type==="childList"?(i(this.find(c.previousSibling,!1)),Array.from(c.addedNodes).forEach(g=>{const d=this.find(g,!1);i(d,!1),d instanceof dt&&d.children.forEach(m=>{i(m,!1)})})):c.type==="attributes"&&i(h.prev)),i(h))}),this.children.forEach(o),a=Array.from(this.observer.takeRecords()),s=a.slice();s.length>0;)e.push(s.pop())}}update(e,t={}){e=e||this.observer.takeRecords();const r=new WeakMap;e.map(s=>{const i=this.find(s.target,!0);return i==null?null:r.has(i.domNode)?(r.get(i.domNode).push(s),null):(r.set(i.domNode,[s]),i)}).forEach(s=>{s!=null&&s!==this&&r.has(s.domNode)&&s.update(r.get(s.domNode)||[],t)}),t.mutationsMap=r,r.has(this.domNode)&&super.update(r.get(this.domNode),t),this.optimize(e,t)}};Yr.blotName="scroll",Yr.defaultChild=Wn,Yr.allowedChildren=[Wn,yi],Yr.scope=ne.BLOCK_BLOT,Yr.tagName="DIV";let Rv=Yr;const Ya=Rv,fa=class _h extends je{static create(e){return document.createTextNode(e)}static value(e){return e.data}constructor(e,t){super(e,t),this.text=this.statics.value(this.domNode)}deleteAt(e,t){this.domNode.data=this.text=this.text.slice(0,e)+this.text.slice(e+t)}index(e,t){return this.domNode===e?t:-1}insertAt(e,t,r){r==null?(this.text=this.text.slice(0,e)+t+this.text.slice(e),this.domNode.data=this.text):super.insertAt(e,t,r)}length(){return this.text.length}optimize(e){super.optimize(e),this.text=this.statics.value(this.domNode),this.text.length===0?this.remove():this.next instanceof _h&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())}position(e,t=!1){return[this.domNode,e]}split(e,t=!1){if(!t){if(e===0)return this;if(e===this.length())return this.next}const r=this.scroll.create(this.domNode.splitText(e));return this.parent.insertBefore(r,this.next||void 0),this.text=this.statics.value(this.domNode),r}update(e,t){e.some(r=>r.type==="characterData"&&r.target===this.domNode)&&(this.text=this.statics.value(this.domNode))}value(){return this.text}};fa.blotName="text",fa.scope=ne.INLINE_BLOT;let Ov=fa;const ti=Ov,Lv=Object.freeze(Object.defineProperty({__proto__:null,Attributor:At,AttributorStore:vi,BlockBlot:Wn,ClassAttributor:pt,ContainerBlot:yi,EmbedBlot:Ye,InlineBlot:Wa,LeafBlot:je,ParentBlot:dt,Registry:ln,Scope:ne,ScrollBlot:Ya,StyleAttributor:ir,TextBlot:ti},Symbol.toStringTag,{value:"Module"}));var Cs={exports:{}},No,lu;function Mv(){if(lu)return No;lu=1;var n=-1,e=1,t=0;function r(b,M,A,$,V){if(b===M)return b?[[t,b]]:[];if(A!=null){var R=ue(b,M,A);if(R)return R}var q=a(b,M),W=b.substring(0,q);b=b.substring(q),M=M.substring(q),q=c(b,M);var Y=b.substring(b.length-q);b=b.substring(0,b.length-q),M=M.substring(0,M.length-q);var T=s(b,M);return W&&T.unshift([t,W]),Y&&T.push([t,Y]),S(T,V),$&&g(T),T}function s(b,M){var A;if(!b)return[[e,M]];if(!M)return[[n,b]];var $=b.length>M.length?b:M,V=b.length>M.length?M:b,R=$.indexOf(V);if(R!==-1)return A=[[e,$.substring(0,R)],[t,V],[e,$.substring(R+V.length)]],b.length>M.length&&(A[0][0]=A[2][0]=n),A;if(V.length===1)return[[n,b],[e,M]];var q=h(b,M);if(q){var W=q[0],Y=q[1],T=q[2],D=q[3],U=q[4],K=r(W,T),z=r(Y,D);return K.concat([[t,U]],z)}return i(b,M)}function i(b,M){for(var A=b.length,$=M.length,V=Math.ceil((A+$)/2),R=V,q=2*V,W=new Array(q),Y=new Array(q),T=0;T<q;T++)W[T]=-1,Y[T]=-1;W[R+1]=0,Y[R+1]=0;for(var D=A-$,U=D%2!==0,K=0,z=0,H=0,Q=0,F=0;F<V;F++){for(var j=-F+K;j<=F-z;j+=2){var Z=R+j,G;j===-F||j!==F&&W[Z-1]<W[Z+1]?G=W[Z+1]:G=W[Z-1]+1;for(var X=G-j;G<A&&X<$&&b.charAt(G)===M.charAt(X);)G++,X++;if(W[Z]=G,G>A)z+=2;else if(X>$)K+=2;else if(U){var k=R+D-j;if(k>=0&&k<q&&Y[k]!==-1){var ce=A-Y[k];if(G>=ce)return o(b,M,G,X)}}}for(var ge=-F+H;ge<=F-Q;ge+=2){var k=R+ge,ce;ge===-F||ge!==F&&Y[k-1]<Y[k+1]?ce=Y[k+1]:ce=Y[k-1]+1;for(var be=ce-ge;ce<A&&be<$&&b.charAt(A-ce-1)===M.charAt($-be-1);)ce++,be++;if(Y[k]=ce,ce>A)Q+=2;else if(be>$)H+=2;else if(!U){var Z=R+D-ge;if(Z>=0&&Z<q&&W[Z]!==-1){var G=W[Z],X=R+G-Z;if(ce=A-ce,G>=ce)return o(b,M,G,X)}}}}return[[n,b],[e,M]]}function o(b,M,A,$){var V=b.substring(0,A),R=M.substring(0,$),q=b.substring(A),W=M.substring($),Y=r(V,R),T=r(q,W);return Y.concat(T)}function a(b,M){if(!b||!M||b.charAt(0)!==M.charAt(0))return 0;for(var A=0,$=Math.min(b.length,M.length),V=$,R=0;A<V;)b.substring(R,V)==M.substring(R,V)?(A=V,R=A):$=V,V=Math.floor(($-A)/2+A);return x(b.charCodeAt(V-1))&&V--,V}function u(b,M){var A=b.length,$=M.length;if(A==0||$==0)return 0;A>$?b=b.substring(A-$):A<$&&(M=M.substring(0,A));var V=Math.min(A,$);if(b==M)return V;for(var R=0,q=1;;){var W=b.substring(V-q),Y=M.indexOf(W);if(Y==-1)return R;q+=Y,(Y==0||b.substring(V-q)==M.substring(0,q))&&(R=q,q++)}}function c(b,M){if(!b||!M||b.slice(-1)!==M.slice(-1))return 0;for(var A=0,$=Math.min(b.length,M.length),V=$,R=0;A<V;)b.substring(b.length-V,b.length-R)==M.substring(M.length-V,M.length-R)?(A=V,R=A):$=V,V=Math.floor(($-A)/2+A);return N(b.charCodeAt(b.length-V))&&V--,V}function h(b,M){var A=b.length>M.length?b:M,$=b.length>M.length?M:b;if(A.length<4||$.length*2<A.length)return null;function V(z,H,Q){for(var F=z.substring(Q,Q+Math.floor(z.length/4)),j=-1,Z="",G,X,k,ce;(j=H.indexOf(F,j+1))!==-1;){var ge=a(z.substring(Q),H.substring(j)),be=c(z.substring(0,Q),H.substring(0,j));Z.length<be+ge&&(Z=H.substring(j-be,j)+H.substring(j,j+ge),G=z.substring(0,Q-be),X=z.substring(Q+ge),k=H.substring(0,j-be),ce=H.substring(j+ge))}return Z.length*2>=z.length?[G,X,k,ce,Z]:null}var R=V(A,$,Math.ceil(A.length/4)),q=V(A,$,Math.ceil(A.length/2)),W;if(!R&&!q)return null;q?R?W=R[4].length>q[4].length?R:q:W=q:W=R;var Y,T,D,U;b.length>M.length?(Y=W[0],T=W[1],D=W[2],U=W[3]):(D=W[0],U=W[1],Y=W[2],T=W[3]);var K=W[4];return[Y,T,D,U,K]}function g(b){for(var M=!1,A=[],$=0,V=null,R=0,q=0,W=0,Y=0,T=0;R<b.length;)b[R][0]==t?(A[$++]=R,q=Y,W=T,Y=0,T=0,V=b[R][1]):(b[R][0]==e?Y+=b[R][1].length:T+=b[R][1].length,V&&V.length<=Math.max(q,W)&&V.length<=Math.max(Y,T)&&(b.splice(A[$-1],0,[n,V]),b[A[$-1]+1][0]=e,$--,$--,R=$>0?A[$-1]:-1,q=0,W=0,Y=0,T=0,V=null,M=!0)),R++;for(M&&S(b),E(b),R=1;R<b.length;){if(b[R-1][0]==n&&b[R][0]==e){var D=b[R-1][1],U=b[R][1],K=u(D,U),z=u(U,D);K>=z?(K>=D.length/2||K>=U.length/2)&&(b.splice(R,0,[t,U.substring(0,K)]),b[R-1][1]=D.substring(0,D.length-K),b[R+1][1]=U.substring(K),R++):(z>=D.length/2||z>=U.length/2)&&(b.splice(R,0,[t,D.substring(0,z)]),b[R-1][0]=e,b[R-1][1]=U.substring(0,U.length-z),b[R+1][0]=n,b[R+1][1]=D.substring(z),R++),R++}R++}}var d=/[^a-zA-Z0-9]/,m=/\s/,v=/[\r\n]/,p=/\n\r?\n$/,y=/^\r?\n\r?\n/;function E(b){function M(z,H){if(!z||!H)return 6;var Q=z.charAt(z.length-1),F=H.charAt(0),j=Q.match(d),Z=F.match(d),G=j&&Q.match(m),X=Z&&F.match(m),k=G&&Q.match(v),ce=X&&F.match(v),ge=k&&z.match(p),be=ce&&H.match(y);return ge||be?5:k||ce?4:j&&!G&&X?3:G||X?2:j||Z?1:0}for(var A=1;A<b.length-1;){if(b[A-1][0]==t&&b[A+1][0]==t){var $=b[A-1][1],V=b[A][1],R=b[A+1][1],q=c($,V);if(q){var W=V.substring(V.length-q);$=$.substring(0,$.length-q),V=W+V.substring(0,V.length-q),R=W+R}for(var Y=$,T=V,D=R,U=M($,V)+M(V,R);V.charAt(0)===R.charAt(0);){$+=V.charAt(0),V=V.substring(1)+R.charAt(0),R=R.substring(1);var K=M($,V)+M(V,R);K>=U&&(U=K,Y=$,T=V,D=R)}b[A-1][1]!=Y&&(Y?b[A-1][1]=Y:(b.splice(A-1,1),A--),b[A][1]=T,D?b[A+1][1]=D:(b.splice(A+1,1),A--))}A++}}function S(b,M){b.push([t,""]);for(var A=0,$=0,V=0,R="",q="",W;A<b.length;){if(A<b.length-1&&!b[A][1]){b.splice(A,1);continue}switch(b[A][0]){case e:V++,q+=b[A][1],A++;break;case n:$++,R+=b[A][1],A++;break;case t:var Y=A-V-$-1;if(M){if(Y>=0&&P(b[Y][1])){var T=b[Y][1].slice(-1);if(b[Y][1]=b[Y][1].slice(0,-1),R=T+R,q=T+q,!b[Y][1]){b.splice(Y,1),A--;var D=Y-1;b[D]&&b[D][0]===e&&(V++,q=b[D][1]+q,D--),b[D]&&b[D][0]===n&&($++,R=b[D][1]+R,D--),Y=D}}if(_(b[A][1])){var T=b[A][1].charAt(0);b[A][1]=b[A][1].slice(1),R+=T,q+=T}}if(A<b.length-1&&!b[A][1]){b.splice(A,1);break}if(R.length>0||q.length>0){R.length>0&&q.length>0&&(W=a(q,R),W!==0&&(Y>=0?b[Y][1]+=q.substring(0,W):(b.splice(0,0,[t,q.substring(0,W)]),A++),q=q.substring(W),R=R.substring(W)),W=c(q,R),W!==0&&(b[A][1]=q.substring(q.length-W)+b[A][1],q=q.substring(0,q.length-W),R=R.substring(0,R.length-W)));var U=V+$;R.length===0&&q.length===0?(b.splice(A-U,U),A=A-U):R.length===0?(b.splice(A-U,U,[e,q]),A=A-U+1):q.length===0?(b.splice(A-U,U,[n,R]),A=A-U+1):(b.splice(A-U,U,[n,R],[e,q]),A=A-U+2)}A!==0&&b[A-1][0]===t?(b[A-1][1]+=b[A][1],b.splice(A,1)):A++,V=0,$=0,R="",q="";break}}b[b.length-1][1]===""&&b.pop();var K=!1;for(A=1;A<b.length-1;)b[A-1][0]===t&&b[A+1][0]===t&&(b[A][1].substring(b[A][1].length-b[A-1][1].length)===b[A-1][1]?(b[A][1]=b[A-1][1]+b[A][1].substring(0,b[A][1].length-b[A-1][1].length),b[A+1][1]=b[A-1][1]+b[A+1][1],b.splice(A-1,1),K=!0):b[A][1].substring(0,b[A+1][1].length)==b[A+1][1]&&(b[A-1][1]+=b[A+1][1],b[A][1]=b[A][1].substring(b[A+1][1].length)+b[A+1][1],b.splice(A+1,1),K=!0)),A++;K&&S(b,M)}function x(b){return b>=55296&&b<=56319}function N(b){return b>=56320&&b<=57343}function _(b){return N(b.charCodeAt(0))}function P(b){return x(b.charCodeAt(b.length-1))}function I(b){for(var M=[],A=0;A<b.length;A++)b[A][1].length>0&&M.push(b[A]);return M}function te(b,M,A,$){return P(b)||_($)?null:I([[t,b],[n,M],[e,A],[t,$]])}function ue(b,M,A){var $=typeof A=="number"?{index:A,length:0}:A.oldRange,V=typeof A=="number"?null:A.newRange,R=b.length,q=M.length;if($.length===0&&(V===null||V.length===0)){var W=$.index,Y=b.slice(0,W),T=b.slice(W),D=V?V.index:null;e:{var U=W+q-R;if(D!==null&&D!==U||U<0||U>q)break e;var K=M.slice(0,U),z=M.slice(U);if(z!==T)break e;var H=Math.min(W,U),Q=Y.slice(0,H),F=K.slice(0,H);if(Q!==F)break e;var j=Y.slice(H),Z=K.slice(H);return te(Q,j,Z,T)}e:{if(D!==null&&D!==W)break e;var G=W,K=M.slice(0,G),z=M.slice(G);if(K!==Y)break e;var X=Math.min(R-G,q-G),k=T.slice(T.length-X),ce=z.slice(z.length-X);if(k!==ce)break e;var j=T.slice(0,T.length-X),Z=z.slice(0,z.length-X);return te(Y,j,Z,k)}}if($.length>0&&V&&V.length===0)e:{var Q=b.slice(0,$.index),k=b.slice($.index+$.length),H=Q.length,X=k.length;if(q<H+X)break e;var F=M.slice(0,H),ce=M.slice(q-X);if(Q!==F||k!==ce)break e;var j=b.slice(H,R-X),Z=M.slice(H,q-X);return te(Q,j,Z,k)}return null}function ie(b,M,A,$){return r(b,M,A,$,!0)}return ie.INSERT=e,ie.DELETE=n,ie.EQUAL=t,No=ie,No}var Dn={exports:{}};Dn.exports;var uu;function Ah(){return uu||(uu=1,(function(n,e){var t=200,r="__lodash_hash_undefined__",s=9007199254740991,i="[object Arguments]",o="[object Array]",a="[object Boolean]",u="[object Date]",c="[object Error]",h="[object Function]",g="[object GeneratorFunction]",d="[object Map]",m="[object Number]",v="[object Object]",p="[object Promise]",y="[object RegExp]",E="[object Set]",S="[object String]",x="[object Symbol]",N="[object WeakMap]",_="[object ArrayBuffer]",P="[object DataView]",I="[object Float32Array]",te="[object Float64Array]",ue="[object Int8Array]",ie="[object Int16Array]",b="[object Int32Array]",M="[object Uint8Array]",A="[object Uint8ClampedArray]",$="[object Uint16Array]",V="[object Uint32Array]",R=/[\\^$.*+?()[\]{}|]/g,q=/\w*$/,W=/^\[object .+?Constructor\]$/,Y=/^(?:0|[1-9]\d*)$/,T={};T[i]=T[o]=T[_]=T[P]=T[a]=T[u]=T[I]=T[te]=T[ue]=T[ie]=T[b]=T[d]=T[m]=T[v]=T[y]=T[E]=T[S]=T[x]=T[M]=T[A]=T[$]=T[V]=!0,T[c]=T[h]=T[N]=!1;var D=typeof De.commonjsGlobal=="object"&&De.commonjsGlobal&&De.commonjsGlobal.Object===Object&&De.commonjsGlobal,U=typeof self=="object"&&self&&self.Object===Object&&self,K=D||U||Function("return this")(),z=e&&!e.nodeType&&e,H=z&&!0&&n&&!n.nodeType&&n,Q=H&&H.exports===z;function F(l,f){return l.set(f[0],f[1]),l}function j(l,f){return l.add(f),l}function Z(l,f){for(var w=-1,L=l?l.length:0;++w<L&&f(l[w],w,l)!==!1;);return l}function G(l,f){for(var w=-1,L=f.length,de=l.length;++w<L;)l[de+w]=f[w];return l}function X(l,f,w,L){for(var de=-1,oe=l?l.length:0;++de<oe;)w=f(w,l[de],de,l);return w}function k(l,f){for(var w=-1,L=Array(l);++w<l;)L[w]=f(w);return L}function ce(l,f){return l==null?void 0:l[f]}function ge(l){var f=!1;if(l!=null&&typeof l.toString!="function")try{f=!!(l+"")}catch{}return f}function be(l){var f=-1,w=Array(l.size);return l.forEach(function(L,de){w[++f]=[de,L]}),w}function kt(l,f){return function(w){return l(f(w))}}function Ut(l){var f=-1,w=Array(l.size);return l.forEach(function(L){w[++f]=L}),w}var Li=Array.prototype,Mi=Function.prototype,Lr=Object.prototype,mn=K["__core-js_shared__"],is=(function(){var l=/[^.]+$/.exec(mn&&mn.keys&&mn.keys.IE_PROTO||"");return l?"Symbol(src)_1."+l:""})(),os=Mi.toString,vt=Lr.hasOwnProperty,Mr=Lr.toString,Di=RegExp("^"+os.call(vt).replace(R,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),lr=Q?K.Buffer:void 0,Dr=K.Symbol,vn=K.Uint8Array,Ze=kt(Object.getPrototypeOf,Object),as=Object.create,ls=Lr.propertyIsEnumerable,Pi=Li.splice,yn=Object.getOwnPropertySymbols,Pr=lr?lr.isBuffer:void 0,us=kt(Object.keys,Object),Br=st(K,"DataView"),ur=st(K,"Map"),nt=st(K,"Promise"),qr=st(K,"Set"),bn=st(K,"WeakMap"),cr=st(Object,"create"),En=He(Br),hr=He(ur),wn=He(nt),xn=He(qr),Sn=He(bn),Ht=Dr?Dr.prototype:void 0,cs=Ht?Ht.valueOf:void 0;function Nt(l){var f=-1,w=l?l.length:0;for(this.clear();++f<w;){var L=l[f];this.set(L[0],L[1])}}function Bi(){this.__data__=cr?cr(null):{}}function qi(l){return this.has(l)&&delete this.__data__[l]}function Fi(l){var f=this.__data__;if(cr){var w=f[l];return w===r?void 0:w}return vt.call(f,l)?f[l]:void 0}function hs(l){var f=this.__data__;return cr?f[l]!==void 0:vt.call(f,l)}function _n(l,f){var w=this.__data__;return w[l]=cr&&f===void 0?r:f,this}Nt.prototype.clear=Bi,Nt.prototype.delete=qi,Nt.prototype.get=Fi,Nt.prototype.has=hs,Nt.prototype.set=_n;function Le(l){var f=-1,w=l?l.length:0;for(this.clear();++f<w;){var L=l[f];this.set(L[0],L[1])}}function ji(){this.__data__=[]}function $i(l){var f=this.__data__,w=jr(f,l);if(w<0)return!1;var L=f.length-1;return w==L?f.pop():Pi.call(f,w,1),!0}function Vi(l){var f=this.__data__,w=jr(f,l);return w<0?void 0:f[w][1]}function Ui(l){return jr(this.__data__,l)>-1}function Hi(l,f){var w=this.__data__,L=jr(w,l);return L<0?w.push([l,f]):w[L][1]=f,this}Le.prototype.clear=ji,Le.prototype.delete=$i,Le.prototype.get=Vi,Le.prototype.has=Ui,Le.prototype.set=Hi;function Be(l){var f=-1,w=l?l.length:0;for(this.clear();++f<w;){var L=l[f];this.set(L[0],L[1])}}function zi(){this.__data__={hash:new Nt,map:new(ur||Le),string:new Nt}}function Gi(l){return fr(this,l).delete(l)}function Ki(l){return fr(this,l).get(l)}function Wi(l){return fr(this,l).has(l)}function Yi(l,f){return fr(this,l).set(l,f),this}Be.prototype.clear=zi,Be.prototype.delete=Gi,Be.prototype.get=Ki,Be.prototype.has=Wi,Be.prototype.set=Yi;function ze(l){this.__data__=new Le(l)}function Zi(){this.__data__=new Le}function Xi(l){return this.__data__.delete(l)}function Qi(l){return this.__data__.get(l)}function Ji(l){return this.__data__.has(l)}function eo(l,f){var w=this.__data__;if(w instanceof Le){var L=w.__data__;if(!ur||L.length<t-1)return L.push([l,f]),this;w=this.__data__=new Be(L)}return w.set(l,f),this}ze.prototype.clear=Zi,ze.prototype.delete=Xi,ze.prototype.get=Qi,ze.prototype.has=Ji,ze.prototype.set=eo;function Fr(l,f){var w=kn(l)||Vr(l)?k(l.length,String):[],L=w.length,de=!!L;for(var oe in l)vt.call(l,oe)&&!(de&&(oe=="length"||go(oe,L)))&&w.push(oe);return w}function ds(l,f,w){var L=l[f];(!(vt.call(l,f)&&vs(L,w))||w===void 0&&!(f in l))&&(l[f]=w)}function jr(l,f){for(var w=l.length;w--;)if(vs(l[w][0],f))return w;return-1}function yt(l,f){return l&&Tn(f,In(f),l)}function An(l,f,w,L,de,oe,ve){var me;if(L&&(me=oe?L(l,de,oe,ve):L(l)),me!==void 0)return me;if(!Et(l))return l;var ke=kn(l);if(ke){if(me=fo(l),!f)return uo(l,me)}else{var Ee=Rt(l),qe=Ee==h||Ee==g;if(ys(l))return $r(l,f);if(Ee==v||Ee==i||qe&&!oe){if(ge(l))return oe?l:{};if(me=bt(qe?{}:l),!f)return co(l,yt(me,l))}else{if(!T[Ee])return oe?l:{};me=po(l,Ee,An,f)}}ve||(ve=new ze);var Ge=ve.get(l);if(Ge)return Ge;if(ve.set(l,me),!ke)var Ie=w?ho(l):In(l);return Z(Ie||l,function(Fe,Me){Ie&&(Me=Fe,Fe=l[Me]),ds(me,Me,An(Fe,f,w,L,Me,l,ve))}),me}function to(l){return Et(l)?as(l):{}}function ro(l,f,w){var L=f(l);return kn(l)?L:G(L,w(l))}function no(l){return Mr.call(l)}function so(l){if(!Et(l)||vo(l))return!1;var f=Nn(l)||ge(l)?Di:W;return f.test(He(l))}function io(l){if(!gs(l))return us(l);var f=[];for(var w in Object(l))vt.call(l,w)&&w!="constructor"&&f.push(w);return f}function $r(l,f){if(f)return l.slice();var w=new l.constructor(l.length);return l.copy(w),w}function Cn(l){var f=new l.constructor(l.byteLength);return new vn(f).set(new vn(l)),f}function dr(l,f){var w=f?Cn(l.buffer):l.buffer;return new l.constructor(w,l.byteOffset,l.byteLength)}function fs(l,f,w){var L=f?w(be(l),!0):be(l);return X(L,F,new l.constructor)}function ps(l){var f=new l.constructor(l.source,q.exec(l));return f.lastIndex=l.lastIndex,f}function oo(l,f,w){var L=f?w(Ut(l),!0):Ut(l);return X(L,j,new l.constructor)}function ao(l){return cs?Object(cs.call(l)):{}}function lo(l,f){var w=f?Cn(l.buffer):l.buffer;return new l.constructor(w,l.byteOffset,l.length)}function uo(l,f){var w=-1,L=l.length;for(f||(f=Array(L));++w<L;)f[w]=l[w];return f}function Tn(l,f,w,L){w||(w={});for(var de=-1,oe=f.length;++de<oe;){var ve=f[de],me=void 0;ds(w,ve,me===void 0?l[ve]:me)}return w}function co(l,f){return Tn(l,It(l),f)}function ho(l){return ro(l,In,It)}function fr(l,f){var w=l.__data__;return mo(f)?w[typeof f=="string"?"string":"hash"]:w.map}function st(l,f){var w=ce(l,f);return so(w)?w:void 0}var It=yn?kt(yn,Object):bo,Rt=no;(Br&&Rt(new Br(new ArrayBuffer(1)))!=P||ur&&Rt(new ur)!=d||nt&&Rt(nt.resolve())!=p||qr&&Rt(new qr)!=E||bn&&Rt(new bn)!=N)&&(Rt=function(l){var f=Mr.call(l),w=f==v?l.constructor:void 0,L=w?He(w):void 0;if(L)switch(L){case En:return P;case hr:return d;case wn:return p;case xn:return E;case Sn:return N}return f});function fo(l){var f=l.length,w=l.constructor(f);return f&&typeof l[0]=="string"&&vt.call(l,"index")&&(w.index=l.index,w.input=l.input),w}function bt(l){return typeof l.constructor=="function"&&!gs(l)?to(Ze(l)):{}}function po(l,f,w,L){var de=l.constructor;switch(f){case _:return Cn(l);case a:case u:return new de(+l);case P:return dr(l,L);case I:case te:case ue:case ie:case b:case M:case A:case $:case V:return lo(l,L);case d:return fs(l,L,w);case m:case S:return new de(l);case y:return ps(l);case E:return oo(l,L,w);case x:return ao(l)}}function go(l,f){return f=f??s,!!f&&(typeof l=="number"||Y.test(l))&&l>-1&&l%1==0&&l<f}function mo(l){var f=typeof l;return f=="string"||f=="number"||f=="symbol"||f=="boolean"?l!=="__proto__":l===null}function vo(l){return!!is&&is in l}function gs(l){var f=l&&l.constructor,w=typeof f=="function"&&f.prototype||Lr;return l===w}function He(l){if(l!=null){try{return os.call(l)}catch{}try{return l+""}catch{}}return""}function ms(l){return An(l,!0,!0)}function vs(l,f){return l===f||l!==l&&f!==f}function Vr(l){return yo(l)&&vt.call(l,"callee")&&(!ls.call(l,"callee")||Mr.call(l)==i)}var kn=Array.isArray;function Ur(l){return l!=null&&bs(l.length)&&!Nn(l)}function yo(l){return Es(l)&&Ur(l)}var ys=Pr||Eo;function Nn(l){var f=Et(l)?Mr.call(l):"";return f==h||f==g}function bs(l){return typeof l=="number"&&l>-1&&l%1==0&&l<=s}function Et(l){var f=typeof l;return!!l&&(f=="object"||f=="function")}function Es(l){return!!l&&typeof l=="object"}function In(l){return Ur(l)?Fr(l):io(l)}function bo(){return[]}function Eo(){return!1}n.exports=ms})(Dn,Dn.exports)),Dn.exports}var Pn={exports:{}};Pn.exports;var cu;function Ch(){return cu||(cu=1,(function(n,e){var t=200,r="__lodash_hash_undefined__",s=1,i=2,o=9007199254740991,a="[object Arguments]",u="[object Array]",c="[object AsyncFunction]",h="[object Boolean]",g="[object Date]",d="[object Error]",m="[object Function]",v="[object GeneratorFunction]",p="[object Map]",y="[object Number]",E="[object Null]",S="[object Object]",x="[object Promise]",N="[object Proxy]",_="[object RegExp]",P="[object Set]",I="[object String]",te="[object Symbol]",ue="[object Undefined]",ie="[object WeakMap]",b="[object ArrayBuffer]",M="[object DataView]",A="[object Float32Array]",$="[object Float64Array]",V="[object Int8Array]",R="[object Int16Array]",q="[object Int32Array]",W="[object Uint8Array]",Y="[object Uint8ClampedArray]",T="[object Uint16Array]",D="[object Uint32Array]",U=/[\\^$.*+?()[\]{}|]/g,K=/^\[object .+?Constructor\]$/,z=/^(?:0|[1-9]\d*)$/,H={};H[A]=H[$]=H[V]=H[R]=H[q]=H[W]=H[Y]=H[T]=H[D]=!0,H[a]=H[u]=H[b]=H[h]=H[M]=H[g]=H[d]=H[m]=H[p]=H[y]=H[S]=H[_]=H[P]=H[I]=H[ie]=!1;var Q=typeof De.commonjsGlobal=="object"&&De.commonjsGlobal&&De.commonjsGlobal.Object===Object&&De.commonjsGlobal,F=typeof self=="object"&&self&&self.Object===Object&&self,j=Q||F||Function("return this")(),Z=e&&!e.nodeType&&e,G=Z&&!0&&n&&!n.nodeType&&n,X=G&&G.exports===Z,k=X&&Q.process,ce=(function(){try{return k&&k.binding&&k.binding("util")}catch{}})(),ge=ce&&ce.isTypedArray;function be(l,f){for(var w=-1,L=l==null?0:l.length,de=0,oe=[];++w<L;){var ve=l[w];f(ve,w,l)&&(oe[de++]=ve)}return oe}function kt(l,f){for(var w=-1,L=f.length,de=l.length;++w<L;)l[de+w]=f[w];return l}function Ut(l,f){for(var w=-1,L=l==null?0:l.length;++w<L;)if(f(l[w],w,l))return!0;return!1}function Li(l,f){for(var w=-1,L=Array(l);++w<l;)L[w]=f(w);return L}function Mi(l){return function(f){return l(f)}}function Lr(l,f){return l.has(f)}function mn(l,f){return l==null?void 0:l[f]}function is(l){var f=-1,w=Array(l.size);return l.forEach(function(L,de){w[++f]=[de,L]}),w}function os(l,f){return function(w){return l(f(w))}}function vt(l){var f=-1,w=Array(l.size);return l.forEach(function(L){w[++f]=L}),w}var Mr=Array.prototype,Di=Function.prototype,lr=Object.prototype,Dr=j["__core-js_shared__"],vn=Di.toString,Ze=lr.hasOwnProperty,as=(function(){var l=/[^.]+$/.exec(Dr&&Dr.keys&&Dr.keys.IE_PROTO||"");return l?"Symbol(src)_1."+l:""})(),ls=lr.toString,Pi=RegExp("^"+vn.call(Ze).replace(U,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),yn=X?j.Buffer:void 0,Pr=j.Symbol,us=j.Uint8Array,Br=lr.propertyIsEnumerable,ur=Mr.splice,nt=Pr?Pr.toStringTag:void 0,qr=Object.getOwnPropertySymbols,bn=yn?yn.isBuffer:void 0,cr=os(Object.keys,Object),En=It(j,"DataView"),hr=It(j,"Map"),wn=It(j,"Promise"),xn=It(j,"Set"),Sn=It(j,"WeakMap"),Ht=It(Object,"create"),cs=He(En),Nt=He(hr),Bi=He(wn),qi=He(xn),Fi=He(Sn),hs=Pr?Pr.prototype:void 0,_n=hs?hs.valueOf:void 0;function Le(l){var f=-1,w=l==null?0:l.length;for(this.clear();++f<w;){var L=l[f];this.set(L[0],L[1])}}function ji(){this.__data__=Ht?Ht(null):{},this.size=0}function $i(l){var f=this.has(l)&&delete this.__data__[l];return this.size-=f?1:0,f}function Vi(l){var f=this.__data__;if(Ht){var w=f[l];return w===r?void 0:w}return Ze.call(f,l)?f[l]:void 0}function Ui(l){var f=this.__data__;return Ht?f[l]!==void 0:Ze.call(f,l)}function Hi(l,f){var w=this.__data__;return this.size+=this.has(l)?0:1,w[l]=Ht&&f===void 0?r:f,this}Le.prototype.clear=ji,Le.prototype.delete=$i,Le.prototype.get=Vi,Le.prototype.has=Ui,Le.prototype.set=Hi;function Be(l){var f=-1,w=l==null?0:l.length;for(this.clear();++f<w;){var L=l[f];this.set(L[0],L[1])}}function zi(){this.__data__=[],this.size=0}function Gi(l){var f=this.__data__,w=$r(f,l);if(w<0)return!1;var L=f.length-1;return w==L?f.pop():ur.call(f,w,1),--this.size,!0}function Ki(l){var f=this.__data__,w=$r(f,l);return w<0?void 0:f[w][1]}function Wi(l){return $r(this.__data__,l)>-1}function Yi(l,f){var w=this.__data__,L=$r(w,l);return L<0?(++this.size,w.push([l,f])):w[L][1]=f,this}Be.prototype.clear=zi,Be.prototype.delete=Gi,Be.prototype.get=Ki,Be.prototype.has=Wi,Be.prototype.set=Yi;function ze(l){var f=-1,w=l==null?0:l.length;for(this.clear();++f<w;){var L=l[f];this.set(L[0],L[1])}}function Zi(){this.size=0,this.__data__={hash:new Le,map:new(hr||Be),string:new Le}}function Xi(l){var f=st(this,l).delete(l);return this.size-=f?1:0,f}function Qi(l){return st(this,l).get(l)}function Ji(l){return st(this,l).has(l)}function eo(l,f){var w=st(this,l),L=w.size;return w.set(l,f),this.size+=w.size==L?0:1,this}ze.prototype.clear=Zi,ze.prototype.delete=Xi,ze.prototype.get=Qi,ze.prototype.has=Ji,ze.prototype.set=eo;function Fr(l){var f=-1,w=l==null?0:l.length;for(this.__data__=new ze;++f<w;)this.add(l[f])}function ds(l){return this.__data__.set(l,r),this}function jr(l){return this.__data__.has(l)}Fr.prototype.add=Fr.prototype.push=ds,Fr.prototype.has=jr;function yt(l){var f=this.__data__=new Be(l);this.size=f.size}function An(){this.__data__=new Be,this.size=0}function to(l){var f=this.__data__,w=f.delete(l);return this.size=f.size,w}function ro(l){return this.__data__.get(l)}function no(l){return this.__data__.has(l)}function so(l,f){var w=this.__data__;if(w instanceof Be){var L=w.__data__;if(!hr||L.length<t-1)return L.push([l,f]),this.size=++w.size,this;w=this.__data__=new ze(L)}return w.set(l,f),this.size=w.size,this}yt.prototype.clear=An,yt.prototype.delete=to,yt.prototype.get=ro,yt.prototype.has=no,yt.prototype.set=so;function io(l,f){var w=Vr(l),L=!w&&vs(l),de=!w&&!L&&Ur(l),oe=!w&&!L&&!de&&Es(l),ve=w||L||de||oe,me=ve?Li(l.length,String):[],ke=me.length;for(var Ee in l)Ze.call(l,Ee)&&!(ve&&(Ee=="length"||de&&(Ee=="offset"||Ee=="parent")||oe&&(Ee=="buffer"||Ee=="byteLength"||Ee=="byteOffset")||po(Ee,ke)))&&me.push(Ee);return me}function $r(l,f){for(var w=l.length;w--;)if(ms(l[w][0],f))return w;return-1}function Cn(l,f,w){var L=f(l);return Vr(l)?L:kt(L,w(l))}function dr(l){return l==null?l===void 0?ue:E:nt&&nt in Object(l)?Rt(l):gs(l)}function fs(l){return Et(l)&&dr(l)==a}function ps(l,f,w,L,de){return l===f?!0:l==null||f==null||!Et(l)&&!Et(f)?l!==l&&f!==f:oo(l,f,w,L,ps,de)}function oo(l,f,w,L,de,oe){var ve=Vr(l),me=Vr(f),ke=ve?u:bt(l),Ee=me?u:bt(f);ke=ke==a?S:ke,Ee=Ee==a?S:Ee;var qe=ke==S,Ge=Ee==S,Ie=ke==Ee;if(Ie&&Ur(l)){if(!Ur(f))return!1;ve=!0,qe=!1}if(Ie&&!qe)return oe||(oe=new yt),ve||Es(l)?Tn(l,f,w,L,de,oe):co(l,f,ke,w,L,de,oe);if(!(w&s)){var Fe=qe&&Ze.call(l,"__wrapped__"),Me=Ge&&Ze.call(f,"__wrapped__");if(Fe||Me){var zt=Fe?l.value():l,Ot=Me?f.value():f;return oe||(oe=new yt),de(zt,Ot,w,L,oe)}}return Ie?(oe||(oe=new yt),ho(l,f,w,L,de,oe)):!1}function ao(l){if(!bs(l)||mo(l))return!1;var f=ys(l)?Pi:K;return f.test(He(l))}function lo(l){return Et(l)&&Nn(l.length)&&!!H[dr(l)]}function uo(l){if(!vo(l))return cr(l);var f=[];for(var w in Object(l))Ze.call(l,w)&&w!="constructor"&&f.push(w);return f}function Tn(l,f,w,L,de,oe){var ve=w&s,me=l.length,ke=f.length;if(me!=ke&&!(ve&&ke>me))return!1;var Ee=oe.get(l);if(Ee&&oe.get(f))return Ee==f;var qe=-1,Ge=!0,Ie=w&i?new Fr:void 0;for(oe.set(l,f),oe.set(f,l);++qe<me;){var Fe=l[qe],Me=f[qe];if(L)var zt=ve?L(Me,Fe,qe,f,l,oe):L(Fe,Me,qe,l,f,oe);if(zt!==void 0){if(zt)continue;Ge=!1;break}if(Ie){if(!Ut(f,function(Ot,pr){if(!Lr(Ie,pr)&&(Fe===Ot||de(Fe,Ot,w,L,oe)))return Ie.push(pr)})){Ge=!1;break}}else if(!(Fe===Me||de(Fe,Me,w,L,oe))){Ge=!1;break}}return oe.delete(l),oe.delete(f),Ge}function co(l,f,w,L,de,oe,ve){switch(w){case M:if(l.byteLength!=f.byteLength||l.byteOffset!=f.byteOffset)return!1;l=l.buffer,f=f.buffer;case b:return!(l.byteLength!=f.byteLength||!oe(new us(l),new us(f)));case h:case g:case y:return ms(+l,+f);case d:return l.name==f.name&&l.message==f.message;case _:case I:return l==f+"";case p:var me=is;case P:var ke=L&s;if(me||(me=vt),l.size!=f.size&&!ke)return!1;var Ee=ve.get(l);if(Ee)return Ee==f;L|=i,ve.set(l,f);var qe=Tn(me(l),me(f),L,de,oe,ve);return ve.delete(l),qe;case te:if(_n)return _n.call(l)==_n.call(f)}return!1}function ho(l,f,w,L,de,oe){var ve=w&s,me=fr(l),ke=me.length,Ee=fr(f),qe=Ee.length;if(ke!=qe&&!ve)return!1;for(var Ge=ke;Ge--;){var Ie=me[Ge];if(!(ve?Ie in f:Ze.call(f,Ie)))return!1}var Fe=oe.get(l);if(Fe&&oe.get(f))return Fe==f;var Me=!0;oe.set(l,f),oe.set(f,l);for(var zt=ve;++Ge<ke;){Ie=me[Ge];var Ot=l[Ie],pr=f[Ie];if(L)var pl=ve?L(pr,Ot,Ie,f,l,oe):L(Ot,pr,Ie,l,f,oe);if(!(pl===void 0?Ot===pr||de(Ot,pr,w,L,oe):pl)){Me=!1;break}zt||(zt=Ie=="constructor")}if(Me&&!zt){var ws=l.constructor,xs=f.constructor;ws!=xs&&"constructor"in l&&"constructor"in f&&!(typeof ws=="function"&&ws instanceof ws&&typeof xs=="function"&&xs instanceof xs)&&(Me=!1)}return oe.delete(l),oe.delete(f),Me}function fr(l){return Cn(l,In,fo)}function st(l,f){var w=l.__data__;return go(f)?w[typeof f=="string"?"string":"hash"]:w.map}function It(l,f){var w=mn(l,f);return ao(w)?w:void 0}function Rt(l){var f=Ze.call(l,nt),w=l[nt];try{l[nt]=void 0;var L=!0}catch{}var de=ls.call(l);return L&&(f?l[nt]=w:delete l[nt]),de}var fo=qr?function(l){return l==null?[]:(l=Object(l),be(qr(l),function(f){return Br.call(l,f)}))}:bo,bt=dr;(En&&bt(new En(new ArrayBuffer(1)))!=M||hr&&bt(new hr)!=p||wn&&bt(wn.resolve())!=x||xn&&bt(new xn)!=P||Sn&&bt(new Sn)!=ie)&&(bt=function(l){var f=dr(l),w=f==S?l.constructor:void 0,L=w?He(w):"";if(L)switch(L){case cs:return M;case Nt:return p;case Bi:return x;case qi:return P;case Fi:return ie}return f});function po(l,f){return f=f??o,!!f&&(typeof l=="number"||z.test(l))&&l>-1&&l%1==0&&l<f}function go(l){var f=typeof l;return f=="string"||f=="number"||f=="symbol"||f=="boolean"?l!=="__proto__":l===null}function mo(l){return!!as&&as in l}function vo(l){var f=l&&l.constructor,w=typeof f=="function"&&f.prototype||lr;return l===w}function gs(l){return ls.call(l)}function He(l){if(l!=null){try{return vn.call(l)}catch{}try{return l+""}catch{}}return""}function ms(l,f){return l===f||l!==l&&f!==f}var vs=fs((function(){return arguments})())?fs:function(l){return Et(l)&&Ze.call(l,"callee")&&!Br.call(l,"callee")},Vr=Array.isArray;function kn(l){return l!=null&&Nn(l.length)&&!ys(l)}var Ur=bn||Eo;function yo(l,f){return ps(l,f)}function ys(l){if(!bs(l))return!1;var f=dr(l);return f==m||f==v||f==c||f==N}function Nn(l){return typeof l=="number"&&l>-1&&l%1==0&&l<=o}function bs(l){var f=typeof l;return l!=null&&(f=="object"||f=="function")}function Et(l){return l!=null&&typeof l=="object"}var Es=ge?Mi(ge):lo;function In(l){return kn(l)?io(l):uo(l)}function bo(){return[]}function Eo(){return!1}n.exports=yo})(Pn,Pn.exports)),Pn.exports}var Ts={},hu;function Dv(){if(hu)return Ts;hu=1,Object.defineProperty(Ts,"__esModule",{value:!0});const n=Ah(),e=Ch();var t;return(function(r){function s(u={},c={},h=!1){typeof u!="object"&&(u={}),typeof c!="object"&&(c={});let g=n(c);h||(g=Object.keys(g).reduce((d,m)=>(g[m]!=null&&(d[m]=g[m]),d),{}));for(const d in u)u[d]!==void 0&&c[d]===void 0&&(g[d]=u[d]);return Object.keys(g).length>0?g:void 0}r.compose=s;function i(u={},c={}){typeof u!="object"&&(u={}),typeof c!="object"&&(c={});const h=Object.keys(u).concat(Object.keys(c)).reduce((g,d)=>(e(u[d],c[d])||(g[d]=c[d]===void 0?null:c[d]),g),{});return Object.keys(h).length>0?h:void 0}r.diff=i;function o(u={},c={}){u=u||{};const h=Object.keys(c).reduce((g,d)=>(c[d]!==u[d]&&u[d]!==void 0&&(g[d]=c[d]),g),{});return Object.keys(u).reduce((g,d)=>(u[d]!==c[d]&&c[d]===void 0&&(g[d]=null),g),h)}r.invert=o;function a(u,c,h=!1){if(typeof u!="object")return c;if(typeof c!="object")return;if(!h)return c;const g=Object.keys(c).reduce((d,m)=>(u[m]===void 0&&(d[m]=c[m]),d),{});return Object.keys(g).length>0?g:void 0}r.transform=a})(t||(t={})),Ts.default=t,Ts}var ks={},du;function Th(){if(du)return ks;du=1,Object.defineProperty(ks,"__esModule",{value:!0});var n;return(function(e){function t(r){return typeof r.delete=="number"?r.delete:typeof r.retain=="number"?r.retain:typeof r.retain=="object"&&r.retain!==null?1:typeof r.insert=="string"?r.insert.length:1}e.length=t})(n||(n={})),ks.default=n,ks}var Ns={},fu;function Pv(){if(fu)return Ns;fu=1,Object.defineProperty(Ns,"__esModule",{value:!0});const n=Th();class e{constructor(r){this.ops=r,this.index=0,this.offset=0}hasNext(){return this.peekLength()<1/0}next(r){r||(r=1/0);const s=this.ops[this.index];if(s){const i=this.offset,o=n.default.length(s);if(r>=o-i?(r=o-i,this.index+=1,this.offset=0):this.offset+=r,typeof s.delete=="number")return{delete:r};{const a={};return s.attributes&&(a.attributes=s.attributes),typeof s.retain=="number"?a.retain=r:typeof s.retain=="object"&&s.retain!==null?a.retain=s.retain:typeof s.insert=="string"?a.insert=s.insert.substr(i,r):a.insert=s.insert,a}}else return{retain:1/0}}peek(){return this.ops[this.index]}peekLength(){return this.ops[this.index]?n.default.length(this.ops[this.index])-this.offset:1/0}peekType(){const r=this.ops[this.index];return r?typeof r.delete=="number"?"delete":typeof r.retain=="number"||typeof r.retain=="object"&&r.retain!==null?"retain":"insert":"retain"}rest(){if(this.hasNext()){if(this.offset===0)return this.ops.slice(this.index);{const r=this.offset,s=this.index,i=this.next(),o=this.ops.slice(this.index);return this.offset=r,this.index=s,[i].concat(o)}}else return[]}}return Ns.default=e,Ns}var pu;function Bv(){return pu||(pu=1,(function(n,e){Object.defineProperty(e,"__esModule",{value:!0}),e.AttributeMap=e.OpIterator=e.Op=void 0;const t=Mv(),r=Ah(),s=Ch(),i=Dv();e.AttributeMap=i.default;const o=Th();e.Op=o.default;const a=Pv();e.OpIterator=a.default;const u="\0",c=(g,d)=>{if(typeof g!="object"||g===null)throw new Error(`cannot retain a ${typeof g}`);if(typeof d!="object"||d===null)throw new Error(`cannot retain a ${typeof d}`);const m=Object.keys(g)[0];if(!m||m!==Object.keys(d)[0])throw new Error(`embed types not matched: ${m} != ${Object.keys(d)[0]}`);return[m,g[m],d[m]]};class h{constructor(d){Array.isArray(d)?this.ops=d:d!=null&&Array.isArray(d.ops)?this.ops=d.ops:this.ops=[]}static registerEmbed(d,m){this.handlers[d]=m}static unregisterEmbed(d){delete this.handlers[d]}static getHandler(d){const m=this.handlers[d];if(!m)throw new Error(`no handlers for embed type "${d}"`);return m}insert(d,m){const v={};return typeof d=="string"&&d.length===0?this:(v.insert=d,m!=null&&typeof m=="object"&&Object.keys(m).length>0&&(v.attributes=m),this.push(v))}delete(d){return d<=0?this:this.push({delete:d})}retain(d,m){if(typeof d=="number"&&d<=0)return this;const v={retain:d};return m!=null&&typeof m=="object"&&Object.keys(m).length>0&&(v.attributes=m),this.push(v)}push(d){let m=this.ops.length,v=this.ops[m-1];if(d=r(d),typeof v=="object"){if(typeof d.delete=="number"&&typeof v.delete=="number")return this.ops[m-1]={delete:v.delete+d.delete},this;if(typeof v.delete=="number"&&d.insert!=null&&(m-=1,v=this.ops[m-1],typeof v!="object"))return this.ops.unshift(d),this;if(s(d.attributes,v.attributes)){if(typeof d.insert=="string"&&typeof v.insert=="string")return this.ops[m-1]={insert:v.insert+d.insert},typeof d.attributes=="object"&&(this.ops[m-1].attributes=d.attributes),this;if(typeof d.retain=="number"&&typeof v.retain=="number")return this.ops[m-1]={retain:v.retain+d.retain},typeof d.attributes=="object"&&(this.ops[m-1].attributes=d.attributes),this}}return m===this.ops.length?this.ops.push(d):this.ops.splice(m,0,d),this}chop(){const d=this.ops[this.ops.length-1];return d&&typeof d.retain=="number"&&!d.attributes&&this.ops.pop(),this}filter(d){return this.ops.filter(d)}forEach(d){this.ops.forEach(d)}map(d){return this.ops.map(d)}partition(d){const m=[],v=[];return this.forEach(p=>{(d(p)?m:v).push(p)}),[m,v]}reduce(d,m){return this.ops.reduce(d,m)}changeLength(){return this.reduce((d,m)=>m.insert?d+o.default.length(m):m.delete?d-m.delete:d,0)}length(){return this.reduce((d,m)=>d+o.default.length(m),0)}slice(d=0,m=1/0){const v=[],p=new a.default(this.ops);let y=0;for(;y<m&&p.hasNext();){let E;y<d?E=p.next(d-y):(E=p.next(m-y),v.push(E)),y+=o.default.length(E)}return new h(v)}compose(d){const m=new a.default(this.ops),v=new a.default(d.ops),p=[],y=v.peek();if(y!=null&&typeof y.retain=="number"&&y.attributes==null){let S=y.retain;for(;m.peekType()==="insert"&&m.peekLength()<=S;)S-=m.peekLength(),p.push(m.next());y.retain-S>0&&v.next(y.retain-S)}const E=new h(p);for(;m.hasNext()||v.hasNext();)if(v.peekType()==="insert")E.push(v.next());else if(m.peekType()==="delete")E.push(m.next());else{const S=Math.min(m.peekLength(),v.peekLength()),x=m.next(S),N=v.next(S);if(N.retain){const _={};if(typeof x.retain=="number")_.retain=typeof N.retain=="number"?S:N.retain;else if(typeof N.retain=="number")x.retain==null?_.insert=x.insert:_.retain=x.retain;else{const I=x.retain==null?"insert":"retain",[te,ue,ie]=c(x[I],N.retain),b=h.getHandler(te);_[I]={[te]:b.compose(ue,ie,I==="retain")}}const P=i.default.compose(x.attributes,N.attributes,typeof x.retain=="number");if(P&&(_.attributes=P),E.push(_),!v.hasNext()&&s(E.ops[E.ops.length-1],_)){const I=new h(m.rest());return E.concat(I).chop()}}else typeof N.delete=="number"&&(typeof x.retain=="number"||typeof x.retain=="object"&&x.retain!==null)&&E.push(N)}return E.chop()}concat(d){const m=new h(this.ops.slice());return d.ops.length>0&&(m.push(d.ops[0]),m.ops=m.ops.concat(d.ops.slice(1))),m}diff(d,m){if(this.ops===d.ops)return new h;const v=[this,d].map(x=>x.map(N=>{if(N.insert!=null)return typeof N.insert=="string"?N.insert:u;const _=x===d?"on":"with";throw new Error("diff() called "+_+" non-document")}).join("")),p=new h,y=t(v[0],v[1],m,!0),E=new a.default(this.ops),S=new a.default(d.ops);return y.forEach(x=>{let N=x[1].length;for(;N>0;){let _=0;switch(x[0]){case t.INSERT:_=Math.min(S.peekLength(),N),p.push(S.next(_));break;case t.DELETE:_=Math.min(N,E.peekLength()),E.next(_),p.delete(_);break;case t.EQUAL:_=Math.min(E.peekLength(),S.peekLength(),N);const P=E.next(_),I=S.next(_);s(P.insert,I.insert)?p.retain(_,i.default.diff(P.attributes,I.attributes)):p.push(I).delete(_);break}N-=_}}),p.chop()}eachLine(d,m=`
106
- `){const v=new a.default(this.ops);let p=new h,y=0;for(;v.hasNext();){if(v.peekType()!=="insert")return;const E=v.peek(),S=o.default.length(E)-v.peekLength(),x=typeof E.insert=="string"?E.insert.indexOf(m,S)-S:-1;if(x<0)p.push(v.next());else if(x>0)p.push(v.next(x));else{if(d(p,v.next(1).attributes||{},y)===!1)return;y+=1,p=new h}}p.length()>0&&d(p,{},y)}invert(d){const m=new h;return this.reduce((v,p)=>{if(p.insert)m.delete(o.default.length(p));else{if(typeof p.retain=="number"&&p.attributes==null)return m.retain(p.retain),v+p.retain;if(p.delete||typeof p.retain=="number"){const y=p.delete||p.retain;return d.slice(v,v+y).forEach(S=>{p.delete?m.push(S):p.retain&&p.attributes&&m.retain(o.default.length(S),i.default.invert(p.attributes,S.attributes))}),v+y}else if(typeof p.retain=="object"&&p.retain!==null){const y=d.slice(v,v+1),E=new a.default(y.ops).next(),[S,x,N]=c(p.retain,E.insert),_=h.getHandler(S);return m.retain({[S]:_.invert(x,N)},i.default.invert(p.attributes,E.attributes)),v+1}}return v},0),m.chop()}transform(d,m=!1){if(m=!!m,typeof d=="number")return this.transformPosition(d,m);const v=d,p=new a.default(this.ops),y=new a.default(v.ops),E=new h;for(;p.hasNext()||y.hasNext();)if(p.peekType()==="insert"&&(m||y.peekType()!=="insert"))E.retain(o.default.length(p.next()));else if(y.peekType()==="insert")E.push(y.next());else{const S=Math.min(p.peekLength(),y.peekLength()),x=p.next(S),N=y.next(S);if(x.delete)continue;if(N.delete)E.push(N);else{const _=x.retain,P=N.retain;let I=typeof P=="object"&&P!==null?P:S;if(typeof _=="object"&&_!==null&&typeof P=="object"&&P!==null){const te=Object.keys(_)[0];if(te===Object.keys(P)[0]){const ue=h.getHandler(te);ue&&(I={[te]:ue.transform(_[te],P[te],m)})}}E.retain(I,i.default.transform(x.attributes,N.attributes,m))}}return E.chop()}transformPosition(d,m=!1){m=!!m;const v=new a.default(this.ops);let p=0;for(;v.hasNext()&&p<=d;){const y=v.peekLength(),E=v.peekType();if(v.next(),E==="delete"){d-=Math.min(y,d-p);continue}else E==="insert"&&(p<d||!m)&&(d+=y);p+=y}return d}}h.Op=o.default,h.OpIterator=a.default,h.AttributeMap=i.default,h.handlers={},e.default=h,n.exports=h,n.exports.default=h})(Cs,Cs.exports)),Cs.exports}var tt=Bv();const re=De.getDefaultExportFromCjs(tt);class gt extends Ye{static value(){}optimize(){(this.prev||this.next)&&this.remove()}length(){return 0}value(){return""}}gt.blotName="break";gt.tagName="BR";let ft=class extends ti{};const qv={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function bi(n){return n.replace(/[&<>"']/g,e=>qv[e])}const wt=class wt extends Wa{static compare(e,t){const r=wt.order.indexOf(e),s=wt.order.indexOf(t);return r>=0||s>=0?r-s:e===t?0:e<t?-1:1}formatAt(e,t,r,s){if(wt.compare(this.statics.blotName,r)<0&&this.scroll.query(r,ne.BLOT)){const i=this.isolate(e,t);s&&i.wrap(r,s)}else super.formatAt(e,t,r,s)}optimize(e){if(super.optimize(e),this.parent instanceof wt&&wt.compare(this.statics.blotName,this.parent.statics.blotName)>0){const t=this.parent.isolate(this.offset(),this.length());this.moveChildren(t),t.wrap(this)}}};J(wt,"allowedChildren",[wt,gt,Ye,ft]),J(wt,"order",["cursor","inline","link","underline","strike","italic","bold","script","code"]);let Ct=wt;const gu=1;class Pe extends Wn{constructor(){super(...arguments);J(this,"cache",{})}delta(){return this.cache.delta==null&&(this.cache.delta=kh(this)),this.cache.delta}deleteAt(t,r){super.deleteAt(t,r),this.cache={}}formatAt(t,r,s,i){r<=0||(this.scroll.query(s,ne.BLOCK)?t+r===this.length()&&this.format(s,i):super.formatAt(t,Math.min(r,this.length()-t-1),s,i),this.cache={})}insertAt(t,r,s){if(s!=null){super.insertAt(t,r,s),this.cache={};return}if(r.length===0)return;const i=r.split(`
107
- `),o=i.shift();o.length>0&&(t<this.length()-1||this.children.tail==null?super.insertAt(Math.min(t,this.length()-1),o):this.children.tail.insertAt(this.children.tail.length(),o),this.cache={});let a=this;i.reduce((u,c)=>(a=a.split(u,!0),a.insertAt(0,c),c.length),t+o.length)}insertBefore(t,r){const{head:s}=this.children;super.insertBefore(t,r),s instanceof gt&&s.remove(),this.cache={}}length(){return this.cache.length==null&&(this.cache.length=super.length()+gu),this.cache.length}moveChildren(t,r){super.moveChildren(t,r),this.cache={}}optimize(t){super.optimize(t),this.cache={}}path(t){return super.path(t,!0)}removeChild(t){super.removeChild(t),this.cache={}}split(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(r&&(t===0||t>=this.length()-gu)){const i=this.clone();return t===0?(this.parent.insertBefore(i,this),this):(this.parent.insertBefore(i,this.next),i)}const s=super.split(t,r);return this.cache={},s}}Pe.blotName="block";Pe.tagName="P";Pe.defaultChild=gt;Pe.allowedChildren=[gt,Ct,Ye,ft];class et extends Ye{attach(){super.attach(),this.attributes=new vi(this.domNode)}delta(){return new re().insert(this.value(),{...this.formats(),...this.attributes.values()})}format(e,t){const r=this.scroll.query(e,ne.BLOCK_ATTRIBUTE);r!=null&&this.attributes.attribute(r,t)}formatAt(e,t,r,s){this.format(r,s)}insertAt(e,t,r){if(r!=null){super.insertAt(e,t,r);return}const s=t.split(`
108
- `),i=s.pop(),o=s.map(u=>{const c=this.scroll.create(Pe.blotName);return c.insertAt(0,u),c}),a=this.split(e);o.forEach(u=>{this.parent.insertBefore(u,a)}),i&&this.parent.insertBefore(this.scroll.create("text",i),a)}}et.scope=ne.BLOCK_BLOT;function kh(n){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return n.descendants(je).reduce((t,r)=>r.length()===0?t:t.insert(r.value(),Qe(r,{},e)),new re).insert(`
109
- `,Qe(n))}function Qe(n){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;return n==null||("formats"in n&&typeof n.formats=="function"&&(e={...e,...n.formats()},t&&delete e["code-token"]),n.parent==null||n.parent.statics.blotName==="scroll"||n.parent.statics.scope!==n.statics.scope)?e:Qe(n.parent,e,t)}const Xe=class Xe extends Ye{static value(){}constructor(e,t,r){super(e,t),this.selection=r,this.textNode=document.createTextNode(Xe.CONTENTS),this.domNode.appendChild(this.textNode),this.savedLength=0}detach(){this.parent!=null&&this.parent.removeChild(this)}format(e,t){if(this.savedLength!==0){super.format(e,t);return}let r=this,s=0;for(;r!=null&&r.statics.scope!==ne.BLOCK_BLOT;)s+=r.offset(r.parent),r=r.parent;r!=null&&(this.savedLength=Xe.CONTENTS.length,r.optimize(),r.formatAt(s,Xe.CONTENTS.length,e,t),this.savedLength=0)}index(e,t){return e===this.textNode?0:super.index(e,t)}length(){return this.savedLength}position(){return[this.textNode,this.textNode.data.length]}remove(){super.remove(),this.parent=null}restore(){if(this.selection.composing||this.parent==null)return null;const e=this.selection.getNativeRange();for(;this.domNode.lastChild!=null&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);const t=this.prev instanceof ft?this.prev:null,r=t?t.length():0,s=this.next instanceof ft?this.next:null,i=s?s.text:"",{textNode:o}=this,a=o.data.split(Xe.CONTENTS).join("");o.data=Xe.CONTENTS;let u;if(t)u=t,(a||s)&&(t.insertAt(t.length(),a+i),s&&s.remove());else if(s)u=s,s.insertAt(0,a);else{const c=document.createTextNode(a);u=this.scroll.create(c),this.parent.insertBefore(u,this)}if(this.remove(),e){const c=(d,m)=>t&&d===t.domNode?m:d===o?r+m-1:s&&d===s.domNode?r+a.length+m:null,h=c(e.start.node,e.start.offset),g=c(e.end.node,e.end.offset);if(h!==null&&g!==null)return{startNode:u.domNode,startOffset:h,endNode:u.domNode,endOffset:g}}return null}update(e,t){if(e.some(r=>r.type==="characterData"&&r.target===this.textNode)){const r=this.restore();r&&(t.range=r)}}optimize(e){super.optimize(e);let{parent:t}=this;for(;t;){if(t.domNode.tagName==="A"){this.savedLength=Xe.CONTENTS.length,t.isolate(this.offset(t),this.length()).unwrap(),this.savedLength=0;break}t=t.parent}}value(){return""}};J(Xe,"blotName","cursor"),J(Xe,"className","ql-cursor"),J(Xe,"tagName","span"),J(Xe,"CONTENTS","\uFEFF");let un=Xe;var Io={exports:{}},mu;function Fv(){return mu||(mu=1,(function(n){var e=Object.prototype.hasOwnProperty,t="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(t=!1));function s(u,c,h){this.fn=u,this.context=c,this.once=h||!1}function i(u,c,h,g,d){if(typeof h!="function")throw new TypeError("The listener must be a function");var m=new s(h,g||u,d),v=t?t+c:c;return u._events[v]?u._events[v].fn?u._events[v]=[u._events[v],m]:u._events[v].push(m):(u._events[v]=m,u._eventsCount++),u}function o(u,c){--u._eventsCount===0?u._events=new r:delete u._events[c]}function a(){this._events=new r,this._eventsCount=0}a.prototype.eventNames=function(){var c=[],h,g;if(this._eventsCount===0)return c;for(g in h=this._events)e.call(h,g)&&c.push(t?g.slice(1):g);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(h)):c},a.prototype.listeners=function(c){var h=t?t+c:c,g=this._events[h];if(!g)return[];if(g.fn)return[g.fn];for(var d=0,m=g.length,v=new Array(m);d<m;d++)v[d]=g[d].fn;return v},a.prototype.listenerCount=function(c){var h=t?t+c:c,g=this._events[h];return g?g.fn?1:g.length:0},a.prototype.emit=function(c,h,g,d,m,v){var p=t?t+c:c;if(!this._events[p])return!1;var y=this._events[p],E=arguments.length,S,x;if(y.fn){switch(y.once&&this.removeListener(c,y.fn,void 0,!0),E){case 1:return y.fn.call(y.context),!0;case 2:return y.fn.call(y.context,h),!0;case 3:return y.fn.call(y.context,h,g),!0;case 4:return y.fn.call(y.context,h,g,d),!0;case 5:return y.fn.call(y.context,h,g,d,m),!0;case 6:return y.fn.call(y.context,h,g,d,m,v),!0}for(x=1,S=new Array(E-1);x<E;x++)S[x-1]=arguments[x];y.fn.apply(y.context,S)}else{var N=y.length,_;for(x=0;x<N;x++)switch(y[x].once&&this.removeListener(c,y[x].fn,void 0,!0),E){case 1:y[x].fn.call(y[x].context);break;case 2:y[x].fn.call(y[x].context,h);break;case 3:y[x].fn.call(y[x].context,h,g);break;case 4:y[x].fn.call(y[x].context,h,g,d);break;default:if(!S)for(_=1,S=new Array(E-1);_<E;_++)S[_-1]=arguments[_];y[x].fn.apply(y[x].context,S)}}return!0},a.prototype.on=function(c,h,g){return i(this,c,h,g,!1)},a.prototype.once=function(c,h,g){return i(this,c,h,g,!0)},a.prototype.removeListener=function(c,h,g,d){var m=t?t+c:c;if(!this._events[m])return this;if(!h)return o(this,m),this;var v=this._events[m];if(v.fn)v.fn===h&&(!d||v.once)&&(!g||v.context===g)&&o(this,m);else{for(var p=0,y=[],E=v.length;p<E;p++)(v[p].fn!==h||d&&!v[p].once||g&&v[p].context!==g)&&y.push(v[p]);y.length?this._events[m]=y.length===1?y[0]:y:o(this,m)}return this},a.prototype.removeAllListeners=function(c){var h;return c?(h=t?t+c:c,this._events[h]&&o(this,h)):(this._events=new r,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=t,a.EventEmitter=a,n.exports=a})(Io)),Io.exports}var jv=Fv();const $v=De.getDefaultExportFromCjs(jv),pa=new WeakMap,ga=["error","warn","log","info"];let ma="warn";function Nh(n){if(ma&&ga.indexOf(n)<=ga.indexOf(ma)){for(var e=arguments.length,t=new Array(e>1?e-1:0),r=1;r<e;r++)t[r-1]=arguments[r];console[n](...t)}}function Vt(n){return ga.reduce((e,t)=>(e[t]=Nh.bind(console,t,n),e),{})}Vt.level=n=>{ma=n};Nh.level=Vt.level;const Ro=Vt("quill:events"),Vv=["selectionchange","mousedown","mouseup","click"];Vv.forEach(n=>{document.addEventListener(n,function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];Array.from(document.querySelectorAll(".ql-container")).forEach(s=>{const i=pa.get(s);i&&i.emitter&&i.emitter.handleDOM(...t)})})});class ee extends $v{constructor(){super(),this.domListeners={},this.on("error",Ro.error)}emit(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return Ro.log.call(Ro,...t),super.emit(...t)}handleDOM(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),s=1;s<t;s++)r[s-1]=arguments[s];(this.domListeners[e.type]||[]).forEach(i=>{let{node:o,handler:a}=i;(e.target===o||o.contains(e.target))&&a(e,...r)})}listenDOM(e,t,r){this.domListeners[e]||(this.domListeners[e]=[]),this.domListeners[e].push({node:t,handler:r})}}J(ee,"events",{EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_BLOT_MOUNT:"scroll-blot-mount",SCROLL_BLOT_UNMOUNT:"scroll-blot-unmount",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SCROLL_EMBED_UPDATE:"scroll-embed-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change",COMPOSITION_BEFORE_START:"composition-before-start",COMPOSITION_START:"composition-start",COMPOSITION_BEFORE_END:"composition-before-end",COMPOSITION_END:"composition-end"}),J(ee,"sources",{API:"api",SILENT:"silent",USER:"user"});const Oo=Vt("quill:selection");class _r{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;this.index=e,this.length=t}}class Uv{constructor(e,t){this.emitter=t,this.scroll=e,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=this.scroll.create("cursor",this),this.savedRange=new _r(0,0),this.lastRange=this.savedRange,this.lastNative=null,this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,()=>{!this.mouseDown&&!this.composing&&setTimeout(this.update.bind(this,ee.sources.USER),1)}),this.emitter.on(ee.events.SCROLL_BEFORE_UPDATE,()=>{if(!this.hasFocus())return;const r=this.getNativeRange();r!=null&&r.start.node!==this.cursor.textNode&&this.emitter.once(ee.events.SCROLL_UPDATE,(s,i)=>{try{this.root.contains(r.start.node)&&this.root.contains(r.end.node)&&this.setNativeRange(r.start.node,r.start.offset,r.end.node,r.end.offset);const o=i.some(a=>a.type==="characterData"||a.type==="childList"||a.type==="attributes"&&a.target===this.root);this.update(o?ee.sources.SILENT:s)}catch{}})}),this.emitter.on(ee.events.SCROLL_OPTIMIZE,(r,s)=>{if(s.range){const{startNode:i,startOffset:o,endNode:a,endOffset:u}=s.range;this.setNativeRange(i,o,a,u),this.update(ee.sources.SILENT)}}),this.update(ee.sources.SILENT)}handleComposition(){this.emitter.on(ee.events.COMPOSITION_BEFORE_START,()=>{this.composing=!0}),this.emitter.on(ee.events.COMPOSITION_END,()=>{if(this.composing=!1,this.cursor.parent){const e=this.cursor.restore();if(!e)return;setTimeout(()=>{this.setNativeRange(e.startNode,e.startOffset,e.endNode,e.endOffset)},1)}})}handleDragging(){this.emitter.listenDOM("mousedown",document.body,()=>{this.mouseDown=!0}),this.emitter.listenDOM("mouseup",document.body,()=>{this.mouseDown=!1,this.update(ee.sources.USER)})}focus(){this.hasFocus()||(this.root.focus({preventScroll:!0}),this.setRange(this.savedRange))}format(e,t){this.scroll.update();const r=this.getNativeRange();if(!(r==null||!r.native.collapsed||this.scroll.query(e,ne.BLOCK))){if(r.start.node!==this.cursor.textNode){const s=this.scroll.find(r.start.node,!1);if(s==null)return;if(s instanceof je){const i=s.split(r.start.offset);s.parent.insertBefore(this.cursor,i)}else s.insertBefore(this.cursor,r.start.node);this.cursor.attach()}this.cursor.format(e,t),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}getBounds(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;const r=this.scroll.length();e=Math.min(e,r-1),t=Math.min(e+t,r-1)-e;let s,[i,o]=this.scroll.leaf(e);if(i==null)return null;if(t>0&&o===i.length()){const[h]=this.scroll.leaf(e+1);if(h){const[g]=this.scroll.line(e),[d]=this.scroll.line(e+1);g===d&&(i=h,o=0)}}[s,o]=i.position(o,!0);const a=document.createRange();if(t>0)return a.setStart(s,o),[i,o]=this.scroll.leaf(e+t),i==null?null:([s,o]=i.position(o,!0),a.setEnd(s,o),a.getBoundingClientRect());let u="left",c;if(s instanceof Text){if(!s.data.length)return null;o<s.data.length?(a.setStart(s,o),a.setEnd(s,o+1)):(a.setStart(s,o-1),a.setEnd(s,o),u="right"),c=a.getBoundingClientRect()}else{if(!(i.domNode instanceof Element))return null;c=i.domNode.getBoundingClientRect(),o>0&&(u="right")}return{bottom:c.top+c.height,height:c.height,left:c[u],right:c[u],top:c.top,width:0}}getNativeRange(){const e=document.getSelection();if(e==null||e.rangeCount<=0)return null;const t=e.getRangeAt(0);if(t==null)return null;const r=this.normalizeNative(t);return Oo.info("getNativeRange",r),r}getRange(){const e=this.scroll.domNode;if("isConnected"in e&&!e.isConnected)return[null,null];const t=this.getNativeRange();return t==null?[null,null]:[this.normalizedToRange(t),t]}hasFocus(){return document.activeElement===this.root||document.activeElement!=null&&Lo(this.root,document.activeElement)}normalizedToRange(e){const t=[[e.start.node,e.start.offset]];e.native.collapsed||t.push([e.end.node,e.end.offset]);const r=t.map(o=>{const[a,u]=o,c=this.scroll.find(a,!0),h=c.offset(this.scroll);return u===0?h:c instanceof je?h+c.index(a,u):h+c.length()}),s=Math.min(Math.max(...r),this.scroll.length()-1),i=Math.min(s,...r);return new _r(i,s-i)}normalizeNative(e){if(!Lo(this.root,e.startContainer)||!e.collapsed&&!Lo(this.root,e.endContainer))return null;const t={start:{node:e.startContainer,offset:e.startOffset},end:{node:e.endContainer,offset:e.endOffset},native:e};return[t.start,t.end].forEach(r=>{let{node:s,offset:i}=r;for(;!(s instanceof Text)&&s.childNodes.length>0;)if(s.childNodes.length>i)s=s.childNodes[i],i=0;else if(s.childNodes.length===i)s=s.lastChild,s instanceof Text?i=s.data.length:s.childNodes.length>0?i=s.childNodes.length:i=s.childNodes.length+1;else break;r.node=s,r.offset=i}),t}rangeToNative(e){const t=this.scroll.length(),r=(s,i)=>{s=Math.min(t-1,s);const[o,a]=this.scroll.leaf(s);return o?o.position(a,i):[null,-1]};return[...r(e.index,!1),...r(e.index+e.length,!0)]}setNativeRange(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e,s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:t,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(Oo.info("setNativeRange",e,t,r,s),e!=null&&(this.root.parentNode==null||e.parentNode==null||r.parentNode==null))return;const o=document.getSelection();if(o!=null)if(e!=null){this.hasFocus()||this.root.focus({preventScroll:!0});const{native:a}=this.getNativeRange()||{};if(a==null||i||e!==a.startContainer||t!==a.startOffset||r!==a.endContainer||s!==a.endOffset){e instanceof Element&&e.tagName==="BR"&&(t=Array.from(e.parentNode.childNodes).indexOf(e),e=e.parentNode),r instanceof Element&&r.tagName==="BR"&&(s=Array.from(r.parentNode.childNodes).indexOf(r),r=r.parentNode);const u=document.createRange();u.setStart(e,t),u.setEnd(r,s),o.removeAllRanges(),o.addRange(u)}}else o.removeAllRanges(),this.root.blur()}setRange(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ee.sources.API;if(typeof t=="string"&&(r=t,t=!1),Oo.info("setRange",e),e!=null){const s=this.rangeToNative(e);this.setNativeRange(...s,t)}else this.setNativeRange(null);this.update(r)}update(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ee.sources.USER;const t=this.lastRange,[r,s]=this.getRange();if(this.lastRange=r,this.lastNative=s,this.lastRange!=null&&(this.savedRange=this.lastRange),!Wt(t,this.lastRange)){if(!this.composing&&s!=null&&s.native.collapsed&&s.start.node!==this.cursor.textNode){const o=this.cursor.restore();o&&this.setNativeRange(o.startNode,o.startOffset,o.endNode,o.endOffset)}const i=[ee.events.SELECTION_CHANGE,Jr(this.lastRange),Jr(t),e];this.emitter.emit(ee.events.EDITOR_CHANGE,...i),e!==ee.sources.SILENT&&this.emitter.emit(...i)}}}function Lo(n,e){try{e.parentNode}catch{return!1}return n.contains(e)}const Hv=/^[ -~]*$/;class zv{constructor(e){this.scroll=e,this.delta=this.getDelta()}applyDelta(e){this.scroll.update();let t=this.scroll.length();this.scroll.batchStart();const r=vu(e),s=new re;return Kv(r.ops.slice()).reduce((o,a)=>{const u=tt.Op.length(a);let c=a.attributes||{},h=!1,g=!1;if(a.insert!=null){if(s.retain(u),typeof a.insert=="string"){const v=a.insert;g=!v.endsWith(`
110
- `)&&(t<=o||!!this.scroll.descendant(et,o)[0]),this.scroll.insertAt(o,v);const[p,y]=this.scroll.line(o);let E=er({},Qe(p));if(p instanceof Pe){const[S]=p.descendant(je,y);S&&(E=er(E,Qe(S)))}c=tt.AttributeMap.diff(E,c)||{}}else if(typeof a.insert=="object"){const v=Object.keys(a.insert)[0];if(v==null)return o;const p=this.scroll.query(v,ne.INLINE)!=null;if(p)(t<=o||this.scroll.descendant(et,o)[0])&&(g=!0);else if(o>0){const[y,E]=this.scroll.descendant(je,o-1);y instanceof ft?y.value()[E]!==`
111
- `&&(h=!0):y instanceof Ye&&y.statics.scope===ne.INLINE_BLOT&&(h=!0)}if(this.scroll.insertAt(o,v,a.insert[v]),p){const[y]=this.scroll.descendant(je,o);if(y){const E=er({},Qe(y));c=tt.AttributeMap.diff(E,c)||{}}}}t+=u}else if(s.push(a),a.retain!==null&&typeof a.retain=="object"){const v=Object.keys(a.retain)[0];if(v==null)return o;this.scroll.updateEmbedAt(o,v,a.retain[v])}Object.keys(c).forEach(v=>{this.scroll.formatAt(o,u,v,c[v])});const d=h?1:0,m=g?1:0;return t+=d+m,s.retain(d),s.delete(m),o+u+d+m},0),s.reduce((o,a)=>typeof a.delete=="number"?(this.scroll.deleteAt(o,a.delete),o):o+tt.Op.length(a),0),this.scroll.batchEnd(),this.scroll.optimize(),this.update(r)}deleteText(e,t){return this.scroll.deleteAt(e,t),this.update(new re().retain(e).delete(t))}formatLine(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.scroll.update(),Object.keys(r).forEach(i=>{this.scroll.lines(e,Math.max(t,1)).forEach(o=>{o.format(i,r[i])})}),this.scroll.optimize();const s=new re().retain(e).retain(t,Jr(r));return this.update(s)}formatText(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};Object.keys(r).forEach(i=>{this.scroll.formatAt(e,t,i,r[i])});const s=new re().retain(e).retain(t,Jr(r));return this.update(s)}getContents(e,t){return this.delta.slice(e,e+t)}getDelta(){return this.scroll.lines().reduce((e,t)=>e.concat(t.delta()),new re)}getFormat(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=[],s=[];t===0?this.scroll.path(e).forEach(a=>{const[u]=a;u instanceof Pe?r.push(u):u instanceof je&&s.push(u)}):(r=this.scroll.lines(e,t),s=this.scroll.descendants(je,e,t));const[i,o]=[r,s].map(a=>{const u=a.shift();if(u==null)return{};let c=Qe(u);for(;Object.keys(c).length>0;){const h=a.shift();if(h==null)return c;c=Gv(Qe(h),c)}return c});return{...i,...o}}getHTML(e,t){const[r,s]=this.scroll.line(e);if(r){const i=r.length();return r.length()>=s+t&&!(s===0&&t===i)?Yn(r,s,t,!0):Yn(this.scroll,e,t,!0)}return""}getText(e,t){return this.getContents(e,t).filter(r=>typeof r.insert=="string").map(r=>r.insert).join("")}insertContents(e,t){const r=vu(t),s=new re().retain(e).concat(r);return this.scroll.insertContents(e,r),this.update(s)}insertEmbed(e,t,r){return this.scroll.insertAt(e,t,r),this.update(new re().retain(e).insert({[t]:r}))}insertText(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return t=t.replace(/\r\n/g,`
112
- `).replace(/\r/g,`
113
- `),this.scroll.insertAt(e,t),Object.keys(r).forEach(s=>{this.scroll.formatAt(e,t.length,s,r[s])}),this.update(new re().retain(e).insert(t,Jr(r)))}isBlank(){if(this.scroll.children.length===0)return!0;if(this.scroll.children.length>1)return!1;const e=this.scroll.children.head;if((e==null?void 0:e.statics.blotName)!==Pe.blotName)return!1;const t=e;return t.children.length>1?!1:t.children.head instanceof gt}removeFormat(e,t){const r=this.getText(e,t),[s,i]=this.scroll.line(e+t);let o=0,a=new re;s!=null&&(o=s.length()-i,a=s.delta().slice(i,i+o-1).insert(`
114
- `));const c=this.getContents(e,t+o).diff(new re().insert(r).concat(a)),h=new re().retain(e).concat(c);return this.applyDelta(h)}update(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0;const s=this.delta;if(t.length===1&&t[0].type==="characterData"&&t[0].target.data.match(Hv)&&this.scroll.find(t[0].target)){const i=this.scroll.find(t[0].target),o=Qe(i),a=i.offset(this.scroll),u=t[0].oldValue.replace(un.CONTENTS,""),c=new re().insert(u),h=new re().insert(i.value()),g=r&&{oldRange:yu(r.oldRange,-a),newRange:yu(r.newRange,-a)};e=new re().retain(a).concat(c.diff(h,g)).reduce((m,v)=>v.insert?m.insert(v.insert,o):m.push(v),new re),this.delta=s.compose(e)}else this.delta=this.getDelta(),(!e||!Wt(s.compose(e),this.delta))&&(e=s.diff(this.delta,r));return e}}function Zr(n,e,t){if(n.length===0){const[m]=Mo(t.pop());return e<=0?`</li></${m}>`:`</li></${m}>${Zr([],e-1,t)}`}const[{child:r,offset:s,length:i,indent:o,type:a},...u]=n,[c,h]=Mo(a);if(o>e)return t.push(a),o===e+1?`<${c}><li${h}>${Yn(r,s,i)}${Zr(u,o,t)}`:`<${c}><li>${Zr(n,e+1,t)}`;const g=t[t.length-1];if(o===e&&a===g)return`</li><li${h}>${Yn(r,s,i)}${Zr(u,o,t)}`;const[d]=Mo(t.pop());return`</li></${d}>${Zr(n,e-1,t)}`}function Yn(n,e,t){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if("html"in n&&typeof n.html=="function")return n.html(e,t);if(n instanceof ft)return bi(n.value().slice(e,e+t)).replaceAll(" ","&nbsp;");if(n instanceof dt){if(n.statics.blotName==="list-container"){const c=[];return n.children.forEachAt(e,t,(h,g,d)=>{const m="formats"in h&&typeof h.formats=="function"?h.formats():{};c.push({child:h,offset:g,length:d,indent:m.indent||0,type:m.list})}),Zr(c,-1,[])}const s=[];if(n.children.forEachAt(e,t,(c,h,g)=>{s.push(Yn(c,h,g))}),r||n.statics.blotName==="list")return s.join("");const{outerHTML:i,innerHTML:o}=n.domNode,[a,u]=i.split(`>${o}<`);return a==="<table"?`<table style="border: 1px solid #000;">${s.join("")}<${u}`:`${a}>${s.join("")}<${u}`}return n.domNode instanceof Element?n.domNode.outerHTML:""}function Gv(n,e){return Object.keys(e).reduce((t,r)=>{if(n[r]==null)return t;const s=e[r];return s===n[r]?t[r]=s:Array.isArray(s)?s.indexOf(n[r])<0?t[r]=s.concat([n[r]]):t[r]=s:t[r]=[s,n[r]],t},{})}function Mo(n){const e=n==="ordered"?"ol":"ul";switch(n){case"checked":return[e,' data-list="checked"'];case"unchecked":return[e,' data-list="unchecked"'];default:return[e,""]}}function vu(n){return n.reduce((e,t)=>{if(typeof t.insert=="string"){const r=t.insert.replace(/\r\n/g,`
115
- `).replace(/\r/g,`
116
- `);return e.insert(r,t.attributes)}return e.push(t)},new re)}function yu(n,e){let{index:t,length:r}=n;return new _r(t+e,r)}function Kv(n){const e=[];return n.forEach(t=>{typeof t.insert=="string"?t.insert.split(`
117
- `).forEach((s,i)=>{i&&e.push({insert:`
118
- `,attributes:t.attributes}),s&&e.push({insert:s,attributes:t.attributes})}):e.push(t)}),e}class mt{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.quill=e,this.options=t}}J(mt,"DEFAULTS",{});const Is="\uFEFF";class Za extends Ye{constructor(e,t){super(e,t),this.contentNode=document.createElement("span"),this.contentNode.setAttribute("contenteditable","false"),Array.from(this.domNode.childNodes).forEach(r=>{this.contentNode.appendChild(r)}),this.leftGuard=document.createTextNode(Is),this.rightGuard=document.createTextNode(Is),this.domNode.appendChild(this.leftGuard),this.domNode.appendChild(this.contentNode),this.domNode.appendChild(this.rightGuard)}index(e,t){return e===this.leftGuard?0:e===this.rightGuard?1:super.index(e,t)}restore(e){let t=null,r;const s=e.data.split(Is).join("");if(e===this.leftGuard)if(this.prev instanceof ft){const i=this.prev.length();this.prev.insertAt(i,s),t={startNode:this.prev.domNode,startOffset:i+s.length}}else r=document.createTextNode(s),this.parent.insertBefore(this.scroll.create(r),this),t={startNode:r,startOffset:s.length};else e===this.rightGuard&&(this.next instanceof ft?(this.next.insertAt(0,s),t={startNode:this.next.domNode,startOffset:s.length}):(r=document.createTextNode(s),this.parent.insertBefore(this.scroll.create(r),this.next),t={startNode:r,startOffset:s.length}));return e.data=Is,t}update(e,t){e.forEach(r=>{if(r.type==="characterData"&&(r.target===this.leftGuard||r.target===this.rightGuard)){const s=this.restore(r.target);s&&(t.range=s)}})}}class Wv{constructor(e,t){J(this,"isComposing",!1);this.scroll=e,this.emitter=t,this.setupListeners()}setupListeners(){this.scroll.domNode.addEventListener("compositionstart",e=>{this.isComposing||this.handleCompositionStart(e)}),this.scroll.domNode.addEventListener("compositionend",e=>{this.isComposing&&queueMicrotask(()=>{this.handleCompositionEnd(e)})})}handleCompositionStart(e){const t=e.target instanceof Node?this.scroll.find(e.target,!0):null;t&&!(t instanceof Za)&&(this.emitter.emit(ee.events.COMPOSITION_BEFORE_START,e),this.scroll.batchStart(),this.emitter.emit(ee.events.COMPOSITION_START,e),this.isComposing=!0)}handleCompositionEnd(e){this.emitter.emit(ee.events.COMPOSITION_BEFORE_END,e),this.scroll.batchEnd(),this.emitter.emit(ee.events.COMPOSITION_END,e),this.isComposing=!1}}const Vn=class Vn{constructor(e,t){J(this,"modules",{});this.quill=e,this.options=t}init(){Object.keys(this.options.modules).forEach(e=>{this.modules[e]==null&&this.addModule(e)})}addModule(e){const t=this.quill.constructor.import(`modules/${e}`);return this.modules[e]=new t(this.quill,this.options.modules[e]||{}),this.modules[e]}};J(Vn,"DEFAULTS",{modules:{}}),J(Vn,"themes",{default:Vn});let cn=Vn;const Yv=n=>n.parentElement||n.getRootNode().host||null,Zv=n=>{const e=n.getBoundingClientRect(),t="offsetWidth"in n&&Math.abs(e.width)/n.offsetWidth||1,r="offsetHeight"in n&&Math.abs(e.height)/n.offsetHeight||1;return{top:e.top,right:e.left+n.clientWidth*t,bottom:e.top+n.clientHeight*r,left:e.left}},Rs=n=>{const e=parseInt(n,10);return Number.isNaN(e)?0:e},bu=(n,e,t,r,s,i)=>n<t&&e>r?0:n<t?-(t-n+s):e>r?e-n>r-t?n+s-t:e-r+i:0,Xv=(n,e)=>{var i,o,a;const t=n.ownerDocument;let r=e,s=n;for(;s;){const u=s===t.body,c=u?{top:0,right:((i=window.visualViewport)==null?void 0:i.width)??t.documentElement.clientWidth,bottom:((o=window.visualViewport)==null?void 0:o.height)??t.documentElement.clientHeight,left:0}:Zv(s),h=getComputedStyle(s),g=bu(r.left,r.right,c.left,c.right,Rs(h.scrollPaddingLeft),Rs(h.scrollPaddingRight)),d=bu(r.top,r.bottom,c.top,c.bottom,Rs(h.scrollPaddingTop),Rs(h.scrollPaddingBottom));if(g||d)if(u)(a=t.defaultView)==null||a.scrollBy(g,d);else{const{scrollLeft:m,scrollTop:v}=s;d&&(s.scrollTop+=d),g&&(s.scrollLeft+=g);const p=s.scrollLeft-m,y=s.scrollTop-v;r={left:r.left-p,top:r.top-y,right:r.right-p,bottom:r.bottom-y}}s=u||h.position==="fixed"?null:Yv(s)}},Qv=100,Jv=["block","break","cursor","inline","scroll","text"],ey=(n,e,t)=>{const r=new ln;return Jv.forEach(s=>{const i=e.query(s);i&&r.register(i)}),n.forEach(s=>{let i=e.query(s);i||t.error(`Cannot register "${s}" specified in "formats" config. Are you sure it was registered?`);let o=0;for(;i;)if(r.register(i),i="blotName"in i?i.requiredContainer??null:null,o+=1,o>Qv){t.error(`Cycle detected in registering blot requiredContainer: "${s}"`);break}}),r},tn=Vt("quill"),Os=new ln;dt.uiClass="ql-ui";const at=class at{static debug(e){e===!0&&(e="log"),Vt.level(e)}static find(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return pa.get(e)||Os.find(e,t)}static import(e){return this.imports[e]==null&&tn.error(`Cannot import ${e}. Are you sure it was registered?`),this.imports[e]}static register(){if(typeof(arguments.length<=0?void 0:arguments[0])!="string"){const e=arguments.length<=0?void 0:arguments[0],t=!!(!(arguments.length<=1)&&arguments[1]),r="attrName"in e?e.attrName:e.blotName;typeof r=="string"?this.register(`formats/${r}`,e,t):Object.keys(e).forEach(s=>{this.register(s,e[s],t)})}else{const e=arguments.length<=0?void 0:arguments[0],t=arguments.length<=1?void 0:arguments[1],r=!!(!(arguments.length<=2)&&arguments[2]);this.imports[e]!=null&&!r&&tn.warn(`Overwriting ${e} with`,t),this.imports[e]=t,(e.startsWith("blots/")||e.startsWith("formats/"))&&t&&typeof t!="boolean"&&t.blotName!=="abstract"&&Os.register(t),typeof t.register=="function"&&t.register(Os)}}constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.options=ty(e,t),this.container=this.options.container,this.container==null){tn.error("Invalid Quill container",e);return}this.options.debug&&at.debug(this.options.debug);const r=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",pa.set(this.container,this),this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.emitter=new ee;const s=Ya.blotName,i=this.options.registry.query(s);if(!i||!("blotName"in i))throw new Error(`Cannot initialize Quill without "${s}" blot`);if(this.scroll=new i(this.options.registry,this.root,{emitter:this.emitter}),this.editor=new zv(this.scroll),this.selection=new Uv(this.scroll,this.emitter),this.composition=new Wv(this.scroll,this.emitter),this.theme=new this.options.theme(this,this.options),this.keyboard=this.theme.addModule("keyboard"),this.clipboard=this.theme.addModule("clipboard"),this.history=this.theme.addModule("history"),this.uploader=this.theme.addModule("uploader"),this.theme.addModule("input"),this.theme.addModule("uiNode"),this.theme.init(),this.emitter.on(ee.events.EDITOR_CHANGE,o=>{o===ee.events.TEXT_CHANGE&&this.root.classList.toggle("ql-blank",this.editor.isBlank())}),this.emitter.on(ee.events.SCROLL_UPDATE,(o,a)=>{const u=this.selection.lastRange,[c]=this.selection.getRange(),h=u&&c?{oldRange:u,newRange:c}:void 0;it.call(this,()=>this.editor.update(null,a,h),o)}),this.emitter.on(ee.events.SCROLL_EMBED_UPDATE,(o,a)=>{const u=this.selection.lastRange,[c]=this.selection.getRange(),h=u&&c?{oldRange:u,newRange:c}:void 0;it.call(this,()=>{const g=new re().retain(o.offset(this)).retain({[o.statics.blotName]:a});return this.editor.update(g,[],h)},at.sources.USER)}),r){const o=this.clipboard.convert({html:`${r}<p><br></p>`,text:`
119
- `});this.setContents(o)}this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable(),this.allowReadOnlyEdits=!1}addContainer(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(typeof e=="string"){const r=e;e=document.createElement("div"),e.classList.add(r)}return this.container.insertBefore(e,t),e}blur(){this.selection.setRange(null)}deleteText(e,t,r){return[e,t,,r]=Lt(e,t,r),it.call(this,()=>this.editor.deleteText(e,t),r,e,-1*t)}disable(){this.enable(!1)}editReadOnly(e){this.allowReadOnlyEdits=!0;const t=e();return this.allowReadOnlyEdits=!1,t}enable(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.scroll.enable(e),this.container.classList.toggle("ql-disabled",!e)}focus(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.selection.focus(),e.preventScroll||this.scrollSelectionIntoView()}format(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ee.sources.API;return it.call(this,()=>{const s=this.getSelection(!0);let i=new re;if(s==null)return i;if(this.scroll.query(e,ne.BLOCK))i=this.editor.formatLine(s.index,s.length,{[e]:t});else{if(s.length===0)return this.selection.format(e,t),i;i=this.editor.formatText(s.index,s.length,{[e]:t})}return this.setSelection(s,ee.sources.SILENT),i},r)}formatLine(e,t,r,s,i){let o;return[e,t,o,i]=Lt(e,t,r,s,i),it.call(this,()=>this.editor.formatLine(e,t,o),i,e,0)}formatText(e,t,r,s,i){let o;return[e,t,o,i]=Lt(e,t,r,s,i),it.call(this,()=>this.editor.formatText(e,t,o),i,e,0)}getBounds(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=null;if(typeof e=="number"?r=this.selection.getBounds(e,t):r=this.selection.getBounds(e.index,e.length),!r)return null;const s=this.container.getBoundingClientRect();return{bottom:r.bottom-s.top,height:r.height,left:r.left-s.left,right:r.right-s.left,top:r.top-s.top,width:r.width}}getContents(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-e;return[e,t]=Lt(e,t),this.editor.getContents(e,t)}getFormat(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.getSelection(!0),t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return typeof e=="number"?this.editor.getFormat(e,t):this.editor.getFormat(e.index,e.length)}getIndex(e){return e.offset(this.scroll)}getLength(){return this.scroll.length()}getLeaf(e){return this.scroll.leaf(e)}getLine(e){return this.scroll.line(e)}getLines(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE;return typeof e!="number"?this.scroll.lines(e.index,e.length):this.scroll.lines(e,t)}getModule(e){return this.theme.modules[e]}getSelection(){return(arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1)&&this.focus(),this.update(),this.selection.getRange()[0]}getSemanticHTML(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,t=arguments.length>1?arguments[1]:void 0;return typeof e=="number"&&(t=t??this.getLength()-e),[e,t]=Lt(e,t),this.editor.getHTML(e,t)}getText(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,t=arguments.length>1?arguments[1]:void 0;return typeof e=="number"&&(t=t??this.getLength()-e),[e,t]=Lt(e,t),this.editor.getText(e,t)}hasFocus(){return this.selection.hasFocus()}insertEmbed(e,t,r){let s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:at.sources.API;return it.call(this,()=>this.editor.insertEmbed(e,t,r),s,e)}insertText(e,t,r,s,i){let o;return[e,,o,i]=Lt(e,0,r,s,i),it.call(this,()=>this.editor.insertText(e,t,o),i,e,t.length)}isEnabled(){return this.scroll.isEnabled()}off(){return this.emitter.off(...arguments)}on(){return this.emitter.on(...arguments)}once(){return this.emitter.once(...arguments)}removeFormat(e,t,r){return[e,t,,r]=Lt(e,t,r),it.call(this,()=>this.editor.removeFormat(e,t),r,e)}scrollRectIntoView(e){Xv(this.root,e)}scrollIntoView(){console.warn("Quill#scrollIntoView() has been deprecated and will be removed in the near future. Please use Quill#scrollSelectionIntoView() instead."),this.scrollSelectionIntoView()}scrollSelectionIntoView(){const e=this.selection.lastRange,t=e&&this.selection.getBounds(e.index,e.length);t&&this.scrollRectIntoView(t)}setContents(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ee.sources.API;return it.call(this,()=>{e=new re(e);const r=this.getLength(),s=this.editor.deleteText(0,r),i=this.editor.insertContents(0,e),o=this.editor.deleteText(this.getLength()-1,1);return s.compose(i).compose(o)},t)}setSelection(e,t,r){e==null?this.selection.setRange(null,t||at.sources.API):([e,t,,r]=Lt(e,t,r),this.selection.setRange(new _r(Math.max(0,e),t),r),r!==ee.sources.SILENT&&this.scrollSelectionIntoView())}setText(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ee.sources.API;const r=new re().insert(e);return this.setContents(r,t)}update(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ee.sources.USER;const t=this.scroll.update(e);return this.selection.update(e),t}updateContents(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ee.sources.API;return it.call(this,()=>(e=new re(e),this.editor.applyDelta(e)),t,!0)}};J(at,"DEFAULTS",{bounds:null,modules:{clipboard:!0,keyboard:!0,history:!0,uploader:!0},placeholder:"",readOnly:!1,registry:Os,theme:"default"}),J(at,"events",ee.events),J(at,"sources",ee.sources),J(at,"version","2.0.3"),J(at,"imports",{delta:re,parchment:Lv,"core/module":mt,"core/theme":cn});let B=at;function Eu(n){return typeof n=="string"?document.querySelector(n):n}function Do(n){return Object.entries(n??{}).reduce((e,t)=>{let[r,s]=t;return{...e,[r]:s===!0?{}:s}},{})}function wu(n){return Object.fromEntries(Object.entries(n).filter(e=>e[1]!==void 0))}function ty(n,e){const t=Eu(n);if(!t)throw new Error("Invalid Quill container");const s=!e.theme||e.theme===B.DEFAULTS.theme?cn:B.import(`themes/${e.theme}`);if(!s)throw new Error(`Invalid theme ${e.theme}. Did you register it?`);const{modules:i,...o}=B.DEFAULTS,{modules:a,...u}=s.DEFAULTS;let c=Do(e.modules);c!=null&&c.toolbar&&c.toolbar.constructor!==Object&&(c={...c,toolbar:{container:c.toolbar}});const h=er({},Do(i),Do(a),c),g={...o,...wu(u),...wu(e)};let d=e.registry;return d?e.formats&&tn.warn('Ignoring "formats" option because "registry" is specified'):d=e.formats?ey(e.formats,g.registry,tn):g.registry,{...g,registry:d,container:t,theme:s,modules:Object.entries(h).reduce((m,v)=>{let[p,y]=v;if(!y)return m;const E=B.import(`modules/${p}`);return E==null?(tn.error(`Cannot load ${p} module. Are you sure you registered it?`),m):{...m,[p]:er({},E.DEFAULTS||{},y)}},{}),bounds:Eu(g.bounds)}}function it(n,e,t,r){if(!this.isEnabled()&&e===ee.sources.USER&&!this.allowReadOnlyEdits)return new re;let s=t==null?null:this.getSelection();const i=this.editor.delta,o=n();if(s!=null&&(t===!0&&(t=s.index),r==null?s=xu(s,o,e):r!==0&&(s=xu(s,t,r,e)),this.setSelection(s,ee.sources.SILENT)),o.length()>0){const a=[ee.events.TEXT_CHANGE,o,i,e];this.emitter.emit(ee.events.EDITOR_CHANGE,...a),e!==ee.sources.SILENT&&this.emitter.emit(...a)}return o}function Lt(n,e,t,r,s){let i={};return typeof n.index=="number"&&typeof n.length=="number"?typeof e!="number"?(s=r,r=t,t=e,e=n.length,n=n.index):(e=n.length,n=n.index):typeof e!="number"&&(s=r,r=t,t=e,e=0),typeof t=="object"?(i=t,s=r):typeof t=="string"&&(r!=null?i[t]=r:s=t),s=s||ee.sources.API,[n,e,i,s]}function xu(n,e,t,r){const s=typeof t=="number"?t:0;if(n==null)return null;let i,o;return e&&typeof e.transformPosition=="function"?[i,o]=[n.index,n.index+n.length].map(a=>e.transformPosition(a,r!==ee.sources.USER)):[i,o]=[n.index,n.index+n.length].map(a=>a<e||a===e&&r===ee.sources.USER?a:s>=0?a+s:Math.max(e,a+s)),new _r(i,o-i)}class Ir extends yi{}function Su(n){return n instanceof Pe||n instanceof et}function _u(n){return typeof n.updateContent=="function"}class Xr extends Ya{constructor(e,t,r){let{emitter:s}=r;super(e,t),this.emitter=s,this.batch=!1,this.optimize(),this.enable(),this.domNode.addEventListener("dragstart",i=>this.handleDragStart(i))}batchStart(){Array.isArray(this.batch)||(this.batch=[])}batchEnd(){if(!this.batch)return;const e=this.batch;this.batch=!1,this.update(e)}emitMount(e){this.emitter.emit(ee.events.SCROLL_BLOT_MOUNT,e)}emitUnmount(e){this.emitter.emit(ee.events.SCROLL_BLOT_UNMOUNT,e)}emitEmbedUpdate(e,t){this.emitter.emit(ee.events.SCROLL_EMBED_UPDATE,e,t)}deleteAt(e,t){const[r,s]=this.line(e),[i]=this.line(e+t);if(super.deleteAt(e,t),i!=null&&r!==i&&s>0){if(r instanceof et||i instanceof et){this.optimize();return}const o=i.children.head instanceof gt?null:i.children.head;r.moveChildren(i,o),r.remove()}this.optimize()}enable(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.domNode.setAttribute("contenteditable",e?"true":"false")}formatAt(e,t,r,s){super.formatAt(e,t,r,s),this.optimize()}insertAt(e,t,r){if(e>=this.length())if(r==null||this.scroll.query(t,ne.BLOCK)==null){const s=this.scroll.create(this.statics.defaultChild.blotName);this.appendChild(s),r==null&&t.endsWith(`
120
- `)?s.insertAt(0,t.slice(0,-1),r):s.insertAt(0,t,r)}else{const s=this.scroll.create(t,r);this.appendChild(s)}else super.insertAt(e,t,r);this.optimize()}insertBefore(e,t){if(e.statics.scope===ne.INLINE_BLOT){const r=this.scroll.create(this.statics.defaultChild.blotName);r.appendChild(e),super.insertBefore(r,t)}else super.insertBefore(e,t)}insertContents(e,t){const r=this.deltaToRenderBlocks(t.concat(new re().insert(`
121
- `))),s=r.pop();if(s==null)return;this.batchStart();const i=r.shift();if(i){const u=i.type==="block"&&(i.delta.length()===0||!this.descendant(et,e)[0]&&e<this.length()),c=i.type==="block"?i.delta:new re().insert({[i.key]:i.value});Po(this,e,c);const h=i.type==="block"?1:0,g=e+c.length()+h;u&&this.insertAt(g-1,`
122
- `);const d=Qe(this.line(e)[0]),m=tt.AttributeMap.diff(d,i.attributes)||{};Object.keys(m).forEach(v=>{this.formatAt(g-1,1,v,m[v])}),e=g}let[o,a]=this.children.find(e);if(r.length&&(o&&(o=o.split(a),a=0),r.forEach(u=>{if(u.type==="block"){const c=this.createBlock(u.attributes,o||void 0);Po(c,0,u.delta)}else{const c=this.create(u.key,u.value);this.insertBefore(c,o||void 0),Object.keys(u.attributes).forEach(h=>{c.format(h,u.attributes[h])})}})),s.type==="block"&&s.delta.length()){const u=o?o.offset(o.scroll)+a:this.length();Po(this,u,s.delta)}this.batchEnd(),this.optimize()}isEnabled(){return this.domNode.getAttribute("contenteditable")==="true"}leaf(e){const t=this.path(e).pop();if(!t)return[null,-1];const[r,s]=t;return r instanceof je?[r,s]:[null,-1]}line(e){return e===this.length()?this.line(e-1):this.descendant(Su,e)}lines(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE;const r=(s,i,o)=>{let a=[],u=o;return s.children.forEachAt(i,o,(c,h,g)=>{Su(c)?a.push(c):c instanceof yi&&(a=a.concat(r(c,h,u))),u-=g}),a};return r(this,e,t)}optimize(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.batch||(super.optimize(e,t),e.length>0&&this.emitter.emit(ee.events.SCROLL_OPTIMIZE,e,t))}path(e){return super.path(e).slice(1)}remove(){}update(e){if(this.batch){Array.isArray(e)&&(this.batch=this.batch.concat(e));return}let t=ee.sources.USER;typeof e=="string"&&(t=e),Array.isArray(e)||(e=this.observer.takeRecords()),e=e.filter(r=>{let{target:s}=r;const i=this.find(s,!0);return i&&!_u(i)}),e.length>0&&this.emitter.emit(ee.events.SCROLL_BEFORE_UPDATE,t,e),super.update(e.concat([])),e.length>0&&this.emitter.emit(ee.events.SCROLL_UPDATE,t,e)}updateEmbedAt(e,t,r){const[s]=this.descendant(i=>i instanceof et,e);s&&s.statics.blotName===t&&_u(s)&&s.updateContent(r)}handleDragStart(e){e.preventDefault()}deltaToRenderBlocks(e){const t=[];let r=new re;return e.forEach(s=>{const i=s==null?void 0:s.insert;if(i)if(typeof i=="string"){const o=i.split(`
123
- `);o.slice(0,-1).forEach(u=>{r.insert(u,s.attributes),t.push({type:"block",delta:r,attributes:s.attributes??{}}),r=new re});const a=o[o.length-1];a&&r.insert(a,s.attributes)}else{const o=Object.keys(i)[0];if(!o)return;this.query(o,ne.INLINE)?r.push(s):(r.length()&&t.push({type:"block",delta:r,attributes:{}}),r=new re,t.push({type:"blockEmbed",key:o,value:i[o],attributes:s.attributes??{}}))}}),r.length()&&t.push({type:"block",delta:r,attributes:{}}),t}createBlock(e,t){let r;const s={};Object.entries(e).forEach(a=>{let[u,c]=a;this.query(u,ne.BLOCK&ne.BLOT)!=null?r=u:s[u]=c});const i=this.create(r||this.statics.defaultChild.blotName,r?e[r]:void 0);this.insertBefore(i,t||void 0);const o=i.length();return Object.entries(s).forEach(a=>{let[u,c]=a;i.formatAt(0,o,u,c)}),i}}J(Xr,"blotName","scroll"),J(Xr,"className","ql-editor"),J(Xr,"tagName","DIV"),J(Xr,"defaultChild",Pe),J(Xr,"allowedChildren",[Pe,et,Ir]);function Po(n,e,t){t.reduce((r,s)=>{const i=tt.Op.length(s);let o=s.attributes||{};if(s.insert!=null){if(typeof s.insert=="string"){const a=s.insert;n.insertAt(r,a);const[u]=n.descendant(je,r),c=Qe(u);o=tt.AttributeMap.diff(c,o)||{}}else if(typeof s.insert=="object"){const a=Object.keys(s.insert)[0];if(a==null)return r;if(n.insertAt(r,a,s.insert[a]),n.scroll.query(a,ne.INLINE)!=null){const[c]=n.descendant(je,r),h=Qe(c);o=tt.AttributeMap.diff(h,o)||{}}}}return Object.keys(o).forEach(a=>{n.formatAt(r,i,a,o[a])}),r+i},e)}const Xa={scope:ne.BLOCK,whitelist:["right","center","justify"]},ry=new At("align","align",Xa),Ih=new pt("align","ql-align",Xa),Rh=new ir("align","text-align",Xa);class Oh extends ir{value(e){let t=super.value(e);return t.startsWith("rgb(")?(t=t.replace(/^[^\d]+/,"").replace(/[^\d]+$/,""),`#${t.split(",").map(s=>`00${parseInt(s,10).toString(16)}`.slice(-2)).join("")}`):t}}const ny=new pt("color","ql-color",{scope:ne.INLINE}),Qa=new Oh("color","color",{scope:ne.INLINE}),sy=new pt("background","ql-bg",{scope:ne.INLINE}),Ja=new Oh("background","background-color",{scope:ne.INLINE});class Rr extends Ir{static create(e){const t=super.create(e);return t.setAttribute("spellcheck","false"),t}code(e,t){return this.children.map(r=>r.length()<=1?"":r.domNode.innerText).join(`
124
- `).slice(e,e+t)}html(e,t){return`<pre>
125
- ${bi(this.code(e,t))}
126
- </pre>`}}class $e extends Pe{static register(){B.register(Rr)}}J($e,"TAB"," ");class el extends Ct{}el.blotName="code";el.tagName="CODE";$e.blotName="code-block";$e.className="ql-code-block";$e.tagName="DIV";Rr.blotName="code-block-container";Rr.className="ql-code-block-container";Rr.tagName="DIV";Rr.allowedChildren=[$e];$e.allowedChildren=[ft,gt,un];$e.requiredContainer=Rr;const tl={scope:ne.BLOCK,whitelist:["rtl"]},Lh=new At("direction","dir",tl),Mh=new pt("direction","ql-direction",tl),Dh=new ir("direction","direction",tl),Ph={scope:ne.INLINE,whitelist:["serif","monospace"]},Bh=new pt("font","ql-font",Ph);class iy extends ir{value(e){return super.value(e).replace(/["']/g,"")}}const qh=new iy("font","font-family",Ph),Fh=new pt("size","ql-size",{scope:ne.INLINE,whitelist:["small","large","huge"]}),jh=new ir("size","font-size",{scope:ne.INLINE,whitelist:["10px","18px","32px"]}),oy=Vt("quill:keyboard"),ay=/Mac/i.test(navigator.platform)?"metaKey":"ctrlKey";class Ei extends mt{static match(e,t){return["altKey","ctrlKey","metaKey","shiftKey"].some(r=>!!t[r]!==e[r]&&t[r]!==null)?!1:t.key===e.key||t.key===e.which}constructor(e,t){super(e,t),this.bindings={},Object.keys(this.options.bindings).forEach(r=>{this.options.bindings[r]&&this.addBinding(this.options.bindings[r])}),this.addBinding({key:"Enter",shiftKey:null},this.handleEnter),this.addBinding({key:"Enter",metaKey:null,ctrlKey:null,altKey:null},()=>{}),/Firefox/i.test(navigator.userAgent)?(this.addBinding({key:"Backspace"},{collapsed:!0},this.handleBackspace),this.addBinding({key:"Delete"},{collapsed:!0},this.handleDelete)):(this.addBinding({key:"Backspace"},{collapsed:!0,prefix:/^.?$/},this.handleBackspace),this.addBinding({key:"Delete"},{collapsed:!0,suffix:/^.?$/},this.handleDelete)),this.addBinding({key:"Backspace"},{collapsed:!1},this.handleDeleteRange),this.addBinding({key:"Delete"},{collapsed:!1},this.handleDeleteRange),this.addBinding({key:"Backspace",altKey:null,ctrlKey:null,metaKey:null,shiftKey:null},{collapsed:!0,offset:0},this.handleBackspace),this.listen()}addBinding(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const s=uy(e);if(s==null){oy.warn("Attempted to add invalid keyboard binding",s);return}typeof t=="function"&&(t={handler:t}),typeof r=="function"&&(r={handler:r}),(Array.isArray(s.key)?s.key:[s.key]).forEach(o=>{const a={...s,key:o,...t,...r};this.bindings[a.key]=this.bindings[a.key]||[],this.bindings[a.key].push(a)})}listen(){this.quill.root.addEventListener("keydown",e=>{if(e.defaultPrevented||e.isComposing||e.keyCode===229&&(e.key==="Enter"||e.key==="Backspace"))return;const s=(this.bindings[e.key]||[]).concat(this.bindings[e.which]||[]).filter(E=>Ei.match(e,E));if(s.length===0)return;const i=B.find(e.target,!0);if(i&&i.scroll!==this.quill.scroll)return;const o=this.quill.getSelection();if(o==null||!this.quill.hasFocus())return;const[a,u]=this.quill.getLine(o.index),[c,h]=this.quill.getLeaf(o.index),[g,d]=o.length===0?[c,h]:this.quill.getLeaf(o.index+o.length),m=c instanceof ti?c.value().slice(0,h):"",v=g instanceof ti?g.value().slice(d):"",p={collapsed:o.length===0,empty:o.length===0&&a.length()<=1,format:this.quill.getFormat(o),line:a,offset:u,prefix:m,suffix:v,event:e};s.some(E=>{if(E.collapsed!=null&&E.collapsed!==p.collapsed||E.empty!=null&&E.empty!==p.empty||E.offset!=null&&E.offset!==p.offset)return!1;if(Array.isArray(E.format)){if(E.format.every(S=>p.format[S]==null))return!1}else if(typeof E.format=="object"&&!Object.keys(E.format).every(S=>E.format[S]===!0?p.format[S]!=null:E.format[S]===!1?p.format[S]==null:Wt(E.format[S],p.format[S])))return!1;return E.prefix!=null&&!E.prefix.test(p.prefix)||E.suffix!=null&&!E.suffix.test(p.suffix)?!1:E.handler.call(this,o,p,E)!==!0})&&e.preventDefault()})}handleBackspace(e,t){const r=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test(t.prefix)?2:1;if(e.index===0||this.quill.getLength()<=1)return;let s={};const[i]=this.quill.getLine(e.index);let o=new re().retain(e.index-r).delete(r);if(t.offset===0){const[a]=this.quill.getLine(e.index-1);if(a&&!(a.statics.blotName==="block"&&a.length()<=1)){const c=i.formats(),h=this.quill.getFormat(e.index-1,1);if(s=tt.AttributeMap.diff(c,h)||{},Object.keys(s).length>0){const g=new re().retain(e.index+i.length()-2).retain(1,s);o=o.compose(g)}}}this.quill.updateContents(o,B.sources.USER),this.quill.focus()}handleDelete(e,t){const r=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test(t.suffix)?2:1;if(e.index>=this.quill.getLength()-r)return;let s={};const[i]=this.quill.getLine(e.index);let o=new re().retain(e.index).delete(r);if(t.offset>=i.length()-1){const[a]=this.quill.getLine(e.index+1);if(a){const u=i.formats(),c=this.quill.getFormat(e.index,1);s=tt.AttributeMap.diff(u,c)||{},Object.keys(s).length>0&&(o=o.retain(a.length()-1).retain(1,s))}}this.quill.updateContents(o,B.sources.USER),this.quill.focus()}handleDeleteRange(e){rl({range:e,quill:this.quill}),this.quill.focus()}handleEnter(e,t){const r=Object.keys(t.format).reduce((i,o)=>(this.quill.scroll.query(o,ne.BLOCK)&&!Array.isArray(t.format[o])&&(i[o]=t.format[o]),i),{}),s=new re().retain(e.index).delete(e.length).insert(`
127
- `,r);this.quill.updateContents(s,B.sources.USER),this.quill.setSelection(e.index+1,B.sources.SILENT),this.quill.focus()}}const ly={bindings:{bold:Bo("bold"),italic:Bo("italic"),underline:Bo("underline"),indent:{key:"Tab",format:["blockquote","indent","list"],handler(n,e){return e.collapsed&&e.offset!==0?!0:(this.quill.format("indent","+1",B.sources.USER),!1)}},outdent:{key:"Tab",shiftKey:!0,format:["blockquote","indent","list"],handler(n,e){return e.collapsed&&e.offset!==0?!0:(this.quill.format("indent","-1",B.sources.USER),!1)}},"outdent backspace":{key:"Backspace",collapsed:!0,shiftKey:null,metaKey:null,ctrlKey:null,altKey:null,format:["indent","list"],offset:0,handler(n,e){e.format.indent!=null?this.quill.format("indent","-1",B.sources.USER):e.format.list!=null&&this.quill.format("list",!1,B.sources.USER)}},"indent code-block":Au(!0),"outdent code-block":Au(!1),"remove tab":{key:"Tab",shiftKey:!0,collapsed:!0,prefix:/\t$/,handler(n){this.quill.deleteText(n.index-1,1,B.sources.USER)}},tab:{key:"Tab",handler(n,e){if(e.format.table)return!0;this.quill.history.cutoff();const t=new re().retain(n.index).delete(n.length).insert(" ");return this.quill.updateContents(t,B.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(n.index+1,B.sources.SILENT),!1}},"blockquote empty enter":{key:"Enter",collapsed:!0,format:["blockquote"],empty:!0,handler(){this.quill.format("blockquote",!1,B.sources.USER)}},"list empty enter":{key:"Enter",collapsed:!0,format:["list"],empty:!0,handler(n,e){const t={list:!1};e.format.indent&&(t.indent=!1),this.quill.formatLine(n.index,n.length,t,B.sources.USER)}},"checklist enter":{key:"Enter",collapsed:!0,format:{list:"checked"},handler(n){const[e,t]=this.quill.getLine(n.index),r={...e.formats(),list:"checked"},s=new re().retain(n.index).insert(`
128
- `,r).retain(e.length()-t-1).retain(1,{list:"unchecked"});this.quill.updateContents(s,B.sources.USER),this.quill.setSelection(n.index+1,B.sources.SILENT),this.quill.scrollSelectionIntoView()}},"header enter":{key:"Enter",collapsed:!0,format:["header"],suffix:/^$/,handler(n,e){const[t,r]=this.quill.getLine(n.index),s=new re().retain(n.index).insert(`
129
- `,e.format).retain(t.length()-r-1).retain(1,{header:null});this.quill.updateContents(s,B.sources.USER),this.quill.setSelection(n.index+1,B.sources.SILENT),this.quill.scrollSelectionIntoView()}},"table backspace":{key:"Backspace",format:["table"],collapsed:!0,offset:0,handler(){}},"table delete":{key:"Delete",format:["table"],collapsed:!0,suffix:/^$/,handler(){}},"table enter":{key:"Enter",shiftKey:null,format:["table"],handler(n){const e=this.quill.getModule("table");if(e){const[t,r,s,i]=e.getTable(n),o=cy(t,r,s,i);if(o==null)return;let a=t.offset();if(o<0){const u=new re().retain(a).insert(`
130
- `);this.quill.updateContents(u,B.sources.USER),this.quill.setSelection(n.index+1,n.length,B.sources.SILENT)}else if(o>0){a+=t.length();const u=new re().retain(a).insert(`
131
- `);this.quill.updateContents(u,B.sources.USER),this.quill.setSelection(a,B.sources.USER)}}}},"table tab":{key:"Tab",shiftKey:null,format:["table"],handler(n,e){const{event:t,line:r}=e,s=r.offset(this.quill.scroll);t.shiftKey?this.quill.setSelection(s-1,B.sources.USER):this.quill.setSelection(s+r.length(),B.sources.USER)}},"list autofill":{key:" ",shiftKey:null,collapsed:!0,format:{"code-block":!1,blockquote:!1,table:!1},prefix:/^\s*?(\d+\.|-|\*|\[ ?\]|\[x\])$/,handler(n,e){if(this.quill.scroll.query("list")==null)return!0;const{length:t}=e.prefix,[r,s]=this.quill.getLine(n.index);if(s>t)return!0;let i;switch(e.prefix.trim()){case"[]":case"[ ]":i="unchecked";break;case"[x]":i="checked";break;case"-":case"*":i="bullet";break;default:i="ordered"}this.quill.insertText(n.index," ",B.sources.USER),this.quill.history.cutoff();const o=new re().retain(n.index-s).delete(t+1).retain(r.length()-2-s).retain(1,{list:i});return this.quill.updateContents(o,B.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(n.index-t,B.sources.SILENT),!1}},"code exit":{key:"Enter",collapsed:!0,format:["code-block"],prefix:/^$/,suffix:/^\s*$/,handler(n){const[e,t]=this.quill.getLine(n.index);let r=2,s=e;for(;s!=null&&s.length()<=1&&s.formats()["code-block"];)if(s=s.prev,r-=1,r<=0){const i=new re().retain(n.index+e.length()-t-2).retain(1,{"code-block":null}).delete(1);return this.quill.updateContents(i,B.sources.USER),this.quill.setSelection(n.index-1,B.sources.SILENT),!1}return!0}},"embed left":Ls("ArrowLeft",!1),"embed left shift":Ls("ArrowLeft",!0),"embed right":Ls("ArrowRight",!1),"embed right shift":Ls("ArrowRight",!0),"table down":Cu(!1),"table up":Cu(!0)}};Ei.DEFAULTS=ly;function Au(n){return{key:"Tab",shiftKey:!n,format:{"code-block":!0},handler(e,t){let{event:r}=t;const s=this.quill.scroll.query("code-block"),{TAB:i}=s;if(e.length===0&&!r.shiftKey){this.quill.insertText(e.index,i,B.sources.USER),this.quill.setSelection(e.index+i.length,B.sources.SILENT);return}const o=e.length===0?this.quill.getLines(e.index,1):this.quill.getLines(e);let{index:a,length:u}=e;o.forEach((c,h)=>{n?(c.insertAt(0,i),h===0?a+=i.length:u+=i.length):c.domNode.textContent.startsWith(i)&&(c.deleteAt(0,i.length),h===0?a-=i.length:u-=i.length)}),this.quill.update(B.sources.USER),this.quill.setSelection(a,u,B.sources.SILENT)}}}function Ls(n,e){return{key:n,shiftKey:e,altKey:null,[n==="ArrowLeft"?"prefix":"suffix"]:/^$/,handler(r){let{index:s}=r;n==="ArrowRight"&&(s+=r.length+1);const[i]=this.quill.getLeaf(s);return i instanceof Ye?(n==="ArrowLeft"?e?this.quill.setSelection(r.index-1,r.length+1,B.sources.USER):this.quill.setSelection(r.index-1,B.sources.USER):e?this.quill.setSelection(r.index,r.length+1,B.sources.USER):this.quill.setSelection(r.index+r.length+1,B.sources.USER),!1):!0}}}function Bo(n){return{key:n[0],shortKey:!0,handler(e,t){this.quill.format(n,!t.format[n],B.sources.USER)}}}function Cu(n){return{key:n?"ArrowUp":"ArrowDown",collapsed:!0,format:["table"],handler(e,t){const r=n?"prev":"next",s=t.line,i=s.parent[r];if(i!=null){if(i.statics.blotName==="table-row"){let o=i.children.head,a=s;for(;a.prev!=null;)a=a.prev,o=o.next;const u=o.offset(this.quill.scroll)+Math.min(t.offset,o.length()-1);this.quill.setSelection(u,0,B.sources.USER)}}else{const o=s.table()[r];o!=null&&(n?this.quill.setSelection(o.offset(this.quill.scroll)+o.length()-1,0,B.sources.USER):this.quill.setSelection(o.offset(this.quill.scroll),0,B.sources.USER))}return!1}}}function uy(n){if(typeof n=="string"||typeof n=="number")n={key:n};else if(typeof n=="object")n=Jr(n);else return null;return n.shortKey&&(n[ay]=n.shortKey,delete n.shortKey),n}function rl(n){let{quill:e,range:t}=n;const r=e.getLines(t);let s={};if(r.length>1){const i=r[0].formats(),o=r[r.length-1].formats();s=tt.AttributeMap.diff(o,i)||{}}e.deleteText(t,B.sources.USER),Object.keys(s).length>0&&e.formatLine(t.index,1,s,B.sources.USER),e.setSelection(t.index,B.sources.SILENT)}function cy(n,e,t,r){return e.prev==null&&e.next==null?t.prev==null&&t.next==null?r===0?-1:1:t.prev==null?-1:1:e.prev==null?-1:e.next==null?1:null}const hy=/font-weight:\s*normal/,dy=["P","OL","UL"],Tu=n=>n&&dy.includes(n.tagName),fy=n=>{Array.from(n.querySelectorAll("br")).filter(e=>Tu(e.previousElementSibling)&&Tu(e.nextElementSibling)).forEach(e=>{var t;(t=e.parentNode)==null||t.removeChild(e)})},py=n=>{Array.from(n.querySelectorAll('b[style*="font-weight"]')).filter(e=>{var t;return(t=e.getAttribute("style"))==null?void 0:t.match(hy)}).forEach(e=>{var r;const t=n.createDocumentFragment();t.append(...e.childNodes),(r=e.parentNode)==null||r.replaceChild(t,e)})};function gy(n){n.querySelector('[id^="docs-internal-guid-"]')&&(py(n),fy(n))}const my=/\bmso-list:[^;]*ignore/i,vy=/\bmso-list:[^;]*\bl(\d+)/i,yy=/\bmso-list:[^;]*\blevel(\d+)/i,by=(n,e)=>{const t=n.getAttribute("style"),r=t==null?void 0:t.match(vy);if(!r)return null;const s=Number(r[1]),i=t==null?void 0:t.match(yy),o=i?Number(i[1]):1,a=new RegExp(`@list l${s}:level${o}\\s*\\{[^\\}]*mso-level-number-format:\\s*([\\w-]+)`,"i"),u=e.match(a),c=u&&u[1]==="bullet"?"bullet":"ordered";return{id:s,indent:o,type:c,element:n}},Ey=n=>{var o,a;const e=Array.from(n.querySelectorAll("[style*=mso-list]")),t=[],r=[];e.forEach(u=>{(u.getAttribute("style")||"").match(my)?t.push(u):r.push(u)}),t.forEach(u=>{var c;return(c=u.parentNode)==null?void 0:c.removeChild(u)});const s=n.documentElement.innerHTML,i=r.map(u=>by(u,s)).filter(u=>u);for(;i.length;){const u=[];let c=i.shift();for(;c;)u.push(c),c=i.length&&((o=i[0])==null?void 0:o.element)===c.element.nextElementSibling&&i[0].id===c.id?i.shift():null;const h=document.createElement("ul");u.forEach(m=>{const v=document.createElement("li");v.setAttribute("data-list",m.type),m.indent>1&&v.setAttribute("class",`ql-indent-${m.indent-1}`),v.innerHTML=m.element.innerHTML,h.appendChild(v)});const g=(a=u[0])==null?void 0:a.element,{parentNode:d}=g??{};g&&(d==null||d.replaceChild(h,g)),u.slice(1).forEach(m=>{let{element:v}=m;d==null||d.removeChild(v)})}};function wy(n){n.documentElement.getAttribute("xmlns:w")==="urn:schemas-microsoft-com:office:word"&&Ey(n)}const xy=[wy,gy],Sy=n=>{n.documentElement&&xy.forEach(e=>{e(n)})},_y=Vt("quill:clipboard"),Ay=[[Node.TEXT_NODE,By],[Node.TEXT_NODE,Nu],["br",Iy],[Node.ELEMENT_NODE,Nu],[Node.ELEMENT_NODE,Ny],[Node.ELEMENT_NODE,ky],[Node.ELEMENT_NODE,Dy],["li",Ly],["ol, ul",My],["pre",Ry],["tr",Py],["b",qo("bold")],["i",qo("italic")],["strike",qo("strike")],["style",Oy]],Cy=[ry,Lh].reduce((n,e)=>(n[e.keyName]=e,n),{}),ku=[Rh,Ja,Qa,Dh,qh,jh].reduce((n,e)=>(n[e.keyName]=e,n),{});class $h extends mt{constructor(e,t){super(e,t),this.quill.root.addEventListener("copy",r=>this.onCaptureCopy(r,!1)),this.quill.root.addEventListener("cut",r=>this.onCaptureCopy(r,!0)),this.quill.root.addEventListener("paste",this.onCapturePaste.bind(this)),this.matchers=[],Ay.concat(this.options.matchers??[]).forEach(r=>{let[s,i]=r;this.addMatcher(s,i)})}addMatcher(e,t){this.matchers.push([e,t])}convert(e){let{html:t,text:r}=e,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(s[$e.blotName])return new re().insert(r||"",{[$e.blotName]:s[$e.blotName]});if(!t)return new re().insert(r||"",s);const i=this.convertHTML(t);return ts(i,`
132
- `)&&(i.ops[i.ops.length-1].attributes==null||s.table)?i.compose(new re().retain(i.length()-1).delete(1)):i}normalizeHTML(e){Sy(e)}convertHTML(e){const t=new DOMParser().parseFromString(e,"text/html");this.normalizeHTML(t);const r=t.body,s=new WeakMap,[i,o]=this.prepareMatching(r,s);return nl(this.quill.scroll,r,i,o,s)}dangerouslyPasteHTML(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:B.sources.API;if(typeof e=="string"){const s=this.convert({html:e,text:""});this.quill.setContents(s,t),this.quill.setSelection(0,B.sources.SILENT)}else{const s=this.convert({html:t,text:""});this.quill.updateContents(new re().retain(e).concat(s),r),this.quill.setSelection(e+s.length(),B.sources.SILENT)}}onCaptureCopy(e){var o,a;let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(e.defaultPrevented)return;e.preventDefault();const[r]=this.quill.selection.getRange();if(r==null)return;const{html:s,text:i}=this.onCopy(r,t);(o=e.clipboardData)==null||o.setData("text/plain",i),(a=e.clipboardData)==null||a.setData("text/html",s),t&&rl({range:r,quill:this.quill})}normalizeURIList(e){return e.split(/\r?\n/).filter(t=>t[0]!=="#").join(`
133
- `)}onCapturePaste(e){var o,a,u,c,h;if(e.defaultPrevented||!this.quill.isEnabled())return;e.preventDefault();const t=this.quill.getSelection(!0);if(t==null)return;const r=(o=e.clipboardData)==null?void 0:o.getData("text/html");let s=(a=e.clipboardData)==null?void 0:a.getData("text/plain");if(!r&&!s){const g=(u=e.clipboardData)==null?void 0:u.getData("text/uri-list");g&&(s=this.normalizeURIList(g))}const i=Array.from(((c=e.clipboardData)==null?void 0:c.files)||[]);if(!r&&i.length>0){this.quill.uploader.upload(t,i);return}if(r&&i.length>0){const g=new DOMParser().parseFromString(r,"text/html");if(g.body.childElementCount===1&&((h=g.body.firstElementChild)==null?void 0:h.tagName)==="IMG"){this.quill.uploader.upload(t,i);return}}this.onPaste(t,{html:r,text:s})}onCopy(e){const t=this.quill.getText(e);return{html:this.quill.getSemanticHTML(e),text:t}}onPaste(e,t){let{text:r,html:s}=t;const i=this.quill.getFormat(e.index),o=this.convert({text:r,html:s},i);_y.log("onPaste",o,{text:r,html:s});const a=new re().retain(e.index).delete(e.length).concat(o);this.quill.updateContents(a,B.sources.USER),this.quill.setSelection(a.length()-e.length,B.sources.SILENT),this.quill.scrollSelectionIntoView()}prepareMatching(e,t){const r=[],s=[];return this.matchers.forEach(i=>{const[o,a]=i;switch(o){case Node.TEXT_NODE:s.push(a);break;case Node.ELEMENT_NODE:r.push(a);break;default:Array.from(e.querySelectorAll(o)).forEach(u=>{if(t.has(u)){const c=t.get(u);c==null||c.push(a)}else t.set(u,[a])});break}}),[r,s]}}J($h,"DEFAULTS",{matchers:[]});function Or(n,e,t,r){return r.query(e)?n.reduce((s,i)=>{if(!i.insert)return s;if(i.attributes&&i.attributes[e])return s.push(i);const o=t?{[e]:t}:{};return s.insert(i.insert,{...o,...i.attributes})},new re):n}function ts(n,e){let t="";for(let r=n.ops.length-1;r>=0&&t.length<e.length;--r){const s=n.ops[r];if(typeof s.insert!="string")break;t=s.insert+t}return t.slice(-1*e.length)===e}function Zt(n,e){if(!(n instanceof Element))return!1;const t=e.query(n);return t&&t.prototype instanceof Ye?!1:["address","article","blockquote","canvas","dd","div","dl","dt","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","iframe","li","main","nav","ol","output","p","pre","section","table","td","tr","ul","video"].includes(n.tagName.toLowerCase())}function Ty(n,e){return n.previousElementSibling&&n.nextElementSibling&&!Zt(n.previousElementSibling,e)&&!Zt(n.nextElementSibling,e)}const Ms=new WeakMap;function Vh(n){return n==null?!1:(Ms.has(n)||(n.tagName==="PRE"?Ms.set(n,!0):Ms.set(n,Vh(n.parentNode))),Ms.get(n))}function nl(n,e,t,r,s){return e.nodeType===e.TEXT_NODE?r.reduce((i,o)=>o(e,i,n),new re):e.nodeType===e.ELEMENT_NODE?Array.from(e.childNodes||[]).reduce((i,o)=>{let a=nl(n,o,t,r,s);return o.nodeType===e.ELEMENT_NODE&&(a=t.reduce((u,c)=>c(o,u,n),a),a=(s.get(o)||[]).reduce((u,c)=>c(o,u,n),a)),i.concat(a)},new re):new re}function qo(n){return(e,t,r)=>Or(t,n,!0,r)}function ky(n,e,t){const r=At.keys(n),s=pt.keys(n),i=ir.keys(n),o={};return r.concat(s).concat(i).forEach(a=>{let u=t.query(a,ne.ATTRIBUTE);u!=null&&(o[u.attrName]=u.value(n),o[u.attrName])||(u=Cy[a],u!=null&&(u.attrName===a||u.keyName===a)&&(o[u.attrName]=u.value(n)||void 0),u=ku[a],u!=null&&(u.attrName===a||u.keyName===a)&&(u=ku[a],o[u.attrName]=u.value(n)||void 0))}),Object.entries(o).reduce((a,u)=>{let[c,h]=u;return Or(a,c,h,t)},e)}function Ny(n,e,t){const r=t.query(n);if(r==null)return e;if(r.prototype instanceof Ye){const s={},i=r.value(n);if(i!=null)return s[r.blotName]=i,new re().insert(s,r.formats(n,t))}else if(r.prototype instanceof Wn&&!ts(e,`
134
- `)&&e.insert(`
135
- `),"blotName"in r&&"formats"in r&&typeof r.formats=="function")return Or(e,r.blotName,r.formats(n,t),t);return e}function Iy(n,e){return ts(e,`
136
- `)||e.insert(`
137
- `),e}function Ry(n,e,t){const r=t.query("code-block"),s=r&&"formats"in r&&typeof r.formats=="function"?r.formats(n,t):!0;return Or(e,"code-block",s,t)}function Oy(){return new re}function Ly(n,e,t){const r=t.query(n);if(r==null||r.blotName!=="list"||!ts(e,`
138
- `))return e;let s=-1,i=n.parentNode;for(;i!=null;)["OL","UL"].includes(i.tagName)&&(s+=1),i=i.parentNode;return s<=0?e:e.reduce((o,a)=>a.insert?a.attributes&&typeof a.attributes.indent=="number"?o.push(a):o.insert(a.insert,{indent:s,...a.attributes||{}}):o,new re)}function My(n,e,t){const r=n;let s=r.tagName==="OL"?"ordered":"bullet";const i=r.getAttribute("data-checked");return i&&(s=i==="true"?"checked":"unchecked"),Or(e,"list",s,t)}function Nu(n,e,t){if(!ts(e,`
139
- `)){if(Zt(n,t)&&(n.childNodes.length>0||n instanceof HTMLParagraphElement))return e.insert(`
140
- `);if(e.length()>0&&n.nextSibling){let r=n.nextSibling;for(;r!=null;){if(Zt(r,t))return e.insert(`
141
- `);const s=t.query(r);if(s&&s.prototype instanceof et)return e.insert(`
142
- `);r=r.firstChild}}}return e}function Dy(n,e,t){var i;const r={},s=n.style||{};return s.fontStyle==="italic"&&(r.italic=!0),s.textDecoration==="underline"&&(r.underline=!0),s.textDecoration==="line-through"&&(r.strike=!0),((i=s.fontWeight)!=null&&i.startsWith("bold")||parseInt(s.fontWeight,10)>=700)&&(r.bold=!0),e=Object.entries(r).reduce((o,a)=>{let[u,c]=a;return Or(o,u,c,t)},e),parseFloat(s.textIndent||0)>0?new re().insert(" ").concat(e):e}function Py(n,e,t){var s,i;const r=((s=n.parentElement)==null?void 0:s.tagName)==="TABLE"?n.parentElement:(i=n.parentElement)==null?void 0:i.parentElement;if(r!=null){const a=Array.from(r.querySelectorAll("tr")).indexOf(n)+1;return Or(e,"table",a,t)}return e}function By(n,e,t){var s;let r=n.data;if(((s=n.parentElement)==null?void 0:s.tagName)==="O:P")return e.insert(r.trim());if(!Vh(n)){if(r.trim().length===0&&r.includes(`
143
- `)&&!Ty(n,t))return e;r=r.replace(/[^\S\u00a0]/g," "),r=r.replace(/ {2,}/g," "),(n.previousSibling==null&&n.parentElement!=null&&Zt(n.parentElement,t)||n.previousSibling instanceof Element&&Zt(n.previousSibling,t))&&(r=r.replace(/^ /,"")),(n.nextSibling==null&&n.parentElement!=null&&Zt(n.parentElement,t)||n.nextSibling instanceof Element&&Zt(n.nextSibling,t))&&(r=r.replace(/ $/,"")),r=r.replaceAll(" "," ")}return e.insert(r)}class Uh extends mt{constructor(t,r){super(t,r);J(this,"lastRecorded",0);J(this,"ignoreChange",!1);J(this,"stack",{undo:[],redo:[]});J(this,"currentRange",null);this.quill.on(B.events.EDITOR_CHANGE,(s,i,o,a)=>{s===B.events.SELECTION_CHANGE?i&&a!==B.sources.SILENT&&(this.currentRange=i):s===B.events.TEXT_CHANGE&&(this.ignoreChange||(!this.options.userOnly||a===B.sources.USER?this.record(i,o):this.transform(i)),this.currentRange=va(this.currentRange,i))}),this.quill.keyboard.addBinding({key:"z",shortKey:!0},this.undo.bind(this)),this.quill.keyboard.addBinding({key:["z","Z"],shortKey:!0,shiftKey:!0},this.redo.bind(this)),/Win/i.test(navigator.platform)&&this.quill.keyboard.addBinding({key:"y",shortKey:!0},this.redo.bind(this)),this.quill.root.addEventListener("beforeinput",s=>{s.inputType==="historyUndo"?(this.undo(),s.preventDefault()):s.inputType==="historyRedo"&&(this.redo(),s.preventDefault())})}change(t,r){if(this.stack[t].length===0)return;const s=this.stack[t].pop();if(!s)return;const i=this.quill.getContents(),o=s.delta.invert(i);this.stack[r].push({delta:o,range:va(s.range,o)}),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(s.delta,B.sources.USER),this.ignoreChange=!1,this.restoreSelection(s)}clear(){this.stack={undo:[],redo:[]}}cutoff(){this.lastRecorded=0}record(t,r){if(t.ops.length===0)return;this.stack.redo=[];let s=t.invert(r),i=this.currentRange;const o=Date.now();if(this.lastRecorded+this.options.delay>o&&this.stack.undo.length>0){const a=this.stack.undo.pop();a&&(s=s.compose(a.delta),i=a.range)}else this.lastRecorded=o;s.length()!==0&&(this.stack.undo.push({delta:s,range:i}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift())}redo(){this.change("redo","undo")}transform(t){Iu(this.stack.undo,t),Iu(this.stack.redo,t)}undo(){this.change("undo","redo")}restoreSelection(t){if(t.range)this.quill.setSelection(t.range,B.sources.USER);else{const r=Fy(this.quill.scroll,t.delta);this.quill.setSelection(r,B.sources.USER)}}}J(Uh,"DEFAULTS",{delay:1e3,maxStack:100,userOnly:!1});function Iu(n,e){let t=e;for(let r=n.length-1;r>=0;r-=1){const s=n[r];n[r]={delta:t.transform(s.delta,!0),range:s.range&&va(s.range,t)},t=s.delta.transform(t),n[r].delta.length()===0&&n.splice(r,1)}}function qy(n,e){const t=e.ops[e.ops.length-1];return t==null?!1:t.insert!=null?typeof t.insert=="string"&&t.insert.endsWith(`
144
- `):t.attributes!=null?Object.keys(t.attributes).some(r=>n.query(r,ne.BLOCK)!=null):!1}function Fy(n,e){const t=e.reduce((s,i)=>s+(i.delete||0),0);let r=e.length()-t;return qy(n,e)&&(r-=1),r}function va(n,e){if(!n)return n;const t=e.transformPosition(n.index),r=e.transformPosition(n.index+n.length);return{index:t,length:r-t}}class Hh extends mt{constructor(e,t){super(e,t),e.root.addEventListener("drop",r=>{var o;r.preventDefault();let s=null;if(document.caretRangeFromPoint)s=document.caretRangeFromPoint(r.clientX,r.clientY);else if(document.caretPositionFromPoint){const a=document.caretPositionFromPoint(r.clientX,r.clientY);s=document.createRange(),s.setStart(a.offsetNode,a.offset),s.setEnd(a.offsetNode,a.offset)}const i=s&&e.selection.normalizeNative(s);if(i){const a=e.selection.normalizedToRange(i);(o=r.dataTransfer)!=null&&o.files&&this.upload(a,r.dataTransfer.files)}})}upload(e,t){const r=[];Array.from(t).forEach(s=>{var i;s&&((i=this.options.mimetypes)!=null&&i.includes(s.type))&&r.push(s)}),r.length>0&&this.options.handler.call(this,e,r)}}Hh.DEFAULTS={mimetypes:["image/png","image/jpeg"],handler(n,e){if(!this.quill.scroll.query("image"))return;const t=e.map(r=>new Promise(s=>{const i=new FileReader;i.onload=()=>{s(i.result)},i.readAsDataURL(r)}));Promise.all(t).then(r=>{const s=r.reduce((i,o)=>i.insert({image:o}),new re().retain(n.index).delete(n.length));this.quill.updateContents(s,ee.sources.USER),this.quill.setSelection(n.index+r.length,ee.sources.SILENT)})}};const jy=["insertText","insertReplacementText"];let $y=class extends mt{constructor(e,t){super(e,t),e.root.addEventListener("beforeinput",r=>{this.handleBeforeInput(r)}),/Android/i.test(navigator.userAgent)||e.on(B.events.COMPOSITION_BEFORE_START,()=>{this.handleCompositionStart()})}deleteRange(e){rl({range:e,quill:this.quill})}replaceText(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";if(e.length===0)return!1;if(t){const r=this.quill.getFormat(e.index,1);this.deleteRange(e),this.quill.updateContents(new re().retain(e.index).insert(t,r),B.sources.USER)}else this.deleteRange(e);return this.quill.setSelection(e.index+t.length,0,B.sources.SILENT),!0}handleBeforeInput(e){if(this.quill.composition.isComposing||e.defaultPrevented||!jy.includes(e.inputType))return;const t=e.getTargetRanges?e.getTargetRanges()[0]:null;if(!t||t.collapsed===!0)return;const r=Vy(e);if(r==null)return;const s=this.quill.selection.normalizeNative(t),i=s?this.quill.selection.normalizedToRange(s):null;i&&this.replaceText(i,r)&&e.preventDefault()}handleCompositionStart(){const e=this.quill.getSelection();e&&this.replaceText(e)}};function Vy(n){var e;return typeof n.data=="string"?n.data:(e=n.dataTransfer)!=null&&e.types.includes("text/plain")?n.dataTransfer.getData("text/plain"):null}const Uy=/Mac/i.test(navigator.platform),Hy=100,zy=n=>!!(n.key==="ArrowLeft"||n.key==="ArrowRight"||n.key==="ArrowUp"||n.key==="ArrowDown"||n.key==="Home"||Uy&&n.key==="a"&&n.ctrlKey===!0);class Gy extends mt{constructor(t,r){super(t,r);J(this,"isListening",!1);J(this,"selectionChangeDeadline",0);this.handleArrowKeys(),this.handleNavigationShortcuts()}handleArrowKeys(){this.quill.keyboard.addBinding({key:["ArrowLeft","ArrowRight"],offset:0,shiftKey:null,handler(t,r){let{line:s,event:i}=r;if(!(s instanceof dt)||!s.uiNode)return!0;const o=getComputedStyle(s.domNode).direction==="rtl";return o&&i.key!=="ArrowRight"||!o&&i.key!=="ArrowLeft"?!0:(this.quill.setSelection(t.index-1,t.length+(i.shiftKey?1:0),B.sources.USER),!1)}})}handleNavigationShortcuts(){this.quill.root.addEventListener("keydown",t=>{!t.defaultPrevented&&zy(t)&&this.ensureListeningToSelectionChange()})}ensureListeningToSelectionChange(){if(this.selectionChangeDeadline=Date.now()+Hy,this.isListening)return;this.isListening=!0;const t=()=>{this.isListening=!1,Date.now()<=this.selectionChangeDeadline&&this.handleSelectionChange()};document.addEventListener("selectionchange",t,{once:!0})}handleSelectionChange(){const t=document.getSelection();if(!t)return;const r=t.getRangeAt(0);if(r.collapsed!==!0||r.startOffset!==0)return;const s=this.quill.scroll.find(r.startContainer);if(!(s instanceof dt)||!s.uiNode)return;const i=document.createRange();i.setStartAfter(s.uiNode),i.setEndAfter(s.uiNode),t.removeAllRanges(),t.addRange(i)}}B.register({"blots/block":Pe,"blots/block/embed":et,"blots/break":gt,"blots/container":Ir,"blots/cursor":un,"blots/embed":Za,"blots/inline":Ct,"blots/scroll":Xr,"blots/text":ft,"modules/clipboard":$h,"modules/history":Uh,"modules/keyboard":Ei,"modules/uploader":Hh,"modules/input":$y,"modules/uiNode":Gy});class Ky extends pt{add(e,t){let r=0;if(t==="+1"||t==="-1"){const s=this.value(e)||0;r=t==="+1"?s+1:s-1}else typeof t=="number"&&(r=t);return r===0?(this.remove(e),!0):super.add(e,r.toString())}canAdd(e,t){return super.canAdd(e,t)||super.canAdd(e,parseInt(t,10))}value(e){return parseInt(super.value(e),10)||void 0}}const Wy=new Ky("indent","ql-indent",{scope:ne.BLOCK,whitelist:[1,2,3,4,5,6,7,8]});class ya extends Pe{}J(ya,"blotName","blockquote"),J(ya,"tagName","blockquote");class ba extends Pe{static formats(e){return this.tagName.indexOf(e.tagName)+1}}J(ba,"blotName","header"),J(ba,"tagName",["H1","H2","H3","H4","H5","H6"]);class rs extends Ir{}rs.blotName="list-container";rs.tagName="OL";class ns extends Pe{static create(e){const t=super.create();return t.setAttribute("data-list",e),t}static formats(e){return e.getAttribute("data-list")||void 0}static register(){B.register(rs)}constructor(e,t){super(e,t);const r=t.ownerDocument.createElement("span"),s=i=>{if(!e.isEnabled())return;const o=this.statics.formats(t,e);o==="checked"?(this.format("list","unchecked"),i.preventDefault()):o==="unchecked"&&(this.format("list","checked"),i.preventDefault())};r.addEventListener("mousedown",s),r.addEventListener("touchstart",s),this.attachUI(r)}format(e,t){e===this.statics.blotName&&t?this.domNode.setAttribute("data-list",t):super.format(e,t)}}ns.blotName="list";ns.tagName="LI";rs.allowedChildren=[ns];ns.requiredContainer=rs;class Zn extends Ct{static create(){return super.create()}static formats(){return!0}optimize(e){super.optimize(e),this.domNode.tagName!==this.statics.tagName[0]&&this.replaceWith(this.statics.blotName)}}J(Zn,"blotName","bold"),J(Zn,"tagName",["STRONG","B"]);class Ea extends Zn{}J(Ea,"blotName","italic"),J(Ea,"tagName",["EM","I"]);class Xt extends Ct{static create(e){const t=super.create(e);return t.setAttribute("href",this.sanitize(e)),t.setAttribute("rel","noopener noreferrer"),t.setAttribute("target","_blank"),t}static formats(e){return e.getAttribute("href")}static sanitize(e){return zh(e,this.PROTOCOL_WHITELIST)?e:this.SANITIZED_URL}format(e,t){e!==this.statics.blotName||!t?super.format(e,t):this.domNode.setAttribute("href",this.constructor.sanitize(t))}}J(Xt,"blotName","link"),J(Xt,"tagName","A"),J(Xt,"SANITIZED_URL","about:blank"),J(Xt,"PROTOCOL_WHITELIST",["http","https","mailto","tel","sms"]);function zh(n,e){const t=document.createElement("a");t.href=n;const r=t.href.slice(0,t.href.indexOf(":"));return e.indexOf(r)>-1}class wa extends Ct{static create(e){return e==="super"?document.createElement("sup"):e==="sub"?document.createElement("sub"):super.create(e)}static formats(e){if(e.tagName==="SUB")return"sub";if(e.tagName==="SUP")return"super"}}J(wa,"blotName","script"),J(wa,"tagName",["SUB","SUP"]);class xa extends Zn{}J(xa,"blotName","strike"),J(xa,"tagName",["S","STRIKE"]);class Sa extends Ct{}J(Sa,"blotName","underline"),J(Sa,"tagName","U");class Us extends Za{static create(e){if(window.katex==null)throw new Error("Formula module requires KaTeX.");const t=super.create(e);return typeof e=="string"&&(window.katex.render(e,t,{throwOnError:!1,errorColor:"#f00"}),t.setAttribute("data-value",e)),t}static value(e){return e.getAttribute("data-value")}html(){const{formula:e}=this.value();return`<span>${e}</span>`}}J(Us,"blotName","formula"),J(Us,"className","ql-formula"),J(Us,"tagName","SPAN");const Ru=["alt","height","width"];class _a extends Ye{static create(e){const t=super.create(e);return typeof e=="string"&&t.setAttribute("src",this.sanitize(e)),t}static formats(e){return Ru.reduce((t,r)=>(e.hasAttribute(r)&&(t[r]=e.getAttribute(r)),t),{})}static match(e){return/\.(jpe?g|gif|png)$/.test(e)||/^data:image\/.+;base64/.test(e)}static sanitize(e){return zh(e,["http","https","data"])?e:"//:0"}static value(e){return e.getAttribute("src")}format(e,t){Ru.indexOf(e)>-1?t?this.domNode.setAttribute(e,t):this.domNode.removeAttribute(e):super.format(e,t)}}J(_a,"blotName","image"),J(_a,"tagName","IMG");const Ou=["height","width"];class Hs extends et{static create(e){const t=super.create(e);return t.setAttribute("frameborder","0"),t.setAttribute("allowfullscreen","true"),t.setAttribute("src",this.sanitize(e)),t}static formats(e){return Ou.reduce((t,r)=>(e.hasAttribute(r)&&(t[r]=e.getAttribute(r)),t),{})}static sanitize(e){return Xt.sanitize(e)}static value(e){return e.getAttribute("src")}format(e,t){Ou.indexOf(e)>-1?t?this.domNode.setAttribute(e,t):this.domNode.removeAttribute(e):super.format(e,t)}html(){const{video:e}=this.value();return`<a href="${e}">${e}</a>`}}J(Hs,"blotName","video"),J(Hs,"className","ql-video"),J(Hs,"tagName","IFRAME");const Bn=new pt("code-token","hljs",{scope:ne.INLINE});class Bt extends Ct{static formats(e,t){for(;e!=null&&e!==t.domNode;){if(e.classList&&e.classList.contains($e.className))return super.formats(e,t);e=e.parentNode}}constructor(e,t,r){super(e,t,r),Bn.add(this.domNode,r)}format(e,t){e!==Bt.blotName?super.format(e,t):t?Bn.add(this.domNode,t):(Bn.remove(this.domNode),this.domNode.classList.remove(this.statics.className))}optimize(){super.optimize(...arguments),Bn.value(this.domNode)||this.unwrap()}}Bt.blotName="code-token";Bt.className="ql-token";class Je extends $e{static create(e){const t=super.create(e);return typeof e=="string"&&t.setAttribute("data-language",e),t}static formats(e){return e.getAttribute("data-language")||"plain"}static register(){}format(e,t){e===this.statics.blotName&&t?this.domNode.setAttribute("data-language",t):super.format(e,t)}replaceWith(e,t){return this.formatAt(0,this.length(),Bt.blotName,!1),super.replaceWith(e,t)}}class $n extends Rr{attach(){super.attach(),this.forceNext=!1,this.scroll.emitMount(this)}format(e,t){e===Je.blotName&&(this.forceNext=!0,this.children.forEach(r=>{r.format(e,t)}))}formatAt(e,t,r,s){r===Je.blotName&&(this.forceNext=!0),super.formatAt(e,t,r,s)}highlight(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(this.children.head==null)return;const s=`${Array.from(this.domNode.childNodes).filter(o=>o!==this.uiNode).map(o=>o.textContent).join(`
145
- `)}
146
- `,i=Je.formats(this.children.head.domNode);if(t||this.forceNext||this.cachedText!==s){if(s.trim().length>0||this.cachedText==null){const o=this.children.reduce((u,c)=>u.concat(kh(c,!1)),new re),a=e(s,i);o.diff(a).reduce((u,c)=>{let{retain:h,attributes:g}=c;return h?(g&&Object.keys(g).forEach(d=>{[Je.blotName,Bt.blotName].includes(d)&&this.formatAt(u,h,d,g[d])}),u+h):u},0)}this.cachedText=s,this.forceNext=!1}}html(e,t){const[r]=this.children.find(e);return`<pre data-language="${r?Je.formats(r.domNode):"plain"}">
147
- ${bi(this.code(e,t))}
148
- </pre>`}optimize(e){if(super.optimize(e),this.parent!=null&&this.children.head!=null&&this.uiNode!=null){const t=Je.formats(this.children.head.domNode);t!==this.uiNode.value&&(this.uiNode.value=t)}}}$n.allowedChildren=[Je];Je.requiredContainer=$n;Je.allowedChildren=[Bt,un,ft,gt];const Yy=(n,e,t)=>{if(typeof n.versionString=="string"){const r=n.versionString.split(".")[0];if(parseInt(r,10)>=11)return n.highlight(t,{language:e}).value}return n.highlight(e,t).value};class Gh extends mt{static register(){B.register(Bt,!0),B.register(Je,!0),B.register($n,!0)}constructor(e,t){if(super(e,t),this.options.hljs==null)throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");this.languages=this.options.languages.reduce((r,s)=>{let{key:i}=s;return r[i]=!0,r},{}),this.highlightBlot=this.highlightBlot.bind(this),this.initListener(),this.initTimer()}initListener(){this.quill.on(B.events.SCROLL_BLOT_MOUNT,e=>{if(!(e instanceof $n))return;const t=this.quill.root.ownerDocument.createElement("select");this.options.languages.forEach(r=>{let{key:s,label:i}=r;const o=t.ownerDocument.createElement("option");o.textContent=i,o.setAttribute("value",s),t.appendChild(o)}),t.addEventListener("change",()=>{e.format(Je.blotName,t.value),this.quill.root.focus(),this.highlight(e,!0)}),e.uiNode==null&&(e.attachUI(t),e.children.head&&(t.value=Je.formats(e.children.head.domNode)))})}initTimer(){let e=null;this.quill.on(B.events.SCROLL_OPTIMIZE,()=>{e&&clearTimeout(e),e=setTimeout(()=>{this.highlight(),e=null},this.options.interval)})}highlight(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(this.quill.selection.composing)return;this.quill.update(B.sources.USER);const r=this.quill.getSelection();(e==null?this.quill.scroll.descendants($n):[e]).forEach(i=>{i.highlight(this.highlightBlot,t)}),this.quill.update(B.sources.SILENT),r!=null&&this.quill.setSelection(r,B.sources.SILENT)}highlightBlot(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"plain";if(t=this.languages[t]?t:"plain",t==="plain")return bi(e).split(`
149
- `).reduce((s,i,o)=>(o!==0&&s.insert(`
150
- `,{[$e.blotName]:t}),s.insert(i)),new re);const r=this.quill.root.ownerDocument.createElement("div");return r.classList.add($e.className),r.innerHTML=Yy(this.options.hljs,t,e),nl(this.quill.scroll,r,[(s,i)=>{const o=Bn.value(s);return o?i.compose(new re().retain(i.length(),{[Bt.blotName]:o})):i}],[(s,i)=>s.data.split(`
151
- `).reduce((o,a,u)=>(u!==0&&o.insert(`
152
- `,{[$e.blotName]:t}),o.insert(a)),i)],new WeakMap)}}Gh.DEFAULTS={hljs:window.hljs,interval:1e3,languages:[{key:"plain",label:"Plain"},{key:"bash",label:"Bash"},{key:"cpp",label:"C++"},{key:"cs",label:"C#"},{key:"css",label:"CSS"},{key:"diff",label:"Diff"},{key:"xml",label:"HTML/XML"},{key:"java",label:"Java"},{key:"javascript",label:"JavaScript"},{key:"markdown",label:"Markdown"},{key:"php",label:"PHP"},{key:"python",label:"Python"},{key:"ruby",label:"Ruby"},{key:"sql",label:"SQL"}]};const Un=class Un extends Pe{static create(e){const t=super.create();return e?t.setAttribute("data-row",e):t.setAttribute("data-row",sl()),t}static formats(e){if(e.hasAttribute("data-row"))return e.getAttribute("data-row")}cellOffset(){return this.parent?this.parent.children.indexOf(this):-1}format(e,t){e===Un.blotName&&t?this.domNode.setAttribute("data-row",t):super.format(e,t)}row(){return this.parent}rowOffset(){return this.row()?this.row().rowOffset():-1}table(){return this.row()&&this.row().table()}};J(Un,"blotName","table"),J(Un,"tagName","TD");let ct=Un;class qt extends Ir{checkMerge(){if(super.checkMerge()&&this.next.children.head!=null){const e=this.children.head.formats(),t=this.children.tail.formats(),r=this.next.children.head.formats(),s=this.next.children.tail.formats();return e.table===t.table&&e.table===r.table&&e.table===s.table}return!1}optimize(e){super.optimize(e),this.children.forEach(t=>{if(t.next==null)return;const r=t.formats(),s=t.next.formats();if(r.table!==s.table){const i=this.splitAfter(t);i&&i.optimize(),this.prev&&this.prev.optimize()}})}rowOffset(){return this.parent?this.parent.children.indexOf(this):-1}table(){return this.parent&&this.parent.parent}}J(qt,"blotName","table-row"),J(qt,"tagName","TR");class _t extends Ir{}J(_t,"blotName","table-body"),J(_t,"tagName","TBODY");class hn extends Ir{balanceCells(){const e=this.descendants(qt),t=e.reduce((r,s)=>Math.max(s.children.length,r),0);e.forEach(r=>{new Array(t-r.children.length).fill(0).forEach(()=>{let s;r.children.head!=null&&(s=ct.formats(r.children.head.domNode));const i=this.scroll.create(ct.blotName,s);r.appendChild(i),i.optimize()})})}cells(e){return this.rows().map(t=>t.children.at(e))}deleteColumn(e){const[t]=this.descendant(_t);t==null||t.children.head==null||t.children.forEach(r=>{const s=r.children.at(e);s!=null&&s.remove()})}insertColumn(e){const[t]=this.descendant(_t);t==null||t.children.head==null||t.children.forEach(r=>{const s=r.children.at(e),i=ct.formats(r.children.head.domNode),o=this.scroll.create(ct.blotName,i);r.insertBefore(o,s)})}insertRow(e){const[t]=this.descendant(_t);if(t==null||t.children.head==null)return;const r=sl(),s=this.scroll.create(qt.blotName);t.children.head.children.forEach(()=>{const o=this.scroll.create(ct.blotName,r);s.appendChild(o)});const i=t.children.at(e);t.insertBefore(s,i)}rows(){const e=this.children.head;return e==null?[]:e.children.map(t=>t)}}J(hn,"blotName","table-container"),J(hn,"tagName","TABLE");hn.allowedChildren=[_t];_t.requiredContainer=hn;_t.allowedChildren=[qt];qt.requiredContainer=_t;qt.allowedChildren=[ct];ct.requiredContainer=qt;function sl(){return`row-${Math.random().toString(36).slice(2,6)}`}class Zy extends mt{static register(){B.register(ct),B.register(qt),B.register(_t),B.register(hn)}constructor(){super(...arguments),this.listenBalanceCells()}balanceTables(){this.quill.scroll.descendants(hn).forEach(e=>{e.balanceCells()})}deleteColumn(){const[e,,t]=this.getTable();t!=null&&(e.deleteColumn(t.cellOffset()),this.quill.update(B.sources.USER))}deleteRow(){const[,e]=this.getTable();e!=null&&(e.remove(),this.quill.update(B.sources.USER))}deleteTable(){const[e]=this.getTable();if(e==null)return;const t=e.offset();e.remove(),this.quill.update(B.sources.USER),this.quill.setSelection(t,B.sources.SILENT)}getTable(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.quill.getSelection();if(e==null)return[null,null,null,-1];const[t,r]=this.quill.getLine(e.index);if(t==null||t.statics.blotName!==ct.blotName)return[null,null,null,-1];const s=t.parent;return[s.parent.parent,s,t,r]}insertColumn(e){const t=this.quill.getSelection();if(!t)return;const[r,s,i]=this.getTable(t);if(i==null)return;const o=i.cellOffset();r.insertColumn(o+e),this.quill.update(B.sources.USER);let a=s.rowOffset();e===0&&(a+=1),this.quill.setSelection(t.index+a,t.length,B.sources.SILENT)}insertColumnLeft(){this.insertColumn(0)}insertColumnRight(){this.insertColumn(1)}insertRow(e){const t=this.quill.getSelection();if(!t)return;const[r,s,i]=this.getTable(t);if(i==null)return;const o=s.rowOffset();r.insertRow(o+e),this.quill.update(B.sources.USER),e>0?this.quill.setSelection(t,B.sources.SILENT):this.quill.setSelection(t.index+s.children.length,t.length,B.sources.SILENT)}insertRowAbove(){this.insertRow(0)}insertRowBelow(){this.insertRow(1)}insertTable(e,t){const r=this.quill.getSelection();if(r==null)return;const s=new Array(e).fill(0).reduce(i=>{const o=new Array(t).fill(`
153
- `).join("");return i.insert(o,{table:sl()})},new re().retain(r.index));this.quill.updateContents(s,B.sources.USER),this.quill.setSelection(r.index,B.sources.SILENT),this.balanceTables()}listenBalanceCells(){this.quill.on(B.events.SCROLL_OPTIMIZE,e=>{e.some(t=>["TD","TR","TBODY","TABLE"].includes(t.target.tagName)?(this.quill.once(B.events.TEXT_CHANGE,(r,s,i)=>{i===B.sources.USER&&this.balanceTables()}),!0):!1)})}}const Lu=Vt("quill:toolbar");class il extends mt{constructor(e,t){var r,s;if(super(e,t),Array.isArray(this.options.container)){const i=document.createElement("div");i.setAttribute("role","toolbar"),Xy(i,this.options.container),(s=(r=e.container)==null?void 0:r.parentNode)==null||s.insertBefore(i,e.container),this.container=i}else typeof this.options.container=="string"?this.container=document.querySelector(this.options.container):this.container=this.options.container;if(!(this.container instanceof HTMLElement)){Lu.error("Container required for toolbar",this.options);return}this.container.classList.add("ql-toolbar"),this.controls=[],this.handlers={},this.options.handlers&&Object.keys(this.options.handlers).forEach(i=>{var a;const o=(a=this.options.handlers)==null?void 0:a[i];o&&this.addHandler(i,o)}),Array.from(this.container.querySelectorAll("button, select")).forEach(i=>{this.attach(i)}),this.quill.on(B.events.EDITOR_CHANGE,()=>{const[i]=this.quill.selection.getRange();this.update(i)})}addHandler(e,t){this.handlers[e]=t}attach(e){let t=Array.from(e.classList).find(s=>s.indexOf("ql-")===0);if(!t)return;if(t=t.slice(3),e.tagName==="BUTTON"&&e.setAttribute("type","button"),this.handlers[t]==null&&this.quill.scroll.query(t)==null){Lu.warn("ignoring attaching to nonexistent format",t,e);return}const r=e.tagName==="SELECT"?"change":"click";e.addEventListener(r,s=>{let i;if(e.tagName==="SELECT"){if(e.selectedIndex<0)return;const a=e.options[e.selectedIndex];a.hasAttribute("selected")?i=!1:i=a.value||!1}else e.classList.contains("ql-active")?i=!1:i=e.value||!e.hasAttribute("value"),s.preventDefault();this.quill.focus();const[o]=this.quill.selection.getRange();if(this.handlers[t]!=null)this.handlers[t].call(this,i);else if(this.quill.scroll.query(t).prototype instanceof Ye){if(i=prompt(`Enter ${t}`),!i)return;this.quill.updateContents(new re().retain(o.index).delete(o.length).insert({[t]:i}),B.sources.USER)}else this.quill.format(t,i,B.sources.USER);this.update(o)}),this.controls.push([t,e])}update(e){const t=e==null?{}:this.quill.getFormat(e);this.controls.forEach(r=>{const[s,i]=r;if(i.tagName==="SELECT"){let o=null;if(e==null)o=null;else if(t[s]==null)o=i.querySelector("option[selected]");else if(!Array.isArray(t[s])){let a=t[s];typeof a=="string"&&(a=a.replace(/"/g,'\\"')),o=i.querySelector(`option[value="${a}"]`)}o==null?(i.value="",i.selectedIndex=-1):o.selected=!0}else if(e==null)i.classList.remove("ql-active"),i.setAttribute("aria-pressed","false");else if(i.hasAttribute("value")){const o=t[s],a=o===i.getAttribute("value")||o!=null&&o.toString()===i.getAttribute("value")||o==null&&!i.getAttribute("value");i.classList.toggle("ql-active",a),i.setAttribute("aria-pressed",a.toString())}else{const o=t[s]!=null;i.classList.toggle("ql-active",o),i.setAttribute("aria-pressed",o.toString())}})}}il.DEFAULTS={};function Mu(n,e,t){const r=document.createElement("button");r.setAttribute("type","button"),r.classList.add(`ql-${e}`),r.setAttribute("aria-pressed","false"),t!=null?(r.value=t,r.setAttribute("aria-label",`${e}: ${t}`)):r.setAttribute("aria-label",e),n.appendChild(r)}function Xy(n,e){Array.isArray(e[0])||(e=[e]),e.forEach(t=>{const r=document.createElement("span");r.classList.add("ql-formats"),t.forEach(s=>{if(typeof s=="string")Mu(r,s);else{const i=Object.keys(s)[0],o=s[i];Array.isArray(o)?Qy(r,i,o):Mu(r,i,o)}}),n.appendChild(r)})}function Qy(n,e,t){const r=document.createElement("select");r.classList.add(`ql-${e}`),t.forEach(s=>{const i=document.createElement("option");s!==!1?i.setAttribute("value",String(s)):i.setAttribute("selected","selected"),r.appendChild(i)}),n.appendChild(r)}il.DEFAULTS={container:null,handlers:{clean(){const n=this.quill.getSelection();if(n!=null)if(n.length===0){const e=this.quill.getFormat();Object.keys(e).forEach(t=>{this.quill.scroll.query(t,ne.INLINE)!=null&&this.quill.format(t,!1,B.sources.USER)})}else this.quill.removeFormat(n.index,n.length,B.sources.USER)},direction(n){const{align:e}=this.quill.getFormat();n==="rtl"&&e==null?this.quill.format("align","right",B.sources.USER):!n&&e==="right"&&this.quill.format("align",!1,B.sources.USER),this.quill.format("direction",n,B.sources.USER)},indent(n){const e=this.quill.getSelection(),t=this.quill.getFormat(e),r=parseInt(t.indent||0,10);if(n==="+1"||n==="-1"){let s=n==="+1"?1:-1;t.direction==="rtl"&&(s*=-1),this.quill.format("indent",r+s,B.sources.USER)}},link(n){n===!0&&(n=prompt("Enter link URL:")),this.quill.format("link",n,B.sources.USER)},list(n){const e=this.quill.getSelection(),t=this.quill.getFormat(e);n==="check"?t.list==="checked"||t.list==="unchecked"?this.quill.format("list",!1,B.sources.USER):this.quill.format("list","unchecked",B.sources.USER):this.quill.format("list",n,B.sources.USER)}}};const Jy='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="3" x2="15" y1="9" y2="9"/><line class="ql-stroke" x1="3" x2="13" y1="14" y2="14"/><line class="ql-stroke" x1="3" x2="9" y1="4" y2="4"/></svg>',eb='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="15" x2="3" y1="9" y2="9"/><line class="ql-stroke" x1="14" x2="4" y1="14" y2="14"/><line class="ql-stroke" x1="12" x2="6" y1="4" y2="4"/></svg>',tb='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="15" x2="3" y1="9" y2="9"/><line class="ql-stroke" x1="15" x2="5" y1="14" y2="14"/><line class="ql-stroke" x1="15" x2="9" y1="4" y2="4"/></svg>',rb='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="15" x2="3" y1="9" y2="9"/><line class="ql-stroke" x1="15" x2="3" y1="14" y2="14"/><line class="ql-stroke" x1="15" x2="3" y1="4" y2="4"/></svg>',nb='<svg viewbox="0 0 18 18"><g class="ql-fill ql-color-label"><polygon points="6 6.868 6 6 5 6 5 7 5.942 7 6 6.868"/><rect height="1" width="1" x="4" y="4"/><polygon points="6.817 5 6 5 6 6 6.38 6 6.817 5"/><rect height="1" width="1" x="2" y="6"/><rect height="1" width="1" x="3" y="5"/><rect height="1" width="1" x="4" y="7"/><polygon points="4 11.439 4 11 3 11 3 12 3.755 12 4 11.439"/><rect height="1" width="1" x="2" y="12"/><rect height="1" width="1" x="2" y="9"/><rect height="1" width="1" x="2" y="15"/><polygon points="4.63 10 4 10 4 11 4.192 11 4.63 10"/><rect height="1" width="1" x="3" y="8"/><path d="M10.832,4.2L11,4.582V4H10.708A1.948,1.948,0,0,1,10.832,4.2Z"/><path d="M7,4.582L7.168,4.2A1.929,1.929,0,0,1,7.292,4H7V4.582Z"/><path d="M8,13H7.683l-0.351.8a1.933,1.933,0,0,1-.124.2H8V13Z"/><rect height="1" width="1" x="12" y="2"/><rect height="1" width="1" x="11" y="3"/><path d="M9,3H8V3.282A1.985,1.985,0,0,1,9,3Z"/><rect height="1" width="1" x="2" y="3"/><rect height="1" width="1" x="6" y="2"/><rect height="1" width="1" x="3" y="2"/><rect height="1" width="1" x="5" y="3"/><rect height="1" width="1" x="9" y="2"/><rect height="1" width="1" x="15" y="14"/><polygon points="13.447 10.174 13.469 10.225 13.472 10.232 13.808 11 14 11 14 10 13.37 10 13.447 10.174"/><rect height="1" width="1" x="13" y="7"/><rect height="1" width="1" x="15" y="5"/><rect height="1" width="1" x="14" y="6"/><rect height="1" width="1" x="15" y="8"/><rect height="1" width="1" x="14" y="9"/><path d="M3.775,14H3v1H4V14.314A1.97,1.97,0,0,1,3.775,14Z"/><rect height="1" width="1" x="14" y="3"/><polygon points="12 6.868 12 6 11.62 6 12 6.868"/><rect height="1" width="1" x="15" y="2"/><rect height="1" width="1" x="12" y="5"/><rect height="1" width="1" x="13" y="4"/><polygon points="12.933 9 13 9 13 8 12.495 8 12.933 9"/><rect height="1" width="1" x="9" y="14"/><rect height="1" width="1" x="8" y="15"/><path d="M6,14.926V15H7V14.316A1.993,1.993,0,0,1,6,14.926Z"/><rect height="1" width="1" x="5" y="15"/><path d="M10.668,13.8L10.317,13H10v1h0.792A1.947,1.947,0,0,1,10.668,13.8Z"/><rect height="1" width="1" x="11" y="15"/><path d="M14.332,12.2a1.99,1.99,0,0,1,.166.8H15V12H14.245Z"/><rect height="1" width="1" x="14" y="15"/><rect height="1" width="1" x="15" y="11"/></g><polyline class="ql-stroke" points="5.5 13 9 5 12.5 13"/><line class="ql-stroke" x1="11.63" x2="6.38" y1="11" y2="11"/></svg>',sb='<svg viewbox="0 0 18 18"><rect class="ql-fill ql-stroke" height="3" width="3" x="4" y="5"/><rect class="ql-fill ql-stroke" height="3" width="3" x="11" y="5"/><path class="ql-even ql-fill ql-stroke" d="M7,8c0,4.031-3,5-3,5"/><path class="ql-even ql-fill ql-stroke" d="M14,8c0,4.031-3,5-3,5"/></svg>',ib='<svg viewbox="0 0 18 18"><path class="ql-stroke" d="M5,4H9.5A2.5,2.5,0,0,1,12,6.5v0A2.5,2.5,0,0,1,9.5,9H5A0,0,0,0,1,5,9V4A0,0,0,0,1,5,4Z"/><path class="ql-stroke" d="M5,9h5.5A2.5,2.5,0,0,1,13,11.5v0A2.5,2.5,0,0,1,10.5,14H5a0,0,0,0,1,0,0V9A0,0,0,0,1,5,9Z"/></svg>',ob='<svg class="" viewbox="0 0 18 18"><line class="ql-stroke" x1="5" x2="13" y1="3" y2="3"/><line class="ql-stroke" x1="6" x2="9.35" y1="12" y2="3"/><line class="ql-stroke" x1="11" x2="15" y1="11" y2="15"/><line class="ql-stroke" x1="15" x2="11" y1="11" y2="15"/><rect class="ql-fill" height="1" rx="0.5" ry="0.5" width="7" x="2" y="14"/></svg>',Du='<svg viewbox="0 0 18 18"><polyline class="ql-even ql-stroke" points="5 7 3 9 5 11"/><polyline class="ql-even ql-stroke" points="13 7 15 9 13 11"/><line class="ql-stroke" x1="10" x2="8" y1="5" y2="13"/></svg>',ab='<svg viewbox="0 0 18 18"><line class="ql-color-label ql-stroke ql-transparent" x1="3" x2="15" y1="15" y2="15"/><polyline class="ql-stroke" points="5.5 11 9 3 12.5 11"/><line class="ql-stroke" x1="11.63" x2="6.38" y1="9" y2="9"/></svg>',lb='<svg viewbox="0 0 18 18"><polygon class="ql-stroke ql-fill" points="3 11 5 9 3 7 3 11"/><line class="ql-stroke ql-fill" x1="15" x2="11" y1="4" y2="4"/><path class="ql-fill" d="M11,3a3,3,0,0,0,0,6h1V3H11Z"/><rect class="ql-fill" height="11" width="1" x="11" y="4"/><rect class="ql-fill" height="11" width="1" x="13" y="4"/></svg>',ub='<svg viewbox="0 0 18 18"><polygon class="ql-stroke ql-fill" points="15 12 13 10 15 8 15 12"/><line class="ql-stroke ql-fill" x1="9" x2="5" y1="4" y2="4"/><path class="ql-fill" d="M5,3A3,3,0,0,0,5,9H6V3H5Z"/><rect class="ql-fill" height="11" width="1" x="5" y="4"/><rect class="ql-fill" height="11" width="1" x="7" y="4"/></svg>',cb='<svg viewbox="0 0 18 18"><path class="ql-fill" d="M11.759,2.482a2.561,2.561,0,0,0-3.53.607A7.656,7.656,0,0,0,6.8,6.2C6.109,9.188,5.275,14.677,4.15,14.927a1.545,1.545,0,0,0-1.3-.933A0.922,0.922,0,0,0,2,15.036S1.954,16,4.119,16s3.091-2.691,3.7-5.553c0.177-.826.36-1.726,0.554-2.6L8.775,6.2c0.381-1.421.807-2.521,1.306-2.676a1.014,1.014,0,0,0,1.02.56A0.966,0.966,0,0,0,11.759,2.482Z"/><rect class="ql-fill" height="1.6" rx="0.8" ry="0.8" width="5" x="5.15" y="6.2"/><path class="ql-fill" d="M13.663,12.027a1.662,1.662,0,0,1,.266-0.276q0.193,0.069.456,0.138a2.1,2.1,0,0,0,.535.069,1.075,1.075,0,0,0,.767-0.3,1.044,1.044,0,0,0,.314-0.8,0.84,0.84,0,0,0-.238-0.619,0.8,0.8,0,0,0-.594-0.239,1.154,1.154,0,0,0-.781.3,4.607,4.607,0,0,0-.781,1q-0.091.15-.218,0.346l-0.246.38c-0.068-.288-0.137-0.582-0.212-0.885-0.459-1.847-2.494-.984-2.941-0.8-0.482.2-.353,0.647-0.094,0.529a0.869,0.869,0,0,1,1.281.585c0.217,0.751.377,1.436,0.527,2.038a5.688,5.688,0,0,1-.362.467,2.69,2.69,0,0,1-.264.271q-0.221-.08-0.471-0.147a2.029,2.029,0,0,0-.522-0.066,1.079,1.079,0,0,0-.768.3A1.058,1.058,0,0,0,9,15.131a0.82,0.82,0,0,0,.832.852,1.134,1.134,0,0,0,.787-0.3,5.11,5.11,0,0,0,.776-0.993q0.141-.219.215-0.34c0.046-.076.122-0.194,0.223-0.346a2.786,2.786,0,0,0,.918,1.726,2.582,2.582,0,0,0,2.376-.185c0.317-.181.212-0.565,0-0.494A0.807,0.807,0,0,1,14.176,15a5.159,5.159,0,0,1-.913-2.446l0,0Q13.487,12.24,13.663,12.027Z"/></svg>',hb='<svg viewBox="0 0 18 18"><path class="ql-fill" d="M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm6.06787,9.209H14.98975V7.59863a.54085.54085,0,0,0-.605-.60547h-.62744a1.01119,1.01119,0,0,0-.748.29688L11.645,8.56641a.5435.5435,0,0,0-.022.8584l.28613.30762a.53861.53861,0,0,0,.84717.0332l.09912-.08789a1.2137,1.2137,0,0,0,.2417-.35254h.02246s-.01123.30859-.01123.60547V13.209H12.041a.54085.54085,0,0,0-.605.60547v.43945a.54085.54085,0,0,0,.605.60547h4.02686a.54085.54085,0,0,0,.605-.60547v-.43945A.54085.54085,0,0,0,16.06787,13.209Z"/></svg>',db='<svg viewBox="0 0 18 18"><path class="ql-fill" d="M16.73975,13.81445v.43945a.54085.54085,0,0,1-.605.60547H11.855a.58392.58392,0,0,1-.64893-.60547V14.0127c0-2.90527,3.39941-3.42187,3.39941-4.55469a.77675.77675,0,0,0-.84717-.78125,1.17684,1.17684,0,0,0-.83594.38477c-.2749.26367-.561.374-.85791.13184l-.4292-.34082c-.30811-.24219-.38525-.51758-.1543-.81445a2.97155,2.97155,0,0,1,2.45361-1.17676,2.45393,2.45393,0,0,1,2.68408,2.40918c0,2.45312-3.1792,2.92676-3.27832,3.93848h2.79443A.54085.54085,0,0,1,16.73975,13.81445ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z"/></svg>',fb='<svg viewBox="0 0 18 18"><path class="ql-fill" d="M16.65186,12.30664a2.6742,2.6742,0,0,1-2.915,2.68457,3.96592,3.96592,0,0,1-2.25537-.6709.56007.56007,0,0,1-.13232-.83594L11.64648,13c.209-.34082.48389-.36328.82471-.1543a2.32654,2.32654,0,0,0,1.12256.33008c.71484,0,1.12207-.35156,1.12207-.78125,0-.61523-.61621-.86816-1.46338-.86816H13.2085a.65159.65159,0,0,1-.68213-.41895l-.05518-.10937a.67114.67114,0,0,1,.14307-.78125l.71533-.86914a8.55289,8.55289,0,0,1,.68213-.7373V8.58887a3.93913,3.93913,0,0,1-.748.05469H11.9873a.54085.54085,0,0,1-.605-.60547V7.59863a.54085.54085,0,0,1,.605-.60547h3.75146a.53773.53773,0,0,1,.60547.59375v.17676a1.03723,1.03723,0,0,1-.27539.748L14.74854,10.0293A2.31132,2.31132,0,0,1,16.65186,12.30664ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z"/></svg>',pb='<svg viewBox="0 0 18 18"><path class="ql-fill" d="M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm7.05371,7.96582v.38477c0,.39648-.165.60547-.46191.60547h-.47314v1.29785a.54085.54085,0,0,1-.605.60547h-.69336a.54085.54085,0,0,1-.605-.60547V12.95605H11.333a.5412.5412,0,0,1-.60547-.60547v-.15332a1.199,1.199,0,0,1,.22021-.748l2.56348-4.05957a.7819.7819,0,0,1,.72607-.39648h1.27637a.54085.54085,0,0,1,.605.60547v3.7627h.33008A.54055.54055,0,0,1,17.05371,11.96582ZM14.28125,8.7207h-.022a4.18969,4.18969,0,0,1-.38525.81348l-1.188,1.80469v.02246h1.5293V9.60059A7.04058,7.04058,0,0,1,14.28125,8.7207Z"/></svg>',gb='<svg viewBox="0 0 18 18"><path class="ql-fill" d="M16.74023,12.18555a2.75131,2.75131,0,0,1-2.91553,2.80566,3.908,3.908,0,0,1-2.25537-.68164.54809.54809,0,0,1-.13184-.8252L11.73438,13c.209-.34082.48389-.36328.8252-.1543a2.23757,2.23757,0,0,0,1.1001.33008,1.01827,1.01827,0,0,0,1.1001-.96777c0-.61621-.53906-.97949-1.25439-.97949a2.15554,2.15554,0,0,0-.64893.09961,1.15209,1.15209,0,0,1-.814.01074l-.12109-.04395a.64116.64116,0,0,1-.45117-.71484l.231-3.00391a.56666.56666,0,0,1,.62744-.583H15.541a.54085.54085,0,0,1,.605.60547v.43945a.54085.54085,0,0,1-.605.60547H13.41748l-.04395.72559a1.29306,1.29306,0,0,1-.04395.30859h.022a2.39776,2.39776,0,0,1,.57227-.07715A2.53266,2.53266,0,0,1,16.74023,12.18555ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z"/></svg>',mb='<svg viewBox="0 0 18 18"><path class="ql-fill" d="M14.51758,9.64453a1.85627,1.85627,0,0,0-1.24316.38477H13.252a1.73532,1.73532,0,0,1,1.72754-1.4082,2.66491,2.66491,0,0,1,.5498.06641c.35254.05469.57227.01074.70508-.40723l.16406-.5166a.53393.53393,0,0,0-.373-.75977,4.83723,4.83723,0,0,0-1.17773-.14258c-2.43164,0-3.7627,2.17773-3.7627,4.43359,0,2.47559,1.60645,3.69629,3.19043,3.69629A2.70585,2.70585,0,0,0,16.96,12.19727,2.43861,2.43861,0,0,0,14.51758,9.64453Zm-.23047,3.58691c-.67187,0-1.22168-.81445-1.22168-1.45215,0-.47363.30762-.583.72559-.583.96875,0,1.27734.59375,1.27734,1.12207A.82182.82182,0,0,1,14.28711,13.23145ZM10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Z"/></svg>',vb='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="7" x2="13" y1="4" y2="4"/><line class="ql-stroke" x1="5" x2="11" y1="14" y2="14"/><line class="ql-stroke" x1="8" x2="10" y1="14" y2="4"/></svg>',yb='<svg viewbox="0 0 18 18"><rect class="ql-stroke" height="10" width="12" x="3" y="4"/><circle class="ql-fill" cx="6" cy="7" r="1"/><polyline class="ql-even ql-fill" points="5 12 5 11 7 9 8 10 11 7 13 9 13 12 5 12"/></svg>',bb='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="3" x2="15" y1="14" y2="14"/><line class="ql-stroke" x1="3" x2="15" y1="4" y2="4"/><line class="ql-stroke" x1="9" x2="15" y1="9" y2="9"/><polyline class="ql-fill ql-stroke" points="3 7 3 11 5 9 3 7"/></svg>',Eb='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="3" x2="15" y1="14" y2="14"/><line class="ql-stroke" x1="3" x2="15" y1="4" y2="4"/><line class="ql-stroke" x1="9" x2="15" y1="9" y2="9"/><polyline class="ql-stroke" points="5 7 5 11 3 9 5 7"/></svg>',wb='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="7" x2="11" y1="7" y2="11"/><path class="ql-even ql-stroke" d="M8.9,4.577a3.476,3.476,0,0,1,.36,4.679A3.476,3.476,0,0,1,4.577,8.9C3.185,7.5,2.035,6.4,4.217,4.217S7.5,3.185,8.9,4.577Z"/><path class="ql-even ql-stroke" d="M13.423,9.1a3.476,3.476,0,0,0-4.679-.36,3.476,3.476,0,0,0,.36,4.679c1.392,1.392,2.5,2.542,4.679.36S14.815,10.5,13.423,9.1Z"/></svg>',xb='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="6" x2="15" y1="4" y2="4"/><line class="ql-stroke" x1="6" x2="15" y1="9" y2="9"/><line class="ql-stroke" x1="6" x2="15" y1="14" y2="14"/><line class="ql-stroke" x1="3" x2="3" y1="4" y2="4"/><line class="ql-stroke" x1="3" x2="3" y1="9" y2="9"/><line class="ql-stroke" x1="3" x2="3" y1="14" y2="14"/></svg>',Sb='<svg class="" viewbox="0 0 18 18"><line class="ql-stroke" x1="9" x2="15" y1="4" y2="4"/><polyline class="ql-stroke" points="3 4 4 5 6 3"/><line class="ql-stroke" x1="9" x2="15" y1="14" y2="14"/><polyline class="ql-stroke" points="3 14 4 15 6 13"/><line class="ql-stroke" x1="9" x2="15" y1="9" y2="9"/><polyline class="ql-stroke" points="3 9 4 10 6 8"/></svg>',_b='<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="7" x2="15" y1="4" y2="4"/><line class="ql-stroke" x1="7" x2="15" y1="9" y2="9"/><line class="ql-stroke" x1="7" x2="15" y1="14" y2="14"/><line class="ql-stroke ql-thin" x1="2.5" x2="4.5" y1="5.5" y2="5.5"/><path class="ql-fill" d="M3.5,6A0.5,0.5,0,0,1,3,5.5V3.085l-0.276.138A0.5,0.5,0,0,1,2.053,3c-0.124-.247-0.023-0.324.224-0.447l1-.5A0.5,0.5,0,0,1,4,2.5v3A0.5,0.5,0,0,1,3.5,6Z"/><path class="ql-stroke ql-thin" d="M4.5,10.5h-2c0-.234,1.85-1.076,1.85-2.234A0.959,0.959,0,0,0,2.5,8.156"/><path class="ql-stroke ql-thin" d="M2.5,14.846a0.959,0.959,0,0,0,1.85-.109A0.7,0.7,0,0,0,3.75,14a0.688,0.688,0,0,0,.6-0.736,0.959,0.959,0,0,0-1.85-.109"/></svg>',Ab='<svg viewbox="0 0 18 18"><path class="ql-fill" d="M15.5,15H13.861a3.858,3.858,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.921,1.921,0,0,0,12.021,11.7a0.50013,0.50013,0,1,0,.957.291h0a0.914,0.914,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.076-1.16971,1.86982-1.93971,2.43082A1.45639,1.45639,0,0,0,12,15.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,15Z"/><path class="ql-fill" d="M9.65,5.241a1,1,0,0,0-1.409.108L6,7.964,3.759,5.349A1,1,0,0,0,2.192,6.59178Q2.21541,6.6213,2.241,6.649L4.684,9.5,2.241,12.35A1,1,0,0,0,3.71,13.70722q0.02557-.02768.049-0.05722L6,11.036,8.241,13.65a1,1,0,1,0,1.567-1.24277Q9.78459,12.3777,9.759,12.35L7.316,9.5,9.759,6.651A1,1,0,0,0,9.65,5.241Z"/></svg>',Cb='<svg viewbox="0 0 18 18"><path class="ql-fill" d="M15.5,7H13.861a4.015,4.015,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.922,1.922,0,0,0,12.021,3.7a0.5,0.5,0,1,0,.957.291,0.917,0.917,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.077-1.164,1.925-1.934,2.486A1.423,1.423,0,0,0,12,7.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,7Z"/><path class="ql-fill" d="M9.651,5.241a1,1,0,0,0-1.41.108L6,7.964,3.759,5.349a1,1,0,1,0-1.519,1.3L4.683,9.5,2.241,12.35a1,1,0,1,0,1.519,1.3L6,11.036,8.241,13.65a1,1,0,0,0,1.519-1.3L7.317,9.5,9.759,6.651A1,1,0,0,0,9.651,5.241Z"/></svg>',Tb='<svg viewbox="0 0 18 18"><line class="ql-stroke ql-thin" x1="15.5" x2="2.5" y1="8.5" y2="9.5"/><path class="ql-fill" d="M9.007,8C6.542,7.791,6,7.519,6,6.5,6,5.792,7.283,5,9,5c1.571,0,2.765.679,2.969,1.309a1,1,0,0,0,1.9-.617C13.356,4.106,11.354,3,9,3,6.2,3,4,4.538,4,6.5a3.2,3.2,0,0,0,.5,1.843Z"/><path class="ql-fill" d="M8.984,10C11.457,10.208,12,10.479,12,11.5c0,0.708-1.283,1.5-3,1.5-1.571,0-2.765-.679-2.969-1.309a1,1,0,1,0-1.9.617C4.644,13.894,6.646,15,9,15c2.8,0,5-1.538,5-3.5a3.2,3.2,0,0,0-.5-1.843Z"/></svg>',kb='<svg viewbox="0 0 18 18"><rect class="ql-stroke" height="12" width="12" x="3" y="3"/><rect class="ql-fill" height="2" width="3" x="5" y="5"/><rect class="ql-fill" height="2" width="4" x="9" y="5"/><g class="ql-fill ql-transparent"><rect height="2" width="3" x="5" y="8"/><rect height="2" width="4" x="9" y="8"/><rect height="2" width="3" x="5" y="11"/><rect height="2" width="4" x="9" y="11"/></g></svg>',Nb='<svg viewbox="0 0 18 18"><path class="ql-stroke" d="M5,3V9a4.012,4.012,0,0,0,4,4H9a4.012,4.012,0,0,0,4-4V3"/><rect class="ql-fill" height="1" rx="0.5" ry="0.5" width="12" x="3" y="15"/></svg>',Ib='<svg viewbox="0 0 18 18"><rect class="ql-stroke" height="12" width="12" x="3" y="3"/><rect class="ql-fill" height="12" width="1" x="5" y="3"/><rect class="ql-fill" height="12" width="1" x="12" y="3"/><rect class="ql-fill" height="2" width="8" x="5" y="8"/><rect class="ql-fill" height="1" width="3" x="3" y="5"/><rect class="ql-fill" height="1" width="3" x="3" y="7"/><rect class="ql-fill" height="1" width="3" x="3" y="10"/><rect class="ql-fill" height="1" width="3" x="3" y="12"/><rect class="ql-fill" height="1" width="3" x="12" y="5"/><rect class="ql-fill" height="1" width="3" x="12" y="7"/><rect class="ql-fill" height="1" width="3" x="12" y="10"/><rect class="ql-fill" height="1" width="3" x="12" y="12"/></svg>',Xn={align:{"":Jy,center:eb,right:tb,justify:rb},background:nb,blockquote:sb,bold:ib,clean:ob,code:Du,"code-block":Du,color:ab,direction:{"":lb,rtl:ub},formula:cb,header:{1:hb,2:db,3:fb,4:pb,5:gb,6:mb},italic:vb,image:yb,indent:{"+1":bb,"-1":Eb},link:wb,list:{bullet:xb,check:Sb,ordered:_b},script:{sub:Ab,super:Cb},strike:Tb,table:kb,underline:Nb,video:Ib},Rb='<svg viewbox="0 0 18 18"><polygon class="ql-stroke" points="7 11 9 13 11 11 7 11"/><polygon class="ql-stroke" points="7 7 9 5 11 7 7 7"/></svg>';let Pu=0;function Bu(n,e){n.setAttribute(e,`${n.getAttribute(e)!=="true"}`)}class wi{constructor(e){this.select=e,this.container=document.createElement("span"),this.buildPicker(),this.select.style.display="none",this.select.parentNode.insertBefore(this.container,this.select),this.label.addEventListener("mousedown",()=>{this.togglePicker()}),this.label.addEventListener("keydown",t=>{switch(t.key){case"Enter":this.togglePicker();break;case"Escape":this.escape(),t.preventDefault();break}}),this.select.addEventListener("change",this.update.bind(this))}togglePicker(){this.container.classList.toggle("ql-expanded"),Bu(this.label,"aria-expanded"),Bu(this.options,"aria-hidden")}buildItem(e){const t=document.createElement("span");t.tabIndex="0",t.setAttribute("role","button"),t.classList.add("ql-picker-item");const r=e.getAttribute("value");return r&&t.setAttribute("data-value",r),e.textContent&&t.setAttribute("data-label",e.textContent),t.addEventListener("click",()=>{this.selectItem(t,!0)}),t.addEventListener("keydown",s=>{switch(s.key){case"Enter":this.selectItem(t,!0),s.preventDefault();break;case"Escape":this.escape(),s.preventDefault();break}}),t}buildLabel(){const e=document.createElement("span");return e.classList.add("ql-picker-label"),e.innerHTML=Rb,e.tabIndex="0",e.setAttribute("role","button"),e.setAttribute("aria-expanded","false"),this.container.appendChild(e),e}buildOptions(){const e=document.createElement("span");e.classList.add("ql-picker-options"),e.setAttribute("aria-hidden","true"),e.tabIndex="-1",e.id=`ql-picker-options-${Pu}`,Pu+=1,this.label.setAttribute("aria-controls",e.id),this.options=e,Array.from(this.select.options).forEach(t=>{const r=this.buildItem(t);e.appendChild(r),t.selected===!0&&this.selectItem(r)}),this.container.appendChild(e)}buildPicker(){Array.from(this.select.attributes).forEach(e=>{this.container.setAttribute(e.name,e.value)}),this.container.classList.add("ql-picker"),this.label=this.buildLabel(),this.buildOptions()}escape(){this.close(),setTimeout(()=>this.label.focus(),1)}close(){this.container.classList.remove("ql-expanded"),this.label.setAttribute("aria-expanded","false"),this.options.setAttribute("aria-hidden","true")}selectItem(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;const r=this.container.querySelector(".ql-selected");e!==r&&(r!=null&&r.classList.remove("ql-selected"),e!=null&&(e.classList.add("ql-selected"),this.select.selectedIndex=Array.from(e.parentNode.children).indexOf(e),e.hasAttribute("data-value")?this.label.setAttribute("data-value",e.getAttribute("data-value")):this.label.removeAttribute("data-value"),e.hasAttribute("data-label")?this.label.setAttribute("data-label",e.getAttribute("data-label")):this.label.removeAttribute("data-label"),t&&(this.select.dispatchEvent(new Event("change")),this.close())))}update(){let e;if(this.select.selectedIndex>-1){const r=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];e=this.select.options[this.select.selectedIndex],this.selectItem(r)}else this.selectItem(null);const t=e!=null&&e!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",t)}}class Kh extends wi{constructor(e,t){super(e),this.label.innerHTML=t,this.container.classList.add("ql-color-picker"),Array.from(this.container.querySelectorAll(".ql-picker-item")).slice(0,7).forEach(r=>{r.classList.add("ql-primary")})}buildItem(e){const t=super.buildItem(e);return t.style.backgroundColor=e.getAttribute("value")||"",t}selectItem(e,t){super.selectItem(e,t);const r=this.label.querySelector(".ql-color-label"),s=e&&e.getAttribute("data-value")||"";r&&(r.tagName==="line"?r.style.stroke=s:r.style.fill=s)}}class Wh extends wi{constructor(e,t){super(e),this.container.classList.add("ql-icon-picker"),Array.from(this.container.querySelectorAll(".ql-picker-item")).forEach(r=>{r.innerHTML=t[r.getAttribute("data-value")||""]}),this.defaultItem=this.container.querySelector(".ql-selected"),this.selectItem(this.defaultItem)}selectItem(e,t){super.selectItem(e,t);const r=e||this.defaultItem;if(r!=null){if(this.label.innerHTML===r.innerHTML)return;this.label.innerHTML=r.innerHTML}}}const Ob=n=>{const{overflowY:e}=getComputedStyle(n,null);return e!=="visible"&&e!=="clip"};class Yh{constructor(e,t){this.quill=e,this.boundsContainer=t||document.body,this.root=e.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,Ob(this.quill.root)&&this.quill.root.addEventListener("scroll",()=>{this.root.style.marginTop=`${-1*this.quill.root.scrollTop}px`}),this.hide()}hide(){this.root.classList.add("ql-hidden")}position(e){const t=e.left+e.width/2-this.root.offsetWidth/2,r=e.bottom+this.quill.root.scrollTop;this.root.style.left=`${t}px`,this.root.style.top=`${r}px`,this.root.classList.remove("ql-flip");const s=this.boundsContainer.getBoundingClientRect(),i=this.root.getBoundingClientRect();let o=0;if(i.right>s.right&&(o=s.right-i.right,this.root.style.left=`${t+o}px`),i.left<s.left&&(o=s.left-i.left,this.root.style.left=`${t+o}px`),i.bottom>s.bottom){const a=i.bottom-i.top,u=e.bottom-e.top+a;this.root.style.top=`${r-u}px`,this.root.classList.add("ql-flip")}return o}show(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}const Lb=[!1,"center","right","justify"],Mb=["#000000","#e60000","#ff9900","#ffff00","#008a00","#0066cc","#9933ff","#ffffff","#facccc","#ffebcc","#ffffcc","#cce8cc","#cce0f5","#ebd6ff","#bbbbbb","#f06666","#ffc266","#ffff66","#66b966","#66a3e0","#c285ff","#888888","#a10000","#b26b00","#b2b200","#006100","#0047b2","#6b24b2","#444444","#5c0000","#663d00","#666600","#003700","#002966","#3d1466"],Db=[!1,"serif","monospace"],Pb=["1","2","3",!1],Bb=["small",!1,"large","huge"];class ss extends cn{constructor(e,t){super(e,t);const r=s=>{if(!document.body.contains(e.root)){document.body.removeEventListener("click",r);return}this.tooltip!=null&&!this.tooltip.root.contains(s.target)&&document.activeElement!==this.tooltip.textbox&&!this.quill.hasFocus()&&this.tooltip.hide(),this.pickers!=null&&this.pickers.forEach(i=>{i.container.contains(s.target)||i.close()})};e.emitter.listenDOM("click",document.body,r)}addModule(e){const t=super.addModule(e);return e==="toolbar"&&this.extendToolbar(t),t}buildButtons(e,t){Array.from(e).forEach(r=>{(r.getAttribute("class")||"").split(/\s+/).forEach(i=>{if(i.startsWith("ql-")&&(i=i.slice(3),t[i]!=null))if(i==="direction")r.innerHTML=t[i][""]+t[i].rtl;else if(typeof t[i]=="string")r.innerHTML=t[i];else{const o=r.value||"";o!=null&&t[i][o]&&(r.innerHTML=t[i][o])}})})}buildPickers(e,t){this.pickers=Array.from(e).map(s=>{if(s.classList.contains("ql-align")&&(s.querySelector("option")==null&&On(s,Lb),typeof t.align=="object"))return new Wh(s,t.align);if(s.classList.contains("ql-background")||s.classList.contains("ql-color")){const i=s.classList.contains("ql-background")?"background":"color";return s.querySelector("option")==null&&On(s,Mb,i==="background"?"#ffffff":"#000000"),new Kh(s,t[i])}return s.querySelector("option")==null&&(s.classList.contains("ql-font")?On(s,Db):s.classList.contains("ql-header")?On(s,Pb):s.classList.contains("ql-size")&&On(s,Bb)),new wi(s)});const r=()=>{this.pickers.forEach(s=>{s.update()})};this.quill.on(ee.events.EDITOR_CHANGE,r)}}ss.DEFAULTS=er({},cn.DEFAULTS,{modules:{toolbar:{handlers:{formula(){this.quill.theme.tooltip.edit("formula")},image(){let n=this.container.querySelector("input.ql-image[type=file]");n==null&&(n=document.createElement("input"),n.setAttribute("type","file"),n.setAttribute("accept",this.quill.uploader.options.mimetypes.join(", ")),n.classList.add("ql-image"),n.addEventListener("change",()=>{const e=this.quill.getSelection(!0);this.quill.uploader.upload(e,n.files),n.value=""}),this.container.appendChild(n)),n.click()},video(){this.quill.theme.tooltip.edit("video")}}}}});class Zh extends Yh{constructor(e,t){super(e,t),this.textbox=this.root.querySelector('input[type="text"]'),this.listen()}listen(){this.textbox.addEventListener("keydown",e=>{e.key==="Enter"?(this.save(),e.preventDefault()):e.key==="Escape"&&(this.cancel(),e.preventDefault())})}cancel(){this.hide(),this.restoreFocus()}edit(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"link",t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),this.textbox==null)return;t!=null?this.textbox.value=t:e!==this.root.getAttribute("data-mode")&&(this.textbox.value="");const r=this.quill.getBounds(this.quill.selection.savedRange);r!=null&&this.position(r),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute(`data-${e}`)||""),this.root.setAttribute("data-mode",e)}restoreFocus(){this.quill.focus({preventScroll:!0})}save(){let{value:e}=this.textbox;switch(this.root.getAttribute("data-mode")){case"link":{const{scrollTop:t}=this.quill.root;this.linkRange?(this.quill.formatText(this.linkRange,"link",e,ee.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",e,ee.sources.USER)),this.quill.root.scrollTop=t;break}case"video":e=qb(e);case"formula":{if(!e)break;const t=this.quill.getSelection(!0);if(t!=null){const r=t.index+t.length;this.quill.insertEmbed(r,this.root.getAttribute("data-mode"),e,ee.sources.USER),this.root.getAttribute("data-mode")==="formula"&&this.quill.insertText(r+1," ",ee.sources.USER),this.quill.setSelection(r+2,ee.sources.USER)}break}}this.textbox.value="",this.hide()}}function qb(n){let e=n.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||n.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);return e?`${e[1]||"https"}://www.youtube.com/embed/${e[2]}?showinfo=0`:(e=n.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?`${e[1]||"https"}://player.vimeo.com/video/${e[2]}/`:n}function On(n,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;e.forEach(r=>{const s=document.createElement("option");r===t?s.setAttribute("selected","selected"):s.setAttribute("value",String(r)),n.appendChild(s)})}const Fb=[["bold","italic","link"],[{header:1},{header:2},"blockquote"]];class Xh extends Zh{constructor(e,t){super(e,t),this.quill.on(ee.events.EDITOR_CHANGE,(r,s,i,o)=>{if(r===ee.events.SELECTION_CHANGE)if(s!=null&&s.length>0&&o===ee.sources.USER){this.show(),this.root.style.left="0px",this.root.style.width="",this.root.style.width=`${this.root.offsetWidth}px`;const a=this.quill.getLines(s.index,s.length);if(a.length===1){const u=this.quill.getBounds(s);u!=null&&this.position(u)}else{const u=a[a.length-1],c=this.quill.getIndex(u),h=Math.min(u.length()-1,s.index+s.length-c),g=this.quill.getBounds(new _r(c,h));g!=null&&this.position(g)}}else document.activeElement!==this.textbox&&this.quill.hasFocus()&&this.hide()})}listen(){super.listen(),this.root.querySelector(".ql-close").addEventListener("click",()=>{this.root.classList.remove("ql-editing")}),this.quill.on(ee.events.SCROLL_OPTIMIZE,()=>{setTimeout(()=>{if(this.root.classList.contains("ql-hidden"))return;const e=this.quill.getSelection();if(e!=null){const t=this.quill.getBounds(e);t!=null&&this.position(t)}},1)})}cancel(){this.show()}position(e){const t=super.position(e),r=this.root.querySelector(".ql-tooltip-arrow");return r.style.marginLeft="",t!==0&&(r.style.marginLeft=`${-1*t-r.offsetWidth/2}px`),t}}J(Xh,"TEMPLATE",['<span class="ql-tooltip-arrow"></span>','<div class="ql-tooltip-editor">','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-close"></a>',"</div>"].join(""));class Qh extends ss{constructor(e,t){t.modules.toolbar!=null&&t.modules.toolbar.container==null&&(t.modules.toolbar.container=Fb),super(e,t),this.quill.container.classList.add("ql-bubble")}extendToolbar(e){this.tooltip=new Xh(this.quill,this.options.bounds),e.container!=null&&(this.tooltip.root.appendChild(e.container),this.buildButtons(e.container.querySelectorAll("button"),Xn),this.buildPickers(e.container.querySelectorAll("select"),Xn))}}Qh.DEFAULTS=er({},ss.DEFAULTS,{modules:{toolbar:{handlers:{link(n){n?this.quill.theme.tooltip.edit():this.quill.format("link",!1,B.sources.USER)}}}}});const jb=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]];class Jh extends Zh{constructor(){super(...arguments);J(this,"preview",this.root.querySelector("a.ql-preview"))}listen(){super.listen(),this.root.querySelector("a.ql-action").addEventListener("click",t=>{this.root.classList.contains("ql-editing")?this.save():this.edit("link",this.preview.textContent),t.preventDefault()}),this.root.querySelector("a.ql-remove").addEventListener("click",t=>{if(this.linkRange!=null){const r=this.linkRange;this.restoreFocus(),this.quill.formatText(r,"link",!1,ee.sources.USER),delete this.linkRange}t.preventDefault(),this.hide()}),this.quill.on(ee.events.SELECTION_CHANGE,(t,r,s)=>{if(t!=null){if(t.length===0&&s===ee.sources.USER){const[i,o]=this.quill.scroll.descendant(Xt,t.index);if(i!=null){this.linkRange=new _r(t.index-o,i.length());const a=Xt.formats(i.domNode);this.preview.textContent=a,this.preview.setAttribute("href",a),this.show();const u=this.quill.getBounds(this.linkRange);u!=null&&this.position(u);return}}else delete this.linkRange;this.hide()}})}show(){super.show(),this.root.removeAttribute("data-mode")}}J(Jh,"TEMPLATE",['<a class="ql-preview" rel="noopener noreferrer" target="_blank" href="about:blank"></a>','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-action"></a>','<a class="ql-remove"></a>'].join(""));class ed extends ss{constructor(e,t){t.modules.toolbar!=null&&t.modules.toolbar.container==null&&(t.modules.toolbar.container=jb),super(e,t),this.quill.container.classList.add("ql-snow")}extendToolbar(e){e.container!=null&&(e.container.classList.add("ql-snow"),this.buildButtons(e.container.querySelectorAll("button"),Xn),this.buildPickers(e.container.querySelectorAll("select"),Xn),this.tooltip=new Jh(this.quill,this.options.bounds),e.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"k",shortKey:!0},(t,r)=>{e.handlers.link.call(e,!r.format.link)}))}}ed.DEFAULTS=er({},ss.DEFAULTS,{modules:{toolbar:{handlers:{link(n){if(n){const e=this.quill.getSelection();if(e==null||e.length===0)return;let t=this.quill.getText(e);/^\S+@\S+\.\S+$/.test(t)&&t.indexOf("mailto:")!==0&&(t=`mailto:${t}`);const{tooltip:r}=this.quill.theme;r.edit("link",t)}else this.quill.format("link",!1,B.sources.USER)}}}}});B.register({"attributors/attribute/direction":Lh,"attributors/class/align":Ih,"attributors/class/background":sy,"attributors/class/color":ny,"attributors/class/direction":Mh,"attributors/class/font":Bh,"attributors/class/size":Fh,"attributors/style/align":Rh,"attributors/style/background":Ja,"attributors/style/color":Qa,"attributors/style/direction":Dh,"attributors/style/font":qh,"attributors/style/size":jh},!0);B.register({"formats/align":Ih,"formats/direction":Mh,"formats/indent":Wy,"formats/background":Ja,"formats/color":Qa,"formats/font":Bh,"formats/size":Fh,"formats/blockquote":ya,"formats/code-block":$e,"formats/header":ba,"formats/list":ns,"formats/bold":Zn,"formats/code":el,"formats/italic":Ea,"formats/link":Xt,"formats/script":wa,"formats/strike":xa,"formats/underline":Sa,"formats/formula":Us,"formats/image":_a,"formats/video":Hs,"modules/syntax":Gh,"modules/table":Zy,"modules/toolbar":il,"themes/bubble":Qh,"themes/snow":ed,"ui/icons":Xn,"ui/picker":wi,"ui/icon-picker":Wh,"ui/color-picker":Kh,"ui/tooltip":Yh},!0);class xi extends C.default.Component{constructor(e){super(e),this.editingAreaRef=We.createRef(),this.containerRef=We.createRef(),this.dirtyProps=["modules","formats","bounds","theme","children"],this.cleanProps=["id","className","style","placeholder","tabIndex","onChange","onChangeSelection","onFocus","onBlur","onKeyPress","onKeyDown","onKeyUp"],this.state={generation:0},this.selection=null,this.onEditorChange=(r,s,i,o)=>{var a,u;r==="text-change"?(a=this.onEditorChangeText)==null||a.call(this,this.editor.getSemanticHTML(),s,o,this.unprivilegedEditor):r==="selection-change"&&((u=this.onEditorChangeSelection)==null||u.call(this,s,o,this.unprivilegedEditor))};const t=this.isControlled()?e.value:e.defaultValue;this.value=t??""}validateProps(e){if(C.default.Children.count(e.children)>1)throw new Error("The Quill editing area can only be composed of a single React element.");if(C.default.Children.count(e.children)){const t=C.default.Children.only(e.children);if((t==null?void 0:t.type)==="textarea")throw new Error("Quill does not support editing on a <textarea>. Use a <div> instead.")}if(this.lastDeltaChangeSet&&e.value===this.lastDeltaChangeSet)throw new Error("You are passing the `delta` object from the `onChange` event back as `value`. You most probably want `editor.getContents()` instead. See: https://github.com/zenoamaro/react-quill#using-deltas")}shouldComponentUpdate(e,t){if(this.validateProps(e),!this.editor||this.state.generation!==t.generation)return!0;if("value"in e){const r=this.getEditorContents(),s=e.value??"";this.isEqualValue(s,r)||this.setEditorContents(this.editor,s)}return e.readOnly!==this.props.readOnly&&this.setEditorReadOnly(this.editor,e.readOnly),[...this.cleanProps,...this.dirtyProps].some(r=>!Wt(e[r],this.props[r]))}shouldComponentRegenerate(e){return this.dirtyProps.some(t=>!Wt(e[t],this.props[t]))}componentDidMount(){this.instantiateEditor(),this.setEditorContents(this.editor,this.getEditorContents())}componentWillUnmount(){this.destroyEditor()}componentDidUpdate(e,t){if(this.editor&&this.shouldComponentRegenerate(e)){const r=this.editor.getContents(),s=this.editor.getSelection();this.regenerationSnapshot={delta:r,selection:s},this.setState({generation:this.state.generation+1}),this.destroyEditor()}if(this.editor&&e.placeholder!==this.props.placeholder&&(this.editor.root.dataset.placeholder=this.props.placeholder||""),this.state.generation!==t.generation){const{delta:r,selection:s}=this.regenerationSnapshot;delete this.regenerationSnapshot,this.instantiateEditor();const i=this.editor;i.setContents(r),qu(()=>this.setEditorSelection(i,s))}}instantiateEditor(){this.editor?this.hookEditor(this.editor):this.editor=this.createEditor(this.getEditingArea(),this.getEditorConfig())}destroyEditor(){var r,s;if(!this.editor)return;this.unhookEditor(this.editor);const e=(r=this.props.modules)==null?void 0:r.toolbar;if(!(typeof e=="object"&&e&&"container"in e&&typeof e.container=="string"||typeof e=="string")){const i=(s=this.containerRef.current)==null?void 0:s.querySelector(".ql-toolbar");i&&i.remove()}delete this.editor}isControlled(){return"value"in this.props}getEditorConfig(){return{bounds:this.props.bounds,formats:this.props.formats,modules:this.props.modules,placeholder:this.props.placeholder,readOnly:this.props.readOnly,tabIndex:this.props.tabIndex,theme:this.props.theme}}getEditor(){if(!this.editor)throw new Error("Accessing non-instantiated editor");return this.editor}createEditor(e,t){const r=new B(e,t);return t.tabIndex!=null&&this.setEditorTabIndex(r,t.tabIndex),this.hookEditor(r),r}hookEditor(e){this.unprivilegedEditor=this.makeUnprivilegedEditor(e),e.on("editor-change",this.onEditorChange)}unhookEditor(e){e.off("editor-change",this.onEditorChange)}getEditorContents(){return this.value}getEditorSelection(){return this.selection}isDelta(e){return e&&e.ops}isEqualValue(e,t){return this.isDelta(e)&&this.isDelta(t)?Wt(e.ops,t.ops):Wt(e,t)}setEditorContents(e,t){this.value=t;const r=this.getEditorSelection();typeof t=="string"?e.setContents(e.clipboard.convert({html:t})):e.setContents(t),qu(()=>this.setEditorSelection(e,r))}setEditorSelection(e,t){if(this.selection=t,t){const r=e.getLength();t.index=Math.max(0,Math.min(t.index,r-1)),t.length=Math.max(0,Math.min(t.length,r-1-t.index)),e.setSelection(t)}}setEditorTabIndex(e,t){var r;(r=e==null?void 0:e.scroll)!=null&&r.domNode&&(e.scroll.domNode.tabIndex=t)}setEditorReadOnly(e,t){t?e.disable():e.enable()}makeUnprivilegedEditor(e){const t=e;return{getHTML:()=>t.root.innerHTML,getSemanticHTML:t.getSemanticHTML.bind(t),getLength:t.getLength.bind(t),getText:t.getText.bind(t),getContents:t.getContents.bind(t),getSelection:t.getSelection.bind(t),getBounds:t.getBounds.bind(t)}}getEditingArea(){const e=this.editingAreaRef.current;if(!e)throw new Error("Cannot find element for editing area");if(e.nodeType===3)throw new Error("Editing area cannot be a text node");return e}renderEditingArea(){const{children:e,preserveWhitespace:t}=this.props,{generation:r}=this.state,s={key:r,ref:this.editingAreaRef};return C.default.Children.count(e)?C.default.cloneElement(C.default.Children.only(e),s):t?C.default.createElement("pre",{...s}):C.default.createElement("div",{...s})}render(){return C.default.createElement("div",{ref:this.containerRef,id:this.props.id,style:this.props.style,key:this.state.generation,className:`quill ${this.props.className??""}`,onKeyPress:this.props.onKeyPress,onKeyDown:this.props.onKeyDown,onKeyUp:this.props.onKeyUp},this.renderEditingArea())}onEditorChangeText(e,t,r,s){var o,a;if(!this.editor)return;const i=this.isDelta(this.value)?s.getContents():s.getSemanticHTML();i!==this.getEditorContents()&&(this.lastDeltaChangeSet=t,this.value=i,(a=(o=this.props).onChange)==null||a.call(o,e,t,r,s))}onEditorChangeSelection(e,t,r){var a,u,c,h,g,d;if(!this.editor)return;const s=this.getEditorSelection(),i=!s&&e,o=s&&!e;Wt(e,s)||(this.selection=e,(u=(a=this.props).onChangeSelection)==null||u.call(a,e,t,r),i?(h=(c=this.props).onFocus)==null||h.call(c,e,t,r):o&&((d=(g=this.props).onBlur)==null||d.call(g,s,t,r)))}focus(){this.editor&&this.editor.focus()}blur(){this.editor&&(this.selection=null,this.editor.blur())}}xi.displayName="React Quill";xi.Quill=B;xi.defaultProps={theme:"snow",modules:{},readOnly:!1};function qu(n){Promise.resolve().then(n)}const $b=Oa.cva("w-full rounded-lg border border-border-alpha-strong dark:bg-transparent file:border-0 placeholder:text-secondary placeholder:text-body-sm-regular focus-within:outline-none focus-within:ring-2 focus-within:ring-offset-bg focus-within:ring-offset-2 focus-within:ring-ring disabled:cursor-not-allowed disabled:opacity-50",{variants:{variant:{default:"focus-within:ring-item-primary",failure:"focus-within:ring-item-destructive bg-item-destructive-focus placeholder:text-item-destructive border-item-destructive text-destructive",success:"focus-within:ring-success bg-success/20 placeholder:text-success/80 border-success text-success"}},defaultVariants:{variant:"default"}}),Vb=ja.div`
154
- .quill {
155
- .ql {
156
- &-toolbar {
157
- border: none;
158
- }
159
-
160
- &-editor,
161
- &-container {
162
- min-height: 120px;
163
- border: none;
164
- }
165
- }
166
- `;function td({containerProps:n,className:e,variant:t,...r}){return O.jsx(Vb,{...n,className:Ce.cn($b({variant:t}),"block h-auto p-0",e),children:O.jsx(xi,{theme:"snow",...r})})}td.displayName="HtmlEditor";const Si=Oa.cva(Ce.cn("h-10 w-full rounded-lg px-2.5 py-2 flex border border-border-alpha-strong","placeholder:text-secondary placeholder:text-body-sm-regular disabled:cursor-not-allowed disabled:opacity-50","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-bg focus-visible:ring-offset-2 focus-visible:ring-ring "),{variants:{variant:{default:"focus-visible:ring-item-primary",failure:"focus-visible:ring-item-destructive placeholder:!text-item-destructive border-item-destructive text-destructive!"}},defaultVariants:{variant:"default"}}),rd=C.forwardRef(({className:n,type:e,variant:t,...r},s)=>{const[i,o]=We.useState(!1),[a,u]=We.useState(!1);return We.useEffect(()=>{o(e==="password")},[e]),O.jsxs("div",{className:"relative",children:[O.jsx("input",{type:a?"text":e,className:Ce.cn(Si({variant:t}),n,i&&"pr-10"),ref:s,...r}),i&&O.jsx(Lf.Button,{type:"button",size:"icon",variant:"tertiary",className:"absolute top-1 right-1 size-8 cursor-pointer rounded-md p-2 !ring-0 !ring-offset-0",onClick:()=>{u(!a)},children:a?O.jsx(Ws.Xt,{}):O.jsx(Ws.qt,{})})]})});rd.displayName="Input";function tr(n){return typeof n=="string"||n instanceof String}function Fu(n){var e;return typeof n=="object"&&n!=null&&(n==null||(e=n.constructor)==null?void 0:e.name)==="Object"}function nd(n,e){return Array.isArray(e)?nd(n,(t,r)=>e.includes(r)):Object.entries(n).reduce((t,r)=>{let[s,i]=r;return e(i,s)&&(t[s]=i),t},{})}const ae={NONE:"NONE",LEFT:"LEFT",FORCE_LEFT:"FORCE_LEFT",RIGHT:"RIGHT",FORCE_RIGHT:"FORCE_RIGHT"};function Ub(n){switch(n){case ae.LEFT:return ae.FORCE_LEFT;case ae.RIGHT:return ae.FORCE_RIGHT;default:return n}}function Fo(n){return n.replace(/([.*+?^=!:${}()|[\]/\\])/g,"\\$1")}function ri(n,e){if(e===n)return!0;const t=Array.isArray(e),r=Array.isArray(n);let s;if(t&&r){if(e.length!=n.length)return!1;for(s=0;s<e.length;s++)if(!ri(e[s],n[s]))return!1;return!0}if(t!=r)return!1;if(e&&n&&typeof e=="object"&&typeof n=="object"){const i=e instanceof Date,o=n instanceof Date;if(i&&o)return e.getTime()==n.getTime();if(i!=o)return!1;const a=e instanceof RegExp,u=n instanceof RegExp;if(a&&u)return e.toString()==n.toString();if(a!=u)return!1;const c=Object.keys(e);for(s=0;s<c.length;s++)if(!Object.prototype.hasOwnProperty.call(n,c[s]))return!1;for(s=0;s<c.length;s++)if(!ri(n[c[s]],e[c[s]]))return!1;return!0}else if(e&&n&&typeof e=="function"&&typeof n=="function")return e.toString()===n.toString();return!1}class Hb{constructor(e){for(Object.assign(this,e);this.value.slice(0,this.startChangePos)!==this.oldValue.slice(0,this.startChangePos);)--this.oldSelection.start;if(this.insertedCount)for(;this.value.slice(this.cursorPos)!==this.oldValue.slice(this.oldSelection.end);)this.value.length-this.cursorPos<this.oldValue.length-this.oldSelection.end?++this.oldSelection.end:++this.cursorPos}get startChangePos(){return Math.min(this.cursorPos,this.oldSelection.start)}get insertedCount(){return this.cursorPos-this.startChangePos}get inserted(){return this.value.substr(this.startChangePos,this.insertedCount)}get removedCount(){return Math.max(this.oldSelection.end-this.startChangePos||this.oldValue.length-this.value.length,0)}get removed(){return this.oldValue.substr(this.startChangePos,this.removedCount)}get head(){return this.value.substring(0,this.startChangePos)}get tail(){return this.value.substring(this.startChangePos+this.insertedCount)}get removeDirection(){return!this.removedCount||this.insertedCount?ae.NONE:(this.oldSelection.end===this.cursorPos||this.oldSelection.start===this.cursorPos)&&this.oldSelection.end===this.oldSelection.start?ae.RIGHT:ae.LEFT}}function he(n,e){return new he.InputMask(n,e)}function sd(n){if(n==null)throw new Error("mask property should be defined");return n instanceof RegExp?he.MaskedRegExp:tr(n)?he.MaskedPattern:n===Date?he.MaskedDate:n===Number?he.MaskedNumber:Array.isArray(n)||n===Array?he.MaskedDynamic:he.Masked&&n.prototype instanceof he.Masked?n:he.Masked&&n instanceof he.Masked?n.constructor:n instanceof Function?he.MaskedFunction:(console.warn("Mask not found for mask",n),he.Masked)}function Qn(n){if(!n)throw new Error("Options in not defined");if(he.Masked){if(n.prototype instanceof he.Masked)return{mask:n};const{mask:e=void 0,...t}=n instanceof he.Masked?{mask:n}:Fu(n)&&n.mask instanceof he.Masked?n:{};if(e){const r=e.mask;return{...nd(e,(s,i)=>!i.startsWith("_")),mask:e.constructor,_mask:r,...t}}}return Fu(n)?{...n}:{mask:n}}function Ft(n){if(he.Masked&&n instanceof he.Masked)return n;const e=Qn(n),t=sd(e.mask);if(!t)throw new Error("Masked class is not found for provided mask "+e.mask+", appropriate module needs to be imported manually before creating mask.");return e.mask===t&&delete e.mask,e._mask&&(e.mask=e._mask,delete e._mask),new t(e)}he.createMask=Ft;class ol{get selectionStart(){let e;try{e=this._unsafeSelectionStart}catch{}return e??this.value.length}get selectionEnd(){let e;try{e=this._unsafeSelectionEnd}catch{}return e??this.value.length}select(e,t){if(!(e==null||t==null||e===this.selectionStart&&t===this.selectionEnd))try{this._unsafeSelect(e,t)}catch{}}get isActive(){return!1}}he.MaskElement=ol;const ju=90,zb=89;class _i extends ol{constructor(e){super(),this.input=e,this._onKeydown=this._onKeydown.bind(this),this._onInput=this._onInput.bind(this),this._onBeforeinput=this._onBeforeinput.bind(this),this._onCompositionEnd=this._onCompositionEnd.bind(this)}get rootElement(){var e,t,r;return(e=(t=(r=this.input).getRootNode)==null?void 0:t.call(r))!=null?e:document}get isActive(){return this.input===this.rootElement.activeElement}bindEvents(e){this.input.addEventListener("keydown",this._onKeydown),this.input.addEventListener("input",this._onInput),this.input.addEventListener("beforeinput",this._onBeforeinput),this.input.addEventListener("compositionend",this._onCompositionEnd),this.input.addEventListener("drop",e.drop),this.input.addEventListener("click",e.click),this.input.addEventListener("focus",e.focus),this.input.addEventListener("blur",e.commit),this._handlers=e}_onKeydown(e){if(this._handlers.redo&&(e.keyCode===ju&&e.shiftKey&&(e.metaKey||e.ctrlKey)||e.keyCode===zb&&e.ctrlKey))return e.preventDefault(),this._handlers.redo(e);if(this._handlers.undo&&e.keyCode===ju&&(e.metaKey||e.ctrlKey))return e.preventDefault(),this._handlers.undo(e);e.isComposing||this._handlers.selectionChange(e)}_onBeforeinput(e){if(e.inputType==="historyUndo"&&this._handlers.undo)return e.preventDefault(),this._handlers.undo(e);if(e.inputType==="historyRedo"&&this._handlers.redo)return e.preventDefault(),this._handlers.redo(e)}_onCompositionEnd(e){this._handlers.input(e)}_onInput(e){e.isComposing||this._handlers.input(e)}unbindEvents(){this.input.removeEventListener("keydown",this._onKeydown),this.input.removeEventListener("input",this._onInput),this.input.removeEventListener("beforeinput",this._onBeforeinput),this.input.removeEventListener("compositionend",this._onCompositionEnd),this.input.removeEventListener("drop",this._handlers.drop),this.input.removeEventListener("click",this._handlers.click),this.input.removeEventListener("focus",this._handlers.focus),this.input.removeEventListener("blur",this._handlers.commit),this._handlers={}}}he.HTMLMaskElement=_i;class Gb extends _i{constructor(e){super(e),this.input=e}get _unsafeSelectionStart(){return this.input.selectionStart!=null?this.input.selectionStart:this.value.length}get _unsafeSelectionEnd(){return this.input.selectionEnd}_unsafeSelect(e,t){this.input.setSelectionRange(e,t)}get value(){return this.input.value}set value(e){this.input.value=e}}he.HTMLMaskElement=_i;class id extends _i{get _unsafeSelectionStart(){const e=this.rootElement,t=e.getSelection&&e.getSelection(),r=t&&t.anchorOffset,s=t&&t.focusOffset;return s==null||r==null||r<s?r:s}get _unsafeSelectionEnd(){const e=this.rootElement,t=e.getSelection&&e.getSelection(),r=t&&t.anchorOffset,s=t&&t.focusOffset;return s==null||r==null||r>s?r:s}_unsafeSelect(e,t){if(!this.rootElement.createRange)return;const r=this.rootElement.createRange();r.setStart(this.input.firstChild||this.input,e),r.setEnd(this.input.lastChild||this.input,t);const s=this.rootElement,i=s.getSelection&&s.getSelection();i&&(i.removeAllRanges(),i.addRange(r))}get value(){return this.input.textContent||""}set value(e){this.input.textContent=e}}he.HTMLContenteditableMaskElement=id;class Ai{constructor(){this.states=[],this.currentIndex=0}get currentState(){return this.states[this.currentIndex]}get isEmpty(){return this.states.length===0}push(e){this.currentIndex<this.states.length-1&&(this.states.length=this.currentIndex+1),this.states.push(e),this.states.length>Ai.MAX_LENGTH&&this.states.shift(),this.currentIndex=this.states.length-1}go(e){return this.currentIndex=Math.min(Math.max(this.currentIndex+e,0),this.states.length-1),this.currentState}undo(){return this.go(-1)}redo(){return this.go(1)}clear(){this.states.length=0,this.currentIndex=0}}Ai.MAX_LENGTH=100;class Kb{constructor(e,t){this.el=e instanceof ol?e:e.isContentEditable&&e.tagName!=="INPUT"&&e.tagName!=="TEXTAREA"?new id(e):new Gb(e),this.masked=Ft(t),this._listeners={},this._value="",this._unmaskedValue="",this._rawInputValue="",this.history=new Ai,this._saveSelection=this._saveSelection.bind(this),this._onInput=this._onInput.bind(this),this._onChange=this._onChange.bind(this),this._onDrop=this._onDrop.bind(this),this._onFocus=this._onFocus.bind(this),this._onClick=this._onClick.bind(this),this._onUndo=this._onUndo.bind(this),this._onRedo=this._onRedo.bind(this),this.alignCursor=this.alignCursor.bind(this),this.alignCursorFriendly=this.alignCursorFriendly.bind(this),this._bindEvents(),this.updateValue(),this._onChange()}maskEquals(e){var t;return e==null||((t=this.masked)==null?void 0:t.maskEquals(e))}get mask(){return this.masked.mask}set mask(e){if(this.maskEquals(e))return;if(!(e instanceof he.Masked)&&this.masked.constructor===sd(e)){this.masked.updateOptions({mask:e});return}const t=e instanceof he.Masked?e:Ft({mask:e});t.unmaskedValue=this.masked.unmaskedValue,this.masked=t}get value(){return this._value}set value(e){this.value!==e&&(this.masked.value=e,this.updateControl("auto"))}get unmaskedValue(){return this._unmaskedValue}set unmaskedValue(e){this.unmaskedValue!==e&&(this.masked.unmaskedValue=e,this.updateControl("auto"))}get rawInputValue(){return this._rawInputValue}set rawInputValue(e){this.rawInputValue!==e&&(this.masked.rawInputValue=e,this.updateControl(),this.alignCursor())}get typedValue(){return this.masked.typedValue}set typedValue(e){this.masked.typedValueEquals(e)||(this.masked.typedValue=e,this.updateControl("auto"))}get displayValue(){return this.masked.displayValue}_bindEvents(){this.el.bindEvents({selectionChange:this._saveSelection,input:this._onInput,drop:this._onDrop,click:this._onClick,focus:this._onFocus,commit:this._onChange,undo:this._onUndo,redo:this._onRedo})}_unbindEvents(){this.el&&this.el.unbindEvents()}_fireEvent(e,t){const r=this._listeners[e];r&&r.forEach(s=>s(t))}get selectionStart(){return this._cursorChanging?this._changingCursorPos:this.el.selectionStart}get cursorPos(){return this._cursorChanging?this._changingCursorPos:this.el.selectionEnd}set cursorPos(e){!this.el||!this.el.isActive||(this.el.select(e,e),this._saveSelection())}_saveSelection(){this.displayValue!==this.el.value&&console.warn("Element value was changed outside of mask. Syncronize mask using `mask.updateValue()` to work properly."),this._selection={start:this.selectionStart,end:this.cursorPos}}updateValue(){this.masked.value=this.el.value,this._value=this.masked.value,this._unmaskedValue=this.masked.unmaskedValue,this._rawInputValue=this.masked.rawInputValue}updateControl(e){const t=this.masked.unmaskedValue,r=this.masked.value,s=this.masked.rawInputValue,i=this.displayValue,o=this.unmaskedValue!==t||this.value!==r||this._rawInputValue!==s;this._unmaskedValue=t,this._value=r,this._rawInputValue=s,this.el.value!==i&&(this.el.value=i),e==="auto"?this.alignCursor():e!=null&&(this.cursorPos=e),o&&this._fireChangeEvents(),!this._historyChanging&&(o||this.history.isEmpty)&&this.history.push({unmaskedValue:t,selection:{start:this.selectionStart,end:this.cursorPos}})}updateOptions(e){const{mask:t,...r}=e,s=!this.maskEquals(t),i=this.masked.optionsIsChanged(r);s&&(this.mask=t),i&&this.masked.updateOptions(r),(s||i)&&this.updateControl()}updateCursor(e){e!=null&&(this.cursorPos=e,this._delayUpdateCursor(e))}_delayUpdateCursor(e){this._abortUpdateCursor(),this._changingCursorPos=e,this._cursorChanging=setTimeout(()=>{this.el&&(this.cursorPos=this._changingCursorPos,this._abortUpdateCursor())},10)}_fireChangeEvents(){this._fireEvent("accept",this._inputEvent),this.masked.isComplete&&this._fireEvent("complete",this._inputEvent)}_abortUpdateCursor(){this._cursorChanging&&(clearTimeout(this._cursorChanging),delete this._cursorChanging)}alignCursor(){this.cursorPos=this.masked.nearestInputPos(this.masked.nearestInputPos(this.cursorPos,ae.LEFT))}alignCursorFriendly(){this.selectionStart===this.cursorPos&&this.alignCursor()}on(e,t){return this._listeners[e]||(this._listeners[e]=[]),this._listeners[e].push(t),this}off(e,t){if(!this._listeners[e])return this;if(!t)return delete this._listeners[e],this;const r=this._listeners[e].indexOf(t);return r>=0&&this._listeners[e].splice(r,1),this}_onInput(e){this._inputEvent=e,this._abortUpdateCursor();const t=new Hb({value:this.el.value,cursorPos:this.cursorPos,oldValue:this.displayValue,oldSelection:this._selection}),r=this.masked.rawInputValue,s=this.masked.splice(t.startChangePos,t.removed.length,t.inserted,t.removeDirection,{input:!0,raw:!0}).offset,i=r===this.masked.rawInputValue?t.removeDirection:ae.NONE;let o=this.masked.nearestInputPos(t.startChangePos+s,i);i!==ae.NONE&&(o=this.masked.nearestInputPos(o,ae.NONE)),this.updateControl(o),delete this._inputEvent}_onChange(){this.displayValue!==this.el.value&&this.updateValue(),this.masked.doCommit(),this.updateControl(),this._saveSelection()}_onDrop(e){e.preventDefault(),e.stopPropagation()}_onFocus(e){this.alignCursorFriendly()}_onClick(e){this.alignCursorFriendly()}_onUndo(){this._applyHistoryState(this.history.undo())}_onRedo(){this._applyHistoryState(this.history.redo())}_applyHistoryState(e){e&&(this._historyChanging=!0,this.unmaskedValue=e.unmaskedValue,this.el.select(e.selection.start,e.selection.end),this._saveSelection(),this._historyChanging=!1)}destroy(){this._unbindEvents(),this._listeners.length=0,delete this.el}}he.InputMask=Kb;class pe{static normalize(e){return Array.isArray(e)?e:[e,new pe]}constructor(e){Object.assign(this,{inserted:"",rawInserted:"",tailShift:0,skip:!1},e)}aggregate(e){return this.inserted+=e.inserted,this.rawInserted+=e.rawInserted,this.tailShift+=e.tailShift,this.skip=this.skip||e.skip,this}get offset(){return this.tailShift+this.inserted.length}get consumed(){return!!this.rawInserted||this.skip}equals(e){return this.inserted===e.inserted&&this.tailShift===e.tailShift&&this.rawInserted===e.rawInserted&&this.skip===e.skip}}he.ChangeDetails=pe;class xt{constructor(e,t,r){e===void 0&&(e=""),t===void 0&&(t=0),this.value=e,this.from=t,this.stop=r}toString(){return this.value}extend(e){this.value+=String(e)}appendTo(e){return e.append(this.toString(),{tail:!0}).aggregate(e._appendPlaceholder())}get state(){return{value:this.value,from:this.from,stop:this.stop}}set state(e){Object.assign(this,e)}unshift(e){if(!this.value.length||e!=null&&this.from>=e)return"";const t=this.value[0];return this.value=this.value.slice(1),t}shift(){if(!this.value.length)return"";const e=this.value[this.value.length-1];return this.value=this.value.slice(0,-1),e}}class Ve{constructor(e){this._value="",this._update({...Ve.DEFAULTS,...e}),this._initialized=!0}updateOptions(e){this.optionsIsChanged(e)&&this.withValueRefresh(this._update.bind(this,e))}_update(e){Object.assign(this,e)}get state(){return{_value:this.value,_rawInputValue:this.rawInputValue}}set state(e){this._value=e._value}reset(){this._value=""}get value(){return this._value}set value(e){this.resolve(e,{input:!0})}resolve(e,t){t===void 0&&(t={input:!0}),this.reset(),this.append(e,t,""),this.doCommit()}get unmaskedValue(){return this.value}set unmaskedValue(e){this.resolve(e,{})}get typedValue(){return this.parse?this.parse(this.value,this):this.unmaskedValue}set typedValue(e){this.format?this.value=this.format(e,this):this.unmaskedValue=String(e)}get rawInputValue(){return this.extractInput(0,this.displayValue.length,{raw:!0})}set rawInputValue(e){this.resolve(e,{raw:!0})}get displayValue(){return this.value}get isComplete(){return!0}get isFilled(){return this.isComplete}nearestInputPos(e,t){return e}totalInputPositions(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length),Math.min(this.displayValue.length,t-e)}extractInput(e,t,r){return e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length),this.displayValue.slice(e,t)}extractTail(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length),new xt(this.extractInput(e,t),e)}appendTail(e){return tr(e)&&(e=new xt(String(e))),e.appendTo(this)}_appendCharRaw(e,t){return e?(this._value+=e,new pe({inserted:e,rawInserted:e})):new pe}_appendChar(e,t,r){t===void 0&&(t={});const s=this.state;let i;if([e,i]=this.doPrepareChar(e,t),e&&(i=i.aggregate(this._appendCharRaw(e,t)),!i.rawInserted&&this.autofix==="pad")){const o=this.state;this.state=s;let a=this.pad(t);const u=this._appendCharRaw(e,t);a=a.aggregate(u),u.rawInserted||a.equals(i)?i=a:this.state=o}if(i.inserted){let o,a=this.doValidate(t)!==!1;if(a&&r!=null){const u=this.state;if(this.overwrite===!0){o=r.state;for(let h=0;h<i.rawInserted.length;++h)r.unshift(this.displayValue.length-i.tailShift)}let c=this.appendTail(r);if(a=c.rawInserted.length===r.toString().length,!(a&&c.inserted)&&this.overwrite==="shift"){this.state=u,o=r.state;for(let h=0;h<i.rawInserted.length;++h)r.shift();c=this.appendTail(r),a=c.rawInserted.length===r.toString().length}a&&c.inserted&&(this.state=u)}a||(i=new pe,this.state=s,r&&o&&(r.state=o))}return i}_appendPlaceholder(){return new pe}_appendEager(){return new pe}append(e,t,r){if(!tr(e))throw new Error("value should be string");const s=tr(r)?new xt(String(r)):r;t!=null&&t.tail&&(t._beforeTailState=this.state);let i;[e,i]=this.doPrepare(e,t);for(let o=0;o<e.length;++o){const a=this._appendChar(e[o],t,s);if(!a.rawInserted&&!this.doSkipInvalid(e[o],t,s))break;i.aggregate(a)}return(this.eager===!0||this.eager==="append")&&t!=null&&t.input&&e&&i.aggregate(this._appendEager()),s!=null&&(i.tailShift+=this.appendTail(s).tailShift),i}remove(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length),this._value=this.displayValue.slice(0,e)+this.displayValue.slice(t),new pe}withValueRefresh(e){if(this._refreshing||!this._initialized)return e();this._refreshing=!0;const t=this.rawInputValue,r=this.value,s=e();return this.rawInputValue=t,this.value&&this.value!==r&&r.indexOf(this.value)===0&&(this.append(r.slice(this.displayValue.length),{},""),this.doCommit()),delete this._refreshing,s}runIsolated(e){if(this._isolated||!this._initialized)return e(this);this._isolated=!0;const t=this.state,r=e(this);return this.state=t,delete this._isolated,r}doSkipInvalid(e,t,r){return!!this.skipInvalid}doPrepare(e,t){return t===void 0&&(t={}),pe.normalize(this.prepare?this.prepare(e,this,t):e)}doPrepareChar(e,t){return t===void 0&&(t={}),pe.normalize(this.prepareChar?this.prepareChar(e,this,t):e)}doValidate(e){return(!this.validate||this.validate(this.value,this,e))&&(!this.parent||this.parent.doValidate(e))}doCommit(){this.commit&&this.commit(this.value,this)}splice(e,t,r,s,i){r===void 0&&(r=""),s===void 0&&(s=ae.NONE),i===void 0&&(i={input:!0});const o=e+t,a=this.extractTail(o),u=this.eager===!0||this.eager==="remove";let c;u&&(s=Ub(s),c=this.extractInput(0,o,{raw:!0}));let h=e;const g=new pe;if(s!==ae.NONE&&(h=this.nearestInputPos(e,t>1&&e!==0&&!u?ae.NONE:s),g.tailShift=h-e),g.aggregate(this.remove(h)),u&&s!==ae.NONE&&c===this.rawInputValue)if(s===ae.FORCE_LEFT){let d;for(;c===this.rawInputValue&&(d=this.displayValue.length);)g.aggregate(new pe({tailShift:-1})).aggregate(this.remove(d-1))}else s===ae.FORCE_RIGHT&&a.unshift();return g.aggregate(this.append(r,i,a))}maskEquals(e){return this.mask===e}optionsIsChanged(e){return!ri(this,e)}typedValueEquals(e){const t=this.typedValue;return e===t||Ve.EMPTY_VALUES.includes(e)&&Ve.EMPTY_VALUES.includes(t)||(this.format?this.format(e,this)===this.format(this.typedValue,this):!1)}pad(e){return new pe}}Ve.DEFAULTS={skipInvalid:!0};Ve.EMPTY_VALUES=[void 0,null,""];he.Masked=Ve;class vr{constructor(e,t){e===void 0&&(e=[]),t===void 0&&(t=0),this.chunks=e,this.from=t}toString(){return this.chunks.map(String).join("")}extend(e){if(!String(e))return;e=tr(e)?new xt(String(e)):e;const t=this.chunks[this.chunks.length-1],r=t&&(t.stop===e.stop||e.stop==null)&&e.from===t.from+t.toString().length;if(e instanceof xt)r?t.extend(e.toString()):this.chunks.push(e);else if(e instanceof vr){if(e.stop==null){let s;for(;e.chunks.length&&e.chunks[0].stop==null;)s=e.chunks.shift(),s.from+=e.from,this.extend(s)}e.toString()&&(e.stop=e.blockIndex,this.chunks.push(e))}}appendTo(e){if(!(e instanceof he.MaskedPattern))return new xt(this.toString()).appendTo(e);const t=new pe;for(let r=0;r<this.chunks.length;++r){const s=this.chunks[r],i=e._mapPosToBlock(e.displayValue.length),o=s.stop;let a;if(o!=null&&(!i||i.index<=o)&&((s instanceof vr||e._stops.indexOf(o)>=0)&&t.aggregate(e._appendPlaceholder(o)),a=s instanceof vr&&e._blocks[o]),a){const u=a.appendTail(s);t.aggregate(u);const c=s.toString().slice(u.rawInserted.length);c&&t.aggregate(e.append(c,{tail:!0}))}else t.aggregate(e.append(s.toString(),{tail:!0}))}return t}get state(){return{chunks:this.chunks.map(e=>e.state),from:this.from,stop:this.stop,blockIndex:this.blockIndex}}set state(e){const{chunks:t,...r}=e;Object.assign(this,r),this.chunks=t.map(s=>{const i="chunks"in s?new vr:new xt;return i.state=s,i})}unshift(e){if(!this.chunks.length||e!=null&&this.from>=e)return"";const t=e!=null?e-this.from:e;let r=0;for(;r<this.chunks.length;){const s=this.chunks[r],i=s.unshift(t);if(s.toString()){if(!i)break;++r}else this.chunks.splice(r,1);if(i)return i}return""}shift(){if(!this.chunks.length)return"";let e=this.chunks.length-1;for(;0<=e;){const t=this.chunks[e],r=t.shift();if(t.toString()){if(!r)break;--e}else this.chunks.splice(e,1);if(r)return r}return""}}class Wb{constructor(e,t){this.masked=e,this._log=[];const{offset:r,index:s}=e._mapPosToBlock(t)||(t<0?{index:0,offset:0}:{index:this.masked._blocks.length,offset:0});this.offset=r,this.index=s,this.ok=!1}get block(){return this.masked._blocks[this.index]}get pos(){return this.masked._blockStartPos(this.index)+this.offset}get state(){return{index:this.index,offset:this.offset,ok:this.ok}}set state(e){Object.assign(this,e)}pushState(){this._log.push(this.state)}popState(){const e=this._log.pop();return e&&(this.state=e),e}bindBlock(){this.block||(this.index<0&&(this.index=0,this.offset=0),this.index>=this.masked._blocks.length&&(this.index=this.masked._blocks.length-1,this.offset=this.block.displayValue.length))}_pushLeft(e){for(this.pushState(),this.bindBlock();0<=this.index;--this.index,this.offset=((t=this.block)==null?void 0:t.displayValue.length)||0){var t;if(e())return this.ok=!0}return this.ok=!1}_pushRight(e){for(this.pushState(),this.bindBlock();this.index<this.masked._blocks.length;++this.index,this.offset=0)if(e())return this.ok=!0;return this.ok=!1}pushLeftBeforeFilled(){return this._pushLeft(()=>{if(!(this.block.isFixed||!this.block.value)&&(this.offset=this.block.nearestInputPos(this.offset,ae.FORCE_LEFT),this.offset!==0))return!0})}pushLeftBeforeInput(){return this._pushLeft(()=>{if(!this.block.isFixed)return this.offset=this.block.nearestInputPos(this.offset,ae.LEFT),!0})}pushLeftBeforeRequired(){return this._pushLeft(()=>{if(!(this.block.isFixed||this.block.isOptional&&!this.block.value))return this.offset=this.block.nearestInputPos(this.offset,ae.LEFT),!0})}pushRightBeforeFilled(){return this._pushRight(()=>{if(!(this.block.isFixed||!this.block.value)&&(this.offset=this.block.nearestInputPos(this.offset,ae.FORCE_RIGHT),this.offset!==this.block.value.length))return!0})}pushRightBeforeInput(){return this._pushRight(()=>{if(!this.block.isFixed)return this.offset=this.block.nearestInputPos(this.offset,ae.NONE),!0})}pushRightBeforeRequired(){return this._pushRight(()=>{if(!(this.block.isFixed||this.block.isOptional&&!this.block.value))return this.offset=this.block.nearestInputPos(this.offset,ae.NONE),!0})}}class od{constructor(e){Object.assign(this,e),this._value="",this.isFixed=!0}get value(){return this._value}get unmaskedValue(){return this.isUnmasking?this.value:""}get rawInputValue(){return this._isRawInput?this.value:""}get displayValue(){return this.value}reset(){this._isRawInput=!1,this._value=""}remove(e,t){return e===void 0&&(e=0),t===void 0&&(t=this._value.length),this._value=this._value.slice(0,e)+this._value.slice(t),this._value||(this._isRawInput=!1),new pe}nearestInputPos(e,t){t===void 0&&(t=ae.NONE);const r=0,s=this._value.length;switch(t){case ae.LEFT:case ae.FORCE_LEFT:return r;case ae.NONE:case ae.RIGHT:case ae.FORCE_RIGHT:default:return s}}totalInputPositions(e,t){return e===void 0&&(e=0),t===void 0&&(t=this._value.length),this._isRawInput?t-e:0}extractInput(e,t,r){return e===void 0&&(e=0),t===void 0&&(t=this._value.length),r===void 0&&(r={}),r.raw&&this._isRawInput&&this._value.slice(e,t)||""}get isComplete(){return!0}get isFilled(){return!!this._value}_appendChar(e,t){if(t===void 0&&(t={}),this.isFilled)return new pe;const r=this.eager===!0||this.eager==="append",i=this.char===e&&(this.isUnmasking||t.input||t.raw)&&(!t.raw||!r)&&!t.tail,o=new pe({inserted:this.char,rawInserted:i?this.char:""});return this._value=this.char,this._isRawInput=i&&(t.raw||t.input),o}_appendEager(){return this._appendChar(this.char,{tail:!0})}_appendPlaceholder(){const e=new pe;return this.isFilled||(this._value=e.inserted=this.char),e}extractTail(){return new xt("")}appendTail(e){return tr(e)&&(e=new xt(String(e))),e.appendTo(this)}append(e,t,r){const s=this._appendChar(e[0],t);return r!=null&&(s.tailShift+=this.appendTail(r).tailShift),s}doCommit(){}get state(){return{_value:this._value,_rawInputValue:this.rawInputValue}}set state(e){this._value=e._value,this._isRawInput=!!e._rawInputValue}pad(e){return this._appendPlaceholder()}}class ni{constructor(e){const{parent:t,isOptional:r,placeholderChar:s,displayChar:i,lazy:o,eager:a,...u}=e;this.masked=Ft(u),Object.assign(this,{parent:t,isOptional:r,placeholderChar:s,displayChar:i,lazy:o,eager:a})}reset(){this.isFilled=!1,this.masked.reset()}remove(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.value.length),e===0&&t>=1?(this.isFilled=!1,this.masked.remove(e,t)):new pe}get value(){return this.masked.value||(this.isFilled&&!this.isOptional?this.placeholderChar:"")}get unmaskedValue(){return this.masked.unmaskedValue}get rawInputValue(){return this.masked.rawInputValue}get displayValue(){return this.masked.value&&this.displayChar||this.value}get isComplete(){return!!this.masked.value||this.isOptional}_appendChar(e,t){if(t===void 0&&(t={}),this.isFilled)return new pe;const r=this.masked.state;let s=this.masked._appendChar(e,this.currentMaskFlags(t));return s.inserted&&this.doValidate(t)===!1&&(s=new pe,this.masked.state=r),!s.inserted&&!this.isOptional&&!this.lazy&&!t.input&&(s.inserted=this.placeholderChar),s.skip=!s.inserted&&!this.isOptional,this.isFilled=!!s.inserted,s}append(e,t,r){return this.masked.append(e,this.currentMaskFlags(t),r)}_appendPlaceholder(){return this.isFilled||this.isOptional?new pe:(this.isFilled=!0,new pe({inserted:this.placeholderChar}))}_appendEager(){return new pe}extractTail(e,t){return this.masked.extractTail(e,t)}appendTail(e){return this.masked.appendTail(e)}extractInput(e,t,r){return e===void 0&&(e=0),t===void 0&&(t=this.value.length),this.masked.extractInput(e,t,r)}nearestInputPos(e,t){t===void 0&&(t=ae.NONE);const r=0,s=this.value.length,i=Math.min(Math.max(e,r),s);switch(t){case ae.LEFT:case ae.FORCE_LEFT:return this.isComplete?i:r;case ae.RIGHT:case ae.FORCE_RIGHT:return this.isComplete?i:s;case ae.NONE:default:return i}}totalInputPositions(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.value.length),this.value.slice(e,t).length}doValidate(e){return this.masked.doValidate(this.currentMaskFlags(e))&&(!this.parent||this.parent.doValidate(this.currentMaskFlags(e)))}doCommit(){this.masked.doCommit()}get state(){return{_value:this.value,_rawInputValue:this.rawInputValue,masked:this.masked.state,isFilled:this.isFilled}}set state(e){this.masked.state=e.masked,this.isFilled=e.isFilled}currentMaskFlags(e){var t;return{...e,_beforeTailState:(e==null||(t=e._beforeTailState)==null?void 0:t.masked)||(e==null?void 0:e._beforeTailState)}}pad(e){return new pe}}ni.DEFAULT_DEFINITIONS={0:/\d/,a:/[\u0041-\u005A\u0061-\u007A\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,"*":/./};class Yb extends Ve{updateOptions(e){super.updateOptions(e)}_update(e){const t=e.mask;t&&(e.validate=r=>r.search(t)>=0),super._update(e)}}he.MaskedRegExp=Yb;class Ue extends Ve{constructor(e){super({...Ue.DEFAULTS,...e,definitions:Object.assign({},ni.DEFAULT_DEFINITIONS,e==null?void 0:e.definitions)})}updateOptions(e){super.updateOptions(e)}_update(e){e.definitions=Object.assign({},this.definitions,e.definitions),super._update(e),this._rebuildMask()}_rebuildMask(){const e=this.definitions;this._blocks=[],this.exposeBlock=void 0,this._stops=[],this._maskedBlocks={};const t=this.mask;if(!t||!e)return;let r=!1,s=!1;for(let i=0;i<t.length;++i){if(this.blocks){const c=t.slice(i),h=Object.keys(this.blocks).filter(d=>c.indexOf(d)===0);h.sort((d,m)=>m.length-d.length);const g=h[0];if(g){const{expose:d,repeat:m,...v}=Qn(this.blocks[g]),p={lazy:this.lazy,eager:this.eager,placeholderChar:this.placeholderChar,displayChar:this.displayChar,overwrite:this.overwrite,autofix:this.autofix,...v,repeat:m,parent:this},y=m!=null?new he.RepeatBlock(p):Ft(p);y&&(this._blocks.push(y),d&&(this.exposeBlock=y),this._maskedBlocks[g]||(this._maskedBlocks[g]=[]),this._maskedBlocks[g].push(this._blocks.length-1)),i+=g.length-1;continue}}let o=t[i],a=o in e;if(o===Ue.STOP_CHAR){this._stops.push(this._blocks.length);continue}if(o==="{"||o==="}"){r=!r;continue}if(o==="["||o==="]"){s=!s;continue}if(o===Ue.ESCAPE_CHAR){if(++i,o=t[i],!o)break;a=!1}const u=a?new ni({isOptional:s,lazy:this.lazy,eager:this.eager,placeholderChar:this.placeholderChar,displayChar:this.displayChar,...Qn(e[o]),parent:this}):new od({char:o,eager:this.eager,isUnmasking:r});this._blocks.push(u)}}get state(){return{...super.state,_blocks:this._blocks.map(e=>e.state)}}set state(e){if(!e){this.reset();return}const{_blocks:t,...r}=e;this._blocks.forEach((s,i)=>s.state=t[i]),super.state=r}reset(){super.reset(),this._blocks.forEach(e=>e.reset())}get isComplete(){return this.exposeBlock?this.exposeBlock.isComplete:this._blocks.every(e=>e.isComplete)}get isFilled(){return this._blocks.every(e=>e.isFilled)}get isFixed(){return this._blocks.every(e=>e.isFixed)}get isOptional(){return this._blocks.every(e=>e.isOptional)}doCommit(){this._blocks.forEach(e=>e.doCommit()),super.doCommit()}get unmaskedValue(){return this.exposeBlock?this.exposeBlock.unmaskedValue:this._blocks.reduce((e,t)=>e+=t.unmaskedValue,"")}set unmaskedValue(e){if(this.exposeBlock){const t=this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock))+this.exposeBlock.displayValue.length);this.exposeBlock.unmaskedValue=e,this.appendTail(t),this.doCommit()}else super.unmaskedValue=e}get value(){return this.exposeBlock?this.exposeBlock.value:this._blocks.reduce((e,t)=>e+=t.value,"")}set value(e){if(this.exposeBlock){const t=this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock))+this.exposeBlock.displayValue.length);this.exposeBlock.value=e,this.appendTail(t),this.doCommit()}else super.value=e}get typedValue(){return this.exposeBlock?this.exposeBlock.typedValue:super.typedValue}set typedValue(e){if(this.exposeBlock){const t=this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock))+this.exposeBlock.displayValue.length);this.exposeBlock.typedValue=e,this.appendTail(t),this.doCommit()}else super.typedValue=e}get displayValue(){return this._blocks.reduce((e,t)=>e+=t.displayValue,"")}appendTail(e){return super.appendTail(e).aggregate(this._appendPlaceholder())}_appendEager(){var e;const t=new pe;let r=(e=this._mapPosToBlock(this.displayValue.length))==null?void 0:e.index;if(r==null)return t;this._blocks[r].isFilled&&++r;for(let s=r;s<this._blocks.length;++s){const i=this._blocks[s]._appendEager();if(!i.inserted)break;t.aggregate(i)}return t}_appendCharRaw(e,t){t===void 0&&(t={});const r=this._mapPosToBlock(this.displayValue.length),s=new pe;if(!r)return s;for(let o=r.index,a;a=this._blocks[o];++o){var i;const u=a._appendChar(e,{...t,_beforeTailState:(i=t._beforeTailState)==null||(i=i._blocks)==null?void 0:i[o]});if(s.aggregate(u),u.consumed)break}return s}extractTail(e,t){e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length);const r=new vr;return e===t||this._forEachBlocksInRange(e,t,(s,i,o,a)=>{const u=s.extractTail(o,a);u.stop=this._findStopBefore(i),u.from=this._blockStartPos(i),u instanceof vr&&(u.blockIndex=i),r.extend(u)}),r}extractInput(e,t,r){if(e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length),r===void 0&&(r={}),e===t)return"";let s="";return this._forEachBlocksInRange(e,t,(i,o,a,u)=>{s+=i.extractInput(a,u,r)}),s}_findStopBefore(e){let t;for(let r=0;r<this._stops.length;++r){const s=this._stops[r];if(s<=e)t=s;else break}return t}_appendPlaceholder(e){const t=new pe;if(this.lazy&&e==null)return t;const r=this._mapPosToBlock(this.displayValue.length);if(!r)return t;const s=r.index,i=e??this._blocks.length;return this._blocks.slice(s,i).forEach(o=>{if(!o.lazy||e!=null){var a;t.aggregate(o._appendPlaceholder((a=o._blocks)==null?void 0:a.length))}}),t}_mapPosToBlock(e){let t="";for(let r=0;r<this._blocks.length;++r){const s=this._blocks[r],i=t.length;if(t+=s.displayValue,e<=t.length)return{index:r,offset:e-i}}}_blockStartPos(e){return this._blocks.slice(0,e).reduce((t,r)=>t+=r.displayValue.length,0)}_forEachBlocksInRange(e,t,r){t===void 0&&(t=this.displayValue.length);const s=this._mapPosToBlock(e);if(s){const i=this._mapPosToBlock(t),o=i&&s.index===i.index,a=s.offset,u=i&&o?i.offset:this._blocks[s.index].displayValue.length;if(r(this._blocks[s.index],s.index,a,u),i&&!o){for(let c=s.index+1;c<i.index;++c)r(this._blocks[c],c,0,this._blocks[c].displayValue.length);r(this._blocks[i.index],i.index,0,i.offset)}}}remove(e,t){e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length);const r=super.remove(e,t);return this._forEachBlocksInRange(e,t,(s,i,o,a)=>{r.aggregate(s.remove(o,a))}),r}nearestInputPos(e,t){if(t===void 0&&(t=ae.NONE),!this._blocks.length)return 0;const r=new Wb(this,e);if(t===ae.NONE)return r.pushRightBeforeInput()||(r.popState(),r.pushLeftBeforeInput())?r.pos:this.displayValue.length;if(t===ae.LEFT||t===ae.FORCE_LEFT){if(t===ae.LEFT){if(r.pushRightBeforeFilled(),r.ok&&r.pos===e)return e;r.popState()}if(r.pushLeftBeforeInput(),r.pushLeftBeforeRequired(),r.pushLeftBeforeFilled(),t===ae.LEFT){if(r.pushRightBeforeInput(),r.pushRightBeforeRequired(),r.ok&&r.pos<=e||(r.popState(),r.ok&&r.pos<=e))return r.pos;r.popState()}return r.ok?r.pos:t===ae.FORCE_LEFT?0:(r.popState(),r.ok||(r.popState(),r.ok)?r.pos:0)}return t===ae.RIGHT||t===ae.FORCE_RIGHT?(r.pushRightBeforeInput(),r.pushRightBeforeRequired(),r.pushRightBeforeFilled()?r.pos:t===ae.FORCE_RIGHT?this.displayValue.length:(r.popState(),r.ok||(r.popState(),r.ok)?r.pos:this.nearestInputPos(e,ae.LEFT))):e}totalInputPositions(e,t){e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length);let r=0;return this._forEachBlocksInRange(e,t,(s,i,o,a)=>{r+=s.totalInputPositions(o,a)}),r}maskedBlock(e){return this.maskedBlocks(e)[0]}maskedBlocks(e){const t=this._maskedBlocks[e];return t?t.map(r=>this._blocks[r]):[]}pad(e){const t=new pe;return this._forEachBlocksInRange(0,this.displayValue.length,r=>t.aggregate(r.pad(e))),t}}Ue.DEFAULTS={...Ve.DEFAULTS,lazy:!0,placeholderChar:"_"};Ue.STOP_CHAR="`";Ue.ESCAPE_CHAR="\\";Ue.InputDefinition=ni;Ue.FixedDefinition=od;he.MaskedPattern=Ue;class zs extends Ue{get _matchFrom(){return this.maxLength-String(this.from).length}constructor(e){super(e)}updateOptions(e){super.updateOptions(e)}_update(e){const{to:t=this.to||0,from:r=this.from||0,maxLength:s=this.maxLength||0,autofix:i=this.autofix,...o}=e;this.to=t,this.from=r,this.maxLength=Math.max(String(t).length,s),this.autofix=i;const a=String(this.from).padStart(this.maxLength,"0"),u=String(this.to).padStart(this.maxLength,"0");let c=0;for(;c<u.length&&u[c]===a[c];)++c;o.mask=u.slice(0,c).replace(/0/g,"\\0")+"0".repeat(this.maxLength-c),super._update(o)}get isComplete(){return super.isComplete&&!!this.value}boundaries(e){let t="",r="";const[,s,i]=e.match(/^(\D*)(\d*)(\D*)/)||[];return i&&(t="0".repeat(s.length)+i,r="9".repeat(s.length)+i),t=t.padEnd(this.maxLength,"0"),r=r.padEnd(this.maxLength,"9"),[t,r]}doPrepareChar(e,t){t===void 0&&(t={});let r;return[e,r]=super.doPrepareChar(e.replace(/\D/g,""),t),e||(r.skip=!this.isComplete),[e,r]}_appendCharRaw(e,t){if(t===void 0&&(t={}),!this.autofix||this.value.length+1>this.maxLength)return super._appendCharRaw(e,t);const r=String(this.from).padStart(this.maxLength,"0"),s=String(this.to).padStart(this.maxLength,"0"),[i,o]=this.boundaries(this.value+e);return Number(o)<this.from?super._appendCharRaw(r[this.value.length],t):Number(i)>this.to?!t.tail&&this.autofix==="pad"&&this.value.length+1<this.maxLength?super._appendCharRaw(r[this.value.length],t).aggregate(this._appendCharRaw(e,t)):super._appendCharRaw(s[this.value.length],t):super._appendCharRaw(e,t)}doValidate(e){const t=this.value;if(t.search(/[^0]/)===-1&&t.length<=this._matchFrom)return!0;const[s,i]=this.boundaries(t);return this.from<=Number(i)&&Number(s)<=this.to&&super.doValidate(e)}pad(e){const t=new pe;if(this.value.length===this.maxLength)return t;const r=this.value,s=this.maxLength-this.value.length;if(s){this.reset();for(let i=0;i<s;++i)t.aggregate(super._appendCharRaw("0",e));r.split("").forEach(i=>this._appendCharRaw(i))}return t}}he.MaskedRange=zs;const Zb="d{.}`m{.}`Y";class Dt extends Ue{static extractPatternOptions(e){const{mask:t,pattern:r,...s}=e;return{...s,mask:tr(t)?t:r}}constructor(e){super(Dt.extractPatternOptions({...Dt.DEFAULTS,...e}))}updateOptions(e){super.updateOptions(e)}_update(e){const{mask:t,pattern:r,blocks:s,...i}={...Dt.DEFAULTS,...e},o=Object.assign({},Dt.GET_DEFAULT_BLOCKS());e.min&&(o.Y.from=e.min.getFullYear()),e.max&&(o.Y.to=e.max.getFullYear()),e.min&&e.max&&o.Y.from===o.Y.to&&(o.m.from=e.min.getMonth()+1,o.m.to=e.max.getMonth()+1,o.m.from===o.m.to&&(o.d.from=e.min.getDate(),o.d.to=e.max.getDate())),Object.assign(o,this.blocks,s),super._update({...i,mask:tr(t)?t:r,blocks:o})}doValidate(e){const t=this.date;return super.doValidate(e)&&(!this.isComplete||this.isDateExist(this.value)&&t!=null&&(this.min==null||this.min<=t)&&(this.max==null||t<=this.max))}isDateExist(e){return this.format(this.parse(e,this),this).indexOf(e)>=0}get date(){return this.typedValue}set date(e){this.typedValue=e}get typedValue(){return this.isComplete?super.typedValue:null}set typedValue(e){super.typedValue=e}maskEquals(e){return e===Date||super.maskEquals(e)}optionsIsChanged(e){return super.optionsIsChanged(Dt.extractPatternOptions(e))}}Dt.GET_DEFAULT_BLOCKS=()=>({d:{mask:zs,from:1,to:31,maxLength:2},m:{mask:zs,from:1,to:12,maxLength:2},Y:{mask:zs,from:1900,to:9999}});Dt.DEFAULTS={...Ue.DEFAULTS,mask:Date,pattern:Zb,format:(n,e)=>{if(!n)return"";const t=String(n.getDate()).padStart(2,"0"),r=String(n.getMonth()+1).padStart(2,"0"),s=n.getFullYear();return[t,r,s].join(".")},parse:(n,e)=>{const[t,r,s]=n.split(".").map(Number);return new Date(s,r-1,t)}};he.MaskedDate=Dt;class Ci extends Ve{constructor(e){super({...Ci.DEFAULTS,...e}),this.currentMask=void 0}updateOptions(e){super.updateOptions(e)}_update(e){super._update(e),"mask"in e&&(this.exposeMask=void 0,this.compiledMasks=Array.isArray(e.mask)?e.mask.map(t=>{const{expose:r,...s}=Qn(t),i=Ft({overwrite:this._overwrite,eager:this._eager,skipInvalid:this._skipInvalid,...s});return r&&(this.exposeMask=i),i}):[])}_appendCharRaw(e,t){t===void 0&&(t={});const r=this._applyDispatch(e,t);return this.currentMask&&r.aggregate(this.currentMask._appendChar(e,this.currentMaskFlags(t))),r}_applyDispatch(e,t,r){e===void 0&&(e=""),t===void 0&&(t={}),r===void 0&&(r="");const s=t.tail&&t._beforeTailState!=null?t._beforeTailState._value:this.value,i=this.rawInputValue,o=t.tail&&t._beforeTailState!=null?t._beforeTailState._rawInputValue:i,a=i.slice(o.length),u=this.currentMask,c=new pe,h=u==null?void 0:u.state;return this.currentMask=this.doDispatch(e,{...t},r),this.currentMask&&(this.currentMask!==u?(this.currentMask.reset(),o&&(this.currentMask.append(o,{raw:!0}),c.tailShift=this.currentMask.value.length-s.length),a&&(c.tailShift+=this.currentMask.append(a,{raw:!0,tail:!0}).tailShift)):h&&(this.currentMask.state=h)),c}_appendPlaceholder(){const e=this._applyDispatch();return this.currentMask&&e.aggregate(this.currentMask._appendPlaceholder()),e}_appendEager(){const e=this._applyDispatch();return this.currentMask&&e.aggregate(this.currentMask._appendEager()),e}appendTail(e){const t=new pe;return e&&t.aggregate(this._applyDispatch("",{},e)),t.aggregate(this.currentMask?this.currentMask.appendTail(e):super.appendTail(e))}currentMaskFlags(e){var t,r;return{...e,_beforeTailState:((t=e._beforeTailState)==null?void 0:t.currentMaskRef)===this.currentMask&&((r=e._beforeTailState)==null?void 0:r.currentMask)||e._beforeTailState}}doDispatch(e,t,r){return t===void 0&&(t={}),r===void 0&&(r=""),this.dispatch(e,this,t,r)}doValidate(e){return super.doValidate(e)&&(!this.currentMask||this.currentMask.doValidate(this.currentMaskFlags(e)))}doPrepare(e,t){t===void 0&&(t={});let[r,s]=super.doPrepare(e,t);if(this.currentMask){let i;[r,i]=super.doPrepare(r,this.currentMaskFlags(t)),s=s.aggregate(i)}return[r,s]}doPrepareChar(e,t){t===void 0&&(t={});let[r,s]=super.doPrepareChar(e,t);if(this.currentMask){let i;[r,i]=super.doPrepareChar(r,this.currentMaskFlags(t)),s=s.aggregate(i)}return[r,s]}reset(){var e;(e=this.currentMask)==null||e.reset(),this.compiledMasks.forEach(t=>t.reset())}get value(){return this.exposeMask?this.exposeMask.value:this.currentMask?this.currentMask.value:""}set value(e){this.exposeMask?(this.exposeMask.value=e,this.currentMask=this.exposeMask,this._applyDispatch()):super.value=e}get unmaskedValue(){return this.exposeMask?this.exposeMask.unmaskedValue:this.currentMask?this.currentMask.unmaskedValue:""}set unmaskedValue(e){this.exposeMask?(this.exposeMask.unmaskedValue=e,this.currentMask=this.exposeMask,this._applyDispatch()):super.unmaskedValue=e}get typedValue(){return this.exposeMask?this.exposeMask.typedValue:this.currentMask?this.currentMask.typedValue:""}set typedValue(e){if(this.exposeMask){this.exposeMask.typedValue=e,this.currentMask=this.exposeMask,this._applyDispatch();return}let t=String(e);this.currentMask&&(this.currentMask.typedValue=e,t=this.currentMask.unmaskedValue),this.unmaskedValue=t}get displayValue(){return this.currentMask?this.currentMask.displayValue:""}get isComplete(){var e;return!!((e=this.currentMask)!=null&&e.isComplete)}get isFilled(){var e;return!!((e=this.currentMask)!=null&&e.isFilled)}remove(e,t){const r=new pe;return this.currentMask&&r.aggregate(this.currentMask.remove(e,t)).aggregate(this._applyDispatch()),r}get state(){var e;return{...super.state,_rawInputValue:this.rawInputValue,compiledMasks:this.compiledMasks.map(t=>t.state),currentMaskRef:this.currentMask,currentMask:(e=this.currentMask)==null?void 0:e.state}}set state(e){const{compiledMasks:t,currentMaskRef:r,currentMask:s,...i}=e;t&&this.compiledMasks.forEach((o,a)=>o.state=t[a]),r!=null&&(this.currentMask=r,this.currentMask.state=s),super.state=i}extractInput(e,t,r){return this.currentMask?this.currentMask.extractInput(e,t,r):""}extractTail(e,t){return this.currentMask?this.currentMask.extractTail(e,t):super.extractTail(e,t)}doCommit(){this.currentMask&&this.currentMask.doCommit(),super.doCommit()}nearestInputPos(e,t){return this.currentMask?this.currentMask.nearestInputPos(e,t):super.nearestInputPos(e,t)}get overwrite(){return this.currentMask?this.currentMask.overwrite:this._overwrite}set overwrite(e){this._overwrite=e}get eager(){return this.currentMask?this.currentMask.eager:this._eager}set eager(e){this._eager=e}get skipInvalid(){return this.currentMask?this.currentMask.skipInvalid:this._skipInvalid}set skipInvalid(e){this._skipInvalid=e}get autofix(){return this.currentMask?this.currentMask.autofix:this._autofix}set autofix(e){this._autofix=e}maskEquals(e){return Array.isArray(e)?this.compiledMasks.every((t,r)=>{if(!e[r])return;const{mask:s,...i}=e[r];return ri(t,i)&&t.maskEquals(s)}):super.maskEquals(e)}typedValueEquals(e){var t;return!!((t=this.currentMask)!=null&&t.typedValueEquals(e))}}Ci.DEFAULTS={...Ve.DEFAULTS,dispatch:(n,e,t,r)=>{if(!e.compiledMasks.length)return;const s=e.rawInputValue,i=e.compiledMasks.map((o,a)=>{const u=e.currentMask===o,c=u?o.displayValue.length:o.nearestInputPos(o.displayValue.length,ae.FORCE_LEFT);return o.rawInputValue!==s?(o.reset(),o.append(s,{raw:!0})):u||o.remove(c),o.append(n,e.currentMaskFlags(t)),o.appendTail(r),{index:a,weight:o.rawInputValue.length,totalInputPositions:o.totalInputPositions(0,Math.max(c,o.nearestInputPos(o.displayValue.length,ae.FORCE_LEFT)))}});return i.sort((o,a)=>a.weight-o.weight||a.totalInputPositions-o.totalInputPositions),e.compiledMasks[i[0].index]}};he.MaskedDynamic=Ci;class Ti extends Ue{constructor(e){super({...Ti.DEFAULTS,...e})}updateOptions(e){super.updateOptions(e)}_update(e){const{enum:t,...r}=e;if(t){const s=t.map(a=>a.length),i=Math.min(...s),o=Math.max(...s)-i;r.mask="*".repeat(i),o&&(r.mask+="["+"*".repeat(o)+"]"),this.enum=t}super._update(r)}_appendCharRaw(e,t){t===void 0&&(t={});const r=Math.min(this.nearestInputPos(0,ae.FORCE_RIGHT),this.value.length),s=this.enum.filter(i=>this.matchValue(i,this.unmaskedValue+e,r));if(s.length){s.length===1&&this._forEachBlocksInRange(0,this.value.length,(o,a)=>{const u=s[0][a];a>=this.value.length||u===o.value||(o.reset(),o._appendChar(u,t))});const i=super._appendCharRaw(s[0][this.value.length],t);return s.length===1&&s[0].slice(this.unmaskedValue.length).split("").forEach(o=>i.aggregate(super._appendCharRaw(o))),i}return new pe({skip:!this.isComplete})}extractTail(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length),new xt("",e)}remove(e,t){if(e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length),e===t)return new pe;const r=Math.min(super.nearestInputPos(0,ae.FORCE_RIGHT),this.value.length);let s;for(s=e;s>=0&&!(this.enum.filter(a=>this.matchValue(a,this.value.slice(r,s),r)).length>1);--s);const i=super.remove(s,t);return i.tailShift+=s-e,i}get isComplete(){return this.enum.indexOf(this.value)>=0}}Ti.DEFAULTS={...Ue.DEFAULTS,matchValue:(n,e,t)=>n.indexOf(e,t)===t};he.MaskedEnum=Ti;class Xb extends Ve{updateOptions(e){super.updateOptions(e)}_update(e){super._update({...e,validate:e.mask})}}he.MaskedFunction=Xb;var ad;class Ke extends Ve{constructor(e){super({...Ke.DEFAULTS,...e})}updateOptions(e){super.updateOptions(e)}_update(e){super._update(e),this._updateRegExps()}_updateRegExps(){const e="^"+(this.allowNegative?"[+|\\-]?":""),t="\\d*",r=(this.scale?"("+Fo(this.radix)+"\\d{0,"+this.scale+"})?":"")+"$";this._numberRegExp=new RegExp(e+t+r),this._mapToRadixRegExp=new RegExp("["+this.mapToRadix.map(Fo).join("")+"]","g"),this._thousandsSeparatorRegExp=new RegExp(Fo(this.thousandsSeparator),"g")}_removeThousandsSeparators(e){return e.replace(this._thousandsSeparatorRegExp,"")}_insertThousandsSeparators(e){const t=e.split(this.radix);return t[0]=t[0].replace(/\B(?=(\d{3})+(?!\d))/g,this.thousandsSeparator),t.join(this.radix)}doPrepareChar(e,t){t===void 0&&(t={});const[r,s]=super.doPrepareChar(this._removeThousandsSeparators(this.scale&&this.mapToRadix.length&&(t.input&&t.raw||!t.input&&!t.raw)?e.replace(this._mapToRadixRegExp,this.radix):e),t);return e&&!r&&(s.skip=!0),r&&!this.allowPositive&&!this.value&&r!=="-"&&s.aggregate(this._appendChar("-")),[r,s]}_separatorsCount(e,t){t===void 0&&(t=!1);let r=0;for(let s=0;s<e;++s)this._value.indexOf(this.thousandsSeparator,s)===s&&(++r,t&&(e+=this.thousandsSeparator.length));return r}_separatorsCountFromSlice(e){return e===void 0&&(e=this._value),this._separatorsCount(this._removeThousandsSeparators(e).length,!0)}extractInput(e,t,r){return e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length),[e,t]=this._adjustRangeWithSeparators(e,t),this._removeThousandsSeparators(super.extractInput(e,t,r))}_appendCharRaw(e,t){t===void 0&&(t={});const r=t.tail&&t._beforeTailState?t._beforeTailState._value:this._value,s=this._separatorsCountFromSlice(r);this._value=this._removeThousandsSeparators(this.value);const i=this._value;this._value+=e;const o=this.number;let a=!isNaN(o),u=!1;if(a){let d;this.min!=null&&this.min<0&&this.number<this.min&&(d=this.min),this.max!=null&&this.max>0&&this.number>this.max&&(d=this.max),d!=null&&(this.autofix?(this._value=this.format(d,this).replace(Ke.UNMASKED_RADIX,this.radix),u||(u=i===this._value&&!t.tail)):a=!1),a&&(a=!!this._value.match(this._numberRegExp))}let c;a?c=new pe({inserted:this._value.slice(i.length),rawInserted:u?"":e,skip:u}):(this._value=i,c=new pe),this._value=this._insertThousandsSeparators(this._value);const h=t.tail&&t._beforeTailState?t._beforeTailState._value:this._value,g=this._separatorsCountFromSlice(h);return c.tailShift+=(g-s)*this.thousandsSeparator.length,c}_findSeparatorAround(e){if(this.thousandsSeparator){const t=e-this.thousandsSeparator.length+1,r=this.value.indexOf(this.thousandsSeparator,t);if(r<=e)return r}return-1}_adjustRangeWithSeparators(e,t){const r=this._findSeparatorAround(e);r>=0&&(e=r);const s=this._findSeparatorAround(t);return s>=0&&(t=s+this.thousandsSeparator.length),[e,t]}remove(e,t){e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length),[e,t]=this._adjustRangeWithSeparators(e,t);const r=this.value.slice(0,e),s=this.value.slice(t),i=this._separatorsCount(r.length);this._value=this._insertThousandsSeparators(this._removeThousandsSeparators(r+s));const o=this._separatorsCountFromSlice(r);return new pe({tailShift:(o-i)*this.thousandsSeparator.length})}nearestInputPos(e,t){if(!this.thousandsSeparator)return e;switch(t){case ae.NONE:case ae.LEFT:case ae.FORCE_LEFT:{const r=this._findSeparatorAround(e-1);if(r>=0){const s=r+this.thousandsSeparator.length;if(e<s||this.value.length<=s||t===ae.FORCE_LEFT)return r}break}case ae.RIGHT:case ae.FORCE_RIGHT:{const r=this._findSeparatorAround(e);if(r>=0)return r+this.thousandsSeparator.length}}return e}doCommit(){if(this.value){const e=this.number;let t=e;this.min!=null&&(t=Math.max(t,this.min)),this.max!=null&&(t=Math.min(t,this.max)),t!==e&&(this.unmaskedValue=this.format(t,this));let r=this.value;this.normalizeZeros&&(r=this._normalizeZeros(r)),this.padFractionalZeros&&this.scale>0&&(r=this._padFractionalZeros(r)),this._value=r}super.doCommit()}_normalizeZeros(e){const t=this._removeThousandsSeparators(e).split(this.radix);return t[0]=t[0].replace(/^(\D*)(0*)(\d*)/,(r,s,i,o)=>s+o),e.length&&!/\d$/.test(t[0])&&(t[0]=t[0]+"0"),t.length>1&&(t[1]=t[1].replace(/0*$/,""),t[1].length||(t.length=1)),this._insertThousandsSeparators(t.join(this.radix))}_padFractionalZeros(e){if(!e)return e;const t=e.split(this.radix);return t.length<2&&t.push(""),t[1]=t[1].padEnd(this.scale,"0"),t.join(this.radix)}doSkipInvalid(e,t,r){t===void 0&&(t={});const s=this.scale===0&&e!==this.thousandsSeparator&&(e===this.radix||e===Ke.UNMASKED_RADIX||this.mapToRadix.includes(e));return super.doSkipInvalid(e,t,r)&&!s}get unmaskedValue(){return this._removeThousandsSeparators(this._normalizeZeros(this.value)).replace(this.radix,Ke.UNMASKED_RADIX)}set unmaskedValue(e){super.unmaskedValue=e}get typedValue(){return this.parse(this.unmaskedValue,this)}set typedValue(e){this.rawInputValue=this.format(e,this).replace(Ke.UNMASKED_RADIX,this.radix)}get number(){return this.typedValue}set number(e){this.typedValue=e}get allowNegative(){return this.min!=null&&this.min<0||this.max!=null&&this.max<0}get allowPositive(){return this.min!=null&&this.min>0||this.max!=null&&this.max>0}typedValueEquals(e){return(super.typedValueEquals(e)||Ke.EMPTY_VALUES.includes(e)&&Ke.EMPTY_VALUES.includes(this.typedValue))&&!(e===0&&this.value==="")}}ad=Ke;Ke.UNMASKED_RADIX=".";Ke.EMPTY_VALUES=[...Ve.EMPTY_VALUES,0];Ke.DEFAULTS={...Ve.DEFAULTS,mask:Number,radix:",",thousandsSeparator:"",mapToRadix:[ad.UNMASKED_RADIX],min:Number.MIN_SAFE_INTEGER,max:Number.MAX_SAFE_INTEGER,scale:2,normalizeZeros:!0,padFractionalZeros:!1,parse:Number,format:n=>n.toLocaleString("en-US",{useGrouping:!1,maximumFractionDigits:20})};he.MaskedNumber=Ke;const Aa={MASKED:"value",UNMASKED:"unmaskedValue",TYPED:"typedValue"};function ld(n,e,t){e===void 0&&(e=Aa.MASKED),t===void 0&&(t=Aa.MASKED);const r=Ft(n);return s=>r.runIsolated(i=>(i[e]=s,i[t]))}function Qb(n,e,t,r){return ld(e,t,r)(n)}he.PIPE_TYPE=Aa;he.createPipe=ld;he.pipe=Qb;class Jb extends Ue{get repeatFrom(){var e;return(e=Array.isArray(this.repeat)?this.repeat[0]:this.repeat===1/0?0:this.repeat)!=null?e:0}get repeatTo(){var e;return(e=Array.isArray(this.repeat)?this.repeat[1]:this.repeat)!=null?e:1/0}constructor(e){super(e)}updateOptions(e){super.updateOptions(e)}_update(e){var t,r,s;const{repeat:i,...o}=Qn(e);this._blockOpts=Object.assign({},this._blockOpts,o);const a=Ft(this._blockOpts);this.repeat=(t=(r=i??a.repeat)!=null?r:this.repeat)!=null?t:1/0,super._update({mask:"m".repeat(Math.max(this.repeatTo===1/0&&((s=this._blocks)==null?void 0:s.length)||0,this.repeatFrom)),blocks:{m:a},eager:a.eager,overwrite:a.overwrite,skipInvalid:a.skipInvalid,lazy:a.lazy,placeholderChar:a.placeholderChar,displayChar:a.displayChar})}_allocateBlock(e){if(e<this._blocks.length)return this._blocks[e];if(this.repeatTo===1/0||this._blocks.length<this.repeatTo)return this._blocks.push(Ft(this._blockOpts)),this.mask+="m",this._blocks[this._blocks.length-1]}_appendCharRaw(e,t){t===void 0&&(t={});const r=new pe;for(let u=(s=(i=this._mapPosToBlock(this.displayValue.length))==null?void 0:i.index)!=null?s:Math.max(this._blocks.length-1,0),c,h;c=(o=this._blocks[u])!=null?o:h=!h&&this._allocateBlock(u);++u){var s,i,o,a;const g=c._appendChar(e,{...t,_beforeTailState:(a=t._beforeTailState)==null||(a=a._blocks)==null?void 0:a[u]});if(g.skip&&h){this._blocks.pop(),this.mask=this.mask.slice(1);break}if(r.aggregate(g),g.consumed)break}return r}_trimEmptyTail(e,t){var r,s;e===void 0&&(e=0);const i=Math.max(((r=this._mapPosToBlock(e))==null?void 0:r.index)||0,this.repeatFrom,0);let o;t!=null&&(o=(s=this._mapPosToBlock(t))==null?void 0:s.index),o==null&&(o=this._blocks.length-1);let a=0;for(let u=o;i<=u&&!this._blocks[u].unmaskedValue;--u,++a);a&&(this._blocks.splice(o-a+1,a),this.mask=this.mask.slice(a))}reset(){super.reset(),this._trimEmptyTail()}remove(e,t){e===void 0&&(e=0),t===void 0&&(t=this.displayValue.length);const r=super.remove(e,t);return this._trimEmptyTail(e,t),r}totalInputPositions(e,t){return e===void 0&&(e=0),t==null&&this.repeatTo===1/0?1/0:super.totalInputPositions(e,t)}get state(){return super.state}set state(e){this._blocks.length=e._blocks.length,this.mask=this.mask.slice(0,this._blocks.length),super.state=e}}he.RepeatBlock=Jb;try{globalThis.IMask=he}catch{}var Ds={exports:{}},Ps={exports:{}},we={};/** @license React v16.13.1
167
- * react-is.production.min.js
168
- *
169
- * Copyright (c) Facebook, Inc. and its affiliates.
170
- *
171
- * This source code is licensed under the MIT license found in the
172
- * LICENSE file in the root directory of this source tree.
173
- */var $u;function eE(){if($u)return we;$u=1;var n=typeof Symbol=="function"&&Symbol.for,e=n?Symbol.for("react.element"):60103,t=n?Symbol.for("react.portal"):60106,r=n?Symbol.for("react.fragment"):60107,s=n?Symbol.for("react.strict_mode"):60108,i=n?Symbol.for("react.profiler"):60114,o=n?Symbol.for("react.provider"):60109,a=n?Symbol.for("react.context"):60110,u=n?Symbol.for("react.async_mode"):60111,c=n?Symbol.for("react.concurrent_mode"):60111,h=n?Symbol.for("react.forward_ref"):60112,g=n?Symbol.for("react.suspense"):60113,d=n?Symbol.for("react.suspense_list"):60120,m=n?Symbol.for("react.memo"):60115,v=n?Symbol.for("react.lazy"):60116,p=n?Symbol.for("react.block"):60121,y=n?Symbol.for("react.fundamental"):60117,E=n?Symbol.for("react.responder"):60118,S=n?Symbol.for("react.scope"):60119;function x(_){if(typeof _=="object"&&_!==null){var P=_.$$typeof;switch(P){case e:switch(_=_.type,_){case u:case c:case r:case i:case s:case g:return _;default:switch(_=_&&_.$$typeof,_){case a:case h:case v:case m:case o:return _;default:return P}}case t:return P}}}function N(_){return x(_)===c}return we.AsyncMode=u,we.ConcurrentMode=c,we.ContextConsumer=a,we.ContextProvider=o,we.Element=e,we.ForwardRef=h,we.Fragment=r,we.Lazy=v,we.Memo=m,we.Portal=t,we.Profiler=i,we.StrictMode=s,we.Suspense=g,we.isAsyncMode=function(_){return N(_)||x(_)===u},we.isConcurrentMode=N,we.isContextConsumer=function(_){return x(_)===a},we.isContextProvider=function(_){return x(_)===o},we.isElement=function(_){return typeof _=="object"&&_!==null&&_.$$typeof===e},we.isForwardRef=function(_){return x(_)===h},we.isFragment=function(_){return x(_)===r},we.isLazy=function(_){return x(_)===v},we.isMemo=function(_){return x(_)===m},we.isPortal=function(_){return x(_)===t},we.isProfiler=function(_){return x(_)===i},we.isStrictMode=function(_){return x(_)===s},we.isSuspense=function(_){return x(_)===g},we.isValidElementType=function(_){return typeof _=="string"||typeof _=="function"||_===r||_===c||_===i||_===s||_===g||_===d||typeof _=="object"&&_!==null&&(_.$$typeof===v||_.$$typeof===m||_.$$typeof===o||_.$$typeof===a||_.$$typeof===h||_.$$typeof===y||_.$$typeof===E||_.$$typeof===S||_.$$typeof===p)},we.typeOf=x,we}var xe={};/** @license React v16.13.1
174
- * react-is.development.js
175
- *
176
- * Copyright (c) Facebook, Inc. and its affiliates.
177
- *
178
- * This source code is licensed under the MIT license found in the
179
- * LICENSE file in the root directory of this source tree.
180
- */var Vu;function tE(){return Vu||(Vu=1,process.env.NODE_ENV!=="production"&&(function(){var n=typeof Symbol=="function"&&Symbol.for,e=n?Symbol.for("react.element"):60103,t=n?Symbol.for("react.portal"):60106,r=n?Symbol.for("react.fragment"):60107,s=n?Symbol.for("react.strict_mode"):60108,i=n?Symbol.for("react.profiler"):60114,o=n?Symbol.for("react.provider"):60109,a=n?Symbol.for("react.context"):60110,u=n?Symbol.for("react.async_mode"):60111,c=n?Symbol.for("react.concurrent_mode"):60111,h=n?Symbol.for("react.forward_ref"):60112,g=n?Symbol.for("react.suspense"):60113,d=n?Symbol.for("react.suspense_list"):60120,m=n?Symbol.for("react.memo"):60115,v=n?Symbol.for("react.lazy"):60116,p=n?Symbol.for("react.block"):60121,y=n?Symbol.for("react.fundamental"):60117,E=n?Symbol.for("react.responder"):60118,S=n?Symbol.for("react.scope"):60119;function x(k){return typeof k=="string"||typeof k=="function"||k===r||k===c||k===i||k===s||k===g||k===d||typeof k=="object"&&k!==null&&(k.$$typeof===v||k.$$typeof===m||k.$$typeof===o||k.$$typeof===a||k.$$typeof===h||k.$$typeof===y||k.$$typeof===E||k.$$typeof===S||k.$$typeof===p)}function N(k){if(typeof k=="object"&&k!==null){var ce=k.$$typeof;switch(ce){case e:var ge=k.type;switch(ge){case u:case c:case r:case i:case s:case g:return ge;default:var be=ge&&ge.$$typeof;switch(be){case a:case h:case v:case m:case o:return be;default:return ce}}case t:return ce}}}var _=u,P=c,I=a,te=o,ue=e,ie=h,b=r,M=v,A=m,$=t,V=i,R=s,q=g,W=!1;function Y(k){return W||(W=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),T(k)||N(k)===u}function T(k){return N(k)===c}function D(k){return N(k)===a}function U(k){return N(k)===o}function K(k){return typeof k=="object"&&k!==null&&k.$$typeof===e}function z(k){return N(k)===h}function H(k){return N(k)===r}function Q(k){return N(k)===v}function F(k){return N(k)===m}function j(k){return N(k)===t}function Z(k){return N(k)===i}function G(k){return N(k)===s}function X(k){return N(k)===g}xe.AsyncMode=_,xe.ConcurrentMode=P,xe.ContextConsumer=I,xe.ContextProvider=te,xe.Element=ue,xe.ForwardRef=ie,xe.Fragment=b,xe.Lazy=M,xe.Memo=A,xe.Portal=$,xe.Profiler=V,xe.StrictMode=R,xe.Suspense=q,xe.isAsyncMode=Y,xe.isConcurrentMode=T,xe.isContextConsumer=D,xe.isContextProvider=U,xe.isElement=K,xe.isForwardRef=z,xe.isFragment=H,xe.isLazy=Q,xe.isMemo=F,xe.isPortal=j,xe.isProfiler=Z,xe.isStrictMode=G,xe.isSuspense=X,xe.isValidElementType=x,xe.typeOf=N})()),xe}var Uu;function ud(){return Uu||(Uu=1,process.env.NODE_ENV==="production"?Ps.exports=eE():Ps.exports=tE()),Ps.exports}/*
181
- object-assign
182
- (c) Sindre Sorhus
183
- @license MIT
184
- */var jo,Hu;function rE(){if(Hu)return jo;Hu=1;var n=Object.getOwnPropertySymbols,e=Object.prototype.hasOwnProperty,t=Object.prototype.propertyIsEnumerable;function r(i){if(i==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(i)}function s(){try{if(!Object.assign)return!1;var i=new String("abc");if(i[5]="de",Object.getOwnPropertyNames(i)[0]==="5")return!1;for(var o={},a=0;a<10;a++)o["_"+String.fromCharCode(a)]=a;var u=Object.getOwnPropertyNames(o).map(function(h){return o[h]});if(u.join("")!=="0123456789")return!1;var c={};return"abcdefghijklmnopqrst".split("").forEach(function(h){c[h]=h}),Object.keys(Object.assign({},c)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return jo=s()?Object.assign:function(i,o){for(var a,u=r(i),c,h=1;h<arguments.length;h++){a=Object(arguments[h]);for(var g in a)e.call(a,g)&&(u[g]=a[g]);if(n){c=n(a);for(var d=0;d<c.length;d++)t.call(a,c[d])&&(u[c[d]]=a[c[d]])}}return u},jo}var $o,zu;function al(){if(zu)return $o;zu=1;var n="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return $o=n,$o}var Vo,Gu;function cd(){return Gu||(Gu=1,Vo=Function.call.bind(Object.prototype.hasOwnProperty)),Vo}var Uo,Ku;function nE(){if(Ku)return Uo;Ku=1;var n=function(){};if(process.env.NODE_ENV!=="production"){var e=al(),t={},r=cd();n=function(i){var o="Warning: "+i;typeof console<"u"&&console.error(o);try{throw new Error(o)}catch{}}}function s(i,o,a,u,c){if(process.env.NODE_ENV!=="production"){for(var h in i)if(r(i,h)){var g;try{if(typeof i[h]!="function"){var d=Error((u||"React class")+": "+a+" type `"+h+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[h]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}g=i[h](o,h,u,a,null,e)}catch(v){g=v}if(g&&!(g instanceof Error)&&n((u||"React class")+": type specification of "+a+" `"+h+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof g+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),g instanceof Error&&!(g.message in t)){t[g.message]=!0;var m=c?c():"";n("Failed "+a+" type: "+g.message+(m??""))}}}}return s.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(t={})},Uo=s,Uo}var Ho,Wu;function sE(){if(Wu)return Ho;Wu=1;var n=ud(),e=rE(),t=al(),r=cd(),s=nE(),i=function(){};process.env.NODE_ENV!=="production"&&(i=function(a){var u="Warning: "+a;typeof console<"u"&&console.error(u);try{throw new Error(u)}catch{}});function o(){return null}return Ho=function(a,u){var c=typeof Symbol=="function"&&Symbol.iterator,h="@@iterator";function g(T){var D=T&&(c&&T[c]||T[h]);if(typeof D=="function")return D}var d="<<anonymous>>",m={array:E("array"),bigint:E("bigint"),bool:E("boolean"),func:E("function"),number:E("number"),object:E("object"),string:E("string"),symbol:E("symbol"),any:S(),arrayOf:x,element:N(),elementType:_(),instanceOf:P,node:ie(),objectOf:te,oneOf:I,oneOfType:ue,shape:M,exact:A};function v(T,D){return T===D?T!==0||1/T===1/D:T!==T&&D!==D}function p(T,D){this.message=T,this.data=D&&typeof D=="object"?D:{},this.stack=""}p.prototype=Error.prototype;function y(T){if(process.env.NODE_ENV!=="production")var D={},U=0;function K(H,Q,F,j,Z,G,X){if(j=j||d,G=G||F,X!==t){if(u){var k=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw k.name="Invariant Violation",k}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var ce=j+":"+F;!D[ce]&&U<3&&(i("You are manually calling a React.PropTypes validation function for the `"+G+"` prop on `"+j+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),D[ce]=!0,U++)}}return Q[F]==null?H?Q[F]===null?new p("The "+Z+" `"+G+"` is marked as required "+("in `"+j+"`, but its value is `null`.")):new p("The "+Z+" `"+G+"` is marked as required in "+("`"+j+"`, but its value is `undefined`.")):null:T(Q,F,j,Z,G)}var z=K.bind(null,!1);return z.isRequired=K.bind(null,!0),z}function E(T){function D(U,K,z,H,Q,F){var j=U[K],Z=R(j);if(Z!==T){var G=q(j);return new p("Invalid "+H+" `"+Q+"` of type "+("`"+G+"` supplied to `"+z+"`, expected ")+("`"+T+"`."),{expectedType:T})}return null}return y(D)}function S(){return y(o)}function x(T){function D(U,K,z,H,Q){if(typeof T!="function")return new p("Property `"+Q+"` of component `"+z+"` has invalid PropType notation inside arrayOf.");var F=U[K];if(!Array.isArray(F)){var j=R(F);return new p("Invalid "+H+" `"+Q+"` of type "+("`"+j+"` supplied to `"+z+"`, expected an array."))}for(var Z=0;Z<F.length;Z++){var G=T(F,Z,z,H,Q+"["+Z+"]",t);if(G instanceof Error)return G}return null}return y(D)}function N(){function T(D,U,K,z,H){var Q=D[U];if(!a(Q)){var F=R(Q);return new p("Invalid "+z+" `"+H+"` of type "+("`"+F+"` supplied to `"+K+"`, expected a single ReactElement."))}return null}return y(T)}function _(){function T(D,U,K,z,H){var Q=D[U];if(!n.isValidElementType(Q)){var F=R(Q);return new p("Invalid "+z+" `"+H+"` of type "+("`"+F+"` supplied to `"+K+"`, expected a single ReactElement type."))}return null}return y(T)}function P(T){function D(U,K,z,H,Q){if(!(U[K]instanceof T)){var F=T.name||d,j=Y(U[K]);return new p("Invalid "+H+" `"+Q+"` of type "+("`"+j+"` supplied to `"+z+"`, expected ")+("instance of `"+F+"`."))}return null}return y(D)}function I(T){if(!Array.isArray(T))return process.env.NODE_ENV!=="production"&&(arguments.length>1?i("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):i("Invalid argument supplied to oneOf, expected an array.")),o;function D(U,K,z,H,Q){for(var F=U[K],j=0;j<T.length;j++)if(v(F,T[j]))return null;var Z=JSON.stringify(T,function(X,k){var ce=q(k);return ce==="symbol"?String(k):k});return new p("Invalid "+H+" `"+Q+"` of value `"+String(F)+"` "+("supplied to `"+z+"`, expected one of "+Z+"."))}return y(D)}function te(T){function D(U,K,z,H,Q){if(typeof T!="function")return new p("Property `"+Q+"` of component `"+z+"` has invalid PropType notation inside objectOf.");var F=U[K],j=R(F);if(j!=="object")return new p("Invalid "+H+" `"+Q+"` of type "+("`"+j+"` supplied to `"+z+"`, expected an object."));for(var Z in F)if(r(F,Z)){var G=T(F,Z,z,H,Q+"."+Z,t);if(G instanceof Error)return G}return null}return y(D)}function ue(T){if(!Array.isArray(T))return process.env.NODE_ENV!=="production"&&i("Invalid argument supplied to oneOfType, expected an instance of array."),o;for(var D=0;D<T.length;D++){var U=T[D];if(typeof U!="function")return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+W(U)+" at index "+D+"."),o}function K(z,H,Q,F,j){for(var Z=[],G=0;G<T.length;G++){var X=T[G],k=X(z,H,Q,F,j,t);if(k==null)return null;k.data&&r(k.data,"expectedType")&&Z.push(k.data.expectedType)}var ce=Z.length>0?", expected one of type ["+Z.join(", ")+"]":"";return new p("Invalid "+F+" `"+j+"` supplied to "+("`"+Q+"`"+ce+"."))}return y(K)}function ie(){function T(D,U,K,z,H){return $(D[U])?null:new p("Invalid "+z+" `"+H+"` supplied to "+("`"+K+"`, expected a ReactNode."))}return y(T)}function b(T,D,U,K,z){return new p((T||"React class")+": "+D+" type `"+U+"."+K+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+z+"`.")}function M(T){function D(U,K,z,H,Q){var F=U[K],j=R(F);if(j!=="object")return new p("Invalid "+H+" `"+Q+"` of type `"+j+"` "+("supplied to `"+z+"`, expected `object`."));for(var Z in T){var G=T[Z];if(typeof G!="function")return b(z,H,Q,Z,q(G));var X=G(F,Z,z,H,Q+"."+Z,t);if(X)return X}return null}return y(D)}function A(T){function D(U,K,z,H,Q){var F=U[K],j=R(F);if(j!=="object")return new p("Invalid "+H+" `"+Q+"` of type `"+j+"` "+("supplied to `"+z+"`, expected `object`."));var Z=e({},U[K],T);for(var G in Z){var X=T[G];if(r(T,G)&&typeof X!="function")return b(z,H,Q,G,q(X));if(!X)return new p("Invalid "+H+" `"+Q+"` key `"+G+"` supplied to `"+z+"`.\nBad object: "+JSON.stringify(U[K],null," ")+`
185
- Valid keys: `+JSON.stringify(Object.keys(T),null," "));var k=X(F,G,z,H,Q+"."+G,t);if(k)return k}return null}return y(D)}function $(T){switch(typeof T){case"number":case"string":case"undefined":return!0;case"boolean":return!T;case"object":if(Array.isArray(T))return T.every($);if(T===null||a(T))return!0;var D=g(T);if(D){var U=D.call(T),K;if(D!==T.entries){for(;!(K=U.next()).done;)if(!$(K.value))return!1}else for(;!(K=U.next()).done;){var z=K.value;if(z&&!$(z[1]))return!1}}else return!1;return!0;default:return!1}}function V(T,D){return T==="symbol"?!0:D?D["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&D instanceof Symbol:!1}function R(T){var D=typeof T;return Array.isArray(T)?"array":T instanceof RegExp?"object":V(D,T)?"symbol":D}function q(T){if(typeof T>"u"||T===null)return""+T;var D=R(T);if(D==="object"){if(T instanceof Date)return"date";if(T instanceof RegExp)return"regexp"}return D}function W(T){var D=q(T);switch(D){case"array":case"object":return"an "+D;case"boolean":case"date":case"regexp":return"a "+D;default:return D}}function Y(T){return!T.constructor||!T.constructor.name?d:T.constructor.name}return m.checkPropTypes=s,m.resetWarningCache=s.resetWarningCache,m.PropTypes=m,m},Ho}var zo,Yu;function iE(){if(Yu)return zo;Yu=1;var n=al();function e(){}function t(){}return t.resetWarningCache=e,zo=function(){function r(o,a,u,c,h,g){if(g!==n){var d=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw d.name="Invariant Violation",d}}r.isRequired=r;function s(){return r}var i={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:s,element:r,elementType:r,instanceOf:s,node:r,objectOf:s,oneOf:s,oneOfType:s,shape:s,exact:s,checkPropTypes:t,resetWarningCache:e};return i.PropTypes=i,i},zo}var Zu;function oE(){if(Zu)return Ds.exports;if(Zu=1,process.env.NODE_ENV!=="production"){var n=ud(),e=!0;Ds.exports=sE()(n.isElement,e)}else Ds.exports=iE()();return Ds.exports}var aE=oE();const se=De.getDefaultExportFromCjs(aE),hd={mask:se.oneOfType([se.array,se.func,se.string,se.instanceOf(RegExp),se.oneOf([Date,Number,he.Masked]),se.instanceOf(he.Masked)]),value:se.any,unmask:se.oneOfType([se.bool,se.oneOf(["typed"])]),prepare:se.func,prepareChar:se.func,validate:se.func,commit:se.func,overwrite:se.oneOfType([se.bool,se.oneOf(["shift"])]),eager:se.oneOfType([se.bool,se.oneOf(["append","remove"])]),skipInvalid:se.bool,onAccept:se.func,onComplete:se.func,placeholderChar:se.string,displayChar:se.string,lazy:se.bool,definitions:se.object,blocks:se.object,enum:se.arrayOf(se.string),maxLength:se.number,from:se.number,to:se.number,pattern:se.string,format:se.func,parse:se.func,autofix:se.oneOfType([se.bool,se.oneOf(["pad"])]),radix:se.string,thousandsSeparator:se.string,mapToRadix:se.arrayOf(se.string),scale:se.number,normalizeZeros:se.bool,padFractionalZeros:se.bool,min:se.oneOfType([se.number,se.instanceOf(Date)]),max:se.oneOfType([se.number,se.instanceOf(Date)]),dispatch:se.func,inputRef:se.oneOfType([se.func,se.shape({current:se.object})])},dd=Object.keys(hd).filter(n=>n!=="value"),lE=["value","unmask","onAccept","onComplete","inputRef"],uE=dd.filter(n=>lE.indexOf(n)<0);function cE(n){var e;const t=(e=class extends C.default.Component{constructor(i){super(i),this._inputRef=this._inputRef.bind(this)}componentDidMount(){this.props.mask&&this.initMask()}componentDidUpdate(){const i=this.props,o=this._extractMaskOptionsFromProps(i);if(o.mask)this.maskRef?(this.maskRef.updateOptions(o),"value"in i&&i.value!==void 0&&(this.maskValue=i.value)):this.initMask(o);else if(this.destroyMask(),"value"in i&&i.value!==void 0){var a;(a=this.element)!=null&&a.isContentEditable&&this.element.tagName!=="INPUT"&&this.element.tagName!=="TEXTAREA"?this.element.textContent=i.value:this.element.value=i.value}}componentWillUnmount(){this.destroyMask()}_inputRef(i){this.element=i,this.props.inputRef&&(Object.prototype.hasOwnProperty.call(this.props.inputRef,"current")?this.props.inputRef.current=i:this.props.inputRef(i))}initMask(i){i===void 0&&(i=this._extractMaskOptionsFromProps(this.props)),this.maskRef=he(this.element,i).on("accept",this._onAccept.bind(this)).on("complete",this._onComplete.bind(this)),"value"in this.props&&this.props.value!==void 0&&(this.maskValue=this.props.value)}destroyMask(){this.maskRef&&(this.maskRef.destroy(),delete this.maskRef)}_extractMaskOptionsFromProps(i){const{...o}=i;return Object.keys(o).filter(a=>uE.indexOf(a)<0).forEach(a=>{delete o[a]}),o}_extractNonMaskProps(i){const{...o}=i;return dd.forEach(a=>{a!=="maxLength"&&delete o[a]}),"defaultValue"in o||(o.defaultValue=i.mask?"":o.value),delete o.value,o}get maskValue(){return this.maskRef?this.props.unmask==="typed"?this.maskRef.typedValue:this.props.unmask?this.maskRef.unmaskedValue:this.maskRef.value:""}set maskValue(i){this.maskRef&&(i=i==null&&this.props.unmask!=="typed"?"":i,this.props.unmask==="typed"?this.maskRef.typedValue=i:this.props.unmask?this.maskRef.unmaskedValue=i:this.maskRef.value=i)}_onAccept(i){this.props.onAccept&&this.maskRef&&this.props.onAccept(this.maskValue,this.maskRef,i)}_onComplete(i){this.props.onComplete&&this.maskRef&&this.props.onComplete(this.maskValue,this.maskRef,i)}render(){return C.default.createElement(n,{...this._extractNonMaskProps(this.props),inputRef:this._inputRef})}},e.displayName=void 0,e.propTypes=void 0,e),r=n.displayName||n.name||"Component";return t.displayName="IMask("+r+")",t.propTypes=hd,C.default.forwardRef((s,i)=>C.default.createElement(t,{...s,ref:i}))}const hE=cE(n=>{let{inputRef:e,...t}=n;return C.default.createElement("input",{...t,ref:e})}),dE=(n,e)=>C.default.createElement(hE,{...n,ref:e}),fE=C.default.forwardRef(dE),fd=We.forwardRef(({className:n,type:e,variant:t,...r},s)=>O.jsx(fE,{className:Ce.cn(Si({variant:t}),n),ref:s,...r}));fd.displayName="MaskInput";var ll="Radio",[pE,pd]=le.createContextScope(ll),[gE,mE]=pE(ll),gd=C.forwardRef((n,e)=>{const{__scopeRadio:t,name:r,checked:s=!1,required:i,disabled:o,value:a="on",onCheck:u,form:c,...h}=n,[g,d]=C.useState(null),m=Oe.useComposedRefs(e,y=>d(y)),v=C.useRef(!1),p=g?c||!!g.closest("form"):!0;return O.jsxs(gE,{scope:t,checked:s,disabled:o,children:[O.jsx(le.Primitive.button,{type:"button",role:"radio","aria-checked":s,"data-state":bd(s),"data-disabled":o?"":void 0,disabled:o,value:a,...h,ref:m,onClick:le.composeEventHandlers(n.onClick,y=>{s||u==null||u(),p&&(v.current=y.isPropagationStopped(),v.current||y.stopPropagation())})}),p&&O.jsx(yd,{control:g,bubbles:!v.current,name:r,value:a,checked:s,required:i,disabled:o,form:c,style:{transform:"translateX(-100%)"}})]})});gd.displayName=ll;var md="RadioIndicator",vd=C.forwardRef((n,e)=>{const{__scopeRadio:t,forceMount:r,...s}=n,i=mE(md,t);return O.jsx(le.Presence,{present:r||i.checked,children:O.jsx(le.Primitive.span,{"data-state":bd(i.checked),"data-disabled":i.disabled?"":void 0,...s,ref:e})})});vd.displayName=md;var vE="RadioBubbleInput",yd=C.forwardRef(({__scopeRadio:n,control:e,checked:t,bubbles:r=!0,...s},i)=>{const o=C.useRef(null),a=Oe.useComposedRefs(o,i),u=oi(t),c=jt.useSize(e);return C.useEffect(()=>{const h=o.current;if(!h)return;const g=window.HTMLInputElement.prototype,m=Object.getOwnPropertyDescriptor(g,"checked").set;if(u!==t&&m){const v=new Event("click",{bubbles:r});m.call(h,t),h.dispatchEvent(v)}},[u,t,r]),O.jsx(le.Primitive.input,{type:"radio","aria-hidden":!0,defaultChecked:t,...s,tabIndex:-1,ref:a,style:{...s.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});yd.displayName=vE;function bd(n){return n?"checked":"unchecked"}var yE=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],ki="RadioGroup",[bE]=le.createContextScope(ki,[ii.createRovingFocusGroupScope,pd]),Ed=ii.createRovingFocusGroupScope(),wd=pd(),[EE,wE]=bE(ki),xd=C.forwardRef((n,e)=>{const{__scopeRadioGroup:t,name:r,defaultValue:s,value:i,required:o=!1,disabled:a=!1,orientation:u,dir:c,loop:h=!0,onValueChange:g,...d}=n,m=Ed(t),v=nc.useDirection(c),[p,y]=Qt.useControllableState({prop:i,defaultProp:s??null,onChange:g,caller:ki});return O.jsx(EE,{scope:t,name:r,required:o,disabled:a,value:p,onValueChange:y,children:O.jsx(ii.Root,{asChild:!0,...m,orientation:u,dir:v,loop:h,children:O.jsx(le.Primitive.div,{role:"radiogroup","aria-required":o,"aria-orientation":u,"data-disabled":a?"":void 0,dir:v,...d,ref:e})})})});xd.displayName=ki;var Sd="RadioGroupItem",_d=C.forwardRef((n,e)=>{const{__scopeRadioGroup:t,disabled:r,...s}=n,i=wE(Sd,t),o=i.disabled||r,a=Ed(t),u=wd(t),c=C.useRef(null),h=Oe.useComposedRefs(e,c),g=i.value===s.value,d=C.useRef(!1);return C.useEffect(()=>{const m=p=>{yE.includes(p.key)&&(d.current=!0)},v=()=>d.current=!1;return document.addEventListener("keydown",m),document.addEventListener("keyup",v),()=>{document.removeEventListener("keydown",m),document.removeEventListener("keyup",v)}},[]),O.jsx(ii.Item,{asChild:!0,...a,focusable:!o,active:g,children:O.jsx(gd,{disabled:o,required:i.required,checked:g,...u,...s,name:i.name,ref:h,onCheck:()=>i.onValueChange(s.value),onKeyDown:le.composeEventHandlers(m=>{m.key==="Enter"&&m.preventDefault()}),onFocus:le.composeEventHandlers(s.onFocus,()=>{var m;d.current&&((m=c.current)==null||m.click())})})})});_d.displayName=Sd;var xE="RadioGroupIndicator",Ad=C.forwardRef((n,e)=>{const{__scopeRadioGroup:t,...r}=n,s=wd(t);return O.jsx(vd,{...s,...r,ref:e})});Ad.displayName=xE;var Cd=xd,Td=_d,SE=Ad;const kd=C.forwardRef(({className:n,...e},t)=>O.jsx(Cd,{className:Ce.cn("grid gap-2",n),...e,ref:t}));kd.displayName=Cd.displayName;const Nd=C.forwardRef(({className:n,...e},t)=>O.jsx(Td,{ref:t,className:Ce.cn("border-border-alpha-strong text-item-primary ring-offset-background focus-visible:ring-ring aspect-square size-4 rounded-full border focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",n),...e,children:O.jsx(SE,{className:"flex items-center justify-center",children:O.jsx(sc.Circle,{className:"size-2.5 fill-current text-current"})})}));Nd.displayName=Td.displayName;function _E(n){const e=AE(n),t=C.forwardRef((r,s)=>{const{children:i,...o}=r,a=C.Children.toArray(i),u=a.find(TE);if(u){const c=u.props.children,h=a.map(g=>g===u?C.Children.count(c)>1?C.Children.only(null):C.isValidElement(c)?c.props.children:null:g);return O.jsx(e,{...o,ref:s,children:C.isValidElement(c)?C.cloneElement(c,void 0,h):null})}return O.jsx(e,{...o,ref:s,children:i})});return t.displayName=`${n}.Slot`,t}function AE(n){const e=C.forwardRef((t,r)=>{const{children:s,...i}=t;if(C.isValidElement(s)){const o=NE(s),a=kE(i,s.props);return s.type!==C.Fragment&&(a.ref=r?Oe.composeRefs(r,o):o),C.cloneElement(s,a)}return C.Children.count(s)>1?C.Children.only(null):null});return e.displayName=`${n}.SlotClone`,e}var CE=Symbol("radix.slottable");function TE(n){return C.isValidElement(n)&&typeof n.type=="function"&&"__radixId"in n.type&&n.type.__radixId===CE}function kE(n,e){const t={...e};for(const r in e){const s=n[r],i=e[r];/^on[A-Z]/.test(r)?s&&i?t[r]=(...a)=>{const u=i(...a);return s(...a),u}:s&&(t[r]=s):r==="style"?t[r]={...s,...i}:r==="className"&&(t[r]=[s,i].filter(Boolean).join(" "))}return{...n,...t}}function NE(n){var r,s;let e=(r=Object.getOwnPropertyDescriptor(n.props,"ref"))==null?void 0:r.get,t=e&&"isReactWarning"in e&&e.isReactWarning;return t?n.ref:(e=(s=Object.getOwnPropertyDescriptor(n,"ref"))==null?void 0:s.get,t=e&&"isReactWarning"in e&&e.isReactWarning,t?n.props.ref:n.props.ref||n.ref)}var IE=[" ","Enter","ArrowUp","ArrowDown"],RE=[" ","Enter"],Ar="Select",[Ni,Ii,OE]=kf.createCollection(Ar),[gn]=le.createContextScope(Ar,[OE,jt.createPopperScope]),Ri=jt.createPopperScope(),[LE,or]=gn(Ar),[ME,DE]=gn(Ar),Id=n=>{const{__scopeSelect:e,children:t,open:r,defaultOpen:s,onOpenChange:i,value:o,defaultValue:a,onValueChange:u,dir:c,name:h,autoComplete:g,disabled:d,required:m,form:v}=n,p=Ri(e),[y,E]=C.useState(null),[S,x]=C.useState(null),[N,_]=C.useState(!1),P=nc.useDirection(c),[I,te]=Qt.useControllableState({prop:r,defaultProp:s??!1,onChange:i,caller:Ar}),[ue,ie]=Qt.useControllableState({prop:o,defaultProp:a,onChange:u,caller:Ar}),b=C.useRef(null),M=y?v||!!y.closest("form"):!0,[A,$]=C.useState(new Set),V=Array.from(A).map(R=>R.props.value).join(";");return O.jsx(jt.Root2,{...p,children:O.jsxs(LE,{required:m,scope:e,trigger:y,onTriggerChange:E,valueNode:S,onValueNodeChange:x,valueNodeHasChildren:N,onValueNodeHasChildrenChange:_,contentId:Qt.useId(),value:ue,onValueChange:ie,open:I,onOpenChange:te,dir:P,triggerPointerDownPosRef:b,disabled:d,children:[O.jsx(Ni.Provider,{scope:e,children:O.jsx(ME,{scope:n.__scopeSelect,onNativeOptionAdd:C.useCallback(R=>{$(q=>new Set(q).add(R))},[]),onNativeOptionRemove:C.useCallback(R=>{$(q=>{const W=new Set(q);return W.delete(R),W})},[]),children:t})}),M?O.jsxs(tf,{"aria-hidden":!0,required:m,tabIndex:-1,name:h,autoComplete:g,value:ue,onChange:R=>ie(R.target.value),disabled:d,form:v,children:[ue===void 0?O.jsx("option",{value:""}):null,Array.from(A)]},V):null]})})};Id.displayName=Ar;var Rd="SelectTrigger",Od=C.forwardRef((n,e)=>{const{__scopeSelect:t,disabled:r=!1,...s}=n,i=Ri(t),o=or(Rd,t),a=o.disabled||r,u=Oe.useComposedRefs(e,o.onTriggerChange),c=Ii(t),h=C.useRef("touch"),[g,d,m]=nf(p=>{const y=c().filter(x=>!x.disabled),E=y.find(x=>x.value===o.value),S=sf(y,p,E);S!==void 0&&o.onValueChange(S.value)}),v=p=>{a||(o.onOpenChange(!0),m()),p&&(o.triggerPointerDownPosRef.current={x:Math.round(p.pageX),y:Math.round(p.pageY)})};return O.jsx(jt.Anchor,{asChild:!0,...i,children:O.jsx(le.Primitive.button,{type:"button",role:"combobox","aria-controls":o.contentId,"aria-expanded":o.open,"aria-required":o.required,"aria-autocomplete":"none",dir:o.dir,"data-state":o.open?"open":"closed",disabled:a,"data-disabled":a?"":void 0,"data-placeholder":rf(o.value)?"":void 0,...s,ref:u,onClick:le.composeEventHandlers(s.onClick,p=>{p.currentTarget.focus(),h.current!=="mouse"&&v(p)}),onPointerDown:le.composeEventHandlers(s.onPointerDown,p=>{h.current=p.pointerType;const y=p.target;y.hasPointerCapture(p.pointerId)&&y.releasePointerCapture(p.pointerId),p.button===0&&p.ctrlKey===!1&&p.pointerType==="mouse"&&(v(p),p.preventDefault())}),onKeyDown:le.composeEventHandlers(s.onKeyDown,p=>{const y=g.current!=="";!(p.ctrlKey||p.altKey||p.metaKey)&&p.key.length===1&&d(p.key),!(y&&p.key===" ")&&IE.includes(p.key)&&(v(),p.preventDefault())})})})});Od.displayName=Rd;var Ld="SelectValue",Md=C.forwardRef((n,e)=>{const{__scopeSelect:t,className:r,style:s,children:i,placeholder:o="",...a}=n,u=or(Ld,t),{onValueNodeHasChildrenChange:c}=u,h=i!==void 0,g=Oe.useComposedRefs(e,u.onValueNodeChange);return rr.useLayoutEffect2(()=>{c(h)},[c,h]),O.jsx(le.Primitive.span,{...a,ref:g,style:{pointerEvents:"none"},children:rf(u.value)?O.jsx(O.Fragment,{children:o}):i})});Md.displayName=Ld;var PE="SelectIcon",Dd=C.forwardRef((n,e)=>{const{__scopeSelect:t,children:r,...s}=n;return O.jsx(le.Primitive.span,{"aria-hidden":!0,...s,ref:e,children:r||"▼"})});Dd.displayName=PE;var BE="SelectPortal",Pd=n=>O.jsx(Te.Portal,{asChild:!0,...n});Pd.displayName=BE;var Cr="SelectContent",Bd=C.forwardRef((n,e)=>{const t=or(Cr,n.__scopeSelect),[r,s]=C.useState();if(rr.useLayoutEffect2(()=>{s(new DocumentFragment)},[]),!t.open){const i=r;return i?ac.createPortal(O.jsx(qd,{scope:n.__scopeSelect,children:O.jsx(Ni.Slot,{scope:n.__scopeSelect,children:O.jsx("div",{children:n.children})})}),i):null}return O.jsx(Fd,{...n,ref:e})});Bd.displayName=Cr;var ot=10,[qd,ar]=gn(Cr),qE="SelectContentImpl",FE=_E("SelectContent.RemoveScroll"),Fd=C.forwardRef((n,e)=>{const{__scopeSelect:t,position:r="item-aligned",onCloseAutoFocus:s,onEscapeKeyDown:i,onPointerDownOutside:o,side:a,sideOffset:u,align:c,alignOffset:h,arrowPadding:g,collisionBoundary:d,collisionPadding:m,sticky:v,hideWhenDetached:p,avoidCollisions:y,...E}=n,S=or(Cr,t),[x,N]=C.useState(null),[_,P]=C.useState(null),I=Oe.useComposedRefs(e,F=>N(F)),[te,ue]=C.useState(null),[ie,b]=C.useState(null),M=Ii(t),[A,$]=C.useState(!1),V=C.useRef(!1);C.useEffect(()=>{if(x)return Te.hideOthers(x)},[x]),Te.useFocusGuards();const R=C.useCallback(F=>{const[j,...Z]=M().map(k=>k.ref.current),[G]=Z.slice(-1),X=document.activeElement;for(const k of F)if(k===X||(k==null||k.scrollIntoView({block:"nearest"}),k===j&&_&&(_.scrollTop=0),k===G&&_&&(_.scrollTop=_.scrollHeight),k==null||k.focus(),document.activeElement!==X))return},[M,_]),q=C.useCallback(()=>R([te,x]),[R,te,x]);C.useEffect(()=>{A&&q()},[A,q]);const{onOpenChange:W,triggerPointerDownPosRef:Y}=S;C.useEffect(()=>{if(x){let F={x:0,y:0};const j=G=>{var X,k;F={x:Math.abs(Math.round(G.pageX)-(((X=Y.current)==null?void 0:X.x)??0)),y:Math.abs(Math.round(G.pageY)-(((k=Y.current)==null?void 0:k.y)??0))}},Z=G=>{F.x<=10&&F.y<=10?G.preventDefault():x.contains(G.target)||W(!1),document.removeEventListener("pointermove",j),Y.current=null};return Y.current!==null&&(document.addEventListener("pointermove",j),document.addEventListener("pointerup",Z,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",j),document.removeEventListener("pointerup",Z,{capture:!0})}}},[x,W,Y]),C.useEffect(()=>{const F=()=>W(!1);return window.addEventListener("blur",F),window.addEventListener("resize",F),()=>{window.removeEventListener("blur",F),window.removeEventListener("resize",F)}},[W]);const[T,D]=nf(F=>{const j=M().filter(X=>!X.disabled),Z=j.find(X=>X.ref.current===document.activeElement),G=sf(j,F,Z);G&&setTimeout(()=>G.ref.current.focus())}),U=C.useCallback((F,j,Z)=>{const G=!V.current&&!Z;(S.value!==void 0&&S.value===j||G)&&(ue(F),G&&(V.current=!0))},[S.value]),K=C.useCallback(()=>x==null?void 0:x.focus(),[x]),z=C.useCallback((F,j,Z)=>{const G=!V.current&&!Z;(S.value!==void 0&&S.value===j||G)&&b(F)},[S.value]),H=r==="popper"?Ca:jd,Q=H===Ca?{side:a,sideOffset:u,align:c,alignOffset:h,arrowPadding:g,collisionBoundary:d,collisionPadding:m,sticky:v,hideWhenDetached:p,avoidCollisions:y}:{};return O.jsx(qd,{scope:t,content:x,viewport:_,onViewportChange:P,itemRefCallback:U,selectedItem:te,onItemLeave:K,itemTextRefCallback:z,focusSelectedItem:q,selectedItemText:ie,position:r,isPositioned:A,searchRef:T,children:O.jsx(Te.ReactRemoveScroll,{as:FE,allowPinchZoom:!0,children:O.jsx(Te.FocusScope,{asChild:!0,trapped:S.open,onMountAutoFocus:F=>{F.preventDefault()},onUnmountAutoFocus:le.composeEventHandlers(s,F=>{var j;(j=S.trigger)==null||j.focus({preventScroll:!0}),F.preventDefault()}),children:O.jsx(Nf.DismissableLayer,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:i,onPointerDownOutside:o,onFocusOutside:F=>F.preventDefault(),onDismiss:()=>S.onOpenChange(!1),children:O.jsx(H,{role:"listbox",id:S.contentId,"data-state":S.open?"open":"closed",dir:S.dir,onContextMenu:F=>F.preventDefault(),...E,...Q,onPlaced:()=>$(!0),ref:I,style:{display:"flex",flexDirection:"column",outline:"none",...E.style},onKeyDown:le.composeEventHandlers(E.onKeyDown,F=>{const j=F.ctrlKey||F.altKey||F.metaKey;if(F.key==="Tab"&&F.preventDefault(),!j&&F.key.length===1&&D(F.key),["ArrowUp","ArrowDown","Home","End"].includes(F.key)){let G=M().filter(X=>!X.disabled).map(X=>X.ref.current);if(["ArrowUp","End"].includes(F.key)&&(G=G.slice().reverse()),["ArrowUp","ArrowDown"].includes(F.key)){const X=F.target,k=G.indexOf(X);G=G.slice(k+1)}setTimeout(()=>R(G)),F.preventDefault()}})})})})})})});Fd.displayName=qE;var jE="SelectItemAlignedPosition",jd=C.forwardRef((n,e)=>{const{__scopeSelect:t,onPlaced:r,...s}=n,i=or(Cr,t),o=ar(Cr,t),[a,u]=C.useState(null),[c,h]=C.useState(null),g=Oe.useComposedRefs(e,I=>h(I)),d=Ii(t),m=C.useRef(!1),v=C.useRef(!0),{viewport:p,selectedItem:y,selectedItemText:E,focusSelectedItem:S}=o,x=C.useCallback(()=>{if(i.trigger&&i.valueNode&&a&&c&&p&&y&&E){const I=i.trigger.getBoundingClientRect(),te=c.getBoundingClientRect(),ue=i.valueNode.getBoundingClientRect(),ie=E.getBoundingClientRect();if(i.dir!=="rtl"){const X=ie.left-te.left,k=ue.left-X,ce=I.left-k,ge=I.width+ce,be=Math.max(ge,te.width),kt=window.innerWidth-ot,Ut=gl.clamp(k,[ot,Math.max(ot,kt-be)]);a.style.minWidth=ge+"px",a.style.left=Ut+"px"}else{const X=te.right-ie.right,k=window.innerWidth-ue.right-X,ce=window.innerWidth-I.right-k,ge=I.width+ce,be=Math.max(ge,te.width),kt=window.innerWidth-ot,Ut=gl.clamp(k,[ot,Math.max(ot,kt-be)]);a.style.minWidth=ge+"px",a.style.right=Ut+"px"}const b=d(),M=window.innerHeight-ot*2,A=p.scrollHeight,$=window.getComputedStyle(c),V=parseInt($.borderTopWidth,10),R=parseInt($.paddingTop,10),q=parseInt($.borderBottomWidth,10),W=parseInt($.paddingBottom,10),Y=V+R+A+W+q,T=Math.min(y.offsetHeight*5,Y),D=window.getComputedStyle(p),U=parseInt(D.paddingTop,10),K=parseInt(D.paddingBottom,10),z=I.top+I.height/2-ot,H=M-z,Q=y.offsetHeight/2,F=y.offsetTop+Q,j=V+R+F,Z=Y-j;if(j<=z){const X=b.length>0&&y===b[b.length-1].ref.current;a.style.bottom="0px";const k=c.clientHeight-p.offsetTop-p.offsetHeight,ce=Math.max(H,Q+(X?K:0)+k+q),ge=j+ce;a.style.height=ge+"px"}else{const X=b.length>0&&y===b[0].ref.current;a.style.top="0px";const ce=Math.max(z,V+p.offsetTop+(X?U:0)+Q)+Z;a.style.height=ce+"px",p.scrollTop=j-z+p.offsetTop}a.style.margin=`${ot}px 0`,a.style.minHeight=T+"px",a.style.maxHeight=M+"px",r==null||r(),requestAnimationFrame(()=>m.current=!0)}},[d,i.trigger,i.valueNode,a,c,p,y,E,i.dir,r]);rr.useLayoutEffect2(()=>x(),[x]);const[N,_]=C.useState();rr.useLayoutEffect2(()=>{c&&_(window.getComputedStyle(c).zIndex)},[c]);const P=C.useCallback(I=>{I&&v.current===!0&&(x(),S==null||S(),v.current=!1)},[x,S]);return O.jsx(VE,{scope:t,contentWrapper:a,shouldExpandOnScrollRef:m,onScrollButtonChange:P,children:O.jsx("div",{ref:u,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:N},children:O.jsx(le.Primitive.div,{...s,ref:g,style:{boxSizing:"border-box",maxHeight:"100%",...s.style}})})})});jd.displayName=jE;var $E="SelectPopperPosition",Ca=C.forwardRef((n,e)=>{const{__scopeSelect:t,align:r="start",collisionPadding:s=ot,...i}=n,o=Ri(t);return O.jsx(jt.Content,{...o,...i,ref:e,align:r,collisionPadding:s,style:{boxSizing:"border-box",...i.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Ca.displayName=$E;var[VE,ul]=gn(Cr,{}),Ta="SelectViewport",$d=C.forwardRef((n,e)=>{const{__scopeSelect:t,nonce:r,...s}=n,i=ar(Ta,t),o=ul(Ta,t),a=Oe.useComposedRefs(e,i.onViewportChange),u=C.useRef(0);return O.jsxs(O.Fragment,{children:[O.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),O.jsx(Ni.Slot,{scope:t,children:O.jsx(le.Primitive.div,{"data-radix-select-viewport":"",role:"presentation",...s,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...s.style},onScroll:le.composeEventHandlers(s.onScroll,c=>{const h=c.currentTarget,{contentWrapper:g,shouldExpandOnScrollRef:d}=o;if(d!=null&&d.current&&g){const m=Math.abs(u.current-h.scrollTop);if(m>0){const v=window.innerHeight-ot*2,p=parseFloat(g.style.minHeight),y=parseFloat(g.style.height),E=Math.max(p,y);if(E<v){const S=E+m,x=Math.min(v,S),N=S-x;g.style.height=x+"px",g.style.bottom==="0px"&&(h.scrollTop=N>0?N:0,g.style.justifyContent="flex-end")}}}u.current=h.scrollTop})})})]})});$d.displayName=Ta;var Vd="SelectGroup",[UE,HE]=gn(Vd),Ud=C.forwardRef((n,e)=>{const{__scopeSelect:t,...r}=n,s=Qt.useId();return O.jsx(UE,{scope:t,id:s,children:O.jsx(le.Primitive.div,{role:"group","aria-labelledby":s,...r,ref:e})})});Ud.displayName=Vd;var Hd="SelectLabel",zd=C.forwardRef((n,e)=>{const{__scopeSelect:t,...r}=n,s=HE(Hd,t);return O.jsx(le.Primitive.div,{id:s.id,...r,ref:e})});zd.displayName=Hd;var si="SelectItem",[zE,Gd]=gn(si),Kd=C.forwardRef((n,e)=>{const{__scopeSelect:t,value:r,disabled:s=!1,textValue:i,...o}=n,a=or(si,t),u=ar(si,t),c=a.value===r,[h,g]=C.useState(i??""),[d,m]=C.useState(!1),v=Oe.useComposedRefs(e,S=>{var x;return(x=u.itemRefCallback)==null?void 0:x.call(u,S,r,s)}),p=Qt.useId(),y=C.useRef("touch"),E=()=>{s||(a.onValueChange(r),a.onOpenChange(!1))};if(r==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return O.jsx(zE,{scope:t,value:r,disabled:s,textId:p,isSelected:c,onItemTextChange:C.useCallback(S=>{g(x=>x||((S==null?void 0:S.textContent)??"").trim())},[]),children:O.jsx(Ni.ItemSlot,{scope:t,value:r,disabled:s,textValue:h,children:O.jsx(le.Primitive.div,{role:"option","aria-labelledby":p,"data-highlighted":d?"":void 0,"aria-selected":c&&d,"data-state":c?"checked":"unchecked","aria-disabled":s||void 0,"data-disabled":s?"":void 0,tabIndex:s?void 0:-1,...o,ref:v,onFocus:le.composeEventHandlers(o.onFocus,()=>m(!0)),onBlur:le.composeEventHandlers(o.onBlur,()=>m(!1)),onClick:le.composeEventHandlers(o.onClick,()=>{y.current!=="mouse"&&E()}),onPointerUp:le.composeEventHandlers(o.onPointerUp,()=>{y.current==="mouse"&&E()}),onPointerDown:le.composeEventHandlers(o.onPointerDown,S=>{y.current=S.pointerType}),onPointerMove:le.composeEventHandlers(o.onPointerMove,S=>{var x;y.current=S.pointerType,s?(x=u.onItemLeave)==null||x.call(u):y.current==="mouse"&&S.currentTarget.focus({preventScroll:!0})}),onPointerLeave:le.composeEventHandlers(o.onPointerLeave,S=>{var x;S.currentTarget===document.activeElement&&((x=u.onItemLeave)==null||x.call(u))}),onKeyDown:le.composeEventHandlers(o.onKeyDown,S=>{var N;((N=u.searchRef)==null?void 0:N.current)!==""&&S.key===" "||(RE.includes(S.key)&&E(),S.key===" "&&S.preventDefault())})})})})});Kd.displayName=si;var qn="SelectItemText",Wd=C.forwardRef((n,e)=>{const{__scopeSelect:t,className:r,style:s,...i}=n,o=or(qn,t),a=ar(qn,t),u=Gd(qn,t),c=DE(qn,t),[h,g]=C.useState(null),d=Oe.useComposedRefs(e,E=>g(E),u.onItemTextChange,E=>{var S;return(S=a.itemTextRefCallback)==null?void 0:S.call(a,E,u.value,u.disabled)}),m=h==null?void 0:h.textContent,v=C.useMemo(()=>O.jsx("option",{value:u.value,disabled:u.disabled,children:m},u.value),[u.disabled,u.value,m]),{onNativeOptionAdd:p,onNativeOptionRemove:y}=c;return rr.useLayoutEffect2(()=>(p(v),()=>y(v)),[p,y,v]),O.jsxs(O.Fragment,{children:[O.jsx(le.Primitive.span,{id:u.textId,...i,ref:d}),u.isSelected&&o.valueNode&&!o.valueNodeHasChildren?ac.createPortal(i.children,o.valueNode):null]})});Wd.displayName=qn;var Yd="SelectItemIndicator",Zd=C.forwardRef((n,e)=>{const{__scopeSelect:t,...r}=n;return Gd(Yd,t).isSelected?O.jsx(le.Primitive.span,{"aria-hidden":!0,...r,ref:e}):null});Zd.displayName=Yd;var ka="SelectScrollUpButton",Xd=C.forwardRef((n,e)=>{const t=ar(ka,n.__scopeSelect),r=ul(ka,n.__scopeSelect),[s,i]=C.useState(!1),o=Oe.useComposedRefs(e,r.onScrollButtonChange);return rr.useLayoutEffect2(()=>{if(t.viewport&&t.isPositioned){let a=function(){const c=u.scrollTop>0;i(c)};const u=t.viewport;return a(),u.addEventListener("scroll",a),()=>u.removeEventListener("scroll",a)}},[t.viewport,t.isPositioned]),s?O.jsx(Jd,{...n,ref:o,onAutoScroll:()=>{const{viewport:a,selectedItem:u}=t;a&&u&&(a.scrollTop=a.scrollTop-u.offsetHeight)}}):null});Xd.displayName=ka;var Na="SelectScrollDownButton",Qd=C.forwardRef((n,e)=>{const t=ar(Na,n.__scopeSelect),r=ul(Na,n.__scopeSelect),[s,i]=C.useState(!1),o=Oe.useComposedRefs(e,r.onScrollButtonChange);return rr.useLayoutEffect2(()=>{if(t.viewport&&t.isPositioned){let a=function(){const c=u.scrollHeight-u.clientHeight,h=Math.ceil(u.scrollTop)<c;i(h)};const u=t.viewport;return a(),u.addEventListener("scroll",a),()=>u.removeEventListener("scroll",a)}},[t.viewport,t.isPositioned]),s?O.jsx(Jd,{...n,ref:o,onAutoScroll:()=>{const{viewport:a,selectedItem:u}=t;a&&u&&(a.scrollTop=a.scrollTop+u.offsetHeight)}}):null});Qd.displayName=Na;var Jd=C.forwardRef((n,e)=>{const{__scopeSelect:t,onAutoScroll:r,...s}=n,i=ar("SelectScrollButton",t),o=C.useRef(null),a=Ii(t),u=C.useCallback(()=>{o.current!==null&&(window.clearInterval(o.current),o.current=null)},[]);return C.useEffect(()=>()=>u(),[u]),rr.useLayoutEffect2(()=>{var h;const c=a().find(g=>g.ref.current===document.activeElement);(h=c==null?void 0:c.ref.current)==null||h.scrollIntoView({block:"nearest"})},[a]),O.jsx(le.Primitive.div,{"aria-hidden":!0,...s,ref:e,style:{flexShrink:0,...s.style},onPointerDown:le.composeEventHandlers(s.onPointerDown,()=>{o.current===null&&(o.current=window.setInterval(r,50))}),onPointerMove:le.composeEventHandlers(s.onPointerMove,()=>{var c;(c=i.onItemLeave)==null||c.call(i),o.current===null&&(o.current=window.setInterval(r,50))}),onPointerLeave:le.composeEventHandlers(s.onPointerLeave,()=>{u()})})}),GE="SelectSeparator",ef=C.forwardRef((n,e)=>{const{__scopeSelect:t,...r}=n;return O.jsx(le.Primitive.div,{"aria-hidden":!0,...r,ref:e})});ef.displayName=GE;var Ia="SelectArrow",KE=C.forwardRef((n,e)=>{const{__scopeSelect:t,...r}=n,s=Ri(t),i=or(Ia,t),o=ar(Ia,t);return i.open&&o.position==="popper"?O.jsx(jt.Arrow,{...s,...r,ref:e}):null});KE.displayName=Ia;var WE="SelectBubbleInput",tf=C.forwardRef(({__scopeSelect:n,value:e,...t},r)=>{const s=C.useRef(null),i=Oe.useComposedRefs(r,s),o=oi(e);return C.useEffect(()=>{const a=s.current;if(!a)return;const u=window.HTMLSelectElement.prototype,h=Object.getOwnPropertyDescriptor(u,"value").set;if(o!==e&&h){const g=new Event("change",{bubbles:!0});h.call(a,e),a.dispatchEvent(g)}},[o,e]),O.jsx(le.Primitive.select,{...t,style:{...Rf.VISUALLY_HIDDEN_STYLES,...t.style},ref:i,defaultValue:e})});tf.displayName=WE;function rf(n){return n===""||n===void 0}function nf(n){const e=If.useCallbackRef(n),t=C.useRef(""),r=C.useRef(0),s=C.useCallback(o=>{const a=t.current+o;e(a),(function u(c){t.current=c,window.clearTimeout(r.current),c!==""&&(r.current=window.setTimeout(()=>u(""),1e3))})(a)},[e]),i=C.useCallback(()=>{t.current="",window.clearTimeout(r.current)},[]);return C.useEffect(()=>()=>window.clearTimeout(r.current),[]),[t,s,i]}function sf(n,e,t){const s=e.length>1&&Array.from(e).every(c=>c===e[0])?e[0]:e,i=t?n.indexOf(t):-1;let o=YE(n,Math.max(i,0));s.length===1&&(o=o.filter(c=>c!==t));const u=o.find(c=>c.textValue.toLowerCase().startsWith(s.toLowerCase()));return u!==t?u:void 0}function YE(n,e){return n.map((t,r)=>n[(e+r)%n.length])}var ZE=Id,of=Od,XE=Md,QE=Dd,JE=Pd,af=Bd,ew=$d,tw=Ud,lf=zd,uf=Kd,rw=Wd,nw=Zd,cf=Xd,hf=Qd,df=ef;function sw(n,e){n.prototype=Object.create(e.prototype),n.prototype.constructor=n,De._setPrototypeOf(n,e)}var Xu=Number.isNaN||function(e){return typeof e=="number"&&e!==e};function iw(n,e){return!!(n===e||Xu(n)&&Xu(e))}function ow(n,e){if(n.length!==e.length)return!1;for(var t=0;t<n.length;t++)if(!iw(n[t],e[t]))return!1;return!0}function Go(n,e){e===void 0&&(e=ow);var t,r=[],s,i=!1;function o(){for(var a=[],u=0;u<arguments.length;u++)a[u]=arguments[u];return i&&t===this&&e(a,r)||(s=n.apply(this,a),i=!0,t=this,r=a),s}return o}var aw=typeof performance=="object"&&typeof performance.now=="function",Qu=aw?function(){return performance.now()}:function(){return Date.now()};function Ju(n){cancelAnimationFrame(n.id)}function lw(n,e){var t=Qu();function r(){Qu()-t>=e?n.call(null):s.id=requestAnimationFrame(r)}var s={id:requestAnimationFrame(r)};return s}var Ko=-1;function ec(n){if(n===void 0&&(n=!1),Ko===-1||n){var e=document.createElement("div"),t=e.style;t.width="50px",t.height="50px",t.overflow="scroll",document.body.appendChild(e),Ko=e.offsetWidth-e.clientWidth,document.body.removeChild(e)}return Ko}var zr=null;function tc(n){if(n===void 0&&(n=!1),zr===null||n){var e=document.createElement("div"),t=e.style;t.width="50px",t.height="50px",t.overflow="scroll",t.direction="rtl";var r=document.createElement("div"),s=r.style;return s.width="100px",s.height="100px",e.appendChild(r),document.body.appendChild(e),e.scrollLeft>0?zr="positive-descending":(e.scrollLeft=1,e.scrollLeft===0?zr="negative":zr="positive-ascending"),document.body.removeChild(e),zr}return zr}process.env.NODE_ENV;var uw=150,cw=function(e,t){return e},Gs=null,Ks=null;process.env.NODE_ENV!=="production"&&typeof window<"u"&&typeof window.WeakSet<"u"&&(Gs=new WeakSet,Ks=new WeakSet);function hw(n){var e,t=n.getItemOffset,r=n.getEstimatedTotalSize,s=n.getItemSize,i=n.getOffsetForIndexAndAlignment,o=n.getStartIndexForOffset,a=n.getStopIndexForStartIndex,u=n.initInstanceProps,c=n.shouldResetStyleCacheOnItemSizeChange,h=n.validateProps;return e=(function(g){sw(d,g);function d(v){var p;return p=g.call(this,v)||this,p._instanceProps=u(p.props,De._assertThisInitialized(p)),p._outerRef=void 0,p._resetIsScrollingTimeoutId=null,p.state={instance:De._assertThisInitialized(p),isScrolling:!1,scrollDirection:"forward",scrollOffset:typeof p.props.initialScrollOffset=="number"?p.props.initialScrollOffset:0,scrollUpdateWasRequested:!1},p._callOnItemsRendered=void 0,p._callOnItemsRendered=Go(function(y,E,S,x){return p.props.onItemsRendered({overscanStartIndex:y,overscanStopIndex:E,visibleStartIndex:S,visibleStopIndex:x})}),p._callOnScroll=void 0,p._callOnScroll=Go(function(y,E,S){return p.props.onScroll({scrollDirection:y,scrollOffset:E,scrollUpdateWasRequested:S})}),p._getItemStyle=void 0,p._getItemStyle=function(y){var E=p.props,S=E.direction,x=E.itemSize,N=E.layout,_=p._getItemStyleCache(c&&x,c&&N,c&&S),P;if(_.hasOwnProperty(y))P=_[y];else{var I=t(p.props,y,p._instanceProps),te=s(p.props,y,p._instanceProps),ue=S==="horizontal"||N==="horizontal",ie=S==="rtl",b=ue?I:0;_[y]=P={position:"absolute",left:ie?void 0:b,right:ie?b:void 0,top:ue?0:I,height:ue?"100%":te,width:ue?te:"100%"}}return P},p._getItemStyleCache=void 0,p._getItemStyleCache=Go(function(y,E,S){return{}}),p._onScrollHorizontal=function(y){var E=y.currentTarget,S=E.clientWidth,x=E.scrollLeft,N=E.scrollWidth;p.setState(function(_){if(_.scrollOffset===x)return null;var P=p.props.direction,I=x;if(P==="rtl")switch(tc()){case"negative":I=-x;break;case"positive-descending":I=N-S-x;break}return I=Math.max(0,Math.min(I,N-S)),{isScrolling:!0,scrollDirection:_.scrollOffset<I?"forward":"backward",scrollOffset:I,scrollUpdateWasRequested:!1}},p._resetIsScrollingDebounced)},p._onScrollVertical=function(y){var E=y.currentTarget,S=E.clientHeight,x=E.scrollHeight,N=E.scrollTop;p.setState(function(_){if(_.scrollOffset===N)return null;var P=Math.max(0,Math.min(N,x-S));return{isScrolling:!0,scrollDirection:_.scrollOffset<P?"forward":"backward",scrollOffset:P,scrollUpdateWasRequested:!1}},p._resetIsScrollingDebounced)},p._outerRefSetter=function(y){var E=p.props.outerRef;p._outerRef=y,typeof E=="function"?E(y):E!=null&&typeof E=="object"&&E.hasOwnProperty("current")&&(E.current=y)},p._resetIsScrollingDebounced=function(){p._resetIsScrollingTimeoutId!==null&&Ju(p._resetIsScrollingTimeoutId),p._resetIsScrollingTimeoutId=lw(p._resetIsScrolling,uw)},p._resetIsScrolling=function(){p._resetIsScrollingTimeoutId=null,p.setState({isScrolling:!1},function(){p._getItemStyleCache(-1,null)})},p}d.getDerivedStateFromProps=function(p,y){return dw(p,y),h(p),null};var m=d.prototype;return m.scrollTo=function(p){p=Math.max(0,p),this.setState(function(y){return y.scrollOffset===p?null:{scrollDirection:y.scrollOffset<p?"forward":"backward",scrollOffset:p,scrollUpdateWasRequested:!0}},this._resetIsScrollingDebounced)},m.scrollToItem=function(p,y){y===void 0&&(y="auto");var E=this.props,S=E.itemCount,x=E.layout,N=this.state.scrollOffset;p=Math.max(0,Math.min(p,S-1));var _=0;if(this._outerRef){var P=this._outerRef;x==="vertical"?_=P.scrollWidth>P.clientWidth?ec():0:_=P.scrollHeight>P.clientHeight?ec():0}this.scrollTo(i(this.props,p,y,N,this._instanceProps,_))},m.componentDidMount=function(){var p=this.props,y=p.direction,E=p.initialScrollOffset,S=p.layout;if(typeof E=="number"&&this._outerRef!=null){var x=this._outerRef;y==="horizontal"||S==="horizontal"?x.scrollLeft=E:x.scrollTop=E}this._callPropsCallbacks()},m.componentDidUpdate=function(){var p=this.props,y=p.direction,E=p.layout,S=this.state,x=S.scrollOffset,N=S.scrollUpdateWasRequested;if(N&&this._outerRef!=null){var _=this._outerRef;if(y==="horizontal"||E==="horizontal")if(y==="rtl")switch(tc()){case"negative":_.scrollLeft=-x;break;case"positive-ascending":_.scrollLeft=x;break;default:var P=_.clientWidth,I=_.scrollWidth;_.scrollLeft=I-P-x;break}else _.scrollLeft=x;else _.scrollTop=x}this._callPropsCallbacks()},m.componentWillUnmount=function(){this._resetIsScrollingTimeoutId!==null&&Ju(this._resetIsScrollingTimeoutId)},m.render=function(){var p=this.props,y=p.children,E=p.className,S=p.direction,x=p.height,N=p.innerRef,_=p.innerElementType,P=p.innerTagName,I=p.itemCount,te=p.itemData,ue=p.itemKey,ie=ue===void 0?cw:ue,b=p.layout,M=p.outerElementType,A=p.outerTagName,$=p.style,V=p.useIsScrolling,R=p.width,q=this.state.isScrolling,W=S==="horizontal"||b==="horizontal",Y=W?this._onScrollHorizontal:this._onScrollVertical,T=this._getRangeToRender(),D=T[0],U=T[1],K=[];if(I>0)for(var z=D;z<=U;z++)K.push(We.createElement(y,{data:te,key:ie(z,te),index:z,isScrolling:V?q:void 0,style:this._getItemStyle(z)}));var H=r(this.props,this._instanceProps);return We.createElement(M||A||"div",{className:E,onScroll:Y,ref:this._outerRefSetter,style:De._extends({position:"relative",height:x,width:R,overflow:"auto",WebkitOverflowScrolling:"touch",willChange:"transform",direction:S},$)},We.createElement(_||P||"div",{children:K,ref:N,style:{height:W?"100%":H,pointerEvents:q?"none":void 0,width:W?H:"100%"}}))},m._callPropsCallbacks=function(){if(typeof this.props.onItemsRendered=="function"){var p=this.props.itemCount;if(p>0){var y=this._getRangeToRender(),E=y[0],S=y[1],x=y[2],N=y[3];this._callOnItemsRendered(E,S,x,N)}}if(typeof this.props.onScroll=="function"){var _=this.state,P=_.scrollDirection,I=_.scrollOffset,te=_.scrollUpdateWasRequested;this._callOnScroll(P,I,te)}},m._getRangeToRender=function(){var p=this.props,y=p.itemCount,E=p.overscanCount,S=this.state,x=S.isScrolling,N=S.scrollDirection,_=S.scrollOffset;if(y===0)return[0,0,0,0];var P=o(this.props,_,this._instanceProps),I=a(this.props,P,_,this._instanceProps),te=!x||N==="backward"?Math.max(1,E):1,ue=!x||N==="forward"?Math.max(1,E):1;return[Math.max(0,P-te),Math.max(0,Math.min(y-1,I+ue)),P,I]},d})(We.PureComponent),e.defaultProps={direction:"ltr",itemData:void 0,layout:"vertical",overscanCount:2,useIsScrolling:!1},e}var dw=function(e,t){var r=e.children,s=e.direction,i=e.height,o=e.layout,a=e.innerTagName,u=e.outerTagName,c=e.width,h=t.instance;if(process.env.NODE_ENV!=="production"){(a!=null||u!=null)&&Ks&&!Ks.has(h)&&(Ks.add(h),console.warn("The innerTagName and outerTagName props have been deprecated. Please use the innerElementType and outerElementType props instead."));var g=s==="horizontal"||o==="horizontal";switch(s){case"horizontal":case"vertical":Gs&&!Gs.has(h)&&(Gs.add(h),console.warn('The direction prop should be either "ltr" (default) or "rtl". Please use the layout prop to specify "vertical" (default) or "horizontal" orientation.'));break;case"ltr":case"rtl":break;default:throw Error('An invalid "direction" prop has been specified. Value should be either "ltr" or "rtl". '+('"'+s+'" was specified.'))}switch(o){case"horizontal":case"vertical":break;default:throw Error('An invalid "layout" prop has been specified. Value should be either "horizontal" or "vertical". '+('"'+o+'" was specified.'))}if(r==null)throw Error('An invalid "children" prop has been specified. Value should be a React component. '+('"'+(r===null?"null":typeof r)+'" was specified.'));if(g&&typeof c!="number")throw Error('An invalid "width" prop has been specified. Horizontal lists must specify a number for width. '+('"'+(c===null?"null":typeof c)+'" was specified.'));if(!g&&typeof i!="number")throw Error('An invalid "height" prop has been specified. Vertical lists must specify a number for height. '+('"'+(i===null?"null":typeof i)+'" was specified.'))}},fw=hw({getItemOffset:function(e,t){var r=e.itemSize;return t*r},getItemSize:function(e,t){var r=e.itemSize;return r},getEstimatedTotalSize:function(e){var t=e.itemCount,r=e.itemSize;return r*t},getOffsetForIndexAndAlignment:function(e,t,r,s,i,o){var a=e.direction,u=e.height,c=e.itemCount,h=e.itemSize,g=e.layout,d=e.width,m=a==="horizontal"||g==="horizontal",v=m?d:u,p=Math.max(0,c*h-v),y=Math.min(p,t*h),E=Math.max(0,t*h-v+h+o);switch(r==="smart"&&(s>=E-v&&s<=y+v?r="auto":r="center"),r){case"start":return y;case"end":return E;case"center":{var S=Math.round(E+(y-E)/2);return S<Math.ceil(v/2)?0:S>p+Math.floor(v/2)?p:S}case"auto":default:return s>=E&&s<=y?s:s<E?E:y}},getStartIndexForOffset:function(e,t){var r=e.itemCount,s=e.itemSize;return Math.max(0,Math.min(r-1,Math.floor(t/s)))},getStopIndexForStartIndex:function(e,t,r){var s=e.direction,i=e.height,o=e.itemCount,a=e.itemSize,u=e.layout,c=e.width,h=s==="horizontal"||u==="horizontal",g=t*a,d=h?c:i,m=Math.ceil((d+r-g)/a);return Math.max(0,Math.min(o-1,t+m-1))},initInstanceProps:function(e){},shouldResetStyleCacheOnItemSizeChange:!0,validateProps:function(e){var t=e.itemSize;if(process.env.NODE_ENV!=="production"&&typeof t!="number")throw Error('An invalid "itemSize" prop has been specified. Value should be a number. '+('"'+(t===null?"null":typeof t)+'" was specified.'))}});const pw=ZE,gw=tw,mw=XE,ff=C.forwardRef(({className:n,children:e,variant:t="default",...r},s)=>O.jsxs(of,{ref:s,className:Ce.cn("border-border ring-offset-background placeholder:text-muted-foreground focus:ring-offset-none focus:ring-primary flex h-10 w-full items-center justify-between rounded-md border bg-white px-3 py-2 text-sm focus:ring-2 focus:ring-offset-transparent focus:outline-none disabled:cursor-not-allowed disabled:opacity-50 dark:bg-transparent [&>span]:line-clamp-1",t==="failure"&&"focus:ring-destructive hover:bg-destructive/20 bg-destructive/20 border-destructive !text-destructive",n),...r,children:[e,O.jsx(QE,{asChild:!0,children:O.jsx(ic.ChevronDown,{className:"h-4 w-4 opacity-50"})})]}));ff.displayName=of.displayName;const cl=C.forwardRef(({className:n,...e},t)=>O.jsx(cf,{ref:t,className:Ce.cn("flex cursor-default items-center justify-center py-1",n),...e,children:O.jsx(Df,{className:"h-4 w-4"})}));cl.displayName=cf.displayName;const hl=C.forwardRef(({className:n,...e},t)=>O.jsx(hf,{ref:t,className:Ce.cn("flex cursor-default items-center justify-center py-1",n),...e,children:O.jsx(ic.ChevronDown,{className:"h-4 w-4"})}));hl.displayName=hf.displayName;const dl=C.forwardRef(({className:n,children:e,position:t="popper",...r},s)=>O.jsx(JE,{children:O.jsxs(af,{ref:s,className:Ce.cn("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border shadow-md",t==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",n),position:t,...r,children:[O.jsx(cl,{}),O.jsx(ew,{className:Ce.cn("p-1",t==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:e}),O.jsx(hl,{})]})}));dl.displayName=af.displayName;const pf=C.forwardRef(({className:n,...e},t)=>O.jsx(lf,{ref:t,className:Ce.cn("py-1.5 pr-2 pl-8 text-sm font-semibold",n),...e}));pf.displayName=lf.displayName;const fl=C.forwardRef(({className:n,children:e,...t},r)=>O.jsxs(uf,{ref:r,className:Ce.cn("focus:bg-accent focus:text-accent-foreground relative flex w-full cursor-default items-center rounded-sm py-1.5 pr-2 pl-8 text-sm outline-none select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50",n),...t,children:[O.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:O.jsx(nw,{children:O.jsx(sc.Check,{className:"h-4 w-4"})})}),O.jsx(rw,{children:e})]}));fl.displayName=uf.displayName;const gf=C.forwardRef(({className:n,...e},t)=>O.jsx(df,{ref:t,className:Ce.cn("bg-muted -mx-1 my-1 h-px",n),...e}));gf.displayName=df.displayName;const mf=C.forwardRef(({className:n,options:e,position:t="popper",itemHeight:r=35,maxHeight:s=300,...i},o)=>{const a=We.useRef(null),u=({index:c,style:h})=>{const g=e[c];return O.jsx("div",{style:h,children:O.jsx(fl,{value:`${g.value}`,children:g.label})})};return O.jsx(dl,{ref:o,...i,children:O.jsx(fw,{ref:a,height:Math.min(s,e.length*r),itemCount:e.length,itemSize:r,width:"100%",children:u})})});mf.displayName="VirtualizedSelectContent";var Oi="Switch",[vw]=le.createContextScope(Oi),[yw,bw]=vw(Oi),vf=C.forwardRef((n,e)=>{const{__scopeSwitch:t,name:r,checked:s,defaultChecked:i,required:o,disabled:a,value:u="on",onCheckedChange:c,form:h,...g}=n,[d,m]=C.useState(null),v=Oe.useComposedRefs(e,x=>m(x)),p=C.useRef(!1),y=d?h||!!d.closest("form"):!0,[E,S]=Qt.useControllableState({prop:s,defaultProp:i??!1,onChange:c,caller:Oi});return O.jsxs(yw,{scope:t,checked:E,disabled:a,children:[O.jsx(le.Primitive.button,{type:"button",role:"switch","aria-checked":E,"aria-required":o,"data-state":wf(E),"data-disabled":a?"":void 0,disabled:a,value:u,...g,ref:v,onClick:le.composeEventHandlers(n.onClick,x=>{S(N=>!N),y&&(p.current=x.isPropagationStopped(),p.current||x.stopPropagation())})}),y&&O.jsx(Ef,{control:d,bubbles:!p.current,name:r,value:u,checked:E,required:o,disabled:a,form:h,style:{transform:"translateX(-100%)"}})]})});vf.displayName=Oi;var yf="SwitchThumb",bf=C.forwardRef((n,e)=>{const{__scopeSwitch:t,...r}=n,s=bw(yf,t);return O.jsx(le.Primitive.span,{"data-state":wf(s.checked),"data-disabled":s.disabled?"":void 0,...r,ref:e})});bf.displayName=yf;var Ew="SwitchBubbleInput",Ef=C.forwardRef(({__scopeSwitch:n,control:e,checked:t,bubbles:r=!0,...s},i)=>{const o=C.useRef(null),a=Oe.useComposedRefs(o,i),u=oi(t),c=jt.useSize(e);return C.useEffect(()=>{const h=o.current;if(!h)return;const g=window.HTMLInputElement.prototype,m=Object.getOwnPropertyDescriptor(g,"checked").set;if(u!==t&&m){const v=new Event("click",{bubbles:r});m.call(h,t),h.dispatchEvent(v)}},[u,t,r]),O.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:t,...s,tabIndex:-1,ref:a,style:{...s.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});Ef.displayName=Ew;function wf(n){return n?"checked":"unchecked"}var xf=vf,ww=bf;const Sf=C.forwardRef(({className:n,...e},t)=>O.jsx(xf,{className:Ce.cn("peer focus-visible:ring-ring focus-visible:ring-offset-background data-[state=checked]:bg-item-primary data-[state=unchecked]:bg-input inline-flex h-4 w-7 shrink-0 cursor-pointer items-center rounded-full border border-transparent transition-colors focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none disabled:cursor-not-allowed disabled:opacity-40",n),...e,ref:t,children:O.jsx(ww,{className:Ce.cn("bg-background pointer-events-none block size-3.5 rounded-full shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-3 data-[state=unchecked]:translate-x-0")})}));Sf.displayName=xf.displayName;const _f=C.forwardRef(({className:n,variant:e,...t},r)=>O.jsx("textarea",{className:Ce.cn("min-h-20 px-3 py-2",Si({variant:e}),n),ref:r,...t}));_f.displayName="Textarea";exports.Checkbox=gc;exports.FilepondContainer=Fc;exports.Form=Xp;exports.FormControl=Gc;exports.FormDescription=Kc;exports.FormField=Qp;exports.FormItem=Hc;exports.FormLabel=zc;exports.FormMessage=Wc;exports.HtmlEditor=td;exports.Input=rd;exports.Label=$a;exports.MaskInput=fd;exports.RadioGroup=kd;exports.RadioGroupItem=Nd;exports.Select=pw;exports.SelectContent=dl;exports.SelectGroup=gw;exports.SelectItem=fl;exports.SelectLabel=pf;exports.SelectScrollDownButton=hl;exports.SelectScrollUpButton=cl;exports.SelectSeparator=gf;exports.SelectTrigger=ff;exports.SelectValue=mw;exports.Switch=Sf;exports.Textarea=_f;exports.VirtualizedSelectContent=mf;exports.inputVariants=Si;exports.useFormField=Jn;
186
- //# sourceMappingURL=textarea-C2I19p_j.cjs.js.map