@opencx/widget 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (125) hide show
  1. package/README.md +105 -0
  2. package/dist/basic.cjs +259 -0
  3. package/dist/basic.cjs.map +1 -0
  4. package/dist/basic.d.ts +2 -0
  5. package/dist/basic.js +40507 -0
  6. package/dist/basic.js.map +1 -0
  7. package/dist/core/client/api.d.ts +15 -0
  8. package/dist/core/client/client.d.ts +39 -0
  9. package/dist/core/client/index.d.ts +1 -0
  10. package/dist/core/errors/index.d.ts +21 -0
  11. package/dist/core/index.d.ts +3 -0
  12. package/dist/core/managers/chathistory-manager.d.ts +61 -0
  13. package/dist/core/managers/session-manager.d.ts +35 -0
  14. package/dist/core/platform/index.d.ts +20 -0
  15. package/dist/core/transport/http.transport.d.ts +17 -0
  16. package/dist/core/transport/transport.d.ts +25 -0
  17. package/dist/core/types/helpers.d.ts +5 -0
  18. package/dist/core/types/index.d.ts +32 -0
  19. package/dist/core/types/messages.d.ts +43 -0
  20. package/dist/core/types/prelude.d.ts +14 -0
  21. package/dist/core/types/pub-sub.d.ts +94 -0
  22. package/dist/core/types/schemas.d.ts +489 -0
  23. package/dist/core/types/transport.d.ts +31 -0
  24. package/dist/core/utils/genId.d.ts +2 -0
  25. package/dist/core/utils/genId.test.d.ts +1 -0
  26. package/dist/core/utils/history-to-widget-messages.d.ts +4 -0
  27. package/dist/history-to-widget-messages-CP0hKjhv.js +195 -0
  28. package/dist/history-to-widget-messages-CP0hKjhv.js.map +1 -0
  29. package/dist/history-to-widget-messages-CdbZolRN.cjs +2 -0
  30. package/dist/history-to-widget-messages-CdbZolRN.cjs.map +1 -0
  31. package/dist/index-C11ivBh5.js +2604 -0
  32. package/dist/index-C11ivBh5.js.map +1 -0
  33. package/dist/index-DQmRZV3b.cjs +18 -0
  34. package/dist/index-DQmRZV3b.cjs.map +1 -0
  35. package/dist/index.cjs +2 -0
  36. package/dist/index.cjs.map +1 -0
  37. package/dist/index.d.ts +2 -0
  38. package/dist/index.js +445 -0
  39. package/dist/index.js.map +1 -0
  40. package/dist/react-lib/Root.d.ts +6 -0
  41. package/dist/react-lib/hooks/handle-socket-messages.d.ts +27 -0
  42. package/dist/react-lib/hooks/index.d.ts +6 -0
  43. package/dist/react-lib/hooks/socket.d.ts +11 -0
  44. package/dist/react-lib/hooks/socketState.d.ts +2 -0
  45. package/dist/react-lib/hooks/use-sound.d.ts +13 -0
  46. package/dist/react-lib/hooks/use-sound.test.d.ts +1 -0
  47. package/dist/react-lib/hooks/use-sync-state.test.d.ts +1 -0
  48. package/dist/react-lib/hooks/useAbstractChat.d.ts +159 -0
  49. package/dist/react-lib/hooks/useAxiosInstance.d.ts +121 -0
  50. package/dist/react-lib/hooks/useBaseClient.d.ts +2 -0
  51. package/dist/react-lib/hooks/useScrollTo.d.ts +2 -0
  52. package/dist/react-lib/hooks/useSyncState.d.ts +4 -0
  53. package/dist/react-lib/hooks/useTimeoutState.d.ts +3 -0
  54. package/dist/react-lib/hooks/useUploadFiles.d.ts +21 -0
  55. package/dist/react-lib/hooks/useVote.d.ts +2 -0
  56. package/dist/react-lib/hooks/useWidgetContentHeight.d.ts +9 -0
  57. package/dist/react-lib/index.d.ts +10 -0
  58. package/dist/react-lib/locales/ar.locale.d.ts +2 -0
  59. package/dist/react-lib/locales/de.locale.d.ts +2 -0
  60. package/dist/react-lib/locales/en.locale.d.ts +55 -0
  61. package/dist/react-lib/locales/fr.locale.d.ts +2 -0
  62. package/dist/react-lib/locales/helper.d.ts +65 -0
  63. package/dist/react-lib/locales/index.d.ts +3 -0
  64. package/dist/react-lib/locales/nl.locale.d.ts +2 -0
  65. package/dist/react-lib/locales/pt.locale.d.ts +2 -0
  66. package/dist/react-lib/providers/ChatProvider.d.ts +135 -0
  67. package/dist/react-lib/providers/ClientProvider.d.ts +7 -0
  68. package/dist/react-lib/providers/ConfigDataProvider.d.ts +62 -0
  69. package/dist/react-lib/providers/ContactProvider.d.ts +58 -0
  70. package/dist/react-lib/providers/LocalesProvider.d.ts +11 -0
  71. package/dist/react-lib/providers/componentRegistry.d.ts +13 -0
  72. package/dist/react-lib/providers/use-widget-sfx.d.ts +7 -0
  73. package/dist/react-lib/providers/usePreludeData.d.ts +2 -0
  74. package/dist/react-lib/types/components.d.ts +10 -0
  75. package/dist/react-lib/types/index.d.ts +6 -0
  76. package/dist/react-lib/types/options.d.ts +43 -0
  77. package/dist/react-lib/utils/create-safe-context.d.ts +1 -0
  78. package/dist/react-lib/utils/debug.d.ts +2 -0
  79. package/dist/react-lib/utils/getters.d.ts +24 -0
  80. package/dist/react-lib/utils/index.d.ts +1 -0
  81. package/dist/react.cjs +2 -0
  82. package/dist/react.cjs.map +1 -0
  83. package/dist/react.d.ts +2 -0
  84. package/dist/react.js +41 -0
  85. package/dist/react.js.map +1 -0
  86. package/dist/src/@components/BotMessage.d.ts +9 -0
  87. package/dist/src/@components/BotMessageWrapper.d.ts +7 -0
  88. package/dist/src/@components/ChatEvent.component.d.ts +9 -0
  89. package/dist/src/@components/Fallback.component.d.ts +8 -0
  90. package/dist/src/@components/Loading.component.d.ts +2 -0
  91. package/dist/src/@components/OpenLogoSvg.d.ts +4 -0
  92. package/dist/src/@components/Text.component.d.ts +3 -0
  93. package/dist/src/@components/index.d.ts +6 -0
  94. package/dist/src/@components/markdown.d.ts +3 -0
  95. package/dist/src/components/MotionDiv.d.ts +18 -0
  96. package/dist/src/components/RenderFile.d.ts +7 -0
  97. package/dist/src/components/avatar.d.ts +6 -0
  98. package/dist/src/components/button.d.ts +11 -0
  99. package/dist/src/components/dialog.d.ts +276 -0
  100. package/dist/src/components/dropdown-menu.d.ts +27 -0
  101. package/dist/src/components/input.d.ts +5 -0
  102. package/dist/src/components/keyboard.d.ts +7 -0
  103. package/dist/src/components/popover.d.ts +8 -0
  104. package/dist/src/components/skeleton.d.ts +3 -0
  105. package/dist/src/components/switch.d.ts +4 -0
  106. package/dist/src/components/tooltip.d.ts +10 -0
  107. package/dist/src/components/userMessage.d.ts +8 -0
  108. package/dist/src/components/wobble.d.ts +15 -0
  109. package/dist/src/designs/basic/WidgetPopoverTrigger.d.ts +5 -0
  110. package/dist/src/designs/basic/index.d.ts +5 -0
  111. package/dist/src/designs/basic/screens/chat-screen/ChatFooter.d.ts +2 -0
  112. package/dist/src/designs/basic/screens/chat-screen/ChatHeader.d.ts +2 -0
  113. package/dist/src/designs/basic/screens/chat-screen/ChatScreen.d.ts +2 -0
  114. package/dist/src/designs/basic/screens/chat-screen/SessionClosedDialog.d.ts +2 -0
  115. package/dist/src/designs/basic/screens/root-screen.d.ts +2 -0
  116. package/dist/src/designs/basic/screens/welcome-screen/WelcomeScreen.d.ts +2 -0
  117. package/dist/src/designs/constants.d.ts +15 -0
  118. package/dist/src/hooks/useShouldCollectData.d.ts +3 -0
  119. package/dist/src/index.d.ts +9 -0
  120. package/dist/src/render.d.ts +2 -0
  121. package/dist/src/utils.d.ts +2 -0
  122. package/dist/style.css +1 -0
  123. package/dist-embed/script.js +476 -0
  124. package/dist-embed/script.js.map +1 -0
  125. package/package.json +153 -0
@@ -0,0 +1,476 @@
1
+ var Joe=Object.defineProperty;var ese=(_i,$r,Zn)=>$r in _i?Joe(_i,$r,{enumerable:!0,configurable:!0,writable:!0,value:Zn}):_i[$r]=Zn;var u6=(_i,$r,Zn)=>ese(_i,typeof $r!="symbol"?$r+"":$r,Zn);(function(){"use strict";var _i=document.createElement("style");_i.textContent='@import"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..700;1,14..32,100..700&display=swap";[data-chat-widget] *,[data-chat-widget] :before,[data-chat-widget] :after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }[data-chat-widget] ::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }[data-chat-widget] *,[data-chat-widget] :before,[data-chat-widget] :after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}[data-chat-widget] :before,[data-chat-widget] :after{--tw-content: ""}[data-chat-widget] html,[data-chat-widget] :host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}[data-chat-widget] body{margin:0;line-height:inherit}[data-chat-widget] hr{height:0;color:inherit;border-top-width:1px}[data-chat-widget] abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}[data-chat-widget] h1,[data-chat-widget] h2,[data-chat-widget] h3,[data-chat-widget] h4,[data-chat-widget] h5,[data-chat-widget] h6{font-size:inherit;font-weight:inherit}[data-chat-widget] a{color:inherit;text-decoration:inherit}[data-chat-widget] b,[data-chat-widget] strong{font-weight:bolder}[data-chat-widget] code,[data-chat-widget] kbd,[data-chat-widget] samp,[data-chat-widget] pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}[data-chat-widget] small{font-size:80%}[data-chat-widget] sub,[data-chat-widget] sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}[data-chat-widget] sub{bottom:-.25em}[data-chat-widget] sup{top:-.5em}[data-chat-widget] table{text-indent:0;border-color:inherit;border-collapse:collapse}[data-chat-widget] button,[data-chat-widget] input,[data-chat-widget] optgroup,[data-chat-widget] select,[data-chat-widget] textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}[data-chat-widget] button,[data-chat-widget] select{text-transform:none}[data-chat-widget] button,[data-chat-widget] input:where([type=button]),[data-chat-widget] input:where([type=reset]),[data-chat-widget] input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}[data-chat-widget] :-moz-focusring{outline:auto}[data-chat-widget] :-moz-ui-invalid{box-shadow:none}[data-chat-widget] progress{vertical-align:baseline}[data-chat-widget] ::-webkit-inner-spin-button,[data-chat-widget] ::-webkit-outer-spin-button{height:auto}[data-chat-widget] [type=search]{-webkit-appearance:textfield;outline-offset:-2px}[data-chat-widget] ::-webkit-search-decoration{-webkit-appearance:none}[data-chat-widget] ::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}[data-chat-widget] summary{display:list-item}[data-chat-widget] blockquote,[data-chat-widget] dl,[data-chat-widget] dd,[data-chat-widget] h1,[data-chat-widget] h2,[data-chat-widget] h3,[data-chat-widget] h4,[data-chat-widget] h5,[data-chat-widget] h6,[data-chat-widget] hr,[data-chat-widget] figure,[data-chat-widget] p,[data-chat-widget] pre{margin:0}[data-chat-widget] fieldset{margin:0;padding:0}[data-chat-widget] legend{padding:0}[data-chat-widget] ol,[data-chat-widget] ul,[data-chat-widget] menu{list-style:none;margin:0;padding:0}[data-chat-widget] dialog{padding:0}[data-chat-widget] textarea{resize:vertical}[data-chat-widget] input::-moz-placeholder,[data-chat-widget] textarea::-moz-placeholder{opacity:1;color:#9ca3af}[data-chat-widget] input::placeholder,[data-chat-widget] textarea::placeholder{opacity:1;color:#9ca3af}[data-chat-widget] button,[data-chat-widget] [role=button]{cursor:pointer}[data-chat-widget] :disabled{cursor:default}[data-chat-widget] img,[data-chat-widget] svg,[data-chat-widget] video,[data-chat-widget] canvas,[data-chat-widget] audio,[data-chat-widget] iframe,[data-chat-widget] embed,[data-chat-widget] object{display:block;vertical-align:middle}[data-chat-widget] img,[data-chat-widget] video{max-width:100%;height:auto}[data-chat-widget] [hidden]:where(:not([hidden=until-found])){display:none}[data-chat-widget] *{-ms-overflow-style:none;scrollbar-width:none}[data-chat-widget] *::-webkit-scrollbar{display:none}[data-chat-widget] *{border-color:hsl(var(--opencx-border))}[data-chat-widget] .container{width:100%}@media (min-width: 640px){[data-chat-widget] .container{max-width:640px}}@media (min-width: 768px){[data-chat-widget] .container{max-width:768px}}@media (min-width: 1024px){[data-chat-widget] .container{max-width:1024px}}@media (min-width: 1280px){[data-chat-widget] .container{max-width:1280px}}@media (min-width: 1536px){[data-chat-widget] .container{max-width:1536px}}[data-chat-widget] .prose{color:var(--tw-prose-body);max-width:65ch}[data-chat-widget] .prose :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}[data-chat-widget] .prose :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-lead);font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}[data-chat-widget] .prose :where(a):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-links);text-decoration:underline;font-weight:500}[data-chat-widget] .prose :where(strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-bold);font-weight:600}[data-chat-widget] .prose :where(a strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(blockquote strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(thead th strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}[data-chat-widget] .prose :where(ol[type=A]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}[data-chat-widget] .prose :where(ol[type=a]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}[data-chat-widget] .prose :where(ol[type=A s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}[data-chat-widget] .prose :where(ol[type=a s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}[data-chat-widget] .prose :where(ol[type=I]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}[data-chat-widget] .prose :where(ol[type=i]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}[data-chat-widget] .prose :where(ol[type=I s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}[data-chat-widget] .prose :where(ol[type=i s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}[data-chat-widget] .prose :where(ol[type="1"]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal}[data-chat-widget] .prose :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:disc;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}[data-chat-widget] .prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{font-weight:400;color:var(--tw-prose-counters)}[data-chat-widget] .prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{color:var(--tw-prose-bullets)}[data-chat-widget] .prose :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.25em}[data-chat-widget] .prose :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){border-color:var(--tw-prose-hr);border-top-width:1px;margin-top:3em;margin-bottom:3em}[data-chat-widget] .prose :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-style:italic;color:var(--tw-prose-quotes);border-inline-start-width:.25rem;border-inline-start-color:var(--tw-prose-quote-borders);quotes:"“""”""‘""’";margin-top:1.6em;margin-bottom:1.6em;padding-inline-start:1em}[data-chat-widget] .prose :where(blockquote p:first-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:open-quote}[data-chat-widget] .prose :where(blockquote p:last-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:close-quote}[data-chat-widget] .prose :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}[data-chat-widget] .prose :where(h1 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:900;color:inherit}[data-chat-widget] .prose :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}[data-chat-widget] .prose :where(h2 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:800;color:inherit}[data-chat-widget] .prose :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}[data-chat-widget] .prose :where(h3 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}[data-chat-widget] .prose :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}[data-chat-widget] .prose :where(h4 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}[data-chat-widget] .prose :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}[data-chat-widget] .prose :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){display:block;margin-top:2em;margin-bottom:2em}[data-chat-widget] .prose :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}[data-chat-widget] .prose :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-family:inherit;color:var(--tw-prose-kbd);box-shadow:0 0 0 1px rgb(var(--tw-prose-kbd-shadows) / 10%),0 3px rgb(var(--tw-prose-kbd-shadows) / 10%);font-size:.875em;border-radius:.3125rem;padding-top:.1875em;padding-inline-end:.375em;padding-bottom:.1875em;padding-inline-start:.375em}[data-chat-widget] .prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-code);font-weight:600;font-size:.875em}[data-chat-widget] .prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:"`"}[data-chat-widget] .prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:"`"}[data-chat-widget] .prose :where(a code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(h1 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.875em}[data-chat-widget] .prose :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.9em}[data-chat-widget] .prose :where(h4 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(blockquote code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(thead th code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-pre-code);background-color:var(--tw-prose-pre-bg);overflow-x:auto;font-weight:400;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding-top:.8571429em;padding-inline-end:1.1428571em;padding-bottom:.8571429em;padding-inline-start:1.1428571em}[data-chat-widget] .prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)){background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:inherit;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}[data-chat-widget] .prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:none}[data-chat-widget] .prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:none}[data-chat-widget] .prose :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){width:100%;table-layout:auto;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}[data-chat-widget] .prose :where(thead):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-th-borders)}[data-chat-widget] .prose :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;vertical-align:bottom;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}[data-chat-widget] .prose :where(tbody tr):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-td-borders)}[data-chat-widget] .prose :where(tbody tr:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:0}[data-chat-widget] .prose :where(tbody td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:baseline}[data-chat-widget] .prose :where(tfoot):not(:where([class~=not-prose],[class~=not-prose] *)){border-top-width:1px;border-top-color:var(--tw-prose-th-borders)}[data-chat-widget] .prose :where(tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:top}[data-chat-widget] .prose :where(th,td):not(:where([class~=not-prose],[class~=not-prose] *)){text-align:start}[data-chat-widget] .prose :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}[data-chat-widget] .prose :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-captions);font-size:.875em;line-height:1.4285714;margin-top:.8571429em}[data-chat-widget] .prose{--tw-prose-body: #374151;--tw-prose-headings: #111827;--tw-prose-lead: #4b5563;--tw-prose-links: #111827;--tw-prose-bold: #111827;--tw-prose-counters: #6b7280;--tw-prose-bullets: #d1d5db;--tw-prose-hr: #e5e7eb;--tw-prose-quotes: #111827;--tw-prose-quote-borders: #e5e7eb;--tw-prose-captions: #6b7280;--tw-prose-kbd: #111827;--tw-prose-kbd-shadows: 17 24 39;--tw-prose-code: #111827;--tw-prose-pre-code: #e5e7eb;--tw-prose-pre-bg: #1f2937;--tw-prose-th-borders: #d1d5db;--tw-prose-td-borders: #e5e7eb;--tw-prose-invert-body: #d1d5db;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #9ca3af;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #9ca3af;--tw-prose-invert-bullets: #4b5563;--tw-prose-invert-hr: #374151;--tw-prose-invert-quotes: #f3f4f6;--tw-prose-invert-quote-borders: #374151;--tw-prose-invert-captions: #9ca3af;--tw-prose-invert-kbd: #fff;--tw-prose-invert-kbd-shadows: 255 255 255;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #d1d5db;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #4b5563;--tw-prose-invert-td-borders: #374151;font-size:1rem;line-height:1.75}[data-chat-widget] .prose :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}[data-chat-widget] .prose :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;margin-bottom:.5em}[data-chat-widget] .prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}[data-chat-widget] .prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}[data-chat-widget] .prose :where(.prose>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}[data-chat-widget] .prose :where(.prose>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}[data-chat-widget] .prose :where(.prose>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}[data-chat-widget] .prose :where(.prose>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}[data-chat-widget] .prose :where(.prose>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}[data-chat-widget] .prose :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}[data-chat-widget] .prose :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}[data-chat-widget] .prose :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;padding-inline-start:1.625em}[data-chat-widget] .prose :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}[data-chat-widget] .prose :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}[data-chat-widget] .prose :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.5714286em;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}[data-chat-widget] .prose :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}[data-chat-widget] .prose :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}[data-chat-widget] .prose :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}[data-chat-widget] .prose :where(.prose>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(.prose>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}[data-chat-widget] .prose-sm{font-size:.875rem;line-height:1.7142857}[data-chat-widget] .prose-sm :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}[data-chat-widget] .prose-sm :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;line-height:1.5555556;margin-top:.8888889em;margin-bottom:.8888889em}[data-chat-widget] .prose-sm :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-inline-start:1.1111111em}[data-chat-widget] .prose-sm :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:2.1428571em;margin-top:0;margin-bottom:.8em;line-height:1.2}[data-chat-widget] .prose-sm :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.4285714em;margin-top:1.6em;margin-bottom:.8em;line-height:1.4}[data-chat-widget] .prose-sm :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;margin-top:1.5555556em;margin-bottom:.4444444em;line-height:1.5555556}[data-chat-widget] .prose-sm :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.4285714em;margin-bottom:.5714286em;line-height:1.4285714}[data-chat-widget] .prose-sm :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}[data-chat-widget] .prose-sm :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}[data-chat-widget] .prose-sm :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}[data-chat-widget] .prose-sm :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}[data-chat-widget] .prose-sm :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;border-radius:.3125rem;padding-top:.1428571em;padding-inline-end:.3571429em;padding-bottom:.1428571em;padding-inline-start:.3571429em}[data-chat-widget] .prose-sm :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em}[data-chat-widget] .prose-sm :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.9em}[data-chat-widget] .prose-sm :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em}[data-chat-widget] .prose-sm :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.6666667;margin-top:1.6666667em;margin-bottom:1.6666667em;border-radius:.25rem;padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}[data-chat-widget] .prose-sm :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}[data-chat-widget] .prose-sm :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}[data-chat-widget] .prose-sm :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;margin-bottom:.2857143em}[data-chat-widget] .prose-sm :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}[data-chat-widget] .prose-sm :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}[data-chat-widget] .prose-sm :where(.prose-sm>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}[data-chat-widget] .prose-sm :where(.prose-sm>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}[data-chat-widget] .prose-sm :where(.prose-sm>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}[data-chat-widget] .prose-sm :where(.prose-sm>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}[data-chat-widget] .prose-sm :where(.prose-sm>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}[data-chat-widget] .prose-sm :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}[data-chat-widget] .prose-sm :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}[data-chat-widget] .prose-sm :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}[data-chat-widget] .prose-sm :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;padding-inline-start:1.5714286em}[data-chat-widget] .prose-sm :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2.8571429em;margin-bottom:2.8571429em}[data-chat-widget] .prose-sm :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.5}[data-chat-widget] .prose-sm :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}[data-chat-widget] .prose-sm :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}[data-chat-widget] .prose-sm :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}[data-chat-widget] .prose-sm :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}[data-chat-widget] .prose-sm :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}[data-chat-widget] .prose-sm :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}[data-chat-widget] .prose-sm :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}[data-chat-widget] .prose-sm :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}[data-chat-widget] .prose-sm :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.3333333;margin-top:.6666667em}[data-chat-widget] .prose-sm :where(.prose-sm>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(.prose-sm>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}[data-chat-widget] .prose-slate{--tw-prose-body: #334155;--tw-prose-headings: #0f172a;--tw-prose-lead: #475569;--tw-prose-links: #0f172a;--tw-prose-bold: #0f172a;--tw-prose-counters: #64748b;--tw-prose-bullets: #cbd5e1;--tw-prose-hr: #e2e8f0;--tw-prose-quotes: #0f172a;--tw-prose-quote-borders: #e2e8f0;--tw-prose-captions: #64748b;--tw-prose-kbd: #0f172a;--tw-prose-kbd-shadows: 15 23 42;--tw-prose-code: #0f172a;--tw-prose-pre-code: #e2e8f0;--tw-prose-pre-bg: #1e293b;--tw-prose-th-borders: #cbd5e1;--tw-prose-td-borders: #e2e8f0;--tw-prose-invert-body: #cbd5e1;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #94a3b8;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #94a3b8;--tw-prose-invert-bullets: #475569;--tw-prose-invert-hr: #334155;--tw-prose-invert-quotes: #f1f5f9;--tw-prose-invert-quote-borders: #334155;--tw-prose-invert-captions: #94a3b8;--tw-prose-invert-kbd: #fff;--tw-prose-invert-kbd-shadows: 255 255 255;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #cbd5e1;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #475569;--tw-prose-invert-td-borders: #334155}[data-chat-widget] .pointer-events-none{pointer-events:none}[data-chat-widget] .visible{visibility:visible}[data-chat-widget] .fixed{position:fixed}[data-chat-widget] .absolute{position:absolute}[data-chat-widget] .relative{position:relative}[data-chat-widget] .inset-0{top:0;right:0;bottom:0;left:0}[data-chat-widget] .inset-x-0{left:0;right:0}[data-chat-widget] .bottom-0{bottom:0}[data-chat-widget] .bottom-2{bottom:.5rem}[data-chat-widget] .left-0{left:0}[data-chat-widget] .left-1\\/2{left:50%}[data-chat-widget] .left-2{left:.5rem}[data-chat-widget] .right-0{right:0}[data-chat-widget] .top-1\\/2{top:50%}[data-chat-widget] .isolate{isolation:isolate}[data-chat-widget] .z-0{z-index:0}[data-chat-widget] .z-10{z-index:10}[data-chat-widget] .z-50{z-index:50}[data-chat-widget] .z-\\[24\\]{z-index:24}[data-chat-widget] .z-\\[25\\]{z-index:25}[data-chat-widget] .-mx-1{margin-left:-.25rem;margin-right:-.25rem}[data-chat-widget] .my-1{margin-top:.25rem;margin-bottom:.25rem}[data-chat-widget] .my-2{margin-top:.5rem;margin-bottom:.5rem}[data-chat-widget] .mb-1{margin-bottom:.25rem}[data-chat-widget] .mb-2{margin-bottom:.5rem}[data-chat-widget] .ml-auto{margin-left:auto}[data-chat-widget] .mt-1{margin-top:.25rem}[data-chat-widget] .mt-2{margin-top:.5rem}[data-chat-widget] .line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}[data-chat-widget] .block{display:block}[data-chat-widget] .inline{display:inline}[data-chat-widget] .flex{display:flex}[data-chat-widget] .inline-flex{display:inline-flex}[data-chat-widget] .grid{display:grid}[data-chat-widget] .contents{display:contents}[data-chat-widget] .hidden{display:none}[data-chat-widget] .aspect-square{aspect-ratio:1 / 1}[data-chat-widget] .size-12{width:3rem;height:3rem}[data-chat-widget] .size-16{width:4rem;height:4rem}[data-chat-widget] .size-3{width:.75rem;height:.75rem}[data-chat-widget] .size-4{width:1rem;height:1rem}[data-chat-widget] .size-5{width:1.25rem;height:1.25rem}[data-chat-widget] .size-6{width:1.5rem;height:1.5rem}[data-chat-widget] .size-7{width:1.75rem;height:1.75rem}[data-chat-widget] .size-8{width:2rem;height:2rem}[data-chat-widget] .size-fit{width:-moz-fit-content;width:fit-content;height:-moz-fit-content;height:fit-content}[data-chat-widget] .size-full{width:100%;height:100%}[data-chat-widget] .h-10{height:2.5rem}[data-chat-widget] .h-11{height:2.75rem}[data-chat-widget] .h-2{height:.5rem}[data-chat-widget] .h-3\\.5{height:.875rem}[data-chat-widget] .h-4{height:1rem}[data-chat-widget] .h-5{height:1.25rem}[data-chat-widget] .h-8{height:2rem}[data-chat-widget] .h-\\[600px\\]{height:600px}[data-chat-widget] .h-fit{height:-moz-fit-content;height:fit-content}[data-chat-widget] .h-full{height:100%}[data-chat-widget] .h-px{height:1px}[data-chat-widget] .max-h-\\[600px\\]{max-height:600px}[data-chat-widget] .max-h-full{max-height:100%}[data-chat-widget] .min-h-\\[400px\\]{min-height:400px}[data-chat-widget] .w-10{width:2.5rem}[data-chat-widget] .w-2{width:.5rem}[data-chat-widget] .w-2\\/3{width:66.666667%}[data-chat-widget] .w-3\\.5{width:.875rem}[data-chat-widget] .w-4{width:1rem}[data-chat-widget] .w-60{width:15rem}[data-chat-widget] .w-9{width:2.25rem}[data-chat-widget] .w-auto{width:auto}[data-chat-widget] .w-fit{width:-moz-fit-content;width:fit-content}[data-chat-widget] .w-full{width:100%}[data-chat-widget] .min-w-56{min-width:14rem}[data-chat-widget] .min-w-\\[80\\%\\]{min-width:80%}[data-chat-widget] .min-w-\\[8rem\\]{min-width:8rem}[data-chat-widget] .min-w-fit{min-width:-moz-fit-content;min-width:fit-content}[data-chat-widget] .max-w-\\[320px\\]{max-width:320px}[data-chat-widget] .max-w-\\[85\\%\\]{max-width:85%}[data-chat-widget] .max-w-\\[90\\%\\]{max-width:90%}[data-chat-widget] .max-w-full{max-width:100%}[data-chat-widget] .max-w-xs{max-width:20rem}[data-chat-widget] .flex-1{flex:1 1 0%}[data-chat-widget] .shrink-0{flex-shrink:0}[data-chat-widget] .origin-bottom{transform-origin:bottom}[data-chat-widget] .-translate-x-1\\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .-translate-y-1\\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .translate-x-\\[var\\(--opencx-wobble-x\\)\\]{--tw-translate-x: var(--opencx-wobble-x);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .translate-y-\\[var\\(--opencx-wobble-y\\)\\]{--tw-translate-y: var(--opencx-wobble-y);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .scale-\\[1\\.01\\]{--tw-scale-x: 1.01;--tw-scale-y: 1.01;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .scale-\\[1\\.02\\]{--tw-scale-x: 1.02;--tw-scale-y: 1.02;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .scale-\\[1\\.1\\]{--tw-scale-x: 1.1;--tw-scale-y: 1.1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .scale-\\[1\\]{--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes bounce{0%,to{transform:translateY(-25%);animation-timing-function:cubic-bezier(.8,0,1,1)}50%{transform:none;animation-timing-function:cubic-bezier(0,0,.2,1)}}[data-chat-widget] .animate-bounce{animation:bounce 1s infinite}@keyframes pulse{50%{opacity:.5}}[data-chat-widget] .animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}[data-chat-widget] .animate-spin{animation:spin 1s linear infinite}[data-chat-widget] .cursor-default{cursor:default}[data-chat-widget] .cursor-pointer{cursor:pointer}[data-chat-widget] .select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}[data-chat-widget] .resize-none{resize:none}[data-chat-widget] .grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}[data-chat-widget] .flex-row{flex-direction:row}[data-chat-widget] .flex-col{flex-direction:column}[data-chat-widget] .flex-wrap{flex-wrap:wrap}[data-chat-widget] .items-start{align-items:flex-start}[data-chat-widget] .items-end{align-items:flex-end}[data-chat-widget] .items-center{align-items:center}[data-chat-widget] .justify-start{justify-content:flex-start}[data-chat-widget] .justify-end{justify-content:flex-end}[data-chat-widget] .justify-center{justify-content:center}[data-chat-widget] .justify-between{justify-content:space-between}[data-chat-widget] .gap-0\\.5{gap:.125rem}[data-chat-widget] .gap-1{gap:.25rem}[data-chat-widget] .gap-2{gap:.5rem}[data-chat-widget] .space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}[data-chat-widget] .space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}[data-chat-widget] .space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}[data-chat-widget] .space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}[data-chat-widget] .overflow-auto{overflow:auto}[data-chat-widget] .overflow-hidden{overflow:hidden}[data-chat-widget] .scroll-smooth{scroll-behavior:smooth}[data-chat-widget] .whitespace-nowrap{white-space:nowrap}[data-chat-widget] .rounded-2xl{border-radius:1rem}[data-chat-widget] .rounded-3xl{border-radius:1.5rem}[data-chat-widget] .rounded-full{border-radius:9999px}[data-chat-widget] .rounded-lg{border-radius:.5rem}[data-chat-widget] .rounded-md{border-radius:.375rem}[data-chat-widget] .rounded-sm{border-radius:.125rem}[data-chat-widget] .rounded-xl{border-radius:.75rem}[data-chat-widget] .rounded-bl-none{border-bottom-left-radius:0}[data-chat-widget] .border{border-width:1px}[data-chat-widget] .border-0{border-width:0px}[data-chat-widget] .border-2{border-width:2px}[data-chat-widget] .border-b{border-bottom-width:1px}[data-chat-widget] .border-destructive{border-color:hsl(var(--opencx-destructive))}[data-chat-widget] .border-input{border-color:hsl(var(--opencx-input))}[data-chat-widget] .border-primary{border-color:hsl(var(--opencx-primary))}[data-chat-widget] .border-transparent{border-color:transparent}[data-chat-widget] .bg-background{background-color:hsl(var(--opencx-background))}[data-chat-widget] .bg-black{--tw-bg-opacity: 1;background-color:rgb(0 0 0 / var(--tw-bg-opacity))}[data-chat-widget] .bg-black\\/50{background-color:#00000080}[data-chat-widget] .bg-destructive{background-color:hsl(var(--opencx-destructive))}[data-chat-widget] .bg-muted{background-color:hsl(var(--opencx-muted))}[data-chat-widget] .bg-primary{background-color:hsl(var(--opencx-primary))}[data-chat-widget] .bg-secondary{background-color:hsl(var(--opencx-secondary))}[data-chat-widget] .bg-transparent{background-color:transparent}[data-chat-widget] .bg-zinc-100{--tw-bg-opacity: 1;background-color:rgb(244 244 245 / var(--tw-bg-opacity))}[data-chat-widget] .bg-gradient-to-t{background-image:linear-gradient(to top,var(--tw-gradient-stops))}[data-chat-widget] .from-gray-100\\/30{--tw-gradient-from: rgb(243 244 246 / .3) var(--tw-gradient-from-position);--tw-gradient-to: rgb(243 244 246 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}[data-chat-widget] .from-primary\\/50{--tw-gradient-from: hsl(var(--opencx-primary) / .5) var(--tw-gradient-from-position);--tw-gradient-to: hsl(var(--opencx-primary) / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}[data-chat-widget] .via-primary{--tw-gradient-to: hsl(var(--opencx-primary) / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), hsl(var(--opencx-primary)) var(--tw-gradient-via-position), var(--tw-gradient-to)}[data-chat-widget] .to-gray-50\\/30{--tw-gradient-to: rgb(249 250 251 / .3) var(--tw-gradient-to-position)}[data-chat-widget] .to-primary{--tw-gradient-to: hsl(var(--opencx-primary)) var(--tw-gradient-to-position)}[data-chat-widget] .fill-current{fill:currentColor}[data-chat-widget] .object-contain{-o-object-fit:contain;object-fit:contain}[data-chat-widget] .object-cover{-o-object-fit:cover;object-fit:cover}[data-chat-widget] .p-0{padding:0}[data-chat-widget] .p-1{padding:.25rem}[data-chat-widget] .p-2{padding:.5rem}[data-chat-widget] .p-2\\.5{padding:.625rem}[data-chat-widget] .p-3{padding:.75rem}[data-chat-widget] .p-4{padding:1rem}[data-chat-widget] .px-2{padding-left:.5rem;padding-right:.5rem}[data-chat-widget] .px-3{padding-left:.75rem;padding-right:.75rem}[data-chat-widget] .px-4{padding-left:1rem;padding-right:1rem}[data-chat-widget] .px-8{padding-left:2rem;padding-right:2rem}[data-chat-widget] .py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}[data-chat-widget] .py-12{padding-top:3rem;padding-bottom:3rem}[data-chat-widget] .py-2{padding-top:.5rem;padding-bottom:.5rem}[data-chat-widget] .py-3{padding-top:.75rem;padding-bottom:.75rem}[data-chat-widget] .py-4{padding-top:1rem;padding-bottom:1rem}[data-chat-widget] .pl-2{padding-left:.5rem}[data-chat-widget] .pl-3{padding-left:.75rem}[data-chat-widget] .pl-8{padding-left:2rem}[data-chat-widget] .pr-2{padding-right:.5rem}[data-chat-widget] .text-center{text-align:center}[data-chat-widget] .text-start{text-align:start}[data-chat-widget] .align-middle{vertical-align:middle}[data-chat-widget] .font-inter{font-family:Inter,sans-serif}[data-chat-widget] .text-2xl{font-size:1.5rem;line-height:2rem}[data-chat-widget] .text-\\[10px\\]{font-size:10px}[data-chat-widget] .text-base{font-size:1rem;line-height:1.5rem}[data-chat-widget] .text-sm{font-size:.875rem;line-height:1.25rem}[data-chat-widget] .text-xl{font-size:1.25rem;line-height:1.75rem}[data-chat-widget] .text-xs{font-size:.75rem;line-height:1rem}[data-chat-widget] .font-bold{font-weight:700}[data-chat-widget] .font-medium{font-weight:500}[data-chat-widget] .font-semibold{font-weight:600}[data-chat-widget] .leading-relaxed{line-height:1.625}[data-chat-widget] .leading-snug{line-height:1.375}[data-chat-widget] .leading-tight{line-height:1.25}[data-chat-widget] .tracking-widest{letter-spacing:.1em}[data-chat-widget] .text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity))}[data-chat-widget] .text-destructive{color:hsl(var(--opencx-destructive))}[data-chat-widget] .text-destructive-foreground{color:hsl(var(--opencx-destructive-foreground))}[data-chat-widget] .text-emerald-500{--tw-text-opacity: 1;color:rgb(16 185 129 / var(--tw-text-opacity))}[data-chat-widget] .text-foreground{color:hsl(var(--opencx-foreground))}[data-chat-widget] .text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity))}[data-chat-widget] .text-primary{color:hsl(var(--opencx-primary))}[data-chat-widget] .text-primary-foreground{color:hsl(var(--opencx-primary-foreground))}[data-chat-widget] .text-primary-foreground\\/90{color:hsl(var(--opencx-primary-foreground) / .9)}[data-chat-widget] .text-secondary-foreground{color:hsl(var(--opencx-secondary-foreground))}[data-chat-widget] .text-zinc-500{--tw-text-opacity: 1;color:rgb(113 113 122 / var(--tw-text-opacity))}[data-chat-widget] .text-zinc-600{--tw-text-opacity: 1;color:rgb(82 82 91 / var(--tw-text-opacity))}[data-chat-widget] .underline{text-decoration-line:underline}[data-chat-widget] .underline-offset-4{text-underline-offset:4px}[data-chat-widget] .antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}[data-chat-widget] .opacity-0{opacity:0}[data-chat-widget] .opacity-50{opacity:.5}[data-chat-widget] .opacity-60{opacity:.6}[data-chat-widget] .shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-2xl{--tw-shadow: 0 25px 50px -12px rgb(0 0 0 / .25);--tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .outline-none{outline:2px solid transparent;outline-offset:2px}[data-chat-widget] .outline{outline-style:solid}[data-chat-widget] .ring-0{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}[data-chat-widget] .ring-2{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}[data-chat-widget] .ring-white{--tw-ring-opacity: 1;--tw-ring-color: rgb(255 255 255 / var(--tw-ring-opacity))}[data-chat-widget] .ring-offset-background{--tw-ring-offset-color: hsl(var(--opencx-background))}[data-chat-widget] .backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}[data-chat-widget] .transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .duration-200{transition-duration:.2s}[data-chat-widget] .ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity, 1);transform:translate3d(var(--tw-enter-translate-x, 0),var(--tw-enter-translate-y, 0),0) scale3d(var(--tw-enter-scale, 1),var(--tw-enter-scale, 1),var(--tw-enter-scale, 1)) rotate(var(--tw-enter-rotate, 0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity, 1);transform:translate3d(var(--tw-exit-translate-x, 0),var(--tw-exit-translate-y, 0),0) scale3d(var(--tw-exit-scale, 1),var(--tw-exit-scale, 1),var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0))}}[data-chat-widget] .animate-in{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}[data-chat-widget] .fade-in-0{--tw-enter-opacity: 0}[data-chat-widget] .zoom-in-95{--tw-enter-scale: .95}[data-chat-widget] .duration-200{animation-duration:.2s}[data-chat-widget] .ease-out{animation-timing-function:cubic-bezier(0,0,.2,1)}[data-chat-widget] .\\[animation-delay\\:-0\\.15s\\]{animation-delay:-.15s}[data-chat-widget] .\\[animation-delay\\:-0\\.3s\\]{animation-delay:-.3s}[data-chat-widget] .\\[background\\:radial-gradient\\(68\\.75\\%_68\\.75\\%_at_50\\%_100\\%\\,_\\#717171_0\\%\\,_\\#000000_100\\%\\)\\]{background:radial-gradient(68.75% 68.75% at 50% 100%,#717171,#000)}[data-chat-widget] .required:after{content:" *";color:red}[data-chat-widget] .file\\:border-0::file-selector-button{border-width:0px}[data-chat-widget] .file\\:bg-transparent::file-selector-button{background-color:transparent}[data-chat-widget] .file\\:text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}[data-chat-widget] .file\\:font-medium::file-selector-button{font-weight:500}[data-chat-widget] .file\\:text-primary-foreground::file-selector-button{color:hsl(var(--opencx-primary-foreground))}[data-chat-widget] .placeholder\\:text-muted-foreground::-moz-placeholder{color:hsl(var(--opencx-muted-foreground))}[data-chat-widget] .placeholder\\:text-muted-foreground::placeholder{color:hsl(var(--opencx-muted-foreground))}[data-chat-widget] .hover\\:bg-accent:hover{background-color:hsl(var(--opencx-accent))}[data-chat-widget] .hover\\:text-accent-foreground:hover{color:hsl(var(--opencx-accent-foreground))}[data-chat-widget] .hover\\:text-blue-600:hover{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity))}[data-chat-widget] .hover\\:underline:hover{text-decoration-line:underline}[data-chat-widget] .hover\\:brightness-110:hover{--tw-brightness: brightness(1.1);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}[data-chat-widget] .focus\\:bg-accent:focus{background-color:hsl(var(--opencx-accent))}[data-chat-widget] .focus\\:text-accent-foreground:focus{color:hsl(var(--opencx-accent-foreground))}[data-chat-widget] .focus-visible\\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}[data-chat-widget] .focus-visible\\:ring-2:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}[data-chat-widget] .focus-visible\\:ring-ring:focus-visible{--tw-ring-color: hsl(var(--opencx-ring))}[data-chat-widget] .focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width: 2px}[data-chat-widget] .focus-visible\\:ring-offset-background:focus-visible{--tw-ring-offset-color: hsl(var(--opencx-background))}[data-chat-widget] .active\\:scale-90:active{--tw-scale-x: .9;--tw-scale-y: .9;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .active\\:scale-95:active{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .active\\:shadow-none:active{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .hover\\:active\\:scale-95:active:hover{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .disabled\\:pointer-events-none:disabled{pointer-events:none}[data-chat-widget] .disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}[data-chat-widget] .disabled\\:opacity-0:disabled{opacity:0}[data-chat-widget] .disabled\\:opacity-50:disabled{opacity:.5}[data-chat-widget] .group:hover .group-hover\\:opacity-100{opacity:1}[data-chat-widget] .group:hover .group-hover\\:active\\:scale-90:active,[data-chat-widget] .group:active .group-active\\:scale-90{--tw-scale-x: .9;--tw-scale-y: .9;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .data-\\[disabled\\]\\:pointer-events-none[data-disabled]{pointer-events:none}[data-chat-widget] .data-\\[state\\=checked\\]\\:translate-x-4[data-state=checked]{--tw-translate-x: 1rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .data-\\[state\\=unchecked\\]\\:translate-x-0[data-state=unchecked]{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .data-\\[state\\=checked\\]\\:bg-primary[data-state=checked]{background-color:hsl(var(--opencx-primary))}[data-chat-widget] .data-\\[state\\=open\\]\\:bg-accent[data-state=open]{background-color:hsl(var(--opencx-accent))}[data-chat-widget] .data-\\[state\\=unchecked\\]\\:bg-input[data-state=unchecked]{background-color:hsl(var(--opencx-input))}[data-chat-widget] .data-\\[disabled\\]\\:opacity-50[data-disabled]{opacity:.5}[data-chat-widget] .data-\\[state\\=open\\]\\:animate-in[data-state=open]{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}[data-chat-widget] .data-\\[state\\=closed\\]\\:animate-out[data-state=closed]{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}[data-chat-widget] .data-\\[state\\=closed\\]\\:fade-out-0[data-state=closed]{--tw-exit-opacity: 0}[data-chat-widget] .data-\\[state\\=open\\]\\:fade-in-0[data-state=open]{--tw-enter-opacity: 0}[data-chat-widget] .data-\\[state\\=closed\\]\\:zoom-out-95[data-state=closed]{--tw-exit-scale: .95}[data-chat-widget] .data-\\[state\\=open\\]\\:zoom-in-95[data-state=open]{--tw-enter-scale: .95}[data-chat-widget] .data-\\[side\\=bottom\\]\\:slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y: -.5rem}[data-chat-widget] .data-\\[side\\=left\\]\\:slide-in-from-right-2[data-side=left]{--tw-enter-translate-x: .5rem}[data-chat-widget] .data-\\[side\\=right\\]\\:slide-in-from-left-2[data-side=right]{--tw-enter-translate-x: -.5rem}[data-chat-widget] .data-\\[side\\=top\\]\\:slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y: .5rem}[data-chat-widget] .prose-a\\:underline :is(:where(a):not(:where([class~=not-prose],[class~=not-prose] *))){text-decoration-line:underline}[data-chat-widget] .prose-a\\:decoration-primary :is(:where(a):not(:where([class~=not-prose],[class~=not-prose] *))){text-decoration-color:hsl(var(--opencx-primary))}[data-chat-widget] .rtl\\:-scale-100:where([dir=rtl],[dir=rtl] *){--tw-scale-x: -1;--tw-scale-y: -1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .\\[\\&_span\\]\\:size-1 span{width:.25rem;height:.25rem}[data-chat-widget] .\\[\\&_span\\]\\:bg-secondary-foreground span{background-color:hsl(var(--opencx-secondary-foreground))}[data-chat-widget] .\\[\\&_svg\\]\\:pointer-events-none svg{pointer-events:none}[data-chat-widget] .\\[\\&_svg\\]\\:size-4 svg{width:1rem;height:1rem}[data-chat-widget] .\\[\\&_svg\\]\\:size-6 svg{width:1.5rem;height:1.5rem}[data-chat-widget] .\\[\\&_svg\\]\\:shrink-0 svg{flex-shrink:0}\n',document.head.appendChild(_i);function $r(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in e)){const a=Object.getOwnPropertyDescriptor(r,i);a&&Object.defineProperty(e,i,a.get?a:{enumerable:!0,get:()=>r[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}var Zn=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function gc(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function c6(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:function(){return e[r]}})}),n}var Sv={exports:{}},wc={},kv={exports:{}},Ne={};/**
2
+ * @license React
3
+ * react.production.min.js
4
+ *
5
+ * Copyright (c) Facebook, Inc. and its affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */var Ws=Symbol.for("react.element"),d6=Symbol.for("react.portal"),f6=Symbol.for("react.fragment"),p6=Symbol.for("react.strict_mode"),h6=Symbol.for("react.profiler"),m6=Symbol.for("react.provider"),g6=Symbol.for("react.context"),w6=Symbol.for("react.forward_ref"),y6=Symbol.for("react.suspense"),v6=Symbol.for("react.memo"),b6=Symbol.for("react.lazy"),Cv=Symbol.iterator;function x6(e){return e===null||typeof e!="object"?null:(e=Cv&&e[Cv]||e["@@iterator"],typeof e=="function"?e:null)}var Av={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Rv=Object.assign,Nv={};function ho(e,t,n){this.props=e,this.context=t,this.refs=Nv,this.updater=n||Av}ho.prototype.isReactComponent={},ho.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},ho.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Ov(){}Ov.prototype=ho.prototype;function fh(e,t,n){this.props=e,this.context=t,this.refs=Nv,this.updater=n||Av}var ph=fh.prototype=new Ov;ph.constructor=fh,Rv(ph,ho.prototype),ph.isPureReactComponent=!0;var Pv=Array.isArray,Iv=Object.prototype.hasOwnProperty,hh={current:null},Dv={key:!0,ref:!0,__self:!0,__source:!0};function Lv(e,t,n){var r,i={},a=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(a=""+t.key),t)Iv.call(t,r)&&!Dv.hasOwnProperty(r)&&(i[r]=t[r]);var s=arguments.length-2;if(s===1)i.children=n;else if(1<s){for(var l=Array(s),u=0;u<s;u++)l[u]=arguments[u+2];i.children=l}if(e&&e.defaultProps)for(r in s=e.defaultProps,s)i[r]===void 0&&(i[r]=s[r]);return{$$typeof:Ws,type:e,key:a,ref:o,props:i,_owner:hh.current}}function E6(e,t){return{$$typeof:Ws,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function mh(e){return typeof e=="object"&&e!==null&&e.$$typeof===Ws}function T6(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Mv=/\/+/g;function gh(e,t){return typeof e=="object"&&e!==null&&e.key!=null?T6(""+e.key):t.toString(36)}function yc(e,t,n,r,i){var a=typeof e;(a==="undefined"||a==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(a){case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case Ws:case d6:o=!0}}if(o)return o=e,i=i(o),e=r===""?"."+gh(o,0):r,Pv(i)?(n="",e!=null&&(n=e.replace(Mv,"$&/")+"/"),yc(i,t,n,"",function(u){return u})):i!=null&&(mh(i)&&(i=E6(i,n+(!i.key||o&&o.key===i.key?"":(""+i.key).replace(Mv,"$&/")+"/")+e)),t.push(i)),1;if(o=0,r=r===""?".":r+":",Pv(e))for(var s=0;s<e.length;s++){a=e[s];var l=r+gh(a,s);o+=yc(a,t,n,l,i)}else if(l=x6(e),typeof l=="function")for(e=l.call(e),s=0;!(a=e.next()).done;)a=a.value,l=r+gh(a,s++),o+=yc(a,t,n,l,i);else if(a==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return o}function vc(e,t,n){if(e==null)return e;var r=[],i=0;return yc(e,r,"","",function(a){return t.call(n,a,i++)}),r}function _6(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var Xt={current:null},bc={transition:null},S6={ReactCurrentDispatcher:Xt,ReactCurrentBatchConfig:bc,ReactCurrentOwner:hh};function Fv(){throw Error("act(...) is not supported in production builds of React.")}Ne.Children={map:vc,forEach:function(e,t,n){vc(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return vc(e,function(){t++}),t},toArray:function(e){return vc(e,function(t){return t})||[]},only:function(e){if(!mh(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},Ne.Component=ho,Ne.Fragment=f6,Ne.Profiler=h6,Ne.PureComponent=fh,Ne.StrictMode=p6,Ne.Suspense=y6,Ne.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=S6,Ne.act=Fv,Ne.cloneElement=function(e,t,n){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=Rv({},e.props),i=e.key,a=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(a=t.ref,o=hh.current),t.key!==void 0&&(i=""+t.key),e.type&&e.type.defaultProps)var s=e.type.defaultProps;for(l in t)Iv.call(t,l)&&!Dv.hasOwnProperty(l)&&(r[l]=t[l]===void 0&&s!==void 0?s[l]:t[l])}var l=arguments.length-2;if(l===1)r.children=n;else if(1<l){s=Array(l);for(var u=0;u<l;u++)s[u]=arguments[u+2];r.children=s}return{$$typeof:Ws,type:e.type,key:i,ref:a,props:r,_owner:o}},Ne.createContext=function(e){return e={$$typeof:g6,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:m6,_context:e},e.Consumer=e},Ne.createElement=Lv,Ne.createFactory=function(e){var t=Lv.bind(null,e);return t.type=e,t},Ne.createRef=function(){return{current:null}},Ne.forwardRef=function(e){return{$$typeof:w6,render:e}},Ne.isValidElement=mh,Ne.lazy=function(e){return{$$typeof:b6,_payload:{_status:-1,_result:e},_init:_6}},Ne.memo=function(e,t){return{$$typeof:v6,type:e,compare:t===void 0?null:t}},Ne.startTransition=function(e){var t=bc.transition;bc.transition={};try{e()}finally{bc.transition=t}},Ne.unstable_act=Fv,Ne.useCallback=function(e,t){return Xt.current.useCallback(e,t)},Ne.useContext=function(e){return Xt.current.useContext(e)},Ne.useDebugValue=function(){},Ne.useDeferredValue=function(e){return Xt.current.useDeferredValue(e)},Ne.useEffect=function(e,t){return Xt.current.useEffect(e,t)},Ne.useId=function(){return Xt.current.useId()},Ne.useImperativeHandle=function(e,t,n){return Xt.current.useImperativeHandle(e,t,n)},Ne.useInsertionEffect=function(e,t){return Xt.current.useInsertionEffect(e,t)},Ne.useLayoutEffect=function(e,t){return Xt.current.useLayoutEffect(e,t)},Ne.useMemo=function(e,t){return Xt.current.useMemo(e,t)},Ne.useReducer=function(e,t,n){return Xt.current.useReducer(e,t,n)},Ne.useRef=function(e){return Xt.current.useRef(e)},Ne.useState=function(e){return Xt.current.useState(e)},Ne.useSyncExternalStore=function(e,t,n){return Xt.current.useSyncExternalStore(e,t,n)},Ne.useTransition=function(){return Xt.current.useTransition()},Ne.version="18.3.1",kv.exports=Ne;var y=kv.exports;const _t=gc(y),k6=$r({__proto__:null,default:_t},[y]);/**
10
+ * @license React
11
+ * react-jsx-runtime.production.min.js
12
+ *
13
+ * Copyright (c) Facebook, Inc. and its affiliates.
14
+ *
15
+ * This source code is licensed under the MIT license found in the
16
+ * LICENSE file in the root directory of this source tree.
17
+ */var C6=y,A6=Symbol.for("react.element"),R6=Symbol.for("react.fragment"),N6=Object.prototype.hasOwnProperty,O6=C6.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,P6={key:!0,ref:!0,__self:!0,__source:!0};function Bv(e,t,n){var r,i={},a=null,o=null;n!==void 0&&(a=""+n),t.key!==void 0&&(a=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)N6.call(t,r)&&!P6.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)i[r]===void 0&&(i[r]=t[r]);return{$$typeof:A6,type:e,key:a,ref:o,props:i,_owner:O6.current}}wc.Fragment=R6,wc.jsx=Bv,wc.jsxs=Bv,Sv.exports=wc;var E=Sv.exports;const I6="@opencx/widget",wh="2.0.0",jv={name:I6,private:!1,version:wh,type:"module",publishConfig:{access:"public"},scripts:{clean:"rm -rf ./dist ./dist-embed","clean:dist":"rm -rf ./dist ./dist-embed",prepublishOnly:"pnpm clean && pnpm test && pnpm batman","build:lib":"vite build",dev:"vite -c vite.config.ts","build:embed":"vite build -c vite.embed.config.ts",test:"vitest run",batman:"pnpm build:lib && pnpm build:embed","test:watch":"vitest --watch",cs:"changeset",csv:"changeset version",csp:"changeset publish","type-check":"tsc --noEmit",lint:"biome lint --fix",format:"biome format --fix"},peerDependencies:{"lucide-react":"^0.412.0",react:"^18.3.1","rehype-raw":"^7.0.0"},peerDependenciesMeta:{react:{optional:!0}},optionalDependencies:{axios:"^1.7.5","socket.io-client":"^4.7.5",zod:"^3.23.8"},dependencies:{"@radix-ui/react-avatar":"^1.1.0","@radix-ui/react-dropdown-menu":"^2.1.4","@radix-ui/react-slot":"^1.1.0","@radix-ui/react-switch":"^1.1.0","@radix-ui/react-tooltip":"^1.1.2",clsx:"^2.1.1","date-fns":"^4.1.0","framer-motion":"^11.3.30","lodash.set":"^4.3.2","lucide-react":"^0.436.0",mutative:"^1.0.11","react-dropzone":"^14.3.5","react-hot-toast":"^2.4.1",tinycolor2:"^1.6.0",zod:"^3.23.8"},overrides:{"@opencx/widget":{react:{optional:!0,dependencies:{"react-hot-toast":"^2.4.1","react-markdown":"^9.0.1","framer-motion":"^11.3.30","date-fns":"^4.1.0"}}}},conditionalDependencies:{react:{"react-hot-toast":"^2.4.1","react-markdown":"^9.0.1","framer-motion":"^11.3.30","date-fns":"^4.1.0"}},files:["dist","dist-embed"],bugs:{url:"https://github.com/openchatai/OpenCopilot/issues"},author:{name:"openchatai",url:"https://github.com/openchatai"},main:"./dist/index.js",module:"./dist/index.js",types:"./dist/index.d.ts",sideEffects:!1,exports:{".":{types:"./dist/index.d.ts",import:"./dist/index.js",require:"./dist/index.cjs"},"./basic":{types:"./dist/basic.d.ts",import:"./dist/basic.js",require:"./dist/basic.cjs"},"./react":{types:"./dist/react.d.ts",import:"./dist/react.js",require:"./dist/react.cjs"},"./package.json":"./package.json","./dist/*.css":"./dist/*.css"},devDependencies:{"@biomejs/biome":"1.9.4","@changesets/cli":"^2.27.9","@radix-ui/react-popover":"^1.1.2","@tailwindcss/typography":"^0.5.15","@testing-library/dom":"^10.4.0","@testing-library/jest-dom":"^6.5.0","@testing-library/react":"^16.0.1","@types/lodash.debounce":"^4.0.9","@types/lodash.set":"^4.3.9","@types/node":"^20.14.8","@types/react":"^18.3.4","@types/react-dom":"^18.3.0","@types/tinycolor2":"^1.4.6","@uiw/react-iframe":"^1.0.3","@vitejs/plugin-react":"^4.3.4",autoprefixer:"^10.4.20",axios:"^1.7.5","class-variance-authority":"^0.7.0",jsdom:"^25.0.1",mutative:"^1.0.11",postcss:"^8.4.41","postcss-prefix-selector":"^1.16.1",react:"^18.3.1","react-dom":"^18.3.1","react-markdown":"^9.0.1","react-use":"^17.5.1","rehype-raw":"^7.0.0","remark-gfm":"^4.0.0","socket.io-client":"^4.7.5",swr:"^2.2.5","tailwind-merge":"^2.4.0",tailwindcss:"^3.4.6","tailwindcss-animate":"^1.0.7",typescript:"^5.5.4",vite:"^5.4.2","vite-plugin-dts":"4.0.3","vite-plugin-externalize-deps":"^0.8.0","vite-tsconfig-paths":"^5.0.1",vitest:"^2.0.5"}},D6=typeof window>"u",zv={getItem:()=>null,setItem:()=>{},removeItem:()=>{}};function L6(e){return D6?zv:e==="local"?localStorage:e==="session"?sessionStorage:zv}function yh(e,t,n="session"){const r=y.useMemo(()=>L6(n),[n]),[i,a]=y.useState(()=>{const l=r.getItem(e);if(l!==null)try{return JSON.parse(l)}catch(u){console.error(`Error parsing stored value for key '${e}':`,u)}return typeof t=="function"?t():t??null}),o=y.useCallback(l=>{if(a(l),l===null)r.removeItem(e);else try{r.setItem(e,JSON.stringify(l))}catch(u){console.error(`Error saving state to storage for key '${e}':`,u)}},[e,r]),s=y.useCallback(()=>{a(null),r.removeItem(e)},[e,r]);return y.useEffect(()=>{const l=u=>{u.key===e&&u.newValue!==JSON.stringify(i)&&a(u.newValue?JSON.parse(u.newValue):null)};return window.addEventListener("storage",l),()=>{window.removeEventListener("storage",l)}},[e,i]),[i,o,s]}function Uv(e,t){return function(){return e.apply(t,arguments)}}const{toString:M6}=Object.prototype,{getPrototypeOf:vh}=Object,xc=(e=>t=>{const n=M6.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Jn=e=>(e=e.toLowerCase(),t=>xc(t)===e),Ec=e=>t=>typeof t===e,{isArray:mo}=Array,Ys=Ec("undefined");function F6(e){return e!==null&&!Ys(e)&&e.constructor!==null&&!Ys(e.constructor)&&bn(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Hv=Jn("ArrayBuffer");function B6(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Hv(e.buffer),t}const j6=Ec("string"),bn=Ec("function"),Vv=Ec("number"),Tc=e=>e!==null&&typeof e=="object",z6=e=>e===!0||e===!1,_c=e=>{if(xc(e)!=="object")return!1;const t=vh(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},U6=Jn("Date"),H6=Jn("File"),V6=Jn("Blob"),$6=Jn("FileList"),W6=e=>Tc(e)&&bn(e.pipe),Y6=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||bn(e.append)&&((t=xc(e))==="formdata"||t==="object"&&bn(e.toString)&&e.toString()==="[object FormData]"))},q6=Jn("URLSearchParams"),[G6,K6,X6,Q6]=["ReadableStream","Request","Response","Headers"].map(Jn),Z6=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function qs(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,i;if(typeof e!="object"&&(e=[e]),mo(e))for(r=0,i=e.length;r<i;r++)t.call(null,e[r],r,e);else{const a=n?Object.getOwnPropertyNames(e):Object.keys(e),o=a.length;let s;for(r=0;r<o;r++)s=a[r],t.call(null,e[s],s,e)}}function $v(e,t){t=t.toLowerCase();const n=Object.keys(e);let r=n.length,i;for(;r-- >0;)if(i=n[r],t===i.toLowerCase())return i;return null}const _a=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Wv=e=>!Ys(e)&&e!==_a;function bh(){const{caseless:e}=Wv(this)&&this||{},t={},n=(r,i)=>{const a=e&&$v(t,i)||i;_c(t[a])&&_c(r)?t[a]=bh(t[a],r):_c(r)?t[a]=bh({},r):mo(r)?t[a]=r.slice():t[a]=r};for(let r=0,i=arguments.length;r<i;r++)arguments[r]&&qs(arguments[r],n);return t}const J6=(e,t,n,{allOwnKeys:r}={})=>(qs(t,(i,a)=>{n&&bn(i)?e[a]=Uv(i,n):e[a]=i},{allOwnKeys:r}),e),e4=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),t4=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},n4=(e,t,n,r)=>{let i,a,o;const s={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),a=i.length;a-- >0;)o=i[a],(!r||r(o,e,t))&&!s[o]&&(t[o]=e[o],s[o]=!0);e=n!==!1&&vh(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},r4=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},i4=e=>{if(!e)return null;if(mo(e))return e;let t=e.length;if(!Vv(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},a4=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&vh(Uint8Array)),o4=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let i;for(;(i=r.next())&&!i.done;){const a=i.value;t.call(e,a[0],a[1])}},s4=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},l4=Jn("HTMLFormElement"),u4=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,i){return r.toUpperCase()+i}),Yv=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),c4=Jn("RegExp"),qv=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};qs(n,(i,a)=>{let o;(o=t(i,a,e))!==!1&&(r[a]=o||i)}),Object.defineProperties(e,r)},d4=e=>{qv(e,(t,n)=>{if(bn(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(bn(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},f4=(e,t)=>{const n={},r=i=>{i.forEach(a=>{n[a]=!0})};return mo(e)?r(e):r(String(e).split(t)),n},p4=()=>{},h4=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t,xh="abcdefghijklmnopqrstuvwxyz",Gv="0123456789",Kv={DIGIT:Gv,ALPHA:xh,ALPHA_DIGIT:xh+xh.toUpperCase()+Gv},m4=(e=16,t=Kv.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function g4(e){return!!(e&&bn(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const w4=e=>{const t=new Array(10),n=(r,i)=>{if(Tc(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[i]=r;const a=mo(r)?[]:{};return qs(r,(o,s)=>{const l=n(o,i+1);!Ys(l)&&(a[s]=l)}),t[i]=void 0,a}}return r};return n(e,0)},y4=Jn("AsyncFunction"),v4=e=>e&&(Tc(e)||bn(e))&&bn(e.then)&&bn(e.catch),Xv=((e,t)=>e?setImmediate:t?((n,r)=>(_a.addEventListener("message",({source:i,data:a})=>{i===_a&&a===n&&r.length&&r.shift()()},!1),i=>{r.push(i),_a.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",bn(_a.postMessage)),b4=typeof queueMicrotask<"u"?queueMicrotask.bind(_a):typeof process<"u"&&process.nextTick||Xv,z={isArray:mo,isArrayBuffer:Hv,isBuffer:F6,isFormData:Y6,isArrayBufferView:B6,isString:j6,isNumber:Vv,isBoolean:z6,isObject:Tc,isPlainObject:_c,isReadableStream:G6,isRequest:K6,isResponse:X6,isHeaders:Q6,isUndefined:Ys,isDate:U6,isFile:H6,isBlob:V6,isRegExp:c4,isFunction:bn,isStream:W6,isURLSearchParams:q6,isTypedArray:a4,isFileList:$6,forEach:qs,merge:bh,extend:J6,trim:Z6,stripBOM:e4,inherits:t4,toFlatObject:n4,kindOf:xc,kindOfTest:Jn,endsWith:r4,toArray:i4,forEachEntry:o4,matchAll:s4,isHTMLForm:l4,hasOwnProperty:Yv,hasOwnProp:Yv,reduceDescriptors:qv,freezeMethods:d4,toObjectSet:f4,toCamelCase:u4,noop:p4,toFiniteNumber:h4,findKey:$v,global:_a,isContextDefined:Wv,ALPHABET:Kv,generateString:m4,isSpecCompliantForm:g4,toJSONObject:w4,isAsyncFn:y4,isThenable:v4,setImmediate:Xv,asap:b4};function ye(e,t,n,r,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i,this.status=i.status?i.status:null)}z.inherits(ye,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:z.toJSONObject(this.config),code:this.code,status:this.status}}});const Qv=ye.prototype,Zv={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{Zv[e]={value:e}}),Object.defineProperties(ye,Zv),Object.defineProperty(Qv,"isAxiosError",{value:!0}),ye.from=(e,t,n,r,i,a)=>{const o=Object.create(Qv);return z.toFlatObject(e,o,function(l){return l!==Error.prototype},s=>s!=="isAxiosError"),ye.call(o,e.message,t,n,r,i),o.cause=e,o.name=e.name,a&&Object.assign(o,a),o};const x4=null;function Eh(e){return z.isPlainObject(e)||z.isArray(e)}function Jv(e){return z.endsWith(e,"[]")?e.slice(0,-2):e}function eb(e,t,n){return e?e.concat(t).map(function(i,a){return i=Jv(i),!n&&a?"["+i+"]":i}).join(n?".":""):t}function E4(e){return z.isArray(e)&&!e.some(Eh)}const T4=z.toFlatObject(z,{},null,function(t){return/^is[A-Z]/.test(t)});function Sc(e,t,n){if(!z.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=z.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(w,x){return!z.isUndefined(x[w])});const r=n.metaTokens,i=n.visitor||c,a=n.dots,o=n.indexes,l=(n.Blob||typeof Blob<"u"&&Blob)&&z.isSpecCompliantForm(t);if(!z.isFunction(i))throw new TypeError("visitor must be a function");function u(g){if(g===null)return"";if(z.isDate(g))return g.toISOString();if(!l&&z.isBlob(g))throw new ye("Blob is not supported. Use a Buffer instead.");return z.isArrayBuffer(g)||z.isTypedArray(g)?l&&typeof Blob=="function"?new Blob([g]):Buffer.from(g):g}function c(g,w,x){let m=g;if(g&&!x&&typeof g=="object"){if(z.endsWith(w,"{}"))w=r?w:w.slice(0,-2),g=JSON.stringify(g);else if(z.isArray(g)&&E4(g)||(z.isFileList(g)||z.endsWith(w,"[]"))&&(m=z.toArray(g)))return w=Jv(w),m.forEach(function(b,T){!(z.isUndefined(b)||b===null)&&t.append(o===!0?eb([w],T,a):o===null?w:w+"[]",u(b))}),!1}return Eh(g)?!0:(t.append(eb(x,w,a),u(g)),!1)}const d=[],f=Object.assign(T4,{defaultVisitor:c,convertValue:u,isVisitable:Eh});function p(g,w){if(!z.isUndefined(g)){if(d.indexOf(g)!==-1)throw Error("Circular reference detected in "+w.join("."));d.push(g),z.forEach(g,function(m,v){(!(z.isUndefined(m)||m===null)&&i.call(t,m,z.isString(v)?v.trim():v,w,f))===!0&&p(m,w?w.concat(v):[v])}),d.pop()}}if(!z.isObject(e))throw new TypeError("data must be an object");return p(e),t}function tb(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Th(e,t){this._pairs=[],e&&Sc(e,this,t)}const nb=Th.prototype;nb.append=function(t,n){this._pairs.push([t,n])},nb.toString=function(t){const n=t?function(r){return t.call(this,r,tb)}:tb;return this._pairs.map(function(i){return n(i[0])+"="+n(i[1])},"").join("&")};function _4(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function rb(e,t,n){if(!t)return e;const r=n&&n.encode||_4,i=n&&n.serialize;let a;if(i?a=i(t,n):a=z.isURLSearchParams(t)?t.toString():new Th(t,n).toString(r),a){const o=e.indexOf("#");o!==-1&&(e=e.slice(0,o)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}class ib{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){z.forEach(this.handlers,function(r){r!==null&&t(r)})}}const ab={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},S4={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:Th,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},_h=typeof window<"u"&&typeof document<"u",Sh=typeof navigator=="object"&&navigator||void 0,k4=_h&&(!Sh||["ReactNative","NativeScript","NS"].indexOf(Sh.product)<0),C4=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",A4=_h&&window.location.href||"http://localhost",sn={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:_h,hasStandardBrowserEnv:k4,hasStandardBrowserWebWorkerEnv:C4,navigator:Sh,origin:A4},Symbol.toStringTag,{value:"Module"})),...S4};function R4(e,t){return Sc(e,new sn.classes.URLSearchParams,Object.assign({visitor:function(n,r,i,a){return sn.isNode&&z.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function N4(e){return z.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function O4(e){const t={},n=Object.keys(e);let r;const i=n.length;let a;for(r=0;r<i;r++)a=n[r],t[a]=e[a];return t}function ob(e){function t(n,r,i,a){let o=n[a++];if(o==="__proto__")return!0;const s=Number.isFinite(+o),l=a>=n.length;return o=!o&&z.isArray(i)?i.length:o,l?(z.hasOwnProp(i,o)?i[o]=[i[o],r]:i[o]=r,!s):((!i[o]||!z.isObject(i[o]))&&(i[o]=[]),t(n,r,i[o],a)&&z.isArray(i[o])&&(i[o]=O4(i[o])),!s)}if(z.isFormData(e)&&z.isFunction(e.entries)){const n={};return z.forEachEntry(e,(r,i)=>{t(N4(r),i,n,0)}),n}return null}function P4(e,t,n){if(z.isString(e))try{return(t||JSON.parse)(e),z.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(0,JSON.stringify)(e)}const Gs={transitional:ab,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",i=r.indexOf("application/json")>-1,a=z.isObject(t);if(a&&z.isHTMLForm(t)&&(t=new FormData(t)),z.isFormData(t))return i?JSON.stringify(ob(t)):t;if(z.isArrayBuffer(t)||z.isBuffer(t)||z.isStream(t)||z.isFile(t)||z.isBlob(t)||z.isReadableStream(t))return t;if(z.isArrayBufferView(t))return t.buffer;if(z.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let s;if(a){if(r.indexOf("application/x-www-form-urlencoded")>-1)return R4(t,this.formSerializer).toString();if((s=z.isFileList(t))||r.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return Sc(s?{"files[]":t}:t,l&&new l,this.formSerializer)}}return a||i?(n.setContentType("application/json",!1),P4(t)):t}],transformResponse:[function(t){const n=this.transitional||Gs.transitional,r=n&&n.forcedJSONParsing,i=this.responseType==="json";if(z.isResponse(t)||z.isReadableStream(t))return t;if(t&&z.isString(t)&&(r&&!this.responseType||i)){const o=!(n&&n.silentJSONParsing)&&i;try{return JSON.parse(t)}catch(s){if(o)throw s.name==="SyntaxError"?ye.from(s,ye.ERR_BAD_RESPONSE,this,null,this.response):s}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:sn.classes.FormData,Blob:sn.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};z.forEach(["delete","get","head","post","put","patch"],e=>{Gs.headers[e]={}});const I4=z.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),D4=e=>{const t={};let n,r,i;return e&&e.split(`
18
+ `).forEach(function(o){i=o.indexOf(":"),n=o.substring(0,i).trim().toLowerCase(),r=o.substring(i+1).trim(),!(!n||t[n]&&I4[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},sb=Symbol("internals");function Ks(e){return e&&String(e).trim().toLowerCase()}function kc(e){return e===!1||e==null?e:z.isArray(e)?e.map(kc):String(e)}function L4(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const M4=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function kh(e,t,n,r,i){if(z.isFunction(r))return r.call(this,t,n);if(i&&(t=n),!!z.isString(t)){if(z.isString(r))return t.indexOf(r)!==-1;if(z.isRegExp(r))return r.test(t)}}function F4(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function B4(e,t){const n=z.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(i,a,o){return this[r].call(this,t,i,a,o)},configurable:!0})})}class ln{constructor(t){t&&this.set(t)}set(t,n,r){const i=this;function a(s,l,u){const c=Ks(l);if(!c)throw new Error("header name must be a non-empty string");const d=z.findKey(i,c);(!d||i[d]===void 0||u===!0||u===void 0&&i[d]!==!1)&&(i[d||l]=kc(s))}const o=(s,l)=>z.forEach(s,(u,c)=>a(u,c,l));if(z.isPlainObject(t)||t instanceof this.constructor)o(t,n);else if(z.isString(t)&&(t=t.trim())&&!M4(t))o(D4(t),n);else if(z.isHeaders(t))for(const[s,l]of t.entries())a(l,s,r);else t!=null&&a(n,t,r);return this}get(t,n){if(t=Ks(t),t){const r=z.findKey(this,t);if(r){const i=this[r];if(!n)return i;if(n===!0)return L4(i);if(z.isFunction(n))return n.call(this,i,r);if(z.isRegExp(n))return n.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Ks(t),t){const r=z.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||kh(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let i=!1;function a(o){if(o=Ks(o),o){const s=z.findKey(r,o);s&&(!n||kh(r,r[s],s,n))&&(delete r[s],i=!0)}}return z.isArray(t)?t.forEach(a):a(t),i}clear(t){const n=Object.keys(this);let r=n.length,i=!1;for(;r--;){const a=n[r];(!t||kh(this,this[a],a,t,!0))&&(delete this[a],i=!0)}return i}normalize(t){const n=this,r={};return z.forEach(this,(i,a)=>{const o=z.findKey(r,a);if(o){n[o]=kc(i),delete n[a];return}const s=t?F4(a):String(a).trim();s!==a&&delete n[a],n[s]=kc(i),r[s]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return z.forEach(this,(r,i)=>{r!=null&&r!==!1&&(n[i]=t&&z.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
19
+ `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(i=>r.set(i)),r}static accessor(t){const r=(this[sb]=this[sb]={accessors:{}}).accessors,i=this.prototype;function a(o){const s=Ks(o);r[s]||(B4(i,o),r[s]=!0)}return z.isArray(t)?t.forEach(a):a(t),this}}ln.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),z.reduceDescriptors(ln.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),z.freezeMethods(ln);function Ch(e,t){const n=this||Gs,r=t||n,i=ln.from(r.headers);let a=r.data;return z.forEach(e,function(s){a=s.call(n,a,i.normalize(),t?t.status:void 0)}),i.normalize(),a}function lb(e){return!!(e&&e.__CANCEL__)}function go(e,t,n){ye.call(this,e??"canceled",ye.ERR_CANCELED,t,n),this.name="CanceledError"}z.inherits(go,ye,{__CANCEL__:!0});function ub(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new ye("Request failed with status code "+n.status,[ye.ERR_BAD_REQUEST,ye.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function j4(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function z4(e,t){e=e||10;const n=new Array(e),r=new Array(e);let i=0,a=0,o;return t=t!==void 0?t:1e3,function(l){const u=Date.now(),c=r[a];o||(o=u),n[i]=l,r[i]=u;let d=a,f=0;for(;d!==i;)f+=n[d++],d=d%e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),u-o<t)return;const p=c&&u-c;return p?Math.round(f*1e3/p):void 0}}function U4(e,t){let n=0,r=1e3/t,i,a;const o=(u,c=Date.now())=>{n=c,i=null,a&&(clearTimeout(a),a=null),e.apply(null,u)};return[(...u)=>{const c=Date.now(),d=c-n;d>=r?o(u,c):(i=u,a||(a=setTimeout(()=>{a=null,o(i)},r-d)))},()=>i&&o(i)]}const Cc=(e,t,n=3)=>{let r=0;const i=z4(50,250);return U4(a=>{const o=a.loaded,s=a.lengthComputable?a.total:void 0,l=o-r,u=i(l),c=o<=s;r=o;const d={loaded:o,total:s,progress:s?o/s:void 0,bytes:l,rate:u||void 0,estimated:u&&s&&c?(s-o)/u:void 0,event:a,lengthComputable:s!=null,[t?"download":"upload"]:!0};e(d)},n)},cb=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},db=e=>(...t)=>z.asap(()=>e(...t)),H4=sn.hasStandardBrowserEnv?function(){const t=sn.navigator&&/(msie|trident)/i.test(sn.navigator.userAgent),n=document.createElement("a");let r;function i(a){let o=a;return t&&(n.setAttribute("href",o),o=n.href),n.setAttribute("href",o),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=i(window.location.href),function(o){const s=z.isString(o)?i(o):o;return s.protocol===r.protocol&&s.host===r.host}}():function(){return function(){return!0}}(),V4=sn.hasStandardBrowserEnv?{write(e,t,n,r,i,a){const o=[e+"="+encodeURIComponent(t)];z.isNumber(n)&&o.push("expires="+new Date(n).toGMTString()),z.isString(r)&&o.push("path="+r),z.isString(i)&&o.push("domain="+i),a===!0&&o.push("secure"),document.cookie=o.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function $4(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function W4(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function fb(e,t){return e&&!$4(t)?W4(e,t):t}const pb=e=>e instanceof ln?{...e}:e;function Sa(e,t){t=t||{};const n={};function r(u,c,d){return z.isPlainObject(u)&&z.isPlainObject(c)?z.merge.call({caseless:d},u,c):z.isPlainObject(c)?z.merge({},c):z.isArray(c)?c.slice():c}function i(u,c,d){if(z.isUndefined(c)){if(!z.isUndefined(u))return r(void 0,u,d)}else return r(u,c,d)}function a(u,c){if(!z.isUndefined(c))return r(void 0,c)}function o(u,c){if(z.isUndefined(c)){if(!z.isUndefined(u))return r(void 0,u)}else return r(void 0,c)}function s(u,c,d){if(d in t)return r(u,c);if(d in e)return r(void 0,u)}const l={url:a,method:a,data:a,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:s,headers:(u,c)=>i(pb(u),pb(c),!0)};return z.forEach(Object.keys(Object.assign({},e,t)),function(c){const d=l[c]||i,f=d(e[c],t[c],c);z.isUndefined(f)&&d!==s||(n[c]=f)}),n}const hb=e=>{const t=Sa({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:i,xsrfCookieName:a,headers:o,auth:s}=t;t.headers=o=ln.from(o),t.url=rb(fb(t.baseURL,t.url),e.params,e.paramsSerializer),s&&o.set("Authorization","Basic "+btoa((s.username||"")+":"+(s.password?unescape(encodeURIComponent(s.password)):"")));let l;if(z.isFormData(n)){if(sn.hasStandardBrowserEnv||sn.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if((l=o.getContentType())!==!1){const[u,...c]=l?l.split(";").map(d=>d.trim()).filter(Boolean):[];o.setContentType([u||"multipart/form-data",...c].join("; "))}}if(sn.hasStandardBrowserEnv&&(r&&z.isFunction(r)&&(r=r(t)),r||r!==!1&&H4(t.url))){const u=i&&a&&V4.read(a);u&&o.set(i,u)}return t},Y4=typeof XMLHttpRequest<"u"&&function(e){return new Promise(function(n,r){const i=hb(e);let a=i.data;const o=ln.from(i.headers).normalize();let{responseType:s,onUploadProgress:l,onDownloadProgress:u}=i,c,d,f,p,g;function w(){p&&p(),g&&g(),i.cancelToken&&i.cancelToken.unsubscribe(c),i.signal&&i.signal.removeEventListener("abort",c)}let x=new XMLHttpRequest;x.open(i.method.toUpperCase(),i.url,!0),x.timeout=i.timeout;function m(){if(!x)return;const b=ln.from("getAllResponseHeaders"in x&&x.getAllResponseHeaders()),_={data:!s||s==="text"||s==="json"?x.responseText:x.response,status:x.status,statusText:x.statusText,headers:b,config:e,request:x};ub(function(R){n(R),w()},function(R){r(R),w()},_),x=null}"onloadend"in x?x.onloadend=m:x.onreadystatechange=function(){!x||x.readyState!==4||x.status===0&&!(x.responseURL&&x.responseURL.indexOf("file:")===0)||setTimeout(m)},x.onabort=function(){x&&(r(new ye("Request aborted",ye.ECONNABORTED,e,x)),x=null)},x.onerror=function(){r(new ye("Network Error",ye.ERR_NETWORK,e,x)),x=null},x.ontimeout=function(){let T=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const _=i.transitional||ab;i.timeoutErrorMessage&&(T=i.timeoutErrorMessage),r(new ye(T,_.clarifyTimeoutError?ye.ETIMEDOUT:ye.ECONNABORTED,e,x)),x=null},a===void 0&&o.setContentType(null),"setRequestHeader"in x&&z.forEach(o.toJSON(),function(T,_){x.setRequestHeader(_,T)}),z.isUndefined(i.withCredentials)||(x.withCredentials=!!i.withCredentials),s&&s!=="json"&&(x.responseType=i.responseType),u&&([f,g]=Cc(u,!0),x.addEventListener("progress",f)),l&&x.upload&&([d,p]=Cc(l),x.upload.addEventListener("progress",d),x.upload.addEventListener("loadend",p)),(i.cancelToken||i.signal)&&(c=b=>{x&&(r(!b||b.type?new go(null,e,x):b),x.abort(),x=null)},i.cancelToken&&i.cancelToken.subscribe(c),i.signal&&(i.signal.aborted?c():i.signal.addEventListener("abort",c)));const v=j4(i.url);if(v&&sn.protocols.indexOf(v)===-1){r(new ye("Unsupported protocol "+v+":",ye.ERR_BAD_REQUEST,e));return}x.send(a||null)})},q4=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,i;const a=function(u){if(!i){i=!0,s();const c=u instanceof Error?u:this.reason;r.abort(c instanceof ye?c:new go(c instanceof Error?c.message:c))}};let o=t&&setTimeout(()=>{o=null,a(new ye(`timeout ${t} of ms exceeded`,ye.ETIMEDOUT))},t);const s=()=>{e&&(o&&clearTimeout(o),o=null,e.forEach(u=>{u.unsubscribe?u.unsubscribe(a):u.removeEventListener("abort",a)}),e=null)};e.forEach(u=>u.addEventListener("abort",a));const{signal:l}=r;return l.unsubscribe=()=>z.asap(s),l}},G4=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let r=0,i;for(;r<n;)i=r+t,yield e.slice(r,i),r=i},K4=async function*(e,t){for await(const n of X4(e))yield*G4(n,t)},X4=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:n,value:r}=await t.read();if(n)break;yield r}}finally{await t.cancel()}},mb=(e,t,n,r)=>{const i=K4(e,t);let a=0,o,s=l=>{o||(o=!0,r&&r(l))};return new ReadableStream({async pull(l){try{const{done:u,value:c}=await i.next();if(u){s(),l.close();return}let d=c.byteLength;if(n){let f=a+=d;n(f)}l.enqueue(new Uint8Array(c))}catch(u){throw s(u),u}},cancel(l){return s(l),i.return()}},{highWaterMark:2})},Ac=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",gb=Ac&&typeof ReadableStream=="function",Q4=Ac&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),wb=(e,...t)=>{try{return!!e(...t)}catch{return!1}},Z4=gb&&wb(()=>{let e=!1;const t=new Request(sn.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),yb=64*1024,Ah=gb&&wb(()=>z.isReadableStream(new Response("").body)),Rc={stream:Ah&&(e=>e.body)};Ac&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Rc[t]&&(Rc[t]=z.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new ye(`Response type '${t}' is not supported`,ye.ERR_NOT_SUPPORT,r)})})})(new Response);const J4=async e=>{if(e==null)return 0;if(z.isBlob(e))return e.size;if(z.isSpecCompliantForm(e))return(await new Request(sn.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(z.isArrayBufferView(e)||z.isArrayBuffer(e))return e.byteLength;if(z.isURLSearchParams(e)&&(e=e+""),z.isString(e))return(await Q4(e)).byteLength},e5=async(e,t)=>{const n=z.toFiniteNumber(e.getContentLength());return n??J4(t)},Rh={http:x4,xhr:Y4,fetch:Ac&&(async e=>{let{url:t,method:n,data:r,signal:i,cancelToken:a,timeout:o,onDownloadProgress:s,onUploadProgress:l,responseType:u,headers:c,withCredentials:d="same-origin",fetchOptions:f}=hb(e);u=u?(u+"").toLowerCase():"text";let p=q4([i,a&&a.toAbortSignal()],o),g;const w=p&&p.unsubscribe&&(()=>{p.unsubscribe()});let x;try{if(l&&Z4&&n!=="get"&&n!=="head"&&(x=await e5(c,r))!==0){let _=new Request(t,{method:"POST",body:r,duplex:"half"}),S;if(z.isFormData(r)&&(S=_.headers.get("content-type"))&&c.setContentType(S),_.body){const[R,P]=cb(x,Cc(db(l)));r=mb(_.body,yb,R,P)}}z.isString(d)||(d=d?"include":"omit");const m="credentials"in Request.prototype;g=new Request(t,{...f,signal:p,method:n.toUpperCase(),headers:c.normalize().toJSON(),body:r,duplex:"half",credentials:m?d:void 0});let v=await fetch(g);const b=Ah&&(u==="stream"||u==="response");if(Ah&&(s||b&&w)){const _={};["status","statusText","headers"].forEach(B=>{_[B]=v[B]});const S=z.toFiniteNumber(v.headers.get("content-length")),[R,P]=s&&cb(S,Cc(db(s),!0))||[];v=new Response(mb(v.body,yb,R,()=>{P&&P(),w&&w()}),_)}u=u||"text";let T=await Rc[z.findKey(Rc,u)||"text"](v,e);return!b&&w&&w(),await new Promise((_,S)=>{ub(_,S,{data:T,headers:ln.from(v.headers),status:v.status,statusText:v.statusText,config:e,request:g})})}catch(m){throw w&&w(),m&&m.name==="TypeError"&&/fetch/i.test(m.message)?Object.assign(new ye("Network Error",ye.ERR_NETWORK,e,g),{cause:m.cause||m}):ye.from(m,m&&m.code,e,g)}})};z.forEach(Rh,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const vb=e=>`- ${e}`,t5=e=>z.isFunction(e)||e===null||e===!1,bb={getAdapter:e=>{e=z.isArray(e)?e:[e];const{length:t}=e;let n,r;const i={};for(let a=0;a<t;a++){n=e[a];let o;if(r=n,!t5(n)&&(r=Rh[(o=String(n)).toLowerCase()],r===void 0))throw new ye(`Unknown adapter '${o}'`);if(r)break;i[o||"#"+a]=r}if(!r){const a=Object.entries(i).map(([s,l])=>`adapter ${s} `+(l===!1?"is not supported by the environment":"is not available in the build"));let o=t?a.length>1?`since :
20
+ `+a.map(vb).join(`
21
+ `):" "+vb(a[0]):"as no adapter specified";throw new ye("There is no suitable adapter to dispatch the request "+o,"ERR_NOT_SUPPORT")}return r},adapters:Rh};function Nh(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new go(null,e)}function xb(e){return Nh(e),e.headers=ln.from(e.headers),e.data=Ch.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),bb.getAdapter(e.adapter||Gs.adapter)(e).then(function(r){return Nh(e),r.data=Ch.call(e,e.transformResponse,r),r.headers=ln.from(r.headers),r},function(r){return lb(r)||(Nh(e),r&&r.response&&(r.response.data=Ch.call(e,e.transformResponse,r.response),r.response.headers=ln.from(r.response.headers))),Promise.reject(r)})}const Eb="1.7.7",Oh={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Oh[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const Tb={};Oh.transitional=function(t,n,r){function i(a,o){return"[Axios v"+Eb+"] Transitional option '"+a+"'"+o+(r?". "+r:"")}return(a,o,s)=>{if(t===!1)throw new ye(i(o," has been removed"+(n?" in "+n:"")),ye.ERR_DEPRECATED);return n&&!Tb[o]&&(Tb[o]=!0,console.warn(i(o," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,o,s):!0}};function n5(e,t,n){if(typeof e!="object")throw new ye("options must be an object",ye.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let i=r.length;for(;i-- >0;){const a=r[i],o=t[a];if(o){const s=e[a],l=s===void 0||o(s,a,e);if(l!==!0)throw new ye("option "+a+" must be "+l,ye.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ye("Unknown option "+a,ye.ERR_BAD_OPTION)}}const Ph={assertOptions:n5,validators:Oh},Si=Ph.validators;class ka{constructor(t){this.defaults=t,this.interceptors={request:new ib,response:new ib}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let i;Error.captureStackTrace?Error.captureStackTrace(i={}):i=new Error;const a=i.stack?i.stack.replace(/^.+\n/,""):"";try{r.stack?a&&!String(r.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(r.stack+=`
22
+ `+a):r.stack=a}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=Sa(this.defaults,n);const{transitional:r,paramsSerializer:i,headers:a}=n;r!==void 0&&Ph.assertOptions(r,{silentJSONParsing:Si.transitional(Si.boolean),forcedJSONParsing:Si.transitional(Si.boolean),clarifyTimeoutError:Si.transitional(Si.boolean)},!1),i!=null&&(z.isFunction(i)?n.paramsSerializer={serialize:i}:Ph.assertOptions(i,{encode:Si.function,serialize:Si.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let o=a&&z.merge(a.common,a[n.method]);a&&z.forEach(["delete","get","head","post","put","patch","common"],g=>{delete a[g]}),n.headers=ln.concat(o,a);const s=[];let l=!0;this.interceptors.request.forEach(function(w){typeof w.runWhen=="function"&&w.runWhen(n)===!1||(l=l&&w.synchronous,s.unshift(w.fulfilled,w.rejected))});const u=[];this.interceptors.response.forEach(function(w){u.push(w.fulfilled,w.rejected)});let c,d=0,f;if(!l){const g=[xb.bind(this),void 0];for(g.unshift.apply(g,s),g.push.apply(g,u),f=g.length,c=Promise.resolve(n);d<f;)c=c.then(g[d++],g[d++]);return c}f=s.length;let p=n;for(d=0;d<f;){const g=s[d++],w=s[d++];try{p=g(p)}catch(x){w.call(this,x);break}}try{c=xb.call(this,p)}catch(g){return Promise.reject(g)}for(d=0,f=u.length;d<f;)c=c.then(u[d++],u[d++]);return c}getUri(t){t=Sa(this.defaults,t);const n=fb(t.baseURL,t.url);return rb(n,t.params,t.paramsSerializer)}}z.forEach(["delete","get","head","options"],function(t){ka.prototype[t]=function(n,r){return this.request(Sa(r||{},{method:t,url:n,data:(r||{}).data}))}}),z.forEach(["post","put","patch"],function(t){function n(r){return function(a,o,s){return this.request(Sa(s||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:o}))}}ka.prototype[t]=n(),ka.prototype[t+"Form"]=n(!0)});class Ih{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(i=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](i);r._listeners=null}),this.promise.then=i=>{let a;const o=new Promise(s=>{r.subscribe(s),a=s}).then(i);return o.cancel=function(){r.unsubscribe(a)},o},t(function(a,o,s){r.reason||(r.reason=new go(a,o,s),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Ih(function(i){t=i}),cancel:t}}}function r5(e){return function(n){return e.apply(null,n)}}function i5(e){return z.isObject(e)&&e.isAxiosError===!0}const Dh={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Dh).forEach(([e,t])=>{Dh[t]=e});function _b(e){const t=new ka(e),n=Uv(ka.prototype.request,t);return z.extend(n,ka.prototype,t,{allOwnKeys:!0}),z.extend(n,t,null,{allOwnKeys:!0}),n.create=function(i){return _b(Sa(e,i))},n}const mt=_b(Gs);mt.Axios=ka,mt.CanceledError=go,mt.CancelToken=Ih,mt.isCancel=lb,mt.VERSION=Eb,mt.toFormData=Sc,mt.AxiosError=ye,mt.Cancel=mt.CanceledError,mt.all=function(t){return Promise.all(t)},mt.spread=r5,mt.isAxiosError=i5,mt.mergeConfig=Sa,mt.AxiosHeaders=ln,mt.formToJSON=e=>ob(z.isHTMLForm(e)?new FormData(e):e),mt.getAdapter=bb.getAdapter,mt.HttpStatusCode=Dh,mt.default=mt;const a5="X-Bot-Token",o5="X-Widget-Version";function Sb(e){const t=y.useMemo(()=>mt.create({baseURL:e.apiUrl,headers:{[a5]:e.botToken,[o5]:wh,"X-Use-Guard":!0}}),[e]);return{apis:y.useMemo(()=>({createSession:r=>{if(!r)throw new Error("Bot token is required");return t.post("/chat-session/"+r)},fetchSession:r=>{if(!r)throw new Error("Session id is required");return t.get(`widget/session/${r}`)},fetchPreludeData:async()=>(await t.get("/widget/prelude")).data,getOfficeHours:()=>t.get("/copilot/office-hours/public"),fetchHistory:r=>{if(!r)throw new Error("Session id is required");return t.get(`widget/session/history/${r}`)},downvote:r=>t.delete(`/chat/vote/${r}`),upvote:r=>t.post(`/chat/vote/${r}`),dumpContact:r=>t.post("/widget/contact/upsert",r),getCompletions:r=>t.post("/widget/chat/completions",{input:r}),uploadFile:async(r,i)=>{const a=new FormData;return a.append("file",r.file),t.post(`/widget/upload?fileId=${r.id}`,a,{headers:{"Content-Type":"multipart/form-data"},...i})},getHistoryPooling:async({lastMessageTimestamp:r,sessionId:i})=>{const a=new URLSearchParams;return a.append("lastMessageTimestamp",r.toString()),t.get(`/widget/session/history/${i}/?${a.toString()}`)}}),[t]),options:e}}function Xs(e){const t=y.createContext({});return[()=>{const r=y.useContext(t);if(r===void 0)throw new Error("useSafeContext must be used within a Provider");return r},t.Provider]}const s5={en:{ok:"OK",yes:"Yes",no:"No",agree:"Agree",cancel:"Cancel","yes-exit":"Yes, exit","yes-reset":"Yes, reset","no-cancel":"No, cancel","are-you-sure":"Are you sure?",recording:"Recording...","thank-you":"Thank you","sorry-try-again":"Sorry, please try again","error-occurred":"An error occurred","please-try-again":"Please try again","write-a-message":"Write a message...","send-message":"Send message",connected:"Connected",connecting:"Connecting",reconnecting:"Reconnecting",reconnected:"Reconnected",disconnecting:"Disconnecting",disconnected:"Disconnected",error:"Error","persist-session":"Persist session",settings:"Settings",close:"Close",help:"Help",chat:"Chat",send:"Send",copy:"Copy",copied:"Copied","sound-effects":"Sound effects",language:"Language",select:"Select",agent:"Agent",user:"User",bot:"Bot","reset-conversation-confirm":"Are you sure you want to reset the conversation?","close-widget":"Close widget","got-any-questions":"Got any questions? Chat with us!","typical-response-time":"Typically respond in less than 1 minute","session-closed-lead":"Your issue has been resolved!","create-new-ticket":"Create new ticket",exit:"Exit","reset-conversation":"Reset conversation","welcome-title":"Welcome to our support chat","welcome-description":"We're here to help! Start a conversation and we'll get back to you as soon as possible.","your-name":"Your name","your-email":"Your email address","start-chat":"Talk to support","starting-chat":"Connecting...","hello-greeting":"Hi there!"},ar:{ok:"حسنا",yes:"نعم",no:"لا",agree:"موافق",cancel:"إلغاء","yes-exit":"نعم، اخرج","yes-reset":"نعم، إعادة تعيين","no-cancel":"لا، إلغاء","are-you-sure":"هل أنت متأكد؟",recording:"تسجيل","thank-you":"شكرا","sorry-try-again":"عذرا، حاول مرة أخرى","error-occurred":"حدث خطأ","please-try-again":"يرجى المحاولة مرة أخرى","write-a-message":"اكتب رسالة...","send-message":"إرسال رسالة",connected:"متصل",connecting:"جاري الاتصال",reconnecting:"جاري إعادة الاتصال",reconnected:"تم إعادة الاتصال",disconnecting:"جاري قطع الاتصال",disconnected:"قطع الاتصال",error:"خطأ","persist-session":"حفظ الجلسة",settings:"إعدادات",close:"إغلاق",help:"مساعدة",chat:"محادثة",send:"إرسال",copy:"نسخ",copied:"تم النسخ","sound-effects":"التاثيرات الصوتية",language:"اللغة",select:"اختر",agent:"الوكيل",user:"المستخدم",bot:"البوت","reset-conversation-confirm":"هل أنت متأكد من أنك تريد إعادة تعيين المحادثة؟","close-widget":"إغلاق الودجة","got-any-questions":"هل لديك أي أسئلة؟ تحدث معنا!","typical-response-time":"عادة ما نرد في أقل من دقيقة واحدة","session-closed-lead":"تم حل مشكلتك!",exit:"خروج","create-new-ticket":"إنشاء تذكرة جديدة","reset-conversation":"إعادة تعيين المحادثة","welcome-title":"مرحبًا بك في دردشة الدعم الخاصة بنا","welcome-description":"نحن هنا للمساعدة! ابدأ محادثة وسنرد عليك في أقرب وقت ممكن.","your-name":"اسمك","your-email":"عنوان بريدك الإلكتروني","start-chat":"تحدث إلى الدعم","starting-chat":"جاري الاتصال...","hello-greeting":"مرحبًا! كيف يمكننا مساعدتك اليوم؟"},nl:{ok:"OK",yes:"Ja",no:"Nee",agree:"Akkoord",cancel:"Annuleren","yes-exit":"Ja, afsluiten","yes-reset":"Ja, resetten","no-cancel":"Nee, annuleren","are-you-sure":"Weet u het zeker?",recording:"Opname...","thank-you":"Dank u","sorry-try-again":"Sorry, probeer het opnieuw","error-occurred":"Er is een fout opgetreden","please-try-again":"Probeer het opnieuw","write-a-message":"Schrijf een bericht...","send-message":"Bericht verzenden",connected:"Verbonden",connecting:"Verbinding maken",reconnecting:"Opnieuw verbinding maken",reconnected:"Opnieuw verbonden",disconnecting:"Verbinding verbreken",disconnected:"Verbinding verbroken",error:"Fout","persist-session":"Sessie behouden",settings:"Instellingen",close:"Sluiten",help:"Help",chat:"Chat",send:"Verzenden",copy:"Kopiëren",copied:"Gekopieerd","sound-effects":"Geluidseffecten",language:"Taal",select:"Selecteren",agent:"Agent",user:"Gebruiker",bot:"Bot","reset-conversation-confirm":"Weet u zeker dat u het gesprek wilt resetten?","close-widget":"Widget sluiten","got-any-questions":"Heeft u vragen? Chat met ons!","typical-response-time":"We reageren doorgaans binnen 1 minuut","session-closed-lead":"Uw probleem is opgelost!","create-new-ticket":"Nieuw ticket aanmaken",exit:"Afsluiten","reset-conversation":"Gesprek resetten","welcome-title":"Welkom bij onze supportchat","welcome-description":"We zijn hier om te helpen! Begin een gesprek en we nemen zo snel mogelijk contact met u op.","your-name":"Uw naam","your-email":"Uw e-mailadres","start-chat":"Praat met ondersteuning","starting-chat":"Verbinding maken...","hello-greeting":"Hallo! Hoe kunnen we u vandaag helpen?"},fr:{ok:"D'accord",yes:"Oui",no:"Non",agree:"Accepter",cancel:"Annuler","yes-exit":"Oui, quitter","yes-reset":"Oui, réinitialiser","no-cancel":"Non, annuler","are-you-sure":"Êtes-vous sûr ?",recording:"Enregistrement...","thank-you":"Merci","sorry-try-again":"Désolé, veuillez réessayer","error-occurred":"Une erreur s'est produite","please-try-again":"Veuillez réessayer","write-a-message":"Écrivez un message...","send-message":"Envoyer le message",connected:"Connecté",connecting:"Connexion en cours",reconnecting:"Reconnexion en cours",reconnected:"Reconnecté",disconnecting:"Déconnexion en cours",disconnected:"Déconnecté",error:"Erreur","persist-session":"Conserver la session",settings:"Paramètres",close:"Fermer",help:"Aide",chat:"Chat",send:"Envoyer",copy:"Copier",copied:"Copié","sound-effects":"Effets sonores",language:"Langue",select:"Sélectionner",agent:"Agent",user:"Utilisateur",bot:"Bot","reset-conversation-confirm":"Êtes-vous sûr de vouloir réinitialiser la conversation ?","close-widget":"Fermer le widget","got-any-questions":"Vous avez des questions ? Chattez avec nous !","typical-response-time":"Nous répondons généralement en moins d'une minute","session-closed-lead":"Votre problème a été résolu !","create-new-ticket":"Créer un nouveau ticket",exit:"Sortie","reset-conversation":"Réinitialiser la conversation","welcome-title":"Bienvenue dans notre chat de support","welcome-description":"Nous sommes là pour vous aider ! Commencez une conversation et nous vous répondrons dès que possible.","your-name":"Votre nom","your-email":"Votre adresse e-mail","start-chat":"Parler au support","starting-chat":"Connexion...","hello-greeting":"Bonjour ! Comment pouvons-nous vous aider aujourd'hui ?"},de:{ok:"OK",yes:"Ja",no:"Nein",agree:"Zustimmen",cancel:"Stornieren","yes-exit":"Ja, beenden","yes-reset":"Ja, zurücksetzen","no-cancel":"Nein, abbrechen","are-you-sure":"Sind Sie sicher?",recording:"Aufnahme läuft","thank-you":"Vielen Dank","sorry-try-again":"Entschuldigung, bitte versuchen Sie es erneut","error-occurred":"Ein Fehler ist aufgetreten","please-try-again":"Bitte versuchen Sie es erneut","write-a-message":"Nachricht schreiben...","send-message":"Nachricht senden",connected:"Verbunden",connecting:"Verbindung wird hergestellt",reconnecting:"Verbindung wird wiederhergestellt",reconnected:"Wieder verbunden",disconnecting:"Verbindung wird getrennt",disconnected:"Verbindung getrennt",error:"Fehler","persist-session":"Sitzung beibehalten",settings:"Einstellungen",close:"Schließen",help:"Hilfe",chat:"Chat",send:"Senden",copy:"Kopieren",copied:"Kopiert","sound-effects":"Soundeffekte",language:"Sprache",select:"Auswählen",agent:"Agent",user:"Benutzer",bot:"Bot","got-any-questions":"Haben Sie Fragen? Chatten Sie mit uns!","typical-response-time":"Üblicherweise antworten wir in weniger als 1 Minute","reset-conversation-confirm":"Möchten Sie die Konversation wirklich zurücksetzen?","close-widget":"Widget schließen","session-closed-lead":"Ihr Problem wurde gelöst!","create-new-ticket":"Neues Ticket erstellen",exit:"Beenden","reset-conversation":"Konversation zurücksetzen","welcome-title":"Willkommen in unserem Support-Chat","welcome-description":"Wir sind hier, um zu helfen! Beginnen Sie ein Gespräch und wir werden so schnell wie möglich antworten.","your-name":"Ihr Name","your-email":"Ihre E-Mail-Adresse","start-chat":"Mit dem Support sprechen","starting-chat":"Verbindung wird hergestellt...","hello-greeting":"Hallo! Wie können wir Ihnen heute helfen?"},pt:{ok:"OK",yes:"Sim",no:"Não",agree:"Concordo",cancel:"Cancelar","yes-exit":"Sim, sair","yes-reset":"Sim, redefinir","no-cancel":"Não, cancelar","are-you-sure":"Você tem certeza?",recording:"Gravando...","thank-you":"Obrigado","sorry-try-again":"Desculpe, tente novamente","error-occurred":"Ocorreu um erro","please-try-again":"Por favor, tente novamente","write-a-message":"Escreva uma mensagem...","send-message":"Enviar mensagem",connected:"Conectado",connecting:"Conectando",reconnecting:"Reconectando",reconnected:"Reconectado",disconnecting:"Desconectando",disconnected:"Desconectado",error:"Erro","persist-session":"Persistir sessão",settings:"Configurações",close:"Fechar",help:"Ajuda",chat:"Bate-papo",send:"Enviar",copy:"Copiar",copied:"Copiado","sound-effects":"Efeitos sonoros",language:"Idioma",select:"Selecionar",agent:"Agente",user:"Usuário",bot:"Bot","reset-conversation-confirm":"Você tem certeza de que deseja redefinir a conversa?","close-widget":"Fechar widget","got-any-questions":"Tem alguma dúvida? Converse conosco!","typical-response-time":"Geralmente respondemos em menos de 1 minuto","session-closed-lead":"Seu problema foi resolvido!","create-new-ticket":"Criar novo ticket",exit:"Sair","reset-conversation":"Redefinir conversa","welcome-title":"Bem-vindo ao nosso chat de suporte","welcome-description":"Estamos aqui para ajudar! Inicie uma conversa e responderemos o mais rápido possível.","your-name":"Seu nome","your-email":"Seu endereço de email","start-chat":"Falar com o suporte","starting-chat":"Conectando...","hello-greeting":"Olá! Como podemos ajudar você hoje?"}};function l5(e,t){const n=s5[t];return n&&n[e]||""}const[Qs,u5]=Xs();function kb({children:e}){const t=Bt();return E.jsx(u5,{value:{get:(n,r)=>l5(n,t.language??"en")+(r??""),lang:t.language},children:e})}class c5{constructor(t){u6(this,"components",[{key:"FALLBACK",component:t=>"fallback"},{key:"LOADING",component:t=>"loading"}]);const{components:n}=t;if(n&&n.forEach(r=>this.register(r)),this.components.length===0)throw new Error("No components registered");if(!this.get("FALLBACK"))throw new Error("No fallback component registered")}register(t){const n=this.components.findIndex(r=>r.key===t.key);return n!==-1?this.components[n]=t:this.components.push(t),this}get(t){const n=this.components.find(r=>r.key.toUpperCase()===t.toUpperCase());return n||null}getOrFallback(t){return t?this.get(t)||this.get("FALLBACK"):this.get("FALLBACK")}getComponent(t,n){var r;return n?this.getOrFallback(t).component:(r=this.get(t))==null?void 0:r.component}}const d5="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABlCAYAAAC7vkbxAAAACXBIWXMAACxLAAAsSwGlPZapAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAACd2SURBVHgB7X15lGZHdd+99b6vu2dfNNIghIgEYonELhkQIGDACB8WOUAsMBgbjA9yYiIHEjA2OO4Tzsk5JCeHBIEd2+AQUBJHAmFAQiBrQ4A2tDHDKEH7vs1oZnqme7q/5dXNrap7a3nf6+nu6ZmR/qD6vP7eV69evXp3+d2l6r0P4FflV+VXZf6C8DQuRGS+dt99Yx/7zuPrBp3hJgN4VLcDGwDN+g7iKiJYwTfQ5ZYVIFogHBLCXF3XM2RpL3/ZXVewq7N/sPN5R6/f9V8/+JLeFsQhPI3L04ohzAB826U3rLntYTqOiX/KjtnBS7n6ZCbyc5FgIxmzlofcWXyPlrj9LN/kk9z3I7y/rVuZX6wbN7etm4V737fzlbsnJ5mRT6PylDPkAqLqC1/dvu7W/q4XD2vaYhBfBmRewJTcjEQrWfY7rAnoyWbceM3SxswdkTuDO+P9ITO2z59PVpW5t7ZwC/d25abxVbf9u5cPHj/ntNMG8BSXp4QhThNe+o2tK3eb3sk7pvrvZkq9tiY6mYezBslpgCc6OmqSIXeGRdLxLp0hzEj/IX2kI+4PaYYV6d6xqnP1+vHuZXtruOGrG07dffbZWMNTUI4oQyYnyVz0nGs3Pbi3etOMHb4LjH0NU+QYPsRMQBOHQzoshzjun6U0XnPox0y++yH3Ps08um2ia769ultdftagc+ffnHNkteaIMGSSjfNXvnrd+qm+fd2Q4A+GQ3gdV68Fw5SPIzggQ7SN2w7fmL0aoSWsZ1lCfs4wecHm1cP/c++H3vgE4pGxNYeVIQ6aXvh33139JD3j9dO9wfvI2jMt4Ea+aYMOLJxotjIkHyFlNY5TBg7fgMNGhkeJDJ41zPH1t41X5r+Nb1jxw4+97+WPTR5mxhw2hpz619S9b8W1Z+zr2w/RAH+Dbep6rq6S+HONEEC+m6edFx7HRj1TwU3GmC+fumb1D37ygZfshsNUDg8FLtg+NrHvyd+rrf0cX2ITWmMgswJayMmalSP0NGSIluSp7eH459vdavxT+845bScchnJoKcAQteHrP34xuy1/TkP8Z8ZihTXzwqEM0si12HeCgEl8zGLWDQh8tPhGh3P88xXvjzl5qT1jEMw2Y6s/e9F4ddnNh9joH7IbOun869fu7vXfPUPwaarsiVCbjvaP4S7cjRXXI/Fsna1p7TSgNXlsi/CWNzVHhiF+FPLp5IOFBy3uHevgFzevPfq8u3/3pCfgEJXl3xAT87iv37hxX907lwOtjxJUx9TGkVpFHgNDHNEbDpINDJGbpba+g5I4xrjAzgcU3A85f8D3jXCA0w9XoeCRuG2/MfSdcYTPTv2L193Lw1n2KJbFECfZGy669dnDfdOfZpq9j1mwznAsTAYksDvwRSxhOzVJT6cEX8En9ceotnI8eWWkXbSR5FDqkdgT44fmA9cayVy70lSf+Pg/fdXPJ7csL1d20EN1zDjuwp8ev7dff5HH+OtctdKTzHokwsXECx6JAhwFakfkcoR3hoeC4c+JbBOTSF3gjBlRo7QcLi+Z9D49X5yffMOEwf/0268cu+RvlpGCOSiGOGac+K3rXvBk3/4Hzqr+prNyAVIyV4oW13cy4JikPD9um/uU2jse5pcV5pXaUijr4SxOnG6f6MKfvHXDwz+48OyzDyr1suSROmYcf/ENJ+2ZnvsSD+EM7mGCP72sqG+bwTukigUuaTPiu9gLM2kXzYnIpTxpMtGSutJZncDcyAUPA5O8ptDWFeOdz3xl3QM/PPsgmFLBEsv/PuWtx+2s587j2zmT4+2OV1tnMzj2RvdZhRDPZad87waCBTTBJvv2KrT5BhIamnR3qMdM2PzxjNGaSNHNcQNDuiXUQWrg7e1iBGM5JYjlMXVtT7/cHr31U6945gNXX331kgz9kkb1sm/fuv6+wdQXrIEPsNRV/ta9AUePWFkGquyZcixrXFIgx8cklNXpSRaL4aqWjNgKV632pc7GYaukWVaudURgzN6yfqJ6746PnH73UryvRY/qnd+9aeVPe/s/zS7FJ5n6Y07sHFJ53AAcIXWRjmqt1apARKqNQBMV7ague9B9bztsgixE6cdtw7x7TPapljGQ1LeWQ8YoHp29rEL70dk/esODiz1pUVd/41VXdbbvMu/hOPUv68psQBXNYDqW4aklt1WJxgnICFVkKaobSZvoiQknSCL6wr6wClPUPIj89U6A9mlV26ih0odGe8RtHPCE21+eBOs/u/2PTplezHkLOoXOiG/d290yNPSnPHu6HgXGA0azjjBwLWkz2YbWS3b4zvuV9W2ivTCK//qdxI5QpBuKIcGWfZTBRrOjNiqeS7HNIUcwLzvY5Ym3D9xrp9770b++qbuY0xacnz7ue1cfxZ3/MXbhFGutCTeBYi9tcq0WWcgmrAjdCO6rra9UqhHESun9idSrgeAaG+QpeNxB+hFUiQRGXROxT/4yBkGBEah0EGhJd3LAuyTtlOV50wDtx79ZD7fz+G/ABezJATXkty64gGe08behwi0uFWLMgNOFQ0txCwZkKZthgujmNMAxJXyHmAjhdAQY1aZK963UByK7OtNhjTK1Pxa1Ss4z2XngtM+fD+E6buukTbzBzMNbdglya6PMvWDa1p9Y++UrNi504vxDYFrfsOHYLX2sP2aqeswRomKHxc8sFfADB78VUKQwFpJEEU6KczAQTqEo1mFymbUeYeR8g6KFynxxqeO+wteyS+rQ64MDdoK3z9GK957CUxMHOnNeyHrWD3+4YaYa+7d8w8+pnE8qQOvyVGhU63FRmYlCR/PQGxOU6C2Q5A99RhX1bIEiK8BmkrF2EIcerlDWLFCYWhGXy4c9KF9rsU+uWwd3GNqQ7uqw7KGEr9A3d7mCafmxB/btuZWh6/r5oKuVIc6QP+eqq/55j+i13JsJ6XO1GxjSTGJCMIswoNU4UgpD1FOSoksX1EYrFfwSk2hfkhss6XqxBZl77HmcqOq8wOh9KePyGIcCpsSYRry44HdpMi6c286YpXlinnyeDPS8Xo/++KWXXbaVq2fa2rYy5Iyf/GT9HMB7KoQVHuCztQjk8yQyLPFU4jBbmE75ZxDuPEqM6oFSQ6ABJo0EmIFIIQhVzSEZiF6b8iuTCFBWG40+xi7k+iT1GGOacIM0EoAeVAlT8Q7xt+x5dN0Lef/mtmatiLMDh+9lCXy1wz5QuE5bhs/k7YpubqLWG95iAzHeYTqp4n+VnG94x3Rkq4zsu08+1iXvBntDXCUbYTpc7zdnkE0amNuXvoKr67w09JAWHYgqbMZgdIdz+xTdX7nhkAYamcZZVrFEG6bm6Pe/eOed423HRy71r+688+iLHrn/cr7lFxkKfofLmTHrYjSIoiSeQDBfSTBDmqWOsJC30IEEsXUwYVX6balhIZmofZEYHIEVDQalt5iityjQEyQ9KpfN2kg7TXAW9bF9tj9CwoU4RlCcSbijIvOBuXNPv7ytt6K88Cc/+r3pYf0lvu9VlQABGeYr1oIghoXOxJ7n90pKchdp8qycvGo1nHnU0fy5xu8fqJcFD9LSznXHp/o1b0PYumsavnz7w3D/vn5kIMkEGgkDNR822u/S/GWeceQMFF742p39D149uaWY0CqoefoFF6x4fPNRl/QBXu/jJzRBQ9yqSpPCt6pNiQWG0nc15Fg4Vjr4tZ0OnHvcCfD7z3wWPJ3K+Xc9AZ+68R7YMzcsZjRj8tNrUZMlS2RIMG47n7Fh4s0Pvf/UrfP2NP2sZ7ySFeDULsMxYz16DOetqjzuM0xzlYH2dEnu+2NwRXVxQ2oXDP/xE+Nw8UtOe9oxw5XfOekYuO6sl8GGlZW3V95mNWMkA8uzK0640W6cme6/3y2vLQ7pDtuOcU4evosJv7rDlizObXRCdFvxP8ObM8ouwBrZTCNPJYbSaCTu24UI+7MnPA+eNT4BT9fyT1ZPwN9vOVmyByn41QA0zrHAwRYXDxFOD4dnXX7atnX5kej23rlz57FDsm9ACfs8WAm7JECGA6KyPyfzI2P7YPSsZFnftekZ8JYNm4pTp+oh3D07AzsHfQFsdYIxfaWyxxRDNG41r6OSBpDNp+ixLhN2w1gHTl67ClZ10nzdGZvXwe889xj4BkNYcpUpibD0d1AuMepY8YTH9s46F/g6PRQZ8iDOngoVnUQyn+MJjJQlASQ2nH8iIZIxBRjySSYwmHffvenY4py9zIzrpnbBAGQlScaQgrAN4sYqyk6LJ4knllWFoBxLf4c/Z90YhkN4ZLYHbzhmA6zvptDsA8/dDOff8/iIEPj9KHu4gPfQUsQ75DGN75mhX5/cvv3myVNO6btDnt8fpZu63YpeB1W9Ejhh5zbDgYzjTcVnGc0tGbEDcSttCKQcOJScDOev7VbwytUbirHdMj3l3dwKQ3wS4hTZF5jzuT+BvQoT/Pl9yVFV2abHtG0F+TmQ+pZz3eZ8yOt3ThVjc1qybrwTxENybrogS+sOalULRULB1Nzwjdc9iEfpIS8O+34x3MiJ9VcbBv1ak9cGdHa2Ifmg36TLXGdz5aGRuuMnVkBe9rF29DidXrUsQCymWUvFCd8BS2XFhnaJSJOIM8VKEPXCTFFC4zmG1f1DCys7iconsD3ZOpgJgbZrZqR9vu7vYHJfkmIgsi/+5RPTz+cvj7la4/JWe+zwxAHUz/aObiaBgGmhQQxi/XBsYwIIYxolbalepWptp1xTMSSKEq0ZgAoh04QkwUlr1KblWpRpgYGoCapdrk1H+wSI1/N9GncsZRD21+VCkXXjldx/w5M0wvEcCSKxabEw5qLstY/u6/+aSlfnQrZrj3V6L2OOb/QCkPw58gl9DaJFjtKFbRCYBSYR/CoyCURGc10kq3Mxq1HmhxvOgu+oEakXyVNFxRAtwcyUgFaFtvmzQLlxUOVqurOBARaSZc9GqtpnwsKakBmAzIa20wZzbTdmrEZ4NXzjMgcfM53PbbtkFdH4S/nCYwJSOqvio3CjqiH12LCuCz2/EoaFcu1ygIGhbScp4RMsCN1agnMsjW7OXCppWK7dw9ImR4FvckQGScKslKQIn161KQSLNtCIFoNfWRPGrRceZ9ZteNgxZALXrO5B/yQT1jD7roxJo0r8yNZJ6a1jG4ma94PqM44QHwVGQo/qLkGU9rgrNiBJL6b24DNtnumFoyWuleh4SQttKNMmIn+t2WqIkIuFDfPpf4WmXIEMxRWUiyp+/gY2mMG4cz8f6rBZ3UxoT3TQ47K1HvYNxvSA2AA1QZg/roEAi4hYo2UduWG1GYG0piHp8WwoIY0K9HAjqxAjbaJnLkw11Ey+h3OJMiJmrvPI/Yh3CZrMdEW9LVklqXNEvkqlIV9ntkBhsq7f1Zs9idXh5g53+EyGkjVh9SH56UDfqBIDjko6yu1LvD9sVowUGTyEuKZZTNQGClKOInx6NskNN64RPSw55vqxFpIpgejIFI/8JPjOOIoQ5z9G+IEQ0/K6gCA6ljl8mdBJca1FLST1FBhjdTjh3Evv6nZozG5muJqwRhPg1lMu2NWYFAf5GuGrBW3nL6hG3bYMB9NNqSFHzNYJKwOafTYE0NFVgs8EdXK+PKQFWAaLMqhCQ0aGrpBlUIJLygREoSz1qs+oEqobsSgqVf3aPvu8Rx8f61RoNjLLx0J2N1zHiEFXaQsfclG5eLXgpXBkt2HTQTLHsU0BT4TZRw5Zaa8gIGIZqxTtsdE3FAxVbdLYtigmGXM/llp60tgjzT9ng1NYNYuDLXKPANlNMEMTHc7kbiBZcx0AI8wo+9m+7GbTOBGgjRnY1ICU9InLPVsALhp10tbZwYxyTY+TMrwMdAkPVunJlLm/KmkE7RwjnJ9uKIYOZQILIF1bF3DHJ/YSihae24IlCNP6FeO4gmMiWq1wJAddtOjtuhhhOZQI3ApWSA0vymZ7mG6uUQR61bOUK8i9FHaiZE4+N58NIsYdBrOF2QDRkwKAMhbB7DyAFkELzoiu86AIUUmzI+ph0mgU8U7LWVpoVhDCrLRDcJAF41YTe2LEjXsqLYTqWN6qQGYrKSA6BK5UWZshQDS8zXNMJukgRIqMwbwaoynIe6CC4rGL9v1MYmMgqFUjfeslJNYSvPUeVzQ4lOROFyva3L5YWTkJB8rJhmJhHKpu1eEJp/Gka0ErUDUysx+jq0tapL3YT+2dS31Ahug9gUpb2X+QeoIRL6iALtEeIA1si/PDjsKauiZCRMJc4MsxSso9vEwI4+rGBMMybkd0XQViU1sfubu6hTwujs7J9jo8F2V4UlC4bdJqds0j6aDKGCJpy4h4y0fuJVXyOR9kNUjQ6u1Q4Y2l5T+ZHU2MgRzumtCGsXm5H763wbHmLf2VhSGeAQgJsgTJwnFMx40MtybMBH+0GLdKo3ILbmT9KwR+KNFCAjHcpV+2A7JKsYWoLTQt6pQ5nSZpsDTqUa6xSShIUIaBudGitUB00ybFznAUbAsxa1H8fLrWy72HINHh6ERRvIHCoIur7CfnjXc0xMMxMHqlIJpsQ2xtxQ9Jrm6QFI07AjPS8WRYkpxhE0uyotGracQhSYAg9h1tApQeUiHpVHaSOwMNtGskJzNnAEe7AmgTLmzRAhFayWZQfhwTVGkkEgnZovkZkXjmo08dNt59RSMPTYAZFAXPSQmnkbvJAVcma0bzmlF2IrPa4MmMona7i5tXZe6tZ6FQONkgiOI+6lHJ14w4MUGL0DIaSATOmOIZHIgh8CSMUGdB7YfvJFPZ+ZiC0IPx8WGnQ5bnZZwqojgywhSQOQUQw8bikLS3HLaB+aP2XKPaMrt5OqaALa3LiBTZUHAMy4eqIsFy6kPUJOVL1G2imO5vo1V0bIzAVG4n9LkU0APhYqhUxPCdFLpU8y2Nst6YHg5h6Iz6PkM2MFDXHLuYAkK4KBNV/mqJ8CVm4Ej3TTNKxc2leijWDERNgmw9bqYhsS5qMECaO88GgRl8lU0TQ7BxUSjbxmKCx6tvBonJEEko+pK/WCIDD3n3gYe26A16LwxGC9kZU0Pf2ZApXRkaICuol/H9kUKK782IJJUeVy3437yT1MaCOg31yL0bwRj1ZBIN051FG0FJP2PvmQOgicgEV5Qkn3SZuBzLISzxHtqyCSH7DQnKFRdNlKCQ3VUJs+nc0mPM3SzRN1nSzzSdmkWa7TD+7YKKajfYCtLLKpwBRkEyHXkMCnFU4nHkZvTaFMcx6vZi5m8ErDG5DmaEUq41hL5sEzVEMsCAEQbjubKSP59eL0dUFpMuHSTeSocZ44OnQMl50kceSBOSoCnsoO++2qWvSPAM3RMYO2F8pt+hDjzCZ+yvkFZ2kIJQqR0xmeeVETxMacZv8p9a4wwQqaWWmwVoBoZYEiYnWkukWzABdKYuSF9kHDYoj7ktguQFAfhE50QjA3r79HRkYJ4Fwfwa+fAa0BUrEaIgB9mjlMlxUQrgfZw46XW6hI+x8d7Fd7MJgkHwzfLAMNwYyOE0ZyJkSLalbTpXwNTPdzQYFucaqLwXGu2lkGiFgry3YA5yqjTgQsafu74kGkliUNZ0ysdlHpqbg311HbXfM0VmBLM5sDRPImyK8ydyj5C8NAQq74/YcHB/dccx5ENv7Hc41ftEr6L7BkTPj497+Y7E+8juupILJMKGKbPkKs9XgjRVLW0qvSnAhKzptKKm6X2NXIXyK5Zjb2oISico8LOGY+RVVcmQ//LAvXyzwe6hW+xnMSRKTaG6iTs6VyLpFqgEr9zTwU4ohTkR4izoSKaOWzVx510MPR0cW7XH2L33cLrdx5MmE1eDSeq0r6ARGdkyuzZvwfj+pbIaMhiEojsPH2uqsXZ1macsoWlRqhZpeqg3B9984tFiTAm7IIvIMYtuG/ClBh5xFNbkU0Blx1zVf9ztdF51/8TctSfMbLM0HHLePT4hqmudAEq3VhONKaZIrJiPKTYuGRo9NhoYBmasNl1ImbUjW9zS0vfffoukPqixbiGnfPLL4oSng4G6cBcFtbldrc9bYsQvr18G7ngIV+1xzY173/lKHLuVD085Qrj+/MIxCEtI/ZJSt7nH1+QxNV1eWhVbWH6atrQEVRe94Txz6vnmFrQpM+igZf7gy0P9OThr+43wcH9Wxi/jlnvxE3cZnPu1ayZbapstqPPoRJlAu1Ui5N+aRPo2Cvf6DWb69fDBl7hlxmEp6aqxsXtmerMMmOBe+00mmcAsfxXDL4lH5pmoapTcSGPLsXz5jruBldjNYOzIqceN03vgij1PwEU7H4OpwTB6GBqZo75pSLG7eNk2ScLuwBpdzFU5LoU3T+xlFv0M5JBnyPNWj++e6neu58j9VY5vaSmpEiblq8KyzmaSsJx/T1cNxS2m9gaqOUDAaEfc5wp5/VZevjV7F/xo7uH4iFlY0xtQwZlbnTlw9bUNa7RqT59gbN05iiDupTRWacf1ro1bOfpwr+fbWUnGegm3ogJO6m0idOYURg8xZIExeF9a7zyreedAMrfS4Hac3X+30toz5Bw8bXDO7kuv6RB8pEZYhXEiMmkFiotooKQ7gT7ZDQAHWLFXemclU1y/41iNMOMf5u6Ei3gLD3s6YpkYzQeiC7EpRPHKkKEQ1z+SwsSsZWjWVkW9+6xt4EAavxptiukVVCIXnhRAXOCQ2wuEbBKMIE/U6totz0TJoa2fqK54/Rue9fiF/yb0EoV2PXVuYr/ujkpw3MjUZbQJ3rsK+yKngTCyDfnbECDbqNhq177FhlSeGaOa8R1mhGOIUacCk6YDpLXxuYDkbfQ4IOqrTLxLg2LfAjFlpVtc8UbSd8pyq/76axmKEJX6aKBUpChlAwxusGejCeE7+jfw0exRK8w/XijPhrgSHW+q9+/uVuM/tta+ArLBxIwvQJSQCAsQ8kOLNb3NZyXdbY5hZwR2v9e7i7e7/dSvCqAj0zDAblzAYBriqXKJmWtqRBvyet9ajxmMIYEyMCUsmwXTHDmkGCaPeXT1I5nUV1aEg4KNFu7fuGZ4R94g8nPlprNmuqa+iFV1vzsnLv2HgJHBDgQtGFCpCXVja9MO3crbG7WBF/fugO/yFjwyeZ+WSK2XfJNrAGUakfY19soFKTkjJW2MSrkeUxiC/DPXhqQlsR9tE0G8vMH4WEb2XCCjhYOafzh2/6N7oY0hk6zLL1u98kbm7E01c9C5sh0JAgkSA/rMlDkmVJ839xjagPsdWLdRsc1R2HoUvrtnQe6zU3Cgckn/Dvg+b8bjtw0Qk7nfRl94Ft1qcZcBYj1COObGXgEVMZR6hxHbi2wEzc+USNhyK4wzjPqSUePS+ZgYi7urDv79hWefbVsZ4sqHccvcChj7Gkumc/wiutbOG5HNa4qrE4l3z37U0LJRtsn3fbYP/69u/1GBHwzuhMuYGZVKM5RP+aIEqvFdH3FThwHK9vr6jJZrqZE2je85/dSjxFzKmysv9RhAMZbYvpkr8hruPQInOZd98v7Xb4dGgmEkuD59zVEXs2Td5aEXUoSamBBsRx3rwuZe5dyXbQC5sU+b+/6F2RvhmkF6J+R+GsCFve1wSe+XRTzin28ElWj1pHU2kyKkqRHOBLm4x6QRaomaFE3wV0p6o1lz1U1kBiWlwOxDISwNKlUaeoL//13bL8S1CRB8fN+l/7JHg89bxNU5I4LEJ2ao+6mkiW90pfyFwILVEIy48yLc/jHVKtgIY7CbZmGW2aV47yVX7n1IIXXp8q21N4LBiA8oxDXe77N12KfKw6JbAW/V7QVxgS1I/GHAvTbefXd96iIQW4cJKO+o+OOhvua4RZ9wq2U61R/z7TG6z35fHtixdXDNHZGsPyb1AyOrTizfSv1X++sHPgUf/vBck/at6acXrj76f/Kp1/KZ5JjgbrTHN86EoKGvI74O+dfkKnOc1gx927AlyAovirEZ3LntiXoG7qn3wF7bi8TzGwUtcPDUQShinwAnpngSV+MYtSX+U57YjQFrixgqDPqvmQeQw6E+h5j3g7lRauu60JYWbQOz88TVq7/axox5GfJROHUvdfCbnGSZFQ1gIUCFsOi9D4Fi5OulRfcBIDEq1OUQl6COIjNLeMyzwyUcpY0yAmFru0gZVIsKpREHAMwnjbJ6gHa64yhCLaLEVdlDvsiV1ao9d83XspUhbnJ970r8JkPGNUNk1WC9UN+cbQH1uAl7UNgn721Rj3Wmzw2c7XBw4jwxbgNzfiOGpOBthY3rZOtnx/vRTXY2iLwHF16TY31A2sHwGUAsswWF4S7dTlSJlxsNr/oIniOCutVqxFPSsJVQDoblgSC/TyVzRokYbU8A0I7b4Na6rr+09cwz98NSGOLK/4J37OlC58tM3Lv5bGQiuc3DFxOO/EbBy/J1cfOvNqS8ri72A5QpPOlnDmtqk/Sh0wqT11XOz2ChDdpeY7KCMZFO6n3lMASFQU7eUnrMOsRAaQyLeLGZ57qfY63cglCcrkz9ldkVT9wIB3hV7PzzSu45hTX4jxxHn8dy1GMj6MhIQxT3l9S7chE0OmJjdIsp30ooUoKL3dPXscdoWY+HW6IRCMrcepF0SK4nlMRXbdH6FMDpsQLYRkkQXdhGAyyvmV0q7oRnTsIj0z4INPQ9xLFvwQK/mHDAib7z8G29sbVwvq07V7IXQawtKJE3MpSxxgDOyubgqRc27GH67mAs2odob8hPWqlb7JjalyBTH11ITm3D3YQsmJPcVNggzEdkZ44WanwupuRR+AHbEKDmScj/sE1Y2eiwtv7l2Dh8aeq3Tl/w5/bMQg2+hu/aY031F8yA2xyr3UJgnzqRLQWNQLV4YH6zVgLJ4O35n/agMGPm45hMi0igK2gKxc0V9aIUtnKDmmbhG8UzB7KXM8vNNgNFzDPQmDkIo/21FgmI0juIMb3DkXWjcoBlYWdlzX98yWq6daG3WvsxwiLKK9a97ZZxqD4/QbiHIHhbCjfRu2pCFUC0C8FTy4gOCaK0HvJjRWAHgK0eFB3Qy1GGlW3mo0eCNlhU+7KNwmbRiWeSrSuqz+/s3nvR1Vu29BbR2eIYMsk9n7hv8D2Oc76A3jkKHJASNMQ6rwvyzXtUPbfvPDNniMCtKMZkd8Sr8vMVensSeNaRgVkEjQHqLNLIoxbp6SKBLEGaEPHrwoysaJ/Q4iohACwozM5IZN6B27cy++HnJnwId6mpxv7zzo/85j5YJE4uiiGufOH4s2fHqT6PYfIbTNuag9VITAjj8e+OzOOS6EkxmvpnJlVjQIw3JY0gWv4MOs5TgzBqA4JTMF9Z7Eialt6f50NmZsrPjhqvP77z1ssfgyUUhCWWd8/84NiHevv+ljO4b3NEl9lnbyNqyhf2y02je2ubj3j9hFlH3FIXAbsX1+rbeiYwJA7d8TEG4Y7fN9CVOp/6Z7UYUNCeMD1rJCsQUifW+4FhFtClSUIKBVWDfYLGSurEp100YepTHyE1MqzdvpW0iJG23OcQ5HdJ5Hx3rKY4G1l7b8S9m4S5YfHurh3+4aNvf/PVi7EbeVm0hmi5aNVvPDpmVpzLKZtL2QXueYAgTZu4PFPNgWHtRkUO1YLW+KlWtCMOKSxNJEhTKc0HIEQDvK8psh9hJ6dHaYWWV8SzUpOHkuky5pbxqvOxM/bvumapzAA4CIa48uN1b79383D9v2YP5WIm+JyVe5T8W7DZmAKO5UKRllEPKy/UaLXc0ua9UctxsUHuxWOV+eWEqf7kkalHrjzYn81b8Add2gqGl6Pf9cp93/9Mv7efxcK+g4e1IoxNDBtlJMtW0C+n0Mg3nL8VtZ2zyJLe1B/CP71UqNPXK1DUD+ejGHP9CuxOfvhNr/nR5DJ+c/2gNEQHfeOat91ZEX2GGfJXjLnTRnKjkn0lSS8oh9o8l3np1fQi9UuYi7Fgm1DkAwFNfQoFnR0BjAnN3LFewo1mUBi+ut/61aeoGCV6HaqvGLfwCWbG1cthhisHzxA/HqTbjzn7ruPx2MlubT7fIdgbAjL/0zLzhVllF/pPVwcsWCj7v+AAFyb/4h0q0lxO5Q0Gi6CpZyu038LB3CcfvPZHtyyXGeEyh6h8iK6auGnHk2f1afg5zoSe5F5iiOKSG59fA7/yqisX7QQvizryzuYJt4/hQYcJ712FyNktNq4KL0s9m6AB0cvyHpR6WShelvGZZz8n49dstXpZxB4WFl6Wr/OvF+d6EyavbHiDmHvrSO3993o3B1VfPL7Gv/3pW97yKByEAW8rh4whrji79mu7v31Krzf4c7ZO72LN7piQfIpTzO7BePdLE+5N2eMsaX7fMQAhur0TEfYaDLEumESJYYJLm9xeE5OZgSGyEC66vW4yjRNLnrhxptOneJzL7NaAtDNEZv0YJ/l8d320VN/E02d/NvazbT++69xz3SzCofJbDs6oz1fEzfvFJG3/4Pce3/a77AL+e67Y7NM7Gn8A6dtBSWOQfLGb9FR801RLPBoxPc8Mp8/k4sX0PLWtHlvUuxFlOP736WrazaO9YIO1f7H1tVsO2Y/a52V5NmSeMomn9J+z2XydSf++MYP/g9Vkt67xCnMVGFI9mnkQ2+EZBI2UOAYvJ5/Hj+vEQOhPcQ6FUoYAwC7OgNMBv4a1QtNcfw11O3+4fg7+dOtrztwBh6kcUshqK+985LsrB+P9MxgR/oAJ9xaG5NXuR266PoNrMDx67RY/EHXdDzJAWu6j79rFMPEVom7QRdHo4ShAFgTIcgzhBkMykvQMEXuAJhe0BsjKppp9vbchbtIi/No0Dd13V1NzjFXj9RyI/neambri/1657XGYnFy24T5QOewMccXZlnPh0rEd+/CtM4P95zCRX22N+wlXZ+jJE969uKsruuIXOID8IgNIwjES0WQMMX4OpZalnd52Mx2HbJni5FiAL2e4oe8JDxKsYjTqnJjzDBla144ncnlWmq/y89oOv9afw4tf/sD0owcb6C21HBGGaHGMOWfnD58xXfXeNGfsOznV8rquMZt5VrLqsmHoiHa4QXUlgNFHL3w+iYJBJgzpGNYEFC/Jx6TsCFkn7TX7dH65D/ilOCEj7aI3yYDGxxFAGOKcADbaQwt72HP7Oc9jXPjsFWsuefn53394cnJyqYHLssoRZUhe3njvVRObj5k+mQaD9zBTXsMxzIvZU17vfvfK/3gMhpf2DcSbis+HCNSQMsSGX5X3xK9lVSVLudqSYYAocin/2i2dkckyn192E6AA+5kZDzO0Xcms+f5gx/CGbWe8wz1edsSYkJenjCFaJhn898NPV03t2/0iU8GbzZBOZ9B4PqciNjJN1jDRqyHjW98nKwBk9YtPcA/ZTwuZ3exHoPnfQAnPZwwkm8uxkR1YY2u3SAZhBycR7uWM9W0MmVcMsXvz9Se+eScD5hGBpQOVp5whRWGaT+64YNVeXPXMzgS9qEf2VLLVK1iMn78f4Si2yKv17V6eIeEBHFKb4mI396IPbxN86tUST5TtR2t2TVh7P3t9t1oau2XcVNsGg5mHXnXSit2TsKUGfGq0oa38f1JavN8hxQxDAAAAAElFTkSuQmCC",f5={primaryColor:"hsl(0,0%,0%)",triggerOffset:"20px"};function p5(e){return y.useMemo(()=>{var i,a,o,s;const t={messageArrived:"https://cloud.opencopilot.so/sfx/notification3.mp3",...e.soundEffectFiles},n=Object.assign({},f5,e.theme??{}),r={id:"555",is_ai:!0,profile_picture:((i=e.bot)==null?void 0:i.avatarUrl)||d5,name:((a=e.bot)==null?void 0:a.name)||"Bot"};return{...e,bot:r,apiUrl:e.apiUrl??"https://api-v2.opencopilot.so/backend",socketUrl:e.socketUrl??"https://api-v2.opencopilot.so",language:e.language??m5,botToken:e.token,headers:e.headers??{},pathParams:e.pathParams??{},queryParams:e.queryParams??{},user:e.user??{},theme:n,soundEffectFiles:t,collectUserData:e.collectUserData??!1,defaultSettings:{persistSession:((o=e.settings)==null?void 0:o.persistSession)??!1,useSoundEffects:((s=e.settings)==null?void 0:s.useSoundEffects)??!1}}},[e])}const[Bt,h5]=Xs(),m5="en";function g5({children:e,data:t}){const n=y.useMemo(()=>new c5({components:t.components}),[t]),r=p5(t),i=Sb({apiUrl:r.apiUrl,botToken:r.token}),[a,o]=yh("open_settings",r.defaultSettings,"local"),s=l=>{const u=Object.assign({},r.defaultSettings,a,l);o(u)};return E.jsx(h5,{value:{...r,http:i,componentStore:n,widgetSettings:a,setSettings:s},children:E.jsx(kb,{children:e})})}var Cb={},Lh=function(e,t){return Lh=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},Lh(e,t)};function Ab(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Lh(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var St=function(){return St=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},St.apply(this,arguments)};function Zs(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function Rb(e,t,n,r){var i=arguments.length,a=i<3?t:r===null?r=Object.getOwnPropertyDescriptor(t,n):r,o;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a}function Nb(e,t){return function(n,r){t(n,r,e)}}function Ob(e,t,n,r,i,a){function o(m){if(m!==void 0&&typeof m!="function")throw new TypeError("Function expected");return m}for(var s=r.kind,l=s==="getter"?"get":s==="setter"?"set":"value",u=!t&&e?r.static?e:e.prototype:null,c=t||(u?Object.getOwnPropertyDescriptor(u,r.name):{}),d,f=!1,p=n.length-1;p>=0;p--){var g={};for(var w in r)g[w]=w==="access"?{}:r[w];for(var w in r.access)g.access[w]=r.access[w];g.addInitializer=function(m){if(f)throw new TypeError("Cannot add initializers after decoration has completed");a.push(o(m||null))};var x=(0,n[p])(s==="accessor"?{get:c.get,set:c.set}:c[l],g);if(s==="accessor"){if(x===void 0)continue;if(x===null||typeof x!="object")throw new TypeError("Object expected");(d=o(x.get))&&(c.get=d),(d=o(x.set))&&(c.set=d),(d=o(x.init))&&i.unshift(d)}else(d=o(x))&&(s==="field"?i.unshift(d):c[l]=d)}u&&Object.defineProperty(u,r.name,c),f=!0}function Pb(e,t,n){for(var r=arguments.length>2,i=0;i<t.length;i++)n=r?t[i].call(e,n):t[i].call(e);return r?n:void 0}function Ib(e){return typeof e=="symbol"?e:"".concat(e)}function Db(e,t,n){return typeof t=="symbol"&&(t=t.description?"[".concat(t.description,"]"):""),Object.defineProperty(e,"name",{configurable:!0,value:n?"".concat(n," ",t):t})}function Lb(e,t){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(e,t)}function Wr(e,t,n,r){function i(a){return a instanceof n?a:new n(function(o){o(a)})}return new(n||(n=Promise))(function(a,o){function s(c){try{u(r.next(c))}catch(d){o(d)}}function l(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?a(c.value):i(c.value).then(s,l)}u((r=r.apply(e,t||[])).next())})}function Mb(e,t){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},r,i,a,o=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(u){return function(c){return l([u,c])}}function l(u){if(r)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(n=0)),n;)try{if(r=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return n.label++,{value:u[1],done:!1};case 5:n.label++,i=u[1],u=[0];continue;case 7:u=n.ops.pop(),n.trys.pop();continue;default:if(a=n.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){n.label=u[1];break}if(u[0]===6&&n.label<a[1]){n.label=a[1],a=u;break}if(a&&n.label<a[2]){n.label=a[2],n.ops.push(u);break}a[2]&&n.ops.pop(),n.trys.pop();continue}u=t.call(e,n)}catch(c){u=[6,c],i=0}finally{r=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}var Nc=Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]};function Fb(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&Nc(t,e,n)}function Oc(e){var t=typeof Symbol=="function"&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Mh(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,a=[],o;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)a.push(i.value)}catch(s){o={error:s}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}return a}function Bb(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Mh(arguments[t]));return e}function jb(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;for(var r=Array(e),i=0,t=0;t<n;t++)for(var a=arguments[t],o=0,s=a.length;o<s;o++,i++)r[i]=a[o];return r}function Pc(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,a;r<i;r++)(a||!(r in t))&&(a||(a=Array.prototype.slice.call(t,0,r)),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}function wo(e){return this instanceof wo?(this.v=e,this):new wo(e)}function zb(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=n.apply(e,t||[]),i,a=[];return i=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),s("next"),s("throw"),s("return",o),i[Symbol.asyncIterator]=function(){return this},i;function o(p){return function(g){return Promise.resolve(g).then(p,d)}}function s(p,g){r[p]&&(i[p]=function(w){return new Promise(function(x,m){a.push([p,w,x,m])>1||l(p,w)})},g&&(i[p]=g(i[p])))}function l(p,g){try{u(r[p](g))}catch(w){f(a[0][3],w)}}function u(p){p.value instanceof wo?Promise.resolve(p.value.v).then(c,d):f(a[0][2],p)}function c(p){l("next",p)}function d(p){l("throw",p)}function f(p,g){p(g),a.shift(),a.length&&l(a[0][0],a[0][1])}}function Ub(e){var t,n;return t={},r("next"),r("throw",function(i){throw i}),r("return"),t[Symbol.iterator]=function(){return this},t;function r(i,a){t[i]=e[i]?function(o){return(n=!n)?{value:wo(e[i](o)),done:!1}:a?a(o):o}:a}}function Hb(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof Oc=="function"?Oc(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(a){n[a]=e[a]&&function(o){return new Promise(function(s,l){o=e[a](o),i(s,l,o.done,o.value)})}}function i(a,o,s,l){Promise.resolve(l).then(function(u){a({value:u,done:s})},o)}}function Vb(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var w5=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};function $b(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var n in e)n!=="default"&&Object.prototype.hasOwnProperty.call(e,n)&&Nc(t,e,n);return w5(t,e),t}function Wb(e){return e&&e.__esModule?e:{default:e}}function Yb(e,t,n,r){if(n==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?r:n==="a"?r.call(e):r?r.value:t.get(e)}function qb(e,t,n,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,n):i?i.value=n:t.set(e,n),n}function Gb(e,t){if(t===null||typeof t!="object"&&typeof t!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e=="function"?t===e:e.has(t)}function Kb(e,t,n){if(t!=null){if(typeof t!="object"&&typeof t!="function")throw new TypeError("Object expected.");var r,i;if(n){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose],n&&(i=r)}if(typeof r!="function")throw new TypeError("Object not disposable.");i&&(r=function(){try{i.call(this)}catch(a){return Promise.reject(a)}}),e.stack.push({value:t,dispose:r,async:n})}else n&&e.stack.push({async:!0});return t}var y5=typeof SuppressedError=="function"?SuppressedError:function(e,t,n){var r=new Error(n);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};function Xb(e){function t(a){e.error=e.hasError?new y5(a,e.error,"An error was suppressed during disposal."):a,e.hasError=!0}var n,r=0;function i(){for(;n=e.stack.pop();)try{if(!n.async&&r===1)return r=0,e.stack.push(n),Promise.resolve().then(i);if(n.dispose){var a=n.dispose.call(n.value);if(n.async)return r|=2,Promise.resolve(a).then(i,function(o){return t(o),i()})}else r|=1}catch(o){t(o)}if(r===1)return e.hasError?Promise.reject(e.error):Promise.resolve();if(e.hasError)throw e.error}return i()}function Qb(e,t){return typeof e=="string"&&/^\.\.?\//.test(e)?e.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i,function(n,r,i,a,o){return r?t?".jsx":".js":i&&(!a||!o)?n:i+a+"."+o.toLowerCase()+"js"}):e}const v5=c6(Object.freeze(Object.defineProperty({__proto__:null,__addDisposableResource:Kb,get __assign(){return St},__asyncDelegator:Ub,__asyncGenerator:zb,__asyncValues:Hb,__await:wo,__awaiter:Wr,__classPrivateFieldGet:Yb,__classPrivateFieldIn:Gb,__classPrivateFieldSet:qb,__createBinding:Nc,__decorate:Rb,__disposeResources:Xb,__esDecorate:Ob,__exportStar:Fb,__extends:Ab,__generator:Mb,__importDefault:Wb,__importStar:$b,__makeTemplateObject:Vb,__metadata:Lb,__param:Nb,__propKey:Ib,__read:Mh,__rest:Zs,__rewriteRelativeImportExtension:Qb,__runInitializers:Pb,__setFunctionName:Db,__spread:Bb,__spreadArray:Pc,__spreadArrays:jb,__values:Oc,default:{__extends:Ab,__assign:St,__rest:Zs,__decorate:Rb,__param:Nb,__esDecorate:Ob,__runInitializers:Pb,__propKey:Ib,__setFunctionName:Db,__metadata:Lb,__awaiter:Wr,__generator:Mb,__createBinding:Nc,__exportStar:Fb,__values:Oc,__read:Mh,__spread:Bb,__spreadArrays:jb,__spreadArray:Pc,__await:wo,__asyncGenerator:zb,__asyncDelegator:Ub,__asyncValues:Hb,__makeTemplateObject:Vb,__importStar:$b,__importDefault:Wb,__classPrivateFieldGet:Yb,__classPrivateFieldSet:qb,__classPrivateFieldIn:Gb,__addDisposableResource:Kb,__disposeResources:Xb,__rewriteRelativeImportExtension:Qb}},Symbol.toStringTag,{value:"Module"})));var Ic={},Zb;function b5(){if(Zb)return Ic;Zb=1,Object.defineProperty(Ic,"__esModule",{value:!0});var e=y;function t(){var n=e.useRef(!1),r=e.useCallback(function(){return n.current},[]);return e.useEffect(function(){return n.current=!0,function(){n.current=!1}},[]),r}return Ic.default=t,Ic}Object.defineProperty(Cb,"__esModule",{value:!0});var Fh=v5,Bh=y,x5=Fh.__importDefault(b5());function E5(e,t,n){t===void 0&&(t=[]),n===void 0&&(n={loading:!1});var r=Bh.useRef(0),i=x5.default(),a=Bh.useState(n),o=a[0],s=a[1],l=Bh.useCallback(function(){for(var u=[],c=0;c<arguments.length;c++)u[c]=arguments[c];var d=++r.current;return o.loading||s(function(f){return Fh.__assign(Fh.__assign({},f),{loading:!0})}),e.apply(void 0,u).then(function(f){return i()&&d===r.current&&s({value:f,loading:!1}),f},function(f){return i()&&d===r.current&&s({error:f,loading:!1}),f})},t);return[o,l]}var Js=Cb.default=E5;const Yr=(e=20)=>{const t="abcdefghijklmnopqrstuvwxyz0123456789";let n="";for(let r=0;r<e;r++)n+=t[Math.floor(Math.random()*t.length)];return n},ki=new Map;function T5(){const[e,t]=y.useState([]),{http:n}=Bt();function r(c){const d=c.map(f=>({file:f,id:Yr(10),status:"pending",progress:0}));t(f=>[...f,...d]),d.forEach(o)}function i(c,d){t(f=>f.map(p=>p.id===c?{...p,...d}:p))}function a(c){t(d=>d.filter(f=>f.id!==c))}const o=async c=>{const d=new AbortController;ki.set(c.id,d);try{t(p=>p.map(g=>g.id===c.id?{...g,status:"uploading",progress:0}:g));const f=await n.apis.uploadFile(c,{signal:d.signal,onUploadProgress:p=>{if(!p.total)return;const g=Math.round(p.loaded*100/p.total);i(c.id,{progress:g})}});i(c.id,{status:"success",fileUrl:f.data.fileUrl,progress:100})}catch(f){d.signal.aborted||i(c.id,{status:"error",error:f instanceof Error?f.message:"Upload failed",progress:0})}finally{ki.delete(c.id)}},s=c=>{const d=ki.get(c);d&&(d.abort(),ki.delete(c)),a(c)},l=y.useMemo(()=>e.filter(c=>c.status==="success"&&c.fileUrl),[e]);function u(){ki.forEach(c=>c.abort()),ki.clear(),t([])}return y.useEffect(()=>()=>{ki.forEach(c=>c.abort()),ki.clear()},[]),{allFiles:e,appendFiles:r,handleCancelUpload:s,successFiles:l,emptyTheFiles:u,getFileById:c=>e.find(d=>d.id===c),getUploadProgress:c=>{var d;return((d=e.find(f=>f.id===c))==null?void 0:d.progress)??0},getUploadStatus:c=>{var d;return(d=e.find(f=>f.id===c))==null?void 0:d.status},hasErrors:e.some(c=>c.status==="error"),isUploading:e.some(c=>c.status==="uploading")}}const _5="[data-chat-widget-content-root]";function Jb({fallbackHeight:e}){const t=y.useRef(null);return y.useEffect(()=>{const n=document.querySelector(_5);if(n&&t.current){const r=t.current;let i;const a=new ResizeObserver(()=>{i=requestAnimationFrame(()=>{const o=Math.max(r.offsetHeight,e);n.style.setProperty("--opencx-widget-height",o.toFixed(1)+"px")})});return a.observe(r),()=>{cancelAnimationFrame(i),a.unobserve(r)}}},[]),{observedElementRef:t}}const dt={Remove:"remove",Replace:"replace",Add:"add"},ex=Symbol.for("__MUTATIVE_PROXY_DRAFT__"),S5=Symbol("__MUTATIVE_RAW_RETURN_SYMBOL__"),Dc=Symbol.iterator,xn={mutable:"mutable",immutable:"immutable"},jh={};function el(e,t){return e instanceof Map?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function tx(e,t){if(t in e){let n=Reflect.getPrototypeOf(e);for(;n;){const r=Reflect.getOwnPropertyDescriptor(n,t);if(r)return r;n=Reflect.getPrototypeOf(n)}}}function En(e){var t;return(t=e.copy)!==null&&t!==void 0?t:e.original}function Ca(e){return!!Pe(e)}function Pe(e){return typeof e!="object"?null:e==null?void 0:e[ex]}function zh(e){var t;const n=Pe(e);return n?(t=n.copy)!==null&&t!==void 0?t:n.original:e}function er(e,t){if(!e||typeof e!="object")return!1;let n;return Object.getPrototypeOf(e)===Object.prototype||Array.isArray(e)||e instanceof Map||e instanceof Set||!!(t!=null&&t.mark)&&((n=t.mark(e,xn))===xn.immutable||typeof n=="function")}function nx(e,t=[]){if(Object.hasOwnProperty.call(e,"key")){const n=e.parent.copy,r=Pe(qr(n,e.key));if(r!==null&&(r==null?void 0:r.original)!==e.original)return null;const i=e.parent.type===3,a=i?Array.from(e.parent.setMap.keys()).indexOf(e.key):e.key;if(!(i&&n.size>a||el(n,a)))return null;t.push(a)}if(e.parent)return nx(e.parent,t);t.reverse();try{k5(e.copy,t)}catch{return null}return t}function Aa(e){return Array.isArray(e)?1:e instanceof Map?2:e instanceof Set?3:0}function qr(e,t){return Aa(e)===2?e.get(t):e[t]}function tl(e,t,n){Aa(e)===2?e.set(t,n):e[t]=n}function Uh(e,t){const n=Pe(e);return(n?En(n):e)[t]}function Gr(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function Hh(e){if(e)for(;e.finalities.revoke.length>0;)e.finalities.revoke.pop()()}function Ra(e,t){return t?e:[""].concat(e).map(n=>{const r=`${n}`;return r.indexOf("/")===-1&&r.indexOf("~")===-1?r:r.replace(/~/g,"~0").replace(/\//g,"~1")}).join("/")}function k5(e,t){for(let n=0;n<t.length-1;n+=1){const r=t[n];if(e=qr(Aa(e)===3?Array.from(e):e,r),typeof e!="object")throw new Error(`Cannot resolve patch at '${t.join("/")}'.`)}return e}function C5(e){const t=Object.create(Object.getPrototypeOf(e));return Reflect.ownKeys(e).forEach(n=>{let r=Reflect.getOwnPropertyDescriptor(e,n);if(r.enumerable&&r.configurable&&r.writable){t[n]=e[n];return}r.writable||(r.writable=!0,r.configurable=!0),(r.get||r.set)&&(r={configurable:!0,writable:!0,enumerable:r.enumerable,value:e[n]}),Reflect.defineProperty(t,n,r)}),t}const A5=Object.prototype.propertyIsEnumerable;function rx(e,t){let n;if(Array.isArray(e))return Array.prototype.concat.call(e);if(e instanceof Set)return new Set(e.values());if(e instanceof Map)return new Map(e);if(t!=null&&t.mark&&(n=t.mark(e,xn),n!==void 0)&&n!==xn.mutable){if(n===xn.immutable)return C5(e);if(typeof n=="function"){if(t.enablePatches||t.enableAutoFreeze)throw new Error("You can't use mark and patches or auto freeze together.");return n()}throw new Error(`Unsupported mark result: ${n}`)}else if(typeof e=="object"&&Object.getPrototypeOf(e)===Object.prototype){const r={};return Object.keys(e).forEach(i=>{r[i]=e[i]}),Object.getOwnPropertySymbols(e).forEach(i=>{A5.call(e,i)&&(r[i]=e[i])}),r}else throw new Error("Please check mark() to ensure that it is a stable marker draftable function.")}function Qt(e){e.copy||(e.copy=rx(e.original,e.options))}function nl(e){if(!er(e))return zh(e);if(Array.isArray(e))return e.map(nl);if(e instanceof Map)return new Map(Array.from(e.entries()).map(([n,r])=>[n,nl(r)]));if(e instanceof Set)return new Set(Array.from(e).map(nl));const t=Object.create(Object.getPrototypeOf(e));for(const n in e)t[n]=nl(e[n]);return t}function Lc(e){return Ca(e)?nl(e):e}function Er(e){var t;e.assignedMap=(t=e.assignedMap)!==null&&t!==void 0?t:new Map,e.operated||(e.operated=!0,e.parent&&Er(e.parent))}function ix(){throw new Error("Cannot modify frozen object")}function yo(e,t,n,r,i){{n=n??new WeakMap,r=r??[],i=i??[];const o=n.has(e)?n.get(e):e;if(r.length>0){const s=r.indexOf(o);if(o&&typeof o=="object"&&s!==-1)throw r[0]===o?new Error("Forbids circular reference"):new Error(`Forbids circular reference: ~/${i.slice(0,s).map((l,u)=>{if(typeof l=="symbol")return`[${l.toString()}]`;const c=r[u];return typeof l=="object"&&(c instanceof Map||c instanceof Set)?Array.from(c.keys()).indexOf(l):l}).join("/")}`);r.push(o),i.push(t)}else r.push(o)}if(Object.isFrozen(e)||Ca(e)){r.pop(),i.pop();return}switch(Aa(e)){case 2:for(const[s,l]of e)yo(s,s,n,r,i),yo(l,s,n,r,i);e.set=e.clear=e.delete=ix;break;case 3:for(const s of e)yo(s,s,n,r,i);e.add=e.clear=e.delete=ix;break;case 1:Object.freeze(e);let o=0;for(const s of e)yo(s,o,n,r,i),o+=1;break;default:Object.freeze(e),Object.keys(e).forEach(s=>{const l=e[s];yo(l,s,n,r,i)})}r.pop(),i.pop()}function Vh(e,t){const n=Aa(e);if(n===0)Reflect.ownKeys(e).forEach(r=>{t(r,e[r],e)});else if(n===1){let r=0;for(const i of e)t(r,i,e),r+=1}else e.forEach((r,i)=>t(i,r,e))}function ax(e,t,n){if(Ca(e)||!er(e,n)||t.has(e)||Object.isFrozen(e))return;const r=e instanceof Set,i=r?new Map:void 0;if(t.add(e),Vh(e,(a,o)=>{var s;if(Ca(o)){const l=Pe(o);Qt(l);const u=!((s=l.assignedMap)===null||s===void 0)&&s.size||l.operated?l.copy:l.original;tl(r?i:e,a,u)}else ax(o,t,n)}),i){const a=e,o=Array.from(a);a.clear(),o.forEach(s=>{a.add(i.has(s)?i.get(s):s)})}}function R5(e,t){const n=e.type===3?e.setMap:e.copy;e.finalities.revoke.length>1&&e.assignedMap.get(t)&&n&&ax(qr(n,t),e.finalities.handledSet,e.options)}function $h(e){e.type===3&&e.copy&&(e.copy.clear(),e.setMap.forEach(t=>{e.copy.add(zh(t))}))}function Wh(e,t,n,r){if(e.operated&&e.assignedMap&&e.assignedMap.size>0&&!e.finalized){if(n&&r){const a=nx(e);a&&t(e,a,n,r)}e.finalized=!0}}function Yh(e,t,n,r){const i=Pe(n);i&&(i.callbacks||(i.callbacks=[]),i.callbacks.push((a,o)=>{var s;const l=e.type===3?e.setMap:e.copy;if(Gr(qr(l,t),n)){let u=i.original;i.copy&&(u=i.copy),$h(e),Wh(e,r,a,o),e.options.enableAutoFreeze&&(e.options.updatedValues=(s=e.options.updatedValues)!==null&&s!==void 0?s:new WeakMap,e.options.updatedValues.set(u,i.original)),tl(l,t,u)}}),e.options.enableAutoFreeze&&i.finalities!==e.finalities&&(e.options.enableAutoFreeze=!1)),er(n,e.options)&&e.finalities.draft.push(()=>{const a=e.type===3?e.setMap:e.copy;Gr(qr(a,t),n)&&R5(e,t)})}function N5(e,t,n,r,i){let{original:a,assignedMap:o,options:s}=e,l=e.copy;l.length<a.length&&([a,l]=[l,a],[n,r]=[r,n]);for(let u=0;u<a.length;u+=1)if(o.get(u.toString())&&l[u]!==a[u]){const c=t.concat([u]),d=Ra(c,i);n.push({op:dt.Replace,path:d,value:Lc(l[u])}),r.push({op:dt.Replace,path:d,value:Lc(a[u])})}for(let u=a.length;u<l.length;u+=1){const c=t.concat([u]),d=Ra(c,i);n.push({op:dt.Add,path:d,value:Lc(l[u])})}if(a.length<l.length){const{arrayLengthAssignment:u=!0}=s.enablePatches;if(u){const c=t.concat(["length"]),d=Ra(c,i);r.push({op:dt.Replace,path:d,value:a.length})}else for(let c=l.length;a.length<c;c-=1){const d=t.concat([c-1]),f=Ra(d,i);r.push({op:dt.Remove,path:f})}}}function O5({original:e,copy:t,assignedMap:n},r,i,a,o){n.forEach((s,l)=>{const u=qr(e,l),c=Lc(qr(t,l)),d=s?el(e,l)?dt.Replace:dt.Add:dt.Remove;if(Gr(u,c)&&d===dt.Replace)return;const f=r.concat(l),p=Ra(f,o);i.push(d===dt.Remove?{op:d,path:p}:{op:d,path:p,value:c}),a.push(d===dt.Add?{op:dt.Remove,path:p}:d===dt.Remove?{op:dt.Add,path:p,value:u}:{op:dt.Replace,path:p,value:u})})}function P5({original:e,copy:t},n,r,i,a){let o=0;e.forEach(s=>{if(!t.has(s)){const l=n.concat([o]),u=Ra(l,a);r.push({op:dt.Remove,path:u,value:s}),i.unshift({op:dt.Add,path:u,value:s})}o+=1}),o=0,t.forEach(s=>{if(!e.has(s)){const l=n.concat([o]),u=Ra(l,a);r.push({op:dt.Add,path:u,value:s}),i.unshift({op:dt.Remove,path:u,value:s})}o+=1})}function rl(e,t,n,r){const{pathAsArray:i=!0}=e.options.enablePatches;switch(e.type){case 0:case 2:return O5(e,t,n,r,i);case 1:return N5(e,t,n,r,i);case 3:return P5(e,t,n,r,i)}}let I5=!1;const Mc=(e,t,n=!1)=>{if(typeof e=="object"&&e!==null&&(!er(e,t)||n)&&!I5)throw new Error("Strict mode: Mutable data cannot be accessed directly, please use 'unsafe(callback)' wrap.")},qh={get size(){return En(Pe(this)).size},has(e){return En(Pe(this)).has(e)},set(e,t){const n=Pe(this),r=En(n);return(!r.has(e)||!Gr(r.get(e),t))&&(Qt(n),Er(n),n.assignedMap.set(e,!0),n.copy.set(e,t),Yh(n,e,t,rl)),this},delete(e){if(!this.has(e))return!1;const t=Pe(this);return Qt(t),Er(t),t.original.has(e)?t.assignedMap.set(e,!1):t.assignedMap.delete(e),t.copy.delete(e),!0},clear(){const e=Pe(this);if(this.size){Qt(e),Er(e),e.assignedMap=new Map;for(const[t]of e.original)e.assignedMap.set(t,!1);e.copy.clear()}},forEach(e,t){const n=Pe(this);En(n).forEach((r,i)=>{e.call(t,this.get(i),i,this)})},get(e){var t,n;const r=Pe(this),i=En(r).get(e),a=((n=(t=r.options).mark)===null||n===void 0?void 0:n.call(t,i,xn))===xn.mutable;if(r.options.strict&&Mc(i,r.options,a),a||r.finalized||!er(i,r.options)||i!==r.original.get(e))return i;const o=jh.createDraft({original:i,parentDraft:r,key:e,finalities:r.finalities,options:r.options});return Qt(r),r.copy.set(e,o),o},keys(){return En(Pe(this)).keys()},values(){const e=this.keys();return{[Dc]:()=>this.values(),next:()=>{const t=e.next();return t.done?t:{done:!1,value:this.get(t.value)}}}},entries(){const e=this.keys();return{[Dc]:()=>this.entries(),next:()=>{const t=e.next();if(t.done)return t;const n=this.get(t.value);return{done:!1,value:[t.value,n]}}}},[Dc](){return this.entries()}},D5=Reflect.ownKeys(qh),ox=(e,t,{isValuesIterator:n})=>()=>{var r,i;const a=t.next();if(a.done)return a;const o=a.value;let s=e.setMap.get(o);const l=Pe(s),u=((i=(r=e.options).mark)===null||i===void 0?void 0:i.call(r,s,xn))===xn.mutable;if(e.options.strict&&Mc(o,e.options,u),!u&&!l&&er(o,e.options)&&!e.finalized&&e.original.has(o)){const c=jh.createDraft({original:o,parentDraft:e,key:o,finalities:e.finalities,options:e.options});e.setMap.set(o,c),s=c}else l&&(s=l.proxy);return{done:!1,value:n?s:[s,s]}},Gh={get size(){return Pe(this).setMap.size},has(e){const t=Pe(this);if(t.setMap.has(e))return!0;Qt(t);const n=Pe(e);return!!(n&&t.setMap.has(n.original))},add(e){const t=Pe(this);return this.has(e)||(Qt(t),Er(t),t.assignedMap.set(e,!0),t.setMap.set(e,e),Yh(t,e,e,rl)),this},delete(e){if(!this.has(e))return!1;const t=Pe(this);Qt(t),Er(t);const n=Pe(e);return n&&t.setMap.has(n.original)?(t.assignedMap.set(n.original,!1),t.setMap.delete(n.original)):(!n&&t.setMap.has(e)?t.assignedMap.set(e,!1):t.assignedMap.delete(e),t.setMap.delete(e))},clear(){if(!this.size)return;const e=Pe(this);Qt(e),Er(e);for(const t of e.original)e.assignedMap.set(t,!1);e.setMap.clear()},values(){const e=Pe(this);Qt(e);const t=e.setMap.keys();return{[Symbol.iterator]:()=>this.values(),next:ox(e,t,{isValuesIterator:!0})}},entries(){const e=Pe(this);Qt(e);const t=e.setMap.keys();return{[Symbol.iterator]:()=>this.entries(),next:ox(e,t,{isValuesIterator:!1})}},keys(){return this.values()},[Dc](){return this.values()},forEach(e,t){const n=this.values();let r=n.next();for(;!r.done;)e.call(t,r.value,r.value,this),r=n.next()}},L5=Reflect.ownKeys(Gh),sx=new WeakSet,lx={get(e,t,n){var r,i;const a=(r=e.copy)===null||r===void 0?void 0:r[t];if(a&&sx.has(a))return a;if(t===ex)return e;let o;if(e.options.mark){const u=t==="size"&&(e.original instanceof Map||e.original instanceof Set)?Reflect.get(e.original,t):Reflect.get(e.original,t,n);if(o=e.options.mark(u,xn),o===xn.mutable)return e.options.strict&&Mc(u,e.options,!0),u}const s=En(e);if(s instanceof Map&&D5.includes(t)){if(t==="size")return Object.getOwnPropertyDescriptor(qh,"size").get.call(e.proxy);const u=qh[t];if(u)return u.bind(e.proxy)}if(s instanceof Set&&L5.includes(t)){if(t==="size")return Object.getOwnPropertyDescriptor(Gh,"size").get.call(e.proxy);const u=Gh[t];if(u)return u.bind(e.proxy)}if(!el(s,t)){const u=tx(s,t);return u?"value"in u?u.value:(i=u.get)===null||i===void 0?void 0:i.call(e.proxy):void 0}const l=s[t];if(e.options.strict&&Mc(l,e.options),e.finalized||!er(l,e.options))return l;if(l===Uh(e.original,t)){if(Qt(e),e.copy[t]=Kh({original:e.original[t],parentDraft:e,key:e.type===1?Number(t):t,finalities:e.finalities,options:e.options}),typeof o=="function"){const u=Pe(e.copy[t]);return Qt(u),Er(u),u.copy}return e.copy[t]}return l},set(e,t,n){var r;if(e.type===3||e.type===2)throw new Error("Map/Set draft does not support any property assignment.");let i;if(e.type===1&&t!=="length"&&!(Number.isInteger(i=Number(t))&&i>=0&&(t===0||i===0||String(i)===String(t))))throw new Error("Only supports setting array indices and the 'length' property.");const a=tx(En(e),t);if(a!=null&&a.set)return a.set.call(e.proxy,n),!0;const o=Uh(En(e),t),s=Pe(o);return s&&Gr(s.original,n)?(e.copy[t]=n,e.assignedMap=(r=e.assignedMap)!==null&&r!==void 0?r:new Map,e.assignedMap.set(t,!1),!0):(Gr(n,o)&&(n!==void 0||el(e.original,t))||(Qt(e),Er(e),el(e.original,t)&&Gr(n,e.original[t])?e.assignedMap.delete(t):e.assignedMap.set(t,!0),e.copy[t]=n,Yh(e,t,n,rl)),!0)},has(e,t){return t in En(e)},ownKeys(e){return Reflect.ownKeys(En(e))},getOwnPropertyDescriptor(e,t){const n=En(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.type!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},getPrototypeOf(e){return Reflect.getPrototypeOf(e.original)},setPrototypeOf(){throw new Error("Cannot call 'setPrototypeOf()' on drafts")},defineProperty(){throw new Error("Cannot call 'defineProperty()' on drafts")},deleteProperty(e,t){var n;return e.type===1?lx.set.call(this,e,t,void 0,e.proxy):(Uh(e.original,t)!==void 0||t in e.original?(Qt(e),Er(e),e.assignedMap.set(t,!1)):(e.assignedMap=(n=e.assignedMap)!==null&&n!==void 0?n:new Map,e.assignedMap.delete(t)),e.copy&&delete e.copy[t],!0)}};function Kh(e){const{original:t,parentDraft:n,key:r,finalities:i,options:a}=e,o=Aa(t),s={type:o,finalized:!1,parent:n,original:t,copy:null,proxy:null,finalities:i,options:a,setMap:o===3?new Map(t.entries()):void 0};(r||"key"in e)&&(s.key=r);const{proxy:l,revoke:u}=Proxy.revocable(o===1?Object.assign([],s):s,lx);if(i.revoke.push(u),sx.add(l),s.proxy=l,n){const c=n;c.finalities.draft.push((d,f)=>{var p,g;const w=Pe(l);let x=c.type===3?c.setMap:c.copy;const m=qr(x,r),v=Pe(m);if(v){let b=v.original;v.operated&&(b=zh(m)),$h(v),Wh(v,rl,d,f),c.options.enableAutoFreeze&&(c.options.updatedValues=(p=c.options.updatedValues)!==null&&p!==void 0?p:new WeakMap,c.options.updatedValues.set(b,v.original)),tl(x,r,b)}(g=w.callbacks)===null||g===void 0||g.forEach(b=>{b(d,f)})})}else{const c=Pe(l);c.finalities.draft.push((d,f)=>{$h(c),Wh(c,rl,d,f)})}return l}jh.createDraft=Kh;function M5(e,t,n,r,i){var a;const o=Pe(e),s=(a=o==null?void 0:o.original)!==null&&a!==void 0?a:e,l=!!t.length;if(o!=null&&o.operated)for(;o.finalities.draft.length>0;)o.finalities.draft.pop()(n,r);const u=l?t[0]:o?o.operated?o.copy:o.original:e;return o&&Hh(o),i&&yo(u,u,o==null?void 0:o.options.updatedValues),[u,n&&l?[{op:dt.Replace,path:[],value:t[0]}]:n,r&&l?[{op:dt.Replace,path:[],value:s}]:r]}function F5(e,t){var n;const r={draft:[],revoke:[],handledSet:new WeakSet};let i,a;t.enablePatches&&(i=[],a=[]);const s=((n=t.mark)===null||n===void 0?void 0:n.call(t,e,xn))===xn.mutable||!er(e,t)?e:Kh({original:e,parentDraft:null,finalities:r,options:t});return[s,(l=[])=>{const[u,c,d]=M5(s,l,i,a,t.enableAutoFreeze);return t.enablePatches?[u,c,d]:u}]}function Xh(e){const{rootDraft:t,value:n,useRawReturn:r=!1,isRoot:i=!0}=e;Vh(n,(a,o,s)=>{const l=Pe(o);if(l&&t&&l.finalities===t.finalities){e.isContainDraft=!0;const u=l.original;if(s instanceof Set){const c=Array.from(s);s.clear(),c.forEach(d=>s.add(a===d?u:d))}else tl(s,a,u)}else typeof o=="object"&&o!==null&&(e.value=o,e.isRoot=!1,Xh(e))}),i&&(e.isContainDraft||console.warn("The return value does not contain any draft, please use 'rawReturn()' to wrap the return value to improve performance."),r&&console.warn("The return value contains drafts, please don't use 'rawReturn()' to wrap the return value."))}function ux(e){const t=Pe(e);if(!er(e,t==null?void 0:t.options))return e;const n=Aa(e);if(t&&!t.operated)return t.original;let r;function i(){r=n===2?new Map(e):n===3?Array.from(t.setMap.values()):rx(e,t==null?void 0:t.options)}if(t){t.finalized=!0;try{i()}finally{t.finalized=!1}}else r=e;return Vh(r,(a,o)=>{if(t&&Gr(qr(t.original,a),o))return;const s=ux(o);s!==o&&(r===e&&i(),tl(r,a,s))}),n===3?new Set(r):r}function cx(e){if(!Ca(e))throw new Error(`current() is only used for Draft, parameter: ${e}`);return ux(e)}const B5=(e=>function t(n,r,i){var a,o,s;if(typeof n=="function"&&typeof r!="function")return function(_,...S){return t(_,R=>n.call(this,R,...S),r)};const l=n,u=r;let c=i;if(typeof r!="function"&&(c=r),c!==void 0&&Object.prototype.toString.call(c)!=="[object Object]")throw new Error(`Invalid options: ${c}, 'options' should be an object.`);c=Object.assign(Object.assign({},e),c);const d=Ca(l)?cx(l):l,f=Array.isArray(c.mark)?(_,S)=>{for(const R of c.mark){if(typeof R!="function")throw new Error(`Invalid mark: ${R}, 'mark' should be a function.`);const P=R(_,S);if(P)return P}}:c.mark,p=(a=c.enablePatches)!==null&&a!==void 0?a:!1,g=(o=c.strict)!==null&&o!==void 0?o:!1,x={enableAutoFreeze:(s=c.enableAutoFreeze)!==null&&s!==void 0?s:!1,mark:f,strict:g,enablePatches:p};if(!er(d,x)&&typeof d=="object"&&d!==null)throw new Error("Invalid base state: create() only supports plain objects, arrays, Set, Map or using mark() to mark the state as immutable.");const[m,v]=F5(d,x);if(typeof r!="function"){if(!er(d,x))throw new Error("Invalid base state: create() only supports plain objects, arrays, Set, Map or using mark() to mark the state as immutable.");return[m,v]}let b;try{b=u(m)}catch(_){throw Hh(Pe(m)),_}const T=_=>{const S=Pe(m);if(!Ca(_)){if(_!==void 0&&!Gr(_,m)&&(S!=null&&S.operated))throw new Error("Either the value is returned as a new non-draft value, or only the draft is modified without returning any value.");const P=_==null?void 0:_[S5];if(P){const B=P[0];return x.strict&&typeof _=="object"&&_!==null&&Xh({rootDraft:S,value:_,useRawReturn:!0}),v([B])}if(_!==void 0)return typeof _=="object"&&_!==null&&Xh({rootDraft:S,value:_}),v([_])}if(_===m||_===void 0)return v([]);const R=Pe(_);if(x===R.options){if(R.operated)throw new Error("Cannot return a modified child draft.");return v([cx(_)])}return v([_])};return b instanceof Promise?b.then(T,_=>{throw Hh(Pe(m)),_}):T(b)})();Object.prototype.constructor.toString();function j5(e,t){const[n,r]=y.useState(e);return y.useEffect(()=>{const i=setTimeout(()=>r(e),t);return()=>clearTimeout(i)},[e,t,n]),[n,r]}var De;(function(e){e.assertEqual=i=>i;function t(i){}e.assertIs=t;function n(i){throw new Error}e.assertNever=n,e.arrayToEnum=i=>{const a={};for(const o of i)a[o]=o;return a},e.getValidEnumValues=i=>{const a=e.objectKeys(i).filter(s=>typeof i[i[s]]!="number"),o={};for(const s of a)o[s]=i[s];return e.objectValues(o)},e.objectValues=i=>e.objectKeys(i).map(function(a){return i[a]}),e.objectKeys=typeof Object.keys=="function"?i=>Object.keys(i):i=>{const a=[];for(const o in i)Object.prototype.hasOwnProperty.call(i,o)&&a.push(o);return a},e.find=(i,a)=>{for(const o of i)if(a(o))return o},e.isInteger=typeof Number.isInteger=="function"?i=>Number.isInteger(i):i=>typeof i=="number"&&isFinite(i)&&Math.floor(i)===i;function r(i,a=" | "){return i.map(o=>typeof o=="string"?`'${o}'`:o).join(a)}e.joinValues=r,e.jsonStringifyReplacer=(i,a)=>typeof a=="bigint"?a.toString():a})(De||(De={}));var Qh;(function(e){e.mergeShapes=(t,n)=>({...t,...n})})(Qh||(Qh={}));const ie=De.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),Ci=e=>{switch(typeof e){case"undefined":return ie.undefined;case"string":return ie.string;case"number":return isNaN(e)?ie.nan:ie.number;case"boolean":return ie.boolean;case"function":return ie.function;case"bigint":return ie.bigint;case"symbol":return ie.symbol;case"object":return Array.isArray(e)?ie.array:e===null?ie.null:e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?ie.promise:typeof Map<"u"&&e instanceof Map?ie.map:typeof Set<"u"&&e instanceof Set?ie.set:typeof Date<"u"&&e instanceof Date?ie.date:ie.object;default:return ie.unknown}},q=De.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),z5=e=>JSON.stringify(e,null,2).replace(/"([^"]+)":/g,"$1:");class Tn extends Error{constructor(t){super(),this.issues=[],this.addIssue=r=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};const n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=t}get errors(){return this.issues}format(t){const n=t||function(a){return a.message},r={_errors:[]},i=a=>{for(const o of a.issues)if(o.code==="invalid_union")o.unionErrors.map(i);else if(o.code==="invalid_return_type")i(o.returnTypeError);else if(o.code==="invalid_arguments")i(o.argumentsError);else if(o.path.length===0)r._errors.push(n(o));else{let s=r,l=0;for(;l<o.path.length;){const u=o.path[l];l===o.path.length-1?(s[u]=s[u]||{_errors:[]},s[u]._errors.push(n(o))):s[u]=s[u]||{_errors:[]},s=s[u],l++}}};return i(this),r}static assert(t){if(!(t instanceof Tn))throw new Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,De.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=n=>n.message){const n={},r=[];for(const i of this.issues)i.path.length>0?(n[i.path[0]]=n[i.path[0]]||[],n[i.path[0]].push(t(i))):r.push(t(i));return{formErrors:r,fieldErrors:n}}get formErrors(){return this.flatten()}}Tn.create=e=>new Tn(e);const vo=(e,t)=>{let n;switch(e.code){case q.invalid_type:e.received===ie.undefined?n="Required":n=`Expected ${e.expected}, received ${e.received}`;break;case q.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(e.expected,De.jsonStringifyReplacer)}`;break;case q.unrecognized_keys:n=`Unrecognized key(s) in object: ${De.joinValues(e.keys,", ")}`;break;case q.invalid_union:n="Invalid input";break;case q.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${De.joinValues(e.options)}`;break;case q.invalid_enum_value:n=`Invalid enum value. Expected ${De.joinValues(e.options)}, received '${e.received}'`;break;case q.invalid_arguments:n="Invalid function arguments";break;case q.invalid_return_type:n="Invalid function return type";break;case q.invalid_date:n="Invalid date";break;case q.invalid_string:typeof e.validation=="object"?"includes"in e.validation?(n=`Invalid input: must include "${e.validation.includes}"`,typeof e.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?n=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?n=`Invalid input: must end with "${e.validation.endsWith}"`:De.assertNever(e.validation):e.validation!=="regex"?n=`Invalid ${e.validation}`:n="Invalid";break;case q.too_small:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:n="Invalid input";break;case q.too_big:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="bigint"?n=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:n="Invalid input";break;case q.custom:n="Invalid input";break;case q.invalid_intersection_types:n="Intersection results could not be merged";break;case q.not_multiple_of:n=`Number must be a multiple of ${e.multipleOf}`;break;case q.not_finite:n="Number must be finite";break;default:n=t.defaultError,De.assertNever(e)}return{message:n}};let dx=vo;function U5(e){dx=e}function Fc(){return dx}const Bc=e=>{const{data:t,path:n,errorMaps:r,issueData:i}=e,a=[...n,...i.path||[]],o={...i,path:a};if(i.message!==void 0)return{...i,path:a,message:i.message};let s="";const l=r.filter(u=>!!u).slice().reverse();for(const u of l)s=u(o,{data:t,defaultError:s}).message;return{...i,path:a,message:s}},H5=[];function re(e,t){const n=Fc(),r=Bc({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,n,n===vo?void 0:vo].filter(i=>!!i)});e.common.issues.push(r)}class jt{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(t,n){const r=[];for(const i of n){if(i.status==="aborted")return ge;i.status==="dirty"&&t.dirty(),r.push(i.value)}return{status:t.value,value:r}}static async mergeObjectAsync(t,n){const r=[];for(const i of n){const a=await i.key,o=await i.value;r.push({key:a,value:o})}return jt.mergeObjectSync(t,r)}static mergeObjectSync(t,n){const r={};for(const i of n){const{key:a,value:o}=i;if(a.status==="aborted"||o.status==="aborted")return ge;a.status==="dirty"&&t.dirty(),o.status==="dirty"&&t.dirty(),a.value!=="__proto__"&&(typeof o.value<"u"||i.alwaysSet)&&(r[a.value]=o.value)}return{status:t.value,value:r}}}const ge=Object.freeze({status:"aborted"}),bo=e=>({status:"dirty",value:e}),Zt=e=>({status:"valid",value:e}),Zh=e=>e.status==="aborted",Jh=e=>e.status==="dirty",il=e=>e.status==="valid",al=e=>typeof Promise<"u"&&e instanceof Promise;function jc(e,t,n,r){if(typeof t=="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t.get(e)}function fx(e,t,n,r,i){if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return t.set(e,n),n}typeof SuppressedError=="function"&&SuppressedError;var ce;(function(e){e.errToObj=t=>typeof t=="string"?{message:t}:t||{},e.toString=t=>typeof t=="string"?t:t==null?void 0:t.message})(ce||(ce={}));var ol,sl;class Tr{constructor(t,n,r,i){this._cachedPath=[],this.parent=t,this.data=n,this._path=r,this._key=i}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const px=(e,t)=>{if(il(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const n=new Tn(e.common.issues);return this._error=n,this._error}}};function ve(e){if(!e)return{};const{errorMap:t,invalid_type_error:n,required_error:r,description:i}=e;if(t&&(n||r))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return t?{errorMap:t,description:i}:{errorMap:(o,s)=>{var l,u;const{message:c}=e;return o.code==="invalid_enum_value"?{message:c??s.defaultError}:typeof s.data>"u"?{message:(l=c??r)!==null&&l!==void 0?l:s.defaultError}:o.code!=="invalid_type"?{message:s.defaultError}:{message:(u=c??n)!==null&&u!==void 0?u:s.defaultError}},description:i}}class _e{constructor(t){this.spa=this.safeParseAsync,this._def=t,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this)}get description(){return this._def.description}_getType(t){return Ci(t.data)}_getOrReturnCtx(t,n){return n||{common:t.parent.common,data:t.data,parsedType:Ci(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new jt,ctx:{common:t.parent.common,data:t.data,parsedType:Ci(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){const n=this._parse(t);if(al(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(t){const n=this._parse(t);return Promise.resolve(n)}parse(t,n){const r=this.safeParse(t,n);if(r.success)return r.data;throw r.error}safeParse(t,n){var r;const i={common:{issues:[],async:(r=n==null?void 0:n.async)!==null&&r!==void 0?r:!1,contextualErrorMap:n==null?void 0:n.errorMap},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Ci(t)},a=this._parseSync({data:t,path:i.path,parent:i});return px(i,a)}async parseAsync(t,n){const r=await this.safeParseAsync(t,n);if(r.success)return r.data;throw r.error}async safeParseAsync(t,n){const r={common:{issues:[],contextualErrorMap:n==null?void 0:n.errorMap,async:!0},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Ci(t)},i=this._parse({data:t,path:r.path,parent:r}),a=await(al(i)?i:Promise.resolve(i));return px(r,a)}refine(t,n){const r=i=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(i):n;return this._refinement((i,a)=>{const o=t(i),s=()=>a.addIssue({code:q.custom,...r(i)});return typeof Promise<"u"&&o instanceof Promise?o.then(l=>l?!0:(s(),!1)):o?!0:(s(),!1)})}refinement(t,n){return this._refinement((r,i)=>t(r)?!0:(i.addIssue(typeof n=="function"?n(r,i):n),!1))}_refinement(t){return new rr({schema:this,typeName:me.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}optional(){return Sr.create(this,this._def)}nullable(){return Oi.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return nr.create(this,this._def)}promise(){return _o.create(this,this._def)}or(t){return dl.create([this,t],this._def)}and(t){return fl.create(this,t,this._def)}transform(t){return new rr({...ve(this._def),schema:this,typeName:me.ZodEffects,effect:{type:"transform",transform:t}})}default(t){const n=typeof t=="function"?t:()=>t;return new wl({...ve(this._def),innerType:this,defaultValue:n,typeName:me.ZodDefault})}brand(){return new nm({typeName:me.ZodBranded,type:this,...ve(this._def)})}catch(t){const n=typeof t=="function"?t:()=>t;return new yl({...ve(this._def),innerType:this,catchValue:n,typeName:me.ZodCatch})}describe(t){const n=this.constructor;return new n({...this._def,description:t})}pipe(t){return vl.create(this,t)}readonly(){return bl.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const V5=/^c[^\s-]{8,}$/i,$5=/^[0-9a-z]+$/,W5=/^[0-9A-HJKMNP-TV-Z]{26}$/,Y5=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,q5=/^[a-z0-9_-]{21}$/i,G5=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,K5=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,X5="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let em;const Q5=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,Z5=/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,J5=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,hx="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",eD=new RegExp(`^${hx}$`);function mx(e){let t="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return e.precision?t=`${t}\\.\\d{${e.precision}}`:e.precision==null&&(t=`${t}(\\.\\d+)?`),t}function tD(e){return new RegExp(`^${mx(e)}$`)}function gx(e){let t=`${hx}T${mx(e)}`;const n=[];return n.push(e.local?"Z?":"Z"),e.offset&&n.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${n.join("|")})`,new RegExp(`^${t}$`)}function nD(e,t){return!!((t==="v4"||!t)&&Q5.test(e)||(t==="v6"||!t)&&Z5.test(e))}class tr extends _e{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==ie.string){const a=this._getOrReturnCtx(t);return re(a,{code:q.invalid_type,expected:ie.string,received:a.parsedType}),ge}const r=new jt;let i;for(const a of this._def.checks)if(a.kind==="min")t.data.length<a.value&&(i=this._getOrReturnCtx(t,i),re(i,{code:q.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),r.dirty());else if(a.kind==="max")t.data.length>a.value&&(i=this._getOrReturnCtx(t,i),re(i,{code:q.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),r.dirty());else if(a.kind==="length"){const o=t.data.length>a.value,s=t.data.length<a.value;(o||s)&&(i=this._getOrReturnCtx(t,i),o?re(i,{code:q.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}):s&&re(i,{code:q.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}),r.dirty())}else if(a.kind==="email")K5.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"email",code:q.invalid_string,message:a.message}),r.dirty());else if(a.kind==="emoji")em||(em=new RegExp(X5,"u")),em.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"emoji",code:q.invalid_string,message:a.message}),r.dirty());else if(a.kind==="uuid")Y5.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"uuid",code:q.invalid_string,message:a.message}),r.dirty());else if(a.kind==="nanoid")q5.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"nanoid",code:q.invalid_string,message:a.message}),r.dirty());else if(a.kind==="cuid")V5.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"cuid",code:q.invalid_string,message:a.message}),r.dirty());else if(a.kind==="cuid2")$5.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"cuid2",code:q.invalid_string,message:a.message}),r.dirty());else if(a.kind==="ulid")W5.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"ulid",code:q.invalid_string,message:a.message}),r.dirty());else if(a.kind==="url")try{new URL(t.data)}catch{i=this._getOrReturnCtx(t,i),re(i,{validation:"url",code:q.invalid_string,message:a.message}),r.dirty()}else a.kind==="regex"?(a.regex.lastIndex=0,a.regex.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"regex",code:q.invalid_string,message:a.message}),r.dirty())):a.kind==="trim"?t.data=t.data.trim():a.kind==="includes"?t.data.includes(a.value,a.position)||(i=this._getOrReturnCtx(t,i),re(i,{code:q.invalid_string,validation:{includes:a.value,position:a.position},message:a.message}),r.dirty()):a.kind==="toLowerCase"?t.data=t.data.toLowerCase():a.kind==="toUpperCase"?t.data=t.data.toUpperCase():a.kind==="startsWith"?t.data.startsWith(a.value)||(i=this._getOrReturnCtx(t,i),re(i,{code:q.invalid_string,validation:{startsWith:a.value},message:a.message}),r.dirty()):a.kind==="endsWith"?t.data.endsWith(a.value)||(i=this._getOrReturnCtx(t,i),re(i,{code:q.invalid_string,validation:{endsWith:a.value},message:a.message}),r.dirty()):a.kind==="datetime"?gx(a).test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{code:q.invalid_string,validation:"datetime",message:a.message}),r.dirty()):a.kind==="date"?eD.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{code:q.invalid_string,validation:"date",message:a.message}),r.dirty()):a.kind==="time"?tD(a).test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{code:q.invalid_string,validation:"time",message:a.message}),r.dirty()):a.kind==="duration"?G5.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"duration",code:q.invalid_string,message:a.message}),r.dirty()):a.kind==="ip"?nD(t.data,a.version)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"ip",code:q.invalid_string,message:a.message}),r.dirty()):a.kind==="base64"?J5.test(t.data)||(i=this._getOrReturnCtx(t,i),re(i,{validation:"base64",code:q.invalid_string,message:a.message}),r.dirty()):De.assertNever(a);return{status:r.value,value:t.data}}_regex(t,n,r){return this.refinement(i=>t.test(i),{validation:n,code:q.invalid_string,...ce.errToObj(r)})}_addCheck(t){return new tr({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...ce.errToObj(t)})}url(t){return this._addCheck({kind:"url",...ce.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...ce.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...ce.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...ce.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...ce.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...ce.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...ce.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...ce.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...ce.errToObj(t)})}datetime(t){var n,r;return typeof t=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t}):this._addCheck({kind:"datetime",precision:typeof(t==null?void 0:t.precision)>"u"?null:t==null?void 0:t.precision,offset:(n=t==null?void 0:t.offset)!==null&&n!==void 0?n:!1,local:(r=t==null?void 0:t.local)!==null&&r!==void 0?r:!1,...ce.errToObj(t==null?void 0:t.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){return typeof t=="string"?this._addCheck({kind:"time",precision:null,message:t}):this._addCheck({kind:"time",precision:typeof(t==null?void 0:t.precision)>"u"?null:t==null?void 0:t.precision,...ce.errToObj(t==null?void 0:t.message)})}duration(t){return this._addCheck({kind:"duration",...ce.errToObj(t)})}regex(t,n){return this._addCheck({kind:"regex",regex:t,...ce.errToObj(n)})}includes(t,n){return this._addCheck({kind:"includes",value:t,position:n==null?void 0:n.position,...ce.errToObj(n==null?void 0:n.message)})}startsWith(t,n){return this._addCheck({kind:"startsWith",value:t,...ce.errToObj(n)})}endsWith(t,n){return this._addCheck({kind:"endsWith",value:t,...ce.errToObj(n)})}min(t,n){return this._addCheck({kind:"min",value:t,...ce.errToObj(n)})}max(t,n){return this._addCheck({kind:"max",value:t,...ce.errToObj(n)})}length(t,n){return this._addCheck({kind:"length",value:t,...ce.errToObj(n)})}nonempty(t){return this.min(1,ce.errToObj(t))}trim(){return new tr({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new tr({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new tr({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(t=>t.kind==="datetime")}get isDate(){return!!this._def.checks.find(t=>t.kind==="date")}get isTime(){return!!this._def.checks.find(t=>t.kind==="time")}get isDuration(){return!!this._def.checks.find(t=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find(t=>t.kind==="email")}get isURL(){return!!this._def.checks.find(t=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find(t=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find(t=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(t=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(t=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(t=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find(t=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find(t=>t.kind==="ip")}get isBase64(){return!!this._def.checks.find(t=>t.kind==="base64")}get minLength(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxLength(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}}tr.create=e=>{var t;return new tr({checks:[],typeName:me.ZodString,coerce:(t=e==null?void 0:e.coerce)!==null&&t!==void 0?t:!1,...ve(e)})};function rD(e,t){const n=(e.toString().split(".")[1]||"").length,r=(t.toString().split(".")[1]||"").length,i=n>r?n:r,a=parseInt(e.toFixed(i).replace(".","")),o=parseInt(t.toFixed(i).replace(".",""));return a%o/Math.pow(10,i)}class Ai extends _e{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce&&(t.data=Number(t.data)),this._getType(t)!==ie.number){const a=this._getOrReturnCtx(t);return re(a,{code:q.invalid_type,expected:ie.number,received:a.parsedType}),ge}let r;const i=new jt;for(const a of this._def.checks)a.kind==="int"?De.isInteger(t.data)||(r=this._getOrReturnCtx(t,r),re(r,{code:q.invalid_type,expected:"integer",received:"float",message:a.message}),i.dirty()):a.kind==="min"?(a.inclusive?t.data<a.value:t.data<=a.value)&&(r=this._getOrReturnCtx(t,r),re(r,{code:q.too_small,minimum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),i.dirty()):a.kind==="max"?(a.inclusive?t.data>a.value:t.data>=a.value)&&(r=this._getOrReturnCtx(t,r),re(r,{code:q.too_big,maximum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),i.dirty()):a.kind==="multipleOf"?rD(t.data,a.value)!==0&&(r=this._getOrReturnCtx(t,r),re(r,{code:q.not_multiple_of,multipleOf:a.value,message:a.message}),i.dirty()):a.kind==="finite"?Number.isFinite(t.data)||(r=this._getOrReturnCtx(t,r),re(r,{code:q.not_finite,message:a.message}),i.dirty()):De.assertNever(a);return{status:i.value,value:t.data}}gte(t,n){return this.setLimit("min",t,!0,ce.toString(n))}gt(t,n){return this.setLimit("min",t,!1,ce.toString(n))}lte(t,n){return this.setLimit("max",t,!0,ce.toString(n))}lt(t,n){return this.setLimit("max",t,!1,ce.toString(n))}setLimit(t,n,r,i){return new Ai({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:ce.toString(i)}]})}_addCheck(t){return new Ai({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:ce.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:ce.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:ce.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:ce.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:ce.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:ce.toString(n)})}finite(t){return this._addCheck({kind:"finite",message:ce.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:ce.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:ce.toString(t)})}get minValue(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}get isInt(){return!!this._def.checks.find(t=>t.kind==="int"||t.kind==="multipleOf"&&De.isInteger(t.value))}get isFinite(){let t=null,n=null;for(const r of this._def.checks){if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;r.kind==="min"?(n===null||r.value>n)&&(n=r.value):r.kind==="max"&&(t===null||r.value<t)&&(t=r.value)}return Number.isFinite(n)&&Number.isFinite(t)}}Ai.create=e=>new Ai({checks:[],typeName:me.ZodNumber,coerce:(e==null?void 0:e.coerce)||!1,...ve(e)});class Ri extends _e{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce&&(t.data=BigInt(t.data)),this._getType(t)!==ie.bigint){const a=this._getOrReturnCtx(t);return re(a,{code:q.invalid_type,expected:ie.bigint,received:a.parsedType}),ge}let r;const i=new jt;for(const a of this._def.checks)a.kind==="min"?(a.inclusive?t.data<a.value:t.data<=a.value)&&(r=this._getOrReturnCtx(t,r),re(r,{code:q.too_small,type:"bigint",minimum:a.value,inclusive:a.inclusive,message:a.message}),i.dirty()):a.kind==="max"?(a.inclusive?t.data>a.value:t.data>=a.value)&&(r=this._getOrReturnCtx(t,r),re(r,{code:q.too_big,type:"bigint",maximum:a.value,inclusive:a.inclusive,message:a.message}),i.dirty()):a.kind==="multipleOf"?t.data%a.value!==BigInt(0)&&(r=this._getOrReturnCtx(t,r),re(r,{code:q.not_multiple_of,multipleOf:a.value,message:a.message}),i.dirty()):De.assertNever(a);return{status:i.value,value:t.data}}gte(t,n){return this.setLimit("min",t,!0,ce.toString(n))}gt(t,n){return this.setLimit("min",t,!1,ce.toString(n))}lte(t,n){return this.setLimit("max",t,!0,ce.toString(n))}lt(t,n){return this.setLimit("max",t,!1,ce.toString(n))}setLimit(t,n,r,i){return new Ri({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:ce.toString(i)}]})}_addCheck(t){return new Ri({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:ce.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:ce.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:ce.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:ce.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:ce.toString(n)})}get minValue(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}}Ri.create=e=>{var t;return new Ri({checks:[],typeName:me.ZodBigInt,coerce:(t=e==null?void 0:e.coerce)!==null&&t!==void 0?t:!1,...ve(e)})};class ll extends _e{_parse(t){if(this._def.coerce&&(t.data=!!t.data),this._getType(t)!==ie.boolean){const r=this._getOrReturnCtx(t);return re(r,{code:q.invalid_type,expected:ie.boolean,received:r.parsedType}),ge}return Zt(t.data)}}ll.create=e=>new ll({typeName:me.ZodBoolean,coerce:(e==null?void 0:e.coerce)||!1,...ve(e)});class Na extends _e{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==ie.date){const a=this._getOrReturnCtx(t);return re(a,{code:q.invalid_type,expected:ie.date,received:a.parsedType}),ge}if(isNaN(t.data.getTime())){const a=this._getOrReturnCtx(t);return re(a,{code:q.invalid_date}),ge}const r=new jt;let i;for(const a of this._def.checks)a.kind==="min"?t.data.getTime()<a.value&&(i=this._getOrReturnCtx(t,i),re(i,{code:q.too_small,message:a.message,inclusive:!0,exact:!1,minimum:a.value,type:"date"}),r.dirty()):a.kind==="max"?t.data.getTime()>a.value&&(i=this._getOrReturnCtx(t,i),re(i,{code:q.too_big,message:a.message,inclusive:!0,exact:!1,maximum:a.value,type:"date"}),r.dirty()):De.assertNever(a);return{status:r.value,value:new Date(t.data.getTime())}}_addCheck(t){return new Na({...this._def,checks:[...this._def.checks,t]})}min(t,n){return this._addCheck({kind:"min",value:t.getTime(),message:ce.toString(n)})}max(t,n){return this._addCheck({kind:"max",value:t.getTime(),message:ce.toString(n)})}get minDate(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t!=null?new Date(t):null}get maxDate(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t!=null?new Date(t):null}}Na.create=e=>new Na({checks:[],coerce:(e==null?void 0:e.coerce)||!1,typeName:me.ZodDate,...ve(e)});class zc extends _e{_parse(t){if(this._getType(t)!==ie.symbol){const r=this._getOrReturnCtx(t);return re(r,{code:q.invalid_type,expected:ie.symbol,received:r.parsedType}),ge}return Zt(t.data)}}zc.create=e=>new zc({typeName:me.ZodSymbol,...ve(e)});class ul extends _e{_parse(t){if(this._getType(t)!==ie.undefined){const r=this._getOrReturnCtx(t);return re(r,{code:q.invalid_type,expected:ie.undefined,received:r.parsedType}),ge}return Zt(t.data)}}ul.create=e=>new ul({typeName:me.ZodUndefined,...ve(e)});class cl extends _e{_parse(t){if(this._getType(t)!==ie.null){const r=this._getOrReturnCtx(t);return re(r,{code:q.invalid_type,expected:ie.null,received:r.parsedType}),ge}return Zt(t.data)}}cl.create=e=>new cl({typeName:me.ZodNull,...ve(e)});class xo extends _e{constructor(){super(...arguments),this._any=!0}_parse(t){return Zt(t.data)}}xo.create=e=>new xo({typeName:me.ZodAny,...ve(e)});class Oa extends _e{constructor(){super(...arguments),this._unknown=!0}_parse(t){return Zt(t.data)}}Oa.create=e=>new Oa({typeName:me.ZodUnknown,...ve(e)});class Kr extends _e{_parse(t){const n=this._getOrReturnCtx(t);return re(n,{code:q.invalid_type,expected:ie.never,received:n.parsedType}),ge}}Kr.create=e=>new Kr({typeName:me.ZodNever,...ve(e)});class Uc extends _e{_parse(t){if(this._getType(t)!==ie.undefined){const r=this._getOrReturnCtx(t);return re(r,{code:q.invalid_type,expected:ie.void,received:r.parsedType}),ge}return Zt(t.data)}}Uc.create=e=>new Uc({typeName:me.ZodVoid,...ve(e)});class nr extends _e{_parse(t){const{ctx:n,status:r}=this._processInputParams(t),i=this._def;if(n.parsedType!==ie.array)return re(n,{code:q.invalid_type,expected:ie.array,received:n.parsedType}),ge;if(i.exactLength!==null){const o=n.data.length>i.exactLength.value,s=n.data.length<i.exactLength.value;(o||s)&&(re(n,{code:o?q.too_big:q.too_small,minimum:s?i.exactLength.value:void 0,maximum:o?i.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:i.exactLength.message}),r.dirty())}if(i.minLength!==null&&n.data.length<i.minLength.value&&(re(n,{code:q.too_small,minimum:i.minLength.value,type:"array",inclusive:!0,exact:!1,message:i.minLength.message}),r.dirty()),i.maxLength!==null&&n.data.length>i.maxLength.value&&(re(n,{code:q.too_big,maximum:i.maxLength.value,type:"array",inclusive:!0,exact:!1,message:i.maxLength.message}),r.dirty()),n.common.async)return Promise.all([...n.data].map((o,s)=>i.type._parseAsync(new Tr(n,o,n.path,s)))).then(o=>jt.mergeArray(r,o));const a=[...n.data].map((o,s)=>i.type._parseSync(new Tr(n,o,n.path,s)));return jt.mergeArray(r,a)}get element(){return this._def.type}min(t,n){return new nr({...this._def,minLength:{value:t,message:ce.toString(n)}})}max(t,n){return new nr({...this._def,maxLength:{value:t,message:ce.toString(n)}})}length(t,n){return new nr({...this._def,exactLength:{value:t,message:ce.toString(n)}})}nonempty(t){return this.min(1,t)}}nr.create=(e,t)=>new nr({type:e,minLength:null,maxLength:null,exactLength:null,typeName:me.ZodArray,...ve(t)});function Eo(e){if(e instanceof it){const t={};for(const n in e.shape){const r=e.shape[n];t[n]=Sr.create(Eo(r))}return new it({...e._def,shape:()=>t})}else return e instanceof nr?new nr({...e._def,type:Eo(e.element)}):e instanceof Sr?Sr.create(Eo(e.unwrap())):e instanceof Oi?Oi.create(Eo(e.unwrap())):e instanceof _r?_r.create(e.items.map(t=>Eo(t))):e}class it extends _e{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const t=this._def.shape(),n=De.objectKeys(t);return this._cached={shape:t,keys:n}}_parse(t){if(this._getType(t)!==ie.object){const u=this._getOrReturnCtx(t);return re(u,{code:q.invalid_type,expected:ie.object,received:u.parsedType}),ge}const{status:r,ctx:i}=this._processInputParams(t),{shape:a,keys:o}=this._getCached(),s=[];if(!(this._def.catchall instanceof Kr&&this._def.unknownKeys==="strip"))for(const u in i.data)o.includes(u)||s.push(u);const l=[];for(const u of o){const c=a[u],d=i.data[u];l.push({key:{status:"valid",value:u},value:c._parse(new Tr(i,d,i.path,u)),alwaysSet:u in i.data})}if(this._def.catchall instanceof Kr){const u=this._def.unknownKeys;if(u==="passthrough")for(const c of s)l.push({key:{status:"valid",value:c},value:{status:"valid",value:i.data[c]}});else if(u==="strict")s.length>0&&(re(i,{code:q.unrecognized_keys,keys:s}),r.dirty());else if(u!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const u=this._def.catchall;for(const c of s){const d=i.data[c];l.push({key:{status:"valid",value:c},value:u._parse(new Tr(i,d,i.path,c)),alwaysSet:c in i.data})}}return i.common.async?Promise.resolve().then(async()=>{const u=[];for(const c of l){const d=await c.key,f=await c.value;u.push({key:d,value:f,alwaysSet:c.alwaysSet})}return u}).then(u=>jt.mergeObjectSync(r,u)):jt.mergeObjectSync(r,l)}get shape(){return this._def.shape()}strict(t){return ce.errToObj,new it({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(n,r)=>{var i,a,o,s;const l=(o=(a=(i=this._def).errorMap)===null||a===void 0?void 0:a.call(i,n,r).message)!==null&&o!==void 0?o:r.defaultError;return n.code==="unrecognized_keys"?{message:(s=ce.errToObj(t).message)!==null&&s!==void 0?s:l}:{message:l}}}:{}})}strip(){return new it({...this._def,unknownKeys:"strip"})}passthrough(){return new it({...this._def,unknownKeys:"passthrough"})}extend(t){return new it({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new it({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:me.ZodObject})}setKey(t,n){return this.augment({[t]:n})}catchall(t){return new it({...this._def,catchall:t})}pick(t){const n={};return De.objectKeys(t).forEach(r=>{t[r]&&this.shape[r]&&(n[r]=this.shape[r])}),new it({...this._def,shape:()=>n})}omit(t){const n={};return De.objectKeys(this.shape).forEach(r=>{t[r]||(n[r]=this.shape[r])}),new it({...this._def,shape:()=>n})}deepPartial(){return Eo(this)}partial(t){const n={};return De.objectKeys(this.shape).forEach(r=>{const i=this.shape[r];t&&!t[r]?n[r]=i:n[r]=i.optional()}),new it({...this._def,shape:()=>n})}required(t){const n={};return De.objectKeys(this.shape).forEach(r=>{if(t&&!t[r])n[r]=this.shape[r];else{let a=this.shape[r];for(;a instanceof Sr;)a=a._def.innerType;n[r]=a}}),new it({...this._def,shape:()=>n})}keyof(){return wx(De.objectKeys(this.shape))}}it.create=(e,t)=>new it({shape:()=>e,unknownKeys:"strip",catchall:Kr.create(),typeName:me.ZodObject,...ve(t)}),it.strictCreate=(e,t)=>new it({shape:()=>e,unknownKeys:"strict",catchall:Kr.create(),typeName:me.ZodObject,...ve(t)}),it.lazycreate=(e,t)=>new it({shape:e,unknownKeys:"strip",catchall:Kr.create(),typeName:me.ZodObject,...ve(t)});class dl extends _e{_parse(t){const{ctx:n}=this._processInputParams(t),r=this._def.options;function i(a){for(const s of a)if(s.result.status==="valid")return s.result;for(const s of a)if(s.result.status==="dirty")return n.common.issues.push(...s.ctx.common.issues),s.result;const o=a.map(s=>new Tn(s.ctx.common.issues));return re(n,{code:q.invalid_union,unionErrors:o}),ge}if(n.common.async)return Promise.all(r.map(async a=>{const o={...n,common:{...n.common,issues:[]},parent:null};return{result:await a._parseAsync({data:n.data,path:n.path,parent:o}),ctx:o}})).then(i);{let a;const o=[];for(const l of r){const u={...n,common:{...n.common,issues:[]},parent:null},c=l._parseSync({data:n.data,path:n.path,parent:u});if(c.status==="valid")return c;c.status==="dirty"&&!a&&(a={result:c,ctx:u}),u.common.issues.length&&o.push(u.common.issues)}if(a)return n.common.issues.push(...a.ctx.common.issues),a.result;const s=o.map(l=>new Tn(l));return re(n,{code:q.invalid_union,unionErrors:s}),ge}}get options(){return this._def.options}}dl.create=(e,t)=>new dl({options:e,typeName:me.ZodUnion,...ve(t)});const Xr=e=>e instanceof hl?Xr(e.schema):e instanceof rr?Xr(e.innerType()):e instanceof ml?[e.value]:e instanceof Ni?e.options:e instanceof gl?De.objectValues(e.enum):e instanceof wl?Xr(e._def.innerType):e instanceof ul?[void 0]:e instanceof cl?[null]:e instanceof Sr?[void 0,...Xr(e.unwrap())]:e instanceof Oi?[null,...Xr(e.unwrap())]:e instanceof nm||e instanceof bl?Xr(e.unwrap()):e instanceof yl?Xr(e._def.innerType):[];class Hc extends _e{_parse(t){const{ctx:n}=this._processInputParams(t);if(n.parsedType!==ie.object)return re(n,{code:q.invalid_type,expected:ie.object,received:n.parsedType}),ge;const r=this.discriminator,i=n.data[r],a=this.optionsMap.get(i);return a?n.common.async?a._parseAsync({data:n.data,path:n.path,parent:n}):a._parseSync({data:n.data,path:n.path,parent:n}):(re(n,{code:q.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),ge)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,n,r){const i=new Map;for(const a of n){const o=Xr(a.shape[t]);if(!o.length)throw new Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(const s of o){if(i.has(s))throw new Error(`Discriminator property ${String(t)} has duplicate value ${String(s)}`);i.set(s,a)}}return new Hc({typeName:me.ZodDiscriminatedUnion,discriminator:t,options:n,optionsMap:i,...ve(r)})}}function tm(e,t){const n=Ci(e),r=Ci(t);if(e===t)return{valid:!0,data:e};if(n===ie.object&&r===ie.object){const i=De.objectKeys(t),a=De.objectKeys(e).filter(s=>i.indexOf(s)!==-1),o={...e,...t};for(const s of a){const l=tm(e[s],t[s]);if(!l.valid)return{valid:!1};o[s]=l.data}return{valid:!0,data:o}}else if(n===ie.array&&r===ie.array){if(e.length!==t.length)return{valid:!1};const i=[];for(let a=0;a<e.length;a++){const o=e[a],s=t[a],l=tm(o,s);if(!l.valid)return{valid:!1};i.push(l.data)}return{valid:!0,data:i}}else return n===ie.date&&r===ie.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}class fl extends _e{_parse(t){const{status:n,ctx:r}=this._processInputParams(t),i=(a,o)=>{if(Zh(a)||Zh(o))return ge;const s=tm(a.value,o.value);return s.valid?((Jh(a)||Jh(o))&&n.dirty(),{status:n.value,value:s.data}):(re(r,{code:q.invalid_intersection_types}),ge)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([a,o])=>i(a,o)):i(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}fl.create=(e,t,n)=>new fl({left:e,right:t,typeName:me.ZodIntersection,...ve(n)});class _r extends _e{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==ie.array)return re(r,{code:q.invalid_type,expected:ie.array,received:r.parsedType}),ge;if(r.data.length<this._def.items.length)return re(r,{code:q.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),ge;!this._def.rest&&r.data.length>this._def.items.length&&(re(r,{code:q.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());const a=[...r.data].map((o,s)=>{const l=this._def.items[s]||this._def.rest;return l?l._parse(new Tr(r,o,r.path,s)):null}).filter(o=>!!o);return r.common.async?Promise.all(a).then(o=>jt.mergeArray(n,o)):jt.mergeArray(n,a)}get items(){return this._def.items}rest(t){return new _r({...this._def,rest:t})}}_r.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new _r({items:e,typeName:me.ZodTuple,rest:null,...ve(t)})};class pl extends _e{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==ie.object)return re(r,{code:q.invalid_type,expected:ie.object,received:r.parsedType}),ge;const i=[],a=this._def.keyType,o=this._def.valueType;for(const s in r.data)i.push({key:a._parse(new Tr(r,s,r.path,s)),value:o._parse(new Tr(r,r.data[s],r.path,s)),alwaysSet:s in r.data});return r.common.async?jt.mergeObjectAsync(n,i):jt.mergeObjectSync(n,i)}get element(){return this._def.valueType}static create(t,n,r){return n instanceof _e?new pl({keyType:t,valueType:n,typeName:me.ZodRecord,...ve(r)}):new pl({keyType:tr.create(),valueType:t,typeName:me.ZodRecord,...ve(n)})}}class Vc extends _e{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==ie.map)return re(r,{code:q.invalid_type,expected:ie.map,received:r.parsedType}),ge;const i=this._def.keyType,a=this._def.valueType,o=[...r.data.entries()].map(([s,l],u)=>({key:i._parse(new Tr(r,s,r.path,[u,"key"])),value:a._parse(new Tr(r,l,r.path,[u,"value"]))}));if(r.common.async){const s=new Map;return Promise.resolve().then(async()=>{for(const l of o){const u=await l.key,c=await l.value;if(u.status==="aborted"||c.status==="aborted")return ge;(u.status==="dirty"||c.status==="dirty")&&n.dirty(),s.set(u.value,c.value)}return{status:n.value,value:s}})}else{const s=new Map;for(const l of o){const u=l.key,c=l.value;if(u.status==="aborted"||c.status==="aborted")return ge;(u.status==="dirty"||c.status==="dirty")&&n.dirty(),s.set(u.value,c.value)}return{status:n.value,value:s}}}}Vc.create=(e,t,n)=>new Vc({valueType:t,keyType:e,typeName:me.ZodMap,...ve(n)});class Pa extends _e{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==ie.set)return re(r,{code:q.invalid_type,expected:ie.set,received:r.parsedType}),ge;const i=this._def;i.minSize!==null&&r.data.size<i.minSize.value&&(re(r,{code:q.too_small,minimum:i.minSize.value,type:"set",inclusive:!0,exact:!1,message:i.minSize.message}),n.dirty()),i.maxSize!==null&&r.data.size>i.maxSize.value&&(re(r,{code:q.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),n.dirty());const a=this._def.valueType;function o(l){const u=new Set;for(const c of l){if(c.status==="aborted")return ge;c.status==="dirty"&&n.dirty(),u.add(c.value)}return{status:n.value,value:u}}const s=[...r.data.values()].map((l,u)=>a._parse(new Tr(r,l,r.path,u)));return r.common.async?Promise.all(s).then(l=>o(l)):o(s)}min(t,n){return new Pa({...this._def,minSize:{value:t,message:ce.toString(n)}})}max(t,n){return new Pa({...this._def,maxSize:{value:t,message:ce.toString(n)}})}size(t,n){return this.min(t,n).max(t,n)}nonempty(t){return this.min(1,t)}}Pa.create=(e,t)=>new Pa({valueType:e,minSize:null,maxSize:null,typeName:me.ZodSet,...ve(t)});class To extends _e{constructor(){super(...arguments),this.validate=this.implement}_parse(t){const{ctx:n}=this._processInputParams(t);if(n.parsedType!==ie.function)return re(n,{code:q.invalid_type,expected:ie.function,received:n.parsedType}),ge;function r(s,l){return Bc({data:s,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Fc(),vo].filter(u=>!!u),issueData:{code:q.invalid_arguments,argumentsError:l}})}function i(s,l){return Bc({data:s,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Fc(),vo].filter(u=>!!u),issueData:{code:q.invalid_return_type,returnTypeError:l}})}const a={errorMap:n.common.contextualErrorMap},o=n.data;if(this._def.returns instanceof _o){const s=this;return Zt(async function(...l){const u=new Tn([]),c=await s._def.args.parseAsync(l,a).catch(p=>{throw u.addIssue(r(l,p)),u}),d=await Reflect.apply(o,this,c);return await s._def.returns._def.type.parseAsync(d,a).catch(p=>{throw u.addIssue(i(d,p)),u})})}else{const s=this;return Zt(function(...l){const u=s._def.args.safeParse(l,a);if(!u.success)throw new Tn([r(l,u.error)]);const c=Reflect.apply(o,this,u.data),d=s._def.returns.safeParse(c,a);if(!d.success)throw new Tn([i(c,d.error)]);return d.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new To({...this._def,args:_r.create(t).rest(Oa.create())})}returns(t){return new To({...this._def,returns:t})}implement(t){return this.parse(t)}strictImplement(t){return this.parse(t)}static create(t,n,r){return new To({args:t||_r.create([]).rest(Oa.create()),returns:n||Oa.create(),typeName:me.ZodFunction,...ve(r)})}}class hl extends _e{get schema(){return this._def.getter()}_parse(t){const{ctx:n}=this._processInputParams(t);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}}hl.create=(e,t)=>new hl({getter:e,typeName:me.ZodLazy,...ve(t)});class ml extends _e{_parse(t){if(t.data!==this._def.value){const n=this._getOrReturnCtx(t);return re(n,{received:n.data,code:q.invalid_literal,expected:this._def.value}),ge}return{status:"valid",value:t.data}}get value(){return this._def.value}}ml.create=(e,t)=>new ml({value:e,typeName:me.ZodLiteral,...ve(t)});function wx(e,t){return new Ni({values:e,typeName:me.ZodEnum,...ve(t)})}class Ni extends _e{constructor(){super(...arguments),ol.set(this,void 0)}_parse(t){if(typeof t.data!="string"){const n=this._getOrReturnCtx(t),r=this._def.values;return re(n,{expected:De.joinValues(r),received:n.parsedType,code:q.invalid_type}),ge}if(jc(this,ol)||fx(this,ol,new Set(this._def.values)),!jc(this,ol).has(t.data)){const n=this._getOrReturnCtx(t),r=this._def.values;return re(n,{received:n.data,code:q.invalid_enum_value,options:r}),ge}return Zt(t.data)}get options(){return this._def.values}get enum(){const t={};for(const n of this._def.values)t[n]=n;return t}get Values(){const t={};for(const n of this._def.values)t[n]=n;return t}get Enum(){const t={};for(const n of this._def.values)t[n]=n;return t}extract(t,n=this._def){return Ni.create(t,{...this._def,...n})}exclude(t,n=this._def){return Ni.create(this.options.filter(r=>!t.includes(r)),{...this._def,...n})}}ol=new WeakMap,Ni.create=wx;class gl extends _e{constructor(){super(...arguments),sl.set(this,void 0)}_parse(t){const n=De.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(t);if(r.parsedType!==ie.string&&r.parsedType!==ie.number){const i=De.objectValues(n);return re(r,{expected:De.joinValues(i),received:r.parsedType,code:q.invalid_type}),ge}if(jc(this,sl)||fx(this,sl,new Set(De.getValidEnumValues(this._def.values))),!jc(this,sl).has(t.data)){const i=De.objectValues(n);return re(r,{received:r.data,code:q.invalid_enum_value,options:i}),ge}return Zt(t.data)}get enum(){return this._def.values}}sl=new WeakMap,gl.create=(e,t)=>new gl({values:e,typeName:me.ZodNativeEnum,...ve(t)});class _o extends _e{unwrap(){return this._def.type}_parse(t){const{ctx:n}=this._processInputParams(t);if(n.parsedType!==ie.promise&&n.common.async===!1)return re(n,{code:q.invalid_type,expected:ie.promise,received:n.parsedType}),ge;const r=n.parsedType===ie.promise?n.data:Promise.resolve(n.data);return Zt(r.then(i=>this._def.type.parseAsync(i,{path:n.path,errorMap:n.common.contextualErrorMap})))}}_o.create=(e,t)=>new _o({type:e,typeName:me.ZodPromise,...ve(t)});class rr extends _e{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===me.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){const{status:n,ctx:r}=this._processInputParams(t),i=this._def.effect||null,a={addIssue:o=>{re(r,o),o.fatal?n.abort():n.dirty()},get path(){return r.path}};if(a.addIssue=a.addIssue.bind(a),i.type==="preprocess"){const o=i.transform(r.data,a);if(r.common.async)return Promise.resolve(o).then(async s=>{if(n.value==="aborted")return ge;const l=await this._def.schema._parseAsync({data:s,path:r.path,parent:r});return l.status==="aborted"?ge:l.status==="dirty"||n.value==="dirty"?bo(l.value):l});{if(n.value==="aborted")return ge;const s=this._def.schema._parseSync({data:o,path:r.path,parent:r});return s.status==="aborted"?ge:s.status==="dirty"||n.value==="dirty"?bo(s.value):s}}if(i.type==="refinement"){const o=s=>{const l=i.refinement(s,a);if(r.common.async)return Promise.resolve(l);if(l instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return s};if(r.common.async===!1){const s=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return s.status==="aborted"?ge:(s.status==="dirty"&&n.dirty(),o(s.value),{status:n.value,value:s.value})}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(s=>s.status==="aborted"?ge:(s.status==="dirty"&&n.dirty(),o(s.value).then(()=>({status:n.value,value:s.value}))))}if(i.type==="transform")if(r.common.async===!1){const o=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!il(o))return o;const s=i.transform(o.value,a);if(s instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:s}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(o=>il(o)?Promise.resolve(i.transform(o.value,a)).then(s=>({status:n.value,value:s})):o);De.assertNever(i)}}rr.create=(e,t,n)=>new rr({schema:e,typeName:me.ZodEffects,effect:t,...ve(n)}),rr.createWithPreprocess=(e,t,n)=>new rr({schema:t,effect:{type:"preprocess",transform:e},typeName:me.ZodEffects,...ve(n)});class Sr extends _e{_parse(t){return this._getType(t)===ie.undefined?Zt(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}Sr.create=(e,t)=>new Sr({innerType:e,typeName:me.ZodOptional,...ve(t)});class Oi extends _e{_parse(t){return this._getType(t)===ie.null?Zt(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}Oi.create=(e,t)=>new Oi({innerType:e,typeName:me.ZodNullable,...ve(t)});class wl extends _e{_parse(t){const{ctx:n}=this._processInputParams(t);let r=n.data;return n.parsedType===ie.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:n.path,parent:n})}removeDefault(){return this._def.innerType}}wl.create=(e,t)=>new wl({innerType:e,typeName:me.ZodDefault,defaultValue:typeof t.default=="function"?t.default:()=>t.default,...ve(t)});class yl extends _e{_parse(t){const{ctx:n}=this._processInputParams(t),r={...n,common:{...n.common,issues:[]}},i=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return al(i)?i.then(a=>({status:"valid",value:a.status==="valid"?a.value:this._def.catchValue({get error(){return new Tn(r.common.issues)},input:r.data})})):{status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new Tn(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}yl.create=(e,t)=>new yl({innerType:e,typeName:me.ZodCatch,catchValue:typeof t.catch=="function"?t.catch:()=>t.catch,...ve(t)});class $c extends _e{_parse(t){if(this._getType(t)!==ie.nan){const r=this._getOrReturnCtx(t);return re(r,{code:q.invalid_type,expected:ie.nan,received:r.parsedType}),ge}return{status:"valid",value:t.data}}}$c.create=e=>new $c({typeName:me.ZodNaN,...ve(e)});const iD=Symbol("zod_brand");class nm extends _e{_parse(t){const{ctx:n}=this._processInputParams(t),r=n.data;return this._def.type._parse({data:r,path:n.path,parent:n})}unwrap(){return this._def.type}}class vl extends _e{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.common.async)return(async()=>{const a=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return a.status==="aborted"?ge:a.status==="dirty"?(n.dirty(),bo(a.value)):this._def.out._parseAsync({data:a.value,path:r.path,parent:r})})();{const i=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return i.status==="aborted"?ge:i.status==="dirty"?(n.dirty(),{status:"dirty",value:i.value}):this._def.out._parseSync({data:i.value,path:r.path,parent:r})}}static create(t,n){return new vl({in:t,out:n,typeName:me.ZodPipeline})}}class bl extends _e{_parse(t){const n=this._def.innerType._parse(t),r=i=>(il(i)&&(i.value=Object.freeze(i.value)),i);return al(n)?n.then(i=>r(i)):r(n)}unwrap(){return this._def.innerType}}bl.create=(e,t)=>new bl({innerType:e,typeName:me.ZodReadonly,...ve(t)});function yx(e,t={},n){return e?xo.create().superRefine((r,i)=>{var a,o;if(!e(r)){const s=typeof t=="function"?t(r):typeof t=="string"?{message:t}:t,l=(o=(a=s.fatal)!==null&&a!==void 0?a:n)!==null&&o!==void 0?o:!0,u=typeof s=="string"?{message:s}:s;i.addIssue({code:"custom",...u,fatal:l})}}):xo.create()}const aD={object:it.lazycreate};var me;(function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"})(me||(me={}));const oD=(e,t={message:`Input not instance of ${e.name}`})=>yx(n=>n instanceof e,t),vx=tr.create,bx=Ai.create,sD=$c.create,lD=Ri.create,xx=ll.create,uD=Na.create,cD=zc.create,dD=ul.create,fD=cl.create,pD=xo.create,hD=Oa.create,mD=Kr.create,gD=Uc.create,wD=nr.create,yD=it.create,vD=it.strictCreate,bD=dl.create,xD=Hc.create,ED=fl.create,TD=_r.create,_D=pl.create,SD=Vc.create,kD=Pa.create,CD=To.create,AD=hl.create,RD=ml.create,ND=Ni.create,OD=gl.create,PD=_o.create,Ex=rr.create,ID=Sr.create,DD=Oi.create,LD=rr.createWithPreprocess,MD=vl.create;var Q=Object.freeze({__proto__:null,defaultErrorMap:vo,setErrorMap:U5,getErrorMap:Fc,makeIssue:Bc,EMPTY_PATH:H5,addIssueToContext:re,ParseStatus:jt,INVALID:ge,DIRTY:bo,OK:Zt,isAborted:Zh,isDirty:Jh,isValid:il,isAsync:al,get util(){return De},get objectUtil(){return Qh},ZodParsedType:ie,getParsedType:Ci,ZodType:_e,datetimeRegex:gx,ZodString:tr,ZodNumber:Ai,ZodBigInt:Ri,ZodBoolean:ll,ZodDate:Na,ZodSymbol:zc,ZodUndefined:ul,ZodNull:cl,ZodAny:xo,ZodUnknown:Oa,ZodNever:Kr,ZodVoid:Uc,ZodArray:nr,ZodObject:it,ZodUnion:dl,ZodDiscriminatedUnion:Hc,ZodIntersection:fl,ZodTuple:_r,ZodRecord:pl,ZodMap:Vc,ZodSet:Pa,ZodFunction:To,ZodLazy:hl,ZodLiteral:ml,ZodEnum:Ni,ZodNativeEnum:gl,ZodPromise:_o,ZodEffects:rr,ZodTransformer:rr,ZodOptional:Sr,ZodNullable:Oi,ZodDefault:wl,ZodCatch:yl,ZodNaN:$c,BRAND:iD,ZodBranded:nm,ZodPipeline:vl,ZodReadonly:bl,custom:yx,Schema:_e,ZodSchema:_e,late:aD,get ZodFirstPartyTypeKind(){return me},coerce:{string:e=>tr.create({...e,coerce:!0}),number:e=>Ai.create({...e,coerce:!0}),boolean:e=>ll.create({...e,coerce:!0}),bigint:e=>Ri.create({...e,coerce:!0}),date:e=>Na.create({...e,coerce:!0})},any:pD,array:wD,bigint:lD,boolean:xx,date:uD,discriminatedUnion:xD,effect:Ex,enum:ND,function:CD,instanceof:oD,intersection:ED,lazy:AD,literal:RD,map:SD,nan:sD,nativeEnum:OD,never:mD,null:fD,nullable:DD,number:bx,object:yD,oboolean:()=>xx().optional(),onumber:()=>bx().optional(),optional:ID,ostring:()=>vx().optional(),pipeline:MD,preprocess:LD,promise:PD,record:_D,set:kD,strictObject:vD,string:vx,symbol:cD,transformer:Ex,tuple:TD,undefined:dD,union:bD,unknown:hD,void:gD,NEVER:ge,ZodIssueCode:q,quotelessJson:z5,ZodError:Tn}),Wc=(e=>(e[e.OPEN=0]="OPEN",e[e.CLOSED_RESOLVED=1]="CLOSED_RESOLVED",e[e.CLOSED_UNRESOLVED=2]="CLOSED_UNRESOLVED",e))(Wc||{}),Tx=(e=>(e.WEB="web",e.WEB_VOICE="web_voice",e.PHONE_VOICE="phone_voice",e.EMAIL="email",e.SMS="sms",e.WHATSAPP="whatsapp",e.API="api",e))(Tx||{}),Yc=(e=>(e.resolved="resolved",e.assumed_resolved="assumed_resolved",e.handed_off="handed_off",e))(Yc||{}),_x=(e=>(e.happy="happy",e.neutral="neutral",e.angry="angry",e))(_x||{}),Sx=(e=>(e.MESSAGE="message",e.HANDOFF="handoff",e.HANDOFF_TO_ZENDESK="handoff_to_zendesk",e.AGENT_MESSAGE="agent_message",e.AGENT_JOINED="agent_joined",e.AGENT_TOOK_SESSION_FROM_AI="agent_took_session_from_ai",e.AI_DECIDED_TO_RESOLVE_THE_ISSUE="ai_decided_to_resolve_the_issue",e.EMAIL_DRAFT_MESSAGE="email_draft_message",e.FOLLOWUP="followup",e))(Sx||{});const FD=Q.object({id:Q.string(),ai_closure_type:Q.nativeEnum(Yc).nullable(),assignee_id:Q.number().nullable(),channel:Q.nativeEnum(Tx),summary:Q.string().nullable(),status:Q.nativeEnum(Wc),language:Q.string().nullable(),last_message:Q.string().nullable(),last_message_at:Q.date().nullable(),assignee:Q.object({name:Q.string(),email:Q.string(),avatar_url:Q.string().optional()}).nullable().optional(),sentiment:Q.nativeEnum(_x).nullable()}),kx=Q.object({id:Q.string(),name:Q.string(),size:Q.number(),type:Q.string(),url:Q.string()});Q.object({publicId:Q.string().uuid(),message:Q.string().nullable(),type:Q.string().nullable(),agent_avatar:Q.string().nullable(),agent_id:Q.number().nullable(),agent_name:Q.string().nullable(),created_at:Q.string(),from_user:Q.boolean().nullable(),handoff_happened_during_office_hours:Q.boolean().nullable(),session_id:Q.string(),updated_at:Q.string().nullable(),attachments:Q.array(kx).optional()});const BD=Q.object({name:Q.string(),is_ai:Q.boolean(),profile_picture:Q.string().optional().nullable(),id:Q.string().nullable()}),jD=Q.object({type:Q.literal("message"),value:Q.string(),attachments:Q.array(kx).optional(),is_stream_chunk:Q.boolean().optional(),server_session_id:Q.string(),client_message_id:Q.string().optional(),server_message_id:Q.string()}),zD=Q.object({type:Q.literal("info"),value:Q.string()}),UD=Q.object({type:Q.literal("ui"),value:Q.object({type:Q.string(),request_response:Q.any(),name:Q.string(),content:Q.string(),message_id:Q.string().optional()}),client_message_id:Q.string().optional(),server_session_id:Q.string()}),HD=Q.object({type:Q.literal("chat_event"),value:Q.object({event:Q.nativeEnum(Sx),message:Q.string()})}),VD=Q.object({type:Q.literal("options"),value:Q.object({options:Q.array(Q.string())}),server_session_id:Q.string()}),$D=Q.object({type:Q.literal("session_update"),value:Q.object({session:FD}),server_session_id:Q.string()});Q.discriminatedUnion("type",[jD,zD,UD,HD,VD,$D]).and(Q.object({timestamp:Q.string(),agent:BD})),Q.object({id:Q.string(),name:Q.string().nullable(),created_at:Q.string(),avatar_url:Q.string().nullable(),email:Q.string().nullable()});function WD(e){var n,r,i,a,o,s,l;const t=e._message;switch(t&&((n=e.onAny)==null||n.call(e,t,e)),t.type){case"message":{(r=e.onBotMessage)==null||r.call(e,{type:"FROM_BOT",component:"TEXT",id:t.server_message_id,timestamp:t.timestamp,attachments:t.attachments,data:{message:t.value},agent:t.agent.is_ai?e._config.bot:t.agent},e);break}case"info":(i=e.onInfo)==null||i.call(e,t,e);break;case"chat_event":{(a=e.onChatEvent)==null||a.call(e,{component:"CHAT_EVENT",type:"FROM_BOT",id:Yr(),data:{event:t.value.event,message:t.value.message},timestamp:t.timestamp},e);break}case"session_update":(o=e.onSessionUpdate)==null||o.call(e,t,e);break;case"options":(s=e.onOptions)==null||s.call(e,t,e);break;case"ui":{const u=t.value;(l=e.onUi)==null||l.call(e,{type:"FROM_BOT",component:u.name,data:u.request_response,id:Yr(),timestamp:t.timestamp},e);break}}}const kr=Object.create(null);kr.open="0",kr.close="1",kr.ping="2",kr.pong="3",kr.message="4",kr.upgrade="5",kr.noop="6";const qc=Object.create(null);Object.keys(kr).forEach(e=>{qc[kr[e]]=e});const rm={type:"error",data:"parser error"},Cx=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",Ax=typeof ArrayBuffer=="function",Rx=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,im=({type:e,data:t},n,r)=>Cx&&t instanceof Blob?n?r(t):Nx(t,r):Ax&&(t instanceof ArrayBuffer||Rx(t))?n?r(t):Nx(new Blob([t]),r):r(kr[e]+(t||"")),Nx=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function Ox(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let am;function YD(e,t){if(Cx&&e.data instanceof Blob)return e.data.arrayBuffer().then(Ox).then(t);if(Ax&&(e.data instanceof ArrayBuffer||Rx(e.data)))return t(Ox(e.data));im(e,!1,n=>{am||(am=new TextEncoder),t(am.encode(n))})}const Px="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",xl=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let e=0;e<Px.length;e++)xl[Px.charCodeAt(e)]=e;const qD=e=>{let t=e.length*.75,n=e.length,r,i=0,a,o,s,l;e[e.length-1]==="="&&(t--,e[e.length-2]==="="&&t--);const u=new ArrayBuffer(t),c=new Uint8Array(u);for(r=0;r<n;r+=4)a=xl[e.charCodeAt(r)],o=xl[e.charCodeAt(r+1)],s=xl[e.charCodeAt(r+2)],l=xl[e.charCodeAt(r+3)],c[i++]=a<<2|o>>4,c[i++]=(o&15)<<4|s>>2,c[i++]=(s&3)<<6|l&63;return u},GD=typeof ArrayBuffer=="function",om=(e,t)=>{if(typeof e!="string")return{type:"message",data:Ix(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:KD(e.substring(1),t)}:qc[n]?e.length>1?{type:qc[n],data:e.substring(1)}:{type:qc[n]}:rm},KD=(e,t)=>{if(GD){const n=qD(e);return Ix(n,t)}else return{base64:!0,data:e}},Ix=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},Dx="",XD=(e,t)=>{const n=e.length,r=new Array(n);let i=0;e.forEach((a,o)=>{im(a,!1,s=>{r[o]=s,++i===n&&t(r.join(Dx))})})},QD=(e,t)=>{const n=e.split(Dx),r=[];for(let i=0;i<n.length;i++){const a=om(n[i],t);if(r.push(a),a.type==="error")break}return r};function ZD(){return new TransformStream({transform(e,t){YD(e,n=>{const r=n.length;let i;if(r<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,r);else if(r<65536){i=new Uint8Array(3);const a=new DataView(i.buffer);a.setUint8(0,126),a.setUint16(1,r)}else{i=new Uint8Array(9);const a=new DataView(i.buffer);a.setUint8(0,127),a.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(i[0]|=128),t.enqueue(i),t.enqueue(n)})}})}let sm;function Gc(e){return e.reduce((t,n)=>t+n.length,0)}function Kc(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let i=0;i<t;i++)n[i]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function JD(e,t){sm||(sm=new TextDecoder);const n=[];let r=0,i=-1,a=!1;return new TransformStream({transform(o,s){for(n.push(o);;){if(r===0){if(Gc(n)<1)break;const l=Kc(n,1);a=(l[0]&128)===128,i=l[0]&127,i<126?r=3:i===126?r=1:r=2}else if(r===1){if(Gc(n)<2)break;const l=Kc(n,2);i=new DataView(l.buffer,l.byteOffset,l.length).getUint16(0),r=3}else if(r===2){if(Gc(n)<8)break;const l=Kc(n,8),u=new DataView(l.buffer,l.byteOffset,l.length),c=u.getUint32(0);if(c>Math.pow(2,21)-1){s.enqueue(rm);break}i=c*Math.pow(2,32)+u.getUint32(4),r=3}else{if(Gc(n)<i)break;const l=Kc(n,i);s.enqueue(om(a?l:sm.decode(l),t)),r=0}if(i===0||i>e){s.enqueue(rm);break}}}})}const Lx=4;function gt(e){if(e)return eL(e)}function eL(e){for(var t in gt.prototype)e[t]=gt.prototype[t];return e}gt.prototype.on=gt.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},gt.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},gt.prototype.off=gt.prototype.removeListener=gt.prototype.removeAllListeners=gt.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks["$"+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var r,i=0;i<n.length;i++)if(r=n[i],r===t||r.fn===t){n.splice(i,1);break}return n.length===0&&delete this._callbacks["$"+e],this},gt.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){n=n.slice(0);for(var r=0,i=n.length;r<i;++r)n[r].apply(this,t)}return this},gt.prototype.emitReserved=gt.prototype.emit,gt.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},gt.prototype.hasListeners=function(e){return!!this.listeners(e).length};const Xc=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),Fn=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),tL="arraybuffer";function jse(){}function Mx(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const nL=Fn.setTimeout,rL=Fn.clearTimeout;function Qc(e,t){t.useNativeTimers?(e.setTimeoutFn=nL.bind(Fn),e.clearTimeoutFn=rL.bind(Fn)):(e.setTimeoutFn=Fn.setTimeout.bind(Fn),e.clearTimeoutFn=Fn.clearTimeout.bind(Fn))}const iL=1.33;function aL(e){return typeof e=="string"?oL(e):Math.ceil((e.byteLength||e.size)*iL)}function oL(e){let t=0,n=0;for(let r=0,i=e.length;r<i;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}function Fx(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function sL(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function lL(e){let t={},n=e.split("&");for(let r=0,i=n.length;r<i;r++){let a=n[r].split("=");t[decodeURIComponent(a[0])]=decodeURIComponent(a[1])}return t}class uL extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class lm extends gt{constructor(t){super(),this.writable=!1,Qc(this,t),this.opts=t,this.query=t.query,this.socket=t.socket,this.supportsBinary=!t.forceBase64}onError(t,n,r){return super.emitReserved("error",new uL(t,n,r)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(t){this.readyState==="open"&&this.write(t)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(t){const n=om(t,this.socket.binaryType);this.onPacket(n)}onPacket(t){super.emitReserved("packet",t)}onClose(t){this.readyState="closed",super.emitReserved("close",t)}pause(t){}createUri(t,n={}){return t+"://"+this._hostname()+this._port()+this.opts.path+this._query(n)}_hostname(){const t=this.opts.hostname;return t.indexOf(":")===-1?t:"["+t+"]"}_port(){return this.opts.port&&(this.opts.secure&&+(this.opts.port!==443)||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(t){const n=sL(t);return n.length?"?"+n:""}}class cL extends lm{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(t){this.readyState="pausing";const n=()=>{this.readyState="paused",t()};if(this._polling||!this.writable){let r=0;this._polling&&(r++,this.once("pollComplete",function(){--r||n()})),this.writable||(r++,this.once("drain",function(){--r||n()}))}else n()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){const n=r=>{if(this.readyState==="opening"&&r.type==="open"&&this.onOpen(),r.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(r)};QD(t,this.socket.binaryType).forEach(n),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){const t=()=>{this.write([{type:"close"}])};this.readyState==="open"?t():this.once("open",t)}write(t){this.writable=!1,XD(t,n=>{this.doWrite(n,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const t=this.opts.secure?"https":"http",n=this.query||{};return this.opts.timestampRequests!==!1&&(n[this.opts.timestampParam]=Fx()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let Bx=!1;try{Bx=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}const dL=Bx;function fL(){}class pL extends cL{constructor(t){if(super(t),typeof location<"u"){const n=location.protocol==="https:";let r=location.port;r||(r=n?"443":"80"),this.xd=typeof location<"u"&&t.hostname!==location.hostname||r!==t.port}}doWrite(t,n){const r=this.request({method:"POST",data:t});r.on("success",n),r.on("error",(i,a)=>{this.onError("xhr post error",i,a)})}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",(n,r)=>{this.onError("xhr poll error",n,r)}),this.pollXhr=t}}let So=class dh extends gt{constructor(t,n,r){super(),this.createRequest=t,Qc(this,r),this._opts=r,this._method=r.method||"GET",this._uri=n,this._data=r.data!==void 0?r.data:null,this._create()}_create(){var t;const n=Mx(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this._opts.xd;const r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let i in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(i)&&r.setRequestHeader(i,this._opts.extraHeaders[i])}}catch{}if(this._method==="POST")try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{r.setRequestHeader("Accept","*/*")}catch{}(t=this._opts.cookieJar)===null||t===void 0||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var i;r.readyState===3&&((i=this._opts.cookieJar)===null||i===void 0||i.parseCookies(r.getResponseHeader("set-cookie"))),r.readyState===4&&(r.status===200||r.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof r.status=="number"?r.status:0)},0))},r.send(this._data)}catch(i){this.setTimeoutFn(()=>{this._onError(i)},0);return}typeof document<"u"&&(this._index=dh.requestsCount++,dh.requests[this._index]=this)}_onError(t){this.emitReserved("error",t,this._xhr),this._cleanup(!0)}_cleanup(t){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=fL,t)try{this._xhr.abort()}catch{}typeof document<"u"&&delete dh.requests[this._index],this._xhr=null}}_onLoad(){const t=this._xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}};if(So.requestsCount=0,So.requests={},typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",jx);else if(typeof addEventListener=="function"){const e="onpagehide"in Fn?"pagehide":"unload";addEventListener(e,jx,!1)}}function jx(){for(let e in So.requests)So.requests.hasOwnProperty(e)&&So.requests[e].abort()}const hL=function(){const e=zx({xdomain:!1});return e&&e.responseType!==null}();class mL extends pL{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=hL&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new So(zx,this.uri(),t)}}function zx(e){const t=e.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!t||dL))return new XMLHttpRequest}catch{}if(!t)try{return new Fn[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}const Ux=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class gL extends lm{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=Ux?{}:Mx(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(t,n,r)}catch(i){return this.emitReserved("error",i)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],i=n===t.length-1;im(r,this.supportsBinary,a=>{try{this.doWrite(r,a)}catch{}i&&Xc(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",n=this.query||{};return this.opts.timestampRequests&&(n[this.opts.timestampParam]=Fx()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const um=Fn.WebSocket||Fn.MozWebSocket;class wL extends gL{createSocket(t,n,r){return Ux?new um(t,n,r):n?new um(t,n):new um(t)}doWrite(t,n){this.ws.send(n)}}class yL extends lm{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(t){return this.emitReserved("error",t)}this._transport.closed.then(()=>{this.onClose()}).catch(t=>{this.onError("webtransport error",t)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(t=>{const n=JD(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),i=ZD();i.readable.pipeTo(t.writable),this._writer=i.writable.getWriter();const a=()=>{r.read().then(({done:s,value:l})=>{s||(this.onPacket(l),a())}).catch(s=>{})};a();const o={type:"open"};this.query.sid&&(o.data=`{"sid":"${this.query.sid}"}`),this._writer.write(o).then(()=>this.onOpen())})})}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],i=n===t.length-1;this._writer.write(r).then(()=>{i&&Xc(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const vL={websocket:wL,webtransport:yL,polling:mL},bL=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,xL=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function cm(e){if(e.length>8e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let i=bL.exec(e||""),a={},o=14;for(;o--;)a[xL[o]]=i[o]||"";return n!=-1&&r!=-1&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a.pathNames=EL(a,a.path),a.queryKey=TL(a,a.query),a}function EL(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");return(t.slice(0,1)=="/"||t.length===0)&&r.splice(0,1),t.slice(-1)=="/"&&r.splice(r.length-1,1),r}function TL(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,i,a){i&&(n[i]=a)}),n}const dm=typeof addEventListener=="function"&&typeof removeEventListener=="function",Zc=[];dm&&addEventListener("offline",()=>{Zc.forEach(e=>e())},!1);class Pi extends gt{constructor(t,n){if(super(),this.binaryType=tL,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,t&&typeof t=="object"&&(n=t,t=null),t){const r=cm(t);n.hostname=r.host,n.secure=r.protocol==="https"||r.protocol==="wss",n.port=r.port,r.query&&(n.query=r.query)}else n.host&&(n.hostname=cm(n.host).host);Qc(this,n),this.secure=n.secure!=null?n.secure:typeof location<"u"&&location.protocol==="https:",n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.hostname=n.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=n.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},n.transports.forEach(r=>{const i=r.prototype.name;this.transports.push(i),this._transportsByName[i]=r}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},n),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=lL(this.opts.query)),dm&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},Zc.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=Lx,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](r)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const t=this.opts.rememberUpgrade&&Pi.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",n=>this._onClose("transport close",n))}onOpen(){this.readyState="open",Pi.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const n=new Error("server error");n.code=t.data,this._onError(n);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r<this.writeBuffer.length;r++){const i=this.writeBuffer[r].data;if(i&&(n+=aL(i)),r>0&&n>this._maxPayload)return this.writeBuffer.slice(0,r);n+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const t=Date.now()>this._pingTimeoutTime;return t&&(this._pingTimeoutTime=0,Xc(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,n,r){return this._sendPacket("message",t,n,r),this}send(t,n,r){return this._sendPacket("message",t,n,r),this}_sendPacket(t,n,r,i){if(typeof n=="function"&&(i=n,n=void 0),typeof r=="function"&&(i=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const a={type:t,data:n,options:r};this.emitReserved("packetCreate",a),this.writeBuffer.push(a),i&&this.once("flush",i),this.flush()}close(){const t=()=>{this._onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}_onError(t){if(Pi.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,n){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),dm&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=Zc.indexOf(this._offlineEventListener);r!==-1&&Zc.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}Pi.protocol=Lx;class _L extends Pi{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let t=0;t<this._upgrades.length;t++)this._probe(this._upgrades[t])}_probe(t){let n=this.createTransport(t),r=!1;Pi.priorWebsocketSuccess=!1;const i=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",d=>{if(!r)if(d.type==="pong"&&d.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;Pi.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(c(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const f=new Error("probe error");f.transport=n.name,this.emitReserved("upgradeError",f)}}))};function a(){r||(r=!0,c(),n.close(),n=null)}const o=d=>{const f=new Error("probe error: "+d);f.transport=n.name,a(),this.emitReserved("upgradeError",f)};function s(){o("transport closed")}function l(){o("socket closed")}function u(d){n&&d.name!==n.name&&a()}const c=()=>{n.removeListener("open",i),n.removeListener("error",o),n.removeListener("close",s),this.off("close",l),this.off("upgrading",u)};n.once("open",i),n.once("error",o),n.once("close",s),this.once("close",l),this.once("upgrading",u),this._upgrades.indexOf("webtransport")!==-1&&t!=="webtransport"?this.setTimeoutFn(()=>{r||n.open()},200):n.open()}onHandshake(t){this._upgrades=this._filterUpgrades(t.upgrades),super.onHandshake(t)}_filterUpgrades(t){const n=[];for(let r=0;r<t.length;r++)~this.transports.indexOf(t[r])&&n.push(t[r]);return n}}let SL=class extends _L{constructor(t,n={}){const r=typeof t=="object"?t:n;(!r.transports||r.transports&&typeof r.transports[0]=="string")&&(r.transports=(r.transports||["polling","websocket","webtransport"]).map(i=>vL[i]).filter(i=>!!i)),super(t,r)}};function kL(e,t="",n){let r=e;n=n||typeof location<"u"&&location,e==null&&(e=n.protocol+"//"+n.host),typeof e=="string"&&(e.charAt(0)==="/"&&(e.charAt(1)==="/"?e=n.protocol+e:e=n.host+e),/^(https?|wss?):\/\//.test(e)||(typeof n<"u"?e=n.protocol+"//"+e:e="https://"+e),r=cm(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";const a=r.host.indexOf(":")!==-1?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+a+":"+r.port+t,r.href=r.protocol+"://"+a+(n&&n.port===r.port?"":":"+r.port),r}const CL=typeof ArrayBuffer=="function",AL=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,Hx=Object.prototype.toString,RL=typeof Blob=="function"||typeof Blob<"u"&&Hx.call(Blob)==="[object BlobConstructor]",NL=typeof File=="function"||typeof File<"u"&&Hx.call(File)==="[object FileConstructor]";function fm(e){return CL&&(e instanceof ArrayBuffer||AL(e))||RL&&e instanceof Blob||NL&&e instanceof File}function Jc(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(Jc(e[n]))return!0;return!1}if(fm(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return Jc(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&Jc(e[n]))return!0;return!1}function OL(e){const t=[],n=e.data,r=e;return r.data=pm(n,t),r.attachments=t.length,{packet:r,buffers:t}}function pm(e,t){if(!e)return e;if(fm(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}else if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=pm(e[r],t);return n}else if(typeof e=="object"&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=pm(e[r],t));return n}return e}function PL(e,t){return e.data=hm(e.data,t),delete e.attachments,e}function hm(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num=="number"&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}else if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=hm(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=hm(e[n],t));return e}const IL=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],DL=5;var Ie;(function(e){e[e.CONNECT=0]="CONNECT",e[e.DISCONNECT=1]="DISCONNECT",e[e.EVENT=2]="EVENT",e[e.ACK=3]="ACK",e[e.CONNECT_ERROR=4]="CONNECT_ERROR",e[e.BINARY_EVENT=5]="BINARY_EVENT",e[e.BINARY_ACK=6]="BINARY_ACK"})(Ie||(Ie={}));class LL{constructor(t){this.replacer=t}encode(t){return(t.type===Ie.EVENT||t.type===Ie.ACK)&&Jc(t)?this.encodeAsBinary({type:t.type===Ie.EVENT?Ie.BINARY_EVENT:Ie.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===Ie.BINARY_EVENT||t.type===Ie.BINARY_ACK)&&(n+=t.attachments+"-"),t.nsp&&t.nsp!=="/"&&(n+=t.nsp+","),t.id!=null&&(n+=t.id),t.data!=null&&(n+=JSON.stringify(t.data,this.replacer)),n}encodeAsBinary(t){const n=OL(t),r=this.encodeAsString(n.packet),i=n.buffers;return i.unshift(r),i}}function Vx(e){return Object.prototype.toString.call(e)==="[object Object]"}class mm extends gt{constructor(t){super(),this.reviver=t}add(t){let n;if(typeof t=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=this.decodeString(t);const r=n.type===Ie.BINARY_EVENT;r||n.type===Ie.BINARY_ACK?(n.type=r?Ie.EVENT:Ie.ACK,this.reconstructor=new ML(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(fm(t)||t.base64)if(this.reconstructor)n=this.reconstructor.takeBinaryData(t),n&&(this.reconstructor=null,super.emitReserved("decoded",n));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+t)}decodeString(t){let n=0;const r={type:Number(t.charAt(0))};if(Ie[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===Ie.BINARY_EVENT||r.type===Ie.BINARY_ACK){const a=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const o=t.substring(a,n);if(o!=Number(o)||t.charAt(n)!=="-")throw new Error("Illegal attachments");r.attachments=Number(o)}if(t.charAt(n+1)==="/"){const a=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(a,n)}else r.nsp="/";const i=t.charAt(n+1);if(i!==""&&Number(i)==i){const a=n+1;for(;++n;){const o=t.charAt(n);if(o==null||Number(o)!=o){--n;break}if(n===t.length)break}r.id=Number(t.substring(a,n+1))}if(t.charAt(++n)){const a=this.tryParse(t.substr(n));if(mm.isPayloadValid(r.type,a))r.data=a;else throw new Error("invalid payload")}return r}tryParse(t){try{return JSON.parse(t,this.reviver)}catch{return!1}}static isPayloadValid(t,n){switch(t){case Ie.CONNECT:return Vx(n);case Ie.DISCONNECT:return n===void 0;case Ie.CONNECT_ERROR:return typeof n=="string"||Vx(n);case Ie.EVENT:case Ie.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&IL.indexOf(n[0])===-1);case Ie.ACK:case Ie.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class ML{constructor(t){this.packet=t,this.buffers=[],this.reconPack=t}takeBinaryData(t){if(this.buffers.push(t),this.buffers.length===this.reconPack.attachments){const n=PL(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const FL=Object.freeze(Object.defineProperty({__proto__:null,Decoder:mm,Encoder:LL,get PacketType(){return Ie},protocol:DL},Symbol.toStringTag,{value:"Module"}));function ir(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const BL=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class $x extends gt{constructor(t,n,r){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=t,this.nsp=n,r&&r.auth&&(this.auth=r.auth),this._opts=Object.assign({},r),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const t=this.io;this.subs=[ir(t,"open",this.onopen.bind(this)),ir(t,"packet",this.onpacket.bind(this)),ir(t,"error",this.onerror.bind(this)),ir(t,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...t){return t.unshift("message"),this.emit.apply(this,t),this}emit(t,...n){var r,i,a;if(BL.hasOwnProperty(t))throw new Error('"'+t.toString()+'" is a reserved event name');if(n.unshift(t),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(n),this;const o={type:Ie.EVENT,data:n};if(o.options={},o.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const c=this.ids++,d=n.pop();this._registerAckCallback(c,d),o.id=c}const s=(i=(r=this.io.engine)===null||r===void 0?void 0:r.transport)===null||i===void 0?void 0:i.writable,l=this.connected&&!(!((a=this.io.engine)===null||a===void 0)&&a._hasPingExpired());return this.flags.volatile&&!s||(l?(this.notifyOutgoingListeners(o),this.packet(o)):this.sendBuffer.push(o)),this.flags={},this}_registerAckCallback(t,n){var r;const i=(r=this.flags.timeout)!==null&&r!==void 0?r:this._opts.ackTimeout;if(i===void 0){this.acks[t]=n;return}const a=this.io.setTimeoutFn(()=>{delete this.acks[t];for(let s=0;s<this.sendBuffer.length;s++)this.sendBuffer[s].id===t&&this.sendBuffer.splice(s,1);n.call(this,new Error("operation has timed out"))},i),o=(...s)=>{this.io.clearTimeoutFn(a),n.apply(this,s)};o.withError=!0,this.acks[t]=o}emitWithAck(t,...n){return new Promise((r,i)=>{const a=(o,s)=>o?i(o):r(s);a.withError=!0,n.push(a),this.emit(t,...n)})}_addToQueue(t){let n;typeof t[t.length-1]=="function"&&(n=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push((i,...a)=>r!==this._queue[0]?void 0:(i!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(i)):(this._queue.shift(),n&&n(null,...a)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:Ie.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,n){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,n),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(t=>{if(!this.sendBuffer.some(r=>String(r.id)===t)){const r=this.acks[t];delete this.acks[t],r.withError&&r.call(this,new Error("socket has been disconnected"))}})}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case Ie.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case Ie.EVENT:case Ie.BINARY_EVENT:this.onevent(t);break;case Ie.ACK:case Ie.BINARY_ACK:this.onack(t);break;case Ie.DISCONNECT:this.ondisconnect();break;case Ie.CONNECT_ERROR:this.destroy();const r=new Error(t.data.message);r.data=t.data.data,this.emitReserved("connect_error",r);break}}onevent(t){const n=t.data||[];t.id!=null&&n.push(this.ack(t.id)),this.connected?this.emitEvent(n):this.receiveBuffer.push(Object.freeze(n))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const n=this._anyListeners.slice();for(const r of n)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&typeof t[t.length-1]=="string"&&(this._lastOffset=t[t.length-1])}ack(t){const n=this;let r=!1;return function(...i){r||(r=!0,n.packet({type:Ie.ACK,id:t,data:i}))}}onack(t){const n=this.acks[t.id];typeof n=="function"&&(delete this.acks[t.id],n.withError&&t.data.unshift(null),n.apply(this,t.data))}onconnect(t,n){this.id=t,this.recovered=n&&this._pid===n,this._pid=n,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:Ie.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const n=this._anyListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(t),this}prependAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(t),this}offAnyOutgoing(t){if(!this._anyOutgoingListeners)return this;if(t){const n=this._anyOutgoingListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(t){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const n=this._anyOutgoingListeners.slice();for(const r of n)r.apply(this,t.data)}}}function ko(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}ko.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+n:e-n}return Math.min(e,this.max)|0},ko.prototype.reset=function(){this.attempts=0},ko.prototype.setMin=function(e){this.ms=e},ko.prototype.setMax=function(e){this.max=e},ko.prototype.setJitter=function(e){this.jitter=e};class gm extends gt{constructor(t,n){var r;super(),this.nsps={},this.subs=[],t&&typeof t=="object"&&(n=t,t=void 0),n=n||{},n.path=n.path||"/socket.io",this.opts=n,Qc(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new ko({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const i=n.parser||FL;this.encoder=new i.Encoder,this.decoder=new i.Decoder,this._autoConnect=n.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,t||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(t){return t===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var n;return t===void 0?this._reconnectionDelay:(this._reconnectionDelay=t,(n=this.backoff)===null||n===void 0||n.setMin(t),this)}randomizationFactor(t){var n;return t===void 0?this._randomizationFactor:(this._randomizationFactor=t,(n=this.backoff)===null||n===void 0||n.setJitter(t),this)}reconnectionDelayMax(t){var n;return t===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,(n=this.backoff)===null||n===void 0||n.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new SL(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const i=ir(n,"open",function(){r.onopen(),t&&t()}),a=s=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",s),t?t(s):this.maybeReconnectOnOpen()},o=ir(n,"error",a);if(this._timeout!==!1){const s=this._timeout,l=this.setTimeoutFn(()=>{i(),a(new Error("timeout")),n.close()},s);this.opts.autoUnref&&l.unref(),this.subs.push(()=>{this.clearTimeoutFn(l)})}return this.subs.push(i),this.subs.push(o),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(ir(t,"ping",this.onping.bind(this)),ir(t,"data",this.ondata.bind(this)),ir(t,"error",this.onerror.bind(this)),ir(t,"close",this.onclose.bind(this)),ir(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(n){this.onclose("parse error",n)}}ondecoded(t){Xc(()=>{this.emitReserved("packet",t)},this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,n){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new $x(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;r<n.length;r++)this.engine.write(n[r],t.options)}cleanup(){this.subs.forEach(t=>t()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(t,n){var r;this.cleanup(),(r=this.engine)===null||r===void 0||r.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(i=>{i?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",i)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const El={};function ed(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=kL(e,t.path||"/socket.io"),r=n.source,i=n.id,a=n.path,o=El[i]&&a in El[i].nsps,s=t.forceNew||t["force new connection"]||t.multiplex===!1||o;let l;return s?l=new gm(r,t):(El[i]||(El[i]=new gm(r,t)),l=El[i]),n.query&&!t.query&&(t.query=n.queryKey),l.socket(n.path,t)}Object.assign(ed,{Manager:gm,Socket:$x,io:ed,connect:ed});function jL(e,t,n=[]){const[r,i]=y.useState(null),[a,o]=y.useState("disconnected"),s=m=>{o(m)},l=()=>{r&&(r.disconnect(),i(null),s("disconnected"))},u=y.useCallback(()=>s("connected"),[s]),c=y.useCallback(()=>s("disconnected"),[s]),d=y.useCallback(()=>s("error"),[s]),f=y.useCallback(()=>s("reconnected"),[s]),p=y.useCallback(()=>s("reconnecting"),[s]),g=y.useCallback(()=>s("error"),[s]),w=y.useCallback(()=>s("error"),[s]);y.useEffect(()=>{if(!e)return;const m=ed(e,t);return i(m),()=>{m.disconnect(),i(null)}},[e]);const x=(m,v,b=[])=>{y.useEffect(()=>{if(r)return r.on(m,v),()=>{r.off(m,v)}},[r,m,v,...b])};return y.useEffect(()=>{if(r)return r.on("connect",u),r.on("disconnect",c),r.on("connect_error",d),r.on("reconnect",f),r.on("reconnecting",p),r.on("reconnect_error",g),r.on("reconnect_failed",w),()=>{r.off("connect",u),r.off("disconnect",c),r.off("connect_error",d),r.off("reconnect",f),r.off("reconnecting",p),r.off("reconnect_error",g),r.off("reconnect_failed",w)}},[u,d,c,f,g,w,p,r]),{socket:r,socketState:a,disconnect:l,useListen:x}}function zL(e,t){switch(e){case"connected":return t("connected","🟢");case"connecting":return t("connecting","🟡");case"reconnecting":return t("reconnecting","🟡");case"reconnected":return t("reconnected","🟢");case"disconnecting":return t("disconnecting","🔴");case"disconnected":return t("disconnected","🔴");case"error":return t("error","❌")}}function Wx(e){var n,r,i;const t=[];for(let a=0;a<e.length;a++){const o=e[a];if(o.from_user===!0)o.message&&o.message.length>0&&t.push({type:"FROM_USER",content:o.message,id:o.publicId||Yr(),deliveredAt:o.created_at||"",attachments:o.attachments});else switch(o.type){case"message":t.push({type:"FROM_BOT",component:"TEXT",data:{message:o.message??""},id:o.publicId||Yr(),timestamp:o.created_at||"",original:o,attachments:o.attachments,agent:{id:((n=o.agent_id)==null?void 0:n.toString())??null,is_ai:!0,profile_picture:o.agent_avatar||"",name:o.agent_name||""}});break;case"agent_message":t.push({type:"FROM_BOT",component:"TEXT",data:{message:o.message??""},id:o.publicId||Yr(),timestamp:o.created_at||"",original:o,attachments:o.attachments,agent:{id:((r=o.agent_id)==null?void 0:r.toString())??null,is_ai:!1,name:o.agent_name||"",profile_picture:o.agent_avatar||""}});break;default:t.push({type:"FROM_BOT",component:"CHAT_EVENT",data:{event:o.type,message:o.message??""},id:o.publicId||Yr(),original:o,attachments:o.attachments,timestamp:o.created_at||"",agent:{is_ai:!0,id:((i=o.agent_id)==null?void 0:i.toString())??null,name:o.agent_name||"",profile_picture:o.agent_avatar||""}})}}return t}var UL="Expected a function",Yx="__lodash_hash_undefined__",qx=1/0,HL=9007199254740991,VL="[object Function]",$L="[object GeneratorFunction]",WL="[object Symbol]",YL=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,qL=/^\w*$/,GL=/^\./,KL=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,XL=/[\\^$.*+?()[\]{}|]/g,QL=/\\(\\)?/g,ZL=/^\[object .+?Constructor\]$/,JL=/^(?:0|[1-9]\d*)$/,eM=typeof Zn=="object"&&Zn&&Zn.Object===Object&&Zn,tM=typeof self=="object"&&self&&self.Object===Object&&self,wm=eM||tM||Function("return this")();function nM(e,t){return e==null?void 0:e[t]}function rM(e){var t=!1;if(e!=null&&typeof e.toString!="function")try{t=!!(e+"")}catch{}return t}var iM=Array.prototype,aM=Function.prototype,Gx=Object.prototype,ym=wm["__core-js_shared__"],Kx=function(){var e=/[^.]+$/.exec(ym&&ym.keys&&ym.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),Xx=aM.toString,td=Gx.hasOwnProperty,Qx=Gx.toString,oM=RegExp("^"+Xx.call(td).replace(XL,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Zx=wm.Symbol,sM=iM.splice,lM=tE(wm,"Map"),Tl=tE(Object,"create"),Jx=Zx?Zx.prototype:void 0,eE=Jx?Jx.toString:void 0;function Ia(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function uM(){this.__data__=Tl?Tl(null):{}}function cM(e){return this.has(e)&&delete this.__data__[e]}function dM(e){var t=this.__data__;if(Tl){var n=t[e];return n===Yx?void 0:n}return td.call(t,e)?t[e]:void 0}function fM(e){var t=this.__data__;return Tl?t[e]!==void 0:td.call(t,e)}function pM(e,t){var n=this.__data__;return n[e]=Tl&&t===void 0?Yx:t,this}Ia.prototype.clear=uM,Ia.prototype.delete=cM,Ia.prototype.get=dM,Ia.prototype.has=fM,Ia.prototype.set=pM;function Co(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function hM(){this.__data__=[]}function mM(e){var t=this.__data__,n=nd(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():sM.call(t,n,1),!0}function gM(e){var t=this.__data__,n=nd(t,e);return n<0?void 0:t[n][1]}function wM(e){return nd(this.__data__,e)>-1}function yM(e,t){var n=this.__data__,r=nd(n,e);return r<0?n.push([e,t]):n[r][1]=t,this}Co.prototype.clear=hM,Co.prototype.delete=mM,Co.prototype.get=gM,Co.prototype.has=wM,Co.prototype.set=yM;function Da(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function vM(){this.__data__={hash:new Ia,map:new(lM||Co),string:new Ia}}function bM(e){return rd(this,e).delete(e)}function xM(e){return rd(this,e).get(e)}function EM(e){return rd(this,e).has(e)}function TM(e,t){return rd(this,e).set(e,t),this}Da.prototype.clear=vM,Da.prototype.delete=bM,Da.prototype.get=xM,Da.prototype.has=EM,Da.prototype.set=TM;function _M(e,t,n){var r=e[t];(!(td.call(e,t)&&nE(r,n))||n===void 0&&!(t in e))&&(e[t]=n)}function nd(e,t){for(var n=e.length;n--;)if(nE(e[n][0],t))return n;return-1}function SM(e){if(!id(e)||PM(e))return!1;var t=MM(e)||rM(e)?oM:ZL;return t.test(LM(e))}function kM(e,t,n,r){if(!id(e))return e;t=NM(t,e)?[t]:AM(t);for(var i=-1,a=t.length,o=a-1,s=e;s!=null&&++i<a;){var l=DM(t[i]),u=n;if(i!=o){var c=s[l];u=void 0,u===void 0&&(u=id(c)?c:RM(t[i+1])?[]:{})}_M(s,l,u),s=s[l]}return e}function CM(e){if(typeof e=="string")return e;if(bm(e))return eE?eE.call(e):"";var t=e+"";return t=="0"&&1/e==-qx?"-0":t}function AM(e){return rE(e)?e:IM(e)}function rd(e,t){var n=e.__data__;return OM(t)?n[typeof t=="string"?"string":"hash"]:n.map}function tE(e,t){var n=nM(e,t);return SM(n)?n:void 0}function RM(e,t){return t=t??HL,!!t&&(typeof e=="number"||JL.test(e))&&e>-1&&e%1==0&&e<t}function NM(e,t){if(rE(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||bm(e)?!0:qL.test(e)||!YL.test(e)||t!=null&&e in Object(t)}function OM(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function PM(e){return!!Kx&&Kx in e}var IM=vm(function(e){e=BM(e);var t=[];return GL.test(e)&&t.push(""),e.replace(KL,function(n,r,i,a){t.push(i?a.replace(QL,"$1"):r||n)}),t});function DM(e){if(typeof e=="string"||bm(e))return e;var t=e+"";return t=="0"&&1/e==-qx?"-0":t}function LM(e){if(e!=null){try{return Xx.call(e)}catch{}try{return e+""}catch{}}return""}function vm(e,t){if(typeof e!="function"||t&&typeof t!="function")throw new TypeError(UL);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var o=e.apply(this,r);return n.cache=a.set(i,o),o};return n.cache=new(vm.Cache||Da),n}vm.Cache=Da;function nE(e,t){return e===t||e!==e&&t!==t}var rE=Array.isArray;function MM(e){var t=id(e)?Qx.call(e):"";return t==VL||t==$L}function id(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function FM(e){return!!e&&typeof e=="object"}function bm(e){return typeof e=="symbol"||FM(e)&&Qx.call(e)==WL}function BM(e){return e==null?"":CM(e)}function jM(e,t,n){return e==null?e:kM(e,t,n)}var zM=jM;const UM=gc(zM);function HM(e){const t=y.useRef(null);return y.useEffect(()=>{if(!t.current){const n=new Audio(e.src);n.volume=e.volume,n.loop=!1,n.preload="auto",t.current=n}return()=>{var n,r;(n=t.current)==null||n.pause(),(r=t.current)==null||r.remove()}},[e]),{play:()=>{var n;e.soundEnabled&&((n=t.current)==null||n.play())},stop:()=>{var n;(n=t.current)==null||n.pause()}}}function VM(){const{soundEffectFiles:e,widgetSettings:t,defaultSettings:n}=Bt(),r=(t==null?void 0:t.useSoundEffects)??n.useSoundEffects;return{messageArrivedSound:HM({src:e.messageArrived,soundEnabled:r,volume:.5})}}function $M(e,t){return B5(e,n=>{const r=()=>{n.lastUpdated=Date.now()};switch(t.type){case"ADD_RESPONSE_MESSAGE":{n.messages.push(t.payload),r();break}case"APPEND_USER_MESSAGE":{n.messages.push(t.payload),r();break}case"RESET":{n.messages=[],n.lastUpdated=null,n.keyboard=null;break}case"PREPEND_HISTORY":{const i=t.payload.map(a=>a.id);n.messages=n.messages.filter(a=>!i.includes(a.id)),n.messages=[...t.payload,...n.messages],r();break}case"SET_KEYBOARD":{n.keyboard=t.payload;break}case"SET_DELIVERED_AT":{const i=n.messages.find(a=>{var o;if(a.type==="FROM_USER"&&a.id===((o=t.payload)==null?void 0:o.clientMessageId))return!0});(i==null?void 0:i.type)==="FROM_USER"&&UM(i,"deliveredAt",t.payload.deliveredAt);break}case"SET_MESSAGES":{n.messages=t.payload;break}case"APPEND_MESSAGES":{const i=t.payload.filter(a=>!n.messages.some(o=>o.id===a.id));n.messages.push(...i);break}}})}function WM({persist:e,sessionKey:t=(n,{external_id:r})=>`[OPEN_SESSION_${n}]_${r||"session"}`}){const{botToken:n,http:r,user:i}=Bt(),[a,o,s]=yh(t(n,i),void 0,e?"local":"memory"),l=a?{...a,isSessionClosed:a.status!==Wc.OPEN,isAssignedToAi:a.assignee_id===555,isAssignedToHuman:a.assignee_id!==555,isPendingHuman:a.assignee_id===555&&a.ai_closure_type===Yc.handed_off}:null,[u,c]=Js(async f=>{let p=await r.apis.fetchSession(f);return p.data&&o(p.data),p.data},[r,o]);function d(){o(null),s()}return{session:l,refreshSession:c,refreshSessionState:u,deleteSession:d,setSession:o}}function YM(){const[e,t]=y.useState({state:"idle"});return[e,t]}function qM({onSessionDestroy:e}){const[t,n]=y.useReducer($M,{lastUpdated:null,messages:[],keyboard:null}),r=Qs(),{botToken:i,http:a,socketUrl:o,widgetSettings:s,defaultSettings:l,language:u,...c}=Bt(),{messageArrivedSound:d}=VM(),[f,p]=Js(async J=>{if(m)try{const{data:de}=await a.apis.fetchHistory(J);if(!de)return[];if(Array.isArray(de))return Wx(de??[])}catch(de){return console.error(de),[]}return[]},[c.bot]),g=(s==null?void 0:s.persistSession)||l.persistSession,{refreshSession:w,refreshSessionState:x,session:m,deleteSession:v,setSession:b}=WM({persist:g}),[T,_]=YM();function S(J){const de=(m==null?void 0:m.isAssignedToHuman)||(m==null?void 0:m.isPendingHuman)||(m==null?void 0:m.isSessionClosed)||!(m!=null&&m.isAssignedToAi);_(de?{state:"idle"}:J)}const{socket:R,socketState:P,useListen:B}=jL(o,{transports:["websocket"],closeOnBeforeunload:!0,autoConnect:!0,query:{botToken:i,sessionId:m==null?void 0:m.id,client:"widget",clientVersion:jv.version,language:u}});y.useEffect(()=>{async function J(){if(!m)return;const de=await w(m==null?void 0:m.id);if(de){const Se=await p(de.id);Se&&n({type:"PREPEND_HISTORY",payload:Se})}}J()},[]),y.useEffect(()=>{let J;if(m&&R){const Se={sessionId:m.id,client:"widget",botToken:i,user:c.user,timestamp:Date.now()};async function Ce(){R==null||R.emit("heartbeat",Se)}Ce(),J=setInterval(()=>{Ce()},50*1e3)}return()=>{clearInterval(J)}},[R,m,i,c.user]),B("heartbeat:ack",J=>{},[m]);const[N,H]=j5(()=>zL(P,r.get),1e3),U=()=>{m&&R&&R.emit("join_session",{session_id:m.id})},K=()=>{m&&R&&R.emit("join_session",{session_id:m.id})};y.useEffect(()=>{if(R)return R.on("connect",U),R.on("reconnect",K),()=>{R.off("connect",U),R.off("reconnect",K)}},[U,R,K]);function X(J){R==null||R.emit("join_session",{session_id:J})}function ee(){R==null||R.emit("leave_session",{session_id:m==null?void 0:m.id}),v(),n({type:"RESET"}),e==null||e(),S({state:"idle"})}function oe(){ee(),a.apis.createSession(i).then(({data:J})=>{b(J),X(J.id)})}const ne=J=>{WD({_message:J,_socket:R,_config:{bot:c.bot},onSessionUpdate(de,Se){b(de.value.session)},onBotMessage(de,Se){S({state:"idle"}),n({type:"ADD_RESPONSE_MESSAGE",payload:de});try{d.play()}catch(Ce){console.error(Ce)}},onChatEvent(){m&&w(m.id)},onUi(de,Se){de.type==="FROM_BOT"&&m&&w(m.id),S({state:"idle"}),n({type:"ADD_RESPONSE_MESSAGE",payload:de})},onForm(de,Se){S({state:"idle"}),n({type:"ADD_RESPONSE_MESSAGE",payload:de})},onOptions(de,Se){n({type:"SET_KEYBOARD",payload:{options:de.value.options}}),S({state:"idle"})}})},L=y.useCallback(J=>{H(J)},[H]);y.useEffect(()=>{var Se;if(!m)return;const J=(Se=t.messages.at(-1))==null?void 0:Se.timestamp;if(!J)return;const de=setInterval(()=>{a.apis.getHistoryPooling({sessionId:m.id,lastMessageTimestamp:J}).then(Ce=>{Ce.data&&n({type:"APPEND_MESSAGES",payload:Wx(Ce.data)})})},20*1e3);return()=>{clearInterval(de)}},[m,t.messages]);const F=y.useCallback(J=>{n({type:"APPEND_USER_MESSAGE",payload:{user:J==null?void 0:J.user,type:"FROM_USER",deliveredAt:null,content:J.content,id:J.id??Yr(10),attachments:[]}})},[]),C=y.useCallback(J=>{n({type:"SET_DELIVERED_AT",payload:{clientMessageId:J.id,deliveredAt:new Date().toISOString()}})},[]);B("structured_message",ne),B("ack:chat_message:delivered",C),B("info",L),B("user_message_broadcast",F);const te=t.messages.length===0,[fe,I]=Js(async({content:J,user:de,...Se})=>{let Ce=m;if(S({state:"loading"}),!m&&te)try{const{data:Re}=await a.apis.createSession(i);if(Re)b(Re),X(Re.id),Ce={...Re,isSessionClosed:Re.status!==Wc.OPEN,isAssignedToAi:Re.assignee_id===555,isAssignedToHuman:!1,isPendingHuman:!1};else throw new Error("Failed to create session")}catch(Re){return console.error("Error creating session:",Re),null}if(Ce&&R){const Re=Yr(),{headers:vt,pathParams:xe,queryParams:we}=c,Ve={id:Re,bot_token:i,content:J.text,attachments:Se.attachments,session_id:Ce.id,headers:vt,pathParams:xe,query_params:we,queryParams:we,user:{...c.user,...de},language:u,...Se};try{return n({type:"APPEND_USER_MESSAGE",payload:{type:"FROM_USER",id:Re,content:J.text,user:Ve.user,deliveredAt:null,attachments:Se.attachments}}),t.keyboard&&n({type:"SET_KEYBOARD",payload:null}),R.emit("send_chat",Ve),Ve}catch(je){return console.error("Error sending message:",je),null}}return null},[S,m,R,c.user,c,i,u]),ke=y.useCallback(J=>{I({content:{text:J}}),n({type:"SET_KEYBOARD",payload:null})},[n,I,R]),Ye=y.useMemo(()=>m!=null&&m.isSessionClosed?{canSend:!1,reason:"closedSession"}:{canSend:!0},[m]);return{version:jv.version,state:t,session:m,unstable__canSend:Ye,noMessages:te,fetchHistoryState:f,refreshSessionState:x,recreateSession:oe,clearSession:ee,sendMessage:I,info:N,handleKeyboard:ke,hookState:T}}const[Ao,GM]=Xs();function KM({children:e}){const{settings:t}=Bt(),n=qM({defaultHookSettings:{persistSession:(t==null?void 0:t.persistSession)??!0,useSoundEffects:(t==null?void 0:t.useSoundEffects)??!1}});return E.jsx(GM,{value:n,children:e})}function XM(){const{http:e,botToken:t,user:n,collectUserData:r}=Bt(),[i,a]=yh(`${t}:contact:${n.external_id}`,null,"local"),[o,s]=Js(async u=>{var c;try{if(!u||!u.email)return null;const d=await e.apis.dumpContact(u);return(c=d==null?void 0:d.data)!=null&&c.id&&a(d.data),d==null?void 0:d.data}catch(d){console.error(d)}return null},[e.apis]);y.useEffect(()=>{n&&t&&s(n)},[n,t]);const l=y.useMemo(()=>!(i!=null&&i.id)&&r?{should:!0,reason:"No contact id and collectUserData is true"}:{should:!1},[i]);return{creatingContactState:o,createContactAsync:s,contact:i,shouldCollectData:l}}const[xm,QM]=Xs();function ZM({children:e}){const t=XM();return E.jsx(QM,{value:t,children:e})}function JM({children:e,options:t}){return E.jsx(g5,{data:t,children:E.jsx(ZM,{children:E.jsx(kb,{children:E.jsx(KM,{children:e})})})})}var iE={exports:{}},aE={};/**
23
+ * @license React
24
+ * use-sync-external-store-shim.production.min.js
25
+ *
26
+ * Copyright (c) Facebook, Inc. and its affiliates.
27
+ *
28
+ * This source code is licensed under the MIT license found in the
29
+ * LICENSE file in the root directory of this source tree.
30
+ */var Ro=y;function e8(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var t8=typeof Object.is=="function"?Object.is:e8,n8=Ro.useState,r8=Ro.useEffect,i8=Ro.useLayoutEffect,a8=Ro.useDebugValue;function o8(e,t){var n=t(),r=n8({inst:{value:n,getSnapshot:t}}),i=r[0].inst,a=r[1];return i8(function(){i.value=n,i.getSnapshot=t,Em(i)&&a({inst:i})},[e,n,t]),r8(function(){return Em(i)&&a({inst:i}),e(function(){Em(i)&&a({inst:i})})},[e]),a8(n),n}function Em(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!t8(e,n)}catch{return!0}}function s8(e,t){return t()}var l8=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?s8:o8;aE.useSyncExternalStore=Ro.useSyncExternalStore!==void 0?Ro.useSyncExternalStore:l8,iE.exports=aE;var u8=iE.exports;const Ii=()=>{},un=Ii(),Tm=Object,Ue=e=>e===un,Cr=e=>typeof e=="function",Di=(e,t)=>({...e,...t}),c8=e=>Cr(e.then),ad=new WeakMap;let d8=0;const _l=e=>{const t=typeof e,n=e&&e.constructor,r=n==Date;let i,a;if(Tm(e)===e&&!r&&n!=RegExp){if(i=ad.get(e),i)return i;if(i=++d8+"~",ad.set(e,i),n==Array){for(i="@",a=0;a<e.length;a++)i+=_l(e[a])+",";ad.set(e,i)}if(n==Tm){i="#";const o=Tm.keys(e).sort();for(;!Ue(a=o.pop());)Ue(e[a])||(i+=a+":"+_l(e[a])+",");ad.set(e,i)}}else i=r?e.toJSON():t=="symbol"?e.toString():t=="string"?JSON.stringify(e):""+e;return i},Qr=new WeakMap,_m={},od={},Sm="undefined",sd=typeof window!=Sm,km=typeof document!=Sm,f8=()=>sd&&typeof window.requestAnimationFrame!=Sm,oE=(e,t)=>{const n=Qr.get(e);return[()=>!Ue(t)&&e.get(t)||_m,r=>{if(!Ue(t)){const i=e.get(t);t in od||(od[t]=i),n[5](t,Di(i,r),i||_m)}},n[6],()=>!Ue(t)&&t in od?od[t]:!Ue(t)&&e.get(t)||_m]};let Cm=!0;const p8=()=>Cm,[Am,Rm]=sd&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[Ii,Ii],h8=()=>{const e=km&&document.visibilityState;return Ue(e)||e!=="hidden"},m8=e=>(km&&document.addEventListener("visibilitychange",e),Am("focus",e),()=>{km&&document.removeEventListener("visibilitychange",e),Rm("focus",e)}),g8=e=>{const t=()=>{Cm=!0,e()},n=()=>{Cm=!1};return Am("online",t),Am("offline",n),()=>{Rm("online",t),Rm("offline",n)}},w8={isOnline:p8,isVisible:h8},y8={initFocus:m8,initReconnect:g8},sE=!_t.useId,Sl=!sd||"Deno"in window,v8=e=>f8()?window.requestAnimationFrame(e):setTimeout(e,1),Nm=Sl?y.useEffect:y.useLayoutEffect,Om=typeof navigator<"u"&&navigator.connection,lE=!Sl&&Om&&(["slow-2g","2g"].includes(Om.effectiveType)||Om.saveData),Pm=e=>{if(Cr(e))try{e=e()}catch{e=""}const t=e;return e=typeof e=="string"?e:(Array.isArray(e)?e.length:e)?_l(e):"",[e,t]};let b8=0;const Im=()=>++b8,uE=0,cE=1,dE=2;var kl={__proto__:null,ERROR_REVALIDATE_EVENT:3,FOCUS_EVENT:uE,MUTATE_EVENT:dE,RECONNECT_EVENT:cE};async function fE(...e){const[t,n,r,i]=e,a=Di({populateCache:!0,throwOnError:!0},typeof i=="boolean"?{revalidate:i}:i||{});let o=a.populateCache;const s=a.rollbackOnError;let l=a.optimisticData;const u=f=>typeof s=="function"?s(f):s!==!1,c=a.throwOnError;if(Cr(n)){const f=n,p=[],g=t.keys();for(const w of g)!/^\$(inf|sub)\$/.test(w)&&f(t.get(w)._k)&&p.push(w);return Promise.all(p.map(d))}return d(n);async function d(f){const[p]=Pm(f);if(!p)return;const[g,w]=oE(t,p),[x,m,v,b]=Qr.get(t),T=()=>{const K=x[p];return(Cr(a.revalidate)?a.revalidate(g().data,f):a.revalidate!==!1)&&(delete v[p],delete b[p],K&&K[0])?K[0](dE).then(()=>g().data):g().data};if(e.length<3)return T();let _=r,S;const R=Im();m[p]=[R,0];const P=!Ue(l),B=g(),N=B.data,H=B._c,U=Ue(H)?N:H;if(P&&(l=Cr(l)?l(U,N):l,w({data:l,_c:U})),Cr(_))try{_=_(U)}catch(K){S=K}if(_&&c8(_))if(_=await _.catch(K=>{S=K}),R!==m[p][0]){if(S)throw S;return _}else S&&P&&u(S)&&(o=!0,w({data:U,_c:un}));if(o&&!S)if(Cr(o)){const K=o(_,U);w({data:K,error:un,_c:un})}else w({data:_,error:un,_c:un});if(m[p][1]=Im(),Promise.resolve(T()).then(()=>{w({_c:un})}),S){if(c)throw S;return}return _}}const pE=(e,t)=>{for(const n in e)e[n][0]&&e[n][0](t)},x8=(e,t)=>{if(!Qr.has(e)){const n=Di(y8,t),r={},i=fE.bind(un,e);let a=Ii;const o={},s=(c,d)=>{const f=o[c]||[];return o[c]=f,f.push(d),()=>f.splice(f.indexOf(d),1)},l=(c,d,f)=>{e.set(c,d);const p=o[c];if(p)for(const g of p)g(d,f)},u=()=>{if(!Qr.has(e)&&(Qr.set(e,[r,{},{},{},i,l,s]),!Sl)){const c=n.initFocus(setTimeout.bind(un,pE.bind(un,r,uE))),d=n.initReconnect(setTimeout.bind(un,pE.bind(un,r,cE)));a=()=>{c&&c(),d&&d(),Qr.delete(e)}}};return u(),[e,i,u,a]}return[e,Qr.get(e)[4]]},E8=(e,t,n,r,i)=>{const a=n.errorRetryCount,o=i.retryCount,s=~~((Math.random()+.5)*(1<<(o<8?o:8)))*n.errorRetryInterval;!Ue(a)&&o>a||setTimeout(r,s,i)},T8=(e,t)=>_l(e)==_l(t),[hE,_8]=x8(new Map),S8=Di({onLoadingSlow:Ii,onSuccess:Ii,onError:Ii,onErrorRetry:E8,onDiscarded:Ii,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:lE?1e4:5e3,focusThrottleInterval:5*1e3,dedupingInterval:2*1e3,loadingTimeout:lE?5e3:3e3,compare:T8,isPaused:()=>!1,cache:hE,mutate:_8,fallback:{}},w8),k8=(e,t)=>{const n=Di(e,t);if(t){const{use:r,fallback:i}=e,{use:a,fallback:o}=t;r&&a&&(n.use=r.concat(a)),i&&o&&(n.fallback=Di(i,o))}return n},C8=y.createContext({}),A8="$inf$",mE=sd&&window.__SWR_DEVTOOLS_USE__,R8=mE?window.__SWR_DEVTOOLS_USE__:[],N8=()=>{mE&&(window.__SWR_DEVTOOLS_REACT__=_t)},O8=e=>Cr(e[1])?[e[0],e[1],e[2]||{}]:[e[0],null,(e[1]===null?e[2]:e[1])||{}],P8=()=>Di(S8,y.useContext(C8)),I8=e=>(t,n,r)=>e(t,n&&((...a)=>{const[o]=Pm(t),[,,,s]=Qr.get(hE);if(o.startsWith(A8))return n(...a);const l=s[o];return Ue(l)?n(...a):(delete s[o],l)}),r),D8=R8.concat(I8),L8=e=>function(...n){const r=P8(),[i,a,o]=O8(n),s=k8(r,o);let l=e;const{use:u}=s,c=(u||[]).concat(D8);for(let d=c.length;d--;)l=c[d](l);return l(i,a||s.fetcher||null,s)},M8=(e,t,n)=>{const r=t[e]||(t[e]=[]);return r.push(n),()=>{const i=r.indexOf(n);i>=0&&(r[i]=r[r.length-1],r.pop())}};N8();const gE=_t.use||(e=>{if(e.status==="pending")throw e;if(e.status==="fulfilled")return e.value;throw e.status==="rejected"?e.reason:(e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e)}),Dm={dedupe:!0},F8=L8((e,t,n)=>{const{cache:r,compare:i,suspense:a,fallbackData:o,revalidateOnMount:s,revalidateIfStale:l,refreshInterval:u,refreshWhenHidden:c,refreshWhenOffline:d,keepPreviousData:f}=n,[p,g,w,x]=Qr.get(r),[m,v]=Pm(e),b=y.useRef(!1),T=y.useRef(!1),_=y.useRef(m),S=y.useRef(t),R=y.useRef(n),P=()=>R.current,B=()=>P().isVisible()&&P().isOnline(),[N,H,U,K]=oE(r,m),X=y.useRef({}).current,ee=Ue(o)?n.fallback[m]:o,oe=(xe,we)=>{for(const Ve in X){const je=Ve;if(je==="data"){if(!i(xe[je],we[je])&&(!Ue(xe[je])||!i(Ye,we[je])))return!1}else if(we[je]!==xe[je])return!1}return!0},ne=y.useMemo(()=>{const xe=!m||!t?!1:Ue(s)?P().isPaused()||a?!1:Ue(l)?!0:l:s,we=ze=>{const Mt=Di(ze);return delete Mt._k,xe?{isValidating:!0,isLoading:!0,...Mt}:Mt},Ve=N(),je=K(),bt=we(Ve),xt=Ve===je?bt:we(je);let Ke=bt;return[()=>{const ze=we(N());return oe(ze,Ke)?(Ke.data=ze.data,Ke.isLoading=ze.isLoading,Ke.isValidating=ze.isValidating,Ke.error=ze.error,Ke):(Ke=ze,ze)},()=>xt]},[r,m]),L=u8.useSyncExternalStore(y.useCallback(xe=>U(m,(we,Ve)=>{oe(Ve,we)||xe()}),[r,m]),ne[0],ne[1]),F=!b.current,C=p[m]&&p[m].length>0,te=L.data,fe=Ue(te)?ee:te,I=L.error,ke=y.useRef(fe),Ye=f?Ue(te)?ke.current:te:fe,J=C&&!Ue(I)?!1:F&&!Ue(s)?s:P().isPaused()?!1:a?Ue(fe)?!1:l:Ue(fe)||l,de=!!(m&&t&&F&&J),Se=Ue(L.isValidating)?de:L.isValidating,Ce=Ue(L.isLoading)?de:L.isLoading,Re=y.useCallback(async xe=>{const we=S.current;if(!m||!we||T.current||P().isPaused())return!1;let Ve,je,bt=!0;const xt=xe||{},Ke=!w[m]||!xt.dedupe,ze=()=>sE?!T.current&&m===_.current&&b.current:m===_.current,Mt={isValidating:!1,isLoading:!1},Hs=()=>{H(Mt)},Vs=()=>{const Z=w[m];Z&&Z[1]===je&&delete w[m]},$s={isValidating:!0};Ue(N().data)&&($s.isLoading=!0);try{if(Ke&&(H($s),n.loadingTimeout&&Ue(N().data)&&setTimeout(()=>{bt&&ze()&&P().onLoadingSlow(m,n)},n.loadingTimeout),w[m]=[we(v),Im()]),[Ve,je]=w[m],Ve=await Ve,Ke&&setTimeout(Vs,n.dedupingInterval),!w[m]||w[m][1]!==je)return Ke&&ze()&&P().onDiscarded(m),!1;Mt.error=un;const Z=g[m];if(!Ue(Z)&&(je<=Z[0]||je<=Z[1]||Z[1]===0))return Hs(),Ke&&ze()&&P().onDiscarded(m),!1;const le=N().data;Mt.data=i(le,Ve)?le:Ve,Ke&&ze()&&P().onSuccess(Ve,m,n)}catch(Z){Vs();const le=P(),{shouldRetryOnError:M}=le;le.isPaused()||(Mt.error=Z,Ke&&ze()&&(le.onError(Z,m,le),(M===!0||Cr(M)&&M(Z))&&(!P().revalidateOnFocus||!P().revalidateOnReconnect||B())&&le.onErrorRetry(Z,m,le,$=>{const se=p[m];se&&se[0]&&se[0](kl.ERROR_REVALIDATE_EVENT,$)},{retryCount:(xt.retryCount||0)+1,dedupe:!0})))}return bt=!1,Hs(),!0},[m,r]),vt=y.useCallback((...xe)=>fE(r,_.current,...xe),[]);if(Nm(()=>{S.current=t,R.current=n,Ue(te)||(ke.current=te)}),Nm(()=>{if(!m)return;const xe=Re.bind(un,Dm);let we=0;const je=M8(m,p,(bt,xt={})=>{if(bt==kl.FOCUS_EVENT){const Ke=Date.now();P().revalidateOnFocus&&Ke>we&&B()&&(we=Ke+P().focusThrottleInterval,xe())}else if(bt==kl.RECONNECT_EVENT)P().revalidateOnReconnect&&B()&&xe();else{if(bt==kl.MUTATE_EVENT)return Re();if(bt==kl.ERROR_REVALIDATE_EVENT)return Re(xt)}});return T.current=!1,_.current=m,b.current=!0,H({_k:v}),J&&(Ue(fe)||Sl?xe():v8(xe)),()=>{T.current=!0,je()}},[m]),Nm(()=>{let xe;function we(){const je=Cr(u)?u(N().data):u;je&&xe!==-1&&(xe=setTimeout(Ve,je))}function Ve(){!N().error&&(c||P().isVisible())&&(d||P().isOnline())?Re(Dm).then(we):we()}return we(),()=>{xe&&(clearTimeout(xe),xe=-1)}},[u,c,d,m]),y.useDebugValue(Ye),a&&Ue(fe)&&m){if(!sE&&Sl)throw new Error("Fallback data is required when using suspense in SSR.");S.current=t,R.current=n,T.current=!1;const xe=x[m];if(!Ue(xe)){const we=vt(xe);gE(we)}if(Ue(I)){const we=Re(Dm);Ue(Ye)||(we.status="fulfilled",we.value=!0),gE(we)}else throw I}return{mutate:vt,get data(){return X.data=!0,Ye},get error(){return X.error=!0,I},get isValidating(){return X.isValidating=!0,Se},get isLoading(){return X.isLoading=!0,Ce}}});function Lm(){const{apiUrl:e,botToken:t}=Bt(),n=Sb({apiUrl:e,botToken:t});return F8(n.options,n.apis.fetchPreludeData)}function Jt(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e==null||e(i),n===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function B8(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function wE(...e){return t=>e.forEach(n=>B8(n,t))}function ar(...e){return y.useCallback(wE(...e),e)}function Zr(e,t=[]){let n=[];function r(a,o){const s=y.createContext(o),l=n.length;n=[...n,o];const u=d=>{var m;const{scope:f,children:p,...g}=d,w=((m=f==null?void 0:f[e])==null?void 0:m[l])||s,x=y.useMemo(()=>g,Object.values(g));return E.jsx(w.Provider,{value:x,children:p})};u.displayName=a+"Provider";function c(d,f){var w;const p=((w=f==null?void 0:f[e])==null?void 0:w[l])||s,g=y.useContext(p);if(g)return g;if(o!==void 0)return o;throw new Error(`\`${d}\` must be used within \`${a}\``)}return[u,c]}const i=()=>{const a=n.map(o=>y.createContext(o));return function(s){const l=(s==null?void 0:s[e])||a;return y.useMemo(()=>({[`__scope${e}`]:{...s,[e]:l}}),[s,l])}};return i.scopeName=e,[r,j8(i,...t)]}function j8(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(a){const o=r.reduce((s,{useScope:l,scopeName:u})=>{const d=l(a)[`__scope${u}`];return{...s,...d}},{});return y.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}var yE={exports:{}},_n={},vE={exports:{}},bE={};/**
31
+ * @license React
32
+ * scheduler.production.min.js
33
+ *
34
+ * Copyright (c) Facebook, Inc. and its affiliates.
35
+ *
36
+ * This source code is licensed under the MIT license found in the
37
+ * LICENSE file in the root directory of this source tree.
38
+ */(function(e){function t(L,F){var C=L.length;L.push(F);e:for(;0<C;){var te=C-1>>>1,fe=L[te];if(0<i(fe,F))L[te]=F,L[C]=fe,C=te;else break e}}function n(L){return L.length===0?null:L[0]}function r(L){if(L.length===0)return null;var F=L[0],C=L.pop();if(C!==F){L[0]=C;e:for(var te=0,fe=L.length,I=fe>>>1;te<I;){var ke=2*(te+1)-1,Ye=L[ke],J=ke+1,de=L[J];if(0>i(Ye,C))J<fe&&0>i(de,Ye)?(L[te]=de,L[J]=C,te=J):(L[te]=Ye,L[ke]=C,te=ke);else if(J<fe&&0>i(de,C))L[te]=de,L[J]=C,te=J;else break e}}return F}function i(L,F){var C=L.sortIndex-F.sortIndex;return C!==0?C:L.id-F.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var l=[],u=[],c=1,d=null,f=3,p=!1,g=!1,w=!1,x=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,v=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function b(L){for(var F=n(u);F!==null;){if(F.callback===null)r(u);else if(F.startTime<=L)r(u),F.sortIndex=F.expirationTime,t(l,F);else break;F=n(u)}}function T(L){if(w=!1,b(L),!g)if(n(l)!==null)g=!0,oe(_);else{var F=n(u);F!==null&&ne(T,F.startTime-L)}}function _(L,F){g=!1,w&&(w=!1,m(P),P=-1),p=!0;var C=f;try{for(b(F),d=n(l);d!==null&&(!(d.expirationTime>F)||L&&!H());){var te=d.callback;if(typeof te=="function"){d.callback=null,f=d.priorityLevel;var fe=te(d.expirationTime<=F);F=e.unstable_now(),typeof fe=="function"?d.callback=fe:d===n(l)&&r(l),b(F)}else r(l);d=n(l)}if(d!==null)var I=!0;else{var ke=n(u);ke!==null&&ne(T,ke.startTime-F),I=!1}return I}finally{d=null,f=C,p=!1}}var S=!1,R=null,P=-1,B=5,N=-1;function H(){return!(e.unstable_now()-N<B)}function U(){if(R!==null){var L=e.unstable_now();N=L;var F=!0;try{F=R(!0,L)}finally{F?K():(S=!1,R=null)}}else S=!1}var K;if(typeof v=="function")K=function(){v(U)};else if(typeof MessageChannel<"u"){var X=new MessageChannel,ee=X.port2;X.port1.onmessage=U,K=function(){ee.postMessage(null)}}else K=function(){x(U,0)};function oe(L){R=L,S||(S=!0,K())}function ne(L,F){P=x(function(){L(e.unstable_now())},F)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(L){L.callback=null},e.unstable_continueExecution=function(){g||p||(g=!0,oe(_))},e.unstable_forceFrameRate=function(L){0>L||125<L?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):B=0<L?Math.floor(1e3/L):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_getFirstCallbackNode=function(){return n(l)},e.unstable_next=function(L){switch(f){case 1:case 2:case 3:var F=3;break;default:F=f}var C=f;f=F;try{return L()}finally{f=C}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(L,F){switch(L){case 1:case 2:case 3:case 4:case 5:break;default:L=3}var C=f;f=L;try{return F()}finally{f=C}},e.unstable_scheduleCallback=function(L,F,C){var te=e.unstable_now();switch(typeof C=="object"&&C!==null?(C=C.delay,C=typeof C=="number"&&0<C?te+C:te):C=te,L){case 1:var fe=-1;break;case 2:fe=250;break;case 5:fe=1073741823;break;case 4:fe=1e4;break;default:fe=5e3}return fe=C+fe,L={id:c++,callback:F,priorityLevel:L,startTime:C,expirationTime:fe,sortIndex:-1},C>te?(L.sortIndex=C,t(u,L),n(l)===null&&L===n(u)&&(w?(m(P),P=-1):w=!0,ne(T,C-te))):(L.sortIndex=fe,t(l,L),g||p||(g=!0,oe(_))),L},e.unstable_shouldYield=H,e.unstable_wrapCallback=function(L){var F=f;return function(){var C=f;f=F;try{return L.apply(this,arguments)}finally{f=C}}}})(bE),vE.exports=bE;var z8=vE.exports;/**
39
+ * @license React
40
+ * react-dom.production.min.js
41
+ *
42
+ * Copyright (c) Facebook, Inc. and its affiliates.
43
+ *
44
+ * This source code is licensed under the MIT license found in the
45
+ * LICENSE file in the root directory of this source tree.
46
+ */var U8=y,Sn=z8;function Y(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var xE=new Set,Cl={};function La(e,t){No(e,t),No(e+"Capture",t)}function No(e,t){for(Cl[e]=t,e=0;e<t.length;e++)xE.add(t[e])}var Jr=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Mm=Object.prototype.hasOwnProperty,H8=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,EE={},TE={};function V8(e){return Mm.call(TE,e)?!0:Mm.call(EE,e)?!1:H8.test(e)?TE[e]=!0:(EE[e]=!0,!1)}function $8(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function W8(e,t,n,r){if(t===null||typeof t>"u"||$8(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function en(e,t,n,r,i,a,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=o}var Ot={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ot[e]=new en(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ot[t]=new en(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ot[e]=new en(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ot[e]=new en(e,2,!1,e,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Ot[e]=new en(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){Ot[e]=new en(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){Ot[e]=new en(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){Ot[e]=new en(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){Ot[e]=new en(e,5,!1,e.toLowerCase(),null,!1,!1)});var Fm=/[\-:]([a-z])/g;function Bm(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Fm,Bm);Ot[t]=new en(t,1,!1,e,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Fm,Bm);Ot[t]=new en(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Fm,Bm);Ot[t]=new en(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){Ot[e]=new en(e,1,!1,e.toLowerCase(),null,!1,!1)}),Ot.xlinkHref=new en("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){Ot[e]=new en(e,1,!1,e.toLowerCase(),null,!0,!0)});function jm(e,t,n,r){var i=Ot.hasOwnProperty(t)?Ot[t]:null;(i!==null?i.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(W8(t,n,i,r)&&(n=null),r||i===null?V8(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):i.mustUseProperty?e[i.propertyName]=n===null?i.type===3?!1:"":n:(t=i.attributeName,r=i.attributeNamespace,n===null?e.removeAttribute(t):(i=i.type,n=i===3||i===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var ei=U8.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,ld=Symbol.for("react.element"),Oo=Symbol.for("react.portal"),Po=Symbol.for("react.fragment"),zm=Symbol.for("react.strict_mode"),Um=Symbol.for("react.profiler"),_E=Symbol.for("react.provider"),SE=Symbol.for("react.context"),Hm=Symbol.for("react.forward_ref"),Vm=Symbol.for("react.suspense"),$m=Symbol.for("react.suspense_list"),Wm=Symbol.for("react.memo"),Li=Symbol.for("react.lazy"),kE=Symbol.for("react.offscreen"),CE=Symbol.iterator;function Al(e){return e===null||typeof e!="object"?null:(e=CE&&e[CE]||e["@@iterator"],typeof e=="function"?e:null)}var at=Object.assign,Ym;function Rl(e){if(Ym===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);Ym=t&&t[1]||""}return`
47
+ `+Ym+e}var qm=!1;function Gm(e,t){if(!e||qm)return"";qm=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(u){var r=u}Reflect.construct(e,[],t)}else{try{t.call()}catch(u){r=u}e.call(t.prototype)}else{try{throw Error()}catch(u){r=u}e()}}catch(u){if(u&&r&&typeof u.stack=="string"){for(var i=u.stack.split(`
48
+ `),a=r.stack.split(`
49
+ `),o=i.length-1,s=a.length-1;1<=o&&0<=s&&i[o]!==a[s];)s--;for(;1<=o&&0<=s;o--,s--)if(i[o]!==a[s]){if(o!==1||s!==1)do if(o--,s--,0>s||i[o]!==a[s]){var l=`
50
+ `+i[o].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}while(1<=o&&0<=s);break}}}finally{qm=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Rl(e):""}function Y8(e){switch(e.tag){case 5:return Rl(e.type);case 16:return Rl("Lazy");case 13:return Rl("Suspense");case 19:return Rl("SuspenseList");case 0:case 2:case 15:return e=Gm(e.type,!1),e;case 11:return e=Gm(e.type.render,!1),e;case 1:return e=Gm(e.type,!0),e;default:return""}}function Km(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Po:return"Fragment";case Oo:return"Portal";case Um:return"Profiler";case zm:return"StrictMode";case Vm:return"Suspense";case $m:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case SE:return(e.displayName||"Context")+".Consumer";case _E:return(e._context.displayName||"Context")+".Provider";case Hm:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Wm:return t=e.displayName||null,t!==null?t:Km(e.type)||"Memo";case Li:t=e._payload,e=e._init;try{return Km(e(t))}catch{}}return null}function q8(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Km(t);case 8:return t===zm?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Mi(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function AE(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function G8(e){var t=AE(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,a=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){r=""+o,a.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function ud(e){e._valueTracker||(e._valueTracker=G8(e))}function RE(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=AE(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function cd(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Xm(e,t){var n=t.checked;return at({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function NE(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Mi(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function OE(e,t){t=t.checked,t!=null&&jm(e,"checked",t,!1)}function Qm(e,t){OE(e,t);var n=Mi(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Zm(e,t.type,n):t.hasOwnProperty("defaultValue")&&Zm(e,t.type,Mi(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function PE(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Zm(e,t,n){(t!=="number"||cd(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Nl=Array.isArray;function Io(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t["$"+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty("$"+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Mi(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Jm(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(Y(91));return at({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function IE(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(Y(92));if(Nl(n)){if(1<n.length)throw Error(Y(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:Mi(n)}}function DE(e,t){var n=Mi(t.value),r=Mi(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function LE(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function ME(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function eg(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?ME(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var dd,FE=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,i){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,i)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(dd=dd||document.createElement("div"),dd.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=dd.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Ol(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Pl={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},K8=["Webkit","ms","Moz","O"];Object.keys(Pl).forEach(function(e){K8.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Pl[t]=Pl[e]})});function BE(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Pl.hasOwnProperty(e)&&Pl[e]?(""+t).trim():t+"px"}function jE(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=BE(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var X8=at({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function tg(e,t){if(t){if(X8[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(Y(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(Y(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(Y(61))}if(t.style!=null&&typeof t.style!="object")throw Error(Y(62))}}function ng(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var rg=null;function ig(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ag=null,Do=null,Lo=null;function zE(e){if(e=eu(e)){if(typeof ag!="function")throw Error(Y(280));var t=e.stateNode;t&&(t=Dd(t),ag(e.stateNode,e.type,t))}}function UE(e){Do?Lo?Lo.push(e):Lo=[e]:Do=e}function HE(){if(Do){var e=Do,t=Lo;if(Lo=Do=null,zE(e),t)for(e=0;e<t.length;e++)zE(t[e])}}function VE(e,t){return e(t)}function $E(){}var og=!1;function WE(e,t,n){if(og)return e(t,n);og=!0;try{return VE(e,t,n)}finally{og=!1,(Do!==null||Lo!==null)&&($E(),HE())}}function Il(e,t){var n=e.stateNode;if(n===null)return null;var r=Dd(n);if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(Y(231,t,typeof n));return n}var sg=!1;if(Jr)try{var Dl={};Object.defineProperty(Dl,"passive",{get:function(){sg=!0}}),window.addEventListener("test",Dl,Dl),window.removeEventListener("test",Dl,Dl)}catch{sg=!1}function Q8(e,t,n,r,i,a,o,s,l){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(c){this.onError(c)}}var Ll=!1,fd=null,pd=!1,lg=null,Z8={onError:function(e){Ll=!0,fd=e}};function J8(e,t,n,r,i,a,o,s,l){Ll=!1,fd=null,Q8.apply(Z8,arguments)}function eF(e,t,n,r,i,a,o,s,l){if(J8.apply(this,arguments),Ll){if(Ll){var u=fd;Ll=!1,fd=null}else throw Error(Y(198));pd||(pd=!0,lg=u)}}function Ma(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function YE(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function qE(e){if(Ma(e)!==e)throw Error(Y(188))}function tF(e){var t=e.alternate;if(!t){if(t=Ma(e),t===null)throw Error(Y(188));return t!==e?null:e}for(var n=e,r=t;;){var i=n.return;if(i===null)break;var a=i.alternate;if(a===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===a.child){for(a=i.child;a;){if(a===n)return qE(i),e;if(a===r)return qE(i),t;a=a.sibling}throw Error(Y(188))}if(n.return!==r.return)n=i,r=a;else{for(var o=!1,s=i.child;s;){if(s===n){o=!0,n=i,r=a;break}if(s===r){o=!0,r=i,n=a;break}s=s.sibling}if(!o){for(s=a.child;s;){if(s===n){o=!0,n=a,r=i;break}if(s===r){o=!0,r=a,n=i;break}s=s.sibling}if(!o)throw Error(Y(189))}}if(n.alternate!==r)throw Error(Y(190))}if(n.tag!==3)throw Error(Y(188));return n.stateNode.current===n?e:t}function GE(e){return e=tF(e),e!==null?KE(e):null}function KE(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=KE(e);if(t!==null)return t;e=e.sibling}return null}var XE=Sn.unstable_scheduleCallback,QE=Sn.unstable_cancelCallback,nF=Sn.unstable_shouldYield,rF=Sn.unstable_requestPaint,ft=Sn.unstable_now,iF=Sn.unstable_getCurrentPriorityLevel,ug=Sn.unstable_ImmediatePriority,ZE=Sn.unstable_UserBlockingPriority,hd=Sn.unstable_NormalPriority,aF=Sn.unstable_LowPriority,JE=Sn.unstable_IdlePriority,md=null,Ar=null;function oF(e){if(Ar&&typeof Ar.onCommitFiberRoot=="function")try{Ar.onCommitFiberRoot(md,e,void 0,(e.current.flags&128)===128)}catch{}}var or=Math.clz32?Math.clz32:uF,sF=Math.log,lF=Math.LN2;function uF(e){return e>>>=0,e===0?32:31-(sF(e)/lF|0)|0}var gd=64,wd=4194304;function Ml(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function yd(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,a=e.pingedLanes,o=n&268435455;if(o!==0){var s=o&~i;s!==0?r=Ml(s):(a&=o,a!==0&&(r=Ml(a)))}else o=n&~i,o!==0?r=Ml(o):a!==0&&(r=Ml(a));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,a=t&-t,i>=a||i===16&&(a&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-or(t),i=1<<n,r|=e[n],t&=~i;return r}function cF(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function dF(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes;0<a;){var o=31-or(a),s=1<<o,l=i[o];l===-1?(!(s&n)||s&r)&&(i[o]=cF(s,t)):l<=t&&(e.expiredLanes|=s),a&=~s}}function cg(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function eT(){var e=gd;return gd<<=1,!(gd&4194240)&&(gd=64),e}function dg(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Fl(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-or(t),e[t]=n}function fF(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<n;){var i=31-or(n),a=1<<i;t[i]=0,r[i]=-1,e[i]=-1,n&=~a}}function fg(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-or(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}var $e=0;function tT(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var nT,pg,rT,iT,aT,hg=!1,vd=[],Fi=null,Bi=null,ji=null,Bl=new Map,jl=new Map,zi=[],pF="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function oT(e,t){switch(e){case"focusin":case"focusout":Fi=null;break;case"dragenter":case"dragleave":Bi=null;break;case"mouseover":case"mouseout":ji=null;break;case"pointerover":case"pointerout":Bl.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":jl.delete(t.pointerId)}}function zl(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=eu(t),t!==null&&pg(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function hF(e,t,n,r,i){switch(t){case"focusin":return Fi=zl(Fi,e,t,n,r,i),!0;case"dragenter":return Bi=zl(Bi,e,t,n,r,i),!0;case"mouseover":return ji=zl(ji,e,t,n,r,i),!0;case"pointerover":var a=i.pointerId;return Bl.set(a,zl(Bl.get(a)||null,e,t,n,r,i)),!0;case"gotpointercapture":return a=i.pointerId,jl.set(a,zl(jl.get(a)||null,e,t,n,r,i)),!0}return!1}function sT(e){var t=Fa(e.target);if(t!==null){var n=Ma(t);if(n!==null){if(t=n.tag,t===13){if(t=YE(n),t!==null){e.blockedOn=t,aT(e.priority,function(){rT(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function bd(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=gg(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);rg=r,n.target.dispatchEvent(r),rg=null}else return t=eu(n),t!==null&&pg(t),e.blockedOn=n,!1;t.shift()}return!0}function lT(e,t,n){bd(e)&&n.delete(t)}function mF(){hg=!1,Fi!==null&&bd(Fi)&&(Fi=null),Bi!==null&&bd(Bi)&&(Bi=null),ji!==null&&bd(ji)&&(ji=null),Bl.forEach(lT),jl.forEach(lT)}function Ul(e,t){e.blockedOn===t&&(e.blockedOn=null,hg||(hg=!0,Sn.unstable_scheduleCallback(Sn.unstable_NormalPriority,mF)))}function Hl(e){function t(i){return Ul(i,e)}if(0<vd.length){Ul(vd[0],e);for(var n=1;n<vd.length;n++){var r=vd[n];r.blockedOn===e&&(r.blockedOn=null)}}for(Fi!==null&&Ul(Fi,e),Bi!==null&&Ul(Bi,e),ji!==null&&Ul(ji,e),Bl.forEach(t),jl.forEach(t),n=0;n<zi.length;n++)r=zi[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<zi.length&&(n=zi[0],n.blockedOn===null);)sT(n),n.blockedOn===null&&zi.shift()}var Mo=ei.ReactCurrentBatchConfig,xd=!0;function gF(e,t,n,r){var i=$e,a=Mo.transition;Mo.transition=null;try{$e=1,mg(e,t,n,r)}finally{$e=i,Mo.transition=a}}function wF(e,t,n,r){var i=$e,a=Mo.transition;Mo.transition=null;try{$e=4,mg(e,t,n,r)}finally{$e=i,Mo.transition=a}}function mg(e,t,n,r){if(xd){var i=gg(e,t,n,r);if(i===null)Ig(e,t,r,Ed,n),oT(e,r);else if(hF(i,e,t,n,r))r.stopPropagation();else if(oT(e,r),t&4&&-1<pF.indexOf(e)){for(;i!==null;){var a=eu(i);if(a!==null&&nT(a),a=gg(e,t,n,r),a===null&&Ig(e,t,r,Ed,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Ig(e,t,r,null,n)}}var Ed=null;function gg(e,t,n,r){if(Ed=null,e=ig(r),e=Fa(e),e!==null)if(t=Ma(e),t===null)e=null;else if(n=t.tag,n===13){if(e=YE(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Ed=e,null}function uT(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(iF()){case ug:return 1;case ZE:return 4;case hd:case aF:return 16;case JE:return 536870912;default:return 16}default:return 16}}var Ui=null,wg=null,Td=null;function cT(){if(Td)return Td;var e,t=wg,n=t.length,r,i="value"in Ui?Ui.value:Ui.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return Td=i.slice(e,1<r?1-r:void 0)}function _d(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Sd(){return!0}function dT(){return!1}function kn(e){function t(n,r,i,a,o){this._reactName=n,this._targetInst=i,this.type=r,this.nativeEvent=a,this.target=o,this.currentTarget=null;for(var s in e)e.hasOwnProperty(s)&&(n=e[s],this[s]=n?n(a):a[s]);return this.isDefaultPrevented=(a.defaultPrevented!=null?a.defaultPrevented:a.returnValue===!1)?Sd:dT,this.isPropagationStopped=dT,this}return at(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=Sd)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Sd)},persist:function(){},isPersistent:Sd}),t}var Fo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},yg=kn(Fo),Vl=at({},Fo,{view:0,detail:0}),yF=kn(Vl),vg,bg,$l,kd=at({},Vl,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Eg,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==$l&&($l&&e.type==="mousemove"?(vg=e.screenX-$l.screenX,bg=e.screenY-$l.screenY):bg=vg=0,$l=e),vg)},movementY:function(e){return"movementY"in e?e.movementY:bg}}),fT=kn(kd),vF=at({},kd,{dataTransfer:0}),bF=kn(vF),xF=at({},Vl,{relatedTarget:0}),xg=kn(xF),EF=at({},Fo,{animationName:0,elapsedTime:0,pseudoElement:0}),TF=kn(EF),_F=at({},Fo,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),SF=kn(_F),kF=at({},Fo,{data:0}),pT=kn(kF),CF={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},AF={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},RF={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function NF(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=RF[e])?!!t[e]:!1}function Eg(){return NF}var OF=at({},Vl,{key:function(e){if(e.key){var t=CF[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=_d(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?AF[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Eg,charCode:function(e){return e.type==="keypress"?_d(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?_d(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),PF=kn(OF),IF=at({},kd,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),hT=kn(IF),DF=at({},Vl,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Eg}),LF=kn(DF),MF=at({},Fo,{propertyName:0,elapsedTime:0,pseudoElement:0}),FF=kn(MF),BF=at({},kd,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),jF=kn(BF),zF=[9,13,27,32],Tg=Jr&&"CompositionEvent"in window,Wl=null;Jr&&"documentMode"in document&&(Wl=document.documentMode);var UF=Jr&&"TextEvent"in window&&!Wl,mT=Jr&&(!Tg||Wl&&8<Wl&&11>=Wl),gT=" ",wT=!1;function yT(e,t){switch(e){case"keyup":return zF.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function vT(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Bo=!1;function HF(e,t){switch(e){case"compositionend":return vT(t);case"keypress":return t.which!==32?null:(wT=!0,gT);case"textInput":return e=t.data,e===gT&&wT?null:e;default:return null}}function VF(e,t){if(Bo)return e==="compositionend"||!Tg&&yT(e,t)?(e=cT(),Td=wg=Ui=null,Bo=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return mT&&t.locale!=="ko"?null:t.data;default:return null}}var $F={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function bT(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!$F[e.type]:t==="textarea"}function xT(e,t,n,r){UE(r),t=Od(t,"onChange"),0<t.length&&(n=new yg("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Yl=null,ql=null;function WF(e){jT(e,0)}function Cd(e){var t=Vo(e);if(RE(t))return e}function YF(e,t){if(e==="change")return t}var ET=!1;if(Jr){var _g;if(Jr){var Sg="oninput"in document;if(!Sg){var TT=document.createElement("div");TT.setAttribute("oninput","return;"),Sg=typeof TT.oninput=="function"}_g=Sg}else _g=!1;ET=_g&&(!document.documentMode||9<document.documentMode)}function _T(){Yl&&(Yl.detachEvent("onpropertychange",ST),ql=Yl=null)}function ST(e){if(e.propertyName==="value"&&Cd(ql)){var t=[];xT(t,ql,e,ig(e)),WE(WF,t)}}function qF(e,t,n){e==="focusin"?(_T(),Yl=t,ql=n,Yl.attachEvent("onpropertychange",ST)):e==="focusout"&&_T()}function GF(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Cd(ql)}function KF(e,t){if(e==="click")return Cd(t)}function XF(e,t){if(e==="input"||e==="change")return Cd(t)}function QF(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var sr=typeof Object.is=="function"?Object.is:QF;function Gl(e,t){if(sr(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!Mm.call(t,i)||!sr(e[i],t[i]))return!1}return!0}function kT(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function CT(e,t){var n=kT(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=kT(n)}}function AT(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?AT(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function RT(){for(var e=window,t=cd();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=cd(e.document)}return t}function kg(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function ZF(e){var t=RT(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&AT(n.ownerDocument.documentElement,n)){if(r!==null&&kg(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=n.textContent.length,a=Math.min(r.start,i);r=r.end===void 0?a:Math.min(r.end,i),!e.extend&&a>r&&(i=r,r=a,a=i),i=CT(n,a);var o=CT(n,r);i&&o&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),a>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var JF=Jr&&"documentMode"in document&&11>=document.documentMode,jo=null,Cg=null,Kl=null,Ag=!1;function NT(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Ag||jo==null||jo!==cd(r)||(r=jo,"selectionStart"in r&&kg(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Kl&&Gl(Kl,r)||(Kl=r,r=Od(Cg,"onSelect"),0<r.length&&(t=new yg("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=jo)))}function Ad(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var zo={animationend:Ad("Animation","AnimationEnd"),animationiteration:Ad("Animation","AnimationIteration"),animationstart:Ad("Animation","AnimationStart"),transitionend:Ad("Transition","TransitionEnd")},Rg={},OT={};Jr&&(OT=document.createElement("div").style,"AnimationEvent"in window||(delete zo.animationend.animation,delete zo.animationiteration.animation,delete zo.animationstart.animation),"TransitionEvent"in window||delete zo.transitionend.transition);function Rd(e){if(Rg[e])return Rg[e];if(!zo[e])return e;var t=zo[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in OT)return Rg[e]=t[n];return e}var PT=Rd("animationend"),IT=Rd("animationiteration"),DT=Rd("animationstart"),LT=Rd("transitionend"),MT=new Map,FT="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Hi(e,t){MT.set(e,t),La(t,[e])}for(var Ng=0;Ng<FT.length;Ng++){var Og=FT[Ng],e9=Og.toLowerCase(),t9=Og[0].toUpperCase()+Og.slice(1);Hi(e9,"on"+t9)}Hi(PT,"onAnimationEnd"),Hi(IT,"onAnimationIteration"),Hi(DT,"onAnimationStart"),Hi("dblclick","onDoubleClick"),Hi("focusin","onFocus"),Hi("focusout","onBlur"),Hi(LT,"onTransitionEnd"),No("onMouseEnter",["mouseout","mouseover"]),No("onMouseLeave",["mouseout","mouseover"]),No("onPointerEnter",["pointerout","pointerover"]),No("onPointerLeave",["pointerout","pointerover"]),La("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),La("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),La("onBeforeInput",["compositionend","keypress","textInput","paste"]),La("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),La("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),La("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Xl="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),n9=new Set("cancel close invalid load scroll toggle".split(" ").concat(Xl));function BT(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,eF(r,t,void 0,e),e.currentTarget=null}function jT(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;e:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],l=s.instance,u=s.currentTarget;if(s=s.listener,l!==a&&i.isPropagationStopped())break e;BT(i,s,u),a=l}else for(o=0;o<r.length;o++){if(s=r[o],l=s.instance,u=s.currentTarget,s=s.listener,l!==a&&i.isPropagationStopped())break e;BT(i,s,u),a=l}}}if(pd)throw e=lg,pd=!1,lg=null,e}function Ze(e,t){var n=t[jg];n===void 0&&(n=t[jg]=new Set);var r=e+"__bubble";n.has(r)||(zT(t,e,2,!1),n.add(r))}function Pg(e,t,n){var r=0;t&&(r|=4),zT(n,e,r,t)}var Nd="_reactListening"+Math.random().toString(36).slice(2);function Ql(e){if(!e[Nd]){e[Nd]=!0,xE.forEach(function(n){n!=="selectionchange"&&(n9.has(n)||Pg(n,!1,e),Pg(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Nd]||(t[Nd]=!0,Pg("selectionchange",!1,t))}}function zT(e,t,n,r){switch(uT(t)){case 1:var i=gF;break;case 4:i=wF;break;default:i=mg}n=i.bind(null,t,n,e),i=void 0,!sg||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(i=!0),r?i!==void 0?e.addEventListener(t,n,{capture:!0,passive:i}):e.addEventListener(t,n,!0):i!==void 0?e.addEventListener(t,n,{passive:i}):e.addEventListener(t,n,!1)}function Ig(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var s=r.stateNode.containerInfo;if(s===i||s.nodeType===8&&s.parentNode===i)break;if(o===4)for(o=r.return;o!==null;){var l=o.tag;if((l===3||l===4)&&(l=o.stateNode.containerInfo,l===i||l.nodeType===8&&l.parentNode===i))return;o=o.return}for(;s!==null;){if(o=Fa(s),o===null)return;if(l=o.tag,l===5||l===6){r=a=o;continue e}s=s.parentNode}}r=r.return}WE(function(){var u=a,c=ig(n),d=[];e:{var f=MT.get(e);if(f!==void 0){var p=yg,g=e;switch(e){case"keypress":if(_d(n)===0)break e;case"keydown":case"keyup":p=PF;break;case"focusin":g="focus",p=xg;break;case"focusout":g="blur",p=xg;break;case"beforeblur":case"afterblur":p=xg;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":p=fT;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":p=bF;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":p=LF;break;case PT:case IT:case DT:p=TF;break;case LT:p=FF;break;case"scroll":p=yF;break;case"wheel":p=jF;break;case"copy":case"cut":case"paste":p=SF;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":p=hT}var w=(t&4)!==0,x=!w&&e==="scroll",m=w?f!==null?f+"Capture":null:f;w=[];for(var v=u,b;v!==null;){b=v;var T=b.stateNode;if(b.tag===5&&T!==null&&(b=T,m!==null&&(T=Il(v,m),T!=null&&w.push(Zl(v,T,b)))),x)break;v=v.return}0<w.length&&(f=new p(f,g,null,n,c),d.push({event:f,listeners:w}))}}if(!(t&7)){e:{if(f=e==="mouseover"||e==="pointerover",p=e==="mouseout"||e==="pointerout",f&&n!==rg&&(g=n.relatedTarget||n.fromElement)&&(Fa(g)||g[ti]))break e;if((p||f)&&(f=c.window===c?c:(f=c.ownerDocument)?f.defaultView||f.parentWindow:window,p?(g=n.relatedTarget||n.toElement,p=u,g=g?Fa(g):null,g!==null&&(x=Ma(g),g!==x||g.tag!==5&&g.tag!==6)&&(g=null)):(p=null,g=u),p!==g)){if(w=fT,T="onMouseLeave",m="onMouseEnter",v="mouse",(e==="pointerout"||e==="pointerover")&&(w=hT,T="onPointerLeave",m="onPointerEnter",v="pointer"),x=p==null?f:Vo(p),b=g==null?f:Vo(g),f=new w(T,v+"leave",p,n,c),f.target=x,f.relatedTarget=b,T=null,Fa(c)===u&&(w=new w(m,v+"enter",g,n,c),w.target=b,w.relatedTarget=x,T=w),x=T,p&&g)t:{for(w=p,m=g,v=0,b=w;b;b=Uo(b))v++;for(b=0,T=m;T;T=Uo(T))b++;for(;0<v-b;)w=Uo(w),v--;for(;0<b-v;)m=Uo(m),b--;for(;v--;){if(w===m||m!==null&&w===m.alternate)break t;w=Uo(w),m=Uo(m)}w=null}else w=null;p!==null&&UT(d,f,p,w,!1),g!==null&&x!==null&&UT(d,x,g,w,!0)}}e:{if(f=u?Vo(u):window,p=f.nodeName&&f.nodeName.toLowerCase(),p==="select"||p==="input"&&f.type==="file")var _=YF;else if(bT(f))if(ET)_=XF;else{_=GF;var S=qF}else(p=f.nodeName)&&p.toLowerCase()==="input"&&(f.type==="checkbox"||f.type==="radio")&&(_=KF);if(_&&(_=_(e,u))){xT(d,_,n,c);break e}S&&S(e,f,u),e==="focusout"&&(S=f._wrapperState)&&S.controlled&&f.type==="number"&&Zm(f,"number",f.value)}switch(S=u?Vo(u):window,e){case"focusin":(bT(S)||S.contentEditable==="true")&&(jo=S,Cg=u,Kl=null);break;case"focusout":Kl=Cg=jo=null;break;case"mousedown":Ag=!0;break;case"contextmenu":case"mouseup":case"dragend":Ag=!1,NT(d,n,c);break;case"selectionchange":if(JF)break;case"keydown":case"keyup":NT(d,n,c)}var R;if(Tg)e:{switch(e){case"compositionstart":var P="onCompositionStart";break e;case"compositionend":P="onCompositionEnd";break e;case"compositionupdate":P="onCompositionUpdate";break e}P=void 0}else Bo?yT(e,n)&&(P="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(P="onCompositionStart");P&&(mT&&n.locale!=="ko"&&(Bo||P!=="onCompositionStart"?P==="onCompositionEnd"&&Bo&&(R=cT()):(Ui=c,wg="value"in Ui?Ui.value:Ui.textContent,Bo=!0)),S=Od(u,P),0<S.length&&(P=new pT(P,e,null,n,c),d.push({event:P,listeners:S}),R?P.data=R:(R=vT(n),R!==null&&(P.data=R)))),(R=UF?HF(e,n):VF(e,n))&&(u=Od(u,"onBeforeInput"),0<u.length&&(c=new pT("onBeforeInput","beforeinput",null,n,c),d.push({event:c,listeners:u}),c.data=R))}jT(d,t)})}function Zl(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Od(e,t){for(var n=t+"Capture",r=[];e!==null;){var i=e,a=i.stateNode;i.tag===5&&a!==null&&(i=a,a=Il(e,n),a!=null&&r.unshift(Zl(e,a,i)),a=Il(e,t),a!=null&&r.push(Zl(e,a,i))),e=e.return}return r}function Uo(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function UT(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,l=s.alternate,u=s.stateNode;if(l!==null&&l===r)break;s.tag===5&&u!==null&&(s=u,i?(l=Il(n,a),l!=null&&o.unshift(Zl(n,l,s))):i||(l=Il(n,a),l!=null&&o.push(Zl(n,l,s)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var r9=/\r\n?/g,i9=/\u0000|\uFFFD/g;function HT(e){return(typeof e=="string"?e:""+e).replace(r9,`
51
+ `).replace(i9,"")}function Pd(e,t,n){if(t=HT(t),HT(e)!==t&&n)throw Error(Y(425))}function Id(){}var Dg=null,Lg=null;function Mg(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Fg=typeof setTimeout=="function"?setTimeout:void 0,a9=typeof clearTimeout=="function"?clearTimeout:void 0,VT=typeof Promise=="function"?Promise:void 0,o9=typeof queueMicrotask=="function"?queueMicrotask:typeof VT<"u"?function(e){return VT.resolve(null).then(e).catch(s9)}:Fg;function s9(e){setTimeout(function(){throw e})}function Bg(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n==="/$"){if(r===0){e.removeChild(i),Hl(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=i}while(n);Hl(t)}function Vi(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function $T(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var Ho=Math.random().toString(36).slice(2),Rr="__reactFiber$"+Ho,Jl="__reactProps$"+Ho,ti="__reactContainer$"+Ho,jg="__reactEvents$"+Ho,l9="__reactListeners$"+Ho,u9="__reactHandles$"+Ho;function Fa(e){var t=e[Rr];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ti]||n[Rr]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=$T(e);e!==null;){if(n=e[Rr])return n;e=$T(e)}return t}e=n,n=e.parentNode}return null}function eu(e){return e=e[Rr]||e[ti],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Vo(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(Y(33))}function Dd(e){return e[Jl]||null}var zg=[],$o=-1;function $i(e){return{current:e}}function Je(e){0>$o||(e.current=zg[$o],zg[$o]=null,$o--)}function Xe(e,t){$o++,zg[$o]=e.current,e.current=t}var Wi={},zt=$i(Wi),cn=$i(!1),Ba=Wi;function Wo(e,t){var n=e.type.contextTypes;if(!n)return Wi;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},a;for(a in n)i[a]=t[a];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function dn(e){return e=e.childContextTypes,e!=null}function Ld(){Je(cn),Je(zt)}function WT(e,t,n){if(zt.current!==Wi)throw Error(Y(168));Xe(zt,t),Xe(cn,n)}function YT(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(Y(108,q8(e)||"Unknown",i));return at({},n,r)}function Md(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Wi,Ba=zt.current,Xe(zt,e),Xe(cn,cn.current),!0}function qT(e,t,n){var r=e.stateNode;if(!r)throw Error(Y(169));n?(e=YT(e,t,Ba),r.__reactInternalMemoizedMergedChildContext=e,Je(cn),Je(zt),Xe(zt,e)):Je(cn),Xe(cn,n)}var ni=null,Fd=!1,Ug=!1;function GT(e){ni===null?ni=[e]:ni.push(e)}function c9(e){Fd=!0,GT(e)}function Yi(){if(!Ug&&ni!==null){Ug=!0;var e=0,t=$e;try{var n=ni;for($e=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}ni=null,Fd=!1}catch(i){throw ni!==null&&(ni=ni.slice(e+1)),XE(ug,Yi),i}finally{$e=t,Ug=!1}}return null}var Yo=[],qo=0,Bd=null,jd=0,Bn=[],jn=0,ja=null,ri=1,ii="";function za(e,t){Yo[qo++]=jd,Yo[qo++]=Bd,Bd=e,jd=t}function KT(e,t,n){Bn[jn++]=ri,Bn[jn++]=ii,Bn[jn++]=ja,ja=e;var r=ri;e=ii;var i=32-or(r)-1;r&=~(1<<i),n+=1;var a=32-or(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,ri=1<<32-or(t)+i|n<<i|r,ii=a+e}else ri=1<<a|n<<i|r,ii=e}function Hg(e){e.return!==null&&(za(e,1),KT(e,1,0))}function Vg(e){for(;e===Bd;)Bd=Yo[--qo],Yo[qo]=null,jd=Yo[--qo],Yo[qo]=null;for(;e===ja;)ja=Bn[--jn],Bn[jn]=null,ii=Bn[--jn],Bn[jn]=null,ri=Bn[--jn],Bn[jn]=null}var Cn=null,An=null,tt=!1,lr=null;function XT(e,t){var n=Vn(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function QT(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,Cn=e,An=Vi(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Cn=e,An=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=ja!==null?{id:ri,overflow:ii}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=Vn(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,Cn=e,An=null,!0):!1;default:return!1}}function $g(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Wg(e){if(tt){var t=An;if(t){var n=t;if(!QT(e,t)){if($g(e))throw Error(Y(418));t=Vi(n.nextSibling);var r=Cn;t&&QT(e,t)?XT(r,n):(e.flags=e.flags&-4097|2,tt=!1,Cn=e)}}else{if($g(e))throw Error(Y(418));e.flags=e.flags&-4097|2,tt=!1,Cn=e}}}function ZT(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Cn=e}function zd(e){if(e!==Cn)return!1;if(!tt)return ZT(e),tt=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Mg(e.type,e.memoizedProps)),t&&(t=An)){if($g(e))throw JT(),Error(Y(418));for(;t;)XT(e,t),t=Vi(t.nextSibling)}if(ZT(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(Y(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){An=Vi(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}An=null}}else An=Cn?Vi(e.stateNode.nextSibling):null;return!0}function JT(){for(var e=An;e;)e=Vi(e.nextSibling)}function Go(){An=Cn=null,tt=!1}function Yg(e){lr===null?lr=[e]:lr.push(e)}var d9=ei.ReactCurrentBatchConfig;function tu(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(Y(309));var r=n.stateNode}if(!r)throw Error(Y(147,e));var i=r,a=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===a?t.ref:(t=function(o){var s=i.refs;o===null?delete s[a]:s[a]=o},t._stringRef=a,t)}if(typeof e!="string")throw Error(Y(284));if(!n._owner)throw Error(Y(290,e))}return e}function Ud(e,t){throw e=Object.prototype.toString.call(t),Error(Y(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function e2(e){var t=e._init;return t(e._payload)}function t2(e){function t(m,v){if(e){var b=m.deletions;b===null?(m.deletions=[v],m.flags|=16):b.push(v)}}function n(m,v){if(!e)return null;for(;v!==null;)t(m,v),v=v.sibling;return null}function r(m,v){for(m=new Map;v!==null;)v.key!==null?m.set(v.key,v):m.set(v.index,v),v=v.sibling;return m}function i(m,v){return m=ea(m,v),m.index=0,m.sibling=null,m}function a(m,v,b){return m.index=b,e?(b=m.alternate,b!==null?(b=b.index,b<v?(m.flags|=2,v):b):(m.flags|=2,v)):(m.flags|=1048576,v)}function o(m){return e&&m.alternate===null&&(m.flags|=2),m}function s(m,v,b,T){return v===null||v.tag!==6?(v=F0(b,m.mode,T),v.return=m,v):(v=i(v,b),v.return=m,v)}function l(m,v,b,T){var _=b.type;return _===Po?c(m,v,b.props.children,T,b.key):v!==null&&(v.elementType===_||typeof _=="object"&&_!==null&&_.$$typeof===Li&&e2(_)===v.type)?(T=i(v,b.props),T.ref=tu(m,v,b),T.return=m,T):(T=ff(b.type,b.key,b.props,null,m.mode,T),T.ref=tu(m,v,b),T.return=m,T)}function u(m,v,b,T){return v===null||v.tag!==4||v.stateNode.containerInfo!==b.containerInfo||v.stateNode.implementation!==b.implementation?(v=B0(b,m.mode,T),v.return=m,v):(v=i(v,b.children||[]),v.return=m,v)}function c(m,v,b,T,_){return v===null||v.tag!==7?(v=Ga(b,m.mode,T,_),v.return=m,v):(v=i(v,b),v.return=m,v)}function d(m,v,b){if(typeof v=="string"&&v!==""||typeof v=="number")return v=F0(""+v,m.mode,b),v.return=m,v;if(typeof v=="object"&&v!==null){switch(v.$$typeof){case ld:return b=ff(v.type,v.key,v.props,null,m.mode,b),b.ref=tu(m,null,v),b.return=m,b;case Oo:return v=B0(v,m.mode,b),v.return=m,v;case Li:var T=v._init;return d(m,T(v._payload),b)}if(Nl(v)||Al(v))return v=Ga(v,m.mode,b,null),v.return=m,v;Ud(m,v)}return null}function f(m,v,b,T){var _=v!==null?v.key:null;if(typeof b=="string"&&b!==""||typeof b=="number")return _!==null?null:s(m,v,""+b,T);if(typeof b=="object"&&b!==null){switch(b.$$typeof){case ld:return b.key===_?l(m,v,b,T):null;case Oo:return b.key===_?u(m,v,b,T):null;case Li:return _=b._init,f(m,v,_(b._payload),T)}if(Nl(b)||Al(b))return _!==null?null:c(m,v,b,T,null);Ud(m,b)}return null}function p(m,v,b,T,_){if(typeof T=="string"&&T!==""||typeof T=="number")return m=m.get(b)||null,s(v,m,""+T,_);if(typeof T=="object"&&T!==null){switch(T.$$typeof){case ld:return m=m.get(T.key===null?b:T.key)||null,l(v,m,T,_);case Oo:return m=m.get(T.key===null?b:T.key)||null,u(v,m,T,_);case Li:var S=T._init;return p(m,v,b,S(T._payload),_)}if(Nl(T)||Al(T))return m=m.get(b)||null,c(v,m,T,_,null);Ud(v,T)}return null}function g(m,v,b,T){for(var _=null,S=null,R=v,P=v=0,B=null;R!==null&&P<b.length;P++){R.index>P?(B=R,R=null):B=R.sibling;var N=f(m,R,b[P],T);if(N===null){R===null&&(R=B);break}e&&R&&N.alternate===null&&t(m,R),v=a(N,v,P),S===null?_=N:S.sibling=N,S=N,R=B}if(P===b.length)return n(m,R),tt&&za(m,P),_;if(R===null){for(;P<b.length;P++)R=d(m,b[P],T),R!==null&&(v=a(R,v,P),S===null?_=R:S.sibling=R,S=R);return tt&&za(m,P),_}for(R=r(m,R);P<b.length;P++)B=p(R,m,P,b[P],T),B!==null&&(e&&B.alternate!==null&&R.delete(B.key===null?P:B.key),v=a(B,v,P),S===null?_=B:S.sibling=B,S=B);return e&&R.forEach(function(H){return t(m,H)}),tt&&za(m,P),_}function w(m,v,b,T){var _=Al(b);if(typeof _!="function")throw Error(Y(150));if(b=_.call(b),b==null)throw Error(Y(151));for(var S=_=null,R=v,P=v=0,B=null,N=b.next();R!==null&&!N.done;P++,N=b.next()){R.index>P?(B=R,R=null):B=R.sibling;var H=f(m,R,N.value,T);if(H===null){R===null&&(R=B);break}e&&R&&H.alternate===null&&t(m,R),v=a(H,v,P),S===null?_=H:S.sibling=H,S=H,R=B}if(N.done)return n(m,R),tt&&za(m,P),_;if(R===null){for(;!N.done;P++,N=b.next())N=d(m,N.value,T),N!==null&&(v=a(N,v,P),S===null?_=N:S.sibling=N,S=N);return tt&&za(m,P),_}for(R=r(m,R);!N.done;P++,N=b.next())N=p(R,m,P,N.value,T),N!==null&&(e&&N.alternate!==null&&R.delete(N.key===null?P:N.key),v=a(N,v,P),S===null?_=N:S.sibling=N,S=N);return e&&R.forEach(function(U){return t(m,U)}),tt&&za(m,P),_}function x(m,v,b,T){if(typeof b=="object"&&b!==null&&b.type===Po&&b.key===null&&(b=b.props.children),typeof b=="object"&&b!==null){switch(b.$$typeof){case ld:e:{for(var _=b.key,S=v;S!==null;){if(S.key===_){if(_=b.type,_===Po){if(S.tag===7){n(m,S.sibling),v=i(S,b.props.children),v.return=m,m=v;break e}}else if(S.elementType===_||typeof _=="object"&&_!==null&&_.$$typeof===Li&&e2(_)===S.type){n(m,S.sibling),v=i(S,b.props),v.ref=tu(m,S,b),v.return=m,m=v;break e}n(m,S);break}else t(m,S);S=S.sibling}b.type===Po?(v=Ga(b.props.children,m.mode,T,b.key),v.return=m,m=v):(T=ff(b.type,b.key,b.props,null,m.mode,T),T.ref=tu(m,v,b),T.return=m,m=T)}return o(m);case Oo:e:{for(S=b.key;v!==null;){if(v.key===S)if(v.tag===4&&v.stateNode.containerInfo===b.containerInfo&&v.stateNode.implementation===b.implementation){n(m,v.sibling),v=i(v,b.children||[]),v.return=m,m=v;break e}else{n(m,v);break}else t(m,v);v=v.sibling}v=B0(b,m.mode,T),v.return=m,m=v}return o(m);case Li:return S=b._init,x(m,v,S(b._payload),T)}if(Nl(b))return g(m,v,b,T);if(Al(b))return w(m,v,b,T);Ud(m,b)}return typeof b=="string"&&b!==""||typeof b=="number"?(b=""+b,v!==null&&v.tag===6?(n(m,v.sibling),v=i(v,b),v.return=m,m=v):(n(m,v),v=F0(b,m.mode,T),v.return=m,m=v),o(m)):n(m,v)}return x}var Ko=t2(!0),n2=t2(!1),Hd=$i(null),Vd=null,Xo=null,qg=null;function Gg(){qg=Xo=Vd=null}function Kg(e){var t=Hd.current;Je(Hd),e._currentValue=t}function Xg(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Qo(e,t){Vd=e,qg=Xo=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(fn=!0),e.firstContext=null)}function zn(e){var t=e._currentValue;if(qg!==e)if(e={context:e,memoizedValue:t,next:null},Xo===null){if(Vd===null)throw Error(Y(308));Xo=e,Vd.dependencies={lanes:0,firstContext:e}}else Xo=Xo.next=e;return t}var Ua=null;function Qg(e){Ua===null?Ua=[e]:Ua.push(e)}function r2(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,Qg(t)):(n.next=i.next,i.next=n),t.interleaved=n,ai(e,r)}function ai(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var qi=!1;function Zg(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function i2(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function oi(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Gi(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Be&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,ai(e,n)}return i=r.interleaved,i===null?(t.next=t,Qg(r)):(t.next=i.next,i.next=t),r.interleaved=t,ai(e,n)}function $d(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,fg(e,n)}}function a2(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Wd(e,t,n,r){var i=e.updateQueue;qi=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var l=s,u=l.next;l.next=null,o===null?a=u:o.next=u,o=l;var c=e.alternate;c!==null&&(c=c.updateQueue,s=c.lastBaseUpdate,s!==o&&(s===null?c.firstBaseUpdate=u:s.next=u,c.lastBaseUpdate=l))}if(a!==null){var d=i.baseState;o=0,c=u=l=null,s=a;do{var f=s.lane,p=s.eventTime;if((r&f)===f){c!==null&&(c=c.next={eventTime:p,lane:0,tag:s.tag,payload:s.payload,callback:s.callback,next:null});e:{var g=e,w=s;switch(f=t,p=n,w.tag){case 1:if(g=w.payload,typeof g=="function"){d=g.call(p,d,f);break e}d=g;break e;case 3:g.flags=g.flags&-65537|128;case 0:if(g=w.payload,f=typeof g=="function"?g.call(p,d,f):g,f==null)break e;d=at({},d,f);break e;case 2:qi=!0}}s.callback!==null&&s.lane!==0&&(e.flags|=64,f=i.effects,f===null?i.effects=[s]:f.push(s))}else p={eventTime:p,lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},c===null?(u=c=p,l=d):c=c.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;f=s,s=f.next,f.next=null,i.lastBaseUpdate=f,i.shared.pending=null}}while(!0);if(c===null&&(l=d),i.baseState=l,i.firstBaseUpdate=u,i.lastBaseUpdate=c,t=i.shared.interleaved,t!==null){i=t;do o|=i.lane,i=i.next;while(i!==t)}else a===null&&(i.shared.lanes=0);$a|=o,e.lanes=o,e.memoizedState=d}}function o2(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],i=r.callback;if(i!==null){if(r.callback=null,r=n,typeof i!="function")throw Error(Y(191,i));i.call(r)}}}var nu={},Nr=$i(nu),ru=$i(nu),iu=$i(nu);function Ha(e){if(e===nu)throw Error(Y(174));return e}function Jg(e,t){switch(Xe(iu,t),Xe(ru,e),Xe(Nr,nu),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:eg(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=eg(t,e)}Je(Nr),Xe(Nr,t)}function Zo(){Je(Nr),Je(ru),Je(iu)}function s2(e){Ha(iu.current);var t=Ha(Nr.current),n=eg(t,e.type);t!==n&&(Xe(ru,e),Xe(Nr,n))}function e0(e){ru.current===e&&(Je(Nr),Je(ru))}var ot=$i(0);function Yd(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var t0=[];function n0(){for(var e=0;e<t0.length;e++)t0[e]._workInProgressVersionPrimary=null;t0.length=0}var qd=ei.ReactCurrentDispatcher,r0=ei.ReactCurrentBatchConfig,Va=0,st=null,Et=null,kt=null,Gd=!1,au=!1,ou=0,f9=0;function Ut(){throw Error(Y(321))}function i0(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!sr(e[n],t[n]))return!1;return!0}function a0(e,t,n,r,i,a){if(Va=a,st=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,qd.current=e===null||e.memoizedState===null?g9:w9,e=n(r,i),au){a=0;do{if(au=!1,ou=0,25<=a)throw Error(Y(301));a+=1,kt=Et=null,t.updateQueue=null,qd.current=y9,e=n(r,i)}while(au)}if(qd.current=Qd,t=Et!==null&&Et.next!==null,Va=0,kt=Et=st=null,Gd=!1,t)throw Error(Y(300));return e}function o0(){var e=ou!==0;return ou=0,e}function Or(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return kt===null?st.memoizedState=kt=e:kt=kt.next=e,kt}function Un(){if(Et===null){var e=st.alternate;e=e!==null?e.memoizedState:null}else e=Et.next;var t=kt===null?st.memoizedState:kt.next;if(t!==null)kt=t,Et=e;else{if(e===null)throw Error(Y(310));Et=e,e={memoizedState:Et.memoizedState,baseState:Et.baseState,baseQueue:Et.baseQueue,queue:Et.queue,next:null},kt===null?st.memoizedState=kt=e:kt=kt.next=e}return kt}function su(e,t){return typeof t=="function"?t(e):t}function s0(e){var t=Un(),n=t.queue;if(n===null)throw Error(Y(311));n.lastRenderedReducer=e;var r=Et,i=r.baseQueue,a=n.pending;if(a!==null){if(i!==null){var o=i.next;i.next=a.next,a.next=o}r.baseQueue=i=a,n.pending=null}if(i!==null){a=i.next,r=r.baseState;var s=o=null,l=null,u=a;do{var c=u.lane;if((Va&c)===c)l!==null&&(l=l.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),r=u.hasEagerState?u.eagerState:e(r,u.action);else{var d={lane:c,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};l===null?(s=l=d,o=r):l=l.next=d,st.lanes|=c,$a|=c}u=u.next}while(u!==null&&u!==a);l===null?o=r:l.next=s,sr(r,t.memoizedState)||(fn=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=l,n.lastRenderedState=r}if(e=n.interleaved,e!==null){i=e;do a=i.lane,st.lanes|=a,$a|=a,i=i.next;while(i!==e)}else i===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function l0(e){var t=Un(),n=t.queue;if(n===null)throw Error(Y(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,a=t.memoizedState;if(i!==null){n.pending=null;var o=i=i.next;do a=e(a,o.action),o=o.next;while(o!==i);sr(a,t.memoizedState)||(fn=!0),t.memoizedState=a,t.baseQueue===null&&(t.baseState=a),n.lastRenderedState=a}return[a,r]}function l2(){}function u2(e,t){var n=st,r=Un(),i=t(),a=!sr(r.memoizedState,i);if(a&&(r.memoizedState=i,fn=!0),r=r.queue,u0(f2.bind(null,n,r,e),[e]),r.getSnapshot!==t||a||kt!==null&&kt.memoizedState.tag&1){if(n.flags|=2048,lu(9,d2.bind(null,n,r,i,t),void 0,null),Ct===null)throw Error(Y(349));Va&30||c2(n,t,i)}return i}function c2(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=st.updateQueue,t===null?(t={lastEffect:null,stores:null},st.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function d2(e,t,n,r){t.value=n,t.getSnapshot=r,p2(t)&&h2(e)}function f2(e,t,n){return n(function(){p2(t)&&h2(e)})}function p2(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!sr(e,n)}catch{return!0}}function h2(e){var t=ai(e,1);t!==null&&fr(t,e,1,-1)}function m2(e){var t=Or();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:su,lastRenderedState:e},t.queue=e,e=e.dispatch=m9.bind(null,st,e),[t.memoizedState,e]}function lu(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=st.updateQueue,t===null?(t={lastEffect:null,stores:null},st.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function g2(){return Un().memoizedState}function Kd(e,t,n,r){var i=Or();st.flags|=e,i.memoizedState=lu(1|t,n,void 0,r===void 0?null:r)}function Xd(e,t,n,r){var i=Un();r=r===void 0?null:r;var a=void 0;if(Et!==null){var o=Et.memoizedState;if(a=o.destroy,r!==null&&i0(r,o.deps)){i.memoizedState=lu(t,n,a,r);return}}st.flags|=e,i.memoizedState=lu(1|t,n,a,r)}function w2(e,t){return Kd(8390656,8,e,t)}function u0(e,t){return Xd(2048,8,e,t)}function y2(e,t){return Xd(4,2,e,t)}function v2(e,t){return Xd(4,4,e,t)}function b2(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function x2(e,t,n){return n=n!=null?n.concat([e]):null,Xd(4,4,b2.bind(null,t,e),n)}function c0(){}function E2(e,t){var n=Un();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&i0(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function T2(e,t){var n=Un();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&i0(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function _2(e,t,n){return Va&21?(sr(n,t)||(n=eT(),st.lanes|=n,$a|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,fn=!0),e.memoizedState=n)}function p9(e,t){var n=$e;$e=n!==0&&4>n?n:4,e(!0);var r=r0.transition;r0.transition={};try{e(!1),t()}finally{$e=n,r0.transition=r}}function S2(){return Un().memoizedState}function h9(e,t,n){var r=Zi(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},k2(e))C2(t,n);else if(n=r2(e,t,n,r),n!==null){var i=nn();fr(n,e,r,i),A2(n,t,r)}}function m9(e,t,n){var r=Zi(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(k2(e))C2(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,sr(s,o)){var l=t.interleaved;l===null?(i.next=i,Qg(t)):(i.next=l.next,l.next=i),t.interleaved=i;return}}catch{}finally{}n=r2(e,t,i,r),n!==null&&(i=nn(),fr(n,e,r,i),A2(n,t,r))}}function k2(e){var t=e.alternate;return e===st||t!==null&&t===st}function C2(e,t){au=Gd=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function A2(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,fg(e,n)}}var Qd={readContext:zn,useCallback:Ut,useContext:Ut,useEffect:Ut,useImperativeHandle:Ut,useInsertionEffect:Ut,useLayoutEffect:Ut,useMemo:Ut,useReducer:Ut,useRef:Ut,useState:Ut,useDebugValue:Ut,useDeferredValue:Ut,useTransition:Ut,useMutableSource:Ut,useSyncExternalStore:Ut,useId:Ut,unstable_isNewReconciler:!1},g9={readContext:zn,useCallback:function(e,t){return Or().memoizedState=[e,t===void 0?null:t],e},useContext:zn,useEffect:w2,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Kd(4194308,4,b2.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Kd(4194308,4,e,t)},useInsertionEffect:function(e,t){return Kd(4,2,e,t)},useMemo:function(e,t){var n=Or();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Or();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=h9.bind(null,st,e),[r.memoizedState,e]},useRef:function(e){var t=Or();return e={current:e},t.memoizedState=e},useState:m2,useDebugValue:c0,useDeferredValue:function(e){return Or().memoizedState=e},useTransition:function(){var e=m2(!1),t=e[0];return e=p9.bind(null,e[1]),Or().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=st,i=Or();if(tt){if(n===void 0)throw Error(Y(407));n=n()}else{if(n=t(),Ct===null)throw Error(Y(349));Va&30||c2(r,t,n)}i.memoizedState=n;var a={value:n,getSnapshot:t};return i.queue=a,w2(f2.bind(null,r,a,e),[e]),r.flags|=2048,lu(9,d2.bind(null,r,a,n,t),void 0,null),n},useId:function(){var e=Or(),t=Ct.identifierPrefix;if(tt){var n=ii,r=ri;n=(r&~(1<<32-or(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=ou++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=f9++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},w9={readContext:zn,useCallback:E2,useContext:zn,useEffect:u0,useImperativeHandle:x2,useInsertionEffect:y2,useLayoutEffect:v2,useMemo:T2,useReducer:s0,useRef:g2,useState:function(){return s0(su)},useDebugValue:c0,useDeferredValue:function(e){var t=Un();return _2(t,Et.memoizedState,e)},useTransition:function(){var e=s0(su)[0],t=Un().memoizedState;return[e,t]},useMutableSource:l2,useSyncExternalStore:u2,useId:S2,unstable_isNewReconciler:!1},y9={readContext:zn,useCallback:E2,useContext:zn,useEffect:u0,useImperativeHandle:x2,useInsertionEffect:y2,useLayoutEffect:v2,useMemo:T2,useReducer:l0,useRef:g2,useState:function(){return l0(su)},useDebugValue:c0,useDeferredValue:function(e){var t=Un();return Et===null?t.memoizedState=e:_2(t,Et.memoizedState,e)},useTransition:function(){var e=l0(su)[0],t=Un().memoizedState;return[e,t]},useMutableSource:l2,useSyncExternalStore:u2,useId:S2,unstable_isNewReconciler:!1};function ur(e,t){if(e&&e.defaultProps){t=at({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function d0(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:at({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Zd={isMounted:function(e){return(e=e._reactInternals)?Ma(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=nn(),i=Zi(e),a=oi(r,i);a.payload=t,n!=null&&(a.callback=n),t=Gi(e,a,i),t!==null&&(fr(t,e,i,r),$d(t,e,i))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=nn(),i=Zi(e),a=oi(r,i);a.tag=1,a.payload=t,n!=null&&(a.callback=n),t=Gi(e,a,i),t!==null&&(fr(t,e,i,r),$d(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=nn(),r=Zi(e),i=oi(n,r);i.tag=2,t!=null&&(i.callback=t),t=Gi(e,i,r),t!==null&&(fr(t,e,r,n),$d(t,e,r))}};function R2(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!Gl(n,r)||!Gl(i,a):!0}function N2(e,t,n){var r=!1,i=Wi,a=t.contextType;return typeof a=="object"&&a!==null?a=zn(a):(i=dn(t)?Ba:zt.current,r=t.contextTypes,a=(r=r!=null)?Wo(e,i):Wi),t=new t(n,a),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Zd,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=a),t}function O2(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Zd.enqueueReplaceState(t,t.state,null)}function f0(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs={},Zg(e);var a=t.contextType;typeof a=="object"&&a!==null?i.context=zn(a):(a=dn(t)?Ba:zt.current,i.context=Wo(e,a)),i.state=e.memoizedState,a=t.getDerivedStateFromProps,typeof a=="function"&&(d0(e,t,a,n),i.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(t=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),t!==i.state&&Zd.enqueueReplaceState(i,i.state,null),Wd(e,n,i,r),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308)}function Jo(e,t){try{var n="",r=t;do n+=Y8(r),r=r.return;while(r);var i=n}catch(a){i=`
52
+ Error generating stack: `+a.message+`
53
+ `+a.stack}return{value:e,source:t,stack:i,digest:null}}function p0(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function h0(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var v9=typeof WeakMap=="function"?WeakMap:Map;function P2(e,t,n){n=oi(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){of||(of=!0,R0=r),h0(e,t)},n}function I2(e,t,n){n=oi(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var i=t.value;n.payload=function(){return r(i)},n.callback=function(){h0(e,t)}}var a=e.stateNode;return a!==null&&typeof a.componentDidCatch=="function"&&(n.callback=function(){h0(e,t),typeof r!="function"&&(Xi===null?Xi=new Set([this]):Xi.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function D2(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new v9;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(i.add(n),e=I9.bind(null,e,t,n),t.then(e,e))}function L2(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function M2(e,t,n,r,i){return e.mode&1?(e.flags|=65536,e.lanes=i,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=oi(-1,1),t.tag=2,Gi(n,t,1))),n.lanes|=1),e)}var b9=ei.ReactCurrentOwner,fn=!1;function tn(e,t,n,r){t.child=e===null?n2(t,null,n,r):Ko(t,e.child,n,r)}function F2(e,t,n,r,i){n=n.render;var a=t.ref;return Qo(t,i),r=a0(e,t,n,r,a,i),n=o0(),e!==null&&!fn?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,si(e,t,i)):(tt&&n&&Hg(t),t.flags|=1,tn(e,t,r,i),t.child)}function B2(e,t,n,r,i){if(e===null){var a=n.type;return typeof a=="function"&&!M0(a)&&a.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=a,j2(e,t,a,r,i)):(e=ff(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!(e.lanes&i)){var o=a.memoizedProps;if(n=n.compare,n=n!==null?n:Gl,n(o,r)&&e.ref===t.ref)return si(e,t,i)}return t.flags|=1,e=ea(a,r),e.ref=t.ref,e.return=t,t.child=e}function j2(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(Gl(a,r)&&e.ref===t.ref)if(fn=!1,t.pendingProps=r=a,(e.lanes&i)!==0)e.flags&131072&&(fn=!0);else return t.lanes=e.lanes,si(e,t,i)}return m0(e,t,n,r,i)}function z2(e,t,n){var r=t.pendingProps,i=r.children,a=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Xe(ts,Rn),Rn|=n;else{if(!(n&1073741824))return e=a!==null?a.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Xe(ts,Rn),Rn|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=a!==null?a.baseLanes:n,Xe(ts,Rn),Rn|=r}else a!==null?(r=a.baseLanes|n,t.memoizedState=null):r=n,Xe(ts,Rn),Rn|=r;return tn(e,t,i,n),t.child}function U2(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function m0(e,t,n,r,i){var a=dn(n)?Ba:zt.current;return a=Wo(t,a),Qo(t,i),n=a0(e,t,n,r,a,i),r=o0(),e!==null&&!fn?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,si(e,t,i)):(tt&&r&&Hg(t),t.flags|=1,tn(e,t,n,i),t.child)}function H2(e,t,n,r,i){if(dn(n)){var a=!0;Md(t)}else a=!1;if(Qo(t,i),t.stateNode===null)ef(e,t),N2(t,n,r),f0(t,n,r,i),r=!0;else if(e===null){var o=t.stateNode,s=t.memoizedProps;o.props=s;var l=o.context,u=n.contextType;typeof u=="object"&&u!==null?u=zn(u):(u=dn(n)?Ba:zt.current,u=Wo(t,u));var c=n.getDerivedStateFromProps,d=typeof c=="function"||typeof o.getSnapshotBeforeUpdate=="function";d||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(s!==r||l!==u)&&O2(t,o,r,u),qi=!1;var f=t.memoizedState;o.state=f,Wd(t,r,o,i),l=t.memoizedState,s!==r||f!==l||cn.current||qi?(typeof c=="function"&&(d0(t,n,c,r),l=t.memoizedState),(s=qi||R2(t,n,s,r,f,l,u))?(d||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(t.flags|=4194308)):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),o.props=r,o.state=l,o.context=u,r=s):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,i2(e,t),s=t.memoizedProps,u=t.type===t.elementType?s:ur(t.type,s),o.props=u,d=t.pendingProps,f=o.context,l=n.contextType,typeof l=="object"&&l!==null?l=zn(l):(l=dn(n)?Ba:zt.current,l=Wo(t,l));var p=n.getDerivedStateFromProps;(c=typeof p=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(s!==d||f!==l)&&O2(t,o,r,l),qi=!1,f=t.memoizedState,o.state=f,Wd(t,r,o,i);var g=t.memoizedState;s!==d||f!==g||cn.current||qi?(typeof p=="function"&&(d0(t,n,p,r),g=t.memoizedState),(u=qi||R2(t,n,u,r,f,g,l)||!1)?(c||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,g,l),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,g,l)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=g),o.props=r,o.state=g,o.context=l,r=u):(typeof o.componentDidUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return g0(e,t,n,r,a,i)}function g0(e,t,n,r,i,a){U2(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return i&&qT(t,n,!1),si(e,t,a);r=t.stateNode,b9.current=t;var s=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=Ko(t,e.child,null,a),t.child=Ko(t,null,s,a)):tn(e,t,s,a),t.memoizedState=r.state,i&&qT(t,n,!0),t.child}function V2(e){var t=e.stateNode;t.pendingContext?WT(e,t.pendingContext,t.pendingContext!==t.context):t.context&&WT(e,t.context,!1),Jg(e,t.containerInfo)}function $2(e,t,n,r,i){return Go(),Yg(i),t.flags|=256,tn(e,t,n,r),t.child}var w0={dehydrated:null,treeContext:null,retryLane:0};function y0(e){return{baseLanes:e,cachePool:null,transitions:null}}function W2(e,t,n){var r=t.pendingProps,i=ot.current,a=!1,o=(t.flags&128)!==0,s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:(i&2)!==0),s?(a=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),Xe(ot,i&1),e===null)return Wg(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(o=r.children,e=r.fallback,a?(r=t.mode,a=t.child,o={mode:"hidden",children:o},!(r&1)&&a!==null?(a.childLanes=0,a.pendingProps=o):a=pf(o,r,0,null),e=Ga(e,r,n,null),a.return=t,e.return=t,a.sibling=e,t.child=a,t.child.memoizedState=y0(n),t.memoizedState=w0,e):v0(t,o));if(i=e.memoizedState,i!==null&&(s=i.dehydrated,s!==null))return x9(e,t,o,r,s,i,n);if(a){a=r.fallback,o=t.mode,i=e.child,s=i.sibling;var l={mode:"hidden",children:r.children};return!(o&1)&&t.child!==i?(r=t.child,r.childLanes=0,r.pendingProps=l,t.deletions=null):(r=ea(i,l),r.subtreeFlags=i.subtreeFlags&14680064),s!==null?a=ea(s,a):(a=Ga(a,o,n,null),a.flags|=2),a.return=t,r.return=t,r.sibling=a,t.child=r,r=a,a=t.child,o=e.child.memoizedState,o=o===null?y0(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},a.memoizedState=o,a.childLanes=e.childLanes&~n,t.memoizedState=w0,r}return a=e.child,e=a.sibling,r=ea(a,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function v0(e,t){return t=pf({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Jd(e,t,n,r){return r!==null&&Yg(r),Ko(t,e.child,null,n),e=v0(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function x9(e,t,n,r,i,a,o){if(n)return t.flags&256?(t.flags&=-257,r=p0(Error(Y(422))),Jd(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(a=r.fallback,i=t.mode,r=pf({mode:"visible",children:r.children},i,0,null),a=Ga(a,i,o,null),a.flags|=2,r.return=t,a.return=t,r.sibling=a,t.child=r,t.mode&1&&Ko(t,e.child,null,o),t.child.memoizedState=y0(o),t.memoizedState=w0,a);if(!(t.mode&1))return Jd(e,t,o,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var s=r.dgst;return r=s,a=Error(Y(419)),r=p0(a,r,void 0),Jd(e,t,o,r)}if(s=(o&e.childLanes)!==0,fn||s){if(r=Ct,r!==null){switch(o&-o){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(r.suspendedLanes|o)?0:i,i!==0&&i!==a.retryLane&&(a.retryLane=i,ai(e,i),fr(r,e,i,-1))}return L0(),r=p0(Error(Y(421))),Jd(e,t,o,r)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=D9.bind(null,e),i._reactRetry=t,null):(e=a.treeContext,An=Vi(i.nextSibling),Cn=t,tt=!0,lr=null,e!==null&&(Bn[jn++]=ri,Bn[jn++]=ii,Bn[jn++]=ja,ri=e.id,ii=e.overflow,ja=t),t=v0(t,r.children),t.flags|=4096,t)}function Y2(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Xg(e.return,t,n)}function b0(e,t,n,r,i){var a=e.memoizedState;a===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=r,a.tail=n,a.tailMode=i)}function q2(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;if(tn(e,t,r.children,n),r=ot.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Y2(e,n,t);else if(e.tag===19)Y2(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(Xe(ot,r),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&Yd(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),b0(t,!1,i,n,a);break;case"backwards":for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&Yd(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}b0(t,!0,n,null,a);break;case"together":b0(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function ef(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function si(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),$a|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(Y(153));if(t.child!==null){for(e=t.child,n=ea(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=ea(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function E9(e,t,n){switch(t.tag){case 3:V2(t),Go();break;case 5:s2(t);break;case 1:dn(t.type)&&Md(t);break;case 4:Jg(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,i=t.memoizedProps.value;Xe(Hd,r._currentValue),r._currentValue=i;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(Xe(ot,ot.current&1),t.flags|=128,null):n&t.child.childLanes?W2(e,t,n):(Xe(ot,ot.current&1),e=si(e,t,n),e!==null?e.sibling:null);Xe(ot,ot.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return q2(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),Xe(ot,ot.current),r)break;return null;case 22:case 23:return t.lanes=0,z2(e,t,n)}return si(e,t,n)}var G2,x0,K2,X2;G2=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},x0=function(){},K2=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,Ha(Nr.current);var a=null;switch(n){case"input":i=Xm(e,i),r=Xm(e,r),a=[];break;case"select":i=at({},i,{value:void 0}),r=at({},r,{value:void 0}),a=[];break;case"textarea":i=Jm(e,i),r=Jm(e,r),a=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Id)}tg(n,r);var o;n=null;for(u in i)if(!r.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var s=i[u];for(o in s)s.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(Cl.hasOwnProperty(u)?a||(a=[]):(a=a||[]).push(u,null));for(u in r){var l=r[u];if(s=i!=null?i[u]:void 0,r.hasOwnProperty(u)&&l!==s&&(l!=null||s!=null))if(u==="style")if(s){for(o in s)!s.hasOwnProperty(o)||l&&l.hasOwnProperty(o)||(n||(n={}),n[o]="");for(o in l)l.hasOwnProperty(o)&&s[o]!==l[o]&&(n||(n={}),n[o]=l[o])}else n||(a||(a=[]),a.push(u,n)),n=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,s=s?s.__html:void 0,l!=null&&s!==l&&(a=a||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(a=a||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(Cl.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&Ze("scroll",e),a||s===l||(a=[])):(a=a||[]).push(u,l))}n&&(a=a||[]).push("style",n);var u=a;(t.updateQueue=u)&&(t.flags|=4)}},X2=function(e,t,n,r){n!==r&&(t.flags|=4)};function uu(e,t){if(!tt)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Ht(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&14680064,r|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function T9(e,t,n){var r=t.pendingProps;switch(Vg(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ht(t),null;case 1:return dn(t.type)&&Ld(),Ht(t),null;case 3:return r=t.stateNode,Zo(),Je(cn),Je(zt),n0(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(zd(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,lr!==null&&(P0(lr),lr=null))),x0(e,t),Ht(t),null;case 5:e0(t);var i=Ha(iu.current);if(n=t.type,e!==null&&t.stateNode!=null)K2(e,t,n,r,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(Y(166));return Ht(t),null}if(e=Ha(Nr.current),zd(t)){r=t.stateNode,n=t.type;var a=t.memoizedProps;switch(r[Rr]=t,r[Jl]=a,e=(t.mode&1)!==0,n){case"dialog":Ze("cancel",r),Ze("close",r);break;case"iframe":case"object":case"embed":Ze("load",r);break;case"video":case"audio":for(i=0;i<Xl.length;i++)Ze(Xl[i],r);break;case"source":Ze("error",r);break;case"img":case"image":case"link":Ze("error",r),Ze("load",r);break;case"details":Ze("toggle",r);break;case"input":NE(r,a),Ze("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!a.multiple},Ze("invalid",r);break;case"textarea":IE(r,a),Ze("invalid",r)}tg(n,a),i=null;for(var o in a)if(a.hasOwnProperty(o)){var s=a[o];o==="children"?typeof s=="string"?r.textContent!==s&&(a.suppressHydrationWarning!==!0&&Pd(r.textContent,s,e),i=["children",s]):typeof s=="number"&&r.textContent!==""+s&&(a.suppressHydrationWarning!==!0&&Pd(r.textContent,s,e),i=["children",""+s]):Cl.hasOwnProperty(o)&&s!=null&&o==="onScroll"&&Ze("scroll",r)}switch(n){case"input":ud(r),PE(r,a,!0);break;case"textarea":ud(r),LE(r);break;case"select":case"option":break;default:typeof a.onClick=="function"&&(r.onclick=Id)}r=i,t.updateQueue=r,r!==null&&(t.flags|=4)}else{o=i.nodeType===9?i:i.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=ME(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=o.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[Rr]=t,e[Jl]=r,G2(e,t,!1,!1),t.stateNode=e;e:{switch(o=ng(n,r),n){case"dialog":Ze("cancel",e),Ze("close",e),i=r;break;case"iframe":case"object":case"embed":Ze("load",e),i=r;break;case"video":case"audio":for(i=0;i<Xl.length;i++)Ze(Xl[i],e);i=r;break;case"source":Ze("error",e),i=r;break;case"img":case"image":case"link":Ze("error",e),Ze("load",e),i=r;break;case"details":Ze("toggle",e),i=r;break;case"input":NE(e,r),i=Xm(e,r),Ze("invalid",e);break;case"option":i=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},i=at({},r,{value:void 0}),Ze("invalid",e);break;case"textarea":IE(e,r),i=Jm(e,r),Ze("invalid",e);break;default:i=r}tg(n,i),s=i;for(a in s)if(s.hasOwnProperty(a)){var l=s[a];a==="style"?jE(e,l):a==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&FE(e,l)):a==="children"?typeof l=="string"?(n!=="textarea"||l!=="")&&Ol(e,l):typeof l=="number"&&Ol(e,""+l):a!=="suppressContentEditableWarning"&&a!=="suppressHydrationWarning"&&a!=="autoFocus"&&(Cl.hasOwnProperty(a)?l!=null&&a==="onScroll"&&Ze("scroll",e):l!=null&&jm(e,a,l,o))}switch(n){case"input":ud(e),PE(e,r,!1);break;case"textarea":ud(e),LE(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Mi(r.value));break;case"select":e.multiple=!!r.multiple,a=r.value,a!=null?Io(e,!!r.multiple,a,!1):r.defaultValue!=null&&Io(e,!!r.multiple,r.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=Id)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return Ht(t),null;case 6:if(e&&t.stateNode!=null)X2(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(Y(166));if(n=Ha(iu.current),Ha(Nr.current),zd(t)){if(r=t.stateNode,n=t.memoizedProps,r[Rr]=t,(a=r.nodeValue!==n)&&(e=Cn,e!==null))switch(e.tag){case 3:Pd(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Pd(r.nodeValue,n,(e.mode&1)!==0)}a&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[Rr]=t,t.stateNode=r}return Ht(t),null;case 13:if(Je(ot),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(tt&&An!==null&&t.mode&1&&!(t.flags&128))JT(),Go(),t.flags|=98560,a=!1;else if(a=zd(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(Y(318));if(a=t.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(Y(317));a[Rr]=t}else Go(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ht(t),a=!1}else lr!==null&&(P0(lr),lr=null),a=!0;if(!a)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,t.mode&1&&(e===null||ot.current&1?Tt===0&&(Tt=3):L0())),t.updateQueue!==null&&(t.flags|=4),Ht(t),null);case 4:return Zo(),x0(e,t),e===null&&Ql(t.stateNode.containerInfo),Ht(t),null;case 10:return Kg(t.type._context),Ht(t),null;case 17:return dn(t.type)&&Ld(),Ht(t),null;case 19:if(Je(ot),a=t.memoizedState,a===null)return Ht(t),null;if(r=(t.flags&128)!==0,o=a.rendering,o===null)if(r)uu(a,!1);else{if(Tt!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=Yd(e),o!==null){for(t.flags|=128,uu(a,!1),r=o.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)a=n,e=r,a.flags&=14680066,o=a.alternate,o===null?(a.childLanes=0,a.lanes=e,a.child=null,a.subtreeFlags=0,a.memoizedProps=null,a.memoizedState=null,a.updateQueue=null,a.dependencies=null,a.stateNode=null):(a.childLanes=o.childLanes,a.lanes=o.lanes,a.child=o.child,a.subtreeFlags=0,a.deletions=null,a.memoizedProps=o.memoizedProps,a.memoizedState=o.memoizedState,a.updateQueue=o.updateQueue,a.type=o.type,e=o.dependencies,a.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return Xe(ot,ot.current&1|2),t.child}e=e.sibling}a.tail!==null&&ft()>ns&&(t.flags|=128,r=!0,uu(a,!1),t.lanes=4194304)}else{if(!r)if(e=Yd(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),uu(a,!0),a.tail===null&&a.tailMode==="hidden"&&!o.alternate&&!tt)return Ht(t),null}else 2*ft()-a.renderingStartTime>ns&&n!==1073741824&&(t.flags|=128,r=!0,uu(a,!1),t.lanes=4194304);a.isBackwards?(o.sibling=t.child,t.child=o):(n=a.last,n!==null?n.sibling=o:t.child=o,a.last=o)}return a.tail!==null?(t=a.tail,a.rendering=t,a.tail=t.sibling,a.renderingStartTime=ft(),t.sibling=null,n=ot.current,Xe(ot,r?n&1|2:n&1),t):(Ht(t),null);case 22:case 23:return D0(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Rn&1073741824&&(Ht(t),t.subtreeFlags&6&&(t.flags|=8192)):Ht(t),null;case 24:return null;case 25:return null}throw Error(Y(156,t.tag))}function _9(e,t){switch(Vg(t),t.tag){case 1:return dn(t.type)&&Ld(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Zo(),Je(cn),Je(zt),n0(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return e0(t),null;case 13:if(Je(ot),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(Y(340));Go()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Je(ot),null;case 4:return Zo(),null;case 10:return Kg(t.type._context),null;case 22:case 23:return D0(),null;case 24:return null;default:return null}}var tf=!1,Vt=!1,S9=typeof WeakSet=="function"?WeakSet:Set,ae=null;function es(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){ct(e,t,r)}else n.current=null}function E0(e,t,n){try{n()}catch(r){ct(e,t,r)}}var Q2=!1;function k9(e,t){if(Dg=xd,e=RT(),kg(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,a=r.focusNode;r=r.focusOffset;try{n.nodeType,a.nodeType}catch{n=null;break e}var o=0,s=-1,l=-1,u=0,c=0,d=e,f=null;t:for(;;){for(var p;d!==n||i!==0&&d.nodeType!==3||(s=o+i),d!==a||r!==0&&d.nodeType!==3||(l=o+r),d.nodeType===3&&(o+=d.nodeValue.length),(p=d.firstChild)!==null;)f=d,d=p;for(;;){if(d===e)break t;if(f===n&&++u===i&&(s=o),f===a&&++c===r&&(l=o),(p=d.nextSibling)!==null)break;d=f,f=d.parentNode}d=p}n=s===-1||l===-1?null:{start:s,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Lg={focusedElem:e,selectionRange:n},xd=!1,ae=t;ae!==null;)if(t=ae,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,ae=e;else for(;ae!==null;){t=ae;try{var g=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(g!==null){var w=g.memoizedProps,x=g.memoizedState,m=t.stateNode,v=m.getSnapshotBeforeUpdate(t.elementType===t.type?w:ur(t.type,w),x);m.__reactInternalSnapshotBeforeUpdate=v}break;case 3:var b=t.stateNode.containerInfo;b.nodeType===1?b.textContent="":b.nodeType===9&&b.documentElement&&b.removeChild(b.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(Y(163))}}catch(T){ct(t,t.return,T)}if(e=t.sibling,e!==null){e.return=t.return,ae=e;break}ae=t.return}return g=Q2,Q2=!1,g}function cu(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var a=i.destroy;i.destroy=void 0,a!==void 0&&E0(t,n,a)}i=i.next}while(i!==r)}}function nf(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function T0(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function Z2(e){var t=e.alternate;t!==null&&(e.alternate=null,Z2(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Rr],delete t[Jl],delete t[jg],delete t[l9],delete t[u9])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function J2(e){return e.tag===5||e.tag===3||e.tag===4}function e_(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||J2(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function _0(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Id));else if(r!==4&&(e=e.child,e!==null))for(_0(e,t,n),e=e.sibling;e!==null;)_0(e,t,n),e=e.sibling}function S0(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(S0(e,t,n),e=e.sibling;e!==null;)S0(e,t,n),e=e.sibling}var Pt=null,cr=!1;function Ki(e,t,n){for(n=n.child;n!==null;)t_(e,t,n),n=n.sibling}function t_(e,t,n){if(Ar&&typeof Ar.onCommitFiberUnmount=="function")try{Ar.onCommitFiberUnmount(md,n)}catch{}switch(n.tag){case 5:Vt||es(n,t);case 6:var r=Pt,i=cr;Pt=null,Ki(e,t,n),Pt=r,cr=i,Pt!==null&&(cr?(e=Pt,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Pt.removeChild(n.stateNode));break;case 18:Pt!==null&&(cr?(e=Pt,n=n.stateNode,e.nodeType===8?Bg(e.parentNode,n):e.nodeType===1&&Bg(e,n),Hl(e)):Bg(Pt,n.stateNode));break;case 4:r=Pt,i=cr,Pt=n.stateNode.containerInfo,cr=!0,Ki(e,t,n),Pt=r,cr=i;break;case 0:case 11:case 14:case 15:if(!Vt&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var a=i,o=a.destroy;a=a.tag,o!==void 0&&(a&2||a&4)&&E0(n,t,o),i=i.next}while(i!==r)}Ki(e,t,n);break;case 1:if(!Vt&&(es(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(s){ct(n,t,s)}Ki(e,t,n);break;case 21:Ki(e,t,n);break;case 22:n.mode&1?(Vt=(r=Vt)||n.memoizedState!==null,Ki(e,t,n),Vt=r):Ki(e,t,n);break;default:Ki(e,t,n)}}function n_(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new S9),t.forEach(function(r){var i=L9.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function dr(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r];try{var a=e,o=t,s=o;e:for(;s!==null;){switch(s.tag){case 5:Pt=s.stateNode,cr=!1;break e;case 3:Pt=s.stateNode.containerInfo,cr=!0;break e;case 4:Pt=s.stateNode.containerInfo,cr=!0;break e}s=s.return}if(Pt===null)throw Error(Y(160));t_(a,o,i),Pt=null,cr=!1;var l=i.alternate;l!==null&&(l.return=null),i.return=null}catch(u){ct(i,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)r_(t,e),t=t.sibling}function r_(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(dr(t,e),Pr(e),r&4){try{cu(3,e,e.return),nf(3,e)}catch(w){ct(e,e.return,w)}try{cu(5,e,e.return)}catch(w){ct(e,e.return,w)}}break;case 1:dr(t,e),Pr(e),r&512&&n!==null&&es(n,n.return);break;case 5:if(dr(t,e),Pr(e),r&512&&n!==null&&es(n,n.return),e.flags&32){var i=e.stateNode;try{Ol(i,"")}catch(w){ct(e,e.return,w)}}if(r&4&&(i=e.stateNode,i!=null)){var a=e.memoizedProps,o=n!==null?n.memoizedProps:a,s=e.type,l=e.updateQueue;if(e.updateQueue=null,l!==null)try{s==="input"&&a.type==="radio"&&a.name!=null&&OE(i,a),ng(s,o);var u=ng(s,a);for(o=0;o<l.length;o+=2){var c=l[o],d=l[o+1];c==="style"?jE(i,d):c==="dangerouslySetInnerHTML"?FE(i,d):c==="children"?Ol(i,d):jm(i,c,d,u)}switch(s){case"input":Qm(i,a);break;case"textarea":DE(i,a);break;case"select":var f=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!a.multiple;var p=a.value;p!=null?Io(i,!!a.multiple,p,!1):f!==!!a.multiple&&(a.defaultValue!=null?Io(i,!!a.multiple,a.defaultValue,!0):Io(i,!!a.multiple,a.multiple?[]:"",!1))}i[Jl]=a}catch(w){ct(e,e.return,w)}}break;case 6:if(dr(t,e),Pr(e),r&4){if(e.stateNode===null)throw Error(Y(162));i=e.stateNode,a=e.memoizedProps;try{i.nodeValue=a}catch(w){ct(e,e.return,w)}}break;case 3:if(dr(t,e),Pr(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Hl(t.containerInfo)}catch(w){ct(e,e.return,w)}break;case 4:dr(t,e),Pr(e);break;case 13:dr(t,e),Pr(e),i=e.child,i.flags&8192&&(a=i.memoizedState!==null,i.stateNode.isHidden=a,!a||i.alternate!==null&&i.alternate.memoizedState!==null||(A0=ft())),r&4&&n_(e);break;case 22:if(c=n!==null&&n.memoizedState!==null,e.mode&1?(Vt=(u=Vt)||c,dr(t,e),Vt=u):dr(t,e),Pr(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!c&&e.mode&1)for(ae=e,c=e.child;c!==null;){for(d=ae=c;ae!==null;){switch(f=ae,p=f.child,f.tag){case 0:case 11:case 14:case 15:cu(4,f,f.return);break;case 1:es(f,f.return);var g=f.stateNode;if(typeof g.componentWillUnmount=="function"){r=f,n=f.return;try{t=r,g.props=t.memoizedProps,g.state=t.memoizedState,g.componentWillUnmount()}catch(w){ct(r,n,w)}}break;case 5:es(f,f.return);break;case 22:if(f.memoizedState!==null){o_(d);continue}}p!==null?(p.return=f,ae=p):o_(d)}c=c.sibling}e:for(c=null,d=e;;){if(d.tag===5){if(c===null){c=d;try{i=d.stateNode,u?(a=i.style,typeof a.setProperty=="function"?a.setProperty("display","none","important"):a.display="none"):(s=d.stateNode,l=d.memoizedProps.style,o=l!=null&&l.hasOwnProperty("display")?l.display:null,s.style.display=BE("display",o))}catch(w){ct(e,e.return,w)}}}else if(d.tag===6){if(c===null)try{d.stateNode.nodeValue=u?"":d.memoizedProps}catch(w){ct(e,e.return,w)}}else if((d.tag!==22&&d.tag!==23||d.memoizedState===null||d===e)&&d.child!==null){d.child.return=d,d=d.child;continue}if(d===e)break e;for(;d.sibling===null;){if(d.return===null||d.return===e)break e;c===d&&(c=null),d=d.return}c===d&&(c=null),d.sibling.return=d.return,d=d.sibling}}break;case 19:dr(t,e),Pr(e),r&4&&n_(e);break;case 21:break;default:dr(t,e),Pr(e)}}function Pr(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(J2(n)){var r=n;break e}n=n.return}throw Error(Y(160))}switch(r.tag){case 5:var i=r.stateNode;r.flags&32&&(Ol(i,""),r.flags&=-33);var a=e_(e);S0(e,a,i);break;case 3:case 4:var o=r.stateNode.containerInfo,s=e_(e);_0(e,s,o);break;default:throw Error(Y(161))}}catch(l){ct(e,e.return,l)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function C9(e,t,n){ae=e,i_(e)}function i_(e,t,n){for(var r=(e.mode&1)!==0;ae!==null;){var i=ae,a=i.child;if(i.tag===22&&r){var o=i.memoizedState!==null||tf;if(!o){var s=i.alternate,l=s!==null&&s.memoizedState!==null||Vt;s=tf;var u=Vt;if(tf=o,(Vt=l)&&!u)for(ae=i;ae!==null;)o=ae,l=o.child,o.tag===22&&o.memoizedState!==null?s_(i):l!==null?(l.return=o,ae=l):s_(i);for(;a!==null;)ae=a,i_(a),a=a.sibling;ae=i,tf=s,Vt=u}a_(e)}else i.subtreeFlags&8772&&a!==null?(a.return=i,ae=a):a_(e)}}function a_(e){for(;ae!==null;){var t=ae;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Vt||nf(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!Vt)if(n===null)r.componentDidMount();else{var i=t.elementType===t.type?n.memoizedProps:ur(t.type,n.memoizedProps);r.componentDidUpdate(i,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var a=t.updateQueue;a!==null&&o2(t,a,r);break;case 3:var o=t.updateQueue;if(o!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}o2(t,o,n)}break;case 5:var s=t.stateNode;if(n===null&&t.flags&4){n=s;var l=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break;case"img":l.src&&(n.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var u=t.alternate;if(u!==null){var c=u.memoizedState;if(c!==null){var d=c.dehydrated;d!==null&&Hl(d)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(Y(163))}Vt||t.flags&512&&T0(t)}catch(f){ct(t,t.return,f)}}if(t===e){ae=null;break}if(n=t.sibling,n!==null){n.return=t.return,ae=n;break}ae=t.return}}function o_(e){for(;ae!==null;){var t=ae;if(t===e){ae=null;break}var n=t.sibling;if(n!==null){n.return=t.return,ae=n;break}ae=t.return}}function s_(e){for(;ae!==null;){var t=ae;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{nf(4,t)}catch(l){ct(t,n,l)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var i=t.return;try{r.componentDidMount()}catch(l){ct(t,i,l)}}var a=t.return;try{T0(t)}catch(l){ct(t,a,l)}break;case 5:var o=t.return;try{T0(t)}catch(l){ct(t,o,l)}}}catch(l){ct(t,t.return,l)}if(t===e){ae=null;break}var s=t.sibling;if(s!==null){s.return=t.return,ae=s;break}ae=t.return}}var A9=Math.ceil,rf=ei.ReactCurrentDispatcher,k0=ei.ReactCurrentOwner,Hn=ei.ReactCurrentBatchConfig,Be=0,Ct=null,wt=null,It=0,Rn=0,ts=$i(0),Tt=0,du=null,$a=0,af=0,C0=0,fu=null,pn=null,A0=0,ns=1/0,li=null,of=!1,R0=null,Xi=null,sf=!1,Qi=null,lf=0,pu=0,N0=null,uf=-1,cf=0;function nn(){return Be&6?ft():uf!==-1?uf:uf=ft()}function Zi(e){return e.mode&1?Be&2&&It!==0?It&-It:d9.transition!==null?(cf===0&&(cf=eT()),cf):(e=$e,e!==0||(e=window.event,e=e===void 0?16:uT(e.type)),e):1}function fr(e,t,n,r){if(50<pu)throw pu=0,N0=null,Error(Y(185));Fl(e,n,r),(!(Be&2)||e!==Ct)&&(e===Ct&&(!(Be&2)&&(af|=n),Tt===4&&Ji(e,It)),hn(e,r),n===1&&Be===0&&!(t.mode&1)&&(ns=ft()+500,Fd&&Yi()))}function hn(e,t){var n=e.callbackNode;dF(e,t);var r=yd(e,e===Ct?It:0);if(r===0)n!==null&&QE(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&QE(n),t===1)e.tag===0?c9(u_.bind(null,e)):GT(u_.bind(null,e)),o9(function(){!(Be&6)&&Yi()}),n=null;else{switch(tT(r)){case 1:n=ug;break;case 4:n=ZE;break;case 16:n=hd;break;case 536870912:n=JE;break;default:n=hd}n=w_(n,l_.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function l_(e,t){if(uf=-1,cf=0,Be&6)throw Error(Y(327));var n=e.callbackNode;if(rs()&&e.callbackNode!==n)return null;var r=yd(e,e===Ct?It:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=df(e,r);else{t=r;var i=Be;Be|=2;var a=d_();(Ct!==e||It!==t)&&(li=null,ns=ft()+500,Ya(e,t));do try{O9();break}catch(s){c_(e,s)}while(!0);Gg(),rf.current=a,Be=i,wt!==null?t=0:(Ct=null,It=0,t=Tt)}if(t!==0){if(t===2&&(i=cg(e),i!==0&&(r=i,t=O0(e,i))),t===1)throw n=du,Ya(e,0),Ji(e,r),hn(e,ft()),n;if(t===6)Ji(e,r);else{if(i=e.current.alternate,!(r&30)&&!R9(i)&&(t=df(e,r),t===2&&(a=cg(e),a!==0&&(r=a,t=O0(e,a))),t===1))throw n=du,Ya(e,0),Ji(e,r),hn(e,ft()),n;switch(e.finishedWork=i,e.finishedLanes=r,t){case 0:case 1:throw Error(Y(345));case 2:qa(e,pn,li);break;case 3:if(Ji(e,r),(r&130023424)===r&&(t=A0+500-ft(),10<t)){if(yd(e,0)!==0)break;if(i=e.suspendedLanes,(i&r)!==r){nn(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=Fg(qa.bind(null,e,pn,li),t);break}qa(e,pn,li);break;case 4:if(Ji(e,r),(r&4194240)===r)break;for(t=e.eventTimes,i=-1;0<r;){var o=31-or(r);a=1<<o,o=t[o],o>i&&(i=o),r&=~a}if(r=i,r=ft()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*A9(r/1960))-r,10<r){e.timeoutHandle=Fg(qa.bind(null,e,pn,li),r);break}qa(e,pn,li);break;case 5:qa(e,pn,li);break;default:throw Error(Y(329))}}}return hn(e,ft()),e.callbackNode===n?l_.bind(null,e):null}function O0(e,t){var n=fu;return e.current.memoizedState.isDehydrated&&(Ya(e,t).flags|=256),e=df(e,t),e!==2&&(t=pn,pn=n,t!==null&&P0(t)),e}function P0(e){pn===null?pn=e:pn.push.apply(pn,e)}function R9(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!sr(a(),i))return!1}catch{return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Ji(e,t){for(t&=~C0,t&=~af,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-or(t),r=1<<n;e[n]=-1,t&=~r}}function u_(e){if(Be&6)throw Error(Y(327));rs();var t=yd(e,0);if(!(t&1))return hn(e,ft()),null;var n=df(e,t);if(e.tag!==0&&n===2){var r=cg(e);r!==0&&(t=r,n=O0(e,r))}if(n===1)throw n=du,Ya(e,0),Ji(e,t),hn(e,ft()),n;if(n===6)throw Error(Y(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,qa(e,pn,li),hn(e,ft()),null}function I0(e,t){var n=Be;Be|=1;try{return e(t)}finally{Be=n,Be===0&&(ns=ft()+500,Fd&&Yi())}}function Wa(e){Qi!==null&&Qi.tag===0&&!(Be&6)&&rs();var t=Be;Be|=1;var n=Hn.transition,r=$e;try{if(Hn.transition=null,$e=1,e)return e()}finally{$e=r,Hn.transition=n,Be=t,!(Be&6)&&Yi()}}function D0(){Rn=ts.current,Je(ts)}function Ya(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,a9(n)),wt!==null)for(n=wt.return;n!==null;){var r=n;switch(Vg(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Ld();break;case 3:Zo(),Je(cn),Je(zt),n0();break;case 5:e0(r);break;case 4:Zo();break;case 13:Je(ot);break;case 19:Je(ot);break;case 10:Kg(r.type._context);break;case 22:case 23:D0()}n=n.return}if(Ct=e,wt=e=ea(e.current,null),It=Rn=t,Tt=0,du=null,C0=af=$a=0,pn=fu=null,Ua!==null){for(t=0;t<Ua.length;t++)if(n=Ua[t],r=n.interleaved,r!==null){n.interleaved=null;var i=r.next,a=n.pending;if(a!==null){var o=a.next;a.next=i,r.next=o}n.pending=r}Ua=null}return e}function c_(e,t){do{var n=wt;try{if(Gg(),qd.current=Qd,Gd){for(var r=st.memoizedState;r!==null;){var i=r.queue;i!==null&&(i.pending=null),r=r.next}Gd=!1}if(Va=0,kt=Et=st=null,au=!1,ou=0,k0.current=null,n===null||n.return===null){Tt=1,du=t,wt=null;break}e:{var a=e,o=n.return,s=n,l=t;if(t=It,s.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l,c=s,d=c.tag;if(!(c.mode&1)&&(d===0||d===11||d===15)){var f=c.alternate;f?(c.updateQueue=f.updateQueue,c.memoizedState=f.memoizedState,c.lanes=f.lanes):(c.updateQueue=null,c.memoizedState=null)}var p=L2(o);if(p!==null){p.flags&=-257,M2(p,o,s,a,t),p.mode&1&&D2(a,u,t),t=p,l=u;var g=t.updateQueue;if(g===null){var w=new Set;w.add(l),t.updateQueue=w}else g.add(l);break e}else{if(!(t&1)){D2(a,u,t),L0();break e}l=Error(Y(426))}}else if(tt&&s.mode&1){var x=L2(o);if(x!==null){!(x.flags&65536)&&(x.flags|=256),M2(x,o,s,a,t),Yg(Jo(l,s));break e}}a=l=Jo(l,s),Tt!==4&&(Tt=2),fu===null?fu=[a]:fu.push(a),a=o;do{switch(a.tag){case 3:a.flags|=65536,t&=-t,a.lanes|=t;var m=P2(a,l,t);a2(a,m);break e;case 1:s=l;var v=a.type,b=a.stateNode;if(!(a.flags&128)&&(typeof v.getDerivedStateFromError=="function"||b!==null&&typeof b.componentDidCatch=="function"&&(Xi===null||!Xi.has(b)))){a.flags|=65536,t&=-t,a.lanes|=t;var T=I2(a,s,t);a2(a,T);break e}}a=a.return}while(a!==null)}p_(n)}catch(_){t=_,wt===n&&n!==null&&(wt=n=n.return);continue}break}while(!0)}function d_(){var e=rf.current;return rf.current=Qd,e===null?Qd:e}function L0(){(Tt===0||Tt===3||Tt===2)&&(Tt=4),Ct===null||!($a&268435455)&&!(af&268435455)||Ji(Ct,It)}function df(e,t){var n=Be;Be|=2;var r=d_();(Ct!==e||It!==t)&&(li=null,Ya(e,t));do try{N9();break}catch(i){c_(e,i)}while(!0);if(Gg(),Be=n,rf.current=r,wt!==null)throw Error(Y(261));return Ct=null,It=0,Tt}function N9(){for(;wt!==null;)f_(wt)}function O9(){for(;wt!==null&&!nF();)f_(wt)}function f_(e){var t=g_(e.alternate,e,Rn);e.memoizedProps=e.pendingProps,t===null?p_(e):wt=t,k0.current=null}function p_(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=_9(n,t),n!==null){n.flags&=32767,wt=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{Tt=6,wt=null;return}}else if(n=T9(n,t,Rn),n!==null){wt=n;return}if(t=t.sibling,t!==null){wt=t;return}wt=t=e}while(t!==null);Tt===0&&(Tt=5)}function qa(e,t,n){var r=$e,i=Hn.transition;try{Hn.transition=null,$e=1,P9(e,t,n,r)}finally{Hn.transition=i,$e=r}return null}function P9(e,t,n,r){do rs();while(Qi!==null);if(Be&6)throw Error(Y(327));n=e.finishedWork;var i=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(Y(177));e.callbackNode=null,e.callbackPriority=0;var a=n.lanes|n.childLanes;if(fF(e,a),e===Ct&&(wt=Ct=null,It=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||sf||(sf=!0,w_(hd,function(){return rs(),null})),a=(n.flags&15990)!==0,n.subtreeFlags&15990||a){a=Hn.transition,Hn.transition=null;var o=$e;$e=1;var s=Be;Be|=4,k0.current=null,k9(e,n),r_(n,e),ZF(Lg),xd=!!Dg,Lg=Dg=null,e.current=n,C9(n),rF(),Be=s,$e=o,Hn.transition=a}else e.current=n;if(sf&&(sf=!1,Qi=e,lf=i),a=e.pendingLanes,a===0&&(Xi=null),oF(n.stateNode),hn(e,ft()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)i=t[n],r(i.value,{componentStack:i.stack,digest:i.digest});if(of)throw of=!1,e=R0,R0=null,e;return lf&1&&e.tag!==0&&rs(),a=e.pendingLanes,a&1?e===N0?pu++:(pu=0,N0=e):pu=0,Yi(),null}function rs(){if(Qi!==null){var e=tT(lf),t=Hn.transition,n=$e;try{if(Hn.transition=null,$e=16>e?16:e,Qi===null)var r=!1;else{if(e=Qi,Qi=null,lf=0,Be&6)throw Error(Y(331));var i=Be;for(Be|=4,ae=e.current;ae!==null;){var a=ae,o=a.child;if(ae.flags&16){var s=a.deletions;if(s!==null){for(var l=0;l<s.length;l++){var u=s[l];for(ae=u;ae!==null;){var c=ae;switch(c.tag){case 0:case 11:case 15:cu(8,c,a)}var d=c.child;if(d!==null)d.return=c,ae=d;else for(;ae!==null;){c=ae;var f=c.sibling,p=c.return;if(Z2(c),c===u){ae=null;break}if(f!==null){f.return=p,ae=f;break}ae=p}}}var g=a.alternate;if(g!==null){var w=g.child;if(w!==null){g.child=null;do{var x=w.sibling;w.sibling=null,w=x}while(w!==null)}}ae=a}}if(a.subtreeFlags&2064&&o!==null)o.return=a,ae=o;else e:for(;ae!==null;){if(a=ae,a.flags&2048)switch(a.tag){case 0:case 11:case 15:cu(9,a,a.return)}var m=a.sibling;if(m!==null){m.return=a.return,ae=m;break e}ae=a.return}}var v=e.current;for(ae=v;ae!==null;){o=ae;var b=o.child;if(o.subtreeFlags&2064&&b!==null)b.return=o,ae=b;else e:for(o=v;ae!==null;){if(s=ae,s.flags&2048)try{switch(s.tag){case 0:case 11:case 15:nf(9,s)}}catch(_){ct(s,s.return,_)}if(s===o){ae=null;break e}var T=s.sibling;if(T!==null){T.return=s.return,ae=T;break e}ae=s.return}}if(Be=i,Yi(),Ar&&typeof Ar.onPostCommitFiberRoot=="function")try{Ar.onPostCommitFiberRoot(md,e)}catch{}r=!0}return r}finally{$e=n,Hn.transition=t}}return!1}function h_(e,t,n){t=Jo(n,t),t=P2(e,t,1),e=Gi(e,t,1),t=nn(),e!==null&&(Fl(e,1,t),hn(e,t))}function ct(e,t,n){if(e.tag===3)h_(e,e,n);else for(;t!==null;){if(t.tag===3){h_(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Xi===null||!Xi.has(r))){e=Jo(n,e),e=I2(t,e,1),t=Gi(t,e,1),e=nn(),t!==null&&(Fl(t,1,e),hn(t,e));break}}t=t.return}}function I9(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=nn(),e.pingedLanes|=e.suspendedLanes&n,Ct===e&&(It&n)===n&&(Tt===4||Tt===3&&(It&130023424)===It&&500>ft()-A0?Ya(e,0):C0|=n),hn(e,t)}function m_(e,t){t===0&&(e.mode&1?(t=wd,wd<<=1,!(wd&130023424)&&(wd=4194304)):t=1);var n=nn();e=ai(e,t),e!==null&&(Fl(e,t,n),hn(e,n))}function D9(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),m_(e,n)}function L9(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(Y(314))}r!==null&&r.delete(t),m_(e,n)}var g_;g_=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||cn.current)fn=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return fn=!1,E9(e,t,n);fn=!!(e.flags&131072)}else fn=!1,tt&&t.flags&1048576&&KT(t,jd,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;ef(e,t),e=t.pendingProps;var i=Wo(t,zt.current);Qo(t,n),i=a0(null,t,r,e,i,n);var a=o0();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,dn(r)?(a=!0,Md(t)):a=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,Zg(t),i.updater=Zd,t.stateNode=i,i._reactInternals=t,f0(t,r,e,n),t=g0(null,t,r,!0,a,n)):(t.tag=0,tt&&a&&Hg(t),tn(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(ef(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=F9(r),e=ur(r,e),i){case 0:t=m0(null,t,r,e,n);break e;case 1:t=H2(null,t,r,e,n);break e;case 11:t=F2(null,t,r,e,n);break e;case 14:t=B2(null,t,r,ur(r.type,e),n);break e}throw Error(Y(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:ur(r,i),m0(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:ur(r,i),H2(e,t,r,i,n);case 3:e:{if(V2(t),e===null)throw Error(Y(387));r=t.pendingProps,a=t.memoizedState,i=a.element,i2(e,t),Wd(t,r,null,n);var o=t.memoizedState;if(r=o.element,a.isDehydrated)if(a={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){i=Jo(Error(Y(423)),t),t=$2(e,t,r,n,i);break e}else if(r!==i){i=Jo(Error(Y(424)),t),t=$2(e,t,r,n,i);break e}else for(An=Vi(t.stateNode.containerInfo.firstChild),Cn=t,tt=!0,lr=null,n=n2(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Go(),r===i){t=si(e,t,n);break e}tn(e,t,r,n)}t=t.child}return t;case 5:return s2(t),e===null&&Wg(t),r=t.type,i=t.pendingProps,a=e!==null?e.memoizedProps:null,o=i.children,Mg(r,i)?o=null:a!==null&&Mg(r,a)&&(t.flags|=32),U2(e,t),tn(e,t,o,n),t.child;case 6:return e===null&&Wg(t),null;case 13:return W2(e,t,n);case 4:return Jg(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ko(t,null,r,n):tn(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:ur(r,i),F2(e,t,r,i,n);case 7:return tn(e,t,t.pendingProps,n),t.child;case 8:return tn(e,t,t.pendingProps.children,n),t.child;case 12:return tn(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,a=t.memoizedProps,o=i.value,Xe(Hd,r._currentValue),r._currentValue=o,a!==null)if(sr(a.value,o)){if(a.children===i.children&&!cn.current){t=si(e,t,n);break e}}else for(a=t.child,a!==null&&(a.return=t);a!==null;){var s=a.dependencies;if(s!==null){o=a.child;for(var l=s.firstContext;l!==null;){if(l.context===r){if(a.tag===1){l=oi(-1,n&-n),l.tag=2;var u=a.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}a.lanes|=n,l=a.alternate,l!==null&&(l.lanes|=n),Xg(a.return,n,t),s.lanes|=n;break}l=l.next}}else if(a.tag===10)o=a.type===t.type?null:a.child;else if(a.tag===18){if(o=a.return,o===null)throw Error(Y(341));o.lanes|=n,s=o.alternate,s!==null&&(s.lanes|=n),Xg(o,n,t),o=a.sibling}else o=a.child;if(o!==null)o.return=a;else for(o=a;o!==null;){if(o===t){o=null;break}if(a=o.sibling,a!==null){a.return=o.return,o=a;break}o=o.return}a=o}tn(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,Qo(t,n),i=zn(i),r=r(i),t.flags|=1,tn(e,t,r,n),t.child;case 14:return r=t.type,i=ur(r,t.pendingProps),i=ur(r.type,i),B2(e,t,r,i,n);case 15:return j2(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:ur(r,i),ef(e,t),t.tag=1,dn(r)?(e=!0,Md(t)):e=!1,Qo(t,n),N2(t,r,i),f0(t,r,i,n),g0(null,t,r,!0,e,n);case 19:return q2(e,t,n);case 22:return z2(e,t,n)}throw Error(Y(156,t.tag))};function w_(e,t){return XE(e,t)}function M9(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Vn(e,t,n,r){return new M9(e,t,n,r)}function M0(e){return e=e.prototype,!(!e||!e.isReactComponent)}function F9(e){if(typeof e=="function")return M0(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Hm)return 11;if(e===Wm)return 14}return 2}function ea(e,t){var n=e.alternate;return n===null?(n=Vn(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function ff(e,t,n,r,i,a){var o=2;if(r=e,typeof e=="function")M0(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Po:return Ga(n.children,i,a,t);case zm:o=8,i|=8;break;case Um:return e=Vn(12,n,t,i|2),e.elementType=Um,e.lanes=a,e;case Vm:return e=Vn(13,n,t,i),e.elementType=Vm,e.lanes=a,e;case $m:return e=Vn(19,n,t,i),e.elementType=$m,e.lanes=a,e;case kE:return pf(n,i,a,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case _E:o=10;break e;case SE:o=9;break e;case Hm:o=11;break e;case Wm:o=14;break e;case Li:o=16,r=null;break e}throw Error(Y(130,e==null?e:typeof e,""))}return t=Vn(o,n,t,i),t.elementType=e,t.type=r,t.lanes=a,t}function Ga(e,t,n,r){return e=Vn(7,e,r,t),e.lanes=n,e}function pf(e,t,n,r){return e=Vn(22,e,r,t),e.elementType=kE,e.lanes=n,e.stateNode={isHidden:!1},e}function F0(e,t,n){return e=Vn(6,e,null,t),e.lanes=n,e}function B0(e,t,n){return t=Vn(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function B9(e,t,n,r,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=dg(0),this.expirationTimes=dg(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=dg(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function j0(e,t,n,r,i,a,o,s,l){return e=new B9(e,t,n,s,l),t===1?(t=1,a===!0&&(t|=8)):t=0,a=Vn(3,null,null,t),e.current=a,a.stateNode=e,a.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Zg(a),e}function j9(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Oo,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function y_(e){if(!e)return Wi;e=e._reactInternals;e:{if(Ma(e)!==e||e.tag!==1)throw Error(Y(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(dn(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(Y(171))}if(e.tag===1){var n=e.type;if(dn(n))return YT(e,n,t)}return t}function v_(e,t,n,r,i,a,o,s,l){return e=j0(n,r,!0,e,i,a,o,s,l),e.context=y_(null),n=e.current,r=nn(),i=Zi(n),a=oi(r,i),a.callback=t??null,Gi(n,a,i),e.current.lanes=i,Fl(e,i,r),hn(e,r),e}function hf(e,t,n,r){var i=t.current,a=nn(),o=Zi(i);return n=y_(n),t.context===null?t.context=n:t.pendingContext=n,t=oi(a,o),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=Gi(i,t,o),e!==null&&(fr(e,i,o,a),$d(e,i,o)),o}function mf(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function b_(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function z0(e,t){b_(e,t),(e=e.alternate)&&b_(e,t)}function z9(){return null}var x_=typeof reportError=="function"?reportError:function(e){console.error(e)};function U0(e){this._internalRoot=e}gf.prototype.render=U0.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(Y(409));hf(e,t,null,null)},gf.prototype.unmount=U0.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Wa(function(){hf(null,e,null,null)}),t[ti]=null}};function gf(e){this._internalRoot=e}gf.prototype.unstable_scheduleHydration=function(e){if(e){var t=iT();e={blockedOn:null,target:e,priority:t};for(var n=0;n<zi.length&&t!==0&&t<zi[n].priority;n++);zi.splice(n,0,e),n===0&&sT(e)}};function H0(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function wf(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function E_(){}function U9(e,t,n,r,i){if(i){if(typeof r=="function"){var a=r;r=function(){var u=mf(o);a.call(u)}}var o=v_(t,r,e,0,null,!1,!1,"",E_);return e._reactRootContainer=o,e[ti]=o.current,Ql(e.nodeType===8?e.parentNode:e),Wa(),o}for(;i=e.lastChild;)e.removeChild(i);if(typeof r=="function"){var s=r;r=function(){var u=mf(l);s.call(u)}}var l=j0(e,0,!1,null,null,!1,!1,"",E_);return e._reactRootContainer=l,e[ti]=l.current,Ql(e.nodeType===8?e.parentNode:e),Wa(function(){hf(t,l,n,r)}),l}function yf(e,t,n,r,i){var a=n._reactRootContainer;if(a){var o=a;if(typeof i=="function"){var s=i;i=function(){var l=mf(o);s.call(l)}}hf(t,o,e,i)}else o=U9(n,t,e,i,r);return mf(o)}nT=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Ml(t.pendingLanes);n!==0&&(fg(t,n|1),hn(t,ft()),!(Be&6)&&(ns=ft()+500,Yi()))}break;case 13:Wa(function(){var r=ai(e,1);if(r!==null){var i=nn();fr(r,e,1,i)}}),z0(e,1)}},pg=function(e){if(e.tag===13){var t=ai(e,134217728);if(t!==null){var n=nn();fr(t,e,134217728,n)}z0(e,134217728)}},rT=function(e){if(e.tag===13){var t=Zi(e),n=ai(e,t);if(n!==null){var r=nn();fr(n,e,t,r)}z0(e,t)}},iT=function(){return $e},aT=function(e,t){var n=$e;try{return $e=e,t()}finally{$e=n}},ag=function(e,t,n){switch(t){case"input":if(Qm(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=Dd(r);if(!i)throw Error(Y(90));RE(r),Qm(r,i)}}}break;case"textarea":DE(e,n);break;case"select":t=n.value,t!=null&&Io(e,!!n.multiple,t,!1)}},VE=I0,$E=Wa;var H9={usingClientEntryPoint:!1,Events:[eu,Vo,Dd,UE,HE,I0]},hu={findFiberByHostInstance:Fa,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},V9={bundleType:hu.bundleType,version:hu.version,rendererPackageName:hu.rendererPackageName,rendererConfig:hu.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:ei.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=GE(e),e===null?null:e.stateNode},findFiberByHostInstance:hu.findFiberByHostInstance||z9,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var vf=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!vf.isDisabled&&vf.supportsFiber)try{md=vf.inject(V9),Ar=vf}catch{}}_n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=H9,_n.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!H0(t))throw Error(Y(200));return j9(e,t,null,n)},_n.createRoot=function(e,t){if(!H0(e))throw Error(Y(299));var n=!1,r="",i=x_;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=j0(e,1,!1,null,null,n,!1,r,i),e[ti]=t.current,Ql(e.nodeType===8?e.parentNode:e),new U0(t)},_n.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(Y(188)):(e=Object.keys(e).join(","),Error(Y(268,e)));return e=GE(t),e=e===null?null:e.stateNode,e},_n.flushSync=function(e){return Wa(e)},_n.hydrate=function(e,t,n){if(!wf(t))throw Error(Y(200));return yf(null,e,t,!0,n)},_n.hydrateRoot=function(e,t,n){if(!H0(e))throw Error(Y(405));var r=n!=null&&n.hydratedSources||null,i=!1,a="",o=x_;if(n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(a=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),t=v_(t,null,e,1,n??null,i,!1,a,o),e[ti]=t.current,Ql(e),r)for(e=0;e<r.length;e++)n=r[e],i=n._getVersion,i=i(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,i]:t.mutableSourceEagerHydrationData.push(n,i);return new gf(t)},_n.render=function(e,t,n){if(!wf(t))throw Error(Y(200));return yf(null,e,t,!1,n)},_n.unmountComponentAtNode=function(e){if(!wf(e))throw Error(Y(40));return e._reactRootContainer?(Wa(function(){yf(null,null,e,!1,function(){e._reactRootContainer=null,e[ti]=null})}),!0):!1},_n.unstable_batchedUpdates=I0,_n.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!wf(n))throw Error(Y(200));if(e==null||e._reactInternals===void 0)throw Error(Y(38));return yf(e,t,n,!1,r)},_n.version="18.3.1-next-f1338f8080-20240426";function T_(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(T_)}catch(e){console.error(e)}}T_(),yE.exports=_n;var is=yE.exports,bf=y.forwardRef((e,t)=>{const{children:n,...r}=e,i=y.Children.toArray(n),a=i.find($9);if(a){const o=a.props.children,s=i.map(l=>l===a?y.Children.count(o)>1?y.Children.only(null):y.isValidElement(o)?o.props.children:null:l);return E.jsx(V0,{...r,ref:t,children:y.isValidElement(o)?y.cloneElement(o,void 0,s):null})}return E.jsx(V0,{...r,ref:t,children:n})});bf.displayName="Slot";var V0=y.forwardRef((e,t)=>{const{children:n,...r}=e;if(y.isValidElement(n)){const i=Y9(n);return y.cloneElement(n,{...W9(r,n.props),ref:t?wE(t,i):i})}return y.Children.count(n)>1?y.Children.only(null):null});V0.displayName="SlotClone";var __=({children:e})=>E.jsx(E.Fragment,{children:e});function $9(e){return y.isValidElement(e)&&e.type===__}function W9(e,t){const n={...t};for(const r in t){const i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...s)=>{a(...s),i(...s)}:i&&(n[r]=i):r==="style"?n[r]={...i,...a}:r==="className"&&(n[r]=[i,a].filter(Boolean).join(" "))}return{...e,...n}}function Y9(e){var r,i;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var q9=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],rn=q9.reduce((e,t)=>{const n=y.forwardRef((r,i)=>{const{asChild:a,...o}=r,s=a?bf:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),E.jsx(s,{...o,ref:i})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function G9(e,t){e&&is.flushSync(()=>e.dispatchEvent(t))}function Dt(e){const t=y.useRef(e);return y.useEffect(()=>{t.current=e}),y.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function S_(e,t=globalThis==null?void 0:globalThis.document){const n=Dt(e);y.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var K9="DismissableLayer",$0="dismissableLayer.update",X9="dismissableLayer.pointerDownOutside",Q9="dismissableLayer.focusOutside",k_,C_=y.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),W0=y.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:o,onDismiss:s,...l}=e,u=y.useContext(C_),[c,d]=y.useState(null),f=(c==null?void 0:c.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,p]=y.useState({}),g=ar(t,R=>d(R)),w=Array.from(u.layers),[x]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),m=w.indexOf(x),v=c?w.indexOf(c):-1,b=u.layersWithOutsidePointerEventsDisabled.size>0,T=v>=m,_=e7(R=>{const P=R.target,B=[...u.branches].some(N=>N.contains(P));!T||B||(i==null||i(R),o==null||o(R),R.defaultPrevented||s==null||s())},f),S=t7(R=>{const P=R.target;[...u.branches].some(N=>N.contains(P))||(a==null||a(R),o==null||o(R),R.defaultPrevented||s==null||s())},f);return S_(R=>{v===u.layers.size-1&&(r==null||r(R),!R.defaultPrevented&&s&&(R.preventDefault(),s()))},f),y.useEffect(()=>{if(c)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(k_=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(c)),u.layers.add(c),A_(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=k_)}},[c,f,n,u]),y.useEffect(()=>()=>{c&&(u.layers.delete(c),u.layersWithOutsidePointerEventsDisabled.delete(c),A_())},[c,u]),y.useEffect(()=>{const R=()=>p({});return document.addEventListener($0,R),()=>document.removeEventListener($0,R)},[]),E.jsx(rn.div,{...l,ref:g,style:{pointerEvents:b?T?"auto":"none":void 0,...e.style},onFocusCapture:Jt(e.onFocusCapture,S.onFocusCapture),onBlurCapture:Jt(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:Jt(e.onPointerDownCapture,_.onPointerDownCapture)})});W0.displayName=K9;var Z9="DismissableLayerBranch",J9=y.forwardRef((e,t)=>{const n=y.useContext(C_),r=y.useRef(null),i=ar(t,r);return y.useEffect(()=>{const a=r.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),E.jsx(rn.div,{...e,ref:i})});J9.displayName=Z9;function e7(e,t=globalThis==null?void 0:globalThis.document){const n=Dt(e),r=y.useRef(!1),i=y.useRef(()=>{});return y.useEffect(()=>{const a=s=>{if(s.target&&!r.current){let l=function(){R_(X9,n,u,{discrete:!0})};const u={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=l,t.addEventListener("click",i.current,{once:!0})):l()}else t.removeEventListener("click",i.current);r.current=!1},o=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",a),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function t7(e,t=globalThis==null?void 0:globalThis.document){const n=Dt(e),r=y.useRef(!1);return y.useEffect(()=>{const i=a=>{a.target&&!r.current&&R_(Q9,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function A_(){const e=new CustomEvent($0);document.dispatchEvent(e)}function R_(e,t,n,{discrete:r}){const i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?G9(i,a):i.dispatchEvent(a)}var $n=globalThis!=null&&globalThis.document?y.useLayoutEffect:()=>{},n7=k6.useId||(()=>{}),r7=0;function mu(e){const[t,n]=y.useState(n7());return $n(()=>{e||n(r=>r??String(r7++))},[e]),e||(t?`radix-${t}`:"")}const i7=["top","right","bottom","left"],ta=Math.min,Nn=Math.max,xf=Math.round,Ef=Math.floor,na=e=>({x:e,y:e}),a7={left:"right",right:"left",bottom:"top",top:"bottom"},o7={start:"end",end:"start"};function Y0(e,t,n){return Nn(e,ta(t,n))}function ui(e,t){return typeof e=="function"?e(t):e}function ci(e){return e.split("-")[0]}function as(e){return e.split("-")[1]}function q0(e){return e==="x"?"y":"x"}function G0(e){return e==="y"?"height":"width"}function ra(e){return["top","bottom"].includes(ci(e))?"y":"x"}function K0(e){return q0(ra(e))}function s7(e,t,n){n===void 0&&(n=!1);const r=as(e),i=K0(e),a=G0(i);let o=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(o=Tf(o)),[o,Tf(o)]}function l7(e){const t=Tf(e);return[X0(e),t,X0(t)]}function X0(e){return e.replace(/start|end/g,t=>o7[t])}function u7(e,t,n){const r=["left","right"],i=["right","left"],a=["top","bottom"],o=["bottom","top"];switch(e){case"top":case"bottom":return n?t?i:r:t?r:i;case"left":case"right":return t?a:o;default:return[]}}function c7(e,t,n,r){const i=as(e);let a=u7(ci(e),n==="start",r);return i&&(a=a.map(o=>o+"-"+i),t&&(a=a.concat(a.map(X0)))),a}function Tf(e){return e.replace(/left|right|bottom|top/g,t=>a7[t])}function d7(e){return{top:0,right:0,bottom:0,left:0,...e}}function N_(e){return typeof e!="number"?d7(e):{top:e,right:e,bottom:e,left:e}}function _f(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function O_(e,t,n){let{reference:r,floating:i}=e;const a=ra(t),o=K0(t),s=G0(o),l=ci(t),u=a==="y",c=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2;let p;switch(l){case"top":p={x:c,y:r.y-i.height};break;case"bottom":p={x:c,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:d};break;case"left":p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(as(t)){case"start":p[o]-=f*(n&&u?-1:1);break;case"end":p[o]+=f*(n&&u?-1:1);break}return p}const f7=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:a=[],platform:o}=n,s=a.filter(Boolean),l=await(o.isRTL==null?void 0:o.isRTL(t));let u=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:c,y:d}=O_(u,r,l),f=r,p={},g=0;for(let w=0;w<s.length;w++){const{name:x,fn:m}=s[w],{x:v,y:b,data:T,reset:_}=await m({x:c,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:p,rects:u,platform:o,elements:{reference:e,floating:t}});c=v??c,d=b??d,p={...p,[x]:{...p[x],...T}},_&&g<=50&&(g++,typeof _=="object"&&(_.placement&&(f=_.placement),_.rects&&(u=_.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):_.rects),{x:c,y:d}=O_(u,f,l)),w=-1)}return{x:c,y:d,placement:f,strategy:i,middlewareData:p}};async function gu(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:a,rects:o,elements:s,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=ui(t,e),g=N_(p),x=s[f?d==="floating"?"reference":"floating":d],m=_f(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(x)))==null||n?x:x.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(s.floating)),boundary:u,rootBoundary:c,strategy:l})),v=d==="floating"?{x:r,y:i,width:o.floating.width,height:o.floating.height}:o.reference,b=await(a.getOffsetParent==null?void 0:a.getOffsetParent(s.floating)),T=await(a.isElement==null?void 0:a.isElement(b))?await(a.getScale==null?void 0:a.getScale(b))||{x:1,y:1}:{x:1,y:1},_=_f(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:v,offsetParent:b,strategy:l}):v);return{top:(m.top-_.top+g.top)/T.y,bottom:(_.bottom-m.bottom+g.bottom)/T.y,left:(m.left-_.left+g.left)/T.x,right:(_.right-m.right+g.right)/T.x}}const p7=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:l}=t,{element:u,padding:c=0}=ui(e,t)||{};if(u==null)return{};const d=N_(c),f={x:n,y:r},p=K0(i),g=G0(p),w=await o.getDimensions(u),x=p==="y",m=x?"top":"left",v=x?"bottom":"right",b=x?"clientHeight":"clientWidth",T=a.reference[g]+a.reference[p]-f[p]-a.floating[g],_=f[p]-a.reference[p],S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(u));let R=S?S[b]:0;(!R||!await(o.isElement==null?void 0:o.isElement(S)))&&(R=s.floating[b]||a.floating[g]);const P=T/2-_/2,B=R/2-w[g]/2-1,N=ta(d[m],B),H=ta(d[v],B),U=N,K=R-w[g]-H,X=R/2-w[g]/2+P,ee=Y0(U,X,K),oe=!l.arrow&&as(i)!=null&&X!==ee&&a.reference[g]/2-(X<U?N:H)-w[g]/2<0,ne=oe?X<U?X-U:X-K:0;return{[p]:f[p]+ne,data:{[p]:ee,centerOffset:X-ee-ne,...oe&&{alignmentOffset:ne}},reset:oe}}}),h7=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:a,rects:o,initialPlacement:s,platform:l,elements:u}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:w=!0,...x}=ui(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const m=ci(i),v=ra(s),b=ci(s)===s,T=await(l.isRTL==null?void 0:l.isRTL(u.floating)),_=f||(b||!w?[Tf(s)]:l7(s)),S=g!=="none";!f&&S&&_.push(...c7(s,w,g,T));const R=[s,..._],P=await gu(t,x),B=[];let N=((r=a.flip)==null?void 0:r.overflows)||[];if(c&&B.push(P[m]),d){const X=s7(i,o,T);B.push(P[X[0]],P[X[1]])}if(N=[...N,{placement:i,overflows:B}],!B.every(X=>X<=0)){var H,U;const X=(((H=a.flip)==null?void 0:H.index)||0)+1,ee=R[X];if(ee)return{data:{index:X,overflows:N},reset:{placement:ee}};let oe=(U=N.filter(ne=>ne.overflows[0]<=0).sort((ne,L)=>ne.overflows[1]-L.overflows[1])[0])==null?void 0:U.placement;if(!oe)switch(p){case"bestFit":{var K;const ne=(K=N.filter(L=>{if(S){const F=ra(L.placement);return F===v||F==="y"}return!0}).map(L=>[L.placement,L.overflows.filter(F=>F>0).reduce((F,C)=>F+C,0)]).sort((L,F)=>L[1]-F[1])[0])==null?void 0:K[0];ne&&(oe=ne);break}case"initialPlacement":oe=s;break}if(i!==oe)return{reset:{placement:oe}}}return{}}}};function P_(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function I_(e){return i7.some(t=>e[t]>=0)}const m7=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...i}=ui(e,t);switch(r){case"referenceHidden":{const a=await gu(t,{...i,elementContext:"reference"}),o=P_(a,n.reference);return{data:{referenceHiddenOffsets:o,referenceHidden:I_(o)}}}case"escaped":{const a=await gu(t,{...i,altBoundary:!0}),o=P_(a,n.floating);return{data:{escapedOffsets:o,escaped:I_(o)}}}default:return{}}}}};async function g7(e,t){const{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=ci(n),s=as(n),l=ra(n)==="y",u=["left","top"].includes(o)?-1:1,c=a&&l?-1:1,d=ui(t,e);let{mainAxis:f,crossAxis:p,alignmentAxis:g}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof g=="number"&&(p=s==="end"?g*-1:g),l?{x:p*c,y:f*u}:{x:f*u,y:p*c}}const w7=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:a,placement:o,middlewareData:s}=t,l=await g7(t,e);return o===((n=s.offset)==null?void 0:n.placement)&&(r=s.arrow)!=null&&r.alignmentOffset?{}:{x:i+l.x,y:a+l.y,data:{...l,placement:o}}}}},y7=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:a=!0,crossAxis:o=!1,limiter:s={fn:x=>{let{x:m,y:v}=x;return{x:m,y:v}}},...l}=ui(e,t),u={x:n,y:r},c=await gu(t,l),d=ra(ci(i)),f=q0(d);let p=u[f],g=u[d];if(a){const x=f==="y"?"top":"left",m=f==="y"?"bottom":"right",v=p+c[x],b=p-c[m];p=Y0(v,p,b)}if(o){const x=d==="y"?"top":"left",m=d==="y"?"bottom":"right",v=g+c[x],b=g-c[m];g=Y0(v,g,b)}const w=s.fn({...t,[f]:p,[d]:g});return{...w,data:{x:w.x-n,y:w.y-r,enabled:{[f]:a,[d]:o}}}}}},v7=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:l=!0,crossAxis:u=!0}=ui(e,t),c={x:n,y:r},d=ra(i),f=q0(d);let p=c[f],g=c[d];const w=ui(s,t),x=typeof w=="number"?{mainAxis:w,crossAxis:0}:{mainAxis:0,crossAxis:0,...w};if(l){const b=f==="y"?"height":"width",T=a.reference[f]-a.floating[b]+x.mainAxis,_=a.reference[f]+a.reference[b]-x.mainAxis;p<T?p=T:p>_&&(p=_)}if(u){var m,v;const b=f==="y"?"width":"height",T=["top","left"].includes(ci(i)),_=a.reference[d]-a.floating[b]+(T&&((m=o.offset)==null?void 0:m[d])||0)+(T?0:x.crossAxis),S=a.reference[d]+a.reference[b]+(T?0:((v=o.offset)==null?void 0:v[d])||0)-(T?x.crossAxis:0);g<_?g=_:g>S&&(g=S)}return{[f]:p,[d]:g}}}},b7=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:i,rects:a,platform:o,elements:s}=t,{apply:l=()=>{},...u}=ui(e,t),c=await gu(t,u),d=ci(i),f=as(i),p=ra(i)==="y",{width:g,height:w}=a.floating;let x,m;d==="top"||d==="bottom"?(x=d,m=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?"start":"end")?"left":"right"):(m=d,x=f==="end"?"top":"bottom");const v=w-c.top-c.bottom,b=g-c.left-c.right,T=ta(w-c[x],v),_=ta(g-c[m],b),S=!t.middlewareData.shift;let R=T,P=_;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(P=b),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(R=v),S&&!f){const N=Nn(c.left,0),H=Nn(c.right,0),U=Nn(c.top,0),K=Nn(c.bottom,0);p?P=g-2*(N!==0||H!==0?N+H:Nn(c.left,c.right)):R=w-2*(U!==0||K!==0?U+K:Nn(c.top,c.bottom))}await l({...t,availableWidth:P,availableHeight:R});const B=await o.getDimensions(s.floating);return g!==B.width||w!==B.height?{reset:{rects:!0}}:{}}}};function Sf(){return typeof window<"u"}function os(e){return D_(e)?(e.nodeName||"").toLowerCase():"#document"}function On(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ir(e){var t;return(t=(D_(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function D_(e){return Sf()?e instanceof Node||e instanceof On(e).Node:!1}function pr(e){return Sf()?e instanceof Element||e instanceof On(e).Element:!1}function Dr(e){return Sf()?e instanceof HTMLElement||e instanceof On(e).HTMLElement:!1}function L_(e){return!Sf()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof On(e).ShadowRoot}function wu(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=hr(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function x7(e){return["table","td","th"].includes(os(e))}function kf(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function Q0(e){const t=Z0(),n=pr(e)?hr(e):e;return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function E7(e){let t=ia(e);for(;Dr(t)&&!ss(t);){if(Q0(t))return t;if(kf(t))return null;t=ia(t)}return null}function Z0(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function ss(e){return["html","body","#document"].includes(os(e))}function hr(e){return On(e).getComputedStyle(e)}function Cf(e){return pr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function ia(e){if(os(e)==="html")return e;const t=e.assignedSlot||e.parentNode||L_(e)&&e.host||Ir(e);return L_(t)?t.host:t}function M_(e){const t=ia(e);return ss(t)?e.ownerDocument?e.ownerDocument.body:e.body:Dr(t)&&wu(t)?t:M_(t)}function yu(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const i=M_(e),a=i===((r=e.ownerDocument)==null?void 0:r.body),o=On(i);if(a){const s=J0(o);return t.concat(o,o.visualViewport||[],wu(i)?i:[],s&&n?yu(s):[])}return t.concat(i,yu(i,[],n))}function J0(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function F_(e){const t=hr(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=Dr(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=xf(n)!==a||xf(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function ew(e){return pr(e)?e:e.contextElement}function ls(e){const t=ew(e);if(!Dr(t))return na(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:a}=F_(t);let o=(a?xf(n.width):n.width)/r,s=(a?xf(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}const T7=na(0);function B_(e){const t=On(e);return!Z0()||!t.visualViewport?T7:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function _7(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==On(e)?!1:t}function Ka(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),a=ew(e);let o=na(1);t&&(r?pr(r)&&(o=ls(r)):o=ls(e));const s=_7(a,n,r)?B_(a):na(0);let l=(i.left+s.x)/o.x,u=(i.top+s.y)/o.y,c=i.width/o.x,d=i.height/o.y;if(a){const f=On(a),p=r&&pr(r)?On(r):r;let g=f,w=J0(g);for(;w&&r&&p!==g;){const x=ls(w),m=w.getBoundingClientRect(),v=hr(w),b=m.left+(w.clientLeft+parseFloat(v.paddingLeft))*x.x,T=m.top+(w.clientTop+parseFloat(v.paddingTop))*x.y;l*=x.x,u*=x.y,c*=x.x,d*=x.y,l+=b,u+=T,g=On(w),w=J0(g)}}return _f({width:c,height:d,x:l,y:u})}function S7(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const a=i==="fixed",o=Ir(r),s=t?kf(t.floating):!1;if(r===o||s&&a)return n;let l={scrollLeft:0,scrollTop:0},u=na(1);const c=na(0),d=Dr(r);if((d||!d&&!a)&&((os(r)!=="body"||wu(o))&&(l=Cf(r)),Dr(r))){const f=Ka(r);u=ls(r),c.x=f.x+r.clientLeft,c.y=f.y+r.clientTop}return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+c.x,y:n.y*u.y-l.scrollTop*u.y+c.y}}function k7(e){return Array.from(e.getClientRects())}function tw(e,t){const n=Cf(e).scrollLeft;return t?t.left+n:Ka(Ir(e)).left+n}function C7(e){const t=Ir(e),n=Cf(e),r=e.ownerDocument.body,i=Nn(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Nn(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let o=-n.scrollLeft+tw(e);const s=-n.scrollTop;return hr(r).direction==="rtl"&&(o+=Nn(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}function A7(e,t){const n=On(e),r=Ir(e),i=n.visualViewport;let a=r.clientWidth,o=r.clientHeight,s=0,l=0;if(i){a=i.width,o=i.height;const u=Z0();(!u||u&&t==="fixed")&&(s=i.offsetLeft,l=i.offsetTop)}return{width:a,height:o,x:s,y:l}}function R7(e,t){const n=Ka(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=Dr(e)?ls(e):na(1),o=e.clientWidth*a.x,s=e.clientHeight*a.y,l=i*a.x,u=r*a.y;return{width:o,height:s,x:l,y:u}}function j_(e,t,n){let r;if(t==="viewport")r=A7(e,n);else if(t==="document")r=C7(Ir(e));else if(pr(t))r=R7(t,n);else{const i=B_(e);r={...t,x:t.x-i.x,y:t.y-i.y}}return _f(r)}function z_(e,t){const n=ia(e);return n===t||!pr(n)||ss(n)?!1:hr(n).position==="fixed"||z_(n,t)}function N7(e,t){const n=t.get(e);if(n)return n;let r=yu(e,[],!1).filter(s=>pr(s)&&os(s)!=="body"),i=null;const a=hr(e).position==="fixed";let o=a?ia(e):e;for(;pr(o)&&!ss(o);){const s=hr(o),l=Q0(o);!l&&s.position==="fixed"&&(i=null),(a?!l&&!i:!l&&s.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||wu(o)&&!l&&z_(e,o))?r=r.filter(c=>c!==o):i=s,o=ia(o)}return t.set(e,r),r}function O7(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o=[...n==="clippingAncestors"?kf(t)?[]:N7(t,this._c):[].concat(n),r],s=o[0],l=o.reduce((u,c)=>{const d=j_(t,c,i);return u.top=Nn(d.top,u.top),u.right=ta(d.right,u.right),u.bottom=ta(d.bottom,u.bottom),u.left=Nn(d.left,u.left),u},j_(t,s,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function P7(e){const{width:t,height:n}=F_(e);return{width:t,height:n}}function I7(e,t,n){const r=Dr(t),i=Ir(t),a=n==="fixed",o=Ka(e,!0,a,t);let s={scrollLeft:0,scrollTop:0};const l=na(0);if(r||!r&&!a)if((os(t)!=="body"||wu(i))&&(s=Cf(t)),r){const p=Ka(t,!0,a,t);l.x=p.x+t.clientLeft,l.y=p.y+t.clientTop}else i&&(l.x=tw(i));let u=0,c=0;if(i&&!r&&!a){const p=i.getBoundingClientRect();c=p.top+s.scrollTop,u=p.left+s.scrollLeft-tw(i,p)}const d=o.left+s.scrollLeft-l.x-u,f=o.top+s.scrollTop-l.y-c;return{x:d,y:f,width:o.width,height:o.height}}function nw(e){return hr(e).position==="static"}function U_(e,t){if(!Dr(e)||hr(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Ir(e)===n&&(n=n.ownerDocument.body),n}function H_(e,t){const n=On(e);if(kf(e))return n;if(!Dr(e)){let i=ia(e);for(;i&&!ss(i);){if(pr(i)&&!nw(i))return i;i=ia(i)}return n}let r=U_(e,t);for(;r&&x7(r)&&nw(r);)r=U_(r,t);return r&&ss(r)&&nw(r)&&!Q0(r)?n:r||E7(e)||n}const D7=async function(e){const t=this.getOffsetParent||H_,n=this.getDimensions,r=await n(e.floating);return{reference:I7(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function L7(e){return hr(e).direction==="rtl"}const M7={convertOffsetParentRelativeRectToViewportRelativeRect:S7,getDocumentElement:Ir,getClippingRect:O7,getOffsetParent:H_,getElementRects:D7,getClientRects:k7,getDimensions:P7,getScale:ls,isElement:pr,isRTL:L7};function F7(e,t){let n=null,r;const i=Ir(e);function a(){var s;clearTimeout(r),(s=n)==null||s.disconnect(),n=null}function o(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),a();const{left:u,top:c,width:d,height:f}=e.getBoundingClientRect();if(s||t(),!d||!f)return;const p=Ef(c),g=Ef(i.clientWidth-(u+d)),w=Ef(i.clientHeight-(c+f)),x=Ef(u),v={rootMargin:-p+"px "+-g+"px "+-w+"px "+-x+"px",threshold:Nn(0,ta(1,l))||1};let b=!0;function T(_){const S=_[0].intersectionRatio;if(S!==l){if(!b)return o();S?o(!1,S):r=setTimeout(()=>{o(!1,1e-7)},1e3)}b=!1}try{n=new IntersectionObserver(T,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(T,v)}n.observe(e)}return o(!0),a}function V_(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,u=ew(e),c=i||a?[...u?yu(u):[],...yu(t)]:[];c.forEach(m=>{i&&m.addEventListener("scroll",n,{passive:!0}),a&&m.addEventListener("resize",n)});const d=u&&s?F7(u,n):null;let f=-1,p=null;o&&(p=new ResizeObserver(m=>{let[v]=m;v&&v.target===u&&p&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var b;(b=p)==null||b.observe(t)})),n()}),u&&!l&&p.observe(u),p.observe(t));let g,w=l?Ka(e):null;l&&x();function x(){const m=Ka(e);w&&(m.x!==w.x||m.y!==w.y||m.width!==w.width||m.height!==w.height)&&n(),w=m,g=requestAnimationFrame(x)}return n(),()=>{var m;c.forEach(v=>{i&&v.removeEventListener("scroll",n),a&&v.removeEventListener("resize",n)}),d==null||d(),(m=p)==null||m.disconnect(),p=null,l&&cancelAnimationFrame(g)}}const B7=w7,j7=y7,z7=h7,U7=b7,H7=m7,$_=p7,V7=v7,$7=(e,t,n)=>{const r=new Map,i={platform:M7,...n},a={...i.platform,_c:r};return f7(e,t,{...i,platform:a})};var Af=typeof document<"u"?y.useLayoutEffect:y.useEffect;function Rf(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Rf(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const a=i[r];if(!(a==="_owner"&&e.$$typeof)&&!Rf(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function W_(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Y_(e,t){const n=W_(e);return Math.round(t*n)/n}function rw(e){const t=y.useRef(e);return Af(()=>{t.current=e}),t}function q_(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:l,open:u}=e,[c,d]=y.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=y.useState(r);Rf(f,r)||p(r);const[g,w]=y.useState(null),[x,m]=y.useState(null),v=y.useCallback(L=>{L!==S.current&&(S.current=L,w(L))},[]),b=y.useCallback(L=>{L!==R.current&&(R.current=L,m(L))},[]),T=a||g,_=o||x,S=y.useRef(null),R=y.useRef(null),P=y.useRef(c),B=l!=null,N=rw(l),H=rw(i),U=rw(u),K=y.useCallback(()=>{if(!S.current||!R.current)return;const L={placement:t,strategy:n,middleware:f};H.current&&(L.platform=H.current),$7(S.current,R.current,L).then(F=>{const C={...F,isPositioned:U.current!==!1};X.current&&!Rf(P.current,C)&&(P.current=C,is.flushSync(()=>{d(C)}))})},[f,t,n,H,U]);Af(()=>{u===!1&&P.current.isPositioned&&(P.current.isPositioned=!1,d(L=>({...L,isPositioned:!1})))},[u]);const X=y.useRef(!1);Af(()=>(X.current=!0,()=>{X.current=!1}),[]),Af(()=>{if(T&&(S.current=T),_&&(R.current=_),T&&_){if(N.current)return N.current(T,_,K);K()}},[T,_,K,N,B]);const ee=y.useMemo(()=>({reference:S,floating:R,setReference:v,setFloating:b}),[v,b]),oe=y.useMemo(()=>({reference:T,floating:_}),[T,_]),ne=y.useMemo(()=>{const L={position:n,left:0,top:0};if(!oe.floating)return L;const F=Y_(oe.floating,c.x),C=Y_(oe.floating,c.y);return s?{...L,transform:"translate("+F+"px, "+C+"px)",...W_(oe.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:F,top:C}},[n,s,oe.floating,c.x,c.y]);return y.useMemo(()=>({...c,update:K,refs:ee,elements:oe,floatingStyles:ne}),[c,K,ee,oe,ne])}const W7=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:i}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?$_({element:r.current,padding:i}).fn(n):{}:r?$_({element:r,padding:i}).fn(n):{}}}},G_=(e,t)=>({...B7(e),options:[e,t]}),K_=(e,t)=>({...j7(e),options:[e,t]}),X_=(e,t)=>({...V7(e),options:[e,t]}),Q_=(e,t)=>({...z7(e),options:[e,t]}),Z_=(e,t)=>({...U7(e),options:[e,t]}),J_=(e,t)=>({...H7(e),options:[e,t]}),eS=(e,t)=>({...W7(e),options:[e,t]});var Y7="Arrow",tS=y.forwardRef((e,t)=>{const{children:n,width:r=10,height:i=5,...a}=e;return E.jsx(rn.svg,{...a,ref:t,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:E.jsx("polygon",{points:"0,0 30,0 15,10"})})});tS.displayName=Y7;var q7=tS;function G7(e,t=[]){let n=[];function r(a,o){const s=y.createContext(o),l=n.length;n=[...n,o];function u(d){const{scope:f,children:p,...g}=d,w=(f==null?void 0:f[e][l])||s,x=y.useMemo(()=>g,Object.values(g));return E.jsx(w.Provider,{value:x,children:p})}function c(d,f){const p=(f==null?void 0:f[e][l])||s,g=y.useContext(p);if(g)return g;if(o!==void 0)return o;throw new Error(`\`${d}\` must be used within \`${a}\``)}return u.displayName=a+"Provider",[u,c]}const i=()=>{const a=n.map(o=>y.createContext(o));return function(s){const l=(s==null?void 0:s[e])||a;return y.useMemo(()=>({[`__scope${e}`]:{...s,[e]:l}}),[s,l])}};return i.scopeName=e,[r,K7(i,...t)]}function K7(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(a){const o=r.reduce((s,{useScope:l,scopeName:u})=>{const d=l(a)[`__scope${u}`];return{...s,...d}},{});return y.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}function iw(e){const[t,n]=y.useState(void 0);return $n(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const a=i[0];let o,s;if("borderBoxSize"in a){const l=a.borderBoxSize,u=Array.isArray(l)?l[0]:l;o=u.inlineSize,s=u.blockSize}else o=e.offsetWidth,s=e.offsetHeight;n({width:o,height:s})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var aw="Popper",[nS,Nf]=G7(aw),[X7,rS]=nS(aw),iS=e=>{const{__scopePopper:t,children:n}=e,[r,i]=y.useState(null);return E.jsx(X7,{scope:t,anchor:r,onAnchorChange:i,children:n})};iS.displayName=aw;var aS="PopperAnchor",oS=y.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...i}=e,a=rS(aS,n),o=y.useRef(null),s=ar(t,o);return y.useEffect(()=>{a.onAnchorChange((r==null?void 0:r.current)||o.current)}),r?null:E.jsx(rn.div,{...i,ref:s})});oS.displayName=aS;var ow="PopperContent",[Q7,Z7]=nS(ow),sS=y.forwardRef((e,t)=>{var de,Se,Ce,Re,vt,xe;const{__scopePopper:n,side:r="bottom",sideOffset:i=0,align:a="center",alignOffset:o=0,arrowPadding:s=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:c=0,sticky:d="partial",hideWhenDetached:f=!1,updatePositionStrategy:p="optimized",onPlaced:g,...w}=e,x=rS(ow,n),[m,v]=y.useState(null),b=ar(t,we=>v(we)),[T,_]=y.useState(null),S=iw(T),R=(S==null?void 0:S.width)??0,P=(S==null?void 0:S.height)??0,B=r+(a!=="center"?"-"+a:""),N=typeof c=="number"?c:{top:0,right:0,bottom:0,left:0,...c},H=Array.isArray(u)?u:[u],U=H.length>0,K={padding:N,boundary:H.filter(eB),altBoundary:U},{refs:X,floatingStyles:ee,placement:oe,isPositioned:ne,middlewareData:L}=q_({strategy:"fixed",placement:B,whileElementsMounted:(...we)=>V_(...we,{animationFrame:p==="always"}),elements:{reference:x.anchor},middleware:[G_({mainAxis:i+P,alignmentAxis:o}),l&&K_({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?X_():void 0,...K}),l&&Q_({...K}),Z_({...K,apply:({elements:we,rects:Ve,availableWidth:je,availableHeight:bt})=>{const{width:xt,height:Ke}=Ve.reference,ze=we.floating.style;ze.setProperty("--radix-popper-available-width",`${je}px`),ze.setProperty("--radix-popper-available-height",`${bt}px`),ze.setProperty("--radix-popper-anchor-width",`${xt}px`),ze.setProperty("--radix-popper-anchor-height",`${Ke}px`)}}),T&&eS({element:T,padding:s}),tB({arrowWidth:R,arrowHeight:P}),f&&J_({strategy:"referenceHidden",...K})]}),[F,C]=cS(oe),te=Dt(g);$n(()=>{ne&&(te==null||te())},[ne,te]);const fe=(de=L.arrow)==null?void 0:de.x,I=(Se=L.arrow)==null?void 0:Se.y,ke=((Ce=L.arrow)==null?void 0:Ce.centerOffset)!==0,[Ye,J]=y.useState();return $n(()=>{m&&J(window.getComputedStyle(m).zIndex)},[m]),E.jsx("div",{ref:X.setFloating,"data-radix-popper-content-wrapper":"",style:{...ee,transform:ne?ee.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Ye,"--radix-popper-transform-origin":[(Re=L.transformOrigin)==null?void 0:Re.x,(vt=L.transformOrigin)==null?void 0:vt.y].join(" "),...((xe=L.hide)==null?void 0:xe.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:E.jsx(Q7,{scope:n,placedSide:F,onArrowChange:_,arrowX:fe,arrowY:I,shouldHideArrow:ke,children:E.jsx(rn.div,{"data-side":F,"data-align":C,...w,ref:b,style:{...w.style,animation:ne?void 0:"none"}})})})});sS.displayName=ow;var lS="PopperArrow",J7={top:"bottom",right:"left",bottom:"top",left:"right"},uS=y.forwardRef(function(t,n){const{__scopePopper:r,...i}=t,a=Z7(lS,r),o=J7[a.placedSide];return E.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:E.jsx(q7,{...i,ref:n,style:{...i.style,display:"block"}})})});uS.displayName=lS;function eB(e){return e!==null}var tB=e=>({name:"transformOrigin",options:e,fn(t){var x,m,v;const{placement:n,rects:r,middlewareData:i}=t,o=((x=i.arrow)==null?void 0:x.centerOffset)!==0,s=o?0:e.arrowWidth,l=o?0:e.arrowHeight,[u,c]=cS(n),d={start:"0%",center:"50%",end:"100%"}[c],f=(((m=i.arrow)==null?void 0:m.x)??0)+s/2,p=(((v=i.arrow)==null?void 0:v.y)??0)+l/2;let g="",w="";return u==="bottom"?(g=o?d:`${f}px`,w=`${-l}px`):u==="top"?(g=o?d:`${f}px`,w=`${r.floating.height+l}px`):u==="right"?(g=`${-l}px`,w=o?d:`${p}px`):u==="left"&&(g=`${r.floating.width+l}px`,w=o?d:`${p}px`),{data:{x:g,y:w}}}});function cS(e){const[t,n="center"]=e.split("-");return[t,n]}var dS=iS,sw=oS,fS=sS,pS=uS;function nB(e,t){return y.useReducer((n,r)=>t[n][r]??n,e)}var lw=e=>{const{present:t,children:n}=e,r=rB(t),i=typeof n=="function"?n({present:r.isPresent}):y.Children.only(n),a=ar(r.ref,iB(i));return typeof n=="function"||r.isPresent?y.cloneElement(i,{ref:a}):null};lw.displayName="Presence";function rB(e){const[t,n]=y.useState(),r=y.useRef({}),i=y.useRef(e),a=y.useRef("none"),o=e?"mounted":"unmounted",[s,l]=nB(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return y.useEffect(()=>{const u=Of(r.current);a.current=s==="mounted"?u:"none"},[s]),$n(()=>{const u=r.current,c=i.current;if(c!==e){const f=a.current,p=Of(u);e?l("MOUNT"):p==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(c&&f!==p?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,l]),$n(()=>{if(t){let u;const c=t.ownerDocument.defaultView??window,d=p=>{const w=Of(r.current).includes(p.animationName);if(p.target===t&&w&&(l("ANIMATION_END"),!i.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",u=c.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},f=p=>{p.target===t&&(a.current=Of(r.current))};return t.addEventListener("animationstart",f),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{c.clearTimeout(u),t.removeEventListener("animationstart",f),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:y.useCallback(u=>{u&&(r.current=getComputedStyle(u)),n(u)},[])}}function Of(e){return(e==null?void 0:e.animationName)||"none"}function iB(e){var r,i;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function vu({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,i]=aB({defaultProp:t,onChange:n}),a=e!==void 0,o=a?e:r,s=Dt(n),l=y.useCallback(u=>{if(a){const d=typeof u=="function"?u(e):u;d!==e&&s(d)}else i(u)},[a,e,i,s]);return[o,l]}function aB({defaultProp:e,onChange:t}){const n=y.useState(e),[r]=n,i=y.useRef(r),a=Dt(t);return y.useEffect(()=>{i.current!==r&&(a(r),i.current=r)},[r,i,a]),n}var oB="VisuallyHidden",hS=y.forwardRef((e,t)=>E.jsx(rn.span,{...e,ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}));hS.displayName=oB;var sB=hS,[Pf,Hse]=Zr("Tooltip",[Nf]),If=Nf(),mS="TooltipProvider",lB=700,uw="tooltip.open",[uB,cw]=Pf(mS),gS=e=>{const{__scopeTooltip:t,delayDuration:n=lB,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:a}=e,[o,s]=y.useState(!0),l=y.useRef(!1),u=y.useRef(0);return y.useEffect(()=>{const c=u.current;return()=>window.clearTimeout(c)},[]),E.jsx(uB,{scope:t,isOpenDelayed:o,delayDuration:n,onOpen:y.useCallback(()=>{window.clearTimeout(u.current),s(!1)},[]),onClose:y.useCallback(()=>{window.clearTimeout(u.current),u.current=window.setTimeout(()=>s(!0),r)},[r]),isPointerInTransitRef:l,onPointerInTransitChange:y.useCallback(c=>{l.current=c},[]),disableHoverableContent:i,children:a})};gS.displayName=mS;var Df="Tooltip",[cB,Lf]=Pf(Df),wS=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:i=!1,onOpenChange:a,disableHoverableContent:o,delayDuration:s}=e,l=cw(Df,e.__scopeTooltip),u=If(t),[c,d]=y.useState(null),f=mu(),p=y.useRef(0),g=o??l.disableHoverableContent,w=s??l.delayDuration,x=y.useRef(!1),[m=!1,v]=vu({prop:r,defaultProp:i,onChange:R=>{R?(l.onOpen(),document.dispatchEvent(new CustomEvent(uw))):l.onClose(),a==null||a(R)}}),b=y.useMemo(()=>m?x.current?"delayed-open":"instant-open":"closed",[m]),T=y.useCallback(()=>{window.clearTimeout(p.current),x.current=!1,v(!0)},[v]),_=y.useCallback(()=>{window.clearTimeout(p.current),v(!1)},[v]),S=y.useCallback(()=>{window.clearTimeout(p.current),p.current=window.setTimeout(()=>{x.current=!0,v(!0)},w)},[w,v]);return y.useEffect(()=>()=>window.clearTimeout(p.current),[]),E.jsx(dS,{...u,children:E.jsx(cB,{scope:t,contentId:f,open:m,stateAttribute:b,trigger:c,onTriggerChange:d,onTriggerEnter:y.useCallback(()=>{l.isOpenDelayed?S():T()},[l.isOpenDelayed,S,T]),onTriggerLeave:y.useCallback(()=>{g?_():window.clearTimeout(p.current)},[_,g]),onOpen:T,onClose:_,disableHoverableContent:g,children:n})})};wS.displayName=Df;var dw="TooltipTrigger",yS=y.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=Lf(dw,n),a=cw(dw,n),o=If(n),s=y.useRef(null),l=ar(t,s,i.onTriggerChange),u=y.useRef(!1),c=y.useRef(!1),d=y.useCallback(()=>u.current=!1,[]);return y.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),E.jsx(sw,{asChild:!0,...o,children:E.jsx(rn.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:l,onPointerMove:Jt(e.onPointerMove,f=>{f.pointerType!=="touch"&&!c.current&&!a.isPointerInTransitRef.current&&(i.onTriggerEnter(),c.current=!0)}),onPointerLeave:Jt(e.onPointerLeave,()=>{i.onTriggerLeave(),c.current=!1}),onPointerDown:Jt(e.onPointerDown,()=>{u.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:Jt(e.onFocus,()=>{u.current||i.onOpen()}),onBlur:Jt(e.onBlur,i.onClose),onClick:Jt(e.onClick,i.onClose)})})});yS.displayName=dw;var dB="TooltipPortal",[Vse,fB]=Pf(dB,{forceMount:void 0}),us="TooltipContent",vS=y.forwardRef((e,t)=>{const n=fB(us,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i="top",...a}=e,o=Lf(us,e.__scopeTooltip);return E.jsx(lw,{present:r||o.open,children:o.disableHoverableContent?E.jsx(bS,{side:i,...a,ref:t}):E.jsx(pB,{side:i,...a,ref:t})})}),pB=y.forwardRef((e,t)=>{const n=Lf(us,e.__scopeTooltip),r=cw(us,e.__scopeTooltip),i=y.useRef(null),a=ar(t,i),[o,s]=y.useState(null),{trigger:l,onClose:u}=n,c=i.current,{onPointerInTransitChange:d}=r,f=y.useCallback(()=>{s(null),d(!1)},[d]),p=y.useCallback((g,w)=>{const x=g.currentTarget,m={x:g.clientX,y:g.clientY},v=wB(m,x.getBoundingClientRect()),b=yB(m,v),T=vB(w.getBoundingClientRect()),_=xB([...b,...T]);s(_),d(!0)},[d]);return y.useEffect(()=>()=>f(),[f]),y.useEffect(()=>{if(l&&c){const g=x=>p(x,c),w=x=>p(x,l);return l.addEventListener("pointerleave",g),c.addEventListener("pointerleave",w),()=>{l.removeEventListener("pointerleave",g),c.removeEventListener("pointerleave",w)}}},[l,c,p,f]),y.useEffect(()=>{if(o){const g=w=>{const x=w.target,m={x:w.clientX,y:w.clientY},v=(l==null?void 0:l.contains(x))||(c==null?void 0:c.contains(x)),b=!bB(m,o);v?f():b&&(f(),u())};return document.addEventListener("pointermove",g),()=>document.removeEventListener("pointermove",g)}},[l,c,o,u,f]),E.jsx(bS,{...e,ref:a})}),[hB,mB]=Pf(Df,{isInside:!1}),bS=y.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:a,onPointerDownOutside:o,...s}=e,l=Lf(us,n),u=If(n),{onClose:c}=l;return y.useEffect(()=>(document.addEventListener(uw,c),()=>document.removeEventListener(uw,c)),[c]),y.useEffect(()=>{if(l.trigger){const d=f=>{const p=f.target;p!=null&&p.contains(l.trigger)&&c()};return window.addEventListener("scroll",d,{capture:!0}),()=>window.removeEventListener("scroll",d,{capture:!0})}},[l.trigger,c]),E.jsx(W0,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:d=>d.preventDefault(),onDismiss:c,children:E.jsxs(fS,{"data-state":l.stateAttribute,...u,...s,ref:t,style:{...s.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[E.jsx(__,{children:r}),E.jsx(hB,{scope:n,isInside:!0,children:E.jsx(sB,{id:l.contentId,role:"tooltip",children:i||r})})]})})});vS.displayName=us;var xS="TooltipArrow",gB=y.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=If(n);return mB(xS,n).isInside?null:E.jsx(pS,{...i,...r,ref:t})});gB.displayName=xS;function wB(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,i,a)){case a:return"left";case i:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function yB(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function vB(e){const{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function bB(e,t){const{x:n,y:r}=e;let i=!1;for(let a=0,o=t.length-1;a<t.length;o=a++){const s=t[a].x,l=t[a].y,u=t[o].x,c=t[o].y;l>r!=c>r&&n<(u-s)*(r-l)/(c-l)+s&&(i=!i)}return i}function xB(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),EB(t)}function EB(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const i=e[r];for(;t.length>=2;){const a=t[t.length-1],o=t[t.length-2];if((a.x-o.x)*(i.y-o.y)>=(a.y-o.y)*(i.x-o.x))t.pop();else break}t.push(i)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const i=e[r];for(;n.length>=2;){const a=n[n.length-1],o=n[n.length-2];if((a.x-o.x)*(i.y-o.y)>=(a.y-o.y)*(i.x-o.x))n.pop();else break}n.push(i)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var TB=gS,_B=wS,SB=yS,ES=vS;function TS(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=TS(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function kB(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=TS(e))&&(r&&(r+=" "),r+=t);return r}const fw="-",CB=e=>{const t=RB(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:o=>{const s=o.split(fw);return s[0]===""&&s.length!==1&&s.shift(),_S(s,t)||AB(o)},getConflictingClassGroupIds:(o,s)=>{const l=n[o]||[];return s&&r[o]?[...l,...r[o]]:l}}},_S=(e,t)=>{var o;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),i=r?_S(e.slice(1),r):void 0;if(i)return i;if(t.validators.length===0)return;const a=e.join(fw);return(o=t.validators.find(({validator:s})=>s(a)))==null?void 0:o.classGroupId},SS=/^\[(.+)\]$/,AB=e=>{if(SS.test(e)){const t=SS.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},RB=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return OB(Object.entries(e.classGroups),n).forEach(([a,o])=>{pw(o,r,a,t)}),r},pw=(e,t,n,r)=>{e.forEach(i=>{if(typeof i=="string"){const a=i===""?t:kS(t,i);a.classGroupId=n;return}if(typeof i=="function"){if(NB(i)){pw(i(r),t,n,r);return}t.validators.push({validator:i,classGroupId:n});return}Object.entries(i).forEach(([a,o])=>{pw(o,kS(t,a),n,r)})})},kS=(e,t)=>{let n=e;return t.split(fw).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},NB=e=>e.isThemeGetter,OB=(e,t)=>t?e.map(([n,r])=>{const i=r.map(a=>typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([o,s])=>[t+o,s])):a);return[n,i]}):e,PB=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const i=(a,o)=>{n.set(a,o),t++,t>e&&(t=0,r=n,n=new Map)};return{get(a){let o=n.get(a);if(o!==void 0)return o;if((o=r.get(a))!==void 0)return i(a,o),o},set(a,o){n.has(a)?n.set(a,o):i(a,o)}}},CS="!",IB=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,i=t[0],a=t.length,o=s=>{const l=[];let u=0,c=0,d;for(let x=0;x<s.length;x++){let m=s[x];if(u===0){if(m===i&&(r||s.slice(x,x+a)===t)){l.push(s.slice(c,x)),c=x+a;continue}if(m==="/"){d=x;continue}}m==="["?u++:m==="]"&&u--}const f=l.length===0?s:s.substring(c),p=f.startsWith(CS),g=p?f.substring(1):f,w=d&&d>c?d-c:void 0;return{modifiers:l,hasImportantModifier:p,baseClassName:g,maybePostfixModifierPosition:w}};return n?s=>n({className:s,parseClassName:o}):o},DB=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},LB=e=>({cache:PB(e.cacheSize),parseClassName:IB(e),...CB(e)}),MB=/\s+/,FB=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i}=t,a=[],o=e.trim().split(MB);let s="";for(let l=o.length-1;l>=0;l-=1){const u=o[l],{modifiers:c,hasImportantModifier:d,baseClassName:f,maybePostfixModifierPosition:p}=n(u);let g=!!p,w=r(g?f.substring(0,p):f);if(!w){if(!g){s=u+(s.length>0?" "+s:s);continue}if(w=r(f),!w){s=u+(s.length>0?" "+s:s);continue}g=!1}const x=DB(c).join(":"),m=d?x+CS:x,v=m+w;if(a.includes(v))continue;a.push(v);const b=i(w,g);for(let T=0;T<b.length;++T){const _=b[T];a.push(m+_)}s=u+(s.length>0?" "+s:s)}return s};function BB(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=AS(t))&&(r&&(r+=" "),r+=n);return r}const AS=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=AS(e[r]))&&(n&&(n+=" "),n+=t);return n};function jB(e,...t){let n,r,i,a=o;function o(l){const u=t.reduce((c,d)=>d(c),e());return n=LB(u),r=n.cache.get,i=n.cache.set,a=s,s(l)}function s(l){const u=r(l);if(u)return u;const c=FB(l,n);return i(l,c),c}return function(){return a(BB.apply(null,arguments))}}const et=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},RS=/^\[(?:([a-z-]+):)?(.+)\]$/i,zB=/^\d+\/\d+$/,UB=new Set(["px","full","screen"]),HB=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,VB=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,$B=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,WB=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,YB=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,di=e=>cs(e)||UB.has(e)||zB.test(e),aa=e=>ds(e,"length",ej),cs=e=>!!e&&!Number.isNaN(Number(e)),hw=e=>ds(e,"number",cs),bu=e=>!!e&&Number.isInteger(Number(e)),qB=e=>e.endsWith("%")&&cs(e.slice(0,-1)),Ee=e=>RS.test(e),oa=e=>HB.test(e),GB=new Set(["length","size","percentage"]),KB=e=>ds(e,GB,NS),XB=e=>ds(e,"position",NS),QB=new Set(["image","url"]),ZB=e=>ds(e,QB,nj),JB=e=>ds(e,"",tj),xu=()=>!0,ds=(e,t,n)=>{const r=RS.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},ej=e=>VB.test(e)&&!$B.test(e),NS=()=>!1,tj=e=>WB.test(e),nj=e=>YB.test(e),rj=jB(()=>{const e=et("colors"),t=et("spacing"),n=et("blur"),r=et("brightness"),i=et("borderColor"),a=et("borderRadius"),o=et("borderSpacing"),s=et("borderWidth"),l=et("contrast"),u=et("grayscale"),c=et("hueRotate"),d=et("invert"),f=et("gap"),p=et("gradientColorStops"),g=et("gradientColorStopPositions"),w=et("inset"),x=et("margin"),m=et("opacity"),v=et("padding"),b=et("saturate"),T=et("scale"),_=et("sepia"),S=et("skew"),R=et("space"),P=et("translate"),B=()=>["auto","contain","none"],N=()=>["auto","hidden","clip","visible","scroll"],H=()=>["auto",Ee,t],U=()=>[Ee,t],K=()=>["",di,aa],X=()=>["auto",cs,Ee],ee=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],oe=()=>["solid","dashed","dotted","double","none"],ne=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],L=()=>["start","end","center","between","around","evenly","stretch"],F=()=>["","0",Ee],C=()=>["auto","avoid","all","avoid-page","page","left","right","column"],te=()=>[cs,Ee];return{cacheSize:500,separator:":",theme:{colors:[xu],spacing:[di,aa],blur:["none","",oa,Ee],brightness:te(),borderColor:[e],borderRadius:["none","","full",oa,Ee],borderSpacing:U(),borderWidth:K(),contrast:te(),grayscale:F(),hueRotate:te(),invert:F(),gap:U(),gradientColorStops:[e],gradientColorStopPositions:[qB,aa],inset:H(),margin:H(),opacity:te(),padding:U(),saturate:te(),scale:te(),sepia:F(),skew:te(),space:U(),translate:U()},classGroups:{aspect:[{aspect:["auto","square","video",Ee]}],container:["container"],columns:[{columns:[oa]}],"break-after":[{"break-after":C()}],"break-before":[{"break-before":C()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ee(),Ee]}],overflow:[{overflow:N()}],"overflow-x":[{"overflow-x":N()}],"overflow-y":[{"overflow-y":N()}],overscroll:[{overscroll:B()}],"overscroll-x":[{"overscroll-x":B()}],"overscroll-y":[{"overscroll-y":B()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[w]}],"inset-x":[{"inset-x":[w]}],"inset-y":[{"inset-y":[w]}],start:[{start:[w]}],end:[{end:[w]}],top:[{top:[w]}],right:[{right:[w]}],bottom:[{bottom:[w]}],left:[{left:[w]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",bu,Ee]}],basis:[{basis:H()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Ee]}],grow:[{grow:F()}],shrink:[{shrink:F()}],order:[{order:["first","last","none",bu,Ee]}],"grid-cols":[{"grid-cols":[xu]}],"col-start-end":[{col:["auto",{span:["full",bu,Ee]},Ee]}],"col-start":[{"col-start":X()}],"col-end":[{"col-end":X()}],"grid-rows":[{"grid-rows":[xu]}],"row-start-end":[{row:["auto",{span:[bu,Ee]},Ee]}],"row-start":[{"row-start":X()}],"row-end":[{"row-end":X()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Ee]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Ee]}],gap:[{gap:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"justify-content":[{justify:["normal",...L()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...L(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...L(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[v]}],px:[{px:[v]}],py:[{py:[v]}],ps:[{ps:[v]}],pe:[{pe:[v]}],pt:[{pt:[v]}],pr:[{pr:[v]}],pb:[{pb:[v]}],pl:[{pl:[v]}],m:[{m:[x]}],mx:[{mx:[x]}],my:[{my:[x]}],ms:[{ms:[x]}],me:[{me:[x]}],mt:[{mt:[x]}],mr:[{mr:[x]}],mb:[{mb:[x]}],ml:[{ml:[x]}],"space-x":[{"space-x":[R]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[R]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Ee,t]}],"min-w":[{"min-w":[Ee,t,"min","max","fit"]}],"max-w":[{"max-w":[Ee,t,"none","full","min","max","fit","prose",{screen:[oa]},oa]}],h:[{h:[Ee,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Ee,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Ee,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Ee,t,"auto","min","max","fit"]}],"font-size":[{text:["base",oa,aa]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",hw]}],"font-family":[{font:[xu]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Ee]}],"line-clamp":[{"line-clamp":["none",cs,hw]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",di,Ee]}],"list-image":[{"list-image":["none",Ee]}],"list-style-type":[{list:["none","disc","decimal",Ee]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[m]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[m]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...oe(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",di,aa]}],"underline-offset":[{"underline-offset":["auto",di,Ee]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:U()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Ee]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Ee]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[m]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ee(),XB]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",KB]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},ZB]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[g]}],"gradient-via-pos":[{via:[g]}],"gradient-to-pos":[{to:[g]}],"gradient-from":[{from:[p]}],"gradient-via":[{via:[p]}],"gradient-to":[{to:[p]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[m]}],"border-style":[{border:[...oe(),"hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[m]}],"divide-style":[{divide:oe()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-s":[{"border-s":[i]}],"border-color-e":[{"border-e":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...oe()]}],"outline-offset":[{"outline-offset":[di,Ee]}],"outline-w":[{outline:[di,aa]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:K()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[m]}],"ring-offset-w":[{"ring-offset":[di,aa]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",oa,JB]}],"shadow-color":[{shadow:[xu]}],opacity:[{opacity:[m]}],"mix-blend":[{"mix-blend":[...ne(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":ne()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",oa,Ee]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[c]}],invert:[{invert:[d]}],saturate:[{saturate:[b]}],sepia:[{sepia:[_]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[c]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[m]}],"backdrop-saturate":[{"backdrop-saturate":[b]}],"backdrop-sepia":[{"backdrop-sepia":[_]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[o]}],"border-spacing-x":[{"border-spacing-x":[o]}],"border-spacing-y":[{"border-spacing-y":[o]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Ee]}],duration:[{duration:te()}],ease:[{ease:["linear","in","out","in-out",Ee]}],delay:[{delay:te()}],animate:[{animate:["none","spin","ping","pulse","bounce",Ee]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[T]}],"scale-x":[{"scale-x":[T]}],"scale-y":[{"scale-y":[T]}],rotate:[{rotate:[bu,Ee]}],"translate-x":[{"translate-x":[P]}],"translate-y":[{"translate-y":[P]}],"skew-x":[{"skew-x":[S]}],"skew-y":[{"skew-y":[S]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Ee]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Ee]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":U()}],"scroll-mx":[{"scroll-mx":U()}],"scroll-my":[{"scroll-my":U()}],"scroll-ms":[{"scroll-ms":U()}],"scroll-me":[{"scroll-me":U()}],"scroll-mt":[{"scroll-mt":U()}],"scroll-mr":[{"scroll-mr":U()}],"scroll-mb":[{"scroll-mb":U()}],"scroll-ml":[{"scroll-ml":U()}],"scroll-p":[{"scroll-p":U()}],"scroll-px":[{"scroll-px":U()}],"scroll-py":[{"scroll-py":U()}],"scroll-ps":[{"scroll-ps":U()}],"scroll-pe":[{"scroll-pe":U()}],"scroll-pt":[{"scroll-pt":U()}],"scroll-pr":[{"scroll-pr":U()}],"scroll-pb":[{"scroll-pb":U()}],"scroll-pl":[{"scroll-pl":U()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Ee]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[di,aa,hw]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}});function He(...e){return rj(kB(e))}const ij=TB,aj=_B,oj=SB,OS=y.forwardRef(({className:e,sideOffset:t=4,...n},r)=>E.jsx(ES,{ref:r,sideOffset:t,className:He("z-50 overflow-hidden max-w-xs rounded-xl bg-black border text-primary-foreground p-2 text-center align-middle text-xs shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-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",e),...n}));OS.displayName=ES.displayName;function mw({children:e,content:t,side:n,align:r}){return E.jsxs(aj,{children:[E.jsx(oj,{asChild:!0,children:e}),E.jsx(OS,{side:n,align:r,collisionPadding:8,avoidCollisions:!0,children:t})]})}function PS(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}function Wse(){}function Yse(){}const an=sa(/[A-Za-z]/),$t=sa(/[\dA-Za-z]/),sj=sa(/[#-'*+\--9=?A-Z^-~]/);function Mf(e){return e!==null&&(e<32||e===127)}const gw=sa(/\d/),lj=sa(/[\dA-Fa-f]/),uj=sa(/[!-/:-@[-`{-~]/);function pe(e){return e!==null&&e<-2}function qe(e){return e!==null&&(e<0||e===32)}function Oe(e){return e===-2||e===-1||e===32}const Ff=sa(new RegExp("\\p{P}|\\p{S}","u")),Xa=sa(/\s/);function sa(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function cj(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}const Bf=function(e){if(e==null)return hj;if(typeof e=="function")return jf(e);if(typeof e=="object")return Array.isArray(e)?dj(e):fj(e);if(typeof e=="string")return pj(e);throw new Error("Expected function, string, or object as test")};function dj(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Bf(e[n]);return jf(r);function r(...i){let a=-1;for(;++a<t.length;)if(t[a].apply(this,i))return!0;return!1}}function fj(e){const t=e;return jf(n);function n(r){const i=r;let a;for(a in e)if(i[a]!==t[a])return!1;return!0}}function pj(e){return jf(t);function t(n){return n&&n.type===e}}function jf(e){return t;function t(n,r,i){return!!(mj(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function hj(){return!0}function mj(e){return e!==null&&typeof e=="object"&&"type"in e}function qse(e){return e}const IS=[],gj=!0,ww=!1,wj="skip";function DS(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const a=Bf(i),o=r?-1:1;s(e,void 0,[])();function s(l,u,c){const d=l&&typeof l=="object"?l:{};if(typeof d.type=="string"){const p=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0;Object.defineProperty(f,"name",{value:"node ("+(l.type+(p?"<"+p+">":""))+")"})}return f;function f(){let p=IS,g,w,x;if((!t||a(l,u,c[c.length-1]||void 0))&&(p=yj(n(l,c)),p[0]===ww))return p;if("children"in l&&l.children){const m=l;if(m.children&&p[0]!==wj)for(w=(r?m.children.length:-1)+o,x=c.concat(m);w>-1&&w<m.children.length;){const v=m.children[w];if(g=s(v,w,x)(),g[0]===ww)return g;w=typeof g[1]=="number"?g[1]:w+o}}return p}}}function yj(e){return Array.isArray(e)?e:typeof e=="number"?[gj,e]:e==null?IS:[e]}function vj(e,t,n){const i=Bf((n||{}).ignore||[]),a=bj(t);let o=-1;for(;++o<a.length;)DS(e,"text",s);function s(u,c){let d=-1,f;for(;++d<c.length;){const p=c[d],g=f?f.children:void 0;if(i(p,g?g.indexOf(p):void 0,f))return;f=p}if(f)return l(u,c)}function l(u,c){const d=c[c.length-1],f=a[o][0],p=a[o][1];let g=0;const x=d.children.indexOf(u);let m=!1,v=[];f.lastIndex=0;let b=f.exec(u.value);for(;b;){const T=b.index,_={index:b.index,input:b.input,stack:[...c,u]};let S=p(...b,_);if(typeof S=="string"&&(S=S.length>0?{type:"text",value:S}:void 0),S===!1?f.lastIndex=T+1:(g!==T&&v.push({type:"text",value:u.value.slice(g,T)}),Array.isArray(S)?v.push(...S):S&&v.push(S),g=T+b[0].length,m=!0),!f.global)break;b=f.exec(u.value)}return m?(g<u.value.length&&v.push({type:"text",value:u.value.slice(g)}),d.children.splice(x,1,...v)):v=[u],x+v.length}}function bj(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let r=-1;for(;++r<n.length;){const i=n[r];t.push([xj(i[0]),Ej(i[1])])}return t}function xj(e){return typeof e=="string"?new RegExp(cj(e),"g"):e}function Ej(e){return typeof e=="function"?e:function(){return e}}const yw="phrasing",vw=["autolink","link","image","label"];function Tj(){return{transforms:[Nj],enter:{literalAutolink:Sj,literalAutolinkEmail:bw,literalAutolinkHttp:bw,literalAutolinkWww:bw},exit:{literalAutolink:Rj,literalAutolinkEmail:Aj,literalAutolinkHttp:kj,literalAutolinkWww:Cj}}}function _j(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:yw,notInConstruct:vw},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:yw,notInConstruct:vw},{character:":",before:"[ps]",after:"\\/",inConstruct:yw,notInConstruct:vw}]}}function Sj(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function bw(e){this.config.enter.autolinkProtocol.call(this,e)}function kj(e){this.config.exit.autolinkProtocol.call(this,e)}function Cj(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function Aj(e){this.config.exit.autolinkEmail.call(this,e)}function Rj(e){this.exit(e)}function Nj(e){vj(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Oj],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),Pj]],{ignore:["link","linkReference"]})}function Oj(e,t,n,r,i){let a="";if(!LS(i)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!Ij(n)))return!1;const o=Dj(n+r);if(!o[0])return!1;const s={type:"link",title:null,url:a+t+o[0],children:[{type:"text",value:t+o[0]}]};return o[1]?[s,{type:"text",value:o[1]}]:s}function Pj(e,t,n,r){return!LS(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function Ij(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function Dj(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const i=PS(e,"(");let a=PS(e,")");for(;r!==-1&&i>a;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),a++;return[e,n]}function LS(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Xa(n)||Ff(n))&&(!t||n!==47)}function mr(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}MS.peek=Wj;function Lj(){return{enter:{gfmFootnoteDefinition:Fj,gfmFootnoteDefinitionLabelString:Bj,gfmFootnoteCall:Uj,gfmFootnoteCallString:Hj},exit:{gfmFootnoteDefinition:zj,gfmFootnoteDefinitionLabelString:jj,gfmFootnoteCall:$j,gfmFootnoteCallString:Vj}}}function Mj(){return{unsafe:[{character:"[",inConstruct:["phrasing","label","reference"]}],handlers:{footnoteDefinition:Yj,footnoteReference:MS}}}function Fj(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function Bj(){this.buffer()}function jj(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=mr(this.sliceSerialize(e)).toLowerCase()}function zj(e){this.exit(e)}function Uj(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function Hj(){this.buffer()}function Vj(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=mr(this.sliceSerialize(e)).toLowerCase()}function $j(e){this.exit(e)}function MS(e,t,n,r){const i=n.createTracker(r);let a=i.move("[^");const o=n.enter("footnoteReference"),s=n.enter("reference");return a+=i.move(n.safe(n.associationId(e),{...i.current(),before:a,after:"]"})),s(),o(),a+=i.move("]"),a}function Wj(){return"["}function Yj(e,t,n,r){const i=n.createTracker(r);let a=i.move("[^");const o=n.enter("footnoteDefinition"),s=n.enter("label");return a+=i.move(n.safe(n.associationId(e),{...i.current(),before:a,after:"]"})),s(),a+=i.move("]:"+(e.children&&e.children.length>0?" ":"")),i.shift(4),a+=i.move(n.indentLines(n.containerFlow(e,i.current()),qj)),o(),a}function qj(e,t,n){return t===0?e:(n?"":" ")+e}const Gj=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];FS.peek=Jj;function Kj(){return{canContainEols:["delete"],enter:{strikethrough:Qj},exit:{strikethrough:Zj}}}function Xj(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:Gj}],handlers:{delete:FS}}}function Qj(e){this.enter({type:"delete",children:[]},e)}function Zj(e){this.exit(e)}function FS(e,t,n,r){const i=n.createTracker(r),a=n.enter("strikethrough");let o=i.move("~~");return o+=n.containerPhrasing(e,{...i.current(),before:o,after:"~"}),o+=i.move("~~"),a(),o}function Jj(){return"~"}function ez(e,t={}){const n=(t.align||[]).concat(),r=t.stringLength||nz,i=[],a=[],o=[],s=[];let l=0,u=-1;for(;++u<e.length;){const g=[],w=[];let x=-1;for(e[u].length>l&&(l=e[u].length);++x<e[u].length;){const m=tz(e[u][x]);if(t.alignDelimiters!==!1){const v=r(m);w[x]=v,(s[x]===void 0||v>s[x])&&(s[x]=v)}g.push(m)}a[u]=g,o[u]=w}let c=-1;if(typeof n=="object"&&"length"in n)for(;++c<l;)i[c]=BS(n[c]);else{const g=BS(n);for(;++c<l;)i[c]=g}c=-1;const d=[],f=[];for(;++c<l;){const g=i[c];let w="",x="";g===99?(w=":",x=":"):g===108?w=":":g===114&&(x=":");let m=t.alignDelimiters===!1?1:Math.max(1,s[c]-w.length-x.length);const v=w+"-".repeat(m)+x;t.alignDelimiters!==!1&&(m=w.length+m+x.length,m>s[c]&&(s[c]=m),f[c]=m),d[c]=v}a.splice(1,0,d),o.splice(1,0,f),u=-1;const p=[];for(;++u<a.length;){const g=a[u],w=o[u];c=-1;const x=[];for(;++c<l;){const m=g[c]||"";let v="",b="";if(t.alignDelimiters!==!1){const T=s[c]-(w[c]||0),_=i[c];_===114?v=" ".repeat(T):_===99?T%2?(v=" ".repeat(T/2+.5),b=" ".repeat(T/2-.5)):(v=" ".repeat(T/2),b=v):b=" ".repeat(T)}t.delimiterStart!==!1&&!c&&x.push("|"),t.padding!==!1&&!(t.alignDelimiters===!1&&m==="")&&(t.delimiterStart!==!1||c)&&x.push(" "),t.alignDelimiters!==!1&&x.push(v),x.push(m),t.alignDelimiters!==!1&&x.push(b),t.padding!==!1&&x.push(" "),(t.delimiterEnd!==!1||c!==l-1)&&x.push("|")}p.push(t.delimiterEnd===!1?x.join("").replace(/ +$/,""):x.join(""))}return p.join(`
54
+ `)}function tz(e){return e==null?"":String(e)}function nz(e){return e.length}function BS(e){const t=typeof e=="string"?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}const jS={}.hasOwnProperty;function zS(e,t){const n=t||{};function r(i,...a){let o=r.invalid;const s=r.handlers;if(i&&jS.call(i,e)){const l=String(i[e]);o=jS.call(s,l)?s[l]:r.unknown}if(o)return o.call(this,i,...a)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}function rz(e,t,n,r){const i=n.enter("blockquote"),a=n.createTracker(r);a.move("> "),a.shift(2);const o=n.indentLines(n.containerFlow(e,a.current()),iz);return i(),o}function iz(e,t,n){return">"+(n?"":" ")+e}function az(e,t){return US(e,t.inConstruct,!0)&&!US(e,t.notInConstruct,!1)}function US(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r<t.length;)if(e.includes(t[r]))return!0;return!1}function HS(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
55
+ `&&az(n.stack,n.unsafe[i]))return/[ \t]/.test(r.before)?"":" ";return`\\
56
+ `}function oz(e,t){const n=String(e);let r=n.indexOf(t),i=r,a=0,o=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;r!==-1;)r===i?++a>o&&(o=a):a=1,i=r+t.length,r=n.indexOf(t,i);return o}function sz(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function lz(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function uz(e,t,n,r){const i=lz(n),a=e.value||"",o=i==="`"?"GraveAccent":"Tilde";if(sz(e,n)){const d=n.enter("codeIndented"),f=n.indentLines(a,cz);return d(),f}const s=n.createTracker(r),l=i.repeat(Math.max(oz(a,i)+1,3)),u=n.enter("codeFenced");let c=s.move(l);if(e.lang){const d=n.enter(`codeFencedLang${o}`);c+=s.move(n.safe(e.lang,{before:c,after:" ",encode:["`"],...s.current()})),d()}if(e.lang&&e.meta){const d=n.enter(`codeFencedMeta${o}`);c+=s.move(" "),c+=s.move(n.safe(e.meta,{before:c,after:`
57
+ `,encode:["`"],...s.current()})),d()}return c+=s.move(`
58
+ `),a&&(c+=s.move(a+`
59
+ `)),c+=s.move(l),u(),c}function cz(e,t,n){return(n?"":" ")+e}function xw(e){const t=e.options.quote||'"';if(t!=='"'&&t!=="'")throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function dz(e,t,n,r){const i=xw(n),a=i==='"'?"Quote":"Apostrophe",o=n.enter("definition");let s=n.enter("label");const l=n.createTracker(r);let u=l.move("[");return u+=l.move(n.safe(n.associationId(e),{before:u,after:"]",...l.current()})),u+=l.move("]: "),s(),!e.url||/[\0- \u007F]/.test(e.url)?(s=n.enter("destinationLiteral"),u+=l.move("<"),u+=l.move(n.safe(e.url,{before:u,after:">",...l.current()})),u+=l.move(">")):(s=n.enter("destinationRaw"),u+=l.move(n.safe(e.url,{before:u,after:e.title?" ":`
60
+ `,...l.current()}))),s(),e.title&&(s=n.enter(`title${a}`),u+=l.move(" "+i),u+=l.move(n.safe(e.title,{before:u,after:i,...l.current()})),u+=l.move(i),s()),o(),u}function fz(e){const t=e.options.emphasis||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}VS.peek=pz;function VS(e,t,n,r){const i=fz(n),a=n.enter("emphasis"),o=n.createTracker(r);let s=o.move(i);return s+=o.move(n.containerPhrasing(e,{before:s,after:i,...o.current()})),s+=o.move(i),a(),s}function pz(e,t,n){return n.options.emphasis||"*"}function zf(e,t,n,r){let i,a,o;typeof t=="function"&&typeof n!="function"?(a=void 0,o=t,i=n):(a=t,o=n,i=r),DS(e,a,s,i);function s(l,u){const c=u[u.length-1],d=c?c.children.indexOf(l):void 0;return o(l,d,c)}}const hz={};function Ew(e,t){const n=hz,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,i=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return $S(e,r,i)}function $S(e,t,n){if(mz(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return WS(e.children,t,n)}return Array.isArray(e)?WS(e,t,n):""}function WS(e,t,n){const r=[];let i=-1;for(;++i<e.length;)r[i]=$S(e[i],t,n);return r.join("")}function mz(e){return!!(e&&typeof e=="object")}function gz(e,t){let n=!1;return zf(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,ww}),!!((!e.depth||e.depth<3)&&Ew(e)&&(t.options.setext||n))}function wz(e,t,n,r){const i=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(gz(e,n)){const c=n.enter("headingSetext"),d=n.enter("phrasing"),f=n.containerPhrasing(e,{...a.current(),before:`
61
+ `,after:`
62
+ `});return d(),c(),f+`
63
+ `+(i===1?"=":"-").repeat(f.length-(Math.max(f.lastIndexOf("\r"),f.lastIndexOf(`
64
+ `))+1))}const o="#".repeat(i),s=n.enter("headingAtx"),l=n.enter("phrasing");a.move(o+" ");let u=n.containerPhrasing(e,{before:"# ",after:`
65
+ `,...a.current()});return/^[\t ]/.test(u)&&(u="&#x"+u.charCodeAt(0).toString(16).toUpperCase()+";"+u.slice(1)),u=u?o+" "+u:o,n.options.closeAtx&&(u+=" "+o),l(),s(),u}YS.peek=yz;function YS(e){return e.value||""}function yz(){return"<"}qS.peek=vz;function qS(e,t,n,r){const i=xw(n),a=i==='"'?"Quote":"Apostrophe",o=n.enter("image");let s=n.enter("label");const l=n.createTracker(r);let u=l.move("![");return u+=l.move(n.safe(e.alt,{before:u,after:"]",...l.current()})),u+=l.move("]("),s(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(s=n.enter("destinationLiteral"),u+=l.move("<"),u+=l.move(n.safe(e.url,{before:u,after:">",...l.current()})),u+=l.move(">")):(s=n.enter("destinationRaw"),u+=l.move(n.safe(e.url,{before:u,after:e.title?" ":")",...l.current()}))),s(),e.title&&(s=n.enter(`title${a}`),u+=l.move(" "+i),u+=l.move(n.safe(e.title,{before:u,after:i,...l.current()})),u+=l.move(i),s()),u+=l.move(")"),o(),u}function vz(){return"!"}GS.peek=bz;function GS(e,t,n,r){const i=e.referenceType,a=n.enter("imageReference");let o=n.enter("label");const s=n.createTracker(r);let l=s.move("![");const u=n.safe(e.alt,{before:l,after:"]",...s.current()});l+=s.move(u+"]["),o();const c=n.stack;n.stack=[],o=n.enter("reference");const d=n.safe(n.associationId(e),{before:l,after:"]",...s.current()});return o(),n.stack=c,a(),i==="full"||!u||u!==d?l+=s.move(d+"]"):i==="shortcut"?l=l.slice(0,-1):l+=s.move("]"),l}function bz(){return"!"}KS.peek=xz;function KS(e,t,n){let r=e.value||"",i="`",a=-1;for(;new RegExp("(^|[^`])"+i+"([^`]|$)").test(r);)i+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=" "+r+" ");++a<n.unsafe.length;){const o=n.unsafe[a],s=n.compilePattern(o);let l;if(o.atBreak)for(;l=s.exec(r);){let u=l.index;r.charCodeAt(u)===10&&r.charCodeAt(u-1)===13&&u--,r=r.slice(0,u)+" "+r.slice(l.index+1)}}return i+r+i}function xz(){return"`"}function XS(e,t){const n=Ew(e);return!!(!t.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type==="text"&&(n===e.url||"mailto:"+n===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}QS.peek=Ez;function QS(e,t,n,r){const i=xw(n),a=i==='"'?"Quote":"Apostrophe",o=n.createTracker(r);let s,l;if(XS(e,n)){const c=n.stack;n.stack=[],s=n.enter("autolink");let d=o.move("<");return d+=o.move(n.containerPhrasing(e,{before:d,after:">",...o.current()})),d+=o.move(">"),s(),n.stack=c,d}s=n.enter("link"),l=n.enter("label");let u=o.move("[");return u+=o.move(n.containerPhrasing(e,{before:u,after:"](",...o.current()})),u+=o.move("]("),l(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(l=n.enter("destinationLiteral"),u+=o.move("<"),u+=o.move(n.safe(e.url,{before:u,after:">",...o.current()})),u+=o.move(">")):(l=n.enter("destinationRaw"),u+=o.move(n.safe(e.url,{before:u,after:e.title?" ":")",...o.current()}))),l(),e.title&&(l=n.enter(`title${a}`),u+=o.move(" "+i),u+=o.move(n.safe(e.title,{before:u,after:i,...o.current()})),u+=o.move(i),l()),u+=o.move(")"),s(),u}function Ez(e,t,n){return XS(e,n)?"<":"["}ZS.peek=Tz;function ZS(e,t,n,r){const i=e.referenceType,a=n.enter("linkReference");let o=n.enter("label");const s=n.createTracker(r);let l=s.move("[");const u=n.containerPhrasing(e,{before:l,after:"]",...s.current()});l+=s.move(u+"]["),o();const c=n.stack;n.stack=[],o=n.enter("reference");const d=n.safe(n.associationId(e),{before:l,after:"]",...s.current()});return o(),n.stack=c,a(),i==="full"||!u||u!==d?l+=s.move(d+"]"):i==="shortcut"?l=l.slice(0,-1):l+=s.move("]"),l}function Tz(){return"["}function Tw(e){const t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function _z(e){const t=Tw(e),n=e.options.bulletOther;if(!n)return t==="*"?"-":"*";if(n!=="*"&&n!=="+"&&n!=="-")throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function Sz(e){const t=e.options.bulletOrdered||".";if(t!=="."&&t!==")")throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function JS(e){const t=e.options.rule||"*";if(t!=="*"&&t!=="-"&&t!=="_")throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function kz(e,t,n,r){const i=n.enter("list"),a=n.bulletCurrent;let o=e.ordered?Sz(n):Tw(n);const s=e.ordered?o==="."?")":".":_z(n);let l=t&&n.bulletLastUsed?o===n.bulletLastUsed:!1;if(!e.ordered){const c=e.children?e.children[0]:void 0;if((o==="*"||o==="-")&&c&&(!c.children||!c.children[0])&&n.stack[n.stack.length-1]==="list"&&n.stack[n.stack.length-2]==="listItem"&&n.stack[n.stack.length-3]==="list"&&n.stack[n.stack.length-4]==="listItem"&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(l=!0),JS(n)===o&&c){let d=-1;for(;++d<e.children.length;){const f=e.children[d];if(f&&f.type==="listItem"&&f.children&&f.children[0]&&f.children[0].type==="thematicBreak"){l=!0;break}}}}l&&(o=s),n.bulletCurrent=o;const u=n.containerFlow(e,r);return n.bulletLastUsed=o,n.bulletCurrent=a,i(),u}function Cz(e){const t=e.options.listItemIndent||"one";if(t!=="tab"&&t!=="one"&&t!=="mixed")throw new Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function Az(e,t,n,r){const i=Cz(n);let a=n.bulletCurrent||Tw(n);t&&t.type==="list"&&t.ordered&&(a=(typeof t.start=="number"&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+a);let o=a.length+1;(i==="tab"||i==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(o=Math.ceil(o/4)*4);const s=n.createTracker(r);s.move(a+" ".repeat(o-a.length)),s.shift(o);const l=n.enter("listItem"),u=n.indentLines(n.containerFlow(e,s.current()),c);return l(),u;function c(d,f,p){return f?(p?"":" ".repeat(o))+d:(p?a:a+" ".repeat(o-a.length))+d}}function Rz(e,t,n,r){const i=n.enter("paragraph"),a=n.enter("phrasing"),o=n.containerPhrasing(e,r);return a(),i(),o}const Nz=Bf(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function Oz(e,t,n,r){return(e.children.some(function(o){return Nz(o)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function Pz(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}ek.peek=Iz;function ek(e,t,n,r){const i=Pz(n),a=n.enter("strong"),o=n.createTracker(r);let s=o.move(i+i);return s+=o.move(n.containerPhrasing(e,{before:s,after:i,...o.current()})),s+=o.move(i+i),a(),s}function Iz(e,t,n){return n.options.strong||"*"}function Dz(e,t,n,r){return n.safe(e.value,r)}function Lz(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function Mz(e,t,n){const r=(JS(n)+(n.options.ruleSpaces?" ":"")).repeat(Lz(n));return n.options.ruleSpaces?r.slice(0,-1):r}const tk={blockquote:rz,break:HS,code:uz,definition:dz,emphasis:VS,hardBreak:HS,heading:wz,html:YS,image:qS,imageReference:GS,inlineCode:KS,link:QS,linkReference:ZS,list:kz,listItem:Az,paragraph:Rz,root:Oz,strong:ek,text:Dz,thematicBreak:Mz},nk=document.createElement("i");function _w(e){const t="&"+e+";";nk.innerHTML=t;const n=nk.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function rk(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}const Fz=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function Bz(e){return e.replace(Fz,jz)}function jz(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const i=n.charCodeAt(1),a=i===120||i===88;return rk(n.slice(a?2:1),a?16:10)}return _w(n)||e}function zz(){return{enter:{table:Uz,tableData:ik,tableHeader:ik,tableRow:Vz},exit:{codeText:$z,table:Hz,tableData:Sw,tableHeader:Sw,tableRow:Sw}}}function Uz(e){const t=e._align;this.enter({type:"table",align:t.map(function(n){return n==="none"?null:n}),children:[]},e),this.data.inTable=!0}function Hz(e){this.exit(e),this.data.inTable=void 0}function Vz(e){this.enter({type:"tableRow",children:[]},e)}function Sw(e){this.exit(e)}function ik(e){this.enter({type:"tableCell",children:[]},e)}function $z(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,Wz));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function Wz(e,t){return t==="|"?t:e}function Yz(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,i=t.stringLength,a=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
66
+ `,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:f,table:o,tableCell:l,tableRow:s}};function o(p,g,w,x){return u(c(p,w,x),p.align)}function s(p,g,w,x){const m=d(p,w,x),v=u([m]);return v.slice(0,v.indexOf(`
67
+ `))}function l(p,g,w,x){const m=w.enter("tableCell"),v=w.enter("phrasing"),b=w.containerPhrasing(p,{...x,before:a,after:a});return v(),m(),b}function u(p,g){return ez(p,{align:g,alignDelimiters:r,padding:n,stringLength:i})}function c(p,g,w){const x=p.children;let m=-1;const v=[],b=g.enter("table");for(;++m<x.length;)v[m]=d(x[m],g,w);return b(),v}function d(p,g,w){const x=p.children;let m=-1;const v=[],b=g.enter("tableRow");for(;++m<x.length;)v[m]=l(x[m],p,g,w);return b(),v}function f(p,g,w){let x=tk.inlineCode(p,g,w);return w.stack.includes("tableCell")&&(x=x.replace(/\|/g,"\\$&")),x}}function qz(){return{exit:{taskListCheckValueChecked:ak,taskListCheckValueUnchecked:ak,paragraph:Kz}}}function Gz(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:Xz}}}function ak(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function Kz(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const n=this.stack[this.stack.length-1];n.type;const r=n.children[0];if(r&&r.type==="text"){const i=t.children;let a=-1,o;for(;++a<i.length;){const s=i[a];if(s.type==="paragraph"){o=s;break}}o===n&&(r.value=r.value.slice(1),r.value.length===0?n.children.shift():n.position&&r.position&&typeof r.position.start.offset=="number"&&(r.position.start.column++,r.position.start.offset++,n.position.start=Object.assign({},r.position.start)))}}this.exit(e)}function Xz(e,t,n,r){const i=e.children[0],a=typeof e.checked=="boolean"&&i&&i.type==="paragraph",o="["+(e.checked?"x":" ")+"] ",s=n.createTracker(r);a&&s.move(o);let l=tk.listItem(e,t,n,{...r,...s.current()});return a&&(l=l.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,u)),l;function u(c){return c+o}}function Qz(){return[Tj(),Lj(),Kj(),zz(),qz()]}function Zz(e){return{extensions:[_j(),Mj(),Xj(),Yz(e),Gz()]}}function Wn(e,t,n,r){const i=e.length;let a=0,o;if(t<0?t=-t>i?0:i+t:t=t>i?i:t,n=n>0?n:0,r.length<1e4)o=Array.from(r),o.unshift(t,n),e.splice(...o);else for(n&&e.splice(t,n);a<r.length;)o=r.slice(a,a+1e4),o.unshift(t,0),e.splice(...o),a+=1e4,t+=1e4}function Yn(e,t){return e.length>0?(Wn(e,e.length,0,t),e):t}const ok={}.hasOwnProperty;function sk(e){const t={};let n=-1;for(;++n<e.length;)Jz(t,e[n]);return t}function Jz(e,t){let n;for(n in t){const i=(ok.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let o;if(a)for(o in a){ok.call(i,o)||(i[o]=[]);const s=a[o];eU(i[o],Array.isArray(s)?s:s?[s]:[])}}}function eU(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);Wn(e,0,0,r)}const tU={tokenize:sU,partial:!0},lk={tokenize:lU,partial:!0},uk={tokenize:uU,partial:!0},ck={tokenize:cU,partial:!0},nU={tokenize:dU,partial:!0},dk={name:"wwwAutolink",tokenize:aU,previous:pk},fk={name:"protocolAutolink",tokenize:oU,previous:hk},fi={name:"emailAutolink",tokenize:iU,previous:mk},Lr={};function rU(){return{text:Lr}}let Qa=48;for(;Qa<123;)Lr[Qa]=fi,Qa++,Qa===58?Qa=65:Qa===91&&(Qa=97);Lr[43]=fi,Lr[45]=fi,Lr[46]=fi,Lr[95]=fi,Lr[72]=[fi,fk],Lr[104]=[fi,fk],Lr[87]=[fi,dk],Lr[119]=[fi,dk];function iU(e,t,n){const r=this;let i,a;return o;function o(d){return!kw(d)||!mk.call(r,r.previous)||Cw(r.events)?n(d):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),s(d))}function s(d){return kw(d)?(e.consume(d),s):d===64?(e.consume(d),l):n(d)}function l(d){return d===46?e.check(nU,c,u)(d):d===45||d===95||$t(d)?(a=!0,e.consume(d),l):c(d)}function u(d){return e.consume(d),i=!0,l}function c(d){return a&&i&&an(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(d)):n(d)}}function aU(e,t,n){const r=this;return i;function i(o){return o!==87&&o!==119||!pk.call(r,r.previous)||Cw(r.events)?n(o):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(tU,e.attempt(lk,e.attempt(uk,a),n),n)(o))}function a(o){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(o)}}function oU(e,t,n){const r=this;let i="",a=!1;return o;function o(d){return(d===72||d===104)&&hk.call(r,r.previous)&&!Cw(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),i+=String.fromCodePoint(d),e.consume(d),s):n(d)}function s(d){if(an(d)&&i.length<5)return i+=String.fromCodePoint(d),e.consume(d),s;if(d===58){const f=i.toLowerCase();if(f==="http"||f==="https")return e.consume(d),l}return n(d)}function l(d){return d===47?(e.consume(d),a?u:(a=!0,l)):n(d)}function u(d){return d===null||Mf(d)||qe(d)||Xa(d)||Ff(d)?n(d):e.attempt(lk,e.attempt(uk,c),n)(d)}function c(d){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(d)}}function sU(e,t,n){let r=0;return i;function i(o){return(o===87||o===119)&&r<3?(r++,e.consume(o),i):o===46&&r===3?(e.consume(o),a):n(o)}function a(o){return o===null?n(o):t(o)}}function lU(e,t,n){let r,i,a;return o;function o(u){return u===46||u===95?e.check(ck,l,s)(u):u===null||qe(u)||Xa(u)||u!==45&&Ff(u)?l(u):(a=!0,e.consume(u),o)}function s(u){return u===95?r=!0:(i=r,r=void 0),e.consume(u),o}function l(u){return i||r||!a?n(u):t(u)}}function uU(e,t){let n=0,r=0;return i;function i(o){return o===40?(n++,e.consume(o),i):o===41&&r<n?a(o):o===33||o===34||o===38||o===39||o===41||o===42||o===44||o===46||o===58||o===59||o===60||o===63||o===93||o===95||o===126?e.check(ck,t,a)(o):o===null||qe(o)||Xa(o)?t(o):(e.consume(o),i)}function a(o){return o===41&&r++,e.consume(o),i}}function cU(e,t,n){return r;function r(s){return s===33||s===34||s===39||s===41||s===42||s===44||s===46||s===58||s===59||s===63||s===95||s===126?(e.consume(s),r):s===38?(e.consume(s),a):s===93?(e.consume(s),i):s===60||s===null||qe(s)||Xa(s)?t(s):n(s)}function i(s){return s===null||s===40||s===91||qe(s)||Xa(s)?t(s):r(s)}function a(s){return an(s)?o(s):n(s)}function o(s){return s===59?(e.consume(s),r):an(s)?(e.consume(s),o):n(s)}}function dU(e,t,n){return r;function r(a){return e.consume(a),i}function i(a){return $t(a)?n(a):t(a)}}function pk(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||qe(e)}function hk(e){return!an(e)}function mk(e){return!(e===47||kw(e))}function kw(e){return e===43||e===45||e===46||e===95||$t(e)}function Cw(e){let t=e.length,n=!1;for(;t--;){const r=e[t][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}function fs(e){const t=[];let n=-1,r=0,i=0;for(;++n<e.length;){const a=e.charCodeAt(n);let o="";if(a===37&&$t(e.charCodeAt(n+1))&&$t(e.charCodeAt(n+2)))i=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(o=String.fromCharCode(a));else if(a>55295&&a<57344){const s=e.charCodeAt(n+1);a<56320&&s>56319&&s<57344?(o=String.fromCharCode(a,s),i=1):o="�"}else o=String.fromCharCode(a);o&&(t.push(e.slice(r,n),encodeURIComponent(o)),r=n+i+1,o=""),i&&(n+=i,i=0)}return t.join("")+e.slice(r)}function Uf(e){if(e===null||qe(e)||Xa(e))return 1;if(Ff(e))return 2}function Hf(e,t,n){const r=[];let i=-1;for(;++i<e.length;){const a=e[i].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}const Aw={name:"attention",tokenize:pU,resolveAll:fU};function fU(e,t){let n=-1,r,i,a,o,s,l,u,c;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;l=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const d=Object.assign({},e[r][1].end),f=Object.assign({},e[n][1].start);gk(d,-l),gk(f,l),o={type:l>1?"strongSequence":"emphasisSequence",start:d,end:Object.assign({},e[r][1].end)},s={type:l>1?"strongSequence":"emphasisSequence",start:Object.assign({},e[n][1].start),end:f},a={type:l>1?"strongText":"emphasisText",start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},i={type:l>1?"strong":"emphasis",start:Object.assign({},o.start),end:Object.assign({},s.end)},e[r][1].end=Object.assign({},o.start),e[n][1].start=Object.assign({},s.end),u=[],e[r][1].end.offset-e[r][1].start.offset&&(u=Yn(u,[["enter",e[r][1],t],["exit",e[r][1],t]])),u=Yn(u,[["enter",i,t],["enter",o,t],["exit",o,t],["enter",a,t]]),u=Yn(u,Hf(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),u=Yn(u,[["exit",a,t],["enter",s,t],["exit",s,t],["exit",i,t]]),e[n][1].end.offset-e[n][1].start.offset?(c=2,u=Yn(u,[["enter",e[n][1],t],["exit",e[n][1],t]])):c=0,Wn(e,r-1,n-r+3,u),n=r+u.length-c-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function pU(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=Uf(r);let a;return o;function o(l){return a=l,e.enter("attentionSequence"),s(l)}function s(l){if(l===a)return e.consume(l),s;const u=e.exit("attentionSequence"),c=Uf(l),d=!c||c===2&&i||n.includes(l),f=!i||i===2&&c||n.includes(r);return u._open=!!(a===42?d:d&&(i||!f)),u._close=!!(a===42?f:f&&(c||!d)),t(l)}}function gk(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const hU={name:"autolink",tokenize:mU};function mU(e,t,n){let r=0;return i;function i(p){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(p){return an(p)?(e.consume(p),o):p===64?n(p):u(p)}function o(p){return p===43||p===45||p===46||$t(p)?(r=1,s(p)):u(p)}function s(p){return p===58?(e.consume(p),r=0,l):(p===43||p===45||p===46||$t(p))&&r++<32?(e.consume(p),s):(r=0,u(p))}function l(p){return p===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):p===null||p===32||p===60||Mf(p)?n(p):(e.consume(p),l)}function u(p){return p===64?(e.consume(p),c):sj(p)?(e.consume(p),u):n(p)}function c(p){return $t(p)?d(p):n(p)}function d(p){return p===46?(e.consume(p),r=0,c):p===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):f(p)}function f(p){if((p===45||$t(p))&&r++<63){const g=p===45?f:d;return e.consume(p),g}return n(p)}}function Le(e,t,n,r){const i=r?r-1:Number.POSITIVE_INFINITY;let a=0;return o;function o(l){return Oe(l)?(e.enter(n),s(l)):t(l)}function s(l){return Oe(l)&&a++<i?(e.consume(l),s):(e.exit(n),t(l))}}const Eu={tokenize:gU,partial:!0};function gU(e,t,n){return r;function r(a){return Oe(a)?Le(e,i,"linePrefix")(a):i(a)}function i(a){return a===null||pe(a)?t(a):n(a)}}const wk={name:"blockQuote",tokenize:wU,continuation:{tokenize:yU},exit:vU};function wU(e,t,n){const r=this;return i;function i(o){if(o===62){const s=r.containerState;return s.open||(e.enter("blockQuote",{_container:!0}),s.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(o),e.exit("blockQuoteMarker"),a}return n(o)}function a(o){return Oe(o)?(e.enter("blockQuotePrefixWhitespace"),e.consume(o),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(o))}}function yU(e,t,n){const r=this;return i;function i(o){return Oe(o)?Le(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(o):a(o)}function a(o){return e.attempt(wk,t,n)(o)}}function vU(e){e.exit("blockQuote")}const yk={name:"characterEscape",tokenize:bU};function bU(e,t,n){return r;function r(a){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(a),e.exit("escapeMarker"),i}function i(a){return uj(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const vk={name:"characterReference",tokenize:xU};function xU(e,t,n){const r=this;let i=0,a,o;return s;function s(d){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),l}function l(d){return d===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(d),e.exit("characterReferenceMarkerNumeric"),u):(e.enter("characterReferenceValue"),a=31,o=$t,c(d))}function u(d){return d===88||d===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(d),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,o=lj,c):(e.enter("characterReferenceValue"),a=7,o=gw,c(d))}function c(d){if(d===59&&i){const f=e.exit("characterReferenceValue");return o===$t&&!_w(r.sliceSerialize(f))?n(d):(e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return o(d)&&i++<a?(e.consume(d),c):n(d)}}const bk={tokenize:TU,partial:!0},xk={name:"codeFenced",tokenize:EU,concrete:!0};function EU(e,t,n){const r=this,i={tokenize:_,partial:!0};let a=0,o=0,s;return l;function l(S){return u(S)}function u(S){const R=r.events[r.events.length-1];return a=R&&R[1].type==="linePrefix"?R[2].sliceSerialize(R[1],!0).length:0,s=S,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),c(S)}function c(S){return S===s?(o++,e.consume(S),c):o<3?n(S):(e.exit("codeFencedFenceSequence"),Oe(S)?Le(e,d,"whitespace")(S):d(S))}function d(S){return S===null||pe(S)?(e.exit("codeFencedFence"),r.interrupt?t(S):e.check(bk,w,T)(S)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),f(S))}function f(S){return S===null||pe(S)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),d(S)):Oe(S)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Le(e,p,"whitespace")(S)):S===96&&S===s?n(S):(e.consume(S),f)}function p(S){return S===null||pe(S)?d(S):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),g(S))}function g(S){return S===null||pe(S)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),d(S)):S===96&&S===s?n(S):(e.consume(S),g)}function w(S){return e.attempt(i,T,x)(S)}function x(S){return e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),m}function m(S){return a>0&&Oe(S)?Le(e,v,"linePrefix",a+1)(S):v(S)}function v(S){return S===null||pe(S)?e.check(bk,w,T)(S):(e.enter("codeFlowValue"),b(S))}function b(S){return S===null||pe(S)?(e.exit("codeFlowValue"),v(S)):(e.consume(S),b)}function T(S){return e.exit("codeFenced"),t(S)}function _(S,R,P){let B=0;return N;function N(ee){return S.enter("lineEnding"),S.consume(ee),S.exit("lineEnding"),H}function H(ee){return S.enter("codeFencedFence"),Oe(ee)?Le(S,U,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(ee):U(ee)}function U(ee){return ee===s?(S.enter("codeFencedFenceSequence"),K(ee)):P(ee)}function K(ee){return ee===s?(B++,S.consume(ee),K):B>=o?(S.exit("codeFencedFenceSequence"),Oe(ee)?Le(S,X,"whitespace")(ee):X(ee)):P(ee)}function X(ee){return ee===null||pe(ee)?(S.exit("codeFencedFence"),R(ee)):P(ee)}}}function TU(e,t,n){const r=this;return i;function i(o){return o===null?n(o):(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),a)}function a(o){return r.parser.lazy[r.now().line]?n(o):t(o)}}const Rw={name:"codeIndented",tokenize:SU},_U={tokenize:kU,partial:!0};function SU(e,t,n){const r=this;return i;function i(u){return e.enter("codeIndented"),Le(e,a,"linePrefix",5)(u)}function a(u){const c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?o(u):n(u)}function o(u){return u===null?l(u):pe(u)?e.attempt(_U,o,l)(u):(e.enter("codeFlowValue"),s(u))}function s(u){return u===null||pe(u)?(e.exit("codeFlowValue"),o(u)):(e.consume(u),s)}function l(u){return e.exit("codeIndented"),t(u)}}function kU(e,t,n){const r=this;return i;function i(o){return r.parser.lazy[r.now().line]?n(o):pe(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),i):Le(e,a,"linePrefix",5)(o)}function a(o){const s=r.events[r.events.length-1];return s&&s[1].type==="linePrefix"&&s[2].sliceSerialize(s[1],!0).length>=4?t(o):pe(o)?i(o):n(o)}}const CU={name:"codeText",tokenize:NU,resolve:AU,previous:RU};function AU(e){let t=e.length-4,n=3,r,i;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)i===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(i=r):(r===t||e[r][1].type==="lineEnding")&&(e[i][1].type="codeTextData",r!==i+2&&(e[i][1].end=e[r-1][1].end,e.splice(i+2,r-i-2),t-=r-i-2,r=i+2),i=void 0);return e}function RU(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function NU(e,t,n){let r=0,i,a;return o;function o(d){return e.enter("codeText"),e.enter("codeTextSequence"),s(d)}function s(d){return d===96?(e.consume(d),r++,s):(e.exit("codeTextSequence"),l(d))}function l(d){return d===null?n(d):d===32?(e.enter("space"),e.consume(d),e.exit("space"),l):d===96?(a=e.enter("codeTextSequence"),i=0,c(d)):pe(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),l):(e.enter("codeTextData"),u(d))}function u(d){return d===null||d===32||d===96||pe(d)?(e.exit("codeTextData"),l(d)):(e.consume(d),u)}function c(d){return d===96?(e.consume(d),i++,c):i===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(d)):(a.type="codeTextData",u(d))}}class OU{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,n){const r=n??Number.POSITIVE_INFINITY;return r<this.left.length?this.left.slice(t,r):t>this.left.length?this.right.slice(this.right.length-r+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-r+this.left.length).reverse())}splice(t,n,r){const i=n||0;this.setCursor(Math.trunc(t));const a=this.right.splice(this.right.length-i,Number.POSITIVE_INFINITY);return r&&Tu(this.left,r),a.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),Tu(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Tu(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const n=this.left.splice(t,Number.POSITIVE_INFINITY);Tu(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Tu(this.left,n.reverse())}}}function Tu(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function Ek(e){const t={};let n=-1,r,i,a,o,s,l,u;const c=new OU(e);for(;++n<c.length;){for(;n in t;)n=t[n];if(r=c.get(n),n&&r[1].type==="chunkFlow"&&c.get(n-1)[1].type==="listItemPrefix"&&(l=r[1]._tokenizer.events,a=0,a<l.length&&l[a][1].type==="lineEndingBlank"&&(a+=2),a<l.length&&l[a][1].type==="content"))for(;++a<l.length&&l[a][1].type!=="content";)l[a][1].type==="chunkText"&&(l[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,PU(c,n)),n=t[n],u=!0);else if(r[1]._container){for(a=n,i=void 0;a--&&(o=c.get(a),o[1].type==="lineEnding"||o[1].type==="lineEndingBlank");)o[0]==="enter"&&(i&&(c.get(i)[1].type="lineEndingBlank"),o[1].type="lineEnding",i=a);i&&(r[1].end=Object.assign({},c.get(i)[1].start),s=c.slice(i,n),s.unshift(r),c.splice(i,n-i+1,s))}}return Wn(e,0,Number.POSITIVE_INFINITY,c.slice(0)),!u}function PU(e,t){const n=e.get(t)[1],r=e.get(t)[2];let i=t-1;const a=[],o=n._tokenizer||r.parser[n.contentType](n.start),s=o.events,l=[],u={};let c,d,f=-1,p=n,g=0,w=0;const x=[w];for(;p;){for(;e.get(++i)[1]!==p;);a.push(i),p._tokenizer||(c=r.sliceStream(p),p.next||c.push(null),d&&o.defineSkip(p.start),p._isInFirstContentOfListItem&&(o._gfmTasklistFirstContentOfListItem=!0),o.write(c),p._isInFirstContentOfListItem&&(o._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++f<s.length;)s[f][0]==="exit"&&s[f-1][0]==="enter"&&s[f][1].type===s[f-1][1].type&&s[f][1].start.line!==s[f][1].end.line&&(w=f+1,x.push(w),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(o.events=[],p?(p._tokenizer=void 0,p.previous=void 0):x.pop(),f=x.length;f--;){const m=s.slice(x[f],x[f+1]),v=a.pop();l.push([v,v+m.length-1]),e.splice(v,2,m)}for(l.reverse(),f=-1;++f<l.length;)u[g+l[f][0]]=g+l[f][1],g+=l[f][1]-l[f][0]-1;return u}const IU={tokenize:MU,resolve:LU},DU={tokenize:FU,partial:!0};function LU(e){return Ek(e),e}function MU(e,t){let n;return r;function r(s){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),i(s)}function i(s){return s===null?a(s):pe(s)?e.check(DU,o,a)(s):(e.consume(s),i)}function a(s){return e.exit("chunkContent"),e.exit("content"),t(s)}function o(s){return e.consume(s),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,i}}function FU(e,t,n){const r=this;return i;function i(o){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),Le(e,a,"linePrefix")}function a(o){if(o===null||pe(o))return n(o);const s=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&s&&s[1].type==="linePrefix"&&s[2].sliceSerialize(s[1],!0).length>=4?t(o):e.interrupt(r.parser.constructs.flow,n,t)(o)}}function Tk(e,t,n,r,i,a,o,s,l){const u=l||Number.POSITIVE_INFINITY;let c=0;return d;function d(m){return m===60?(e.enter(r),e.enter(i),e.enter(a),e.consume(m),e.exit(a),f):m===null||m===32||m===41||Mf(m)?n(m):(e.enter(r),e.enter(o),e.enter(s),e.enter("chunkString",{contentType:"string"}),w(m))}function f(m){return m===62?(e.enter(a),e.consume(m),e.exit(a),e.exit(i),e.exit(r),t):(e.enter(s),e.enter("chunkString",{contentType:"string"}),p(m))}function p(m){return m===62?(e.exit("chunkString"),e.exit(s),f(m)):m===null||m===60||pe(m)?n(m):(e.consume(m),m===92?g:p)}function g(m){return m===60||m===62||m===92?(e.consume(m),p):p(m)}function w(m){return!c&&(m===null||m===41||qe(m))?(e.exit("chunkString"),e.exit(s),e.exit(o),e.exit(r),t(m)):c<u&&m===40?(e.consume(m),c++,w):m===41?(e.consume(m),c--,w):m===null||m===32||m===40||Mf(m)?n(m):(e.consume(m),m===92?x:w)}function x(m){return m===40||m===41||m===92?(e.consume(m),w):w(m)}}function _k(e,t,n,r,i,a){const o=this;let s=0,l;return u;function u(p){return e.enter(r),e.enter(i),e.consume(p),e.exit(i),e.enter(a),c}function c(p){return s>999||p===null||p===91||p===93&&!l||p===94&&!s&&"_hiddenFootnoteSupport"in o.parser.constructs?n(p):p===93?(e.exit(a),e.enter(i),e.consume(p),e.exit(i),e.exit(r),t):pe(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),c):(e.enter("chunkString",{contentType:"string"}),d(p))}function d(p){return p===null||p===91||p===93||pe(p)||s++>999?(e.exit("chunkString"),c(p)):(e.consume(p),l||(l=!Oe(p)),p===92?f:d)}function f(p){return p===91||p===92||p===93?(e.consume(p),s++,d):d(p)}}function Sk(e,t,n,r,i,a){let o;return s;function s(f){return f===34||f===39||f===40?(e.enter(r),e.enter(i),e.consume(f),e.exit(i),o=f===40?41:f,l):n(f)}function l(f){return f===o?(e.enter(i),e.consume(f),e.exit(i),e.exit(r),t):(e.enter(a),u(f))}function u(f){return f===o?(e.exit(a),l(o)):f===null?n(f):pe(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),Le(e,u,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),c(f))}function c(f){return f===o||f===null||pe(f)?(e.exit("chunkString"),u(f)):(e.consume(f),f===92?d:c)}function d(f){return f===o||f===92?(e.consume(f),c):c(f)}}function _u(e,t){let n;return r;function r(i){return pe(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):Oe(i)?Le(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}const BU={name:"definition",tokenize:zU},jU={tokenize:UU,partial:!0};function zU(e,t,n){const r=this;let i;return a;function a(p){return e.enter("definition"),o(p)}function o(p){return _k.call(r,e,s,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(p)}function s(p){return i=mr(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),p===58?(e.enter("definitionMarker"),e.consume(p),e.exit("definitionMarker"),l):n(p)}function l(p){return qe(p)?_u(e,u)(p):u(p)}function u(p){return Tk(e,c,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(p)}function c(p){return e.attempt(jU,d,d)(p)}function d(p){return Oe(p)?Le(e,f,"whitespace")(p):f(p)}function f(p){return p===null||pe(p)?(e.exit("definition"),r.parser.defined.push(i),t(p)):n(p)}}function UU(e,t,n){return r;function r(s){return qe(s)?_u(e,i)(s):n(s)}function i(s){return Sk(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(s)}function a(s){return Oe(s)?Le(e,o,"whitespace")(s):o(s)}function o(s){return s===null||pe(s)?t(s):n(s)}}const HU={name:"hardBreakEscape",tokenize:VU};function VU(e,t,n){return r;function r(a){return e.enter("hardBreakEscape"),e.consume(a),i}function i(a){return pe(a)?(e.exit("hardBreakEscape"),t(a)):n(a)}}const $U={name:"headingAtx",tokenize:YU,resolve:WU};function WU(e,t){let n=e.length-2,r=3,i,a;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(i={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},a={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Wn(e,r,n-r+1,[["enter",i,t],["enter",a,t],["exit",a,t],["exit",i,t]])),e}function YU(e,t,n){let r=0;return i;function i(c){return e.enter("atxHeading"),a(c)}function a(c){return e.enter("atxHeadingSequence"),o(c)}function o(c){return c===35&&r++<6?(e.consume(c),o):c===null||qe(c)?(e.exit("atxHeadingSequence"),s(c)):n(c)}function s(c){return c===35?(e.enter("atxHeadingSequence"),l(c)):c===null||pe(c)?(e.exit("atxHeading"),t(c)):Oe(c)?Le(e,s,"whitespace")(c):(e.enter("atxHeadingText"),u(c))}function l(c){return c===35?(e.consume(c),l):(e.exit("atxHeadingSequence"),s(c))}function u(c){return c===null||c===35||qe(c)?(e.exit("atxHeadingText"),s(c)):(e.consume(c),u)}}const qU=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],kk=["pre","script","style","textarea"],GU={name:"htmlFlow",tokenize:ZU,resolveTo:QU,concrete:!0},KU={tokenize:eH,partial:!0},XU={tokenize:JU,partial:!0};function QU(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function ZU(e,t,n){const r=this;let i,a,o,s,l;return u;function u(I){return c(I)}function c(I){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(I),d}function d(I){return I===33?(e.consume(I),f):I===47?(e.consume(I),a=!0,w):I===63?(e.consume(I),i=3,r.interrupt?t:C):an(I)?(e.consume(I),o=String.fromCharCode(I),x):n(I)}function f(I){return I===45?(e.consume(I),i=2,p):I===91?(e.consume(I),i=5,s=0,g):an(I)?(e.consume(I),i=4,r.interrupt?t:C):n(I)}function p(I){return I===45?(e.consume(I),r.interrupt?t:C):n(I)}function g(I){const ke="CDATA[";return I===ke.charCodeAt(s++)?(e.consume(I),s===ke.length?r.interrupt?t:U:g):n(I)}function w(I){return an(I)?(e.consume(I),o=String.fromCharCode(I),x):n(I)}function x(I){if(I===null||I===47||I===62||qe(I)){const ke=I===47,Ye=o.toLowerCase();return!ke&&!a&&kk.includes(Ye)?(i=1,r.interrupt?t(I):U(I)):qU.includes(o.toLowerCase())?(i=6,ke?(e.consume(I),m):r.interrupt?t(I):U(I)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(I):a?v(I):b(I))}return I===45||$t(I)?(e.consume(I),o+=String.fromCharCode(I),x):n(I)}function m(I){return I===62?(e.consume(I),r.interrupt?t:U):n(I)}function v(I){return Oe(I)?(e.consume(I),v):N(I)}function b(I){return I===47?(e.consume(I),N):I===58||I===95||an(I)?(e.consume(I),T):Oe(I)?(e.consume(I),b):N(I)}function T(I){return I===45||I===46||I===58||I===95||$t(I)?(e.consume(I),T):_(I)}function _(I){return I===61?(e.consume(I),S):Oe(I)?(e.consume(I),_):b(I)}function S(I){return I===null||I===60||I===61||I===62||I===96?n(I):I===34||I===39?(e.consume(I),l=I,R):Oe(I)?(e.consume(I),S):P(I)}function R(I){return I===l?(e.consume(I),l=null,B):I===null||pe(I)?n(I):(e.consume(I),R)}function P(I){return I===null||I===34||I===39||I===47||I===60||I===61||I===62||I===96||qe(I)?_(I):(e.consume(I),P)}function B(I){return I===47||I===62||Oe(I)?b(I):n(I)}function N(I){return I===62?(e.consume(I),H):n(I)}function H(I){return I===null||pe(I)?U(I):Oe(I)?(e.consume(I),H):n(I)}function U(I){return I===45&&i===2?(e.consume(I),oe):I===60&&i===1?(e.consume(I),ne):I===62&&i===4?(e.consume(I),te):I===63&&i===3?(e.consume(I),C):I===93&&i===5?(e.consume(I),F):pe(I)&&(i===6||i===7)?(e.exit("htmlFlowData"),e.check(KU,fe,K)(I)):I===null||pe(I)?(e.exit("htmlFlowData"),K(I)):(e.consume(I),U)}function K(I){return e.check(XU,X,fe)(I)}function X(I){return e.enter("lineEnding"),e.consume(I),e.exit("lineEnding"),ee}function ee(I){return I===null||pe(I)?K(I):(e.enter("htmlFlowData"),U(I))}function oe(I){return I===45?(e.consume(I),C):U(I)}function ne(I){return I===47?(e.consume(I),o="",L):U(I)}function L(I){if(I===62){const ke=o.toLowerCase();return kk.includes(ke)?(e.consume(I),te):U(I)}return an(I)&&o.length<8?(e.consume(I),o+=String.fromCharCode(I),L):U(I)}function F(I){return I===93?(e.consume(I),C):U(I)}function C(I){return I===62?(e.consume(I),te):I===45&&i===2?(e.consume(I),C):U(I)}function te(I){return I===null||pe(I)?(e.exit("htmlFlowData"),fe(I)):(e.consume(I),te)}function fe(I){return e.exit("htmlFlow"),t(I)}}function JU(e,t,n){const r=this;return i;function i(o){return pe(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),a):n(o)}function a(o){return r.parser.lazy[r.now().line]?n(o):t(o)}}function eH(e,t,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),e.attempt(Eu,t,n)}}const tH={name:"htmlText",tokenize:nH};function nH(e,t,n){const r=this;let i,a,o;return s;function s(C){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(C),l}function l(C){return C===33?(e.consume(C),u):C===47?(e.consume(C),_):C===63?(e.consume(C),b):an(C)?(e.consume(C),P):n(C)}function u(C){return C===45?(e.consume(C),c):C===91?(e.consume(C),a=0,g):an(C)?(e.consume(C),v):n(C)}function c(C){return C===45?(e.consume(C),p):n(C)}function d(C){return C===null?n(C):C===45?(e.consume(C),f):pe(C)?(o=d,ne(C)):(e.consume(C),d)}function f(C){return C===45?(e.consume(C),p):d(C)}function p(C){return C===62?oe(C):C===45?f(C):d(C)}function g(C){const te="CDATA[";return C===te.charCodeAt(a++)?(e.consume(C),a===te.length?w:g):n(C)}function w(C){return C===null?n(C):C===93?(e.consume(C),x):pe(C)?(o=w,ne(C)):(e.consume(C),w)}function x(C){return C===93?(e.consume(C),m):w(C)}function m(C){return C===62?oe(C):C===93?(e.consume(C),m):w(C)}function v(C){return C===null||C===62?oe(C):pe(C)?(o=v,ne(C)):(e.consume(C),v)}function b(C){return C===null?n(C):C===63?(e.consume(C),T):pe(C)?(o=b,ne(C)):(e.consume(C),b)}function T(C){return C===62?oe(C):b(C)}function _(C){return an(C)?(e.consume(C),S):n(C)}function S(C){return C===45||$t(C)?(e.consume(C),S):R(C)}function R(C){return pe(C)?(o=R,ne(C)):Oe(C)?(e.consume(C),R):oe(C)}function P(C){return C===45||$t(C)?(e.consume(C),P):C===47||C===62||qe(C)?B(C):n(C)}function B(C){return C===47?(e.consume(C),oe):C===58||C===95||an(C)?(e.consume(C),N):pe(C)?(o=B,ne(C)):Oe(C)?(e.consume(C),B):oe(C)}function N(C){return C===45||C===46||C===58||C===95||$t(C)?(e.consume(C),N):H(C)}function H(C){return C===61?(e.consume(C),U):pe(C)?(o=H,ne(C)):Oe(C)?(e.consume(C),H):B(C)}function U(C){return C===null||C===60||C===61||C===62||C===96?n(C):C===34||C===39?(e.consume(C),i=C,K):pe(C)?(o=U,ne(C)):Oe(C)?(e.consume(C),U):(e.consume(C),X)}function K(C){return C===i?(e.consume(C),i=void 0,ee):C===null?n(C):pe(C)?(o=K,ne(C)):(e.consume(C),K)}function X(C){return C===null||C===34||C===39||C===60||C===61||C===96?n(C):C===47||C===62||qe(C)?B(C):(e.consume(C),X)}function ee(C){return C===47||C===62||qe(C)?B(C):n(C)}function oe(C){return C===62?(e.consume(C),e.exit("htmlTextData"),e.exit("htmlText"),t):n(C)}function ne(C){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(C),e.exit("lineEnding"),L}function L(C){return Oe(C)?Le(e,F,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(C):F(C)}function F(C){return e.enter("htmlTextData"),o(C)}}const Nw={name:"labelEnd",tokenize:lH,resolveTo:sH,resolveAll:oH},rH={tokenize:uH},iH={tokenize:cH},aH={tokenize:dH};function oH(e){let t=-1;for(;++t<e.length;){const n=e[t][1];(n.type==="labelImage"||n.type==="labelLink"||n.type==="labelEnd")&&(e.splice(t+1,n.type==="labelImage"?4:2),n.type="data",t++)}return e}function sH(e,t){let n=e.length,r=0,i,a,o,s;for(;n--;)if(i=e[n][1],a){if(i.type==="link"||i.type==="labelLink"&&i._inactive)break;e[n][0]==="enter"&&i.type==="labelLink"&&(i._inactive=!0)}else if(o){if(e[n][0]==="enter"&&(i.type==="labelImage"||i.type==="labelLink")&&!i._balanced&&(a=n,i.type!=="labelLink")){r=2;break}}else i.type==="labelEnd"&&(o=n);const l={type:e[a][1].type==="labelLink"?"link":"image",start:Object.assign({},e[a][1].start),end:Object.assign({},e[e.length-1][1].end)},u={type:"label",start:Object.assign({},e[a][1].start),end:Object.assign({},e[o][1].end)},c={type:"labelText",start:Object.assign({},e[a+r+2][1].end),end:Object.assign({},e[o-2][1].start)};return s=[["enter",l,t],["enter",u,t]],s=Yn(s,e.slice(a+1,a+r+3)),s=Yn(s,[["enter",c,t]]),s=Yn(s,Hf(t.parser.constructs.insideSpan.null,e.slice(a+r+4,o-3),t)),s=Yn(s,[["exit",c,t],e[o-2],e[o-1],["exit",u,t]]),s=Yn(s,e.slice(o+1)),s=Yn(s,[["exit",l,t]]),Wn(e,a,e.length,s),e}function lH(e,t,n){const r=this;let i=r.events.length,a,o;for(;i--;)if((r.events[i][1].type==="labelImage"||r.events[i][1].type==="labelLink")&&!r.events[i][1]._balanced){a=r.events[i][1];break}return s;function s(f){return a?a._inactive?d(f):(o=r.parser.defined.includes(mr(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(f),e.exit("labelMarker"),e.exit("labelEnd"),l):n(f)}function l(f){return f===40?e.attempt(rH,c,o?c:d)(f):f===91?e.attempt(iH,c,o?u:d)(f):o?c(f):d(f)}function u(f){return e.attempt(aH,c,d)(f)}function c(f){return t(f)}function d(f){return a._balanced=!0,n(f)}}function uH(e,t,n){return r;function r(d){return e.enter("resource"),e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),i}function i(d){return qe(d)?_u(e,a)(d):a(d)}function a(d){return d===41?c(d):Tk(e,o,s,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(d)}function o(d){return qe(d)?_u(e,l)(d):c(d)}function s(d){return n(d)}function l(d){return d===34||d===39||d===40?Sk(e,u,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(d):c(d)}function u(d){return qe(d)?_u(e,c)(d):c(d)}function c(d){return d===41?(e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),e.exit("resource"),t):n(d)}}function cH(e,t,n){const r=this;return i;function i(s){return _k.call(r,e,a,o,"reference","referenceMarker","referenceString")(s)}function a(s){return r.parser.defined.includes(mr(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(s):n(s)}function o(s){return n(s)}}function dH(e,t,n){return r;function r(a){return e.enter("reference"),e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),i}function i(a){return a===93?(e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),e.exit("reference"),t):n(a)}}const fH={name:"labelStartImage",tokenize:pH,resolveAll:Nw.resolveAll};function pH(e,t,n){const r=this;return i;function i(s){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(s),e.exit("labelImageMarker"),a}function a(s){return s===91?(e.enter("labelMarker"),e.consume(s),e.exit("labelMarker"),e.exit("labelImage"),o):n(s)}function o(s){return s===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(s):t(s)}}const hH={name:"labelStartLink",tokenize:mH,resolveAll:Nw.resolveAll};function mH(e,t,n){const r=this;return i;function i(o){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(o),e.exit("labelMarker"),e.exit("labelLink"),a}function a(o){return o===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(o):t(o)}}const Ow={name:"lineEnding",tokenize:gH};function gH(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),Le(e,t,"linePrefix")}}const Vf={name:"thematicBreak",tokenize:wH};function wH(e,t,n){let r=0,i;return a;function a(u){return e.enter("thematicBreak"),o(u)}function o(u){return i=u,s(u)}function s(u){return u===i?(e.enter("thematicBreakSequence"),l(u)):r>=3&&(u===null||pe(u))?(e.exit("thematicBreak"),t(u)):n(u)}function l(u){return u===i?(e.consume(u),r++,l):(e.exit("thematicBreakSequence"),Oe(u)?Le(e,s,"whitespace")(u):s(u))}}const mn={name:"list",tokenize:bH,continuation:{tokenize:xH},exit:TH},yH={tokenize:_H,partial:!0},vH={tokenize:EH,partial:!0};function bH(e,t,n){const r=this,i=r.events[r.events.length-1];let a=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0,o=0;return s;function s(p){const g=r.containerState.type||(p===42||p===43||p===45?"listUnordered":"listOrdered");if(g==="listUnordered"?!r.containerState.marker||p===r.containerState.marker:gw(p)){if(r.containerState.type||(r.containerState.type=g,e.enter(g,{_container:!0})),g==="listUnordered")return e.enter("listItemPrefix"),p===42||p===45?e.check(Vf,n,u)(p):u(p);if(!r.interrupt||p===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),l(p)}return n(p)}function l(p){return gw(p)&&++o<10?(e.consume(p),l):(!r.interrupt||o<2)&&(r.containerState.marker?p===r.containerState.marker:p===41||p===46)?(e.exit("listItemValue"),u(p)):n(p)}function u(p){return e.enter("listItemMarker"),e.consume(p),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||p,e.check(Eu,r.interrupt?n:c,e.attempt(yH,f,d))}function c(p){return r.containerState.initialBlankLine=!0,a++,f(p)}function d(p){return Oe(p)?(e.enter("listItemPrefixWhitespace"),e.consume(p),e.exit("listItemPrefixWhitespace"),f):n(p)}function f(p){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(p)}}function xH(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Eu,i,a);function i(s){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Le(e,t,"listItemIndent",r.containerState.size+1)(s)}function a(s){return r.containerState.furtherBlankLines||!Oe(s)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(s)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(vH,t,o)(s))}function o(s){return r.containerState._closeFlow=!0,r.interrupt=void 0,Le(e,e.attempt(mn,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(s)}}function EH(e,t,n){const r=this;return Le(e,i,"listItemIndent",r.containerState.size+1);function i(a){const o=r.events[r.events.length-1];return o&&o[1].type==="listItemIndent"&&o[2].sliceSerialize(o[1],!0).length===r.containerState.size?t(a):n(a)}}function TH(e){e.exit(this.containerState.type)}function _H(e,t,n){const r=this;return Le(e,i,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function i(a){const o=r.events[r.events.length-1];return!Oe(a)&&o&&o[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const Ck={name:"setextUnderline",tokenize:kH,resolveTo:SH};function SH(e,t){let n=e.length,r,i,a;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(i=n)}else e[n][1].type==="content"&&e.splice(n,1),!a&&e[n][1].type==="definition"&&(a=n);const o={type:"setextHeading",start:Object.assign({},e[i][1].start),end:Object.assign({},e[e.length-1][1].end)};return e[i][1].type="setextHeadingText",a?(e.splice(i,0,["enter",o,t]),e.splice(a+1,0,["exit",e[r][1],t]),e[r][1].end=Object.assign({},e[a][1].end)):e[r][1]=o,e.push(["exit",o,t]),e}function kH(e,t,n){const r=this;let i;return a;function a(u){let c=r.events.length,d;for(;c--;)if(r.events[c][1].type!=="lineEnding"&&r.events[c][1].type!=="linePrefix"&&r.events[c][1].type!=="content"){d=r.events[c][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||d)?(e.enter("setextHeadingLine"),i=u,o(u)):n(u)}function o(u){return e.enter("setextHeadingLineSequence"),s(u)}function s(u){return u===i?(e.consume(u),s):(e.exit("setextHeadingLineSequence"),Oe(u)?Le(e,l,"lineSuffix")(u):l(u))}function l(u){return u===null||pe(u)?(e.exit("setextHeadingLine"),t(u)):n(u)}}const CH={tokenize:LH,partial:!0};function AH(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:PH,continuation:{tokenize:IH},exit:DH}},text:{91:{name:"gfmFootnoteCall",tokenize:OH},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:RH,resolveTo:NH}}}}function RH(e,t,n){const r=this;let i=r.events.length;const a=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let o;for(;i--;){const l=r.events[i][1];if(l.type==="labelImage"){o=l;break}if(l.type==="gfmFootnoteCall"||l.type==="labelLink"||l.type==="label"||l.type==="image"||l.type==="link")break}return s;function s(l){if(!o||!o._balanced)return n(l);const u=mr(r.sliceSerialize({start:o.end,end:r.now()}));return u.codePointAt(0)!==94||!a.includes(u.slice(1))?n(l):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(l),e.exit("gfmFootnoteCallLabelMarker"),t(l))}}function NH(e,t){let n=e.length;for(;n--;)if(e[n][1].type==="labelImage"&&e[n][0]==="enter"){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},i={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};i.end.column++,i.end.offset++,i.end._bufferIndex++;const a={type:"gfmFootnoteCallString",start:Object.assign({},i.end),end:Object.assign({},e[e.length-1][1].start)},o={type:"chunkString",contentType:"string",start:Object.assign({},a.start),end:Object.assign({},a.end)},s=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",i,t],["exit",i,t],["enter",a,t],["enter",o,t],["exit",o,t],["exit",a,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...s),e}function OH(e,t,n){const r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a=0,o;return s;function s(d){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),l}function l(d){return d!==94?n(d):(e.enter("gfmFootnoteCallMarker"),e.consume(d),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",u)}function u(d){if(a>999||d===93&&!o||d===null||d===91||qe(d))return n(d);if(d===93){e.exit("chunkString");const f=e.exit("gfmFootnoteCallString");return i.includes(mr(r.sliceSerialize(f)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(d)}return qe(d)||(o=!0),a++,e.consume(d),d===92?c:u}function c(d){return d===91||d===92||d===93?(e.consume(d),a++,u):u(d)}}function PH(e,t,n){const r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a,o=0,s;return l;function l(g){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(g),e.exit("gfmFootnoteDefinitionLabelMarker"),u}function u(g){return g===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(g),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",c):n(g)}function c(g){if(o>999||g===93&&!s||g===null||g===91||qe(g))return n(g);if(g===93){e.exit("chunkString");const w=e.exit("gfmFootnoteDefinitionLabelString");return a=mr(r.sliceSerialize(w)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(g),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),f}return qe(g)||(s=!0),o++,e.consume(g),g===92?d:c}function d(g){return g===91||g===92||g===93?(e.consume(g),o++,c):c(g)}function f(g){return g===58?(e.enter("definitionMarker"),e.consume(g),e.exit("definitionMarker"),i.includes(a)||i.push(a),Le(e,p,"gfmFootnoteDefinitionWhitespace")):n(g)}function p(g){return t(g)}}function IH(e,t,n){return e.check(Eu,t,e.attempt(CH,t,n))}function DH(e){e.exit("gfmFootnoteDefinition")}function LH(e,t,n){const r=this;return Le(e,i,"gfmFootnoteDefinitionIndent",5);function i(a){const o=r.events[r.events.length-1];return o&&o[1].type==="gfmFootnoteDefinitionIndent"&&o[2].sliceSerialize(o[1],!0).length===4?t(a):n(a)}}function MH(e){let n=(e||{}).singleTilde;const r={name:"strikethrough",tokenize:a,resolveAll:i};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function i(o,s){let l=-1;for(;++l<o.length;)if(o[l][0]==="enter"&&o[l][1].type==="strikethroughSequenceTemporary"&&o[l][1]._close){let u=l;for(;u--;)if(o[u][0]==="exit"&&o[u][1].type==="strikethroughSequenceTemporary"&&o[u][1]._open&&o[l][1].end.offset-o[l][1].start.offset===o[u][1].end.offset-o[u][1].start.offset){o[l][1].type="strikethroughSequence",o[u][1].type="strikethroughSequence";const c={type:"strikethrough",start:Object.assign({},o[u][1].start),end:Object.assign({},o[l][1].end)},d={type:"strikethroughText",start:Object.assign({},o[u][1].end),end:Object.assign({},o[l][1].start)},f=[["enter",c,s],["enter",o[u][1],s],["exit",o[u][1],s],["enter",d,s]],p=s.parser.constructs.insideSpan.null;p&&Wn(f,f.length,0,Hf(p,o.slice(u+1,l),s)),Wn(f,f.length,0,[["exit",d,s],["enter",o[l][1],s],["exit",o[l][1],s],["exit",c,s]]),Wn(o,u-1,l-u+3,f),l=u+f.length-2;break}}for(l=-1;++l<o.length;)o[l][1].type==="strikethroughSequenceTemporary"&&(o[l][1].type="data");return o}function a(o,s,l){const u=this.previous,c=this.events;let d=0;return f;function f(g){return u===126&&c[c.length-1][1].type!=="characterEscape"?l(g):(o.enter("strikethroughSequenceTemporary"),p(g))}function p(g){const w=Uf(u);if(g===126)return d>1?l(g):(o.consume(g),d++,p);if(d<2&&!n)return l(g);const x=o.exit("strikethroughSequenceTemporary"),m=Uf(g);return x._open=!m||m===2&&!!w,x._close=!w||w===2&&!!m,s(g)}}}class FH{constructor(){this.map=[]}add(t,n,r){BH(this,t,n,r)}consume(t){if(this.map.sort(function(a,o){return a[0]-o[0]}),this.map.length===0)return;let n=this.map.length;const r=[];for(;n>0;)n-=1,r.push(t.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),t.length=this.map[n][0];r.push([...t]),t.length=0;let i=r.pop();for(;i;)t.push(...i),i=r.pop();this.map.length=0}}function BH(e,t,n,r){let i=0;if(!(n===0&&r.length===0)){for(;i<e.map.length;){if(e.map[i][0]===t){e.map[i][1]+=n,e.map[i][2].push(...r);return}i+=1}e.map.push([t,n,r])}}function jH(e,t){let n=!1;const r=[];for(;t<e.length;){const i=e[t];if(n){if(i[0]==="enter")i[1].type==="tableContent"&&r.push(e[t+1][1].type==="tableDelimiterMarker"?"left":"none");else if(i[1].type==="tableContent"){if(e[t-1][1].type==="tableDelimiterMarker"){const a=r.length-1;r[a]=r[a]==="left"?"center":"right"}}else if(i[1].type==="tableDelimiterRow")break}else i[0]==="enter"&&i[1].type==="tableDelimiterRow"&&(n=!0);t+=1}return r}function zH(){return{flow:{null:{name:"table",tokenize:UH,resolveAll:HH}}}}function UH(e,t,n){const r=this;let i=0,a=0,o;return s;function s(N){let H=r.events.length-1;for(;H>-1;){const X=r.events[H][1].type;if(X==="lineEnding"||X==="linePrefix")H--;else break}const U=H>-1?r.events[H][1].type:null,K=U==="tableHead"||U==="tableRow"?S:l;return K===S&&r.parser.lazy[r.now().line]?n(N):K(N)}function l(N){return e.enter("tableHead"),e.enter("tableRow"),u(N)}function u(N){return N===124||(o=!0,a+=1),c(N)}function c(N){return N===null?n(N):pe(N)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(N),e.exit("lineEnding"),p):n(N):Oe(N)?Le(e,c,"whitespace")(N):(a+=1,o&&(o=!1,i+=1),N===124?(e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),o=!0,c):(e.enter("data"),d(N)))}function d(N){return N===null||N===124||qe(N)?(e.exit("data"),c(N)):(e.consume(N),N===92?f:d)}function f(N){return N===92||N===124?(e.consume(N),d):d(N)}function p(N){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(N):(e.enter("tableDelimiterRow"),o=!1,Oe(N)?Le(e,g,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(N):g(N))}function g(N){return N===45||N===58?x(N):N===124?(o=!0,e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),w):_(N)}function w(N){return Oe(N)?Le(e,x,"whitespace")(N):x(N)}function x(N){return N===58?(a+=1,o=!0,e.enter("tableDelimiterMarker"),e.consume(N),e.exit("tableDelimiterMarker"),m):N===45?(a+=1,m(N)):N===null||pe(N)?T(N):_(N)}function m(N){return N===45?(e.enter("tableDelimiterFiller"),v(N)):_(N)}function v(N){return N===45?(e.consume(N),v):N===58?(o=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(N),e.exit("tableDelimiterMarker"),b):(e.exit("tableDelimiterFiller"),b(N))}function b(N){return Oe(N)?Le(e,T,"whitespace")(N):T(N)}function T(N){return N===124?g(N):N===null||pe(N)?!o||i!==a?_(N):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(N)):_(N)}function _(N){return n(N)}function S(N){return e.enter("tableRow"),R(N)}function R(N){return N===124?(e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),R):N===null||pe(N)?(e.exit("tableRow"),t(N)):Oe(N)?Le(e,R,"whitespace")(N):(e.enter("data"),P(N))}function P(N){return N===null||N===124||qe(N)?(e.exit("data"),R(N)):(e.consume(N),N===92?B:P)}function B(N){return N===92||N===124?(e.consume(N),P):P(N)}}function HH(e,t){let n=-1,r=!0,i=0,a=[0,0,0,0],o=[0,0,0,0],s=!1,l=0,u,c,d;const f=new FH;for(;++n<e.length;){const p=e[n],g=p[1];p[0]==="enter"?g.type==="tableHead"?(s=!1,l!==0&&(Ak(f,t,l,u,c),c=void 0,l=0),u={type:"table",start:Object.assign({},g.start),end:Object.assign({},g.end)},f.add(n,0,[["enter",u,t]])):g.type==="tableRow"||g.type==="tableDelimiterRow"?(r=!0,d=void 0,a=[0,0,0,0],o=[0,n+1,0,0],s&&(s=!1,c={type:"tableBody",start:Object.assign({},g.start),end:Object.assign({},g.end)},f.add(n,0,[["enter",c,t]])),i=g.type==="tableDelimiterRow"?2:c?3:1):i&&(g.type==="data"||g.type==="tableDelimiterMarker"||g.type==="tableDelimiterFiller")?(r=!1,o[2]===0&&(a[1]!==0&&(o[0]=o[1],d=$f(f,t,a,i,void 0,d),a=[0,0,0,0]),o[2]=n)):g.type==="tableCellDivider"&&(r?r=!1:(a[1]!==0&&(o[0]=o[1],d=$f(f,t,a,i,void 0,d)),a=o,o=[a[1],n,0,0])):g.type==="tableHead"?(s=!0,l=n):g.type==="tableRow"||g.type==="tableDelimiterRow"?(l=n,a[1]!==0?(o[0]=o[1],d=$f(f,t,a,i,n,d)):o[1]!==0&&(d=$f(f,t,o,i,n,d)),i=0):i&&(g.type==="data"||g.type==="tableDelimiterMarker"||g.type==="tableDelimiterFiller")&&(o[3]=n)}for(l!==0&&Ak(f,t,l,u,c),f.consume(t.events),n=-1;++n<t.events.length;){const p=t.events[n];p[0]==="enter"&&p[1].type==="table"&&(p[1]._align=jH(t.events,n))}return e}function $f(e,t,n,r,i,a){const o=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",s="tableContent";n[0]!==0&&(a.end=Object.assign({},ps(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const l=ps(t.events,n[1]);if(a={type:o,start:Object.assign({},l),end:Object.assign({},l)},e.add(n[1],0,[["enter",a,t]]),n[2]!==0){const u=ps(t.events,n[2]),c=ps(t.events,n[3]),d={type:s,start:Object.assign({},u),end:Object.assign({},c)};if(e.add(n[2],0,[["enter",d,t]]),r!==2){const f=t.events[n[2]],p=t.events[n[3]];if(f[1].end=Object.assign({},p[1].end),f[1].type="chunkText",f[1].contentType="text",n[3]>n[2]+1){const g=n[2]+1,w=n[3]-n[2]-1;e.add(g,w,[])}}e.add(n[3]+1,0,[["exit",d,t]])}return i!==void 0&&(a.end=Object.assign({},ps(t.events,i)),e.add(i,0,[["exit",a,t]]),a=void 0),a}function Ak(e,t,n,r,i){const a=[],o=ps(t.events,n);i&&(i.end=Object.assign({},o),a.push(["exit",i,t])),r.end=Object.assign({},o),a.push(["exit",r,t]),e.add(n+1,0,a)}function ps(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const VH={name:"tasklistCheck",tokenize:WH};function $H(){return{text:{91:VH}}}function WH(e,t,n){const r=this;return i;function i(l){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(l):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(l),e.exit("taskListCheckMarker"),a)}function a(l){return qe(l)?(e.enter("taskListCheckValueUnchecked"),e.consume(l),e.exit("taskListCheckValueUnchecked"),o):l===88||l===120?(e.enter("taskListCheckValueChecked"),e.consume(l),e.exit("taskListCheckValueChecked"),o):n(l)}function o(l){return l===93?(e.enter("taskListCheckMarker"),e.consume(l),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),s):n(l)}function s(l){return pe(l)?t(l):Oe(l)?e.check({tokenize:YH},t,n)(l):n(l)}}function YH(e,t,n){return Le(e,r,"whitespace");function r(i){return i===null?n(i):t(i)}}function qH(e){return sk([rU(),AH(),MH(e),zH(),$H()])}const GH={};function KH(e){const t=this,n=e||GH,r=t.data(),i=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),o=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);i.push(qH(n)),a.push(Qz()),o.push(Zz(n))}function Rk(e){const t=[],n=String(e||"");let r=n.indexOf(","),i=0,a=!1;for(;!a;){r===-1&&(r=n.length,a=!0);const o=n.slice(i,r).trim();(o||!a)&&t.push(o),i=r+1,r=n.indexOf(",",i)}return t}function Nk(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const XH=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,QH=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,ZH={};function Ok(e,t){return(ZH.jsx?QH:XH).test(e)}const JH=/[ \t\n\f\r]/g;function eV(e){return typeof e=="object"?e.type==="text"?Pk(e.value):!1:Pk(e)}function Pk(e){return e.replace(JH,"")===""}class Su{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}Su.prototype.property={},Su.prototype.normal={},Su.prototype.space=null;function Ik(e,t){const n={},r={};let i=-1;for(;++i<e.length;)Object.assign(n,e[i].property),Object.assign(r,e[i].normal);return new Su(n,r,t)}function ku(e){return e.toLowerCase()}class qn{constructor(t,n){this.property=t,this.attribute=n}}qn.prototype.space=null,qn.prototype.boolean=!1,qn.prototype.booleanish=!1,qn.prototype.overloadedBoolean=!1,qn.prototype.number=!1,qn.prototype.commaSeparated=!1,qn.prototype.spaceSeparated=!1,qn.prototype.commaOrSpaceSeparated=!1,qn.prototype.mustUseProperty=!1,qn.prototype.defined=!1;let tV=0;const be=Za(),yt=Za(),Dk=Za(),G=Za(),Qe=Za(),hs=Za(),Pn=Za();function Za(){return 2**++tV}const Pw=Object.freeze(Object.defineProperty({__proto__:null,boolean:be,booleanish:yt,commaOrSpaceSeparated:Pn,commaSeparated:hs,number:G,overloadedBoolean:Dk,spaceSeparated:Qe},Symbol.toStringTag,{value:"Module"})),Iw=Object.keys(Pw);class Dw extends qn{constructor(t,n,r,i){let a=-1;if(super(t,n),Lk(this,"space",i),typeof r=="number")for(;++a<Iw.length;){const o=Iw[a];Lk(this,Iw[a],(r&Pw[o])===Pw[o])}}}Dw.prototype.defined=!0;function Lk(e,t,n){n&&(e[t]=n)}const nV={}.hasOwnProperty;function ms(e){const t={},n={};let r;for(r in e.properties)if(nV.call(e.properties,r)){const i=e.properties[r],a=new Dw(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[ku(r)]=r,n[ku(a.attribute)]=r}return new Su(t,n,e.space)}const Mk=ms({space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()},properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),Fk=ms({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function Bk(e,t){return t in e?e[t]:t}function jk(e,t){return Bk(e,t.toLowerCase())}const zk=ms({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:jk,properties:{xmlns:null,xmlnsXLink:null}}),Uk=ms({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:yt,ariaAutoComplete:null,ariaBusy:yt,ariaChecked:yt,ariaColCount:G,ariaColIndex:G,ariaColSpan:G,ariaControls:Qe,ariaCurrent:null,ariaDescribedBy:Qe,ariaDetails:null,ariaDisabled:yt,ariaDropEffect:Qe,ariaErrorMessage:null,ariaExpanded:yt,ariaFlowTo:Qe,ariaGrabbed:yt,ariaHasPopup:null,ariaHidden:yt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:Qe,ariaLevel:G,ariaLive:null,ariaModal:yt,ariaMultiLine:yt,ariaMultiSelectable:yt,ariaOrientation:null,ariaOwns:Qe,ariaPlaceholder:null,ariaPosInSet:G,ariaPressed:yt,ariaReadOnly:yt,ariaRelevant:null,ariaRequired:yt,ariaRoleDescription:Qe,ariaRowCount:G,ariaRowIndex:G,ariaRowSpan:G,ariaSelected:yt,ariaSetSize:G,ariaSort:null,ariaValueMax:G,ariaValueMin:G,ariaValueNow:G,ariaValueText:null,role:null}}),rV=ms({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:jk,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:hs,acceptCharset:Qe,accessKey:Qe,action:null,allow:null,allowFullScreen:be,allowPaymentRequest:be,allowUserMedia:be,alt:null,as:null,async:be,autoCapitalize:null,autoComplete:Qe,autoFocus:be,autoPlay:be,blocking:Qe,capture:null,charSet:null,checked:be,cite:null,className:Qe,cols:G,colSpan:null,content:null,contentEditable:yt,controls:be,controlsList:Qe,coords:G|hs,crossOrigin:null,data:null,dateTime:null,decoding:null,default:be,defer:be,dir:null,dirName:null,disabled:be,download:Dk,draggable:yt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:be,formTarget:null,headers:Qe,height:G,hidden:be,high:G,href:null,hrefLang:null,htmlFor:Qe,httpEquiv:Qe,id:null,imageSizes:null,imageSrcSet:null,inert:be,inputMode:null,integrity:null,is:null,isMap:be,itemId:null,itemProp:Qe,itemRef:Qe,itemScope:be,itemType:Qe,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:be,low:G,manifest:null,max:null,maxLength:G,media:null,method:null,min:null,minLength:G,multiple:be,muted:be,name:null,nonce:null,noModule:be,noValidate:be,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:be,optimum:G,pattern:null,ping:Qe,placeholder:null,playsInline:be,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:be,referrerPolicy:null,rel:Qe,required:be,reversed:be,rows:G,rowSpan:G,sandbox:Qe,scope:null,scoped:be,seamless:be,selected:be,shadowRootClonable:be,shadowRootDelegatesFocus:be,shadowRootMode:null,shape:null,size:G,sizes:null,slot:null,span:G,spellCheck:yt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:G,step:null,style:null,tabIndex:G,target:null,title:null,translate:null,type:null,typeMustMatch:be,useMap:null,value:yt,width:G,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:Qe,axis:null,background:null,bgColor:null,border:G,borderColor:null,bottomMargin:G,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:be,declare:be,event:null,face:null,frame:null,frameBorder:null,hSpace:G,leftMargin:G,link:null,longDesc:null,lowSrc:null,marginHeight:G,marginWidth:G,noResize:be,noHref:be,noShade:be,noWrap:be,object:null,profile:null,prompt:null,rev:null,rightMargin:G,rules:null,scheme:null,scrolling:yt,standby:null,summary:null,text:null,topMargin:G,valueType:null,version:null,vAlign:null,vLink:null,vSpace:G,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:be,disableRemotePlayback:be,prefix:null,property:null,results:G,security:null,unselectable:null}}),iV=ms({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:Bk,properties:{about:Pn,accentHeight:G,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:G,amplitude:G,arabicForm:null,ascent:G,attributeName:null,attributeType:null,azimuth:G,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:G,by:null,calcMode:null,capHeight:G,className:Qe,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:G,diffuseConstant:G,direction:null,display:null,dur:null,divisor:G,dominantBaseline:null,download:be,dx:null,dy:null,edgeMode:null,editable:null,elevation:G,enableBackground:null,end:null,event:null,exponent:G,externalResourcesRequired:null,fill:null,fillOpacity:G,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:hs,g2:hs,glyphName:hs,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:G,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:G,horizOriginX:G,horizOriginY:G,id:null,ideographic:G,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:G,k:G,k1:G,k2:G,k3:G,k4:G,kernelMatrix:Pn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:G,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:G,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:G,overlineThickness:G,paintOrder:null,panose1:null,path:null,pathLength:G,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:Qe,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:G,pointsAtY:G,pointsAtZ:G,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Pn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Pn,rev:Pn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Pn,requiredFeatures:Pn,requiredFonts:Pn,requiredFormats:Pn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:G,specularExponent:G,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:G,strikethroughThickness:G,string:null,stroke:null,strokeDashArray:Pn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:G,strokeOpacity:G,strokeWidth:null,style:null,surfaceScale:G,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Pn,tabIndex:G,tableValues:null,target:null,targetX:G,targetY:G,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Pn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:G,underlineThickness:G,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:G,values:null,vAlphabetic:G,vMathematical:G,vectorEffect:null,vHanging:G,vIdeographic:G,version:null,vertAdvY:G,vertOriginX:G,vertOriginY:G,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:G,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),aV=/^data[-\w.:]+$/i,Hk=/-[a-z]/g,oV=/[A-Z]/g;function Wf(e,t){const n=ku(t);let r=t,i=qn;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&aV.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(Hk,lV);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!Hk.test(a)){let o=a.replace(oV,sV);o.charAt(0)!=="-"&&(o="-"+o),t="data"+o}}i=Dw}return new i(r,t)}function sV(e){return"-"+e.toLowerCase()}function lV(e){return e.charAt(1).toUpperCase()}const uV={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},Cu=Ik([Fk,Mk,zk,Uk,rV],"html"),la=Ik([Fk,Mk,zk,Uk,iV],"svg");function Vk(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function $k(e){return e.join(" ").trim()}var Wk={},Yk=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,cV=/\n/g,dV=/^\s*/,fV=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,pV=/^:\s*/,hV=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,mV=/^[;\s]*/,gV=/^\s+|\s+$/g,wV=`
68
+ `,qk="/",Gk="*",Ja="",yV="comment",vV="declaration",bV=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function i(g){var w=g.match(cV);w&&(n+=w.length);var x=g.lastIndexOf(wV);r=~x?g.length-x:r+g.length}function a(){var g={line:n,column:r};return function(w){return w.position=new o(g),u(),w}}function o(g){this.start=g,this.end={line:n,column:r},this.source=t.source}o.prototype.content=e;function s(g){var w=new Error(t.source+":"+n+":"+r+": "+g);if(w.reason=g,w.filename=t.source,w.line=n,w.column=r,w.source=e,!t.silent)throw w}function l(g){var w=g.exec(e);if(w){var x=w[0];return i(x),e=e.slice(x.length),w}}function u(){l(dV)}function c(g){var w;for(g=g||[];w=d();)w!==!1&&g.push(w);return g}function d(){var g=a();if(!(qk!=e.charAt(0)||Gk!=e.charAt(1))){for(var w=2;Ja!=e.charAt(w)&&(Gk!=e.charAt(w)||qk!=e.charAt(w+1));)++w;if(w+=2,Ja===e.charAt(w-1))return s("End of comment missing");var x=e.slice(2,w-2);return r+=2,i(x),e=e.slice(w),r+=2,g({type:yV,comment:x})}}function f(){var g=a(),w=l(fV);if(w){if(d(),!l(pV))return s("property missing ':'");var x=l(hV),m=g({type:vV,property:Kk(w[0].replace(Yk,Ja)),value:x?Kk(x[0].replace(Yk,Ja)):Ja});return l(mV),m}}function p(){var g=[];c(g);for(var w;w=f();)w!==!1&&(g.push(w),c(g));return g}return u(),p()};function Kk(e){return e?e.replace(gV,Ja):Ja}var xV=Zn&&Zn.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Wk,"__esModule",{value:!0});var Xk=Wk.default=TV,EV=xV(bV);function TV(e,t){var n=null;if(!e||typeof e!="string")return n;var r=(0,EV.default)(e),i=typeof t=="function";return r.forEach(function(a){if(a.type==="declaration"){var o=a.property,s=a.value;i?t(o,s,a):s&&(n=n||{},n[o]=s)}}),n}const _V=Xk.default||Xk,Yf=Qk("end"),Mr=Qk("start");function Qk(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function SV(e){const t=Mr(e),n=Yf(e);if(t&&n)return{start:t,end:n}}function Au(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?Zk(e.position):"start"in e||"end"in e?Zk(e):"line"in e||"column"in e?Lw(e):""}function Lw(e){return Jk(e&&e.line)+":"+Jk(e&&e.column)}function Zk(e){return Lw(e&&e.start)+"-"+Lw(e&&e.end)}function Jk(e){return e&&typeof e=="number"?e:1}class Wt extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let i="",a={},o=!1;if(n&&("line"in n&&"column"in n?a={place:n}:"start"in n&&"end"in n?a={place:n}:"type"in n?a={ancestors:[n],place:n.position}:a={...n}),typeof t=="string"?i=t:!a.cause&&t&&(o=!0,i=t.message,a.cause=t),!a.ruleId&&!a.source&&typeof r=="string"){const l=r.indexOf(":");l===-1?a.ruleId=r:(a.source=r.slice(0,l),a.ruleId=r.slice(l+1))}if(!a.place&&a.ancestors&&a.ancestors){const l=a.ancestors[a.ancestors.length-1];l&&(a.place=l.position)}const s=a.place&&"start"in a.place?a.place.start:a.place;this.ancestors=a.ancestors||void 0,this.cause=a.cause||void 0,this.column=s?s.column:void 0,this.fatal=void 0,this.file,this.message=i,this.line=s?s.line:void 0,this.name=Au(a.place)||"1:1",this.place=a.place||void 0,this.reason=this.message,this.ruleId=a.ruleId||void 0,this.source=a.source||void 0,this.stack=o&&a.cause&&typeof a.cause.stack=="string"?a.cause.stack:"",this.actual,this.expected,this.note,this.url}}Wt.prototype.file="",Wt.prototype.name="",Wt.prototype.reason="",Wt.prototype.message="",Wt.prototype.stack="",Wt.prototype.column=void 0,Wt.prototype.line=void 0,Wt.prototype.ancestors=void 0,Wt.prototype.cause=void 0,Wt.prototype.fatal=void 0,Wt.prototype.place=void 0,Wt.prototype.ruleId=void 0,Wt.prototype.source=void 0;const Mw={}.hasOwnProperty,kV=new Map,CV=/[A-Z]/g,AV=/-([a-z])/g,RV=new Set(["table","tbody","thead","tfoot","tr"]),NV=new Set(["td","th"]),eC="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function OV(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=jV(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=BV(n,t.jsx,t.jsxs)}const i={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?la:Cu,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=tC(i,e,void 0);return a&&typeof a!="string"?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function tC(e,t,n){if(t.type==="element")return PV(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return IV(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return LV(e,t,n);if(t.type==="mdxjsEsm")return DV(e,t);if(t.type==="root")return MV(e,t,n);if(t.type==="text")return FV(e,t)}function PV(e,t,n){const r=e.schema;let i=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(i=la,e.schema=i),e.ancestors.push(t);const a=rC(e,t.tagName,!1),o=zV(e,t);let s=Bw(e,t);return RV.has(t.tagName)&&(s=s.filter(function(l){return typeof l=="string"?!eV(l):!0})),nC(e,o,a,t),Fw(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function IV(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return r.type,e.evaluater.evaluateExpression(r.expression)}Ru(e,t.position)}function DV(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Ru(e,t.position)}function LV(e,t,n){const r=e.schema;let i=r;t.name==="svg"&&r.space==="html"&&(i=la,e.schema=i),e.ancestors.push(t);const a=t.name===null?e.Fragment:rC(e,t.name,!0),o=UV(e,t),s=Bw(e,t);return nC(e,o,a,t),Fw(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function MV(e,t,n){const r={};return Fw(r,Bw(e,t)),e.create(t,e.Fragment,r,n)}function FV(e,t){return t.value}function nC(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Fw(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function BV(e,t,n){return r;function r(i,a,o,s){const u=Array.isArray(o.children)?n:t;return s?u(a,o,s):u(a,o)}}function jV(e,t){return n;function n(r,i,a,o){const s=Array.isArray(a.children),l=Mr(r);return t(i,a,o,s,{columnNumber:l?l.column-1:void 0,fileName:e,lineNumber:l?l.line:void 0},void 0)}}function zV(e,t){const n={};let r,i;for(i in t.properties)if(i!=="children"&&Mw.call(t.properties,i)){const a=HV(e,i,t.properties[i]);if(a){const[o,s]=a;e.tableCellAlignToStyle&&o==="align"&&typeof s=="string"&&NV.has(t.tagName)?r=s:n[o]=s}}if(r){const a=n.style||(n.style={});a[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function UV(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const a=r.data.estree.body[0];a.type;const o=a.expression;o.type;const s=o.properties[0];s.type,Object.assign(n,e.evaluater.evaluateExpression(s.argument))}else Ru(e,t.position);else{const i=r.name;let a;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&e.evaluater){const s=r.value.data.estree.body[0];s.type,a=e.evaluater.evaluateExpression(s.expression)}else Ru(e,t.position);else a=r.value===null?!0:r.value;n[i]=a}return n}function Bw(e,t){const n=[];let r=-1;const i=e.passKeys?new Map:kV;for(;++r<t.children.length;){const a=t.children[r];let o;if(e.passKeys){const l=a.type==="element"?a.tagName:a.type==="mdxJsxFlowElement"||a.type==="mdxJsxTextElement"?a.name:void 0;if(l){const u=i.get(l)||0;o=l+"-"+u,i.set(l,u+1)}}const s=tC(e,a,o);s!==void 0&&n.push(s)}return n}function HV(e,t,n){const r=Wf(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?Nk(n):$k(n)),r.property==="style"){let i=typeof n=="object"?n:VV(e,String(n));return e.stylePropertyNameCase==="css"&&(i=$V(i)),["style",i]}return[e.elementAttributeNameCase==="react"&&r.space?uV[r.property]||r.property:r.attribute,n]}}function VV(e,t){const n={};try{_V(t,r)}catch(i){if(!e.ignoreInvalidStyle){const a=i,o=new Wt("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:a,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw o.file=e.filePath||void 0,o.url=eC+"#cannot-parse-style-attribute",o}}return n;function r(i,a){let o=i;o.slice(0,2)!=="--"&&(o.slice(0,4)==="-ms-"&&(o="ms-"+o.slice(4)),o=o.replace(AV,YV)),n[o]=a}}function rC(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const i=t.split(".");let a=-1,o;for(;++a<i.length;){const s=Ok(i[a])?{type:"Identifier",name:i[a]}:{type:"Literal",value:i[a]};o=o?{type:"MemberExpression",object:o,property:s,computed:!!(a&&s.type==="Literal"),optional:!1}:s}r=o}else r=Ok(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const i=r.value;return Mw.call(e.components,i)?e.components[i]:i}if(e.evaluater)return e.evaluater.evaluateExpression(r);Ru(e)}function Ru(e,t){const n=new Wt("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=eC+"#cannot-handle-mdx-estrees-without-createevaluater",n}function $V(e){const t={};let n;for(n in e)Mw.call(e,n)&&(t[WV(n)]=e[n]);return t}function WV(e){let t=e.replace(CV,qV);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function YV(e,t){return t.toUpperCase()}function qV(e){return"-"+e.toLowerCase()}const jw={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},GV={tokenize:KV};function KV(e){const t=e.attempt(this.parser.constructs.contentInitial,r,i);let n;return t;function r(s){if(s===null){e.consume(s);return}return e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),Le(e,t,"linePrefix")}function i(s){return e.enter("paragraph"),a(s)}function a(s){const l=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=l),n=l,o(s)}function o(s){if(s===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(s);return}return pe(s)?(e.consume(s),e.exit("chunkText"),a):(e.consume(s),o)}}const XV={tokenize:QV},iC={tokenize:ZV};function QV(e){const t=this,n=[];let r=0,i,a,o;return s;function s(b){if(r<n.length){const T=n[r];return t.containerState=T[1],e.attempt(T[0].continuation,l,u)(b)}return u(b)}function l(b){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&v();const T=t.events.length;let _=T,S;for(;_--;)if(t.events[_][0]==="exit"&&t.events[_][1].type==="chunkFlow"){S=t.events[_][1].end;break}m(r);let R=T;for(;R<t.events.length;)t.events[R][1].end=Object.assign({},S),R++;return Wn(t.events,_+1,0,t.events.slice(T)),t.events.length=R,u(b)}return s(b)}function u(b){if(r===n.length){if(!i)return f(b);if(i.currentConstruct&&i.currentConstruct.concrete)return g(b);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(iC,c,d)(b)}function c(b){return i&&v(),m(r),f(b)}function d(b){return t.parser.lazy[t.now().line]=r!==n.length,o=t.now().offset,g(b)}function f(b){return t.containerState={},e.attempt(iC,p,g)(b)}function p(b){return r++,n.push([t.currentConstruct,t.containerState]),f(b)}function g(b){if(b===null){i&&v(),m(0),e.consume(b);return}return i=i||t.parser.flow(t.now()),e.enter("chunkFlow",{contentType:"flow",previous:a,_tokenizer:i}),w(b)}function w(b){if(b===null){x(e.exit("chunkFlow"),!0),m(0),e.consume(b);return}return pe(b)?(e.consume(b),x(e.exit("chunkFlow")),r=0,t.interrupt=void 0,s):(e.consume(b),w)}function x(b,T){const _=t.sliceStream(b);if(T&&_.push(null),b.previous=a,a&&(a.next=b),a=b,i.defineSkip(b.start),i.write(_),t.parser.lazy[b.start.line]){let S=i.events.length;for(;S--;)if(i.events[S][1].start.offset<o&&(!i.events[S][1].end||i.events[S][1].end.offset>o))return;const R=t.events.length;let P=R,B,N;for(;P--;)if(t.events[P][0]==="exit"&&t.events[P][1].type==="chunkFlow"){if(B){N=t.events[P][1].end;break}B=!0}for(m(r),S=R;S<t.events.length;)t.events[S][1].end=Object.assign({},N),S++;Wn(t.events,P+1,0,t.events.slice(R)),t.events.length=S}}function m(b){let T=n.length;for(;T-- >b;){const _=n[T];t.containerState=_[1],_[0].exit.call(t,e)}n.length=b}function v(){i.write([null]),a=void 0,i=void 0,t.containerState._closeFlow=void 0}}function ZV(e,t,n){return Le(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}const JV={tokenize:e$};function e$(e){const t=this,n=e.attempt(Eu,r,e.attempt(this.parser.constructs.flowInitial,i,Le(e,e.attempt(this.parser.constructs.flow,i,e.attempt(IU,i)),"linePrefix")));return n;function r(a){if(a===null){e.consume(a);return}return e.enter("lineEndingBlank"),e.consume(a),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function i(a){if(a===null){e.consume(a);return}return e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const t$={resolveAll:oC()},n$=aC("string"),r$=aC("text");function aC(e){return{tokenize:t,resolveAll:oC(e==="text"?i$:void 0)};function t(n){const r=this,i=this.parser.constructs[e],a=n.attempt(i,o,s);return o;function o(c){return u(c)?a(c):s(c)}function s(c){if(c===null){n.consume(c);return}return n.enter("data"),n.consume(c),l}function l(c){return u(c)?(n.exit("data"),a(c)):(n.consume(c),l)}function u(c){if(c===null)return!0;const d=i[c];let f=-1;if(d)for(;++f<d.length;){const p=d[f];if(!p.previous||p.previous.call(r,r.previous))return!0}return!1}}}function oC(e){return t;function t(n,r){let i=-1,a;for(;++i<=n.length;)a===void 0?n[i]&&n[i][1].type==="data"&&(a=i,i++):(!n[i]||n[i][1].type!=="data")&&(i!==a+2&&(n[a][1].end=n[i-1][1].end,n.splice(a+2,i-a-2),i=a+2),a=void 0);return e?e(n,r):n}}function i$(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],i=t.sliceStream(r);let a=i.length,o=-1,s=0,l;for(;a--;){const u=i[a];if(typeof u=="string"){for(o=u.length;u.charCodeAt(o-1)===32;)s++,o--;if(o)break;o=-1}else if(u===-2)l=!0,s++;else if(u!==-1){a++;break}}if(s){const u={type:n===e.length||l||s<2?"lineSuffix":"hardBreakTrailing",start:{line:r.end.line,column:r.end.column-s,offset:r.end.offset-s,_index:r.start._index+a,_bufferIndex:a?o:r.start._bufferIndex+o},end:Object.assign({},r.end)};r.end=Object.assign({},u.start),r.start.offset===r.end.offset?Object.assign(r,u):(e.splice(n,0,["enter",u,t],["exit",u,t]),n+=2)}n++}return e}function a$(e,t,n){let r=Object.assign(n?Object.assign({},n):{line:1,column:1,offset:0},{_index:0,_bufferIndex:-1});const i={},a=[];let o=[],s=[];const l={consume:v,enter:b,exit:T,attempt:R(_),check:R(S),interrupt:R(S,{interrupt:!0})},u={previous:null,code:null,containerState:{},events:[],parser:e,sliceStream:p,sliceSerialize:f,now:g,defineSkip:w,write:d};let c=t.tokenize.call(u,l);return t.resolveAll&&a.push(t),u;function d(H){return o=Yn(o,H),x(),o[o.length-1]!==null?[]:(P(t,0),u.events=Hf(a,u.events,u),u.events)}function f(H,U){return s$(p(H),U)}function p(H){return o$(o,H)}function g(){const{line:H,column:U,offset:K,_index:X,_bufferIndex:ee}=r;return{line:H,column:U,offset:K,_index:X,_bufferIndex:ee}}function w(H){i[H.line]=H.column,N()}function x(){let H;for(;r._index<o.length;){const U=o[r._index];if(typeof U=="string")for(H=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===H&&r._bufferIndex<U.length;)m(U.charCodeAt(r._bufferIndex));else m(U)}}function m(H){c=c(H)}function v(H){pe(H)?(r.line++,r.column=1,r.offset+=H===-3?2:1,N()):H!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===o[r._index].length&&(r._bufferIndex=-1,r._index++)),u.previous=H}function b(H,U){const K=U||{};return K.type=H,K.start=g(),u.events.push(["enter",K,u]),s.push(K),K}function T(H){const U=s.pop();return U.end=g(),u.events.push(["exit",U,u]),U}function _(H,U){P(H,U.from)}function S(H,U){U.restore()}function R(H,U){return K;function K(X,ee,oe){let ne,L,F,C;return Array.isArray(X)?fe(X):"tokenize"in X?fe([X]):te(X);function te(J){return de;function de(Se){const Ce=Se!==null&&J[Se],Re=Se!==null&&J.null,vt=[...Array.isArray(Ce)?Ce:Ce?[Ce]:[],...Array.isArray(Re)?Re:Re?[Re]:[]];return fe(vt)(Se)}}function fe(J){return ne=J,L=0,J.length===0?oe:I(J[L])}function I(J){return de;function de(Se){return C=B(),F=J,J.partial||(u.currentConstruct=J),J.name&&u.parser.constructs.disable.null.includes(J.name)?Ye():J.tokenize.call(U?Object.assign(Object.create(u),U):u,l,ke,Ye)(Se)}}function ke(J){return H(F,C),ee}function Ye(J){return C.restore(),++L<ne.length?I(ne[L]):oe}}}function P(H,U){H.resolveAll&&!a.includes(H)&&a.push(H),H.resolve&&Wn(u.events,U,u.events.length-U,H.resolve(u.events.slice(U),u)),H.resolveTo&&(u.events=H.resolveTo(u.events,u))}function B(){const H=g(),U=u.previous,K=u.currentConstruct,X=u.events.length,ee=Array.from(s);return{restore:oe,from:X};function oe(){r=H,u.previous=U,u.currentConstruct=K,u.events.length=X,s=ee,N()}}function N(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function o$(e,t){const n=t.start._index,r=t.start._bufferIndex,i=t.end._index,a=t.end._bufferIndex;let o;if(n===i)o=[e[n].slice(r,a)];else{if(o=e.slice(n,i),r>-1){const s=o[0];typeof s=="string"?o[0]=s.slice(r):o.shift()}a>0&&o.push(e[i].slice(0,a))}return o}function s$(e,t){let n=-1;const r=[];let i;for(;++n<e.length;){const a=e[n];let o;if(typeof a=="string")o=a;else switch(a){case-5:{o="\r";break}case-4:{o=`
69
+ `;break}case-3:{o=`\r
70
+ `;break}case-2:{o=t?" ":" ";break}case-1:{if(!t&&i)continue;o=" ";break}default:o=String.fromCharCode(a)}i=a===-2,r.push(o)}return r.join("")}const l$=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:BU},disable:{null:[]},document:{42:mn,43:mn,45:mn,48:mn,49:mn,50:mn,51:mn,52:mn,53:mn,54:mn,55:mn,56:mn,57:mn,62:wk},flow:{35:$U,42:Vf,45:[Ck,Vf],60:GU,61:Ck,95:Vf,96:xk,126:xk},flowInitial:{[-2]:Rw,[-1]:Rw,32:Rw},insideSpan:{null:[Aw,t$]},string:{38:vk,92:yk},text:{[-5]:Ow,[-4]:Ow,[-3]:Ow,33:fH,38:vk,42:Aw,60:[hU,tH],91:hH,92:[HU,yk],93:Nw,95:Aw,96:CU}},Symbol.toStringTag,{value:"Module"}));function u$(e){const n=sk([l$,...(e||{}).extensions||[]]),r={defined:[],lazy:{},constructs:n,content:i(GV),document:i(XV),flow:i(JV),string:i(n$),text:i(r$)};return r;function i(a){return o;function o(s){return a$(r,a,s)}}}function c$(e){for(;!Ek(e););return e}const sC=/[\0\t\n\r]/g;function d$(){let e=1,t="",n=!0,r;return i;function i(a,o,s){const l=[];let u,c,d,f,p;for(a=t+(typeof a=="string"?a.toString():new TextDecoder(o||void 0).decode(a)),d=0,t="",n&&(a.charCodeAt(0)===65279&&d++,n=void 0);d<a.length;){if(sC.lastIndex=d,u=sC.exec(a),f=u&&u.index!==void 0?u.index:a.length,p=a.charCodeAt(f),!u){t=a.slice(d);break}if(p===10&&d===f&&r)l.push(-3),r=void 0;else switch(r&&(l.push(-5),r=void 0),d<f&&(l.push(a.slice(d,f)),e+=f-d),p){case 0:{l.push(65533),e++;break}case 9:{for(c=Math.ceil(e/4)*4,l.push(-2);e++<c;)l.push(-1);break}case 10:{l.push(-4),e=1;break}default:r=!0,e=1}d=f+1}return s&&(r&&l.push(-5),t&&l.push(t),l.push(null)),l}}const lC={}.hasOwnProperty;function f$(e,t,n){return typeof t!="string"&&(n=t,t=void 0),p$(n)(c$(u$(n).document().write(d$()(e,t,!0))))}function p$(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(ze),autolinkProtocol:B,autolinkEmail:B,atxHeading:a(je),blockQuote:a(Re),characterEscape:B,characterReference:B,codeFenced:a(vt),codeFencedFenceInfo:o,codeFencedFenceMeta:o,codeIndented:a(vt,o),codeText:a(xe,o),codeTextData:B,data:B,codeFlowValue:B,definition:a(we),definitionDestinationString:o,definitionLabelString:o,definitionTitleString:o,emphasis:a(Ve),hardBreakEscape:a(bt),hardBreakTrailing:a(bt),htmlFlow:a(xt,o),htmlFlowData:B,htmlText:a(xt,o),htmlTextData:B,image:a(Ke),label:o,link:a(ze),listItem:a(Hs),listItemValue:f,listOrdered:a(Mt,d),listUnordered:a(Mt),paragraph:a(Vs),reference:I,referenceString:o,resourceDestinationString:o,resourceTitleString:o,setextHeading:a(je),strong:a($s),thematicBreak:a(le)},exit:{atxHeading:l(),atxHeadingSequence:_,autolink:l(),autolinkEmail:Ce,autolinkProtocol:Se,blockQuote:l(),characterEscapeValue:N,characterReferenceMarkerHexadecimal:Ye,characterReferenceMarkerNumeric:Ye,characterReferenceValue:J,characterReference:de,codeFenced:l(x),codeFencedFence:w,codeFencedFenceInfo:p,codeFencedFenceMeta:g,codeFlowValue:N,codeIndented:l(m),codeText:l(ee),codeTextData:N,data:N,definition:l(),definitionDestinationString:T,definitionLabelString:v,definitionTitleString:b,emphasis:l(),hardBreakEscape:l(U),hardBreakTrailing:l(U),htmlFlow:l(K),htmlFlowData:N,htmlText:l(X),htmlTextData:N,image:l(ne),label:F,labelText:L,lineEnding:H,link:l(oe),listItem:l(),listOrdered:l(),listUnordered:l(),paragraph:l(),referenceString:ke,resourceDestinationString:C,resourceTitleString:te,resource:fe,setextHeading:l(P),setextHeadingLineSequence:R,setextHeadingText:S,strong:l(),thematicBreak:l()}};uC(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(M){let $={type:"root",children:[]};const se={stack:[$],tokenStack:[],config:t,enter:s,exit:u,buffer:o,resume:c,data:n},Te=[];let Fe=-1;for(;++Fe<M.length;)if(M[Fe][1].type==="listOrdered"||M[Fe][1].type==="listUnordered")if(M[Fe][0]==="enter")Te.push(Fe);else{const on=Te.pop();Fe=i(M,on,Fe)}for(Fe=-1;++Fe<M.length;){const on=t[M[Fe][0]];lC.call(on,M[Fe][1].type)&&on[M[Fe][1].type].call(Object.assign({sliceSerialize:M[Fe][2].sliceSerialize},se),M[Fe][1])}if(se.tokenStack.length>0){const on=se.tokenStack[se.tokenStack.length-1];(on[1]||cC).call(se,void 0,on[0])}for($.position={start:ua(M.length>0?M[0][1].start:{line:1,column:1,offset:0}),end:ua(M.length>0?M[M.length-2][1].end:{line:1,column:1,offset:0})},Fe=-1;++Fe<t.transforms.length;)$=t.transforms[Fe]($)||$;return $}function i(M,$,se){let Te=$-1,Fe=-1,on=!1,xr,Ln,Hr,Ti;for(;++Te<=se;){const Ft=M[Te];switch(Ft[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{Ft[0]==="enter"?Fe++:Fe--,Ti=void 0;break}case"lineEndingBlank":{Ft[0]==="enter"&&(xr&&!Ti&&!Fe&&!Hr&&(Hr=Te),Ti=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Ti=void 0}if(!Fe&&Ft[0]==="enter"&&Ft[1].type==="listItemPrefix"||Fe===-1&&Ft[0]==="exit"&&(Ft[1].type==="listUnordered"||Ft[1].type==="listOrdered")){if(xr){let Vr=Te;for(Ln=void 0;Vr--;){const Mn=M[Vr];if(Mn[1].type==="lineEnding"||Mn[1].type==="lineEndingBlank"){if(Mn[0]==="exit")continue;Ln&&(M[Ln][1].type="lineEndingBlank",on=!0),Mn[1].type="lineEnding",Ln=Vr}else if(!(Mn[1].type==="linePrefix"||Mn[1].type==="blockQuotePrefix"||Mn[1].type==="blockQuotePrefixWhitespace"||Mn[1].type==="blockQuoteMarker"||Mn[1].type==="listItemIndent"))break}Hr&&(!Ln||Hr<Ln)&&(xr._spread=!0),xr.end=Object.assign({},Ln?M[Ln][1].start:Ft[1].end),M.splice(Ln||Te,0,["exit",xr,Ft[2]]),Te++,se++}if(Ft[1].type==="listItemPrefix"){const Vr={type:"listItem",_spread:!1,start:Object.assign({},Ft[1].start),end:void 0};xr=Vr,M.splice(Te,0,["enter",Vr,Ft[2]]),Te++,se++,Hr=void 0,Ti=!0}}}return M[$][1]._spread=on,se}function a(M,$){return se;function se(Te){s.call(this,M(Te),Te),$&&$.call(this,Te)}}function o(){this.stack.push({type:"fragment",children:[]})}function s(M,$,se){this.stack[this.stack.length-1].children.push(M),this.stack.push(M),this.tokenStack.push([$,se]),M.position={start:ua($.start),end:void 0}}function l(M){return $;function $(se){M&&M.call(this,se),u.call(this,se)}}function u(M,$){const se=this.stack.pop(),Te=this.tokenStack.pop();if(Te)Te[0].type!==M.type&&($?$.call(this,M,Te[0]):(Te[1]||cC).call(this,M,Te[0]));else throw new Error("Cannot close `"+M.type+"` ("+Au({start:M.start,end:M.end})+"): it’s not open");se.position.end=ua(M.end)}function c(){return Ew(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function f(M){if(this.data.expectingFirstListItemValue){const $=this.stack[this.stack.length-2];$.start=Number.parseInt(this.sliceSerialize(M),10),this.data.expectingFirstListItemValue=void 0}}function p(){const M=this.resume(),$=this.stack[this.stack.length-1];$.lang=M}function g(){const M=this.resume(),$=this.stack[this.stack.length-1];$.meta=M}function w(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function x(){const M=this.resume(),$=this.stack[this.stack.length-1];$.value=M.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function m(){const M=this.resume(),$=this.stack[this.stack.length-1];$.value=M.replace(/(\r?\n|\r)$/g,"")}function v(M){const $=this.resume(),se=this.stack[this.stack.length-1];se.label=$,se.identifier=mr(this.sliceSerialize(M)).toLowerCase()}function b(){const M=this.resume(),$=this.stack[this.stack.length-1];$.title=M}function T(){const M=this.resume(),$=this.stack[this.stack.length-1];$.url=M}function _(M){const $=this.stack[this.stack.length-1];if(!$.depth){const se=this.sliceSerialize(M).length;$.depth=se}}function S(){this.data.setextHeadingSlurpLineEnding=!0}function R(M){const $=this.stack[this.stack.length-1];$.depth=this.sliceSerialize(M).codePointAt(0)===61?1:2}function P(){this.data.setextHeadingSlurpLineEnding=void 0}function B(M){const se=this.stack[this.stack.length-1].children;let Te=se[se.length-1];(!Te||Te.type!=="text")&&(Te=Z(),Te.position={start:ua(M.start),end:void 0},se.push(Te)),this.stack.push(Te)}function N(M){const $=this.stack.pop();$.value+=this.sliceSerialize(M),$.position.end=ua(M.end)}function H(M){const $=this.stack[this.stack.length-1];if(this.data.atHardBreak){const se=$.children[$.children.length-1];se.position.end=ua(M.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes($.type)&&(B.call(this,M),N.call(this,M))}function U(){this.data.atHardBreak=!0}function K(){const M=this.resume(),$=this.stack[this.stack.length-1];$.value=M}function X(){const M=this.resume(),$=this.stack[this.stack.length-1];$.value=M}function ee(){const M=this.resume(),$=this.stack[this.stack.length-1];$.value=M}function oe(){const M=this.stack[this.stack.length-1];if(this.data.inReference){const $=this.data.referenceType||"shortcut";M.type+="Reference",M.referenceType=$,delete M.url,delete M.title}else delete M.identifier,delete M.label;this.data.referenceType=void 0}function ne(){const M=this.stack[this.stack.length-1];if(this.data.inReference){const $=this.data.referenceType||"shortcut";M.type+="Reference",M.referenceType=$,delete M.url,delete M.title}else delete M.identifier,delete M.label;this.data.referenceType=void 0}function L(M){const $=this.sliceSerialize(M),se=this.stack[this.stack.length-2];se.label=Bz($),se.identifier=mr($).toLowerCase()}function F(){const M=this.stack[this.stack.length-1],$=this.resume(),se=this.stack[this.stack.length-1];if(this.data.inReference=!0,se.type==="link"){const Te=M.children;se.children=Te}else se.alt=$}function C(){const M=this.resume(),$=this.stack[this.stack.length-1];$.url=M}function te(){const M=this.resume(),$=this.stack[this.stack.length-1];$.title=M}function fe(){this.data.inReference=void 0}function I(){this.data.referenceType="collapsed"}function ke(M){const $=this.resume(),se=this.stack[this.stack.length-1];se.label=$,se.identifier=mr(this.sliceSerialize(M)).toLowerCase(),this.data.referenceType="full"}function Ye(M){this.data.characterReferenceType=M.type}function J(M){const $=this.sliceSerialize(M),se=this.data.characterReferenceType;let Te;se?(Te=rk($,se==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Te=_w($);const Fe=this.stack[this.stack.length-1];Fe.value+=Te}function de(M){const $=this.stack.pop();$.position.end=ua(M.end)}function Se(M){N.call(this,M);const $=this.stack[this.stack.length-1];$.url=this.sliceSerialize(M)}function Ce(M){N.call(this,M);const $=this.stack[this.stack.length-1];$.url="mailto:"+this.sliceSerialize(M)}function Re(){return{type:"blockquote",children:[]}}function vt(){return{type:"code",lang:null,meta:null,value:""}}function xe(){return{type:"inlineCode",value:""}}function we(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Ve(){return{type:"emphasis",children:[]}}function je(){return{type:"heading",depth:0,children:[]}}function bt(){return{type:"break"}}function xt(){return{type:"html",value:""}}function Ke(){return{type:"image",title:null,url:"",alt:null}}function ze(){return{type:"link",title:null,url:"",children:[]}}function Mt(M){return{type:"list",ordered:M.type==="listOrdered",start:null,spread:M._spread,children:[]}}function Hs(M){return{type:"listItem",spread:M._spread,checked:null,children:[]}}function Vs(){return{type:"paragraph",children:[]}}function $s(){return{type:"strong",children:[]}}function Z(){return{type:"text",value:""}}function le(){return{type:"thematicBreak"}}}function ua(e){return{line:e.line,column:e.column,offset:e.offset}}function uC(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?uC(e,r):h$(e,r)}}function h$(e,t){let n;for(n in t)if(lC.call(t,n))switch(n){case"canContainEols":{const r=t[n];r&&e[n].push(...r);break}case"transforms":{const r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{const r=t[n];r&&Object.assign(e[n],r);break}}}function cC(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Au({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Au({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Au({start:t.start,end:t.end})+") is still open")}function m$(e){const t=this;t.parser=n;function n(r){return f$(r,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function g$(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function w$(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
71
+ `}]}function y$(e,t){const n=t.value?t.value+`
72
+ `:"",r={};t.lang&&(r.className=["language-"+t.lang]);let i={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(i.data={meta:t.meta}),e.patch(t,i),i=e.applyData(t,i),i={type:"element",tagName:"pre",properties:{},children:[i]},e.patch(t,i),i}function v$(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function b$(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function x$(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),i=fs(r.toLowerCase()),a=e.footnoteOrder.indexOf(r);let o,s=e.footnoteCounts.get(r);s===void 0?(s=0,e.footnoteOrder.push(r),o=e.footnoteOrder.length):o=a+1,s+=1,e.footnoteCounts.set(r,s);const l={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+i,id:n+"fnref-"+i+(s>1?"-"+s:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(o)}]};e.patch(t,l);const u={type:"element",tagName:"sup",properties:{},children:[l]};return e.patch(t,u),e.applyData(t,u)}function E$(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function T$(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function dC(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return[{type:"text",value:"!["+t.alt+r}];const i=e.all(t),a=i[0];a&&a.type==="text"?a.value="["+a.value:i.unshift({type:"text",value:"["});const o=i[i.length-1];return o&&o.type==="text"?o.value+=r:i.push({type:"text",value:r}),i}function _$(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return dC(e,t);const i={src:fs(r.url||""),alt:t.alt};r.title!==null&&r.title!==void 0&&(i.title=r.title);const a={type:"element",tagName:"img",properties:i,children:[]};return e.patch(t,a),e.applyData(t,a)}function S$(e,t){const n={src:fs(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function k$(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function C$(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return dC(e,t);const i={href:fs(r.url||"")};r.title!==null&&r.title!==void 0&&(i.title=r.title);const a={type:"element",tagName:"a",properties:i,children:e.all(t)};return e.patch(t,a),e.applyData(t,a)}function A$(e,t){const n={href:fs(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function R$(e,t,n){const r=e.all(t),i=n?N$(n):fC(t),a={},o=[];if(typeof t.checked=="boolean"){const c=r[0];let d;c&&c.type==="element"&&c.tagName==="p"?d=c:(d={type:"element",tagName:"p",properties:{},children:[]},r.unshift(d)),d.children.length>0&&d.children.unshift({type:"text",value:" "}),d.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),a.className=["task-list-item"]}let s=-1;for(;++s<r.length;){const c=r[s];(i||s!==0||c.type!=="element"||c.tagName!=="p")&&o.push({type:"text",value:`
73
+ `}),c.type==="element"&&c.tagName==="p"&&!i?o.push(...c.children):o.push(c)}const l=r[r.length-1];l&&(i||l.type!=="element"||l.tagName!=="p")&&o.push({type:"text",value:`
74
+ `});const u={type:"element",tagName:"li",properties:a,children:o};return e.patch(t,u),e.applyData(t,u)}function N$(e){let t=!1;if(e.type==="list"){t=e.spread||!1;const n=e.children;let r=-1;for(;!t&&++r<n.length;)t=fC(n[r])}return t}function fC(e){const t=e.spread;return t??e.children.length>1}function O$(e,t){const n={},r=e.all(t);let i=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++i<r.length;){const o=r[i];if(o.type==="element"&&o.tagName==="li"&&o.properties&&Array.isArray(o.properties.className)&&o.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}const a={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,a),e.applyData(t,a)}function P$(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function I$(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function D$(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function L$(e,t){const n=e.all(t),r=n.shift(),i=[];if(r){const o={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],o),i.push(o)}if(n.length>0){const o={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},s=Mr(t.children[1]),l=Yf(t.children[t.children.length-1]);s&&l&&(o.position={start:s,end:l}),i.push(o)}const a={type:"element",tagName:"table",properties:{},children:e.wrap(i,!0)};return e.patch(t,a),e.applyData(t,a)}function M$(e,t,n){const r=n?n.children:void 0,a=(r?r.indexOf(t):1)===0?"th":"td",o=n&&n.type==="table"?n.align:void 0,s=o?o.length:t.children.length;let l=-1;const u=[];for(;++l<s;){const d=t.children[l],f={},p=o?o[l]:void 0;p&&(f.align=p);let g={type:"element",tagName:a,properties:f,children:[]};d&&(g.children=e.all(d),e.patch(d,g),g=e.applyData(d,g)),u.push(g)}const c={type:"element",tagName:"tr",properties:{},children:e.wrap(u,!0)};return e.patch(t,c),e.applyData(t,c)}function F$(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const pC=9,hC=32;function B$(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),i=0;const a=[];for(;r;)a.push(mC(t.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return a.push(mC(t.slice(i),i>0,!1)),a.join("")}function mC(e,t,n){let r=0,i=e.length;if(t){let a=e.codePointAt(r);for(;a===pC||a===hC;)r++,a=e.codePointAt(r)}if(n){let a=e.codePointAt(i-1);for(;a===pC||a===hC;)i--,a=e.codePointAt(i-1)}return i>r?e.slice(r,i):""}function j$(e,t){const n={type:"text",value:B$(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function z$(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const U$={blockquote:g$,break:w$,code:y$,delete:v$,emphasis:b$,footnoteReference:x$,heading:E$,html:T$,imageReference:_$,image:S$,inlineCode:k$,linkReference:C$,link:A$,listItem:R$,list:O$,paragraph:P$,root:I$,strong:D$,table:L$,tableCell:F$,tableRow:M$,text:j$,thematicBreak:z$,toml:qf,yaml:qf,definition:qf,footnoteDefinition:qf};function qf(){}const gC=-1,Gf=0,Kf=1,Xf=2,zw=3,Uw=4,Hw=5,Vw=6,wC=7,yC=8,vC=typeof self=="object"?self:globalThis,H$=(e,t)=>{const n=(i,a)=>(e.set(a,i),i),r=i=>{if(e.has(i))return e.get(i);const[a,o]=t[i];switch(a){case Gf:case gC:return n(o,i);case Kf:{const s=n([],i);for(const l of o)s.push(r(l));return s}case Xf:{const s=n({},i);for(const[l,u]of o)s[r(l)]=r(u);return s}case zw:return n(new Date(o),i);case Uw:{const{source:s,flags:l}=o;return n(new RegExp(s,l),i)}case Hw:{const s=n(new Map,i);for(const[l,u]of o)s.set(r(l),r(u));return s}case Vw:{const s=n(new Set,i);for(const l of o)s.add(r(l));return s}case wC:{const{name:s,message:l}=o;return n(new vC[s](l),i)}case yC:return n(BigInt(o),i);case"BigInt":return n(Object(BigInt(o)),i)}return n(new vC[a](o),i)};return r},bC=e=>H$(new Map,e)(0),gs="",{toString:V$}={},{keys:$$}=Object,Nu=e=>{const t=typeof e;if(t!=="object"||!e)return[Gf,t];const n=V$.call(e).slice(8,-1);switch(n){case"Array":return[Kf,gs];case"Object":return[Xf,gs];case"Date":return[zw,gs];case"RegExp":return[Uw,gs];case"Map":return[Hw,gs];case"Set":return[Vw,gs]}return n.includes("Array")?[Kf,n]:n.includes("Error")?[wC,n]:[Xf,n]},Qf=([e,t])=>e===Gf&&(t==="function"||t==="symbol"),W$=(e,t,n,r)=>{const i=(o,s)=>{const l=r.push(o)-1;return n.set(s,l),l},a=o=>{if(n.has(o))return n.get(o);let[s,l]=Nu(o);switch(s){case Gf:{let c=o;switch(l){case"bigint":s=yC,c=o.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+l);c=null;break;case"undefined":return i([gC],o)}return i([s,c],o)}case Kf:{if(l)return i([l,[...o]],o);const c=[],d=i([s,c],o);for(const f of o)c.push(a(f));return d}case Xf:{if(l)switch(l){case"BigInt":return i([l,o.toString()],o);case"Boolean":case"Number":case"String":return i([l,o.valueOf()],o)}if(t&&"toJSON"in o)return a(o.toJSON());const c=[],d=i([s,c],o);for(const f of $$(o))(e||!Qf(Nu(o[f])))&&c.push([a(f),a(o[f])]);return d}case zw:return i([s,o.toISOString()],o);case Uw:{const{source:c,flags:d}=o;return i([s,{source:c,flags:d}],o)}case Hw:{const c=[],d=i([s,c],o);for(const[f,p]of o)(e||!(Qf(Nu(f))||Qf(Nu(p))))&&c.push([a(f),a(p)]);return d}case Vw:{const c=[],d=i([s,c],o);for(const f of o)(e||!Qf(Nu(f)))&&c.push(a(f));return d}}const{message:u}=o;return i([s,{name:l,message:u}],o)};return a},xC=(e,{json:t,lossy:n}={})=>{const r=[];return W$(!(t||n),!!t,new Map,r)(e),r},ws=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?bC(xC(e,t)):structuredClone(e):(e,t)=>bC(xC(e,t));function Y$(e,t){const n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function q$(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function G$(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||Y$,r=e.options.footnoteBackLabel||q$,i=e.options.footnoteLabel||"Footnotes",a=e.options.footnoteLabelTagName||"h2",o=e.options.footnoteLabelProperties||{className:["sr-only"]},s=[];let l=-1;for(;++l<e.footnoteOrder.length;){const u=e.footnoteById.get(e.footnoteOrder[l]);if(!u)continue;const c=e.all(u),d=String(u.identifier).toUpperCase(),f=fs(d.toLowerCase());let p=0;const g=[],w=e.footnoteCounts.get(d);for(;w!==void 0&&++p<=w;){g.length>0&&g.push({type:"text",value:" "});let v=typeof n=="string"?n:n(l,p);typeof v=="string"&&(v={type:"text",value:v}),g.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+f+(p>1?"-"+p:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(l,p),className:["data-footnote-backref"]},children:Array.isArray(v)?v:[v]})}const x=c[c.length-1];if(x&&x.type==="element"&&x.tagName==="p"){const v=x.children[x.children.length-1];v&&v.type==="text"?v.value+=" ":x.children.push({type:"text",value:" "}),x.children.push(...g)}else c.push(...g);const m={type:"element",tagName:"li",properties:{id:t+"fn-"+f},children:e.wrap(c,!0)};e.patch(u,m),s.push(m)}if(s.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:a,properties:{...ws(o),id:"footnote-label"},children:[{type:"text",value:i}]},{type:"text",value:`
75
+ `},{type:"element",tagName:"ol",properties:{},children:e.wrap(s,!0)},{type:"text",value:`
76
+ `}]}}const $w={}.hasOwnProperty,K$={};function X$(e,t){const n=t||K$,r=new Map,i=new Map,a=new Map,o={...U$,...n.handlers},s={all:u,applyData:Z$,definitionById:r,footnoteById:i,footnoteCounts:a,footnoteOrder:[],handlers:o,one:l,options:n,patch:Q$,wrap:eW};return zf(e,function(c){if(c.type==="definition"||c.type==="footnoteDefinition"){const d=c.type==="definition"?r:i,f=String(c.identifier).toUpperCase();d.has(f)||d.set(f,c)}}),s;function l(c,d){const f=c.type,p=s.handlers[f];if($w.call(s.handlers,f)&&p)return p(s,c,d);if(s.options.passThrough&&s.options.passThrough.includes(f)){if("children"in c){const{children:w,...x}=c,m=ws(x);return m.children=s.all(c),m}return ws(c)}return(s.options.unknownHandler||J$)(s,c,d)}function u(c){const d=[];if("children"in c){const f=c.children;let p=-1;for(;++p<f.length;){const g=s.one(f[p],c);if(g){if(p&&f[p-1].type==="break"&&(!Array.isArray(g)&&g.type==="text"&&(g.value=EC(g.value)),!Array.isArray(g)&&g.type==="element")){const w=g.children[0];w&&w.type==="text"&&(w.value=EC(w.value))}Array.isArray(g)?d.push(...g):d.push(g)}}}return d}}function Q$(e,t){e.position&&(t.position=SV(e))}function Z$(e,t){let n=t;if(e&&e.data){const r=e.data.hName,i=e.data.hChildren,a=e.data.hProperties;if(typeof r=="string")if(n.type==="element")n.tagName=r;else{const o="children"in n?n.children:[n];n={type:"element",tagName:r,properties:{},children:o}}n.type==="element"&&a&&Object.assign(n.properties,ws(a)),"children"in n&&n.children&&i!==null&&i!==void 0&&(n.children=i)}return n}function J$(e,t){const n=t.data||{},r="value"in t&&!($w.call(n,"hProperties")||$w.call(n,"hChildren"))?{type:"text",value:t.value}:{type:"element",tagName:"div",properties:{},children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function eW(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
77
+ `});++r<e.length;)r&&n.push({type:"text",value:`
78
+ `}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:`
79
+ `}),n}function EC(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function TC(e,t){const n=X$(e,t),r=n.one(e,void 0),i=G$(n),a=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return i&&a.children.push({type:"text",value:`
80
+ `},i),a}function tW(e,t){return e&&"run"in e?async function(n,r){const i=TC(n,{file:r,...t});await e.run(i,r)}:function(n,r){return TC(n,{file:r,...e||t})}}function _C(e){if(e)throw e}var Zf=Object.prototype.hasOwnProperty,SC=Object.prototype.toString,kC=Object.defineProperty,CC=Object.getOwnPropertyDescriptor,AC=function(t){return typeof Array.isArray=="function"?Array.isArray(t):SC.call(t)==="[object Array]"},RC=function(t){if(!t||SC.call(t)!=="[object Object]")return!1;var n=Zf.call(t,"constructor"),r=t.constructor&&t.constructor.prototype&&Zf.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!r)return!1;var i;for(i in t);return typeof i>"u"||Zf.call(t,i)},NC=function(t,n){kC&&n.name==="__proto__"?kC(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},OC=function(t,n){if(n==="__proto__")if(Zf.call(t,n)){if(CC)return CC(t,n).value}else return;return t[n]},nW=function e(){var t,n,r,i,a,o,s=arguments[0],l=1,u=arguments.length,c=!1;for(typeof s=="boolean"&&(c=s,s=arguments[1]||{},l=2),(s==null||typeof s!="object"&&typeof s!="function")&&(s={});l<u;++l)if(t=arguments[l],t!=null)for(n in t)r=OC(s,n),i=OC(t,n),s!==i&&(c&&i&&(RC(i)||(a=AC(i)))?(a?(a=!1,o=r&&AC(r)?r:[]):o=r&&RC(r)?r:{},NC(s,{name:n,newValue:e(c,o,i)})):typeof i<"u"&&NC(s,{name:n,newValue:i}));return s};const Ww=gc(nW);function Yw(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function rW(){const e=[],t={run:n,use:r};return t;function n(...i){let a=-1;const o=i.pop();if(typeof o!="function")throw new TypeError("Expected function as last argument, not "+o);s(null,...i);function s(l,...u){const c=e[++a];let d=-1;if(l){o(l);return}for(;++d<i.length;)(u[d]===null||u[d]===void 0)&&(u[d]=i[d]);i=u,c?iW(c,s)(...u):o(null,...u)}}function r(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return e.push(i),t}}function iW(e,t){let n;return r;function r(...o){const s=e.length>o.length;let l;s&&o.push(i);try{l=e.apply(this,o)}catch(u){const c=u;if(s&&n)throw c;return i(c)}s||(l&&l.then&&typeof l.then=="function"?l.then(a,i):l instanceof Error?i(l):a(l))}function i(o,...s){n||(n=!0,t(o,...s))}function a(o){i(null,o)}}const Fr={basename:aW,dirname:oW,extname:sW,join:lW,sep:"/"};function aW(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Ou(e);let n=0,r=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else r<0&&(a=!0,r=i+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let o=-1,s=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else o<0&&(a=!0,o=i+1),s>-1&&(e.codePointAt(i)===t.codePointAt(s--)?s<0&&(r=i):(s=-1,r=o));return n===r?r=o:r<0&&(r=e.length),e.slice(n,r)}function oW(e){if(Ou(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function sW(e){Ou(e);let t=e.length,n=-1,r=0,i=-1,a=0,o;for(;t--;){const s=e.codePointAt(t);if(s===47){if(o){r=t+1;break}continue}n<0&&(o=!0,n=t+1),s===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||n<0||a===0||a===1&&i===n-1&&i===r+1?"":e.slice(i,n)}function lW(...e){let t=-1,n;for(;++t<e.length;)Ou(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":uW(n)}function uW(e){Ou(e);const t=e.codePointAt(0)===47;let n=cW(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function cW(e,t){let n="",r=0,i=-1,a=0,o=-1,s,l;for(;++o<=e.length;){if(o<e.length)s=e.codePointAt(o);else{if(s===47)break;s=47}if(s===47){if(!(i===o-1||a===1))if(i!==o-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(l=n.lastIndexOf("/"),l!==n.length-1){l<0?(n="",r=0):(n=n.slice(0,l),r=n.length-1-n.lastIndexOf("/")),i=o,a=0;continue}}else if(n.length>0){n="",r=0,i=o,a=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(i+1,o):n=e.slice(i+1,o),r=o-i-1;i=o,a=0}else s===46&&a>-1?a++:a=-1}return n}function Ou(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const dW={cwd:fW};function fW(){return"/"}function qw(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function pW(e){if(typeof e=="string")e=new URL(e);else if(!qw(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return hW(e)}function hW(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){const r=t.codePointAt(n+2);if(r===70||r===102){const i=new TypeError("File URL path must not include encoded / characters");throw i.code="ERR_INVALID_FILE_URL_PATH",i}}return decodeURIComponent(t)}const Gw=["history","path","basename","stem","extname","dirname"];class PC{constructor(t){let n;t?qw(t)?n={path:t}:typeof t=="string"||mW(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":dW.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<Gw.length;){const a=Gw[r];a in n&&n[a]!==void 0&&n[a]!==null&&(this[a]=a==="history"?[...n[a]]:n[a])}let i;for(i in n)Gw.includes(i)||(this[i]=n[i])}get basename(){return typeof this.path=="string"?Fr.basename(this.path):void 0}set basename(t){Xw(t,"basename"),Kw(t,"basename"),this.path=Fr.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?Fr.dirname(this.path):void 0}set dirname(t){IC(this.basename,"dirname"),this.path=Fr.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?Fr.extname(this.path):void 0}set extname(t){if(Kw(t,"extname"),IC(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Fr.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){qw(t)&&(t=pW(t)),Xw(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?Fr.basename(this.path,this.extname):void 0}set stem(t){Xw(t,"stem"),Kw(t,"stem"),this.path=Fr.join(this.dirname||"",t+(this.extname||""))}fail(t,n,r){const i=this.message(t,n,r);throw i.fatal=!0,i}info(t,n,r){const i=this.message(t,n,r);return i.fatal=void 0,i}message(t,n,r){const i=new Wt(t,n,r);return this.path&&(i.name=this.path+":"+i.name,i.file=this.path),i.fatal=!1,this.messages.push(i),i}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function Kw(e,t){if(e&&e.includes(Fr.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+Fr.sep+"`")}function Xw(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function IC(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function mW(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const gW=function(e){const r=this.constructor.prototype,i=r[e],a=function(){return i.apply(a,arguments)};return Object.setPrototypeOf(a,r),a},wW={}.hasOwnProperty;class Qw extends gW{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=rW()}copy(){const t=new Qw;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(Ww(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(ey("data",this.frozen),this.namespace[t]=n,this):wW.call(this.namespace,t)&&this.namespace[t]||void 0:t?(ey("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[n,...r]=this.attachers[this.freezeIndex];if(r[0]===!1)continue;r[0]===!0&&(r[0]=void 0);const i=n.call(t,...r);typeof i=="function"&&this.transformers.use(i)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const n=Jf(t),r=this.parser||this.Parser;return Zw("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),Zw("process",this.parser||this.Parser),Jw("process",this.compiler||this.Compiler),n?i(void 0,n):new Promise(i);function i(a,o){const s=Jf(t),l=r.parse(s);r.run(l,s,function(c,d,f){if(c||!d||!f)return u(c);const p=d,g=r.stringify(p,f);bW(g)?f.value=g:f.result=g,u(c,f)});function u(c,d){c||!d?o(c):a?a(d):n(void 0,d)}}}processSync(t){let n=!1,r;return this.freeze(),Zw("processSync",this.parser||this.Parser),Jw("processSync",this.compiler||this.Compiler),this.process(t,i),LC("processSync","process",n),r;function i(a,o){n=!0,_C(a),r=o}}run(t,n,r){DC(t),this.freeze();const i=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?a(void 0,r):new Promise(a);function a(o,s){const l=Jf(n);i.run(t,l,u);function u(c,d,f){const p=d||t;c?s(c):o?o(p):r(void 0,p,f)}}}runSync(t,n){let r=!1,i;return this.run(t,n,a),LC("runSync","run",r),i;function a(o,s){_C(o),i=s,r=!0}}stringify(t,n){this.freeze();const r=Jf(n),i=this.compiler||this.Compiler;return Jw("stringify",i),DC(t),i(t,r)}use(t,...n){const r=this.attachers,i=this.namespace;if(ey("use",this.frozen),t!=null)if(typeof t=="function")l(t,n);else if(typeof t=="object")Array.isArray(t)?s(t):o(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function a(u){if(typeof u=="function")l(u,[]);else if(typeof u=="object")if(Array.isArray(u)){const[c,...d]=u;l(c,d)}else o(u);else throw new TypeError("Expected usable value, not `"+u+"`")}function o(u){if(!("plugins"in u)&&!("settings"in u))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");s(u.plugins),u.settings&&(i.settings=Ww(!0,i.settings,u.settings))}function s(u){let c=-1;if(u!=null)if(Array.isArray(u))for(;++c<u.length;){const d=u[c];a(d)}else throw new TypeError("Expected a list of plugins, not `"+u+"`")}function l(u,c){let d=-1,f=-1;for(;++d<r.length;)if(r[d][0]===u){f=d;break}if(f===-1)r.push([u,...c]);else if(c.length>0){let[p,...g]=c;const w=r[f][1];Yw(w)&&Yw(p)&&(p=Ww(!0,w,p)),r[f]=[u,p,...g]}}}}const yW=new Qw().freeze();function Zw(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Jw(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function ey(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function DC(e){if(!Yw(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function LC(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Jf(e){return vW(e)?e:new PC(e)}function vW(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function bW(e){return typeof e=="string"||xW(e)}function xW(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const EW="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",MC=[],FC={allowDangerousHtml:!0},TW=/^(https?|ircs?|mailto|xmpp)$/i,_W=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function SW(e){const t=e.allowedElements,n=e.allowElement,r=e.children||"",i=e.className,a=e.components,o=e.disallowedElements,s=e.rehypePlugins||MC,l=e.remarkPlugins||MC,u=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...FC}:FC,c=e.skipHtml,d=e.unwrapDisallowed,f=e.urlTransform||kW,p=yW().use(m$).use(l).use(tW,u).use(s),g=new PC;typeof r=="string"&&(g.value=r);for(const v of _W)Object.hasOwn(e,v.from)&&(""+v.from+(v.to?"use `"+v.to+"` instead":"remove it")+EW+v.id,void 0);const w=p.parse(g);let x=p.runSync(w,g);return i&&(x={type:"element",tagName:"div",properties:{className:i},children:x.type==="root"?x.children:[x]}),zf(x,m),OV(x,{Fragment:E.Fragment,components:a,ignoreInvalidStyle:!0,jsx:E.jsx,jsxs:E.jsxs,passKeys:!0,passNode:!0});function m(v,b,T){if(v.type==="raw"&&T&&typeof b=="number")return c?T.children.splice(b,1):T.children[b]={type:"text",value:v.value},b;if(v.type==="element"){let _;for(_ in jw)if(Object.hasOwn(jw,_)&&Object.hasOwn(v.properties,_)){const S=v.properties[_],R=jw[_];(R===null||R.includes(v.tagName))&&(v.properties[_]=f(String(S||""),_,v))}}if(v.type==="element"){let _=t?!t.includes(v.tagName):o?o.includes(v.tagName):!1;if(!_&&n&&typeof b=="number"&&(_=!n(v,b,T)),_&&T&&typeof b=="number")return d&&v.children?T.children.splice(b,1,...v.children):T.children.splice(b,1),b}}}function kW(e){const t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),i=e.indexOf("/");return t<0||i>-1&&t>i||n>-1&&t>n||r>-1&&t>r||TW.test(e.slice(0,t))?e:""}const CW=_t.memo(SW,(e,t)=>e.children===t.children&&e.className===t.className),BC=/[#.]/g;function AW(e,t){const n=e||"",r={};let i=0,a,o;for(;i<n.length;){BC.lastIndex=i;const s=BC.exec(n),l=n.slice(i,s?s.index:n.length);l&&(a?a==="#"?r.id=l:Array.isArray(r.className)?r.className.push(l):r.className=[l]:o=l,i+=l.length),s&&(a=s[0],i++)}return{type:"element",tagName:o||t||"div",properties:r,children:[]}}const ty={}.hasOwnProperty;function jC(e,t,n){const r=n&&PW(n);function i(a,o,...s){let l=-1,u;if(a==null){u={type:"root",children:[]};const c=o;s.unshift(c)}else if(u=AW(a,t),u.tagName=u.tagName.toLowerCase(),r&&ty.call(r,u.tagName)&&(u.tagName=r[u.tagName]),RW(o))s.unshift(o);else{let c;for(c in o)ty.call(o,c)&&NW(e,u.properties,c,o[c])}for(;++l<s.length;)ny(u.children,s[l]);return u.type==="element"&&u.tagName==="template"&&(u.content={type:"root",children:u.children},u.children=[]),u}return i}function RW(e){if(e===null||typeof e!="object"||Array.isArray(e))return!0;if(typeof e.type!="string")return!1;const t=e,n=Object.keys(e);for(const r of n){const i=t[r];if(i&&typeof i=="object"){if(!Array.isArray(i))return!0;const a=i;for(const o of a)if(typeof o!="number"&&typeof o!="string")return!0}}return!!("children"in e&&Array.isArray(e.children))}function NW(e,t,n,r){const i=Wf(e,n);let a=-1,o;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;o=r}else typeof r=="boolean"?o=r:typeof r=="string"?i.spaceSeparated?o=Vk(r):i.commaSeparated?o=Rk(r):i.commaOrSpaceSeparated?o=Vk(Rk(r).join(" ")):o=zC(i,i.property,r):Array.isArray(r)?o=r.concat():o=i.property==="style"?OW(r):String(r);if(Array.isArray(o)){const s=[];for(;++a<o.length;){const l=zC(i,i.property,o[a]);s[a]=l}o=s}if(i.property==="className"&&Array.isArray(t.className)){const s=o;o=t.className.concat(s)}t[i.property]=o}}function ny(e,t){let n=-1;if(t!=null)if(typeof t=="string"||typeof t=="number")e.push({type:"text",value:String(t)});else if(Array.isArray(t))for(;++n<t.length;)ny(e,t[n]);else if(typeof t=="object"&&"type"in t)t.type==="root"?ny(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function zC(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||ku(n)===ku(t)))return!0}return n}function OW(e){const t=[];let n;for(n in e)ty.call(e,n)&&t.push([n,e[n]].join(": "));return t.join("; ")}function PW(e){const t={};let n=-1;for(;++n<e.length;)t[e[n].toLowerCase()]=e[n];return t}const IW=["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","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","foreignObject","glyphRef","linearGradient","radialGradient","solidColor","textArea","textPath"],DW=jC(Cu,"div"),LW=jC(la,"g",IW);function MW(e){const t=String(e),n=[];return{toOffset:i,toPoint:r};function r(a){if(typeof a=="number"&&a>-1&&a<=t.length){let o=0;for(;;){let s=n[o];if(s===void 0){const l=UC(t,n[o-1]);s=l===-1?t.length+1:l+1,n[o]=s}if(s>a)return{line:o+1,column:a-(o>0?n[o-1]:0)+1,offset:a};o++}}}function i(a){if(a&&typeof a.line=="number"&&typeof a.column=="number"&&!Number.isNaN(a.line)&&!Number.isNaN(a.column)){for(;n.length<a.line;){const s=n[n.length-1],l=UC(t,s),u=l===-1?t.length+1:l+1;if(s===u)break;n.push(u)}const o=(a.line>1?n[a.line-2]:0)+a.column-1;if(o<n[a.line-1])return o}}}function UC(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
81
+ `,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const eo={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},HC={}.hasOwnProperty,FW=Object.prototype;function BW(e,t){const n=t||{};return ry({file:n.file||void 0,location:!1,schema:n.space==="svg"?la:Cu,verbose:n.verbose||!1},e)}function ry(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},ep(e,r,n),n}case"#document":case"#document-fragment":{const r=t,i="mode"in r?r.mode==="quirks"||r.mode==="limited-quirks":!1;if(n={type:"root",children:VC(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){const a=String(e.file),o=MW(a),s=o.toPoint(0),l=o.toPoint(a.length);n.position={start:s,end:l}}return n}case"#documentType":{const r=t;return n={type:"doctype"},ep(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},ep(e,r,n),n}default:return n=jW(e,t),n}}function VC(e,t){let n=-1;const r=[];for(;++n<t.length;){const i=ry(e,t[n]);r.push(i)}return r}function jW(e,t){const n=e.schema;e.schema=t.namespaceURI===eo.svg?la:Cu;let r=-1;const i={};for(;++r<t.attrs.length;){const s=t.attrs[r],l=(s.prefix?s.prefix+":":"")+s.name;HC.call(FW,l)||(i[l]=s.value)}const o=(e.schema.space==="svg"?LW:DW)(t.tagName,i,VC(e,t.childNodes));if(ep(e,t,o),o.tagName==="template"){const s=t,l=s.sourceCodeLocation,u=l&&l.startTag&&ys(l.startTag),c=l&&l.endTag&&ys(l.endTag),d=ry(e,s.content);u&&c&&e.file&&(d.position={start:u.end,end:c.start}),o.content=d}return e.schema=n,o}function ep(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=zW(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function zW(e,t,n){const r=ys(n);if(t.type==="element"){const i=t.children[t.children.length-1];if(r&&!n.endTag&&i&&i.position&&i.position.end&&(r.end=Object.assign({},i.position.end)),e.verbose){const a={};let o;if(n.attrs)for(o in n.attrs)HC.call(n.attrs,o)&&(a[Wf(e.schema,o).property]=ys(n.attrs[o]));n.startTag;const s=ys(n.startTag),l=n.endTag?ys(n.endTag):void 0,u={opening:s};l&&(u.closing=l),u.properties=a,t.data={position:u}}}return r}function ys(e){const t=$C({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=$C({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function $C(e){return e.line&&e.column?e:void 0}const UW={},HW={}.hasOwnProperty,WC=zS("type",{handlers:{root:$W,element:KW,text:qW,comment:GW,doctype:YW}});function VW(e,t){const r=(t||UW).space;return WC(e,r==="svg"?la:Cu)}function $W(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=iy(e.children,n,t),vs(e,n),n}function WW(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=iy(e.children,n,t),vs(e,n),n}function YW(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return vs(e,t),t}function qW(e){const t={nodeName:"#text",value:e.value,parentNode:null};return vs(e,t),t}function GW(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return vs(e,t),t}function KW(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=la);const i=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&HW.call(e.properties,a)){const l=XW(r,a,e.properties[a]);l&&i.push(l)}}const o=r.space,s={nodeName:e.tagName,tagName:e.tagName,attrs:i,namespaceURI:eo[o],childNodes:[],parentNode:null};return s.childNodes=iy(e.children,s,r),vs(e,s),e.tagName==="template"&&e.content&&(s.content=WW(e.content,r)),s}function XW(e,t,n){const r=Wf(e,t);if(n===!1||n===null||n===void 0||typeof n=="number"&&Number.isNaN(n)||!n&&r.boolean)return;Array.isArray(n)&&(n=r.commaSeparated?Nk(n):$k(n));const i={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const a=i.name.indexOf(":");a<0?i.prefix="":(i.name=i.name.slice(a+1),i.prefix=r.attribute.slice(0,a)),i.namespace=eo[r.space]}return i}function iy(e,t,n){let r=-1;const i=[];if(e)for(;++r<e.length;){const a=WC(e[r],n);a.parentNode=t,i.push(a)}return i}function vs(e,t){const n=e.position;n&&n.start&&n.end&&(n.start.offset,n.end.offset,t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset})}const QW=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],ZW=new Set([65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111]),nt="�";var k;(function(e){e[e.EOF=-1]="EOF",e[e.NULL=0]="NULL",e[e.TABULATION=9]="TABULATION",e[e.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",e[e.LINE_FEED=10]="LINE_FEED",e[e.FORM_FEED=12]="FORM_FEED",e[e.SPACE=32]="SPACE",e[e.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",e[e.QUOTATION_MARK=34]="QUOTATION_MARK",e[e.AMPERSAND=38]="AMPERSAND",e[e.APOSTROPHE=39]="APOSTROPHE",e[e.HYPHEN_MINUS=45]="HYPHEN_MINUS",e[e.SOLIDUS=47]="SOLIDUS",e[e.DIGIT_0=48]="DIGIT_0",e[e.DIGIT_9=57]="DIGIT_9",e[e.SEMICOLON=59]="SEMICOLON",e[e.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",e[e.EQUALS_SIGN=61]="EQUALS_SIGN",e[e.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",e[e.QUESTION_MARK=63]="QUESTION_MARK",e[e.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",e[e.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",e[e.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",e[e.GRAVE_ACCENT=96]="GRAVE_ACCENT",e[e.LATIN_SMALL_A=97]="LATIN_SMALL_A",e[e.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(k||(k={}));const gn={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function YC(e){return e>=55296&&e<=57343}function JW(e){return e>=56320&&e<=57343}function eY(e,t){return(e-55296)*1024+9216+t}function qC(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function GC(e){return e>=64976&&e<=65007||ZW.has(e)}var j;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(j||(j={}));const tY=65536;class nY{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=tY,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t,n){const{line:r,col:i,offset:a}=this,o=i+n,s=a+n;return{code:t,startLine:r,endLine:r,startCol:o,endCol:o,startOffset:s,endOffset:s}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(JW(n))return this.pos++,this._addGap(),eY(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,k.EOF;return this._err(j.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r<t.length;r++)if((this.html.charCodeAt(this.pos+r)|32)!==t.charCodeAt(r))return!1;return!0}peek(t){const n=this.pos+t;if(n>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,k.EOF;const r=this.html.charCodeAt(n);return r===k.CARRIAGE_RETURN?k.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,k.EOF;let t=this.html.charCodeAt(this.pos);return t===k.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,k.LINE_FEED):t===k.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,YC(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===k.LINE_FEED||t===k.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){qC(t)?this._err(j.controlCharacterInInputStream):GC(t)&&this._err(j.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var Ae;(function(e){e[e.CHARACTER=0]="CHARACTER",e[e.NULL_CHARACTER=1]="NULL_CHARACTER",e[e.WHITESPACE_CHARACTER=2]="WHITESPACE_CHARACTER",e[e.START_TAG=3]="START_TAG",e[e.END_TAG=4]="END_TAG",e[e.COMMENT=5]="COMMENT",e[e.DOCTYPE=6]="DOCTYPE",e[e.EOF=7]="EOF",e[e.HIBERNATION=8]="HIBERNATION"})(Ae||(Ae={}));function KC(e,t){for(let n=e.attrs.length-1;n>=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}const XC=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),rY=new Uint16Array("Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(e=>e.charCodeAt(0)));var ay;const iY=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]),aY=(ay=String.fromCodePoint)!==null&&ay!==void 0?ay:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|e&1023),t+=String.fromCharCode(e),t};function oY(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=iY.get(e))!==null&&t!==void 0?t:e}var At;(function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"})(At||(At={}));const sY=32;var ca;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(ca||(ca={}));function oy(e){return e>=At.ZERO&&e<=At.NINE}function lY(e){return e>=At.UPPER_A&&e<=At.UPPER_F||e>=At.LOWER_A&&e<=At.LOWER_F}function uY(e){return e>=At.UPPER_A&&e<=At.UPPER_Z||e>=At.LOWER_A&&e<=At.LOWER_Z||oy(e)}function cY(e){return e===At.EQUALS||uY(e)}var Rt;(function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"})(Rt||(Rt={}));var pi;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(pi||(pi={}));class QC{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Rt.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=pi.Strict}startEntity(t){this.decodeMode=t,this.state=Rt.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Rt.EntityStart:return t.charCodeAt(n)===At.NUM?(this.state=Rt.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Rt.NamedEntity,this.stateNamedEntity(t,n));case Rt.NumericStart:return this.stateNumericStart(t,n);case Rt.NumericDecimal:return this.stateNumericDecimal(t,n);case Rt.NumericHex:return this.stateNumericHex(t,n);case Rt.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|sY)===At.LOWER_X?(this.state=Rt.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Rt.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,i){if(n!==r){const a=r-n;this.result=this.result*Math.pow(i,a)+parseInt(t.substr(n,a),i),this.consumed+=a}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(oy(i)||lY(i))n+=1;else return this.addToNumericResult(t,r,n,16),this.emitNumericEntity(i,3)}return this.addToNumericResult(t,r,n,16),-1}stateNumericDecimal(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(oy(i))n+=1;else return this.addToNumericResult(t,r,n,10),this.emitNumericEntity(i,2)}return this.addToNumericResult(t,r,n,10),-1}emitNumericEntity(t,n){var r;if(this.consumed<=n)return(r=this.errors)===null||r===void 0||r.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===At.SEMI)this.consumed+=1;else if(this.decodeMode===pi.Strict)return 0;return this.emitCodePoint(oY(this.result),this.consumed),this.errors&&(t!==At.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let i=r[this.treeIndex],a=(i&ca.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const o=t.charCodeAt(n);if(this.treeIndex=dY(r,i,this.treeIndex+Math.max(1,a),o),this.treeIndex<0)return this.result===0||this.decodeMode===pi.Attribute&&(a===0||cY(o))?0:this.emitNotTerminatedNamedEntity();if(i=r[this.treeIndex],a=(i&ca.VALUE_LENGTH)>>14,a!==0){if(o===At.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==pi.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,i=(r[n]&ca.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,i,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:i}=this;return this.emitCodePoint(n===1?i[t]&~ca.VALUE_LENGTH:i[t+1],r),n===3&&this.emitCodePoint(i[t+2],r),r}end(){var t;switch(this.state){case Rt.NamedEntity:return this.result!==0&&(this.decodeMode!==pi.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Rt.NumericDecimal:return this.emitNumericEntity(0,2);case Rt.NumericHex:return this.emitNumericEntity(0,3);case Rt.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Rt.EntityStart:return 0}}}function ZC(e){let t="";const n=new QC(e,r=>t+=aY(r));return function(i,a){let o=0,s=0;for(;(s=i.indexOf("&",s))>=0;){t+=i.slice(o,s),n.startEntity(a);const u=n.write(i,s+1);if(u<0){o=s+n.end();break}o=s+u,s=u===0?o+1:o}const l=t+i.slice(o);return t="",l}}function dY(e,t,n,r){const i=(t&ca.BRANCH_LENGTH)>>7,a=t&ca.JUMP_TABLE;if(i===0)return a!==0&&r===a?n:-1;if(a){const l=r-a;return l<0||l>=i?-1:e[n+l]-1}let o=n,s=o+i-1;for(;o<=s;){const l=o+s>>>1,u=e[l];if(u<r)o=l+1;else if(u>r)s=l-1;else return e[l+i]}return-1}ZC(XC),ZC(rY);var V;(function(e){e.HTML="http://www.w3.org/1999/xhtml",e.MATHML="http://www.w3.org/1998/Math/MathML",e.SVG="http://www.w3.org/2000/svg",e.XLINK="http://www.w3.org/1999/xlink",e.XML="http://www.w3.org/XML/1998/namespace",e.XMLNS="http://www.w3.org/2000/xmlns/"})(V||(V={}));var to;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(to||(to={}));var Gn;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Gn||(Gn={}));var D;(function(e){e.A="a",e.ADDRESS="address",e.ANNOTATION_XML="annotation-xml",e.APPLET="applet",e.AREA="area",e.ARTICLE="article",e.ASIDE="aside",e.B="b",e.BASE="base",e.BASEFONT="basefont",e.BGSOUND="bgsound",e.BIG="big",e.BLOCKQUOTE="blockquote",e.BODY="body",e.BR="br",e.BUTTON="button",e.CAPTION="caption",e.CENTER="center",e.CODE="code",e.COL="col",e.COLGROUP="colgroup",e.DD="dd",e.DESC="desc",e.DETAILS="details",e.DIALOG="dialog",e.DIR="dir",e.DIV="div",e.DL="dl",e.DT="dt",e.EM="em",e.EMBED="embed",e.FIELDSET="fieldset",e.FIGCAPTION="figcaption",e.FIGURE="figure",e.FONT="font",e.FOOTER="footer",e.FOREIGN_OBJECT="foreignObject",e.FORM="form",e.FRAME="frame",e.FRAMESET="frameset",e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.HEAD="head",e.HEADER="header",e.HGROUP="hgroup",e.HR="hr",e.HTML="html",e.I="i",e.IMG="img",e.IMAGE="image",e.INPUT="input",e.IFRAME="iframe",e.KEYGEN="keygen",e.LABEL="label",e.LI="li",e.LINK="link",e.LISTING="listing",e.MAIN="main",e.MALIGNMARK="malignmark",e.MARQUEE="marquee",e.MATH="math",e.MENU="menu",e.META="meta",e.MGLYPH="mglyph",e.MI="mi",e.MO="mo",e.MN="mn",e.MS="ms",e.MTEXT="mtext",e.NAV="nav",e.NOBR="nobr",e.NOFRAMES="noframes",e.NOEMBED="noembed",e.NOSCRIPT="noscript",e.OBJECT="object",e.OL="ol",e.OPTGROUP="optgroup",e.OPTION="option",e.P="p",e.PARAM="param",e.PLAINTEXT="plaintext",e.PRE="pre",e.RB="rb",e.RP="rp",e.RT="rt",e.RTC="rtc",e.RUBY="ruby",e.S="s",e.SCRIPT="script",e.SEARCH="search",e.SECTION="section",e.SELECT="select",e.SOURCE="source",e.SMALL="small",e.SPAN="span",e.STRIKE="strike",e.STRONG="strong",e.STYLE="style",e.SUB="sub",e.SUMMARY="summary",e.SUP="sup",e.TABLE="table",e.TBODY="tbody",e.TEMPLATE="template",e.TEXTAREA="textarea",e.TFOOT="tfoot",e.TD="td",e.TH="th",e.THEAD="thead",e.TITLE="title",e.TR="tr",e.TRACK="track",e.TT="tt",e.U="u",e.UL="ul",e.SVG="svg",e.VAR="var",e.WBR="wbr",e.XMP="xmp"})(D||(D={}));var h;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.A=1]="A",e[e.ADDRESS=2]="ADDRESS",e[e.ANNOTATION_XML=3]="ANNOTATION_XML",e[e.APPLET=4]="APPLET",e[e.AREA=5]="AREA",e[e.ARTICLE=6]="ARTICLE",e[e.ASIDE=7]="ASIDE",e[e.B=8]="B",e[e.BASE=9]="BASE",e[e.BASEFONT=10]="BASEFONT",e[e.BGSOUND=11]="BGSOUND",e[e.BIG=12]="BIG",e[e.BLOCKQUOTE=13]="BLOCKQUOTE",e[e.BODY=14]="BODY",e[e.BR=15]="BR",e[e.BUTTON=16]="BUTTON",e[e.CAPTION=17]="CAPTION",e[e.CENTER=18]="CENTER",e[e.CODE=19]="CODE",e[e.COL=20]="COL",e[e.COLGROUP=21]="COLGROUP",e[e.DD=22]="DD",e[e.DESC=23]="DESC",e[e.DETAILS=24]="DETAILS",e[e.DIALOG=25]="DIALOG",e[e.DIR=26]="DIR",e[e.DIV=27]="DIV",e[e.DL=28]="DL",e[e.DT=29]="DT",e[e.EM=30]="EM",e[e.EMBED=31]="EMBED",e[e.FIELDSET=32]="FIELDSET",e[e.FIGCAPTION=33]="FIGCAPTION",e[e.FIGURE=34]="FIGURE",e[e.FONT=35]="FONT",e[e.FOOTER=36]="FOOTER",e[e.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",e[e.FORM=38]="FORM",e[e.FRAME=39]="FRAME",e[e.FRAMESET=40]="FRAMESET",e[e.H1=41]="H1",e[e.H2=42]="H2",e[e.H3=43]="H3",e[e.H4=44]="H4",e[e.H5=45]="H5",e[e.H6=46]="H6",e[e.HEAD=47]="HEAD",e[e.HEADER=48]="HEADER",e[e.HGROUP=49]="HGROUP",e[e.HR=50]="HR",e[e.HTML=51]="HTML",e[e.I=52]="I",e[e.IMG=53]="IMG",e[e.IMAGE=54]="IMAGE",e[e.INPUT=55]="INPUT",e[e.IFRAME=56]="IFRAME",e[e.KEYGEN=57]="KEYGEN",e[e.LABEL=58]="LABEL",e[e.LI=59]="LI",e[e.LINK=60]="LINK",e[e.LISTING=61]="LISTING",e[e.MAIN=62]="MAIN",e[e.MALIGNMARK=63]="MALIGNMARK",e[e.MARQUEE=64]="MARQUEE",e[e.MATH=65]="MATH",e[e.MENU=66]="MENU",e[e.META=67]="META",e[e.MGLYPH=68]="MGLYPH",e[e.MI=69]="MI",e[e.MO=70]="MO",e[e.MN=71]="MN",e[e.MS=72]="MS",e[e.MTEXT=73]="MTEXT",e[e.NAV=74]="NAV",e[e.NOBR=75]="NOBR",e[e.NOFRAMES=76]="NOFRAMES",e[e.NOEMBED=77]="NOEMBED",e[e.NOSCRIPT=78]="NOSCRIPT",e[e.OBJECT=79]="OBJECT",e[e.OL=80]="OL",e[e.OPTGROUP=81]="OPTGROUP",e[e.OPTION=82]="OPTION",e[e.P=83]="P",e[e.PARAM=84]="PARAM",e[e.PLAINTEXT=85]="PLAINTEXT",e[e.PRE=86]="PRE",e[e.RB=87]="RB",e[e.RP=88]="RP",e[e.RT=89]="RT",e[e.RTC=90]="RTC",e[e.RUBY=91]="RUBY",e[e.S=92]="S",e[e.SCRIPT=93]="SCRIPT",e[e.SEARCH=94]="SEARCH",e[e.SECTION=95]="SECTION",e[e.SELECT=96]="SELECT",e[e.SOURCE=97]="SOURCE",e[e.SMALL=98]="SMALL",e[e.SPAN=99]="SPAN",e[e.STRIKE=100]="STRIKE",e[e.STRONG=101]="STRONG",e[e.STYLE=102]="STYLE",e[e.SUB=103]="SUB",e[e.SUMMARY=104]="SUMMARY",e[e.SUP=105]="SUP",e[e.TABLE=106]="TABLE",e[e.TBODY=107]="TBODY",e[e.TEMPLATE=108]="TEMPLATE",e[e.TEXTAREA=109]="TEXTAREA",e[e.TFOOT=110]="TFOOT",e[e.TD=111]="TD",e[e.TH=112]="TH",e[e.THEAD=113]="THEAD",e[e.TITLE=114]="TITLE",e[e.TR=115]="TR",e[e.TRACK=116]="TRACK",e[e.TT=117]="TT",e[e.U=118]="U",e[e.UL=119]="UL",e[e.SVG=120]="SVG",e[e.VAR=121]="VAR",e[e.WBR=122]="WBR",e[e.XMP=123]="XMP"})(h||(h={}));const fY=new Map([[D.A,h.A],[D.ADDRESS,h.ADDRESS],[D.ANNOTATION_XML,h.ANNOTATION_XML],[D.APPLET,h.APPLET],[D.AREA,h.AREA],[D.ARTICLE,h.ARTICLE],[D.ASIDE,h.ASIDE],[D.B,h.B],[D.BASE,h.BASE],[D.BASEFONT,h.BASEFONT],[D.BGSOUND,h.BGSOUND],[D.BIG,h.BIG],[D.BLOCKQUOTE,h.BLOCKQUOTE],[D.BODY,h.BODY],[D.BR,h.BR],[D.BUTTON,h.BUTTON],[D.CAPTION,h.CAPTION],[D.CENTER,h.CENTER],[D.CODE,h.CODE],[D.COL,h.COL],[D.COLGROUP,h.COLGROUP],[D.DD,h.DD],[D.DESC,h.DESC],[D.DETAILS,h.DETAILS],[D.DIALOG,h.DIALOG],[D.DIR,h.DIR],[D.DIV,h.DIV],[D.DL,h.DL],[D.DT,h.DT],[D.EM,h.EM],[D.EMBED,h.EMBED],[D.FIELDSET,h.FIELDSET],[D.FIGCAPTION,h.FIGCAPTION],[D.FIGURE,h.FIGURE],[D.FONT,h.FONT],[D.FOOTER,h.FOOTER],[D.FOREIGN_OBJECT,h.FOREIGN_OBJECT],[D.FORM,h.FORM],[D.FRAME,h.FRAME],[D.FRAMESET,h.FRAMESET],[D.H1,h.H1],[D.H2,h.H2],[D.H3,h.H3],[D.H4,h.H4],[D.H5,h.H5],[D.H6,h.H6],[D.HEAD,h.HEAD],[D.HEADER,h.HEADER],[D.HGROUP,h.HGROUP],[D.HR,h.HR],[D.HTML,h.HTML],[D.I,h.I],[D.IMG,h.IMG],[D.IMAGE,h.IMAGE],[D.INPUT,h.INPUT],[D.IFRAME,h.IFRAME],[D.KEYGEN,h.KEYGEN],[D.LABEL,h.LABEL],[D.LI,h.LI],[D.LINK,h.LINK],[D.LISTING,h.LISTING],[D.MAIN,h.MAIN],[D.MALIGNMARK,h.MALIGNMARK],[D.MARQUEE,h.MARQUEE],[D.MATH,h.MATH],[D.MENU,h.MENU],[D.META,h.META],[D.MGLYPH,h.MGLYPH],[D.MI,h.MI],[D.MO,h.MO],[D.MN,h.MN],[D.MS,h.MS],[D.MTEXT,h.MTEXT],[D.NAV,h.NAV],[D.NOBR,h.NOBR],[D.NOFRAMES,h.NOFRAMES],[D.NOEMBED,h.NOEMBED],[D.NOSCRIPT,h.NOSCRIPT],[D.OBJECT,h.OBJECT],[D.OL,h.OL],[D.OPTGROUP,h.OPTGROUP],[D.OPTION,h.OPTION],[D.P,h.P],[D.PARAM,h.PARAM],[D.PLAINTEXT,h.PLAINTEXT],[D.PRE,h.PRE],[D.RB,h.RB],[D.RP,h.RP],[D.RT,h.RT],[D.RTC,h.RTC],[D.RUBY,h.RUBY],[D.S,h.S],[D.SCRIPT,h.SCRIPT],[D.SEARCH,h.SEARCH],[D.SECTION,h.SECTION],[D.SELECT,h.SELECT],[D.SOURCE,h.SOURCE],[D.SMALL,h.SMALL],[D.SPAN,h.SPAN],[D.STRIKE,h.STRIKE],[D.STRONG,h.STRONG],[D.STYLE,h.STYLE],[D.SUB,h.SUB],[D.SUMMARY,h.SUMMARY],[D.SUP,h.SUP],[D.TABLE,h.TABLE],[D.TBODY,h.TBODY],[D.TEMPLATE,h.TEMPLATE],[D.TEXTAREA,h.TEXTAREA],[D.TFOOT,h.TFOOT],[D.TD,h.TD],[D.TH,h.TH],[D.THEAD,h.THEAD],[D.TITLE,h.TITLE],[D.TR,h.TR],[D.TRACK,h.TRACK],[D.TT,h.TT],[D.U,h.U],[D.UL,h.UL],[D.SVG,h.SVG],[D.VAR,h.VAR],[D.WBR,h.WBR],[D.XMP,h.XMP]]);function bs(e){var t;return(t=fY.get(e))!==null&&t!==void 0?t:h.UNKNOWN}const W=h,pY={[V.HTML]:new Set([W.ADDRESS,W.APPLET,W.AREA,W.ARTICLE,W.ASIDE,W.BASE,W.BASEFONT,W.BGSOUND,W.BLOCKQUOTE,W.BODY,W.BR,W.BUTTON,W.CAPTION,W.CENTER,W.COL,W.COLGROUP,W.DD,W.DETAILS,W.DIR,W.DIV,W.DL,W.DT,W.EMBED,W.FIELDSET,W.FIGCAPTION,W.FIGURE,W.FOOTER,W.FORM,W.FRAME,W.FRAMESET,W.H1,W.H2,W.H3,W.H4,W.H5,W.H6,W.HEAD,W.HEADER,W.HGROUP,W.HR,W.HTML,W.IFRAME,W.IMG,W.INPUT,W.LI,W.LINK,W.LISTING,W.MAIN,W.MARQUEE,W.MENU,W.META,W.NAV,W.NOEMBED,W.NOFRAMES,W.NOSCRIPT,W.OBJECT,W.OL,W.P,W.PARAM,W.PLAINTEXT,W.PRE,W.SCRIPT,W.SECTION,W.SELECT,W.SOURCE,W.STYLE,W.SUMMARY,W.TABLE,W.TBODY,W.TD,W.TEMPLATE,W.TEXTAREA,W.TFOOT,W.TH,W.THEAD,W.TITLE,W.TR,W.TRACK,W.UL,W.WBR,W.XMP]),[V.MATHML]:new Set([W.MI,W.MO,W.MN,W.MS,W.MTEXT,W.ANNOTATION_XML]),[V.SVG]:new Set([W.TITLE,W.FOREIGN_OBJECT,W.DESC]),[V.XLINK]:new Set,[V.XML]:new Set,[V.XMLNS]:new Set},sy=new Set([W.H1,W.H2,W.H3,W.H4,W.H5,W.H6]);D.STYLE,D.SCRIPT,D.XMP,D.IFRAME,D.NOEMBED,D.NOFRAMES,D.PLAINTEXT;var A;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(A||(A={}));const pt={DATA:A.DATA,RCDATA:A.RCDATA,RAWTEXT:A.RAWTEXT,SCRIPT_DATA:A.SCRIPT_DATA,PLAINTEXT:A.PLAINTEXT,CDATA_SECTION:A.CDATA_SECTION};function hY(e){return e>=k.DIGIT_0&&e<=k.DIGIT_9}function Pu(e){return e>=k.LATIN_CAPITAL_A&&e<=k.LATIN_CAPITAL_Z}function mY(e){return e>=k.LATIN_SMALL_A&&e<=k.LATIN_SMALL_Z}function da(e){return mY(e)||Pu(e)}function JC(e){return da(e)||hY(e)}function tp(e){return e+32}function eA(e){return e===k.SPACE||e===k.LINE_FEED||e===k.TABULATION||e===k.FORM_FEED}function tA(e){return eA(e)||e===k.SOLIDUS||e===k.GREATER_THAN_SIGN}function gY(e){return e===k.NULL?j.nullCharacterReference:e>1114111?j.characterReferenceOutsideUnicodeRange:YC(e)?j.surrogateCharacterReference:GC(e)?j.noncharacterCharacterReference:qC(e)||e===k.CARRIAGE_RETURN?j.controlCharacterReference:null}class wY{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=A.DATA,this.returnState=A.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new nY(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new QC(XC,(r,i)=>{this.preprocessor.pos=this.entityStartPos+i-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(j.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(j.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const i=gY(r);i&&this._err(i,1)}}:void 0)}_err(t,n=0){var r,i;(i=(r=this.handler).onParseError)===null||i===void 0||i.call(r,this.preprocessor.getError(t,n))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t==null||t())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r==null||r()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n<t;n++)this.preprocessor.advance()}_consumeSequenceIfMatch(t,n){return this.preprocessor.startsWith(t,n)?(this._advanceBy(t.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:Ae.START_TAG,tagName:"",tagID:h.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:Ae.END_TAG,tagName:"",tagID:h.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:Ae.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:Ae.DOCTYPE,name:t,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(t,n){this.currentCharacterToken={type:t,chars:n,location:this.currentLocation}}_createAttr(t){this.currentAttr={name:t,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var t,n;const r=this.currentToken;if(KC(r,this.currentAttr.name)===null){if(r.attrs.push(this.currentAttr),r.location&&this.currentLocation){const i=(t=(n=r.location).attrs)!==null&&t!==void 0?t:n.attrs=Object.create(null);i[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(j.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=bs(t.tagName),t.type===Ae.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(j.endTagWithAttributes),t.selfClosing&&this._err(j.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case Ae.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case Ae.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case Ae.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:Ae.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type===t){this.currentCharacterToken.chars+=n;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(t,n)}_emitCodePoint(t){const n=eA(t)?Ae.WHITESPACE_CHARACTER:t===k.NULL?Ae.NULL_CHARACTER:Ae.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(Ae.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=A.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?pi.Attribute:pi.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===A.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===A.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===A.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case A.DATA:{this._stateData(t);break}case A.RCDATA:{this._stateRcdata(t);break}case A.RAWTEXT:{this._stateRawtext(t);break}case A.SCRIPT_DATA:{this._stateScriptData(t);break}case A.PLAINTEXT:{this._statePlaintext(t);break}case A.TAG_OPEN:{this._stateTagOpen(t);break}case A.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case A.TAG_NAME:{this._stateTagName(t);break}case A.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case A.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case A.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case A.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case A.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case A.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case A.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case A.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case A.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case A.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case A.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case A.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case A.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case A.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case A.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case A.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case A.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case A.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case A.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case A.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case A.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case A.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case A.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case A.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case A.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case A.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case A.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case A.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case A.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case A.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case A.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case A.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case A.BOGUS_COMMENT:{this._stateBogusComment(t);break}case A.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case A.COMMENT_START:{this._stateCommentStart(t);break}case A.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case A.COMMENT:{this._stateComment(t);break}case A.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case A.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case A.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case A.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case A.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case A.COMMENT_END:{this._stateCommentEnd(t);break}case A.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case A.DOCTYPE:{this._stateDoctype(t);break}case A.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case A.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case A.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case A.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case A.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case A.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case A.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case A.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case A.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case A.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case A.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case A.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case A.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case A.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case A.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case A.CDATA_SECTION:{this._stateCdataSection(t);break}case A.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case A.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case A.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case A.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case k.LESS_THAN_SIGN:{this.state=A.TAG_OPEN;break}case k.AMPERSAND:{this._startCharacterReference();break}case k.NULL:{this._err(j.unexpectedNullCharacter),this._emitCodePoint(t);break}case k.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case k.AMPERSAND:{this._startCharacterReference();break}case k.LESS_THAN_SIGN:{this.state=A.RCDATA_LESS_THAN_SIGN;break}case k.NULL:{this._err(j.unexpectedNullCharacter),this._emitChars(nt);break}case k.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case k.LESS_THAN_SIGN:{this.state=A.RAWTEXT_LESS_THAN_SIGN;break}case k.NULL:{this._err(j.unexpectedNullCharacter),this._emitChars(nt);break}case k.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case k.LESS_THAN_SIGN:{this.state=A.SCRIPT_DATA_LESS_THAN_SIGN;break}case k.NULL:{this._err(j.unexpectedNullCharacter),this._emitChars(nt);break}case k.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case k.NULL:{this._err(j.unexpectedNullCharacter),this._emitChars(nt);break}case k.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(da(t))this._createStartTagToken(),this.state=A.TAG_NAME,this._stateTagName(t);else switch(t){case k.EXCLAMATION_MARK:{this.state=A.MARKUP_DECLARATION_OPEN;break}case k.SOLIDUS:{this.state=A.END_TAG_OPEN;break}case k.QUESTION_MARK:{this._err(j.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=A.BOGUS_COMMENT,this._stateBogusComment(t);break}case k.EOF:{this._err(j.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(j.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=A.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(da(t))this._createEndTagToken(),this.state=A.TAG_NAME,this._stateTagName(t);else switch(t){case k.GREATER_THAN_SIGN:{this._err(j.missingEndTagName),this.state=A.DATA;break}case k.EOF:{this._err(j.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(j.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=A.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:{this.state=A.BEFORE_ATTRIBUTE_NAME;break}case k.SOLIDUS:{this.state=A.SELF_CLOSING_START_TAG;break}case k.GREATER_THAN_SIGN:{this.state=A.DATA,this.emitCurrentTagToken();break}case k.NULL:{this._err(j.unexpectedNullCharacter),n.tagName+=nt;break}case k.EOF:{this._err(j.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(Pu(t)?tp(t):t)}}_stateRcdataLessThanSign(t){t===k.SOLIDUS?this.state=A.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=A.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){da(t)?(this.state=A.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=A.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=A.BEFORE_ATTRIBUTE_NAME,!1;case k.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=A.SELF_CLOSING_START_TAG,!1;case k.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=A.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=A.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===k.SOLIDUS?this.state=A.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=A.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){da(t)?(this.state=A.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=A.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=A.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case k.SOLIDUS:{this.state=A.SCRIPT_DATA_END_TAG_OPEN;break}case k.EXCLAMATION_MARK:{this.state=A.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=A.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){da(t)?(this.state=A.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=A.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=A.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===k.HYPHEN_MINUS?(this.state=A.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=A.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===k.HYPHEN_MINUS?(this.state=A.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=A.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case k.HYPHEN_MINUS:{this.state=A.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case k.LESS_THAN_SIGN:{this.state=A.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case k.NULL:{this._err(j.unexpectedNullCharacter),this._emitChars(nt);break}case k.EOF:{this._err(j.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case k.HYPHEN_MINUS:{this.state=A.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case k.LESS_THAN_SIGN:{this.state=A.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case k.NULL:{this._err(j.unexpectedNullCharacter),this.state=A.SCRIPT_DATA_ESCAPED,this._emitChars(nt);break}case k.EOF:{this._err(j.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=A.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case k.HYPHEN_MINUS:{this._emitChars("-");break}case k.LESS_THAN_SIGN:{this.state=A.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case k.GREATER_THAN_SIGN:{this.state=A.SCRIPT_DATA,this._emitChars(">");break}case k.NULL:{this._err(j.unexpectedNullCharacter),this.state=A.SCRIPT_DATA_ESCAPED,this._emitChars(nt);break}case k.EOF:{this._err(j.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=A.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===k.SOLIDUS?this.state=A.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:da(t)?(this._emitChars("<"),this.state=A.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=A.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){da(t)?(this.state=A.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=A.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=A.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(gn.SCRIPT,!1)&&tA(this.preprocessor.peek(gn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<gn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=A.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case k.HYPHEN_MINUS:{this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case k.LESS_THAN_SIGN:{this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case k.NULL:{this._err(j.unexpectedNullCharacter),this._emitChars(nt);break}case k.EOF:{this._err(j.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case k.HYPHEN_MINUS:{this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case k.LESS_THAN_SIGN:{this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case k.NULL:{this._err(j.unexpectedNullCharacter),this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(nt);break}case k.EOF:{this._err(j.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case k.HYPHEN_MINUS:{this._emitChars("-");break}case k.LESS_THAN_SIGN:{this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case k.GREATER_THAN_SIGN:{this.state=A.SCRIPT_DATA,this._emitChars(">");break}case k.NULL:{this._err(j.unexpectedNullCharacter),this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(nt);break}case k.EOF:{this._err(j.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===k.SOLIDUS?(this.state=A.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(gn.SCRIPT,!1)&&tA(this.preprocessor.peek(gn.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<gn.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=A.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=A.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:break;case k.SOLIDUS:case k.GREATER_THAN_SIGN:case k.EOF:{this.state=A.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case k.EQUALS_SIGN:{this._err(j.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=A.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=A.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:case k.SOLIDUS:case k.GREATER_THAN_SIGN:case k.EOF:{this._leaveAttrName(),this.state=A.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case k.EQUALS_SIGN:{this._leaveAttrName(),this.state=A.BEFORE_ATTRIBUTE_VALUE;break}case k.QUOTATION_MARK:case k.APOSTROPHE:case k.LESS_THAN_SIGN:{this._err(j.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case k.NULL:{this._err(j.unexpectedNullCharacter),this.currentAttr.name+=nt;break}default:this.currentAttr.name+=String.fromCodePoint(Pu(t)?tp(t):t)}}_stateAfterAttributeName(t){switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:break;case k.SOLIDUS:{this.state=A.SELF_CLOSING_START_TAG;break}case k.EQUALS_SIGN:{this.state=A.BEFORE_ATTRIBUTE_VALUE;break}case k.GREATER_THAN_SIGN:{this.state=A.DATA,this.emitCurrentTagToken();break}case k.EOF:{this._err(j.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=A.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:break;case k.QUOTATION_MARK:{this.state=A.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case k.APOSTROPHE:{this.state=A.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case k.GREATER_THAN_SIGN:{this._err(j.missingAttributeValue),this.state=A.DATA,this.emitCurrentTagToken();break}default:this.state=A.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case k.QUOTATION_MARK:{this.state=A.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case k.AMPERSAND:{this._startCharacterReference();break}case k.NULL:{this._err(j.unexpectedNullCharacter),this.currentAttr.value+=nt;break}case k.EOF:{this._err(j.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case k.APOSTROPHE:{this.state=A.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case k.AMPERSAND:{this._startCharacterReference();break}case k.NULL:{this._err(j.unexpectedNullCharacter),this.currentAttr.value+=nt;break}case k.EOF:{this._err(j.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:{this._leaveAttrValue(),this.state=A.BEFORE_ATTRIBUTE_NAME;break}case k.AMPERSAND:{this._startCharacterReference();break}case k.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=A.DATA,this.emitCurrentTagToken();break}case k.NULL:{this._err(j.unexpectedNullCharacter),this.currentAttr.value+=nt;break}case k.QUOTATION_MARK:case k.APOSTROPHE:case k.LESS_THAN_SIGN:case k.EQUALS_SIGN:case k.GRAVE_ACCENT:{this._err(j.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case k.EOF:{this._err(j.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:{this._leaveAttrValue(),this.state=A.BEFORE_ATTRIBUTE_NAME;break}case k.SOLIDUS:{this._leaveAttrValue(),this.state=A.SELF_CLOSING_START_TAG;break}case k.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=A.DATA,this.emitCurrentTagToken();break}case k.EOF:{this._err(j.eofInTag),this._emitEOFToken();break}default:this._err(j.missingWhitespaceBetweenAttributes),this.state=A.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case k.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=A.DATA,this.emitCurrentTagToken();break}case k.EOF:{this._err(j.eofInTag),this._emitEOFToken();break}default:this._err(j.unexpectedSolidusInTag),this.state=A.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case k.GREATER_THAN_SIGN:{this.state=A.DATA,this.emitCurrentComment(n);break}case k.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case k.NULL:{this._err(j.unexpectedNullCharacter),n.data+=nt;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(gn.DASH_DASH,!0)?(this._createCommentToken(gn.DASH_DASH.length+1),this.state=A.COMMENT_START):this._consumeSequenceIfMatch(gn.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(gn.DOCTYPE.length+1),this.state=A.DOCTYPE):this._consumeSequenceIfMatch(gn.CDATA_START,!0)?this.inForeignNode?this.state=A.CDATA_SECTION:(this._err(j.cdataInHtmlContent),this._createCommentToken(gn.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=A.BOGUS_COMMENT):this._ensureHibernation()||(this._err(j.incorrectlyOpenedComment),this._createCommentToken(2),this.state=A.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case k.HYPHEN_MINUS:{this.state=A.COMMENT_START_DASH;break}case k.GREATER_THAN_SIGN:{this._err(j.abruptClosingOfEmptyComment),this.state=A.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=A.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case k.HYPHEN_MINUS:{this.state=A.COMMENT_END;break}case k.GREATER_THAN_SIGN:{this._err(j.abruptClosingOfEmptyComment),this.state=A.DATA,this.emitCurrentComment(n);break}case k.EOF:{this._err(j.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=A.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case k.HYPHEN_MINUS:{this.state=A.COMMENT_END_DASH;break}case k.LESS_THAN_SIGN:{n.data+="<",this.state=A.COMMENT_LESS_THAN_SIGN;break}case k.NULL:{this._err(j.unexpectedNullCharacter),n.data+=nt;break}case k.EOF:{this._err(j.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case k.EXCLAMATION_MARK:{n.data+="!",this.state=A.COMMENT_LESS_THAN_SIGN_BANG;break}case k.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=A.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===k.HYPHEN_MINUS?this.state=A.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=A.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===k.HYPHEN_MINUS?this.state=A.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=A.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==k.GREATER_THAN_SIGN&&t!==k.EOF&&this._err(j.nestedComment),this.state=A.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case k.HYPHEN_MINUS:{this.state=A.COMMENT_END;break}case k.EOF:{this._err(j.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=A.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case k.GREATER_THAN_SIGN:{this.state=A.DATA,this.emitCurrentComment(n);break}case k.EXCLAMATION_MARK:{this.state=A.COMMENT_END_BANG;break}case k.HYPHEN_MINUS:{n.data+="-";break}case k.EOF:{this._err(j.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=A.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case k.HYPHEN_MINUS:{n.data+="--!",this.state=A.COMMENT_END_DASH;break}case k.GREATER_THAN_SIGN:{this._err(j.incorrectlyClosedComment),this.state=A.DATA,this.emitCurrentComment(n);break}case k.EOF:{this._err(j.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=A.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:{this.state=A.BEFORE_DOCTYPE_NAME;break}case k.GREATER_THAN_SIGN:{this.state=A.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case k.EOF:{this._err(j.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(j.missingWhitespaceBeforeDoctypeName),this.state=A.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(Pu(t))this._createDoctypeToken(String.fromCharCode(tp(t))),this.state=A.DOCTYPE_NAME;else switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:break;case k.NULL:{this._err(j.unexpectedNullCharacter),this._createDoctypeToken(nt),this.state=A.DOCTYPE_NAME;break}case k.GREATER_THAN_SIGN:{this._err(j.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=A.DATA;break}case k.EOF:{this._err(j.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=A.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:{this.state=A.AFTER_DOCTYPE_NAME;break}case k.GREATER_THAN_SIGN:{this.state=A.DATA,this.emitCurrentDoctype(n);break}case k.NULL:{this._err(j.unexpectedNullCharacter),n.name+=nt;break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(Pu(t)?tp(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:break;case k.GREATER_THAN_SIGN:{this.state=A.DATA,this.emitCurrentDoctype(n);break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(gn.PUBLIC,!1)?this.state=A.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(gn.SYSTEM,!1)?this.state=A.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(j.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=A.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:{this.state=A.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case k.QUOTATION_MARK:{this._err(j.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=A.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case k.APOSTROPHE:{this._err(j.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=A.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case k.GREATER_THAN_SIGN:{this._err(j.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=A.DATA,this.emitCurrentDoctype(n);break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(j.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=A.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:break;case k.QUOTATION_MARK:{n.publicId="",this.state=A.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case k.APOSTROPHE:{n.publicId="",this.state=A.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case k.GREATER_THAN_SIGN:{this._err(j.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=A.DATA,this.emitCurrentDoctype(n);break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(j.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=A.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case k.QUOTATION_MARK:{this.state=A.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case k.NULL:{this._err(j.unexpectedNullCharacter),n.publicId+=nt;break}case k.GREATER_THAN_SIGN:{this._err(j.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=A.DATA;break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateDoctypePublicIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case k.APOSTROPHE:{this.state=A.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case k.NULL:{this._err(j.unexpectedNullCharacter),n.publicId+=nt;break}case k.GREATER_THAN_SIGN:{this._err(j.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=A.DATA;break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateAfterDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:{this.state=A.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case k.GREATER_THAN_SIGN:{this.state=A.DATA,this.emitCurrentDoctype(n);break}case k.QUOTATION_MARK:{this._err(j.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=A.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case k.APOSTROPHE:{this._err(j.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=A.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(j.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=A.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:break;case k.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=A.DATA;break}case k.QUOTATION_MARK:{n.systemId="",this.state=A.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case k.APOSTROPHE:{n.systemId="",this.state=A.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(j.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=A.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:{this.state=A.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case k.QUOTATION_MARK:{this._err(j.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=A.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case k.APOSTROPHE:{this._err(j.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=A.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case k.GREATER_THAN_SIGN:{this._err(j.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=A.DATA,this.emitCurrentDoctype(n);break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(j.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=A.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:break;case k.QUOTATION_MARK:{n.systemId="",this.state=A.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case k.APOSTROPHE:{n.systemId="",this.state=A.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case k.GREATER_THAN_SIGN:{this._err(j.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=A.DATA,this.emitCurrentDoctype(n);break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(j.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=A.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case k.QUOTATION_MARK:{this.state=A.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case k.NULL:{this._err(j.unexpectedNullCharacter),n.systemId+=nt;break}case k.GREATER_THAN_SIGN:{this._err(j.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=A.DATA;break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateDoctypeSystemIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case k.APOSTROPHE:{this.state=A.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case k.NULL:{this._err(j.unexpectedNullCharacter),n.systemId+=nt;break}case k.GREATER_THAN_SIGN:{this._err(j.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=A.DATA;break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateAfterDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case k.SPACE:case k.LINE_FEED:case k.TABULATION:case k.FORM_FEED:break;case k.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=A.DATA;break}case k.EOF:{this._err(j.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(j.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=A.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case k.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=A.DATA;break}case k.NULL:{this._err(j.unexpectedNullCharacter);break}case k.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case k.RIGHT_SQUARE_BRACKET:{this.state=A.CDATA_SECTION_BRACKET;break}case k.EOF:{this._err(j.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===k.RIGHT_SQUARE_BRACKET?this.state=A.CDATA_SECTION_END:(this._emitChars("]"),this.state=A.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case k.GREATER_THAN_SIGN:{this.state=A.DATA;break}case k.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=A.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(k.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&JC(this.preprocessor.peek(1))?A.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){JC(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===k.SEMICOLON&&this._err(j.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const nA=new Set([h.DD,h.DT,h.LI,h.OPTGROUP,h.OPTION,h.P,h.RB,h.RP,h.RT,h.RTC]),rA=new Set([...nA,h.CAPTION,h.COLGROUP,h.TBODY,h.TD,h.TFOOT,h.TH,h.THEAD,h.TR]),np=new Set([h.APPLET,h.CAPTION,h.HTML,h.MARQUEE,h.OBJECT,h.TABLE,h.TD,h.TEMPLATE,h.TH]),yY=new Set([...np,h.OL,h.UL]),vY=new Set([...np,h.BUTTON]),iA=new Set([h.ANNOTATION_XML,h.MI,h.MN,h.MO,h.MS,h.MTEXT]),aA=new Set([h.DESC,h.FOREIGN_OBJECT,h.TITLE]),bY=new Set([h.TR,h.TEMPLATE,h.HTML]),xY=new Set([h.TBODY,h.TFOOT,h.THEAD,h.TEMPLATE,h.HTML]),EY=new Set([h.TABLE,h.TEMPLATE,h.HTML]),TY=new Set([h.TD,h.TH]);class _Y{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=h.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===h.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===V.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const i=this._indexOf(t)+1;this.items.splice(i,0,n),this.tagIDs.splice(i,0,r),this.stackTop++,i===this.stackTop&&this._updateCurrentElement(),this.handler.onItemPush(this.current,this.currentTagId,i===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==V.HTML);this.shortenToLength(n<0?0:n)}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop<t)}}popUntilElementPopped(t){const n=this._indexOf(t);this.shortenToLength(n<0?0:n)}popUntilPopped(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r<0?0:r)}popUntilNumberedHeaderPopped(){this.popUntilPopped(sy,V.HTML)}popUntilTableCellPopped(){this.popUntilPopped(TY,V.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(t,n){for(let r=this.stackTop;r>=0;r--)if(t.has(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(EY,V.HTML)}clearBackToTableBodyContext(){this.clearBackTo(xY,V.HTML)}clearBackToTableRowContext(){this.clearBackTo(bY,V.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===h.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===h.HTML}hasInDynamicScope(t,n){for(let r=this.stackTop;r>=0;r--){const i=this.tagIDs[r];switch(this.treeAdapter.getNamespaceURI(this.items[r])){case V.HTML:{if(i===t)return!0;if(n.has(i))return!1;break}case V.SVG:{if(aA.has(i))return!1;break}case V.MATHML:{if(iA.has(i))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,np)}hasInListItemScope(t){return this.hasInDynamicScope(t,yY)}hasInButtonScope(t){return this.hasInDynamicScope(t,vY)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case V.HTML:{if(sy.has(n))return!0;if(np.has(n))return!1;break}case V.SVG:{if(aA.has(n))return!1;break}case V.MATHML:{if(iA.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===V.HTML)switch(this.tagIDs[n]){case t:return!0;case h.TABLE:case h.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===V.HTML)switch(this.tagIDs[t]){case h.TBODY:case h.THEAD:case h.TFOOT:return!0;case h.TABLE:case h.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===V.HTML)switch(this.tagIDs[n]){case t:return!0;case h.OPTION:case h.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;nA.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;rA.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==t&&rA.has(this.currentTagId);)this.pop()}}const ly=3;var Br;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(Br||(Br={}));const oA={type:Br.Marker};class SY{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],i=n.length,a=this.treeAdapter.getTagName(t),o=this.treeAdapter.getNamespaceURI(t);for(let s=0;s<this.entries.length;s++){const l=this.entries[s];if(l.type===Br.Marker)break;const{element:u}=l;if(this.treeAdapter.getTagName(u)===a&&this.treeAdapter.getNamespaceURI(u)===o){const c=this.treeAdapter.getAttrList(u);c.length===i&&r.push({idx:s,attrs:c})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<ly)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<ly)return;const i=new Map(n.map(o=>[o.name,o.value]));let a=0;for(let o=0;o<r.length;o++){const s=r[o];s.attrs.every(l=>i.get(l.name)===l.value)&&(a+=1,a>=ly&&this.entries.splice(s.idx,1))}}insertMarker(){this.entries.unshift(oA)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:Br.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:Br.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n>=0&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(oA);t>=0?this.entries.splice(0,t+1):this.entries.length=0}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===Br.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===Br.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===Br.Element&&n.element===t)}}const fa={createDocument(){return{nodeName:"#document",mode:Gn.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},createTextNode(e){return{nodeName:"#text",value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const i=e.childNodes.find(a=>a.nodeName==="#documentType");if(i)i.name=t,i.publicId=n,i.systemId=r;else{const a={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};fa.appendChild(e,a)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(fa.isTextNode(n)){n.value+=t;return}}fa.appendChild(e,fa.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&fa.isTextNode(r)?r.value+=t:fa.insertBefore(e,fa.createTextNode(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName==="#text"},isCommentNode(e){return e.nodeName==="#comment"},isDocumentTypeNode(e){return e.nodeName==="#documentType"},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,"tagName")},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation={...e.sourceCodeLocation,...t}}},sA="html",kY="about:legacy-compat",CY="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",lA=["+//silmaril//dtd html pro v0r11 19970101//","-//as//dtd html 3.0 aswedit + extensions//","-//advasoft ltd//dtd html 3.0 aswedit + extensions//","-//ietf//dtd html 2.0 level 1//","-//ietf//dtd html 2.0 level 2//","-//ietf//dtd html 2.0 strict level 1//","-//ietf//dtd html 2.0 strict level 2//","-//ietf//dtd html 2.0 strict//","-//ietf//dtd html 2.0//","-//ietf//dtd html 2.1e//","-//ietf//dtd html 3.0//","-//ietf//dtd html 3.2 final//","-//ietf//dtd html 3.2//","-//ietf//dtd html 3//","-//ietf//dtd html level 0//","-//ietf//dtd html level 1//","-//ietf//dtd html level 2//","-//ietf//dtd html level 3//","-//ietf//dtd html strict level 0//","-//ietf//dtd html strict level 1//","-//ietf//dtd html strict level 2//","-//ietf//dtd html strict level 3//","-//ietf//dtd html strict//","-//ietf//dtd html//","-//metrius//dtd metrius presentational//","-//microsoft//dtd internet explorer 2.0 html strict//","-//microsoft//dtd internet explorer 2.0 html//","-//microsoft//dtd internet explorer 2.0 tables//","-//microsoft//dtd internet explorer 3.0 html strict//","-//microsoft//dtd internet explorer 3.0 html//","-//microsoft//dtd internet explorer 3.0 tables//","-//netscape comm. corp.//dtd html//","-//netscape comm. corp.//dtd strict html//","-//o'reilly and associates//dtd html 2.0//","-//o'reilly and associates//dtd html extended 1.0//","-//o'reilly and associates//dtd html extended relaxed 1.0//","-//sq//dtd html 2.0 hotmetal + extensions//","-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//","-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//","-//spyglass//dtd html 2.0 extended//","-//sun microsystems corp.//dtd hotjava html//","-//sun microsystems corp.//dtd hotjava strict html//","-//w3c//dtd html 3 1995-03-24//","-//w3c//dtd html 3.2 draft//","-//w3c//dtd html 3.2 final//","-//w3c//dtd html 3.2//","-//w3c//dtd html 3.2s draft//","-//w3c//dtd html 4.0 frameset//","-//w3c//dtd html 4.0 transitional//","-//w3c//dtd html experimental 19960712//","-//w3c//dtd html experimental 970421//","-//w3c//dtd w3 html//","-//w3o//dtd w3 html 3.0//","-//webtechs//dtd mozilla html 2.0//","-//webtechs//dtd mozilla html//"],AY=[...lA,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],RY=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),uA=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],NY=[...uA,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function cA(e,t){return t.some(n=>e.startsWith(n))}function OY(e){return e.name===sA&&e.publicId===null&&(e.systemId===null||e.systemId===kY)}function PY(e){if(e.name!==sA)return Gn.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===CY)return Gn.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),RY.has(n))return Gn.QUIRKS;let r=t===null?AY:lA;if(cA(n,r))return Gn.QUIRKS;if(r=t===null?uA:NY,cA(n,r))return Gn.LIMITED_QUIRKS}return Gn.NO_QUIRKS}const dA={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},IY="definitionurl",DY="definitionURL",LY=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),MY=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:V.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:V.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:V.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:V.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:V.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:V.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:V.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:V.XML}],["xml:space",{prefix:"xml",name:"space",namespace:V.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:V.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:V.XMLNS}]]),FY=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),BY=new Set([h.B,h.BIG,h.BLOCKQUOTE,h.BODY,h.BR,h.CENTER,h.CODE,h.DD,h.DIV,h.DL,h.DT,h.EM,h.EMBED,h.H1,h.H2,h.H3,h.H4,h.H5,h.H6,h.HEAD,h.HR,h.I,h.IMG,h.LI,h.LISTING,h.MENU,h.META,h.NOBR,h.OL,h.P,h.PRE,h.RUBY,h.S,h.SMALL,h.SPAN,h.STRONG,h.STRIKE,h.SUB,h.SUP,h.TABLE,h.TT,h.U,h.UL,h.VAR]);function jY(e){const t=e.tagID;return t===h.FONT&&e.attrs.some(({name:r})=>r===to.COLOR||r===to.SIZE||r===to.FACE)||BY.has(t)}function fA(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===IY){e.attrs[t].name=DY;break}}function pA(e){for(let t=0;t<e.attrs.length;t++){const n=LY.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function uy(e){for(let t=0;t<e.attrs.length;t++){const n=MY.get(e.attrs[t].name);n&&(e.attrs[t].prefix=n.prefix,e.attrs[t].name=n.name,e.attrs[t].namespace=n.namespace)}}function zY(e){const t=FY.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=bs(e.tagName))}function UY(e,t){return t===V.MATHML&&(e===h.MI||e===h.MO||e===h.MN||e===h.MS||e===h.MTEXT)}function HY(e,t,n){if(t===V.MATHML&&e===h.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===to.ENCODING){const i=n[r].value.toLowerCase();return i===dA.TEXT_HTML||i===dA.APPLICATION_XML}}return t===V.SVG&&(e===h.FOREIGN_OBJECT||e===h.DESC||e===h.TITLE)}function VY(e,t,n,r){return(!r||r===V.HTML)&&HY(e,t,n)||(!r||r===V.MATHML)&&UY(e,t)}const $Y="hidden",WY=8,YY=3;var O;(function(e){e[e.INITIAL=0]="INITIAL",e[e.BEFORE_HTML=1]="BEFORE_HTML",e[e.BEFORE_HEAD=2]="BEFORE_HEAD",e[e.IN_HEAD=3]="IN_HEAD",e[e.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",e[e.AFTER_HEAD=5]="AFTER_HEAD",e[e.IN_BODY=6]="IN_BODY",e[e.TEXT=7]="TEXT",e[e.IN_TABLE=8]="IN_TABLE",e[e.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",e[e.IN_CAPTION=10]="IN_CAPTION",e[e.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",e[e.IN_TABLE_BODY=12]="IN_TABLE_BODY",e[e.IN_ROW=13]="IN_ROW",e[e.IN_CELL=14]="IN_CELL",e[e.IN_SELECT=15]="IN_SELECT",e[e.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",e[e.IN_TEMPLATE=17]="IN_TEMPLATE",e[e.AFTER_BODY=18]="AFTER_BODY",e[e.IN_FRAMESET=19]="IN_FRAMESET",e[e.AFTER_FRAMESET=20]="AFTER_FRAMESET",e[e.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",e[e.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(O||(O={}));const qY={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},hA=new Set([h.TABLE,h.TBODY,h.TFOOT,h.THEAD,h.TR]),mA={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:fa,onParseError:null};class gA{constructor(t,n,r=null,i=null){this.fragmentContext=r,this.scriptHandler=i,this.currentToken=null,this.stopped=!1,this.insertionMode=O.INITIAL,this.originalInsertionMode=O.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={...mA,...t},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=n??this.treeAdapter.createDocument(),this.tokenizer=new wY(this.options,this),this.activeFormattingElements=new SY(this.treeAdapter),this.fragmentContextID=r?bs(this.treeAdapter.getTagName(r)):h.UNKNOWN,this._setContextModes(r??this.document,this.fragmentContextID),this.openElements=new _Y(this.document,this.treeAdapter,this)}static parse(t,n){const r=new this(n);return r.tokenizer.write(t,!0),r.document}static getFragmentParser(t,n){const r={...mA,...n};t??(t=r.treeAdapter.createElement(D.TEMPLATE,V.HTML,[]));const i=r.treeAdapter.createElement("documentmock",V.HTML,[]),a=new this(r,i,t);return a.fragmentContextID===h.TEMPLATE&&a.tmplInsertionModeStack.unshift(O.IN_TEMPLATE),a._initTokenizerForFragmentParsing(),a._insertFakeRootElement(),a._resetInsertionMode(),a._findFormInFragmentContext(),a}getFragment(){const t=this.treeAdapter.getFirstChild(this.document),n=this.treeAdapter.createDocumentFragment();return this._adoptNodes(t,n),n}_err(t,n,r){var i;if(!this.onParseError)return;const a=(i=t.location)!==null&&i!==void 0?i:qY,o={code:n,startLine:a.startLine,startCol:a.startCol,startOffset:a.startOffset,endLine:r?a.startLine:a.endLine,endCol:r?a.startCol:a.endCol,endOffset:r?a.startOffset:a.endOffset};this.onParseError(o)}onItemPush(t,n,r){var i,a;(a=(i=this.treeAdapter).onItemPush)===null||a===void 0||a.call(i,t),r&&this.openElements.stackTop>0&&this._setContextModes(t,n)}onItemPop(t,n){var r,i;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(i=(r=this.treeAdapter).onItemPop)===null||i===void 0||i.call(r,t,this.openElements.current),n){let a,o;this.openElements.stackTop===0&&this.fragmentContext?(a=this.fragmentContext,o=this.fragmentContextID):{current:a,currentTagId:o}=this.openElements,this._setContextModes(a,o)}}_setContextModes(t,n){const r=t===this.document||this.treeAdapter.getNamespaceURI(t)===V.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,V.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=O.TEXT}switchToPlaintextParsing(){this.insertionMode=O.TEXT,this.originalInsertionMode=O.IN_BODY,this.tokenizer.state=pt.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===D.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==V.HTML))switch(this.fragmentContextID){case h.TITLE:case h.TEXTAREA:{this.tokenizer.state=pt.RCDATA;break}case h.STYLE:case h.XMP:case h.IFRAME:case h.NOEMBED:case h.NOFRAMES:case h.NOSCRIPT:{this.tokenizer.state=pt.RAWTEXT;break}case h.SCRIPT:{this.tokenizer.state=pt.SCRIPT_DATA;break}case h.PLAINTEXT:{this.tokenizer.state=pt.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",i=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,i),t.location){const o=this.treeAdapter.getChildNodes(this.document).find(s=>this.treeAdapter.isDocumentTypeNode(s));o&&this.treeAdapter.setNodeSourceCodeLocation(o,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&{...n,startTag:n};this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,V.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,V.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(D.HTML,V.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,h.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const i=this.treeAdapter.getChildNodes(n),a=r?i.lastIndexOf(r):i.length,o=i[a-1];if(this.treeAdapter.getNodeSourceCodeLocation(o)){const{endLine:l,endCol:u,endOffset:c}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(o,{endLine:l,endCol:u,endOffset:c})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(o,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,i=this.treeAdapter.getTagName(t),a=n.type===Ae.END_TAG&&i===n.tagName?{endTag:{...r},endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,a)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===h.SVG&&this.treeAdapter.getTagName(n)===D.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===V.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===h.MGLYPH||t.tagID===h.MALIGNMARK)&&!this._isIntegrationPoint(r,n,V.HTML)}_processToken(t){switch(t.type){case Ae.CHARACTER:{this.onCharacter(t);break}case Ae.NULL_CHARACTER:{this.onNullCharacter(t);break}case Ae.COMMENT:{this.onComment(t);break}case Ae.DOCTYPE:{this.onDoctype(t);break}case Ae.START_TAG:{this._processStartTag(t);break}case Ae.END_TAG:{this.onEndTag(t);break}case Ae.EOF:{this.onEof(t);break}case Ae.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const i=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return VY(t,i,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(i=>i.type===Br.Marker||this.openElements.contains(i.element)),r=n<0?t-1:n-1;for(let i=r;i>=0;i--){const a=this.activeFormattingElements.entries[i];this._insertElement(a.token,this.treeAdapter.getNamespaceURI(a.element)),a.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=O.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(h.P),this.openElements.popUntilTagNamePopped(h.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case h.TR:{this.insertionMode=O.IN_ROW;return}case h.TBODY:case h.THEAD:case h.TFOOT:{this.insertionMode=O.IN_TABLE_BODY;return}case h.CAPTION:{this.insertionMode=O.IN_CAPTION;return}case h.COLGROUP:{this.insertionMode=O.IN_COLUMN_GROUP;return}case h.TABLE:{this.insertionMode=O.IN_TABLE;return}case h.BODY:{this.insertionMode=O.IN_BODY;return}case h.FRAMESET:{this.insertionMode=O.IN_FRAMESET;return}case h.SELECT:{this._resetInsertionModeForSelect(t);return}case h.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case h.HTML:{this.insertionMode=this.headElement?O.AFTER_HEAD:O.BEFORE_HEAD;return}case h.TD:case h.TH:{if(t>0){this.insertionMode=O.IN_CELL;return}break}case h.HEAD:{if(t>0){this.insertionMode=O.IN_HEAD;return}break}}this.insertionMode=O.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===h.TEMPLATE)break;if(r===h.TABLE){this.insertionMode=O.IN_SELECT_IN_TABLE;return}}this.insertionMode=O.IN_SELECT}_isElementCausesFosterParenting(t){return hA.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case h.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===V.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case h.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return pY[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){TG(this,t);return}switch(this.insertionMode){case O.INITIAL:{Iu(this,t);break}case O.BEFORE_HTML:{Du(this,t);break}case O.BEFORE_HEAD:{Lu(this,t);break}case O.IN_HEAD:{Mu(this,t);break}case O.IN_HEAD_NO_SCRIPT:{Fu(this,t);break}case O.AFTER_HEAD:{Bu(this,t);break}case O.IN_BODY:case O.IN_CAPTION:case O.IN_CELL:case O.IN_TEMPLATE:{yA(this,t);break}case O.TEXT:case O.IN_SELECT:case O.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case O.IN_TABLE:case O.IN_TABLE_BODY:case O.IN_ROW:{py(this,t);break}case O.IN_TABLE_TEXT:{kA(this,t);break}case O.IN_COLUMN_GROUP:{ap(this,t);break}case O.AFTER_BODY:{lp(this,t);break}case O.AFTER_AFTER_BODY:{up(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){EG(this,t);return}switch(this.insertionMode){case O.INITIAL:{Iu(this,t);break}case O.BEFORE_HTML:{Du(this,t);break}case O.BEFORE_HEAD:{Lu(this,t);break}case O.IN_HEAD:{Mu(this,t);break}case O.IN_HEAD_NO_SCRIPT:{Fu(this,t);break}case O.AFTER_HEAD:{Bu(this,t);break}case O.TEXT:{this._insertCharacters(t);break}case O.IN_TABLE:case O.IN_TABLE_BODY:case O.IN_ROW:{py(this,t);break}case O.IN_COLUMN_GROUP:{ap(this,t);break}case O.AFTER_BODY:{lp(this,t);break}case O.AFTER_AFTER_BODY:{up(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){dy(this,t);return}switch(this.insertionMode){case O.INITIAL:case O.BEFORE_HTML:case O.BEFORE_HEAD:case O.IN_HEAD:case O.IN_HEAD_NO_SCRIPT:case O.AFTER_HEAD:case O.IN_BODY:case O.IN_TABLE:case O.IN_CAPTION:case O.IN_COLUMN_GROUP:case O.IN_TABLE_BODY:case O.IN_ROW:case O.IN_CELL:case O.IN_SELECT:case O.IN_SELECT_IN_TABLE:case O.IN_TEMPLATE:case O.IN_FRAMESET:case O.AFTER_FRAMESET:{dy(this,t);break}case O.IN_TABLE_TEXT:{Uu(this,t);break}case O.AFTER_BODY:{eq(this,t);break}case O.AFTER_AFTER_BODY:case O.AFTER_AFTER_FRAMESET:{tq(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case O.INITIAL:{nq(this,t);break}case O.BEFORE_HEAD:case O.IN_HEAD:case O.IN_HEAD_NO_SCRIPT:case O.AFTER_HEAD:{this._err(t,j.misplacedDoctype);break}case O.IN_TABLE_TEXT:{Uu(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,j.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?_G(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case O.INITIAL:{Iu(this,t);break}case O.BEFORE_HTML:{rq(this,t);break}case O.BEFORE_HEAD:{aq(this,t);break}case O.IN_HEAD:{gr(this,t);break}case O.IN_HEAD_NO_SCRIPT:{lq(this,t);break}case O.AFTER_HEAD:{cq(this,t);break}case O.IN_BODY:{Yt(this,t);break}case O.IN_TABLE:{xs(this,t);break}case O.IN_TABLE_TEXT:{Uu(this,t);break}case O.IN_CAPTION:{oG(this,t);break}case O.IN_COLUMN_GROUP:{hy(this,t);break}case O.IN_TABLE_BODY:{op(this,t);break}case O.IN_ROW:{sp(this,t);break}case O.IN_CELL:{uG(this,t);break}case O.IN_SELECT:{RA(this,t);break}case O.IN_SELECT_IN_TABLE:{dG(this,t);break}case O.IN_TEMPLATE:{pG(this,t);break}case O.AFTER_BODY:{mG(this,t);break}case O.IN_FRAMESET:{gG(this,t);break}case O.AFTER_FRAMESET:{yG(this,t);break}case O.AFTER_AFTER_BODY:{bG(this,t);break}case O.AFTER_AFTER_FRAMESET:{xG(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?SG(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case O.INITIAL:{Iu(this,t);break}case O.BEFORE_HTML:{iq(this,t);break}case O.BEFORE_HEAD:{oq(this,t);break}case O.IN_HEAD:{sq(this,t);break}case O.IN_HEAD_NO_SCRIPT:{uq(this,t);break}case O.AFTER_HEAD:{dq(this,t);break}case O.IN_BODY:{ip(this,t);break}case O.TEXT:{Xq(this,t);break}case O.IN_TABLE:{ju(this,t);break}case O.IN_TABLE_TEXT:{Uu(this,t);break}case O.IN_CAPTION:{sG(this,t);break}case O.IN_COLUMN_GROUP:{lG(this,t);break}case O.IN_TABLE_BODY:{my(this,t);break}case O.IN_ROW:{AA(this,t);break}case O.IN_CELL:{cG(this,t);break}case O.IN_SELECT:{NA(this,t);break}case O.IN_SELECT_IN_TABLE:{fG(this,t);break}case O.IN_TEMPLATE:{hG(this,t);break}case O.AFTER_BODY:{PA(this,t);break}case O.IN_FRAMESET:{wG(this,t);break}case O.AFTER_FRAMESET:{vG(this,t);break}case O.AFTER_AFTER_BODY:{up(this,t);break}}}onEof(t){switch(this.insertionMode){case O.INITIAL:{Iu(this,t);break}case O.BEFORE_HTML:{Du(this,t);break}case O.BEFORE_HEAD:{Lu(this,t);break}case O.IN_HEAD:{Mu(this,t);break}case O.IN_HEAD_NO_SCRIPT:{Fu(this,t);break}case O.AFTER_HEAD:{Bu(this,t);break}case O.IN_BODY:case O.IN_TABLE:case O.IN_CAPTION:case O.IN_COLUMN_GROUP:case O.IN_TABLE_BODY:case O.IN_ROW:case O.IN_CELL:case O.IN_SELECT:case O.IN_SELECT_IN_TABLE:{_A(this,t);break}case O.TEXT:{Qq(this,t);break}case O.IN_TABLE_TEXT:{Uu(this,t);break}case O.IN_TEMPLATE:{OA(this,t);break}case O.AFTER_BODY:case O.IN_FRAMESET:case O.AFTER_FRAMESET:case O.AFTER_AFTER_BODY:case O.AFTER_AFTER_FRAMESET:{fy(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===k.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case O.IN_HEAD:case O.IN_HEAD_NO_SCRIPT:case O.AFTER_HEAD:case O.TEXT:case O.IN_COLUMN_GROUP:case O.IN_SELECT:case O.IN_SELECT_IN_TABLE:case O.IN_FRAMESET:case O.AFTER_FRAMESET:{this._insertCharacters(t);break}case O.IN_BODY:case O.IN_CAPTION:case O.IN_CELL:case O.IN_TEMPLATE:case O.AFTER_BODY:case O.AFTER_AFTER_BODY:case O.AFTER_AFTER_FRAMESET:{wA(this,t);break}case O.IN_TABLE:case O.IN_TABLE_BODY:case O.IN_ROW:{py(this,t);break}case O.IN_TABLE_TEXT:{SA(this,t);break}}}}function GY(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagID)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):TA(e,t),n}function KY(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const i=e.openElements.items[r];if(i===t.element)break;e._isSpecialElement(i,e.openElements.tagIDs[r])&&(n=i)}return n||(e.openElements.shortenToLength(r<0?0:r),e.activeFormattingElements.removeEntry(t)),n}function XY(e,t,n){let r=t,i=e.openElements.getCommonAncestor(t);for(let a=0,o=i;o!==n;a++,o=i){i=e.openElements.getCommonAncestor(o);const s=e.activeFormattingElements.getElementEntry(o),l=s&&a>=YY;!s||l?(l&&e.activeFormattingElements.removeEntry(s),e.openElements.remove(o)):(o=QY(e,s),r===t&&(e.activeFormattingElements.bookmark=s),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(o,r),r=o)}return r}function QY(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function ZY(e,t,n){const r=e.treeAdapter.getTagName(t),i=bs(r);if(e._isElementCausesFosterParenting(i))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);i===h.TEMPLATE&&a===V.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function JY(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:i}=n,a=e.treeAdapter.createElement(i.tagName,r,i.attrs);e._adoptNodes(t,a),e.treeAdapter.appendChild(t,a),e.activeFormattingElements.insertElementAfterBookmark(a,i),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,a,i.tagID)}function cy(e,t){for(let n=0;n<WY;n++){const r=GY(e,t);if(!r)break;const i=KY(e,r);if(!i)break;e.activeFormattingElements.bookmark=r;const a=XY(e,i,r.element),o=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),o&&ZY(e,o,a),JY(e,i,r)}}function dy(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function eq(e,t){e._appendCommentNode(t,e.openElements.items[0])}function tq(e,t){e._appendCommentNode(t,e.document)}function fy(e,t){if(e.stopped=!0,t.location){const n=e.fragmentContext?0:2;for(let r=e.openElements.stackTop;r>=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],i=e.treeAdapter.getNodeSourceCodeLocation(r);if(i&&!i.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const a=e.openElements.items[1],o=e.treeAdapter.getNodeSourceCodeLocation(a);o&&!o.endTag&&e._setEndLocation(a,t)}}}}function nq(e,t){e._setDocumentType(t);const n=t.forceQuirks?Gn.QUIRKS:PY(t);OY(t)||e._err(t,j.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=O.BEFORE_HTML}function Iu(e,t){e._err(t,j.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Gn.QUIRKS),e.insertionMode=O.BEFORE_HTML,e._processToken(t)}function rq(e,t){t.tagID===h.HTML?(e._insertElement(t,V.HTML),e.insertionMode=O.BEFORE_HEAD):Du(e,t)}function iq(e,t){const n=t.tagID;(n===h.HTML||n===h.HEAD||n===h.BODY||n===h.BR)&&Du(e,t)}function Du(e,t){e._insertFakeRootElement(),e.insertionMode=O.BEFORE_HEAD,e._processToken(t)}function aq(e,t){switch(t.tagID){case h.HTML:{Yt(e,t);break}case h.HEAD:{e._insertElement(t,V.HTML),e.headElement=e.openElements.current,e.insertionMode=O.IN_HEAD;break}default:Lu(e,t)}}function oq(e,t){const n=t.tagID;n===h.HEAD||n===h.BODY||n===h.HTML||n===h.BR?Lu(e,t):e._err(t,j.endTagWithoutMatchingOpenElement)}function Lu(e,t){e._insertFakeElement(D.HEAD,h.HEAD),e.headElement=e.openElements.current,e.insertionMode=O.IN_HEAD,e._processToken(t)}function gr(e,t){switch(t.tagID){case h.HTML:{Yt(e,t);break}case h.BASE:case h.BASEFONT:case h.BGSOUND:case h.LINK:case h.META:{e._appendElement(t,V.HTML),t.ackSelfClosing=!0;break}case h.TITLE:{e._switchToTextParsing(t,pt.RCDATA);break}case h.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,pt.RAWTEXT):(e._insertElement(t,V.HTML),e.insertionMode=O.IN_HEAD_NO_SCRIPT);break}case h.NOFRAMES:case h.STYLE:{e._switchToTextParsing(t,pt.RAWTEXT);break}case h.SCRIPT:{e._switchToTextParsing(t,pt.SCRIPT_DATA);break}case h.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=O.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(O.IN_TEMPLATE);break}case h.HEAD:{e._err(t,j.misplacedStartTagForHeadElement);break}default:Mu(e,t)}}function sq(e,t){switch(t.tagID){case h.HEAD:{e.openElements.pop(),e.insertionMode=O.AFTER_HEAD;break}case h.BODY:case h.BR:case h.HTML:{Mu(e,t);break}case h.TEMPLATE:{no(e,t);break}default:e._err(t,j.endTagWithoutMatchingOpenElement)}}function no(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==h.TEMPLATE&&e._err(t,j.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(h.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,j.endTagWithoutMatchingOpenElement)}function Mu(e,t){e.openElements.pop(),e.insertionMode=O.AFTER_HEAD,e._processToken(t)}function lq(e,t){switch(t.tagID){case h.HTML:{Yt(e,t);break}case h.BASEFONT:case h.BGSOUND:case h.HEAD:case h.LINK:case h.META:case h.NOFRAMES:case h.STYLE:{gr(e,t);break}case h.NOSCRIPT:{e._err(t,j.nestedNoscriptInHead);break}default:Fu(e,t)}}function uq(e,t){switch(t.tagID){case h.NOSCRIPT:{e.openElements.pop(),e.insertionMode=O.IN_HEAD;break}case h.BR:{Fu(e,t);break}default:e._err(t,j.endTagWithoutMatchingOpenElement)}}function Fu(e,t){const n=t.type===Ae.EOF?j.openElementsLeftAfterEof:j.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=O.IN_HEAD,e._processToken(t)}function cq(e,t){switch(t.tagID){case h.HTML:{Yt(e,t);break}case h.BODY:{e._insertElement(t,V.HTML),e.framesetOk=!1,e.insertionMode=O.IN_BODY;break}case h.FRAMESET:{e._insertElement(t,V.HTML),e.insertionMode=O.IN_FRAMESET;break}case h.BASE:case h.BASEFONT:case h.BGSOUND:case h.LINK:case h.META:case h.NOFRAMES:case h.SCRIPT:case h.STYLE:case h.TEMPLATE:case h.TITLE:{e._err(t,j.abandonedHeadElementChild),e.openElements.push(e.headElement,h.HEAD),gr(e,t),e.openElements.remove(e.headElement);break}case h.HEAD:{e._err(t,j.misplacedStartTagForHeadElement);break}default:Bu(e,t)}}function dq(e,t){switch(t.tagID){case h.BODY:case h.HTML:case h.BR:{Bu(e,t);break}case h.TEMPLATE:{no(e,t);break}default:e._err(t,j.endTagWithoutMatchingOpenElement)}}function Bu(e,t){e._insertFakeElement(D.BODY,h.BODY),e.insertionMode=O.IN_BODY,rp(e,t)}function rp(e,t){switch(t.type){case Ae.CHARACTER:{yA(e,t);break}case Ae.WHITESPACE_CHARACTER:{wA(e,t);break}case Ae.COMMENT:{dy(e,t);break}case Ae.START_TAG:{Yt(e,t);break}case Ae.END_TAG:{ip(e,t);break}case Ae.EOF:{_A(e,t);break}}}function wA(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function yA(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function fq(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function pq(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function hq(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,V.HTML),e.insertionMode=O.IN_FRAMESET)}function mq(e,t){e.openElements.hasInButtonScope(h.P)&&e._closePElement(),e._insertElement(t,V.HTML)}function gq(e,t){e.openElements.hasInButtonScope(h.P)&&e._closePElement(),sy.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,V.HTML)}function wq(e,t){e.openElements.hasInButtonScope(h.P)&&e._closePElement(),e._insertElement(t,V.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function yq(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(h.P)&&e._closePElement(),e._insertElement(t,V.HTML),n||(e.formElement=e.openElements.current))}function vq(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const i=e.openElements.tagIDs[r];if(n===h.LI&&i===h.LI||(n===h.DD||n===h.DT)&&(i===h.DD||i===h.DT)){e.openElements.generateImpliedEndTagsWithExclusion(i),e.openElements.popUntilTagNamePopped(i);break}if(i!==h.ADDRESS&&i!==h.DIV&&i!==h.P&&e._isSpecialElement(e.openElements.items[r],i))break}e.openElements.hasInButtonScope(h.P)&&e._closePElement(),e._insertElement(t,V.HTML)}function bq(e,t){e.openElements.hasInButtonScope(h.P)&&e._closePElement(),e._insertElement(t,V.HTML),e.tokenizer.state=pt.PLAINTEXT}function xq(e,t){e.openElements.hasInScope(h.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(h.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,V.HTML),e.framesetOk=!1}function Eq(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(D.A);n&&(cy(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,V.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Tq(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,V.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function _q(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(h.NOBR)&&(cy(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,V.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Sq(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,V.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function kq(e,t){e.treeAdapter.getDocumentMode(e.document)!==Gn.QUIRKS&&e.openElements.hasInButtonScope(h.P)&&e._closePElement(),e._insertElement(t,V.HTML),e.framesetOk=!1,e.insertionMode=O.IN_TABLE}function vA(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,V.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function bA(e){const t=KC(e,to.TYPE);return t!=null&&t.toLowerCase()===$Y}function Cq(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,V.HTML),bA(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function Aq(e,t){e._appendElement(t,V.HTML),t.ackSelfClosing=!0}function Rq(e,t){e.openElements.hasInButtonScope(h.P)&&e._closePElement(),e._appendElement(t,V.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Nq(e,t){t.tagName=D.IMG,t.tagID=h.IMG,vA(e,t)}function Oq(e,t){e._insertElement(t,V.HTML),e.skipNextNewLine=!0,e.tokenizer.state=pt.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=O.TEXT}function Pq(e,t){e.openElements.hasInButtonScope(h.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,pt.RAWTEXT)}function Iq(e,t){e.framesetOk=!1,e._switchToTextParsing(t,pt.RAWTEXT)}function xA(e,t){e._switchToTextParsing(t,pt.RAWTEXT)}function Dq(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,V.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===O.IN_TABLE||e.insertionMode===O.IN_CAPTION||e.insertionMode===O.IN_TABLE_BODY||e.insertionMode===O.IN_ROW||e.insertionMode===O.IN_CELL?O.IN_SELECT_IN_TABLE:O.IN_SELECT}function Lq(e,t){e.openElements.currentTagId===h.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,V.HTML)}function Mq(e,t){e.openElements.hasInScope(h.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,V.HTML)}function Fq(e,t){e.openElements.hasInScope(h.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(h.RTC),e._insertElement(t,V.HTML)}function Bq(e,t){e._reconstructActiveFormattingElements(),fA(t),uy(t),t.selfClosing?e._appendElement(t,V.MATHML):e._insertElement(t,V.MATHML),t.ackSelfClosing=!0}function jq(e,t){e._reconstructActiveFormattingElements(),pA(t),uy(t),t.selfClosing?e._appendElement(t,V.SVG):e._insertElement(t,V.SVG),t.ackSelfClosing=!0}function EA(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,V.HTML)}function Yt(e,t){switch(t.tagID){case h.I:case h.S:case h.B:case h.U:case h.EM:case h.TT:case h.BIG:case h.CODE:case h.FONT:case h.SMALL:case h.STRIKE:case h.STRONG:{Tq(e,t);break}case h.A:{Eq(e,t);break}case h.H1:case h.H2:case h.H3:case h.H4:case h.H5:case h.H6:{gq(e,t);break}case h.P:case h.DL:case h.OL:case h.UL:case h.DIV:case h.DIR:case h.NAV:case h.MAIN:case h.MENU:case h.ASIDE:case h.CENTER:case h.FIGURE:case h.FOOTER:case h.HEADER:case h.HGROUP:case h.DIALOG:case h.DETAILS:case h.ADDRESS:case h.ARTICLE:case h.SEARCH:case h.SECTION:case h.SUMMARY:case h.FIELDSET:case h.BLOCKQUOTE:case h.FIGCAPTION:{mq(e,t);break}case h.LI:case h.DD:case h.DT:{vq(e,t);break}case h.BR:case h.IMG:case h.WBR:case h.AREA:case h.EMBED:case h.KEYGEN:{vA(e,t);break}case h.HR:{Rq(e,t);break}case h.RB:case h.RTC:{Mq(e,t);break}case h.RT:case h.RP:{Fq(e,t);break}case h.PRE:case h.LISTING:{wq(e,t);break}case h.XMP:{Pq(e,t);break}case h.SVG:{jq(e,t);break}case h.HTML:{fq(e,t);break}case h.BASE:case h.LINK:case h.META:case h.STYLE:case h.TITLE:case h.SCRIPT:case h.BGSOUND:case h.BASEFONT:case h.TEMPLATE:{gr(e,t);break}case h.BODY:{pq(e,t);break}case h.FORM:{yq(e,t);break}case h.NOBR:{_q(e,t);break}case h.MATH:{Bq(e,t);break}case h.TABLE:{kq(e,t);break}case h.INPUT:{Cq(e,t);break}case h.PARAM:case h.TRACK:case h.SOURCE:{Aq(e,t);break}case h.IMAGE:{Nq(e,t);break}case h.BUTTON:{xq(e,t);break}case h.APPLET:case h.OBJECT:case h.MARQUEE:{Sq(e,t);break}case h.IFRAME:{Iq(e,t);break}case h.SELECT:{Dq(e,t);break}case h.OPTION:case h.OPTGROUP:{Lq(e,t);break}case h.NOEMBED:case h.NOFRAMES:{xA(e,t);break}case h.FRAMESET:{hq(e,t);break}case h.TEXTAREA:{Oq(e,t);break}case h.NOSCRIPT:{e.options.scriptingEnabled?xA(e,t):EA(e,t);break}case h.PLAINTEXT:{bq(e,t);break}case h.COL:case h.TH:case h.TD:case h.TR:case h.HEAD:case h.FRAME:case h.TBODY:case h.TFOOT:case h.THEAD:case h.CAPTION:case h.COLGROUP:break;default:EA(e,t)}}function zq(e,t){if(e.openElements.hasInScope(h.BODY)&&(e.insertionMode=O.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function Uq(e,t){e.openElements.hasInScope(h.BODY)&&(e.insertionMode=O.AFTER_BODY,PA(e,t))}function Hq(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function Vq(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(h.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(h.FORM):n&&e.openElements.remove(n))}function $q(e){e.openElements.hasInButtonScope(h.P)||e._insertFakeElement(D.P,h.P),e._closePElement()}function Wq(e){e.openElements.hasInListItemScope(h.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(h.LI),e.openElements.popUntilTagNamePopped(h.LI))}function Yq(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function qq(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function Gq(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function Kq(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(D.BR,h.BR),e.openElements.pop(),e.framesetOk=!1}function TA(e,t){const n=t.tagName,r=t.tagID;for(let i=e.openElements.stackTop;i>0;i--){const a=e.openElements.items[i],o=e.openElements.tagIDs[i];if(r===o&&(r!==h.UNKNOWN||e.treeAdapter.getTagName(a)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=i&&e.openElements.shortenToLength(i);break}if(e._isSpecialElement(a,o))break}}function ip(e,t){switch(t.tagID){case h.A:case h.B:case h.I:case h.S:case h.U:case h.EM:case h.TT:case h.BIG:case h.CODE:case h.FONT:case h.NOBR:case h.SMALL:case h.STRIKE:case h.STRONG:{cy(e,t);break}case h.P:{$q(e);break}case h.DL:case h.UL:case h.OL:case h.DIR:case h.DIV:case h.NAV:case h.PRE:case h.MAIN:case h.MENU:case h.ASIDE:case h.BUTTON:case h.CENTER:case h.FIGURE:case h.FOOTER:case h.HEADER:case h.HGROUP:case h.DIALOG:case h.ADDRESS:case h.ARTICLE:case h.DETAILS:case h.SEARCH:case h.SECTION:case h.SUMMARY:case h.LISTING:case h.FIELDSET:case h.BLOCKQUOTE:case h.FIGCAPTION:{Hq(e,t);break}case h.LI:{Wq(e);break}case h.DD:case h.DT:{Yq(e,t);break}case h.H1:case h.H2:case h.H3:case h.H4:case h.H5:case h.H6:{qq(e);break}case h.BR:{Kq(e);break}case h.BODY:{zq(e,t);break}case h.HTML:{Uq(e,t);break}case h.FORM:{Vq(e);break}case h.APPLET:case h.OBJECT:case h.MARQUEE:{Gq(e,t);break}case h.TEMPLATE:{no(e,t);break}default:TA(e,t)}}function _A(e,t){e.tmplInsertionModeStack.length>0?OA(e,t):fy(e,t)}function Xq(e,t){var n;t.tagID===h.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function Qq(e,t){e._err(t,j.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function py(e,t){if(hA.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=O.IN_TABLE_TEXT,t.type){case Ae.CHARACTER:{kA(e,t);break}case Ae.WHITESPACE_CHARACTER:{SA(e,t);break}}else zu(e,t)}function Zq(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,V.HTML),e.insertionMode=O.IN_CAPTION}function Jq(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,V.HTML),e.insertionMode=O.IN_COLUMN_GROUP}function eG(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(D.COLGROUP,h.COLGROUP),e.insertionMode=O.IN_COLUMN_GROUP,hy(e,t)}function tG(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,V.HTML),e.insertionMode=O.IN_TABLE_BODY}function nG(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(D.TBODY,h.TBODY),e.insertionMode=O.IN_TABLE_BODY,op(e,t)}function rG(e,t){e.openElements.hasInTableScope(h.TABLE)&&(e.openElements.popUntilTagNamePopped(h.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function iG(e,t){bA(t)?e._appendElement(t,V.HTML):zu(e,t),t.ackSelfClosing=!0}function aG(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,V.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function xs(e,t){switch(t.tagID){case h.TD:case h.TH:case h.TR:{nG(e,t);break}case h.STYLE:case h.SCRIPT:case h.TEMPLATE:{gr(e,t);break}case h.COL:{eG(e,t);break}case h.FORM:{aG(e,t);break}case h.TABLE:{rG(e,t);break}case h.TBODY:case h.TFOOT:case h.THEAD:{tG(e,t);break}case h.INPUT:{iG(e,t);break}case h.CAPTION:{Zq(e,t);break}case h.COLGROUP:{Jq(e,t);break}default:zu(e,t)}}function ju(e,t){switch(t.tagID){case h.TABLE:{e.openElements.hasInTableScope(h.TABLE)&&(e.openElements.popUntilTagNamePopped(h.TABLE),e._resetInsertionMode());break}case h.TEMPLATE:{no(e,t);break}case h.BODY:case h.CAPTION:case h.COL:case h.COLGROUP:case h.HTML:case h.TBODY:case h.TD:case h.TFOOT:case h.TH:case h.THEAD:case h.TR:break;default:zu(e,t)}}function zu(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,rp(e,t),e.fosterParentingEnabled=n}function SA(e,t){e.pendingCharacterTokens.push(t)}function kA(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Uu(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)zu(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const CA=new Set([h.CAPTION,h.COL,h.COLGROUP,h.TBODY,h.TD,h.TFOOT,h.TH,h.THEAD,h.TR]);function oG(e,t){const n=t.tagID;CA.has(n)?e.openElements.hasInTableScope(h.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(h.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=O.IN_TABLE,xs(e,t)):Yt(e,t)}function sG(e,t){const n=t.tagID;switch(n){case h.CAPTION:case h.TABLE:{e.openElements.hasInTableScope(h.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(h.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=O.IN_TABLE,n===h.TABLE&&ju(e,t));break}case h.BODY:case h.COL:case h.COLGROUP:case h.HTML:case h.TBODY:case h.TD:case h.TFOOT:case h.TH:case h.THEAD:case h.TR:break;default:ip(e,t)}}function hy(e,t){switch(t.tagID){case h.HTML:{Yt(e,t);break}case h.COL:{e._appendElement(t,V.HTML),t.ackSelfClosing=!0;break}case h.TEMPLATE:{gr(e,t);break}default:ap(e,t)}}function lG(e,t){switch(t.tagID){case h.COLGROUP:{e.openElements.currentTagId===h.COLGROUP&&(e.openElements.pop(),e.insertionMode=O.IN_TABLE);break}case h.TEMPLATE:{no(e,t);break}case h.COL:break;default:ap(e,t)}}function ap(e,t){e.openElements.currentTagId===h.COLGROUP&&(e.openElements.pop(),e.insertionMode=O.IN_TABLE,e._processToken(t))}function op(e,t){switch(t.tagID){case h.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,V.HTML),e.insertionMode=O.IN_ROW;break}case h.TH:case h.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(D.TR,h.TR),e.insertionMode=O.IN_ROW,sp(e,t);break}case h.CAPTION:case h.COL:case h.COLGROUP:case h.TBODY:case h.TFOOT:case h.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=O.IN_TABLE,xs(e,t));break}default:xs(e,t)}}function my(e,t){const n=t.tagID;switch(t.tagID){case h.TBODY:case h.TFOOT:case h.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=O.IN_TABLE);break}case h.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=O.IN_TABLE,ju(e,t));break}case h.BODY:case h.CAPTION:case h.COL:case h.COLGROUP:case h.HTML:case h.TD:case h.TH:case h.TR:break;default:ju(e,t)}}function sp(e,t){switch(t.tagID){case h.TH:case h.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,V.HTML),e.insertionMode=O.IN_CELL,e.activeFormattingElements.insertMarker();break}case h.CAPTION:case h.COL:case h.COLGROUP:case h.TBODY:case h.TFOOT:case h.THEAD:case h.TR:{e.openElements.hasInTableScope(h.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=O.IN_TABLE_BODY,op(e,t));break}default:xs(e,t)}}function AA(e,t){switch(t.tagID){case h.TR:{e.openElements.hasInTableScope(h.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=O.IN_TABLE_BODY);break}case h.TABLE:{e.openElements.hasInTableScope(h.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=O.IN_TABLE_BODY,my(e,t));break}case h.TBODY:case h.TFOOT:case h.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(h.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=O.IN_TABLE_BODY,my(e,t));break}case h.BODY:case h.CAPTION:case h.COL:case h.COLGROUP:case h.HTML:case h.TD:case h.TH:break;default:ju(e,t)}}function uG(e,t){const n=t.tagID;CA.has(n)?(e.openElements.hasInTableScope(h.TD)||e.openElements.hasInTableScope(h.TH))&&(e._closeTableCell(),sp(e,t)):Yt(e,t)}function cG(e,t){const n=t.tagID;switch(n){case h.TD:case h.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=O.IN_ROW);break}case h.TABLE:case h.TBODY:case h.TFOOT:case h.THEAD:case h.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),AA(e,t));break}case h.BODY:case h.CAPTION:case h.COL:case h.COLGROUP:case h.HTML:break;default:ip(e,t)}}function RA(e,t){switch(t.tagID){case h.HTML:{Yt(e,t);break}case h.OPTION:{e.openElements.currentTagId===h.OPTION&&e.openElements.pop(),e._insertElement(t,V.HTML);break}case h.OPTGROUP:{e.openElements.currentTagId===h.OPTION&&e.openElements.pop(),e.openElements.currentTagId===h.OPTGROUP&&e.openElements.pop(),e._insertElement(t,V.HTML);break}case h.HR:{e.openElements.currentTagId===h.OPTION&&e.openElements.pop(),e.openElements.currentTagId===h.OPTGROUP&&e.openElements.pop(),e._appendElement(t,V.HTML),t.ackSelfClosing=!0;break}case h.INPUT:case h.KEYGEN:case h.TEXTAREA:case h.SELECT:{e.openElements.hasInSelectScope(h.SELECT)&&(e.openElements.popUntilTagNamePopped(h.SELECT),e._resetInsertionMode(),t.tagID!==h.SELECT&&e._processStartTag(t));break}case h.SCRIPT:case h.TEMPLATE:{gr(e,t);break}}}function NA(e,t){switch(t.tagID){case h.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===h.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===h.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===h.OPTGROUP&&e.openElements.pop();break}case h.OPTION:{e.openElements.currentTagId===h.OPTION&&e.openElements.pop();break}case h.SELECT:{e.openElements.hasInSelectScope(h.SELECT)&&(e.openElements.popUntilTagNamePopped(h.SELECT),e._resetInsertionMode());break}case h.TEMPLATE:{no(e,t);break}}}function dG(e,t){const n=t.tagID;n===h.CAPTION||n===h.TABLE||n===h.TBODY||n===h.TFOOT||n===h.THEAD||n===h.TR||n===h.TD||n===h.TH?(e.openElements.popUntilTagNamePopped(h.SELECT),e._resetInsertionMode(),e._processStartTag(t)):RA(e,t)}function fG(e,t){const n=t.tagID;n===h.CAPTION||n===h.TABLE||n===h.TBODY||n===h.TFOOT||n===h.THEAD||n===h.TR||n===h.TD||n===h.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(h.SELECT),e._resetInsertionMode(),e.onEndTag(t)):NA(e,t)}function pG(e,t){switch(t.tagID){case h.BASE:case h.BASEFONT:case h.BGSOUND:case h.LINK:case h.META:case h.NOFRAMES:case h.SCRIPT:case h.STYLE:case h.TEMPLATE:case h.TITLE:{gr(e,t);break}case h.CAPTION:case h.COLGROUP:case h.TBODY:case h.TFOOT:case h.THEAD:{e.tmplInsertionModeStack[0]=O.IN_TABLE,e.insertionMode=O.IN_TABLE,xs(e,t);break}case h.COL:{e.tmplInsertionModeStack[0]=O.IN_COLUMN_GROUP,e.insertionMode=O.IN_COLUMN_GROUP,hy(e,t);break}case h.TR:{e.tmplInsertionModeStack[0]=O.IN_TABLE_BODY,e.insertionMode=O.IN_TABLE_BODY,op(e,t);break}case h.TD:case h.TH:{e.tmplInsertionModeStack[0]=O.IN_ROW,e.insertionMode=O.IN_ROW,sp(e,t);break}default:e.tmplInsertionModeStack[0]=O.IN_BODY,e.insertionMode=O.IN_BODY,Yt(e,t)}}function hG(e,t){t.tagID===h.TEMPLATE&&no(e,t)}function OA(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(h.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):fy(e,t)}function mG(e,t){t.tagID===h.HTML?Yt(e,t):lp(e,t)}function PA(e,t){var n;if(t.tagID===h.HTML){if(e.fragmentContext||(e.insertionMode=O.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===h.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else lp(e,t)}function lp(e,t){e.insertionMode=O.IN_BODY,rp(e,t)}function gG(e,t){switch(t.tagID){case h.HTML:{Yt(e,t);break}case h.FRAMESET:{e._insertElement(t,V.HTML);break}case h.FRAME:{e._appendElement(t,V.HTML),t.ackSelfClosing=!0;break}case h.NOFRAMES:{gr(e,t);break}}}function wG(e,t){t.tagID===h.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==h.FRAMESET&&(e.insertionMode=O.AFTER_FRAMESET))}function yG(e,t){switch(t.tagID){case h.HTML:{Yt(e,t);break}case h.NOFRAMES:{gr(e,t);break}}}function vG(e,t){t.tagID===h.HTML&&(e.insertionMode=O.AFTER_AFTER_FRAMESET)}function bG(e,t){t.tagID===h.HTML?Yt(e,t):up(e,t)}function up(e,t){e.insertionMode=O.IN_BODY,rp(e,t)}function xG(e,t){switch(t.tagID){case h.HTML:{Yt(e,t);break}case h.NOFRAMES:{gr(e,t);break}}}function EG(e,t){t.chars=nt,e._insertCharacters(t)}function TG(e,t){e._insertCharacters(t),e.framesetOk=!1}function IA(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==V.HTML&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function _G(e,t){if(jY(t))IA(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===V.MATHML?fA(t):r===V.SVG&&(zY(t),pA(t)),uy(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function SG(e,t){if(t.tagID===h.P||t.tagID===h.BR){IA(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===V.HTML){e._endTagOutsideForeignContent(t);break}const i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}D.AREA,D.BASE,D.BASEFONT,D.BGSOUND,D.BR,D.COL,D.EMBED,D.FRAME,D.HR,D.IMG,D.INPUT,D.KEYGEN,D.LINK,D.META,D.PARAM,D.SOURCE,D.TRACK,D.WBR;const kG=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,CG=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),DA={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function LA(e,t){const n=FG(e),r=zS("type",{handlers:{root:AG,element:RG,text:NG,comment:FA,doctype:OG,raw:IG},unknown:DG}),i={parser:n?new gA(DA):gA.getFragmentParser(void 0,DA),handle(s){r(s,i)},stitches:!1,options:t||{}};r(e,i),Es(i,Mr());const a=n?i.parser.document:i.parser.getFragment(),o=BW(a,{file:i.options.file});return i.stitches&&zf(o,"comment",function(s,l,u){const c=s;if(c.value.stitch&&u&&l!==void 0){const d=u.children;return d[l]=c.value.stitch,l}}),o.type==="root"&&o.children.length===1&&o.children[0].type===e.type?o.children[0]:o}function MA(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function AG(e,t){MA(e.children,t)}function RG(e,t){LG(e,t),MA(e.children,t),MG(e,t)}function NG(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:Ae.CHARACTER,chars:e.value,location:Hu(e)};Es(t,Mr(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function OG(e,t){const n={type:Ae.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:Hu(e)};Es(t,Mr(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function PG(e,t){t.stitches=!0;const n=BG(e);if("children"in e&&"children"in n){const r=LA({type:"root",children:e.children},t.options);n.children=r.children}FA({type:"comment",value:{stitch:n}},t)}function FA(e,t){const n=e.value,r={type:Ae.COMMENT,data:n,location:Hu(e)};Es(t,Mr(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function IG(e,t){if(t.parser.tokenizer.preprocessor.html="",t.parser.tokenizer.preprocessor.pos=-1,t.parser.tokenizer.preprocessor.lastGapPos=-2,t.parser.tokenizer.preprocessor.gapStack=[],t.parser.tokenizer.preprocessor.skipNextNewLine=!1,t.parser.tokenizer.preprocessor.lastChunkWritten=!1,t.parser.tokenizer.preprocessor.endOfChunkHit=!1,t.parser.tokenizer.preprocessor.isEol=!1,BA(t,Mr(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(kG,"&lt;$1$2"):e.value,!1),t.parser.tokenizer._runParsingLoop(),t.parser.tokenizer.state===72||t.parser.tokenizer.state===78){t.parser.tokenizer.preprocessor.lastChunkWritten=!0;const n=t.parser.tokenizer._consume();t.parser.tokenizer._callState(n)}}function DG(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))PG(n,t);else{let r="";throw CG.has(n.type)&&(r=". It looks like you are using MDX nodes with `hast-util-raw` (or `rehype-raw`). If you use this because you are using remark or rehype plugins that inject `'html'` nodes, then please raise an issue with that plugin, as its a bad and slow idea. If you use this because you are using markdown syntax, then you have to configure this utility (or plugin) to pass through these nodes (see `passThrough` in docs), but you can also migrate to use the MDX syntax"),new Error("Cannot compile `"+n.type+"` node"+r)}}function Es(e,t){BA(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=pt.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function BA(e,t){if(t&&t.offset!==void 0){const n={startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:-1,endCol:-1,endOffset:-1};e.parser.tokenizer.preprocessor.lineStartPos=-t.column+1,e.parser.tokenizer.preprocessor.droppedBufferSize=t.offset,e.parser.tokenizer.preprocessor.line=t.line,e.parser.tokenizer.currentLocation=n}}function LG(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===pt.PLAINTEXT)return;Es(t,Mr(e));const r=t.parser.openElements.current;let i="namespaceURI"in r?r.namespaceURI:eo.html;i===eo.html&&n==="svg"&&(i=eo.svg);const a=VW({...e,children:[]},{space:i===eo.svg?"svg":"html"}),o={type:Ae.START_TAG,tagName:n,tagID:bs(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:Hu(e)};t.parser.currentToken=o,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function MG(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&QW.includes(n)||t.parser.tokenizer.state===pt.PLAINTEXT)return;Es(t,Yf(e));const r={type:Ae.END_TAG,tagName:n,tagID:bs(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:Hu(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===pt.RCDATA||t.parser.tokenizer.state===pt.RAWTEXT||t.parser.tokenizer.state===pt.SCRIPT_DATA)&&(t.parser.tokenizer.state=pt.DATA)}function FG(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function Hu(e){const t=Mr(e)||{line:void 0,column:void 0,offset:void 0},n=Yf(e)||{line:void 0,column:void 0,offset:void 0};return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function BG(e){return"children"in e?ws({...e,children:[]}):ws(e)}function jG(e){return function(t,n){return LA(t,{...e,file:n})}}function jA({attachment:e}){const{name:t,size:n,type:r,url:i}=e,a=r.startsWith("image/"),o=r.startsWith("video/"),s=r.startsWith("audio/");return E.jsxs("div",{className:"size-fit gap-2 border shrink-0 rounded-xl overflow-hidden",children:[a&&E.jsx("img",{loading:"lazy",src:i,className:"object-cover size-16"}),o&&E.jsxs("video",{controls:!0,children:[E.jsx("source",{src:i,type:r}),"Your browser does not support the video tag."]}),s&&E.jsxs("audio",{controls:!0,className:"w-full mt-2 rounded-md border",children:[E.jsx("source",{src:i,type:r}),"Your browser does not support the audio tag."]}),!a&&!o&&!s&&E.jsxs("div",{className:"flex items-center gap-2 p-2",children:[E.jsx("a",{href:i,target:"_blank",rel:"noopener noreferrer",className:"text-blue-500 line-clamp-2 underline hover:text-blue-600",children:t}),E.jsxs("span",{className:"text-sm text-gray-500 whitespace-nowrap",children:[(n/1024).toFixed(2)," KB"]})]})]})}function zG({data:e,id:t,type:n,attachments:r}){return E.jsxs("div",{children:[E.jsx("div",{className:"gap-0.5 flex flex-row flex-wrap items-center justify-start",children:r==null?void 0:r.map(i=>E.jsx(jA,{attachment:i},i.id))}),E.jsx(CW,{"data-type":n,"data-id":t,remarkPlugins:[KH],rehypePlugins:[jG],components:{a:({children:i,...a})=>E.jsx("a",{target:"_top",...a,children:i})},className:"leading-snug font-medium text-sm prose prose-a:decoration-primary prose-a:underline prose-sm prose-slate",children:e.message})]})}var gy="Avatar",[UG,rle]=Zr(gy),[HG,zA]=UG(gy),UA=y.forwardRef((e,t)=>{const{__scopeAvatar:n,...r}=e,[i,a]=y.useState("idle");return E.jsx(HG,{scope:n,imageLoadingStatus:i,onImageLoadingStatusChange:a,children:E.jsx(rn.span,{...r,ref:t})})});UA.displayName=gy;var HA="AvatarImage",VA=y.forwardRef((e,t)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:i=()=>{},...a}=e,o=zA(HA,n),s=VG(r,a.referrerPolicy),l=Dt(u=>{i(u),o.onImageLoadingStatusChange(u)});return $n(()=>{s!=="idle"&&l(s)},[s,l]),s==="loaded"?E.jsx(rn.img,{...a,ref:t,src:r}):null});VA.displayName=HA;var $A="AvatarFallback",WA=y.forwardRef((e,t)=>{const{__scopeAvatar:n,delayMs:r,...i}=e,a=zA($A,n),[o,s]=y.useState(r===void 0);return y.useEffect(()=>{if(r!==void 0){const l=window.setTimeout(()=>s(!0),r);return()=>window.clearTimeout(l)}},[r]),o&&a.imageLoadingStatus!=="loaded"?E.jsx(rn.span,{...i,ref:t}):null});WA.displayName=$A;function VG(e,t){const[n,r]=y.useState("idle");return $n(()=>{if(!e){r("error");return}let i=!0;const a=new window.Image,o=s=>()=>{i&&r(s)};return r("loading"),a.onload=o("loaded"),a.onerror=o("error"),a.src=e,t&&(a.referrerPolicy=t),()=>{i=!1}},[e,t]),n}var YA=UA,qA=VA,GA=WA;const cp=y.forwardRef(({className:e,...t},n)=>E.jsx(YA,{ref:n,className:He("relative flex size-6 aspect-square shrink-0 overflow-hidden rounded-lg border bg-secondary",e),...t}));cp.displayName=YA.displayName;const wy=y.forwardRef(({className:e,...t},n)=>E.jsx(qA,{ref:n,className:He("aspect-square h-full w-full",e),...t}));wy.displayName=qA.displayName;const yy=y.forwardRef(({className:e,...t},n)=>E.jsx(GA,{ref:n,className:He("flex size-full text-sm items-center justify-center rounded-lg",e),...t}));yy.displayName=GA.displayName;function $G(e){if(typeof Proxy>"u")return e;const t=new Map,n=(...r)=>e(...r);return new Proxy(n,{get:(r,i)=>i==="create"?e:(t.has(i)||t.set(i,e(i)),t.get(i))})}function Vu(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}const vy=e=>Array.isArray(e);function KA(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}function $u(e){return typeof e=="string"||Array.isArray(e)}function XA(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function by(e,t,n,r){if(typeof t=="function"){const[i,a]=XA(r);t=t(n!==void 0?n:e.custom,i,a)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,a]=XA(r);t=t(n!==void 0?n:e.custom,i,a)}return t}function dp(e,t,n){const r=e.getProps();return by(r,t,n!==void 0?n:r.custom,e)}const xy=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Ey=["initial",...xy],Wu=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],pa=new Set(Wu),hi=e=>e*1e3,mi=e=>e/1e3,WG={type:"spring",stiffness:500,damping:25,restSpeed:10},YG=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),qG={type:"keyframes",duration:.8},GG={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},KG=(e,{keyframes:t})=>t.length>2?qG:pa.has(e)?e.startsWith("scale")?YG(t[1]):WG:GG;function Ty(e,t){return e?e[t]||e.default||e:void 0}const XG={skipAnimations:!1,useManualTiming:!1},QG=e=>e!==null;function fp(e,{repeat:t,repeatType:n="loop"},r){const i=e.filter(QG),a=t&&n!=="loop"&&t%2===1?0:i.length-1;return!a||r===void 0?i[a]:r}const qt=e=>e;function ZG(e){let t=new Set,n=new Set,r=!1,i=!1;const a=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1};function s(u){a.has(u)&&(l.schedule(u),e()),u(o)}const l={schedule:(u,c=!1,d=!1)=>{const p=d&&r?t:n;return c&&a.add(u),p.has(u)||p.add(u),u},cancel:u=>{n.delete(u),a.delete(u)},process:u=>{if(o=u,r){i=!0;return}r=!0,[t,n]=[n,t],n.clear(),t.forEach(s),r=!1,i&&(i=!1,l.process(u))}};return l}const pp=["read","resolveKeyframes","update","preRender","render","postRender"],JG=40;function QA(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},a=()=>n=!0,o=pp.reduce((m,v)=>(m[v]=ZG(a),m),{}),{read:s,resolveKeyframes:l,update:u,preRender:c,render:d,postRender:f}=o,p=()=>{const m=performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(m-i.timestamp,JG),1),i.timestamp=m,i.isProcessing=!0,s.process(i),l.process(i),u.process(i),c.process(i),d.process(i),f.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(p))},g=()=>{n=!0,r=!0,i.isProcessing||e(p)};return{schedule:pp.reduce((m,v)=>{const b=o[v];return m[v]=(T,_=!1,S=!1)=>(n||g(),b.schedule(T,_,S)),m},{}),cancel:m=>{for(let v=0;v<pp.length;v++)o[pp[v]].cancel(m)},state:i,steps:o}}const{schedule:We,cancel:ha,state:Lt,steps:_y}=QA(typeof requestAnimationFrame<"u"?requestAnimationFrame:qt,!0),ZA=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,eK=1e-7,tK=12;function nK(e,t,n,r,i){let a,o,s=0;do o=t+(n-t)/2,a=ZA(o,r,i)-e,a>0?n=o:t=o;while(Math.abs(a)>eK&&++s<tK);return o}function Yu(e,t,n,r){if(e===t&&n===r)return qt;const i=a=>nK(a,0,1,e,n);return a=>a===0||a===1?a:ZA(i(a),t,r)}const JA=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,e3=e=>t=>1-e(1-t),t3=Yu(.33,1.53,.69,.99),Sy=e3(t3),n3=JA(Sy),r3=e=>(e*=2)<1?.5*Sy(e):.5*(2-Math.pow(2,-10*(e-1))),ky=e=>1-Math.sin(Math.acos(e)),i3=e3(ky),a3=JA(ky),o3=e=>/^0[^.\s]+$/u.test(e);function rK(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||o3(e):!0}let Cy=qt;const s3=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),l3=e=>t=>typeof t=="string"&&t.startsWith(e),u3=l3("--"),iK=l3("var(--"),Ay=e=>iK(e)?aK.test(e.split("/*")[0].trim()):!1,aK=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,oK=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function sK(e){const t=oK.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}function c3(e,t,n=1){const[r,i]=sK(e);if(!r)return;const a=window.getComputedStyle(t).getPropertyValue(r);if(a){const o=a.trim();return s3(o)?parseFloat(o):o}return Ay(i)?c3(i,t,n+1):i}const ma=(e,t,n)=>n>t?t:n<e?e:n,Ts={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},qu={...Ts,transform:e=>ma(0,1,e)},hp={...Ts,default:1},Gu=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),ga=Gu("deg"),jr=Gu("%"),he=Gu("px"),lK=Gu("vh"),uK=Gu("vw"),d3={...jr,parse:e=>jr.parse(e)/100,transform:e=>jr.transform(e*100)},cK=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),f3=e=>e===Ts||e===he,p3=(e,t)=>parseFloat(e.split(", ")[t]),h3=(e,t)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;const i=r.match(/^matrix3d\((.+)\)$/u);if(i)return p3(i[1],t);{const a=r.match(/^matrix\((.+)\)$/u);return a?p3(a[1],e):0}},dK=new Set(["x","y","z"]),fK=Wu.filter(e=>!dK.has(e));function pK(e){const t=[];return fK.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const _s={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:h3(4,13),y:h3(5,14)};_s.translateX=_s.x,_s.translateY=_s.y;const m3=e=>t=>t.test(e),g3=[Ts,he,jr,ga,uK,lK,{test:e=>e==="auto",parse:e=>e}],w3=e=>g3.find(m3(e)),ro=new Set;let Ry=!1,Ny=!1;function y3(){if(Ny){const e=Array.from(ro).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=pK(r);i.length&&(n.set(r,i),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const i=n.get(r);i&&i.forEach(([a,o])=>{var s;(s=r.getValue(a))===null||s===void 0||s.set(o)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Ny=!1,Ry=!1,ro.forEach(e=>e.complete()),ro.clear()}function v3(){ro.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Ny=!0)})}function hK(){v3(),y3()}class Oy{constructor(t,n,r,i,a,o=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=a,this.isAsync=o}scheduleResolve(){this.isScheduled=!0,this.isAsync?(ro.add(this),Ry||(Ry=!0,We.read(v3),We.resolveKeyframes(y3))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;for(let a=0;a<t.length;a++)if(t[a]===null)if(a===0){const o=i==null?void 0:i.get(),s=t[t.length-1];if(o!==void 0)t[0]=o;else if(r&&n){const l=r.readValue(n,s);l!=null&&(t[0]=l)}t[0]===void 0&&(t[0]=s),i&&o===void 0&&i.set(t[0])}else t[a]=t[a-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),ro.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,ro.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}const Ku=e=>Math.round(e*1e5)/1e5,Py=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function mK(e){return e==null}const gK=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Iy=(e,t)=>n=>!!(typeof n=="string"&&gK.test(n)&&n.startsWith(e)||t&&!mK(n)&&Object.prototype.hasOwnProperty.call(n,t)),b3=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,a,o,s]=r.match(Py);return{[e]:parseFloat(i),[t]:parseFloat(a),[n]:parseFloat(o),alpha:s!==void 0?parseFloat(s):1}},wK=e=>ma(0,255,e),Dy={...Ts,transform:e=>Math.round(wK(e))},io={test:Iy("rgb","red"),parse:b3("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Dy.transform(e)+", "+Dy.transform(t)+", "+Dy.transform(n)+", "+Ku(qu.transform(r))+")"};function yK(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const Ly={test:Iy("#"),parse:yK,transform:io.transform},Ss={test:Iy("hsl","hue"),parse:b3("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+jr.transform(Ku(t))+", "+jr.transform(Ku(n))+", "+Ku(qu.transform(r))+")"},Gt={test:e=>io.test(e)||Ly.test(e)||Ss.test(e),parse:e=>io.test(e)?io.parse(e):Ss.test(e)?Ss.parse(e):Ly.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?io.transform(e):Ss.transform(e)},vK=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function bK(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(Py))===null||t===void 0?void 0:t.length)||0)+(((n=e.match(vK))===null||n===void 0?void 0:n.length)||0)>0}const x3="number",E3="color",xK="var",EK="var(",T3="${}",TK=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Xu(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let a=0;const s=t.replace(TK,l=>(Gt.test(l)?(r.color.push(a),i.push(E3),n.push(Gt.parse(l))):l.startsWith(EK)?(r.var.push(a),i.push(xK),n.push(l)):(r.number.push(a),i.push(x3),n.push(parseFloat(l))),++a,T3)).split(T3);return{values:n,split:s,indexes:r,types:i}}function _3(e){return Xu(e).values}function S3(e){const{split:t,types:n}=Xu(e),r=t.length;return i=>{let a="";for(let o=0;o<r;o++)if(a+=t[o],i[o]!==void 0){const s=n[o];s===x3?a+=Ku(i[o]):s===E3?a+=Gt.transform(i[o]):a+=i[o]}return a}}const _K=e=>typeof e=="number"?0:e;function SK(e){const t=_3(e);return S3(e)(t.map(_K))}const wa={test:bK,parse:_3,createTransformer:S3,getAnimatableNone:SK},kK=new Set(["brightness","contrast","saturate","opacity"]);function CK(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Py)||[];if(!r)return e;const i=n.replace(r,"");let a=kK.has(t)?1:0;return r!==n&&(a*=100),t+"("+a+i+")"}const AK=/\b([a-z-]*)\(.*?\)/gu,My={...wa,getAnimatableNone:e=>{const t=e.match(AK);return t?t.map(CK).join(" "):e}},RK={borderWidth:he,borderTopWidth:he,borderRightWidth:he,borderBottomWidth:he,borderLeftWidth:he,borderRadius:he,radius:he,borderTopLeftRadius:he,borderTopRightRadius:he,borderBottomRightRadius:he,borderBottomLeftRadius:he,width:he,maxWidth:he,height:he,maxHeight:he,top:he,right:he,bottom:he,left:he,padding:he,paddingTop:he,paddingRight:he,paddingBottom:he,paddingLeft:he,margin:he,marginTop:he,marginRight:he,marginBottom:he,marginLeft:he,backgroundPositionX:he,backgroundPositionY:he},NK={rotate:ga,rotateX:ga,rotateY:ga,rotateZ:ga,scale:hp,scaleX:hp,scaleY:hp,scaleZ:hp,skew:ga,skewX:ga,skewY:ga,distance:he,translateX:he,translateY:he,translateZ:he,x:he,y:he,z:he,perspective:he,transformPerspective:he,opacity:qu,originX:d3,originY:d3,originZ:he},k3={...Ts,transform:Math.round},Fy={...RK,...NK,zIndex:k3,size:he,fillOpacity:qu,strokeOpacity:qu,numOctaves:k3},OK={...Fy,color:Gt,backgroundColor:Gt,outlineColor:Gt,fill:Gt,stroke:Gt,borderColor:Gt,borderTopColor:Gt,borderRightColor:Gt,borderBottomColor:Gt,borderLeftColor:Gt,filter:My,WebkitFilter:My},By=e=>OK[e];function C3(e,t){let n=By(e);return n!==My&&(n=wa),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const PK=new Set(["auto","none","0"]);function IK(e,t,n){let r=0,i;for(;r<e.length&&!i;){const a=e[r];typeof a=="string"&&!PK.has(a)&&Xu(a).values.length&&(i=e[r]),r++}if(i&&n)for(const a of t)e[a]=C3(n,i)}class A3 extends Oy{constructor(t,n,r,i,a){super(t,n,r,i,a,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let u=t[l];if(typeof u=="string"&&(u=u.trim(),Ay(u))){const c=c3(u,n.current);c!==void 0&&(t[l]=c),l===t.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!cK.has(r)||t.length!==2)return;const[i,a]=t,o=w3(i),s=w3(a);if(o!==s)if(f3(o)&&f3(s))for(let l=0;l<t.length;l++){const u=t[l];typeof u=="string"&&(t[l]=parseFloat(u))}else this.needsMeasurement=!0}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let i=0;i<t.length;i++)rK(t[i])&&r.push(i);r.length&&IK(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=_s[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&t.getValue(r,i).jump(i,!1)}measureEndState(){var t;const{element:n,name:r,unresolvedKeyframes:i}=this;if(!n||!n.current)return;const a=n.getValue(r);a&&a.jump(this.measuredOrigin,!1);const o=i.length-1,s=i[o];i[o]=_s[r](n.measureViewportBox(),window.getComputedStyle(n.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),!((t=this.removedTransforms)===null||t===void 0)&&t.length&&this.removedTransforms.forEach(([l,u])=>{n.getValue(l).set(u)}),this.resolveNoneKeyframes()}}function jy(e){return typeof e=="function"}let mp;function DK(){mp=void 0}const zr={now:()=>(mp===void 0&&zr.set(Lt.isProcessing||XG.useManualTiming?Lt.timestamp:performance.now()),mp),set:e=>{mp=e,queueMicrotask(DK)}},R3=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(wa.test(e)||e==="0")&&!e.startsWith("url("));function LK(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function MK(e,t,n,r){const i=e[0];if(i===null)return!1;if(t==="display"||t==="visibility")return!0;const a=e[e.length-1],o=R3(i,t),s=R3(a,t);return!o||!s?!1:LK(e)||(n==="spring"||jy(n))&&r}const FK=40;class N3{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:a=0,repeatType:o="loop",...s}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=zr.now(),this.options={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:a,repeatType:o,...s},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt?this.resolvedAt-this.createdAt>FK?this.resolvedAt:this.createdAt:this.createdAt}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&hK(),this._resolved}onKeyframesResolved(t,n){this.resolvedAt=zr.now(),this.hasAttemptedResolve=!0;const{name:r,type:i,velocity:a,delay:o,onComplete:s,onUpdate:l,isGenerator:u}=this.options;if(!u&&!MK(t,r,i,a))if(o)this.options.duration=0;else{l==null||l(fp(t,this.options,n)),s==null||s(),this.resolveFinishedPromise();return}const c=this.initPlayback(t,n);c!==!1&&(this._resolved={keyframes:t,finalKeyframe:n,...c},this.onPostResolved())}onPostResolved(){}then(t,n){return this.currentFinishedPromise.then(t,n)}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}}function O3(e,t){return t?e*(1e3/t):0}const BK=5;function P3(e,t,n){const r=Math.max(t-BK,0);return O3(n-e(r),t-r)}const zy=.001,jK=.01,zK=10,UK=.05,HK=1;function VK({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let i,a,o=1-t;o=ma(UK,HK,o),e=ma(jK,zK,mi(e)),o<1?(i=u=>{const c=u*o,d=c*e,f=c-n,p=Uy(u,o),g=Math.exp(-d);return zy-f/p*g},a=u=>{const d=u*o*e,f=d*n+n,p=Math.pow(o,2)*Math.pow(u,2)*e,g=Math.exp(-d),w=Uy(Math.pow(u,2),o);return(-i(u)+zy>0?-1:1)*((f-p)*g)/w}):(i=u=>{const c=Math.exp(-u*e),d=(u-n)*e+1;return-zy+c*d},a=u=>{const c=Math.exp(-u*e),d=(n-u)*(e*e);return c*d});const s=5/e,l=WK(i,a,s);if(e=hi(e),isNaN(l))return{stiffness:100,damping:10,duration:e};{const u=Math.pow(l,2)*r;return{stiffness:u,damping:o*2*Math.sqrt(r*u),duration:e}}}const $K=12;function WK(e,t,n){let r=n;for(let i=1;i<$K;i++)r=r-e(r)/t(r);return r}function Uy(e,t){return e*Math.sqrt(1-t*t)}const YK=["duration","bounce"],qK=["stiffness","damping","mass"];function I3(e,t){return t.some(n=>e[n]!==void 0)}function GK(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!I3(e,qK)&&I3(e,YK)){const n=VK(e);t={...t,...n,mass:1},t.isResolvedFromDuration=!0}return t}function D3({keyframes:e,restDelta:t,restSpeed:n,...r}){const i=e[0],a=e[e.length-1],o={done:!1,value:i},{stiffness:s,damping:l,mass:u,duration:c,velocity:d,isResolvedFromDuration:f}=GK({...r,velocity:-mi(r.velocity||0)}),p=d||0,g=l/(2*Math.sqrt(s*u)),w=a-i,x=mi(Math.sqrt(s/u)),m=Math.abs(w)<5;n||(n=m?.01:2),t||(t=m?.005:.5);let v;if(g<1){const b=Uy(x,g);v=T=>{const _=Math.exp(-g*x*T);return a-_*((p+g*x*w)/b*Math.sin(b*T)+w*Math.cos(b*T))}}else if(g===1)v=b=>a-Math.exp(-x*b)*(w+(p+x*w)*b);else{const b=x*Math.sqrt(g*g-1);v=T=>{const _=Math.exp(-g*x*T),S=Math.min(b*T,300);return a-_*((p+g*x*w)*Math.sinh(S)+b*w*Math.cosh(S))/b}}return{calculatedDuration:f&&c||null,next:b=>{const T=v(b);if(f)o.done=b>=c;else{let _=0;g<1&&(_=b===0?hi(p):P3(v,b,T));const S=Math.abs(_)<=n,R=Math.abs(a-T)<=t;o.done=S&&R}return o.value=o.done?a:T,o}}}function L3({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:a=500,modifyTarget:o,min:s,max:l,restDelta:u=.5,restSpeed:c}){const d=e[0],f={done:!1,value:d},p=P=>s!==void 0&&P<s||l!==void 0&&P>l,g=P=>s===void 0?l:l===void 0||Math.abs(s-P)<Math.abs(l-P)?s:l;let w=n*t;const x=d+w,m=o===void 0?x:o(x);m!==x&&(w=m-d);const v=P=>-w*Math.exp(-P/r),b=P=>m+v(P),T=P=>{const B=v(P),N=b(P);f.done=Math.abs(B)<=u,f.value=f.done?m:N};let _,S;const R=P=>{p(f.value)&&(_=P,S=D3({keyframes:[f.value,g(f.value)],velocity:P3(b,P,f.value),damping:i,stiffness:a,restDelta:u,restSpeed:c}))};return R(0),{calculatedDuration:null,next:P=>{let B=!1;return!S&&_===void 0&&(B=!0,T(P),R(P)),_!==void 0&&P>=_?S.next(P-_):(!B&&T(P),f)}}}const KK=Yu(.42,0,1,1),XK=Yu(0,0,.58,1),M3=Yu(.42,0,.58,1),QK=e=>Array.isArray(e)&&typeof e[0]!="number",Hy=e=>Array.isArray(e)&&typeof e[0]=="number",F3={linear:qt,easeIn:KK,easeInOut:M3,easeOut:XK,circIn:ky,circInOut:a3,circOut:i3,backIn:Sy,backInOut:n3,backOut:t3,anticipate:r3},B3=e=>{if(Hy(e)){Cy(e.length===4);const[t,n,r,i]=e;return Yu(t,n,r,i)}else if(typeof e=="string")return Cy(F3[e]!==void 0),F3[e];return e},ZK=(e,t)=>n=>t(e(n)),gi=(...e)=>e.reduce(ZK),ks=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r},lt=(e,t,n)=>e+(t-e)*n;function Vy(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function JK({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,a=0,o=0;if(!t)i=a=o=n;else{const s=n<.5?n*(1+t):n+t-n*t,l=2*n-s;i=Vy(l,s,e+1/3),a=Vy(l,s,e),o=Vy(l,s,e-1/3)}return{red:Math.round(i*255),green:Math.round(a*255),blue:Math.round(o*255),alpha:r}}function gp(e,t){return n=>n>0?t:e}const $y=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},eX=[Ly,io,Ss],tX=e=>eX.find(t=>t.test(e));function j3(e){const t=tX(e);if(!t)return!1;let n=t.parse(e);return t===Ss&&(n=JK(n)),n}const z3=(e,t)=>{const n=j3(e),r=j3(t);if(!n||!r)return gp(e,t);const i={...n};return a=>(i.red=$y(n.red,r.red,a),i.green=$y(n.green,r.green,a),i.blue=$y(n.blue,r.blue,a),i.alpha=lt(n.alpha,r.alpha,a),io.transform(i))},Wy=new Set(["none","hidden"]);function nX(e,t){return Wy.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function rX(e,t){return n=>lt(e,t,n)}function Yy(e){return typeof e=="number"?rX:typeof e=="string"?Ay(e)?gp:Gt.test(e)?z3:oX:Array.isArray(e)?U3:typeof e=="object"?Gt.test(e)?z3:iX:gp}function U3(e,t){const n=[...e],r=n.length,i=e.map((a,o)=>Yy(a)(a,t[o]));return a=>{for(let o=0;o<r;o++)n[o]=i[o](a);return n}}function iX(e,t){const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=Yy(e[i])(e[i],t[i]));return i=>{for(const a in r)n[a]=r[a](i);return n}}function aX(e,t){var n;const r=[],i={color:0,var:0,number:0};for(let a=0;a<t.values.length;a++){const o=t.types[a],s=e.indexes[o][i[o]],l=(n=e.values[s])!==null&&n!==void 0?n:0;r[a]=l,i[o]++}return r}const oX=(e,t)=>{const n=wa.createTransformer(t),r=Xu(e),i=Xu(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Wy.has(e)&&!i.values.length||Wy.has(t)&&!r.values.length?nX(e,t):gi(U3(aX(r,i),i.values),n):gp(e,t)};function H3(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?lt(e,t,n):Yy(e)(e,t)}function sX(e,t,n){const r=[],i=n||H3,a=e.length-1;for(let o=0;o<a;o++){let s=i(e[o],e[o+1]);if(t){const l=Array.isArray(t)?t[o]||qt:t;s=gi(l,s)}r.push(s)}return r}function lX(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const a=e.length;if(Cy(a===t.length),a===1)return()=>t[0];if(a===2&&e[0]===e[1])return()=>t[1];e[0]>e[a-1]&&(e=[...e].reverse(),t=[...t].reverse());const o=sX(t,r,i),s=o.length,l=u=>{let c=0;if(s>1)for(;c<e.length-2&&!(u<e[c+1]);c++);const d=ks(e[c],e[c+1],u);return o[c](d)};return n?u=>l(ma(e[0],e[a-1],u)):l}function uX(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=ks(0,t,r);e.push(lt(n,1,i))}}function cX(e){const t=[0];return uX(t,e.length-1),t}function dX(e,t){return e.map(n=>n*t)}function fX(e,t){return e.map(()=>t||M3).splice(0,e.length-1)}function wp({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=QK(r)?r.map(B3):B3(r),a={done:!1,value:t[0]},o=dX(n&&n.length===t.length?n:cX(t),e),s=lX(o,t,{ease:Array.isArray(i)?i:fX(t,i)});return{calculatedDuration:e,next:l=>(a.value=s(l),a.done=l>=e,a)}}const V3=2e4;function pX(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<V3;)t+=n,r=e.next(t);return t>=V3?1/0:t}const hX=e=>{const t=({timestamp:n})=>e(n);return{start:()=>We.update(t,!0),stop:()=>ha(t),now:()=>Lt.isProcessing?Lt.timestamp:zr.now()}},mX={decay:L3,inertia:L3,tween:wp,keyframes:wp,spring:D3},gX=e=>e/100;class qy extends N3{constructor(t){super(t),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();const{onStop:l}=this.options;l&&l()};const{name:n,motionValue:r,element:i,keyframes:a}=this.options,o=(i==null?void 0:i.KeyframeResolver)||Oy,s=(l,u)=>this.onKeyframesResolved(l,u);this.resolver=new o(a,s,n,r,i),this.resolver.scheduleResolve()}initPlayback(t){const{type:n="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:a,velocity:o=0}=this.options,s=jy(n)?n:mX[n]||wp;let l,u;s!==wp&&typeof t[0]!="number"&&(l=gi(gX,H3(t[0],t[1])),t=[0,100]);const c=s({...this.options,keyframes:t});a==="mirror"&&(u=s({...this.options,keyframes:[...t].reverse(),velocity:-o})),c.calculatedDuration===null&&(c.calculatedDuration=pX(c));const{calculatedDuration:d}=c,f=d+i,p=f*(r+1)-i;return{generator:c,mirroredGenerator:u,mapPercentToKeyframes:l,calculatedDuration:d,resolvedDuration:f,totalDuration:p}}onPostResolved(){const{autoplay:t=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!t?this.pause():this.state=this.pendingPlayState}tick(t,n=!1){const{resolved:r}=this;if(!r){const{keyframes:P}=this.options;return{done:!0,value:P[P.length-1]}}const{finalKeyframe:i,generator:a,mirroredGenerator:o,mapPercentToKeyframes:s,keyframes:l,calculatedDuration:u,totalDuration:c,resolvedDuration:d}=r;if(this.startTime===null)return a.next(0);const{delay:f,repeat:p,repeatType:g,repeatDelay:w,onUpdate:x}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-c/this.speed,this.startTime)),n?this.currentTime=t:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;const m=this.currentTime-f*(this.speed>=0?1:-1),v=this.speed>=0?m<0:m>c;this.currentTime=Math.max(m,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=c);let b=this.currentTime,T=a;if(p){const P=Math.min(this.currentTime,c)/d;let B=Math.floor(P),N=P%1;!N&&P>=1&&(N=1),N===1&&B--,B=Math.min(B,p+1),!!(B%2)&&(g==="reverse"?(N=1-N,w&&(N-=w/d)):g==="mirror"&&(T=o)),b=ma(0,1,N)*d}const _=v?{done:!1,value:l[0]}:T.next(b);s&&(_.value=s(_.value));let{done:S}=_;!v&&u!==null&&(S=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const R=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&S);return R&&i!==void 0&&(_.value=fp(l,this.options,i)),x&&x(_.value),R&&this.finish(),_}get duration(){const{resolved:t}=this;return t?mi(t.calculatedDuration):0}get time(){return mi(this.currentTime)}set time(t){t=hi(t),this.currentTime=t,this.holdTime!==null||this.speed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=mi(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;const{driver:t=hX,onPlay:n,startTime:r}=this.options;this.driver||(this.driver=t(a=>this.tick(a))),n&&n();const i=this.driver.now();this.holdTime!==null?this.startTime=i-this.holdTime:this.startTime?this.state==="finished"&&(this.startTime=i):this.startTime=r??this.calcStartTime(),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}}const $3=new Set(["opacity","clipPath","filter","transform"]),wX=10,yX=(e,t)=>{let n="";const r=Math.max(Math.round(t/wX),2);for(let i=0;i<r;i++)n+=e(ks(0,r-1,i))+", ";return`linear(${n.substring(0,n.length-2)})`};function Gy(e){let t;return()=>(t===void 0&&(t=e()),t)}const vX={linearEasing:void 0};function bX(e,t){const n=Gy(e);return()=>{var r;return(r=vX[t])!==null&&r!==void 0?r:n()}}const yp=bX(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");function W3(e){return!!(typeof e=="function"&&yp()||!e||typeof e=="string"&&(e in Ky||yp())||Hy(e)||Array.isArray(e)&&e.every(W3))}const Qu=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Ky={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Qu([0,.65,.55,1]),circOut:Qu([.55,0,1,.45]),backIn:Qu([.31,.01,.66,-.59]),backOut:Qu([.33,1.53,.69,.99])};function Y3(e,t){if(e)return typeof e=="function"&&yp()?yX(e,t):Hy(e)?Qu(e):Array.isArray(e)?e.map(n=>Y3(n,t)||Ky.easeOut):Ky[e]}function xX(e,t,n,{delay:r=0,duration:i=300,repeat:a=0,repeatType:o="loop",ease:s,times:l}={}){const u={[t]:n};l&&(u.offset=l);const c=Y3(s,i);return Array.isArray(c)&&(u.easing=c),e.animate(u,{delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:a+1,direction:o==="reverse"?"alternate":"normal"})}function q3(e,t){e.timeline=t,e.onfinish=null}const EX=Gy(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),vp=10,TX=2e4;function _X(e){return jy(e.type)||e.type==="spring"||!W3(e.ease)}function SX(e,t){const n=new qy({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0});let r={done:!1,value:e[0]};const i=[];let a=0;for(;!r.done&&a<TX;)r=n.sample(a),i.push(r.value),a+=vp;return{times:void 0,keyframes:i,duration:a-vp,ease:"linear"}}const G3={anticipate:r3,backInOut:n3,circInOut:a3};function kX(e){return e in G3}class K3 extends N3{constructor(t){super(t);const{name:n,motionValue:r,element:i,keyframes:a}=this.options;this.resolver=new A3(a,(o,s)=>this.onKeyframesResolved(o,s),n,r,i),this.resolver.scheduleResolve()}initPlayback(t,n){var r;let{duration:i=300,times:a,ease:o,type:s,motionValue:l,name:u,startTime:c}=this.options;if(!(!((r=l.owner)===null||r===void 0)&&r.current))return!1;if(typeof o=="string"&&yp()&&kX(o)&&(o=G3[o]),_X(this.options)){const{onComplete:f,onUpdate:p,motionValue:g,element:w,...x}=this.options,m=SX(t,x);t=m.keyframes,t.length===1&&(t[1]=t[0]),i=m.duration,a=m.times,o=m.ease,s="keyframes"}const d=xX(l.owner.current,u,t,{...this.options,duration:i,times:a,ease:o});return d.startTime=c??this.calcStartTime(),this.pendingTimeline?(q3(d,this.pendingTimeline),this.pendingTimeline=void 0):d.onfinish=()=>{const{onComplete:f}=this.options;l.set(fp(t,this.options,n)),f&&f(),this.cancel(),this.resolveFinishedPromise()},{animation:d,duration:i,times:a,type:s,ease:o,keyframes:t}}get duration(){const{resolved:t}=this;if(!t)return 0;const{duration:n}=t;return mi(n)}get time(){const{resolved:t}=this;if(!t)return 0;const{animation:n}=t;return mi(n.currentTime||0)}set time(t){const{resolved:n}=this;if(!n)return;const{animation:r}=n;r.currentTime=hi(t)}get speed(){const{resolved:t}=this;if(!t)return 1;const{animation:n}=t;return n.playbackRate}set speed(t){const{resolved:n}=this;if(!n)return;const{animation:r}=n;r.playbackRate=t}get state(){const{resolved:t}=this;if(!t)return"idle";const{animation:n}=t;return n.playState}get startTime(){const{resolved:t}=this;if(!t)return null;const{animation:n}=t;return n.startTime}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{const{resolved:n}=this;if(!n)return qt;const{animation:r}=n;q3(r,t)}return qt}play(){if(this.isStopped)return;const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.playState==="finished"&&this.updateFinishedPromise(),n.play()}pause(){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:t}=this;if(!t)return;const{animation:n,keyframes:r,duration:i,type:a,ease:o,times:s}=t;if(n.playState==="idle"||n.playState==="finished")return;if(this.time){const{motionValue:u,onUpdate:c,onComplete:d,element:f,...p}=this.options,g=new qy({...p,keyframes:r,duration:i,type:a,ease:o,times:s,isGenerator:!0}),w=hi(this.time);u.setWithVelocity(g.sample(w-vp).value,g.sample(w).value,vp)}const{onStop:l}=this.options;l&&l(),this.cancel()}complete(){const{resolved:t}=this;t&&t.animation.finish()}cancel(){const{resolved:t}=this;t&&t.animation.cancel()}static supports(t){const{motionValue:n,name:r,repeatDelay:i,repeatType:a,damping:o,type:s}=t;return EX()&&r&&$3.has(r)&&n&&n.owner&&n.owner.current instanceof HTMLElement&&!n.owner.getProps().onUpdate&&!i&&a!=="mirror"&&o!==0&&s!=="inertia"}}const CX=Gy(()=>window.ScrollTimeline!==void 0);class AX{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}then(t,n){return Promise.all(this.animations).then(t).catch(n)}getAll(t){return this.animations[0][t]}setAll(t,n){for(let r=0;r<this.animations.length;r++)this.animations[r][t]=n}attachTimeline(t,n){const r=this.animations.map(i=>CX()&&i.attachTimeline?i.attachTimeline(t):n(i));return()=>{r.forEach((i,a)=>{i&&i(),this.animations[a].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let n=0;n<this.animations.length;n++)t=Math.max(t,this.animations[n].duration);return t}runAll(t){this.animations.forEach(n=>n[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}function RX({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:a,repeatType:o,repeatDelay:s,from:l,elapsed:u,...c}){return!!Object.keys(c).length}const Xy=(e,t,n,r={},i,a)=>o=>{const s=Ty(r,e)||{},l=s.delay||r.delay||0;let{elapsed:u=0}=r;u=u-hi(l);let c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...s,delay:-u,onUpdate:f=>{t.set(f),s.onUpdate&&s.onUpdate(f)},onComplete:()=>{o(),s.onComplete&&s.onComplete()},name:e,motionValue:t,element:a?void 0:i};RX(s)||(c={...c,...KG(e,c)}),c.duration&&(c.duration=hi(c.duration)),c.repeatDelay&&(c.repeatDelay=hi(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let d=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(c.duration=0,c.delay===0&&(d=!0)),d&&!a&&t.get()!==void 0){const f=fp(c.keyframes,s);if(f!==void 0)return We.update(()=>{c.onUpdate(f),c.onComplete()}),new AX([])}return!a&&K3.supports(c)?new K3(c):new qy(c)},NX=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),OX=e=>vy(e)?e[e.length-1]||0:e;function Qy(e,t){e.indexOf(t)===-1&&e.push(t)}function Zy(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class Jy{constructor(){this.subscriptions=[]}add(t){return Qy(this.subscriptions,t),()=>Zy(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let a=0;a<i;a++){const o=this.subscriptions[a];o&&o(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const X3=30,PX=e=>!isNaN(parseFloat(e));class IX{constructor(t,n={}){this.version="11.11.9",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(r,i=!0)=>{const a=zr.now();this.updatedAt!==a&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),i&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=zr.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=PX(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new Jy);const r=this.events[t].add(n);return t==="change"?()=>{r(),We.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t,n=!0){!n||!this.passiveEffect?this.updateAndNotify(t,n):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=zr.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>X3)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,X3);return O3(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Zu(e,t){return new IX(e,t)}function DX(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Zu(n))}function LX(e,t){const n=dp(e,t);let{transitionEnd:r={},transition:i={},...a}=n||{};a={...a,...r};for(const o in a){const s=OX(a[o]);DX(e,o,s)}}const bp=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),Q3="data-"+bp("framerAppearId");function Z3(e){return e.props[Q3]}const Kt=e=>!!(e&&e.getVelocity);function MX(e){return!!(Kt(e)&&e.add)}function e1(e,t){if(!e.applyWillChange)return;const n=e.getValue("willChange");if(MX(n))return n.add(t)}function FX({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function J3(e,t,{delay:n=0,transitionOverride:r,type:i}={}){var a;let{transition:o=e.getDefaultTransition(),transitionEnd:s,...l}=t;r&&(o=r);const u=[],c=i&&e.animationState&&e.animationState.getState()[i];for(const d in l){const f=e.getValue(d,(a=e.latestValues[d])!==null&&a!==void 0?a:null),p=l[d];if(p===void 0||c&&FX(c,d))continue;const g={delay:n,...Ty(o||{},d)};let w=!1;if(window.MotionHandoffAnimation){const m=Z3(e);if(m){const v=window.MotionHandoffAnimation(m,d,We);v!==null&&(g.startTime=v,w=!0)}}e1(e,d),f.start(Xy(d,f,p,e.shouldReduceMotion&&pa.has(d)?{type:!1}:g,e,w));const x=f.animation;x&&u.push(x)}return s&&Promise.all(u).then(()=>{We.update(()=>{s&&LX(e,s)})}),u}function t1(e,t,n={}){var r;const i=dp(e,t,n.type==="exit"?(r=e.presenceContext)===null||r===void 0?void 0:r.custom:void 0);let{transition:a=e.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(a=n.transitionOverride);const o=i?()=>Promise.all(J3(e,i,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:f}=a;return BX(e,t,c+u,d,f,n)}:()=>Promise.resolve(),{when:l}=a;if(l){const[u,c]=l==="beforeChildren"?[o,s]:[s,o];return u().then(()=>c())}else return Promise.all([o(),s(n.delay)])}function BX(e,t,n=0,r=0,i=1,a){const o=[],s=(e.variantChildren.size-1)*r,l=i===1?(u=0)=>u*r:(u=0)=>s-u*r;return Array.from(e.variantChildren).sort(jX).forEach((u,c)=>{u.notify("AnimationStart",t),o.push(t1(u,t,{...a,delay:n+l(c)}).then(()=>u.notify("AnimationComplete",t)))}),Promise.all(o)}function jX(e,t){return e.sortNodePosition(t)}function zX(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(a=>t1(e,a,n));r=Promise.all(i)}else if(typeof t=="string")r=t1(e,t,n);else{const i=typeof t=="function"?dp(e,t,n.custom):t;r=Promise.all(J3(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const UX=Ey.length;function eR(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?eR(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<UX;n++){const r=Ey[n],i=e.props[r];($u(i)||i===!1)&&(t[r]=i)}return t}const HX=[...xy].reverse(),VX=xy.length;function $X(e){return t=>Promise.all(t.map(({animation:n,options:r})=>zX(e,n,r)))}function WX(e){let t=$X(e),n=tR(),r=!0;const i=l=>(u,c)=>{var d;const f=dp(e,c,l==="exit"?(d=e.presenceContext)===null||d===void 0?void 0:d.custom:void 0);if(f){const{transition:p,transitionEnd:g,...w}=f;u={...u,...w,...g}}return u};function a(l){t=l(e)}function o(l){const{props:u}=e,c=eR(e.parent)||{},d=[],f=new Set;let p={},g=1/0;for(let x=0;x<VX;x++){const m=HX[x],v=n[m],b=u[m]!==void 0?u[m]:c[m],T=$u(b),_=m===l?v.isActive:null;_===!1&&(g=x);let S=b===c[m]&&b!==u[m]&&T;if(S&&r&&e.manuallyAnimateOnMount&&(S=!1),v.protectedKeys={...p},!v.isActive&&_===null||!b&&!v.prevProp||Vu(b)||typeof b=="boolean")continue;const R=YX(v.prevProp,b);let P=R||m===l&&v.isActive&&!S&&T||x>g&&T,B=!1;const N=Array.isArray(b)?b:[b];let H=N.reduce(i(m),{});_===!1&&(H={});const{prevResolvedValues:U={}}=v,K={...U,...H},X=ne=>{P=!0,f.has(ne)&&(B=!0,f.delete(ne)),v.needsAnimating[ne]=!0;const L=e.getValue(ne);L&&(L.liveStyle=!1)};for(const ne in K){const L=H[ne],F=U[ne];if(p.hasOwnProperty(ne))continue;let C=!1;vy(L)&&vy(F)?C=!KA(L,F):C=L!==F,C?L!=null?X(ne):f.add(ne):L!==void 0&&f.has(ne)?X(ne):v.protectedKeys[ne]=!0}v.prevProp=b,v.prevResolvedValues=H,v.isActive&&(p={...p,...H}),r&&e.blockInitialAnimation&&(P=!1),P&&(!(S&&R)||B)&&d.push(...N.map(ne=>({animation:ne,options:{type:m}})))}if(f.size){const x={};f.forEach(m=>{const v=e.getBaseTarget(m),b=e.getValue(m);b&&(b.liveStyle=!0),x[m]=v??null}),d.push({animation:x})}let w=!!d.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(w=!1),r=!1,w?t(d):Promise.resolve()}function s(l,u){var c;if(n[l].isActive===u)return Promise.resolve();(c=e.variantChildren)===null||c===void 0||c.forEach(f=>{var p;return(p=f.animationState)===null||p===void 0?void 0:p.setActive(l,u)}),n[l].isActive=u;const d=o(l);for(const f in n)n[f].protectedKeys={};return d}return{animateChanges:o,setActive:s,setAnimateFunction:a,getState:()=>n,reset:()=>{n=tR(),r=!0}}}function YX(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!KA(t,e):!1}function ao(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function tR(){return{animate:ao(!0),whileInView:ao(),whileHover:ao(),whileTap:ao(),whileDrag:ao(),whileFocus:ao(),exit:ao()}}class ya{constructor(t){this.isMounted=!1,this.node=t}update(){}}class qX extends ya{constructor(t){super(t),t.animationState||(t.animationState=WX(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Vu(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)===null||t===void 0||t.call(this)}}let GX=0;class KX extends ya{constructor(){super(...arguments),this.id=GX++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const i=this.node.animationState.setActive("exit",!t);n&&!t&&i.then(()=>n(this.id))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}const XX={animation:{Feature:qX},exit:{Feature:KX}},nR=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function xp(e,t="page"){return{point:{x:e[`${t}X`],y:e[`${t}Y`]}}}const QX=e=>t=>nR(t)&&e(t,xp(t));function wi(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function yi(e,t,n,r){return wi(e,t,QX(n),r)}const rR=(e,t)=>Math.abs(e-t);function ZX(e,t){const n=rR(e.x,t.x),r=rR(e.y,t.y);return Math.sqrt(n**2+r**2)}class iR{constructor(t,n,{transformPagePoint:r,contextWindow:i,dragSnapToOrigin:a=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const d=r1(this.lastMoveEventInfo,this.history),f=this.startEvent!==null,p=ZX(d.offset,{x:0,y:0})>=3;if(!f&&!p)return;const{point:g}=d,{timestamp:w}=Lt;this.history.push({...g,timestamp:w});const{onStart:x,onMove:m}=this.handlers;f||(x&&x(this.lastMoveEvent,d),this.startEvent=this.lastMoveEvent),m&&m(this.lastMoveEvent,d)},this.handlePointerMove=(d,f)=>{this.lastMoveEvent=d,this.lastMoveEventInfo=n1(f,this.transformPagePoint),We.update(this.updatePoint,!0)},this.handlePointerUp=(d,f)=>{this.end();const{onEnd:p,onSessionEnd:g,resumeAnimation:w}=this.handlers;if(this.dragSnapToOrigin&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const x=r1(d.type==="pointercancel"?this.lastMoveEventInfo:n1(f,this.transformPagePoint),this.history);this.startEvent&&p&&p(d,x),g&&g(d,x)},!nR(t))return;this.dragSnapToOrigin=a,this.handlers=n,this.transformPagePoint=r,this.contextWindow=i||window;const o=xp(t),s=n1(o,this.transformPagePoint),{point:l}=s,{timestamp:u}=Lt;this.history=[{...l,timestamp:u}];const{onSessionStart:c}=n;c&&c(t,r1(s,this.history)),this.removeListeners=gi(yi(this.contextWindow,"pointermove",this.handlePointerMove),yi(this.contextWindow,"pointerup",this.handlePointerUp),yi(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),ha(this.updatePoint)}}function n1(e,t){return t?{point:t(e.point)}:e}function aR(e,t){return{x:e.x-t.x,y:e.y-t.y}}function r1({point:e},t){return{point:e,delta:aR(e,oR(t)),offset:aR(e,JX(t)),velocity:eQ(t,.1)}}function JX(e){return e[0]}function oR(e){return e[e.length-1]}function eQ(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=oR(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>hi(t)));)n--;if(!r)return{x:0,y:0};const a=mi(i.timestamp-r.timestamp);if(a===0)return{x:0,y:0};const o={x:(i.x-r.x)/a,y:(i.y-r.y)/a};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function sR(e){let t=null;return()=>{const n=()=>{t=null};return t===null?(t=e,n):!1}}const lR=sR("dragHorizontal"),uR=sR("dragVertical");function cR(e){let t=!1;if(e==="y")t=uR();else if(e==="x")t=lR();else{const n=lR(),r=uR();n&&r?t=()=>{n(),r()}:(n&&n(),r&&r())}return t}function dR(){const e=cR(!0);return e?(e(),!1):!0}function Cs(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}const fR=1e-4,tQ=1-fR,nQ=1+fR,pR=.01,rQ=0-pR,iQ=0+pR;function In(e){return e.max-e.min}function aQ(e,t,n){return Math.abs(e-t)<=n}function hR(e,t,n,r=.5){e.origin=r,e.originPoint=lt(t.min,t.max,e.origin),e.scale=In(n)/In(t),e.translate=lt(n.min,n.max,e.origin)-e.originPoint,(e.scale>=tQ&&e.scale<=nQ||isNaN(e.scale))&&(e.scale=1),(e.translate>=rQ&&e.translate<=iQ||isNaN(e.translate))&&(e.translate=0)}function Ju(e,t,n,r){hR(e.x,t.x,n.x,r?r.originX:void 0),hR(e.y,t.y,n.y,r?r.originY:void 0)}function mR(e,t,n){e.min=n.min+t.min,e.max=e.min+In(t)}function oQ(e,t,n){mR(e.x,t.x,n.x),mR(e.y,t.y,n.y)}function gR(e,t,n){e.min=t.min-n.min,e.max=e.min+In(t)}function ec(e,t,n){gR(e.x,t.x,n.x),gR(e.y,t.y,n.y)}function sQ(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?lt(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?lt(n,e,r.max):Math.min(e,n)),e}function wR(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function lQ(e,{top:t,left:n,bottom:r,right:i}){return{x:wR(e.x,n,i),y:wR(e.y,t,r)}}function yR(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function uQ(e,t){return{x:yR(e.x,t.x),y:yR(e.y,t.y)}}function cQ(e,t){let n=.5;const r=In(e),i=In(t);return i>r?n=ks(t.min,t.max-r,e.min):r>i&&(n=ks(e.min,e.max-i,t.min)),ma(0,1,n)}function dQ(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const i1=.35;function fQ(e=i1){return e===!1?e=0:e===!0&&(e=i1),{x:vR(e,"left","right"),y:vR(e,"top","bottom")}}function vR(e,t,n){return{min:bR(e,t),max:bR(e,n)}}function bR(e,t){return typeof e=="number"?e:e[t]||0}const xR=()=>({translate:0,scale:1,origin:0,originPoint:0}),As=()=>({x:xR(),y:xR()}),ER=()=>({min:0,max:0}),ht=()=>({x:ER(),y:ER()});function Kn(e){return[e("x"),e("y")]}function TR({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function pQ({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function hQ(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function a1(e){return e===void 0||e===1}function o1({scale:e,scaleX:t,scaleY:n}){return!a1(e)||!a1(t)||!a1(n)}function oo(e){return o1(e)||_R(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function _R(e){return SR(e.x)||SR(e.y)}function SR(e){return e&&e!=="0%"}function Ep(e,t,n){const r=e-n,i=t*r;return n+i}function kR(e,t,n,r,i){return i!==void 0&&(e=Ep(e,i,r)),Ep(e,n,r)+t}function s1(e,t=0,n=1,r,i){e.min=kR(e.min,t,n,r,i),e.max=kR(e.max,t,n,r,i)}function CR(e,{x:t,y:n}){s1(e.x,t.translate,t.scale,t.originPoint),s1(e.y,n.translate,n.scale,n.originPoint)}const AR=.999999999999,RR=1.0000000000001;function mQ(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let a,o;for(let s=0;s<i;s++){a=n[s],o=a.projectionDelta;const{visualElement:l}=a.options;l&&l.props.style&&l.props.style.display==="contents"||(r&&a.options.layoutScroll&&a.scroll&&a!==a.root&&Ns(e,{x:-a.scroll.offset.x,y:-a.scroll.offset.y}),o&&(t.x*=o.x.scale,t.y*=o.y.scale,CR(e,o)),r&&oo(a.latestValues)&&Ns(e,a.latestValues))}t.x<RR&&t.x>AR&&(t.x=1),t.y<RR&&t.y>AR&&(t.y=1)}function Rs(e,t){e.min=e.min+t,e.max=e.max+t}function NR(e,t,n,r,i=.5){const a=lt(e.min,e.max,i);s1(e,t,n,a,r)}function Ns(e,t){NR(e.x,t.x,t.scaleX,t.scale,t.originX),NR(e.y,t.y,t.scaleY,t.scale,t.originY)}function OR(e,t){return TR(hQ(e.getBoundingClientRect(),t))}function gQ(e,t,n){const r=OR(e,n),{scroll:i}=t;return i&&(Rs(r.x,i.offset.x),Rs(r.y,i.offset.y)),r}const PR=({current:e})=>e?e.ownerDocument.defaultView:null,wQ=new WeakMap;class yQ{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ht(),this.visualElement=t}start(t,{snapToCursor:n=!1}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const i=c=>{const{dragSnapToOrigin:d}=this.getProps();d?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(xp(c,"page").point)},a=(c,d)=>{const{drag:f,dragPropagation:p,onDragStart:g}=this.getProps();if(f&&!p&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=cR(f),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Kn(x=>{let m=this.getAxisMotionValue(x).get()||0;if(jr.test(m)){const{projection:v}=this.visualElement;if(v&&v.layout){const b=v.layout.layoutBox[x];b&&(m=In(b)*(parseFloat(m)/100))}}this.originPoint[x]=m}),g&&We.postRender(()=>g(c,d)),e1(this.visualElement,"transform");const{animationState:w}=this.visualElement;w&&w.setActive("whileDrag",!0)},o=(c,d)=>{const{dragPropagation:f,dragDirectionLock:p,onDirectionLock:g,onDrag:w}=this.getProps();if(!f&&!this.openGlobalLock)return;const{offset:x}=d;if(p&&this.currentDirection===null){this.currentDirection=vQ(x),this.currentDirection!==null&&g&&g(this.currentDirection);return}this.updateAxis("x",d.point,x),this.updateAxis("y",d.point,x),this.visualElement.render(),w&&w(c,d)},s=(c,d)=>this.stop(c,d),l=()=>Kn(c=>{var d;return this.getAnimationState(c)==="paused"&&((d=this.getAxisMotionValue(c).animation)===null||d===void 0?void 0:d.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new iR(t,{onSessionStart:i,onStart:a,onMove:o,onSessionEnd:s,resumeAnimation:l},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,contextWindow:PR(this.visualElement)})}stop(t,n){const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:i}=n;this.startAnimation(i);const{onDragEnd:a}=this.getProps();a&&We.postRender(()=>a(t,n))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!Tp(t,i,this.currentDirection))return;const a=this.getAxisMotionValue(t);let o=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(o=sQ(o,this.constraints[t],this.elastic[t])),a.set(o)}resolveConstraints(){var t;const{dragConstraints:n,dragElastic:r}=this.getProps(),i=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,a=this.constraints;n&&Cs(n)?this.constraints||(this.constraints=this.resolveRefConstraints()):n&&i?this.constraints=lQ(i.layoutBox,n):this.constraints=!1,this.elastic=fQ(r),a!==this.constraints&&i&&this.constraints&&!this.hasMutatedConstraints&&Kn(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=dQ(i.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Cs(t))return!1;const r=t.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const a=gQ(r,i.root,this.visualElement.getTransformPagePoint());let o=uQ(i.layout.layoutBox,a);if(n){const s=n(pQ(o));this.hasMutatedConstraints=!!s,s&&(o=TR(s))}return o}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:a,dragSnapToOrigin:o,onDragTransitionEnd:s}=this.getProps(),l=this.constraints||{},u=Kn(c=>{if(!Tp(c,n,this.currentDirection))return;let d=l&&l[c]||{};o&&(d={min:0,max:0});const f=i?200:1e6,p=i?40:1e7,g={type:"inertia",velocity:r?t[c]:0,bounceStiffness:f,bounceDamping:p,timeConstant:750,restDelta:1,restSpeed:10,...a,...d};return this.startAxisValueAnimation(c,g)});return Promise.all(u).then(s)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return e1(this.visualElement,t),r.start(Xy(t,r,0,n,this.visualElement,!1))}stopAnimation(){Kn(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Kn(t=>{var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Kn(n=>{const{drag:r}=this.getProps();if(!Tp(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,a=this.getAxisMotionValue(n);if(i&&i.layout){const{min:o,max:s}=i.layout.layoutBox[n];a.set(t[n]-lt(o,s,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Cs(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Kn(o=>{const s=this.getAxisMotionValue(o);if(s&&this.constraints!==!1){const l=s.get();i[o]=cQ({min:l,max:l},this.constraints[o])}});const{transformTemplate:a}=this.visualElement.getProps();this.visualElement.current.style.transform=a?a({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Kn(o=>{if(!Tp(o,t,null))return;const s=this.getAxisMotionValue(o),{min:l,max:u}=this.constraints[o];s.set(lt(l,u,i[o]))})}addListeners(){if(!this.visualElement.current)return;wQ.set(this.visualElement,this);const t=this.visualElement.current,n=yi(t,"pointerdown",l=>{const{drag:u,dragListener:c=!0}=this.getProps();u&&c&&this.start(l)}),r=()=>{const{dragConstraints:l}=this.getProps();Cs(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,a=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),We.read(r);const o=wi(window,"resize",()=>this.scalePositionWithinConstraints()),s=i.addEventListener("didUpdate",({delta:l,hasLayoutChanged:u})=>{this.isDragging&&u&&(Kn(c=>{const d=this.getAxisMotionValue(c);d&&(this.originPoint[c]+=l[c].translate,d.set(d.get()+l[c].translate))}),this.visualElement.render())});return()=>{o(),n(),a(),s&&s()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:a=!1,dragElastic:o=i1,dragMomentum:s=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:a,dragElastic:o,dragMomentum:s}}}function Tp(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function vQ(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class bQ extends ya{constructor(t){super(t),this.removeGroupControls=qt,this.removeListeners=qt,this.controls=new yQ(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||qt}unmount(){this.removeGroupControls(),this.removeListeners()}}const IR=e=>(t,n)=>{e&&We.postRender(()=>e(t,n))};class xQ extends ya{constructor(){super(...arguments),this.removePointerDownListener=qt}onPointerDown(t){this.session=new iR(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:PR(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:IR(t),onStart:IR(n),onMove:r,onEnd:(a,o)=>{delete this.session,i&&We.postRender(()=>i(a,o))}}}mount(){this.removePointerDownListener=yi(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const _p=y.createContext(null);function EQ(){const e=y.useContext(_p);if(e===null)return[!0,null];const{isPresent:t,onExitComplete:n,register:r}=e,i=y.useId();y.useEffect(()=>r(i),[]);const a=y.useCallback(()=>n&&n(i),[i,n]);return!t&&n?[!1,a]:[!0]}const l1=y.createContext({}),DR=y.createContext({}),Sp={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function LR(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const tc={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(he.test(e))e=parseFloat(e);else return e;const n=LR(e,t.target.x),r=LR(e,t.target.y);return`${n}% ${r}%`}},TQ={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=wa.parse(e);if(i.length>5)return r;const a=wa.createTransformer(e),o=typeof i[0]!="number"?1:0,s=n.x.scale*t.x,l=n.y.scale*t.y;i[0+o]/=s,i[1+o]/=l;const u=lt(s,l,.5);return typeof i[2+o]=="number"&&(i[2+o]/=u),typeof i[3+o]=="number"&&(i[3+o]/=u),a(i)}},kp={};function _Q(e){Object.assign(kp,e)}const{schedule:u1,cancel:ole}=QA(queueMicrotask,!1);class SQ extends y.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:a}=t;_Q(kQ),a&&(n.group&&n.group.add(a),r&&r.register&&i&&r.register(a),a.root.didUpdate(),a.addEventListener("animationComplete",()=>{this.safeToRemove()}),a.setOptions({...a.options,onExitComplete:()=>this.safeToRemove()})),Sp.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:a}=this.props,o=r.projection;return o&&(o.isPresent=a,i||t.layoutDependency!==n||n===void 0?o.willUpdate():this.safeToRemove(),t.isPresent!==a&&(a?o.promote():o.relegate()||We.postRender(()=>{const s=o.getStack();(!s||!s.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),u1.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function MR(e){const[t,n]=EQ(),r=y.useContext(l1);return E.jsx(SQ,{...e,layoutGroup:r,switchLayoutGroup:y.useContext(DR),isPresent:t,safeToRemove:n})}const kQ={borderRadius:{...tc,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:tc,borderTopRightRadius:tc,borderBottomLeftRadius:tc,borderBottomRightRadius:tc,boxShadow:TQ},FR=["TopLeft","TopRight","BottomLeft","BottomRight"],CQ=FR.length,BR=e=>typeof e=="string"?parseFloat(e):e,jR=e=>typeof e=="number"||he.test(e);function AQ(e,t,n,r,i,a){i?(e.opacity=lt(0,n.opacity!==void 0?n.opacity:1,RQ(r)),e.opacityExit=lt(t.opacity!==void 0?t.opacity:1,0,NQ(r))):a&&(e.opacity=lt(t.opacity!==void 0?t.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let o=0;o<CQ;o++){const s=`border${FR[o]}Radius`;let l=zR(t,s),u=zR(n,s);if(l===void 0&&u===void 0)continue;l||(l=0),u||(u=0),l===0||u===0||jR(l)===jR(u)?(e[s]=Math.max(lt(BR(l),BR(u),r),0),(jr.test(u)||jr.test(l))&&(e[s]+="%")):e[s]=u}(t.rotate||n.rotate)&&(e.rotate=lt(t.rotate||0,n.rotate||0,r))}function zR(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const RQ=UR(0,.5,i3),NQ=UR(.5,.95,qt);function UR(e,t,n){return r=>r<e?0:r>t?1:n(ks(e,t,r))}function HR(e,t){e.min=t.min,e.max=t.max}function Xn(e,t){HR(e.x,t.x),HR(e.y,t.y)}function VR(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function $R(e,t,n,r,i){return e-=t,e=Ep(e,1/n,r),i!==void 0&&(e=Ep(e,1/i,r)),e}function OQ(e,t=0,n=1,r=.5,i,a=e,o=e){if(jr.test(t)&&(t=parseFloat(t),t=lt(o.min,o.max,t/100)-o.min),typeof t!="number")return;let s=lt(a.min,a.max,r);e===a&&(s-=t),e.min=$R(e.min,t,n,s,i),e.max=$R(e.max,t,n,s,i)}function WR(e,t,[n,r,i],a,o){OQ(e,t[n],t[r],t[i],t.scale,a,o)}const PQ=["x","scaleX","originX"],IQ=["y","scaleY","originY"];function YR(e,t,n,r){WR(e.x,t,PQ,n?n.x:void 0,r?r.x:void 0),WR(e.y,t,IQ,n?n.y:void 0,r?r.y:void 0)}function qR(e){return e.translate===0&&e.scale===1}function GR(e){return qR(e.x)&&qR(e.y)}function KR(e,t){return e.min===t.min&&e.max===t.max}function DQ(e,t){return KR(e.x,t.x)&&KR(e.y,t.y)}function XR(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function QR(e,t){return XR(e.x,t.x)&&XR(e.y,t.y)}function ZR(e){return In(e.x)/In(e.y)}function JR(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class LQ{constructor(){this.members=[]}add(t){Qy(this.members,t),t.scheduleRender()}remove(t){if(Zy(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const a=this.members[i];if(a.isPresent!==!1){r=a;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:i}=t.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function MQ(e,t,n){let r="";const i=e.x.translate/t.x,a=e.y.translate/t.y,o=(n==null?void 0:n.z)||0;if((i||a||o)&&(r=`translate3d(${i}px, ${a}px, ${o}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:c,rotateX:d,rotateY:f,skewX:p,skewY:g}=n;u&&(r=`perspective(${u}px) ${r}`),c&&(r+=`rotate(${c}deg) `),d&&(r+=`rotateX(${d}deg) `),f&&(r+=`rotateY(${f}deg) `),p&&(r+=`skewX(${p}deg) `),g&&(r+=`skewY(${g}deg) `)}const s=e.x.scale*t.x,l=e.y.scale*t.y;return(s!==1||l!==1)&&(r+=`scale(${s}, ${l})`),r||"none"}const FQ=(e,t)=>e.depth-t.depth;class BQ{constructor(){this.children=[],this.isDirty=!1}add(t){Qy(this.children,t),this.isDirty=!0}remove(t){Zy(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(FQ),this.isDirty=!1,this.children.forEach(t)}}function Cp(e){const t=Kt(e)?e.get():e;return NX(t)?t.toValue():t}function jQ(e,t){const n=zr.now(),r=({timestamp:i})=>{const a=i-n;a>=t&&(ha(r),e(a-t))};return We.read(r,!0),()=>ha(r)}function zQ(e){return e instanceof SVGElement&&e.tagName!=="svg"}function UQ(e,t,n){const r=Kt(e)?e:Zu(e);return r.start(Xy("",r,t,n)),r.animation}const so={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},nc=typeof window<"u"&&window.MotionDebug!==void 0,c1=["","X","Y","Z"],HQ={visibility:"hidden"},eN=1e3;let VQ=0;function d1(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function tN(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=Z3(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:a}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",We,!(i||a))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&tN(r)}function nN({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(o={},s=t==null?void 0:t()){this.id=VQ++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,nc&&(so.totalNodes=so.resolvedTargetDeltas=so.recalculatedProjection=0),this.nodes.forEach(YQ),this.nodes.forEach(QQ),this.nodes.forEach(ZQ),this.nodes.forEach(qQ),nc&&window.MotionDebug.record(so)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=s?s.root||s:this,this.path=s?[...s.path,s]:[],this.parent=s,this.depth=s?s.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new BQ)}addEventListener(o,s){return this.eventHandlers.has(o)||this.eventHandlers.set(o,new Jy),this.eventHandlers.get(o).add(s)}notifyListeners(o,...s){const l=this.eventHandlers.get(o);l&&l.notify(...s)}hasListeners(o){return this.eventHandlers.has(o)}mount(o,s=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=zQ(o),this.instance=o;const{layoutId:l,layout:u,visualElement:c}=this.options;if(c&&!c.current&&c.mount(o),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),s&&(u||l)&&(this.isLayoutDirty=!0),e){let d;const f=()=>this.root.updateBlockedByResize=!1;e(o,()=>{this.root.updateBlockedByResize=!0,d&&d(),d=jQ(f,250),Sp.hasAnimatedSinceResize&&(Sp.hasAnimatedSinceResize=!1,this.nodes.forEach(iN))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&c&&(l||u)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:f,hasRelativeTargetChanged:p,layout:g})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const w=this.options.transition||c.getDefaultTransition()||rZ,{onLayoutAnimationStart:x,onLayoutAnimationComplete:m}=c.getProps(),v=!this.targetLayout||!QR(this.targetLayout,g)||p,b=!f&&p;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||b||f&&(v||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(d,b);const T={...Ty(w,"layout"),onPlay:x,onComplete:m};(c.shouldReduceMotion||this.options.layoutRoot)&&(T.delay=0,T.type=!1),this.startAnimation(T)}else f||iN(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=g})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,ha(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(JQ),this.animationId++)}getTransformTemplate(){const{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&tN(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c<this.path.length;c++){const d=this.path[c];d.shouldResetTransform=!0,d.updateScroll("snapshot"),d.options.layoutRoot&&d.willUpdate(!1)}const{layoutId:s,layout:l}=this.options;if(s===void 0&&!l)return;const u=this.getTransformTemplate();this.prevTransformTemplateValue=u?u(this.latestValues,""):void 0,this.updateSnapshot(),o&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(rN);return}this.isUpdating||this.nodes.forEach(KQ),this.isUpdating=!1,this.nodes.forEach(XQ),this.nodes.forEach($Q),this.nodes.forEach(WQ),this.clearAllSnapshots();const s=zr.now();Lt.delta=ma(0,1e3/60,s-Lt.timestamp),Lt.timestamp=s,Lt.isProcessing=!0,_y.update.process(Lt),_y.preRender.process(Lt),_y.render.process(Lt),Lt.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,u1.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(GQ),this.sharedNodes.forEach(eZ)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,We.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){We.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const o=this.layout;this.layout=this.measure(!1),this.layoutCorrected=ht(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:s}=this.options;s&&s.notify("LayoutMeasure",this.layout.layoutBox,o?o.layoutBox:void 0)}updateScroll(o="measure"){let s=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===o&&(s=!1),s){const l=r(this.instance);this.scroll={animationId:this.root.animationId,phase:o,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!i)return;const o=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,s=this.projectionDelta&&!GR(this.projectionDelta),l=this.getTransformTemplate(),u=l?l(this.latestValues,""):void 0,c=u!==this.prevTransformTemplateValue;o&&(s||oo(this.latestValues)||c)&&(i(this.instance,u),this.shouldResetTransform=!1,this.scheduleRender())}measure(o=!0){const s=this.measurePageBox();let l=this.removeElementScroll(s);return o&&(l=this.removeTransform(l)),iZ(l),{animationId:this.root.animationId,measuredBox:s,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var o;const{visualElement:s}=this.options;if(!s)return ht();const l=s.measureViewportBox();if(!(((o=this.scroll)===null||o===void 0?void 0:o.wasRoot)||this.path.some(aZ))){const{scroll:c}=this.root;c&&(Rs(l.x,c.offset.x),Rs(l.y,c.offset.y))}return l}removeElementScroll(o){var s;const l=ht();if(Xn(l,o),!((s=this.scroll)===null||s===void 0)&&s.wasRoot)return l;for(let u=0;u<this.path.length;u++){const c=this.path[u],{scroll:d,options:f}=c;c!==this.root&&d&&f.layoutScroll&&(d.wasRoot&&Xn(l,o),Rs(l.x,d.offset.x),Rs(l.y,d.offset.y))}return l}applyTransform(o,s=!1){const l=ht();Xn(l,o);for(let u=0;u<this.path.length;u++){const c=this.path[u];!s&&c.options.layoutScroll&&c.scroll&&c!==c.root&&Ns(l,{x:-c.scroll.offset.x,y:-c.scroll.offset.y}),oo(c.latestValues)&&Ns(l,c.latestValues)}return oo(this.latestValues)&&Ns(l,this.latestValues),l}removeTransform(o){const s=ht();Xn(s,o);for(let l=0;l<this.path.length;l++){const u=this.path[l];if(!u.instance||!oo(u.latestValues))continue;o1(u.latestValues)&&u.updateSnapshot();const c=ht(),d=u.measurePageBox();Xn(c,d),YR(s,u.latestValues,u.snapshot?u.snapshot.layoutBox:void 0,c)}return oo(this.latestValues)&&YR(s,this.latestValues),s}setTargetDelta(o){this.targetDelta=o,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(o){this.options={...this.options,...o,crossfade:o.crossfade!==void 0?o.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Lt.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(o=!1){var s;const l=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=l.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=l.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=l.isSharedProjectionDirty);const u=!!this.resumingFrom||this!==l;if(!(o||u&&this.isSharedProjectionDirty||this.isProjectionDirty||!((s=this.parent)===null||s===void 0)&&s.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:d,layoutId:f}=this.options;if(!(!this.layout||!(d||f))){if(this.resolvedRelativeTargetAt=Lt.timestamp,!this.targetDelta&&!this.relativeTarget){const p=this.getClosestProjectingParent();p&&p.layout&&this.animationProgress!==1?(this.relativeParent=p,this.forceRelativeParentToResolveTarget(),this.relativeTarget=ht(),this.relativeTargetOrigin=ht(),ec(this.relativeTargetOrigin,this.layout.layoutBox,p.layout.layoutBox),Xn(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=ht(),this.targetWithTransforms=ht()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),oQ(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Xn(this.target,this.layout.layoutBox),CR(this.target,this.targetDelta)):Xn(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const p=this.getClosestProjectingParent();p&&!!p.resumingFrom==!!this.resumingFrom&&!p.options.layoutScroll&&p.target&&this.animationProgress!==1?(this.relativeParent=p,this.forceRelativeParentToResolveTarget(),this.relativeTarget=ht(),this.relativeTargetOrigin=ht(),ec(this.relativeTargetOrigin,this.target,p.target),Xn(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}nc&&so.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||o1(this.parent.latestValues)||_R(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var o;const s=this.getLead(),l=!!this.resumingFrom||this!==s;let u=!0;if((this.isProjectionDirty||!((o=this.parent)===null||o===void 0)&&o.isProjectionDirty)&&(u=!1),l&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(u=!1),this.resolvedRelativeTargetAt===Lt.timestamp&&(u=!1),u)return;const{layout:c,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(c||d))return;Xn(this.layoutCorrected,this.layout.layoutBox);const f=this.treeScale.x,p=this.treeScale.y;mQ(this.layoutCorrected,this.treeScale,this.path,l),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=ht());const{target:g}=s;if(!g){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(VR(this.prevProjectionDelta.x,this.projectionDelta.x),VR(this.prevProjectionDelta.y,this.projectionDelta.y)),Ju(this.projectionDelta,this.layoutCorrected,g,this.latestValues),(this.treeScale.x!==f||this.treeScale.y!==p||!JR(this.projectionDelta.x,this.prevProjectionDelta.x)||!JR(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",g)),nc&&so.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(o=!0){var s;if((s=this.options.visualElement)===null||s===void 0||s.scheduleRender(),o){const l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=As(),this.projectionDelta=As(),this.projectionDeltaWithTransform=As()}setAnimationOrigin(o,s=!1){const l=this.snapshot,u=l?l.latestValues:{},c={...this.latestValues},d=As();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!s;const f=ht(),p=l?l.source:void 0,g=this.layout?this.layout.source:void 0,w=p!==g,x=this.getStack(),m=!x||x.members.length<=1,v=!!(w&&!m&&this.options.crossfade===!0&&!this.path.some(nZ));this.animationProgress=0;let b;this.mixTargetDelta=T=>{const _=T/1e3;aN(d.x,o.x,_),aN(d.y,o.y,_),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(ec(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),tZ(this.relativeTarget,this.relativeTargetOrigin,f,_),b&&DQ(this.relativeTarget,b)&&(this.isProjectionDirty=!1),b||(b=ht()),Xn(b,this.relativeTarget)),w&&(this.animationValues=c,AQ(c,u,this.latestValues,_,v,m)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=_},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(ha(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=We.update(()=>{Sp.hasAnimatedSinceResize=!0,this.currentAnimation=UQ(0,eN,{...o,onUpdate:s=>{this.mixTargetDelta(s),o.onUpdate&&o.onUpdate(s)},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(eN),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const o=this.getLead();let{targetWithTransforms:s,target:l,layout:u,latestValues:c}=o;if(!(!s||!l||!u)){if(this!==o&&this.layout&&u&&cN(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||ht();const d=In(this.layout.layoutBox.x);l.x.min=o.target.x.min,l.x.max=l.x.min+d;const f=In(this.layout.layoutBox.y);l.y.min=o.target.y.min,l.y.max=l.y.min+f}Xn(s,l),Ns(s,c),Ju(this.projectionDeltaWithTransform,this.layoutCorrected,s,c)}}registerSharedNode(o,s){this.sharedNodes.has(o)||this.sharedNodes.set(o,new LQ),this.sharedNodes.get(o).add(s);const u=s.options.initialPromotionConfig;s.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(s):void 0})}isLead(){const o=this.getStack();return o?o.lead===this:!0}getLead(){var o;const{layoutId:s}=this.options;return s?((o=this.getStack())===null||o===void 0?void 0:o.lead)||this:this}getPrevLead(){var o;const{layoutId:s}=this.options;return s?(o=this.getStack())===null||o===void 0?void 0:o.prevLead:void 0}getStack(){const{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:s,preserveFollowOpacity:l}={}){const u=this.getStack();u&&u.promote(this,l),o&&(this.projectionDelta=void 0,this.needsReset=!0),s&&this.setOptions({transition:s})}relegate(){const o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){const{visualElement:o}=this.options;if(!o)return;let s=!1;const{latestValues:l}=o;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(s=!0),!s)return;const u={};l.z&&d1("z",o,u,this.animationValues);for(let c=0;c<c1.length;c++)d1(`rotate${c1[c]}`,o,u,this.animationValues),d1(`skew${c1[c]}`,o,u,this.animationValues);o.render();for(const c in u)o.setStaticValue(c,u[c]),this.animationValues&&(this.animationValues[c]=u[c]);o.scheduleRender()}getProjectionStyles(o){var s,l;if(!this.instance||this.isSVG)return;if(!this.isVisible)return HQ;const u={visibility:""},c=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,u.opacity="",u.pointerEvents=Cp(o==null?void 0:o.pointerEvents)||"",u.transform=c?c(this.latestValues,""):"none",u;const d=this.getLead();if(!this.projectionDelta||!this.layout||!d.target){const w={};return this.options.layoutId&&(w.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,w.pointerEvents=Cp(o==null?void 0:o.pointerEvents)||""),this.hasProjected&&!oo(this.latestValues)&&(w.transform=c?c({},""):"none",this.hasProjected=!1),w}const f=d.animationValues||d.latestValues;this.applyTransformsToTarget(),u.transform=MQ(this.projectionDeltaWithTransform,this.treeScale,f),c&&(u.transform=c(f,u.transform));const{x:p,y:g}=this.projectionDelta;u.transformOrigin=`${p.origin*100}% ${g.origin*100}% 0`,d.animationValues?u.opacity=d===this?(l=(s=f.opacity)!==null&&s!==void 0?s:this.latestValues.opacity)!==null&&l!==void 0?l:1:this.preserveOpacity?this.latestValues.opacity:f.opacityExit:u.opacity=d===this?f.opacity!==void 0?f.opacity:"":f.opacityExit!==void 0?f.opacityExit:0;for(const w in kp){if(f[w]===void 0)continue;const{correct:x,applyTo:m}=kp[w],v=u.transform==="none"?f[w]:x(f[w],d);if(m){const b=m.length;for(let T=0;T<b;T++)u[m[T]]=v}else u[w]=v}return this.options.layoutId&&(u.pointerEvents=d===this?Cp(o==null?void 0:o.pointerEvents)||"":"none"),u}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(o=>{var s;return(s=o.currentAnimation)===null||s===void 0?void 0:s.stop()}),this.root.nodes.forEach(rN),this.root.sharedNodes.clear()}}}function $Q(e){e.updateLayout()}function WQ(e){var t;const n=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:i}=e.layout,{animationType:a}=e.options,o=n.source!==e.layout.source;a==="size"?Kn(d=>{const f=o?n.measuredBox[d]:n.layoutBox[d],p=In(f);f.min=r[d].min,f.max=f.min+p}):cN(a,n.layoutBox,r)&&Kn(d=>{const f=o?n.measuredBox[d]:n.layoutBox[d],p=In(r[d]);f.max=f.min+p,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+p)});const s=As();Ju(s,r,n.layoutBox);const l=As();o?Ju(l,e.applyTransform(i,!0),n.measuredBox):Ju(l,r,n.layoutBox);const u=!GR(s);let c=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:f,layout:p}=d;if(f&&p){const g=ht();ec(g,n.layoutBox,f.layoutBox);const w=ht();ec(w,r,p.layoutBox),QR(g,w)||(c=!0),d.options.layoutRoot&&(e.relativeTarget=w,e.relativeTargetOrigin=g,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:l,layoutDelta:s,hasLayoutChanged:u,hasRelativeTargetChanged:c})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function YQ(e){nc&&so.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function qQ(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function GQ(e){e.clearSnapshot()}function rN(e){e.clearMeasurements()}function KQ(e){e.isLayoutDirty=!1}function XQ(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function iN(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function QQ(e){e.resolveTargetDelta()}function ZQ(e){e.calcProjection()}function JQ(e){e.resetSkewAndRotation()}function eZ(e){e.removeLeadSnapshot()}function aN(e,t,n){e.translate=lt(t.translate,0,n),e.scale=lt(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function oN(e,t,n,r){e.min=lt(t.min,n.min,r),e.max=lt(t.max,n.max,r)}function tZ(e,t,n,r){oN(e.x,t.x,n.x,r),oN(e.y,t.y,n.y,r)}function nZ(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const rZ={duration:.45,ease:[.4,0,.1,1]},sN=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),lN=sN("applewebkit/")&&!sN("chrome/")?Math.round:qt;function uN(e){e.min=lN(e.min),e.max=lN(e.max)}function iZ(e){uN(e.x),uN(e.y)}function cN(e,t,n){return e==="position"||e==="preserve-aspect"&&!aQ(ZR(t),ZR(n),.2)}function aZ(e){var t;return e!==e.root&&((t=e.scroll)===null||t===void 0?void 0:t.wasRoot)}const oZ=nN({attachResizeListener:(e,t)=>wi(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),f1={current:void 0},dN=nN({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!f1.current){const e=new oZ({});e.mount(window),e.setOptions({layoutScroll:!0}),f1.current=e}return f1.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),sZ={pan:{Feature:xQ},drag:{Feature:bQ,ProjectionNode:dN,MeasureLayout:MR}};function fN(e,t){const n=t?"pointerenter":"pointerleave",r=t?"onHoverStart":"onHoverEnd",i=(a,o)=>{if(a.pointerType==="touch"||dR())return;const s=e.getProps();e.animationState&&s.whileHover&&e.animationState.setActive("whileHover",t);const l=s[r];l&&We.postRender(()=>l(a,o))};return yi(e.current,n,i,{passive:!e.getProps()[r]})}class lZ extends ya{mount(){this.unmount=gi(fN(this.node,!0),fN(this.node,!1))}unmount(){}}class uZ extends ya{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=gi(wi(this.node.current,"focus",()=>this.onFocus()),wi(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}const pN=(e,t)=>t?e===t?!0:pN(e,t.parentElement):!1;function p1(e,t){if(!t)return;const n=new PointerEvent("pointer"+e);t(n,xp(n))}class cZ extends ya{constructor(){super(...arguments),this.removeStartListeners=qt,this.removeEndListeners=qt,this.removeAccessibleListeners=qt,this.startPointerPress=(t,n)=>{if(this.isPressing)return;this.removeEndListeners();const r=this.node.getProps(),a=yi(window,"pointerup",(s,l)=>{if(!this.checkPressEnd())return;const{onTap:u,onTapCancel:c,globalTapTarget:d}=this.node.getProps(),f=!d&&!pN(this.node.current,s.target)?c:u;f&&We.update(()=>f(s,l))},{passive:!(r.onTap||r.onPointerUp)}),o=yi(window,"pointercancel",(s,l)=>this.cancelPress(s,l),{passive:!(r.onTapCancel||r.onPointerCancel)});this.removeEndListeners=gi(a,o),this.startPress(t,n)},this.startAccessiblePress=()=>{const t=a=>{if(a.key!=="Enter"||this.isPressing)return;const o=s=>{s.key!=="Enter"||!this.checkPressEnd()||p1("up",(l,u)=>{const{onTap:c}=this.node.getProps();c&&We.postRender(()=>c(l,u))})};this.removeEndListeners(),this.removeEndListeners=wi(this.node.current,"keyup",o),p1("down",(s,l)=>{this.startPress(s,l)})},n=wi(this.node.current,"keydown",t),r=()=>{this.isPressing&&p1("cancel",(a,o)=>this.cancelPress(a,o))},i=wi(this.node.current,"blur",r);this.removeAccessibleListeners=gi(n,i)}}startPress(t,n){this.isPressing=!0;const{onTapStart:r,whileTap:i}=this.node.getProps();i&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),r&&We.postRender(()=>r(t,n))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!dR()}cancelPress(t,n){if(!this.checkPressEnd())return;const{onTapCancel:r}=this.node.getProps();r&&We.postRender(()=>r(t,n))}mount(){const t=this.node.getProps(),n=yi(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),r=wi(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=gi(n,r)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}const h1=new WeakMap,m1=new WeakMap,dZ=e=>{const t=h1.get(e.target);t&&t(e)},fZ=e=>{e.forEach(dZ)};function pZ({root:e,...t}){const n=e||document;m1.has(n)||m1.set(n,{});const r=m1.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(fZ,{root:e,...t})),r[i]}function hZ(e,t,n){const r=pZ(t);return h1.set(e,n),r.observe(e),()=>{h1.delete(e),r.unobserve(e)}}const mZ={some:0,all:1};class gZ extends ya{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:a}=t,o={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:mZ[i]},s=l=>{const{isIntersecting:u}=l;if(this.isInView===u||(this.isInView=u,a&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:c,onViewportLeave:d}=this.node.getProps(),f=u?c:d;f&&f(l)};return hZ(this.node.current,o,s)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(wZ(t,n))&&this.startObserver()}unmount(){}}function wZ({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const yZ={inView:{Feature:gZ},tap:{Feature:cZ},focus:{Feature:uZ},hover:{Feature:lZ}},vZ={layout:{ProjectionNode:dN,MeasureLayout:MR}},g1=y.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),Ap=y.createContext({}),w1=typeof window<"u",hN=w1?y.useLayoutEffect:y.useEffect,mN=y.createContext({strict:!1});function bZ(e,t,n,r,i){var a,o;const{visualElement:s}=y.useContext(Ap),l=y.useContext(mN),u=y.useContext(_p),c=y.useContext(g1).reducedMotion,d=y.useRef();r=r||l.renderer,!d.current&&r&&(d.current=r(e,{visualState:t,parent:s,props:n,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:c}));const f=d.current,p=y.useContext(DR);f&&!f.projection&&i&&(f.type==="html"||f.type==="svg")&&xZ(d.current,n,i,p),y.useInsertionEffect(()=>{f&&f.update(n,u)});const g=n[Q3],w=y.useRef(!!g&&!(!((a=window.MotionHandoffIsComplete)===null||a===void 0)&&a.call(window,g))&&((o=window.MotionHasOptimisedAnimation)===null||o===void 0?void 0:o.call(window,g)));return hN(()=>{f&&(window.MotionIsMounted=!0,f.updateFeatures(),u1.render(f.render),w.current&&f.animationState&&f.animationState.animateChanges())}),y.useEffect(()=>{f&&(!w.current&&f.animationState&&f.animationState.animateChanges(),w.current&&(queueMicrotask(()=>{var x;(x=window.MotionHandoffMarkAsComplete)===null||x===void 0||x.call(window,g)}),w.current=!1))}),f}function xZ(e,t,n,r){const{layoutId:i,layout:a,drag:o,dragConstraints:s,layoutScroll:l,layoutRoot:u}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:gN(e.parent)),e.projection.setOptions({layoutId:i,layout:a,alwaysMeasureLayout:!!o||s&&Cs(s),visualElement:e,animationType:typeof a=="string"?a:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:u})}function gN(e){if(e)return e.options.allowProjection!==!1?e.projection:gN(e.parent)}function EZ(e,t,n){return y.useCallback(r=>{r&&e.mount&&e.mount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):Cs(n)&&(n.current=r))},[t])}function Rp(e){return Vu(e.animate)||Ey.some(t=>$u(e[t]))}function wN(e){return!!(Rp(e)||e.variants)}function TZ(e,t){if(Rp(e)){const{initial:n,animate:r}=e;return{initial:n===!1||$u(n)?n:void 0,animate:$u(r)?r:void 0}}return e.inherit!==!1?t:{}}function _Z(e){const{initial:t,animate:n}=TZ(e,y.useContext(Ap));return y.useMemo(()=>({initial:t,animate:n}),[yN(t),yN(n)])}function yN(e){return Array.isArray(e)?e.join(" "):e}const vN={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Os={};for(const e in vN)Os[e]={isEnabled:t=>vN[e].some(n=>!!t[n])};function SZ(e){for(const t in e)Os[t]={...Os[t],...e[t]}}const kZ=Symbol.for("motionComponentSymbol");function CZ({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:i}){e&&SZ(e);function a(s,l){let u;const c={...y.useContext(g1),...s,layoutId:AZ(s)},{isStatic:d}=c,f=_Z(s),p=r(s,d);if(!d&&w1){RZ();const g=NZ(c);u=g.MeasureLayout,f.visualElement=bZ(i,p,c,t,g.ProjectionNode)}return E.jsxs(Ap.Provider,{value:f,children:[u&&f.visualElement?E.jsx(u,{visualElement:f.visualElement,...c}):null,n(i,s,EZ(p,f.visualElement,l),p,d,f.visualElement)]})}const o=y.forwardRef(a);return o[kZ]=i,o}function AZ({layoutId:e}){const t=y.useContext(l1).id;return t&&e!==void 0?t+"-"+e:e}function RZ(e,t){y.useContext(mN).strict}function NZ(e){const{drag:t,layout:n}=Os;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t!=null&&t.isEnabled(e)||n!=null&&n.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}const OZ=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function y1(e){return typeof e!="string"||e.includes("-")?!1:!!(OZ.indexOf(e)>-1||/[A-Z]/u.test(e))}function bN(e,{style:t,vars:n},r,i){Object.assign(e.style,t,i&&i.getProjectionStyles(r));for(const a in n)e.style.setProperty(a,n[a])}const xN=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function EN(e,t,n,r){bN(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(xN.has(i)?i:bp(i),t.attrs[i])}function TN(e,{layout:t,layoutId:n}){return pa.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!kp[e]||e==="opacity")}function v1(e,t,n){var r;const{style:i}=e,a={};for(const o in i)(Kt(i[o])||t.style&&Kt(t.style[o])||TN(o,e)||((r=n==null?void 0:n.getValue(o))===null||r===void 0?void 0:r.liveStyle)!==void 0)&&(a[o]=i[o]);return n&&i&&typeof i.willChange=="string"&&(n.applyWillChange=!1),a}function _N(e,t,n){const r=v1(e,t,n);for(const i in e)if(Kt(e[i])||Kt(t[i])){const a=Wu.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[a]=e[i]}return r}function b1(e){const t=y.useRef(null);return t.current===null&&(t.current=e()),t.current}function PZ(e){if(pa.has(e))return"transform";if($3.has(e))return bp(e)}function IZ({applyWillChange:e=!1,scrapeMotionValuesFromProps:t,createRenderState:n,onMount:r},i,a,o,s){const l={latestValues:DZ(i,a,o,s?!1:e,t),renderState:n()};return r&&(l.mount=u=>r(i,u,l)),l}const SN=e=>(t,n)=>{const r=y.useContext(Ap),i=y.useContext(_p),a=()=>IZ(e,t,r,i,n);return n?a():b1(a)};function kN(e,t,n){const r=Array.isArray(t)?t:[t];for(let i=0;i<r.length;i++){const a=by(e,r[i]);if(a){const{transitionEnd:o,transition:s,...l}=a;n(l,o)}}}function DZ(e,t,n,r,i){var a;const o={},s=new Set,l=r&&((a=e.style)===null||a===void 0?void 0:a.willChange)===void 0,u=i(e,{});for(const x in u)o[x]=Cp(u[x]);let{initial:c,animate:d}=e;const f=Rp(e),p=wN(e);t&&p&&!f&&e.inherit!==!1&&(c===void 0&&(c=t.initial),d===void 0&&(d=t.animate));let g=n?n.initial===!1:!1;g=g||c===!1;const w=g?d:c;return w&&typeof w!="boolean"&&!Vu(w)&&kN(e,w,(x,m)=>{for(const v in x){let b=x[v];if(Array.isArray(b)){const T=g?b.length-1:0;b=b[T]}b!==null&&(o[v]=b)}for(const v in m)o[v]=m[v]}),l&&(d&&c!==!1&&!Vu(d)&&kN(e,d,x=>{for(const m in x){const v=PZ(m);v&&s.add(v)}}),s.size&&(o.willChange=Array.from(s).join(","))),o}const x1=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),CN=()=>({...x1(),attrs:{}}),AN=(e,t)=>t&&typeof e=="number"?t.transform(e):e,LZ={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},MZ=Wu.length;function FZ(e,t,n){let r="",i=!0;for(let a=0;a<MZ;a++){const o=Wu[a],s=e[o];if(s===void 0)continue;let l=!0;if(typeof s=="number"?l=s===(o.startsWith("scale")?1:0):l=parseFloat(s)===0,!l||n){const u=AN(s,Fy[o]);if(!l){i=!1;const c=LZ[o]||o;r+=`${c}(${u}) `}n&&(t[o]=u)}}return r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}function E1(e,t,n){const{style:r,vars:i,transformOrigin:a}=e;let o=!1,s=!1;for(const l in t){const u=t[l];if(pa.has(l)){o=!0;continue}else if(u3(l)){i[l]=u;continue}else{const c=AN(u,Fy[l]);l.startsWith("origin")?(s=!0,a[l]=c):r[l]=c}}if(t.transform||(o||n?r.transform=FZ(t,e.transform,n):r.transform&&(r.transform="none")),s){const{originX:l="50%",originY:u="50%",originZ:c=0}=a;r.transformOrigin=`${l} ${u} ${c}`}}function RN(e,t,n){return typeof e=="string"?e:he.transform(t+n*e)}function BZ(e,t,n){const r=RN(t,e.x,e.width),i=RN(n,e.y,e.height);return`${r} ${i}`}const jZ={offset:"stroke-dashoffset",array:"stroke-dasharray"},zZ={offset:"strokeDashoffset",array:"strokeDasharray"};function UZ(e,t,n=1,r=0,i=!0){e.pathLength=1;const a=i?jZ:zZ;e[a.offset]=he.transform(-r);const o=he.transform(t),s=he.transform(n);e[a.array]=`${o} ${s}`}function T1(e,{attrX:t,attrY:n,attrScale:r,originX:i,originY:a,pathLength:o,pathSpacing:s=1,pathOffset:l=0,...u},c,d){if(E1(e,u,d),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:f,style:p,dimensions:g}=e;f.transform&&(g&&(p.transform=f.transform),delete f.transform),g&&(i!==void 0||a!==void 0||p.transform)&&(p.transformOrigin=BZ(g,i!==void 0?i:.5,a!==void 0?a:.5)),t!==void 0&&(f.x=t),n!==void 0&&(f.y=n),r!==void 0&&(f.scale=r),o!==void 0&&UZ(f,o,s,l,!1)}const _1=e=>typeof e=="string"&&e.toLowerCase()==="svg",HZ={useVisualState:SN({scrapeMotionValuesFromProps:_N,createRenderState:CN,onMount:(e,t,{renderState:n,latestValues:r})=>{We.read(()=>{try{n.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch{n.dimensions={x:0,y:0,width:0,height:0}}}),We.render(()=>{T1(n,r,_1(t.tagName),e.transformTemplate),EN(t,n)})}})},VZ={useVisualState:SN({applyWillChange:!0,scrapeMotionValuesFromProps:v1,createRenderState:x1})};function NN(e,t,n){for(const r in t)!Kt(t[r])&&!TN(r,n)&&(e[r]=t[r])}function $Z({transformTemplate:e},t){return y.useMemo(()=>{const n=x1();return E1(n,t,e),Object.assign({},n.vars,n.style)},[t])}function WZ(e,t){const n=e.style||{},r={};return NN(r,n,e),Object.assign(r,$Z(e,t)),r}function YZ(e,t){const n={},r=WZ(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const qZ=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Np(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||qZ.has(e)}let ON=e=>!Np(e);function GZ(e){e&&(ON=t=>t.startsWith("on")?!Np(t):e(t))}try{GZ(require("@emotion/is-prop-valid").default)}catch{}function KZ(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(ON(i)||n===!0&&Np(i)||!t&&!Np(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}function XZ(e,t,n,r){const i=y.useMemo(()=>{const a=CN();return T1(a,t,_1(r),e.transformTemplate),{...a.attrs,style:{...a.style}}},[t]);if(e.style){const a={};NN(a,e.style,e),i.style={...a,...i.style}}return i}function QZ(e=!1){return(n,r,i,{latestValues:a},o)=>{const l=(y1(n)?XZ:YZ)(r,a,o,n),u=KZ(r,typeof n=="string",e),c=n!==y.Fragment?{...u,...l,ref:i}:{},{children:d}=r,f=y.useMemo(()=>Kt(d)?d.get():d,[d]);return y.createElement(n,{...c,children:f})}}function ZZ(e,t){return function(r,{forwardMotionProps:i}={forwardMotionProps:!1}){const o={...y1(r)?HZ:VZ,preloadedFeatures:e,useRender:QZ(i),createVisualElement:t,Component:r};return CZ(o)}}const S1={current:null},PN={current:!1};function JZ(){if(PN.current=!0,!!w1)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>S1.current=e.matches;e.addListener(t),t()}else S1.current=!1}function eJ(e,t,n){for(const r in t){const i=t[r],a=n[r];if(Kt(i))e.addValue(r,i);else if(Kt(a))e.addValue(r,Zu(i,{owner:e}));else if(a!==i)if(e.hasValue(r)){const o=e.getValue(r);o.liveStyle===!0?o.jump(i):o.hasAnimated||o.set(i)}else{const o=e.getStaticValue(r);e.addValue(r,Zu(o!==void 0?o:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const IN=new WeakMap,tJ=[...g3,Gt,wa],nJ=e=>tJ.find(m3(e)),DN=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class rJ{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,blockInitialAnimation:a,visualState:o},s={}){this.applyWillChange=!1,this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Oy,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const f=zr.now();this.renderScheduledAt<f&&(this.renderScheduledAt=f,We.render(this.render,!1,!0))};const{latestValues:l,renderState:u}=o;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=u,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=s,this.blockInitialAnimation=!!a,this.isControllingVariants=Rp(n),this.isVariantNode=wN(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:c,...d}=this.scrapeMotionValuesFromProps(n,{},this);for(const f in d){const p=d[f];l[f]!==void 0&&Kt(p)&&p.set(l[f],!1)}}mount(t){this.current=t,IN.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),PN.current||JZ(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:S1.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){IN.delete(this.current),this.projection&&this.projection.unmount(),ha(this.notifyUpdate),ha(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=pa.has(t),i=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&We.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0)}),a=n.on("renderRequest",this.scheduleRender);let o;window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),a(),o&&o(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Os){const n=Os[t];if(!n)continue;const{isEnabled:r,Feature:i}=n;if(!this.features[t]&&i&&r(this.props)&&(this.features[t]=new i(this)),this.features[t]){const a=this.features[t];a.isMounted?a.update():(a.mount(),a.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ht()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<DN.length;r++){const i=DN[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const a="on"+i,o=t[a];o&&(this.propEventSubscriptions[i]=this.on(i,o))}this.prevMotionValues=eJ(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Zu(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){var r;let i=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(r=this.getBaseTargetFromProps(this.props,t))!==null&&r!==void 0?r:this.readValueFromInstance(this.current,t,this.options);return i!=null&&(typeof i=="string"&&(s3(i)||o3(i))?i=parseFloat(i):!nJ(i)&&wa.test(n)&&(i=C3(t,n)),this.setBaseTarget(t,Kt(i)?i.get():i)),Kt(i)?i.get():i}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var n;const{initial:r}=this.props;let i;if(typeof r=="string"||typeof r=="object"){const o=by(this.props,r,(n=this.presenceContext)===null||n===void 0?void 0:n.custom);o&&(i=o[t])}if(r&&i!==void 0)return i;const a=this.getBaseTargetFromProps(this.props,t);return a!==void 0&&!Kt(a)?a:this.initialValues[t]!==void 0&&i===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Jy),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}}class LN extends rJ{constructor(){super(...arguments),this.KeyframeResolver=A3}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}}function iJ(e){return window.getComputedStyle(e)}class aJ extends LN{constructor(){super(...arguments),this.type="html",this.applyWillChange=!0,this.renderInstance=bN}readValueFromInstance(t,n){if(pa.has(n)){const r=By(n);return r&&r.default||0}else{const r=iJ(t),i=(u3(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return OR(t,n)}build(t,n,r){E1(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return v1(t,n,r)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Kt(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class oJ extends LN{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ht}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(pa.has(n)){const r=By(n);return r&&r.default||0}return n=xN.has(n)?n:bp(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return _N(t,n,r)}build(t,n,r){T1(t,n,this.isSVGTag,r.transformTemplate)}renderInstance(t,n,r,i){EN(t,n,r,i)}mount(t){this.isSVGTag=_1(t.tagName),super.mount(t)}}const sJ=(e,t)=>y1(e)?new oJ(t):new aJ(t,{allowProjection:e!==y.Fragment}),lJ=ZZ({...XX,...yZ,...sZ,...vZ},sJ),vi=$G(lJ);class uJ extends y.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=this.props.sizeRef.current;r.height=n.offsetHeight||0,r.width=n.offsetWidth||0,r.top=n.offsetTop,r.left=n.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}}function cJ({children:e,isPresent:t}){const n=y.useId(),r=y.useRef(null),i=y.useRef({width:0,height:0,top:0,left:0}),{nonce:a}=y.useContext(g1);return y.useInsertionEffect(()=>{const{width:o,height:s,top:l,left:u}=i.current;if(t||!r.current||!o||!s)return;r.current.dataset.motionPopId=n;const c=document.createElement("style");return a&&(c.nonce=a),document.head.appendChild(c),c.sheet&&c.sheet.insertRule(`
82
+ [data-motion-pop-id="${n}"] {
83
+ position: absolute !important;
84
+ width: ${o}px !important;
85
+ height: ${s}px !important;
86
+ top: ${l}px !important;
87
+ left: ${u}px !important;
88
+ }
89
+ `),()=>{document.head.removeChild(c)}},[t]),E.jsx(uJ,{isPresent:t,childRef:r,sizeRef:i,children:y.cloneElement(e,{ref:r})})}const dJ=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:a,mode:o})=>{const s=b1(fJ),l=y.useId(),u=y.useCallback(d=>{s.set(d,!0);for(const f of s.values())if(!f)return;r&&r()},[s,r]),c=y.useMemo(()=>({id:l,initial:t,isPresent:n,custom:i,onExitComplete:u,register:d=>(s.set(d,!1),()=>s.delete(d))}),a?[Math.random(),u]:[n,u]);return y.useMemo(()=>{s.forEach((d,f)=>s.set(f,!1))},[n]),y.useEffect(()=>{!n&&!s.size&&r&&r()},[n]),o==="popLayout"&&(e=E.jsx(cJ,{isPresent:n,children:e})),E.jsx(_p.Provider,{value:c,children:e})};function fJ(){return new Map}const Op=e=>e.key||"";function MN(e){const t=[];return y.Children.forEach(e,n=>{y.isValidElement(n)&&t.push(n)}),t}const lo=({children:e,exitBeforeEnter:t,custom:n,initial:r=!0,onExitComplete:i,presenceAffectsLayout:a=!0,mode:o="sync"})=>{const s=y.useMemo(()=>MN(e),[e]),l=s.map(Op),u=y.useRef(!0),c=y.useRef(s),d=b1(()=>new Map),[f,p]=y.useState(s),[g,w]=y.useState(s);hN(()=>{u.current=!1,c.current=s;for(let v=0;v<g.length;v++){const b=Op(g[v]);l.includes(b)?d.delete(b):d.get(b)!==!0&&d.set(b,!1)}},[g,l.length,l.join("-")]);const x=[];if(s!==f){let v=[...s];for(let b=0;b<g.length;b++){const T=g[b],_=Op(T);l.includes(_)||(v.splice(b,0,T),x.push(T))}o==="wait"&&x.length&&(v=x),w(MN(v)),p(s);return}const{forceRender:m}=y.useContext(l1);return E.jsx(E.Fragment,{children:g.map(v=>{const b=Op(v),T=s===g||l.includes(b),_=()=>{if(d.has(b))d.set(b,!0);else return;let S=!0;d.forEach(R=>{R||(S=!1)}),S&&(m==null||m(),w(c.current),i&&i())};return E.jsx(dJ,{isPresent:T,initial:!u.current||r?void 0:!1,custom:T?void 0:n,presenceAffectsLayout:a,mode:o,onExitComplete:T?void 0:_,children:v},b)})})};function pJ(){return E.jsx(lo,{children:E.jsxs(vi.div,{animate:{opacity:1},exit:{opacity:0},transition:{duration:.5},className:"flex flex-row items-end w-full gap-1",children:[E.jsx("div",{className:"flex items-center gap-1",children:E.jsx(cp,{className:"animate-pulse size-7 rounded-xl bg-secondary",children:E.jsx(yy,{})})}),E.jsxs("div",{className:"flex items-center [&_span]:bg-secondary-foreground [&_span]:size-1 gap-1 p-3 rounded-lg rounded-bl-none bg-secondary",children:[E.jsx(vi.span,{className:"rounded-full animate-bounce [animation-delay:-0.3s]"}),E.jsx(vi.span,{className:"rounded-full animate-bounce [animation-delay:-0.15s]"}),E.jsx(vi.span,{className:"rounded-full animate-bounce"})]})]})})}function hJ(e){return E.jsx("div",{className:"w-full max-w-full overflow-auto shrink-0",children:E.jsx("pre",{dir:"auto",className:"text-xs leading-tight",children:JSON.stringify(e,null,1)})})}function k1({children:e,agent:t,className:n}){return E.jsxs("div",{className:"flex flex-row items-end w-full gap-2",children:[E.jsx(cp,{className:"flex items-center size-7 border-0",children:E.jsx(wy,{src:(t==null?void 0:t.profile_picture)??"",alt:"Agent Icon"})}),E.jsx("div",{className:He("w-fit min-w-[80%]",n),children:E.jsx("div",{className:"rounded-xl rounded-bl-none bg-secondary shadow-sm p-2.5 min-w-fit",children:e})})]})}function Pp({message:e,Wrapper:t,wrapperProps:n}){const r=Bt(),i=r.componentStore.getComponent(e.component,r.debug);return i?t?y.createElement(t,{...n,key:e.id},E.jsx(i,{...e,id:e.id})):y.createElement(i,{...e,id:e.id,key:e.id}):null}function Ip(e){"@babel/helpers - typeof";return Ip=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ip(e)}var mJ=/^\s+/,gJ=/\s+$/;function ue(e,t){if(e=e||"",t=t||{},e instanceof ue)return e;if(!(this instanceof ue))return new ue(e,t);var n=wJ(e);this._originalInput=e,this._r=n.r,this._g=n.g,this._b=n.b,this._a=n.a,this._roundA=Math.round(100*this._a)/100,this._format=t.format||n.format,this._gradientType=t.gradientType,this._r<1&&(this._r=Math.round(this._r)),this._g<1&&(this._g=Math.round(this._g)),this._b<1&&(this._b=Math.round(this._b)),this._ok=n.ok}ue.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var t=this.toRgb();return(t.r*299+t.g*587+t.b*114)/1e3},getLuminance:function(){var t=this.toRgb(),n,r,i,a,o,s;return n=t.r/255,r=t.g/255,i=t.b/255,n<=.03928?a=n/12.92:a=Math.pow((n+.055)/1.055,2.4),r<=.03928?o=r/12.92:o=Math.pow((r+.055)/1.055,2.4),i<=.03928?s=i/12.92:s=Math.pow((i+.055)/1.055,2.4),.2126*a+.7152*o+.0722*s},setAlpha:function(t){return this._a=HN(t),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var t=BN(this._r,this._g,this._b);return{h:t.h*360,s:t.s,v:t.v,a:this._a}},toHsvString:function(){var t=BN(this._r,this._g,this._b),n=Math.round(t.h*360),r=Math.round(t.s*100),i=Math.round(t.v*100);return this._a==1?"hsv("+n+", "+r+"%, "+i+"%)":"hsva("+n+", "+r+"%, "+i+"%, "+this._roundA+")"},toHsl:function(){var t=FN(this._r,this._g,this._b);return{h:t.h*360,s:t.s,l:t.l,a:this._a}},toHslString:function(){var t=FN(this._r,this._g,this._b),n=Math.round(t.h*360),r=Math.round(t.s*100),i=Math.round(t.l*100);return this._a==1?"hsl("+n+", "+r+"%, "+i+"%)":"hsla("+n+", "+r+"%, "+i+"%, "+this._roundA+")"},toHex:function(t){return jN(this._r,this._g,this._b,t)},toHexString:function(t){return"#"+this.toHex(t)},toHex8:function(t){return xJ(this._r,this._g,this._b,this._a,t)},toHex8String:function(t){return"#"+this.toHex8(t)},toRgb:function(){return{r:Math.round(this._r),g:Math.round(this._g),b:Math.round(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+")":"rgba("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:Math.round(rt(this._r,255)*100)+"%",g:Math.round(rt(this._g,255)*100)+"%",b:Math.round(rt(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+Math.round(rt(this._r,255)*100)+"%, "+Math.round(rt(this._g,255)*100)+"%, "+Math.round(rt(this._b,255)*100)+"%)":"rgba("+Math.round(rt(this._r,255)*100)+"%, "+Math.round(rt(this._g,255)*100)+"%, "+Math.round(rt(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:IJ[jN(this._r,this._g,this._b,!0)]||!1},toFilter:function(t){var n="#"+zN(this._r,this._g,this._b,this._a),r=n,i=this._gradientType?"GradientType = 1, ":"";if(t){var a=ue(t);r="#"+zN(a._r,a._g,a._b,a._a)}return"progid:DXImageTransform.Microsoft.gradient("+i+"startColorstr="+n+",endColorstr="+r+")"},toString:function(t){var n=!!t;t=t||this._format;var r=!1,i=this._a<1&&this._a>=0,a=!n&&i&&(t==="hex"||t==="hex6"||t==="hex3"||t==="hex4"||t==="hex8"||t==="name");return a?t==="name"&&this._a===0?this.toName():this.toRgbString():(t==="rgb"&&(r=this.toRgbString()),t==="prgb"&&(r=this.toPercentageRgbString()),(t==="hex"||t==="hex6")&&(r=this.toHexString()),t==="hex3"&&(r=this.toHexString(!0)),t==="hex4"&&(r=this.toHex8String(!0)),t==="hex8"&&(r=this.toHex8String()),t==="name"&&(r=this.toName()),t==="hsl"&&(r=this.toHslString()),t==="hsv"&&(r=this.toHsvString()),r||this.toHexString())},clone:function(){return ue(this.toString())},_applyModification:function(t,n){var r=t.apply(null,[this].concat([].slice.call(n)));return this._r=r._r,this._g=r._g,this._b=r._b,this.setAlpha(r._a),this},lighten:function(){return this._applyModification(SJ,arguments)},brighten:function(){return this._applyModification(kJ,arguments)},darken:function(){return this._applyModification(CJ,arguments)},desaturate:function(){return this._applyModification(EJ,arguments)},saturate:function(){return this._applyModification(TJ,arguments)},greyscale:function(){return this._applyModification(_J,arguments)},spin:function(){return this._applyModification(AJ,arguments)},_applyCombination:function(t,n){return t.apply(null,[this].concat([].slice.call(n)))},analogous:function(){return this._applyCombination(OJ,arguments)},complement:function(){return this._applyCombination(RJ,arguments)},monochromatic:function(){return this._applyCombination(PJ,arguments)},splitcomplement:function(){return this._applyCombination(NJ,arguments)},triad:function(){return this._applyCombination(UN,[3])},tetrad:function(){return this._applyCombination(UN,[4])}},ue.fromRatio=function(e,t){if(Ip(e)=="object"){var n={};for(var r in e)e.hasOwnProperty(r)&&(r==="a"?n[r]=e[r]:n[r]=rc(e[r]));e=n}return ue(e,t)};function wJ(e){var t={r:0,g:0,b:0},n=1,r=null,i=null,a=null,o=!1,s=!1;return typeof e=="string"&&(e=FJ(e)),Ip(e)=="object"&&(bi(e.r)&&bi(e.g)&&bi(e.b)?(t=yJ(e.r,e.g,e.b),o=!0,s=String(e.r).substr(-1)==="%"?"prgb":"rgb"):bi(e.h)&&bi(e.s)&&bi(e.v)?(r=rc(e.s),i=rc(e.v),t=bJ(e.h,r,i),o=!0,s="hsv"):bi(e.h)&&bi(e.s)&&bi(e.l)&&(r=rc(e.s),a=rc(e.l),t=vJ(e.h,r,a),o=!0,s="hsl"),e.hasOwnProperty("a")&&(n=e.a)),n=HN(n),{ok:o,format:e.format||s,r:Math.min(255,Math.max(t.r,0)),g:Math.min(255,Math.max(t.g,0)),b:Math.min(255,Math.max(t.b,0)),a:n}}function yJ(e,t,n){return{r:rt(e,255)*255,g:rt(t,255)*255,b:rt(n,255)*255}}function FN(e,t,n){e=rt(e,255),t=rt(t,255),n=rt(n,255);var r=Math.max(e,t,n),i=Math.min(e,t,n),a,o,s=(r+i)/2;if(r==i)a=o=0;else{var l=r-i;switch(o=s>.5?l/(2-r-i):l/(r+i),r){case e:a=(t-n)/l+(t<n?6:0);break;case t:a=(n-e)/l+2;break;case n:a=(e-t)/l+4;break}a/=6}return{h:a,s:o,l:s}}function vJ(e,t,n){var r,i,a;e=rt(e,360),t=rt(t,100),n=rt(n,100);function o(u,c,d){return d<0&&(d+=1),d>1&&(d-=1),d<1/6?u+(c-u)*6*d:d<1/2?c:d<2/3?u+(c-u)*(2/3-d)*6:u}if(t===0)r=i=a=n;else{var s=n<.5?n*(1+t):n+t-n*t,l=2*n-s;r=o(l,s,e+1/3),i=o(l,s,e),a=o(l,s,e-1/3)}return{r:r*255,g:i*255,b:a*255}}function BN(e,t,n){e=rt(e,255),t=rt(t,255),n=rt(n,255);var r=Math.max(e,t,n),i=Math.min(e,t,n),a,o,s=r,l=r-i;if(o=r===0?0:l/r,r==i)a=0;else{switch(r){case e:a=(t-n)/l+(t<n?6:0);break;case t:a=(n-e)/l+2;break;case n:a=(e-t)/l+4;break}a/=6}return{h:a,s:o,v:s}}function bJ(e,t,n){e=rt(e,360)*6,t=rt(t,100),n=rt(n,100);var r=Math.floor(e),i=e-r,a=n*(1-t),o=n*(1-i*t),s=n*(1-(1-i)*t),l=r%6,u=[n,o,a,a,s,n][l],c=[s,n,n,o,a,a][l],d=[a,a,s,n,n,o][l];return{r:u*255,g:c*255,b:d*255}}function jN(e,t,n,r){var i=[wr(Math.round(e).toString(16)),wr(Math.round(t).toString(16)),wr(Math.round(n).toString(16))];return r&&i[0].charAt(0)==i[0].charAt(1)&&i[1].charAt(0)==i[1].charAt(1)&&i[2].charAt(0)==i[2].charAt(1)?i[0].charAt(0)+i[1].charAt(0)+i[2].charAt(0):i.join("")}function xJ(e,t,n,r,i){var a=[wr(Math.round(e).toString(16)),wr(Math.round(t).toString(16)),wr(Math.round(n).toString(16)),wr(VN(r))];return i&&a[0].charAt(0)==a[0].charAt(1)&&a[1].charAt(0)==a[1].charAt(1)&&a[2].charAt(0)==a[2].charAt(1)&&a[3].charAt(0)==a[3].charAt(1)?a[0].charAt(0)+a[1].charAt(0)+a[2].charAt(0)+a[3].charAt(0):a.join("")}function zN(e,t,n,r){var i=[wr(VN(r)),wr(Math.round(e).toString(16)),wr(Math.round(t).toString(16)),wr(Math.round(n).toString(16))];return i.join("")}ue.equals=function(e,t){return!e||!t?!1:ue(e).toRgbString()==ue(t).toRgbString()},ue.random=function(){return ue.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})};function EJ(e,t){t=t===0?0:t||10;var n=ue(e).toHsl();return n.s-=t/100,n.s=Dp(n.s),ue(n)}function TJ(e,t){t=t===0?0:t||10;var n=ue(e).toHsl();return n.s+=t/100,n.s=Dp(n.s),ue(n)}function _J(e){return ue(e).desaturate(100)}function SJ(e,t){t=t===0?0:t||10;var n=ue(e).toHsl();return n.l+=t/100,n.l=Dp(n.l),ue(n)}function kJ(e,t){t=t===0?0:t||10;var n=ue(e).toRgb();return n.r=Math.max(0,Math.min(255,n.r-Math.round(255*-(t/100)))),n.g=Math.max(0,Math.min(255,n.g-Math.round(255*-(t/100)))),n.b=Math.max(0,Math.min(255,n.b-Math.round(255*-(t/100)))),ue(n)}function CJ(e,t){t=t===0?0:t||10;var n=ue(e).toHsl();return n.l-=t/100,n.l=Dp(n.l),ue(n)}function AJ(e,t){var n=ue(e).toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,ue(n)}function RJ(e){var t=ue(e).toHsl();return t.h=(t.h+180)%360,ue(t)}function UN(e,t){if(isNaN(t)||t<=0)throw new Error("Argument to polyad must be a positive number");for(var n=ue(e).toHsl(),r=[ue(e)],i=360/t,a=1;a<t;a++)r.push(ue({h:(n.h+a*i)%360,s:n.s,l:n.l}));return r}function NJ(e){var t=ue(e).toHsl(),n=t.h;return[ue(e),ue({h:(n+72)%360,s:t.s,l:t.l}),ue({h:(n+216)%360,s:t.s,l:t.l})]}function OJ(e,t,n){t=t||6,n=n||30;var r=ue(e).toHsl(),i=360/n,a=[ue(e)];for(r.h=(r.h-(i*t>>1)+720)%360;--t;)r.h=(r.h+i)%360,a.push(ue(r));return a}function PJ(e,t){t=t||6;for(var n=ue(e).toHsv(),r=n.h,i=n.s,a=n.v,o=[],s=1/t;t--;)o.push(ue({h:r,s:i,v:a})),a=(a+s)%1;return o}ue.mix=function(e,t,n){n=n===0?0:n||50;var r=ue(e).toRgb(),i=ue(t).toRgb(),a=n/100,o={r:(i.r-r.r)*a+r.r,g:(i.g-r.g)*a+r.g,b:(i.b-r.b)*a+r.b,a:(i.a-r.a)*a+r.a};return ue(o)},ue.readability=function(e,t){var n=ue(e),r=ue(t);return(Math.max(n.getLuminance(),r.getLuminance())+.05)/(Math.min(n.getLuminance(),r.getLuminance())+.05)},ue.isReadable=function(e,t,n){var r=ue.readability(e,t),i,a;switch(a=!1,i=BJ(n),i.level+i.size){case"AAsmall":case"AAAlarge":a=r>=4.5;break;case"AAlarge":a=r>=3;break;case"AAAsmall":a=r>=7;break}return a},ue.mostReadable=function(e,t,n){var r=null,i=0,a,o,s,l;n=n||{},o=n.includeFallbackColors,s=n.level,l=n.size;for(var u=0;u<t.length;u++)a=ue.readability(e,t[u]),a>i&&(i=a,r=ue(t[u]));return ue.isReadable(e,r,{level:s,size:l})||!o?r:(n.includeFallbackColors=!1,ue.mostReadable(e,["#fff","#000"],n))};var C1=ue.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},IJ=ue.hexNames=DJ(C1);function DJ(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}function HN(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function rt(e,t){LJ(e)&&(e="100%");var n=MJ(e);return e=Math.min(t,Math.max(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),Math.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function Dp(e){return Math.min(1,Math.max(0,e))}function Dn(e){return parseInt(e,16)}function LJ(e){return typeof e=="string"&&e.indexOf(".")!=-1&&parseFloat(e)===1}function MJ(e){return typeof e=="string"&&e.indexOf("%")!=-1}function wr(e){return e.length==1?"0"+e:""+e}function rc(e){return e<=1&&(e=e*100+"%"),e}function VN(e){return Math.round(parseFloat(e)*255).toString(16)}function $N(e){return Dn(e)/255}var yr=function(){var e="[-\\+]?\\d+%?",t="[-\\+]?\\d*\\.\\d+%?",n="(?:"+t+")|(?:"+e+")",r="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?",i="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?";return{CSS_UNIT:new RegExp(n),rgb:new RegExp("rgb"+r),rgba:new RegExp("rgba"+i),hsl:new RegExp("hsl"+r),hsla:new RegExp("hsla"+i),hsv:new RegExp("hsv"+r),hsva:new RegExp("hsva"+i),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function bi(e){return!!yr.CSS_UNIT.exec(e)}function FJ(e){e=e.replace(mJ,"").replace(gJ,"").toLowerCase();var t=!1;if(C1[e])e=C1[e],t=!0;else if(e=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var n;return(n=yr.rgb.exec(e))?{r:n[1],g:n[2],b:n[3]}:(n=yr.rgba.exec(e))?{r:n[1],g:n[2],b:n[3],a:n[4]}:(n=yr.hsl.exec(e))?{h:n[1],s:n[2],l:n[3]}:(n=yr.hsla.exec(e))?{h:n[1],s:n[2],l:n[3],a:n[4]}:(n=yr.hsv.exec(e))?{h:n[1],s:n[2],v:n[3]}:(n=yr.hsva.exec(e))?{h:n[1],s:n[2],v:n[3],a:n[4]}:(n=yr.hex8.exec(e))?{r:Dn(n[1]),g:Dn(n[2]),b:Dn(n[3]),a:$N(n[4]),format:t?"name":"hex8"}:(n=yr.hex6.exec(e))?{r:Dn(n[1]),g:Dn(n[2]),b:Dn(n[3]),format:t?"name":"hex"}:(n=yr.hex4.exec(e))?{r:Dn(n[1]+""+n[1]),g:Dn(n[2]+""+n[2]),b:Dn(n[3]+""+n[3]),a:$N(n[4]+""+n[4]),format:t?"name":"hex8"}:(n=yr.hex3.exec(e))?{r:Dn(n[1]+""+n[1]),g:Dn(n[2]+""+n[2]),b:Dn(n[3]+""+n[3]),format:t?"name":"hex"}:!1}function BJ(e){var t,n;return e=e||{level:"AA",size:"small"},t=(e.level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),t!=="AA"&&t!=="AAA"&&(t="AA"),n!=="small"&&n!=="large"&&(n="small"),{level:t,size:n}}const jJ=400,zJ=600,A1={widgetMinHeight:"min-h-[400px]",widgetMaxHeight:"max-h-[600px]",widgetHeight:"h-[600px]"},WN=(e,t)=>{const n=ue(e.primary).toHsl(),r=ue(e.primary).isLight()?"240 10% 3.9%":"0 0% 100%";return{"--opencx-primary":`${n.h} ${n.s}% ${n.l}%`,"--opencx-primary-foreground":r,"--opencx-background":"0 0% 100%","--opencx-foreground":"240 10% 3.9%","--opencx-accent":"240 4.8% 95.9%","--opencx-accent-foreground":"240 5.9% 10%","--opencx-destructive":"0 84.2% 60.2%","--opencx-destructive-foreground":"0 0% 98%","--opencx-secondary":"240 4.8% 95.9%","--opencx-secondary-foreground":"240 5.9% 10%","--opencx-muted":"240 4.8% 95.9%","--opencx-muted-foreground":"240 3.8% 46.1%","--opencx-input":"240 5.9% 90%","--opencx-border":"240 5.9% 90%","--opencx-ring":"240 5.9% 10%","--opencx-trigger-offset":t.triggerOffset}},UJ=10,HJ={right:(e,t)=>({initial:{opacity:0,x:-e,...t.initial},animate:{opacity:1,x:0,...t.animate},exit:{opacity:0,x:e,...t.exit}}),left:(e,t)=>({initial:{opacity:0,x:e,...t.initial},animate:{opacity:1,x:0,...t.animate},exit:{opacity:0,x:-e,...t.exit}}),up:(e,t)=>({initial:{opacity:0,y:e,...t.initial},animate:{opacity:1,y:0,...t.animate},exit:{opacity:0,y:-e,...t.exit}}),down:(e,t)=>({initial:{opacity:0,y:-e,...t.initial},animate:{opacity:1,y:0,...t.animate},exit:{opacity:0,y:e,...t.exit}})},vr=y.forwardRef(({fadeIn:e="down",distance:t=UJ,children:n,snapExit:r=!1,overrides:i={},...a},o)=>{const s=e?HJ[e](t,i):{};return r&&s.exit&&typeof s.exit=="object"&&!Array.isArray(s.exit)&&(s.exit.transition={duration:0}),E.jsx(vi.div,{ref:o,...a,...s,children:n})});vr.displayName="MotionDiv";function VJ(){const{contact:e}=xm(),{collectUserData:t}=Bt();return{shouldCollectDataFirst:t&&!(e!=null&&e.id)}}const Lp=43200,YN=1440,qN=Symbol.for("constructDateFrom");function GN(e,t){return typeof e=="function"?e(t):e&&typeof e=="object"&&qN in e?e[qN](t):e instanceof Date?new e.constructor(t):new Date(t)}function va(e,t){return GN(e,e)}let $J={};function WJ(){return $J}function KN(e){const t=va(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function R1(e,...t){const n=GN.bind(null,e||t.find(r=>typeof r=="object"));return t.map(n)}function Mp(e,t){const n=+va(e)-+va(t);return n<0?-1:n>0?1:n}function YJ(e,t,n){const[r,i]=R1(n==null?void 0:n.in,e,t),a=r.getFullYear()-i.getFullYear(),o=r.getMonth()-i.getMonth();return a*12+o}function qJ(e){return t=>{const r=(e?Math[e]:Math.trunc)(t);return r===0?0:r}}function GJ(e,t){return+va(e)-+va(t)}function KJ(e,t){const n=va(e);return n.setHours(23,59,59,999),n}function XJ(e,t){const n=va(e),r=n.getMonth();return n.setFullYear(n.getFullYear(),r+1,0),n.setHours(23,59,59,999),n}function QJ(e,t){const n=va(e);return+KJ(n)==+XJ(n)}function ZJ(e,t,n){const[r,i,a]=R1(n==null?void 0:n.in,e,e,t),o=Mp(i,a),s=Math.abs(YJ(i,a));if(s<1)return 0;i.getMonth()===1&&i.getDate()>27&&i.setDate(30),i.setMonth(i.getMonth()-o*s);let l=Mp(i,a)===-o;QJ(r)&&s===1&&Mp(r,a)===1&&(l=!1);const u=o*(s-+l);return u===0?0:u}function JJ(e,t,n){const r=GJ(e,t)/1e3;return qJ(n==null?void 0:n.roundingMethod)(r)}const eee={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},tee=(e,t,n)=>{let r;const i=eee[e];return typeof i=="string"?r=i:t===1?r=i.one:r=i.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function N1(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const nee={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},ree={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},iee={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},aee={date:N1({formats:nee,defaultWidth:"full"}),time:N1({formats:ree,defaultWidth:"full"}),dateTime:N1({formats:iee,defaultWidth:"full"})},oee={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},see=(e,t,n,r)=>oee[e];function ic(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let i;if(r==="formatting"&&e.formattingValues){const o=e.defaultFormattingWidth||e.defaultWidth,s=n!=null&&n.width?String(n.width):o;i=e.formattingValues[s]||e.formattingValues[o]}else{const o=e.defaultWidth,s=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[s]||e.values[o]}const a=e.argumentCallback?e.argumentCallback(t):t;return i[a]}}const lee={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},uee={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},cee={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},dee={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},fee={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},pee={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},hee={ordinalNumber:(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:ic({values:lee,defaultWidth:"wide"}),quarter:ic({values:uee,defaultWidth:"wide",argumentCallback:e=>e-1}),month:ic({values:cee,defaultWidth:"wide"}),day:ic({values:dee,defaultWidth:"wide"}),dayPeriod:ic({values:fee,defaultWidth:"wide",formattingValues:pee,defaultFormattingWidth:"wide"})};function ac(e){return(t,n={})=>{const r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],a=t.match(i);if(!a)return null;const o=a[0],s=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(s)?gee(s,d=>d.test(o)):mee(s,d=>d.test(o));let u;u=e.valueCallback?e.valueCallback(l):l,u=n.valueCallback?n.valueCallback(u):u;const c=t.slice(o.length);return{value:u,rest:c}}}function mee(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function gee(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function wee(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const i=r[0],a=t.match(e.parsePattern);if(!a)return null;let o=e.valueCallback?e.valueCallback(a[0]):a[0];o=n.valueCallback?n.valueCallback(o):o;const s=t.slice(i.length);return{value:o,rest:s}}}const yee=/^(\d+)(th|st|nd|rd)?/i,vee=/\d+/i,bee={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},xee={any:[/^b/i,/^(a|c)/i]},Eee={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Tee={any:[/1/i,/2/i,/3/i,/4/i]},_ee={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},See={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},kee={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Cee={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Aee={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Ree={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},Nee={ordinalNumber:wee({matchPattern:yee,parsePattern:vee,valueCallback:e=>parseInt(e,10)}),era:ac({matchPatterns:bee,defaultMatchWidth:"wide",parsePatterns:xee,defaultParseWidth:"any"}),quarter:ac({matchPatterns:Eee,defaultMatchWidth:"wide",parsePatterns:Tee,defaultParseWidth:"any",valueCallback:e=>e+1}),month:ac({matchPatterns:_ee,defaultMatchWidth:"wide",parsePatterns:See,defaultParseWidth:"any"}),day:ac({matchPatterns:kee,defaultMatchWidth:"wide",parsePatterns:Cee,defaultParseWidth:"any"}),dayPeriod:ac({matchPatterns:Aee,defaultMatchWidth:"any",parsePatterns:Ree,defaultParseWidth:"any"})},Oee={code:"en-US",formatDistance:tee,formatLong:aee,formatRelative:see,localize:hee,match:Nee,options:{weekStartsOn:0,firstWeekContainsDate:1}};function Pee(e,t,n){const r=WJ(),i=(n==null?void 0:n.locale)??r.locale??Oee,a=2520,o=Mp(e,t);if(isNaN(o))throw new RangeError("Invalid time value");const s=Object.assign({},n,{addSuffix:n==null?void 0:n.addSuffix,comparison:o}),[l,u]=R1(n==null?void 0:n.in,...o>0?[t,e]:[e,t]),c=JJ(u,l),d=(KN(u)-KN(l))/1e3,f=Math.round((c-d)/60);let p;if(f<2)return n!=null&&n.includeSeconds?c<5?i.formatDistance("lessThanXSeconds",5,s):c<10?i.formatDistance("lessThanXSeconds",10,s):c<20?i.formatDistance("lessThanXSeconds",20,s):c<40?i.formatDistance("halfAMinute",0,s):c<60?i.formatDistance("lessThanXMinutes",1,s):i.formatDistance("xMinutes",1,s):f===0?i.formatDistance("lessThanXMinutes",1,s):i.formatDistance("xMinutes",f,s);if(f<45)return i.formatDistance("xMinutes",f,s);if(f<90)return i.formatDistance("aboutXHours",1,s);if(f<YN){const g=Math.round(f/60);return i.formatDistance("aboutXHours",g,s)}else{if(f<a)return i.formatDistance("xDays",1,s);if(f<Lp){const g=Math.round(f/YN);return i.formatDistance("xDays",g,s)}else if(f<Lp*2)return p=Math.round(f/Lp),i.formatDistance("aboutXMonths",p,s)}if(p=ZJ(u,l),p<12){const g=Math.round(f/Lp);return i.formatDistance("xMonths",g,s)}else{const g=p%12,w=Math.trunc(p/12);return g<3?i.formatDistance("aboutXYears",w,s):g<9?i.formatDistance("overXYears",w,s):i.formatDistance("almostXYears",w+1,s)}}/**
90
+ * @license lucide-react v0.436.0 - ISC
91
+ *
92
+ * This source code is licensed under the ISC license.
93
+ * See the LICENSE file in the root directory of this source tree.
94
+ */const Iee=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),XN=(...e)=>e.filter((t,n,r)=>!!t&&r.indexOf(t)===n).join(" ");/**
95
+ * @license lucide-react v0.436.0 - ISC
96
+ *
97
+ * This source code is licensed under the ISC license.
98
+ * See the LICENSE file in the root directory of this source tree.
99
+ */var Dee={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
100
+ * @license lucide-react v0.436.0 - ISC
101
+ *
102
+ * This source code is licensed under the ISC license.
103
+ * See the LICENSE file in the root directory of this source tree.
104
+ */const Lee=y.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i="",children:a,iconNode:o,...s},l)=>y.createElement("svg",{ref:l,...Dee,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:XN("lucide",i),...s},[...o.map(([u,c])=>y.createElement(u,c)),...Array.isArray(a)?a:[a]]));/**
105
+ * @license lucide-react v0.436.0 - ISC
106
+ *
107
+ * This source code is licensed under the ISC license.
108
+ * See the LICENSE file in the root directory of this source tree.
109
+ */const Nt=(e,t)=>{const n=y.forwardRef(({className:r,...i},a)=>y.createElement(Lee,{ref:a,iconNode:t,className:XN(`lucide-${Iee(e)}`,r),...i}));return n.displayName=`${e}`,n};/**
110
+ * @license lucide-react v0.436.0 - ISC
111
+ *
112
+ * This source code is licensed under the ISC license.
113
+ * See the LICENSE file in the root directory of this source tree.
114
+ */const QN=Nt("CheckCheck",[["path",{d:"M18 6 7 17l-5-5",key:"116fxf"}],["path",{d:"m22 10-7.5 7.5L13 16",key:"ke71qq"}]]);/**
115
+ * @license lucide-react v0.436.0 - ISC
116
+ *
117
+ * This source code is licensed under the ISC license.
118
+ * See the LICENSE file in the root directory of this source tree.
119
+ */const Mee=Nt("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
120
+ * @license lucide-react v0.436.0 - ISC
121
+ *
122
+ * This source code is licensed under the ISC license.
123
+ * See the LICENSE file in the root directory of this source tree.
124
+ */const Fee=Nt("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
125
+ * @license lucide-react v0.436.0 - ISC
126
+ *
127
+ * This source code is licensed under the ISC license.
128
+ * See the LICENSE file in the root directory of this source tree.
129
+ */const Bee=Nt("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
130
+ * @license lucide-react v0.436.0 - ISC
131
+ *
132
+ * This source code is licensed under the ISC license.
133
+ * See the LICENSE file in the root directory of this source tree.
134
+ */const jee=Nt("CircleDashed",[["path",{d:"M10.1 2.182a10 10 0 0 1 3.8 0",key:"5ilxe3"}],["path",{d:"M13.9 21.818a10 10 0 0 1-3.8 0",key:"11zvb9"}],["path",{d:"M17.609 3.721a10 10 0 0 1 2.69 2.7",key:"1iw5b2"}],["path",{d:"M2.182 13.9a10 10 0 0 1 0-3.8",key:"c0bmvh"}],["path",{d:"M20.279 17.609a10 10 0 0 1-2.7 2.69",key:"1ruxm7"}],["path",{d:"M21.818 10.1a10 10 0 0 1 0 3.8",key:"qkgqxc"}],["path",{d:"M3.721 6.391a10 10 0 0 1 2.7-2.69",key:"1mcia2"}],["path",{d:"M6.391 20.279a10 10 0 0 1-2.69-2.7",key:"1fvljs"}]]);/**
135
+ * @license lucide-react v0.436.0 - ISC
136
+ *
137
+ * This source code is licensed under the ISC license.
138
+ * See the LICENSE file in the root directory of this source tree.
139
+ */const zee=Nt("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/**
140
+ * @license lucide-react v0.436.0 - ISC
141
+ *
142
+ * This source code is licensed under the ISC license.
143
+ * See the LICENSE file in the root directory of this source tree.
144
+ */const Uee=Nt("EllipsisVertical",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"12",cy:"5",r:"1",key:"gxeob9"}],["circle",{cx:"12",cy:"19",r:"1",key:"lyex9k"}]]);/**
145
+ * @license lucide-react v0.436.0 - ISC
146
+ *
147
+ * This source code is licensed under the ISC license.
148
+ * See the LICENSE file in the root directory of this source tree.
149
+ */const Hee=Nt("FileAudio",[["path",{d:"M17.5 22h.5a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v3",key:"rslqgf"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M2 19a2 2 0 1 1 4 0v1a2 2 0 1 1-4 0v-4a6 6 0 0 1 12 0v4a2 2 0 1 1-4 0v-1a2 2 0 1 1 4 0",key:"9f7x3i"}]]);/**
150
+ * @license lucide-react v0.436.0 - ISC
151
+ *
152
+ * This source code is licensed under the ISC license.
153
+ * See the LICENSE file in the root directory of this source tree.
154
+ */const Vee=Nt("File",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}]]);/**
155
+ * @license lucide-react v0.436.0 - ISC
156
+ *
157
+ * This source code is licensed under the ISC license.
158
+ * See the LICENSE file in the root directory of this source tree.
159
+ */const $ee=Nt("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
160
+ * @license lucide-react v0.436.0 - ISC
161
+ *
162
+ * This source code is licensed under the ISC license.
163
+ * See the LICENSE file in the root directory of this source tree.
164
+ */const Wee=Nt("Paperclip",[["path",{d:"m21.44 11.05-9.19 9.19a6 6 0 0 1-8.49-8.49l8.57-8.57A4 4 0 1 1 18 8.84l-8.59 8.57a2 2 0 0 1-2.83-2.83l8.49-8.48",key:"1u3ebp"}]]);/**
165
+ * @license lucide-react v0.436.0 - ISC
166
+ *
167
+ * This source code is licensed under the ISC license.
168
+ * See the LICENSE file in the root directory of this source tree.
169
+ */const Yee=Nt("RotateCcw",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]]);/**
170
+ * @license lucide-react v0.436.0 - ISC
171
+ *
172
+ * This source code is licensed under the ISC license.
173
+ * See the LICENSE file in the root directory of this source tree.
174
+ */const qee=Nt("SaveOff",[["path",{d:"M13 13H8a1 1 0 0 0-1 1v7",key:"h8g396"}],["path",{d:"M14 8h1",key:"1lfen6"}],["path",{d:"M17 21v-4",key:"1yknxs"}],["path",{d:"m2 2 20 20",key:"1ooewy"}],["path",{d:"M20.41 20.41A2 2 0 0 1 19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 .59-1.41",key:"1t4vdl"}],["path",{d:"M29.5 11.5s5 5 4 5",key:"zzn4i6"}],["path",{d:"M9 3h6.2a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V15",key:"24cby9"}]]);/**
175
+ * @license lucide-react v0.436.0 - ISC
176
+ *
177
+ * This source code is licensed under the ISC license.
178
+ * See the LICENSE file in the root directory of this source tree.
179
+ */const Gee=Nt("Save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);/**
180
+ * @license lucide-react v0.436.0 - ISC
181
+ *
182
+ * This source code is licensed under the ISC license.
183
+ * See the LICENSE file in the root directory of this source tree.
184
+ */const ZN=Nt("SendHorizontal",[["path",{d:"m3 3 3 9-3 9 19-9Z",key:"1aobqy"}],["path",{d:"M6 12h16",key:"s4cdu5"}]]);/**
185
+ * @license lucide-react v0.436.0 - ISC
186
+ *
187
+ * This source code is licensed under the ISC license.
188
+ * See the LICENSE file in the root directory of this source tree.
189
+ */const Kee=Nt("Volume2",[["path",{d:"M11 4.702a.705.705 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298z",key:"uqj9uw"}],["path",{d:"M16 9a5 5 0 0 1 0 6",key:"1q6k2b"}],["path",{d:"M19.364 18.364a9 9 0 0 0 0-12.728",key:"ijwkga"}]]);/**
190
+ * @license lucide-react v0.436.0 - ISC
191
+ *
192
+ * This source code is licensed under the ISC license.
193
+ * See the LICENSE file in the root directory of this source tree.
194
+ */const Xee=Nt("VolumeOff",[["path",{d:"M16 9a5 5 0 0 1 .95 2.293",key:"1fgyg8"}],["path",{d:"M19.364 5.636a9 9 0 0 1 1.889 9.96",key:"l3zxae"}],["path",{d:"m2 2 20 20",key:"1ooewy"}],["path",{d:"m7 7-.587.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298V11",key:"1gbwow"}],["path",{d:"M9.828 4.172A.686.686 0 0 1 11 4.657v.686",key:"s2je0y"}]]);/**
195
+ * @license lucide-react v0.436.0 - ISC
196
+ *
197
+ * This source code is licensed under the ISC license.
198
+ * See the LICENSE file in the root directory of this source tree.
199
+ */const JN=Nt("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);function Qee({children:e,user:t,message:n}){var i,a,o;const r=y.useMemo(()=>n.deliveredAt?Pee(new Date(n.deliveredAt),new Date,{addSuffix:!0}):null,[n.deliveredAt]);return E.jsxs("div",{className:"flex flex-row w-full gap-2 justify-end items-start group",children:[E.jsx("div",{className:"flex flex-col items-end gap-1 relative",children:E.jsxs("div",{className:"max-w-[85%] min-w-fit",children:[E.jsx("div",{className:"bg-primary p-2 text-primary-foreground rounded-xl leading-relaxed text-sm",children:e}),n.attachments&&n.attachments.length>0&&E.jsx("div",{className:"flex gap-1 flex-wrap mb-1",children:(i=n.attachments)==null?void 0:i.map(s=>E.jsx(jA,{attachment:s},s.id))}),r&&E.jsxs("div",{className:"flex items-center justify-end gap-1 mt-1 text-[10px] text-zinc-500 opacity-0 group-hover:opacity-100 transition-opacity duration-200",children:[E.jsx("span",{children:r}),E.jsx(QN,{className:"size-3"})]})]})}),E.jsxs(cp,{className:"size-8 ring-2 ring-white shadow-sm",children:[E.jsx(wy,{src:t==null?void 0:t.avatarUrl,className:"object-cover",alt:(t==null?void 0:t.name)||"User avatar"}),E.jsx(yy,{className:"bg-zinc-100 text-zinc-600 text-xs font-medium",children:((o=(a=t==null?void 0:t.name)==null?void 0:a.slice(0,2))==null?void 0:o.toUpperCase())||"U"})]})]})}function eO(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=eO(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Zee(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=eO(e))&&(r&&(r+=" "),r+=t);return r}const tO=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,nO=Zee,Jee=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return nO(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:i,defaultVariants:a}=t,o=Object.keys(i).map(u=>{const c=n==null?void 0:n[u],d=a==null?void 0:a[u];if(c===null)return null;const f=tO(c)||tO(d);return i[u][f]}),s=n&&Object.entries(n).reduce((u,c)=>{let[d,f]=c;return f===void 0||(u[d]=f),u},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((u,c)=>{let{class:d,className:f,...p}=c;return Object.entries(p).every(g=>{let[w,x]=g;return Array.isArray(x)?x.includes({...a,...s}[w]):{...a,...s}[w]===x})?[...u,d,f]:u},[]);return nO(e,o,l,n==null?void 0:n.class,n==null?void 0:n.className)},rO={x:2,y:2},ete={1:"scale-[1]","1.01":"scale-[1.01]","1.02":"scale-[1.02]","1.1":"scale-[1.1]"},oc=y.memo(y.forwardRef(({children:e,className:t,scale:n="1.02",off:r=!1},i)=>{const[a,o]=y.useState(!1),[s,l]=y.useState({x:0,y:0});if(r||/translate/.test(e.props.className||""))return e;const c=g=>{var P,B;const{clientX:w,clientY:x}=g,m=g.currentTarget.getBoundingClientRect(),v=w-(m.left+m.width/2),b=x-(m.top+m.height/2),T=Math.max(-1,Math.min(1,v/(m.width/2))),_=Math.max(-1,Math.min(1,b/(m.height/2))),S=T*rO.x,R=_*rO.y;l({x:S,y:R}),(B=(P=e.props).onMouseMove)==null||B.call(P,g)},d=()=>{var g,w;o(!0),(w=(g=e.props).onMouseEnter)==null||w.call(g)},f=()=>{var g,w;o(!1),l({x:0,y:0}),(w=(g=e.props).onMouseLeave)==null||w.call(g)},p={"--opencx-wobble-x":a?`${s.x}px`:"0px","--opencx-wobble-y":a?`${s.y}px`:"0px"};return y.cloneElement(e,{ref:i,onMouseMove:c,onMouseEnter:d,onMouseLeave:f,style:{...p,...e.props.style},className:He("translate-x-[var(--opencx-wobble-x)]","translate-y-[var(--opencx-wobble-y)]",`hover:${ete[n]}`,t,e.props.className,"transition-all ease-out")})}));oc.displayName="Wobble";const tte=Jee(He("inline-flex shrink-0 items-center justify-center gap-2","text-sm font-medium whitespace-nowrap","ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50","shadow-sm active:shadow-none active:scale-95 hover:active:scale-95","rounded-xl","border","transition"),{variants:{variant:{default:"border-primary bg-primary text-primary-foreground",destructive:"border-destructive bg-destructive text-destructive-foreground",outline:"bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground",ghost:"border-transparent shadow-none hover:bg-accent hover:text-accent-foreground",link:"border-transparent shadow-none text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-8 px-3 text-xs",lg:"h-11 px-8",icon:"h-10 w-10",fit:"size-fit p-2"}},defaultVariants:{variant:"default",size:"default"}}),uo=y.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...i},a)=>{const o=r?bf:"button";return E.jsx(oc,{ref:a,children:E.jsx(o,{className:He(tte({variant:t,size:n,className:e})),...i})})});uo.displayName="Button";function nte({options:e,onKeyboardClick:t}){return E.jsx("div",{className:"flex items-center gap-2 p-2 flex-wrap",children:e.map((n,r)=>E.jsx(uo,{onClick:()=>t(n),className:"flex-1 rounded-full",size:"sm",children:n},r))})}function Me(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e==null||e(i),n===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function iO(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Fp(...e){return t=>{let n=!1;const r=e.map(i=>{const a=iO(i,t);return!n&&typeof a=="function"&&(n=!0),a});if(n)return()=>{for(let i=0;i<r.length;i++){const a=r[i];typeof a=="function"?a():iO(e[i],null)}}}}function wn(...e){return y.useCallback(Fp(...e),e)}var sc=y.forwardRef((e,t)=>{const{children:n,...r}=e,i=y.Children.toArray(n),a=i.find(ite);if(a){const o=a.props.children,s=i.map(l=>l===a?y.Children.count(o)>1?y.Children.only(null):y.isValidElement(o)?o.props.children:null:l);return E.jsx(O1,{...r,ref:t,children:y.isValidElement(o)?y.cloneElement(o,void 0,s):null})}return E.jsx(O1,{...r,ref:t,children:n})});sc.displayName="Slot";var O1=y.forwardRef((e,t)=>{const{children:n,...r}=e;if(y.isValidElement(n)){const i=ote(n);return y.cloneElement(n,{...ate(r,n.props),ref:t?Fp(t,i):i})}return y.Children.count(n)>1?y.Children.only(null):null});O1.displayName="SlotClone";var rte=({children:e})=>E.jsx(E.Fragment,{children:e});function ite(e){return y.isValidElement(e)&&e.type===rte}function ate(e,t){const n={...t};for(const r in t){const i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...s)=>{a(...s),i(...s)}:i&&(n[r]=i):r==="style"?n[r]={...i,...a}:r==="className"&&(n[r]=[i,a].filter(Boolean).join(" "))}return{...e,...n}}function ote(e){var r,i;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var ste=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],yn=ste.reduce((e,t)=>{const n=y.forwardRef((r,i)=>{const{asChild:a,...o}=r,s=a?sc:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),E.jsx(s,{...o,ref:i})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function aO(e,t){e&&is.flushSync(()=>e.dispatchEvent(t))}function oO(e){const t=e+"CollectionProvider",[n,r]=Zr(t),[i,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=p=>{const{scope:g,children:w}=p,x=_t.useRef(null),m=_t.useRef(new Map).current;return E.jsx(i,{scope:g,itemMap:m,collectionRef:x,children:w})};o.displayName=t;const s=e+"CollectionSlot",l=_t.forwardRef((p,g)=>{const{scope:w,children:x}=p,m=a(s,w),v=wn(g,m.collectionRef);return E.jsx(sc,{ref:v,children:x})});l.displayName=s;const u=e+"CollectionItemSlot",c="data-radix-collection-item",d=_t.forwardRef((p,g)=>{const{scope:w,children:x,...m}=p,v=_t.useRef(null),b=wn(g,v),T=a(u,w);return _t.useEffect(()=>(T.itemMap.set(v,{ref:v,...m}),()=>void T.itemMap.delete(v))),E.jsx(sc,{[c]:"",ref:b,children:x})});d.displayName=u;function f(p){const g=a(e+"CollectionConsumer",p);return _t.useCallback(()=>{const x=g.collectionRef.current;if(!x)return[];const m=Array.from(x.querySelectorAll(`[${c}]`));return Array.from(g.itemMap.values()).sort((T,_)=>m.indexOf(T.ref.current)-m.indexOf(_.ref.current))},[g.collectionRef,g.itemMap])}return[{Provider:o,Slot:l,ItemSlot:d},f,r]}var lte=y.createContext(void 0);function sO(e){const t=y.useContext(lte);return e||t||"ltr"}var ute="DismissableLayer",P1="dismissableLayer.update",cte="dismissableLayer.pointerDownOutside",dte="dismissableLayer.focusOutside",lO,uO=y.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),cO=y.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:o,onDismiss:s,...l}=e,u=y.useContext(uO),[c,d]=y.useState(null),f=(c==null?void 0:c.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,p]=y.useState({}),g=wn(t,R=>d(R)),w=Array.from(u.layers),[x]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),m=w.indexOf(x),v=c?w.indexOf(c):-1,b=u.layersWithOutsidePointerEventsDisabled.size>0,T=v>=m,_=hte(R=>{const P=R.target,B=[...u.branches].some(N=>N.contains(P));!T||B||(i==null||i(R),o==null||o(R),R.defaultPrevented||s==null||s())},f),S=mte(R=>{const P=R.target;[...u.branches].some(N=>N.contains(P))||(a==null||a(R),o==null||o(R),R.defaultPrevented||s==null||s())},f);return S_(R=>{v===u.layers.size-1&&(r==null||r(R),!R.defaultPrevented&&s&&(R.preventDefault(),s()))},f),y.useEffect(()=>{if(c)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(lO=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(c)),u.layers.add(c),dO(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=lO)}},[c,f,n,u]),y.useEffect(()=>()=>{c&&(u.layers.delete(c),u.layersWithOutsidePointerEventsDisabled.delete(c),dO())},[c,u]),y.useEffect(()=>{const R=()=>p({});return document.addEventListener(P1,R),()=>document.removeEventListener(P1,R)},[]),E.jsx(yn.div,{...l,ref:g,style:{pointerEvents:b?T?"auto":"none":void 0,...e.style},onFocusCapture:Me(e.onFocusCapture,S.onFocusCapture),onBlurCapture:Me(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:Me(e.onPointerDownCapture,_.onPointerDownCapture)})});cO.displayName=ute;var fte="DismissableLayerBranch",pte=y.forwardRef((e,t)=>{const n=y.useContext(uO),r=y.useRef(null),i=wn(t,r);return y.useEffect(()=>{const a=r.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),E.jsx(yn.div,{...e,ref:i})});pte.displayName=fte;function hte(e,t=globalThis==null?void 0:globalThis.document){const n=Dt(e),r=y.useRef(!1),i=y.useRef(()=>{});return y.useEffect(()=>{const a=s=>{if(s.target&&!r.current){let l=function(){fO(cte,n,u,{discrete:!0})};const u={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=l,t.addEventListener("click",i.current,{once:!0})):l()}else t.removeEventListener("click",i.current);r.current=!1},o=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",a),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function mte(e,t=globalThis==null?void 0:globalThis.document){const n=Dt(e),r=y.useRef(!1);return y.useEffect(()=>{const i=a=>{a.target&&!r.current&&fO(dte,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function dO(){const e=new CustomEvent(P1);document.dispatchEvent(e)}function fO(e,t,n,{discrete:r}){const i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?aO(i,a):i.dispatchEvent(a)}var I1=0;function pO(){y.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??hO()),document.body.insertAdjacentElement("beforeend",e[1]??hO()),I1++,()=>{I1===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),I1--}},[])}function hO(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var D1="focusScope.autoFocusOnMount",L1="focusScope.autoFocusOnUnmount",mO={bubbles:!1,cancelable:!0},gte="FocusScope",gO=y.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,l]=y.useState(null),u=Dt(i),c=Dt(a),d=y.useRef(null),f=wn(t,w=>l(w)),p=y.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;y.useEffect(()=>{if(r){let w=function(b){if(p.paused||!s)return;const T=b.target;s.contains(T)?d.current=T:ba(d.current,{select:!0})},x=function(b){if(p.paused||!s)return;const T=b.relatedTarget;T!==null&&(s.contains(T)||ba(d.current,{select:!0}))},m=function(b){if(document.activeElement===document.body)for(const _ of b)_.removedNodes.length>0&&ba(s)};document.addEventListener("focusin",w),document.addEventListener("focusout",x);const v=new MutationObserver(m);return s&&v.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",w),document.removeEventListener("focusout",x),v.disconnect()}}},[r,s,p.paused]),y.useEffect(()=>{if(s){vO.add(p);const w=document.activeElement;if(!s.contains(w)){const m=new CustomEvent(D1,mO);s.addEventListener(D1,u),s.dispatchEvent(m),m.defaultPrevented||(wte(Ete(wO(s)),{select:!0}),document.activeElement===w&&ba(s))}return()=>{s.removeEventListener(D1,u),setTimeout(()=>{const m=new CustomEvent(L1,mO);s.addEventListener(L1,c),s.dispatchEvent(m),m.defaultPrevented||ba(w??document.body,{select:!0}),s.removeEventListener(L1,c),vO.remove(p)},0)}}},[s,u,c,p]);const g=y.useCallback(w=>{if(!n&&!r||p.paused)return;const x=w.key==="Tab"&&!w.altKey&&!w.ctrlKey&&!w.metaKey,m=document.activeElement;if(x&&m){const v=w.currentTarget,[b,T]=yte(v);b&&T?!w.shiftKey&&m===T?(w.preventDefault(),n&&ba(b,{select:!0})):w.shiftKey&&m===b&&(w.preventDefault(),n&&ba(T,{select:!0})):m===v&&w.preventDefault()}},[n,r,p.paused]);return E.jsx(yn.div,{tabIndex:-1,...o,ref:f,onKeyDown:g})});gO.displayName=gte;function wte(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(ba(r,{select:t}),document.activeElement!==n)return}function yte(e){const t=wO(e),n=yO(t,e),r=yO(t.reverse(),e);return[n,r]}function wO(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function yO(e,t){for(const n of e)if(!vte(n,{upTo:t}))return n}function vte(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function bte(e){return e instanceof HTMLInputElement&&"select"in e}function ba(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&bte(e)&&t&&e.select()}}var vO=xte();function xte(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=bO(e,t),e.unshift(t)},remove(t){var n;e=bO(e,t),(n=e[0])==null||n.resume()}}}function bO(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Ete(e){return e.filter(t=>t.tagName!=="A")}var Tte="Arrow",xO=y.forwardRef((e,t)=>{const{children:n,width:r=10,height:i=5,...a}=e;return E.jsx(yn.svg,{...a,ref:t,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:E.jsx("polygon",{points:"0,0 30,0 15,10"})})});xO.displayName=Tte;var _te=xO,M1="Popper",[EO,TO]=Zr(M1),[Ste,_O]=EO(M1),SO=e=>{const{__scopePopper:t,children:n}=e,[r,i]=y.useState(null);return E.jsx(Ste,{scope:t,anchor:r,onAnchorChange:i,children:n})};SO.displayName=M1;var kO="PopperAnchor",CO=y.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...i}=e,a=_O(kO,n),o=y.useRef(null),s=wn(t,o);return y.useEffect(()=>{a.onAnchorChange((r==null?void 0:r.current)||o.current)}),r?null:E.jsx(yn.div,{...i,ref:s})});CO.displayName=kO;var F1="PopperContent",[kte,Cte]=EO(F1),AO=y.forwardRef((e,t)=>{var de,Se,Ce,Re,vt,xe;const{__scopePopper:n,side:r="bottom",sideOffset:i=0,align:a="center",alignOffset:o=0,arrowPadding:s=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:c=0,sticky:d="partial",hideWhenDetached:f=!1,updatePositionStrategy:p="optimized",onPlaced:g,...w}=e,x=_O(F1,n),[m,v]=y.useState(null),b=wn(t,we=>v(we)),[T,_]=y.useState(null),S=iw(T),R=(S==null?void 0:S.width)??0,P=(S==null?void 0:S.height)??0,B=r+(a!=="center"?"-"+a:""),N=typeof c=="number"?c:{top:0,right:0,bottom:0,left:0,...c},H=Array.isArray(u)?u:[u],U=H.length>0,K={padding:N,boundary:H.filter(Rte),altBoundary:U},{refs:X,floatingStyles:ee,placement:oe,isPositioned:ne,middlewareData:L}=q_({strategy:"fixed",placement:B,whileElementsMounted:(...we)=>V_(...we,{animationFrame:p==="always"}),elements:{reference:x.anchor},middleware:[G_({mainAxis:i+P,alignmentAxis:o}),l&&K_({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?X_():void 0,...K}),l&&Q_({...K}),Z_({...K,apply:({elements:we,rects:Ve,availableWidth:je,availableHeight:bt})=>{const{width:xt,height:Ke}=Ve.reference,ze=we.floating.style;ze.setProperty("--radix-popper-available-width",`${je}px`),ze.setProperty("--radix-popper-available-height",`${bt}px`),ze.setProperty("--radix-popper-anchor-width",`${xt}px`),ze.setProperty("--radix-popper-anchor-height",`${Ke}px`)}}),T&&eS({element:T,padding:s}),Nte({arrowWidth:R,arrowHeight:P}),f&&J_({strategy:"referenceHidden",...K})]}),[F,C]=OO(oe),te=Dt(g);$n(()=>{ne&&(te==null||te())},[ne,te]);const fe=(de=L.arrow)==null?void 0:de.x,I=(Se=L.arrow)==null?void 0:Se.y,ke=((Ce=L.arrow)==null?void 0:Ce.centerOffset)!==0,[Ye,J]=y.useState();return $n(()=>{m&&J(window.getComputedStyle(m).zIndex)},[m]),E.jsx("div",{ref:X.setFloating,"data-radix-popper-content-wrapper":"",style:{...ee,transform:ne?ee.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Ye,"--radix-popper-transform-origin":[(Re=L.transformOrigin)==null?void 0:Re.x,(vt=L.transformOrigin)==null?void 0:vt.y].join(" "),...((xe=L.hide)==null?void 0:xe.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:E.jsx(kte,{scope:n,placedSide:F,onArrowChange:_,arrowX:fe,arrowY:I,shouldHideArrow:ke,children:E.jsx(yn.div,{"data-side":F,"data-align":C,...w,ref:b,style:{...w.style,animation:ne?void 0:"none"}})})})});AO.displayName=F1;var RO="PopperArrow",Ate={top:"bottom",right:"left",bottom:"top",left:"right"},NO=y.forwardRef(function(t,n){const{__scopePopper:r,...i}=t,a=Cte(RO,r),o=Ate[a.placedSide];return E.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:E.jsx(_te,{...i,ref:n,style:{...i.style,display:"block"}})})});NO.displayName=RO;function Rte(e){return e!==null}var Nte=e=>({name:"transformOrigin",options:e,fn(t){var x,m,v;const{placement:n,rects:r,middlewareData:i}=t,o=((x=i.arrow)==null?void 0:x.centerOffset)!==0,s=o?0:e.arrowWidth,l=o?0:e.arrowHeight,[u,c]=OO(n),d={start:"0%",center:"50%",end:"100%"}[c],f=(((m=i.arrow)==null?void 0:m.x)??0)+s/2,p=(((v=i.arrow)==null?void 0:v.y)??0)+l/2;let g="",w="";return u==="bottom"?(g=o?d:`${f}px`,w=`${-l}px`):u==="top"?(g=o?d:`${f}px`,w=`${r.floating.height+l}px`):u==="right"?(g=`${-l}px`,w=o?d:`${p}px`):u==="left"&&(g=`${r.floating.width+l}px`,w=o?d:`${p}px`),{data:{x:g,y:w}}}});function OO(e){const[t,n="center"]=e.split("-");return[t,n]}var Ote=SO,Pte=CO,Ite=AO,Dte=NO;function Lte(e,t){return y.useReducer((n,r)=>t[n][r]??n,e)}var Bp=e=>{const{present:t,children:n}=e,r=Mte(t),i=typeof n=="function"?n({present:r.isPresent}):y.Children.only(n),a=wn(r.ref,Fte(i));return typeof n=="function"||r.isPresent?y.cloneElement(i,{ref:a}):null};Bp.displayName="Presence";function Mte(e){const[t,n]=y.useState(),r=y.useRef({}),i=y.useRef(e),a=y.useRef("none"),o=e?"mounted":"unmounted",[s,l]=Lte(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return y.useEffect(()=>{const u=jp(r.current);a.current=s==="mounted"?u:"none"},[s]),$n(()=>{const u=r.current,c=i.current;if(c!==e){const f=a.current,p=jp(u);e?l("MOUNT"):p==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(c&&f!==p?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,l]),$n(()=>{if(t){let u;const c=t.ownerDocument.defaultView??window,d=p=>{const w=jp(r.current).includes(p.animationName);if(p.target===t&&w&&(l("ANIMATION_END"),!i.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",u=c.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},f=p=>{p.target===t&&(a.current=jp(r.current))};return t.addEventListener("animationstart",f),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{c.clearTimeout(u),t.removeEventListener("animationstart",f),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:y.useCallback(u=>{u&&(r.current=getComputedStyle(u)),n(u)},[])}}function jp(e){return(e==null?void 0:e.animationName)||"none"}function Fte(e){var r,i;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var B1="rovingFocusGroup.onEntryFocus",Bte={bubbles:!1,cancelable:!0},zp="RovingFocusGroup",[j1,PO,jte]=oO(zp),[zte,IO]=Zr(zp,[jte]),[Ute,Hte]=zte(zp),DO=y.forwardRef((e,t)=>E.jsx(j1.Provider,{scope:e.__scopeRovingFocusGroup,children:E.jsx(j1.Slot,{scope:e.__scopeRovingFocusGroup,children:E.jsx(Vte,{...e,ref:t})})}));DO.displayName=zp;var Vte=y.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:a,currentTabStopId:o,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:l,onEntryFocus:u,preventScrollOnEntryFocus:c=!1,...d}=e,f=y.useRef(null),p=wn(t,f),g=sO(a),[w=null,x]=vu({prop:o,defaultProp:s,onChange:l}),[m,v]=y.useState(!1),b=Dt(u),T=PO(n),_=y.useRef(!1),[S,R]=y.useState(0);return y.useEffect(()=>{const P=f.current;if(P)return P.addEventListener(B1,b),()=>P.removeEventListener(B1,b)},[b]),E.jsx(Ute,{scope:n,orientation:r,dir:g,loop:i,currentTabStopId:w,onItemFocus:y.useCallback(P=>x(P),[x]),onItemShiftTab:y.useCallback(()=>v(!0),[]),onFocusableItemAdd:y.useCallback(()=>R(P=>P+1),[]),onFocusableItemRemove:y.useCallback(()=>R(P=>P-1),[]),children:E.jsx(yn.div,{tabIndex:m||S===0?-1:0,"data-orientation":r,...d,ref:p,style:{outline:"none",...e.style},onMouseDown:Me(e.onMouseDown,()=>{_.current=!0}),onFocus:Me(e.onFocus,P=>{const B=!_.current;if(P.target===P.currentTarget&&B&&!m){const N=new CustomEvent(B1,Bte);if(P.currentTarget.dispatchEvent(N),!N.defaultPrevented){const H=T().filter(oe=>oe.focusable),U=H.find(oe=>oe.active),K=H.find(oe=>oe.id===w),ee=[U,K,...H].filter(Boolean).map(oe=>oe.ref.current);FO(ee,c)}}_.current=!1}),onBlur:Me(e.onBlur,()=>v(!1))})})}),LO="RovingFocusGroupItem",MO=y.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:a,...o}=e,s=mu(),l=a||s,u=Hte(LO,n),c=u.currentTabStopId===l,d=PO(n),{onFocusableItemAdd:f,onFocusableItemRemove:p}=u;return y.useEffect(()=>{if(r)return f(),()=>p()},[r,f,p]),E.jsx(j1.ItemSlot,{scope:n,id:l,focusable:r,active:i,children:E.jsx(yn.span,{tabIndex:c?0:-1,"data-orientation":u.orientation,...o,ref:t,onMouseDown:Me(e.onMouseDown,g=>{r?u.onItemFocus(l):g.preventDefault()}),onFocus:Me(e.onFocus,()=>u.onItemFocus(l)),onKeyDown:Me(e.onKeyDown,g=>{if(g.key==="Tab"&&g.shiftKey){u.onItemShiftTab();return}if(g.target!==g.currentTarget)return;const w=Yte(g,u.orientation,u.dir);if(w!==void 0){if(g.metaKey||g.ctrlKey||g.altKey||g.shiftKey)return;g.preventDefault();let m=d().filter(v=>v.focusable).map(v=>v.ref.current);if(w==="last")m.reverse();else if(w==="prev"||w==="next"){w==="prev"&&m.reverse();const v=m.indexOf(g.currentTarget);m=u.loop?qte(m,v+1):m.slice(v+1)}setTimeout(()=>FO(m))}})})})});MO.displayName=LO;var $te={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Wte(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Yte(e,t,n){const r=Wte(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return $te[r]}function FO(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function qte(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Gte=DO,Kte=MO,Xte=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Ps=new WeakMap,Up=new WeakMap,Hp={},z1=0,BO=function(e){return e&&(e.host||BO(e.parentNode))},Qte=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=BO(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Zte=function(e,t,n,r){var i=Qte(t,Array.isArray(e)?e:[e]);Hp[n]||(Hp[n]=new WeakMap);var a=Hp[n],o=[],s=new Set,l=new Set(i),u=function(d){!d||s.has(d)||(s.add(d),u(d.parentNode))};i.forEach(u);var c=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(f){if(s.has(f))c(f);else try{var p=f.getAttribute(r),g=p!==null&&p!=="false",w=(Ps.get(f)||0)+1,x=(a.get(f)||0)+1;Ps.set(f,w),a.set(f,x),o.push(f),w===1&&g&&Up.set(f,!0),x===1&&f.setAttribute(n,"true"),g||f.setAttribute(r,"true")}catch(m){console.error("aria-hidden: cannot operate on ",f,m)}})};return c(t),s.clear(),z1++,function(){o.forEach(function(d){var f=Ps.get(d)-1,p=a.get(d)-1;Ps.set(d,f),a.set(d,p),f||(Up.has(d)||d.removeAttribute(r),Up.delete(d)),p||d.removeAttribute(n)}),z1--,z1||(Ps=new WeakMap,Ps=new WeakMap,Up=new WeakMap,Hp={})}},jO=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),i=Xte(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live]"))),Zte(r,i,n,"aria-hidden")):function(){return null}},Vp="right-scroll-bar-position",$p="width-before-scroll-bar",Jte="with-scroll-bars-hidden",ene="--removed-body-scroll-bar-size";function U1(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function tne(e,t){var n=y.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=t,n.facade}var nne=typeof window<"u"?y.useLayoutEffect:y.useEffect,zO=new WeakMap;function rne(e,t){var n=tne(null,function(r){return e.forEach(function(i){return U1(i,r)})});return nne(function(){var r=zO.get(n);if(r){var i=new Set(r),a=new Set(e),o=n.current;i.forEach(function(s){a.has(s)||U1(s,null)}),a.forEach(function(s){i.has(s)||U1(s,o)})}zO.set(n,e)},[e]),n}function ine(e){return e}function ane(e,t){t===void 0&&(t=ine);var n=[],r=!1,i={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(a){var o=t(a,r);return n.push(o),function(){n=n.filter(function(s){return s!==o})}},assignSyncMedium:function(a){for(r=!0;n.length;){var o=n;n=[],o.forEach(a)}n={push:function(s){return a(s)},filter:function(){return n}}},assignMedium:function(a){r=!0;var o=[];if(n.length){var s=n;n=[],s.forEach(a),o=n}var l=function(){var c=o;o=[],c.forEach(a)},u=function(){return Promise.resolve().then(l)};u(),n={push:function(c){o.push(c),u()},filter:function(c){return o=o.filter(c),n}}}};return i}function UO(e){e===void 0&&(e={});var t=ane(null);return t.options=St({async:!0,ssr:!1},e),t}var HO=function(e){var t=e.sideCar,n=Zs(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return y.createElement(r,St({},n))};HO.isSideCarExport=!0;function VO(e,t){return e.useMedium(t),HO}var $O=UO(),H1=function(){},Wp=y.forwardRef(function(e,t){var n=y.useRef(null),r=y.useState({onScrollCapture:H1,onWheelCapture:H1,onTouchMoveCapture:H1}),i=r[0],a=r[1],o=e.forwardProps,s=e.children,l=e.className,u=e.removeScrollBar,c=e.enabled,d=e.shards,f=e.sideCar,p=e.noIsolation,g=e.inert,w=e.allowPinchZoom,x=e.as,m=x===void 0?"div":x,v=e.gapMode,b=Zs(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),T=f,_=rne([n,t]),S=St(St({},b),i);return y.createElement(y.Fragment,null,c&&y.createElement(T,{sideCar:$O,removeScrollBar:u,shards:d,noIsolation:p,inert:g,setCallbacks:a,allowPinchZoom:!!w,lockRef:n,gapMode:v}),o?y.cloneElement(y.Children.only(s),St(St({},S),{ref:_})):y.createElement(m,St({},S,{className:l,ref:_}),s))});Wp.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Wp.classNames={fullWidth:$p,zeroRight:Vp};var WO=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function one(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=WO();return t&&e.setAttribute("nonce",t),e}function sne(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function lne(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var une=function(){var e=0,t=null;return{add:function(n){e==0&&(t=one())&&(sne(t,n),lne(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},cne=function(){var e=une();return function(t,n){y.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},dne=function(){var e=cne(),t=function(n){var r=n.styles,i=n.dynamic;return e(r,i),null};return t},fne={left:0,top:0,right:0,gap:0},V1=function(e){return parseInt(e||"",10)||0},pne=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[V1(n),V1(r),V1(i)]},hne=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return fne;var t=pne(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},mne=dne(),Is="data-scroll-locked",gne=function(e,t,n,r){var i=e.left,a=e.top,o=e.right,s=e.gap;return n===void 0&&(n="margin"),`
200
+ .`.concat(Jte,` {
201
+ overflow: hidden `).concat(r,`;
202
+ padding-right: `).concat(s,"px ").concat(r,`;
203
+ }
204
+ body[`).concat(Is,`] {
205
+ overflow: hidden `).concat(r,`;
206
+ overscroll-behavior: contain;
207
+ `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
208
+ padding-left: `.concat(i,`px;
209
+ padding-top: `).concat(a,`px;
210
+ padding-right: `).concat(o,`px;
211
+ margin-left:0;
212
+ margin-top:0;
213
+ margin-right: `).concat(s,"px ").concat(r,`;
214
+ `),n==="padding"&&"padding-right: ".concat(s,"px ").concat(r,";")].filter(Boolean).join(""),`
215
+ }
216
+
217
+ .`).concat(Vp,` {
218
+ right: `).concat(s,"px ").concat(r,`;
219
+ }
220
+
221
+ .`).concat($p,` {
222
+ margin-right: `).concat(s,"px ").concat(r,`;
223
+ }
224
+
225
+ .`).concat(Vp," .").concat(Vp,` {
226
+ right: 0 `).concat(r,`;
227
+ }
228
+
229
+ .`).concat($p," .").concat($p,` {
230
+ margin-right: 0 `).concat(r,`;
231
+ }
232
+
233
+ body[`).concat(Is,`] {
234
+ `).concat(ene,": ").concat(s,`px;
235
+ }
236
+ `)},YO=function(){var e=parseInt(document.body.getAttribute(Is)||"0",10);return isFinite(e)?e:0},wne=function(){y.useEffect(function(){return document.body.setAttribute(Is,(YO()+1).toString()),function(){var e=YO()-1;e<=0?document.body.removeAttribute(Is):document.body.setAttribute(Is,e.toString())}},[])},yne=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?"margin":r;wne();var a=y.useMemo(function(){return hne(i)},[i]);return y.createElement(mne,{styles:gne(a,!t,i,n?"":"!important")})};function vne(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=WO();return t&&e.setAttribute("nonce",t),e}function bne(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function xne(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Ene=function(){var e=0,t=null;return{add:function(n){e==0&&(t=vne())&&(bne(t,n),xne(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Tne=function(){var e=Ene();return function(t,n){y.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},$1=function(){var e=Tne(),t=function(n){var r=n.styles,i=n.dynamic;return e(r,i),null};return t},W1=!1;if(typeof window<"u")try{var Yp=Object.defineProperty({},"passive",{get:function(){return W1=!0,!0}});window.addEventListener("test",Yp,Yp),window.removeEventListener("test",Yp,Yp)}catch{W1=!1}var Ds=W1?{passive:!1}:!1,_ne=function(e){return e.tagName==="TEXTAREA"},qO=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!_ne(e)&&n[t]==="visible")},Sne=function(e){return qO(e,"overflowY")},kne=function(e){return qO(e,"overflowX")},GO=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var i=KO(e,r);if(i){var a=XO(e,r),o=a[1],s=a[2];if(o>s)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},Cne=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},Ane=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},KO=function(e,t){return e==="v"?Sne(t):kne(t)},XO=function(e,t){return e==="v"?Cne(t):Ane(t)},Rne=function(e,t){return e==="h"&&t==="rtl"?-1:1},Nne=function(e,t,n,r,i){var a=Rne(e,window.getComputedStyle(t).direction),o=a*r,s=n.target,l=t.contains(s),u=!1,c=o>0,d=0,f=0;do{var p=XO(e,s),g=p[0],w=p[1],x=p[2],m=w-x-a*g;(g||m)&&KO(e,s)&&(d+=m,f+=g),s instanceof ShadowRoot?s=s.host:s=s.parentNode}while(!l&&s!==document.body||l&&(t.contains(s)||t===s));return(c&&(Math.abs(d)<1||!i)||!c&&(Math.abs(f)<1||!i))&&(u=!0),u},qp=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},QO=function(e){return[e.deltaX,e.deltaY]},ZO=function(e){return e&&"current"in e?e.current:e},One=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Pne=function(e){return`
237
+ .block-interactivity-`.concat(e,` {pointer-events: none;}
238
+ .allow-interactivity-`).concat(e,` {pointer-events: all;}
239
+ `)},Ine=0,Ls=[];function Dne(e){var t=y.useRef([]),n=y.useRef([0,0]),r=y.useRef(),i=y.useState(Ine++)[0],a=y.useState($1)[0],o=y.useRef(e);y.useEffect(function(){o.current=e},[e]),y.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var w=Pc([e.lockRef.current],(e.shards||[]).map(ZO),!0).filter(Boolean);return w.forEach(function(x){return x.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),w.forEach(function(x){return x.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var s=y.useCallback(function(w,x){if("touches"in w&&w.touches.length===2||w.type==="wheel"&&w.ctrlKey)return!o.current.allowPinchZoom;var m=qp(w),v=n.current,b="deltaX"in w?w.deltaX:v[0]-m[0],T="deltaY"in w?w.deltaY:v[1]-m[1],_,S=w.target,R=Math.abs(b)>Math.abs(T)?"h":"v";if("touches"in w&&R==="h"&&S.type==="range")return!1;var P=GO(R,S);if(!P)return!0;if(P?_=R:(_=R==="v"?"h":"v",P=GO(R,S)),!P)return!1;if(!r.current&&"changedTouches"in w&&(b||T)&&(r.current=_),!_)return!0;var B=r.current||_;return Nne(B,x,w,B==="h"?b:T,!0)},[]),l=y.useCallback(function(w){var x=w;if(!(!Ls.length||Ls[Ls.length-1]!==a)){var m="deltaY"in x?QO(x):qp(x),v=t.current.filter(function(_){return _.name===x.type&&(_.target===x.target||x.target===_.shadowParent)&&One(_.delta,m)})[0];if(v&&v.should){x.cancelable&&x.preventDefault();return}if(!v){var b=(o.current.shards||[]).map(ZO).filter(Boolean).filter(function(_){return _.contains(x.target)}),T=b.length>0?s(x,b[0]):!o.current.noIsolation;T&&x.cancelable&&x.preventDefault()}}},[]),u=y.useCallback(function(w,x,m,v){var b={name:w,delta:x,target:m,should:v,shadowParent:Lne(m)};t.current.push(b),setTimeout(function(){t.current=t.current.filter(function(T){return T!==b})},1)},[]),c=y.useCallback(function(w){n.current=qp(w),r.current=void 0},[]),d=y.useCallback(function(w){u(w.type,QO(w),w.target,s(w,e.lockRef.current))},[]),f=y.useCallback(function(w){u(w.type,qp(w),w.target,s(w,e.lockRef.current))},[]);y.useEffect(function(){return Ls.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener("wheel",l,Ds),document.addEventListener("touchmove",l,Ds),document.addEventListener("touchstart",c,Ds),function(){Ls=Ls.filter(function(w){return w!==a}),document.removeEventListener("wheel",l,Ds),document.removeEventListener("touchmove",l,Ds),document.removeEventListener("touchstart",c,Ds)}},[]);var p=e.removeScrollBar,g=e.inert;return y.createElement(y.Fragment,null,g?y.createElement(a,{styles:Pne(i)}):null,p?y.createElement(yne,{gapMode:e.gapMode}):null)}function Lne(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const Mne=VO($O,Dne);var JO=y.forwardRef(function(e,t){return y.createElement(Wp,St({},e,{ref:t,sideCar:Mne}))});JO.classNames=Wp.classNames;var Y1=["Enter"," "],Fne=["ArrowDown","PageUp","Home"],eP=["ArrowUp","PageDown","End"],Bne=[...Fne,...eP],jne={ltr:[...Y1,"ArrowRight"],rtl:[...Y1,"ArrowLeft"]},zne={ltr:["ArrowLeft"],rtl:["ArrowRight"]},lc="Menu",[uc,Une,Hne]=oO(lc),[co,tP]=Zr(lc,[Hne,TO,IO]),Gp=TO(),nP=IO(),[Vne,Ms]=co(lc),[$ne,cc]=co(lc),rP=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:i,onOpenChange:a,modal:o=!0}=e,s=Gp(t),[l,u]=y.useState(null),c=y.useRef(!1),d=Dt(a),f=sO(i);return y.useEffect(()=>{const p=()=>{c.current=!0,document.addEventListener("pointerdown",g,{capture:!0,once:!0}),document.addEventListener("pointermove",g,{capture:!0,once:!0})},g=()=>c.current=!1;return document.addEventListener("keydown",p,{capture:!0}),()=>{document.removeEventListener("keydown",p,{capture:!0}),document.removeEventListener("pointerdown",g,{capture:!0}),document.removeEventListener("pointermove",g,{capture:!0})}},[]),E.jsx(Ote,{...s,children:E.jsx(Vne,{scope:t,open:n,onOpenChange:d,content:l,onContentChange:u,children:E.jsx($ne,{scope:t,onClose:y.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:c,dir:f,modal:o,children:r})})})};rP.displayName=lc;var Wne="MenuAnchor",q1=y.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,i=Gp(n);return E.jsx(Pte,{...i,...r,ref:t})});q1.displayName=Wne;var Yne="MenuPortal",[fle,iP]=co(Yne,{forceMount:void 0}),Qn="MenuContent",[qne,G1]=co(Qn),aP=y.forwardRef((e,t)=>{const n=iP(Qn,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,a=Ms(Qn,e.__scopeMenu),o=cc(Qn,e.__scopeMenu);return E.jsx(uc.Provider,{scope:e.__scopeMenu,children:E.jsx(Bp,{present:r||a.open,children:E.jsx(uc.Slot,{scope:e.__scopeMenu,children:o.modal?E.jsx(Gne,{...i,ref:t}):E.jsx(Kne,{...i,ref:t})})})})}),Gne=y.forwardRef((e,t)=>{const n=Ms(Qn,e.__scopeMenu),r=y.useRef(null),i=wn(t,r);return y.useEffect(()=>{const a=r.current;if(a)return jO(a)},[]),E.jsx(K1,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:Me(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),Kne=y.forwardRef((e,t)=>{const n=Ms(Qn,e.__scopeMenu);return E.jsx(K1,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),K1=y.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:i,onOpenAutoFocus:a,onCloseAutoFocus:o,disableOutsidePointerEvents:s,onEntryFocus:l,onEscapeKeyDown:u,onPointerDownOutside:c,onFocusOutside:d,onInteractOutside:f,onDismiss:p,disableOutsideScroll:g,...w}=e,x=Ms(Qn,n),m=cc(Qn,n),v=Gp(n),b=nP(n),T=Une(n),[_,S]=y.useState(null),R=y.useRef(null),P=wn(t,R,x.onContentChange),B=y.useRef(0),N=y.useRef(""),H=y.useRef(0),U=y.useRef(null),K=y.useRef("right"),X=y.useRef(0),ee=g?JO:y.Fragment,oe=g?{as:sc,allowPinchZoom:!0}:void 0,ne=F=>{var de,Se;const C=N.current+F,te=T().filter(Ce=>!Ce.disabled),fe=document.activeElement,I=(de=te.find(Ce=>Ce.ref.current===fe))==null?void 0:de.textValue,ke=te.map(Ce=>Ce.textValue),Ye=sre(ke,C,I),J=(Se=te.find(Ce=>Ce.textValue===Ye))==null?void 0:Se.ref.current;(function Ce(Re){N.current=Re,window.clearTimeout(B.current),Re!==""&&(B.current=window.setTimeout(()=>Ce(""),1e3))})(C),J&&setTimeout(()=>J.focus())};y.useEffect(()=>()=>window.clearTimeout(B.current),[]),pO();const L=y.useCallback(F=>{var te,fe;return K.current===((te=U.current)==null?void 0:te.side)&&ure(F,(fe=U.current)==null?void 0:fe.area)},[]);return E.jsx(qne,{scope:n,searchRef:N,onItemEnter:y.useCallback(F=>{L(F)&&F.preventDefault()},[L]),onItemLeave:y.useCallback(F=>{var C;L(F)||((C=R.current)==null||C.focus(),S(null))},[L]),onTriggerLeave:y.useCallback(F=>{L(F)&&F.preventDefault()},[L]),pointerGraceTimerRef:H,onPointerGraceIntentChange:y.useCallback(F=>{U.current=F},[]),children:E.jsx(ee,{...oe,children:E.jsx(gO,{asChild:!0,trapped:i,onMountAutoFocus:Me(a,F=>{var C;F.preventDefault(),(C=R.current)==null||C.focus({preventScroll:!0})}),onUnmountAutoFocus:o,children:E.jsx(cO,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:u,onPointerDownOutside:c,onFocusOutside:d,onInteractOutside:f,onDismiss:p,children:E.jsx(Gte,{asChild:!0,...b,dir:m.dir,orientation:"vertical",loop:r,currentTabStopId:_,onCurrentTabStopIdChange:S,onEntryFocus:Me(l,F=>{m.isUsingKeyboardRef.current||F.preventDefault()}),preventScrollOnEntryFocus:!0,children:E.jsx(Ite,{role:"menu","aria-orientation":"vertical","data-state":EP(x.open),"data-radix-menu-content":"",dir:m.dir,...v,...w,ref:P,style:{outline:"none",...w.style},onKeyDown:Me(w.onKeyDown,F=>{const te=F.target.closest("[data-radix-menu-content]")===F.currentTarget,fe=F.ctrlKey||F.altKey||F.metaKey,I=F.key.length===1;te&&(F.key==="Tab"&&F.preventDefault(),!fe&&I&&ne(F.key));const ke=R.current;if(F.target!==ke||!Bne.includes(F.key))return;F.preventDefault();const J=T().filter(de=>!de.disabled).map(de=>de.ref.current);eP.includes(F.key)&&J.reverse(),are(J)}),onBlur:Me(e.onBlur,F=>{F.currentTarget.contains(F.target)||(window.clearTimeout(B.current),N.current="")}),onPointerMove:Me(e.onPointerMove,fc(F=>{const C=F.target,te=X.current!==F.clientX;if(F.currentTarget.contains(C)&&te){const fe=F.clientX>X.current?"right":"left";K.current=fe,X.current=F.clientX}}))})})})})})})});aP.displayName=Qn;var Xne="MenuGroup",X1=y.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return E.jsx(yn.div,{role:"group",...r,ref:t})});X1.displayName=Xne;var Qne="MenuLabel",oP=y.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return E.jsx(yn.div,{...r,ref:t})});oP.displayName=Qne;var Kp="MenuItem",sP="menu.itemSelect",Xp=y.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...i}=e,a=y.useRef(null),o=cc(Kp,e.__scopeMenu),s=G1(Kp,e.__scopeMenu),l=wn(t,a),u=y.useRef(!1),c=()=>{const d=a.current;if(!n&&d){const f=new CustomEvent(sP,{bubbles:!0,cancelable:!0});d.addEventListener(sP,p=>r==null?void 0:r(p),{once:!0}),aO(d,f),f.defaultPrevented?u.current=!1:o.onClose()}};return E.jsx(lP,{...i,ref:l,disabled:n,onClick:Me(e.onClick,c),onPointerDown:d=>{var f;(f=e.onPointerDown)==null||f.call(e,d),u.current=!0},onPointerUp:Me(e.onPointerUp,d=>{var f;u.current||(f=d.currentTarget)==null||f.click()}),onKeyDown:Me(e.onKeyDown,d=>{const f=s.searchRef.current!=="";n||f&&d.key===" "||Y1.includes(d.key)&&(d.currentTarget.click(),d.preventDefault())})})});Xp.displayName=Kp;var lP=y.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:i,...a}=e,o=G1(Kp,n),s=nP(n),l=y.useRef(null),u=wn(t,l),[c,d]=y.useState(!1),[f,p]=y.useState("");return y.useEffect(()=>{const g=l.current;g&&p((g.textContent??"").trim())},[a.children]),E.jsx(uc.ItemSlot,{scope:n,disabled:r,textValue:i??f,children:E.jsx(Kte,{asChild:!0,...s,focusable:!r,children:E.jsx(yn.div,{role:"menuitem","data-highlighted":c?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0,...a,ref:u,onPointerMove:Me(e.onPointerMove,fc(g=>{r?o.onItemLeave(g):(o.onItemEnter(g),g.defaultPrevented||g.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:Me(e.onPointerLeave,fc(g=>o.onItemLeave(g))),onFocus:Me(e.onFocus,()=>d(!0)),onBlur:Me(e.onBlur,()=>d(!1))})})})}),Zne="MenuCheckboxItem",uP=y.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...i}=e;return E.jsx(hP,{scope:e.__scopeMenu,checked:n,children:E.jsx(Xp,{role:"menuitemcheckbox","aria-checked":Qp(n)?"mixed":n,...i,ref:t,"data-state":Z1(n),onSelect:Me(i.onSelect,()=>r==null?void 0:r(Qp(n)?!0:!n),{checkForDefaultPrevented:!1})})})});uP.displayName=Zne;var cP="MenuRadioGroup",[Jne,ere]=co(cP,{value:void 0,onValueChange:()=>{}}),dP=y.forwardRef((e,t)=>{const{value:n,onValueChange:r,...i}=e,a=Dt(r);return E.jsx(Jne,{scope:e.__scopeMenu,value:n,onValueChange:a,children:E.jsx(X1,{...i,ref:t})})});dP.displayName=cP;var fP="MenuRadioItem",pP=y.forwardRef((e,t)=>{const{value:n,...r}=e,i=ere(fP,e.__scopeMenu),a=n===i.value;return E.jsx(hP,{scope:e.__scopeMenu,checked:a,children:E.jsx(Xp,{role:"menuitemradio","aria-checked":a,...r,ref:t,"data-state":Z1(a),onSelect:Me(r.onSelect,()=>{var o;return(o=i.onValueChange)==null?void 0:o.call(i,n)},{checkForDefaultPrevented:!1})})})});pP.displayName=fP;var Q1="MenuItemIndicator",[hP,tre]=co(Q1,{checked:!1}),mP=y.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...i}=e,a=tre(Q1,n);return E.jsx(Bp,{present:r||Qp(a.checked)||a.checked===!0,children:E.jsx(yn.span,{...i,ref:t,"data-state":Z1(a.checked)})})});mP.displayName=Q1;var nre="MenuSeparator",gP=y.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return E.jsx(yn.div,{role:"separator","aria-orientation":"horizontal",...r,ref:t})});gP.displayName=nre;var rre="MenuArrow",wP=y.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,i=Gp(n);return E.jsx(Dte,{...i,...r,ref:t})});wP.displayName=rre;var ire="MenuSub",[ple,yP]=co(ire),dc="MenuSubTrigger",vP=y.forwardRef((e,t)=>{const n=Ms(dc,e.__scopeMenu),r=cc(dc,e.__scopeMenu),i=yP(dc,e.__scopeMenu),a=G1(dc,e.__scopeMenu),o=y.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:l}=a,u={__scopeMenu:e.__scopeMenu},c=y.useCallback(()=>{o.current&&window.clearTimeout(o.current),o.current=null},[]);return y.useEffect(()=>c,[c]),y.useEffect(()=>{const d=s.current;return()=>{window.clearTimeout(d),l(null)}},[s,l]),E.jsx(q1,{asChild:!0,...u,children:E.jsx(lP,{id:i.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":i.contentId,"data-state":EP(n.open),...e,ref:Fp(t,i.onTriggerChange),onClick:d=>{var f;(f=e.onClick)==null||f.call(e,d),!(e.disabled||d.defaultPrevented)&&(d.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:Me(e.onPointerMove,fc(d=>{a.onItemEnter(d),!d.defaultPrevented&&!e.disabled&&!n.open&&!o.current&&(a.onPointerGraceIntentChange(null),o.current=window.setTimeout(()=>{n.onOpenChange(!0),c()},100))})),onPointerLeave:Me(e.onPointerLeave,fc(d=>{var p,g;c();const f=(p=n.content)==null?void 0:p.getBoundingClientRect();if(f){const w=(g=n.content)==null?void 0:g.dataset.side,x=w==="right",m=x?-5:5,v=f[x?"left":"right"],b=f[x?"right":"left"];a.onPointerGraceIntentChange({area:[{x:d.clientX+m,y:d.clientY},{x:v,y:f.top},{x:b,y:f.top},{x:b,y:f.bottom},{x:v,y:f.bottom}],side:w}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(d),d.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:Me(e.onKeyDown,d=>{var p;const f=a.searchRef.current!=="";e.disabled||f&&d.key===" "||jne[r.dir].includes(d.key)&&(n.onOpenChange(!0),(p=n.content)==null||p.focus(),d.preventDefault())})})})});vP.displayName=dc;var bP="MenuSubContent",xP=y.forwardRef((e,t)=>{const n=iP(Qn,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,a=Ms(Qn,e.__scopeMenu),o=cc(Qn,e.__scopeMenu),s=yP(bP,e.__scopeMenu),l=y.useRef(null),u=wn(t,l);return E.jsx(uc.Provider,{scope:e.__scopeMenu,children:E.jsx(Bp,{present:r||a.open,children:E.jsx(uc.Slot,{scope:e.__scopeMenu,children:E.jsx(K1,{id:s.contentId,"aria-labelledby":s.triggerId,...i,ref:u,align:"start",side:o.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:c=>{var d;o.isUsingKeyboardRef.current&&((d=l.current)==null||d.focus()),c.preventDefault()},onCloseAutoFocus:c=>c.preventDefault(),onFocusOutside:Me(e.onFocusOutside,c=>{c.target!==s.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:Me(e.onEscapeKeyDown,c=>{o.onClose(),c.preventDefault()}),onKeyDown:Me(e.onKeyDown,c=>{var p;const d=c.currentTarget.contains(c.target),f=zne[o.dir].includes(c.key);d&&f&&(a.onOpenChange(!1),(p=s.trigger)==null||p.focus(),c.preventDefault())})})})})})});xP.displayName=bP;function EP(e){return e?"open":"closed"}function Qp(e){return e==="indeterminate"}function Z1(e){return Qp(e)?"indeterminate":e?"checked":"unchecked"}function are(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function ore(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function sre(e,t,n){const i=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,a=n?e.indexOf(n):-1;let o=ore(e,Math.max(a,0));i.length===1&&(o=o.filter(u=>u!==n));const l=o.find(u=>u.toLowerCase().startsWith(i.toLowerCase()));return l!==n?l:void 0}function lre(e,t){const{x:n,y:r}=e;let i=!1;for(let a=0,o=t.length-1;a<t.length;o=a++){const s=t[a].x,l=t[a].y,u=t[o].x,c=t[o].y;l>r!=c>r&&n<(u-s)*(r-l)/(c-l)+s&&(i=!i)}return i}function ure(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return lre(n,t)}function fc(e){return t=>t.pointerType==="mouse"?e(t):void 0}var cre=rP,dre=q1,fre=aP,pre=X1,hre=oP,mre=Xp,gre=uP,wre=dP,yre=pP,vre=mP,bre=gP,xre=wP,Ere=vP,Tre=xP,J1="DropdownMenu",[_re,hle]=Zr(J1,[tP]),vn=tP(),[Sre,TP]=_re(J1),_P=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:i,defaultOpen:a,onOpenChange:o,modal:s=!0}=e,l=vn(t),u=y.useRef(null),[c=!1,d]=vu({prop:i,defaultProp:a,onChange:o});return E.jsx(Sre,{scope:t,triggerId:mu(),triggerRef:u,contentId:mu(),open:c,onOpenChange:d,onOpenToggle:y.useCallback(()=>d(f=>!f),[d]),modal:s,children:E.jsx(cre,{...l,open:c,onOpenChange:d,dir:r,modal:s,children:n})})};_P.displayName=J1;var SP="DropdownMenuTrigger",kP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...i}=e,a=TP(SP,n),o=vn(n);return E.jsx(dre,{asChild:!0,...o,children:E.jsx(yn.button,{type:"button",id:a.triggerId,"aria-haspopup":"menu","aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...i,ref:Fp(t,a.triggerRef),onPointerDown:Me(e.onPointerDown,s=>{!r&&s.button===0&&s.ctrlKey===!1&&(a.onOpenToggle(),a.open||s.preventDefault())}),onKeyDown:Me(e.onKeyDown,s=>{r||(["Enter"," "].includes(s.key)&&a.onOpenToggle(),s.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})})});kP.displayName=SP;var CP="DropdownMenuContent",AP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=TP(CP,n),a=vn(n),o=y.useRef(!1);return E.jsx(fre,{id:i.contentId,"aria-labelledby":i.triggerId,...a,...r,ref:t,onCloseAutoFocus:Me(e.onCloseAutoFocus,s=>{var l;o.current||(l=i.triggerRef.current)==null||l.focus(),o.current=!1,s.preventDefault()}),onInteractOutside:Me(e.onInteractOutside,s=>{const l=s.detail.originalEvent,u=l.button===0&&l.ctrlKey===!0,c=l.button===2||u;(!i.modal||c)&&(o.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});AP.displayName=CP;var kre="DropdownMenuGroup",RP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(pre,{...i,...r,ref:t})});RP.displayName=kre;var Cre="DropdownMenuLabel",NP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(hre,{...i,...r,ref:t})});NP.displayName=Cre;var Are="DropdownMenuItem",OP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(mre,{...i,...r,ref:t})});OP.displayName=Are;var Rre="DropdownMenuCheckboxItem",PP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(gre,{...i,...r,ref:t})});PP.displayName=Rre;var Nre="DropdownMenuRadioGroup",Ore=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(wre,{...i,...r,ref:t})});Ore.displayName=Nre;var Pre="DropdownMenuRadioItem",IP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(yre,{...i,...r,ref:t})});IP.displayName=Pre;var Ire="DropdownMenuItemIndicator",DP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(vre,{...i,...r,ref:t})});DP.displayName=Ire;var Dre="DropdownMenuSeparator",LP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(bre,{...i,...r,ref:t})});LP.displayName=Dre;var Lre="DropdownMenuArrow",Mre=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(xre,{...i,...r,ref:t})});Mre.displayName=Lre;var Fre="DropdownMenuSubTrigger",MP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(Ere,{...i,...r,ref:t})});MP.displayName=Fre;var Bre="DropdownMenuSubContent",FP=y.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=vn(n);return E.jsx(Tre,{...i,...r,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});FP.displayName=Bre;var jre=_P,zre=kP,BP=AP,Ure=RP,jP=NP,zP=OP,UP=PP,HP=IP,VP=DP,$P=LP,WP=MP,YP=FP;const Hre=jre,Vre=zre,qP=Ure,$re=y.forwardRef(({className:e,inset:t,children:n,...r},i)=>E.jsxs(WP,{ref:i,className:He("flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...r,children:[n,E.jsx(Fee,{className:"ml-auto"})]}));$re.displayName=WP.displayName;const Wre=y.forwardRef(({className:e,...t},n)=>E.jsx(YP,{ref:n,className:He("z-50 min-w-[8rem] overflow-hidden rounded-2xl border bg-background p-1 text-foreground shadow-2xl 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",e),...t}));Wre.displayName=YP.displayName;const GP=y.forwardRef(({className:e,sideOffset:t=4,...n},r)=>E.jsx(BP,{ref:r,sideOffset:t,className:He("z-50 min-w-[8rem] overflow-hidden rounded-2xl border bg-background p-1 text-foreground shadow-2xl","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",e),...n}));GP.displayName=BP.displayName;const Zp=y.forwardRef(({className:e,inset:t,...n},r)=>E.jsx(vr,{children:E.jsx(zP,{ref:r,className:He("relative flex cursor-default select-none items-center gap-2 rounded-xl px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...n})}));Zp.displayName=zP.displayName;const Yre=y.forwardRef(({className:e,children:t,checked:n,...r},i)=>E.jsxs(UP,{ref:i,className:He("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:n,...r,children:[E.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:E.jsx(VP,{children:E.jsx(Mee,{className:"h-4 w-4"})})}),t]}));Yre.displayName=UP.displayName;const qre=y.forwardRef(({className:e,children:t,...n},r)=>E.jsxs(HP,{ref:r,className:He("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[E.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:E.jsx(VP,{children:E.jsx(zee,{className:"h-2 w-2 fill-current"})})}),t]}));qre.displayName=HP.displayName;const Gre=y.forwardRef(({className:e,inset:t,...n},r)=>E.jsx(jP,{ref:r,className:He("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...n}));Gre.displayName=jP.displayName;const KP=y.forwardRef(({className:e,...t},n)=>E.jsx($P,{ref:n,className:He("-mx-1 my-1 h-px bg-muted",e),...t}));KP.displayName=$P.displayName;function Kre({className:e,...t}){return E.jsx("div",{className:He("animate-pulse rounded-md bg-secondary",e),...t})}function Xre(e){const t=y.useRef({value:e,previous:e});return y.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var ev="Switch",[Qre,mle]=Zr(ev),[Zre,Jre]=Qre(ev),XP=y.forwardRef((e,t)=>{const{__scopeSwitch:n,name:r,checked:i,defaultChecked:a,required:o,disabled:s,value:l="on",onCheckedChange:u,form:c,...d}=e,[f,p]=y.useState(null),g=ar(t,b=>p(b)),w=y.useRef(!1),x=f?c||!!f.closest("form"):!0,[m=!1,v]=vu({prop:i,defaultProp:a,onChange:u});return E.jsxs(Zre,{scope:n,checked:m,disabled:s,children:[E.jsx(rn.button,{type:"button",role:"switch","aria-checked":m,"aria-required":o,"data-state":JP(m),"data-disabled":s?"":void 0,disabled:s,value:l,...d,ref:g,onClick:Jt(e.onClick,b=>{v(T=>!T),x&&(w.current=b.isPropagationStopped(),w.current||b.stopPropagation())})}),x&&E.jsx(eie,{control:f,bubbles:!w.current,name:r,value:l,checked:m,required:o,disabled:s,form:c,style:{transform:"translateX(-100%)"}})]})});XP.displayName=ev;var QP="SwitchThumb",ZP=y.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,i=Jre(QP,n);return E.jsx(rn.span,{"data-state":JP(i.checked),"data-disabled":i.disabled?"":void 0,...r,ref:t})});ZP.displayName=QP;var eie=e=>{const{control:t,checked:n,bubbles:r=!0,...i}=e,a=y.useRef(null),o=Xre(n),s=iw(t);return y.useEffect(()=>{const l=a.current,u=window.HTMLInputElement.prototype,d=Object.getOwnPropertyDescriptor(u,"checked").set;if(o!==n&&d){const f=new Event("click",{bubbles:r});d.call(l,n),l.dispatchEvent(f)}},[o,n,r]),E.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...i,tabIndex:-1,ref:a,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function JP(e){return e?"checked":"unchecked"}var eI=XP,tie=ZP;const tv=y.forwardRef(({className:e,...t},n)=>E.jsx(oc,{scale:"1.1",ref:n,children:E.jsx(eI,{className:He("peer group inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent shadow-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...t,ref:n,children:E.jsx(tie,{className:He("pointer-events-none block size-4 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0","group-active:scale-90 group-hover:active:scale-90")})})}));tv.displayName=eI.displayName;function nie(){const e=Qs(),[t,n]=y.useState(!1),{clearSession:r}=Ao(),{widgetSettings:i,setSettings:a}=Bt(),o=()=>{a({persistSession:!(i!=null&&i.persistSession)})},s=()=>{a({useSoundEffects:!(i!=null&&i.useSoundEffects)})};return E.jsxs(Hre,{open:t,onOpenChange:n,children:[E.jsx(Vre,{asChild:!0,children:E.jsx(uo,{variant:"ghost",size:"fit",className:"rounded-full",children:E.jsx(Uee,{className:"size-4"})})}),E.jsxs(GP,{align:"end",className:"min-w-56",children:[E.jsxs(qP,{children:[E.jsxs(Zp,{onSelect:l=>{l.preventDefault(),o()},children:[E.jsx(lo,{mode:"wait",children:i!=null&&i.persistSession?E.jsx(vr,{fadeIn:"right",distance:4,snapExit:!0,children:E.jsx(Gee,{})},"save"):E.jsx(vr,{fadeIn:"right",distance:4,snapExit:!0,children:E.jsx(qee,{})},"save-off")}),e.get("persist-session"),E.jsx(tv,{className:"ml-auto",checked:i==null?void 0:i.persistSession,onCheckedChange:o})]}),E.jsxs(Zp,{onSelect:l=>{l.preventDefault(),s()},children:[E.jsx(lo,{mode:"wait",children:i!=null&&i.useSoundEffects?E.jsx(vr,{fadeIn:"right",distance:4,snapExit:!0,children:E.jsx(Kee,{})},"volume-2"):E.jsx(vr,{fadeIn:"right",distance:4,snapExit:!0,children:E.jsx(Xee,{})},"volume-off")}),e.get("sound-effects"),E.jsx(tv,{className:"ml-auto",checked:i==null?void 0:i.useSoundEffects,onCheckedChange:s})]})]}),E.jsx(KP,{}),E.jsx(qP,{children:E.jsxs(Zp,{onSelect:()=>{r(),n(!1)},children:[E.jsx(vi.div,{initial:{opacity:0,x:-4,rotate:360},animate:{opacity:1,x:0,rotate:0},children:E.jsx(Yee,{})}),e.get("reset-conversation")]})})]})]})}function rie(){const{data:e,isLoading:t}=Lm();return E.jsx("header",{className:"p-2 border-b bg-background",children:E.jsxs("div",{className:"flex items-center gap-2",children:[E.jsx("div",{className:"flex-1 pl-2",children:t?E.jsx(Kre,{className:"h-4 w-2/3"}):E.jsx("h2",{className:"font-semibold",children:e==null?void 0:e.organization_name})}),E.jsx(nie,{})]})})}const[nv,iie]=Xs(),aie=()=>{};function oie({defaultOpen:e,onOpenChange:t,open:n,children:r,isAlert:i}){const[a,o]=y.useState(e),s=n??a??!1,l=t??o;return E.jsx(iie,{value:{open:s,setOpen:l,onOpenChange:t??aie,isAlert:i||!1},children:typeof r=="function"?r({open:s,setOpen:l}):r})}_t.forwardRef((e,t)=>{const{setOpen:n,open:r}=nv();return E.jsx("button",{...e,"data-open":r,onClick:()=>n(!0),ref:t})});const sie=_t.forwardRef((e,t)=>E.jsx(vi.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0,transition:{delay:.1}},transition:{duration:.2},className:"absolute inset-0 z-[24] from-gray-100/30 to-gray-50/30 bg-gradient-to-t backdrop-blur-sm",...e,ref:t}));function lie(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n&&(n.current=t)})}}const uie=_t.forwardRef(({children:e,...t},n)=>{const{open:r,setOpen:i,isAlert:a}=nv(),o=y.useRef(null),s=y.useRef(null),l=lie(n,o);return y.useEffect(()=>{if(!r||a)return;const u=c=>{c.key==="Escape"&&i(!1)};return window.addEventListener("keydown",u),()=>{window.removeEventListener("keydown",u)}},[r,i]),y.useEffect(()=>{var u;r&&((u=o.current)==null||u.focus())},[r]),E.jsx(lo,{children:r&&E.jsxs(E.Fragment,{children:[E.jsx(vi.div,{"data-alert":a,initial:{opacity:0,y:20,x:"-50%"},animate:{opacity:1,y:0,x:"-50%"},exit:{opacity:0,y:20,x:"-50%"},transition:{type:"spring",damping:20,stiffness:300},className:"bg-background rounded-xl grid grid-cols-1 gap-2 border max-w-[90%] bottom-2 w-full absolute left-1/2 p-3 z-[25]",ref:l,...t,children:e}),E.jsx(sie,{onClick:u=>{a||u.target===s.current&&i(!1)},ref:s})]})})});_t.forwardRef((e,t)=>{const{setOpen:n,open:r}=nv();return E.jsx("button",{...e,"data-open":r,onClick:()=>{n(!1)},ref:t})});function cie(){const{session:e,recreateSession:t,hookState:n}=Ao(),r=Qs();return e&&e.isSessionClosed!==!0||n.state==="loading"?null:E.jsx(oie,{open:e==null?void 0:e.isSessionClosed,children:E.jsxs(uie,{children:[E.jsxs("header",{className:"flex items-center gap-1",children:[E.jsx(QN,{className:"size-5 text-emerald-500"}),E.jsx("h2",{className:"text-base font-medium",dir:"auto",children:r.get("session-closed-lead")})]}),E.jsx("footer",{className:"grid mt-2",children:E.jsx("button",{onClick:t,className:"text-sm font-medium hover:brightness-110 whitespace-nowrap px-3 py-2 bg-primary text-primary-foreground rounded-md",children:r.get("create-new-ticket")})})]})})}var tI={exports:{}},die="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",fie=die,pie=fie;function nI(){}function rI(){}rI.resetWarningCache=nI;var hie=function(){function e(r,i,a,o,s,l){if(l!==pie){var u=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 u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:rI,resetWarningCache:nI};return n.PropTypes=n,n};tI.exports=hie();var mie=tI.exports;const Ge=gc(mie),gie=new Map([["1km","application/vnd.1000minds.decision-model+xml"],["3dml","text/vnd.in3d.3dml"],["3ds","image/x-3ds"],["3g2","video/3gpp2"],["3gp","video/3gp"],["3gpp","video/3gpp"],["3mf","model/3mf"],["7z","application/x-7z-compressed"],["7zip","application/x-7z-compressed"],["123","application/vnd.lotus-1-2-3"],["aab","application/x-authorware-bin"],["aac","audio/x-acc"],["aam","application/x-authorware-map"],["aas","application/x-authorware-seg"],["abw","application/x-abiword"],["ac","application/vnd.nokia.n-gage.ac+xml"],["ac3","audio/ac3"],["acc","application/vnd.americandynamics.acc"],["ace","application/x-ace-compressed"],["acu","application/vnd.acucobol"],["acutc","application/vnd.acucorp"],["adp","audio/adpcm"],["aep","application/vnd.audiograph"],["afm","application/x-font-type1"],["afp","application/vnd.ibm.modcap"],["ahead","application/vnd.ahead.space"],["ai","application/pdf"],["aif","audio/x-aiff"],["aifc","audio/x-aiff"],["aiff","audio/x-aiff"],["air","application/vnd.adobe.air-application-installer-package+zip"],["ait","application/vnd.dvb.ait"],["ami","application/vnd.amiga.ami"],["amr","audio/amr"],["apk","application/vnd.android.package-archive"],["apng","image/apng"],["appcache","text/cache-manifest"],["application","application/x-ms-application"],["apr","application/vnd.lotus-approach"],["arc","application/x-freearc"],["arj","application/x-arj"],["asc","application/pgp-signature"],["asf","video/x-ms-asf"],["asm","text/x-asm"],["aso","application/vnd.accpac.simply.aso"],["asx","video/x-ms-asf"],["atc","application/vnd.acucorp"],["atom","application/atom+xml"],["atomcat","application/atomcat+xml"],["atomdeleted","application/atomdeleted+xml"],["atomsvc","application/atomsvc+xml"],["atx","application/vnd.antix.game-component"],["au","audio/x-au"],["avi","video/x-msvideo"],["avif","image/avif"],["aw","application/applixware"],["azf","application/vnd.airzip.filesecure.azf"],["azs","application/vnd.airzip.filesecure.azs"],["azv","image/vnd.airzip.accelerator.azv"],["azw","application/vnd.amazon.ebook"],["b16","image/vnd.pco.b16"],["bat","application/x-msdownload"],["bcpio","application/x-bcpio"],["bdf","application/x-font-bdf"],["bdm","application/vnd.syncml.dm+wbxml"],["bdoc","application/x-bdoc"],["bed","application/vnd.realvnc.bed"],["bh2","application/vnd.fujitsu.oasysprs"],["bin","application/octet-stream"],["blb","application/x-blorb"],["blorb","application/x-blorb"],["bmi","application/vnd.bmi"],["bmml","application/vnd.balsamiq.bmml+xml"],["bmp","image/bmp"],["book","application/vnd.framemaker"],["box","application/vnd.previewsystems.box"],["boz","application/x-bzip2"],["bpk","application/octet-stream"],["bpmn","application/octet-stream"],["bsp","model/vnd.valve.source.compiled-map"],["btif","image/prs.btif"],["buffer","application/octet-stream"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["c","text/x-c"],["c4d","application/vnd.clonk.c4group"],["c4f","application/vnd.clonk.c4group"],["c4g","application/vnd.clonk.c4group"],["c4p","application/vnd.clonk.c4group"],["c4u","application/vnd.clonk.c4group"],["c11amc","application/vnd.cluetrust.cartomobile-config"],["c11amz","application/vnd.cluetrust.cartomobile-config-pkg"],["cab","application/vnd.ms-cab-compressed"],["caf","audio/x-caf"],["cap","application/vnd.tcpdump.pcap"],["car","application/vnd.curl.car"],["cat","application/vnd.ms-pki.seccat"],["cb7","application/x-cbr"],["cba","application/x-cbr"],["cbr","application/x-cbr"],["cbt","application/x-cbr"],["cbz","application/x-cbr"],["cc","text/x-c"],["cco","application/x-cocoa"],["cct","application/x-director"],["ccxml","application/ccxml+xml"],["cdbcmsg","application/vnd.contact.cmsg"],["cda","application/x-cdf"],["cdf","application/x-netcdf"],["cdfx","application/cdfx+xml"],["cdkey","application/vnd.mediastation.cdkey"],["cdmia","application/cdmi-capability"],["cdmic","application/cdmi-container"],["cdmid","application/cdmi-domain"],["cdmio","application/cdmi-object"],["cdmiq","application/cdmi-queue"],["cdr","application/cdr"],["cdx","chemical/x-cdx"],["cdxml","application/vnd.chemdraw+xml"],["cdy","application/vnd.cinderella"],["cer","application/pkix-cert"],["cfs","application/x-cfs-compressed"],["cgm","image/cgm"],["chat","application/x-chat"],["chm","application/vnd.ms-htmlhelp"],["chrt","application/vnd.kde.kchart"],["cif","chemical/x-cif"],["cii","application/vnd.anser-web-certificate-issue-initiation"],["cil","application/vnd.ms-artgalry"],["cjs","application/node"],["cla","application/vnd.claymore"],["class","application/octet-stream"],["clkk","application/vnd.crick.clicker.keyboard"],["clkp","application/vnd.crick.clicker.palette"],["clkt","application/vnd.crick.clicker.template"],["clkw","application/vnd.crick.clicker.wordbank"],["clkx","application/vnd.crick.clicker"],["clp","application/x-msclip"],["cmc","application/vnd.cosmocaller"],["cmdf","chemical/x-cmdf"],["cml","chemical/x-cml"],["cmp","application/vnd.yellowriver-custom-menu"],["cmx","image/x-cmx"],["cod","application/vnd.rim.cod"],["coffee","text/coffeescript"],["com","application/x-msdownload"],["conf","text/plain"],["cpio","application/x-cpio"],["cpp","text/x-c"],["cpt","application/mac-compactpro"],["crd","application/x-mscardfile"],["crl","application/pkix-crl"],["crt","application/x-x509-ca-cert"],["crx","application/x-chrome-extension"],["cryptonote","application/vnd.rig.cryptonote"],["csh","application/x-csh"],["csl","application/vnd.citationstyles.style+xml"],["csml","chemical/x-csml"],["csp","application/vnd.commonspace"],["csr","application/octet-stream"],["css","text/css"],["cst","application/x-director"],["csv","text/csv"],["cu","application/cu-seeme"],["curl","text/vnd.curl"],["cww","application/prs.cww"],["cxt","application/x-director"],["cxx","text/x-c"],["dae","model/vnd.collada+xml"],["daf","application/vnd.mobius.daf"],["dart","application/vnd.dart"],["dataless","application/vnd.fdsn.seed"],["davmount","application/davmount+xml"],["dbf","application/vnd.dbf"],["dbk","application/docbook+xml"],["dcr","application/x-director"],["dcurl","text/vnd.curl.dcurl"],["dd2","application/vnd.oma.dd2+xml"],["ddd","application/vnd.fujixerox.ddd"],["ddf","application/vnd.syncml.dmddf+xml"],["dds","image/vnd.ms-dds"],["deb","application/x-debian-package"],["def","text/plain"],["deploy","application/octet-stream"],["der","application/x-x509-ca-cert"],["dfac","application/vnd.dreamfactory"],["dgc","application/x-dgc-compressed"],["dic","text/x-c"],["dir","application/x-director"],["dis","application/vnd.mobius.dis"],["disposition-notification","message/disposition-notification"],["dist","application/octet-stream"],["distz","application/octet-stream"],["djv","image/vnd.djvu"],["djvu","image/vnd.djvu"],["dll","application/octet-stream"],["dmg","application/x-apple-diskimage"],["dmn","application/octet-stream"],["dmp","application/vnd.tcpdump.pcap"],["dms","application/octet-stream"],["dna","application/vnd.dna"],["doc","application/msword"],["docm","application/vnd.ms-word.template.macroEnabled.12"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["dot","application/msword"],["dotm","application/vnd.ms-word.template.macroEnabled.12"],["dotx","application/vnd.openxmlformats-officedocument.wordprocessingml.template"],["dp","application/vnd.osgi.dp"],["dpg","application/vnd.dpgraph"],["dra","audio/vnd.dra"],["drle","image/dicom-rle"],["dsc","text/prs.lines.tag"],["dssc","application/dssc+der"],["dtb","application/x-dtbook+xml"],["dtd","application/xml-dtd"],["dts","audio/vnd.dts"],["dtshd","audio/vnd.dts.hd"],["dump","application/octet-stream"],["dvb","video/vnd.dvb.file"],["dvi","application/x-dvi"],["dwd","application/atsc-dwd+xml"],["dwf","model/vnd.dwf"],["dwg","image/vnd.dwg"],["dxf","image/vnd.dxf"],["dxp","application/vnd.spotfire.dxp"],["dxr","application/x-director"],["ear","application/java-archive"],["ecelp4800","audio/vnd.nuera.ecelp4800"],["ecelp7470","audio/vnd.nuera.ecelp7470"],["ecelp9600","audio/vnd.nuera.ecelp9600"],["ecma","application/ecmascript"],["edm","application/vnd.novadigm.edm"],["edx","application/vnd.novadigm.edx"],["efif","application/vnd.picsel"],["ei6","application/vnd.pg.osasli"],["elc","application/octet-stream"],["emf","image/emf"],["eml","message/rfc822"],["emma","application/emma+xml"],["emotionml","application/emotionml+xml"],["emz","application/x-msmetafile"],["eol","audio/vnd.digital-winds"],["eot","application/vnd.ms-fontobject"],["eps","application/postscript"],["epub","application/epub+zip"],["es","application/ecmascript"],["es3","application/vnd.eszigno3+xml"],["esa","application/vnd.osgi.subsystem"],["esf","application/vnd.epson.esf"],["et3","application/vnd.eszigno3+xml"],["etx","text/x-setext"],["eva","application/x-eva"],["evy","application/x-envoy"],["exe","application/octet-stream"],["exi","application/exi"],["exp","application/express"],["exr","image/aces"],["ext","application/vnd.novadigm.ext"],["ez","application/andrew-inset"],["ez2","application/vnd.ezpix-album"],["ez3","application/vnd.ezpix-package"],["f","text/x-fortran"],["f4v","video/mp4"],["f77","text/x-fortran"],["f90","text/x-fortran"],["fbs","image/vnd.fastbidsheet"],["fcdt","application/vnd.adobe.formscentral.fcdt"],["fcs","application/vnd.isac.fcs"],["fdf","application/vnd.fdf"],["fdt","application/fdt+xml"],["fe_launch","application/vnd.denovo.fcselayout-link"],["fg5","application/vnd.fujitsu.oasysgp"],["fgd","application/x-director"],["fh","image/x-freehand"],["fh4","image/x-freehand"],["fh5","image/x-freehand"],["fh7","image/x-freehand"],["fhc","image/x-freehand"],["fig","application/x-xfig"],["fits","image/fits"],["flac","audio/x-flac"],["fli","video/x-fli"],["flo","application/vnd.micrografx.flo"],["flv","video/x-flv"],["flw","application/vnd.kde.kivio"],["flx","text/vnd.fmi.flexstor"],["fly","text/vnd.fly"],["fm","application/vnd.framemaker"],["fnc","application/vnd.frogans.fnc"],["fo","application/vnd.software602.filler.form+xml"],["for","text/x-fortran"],["fpx","image/vnd.fpx"],["frame","application/vnd.framemaker"],["fsc","application/vnd.fsc.weblaunch"],["fst","image/vnd.fst"],["ftc","application/vnd.fluxtime.clip"],["fti","application/vnd.anser-web-funds-transfer-initiation"],["fvt","video/vnd.fvt"],["fxp","application/vnd.adobe.fxp"],["fxpl","application/vnd.adobe.fxp"],["fzs","application/vnd.fuzzysheet"],["g2w","application/vnd.geoplan"],["g3","image/g3fax"],["g3w","application/vnd.geospace"],["gac","application/vnd.groove-account"],["gam","application/x-tads"],["gbr","application/rpki-ghostbusters"],["gca","application/x-gca-compressed"],["gdl","model/vnd.gdl"],["gdoc","application/vnd.google-apps.document"],["geo","application/vnd.dynageo"],["geojson","application/geo+json"],["gex","application/vnd.geometry-explorer"],["ggb","application/vnd.geogebra.file"],["ggt","application/vnd.geogebra.tool"],["ghf","application/vnd.groove-help"],["gif","image/gif"],["gim","application/vnd.groove-identity-message"],["glb","model/gltf-binary"],["gltf","model/gltf+json"],["gml","application/gml+xml"],["gmx","application/vnd.gmx"],["gnumeric","application/x-gnumeric"],["gpg","application/gpg-keys"],["gph","application/vnd.flographit"],["gpx","application/gpx+xml"],["gqf","application/vnd.grafeq"],["gqs","application/vnd.grafeq"],["gram","application/srgs"],["gramps","application/x-gramps-xml"],["gre","application/vnd.geometry-explorer"],["grv","application/vnd.groove-injector"],["grxml","application/srgs+xml"],["gsf","application/x-font-ghostscript"],["gsheet","application/vnd.google-apps.spreadsheet"],["gslides","application/vnd.google-apps.presentation"],["gtar","application/x-gtar"],["gtm","application/vnd.groove-tool-message"],["gtw","model/vnd.gtw"],["gv","text/vnd.graphviz"],["gxf","application/gxf"],["gxt","application/vnd.geonext"],["gz","application/gzip"],["gzip","application/gzip"],["h","text/x-c"],["h261","video/h261"],["h263","video/h263"],["h264","video/h264"],["hal","application/vnd.hal+xml"],["hbci","application/vnd.hbci"],["hbs","text/x-handlebars-template"],["hdd","application/x-virtualbox-hdd"],["hdf","application/x-hdf"],["heic","image/heic"],["heics","image/heic-sequence"],["heif","image/heif"],["heifs","image/heif-sequence"],["hej2","image/hej2k"],["held","application/atsc-held+xml"],["hh","text/x-c"],["hjson","application/hjson"],["hlp","application/winhlp"],["hpgl","application/vnd.hp-hpgl"],["hpid","application/vnd.hp-hpid"],["hps","application/vnd.hp-hps"],["hqx","application/mac-binhex40"],["hsj2","image/hsj2"],["htc","text/x-component"],["htke","application/vnd.kenameaapp"],["htm","text/html"],["html","text/html"],["hvd","application/vnd.yamaha.hv-dic"],["hvp","application/vnd.yamaha.hv-voice"],["hvs","application/vnd.yamaha.hv-script"],["i2g","application/vnd.intergeo"],["icc","application/vnd.iccprofile"],["ice","x-conference/x-cooltalk"],["icm","application/vnd.iccprofile"],["ico","image/x-icon"],["ics","text/calendar"],["ief","image/ief"],["ifb","text/calendar"],["ifm","application/vnd.shana.informed.formdata"],["iges","model/iges"],["igl","application/vnd.igloader"],["igm","application/vnd.insors.igm"],["igs","model/iges"],["igx","application/vnd.micrografx.igx"],["iif","application/vnd.shana.informed.interchange"],["img","application/octet-stream"],["imp","application/vnd.accpac.simply.imp"],["ims","application/vnd.ms-ims"],["in","text/plain"],["ini","text/plain"],["ink","application/inkml+xml"],["inkml","application/inkml+xml"],["install","application/x-install-instructions"],["iota","application/vnd.astraea-software.iota"],["ipfix","application/ipfix"],["ipk","application/vnd.shana.informed.package"],["irm","application/vnd.ibm.rights-management"],["irp","application/vnd.irepository.package+xml"],["iso","application/x-iso9660-image"],["itp","application/vnd.shana.informed.formtemplate"],["its","application/its+xml"],["ivp","application/vnd.immervision-ivp"],["ivu","application/vnd.immervision-ivu"],["jad","text/vnd.sun.j2me.app-descriptor"],["jade","text/jade"],["jam","application/vnd.jam"],["jar","application/java-archive"],["jardiff","application/x-java-archive-diff"],["java","text/x-java-source"],["jhc","image/jphc"],["jisp","application/vnd.jisp"],["jls","image/jls"],["jlt","application/vnd.hp-jlyt"],["jng","image/x-jng"],["jnlp","application/x-java-jnlp-file"],["joda","application/vnd.joost.joda-archive"],["jp2","image/jp2"],["jpe","image/jpeg"],["jpeg","image/jpeg"],["jpf","image/jpx"],["jpg","image/jpeg"],["jpg2","image/jp2"],["jpgm","video/jpm"],["jpgv","video/jpeg"],["jph","image/jph"],["jpm","video/jpm"],["jpx","image/jpx"],["js","application/javascript"],["json","application/json"],["json5","application/json5"],["jsonld","application/ld+json"],["jsonl","application/jsonl"],["jsonml","application/jsonml+json"],["jsx","text/jsx"],["jxr","image/jxr"],["jxra","image/jxra"],["jxrs","image/jxrs"],["jxs","image/jxs"],["jxsc","image/jxsc"],["jxsi","image/jxsi"],["jxss","image/jxss"],["kar","audio/midi"],["karbon","application/vnd.kde.karbon"],["kdb","application/octet-stream"],["kdbx","application/x-keepass2"],["key","application/x-iwork-keynote-sffkey"],["kfo","application/vnd.kde.kformula"],["kia","application/vnd.kidspiration"],["kml","application/vnd.google-earth.kml+xml"],["kmz","application/vnd.google-earth.kmz"],["kne","application/vnd.kinar"],["knp","application/vnd.kinar"],["kon","application/vnd.kde.kontour"],["kpr","application/vnd.kde.kpresenter"],["kpt","application/vnd.kde.kpresenter"],["kpxx","application/vnd.ds-keypoint"],["ksp","application/vnd.kde.kspread"],["ktr","application/vnd.kahootz"],["ktx","image/ktx"],["ktx2","image/ktx2"],["ktz","application/vnd.kahootz"],["kwd","application/vnd.kde.kword"],["kwt","application/vnd.kde.kword"],["lasxml","application/vnd.las.las+xml"],["latex","application/x-latex"],["lbd","application/vnd.llamagraphics.life-balance.desktop"],["lbe","application/vnd.llamagraphics.life-balance.exchange+xml"],["les","application/vnd.hhe.lesson-player"],["less","text/less"],["lgr","application/lgr+xml"],["lha","application/octet-stream"],["link66","application/vnd.route66.link66+xml"],["list","text/plain"],["list3820","application/vnd.ibm.modcap"],["listafp","application/vnd.ibm.modcap"],["litcoffee","text/coffeescript"],["lnk","application/x-ms-shortcut"],["log","text/plain"],["lostxml","application/lost+xml"],["lrf","application/octet-stream"],["lrm","application/vnd.ms-lrm"],["ltf","application/vnd.frogans.ltf"],["lua","text/x-lua"],["luac","application/x-lua-bytecode"],["lvp","audio/vnd.lucent.voice"],["lwp","application/vnd.lotus-wordpro"],["lzh","application/octet-stream"],["m1v","video/mpeg"],["m2a","audio/mpeg"],["m2v","video/mpeg"],["m3a","audio/mpeg"],["m3u","text/plain"],["m3u8","application/vnd.apple.mpegurl"],["m4a","audio/x-m4a"],["m4p","application/mp4"],["m4s","video/iso.segment"],["m4u","application/vnd.mpegurl"],["m4v","video/x-m4v"],["m13","application/x-msmediaview"],["m14","application/x-msmediaview"],["m21","application/mp21"],["ma","application/mathematica"],["mads","application/mads+xml"],["maei","application/mmt-aei+xml"],["mag","application/vnd.ecowin.chart"],["maker","application/vnd.framemaker"],["man","text/troff"],["manifest","text/cache-manifest"],["map","application/json"],["mar","application/octet-stream"],["markdown","text/markdown"],["mathml","application/mathml+xml"],["mb","application/mathematica"],["mbk","application/vnd.mobius.mbk"],["mbox","application/mbox"],["mc1","application/vnd.medcalcdata"],["mcd","application/vnd.mcd"],["mcurl","text/vnd.curl.mcurl"],["md","text/markdown"],["mdb","application/x-msaccess"],["mdi","image/vnd.ms-modi"],["mdx","text/mdx"],["me","text/troff"],["mesh","model/mesh"],["meta4","application/metalink4+xml"],["metalink","application/metalink+xml"],["mets","application/mets+xml"],["mfm","application/vnd.mfmp"],["mft","application/rpki-manifest"],["mgp","application/vnd.osgeo.mapguide.package"],["mgz","application/vnd.proteus.magazine"],["mid","audio/midi"],["midi","audio/midi"],["mie","application/x-mie"],["mif","application/vnd.mif"],["mime","message/rfc822"],["mj2","video/mj2"],["mjp2","video/mj2"],["mjs","application/javascript"],["mk3d","video/x-matroska"],["mka","audio/x-matroska"],["mkd","text/x-markdown"],["mks","video/x-matroska"],["mkv","video/x-matroska"],["mlp","application/vnd.dolby.mlp"],["mmd","application/vnd.chipnuts.karaoke-mmd"],["mmf","application/vnd.smaf"],["mml","text/mathml"],["mmr","image/vnd.fujixerox.edmics-mmr"],["mng","video/x-mng"],["mny","application/x-msmoney"],["mobi","application/x-mobipocket-ebook"],["mods","application/mods+xml"],["mov","video/quicktime"],["movie","video/x-sgi-movie"],["mp2","audio/mpeg"],["mp2a","audio/mpeg"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mp4a","audio/mp4"],["mp4s","application/mp4"],["mp4v","video/mp4"],["mp21","application/mp21"],["mpc","application/vnd.mophun.certificate"],["mpd","application/dash+xml"],["mpe","video/mpeg"],["mpeg","video/mpeg"],["mpg","video/mpeg"],["mpg4","video/mp4"],["mpga","audio/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["mpm","application/vnd.blueice.multipass"],["mpn","application/vnd.mophun.application"],["mpp","application/vnd.ms-project"],["mpt","application/vnd.ms-project"],["mpy","application/vnd.ibm.minipay"],["mqy","application/vnd.mobius.mqy"],["mrc","application/marc"],["mrcx","application/marcxml+xml"],["ms","text/troff"],["mscml","application/mediaservercontrol+xml"],["mseed","application/vnd.fdsn.mseed"],["mseq","application/vnd.mseq"],["msf","application/vnd.epson.msf"],["msg","application/vnd.ms-outlook"],["msh","model/mesh"],["msi","application/x-msdownload"],["msl","application/vnd.mobius.msl"],["msm","application/octet-stream"],["msp","application/octet-stream"],["msty","application/vnd.muvee.style"],["mtl","model/mtl"],["mts","model/vnd.mts"],["mus","application/vnd.musician"],["musd","application/mmt-usd+xml"],["musicxml","application/vnd.recordare.musicxml+xml"],["mvb","application/x-msmediaview"],["mvt","application/vnd.mapbox-vector-tile"],["mwf","application/vnd.mfer"],["mxf","application/mxf"],["mxl","application/vnd.recordare.musicxml"],["mxmf","audio/mobile-xmf"],["mxml","application/xv+xml"],["mxs","application/vnd.triscape.mxs"],["mxu","video/vnd.mpegurl"],["n-gage","application/vnd.nokia.n-gage.symbian.install"],["n3","text/n3"],["nb","application/mathematica"],["nbp","application/vnd.wolfram.player"],["nc","application/x-netcdf"],["ncx","application/x-dtbncx+xml"],["nfo","text/x-nfo"],["ngdat","application/vnd.nokia.n-gage.data"],["nitf","application/vnd.nitf"],["nlu","application/vnd.neurolanguage.nlu"],["nml","application/vnd.enliven"],["nnd","application/vnd.noblenet-directory"],["nns","application/vnd.noblenet-sealer"],["nnw","application/vnd.noblenet-web"],["npx","image/vnd.net-fpx"],["nq","application/n-quads"],["nsc","application/x-conference"],["nsf","application/vnd.lotus-notes"],["nt","application/n-triples"],["ntf","application/vnd.nitf"],["numbers","application/x-iwork-numbers-sffnumbers"],["nzb","application/x-nzb"],["oa2","application/vnd.fujitsu.oasys2"],["oa3","application/vnd.fujitsu.oasys3"],["oas","application/vnd.fujitsu.oasys"],["obd","application/x-msbinder"],["obgx","application/vnd.openblox.game+xml"],["obj","model/obj"],["oda","application/oda"],["odb","application/vnd.oasis.opendocument.database"],["odc","application/vnd.oasis.opendocument.chart"],["odf","application/vnd.oasis.opendocument.formula"],["odft","application/vnd.oasis.opendocument.formula-template"],["odg","application/vnd.oasis.opendocument.graphics"],["odi","application/vnd.oasis.opendocument.image"],["odm","application/vnd.oasis.opendocument.text-master"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogex","model/vnd.opengex"],["ogg","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["omdoc","application/omdoc+xml"],["onepkg","application/onenote"],["onetmp","application/onenote"],["onetoc","application/onenote"],["onetoc2","application/onenote"],["opf","application/oebps-package+xml"],["opml","text/x-opml"],["oprc","application/vnd.palm"],["opus","audio/ogg"],["org","text/x-org"],["osf","application/vnd.yamaha.openscoreformat"],["osfpvg","application/vnd.yamaha.openscoreformat.osfpvg+xml"],["osm","application/vnd.openstreetmap.data+xml"],["otc","application/vnd.oasis.opendocument.chart-template"],["otf","font/otf"],["otg","application/vnd.oasis.opendocument.graphics-template"],["oth","application/vnd.oasis.opendocument.text-web"],["oti","application/vnd.oasis.opendocument.image-template"],["otp","application/vnd.oasis.opendocument.presentation-template"],["ots","application/vnd.oasis.opendocument.spreadsheet-template"],["ott","application/vnd.oasis.opendocument.text-template"],["ova","application/x-virtualbox-ova"],["ovf","application/x-virtualbox-ovf"],["owl","application/rdf+xml"],["oxps","application/oxps"],["oxt","application/vnd.openofficeorg.extension"],["p","text/x-pascal"],["p7a","application/x-pkcs7-signature"],["p7b","application/x-pkcs7-certificates"],["p7c","application/pkcs7-mime"],["p7m","application/pkcs7-mime"],["p7r","application/x-pkcs7-certreqresp"],["p7s","application/pkcs7-signature"],["p8","application/pkcs8"],["p10","application/x-pkcs10"],["p12","application/x-pkcs12"],["pac","application/x-ns-proxy-autoconfig"],["pages","application/x-iwork-pages-sffpages"],["pas","text/x-pascal"],["paw","application/vnd.pawaafile"],["pbd","application/vnd.powerbuilder6"],["pbm","image/x-portable-bitmap"],["pcap","application/vnd.tcpdump.pcap"],["pcf","application/x-font-pcf"],["pcl","application/vnd.hp-pcl"],["pclxl","application/vnd.hp-pclxl"],["pct","image/x-pict"],["pcurl","application/vnd.curl.pcurl"],["pcx","image/x-pcx"],["pdb","application/x-pilot"],["pde","text/x-processing"],["pdf","application/pdf"],["pem","application/x-x509-user-cert"],["pfa","application/x-font-type1"],["pfb","application/x-font-type1"],["pfm","application/x-font-type1"],["pfr","application/font-tdpfr"],["pfx","application/x-pkcs12"],["pgm","image/x-portable-graymap"],["pgn","application/x-chess-pgn"],["pgp","application/pgp"],["php","application/x-httpd-php"],["php3","application/x-httpd-php"],["php4","application/x-httpd-php"],["phps","application/x-httpd-php-source"],["phtml","application/x-httpd-php"],["pic","image/x-pict"],["pkg","application/octet-stream"],["pki","application/pkixcmp"],["pkipath","application/pkix-pkipath"],["pkpass","application/vnd.apple.pkpass"],["pl","application/x-perl"],["plb","application/vnd.3gpp.pic-bw-large"],["plc","application/vnd.mobius.plc"],["plf","application/vnd.pocketlearn"],["pls","application/pls+xml"],["pm","application/x-perl"],["pml","application/vnd.ctc-posml"],["png","image/png"],["pnm","image/x-portable-anymap"],["portpkg","application/vnd.macports.portpkg"],["pot","application/vnd.ms-powerpoint"],["potm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["potx","application/vnd.openxmlformats-officedocument.presentationml.template"],["ppa","application/vnd.ms-powerpoint"],["ppam","application/vnd.ms-powerpoint.addin.macroEnabled.12"],["ppd","application/vnd.cups-ppd"],["ppm","image/x-portable-pixmap"],["pps","application/vnd.ms-powerpoint"],["ppsm","application/vnd.ms-powerpoint.slideshow.macroEnabled.12"],["ppsx","application/vnd.openxmlformats-officedocument.presentationml.slideshow"],["ppt","application/powerpoint"],["pptm","application/vnd.ms-powerpoint.presentation.macroEnabled.12"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["pqa","application/vnd.palm"],["prc","application/x-pilot"],["pre","application/vnd.lotus-freelance"],["prf","application/pics-rules"],["provx","application/provenance+xml"],["ps","application/postscript"],["psb","application/vnd.3gpp.pic-bw-small"],["psd","application/x-photoshop"],["psf","application/x-font-linux-psf"],["pskcxml","application/pskc+xml"],["pti","image/prs.pti"],["ptid","application/vnd.pvi.ptid1"],["pub","application/x-mspublisher"],["pvb","application/vnd.3gpp.pic-bw-var"],["pwn","application/vnd.3m.post-it-notes"],["pya","audio/vnd.ms-playready.media.pya"],["pyv","video/vnd.ms-playready.media.pyv"],["qam","application/vnd.epson.quickanime"],["qbo","application/vnd.intu.qbo"],["qfx","application/vnd.intu.qfx"],["qps","application/vnd.publishare-delta-tree"],["qt","video/quicktime"],["qwd","application/vnd.quark.quarkxpress"],["qwt","application/vnd.quark.quarkxpress"],["qxb","application/vnd.quark.quarkxpress"],["qxd","application/vnd.quark.quarkxpress"],["qxl","application/vnd.quark.quarkxpress"],["qxt","application/vnd.quark.quarkxpress"],["ra","audio/x-realaudio"],["ram","audio/x-pn-realaudio"],["raml","application/raml+yaml"],["rapd","application/route-apd+xml"],["rar","application/x-rar"],["ras","image/x-cmu-raster"],["rcprofile","application/vnd.ipunplugged.rcprofile"],["rdf","application/rdf+xml"],["rdz","application/vnd.data-vision.rdz"],["relo","application/p2p-overlay+xml"],["rep","application/vnd.businessobjects"],["res","application/x-dtbresource+xml"],["rgb","image/x-rgb"],["rif","application/reginfo+xml"],["rip","audio/vnd.rip"],["ris","application/x-research-info-systems"],["rl","application/resource-lists+xml"],["rlc","image/vnd.fujixerox.edmics-rlc"],["rld","application/resource-lists-diff+xml"],["rm","audio/x-pn-realaudio"],["rmi","audio/midi"],["rmp","audio/x-pn-realaudio-plugin"],["rms","application/vnd.jcp.javame.midlet-rms"],["rmvb","application/vnd.rn-realmedia-vbr"],["rnc","application/relax-ng-compact-syntax"],["rng","application/xml"],["roa","application/rpki-roa"],["roff","text/troff"],["rp9","application/vnd.cloanto.rp9"],["rpm","audio/x-pn-realaudio-plugin"],["rpss","application/vnd.nokia.radio-presets"],["rpst","application/vnd.nokia.radio-preset"],["rq","application/sparql-query"],["rs","application/rls-services+xml"],["rsa","application/x-pkcs7"],["rsat","application/atsc-rsat+xml"],["rsd","application/rsd+xml"],["rsheet","application/urc-ressheet+xml"],["rss","application/rss+xml"],["rtf","text/rtf"],["rtx","text/richtext"],["run","application/x-makeself"],["rusd","application/route-usd+xml"],["rv","video/vnd.rn-realvideo"],["s","text/x-asm"],["s3m","audio/s3m"],["saf","application/vnd.yamaha.smaf-audio"],["sass","text/x-sass"],["sbml","application/sbml+xml"],["sc","application/vnd.ibm.secure-container"],["scd","application/x-msschedule"],["scm","application/vnd.lotus-screencam"],["scq","application/scvp-cv-request"],["scs","application/scvp-cv-response"],["scss","text/x-scss"],["scurl","text/vnd.curl.scurl"],["sda","application/vnd.stardivision.draw"],["sdc","application/vnd.stardivision.calc"],["sdd","application/vnd.stardivision.impress"],["sdkd","application/vnd.solent.sdkm+xml"],["sdkm","application/vnd.solent.sdkm+xml"],["sdp","application/sdp"],["sdw","application/vnd.stardivision.writer"],["sea","application/octet-stream"],["see","application/vnd.seemail"],["seed","application/vnd.fdsn.seed"],["sema","application/vnd.sema"],["semd","application/vnd.semd"],["semf","application/vnd.semf"],["senmlx","application/senml+xml"],["sensmlx","application/sensml+xml"],["ser","application/java-serialized-object"],["setpay","application/set-payment-initiation"],["setreg","application/set-registration-initiation"],["sfd-hdstx","application/vnd.hydrostatix.sof-data"],["sfs","application/vnd.spotfire.sfs"],["sfv","text/x-sfv"],["sgi","image/sgi"],["sgl","application/vnd.stardivision.writer-global"],["sgm","text/sgml"],["sgml","text/sgml"],["sh","application/x-sh"],["shar","application/x-shar"],["shex","text/shex"],["shf","application/shf+xml"],["shtml","text/html"],["sid","image/x-mrsid-image"],["sieve","application/sieve"],["sig","application/pgp-signature"],["sil","audio/silk"],["silo","model/mesh"],["sis","application/vnd.symbian.install"],["sisx","application/vnd.symbian.install"],["sit","application/x-stuffit"],["sitx","application/x-stuffitx"],["siv","application/sieve"],["skd","application/vnd.koan"],["skm","application/vnd.koan"],["skp","application/vnd.koan"],["skt","application/vnd.koan"],["sldm","application/vnd.ms-powerpoint.slide.macroenabled.12"],["sldx","application/vnd.openxmlformats-officedocument.presentationml.slide"],["slim","text/slim"],["slm","text/slim"],["sls","application/route-s-tsid+xml"],["slt","application/vnd.epson.salt"],["sm","application/vnd.stepmania.stepchart"],["smf","application/vnd.stardivision.math"],["smi","application/smil"],["smil","application/smil"],["smv","video/x-smv"],["smzip","application/vnd.stepmania.package"],["snd","audio/basic"],["snf","application/x-font-snf"],["so","application/octet-stream"],["spc","application/x-pkcs7-certificates"],["spdx","text/spdx"],["spf","application/vnd.yamaha.smaf-phrase"],["spl","application/x-futuresplash"],["spot","text/vnd.in3d.spot"],["spp","application/scvp-vp-response"],["spq","application/scvp-vp-request"],["spx","audio/ogg"],["sql","application/x-sql"],["src","application/x-wais-source"],["srt","application/x-subrip"],["sru","application/sru+xml"],["srx","application/sparql-results+xml"],["ssdl","application/ssdl+xml"],["sse","application/vnd.kodak-descriptor"],["ssf","application/vnd.epson.ssf"],["ssml","application/ssml+xml"],["sst","application/octet-stream"],["st","application/vnd.sailingtracker.track"],["stc","application/vnd.sun.xml.calc.template"],["std","application/vnd.sun.xml.draw.template"],["stf","application/vnd.wt.stf"],["sti","application/vnd.sun.xml.impress.template"],["stk","application/hyperstudio"],["stl","model/stl"],["stpx","model/step+xml"],["stpxz","model/step-xml+zip"],["stpz","model/step+zip"],["str","application/vnd.pg.format"],["stw","application/vnd.sun.xml.writer.template"],["styl","text/stylus"],["stylus","text/stylus"],["sub","text/vnd.dvb.subtitle"],["sus","application/vnd.sus-calendar"],["susp","application/vnd.sus-calendar"],["sv4cpio","application/x-sv4cpio"],["sv4crc","application/x-sv4crc"],["svc","application/vnd.dvb.service"],["svd","application/vnd.svd"],["svg","image/svg+xml"],["svgz","image/svg+xml"],["swa","application/x-director"],["swf","application/x-shockwave-flash"],["swi","application/vnd.aristanetworks.swi"],["swidtag","application/swid+xml"],["sxc","application/vnd.sun.xml.calc"],["sxd","application/vnd.sun.xml.draw"],["sxg","application/vnd.sun.xml.writer.global"],["sxi","application/vnd.sun.xml.impress"],["sxm","application/vnd.sun.xml.math"],["sxw","application/vnd.sun.xml.writer"],["t","text/troff"],["t3","application/x-t3vm-image"],["t38","image/t38"],["taglet","application/vnd.mynfc"],["tao","application/vnd.tao.intent-module-archive"],["tap","image/vnd.tencent.tap"],["tar","application/x-tar"],["tcap","application/vnd.3gpp2.tcap"],["tcl","application/x-tcl"],["td","application/urc-targetdesc+xml"],["teacher","application/vnd.smart.teacher"],["tei","application/tei+xml"],["teicorpus","application/tei+xml"],["tex","application/x-tex"],["texi","application/x-texinfo"],["texinfo","application/x-texinfo"],["text","text/plain"],["tfi","application/thraud+xml"],["tfm","application/x-tex-tfm"],["tfx","image/tiff-fx"],["tga","image/x-tga"],["tgz","application/x-tar"],["thmx","application/vnd.ms-officetheme"],["tif","image/tiff"],["tiff","image/tiff"],["tk","application/x-tcl"],["tmo","application/vnd.tmobile-livetv"],["toml","application/toml"],["torrent","application/x-bittorrent"],["tpl","application/vnd.groove-tool-template"],["tpt","application/vnd.trid.tpt"],["tr","text/troff"],["tra","application/vnd.trueapp"],["trig","application/trig"],["trm","application/x-msterminal"],["ts","video/mp2t"],["tsd","application/timestamped-data"],["tsv","text/tab-separated-values"],["ttc","font/collection"],["ttf","font/ttf"],["ttl","text/turtle"],["ttml","application/ttml+xml"],["twd","application/vnd.simtech-mindmapper"],["twds","application/vnd.simtech-mindmapper"],["txd","application/vnd.genomatix.tuxedo"],["txf","application/vnd.mobius.txf"],["txt","text/plain"],["u8dsn","message/global-delivery-status"],["u8hdr","message/global-headers"],["u8mdn","message/global-disposition-notification"],["u8msg","message/global"],["u32","application/x-authorware-bin"],["ubj","application/ubjson"],["udeb","application/x-debian-package"],["ufd","application/vnd.ufdl"],["ufdl","application/vnd.ufdl"],["ulx","application/x-glulx"],["umj","application/vnd.umajin"],["unityweb","application/vnd.unity"],["uoml","application/vnd.uoml+xml"],["uri","text/uri-list"],["uris","text/uri-list"],["urls","text/uri-list"],["usdz","model/vnd.usdz+zip"],["ustar","application/x-ustar"],["utz","application/vnd.uiq.theme"],["uu","text/x-uuencode"],["uva","audio/vnd.dece.audio"],["uvd","application/vnd.dece.data"],["uvf","application/vnd.dece.data"],["uvg","image/vnd.dece.graphic"],["uvh","video/vnd.dece.hd"],["uvi","image/vnd.dece.graphic"],["uvm","video/vnd.dece.mobile"],["uvp","video/vnd.dece.pd"],["uvs","video/vnd.dece.sd"],["uvt","application/vnd.dece.ttml+xml"],["uvu","video/vnd.uvvu.mp4"],["uvv","video/vnd.dece.video"],["uvva","audio/vnd.dece.audio"],["uvvd","application/vnd.dece.data"],["uvvf","application/vnd.dece.data"],["uvvg","image/vnd.dece.graphic"],["uvvh","video/vnd.dece.hd"],["uvvi","image/vnd.dece.graphic"],["uvvm","video/vnd.dece.mobile"],["uvvp","video/vnd.dece.pd"],["uvvs","video/vnd.dece.sd"],["uvvt","application/vnd.dece.ttml+xml"],["uvvu","video/vnd.uvvu.mp4"],["uvvv","video/vnd.dece.video"],["uvvx","application/vnd.dece.unspecified"],["uvvz","application/vnd.dece.zip"],["uvx","application/vnd.dece.unspecified"],["uvz","application/vnd.dece.zip"],["vbox","application/x-virtualbox-vbox"],["vbox-extpack","application/x-virtualbox-vbox-extpack"],["vcard","text/vcard"],["vcd","application/x-cdlink"],["vcf","text/x-vcard"],["vcg","application/vnd.groove-vcard"],["vcs","text/x-vcalendar"],["vcx","application/vnd.vcx"],["vdi","application/x-virtualbox-vdi"],["vds","model/vnd.sap.vds"],["vhd","application/x-virtualbox-vhd"],["vis","application/vnd.visionary"],["viv","video/vnd.vivo"],["vlc","application/videolan"],["vmdk","application/x-virtualbox-vmdk"],["vob","video/x-ms-vob"],["vor","application/vnd.stardivision.writer"],["vox","application/x-authorware-bin"],["vrml","model/vrml"],["vsd","application/vnd.visio"],["vsf","application/vnd.vsf"],["vss","application/vnd.visio"],["vst","application/vnd.visio"],["vsw","application/vnd.visio"],["vtf","image/vnd.valve.source.texture"],["vtt","text/vtt"],["vtu","model/vnd.vtu"],["vxml","application/voicexml+xml"],["w3d","application/x-director"],["wad","application/x-doom"],["wadl","application/vnd.sun.wadl+xml"],["war","application/java-archive"],["wasm","application/wasm"],["wav","audio/x-wav"],["wax","audio/x-ms-wax"],["wbmp","image/vnd.wap.wbmp"],["wbs","application/vnd.criticaltools.wbs+xml"],["wbxml","application/wbxml"],["wcm","application/vnd.ms-works"],["wdb","application/vnd.ms-works"],["wdp","image/vnd.ms-photo"],["weba","audio/webm"],["webapp","application/x-web-app-manifest+json"],["webm","video/webm"],["webmanifest","application/manifest+json"],["webp","image/webp"],["wg","application/vnd.pmi.widget"],["wgt","application/widget"],["wks","application/vnd.ms-works"],["wm","video/x-ms-wm"],["wma","audio/x-ms-wma"],["wmd","application/x-ms-wmd"],["wmf","image/wmf"],["wml","text/vnd.wap.wml"],["wmlc","application/wmlc"],["wmls","text/vnd.wap.wmlscript"],["wmlsc","application/vnd.wap.wmlscriptc"],["wmv","video/x-ms-wmv"],["wmx","video/x-ms-wmx"],["wmz","application/x-msmetafile"],["woff","font/woff"],["woff2","font/woff2"],["word","application/msword"],["wpd","application/vnd.wordperfect"],["wpl","application/vnd.ms-wpl"],["wps","application/vnd.ms-works"],["wqd","application/vnd.wqd"],["wri","application/x-mswrite"],["wrl","model/vrml"],["wsc","message/vnd.wfa.wsc"],["wsdl","application/wsdl+xml"],["wspolicy","application/wspolicy+xml"],["wtb","application/vnd.webturbo"],["wvx","video/x-ms-wvx"],["x3d","model/x3d+xml"],["x3db","model/x3d+fastinfoset"],["x3dbz","model/x3d+binary"],["x3dv","model/x3d-vrml"],["x3dvz","model/x3d+vrml"],["x3dz","model/x3d+xml"],["x32","application/x-authorware-bin"],["x_b","model/vnd.parasolid.transmit.binary"],["x_t","model/vnd.parasolid.transmit.text"],["xaml","application/xaml+xml"],["xap","application/x-silverlight-app"],["xar","application/vnd.xara"],["xav","application/xcap-att+xml"],["xbap","application/x-ms-xbap"],["xbd","application/vnd.fujixerox.docuworks.binder"],["xbm","image/x-xbitmap"],["xca","application/xcap-caps+xml"],["xcs","application/calendar+xml"],["xdf","application/xcap-diff+xml"],["xdm","application/vnd.syncml.dm+xml"],["xdp","application/vnd.adobe.xdp+xml"],["xdssc","application/dssc+xml"],["xdw","application/vnd.fujixerox.docuworks"],["xel","application/xcap-el+xml"],["xenc","application/xenc+xml"],["xer","application/patch-ops-error+xml"],["xfdf","application/vnd.adobe.xfdf"],["xfdl","application/vnd.xfdl"],["xht","application/xhtml+xml"],["xhtml","application/xhtml+xml"],["xhvml","application/xv+xml"],["xif","image/vnd.xiff"],["xl","application/excel"],["xla","application/vnd.ms-excel"],["xlam","application/vnd.ms-excel.addin.macroEnabled.12"],["xlc","application/vnd.ms-excel"],["xlf","application/xliff+xml"],["xlm","application/vnd.ms-excel"],["xls","application/vnd.ms-excel"],["xlsb","application/vnd.ms-excel.sheet.binary.macroEnabled.12"],["xlsm","application/vnd.ms-excel.sheet.macroEnabled.12"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xlt","application/vnd.ms-excel"],["xltm","application/vnd.ms-excel.template.macroEnabled.12"],["xltx","application/vnd.openxmlformats-officedocument.spreadsheetml.template"],["xlw","application/vnd.ms-excel"],["xm","audio/xm"],["xml","application/xml"],["xns","application/xcap-ns+xml"],["xo","application/vnd.olpc-sugar"],["xop","application/xop+xml"],["xpi","application/x-xpinstall"],["xpl","application/xproc+xml"],["xpm","image/x-xpixmap"],["xpr","application/vnd.is-xpr"],["xps","application/vnd.ms-xpsdocument"],["xpw","application/vnd.intercon.formnet"],["xpx","application/vnd.intercon.formnet"],["xsd","application/xml"],["xsl","application/xml"],["xslt","application/xslt+xml"],["xsm","application/vnd.syncml+xml"],["xspf","application/xspf+xml"],["xul","application/vnd.mozilla.xul+xml"],["xvm","application/xv+xml"],["xvml","application/xv+xml"],["xwd","image/x-xwindowdump"],["xyz","chemical/x-xyz"],["xz","application/x-xz"],["yaml","text/yaml"],["yang","application/yang"],["yin","application/yin+xml"],["yml","text/yaml"],["ymp","text/x-suse-ymp"],["z","application/x-compress"],["z1","application/x-zmachine"],["z2","application/x-zmachine"],["z3","application/x-zmachine"],["z4","application/x-zmachine"],["z5","application/x-zmachine"],["z6","application/x-zmachine"],["z7","application/x-zmachine"],["z8","application/x-zmachine"],["zaz","application/vnd.zzazz.deck+xml"],["zip","application/zip"],["zir","application/vnd.zul"],["zirz","application/vnd.zul"],["zmm","application/vnd.handheld-entertainment+xml"],["zsh","text/x-scriptzsh"]]);function Fs(e,t,n){const r=wie(e),{webkitRelativePath:i}=e,a=typeof t=="string"?t:typeof i=="string"&&i.length>0?i:`./${e.name}`;return typeof r.path!="string"&&iI(r,"path",a),iI(r,"relativePath",a),r}function wie(e){const{name:t}=e;if(t&&t.lastIndexOf(".")!==-1&&!e.type){const r=t.split(".").pop().toLowerCase(),i=gie.get(r);i&&Object.defineProperty(e,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return e}function iI(e,t,n){Object.defineProperty(e,t,{value:n,writable:!1,configurable:!1,enumerable:!0})}const yie=[".DS_Store","Thumbs.db"];function vie(e){return Wr(this,void 0,void 0,function*(){return Jp(e)&&bie(e.dataTransfer)?_ie(e.dataTransfer,e.type):xie(e)?Eie(e):Array.isArray(e)&&e.every(t=>"getFile"in t&&typeof t.getFile=="function")?Tie(e):[]})}function bie(e){return Jp(e)}function xie(e){return Jp(e)&&Jp(e.target)}function Jp(e){return typeof e=="object"&&e!==null}function Eie(e){return rv(e.target.files).map(t=>Fs(t))}function Tie(e){return Wr(this,void 0,void 0,function*(){return(yield Promise.all(e.map(n=>n.getFile()))).map(n=>Fs(n))})}function _ie(e,t){return Wr(this,void 0,void 0,function*(){if(e.items){const n=rv(e.items).filter(i=>i.kind==="file");if(t!=="drop")return n;const r=yield Promise.all(n.map(Sie));return aI(oI(r))}return aI(rv(e.files).map(n=>Fs(n)))})}function aI(e){return e.filter(t=>yie.indexOf(t.name)===-1)}function rv(e){if(e===null)return[];const t=[];for(let n=0;n<e.length;n++){const r=e[n];t.push(r)}return t}function Sie(e){if(typeof e.webkitGetAsEntry!="function")return sI(e);const t=e.webkitGetAsEntry();return t&&t.isDirectory?lI(t):sI(e,t)}function oI(e){return e.reduce((t,n)=>[...t,...Array.isArray(n)?oI(n):[n]],[])}function sI(e,t){var n;if(typeof e.getAsFileSystemHandle=="function")return e.getAsFileSystemHandle().then(a=>Wr(this,void 0,void 0,function*(){const o=yield a.getFile();return o.handle=a,Fs(o)}));const r=e.getAsFile();if(!r)return Promise.reject(`${e} is not a File`);const i=Fs(r,(n=t==null?void 0:t.fullPath)!==null&&n!==void 0?n:void 0);return Promise.resolve(i)}function kie(e){return Wr(this,void 0,void 0,function*(){return e.isDirectory?lI(e):Cie(e)})}function lI(e){const t=e.createReader();return new Promise((n,r)=>{const i=[];function a(){t.readEntries(o=>Wr(this,void 0,void 0,function*(){if(o.length){const s=Promise.all(o.map(kie));i.push(s),a()}else try{const s=yield Promise.all(i);n(s)}catch(s){r(s)}}),o=>{r(o)})}a()})}function Cie(e){return Wr(this,void 0,void 0,function*(){return new Promise((t,n)=>{e.file(r=>{const i=Fs(r,e.fullPath);t(i)},r=>{n(r)})})})}var iv=function(e,t){if(e&&t){var n=Array.isArray(t)?t:t.split(",");if(n.length===0)return!0;var r=e.name||"",i=(e.type||"").toLowerCase(),a=i.replace(/\/.*$/,"");return n.some(function(o){var s=o.trim().toLowerCase();return s.charAt(0)==="."?r.toLowerCase().endsWith(s):s.endsWith("/*")?a===s.replace(/\/.*$/,""):i===s})}return!0};function uI(e){return Nie(e)||Rie(e)||pI(e)||Aie()}function Aie(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
240
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Rie(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Nie(e){if(Array.isArray(e))return av(e)}function cI(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function dI(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?cI(Object(n),!0).forEach(function(r){fI(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function fI(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pc(e,t){return Iie(e)||Pie(e,t)||pI(e,t)||Oie()}function Oie(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
241
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function pI(e,t){if(e){if(typeof e=="string")return av(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return av(e,t)}}function av(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Pie(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],i=!0,a=!1,o,s;try{for(n=n.call(e);!(i=(o=n.next()).done)&&(r.push(o.value),!(t&&r.length===t));i=!0);}catch(l){a=!0,s=l}finally{try{!i&&n.return!=null&&n.return()}finally{if(a)throw s}}return r}}function Iie(e){if(Array.isArray(e))return e}var Die=typeof iv=="function"?iv:iv.default,Lie="file-invalid-type",Mie="file-too-large",Fie="file-too-small",Bie="too-many-files",jie=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",n=t.split(","),r=n.length>1?"one of ".concat(n.join(", ")):n[0];return{code:Lie,message:"File type must be ".concat(r)}},hI=function(t){return{code:Mie,message:"File is larger than ".concat(t," ").concat(t===1?"byte":"bytes")}},mI=function(t){return{code:Fie,message:"File is smaller than ".concat(t," ").concat(t===1?"byte":"bytes")}},zie={code:Bie,message:"Too many files"};function gI(e,t){var n=e.type==="application/x-moz-file"||Die(e,t);return[n,n?null:jie(t)]}function wI(e,t,n){if(fo(e.size))if(fo(t)&&fo(n)){if(e.size>n)return[!1,hI(n)];if(e.size<t)return[!1,mI(t)]}else{if(fo(t)&&e.size<t)return[!1,mI(t)];if(fo(n)&&e.size>n)return[!1,hI(n)]}return[!0,null]}function fo(e){return e!=null}function Uie(e){var t=e.files,n=e.accept,r=e.minSize,i=e.maxSize,a=e.multiple,o=e.maxFiles,s=e.validator;return!a&&t.length>1||a&&o>=1&&t.length>o?!1:t.every(function(l){var u=gI(l,n),c=pc(u,1),d=c[0],f=wI(l,r,i),p=pc(f,1),g=p[0],w=s?s(l):null;return d&&g&&!w})}function eh(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function th(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,function(t){return t==="Files"||t==="application/x-moz-file"}):!!e.target&&!!e.target.files}function yI(e){e.preventDefault()}function Hie(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function Vie(e){return e.indexOf("Edge/")!==-1}function $ie(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return Hie(e)||Vie(e)}function Ur(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(r){for(var i=arguments.length,a=new Array(i>1?i-1:0),o=1;o<i;o++)a[o-1]=arguments[o];return t.some(function(s){return!eh(r)&&s&&s.apply(void 0,[r].concat(a)),eh(r)})}}function Wie(){return"showOpenFilePicker"in window}function Yie(e){if(fo(e)){var t=Object.entries(e).filter(function(n){var r=pc(n,2),i=r[0],a=r[1],o=!0;return vI(i)||(console.warn('Skipped "'.concat(i,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),o=!1),(!Array.isArray(a)||!a.every(bI))&&(console.warn('Skipped "'.concat(i,'" because an invalid file extension was provided.')),o=!1),o}).reduce(function(n,r){var i=pc(r,2),a=i[0],o=i[1];return dI(dI({},n),{},fI({},a,o))},{});return[{description:"Files",accept:t}]}return e}function qie(e){if(fo(e))return Object.entries(e).reduce(function(t,n){var r=pc(n,2),i=r[0],a=r[1];return[].concat(uI(t),[i],uI(a))},[]).filter(function(t){return vI(t)||bI(t)}).join(",")}function Gie(e){return e instanceof DOMException&&(e.name==="AbortError"||e.code===e.ABORT_ERR)}function Kie(e){return e instanceof DOMException&&(e.name==="SecurityError"||e.code===e.SECURITY_ERR)}function vI(e){return e==="audio/*"||e==="video/*"||e==="image/*"||e==="text/*"||e==="application/*"||/\w+\/[-+.\w]+/g.test(e)}function bI(e){return/^.*\.[\w]+$/.test(e)}var Xie=["children"],Qie=["open"],Zie=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],Jie=["refKey","onChange","onClick"];function eae(e){return rae(e)||nae(e)||xI(e)||tae()}function tae(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
242
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function nae(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function rae(e){if(Array.isArray(e))return sv(e)}function ov(e,t){return oae(e)||aae(e,t)||xI(e,t)||iae()}function iae(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
243
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xI(e,t){if(e){if(typeof e=="string")return sv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return sv(e,t)}}function sv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function aae(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],i=!0,a=!1,o,s;try{for(n=n.call(e);!(i=(o=n.next()).done)&&(r.push(o.value),!(t&&r.length===t));i=!0);}catch(l){a=!0,s=l}finally{try{!i&&n.return!=null&&n.return()}finally{if(a)throw s}}return r}}function oae(e){if(Array.isArray(e))return e}function EI(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ut(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?EI(Object(n),!0).forEach(function(r){lv(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):EI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lv(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nh(e,t){if(e==null)return{};var n=sae(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function sae(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,a;for(a=0;a<r.length;a++)i=r[a],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}var uv=y.forwardRef(function(e,t){var n=e.children,r=nh(e,Xie),i=_I(r),a=i.open,o=nh(i,Qie);return y.useImperativeHandle(t,function(){return{open:a}},[a]),_t.createElement(y.Fragment,null,n(ut(ut({},o),{},{open:a})))});uv.displayName="Dropzone";var TI={disabled:!1,getFilesFromEvent:vie,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1,autoFocus:!1};uv.defaultProps=TI,uv.propTypes={children:Ge.func,accept:Ge.objectOf(Ge.arrayOf(Ge.string)),multiple:Ge.bool,preventDropOnDocument:Ge.bool,noClick:Ge.bool,noKeyboard:Ge.bool,noDrag:Ge.bool,noDragEventsBubbling:Ge.bool,minSize:Ge.number,maxSize:Ge.number,maxFiles:Ge.number,disabled:Ge.bool,getFilesFromEvent:Ge.func,onFileDialogCancel:Ge.func,onFileDialogOpen:Ge.func,useFsAccessApi:Ge.bool,autoFocus:Ge.bool,onDragEnter:Ge.func,onDragLeave:Ge.func,onDragOver:Ge.func,onDrop:Ge.func,onDropAccepted:Ge.func,onDropRejected:Ge.func,onError:Ge.func,validator:Ge.func};var cv={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function _I(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=ut(ut({},TI),e),n=t.accept,r=t.disabled,i=t.getFilesFromEvent,a=t.maxSize,o=t.minSize,s=t.multiple,l=t.maxFiles,u=t.onDragEnter,c=t.onDragLeave,d=t.onDragOver,f=t.onDrop,p=t.onDropAccepted,g=t.onDropRejected,w=t.onFileDialogCancel,x=t.onFileDialogOpen,m=t.useFsAccessApi,v=t.autoFocus,b=t.preventDropOnDocument,T=t.noClick,_=t.noKeyboard,S=t.noDrag,R=t.noDragEventsBubbling,P=t.onError,B=t.validator,N=y.useMemo(function(){return qie(n)},[n]),H=y.useMemo(function(){return Yie(n)},[n]),U=y.useMemo(function(){return typeof x=="function"?x:SI},[x]),K=y.useMemo(function(){return typeof w=="function"?w:SI},[w]),X=y.useRef(null),ee=y.useRef(null),oe=y.useReducer(lae,cv),ne=ov(oe,2),L=ne[0],F=ne[1],C=L.isFocused,te=L.isFileDialogActive,fe=y.useRef(typeof window<"u"&&window.isSecureContext&&m&&Wie()),I=function(){!fe.current&&te&&setTimeout(function(){if(ee.current){var le=ee.current.files;le.length||(F({type:"closeDialog"}),K())}},300)};y.useEffect(function(){return window.addEventListener("focus",I,!1),function(){window.removeEventListener("focus",I,!1)}},[ee,te,K,fe]);var ke=y.useRef([]),Ye=function(le){X.current&&X.current.contains(le.target)||(le.preventDefault(),ke.current=[])};y.useEffect(function(){return b&&(document.addEventListener("dragover",yI,!1),document.addEventListener("drop",Ye,!1)),function(){b&&(document.removeEventListener("dragover",yI),document.removeEventListener("drop",Ye))}},[X,b]),y.useEffect(function(){return!r&&v&&X.current&&X.current.focus(),function(){}},[X,v,r]);var J=y.useCallback(function(Z){P?P(Z):console.error(Z)},[P]),de=y.useCallback(function(Z){Z.preventDefault(),Z.persist(),Mt(Z),ke.current=[].concat(eae(ke.current),[Z.target]),th(Z)&&Promise.resolve(i(Z)).then(function(le){if(!(eh(Z)&&!R)){var M=le.length,$=M>0&&Uie({files:le,accept:N,minSize:o,maxSize:a,multiple:s,maxFiles:l,validator:B}),se=M>0&&!$;F({isDragAccept:$,isDragReject:se,isDragActive:!0,type:"setDraggedFiles"}),u&&u(Z)}}).catch(function(le){return J(le)})},[i,u,J,R,N,o,a,s,l,B]),Se=y.useCallback(function(Z){Z.preventDefault(),Z.persist(),Mt(Z);var le=th(Z);if(le&&Z.dataTransfer)try{Z.dataTransfer.dropEffect="copy"}catch{}return le&&d&&d(Z),!1},[d,R]),Ce=y.useCallback(function(Z){Z.preventDefault(),Z.persist(),Mt(Z);var le=ke.current.filter(function($){return X.current&&X.current.contains($)}),M=le.indexOf(Z.target);M!==-1&&le.splice(M,1),ke.current=le,!(le.length>0)&&(F({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),th(Z)&&c&&c(Z))},[X,c,R]),Re=y.useCallback(function(Z,le){var M=[],$=[];Z.forEach(function(se){var Te=gI(se,N),Fe=ov(Te,2),on=Fe[0],xr=Fe[1],Ln=wI(se,o,a),Hr=ov(Ln,2),Ti=Hr[0],Ft=Hr[1],Vr=B?B(se):null;if(on&&Ti&&!Vr)M.push(se);else{var Mn=[xr,Ft];Vr&&(Mn=Mn.concat(Vr)),$.push({file:se,errors:Mn.filter(function(Zoe){return Zoe})})}}),(!s&&M.length>1||s&&l>=1&&M.length>l)&&(M.forEach(function(se){$.push({file:se,errors:[zie]})}),M.splice(0)),F({acceptedFiles:M,fileRejections:$,isDragReject:$.length>0,type:"setFiles"}),f&&f(M,$,le),$.length>0&&g&&g($,le),M.length>0&&p&&p(M,le)},[F,s,N,o,a,l,f,p,g,B]),vt=y.useCallback(function(Z){Z.preventDefault(),Z.persist(),Mt(Z),ke.current=[],th(Z)&&Promise.resolve(i(Z)).then(function(le){eh(Z)&&!R||Re(le,Z)}).catch(function(le){return J(le)}),F({type:"reset"})},[i,Re,J,R]),xe=y.useCallback(function(){if(fe.current){F({type:"openDialog"}),U();var Z={multiple:s,types:H};window.showOpenFilePicker(Z).then(function(le){return i(le)}).then(function(le){Re(le,null),F({type:"closeDialog"})}).catch(function(le){Gie(le)?(K(le),F({type:"closeDialog"})):Kie(le)?(fe.current=!1,ee.current?(ee.current.value=null,ee.current.click()):J(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):J(le)});return}ee.current&&(F({type:"openDialog"}),U(),ee.current.value=null,ee.current.click())},[F,U,K,m,Re,J,H,s]),we=y.useCallback(function(Z){!X.current||!X.current.isEqualNode(Z.target)||(Z.key===" "||Z.key==="Enter"||Z.keyCode===32||Z.keyCode===13)&&(Z.preventDefault(),xe())},[X,xe]),Ve=y.useCallback(function(){F({type:"focus"})},[]),je=y.useCallback(function(){F({type:"blur"})},[]),bt=y.useCallback(function(){T||($ie()?setTimeout(xe,0):xe())},[T,xe]),xt=function(le){return r?null:le},Ke=function(le){return _?null:xt(le)},ze=function(le){return S?null:xt(le)},Mt=function(le){R&&le.stopPropagation()},Hs=y.useMemo(function(){return function(){var Z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},le=Z.refKey,M=le===void 0?"ref":le,$=Z.role,se=Z.onKeyDown,Te=Z.onFocus,Fe=Z.onBlur,on=Z.onClick,xr=Z.onDragEnter,Ln=Z.onDragOver,Hr=Z.onDragLeave,Ti=Z.onDrop,Ft=nh(Z,Zie);return ut(ut(lv({onKeyDown:Ke(Ur(se,we)),onFocus:Ke(Ur(Te,Ve)),onBlur:Ke(Ur(Fe,je)),onClick:xt(Ur(on,bt)),onDragEnter:ze(Ur(xr,de)),onDragOver:ze(Ur(Ln,Se)),onDragLeave:ze(Ur(Hr,Ce)),onDrop:ze(Ur(Ti,vt)),role:typeof $=="string"&&$!==""?$:"presentation"},M,X),!r&&!_?{tabIndex:0}:{}),Ft)}},[X,we,Ve,je,bt,de,Se,Ce,vt,_,S,r]),Vs=y.useCallback(function(Z){Z.stopPropagation()},[]),$s=y.useMemo(function(){return function(){var Z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},le=Z.refKey,M=le===void 0?"ref":le,$=Z.onChange,se=Z.onClick,Te=nh(Z,Jie),Fe=lv({accept:N,multiple:s,type:"file",style:{border:0,clip:"rect(0, 0, 0, 0)",clipPath:"inset(50%)",height:"1px",margin:"0 -1px -1px 0",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"},onChange:xt(Ur($,vt)),onClick:xt(Ur(se,Vs)),tabIndex:-1},M,ee);return ut(ut({},Fe),Te)}},[ee,n,s,vt,r]);return ut(ut({},L),{},{isFocused:C&&!r,getRootProps:Hs,getInputProps:$s,rootRef:X,inputRef:ee,open:xt(xe)})}function lae(e,t){switch(t.type){case"focus":return ut(ut({},e),{},{isFocused:!0});case"blur":return ut(ut({},e),{},{isFocused:!1});case"openDialog":return ut(ut({},cv),{},{isFileDialogActive:!0});case"closeDialog":return ut(ut({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return ut(ut({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return ut(ut({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections,isDragReject:t.isDragReject});case"reset":return ut({},cv);default:return e}}function SI(){}let uae={data:""},cae=e=>typeof window=="object"?((e?e.querySelector("#_goober"):window._goober)||Object.assign((e||document.head).appendChild(document.createElement("style")),{innerHTML:" ",id:"_goober"})).firstChild:e||uae,dae=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,fae=/\/\*[^]*?\*\/| +/g,kI=/\n+/g,xa=(e,t)=>{let n="",r="",i="";for(let a in e){let o=e[a];a[0]=="@"?a[1]=="i"?n=a+" "+o+";":r+=a[1]=="f"?xa(o,a):a+"{"+xa(o,a[1]=="k"?"":t)+"}":typeof o=="object"?r+=xa(o,t?t.replace(/([^,])+/g,s=>a.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,l=>/&/.test(l)?l.replace(/&/g,s):s?s+" "+l:l)):a):o!=null&&(a=/^--/.test(a)?a:a.replace(/[A-Z]/g,"-$&").toLowerCase(),i+=xa.p?xa.p(a,o):a+":"+o+";")}return n+(t&&i?t+"{"+i+"}":i)+r},xi={},CI=e=>{if(typeof e=="object"){let t="";for(let n in e)t+=n+CI(e[n]);return t}return e},pae=(e,t,n,r,i)=>{let a=CI(e),o=xi[a]||(xi[a]=(l=>{let u=0,c=11;for(;u<l.length;)c=101*c+l.charCodeAt(u++)>>>0;return"go"+c})(a));if(!xi[o]){let l=a!==e?e:(u=>{let c,d,f=[{}];for(;c=dae.exec(u.replace(fae,""));)c[4]?f.shift():c[3]?(d=c[3].replace(kI," ").trim(),f.unshift(f[0][d]=f[0][d]||{})):f[0][c[1]]=c[2].replace(kI," ").trim();return f[0]})(e);xi[o]=xa(i?{["@keyframes "+o]:l}:l,n?"":"."+o)}let s=n&&xi.g?xi.g:null;return n&&(xi.g=xi[o]),((l,u,c,d)=>{d?u.data=u.data.replace(d,l):u.data.indexOf(l)===-1&&(u.data=c?l+u.data:u.data+l)})(xi[o],t,r,s),o},hae=(e,t,n)=>e.reduce((r,i,a)=>{let o=t[a];if(o&&o.call){let s=o(n),l=s&&s.props&&s.props.className||/^go/.test(s)&&s;o=l?"."+l:s&&typeof s=="object"?s.props?"":xa(s,""):s===!1?"":s}return r+i+(o??"")},"");function rh(e){let t=this||{},n=e.call?e(t.p):e;return pae(n.unshift?n.raw?hae(n,[].slice.call(arguments,1),t.p):n.reduce((r,i)=>Object.assign(r,i&&i.call?i(t.p):i),{}):n,cae(t.target),t.g,t.o,t.k)}let AI,dv,fv;rh.bind({g:1});let Ei=rh.bind({k:1});function mae(e,t,n,r){xa.p=t,AI=e,dv=n,fv=r}function Ea(e,t){let n=this||{};return function(){let r=arguments;function i(a,o){let s=Object.assign({},a),l=s.className||i.className;n.p=Object.assign({theme:dv&&dv()},s),n.o=/ *go\d+/.test(l),s.className=rh.apply(n,r)+(l?" "+l:"");let u=e;return e[0]&&(u=s.as||e,delete s.as),fv&&u[0]&&fv(s),AI(u,s)}return i}}var gae=e=>typeof e=="function",pv=(e,t)=>gae(e)?e(t):e,wae=(()=>{let e=0;return()=>(++e).toString()})(),yae=(()=>{let e;return()=>{if(e===void 0&&typeof window<"u"){let t=matchMedia("(prefers-reduced-motion: reduce)");e=!t||t.matches}return e}})(),vae=20,ih=new Map,bae=1e3,RI=e=>{if(ih.has(e))return;let t=setTimeout(()=>{ih.delete(e),ah({type:4,toastId:e})},bae);ih.set(e,t)},xae=e=>{let t=ih.get(e);t&&clearTimeout(t)},hv=(e,t)=>{switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,vae)};case 1:return t.toast.id&&xae(t.toast.id),{...e,toasts:e.toasts.map(a=>a.id===t.toast.id?{...a,...t.toast}:a)};case 2:let{toast:n}=t;return e.toasts.find(a=>a.id===n.id)?hv(e,{type:1,toast:n}):hv(e,{type:0,toast:n});case 3:let{toastId:r}=t;return r?RI(r):e.toasts.forEach(a=>{RI(a.id)}),{...e,toasts:e.toasts.map(a=>a.id===r||r===void 0?{...a,visible:!1}:a)};case 4:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(a=>a.id!==t.toastId)};case 5:return{...e,pausedAt:t.time};case 6:let i=t.time-(e.pausedAt||0);return{...e,pausedAt:void 0,toasts:e.toasts.map(a=>({...a,pauseDuration:a.pauseDuration+i}))}}},Eae=[],mv={toasts:[],pausedAt:void 0},ah=e=>{mv=hv(mv,e),Eae.forEach(t=>{t(mv)})},Tae=(e,t="blank",n)=>({createdAt:Date.now(),visible:!0,type:t,ariaProps:{role:"status","aria-live":"polite"},message:e,pauseDuration:0,...n,id:(n==null?void 0:n.id)||wae()}),hc=e=>(t,n)=>{let r=Tae(t,e,n);return ah({type:2,toast:r}),r.id},br=(e,t)=>hc("blank")(e,t);br.error=hc("error"),br.success=hc("success"),br.loading=hc("loading"),br.custom=hc("custom"),br.dismiss=e=>{ah({type:3,toastId:e})},br.remove=e=>ah({type:4,toastId:e}),br.promise=(e,t,n)=>{let r=br.loading(t.loading,{...n,...n==null?void 0:n.loading});return e.then(i=>(br.success(pv(t.success,i),{id:r,...n,...n==null?void 0:n.success}),i)).catch(i=>{br.error(pv(t.error,i),{id:r,...n,...n==null?void 0:n.error})}),e};var _ae=Ei`
244
+ from {
245
+ transform: scale(0) rotate(45deg);
246
+ opacity: 0;
247
+ }
248
+ to {
249
+ transform: scale(1) rotate(45deg);
250
+ opacity: 1;
251
+ }`,Sae=Ei`
252
+ from {
253
+ transform: scale(0);
254
+ opacity: 0;
255
+ }
256
+ to {
257
+ transform: scale(1);
258
+ opacity: 1;
259
+ }`,kae=Ei`
260
+ from {
261
+ transform: scale(0) rotate(90deg);
262
+ opacity: 0;
263
+ }
264
+ to {
265
+ transform: scale(1) rotate(90deg);
266
+ opacity: 1;
267
+ }`,Cae=Ea("div")`
268
+ width: 20px;
269
+ opacity: 0;
270
+ height: 20px;
271
+ border-radius: 10px;
272
+ background: ${e=>e.primary||"#ff4b4b"};
273
+ position: relative;
274
+ transform: rotate(45deg);
275
+
276
+ animation: ${_ae} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
277
+ forwards;
278
+ animation-delay: 100ms;
279
+
280
+ &:after,
281
+ &:before {
282
+ content: '';
283
+ animation: ${Sae} 0.15s ease-out forwards;
284
+ animation-delay: 150ms;
285
+ position: absolute;
286
+ border-radius: 3px;
287
+ opacity: 0;
288
+ background: ${e=>e.secondary||"#fff"};
289
+ bottom: 9px;
290
+ left: 4px;
291
+ height: 2px;
292
+ width: 12px;
293
+ }
294
+
295
+ &:before {
296
+ animation: ${kae} 0.15s ease-out forwards;
297
+ animation-delay: 180ms;
298
+ transform: rotate(90deg);
299
+ }
300
+ `,Aae=Ei`
301
+ from {
302
+ transform: rotate(0deg);
303
+ }
304
+ to {
305
+ transform: rotate(360deg);
306
+ }
307
+ `,Rae=Ea("div")`
308
+ width: 12px;
309
+ height: 12px;
310
+ box-sizing: border-box;
311
+ border: 2px solid;
312
+ border-radius: 100%;
313
+ border-color: ${e=>e.secondary||"#e0e0e0"};
314
+ border-right-color: ${e=>e.primary||"#616161"};
315
+ animation: ${Aae} 1s linear infinite;
316
+ `,Nae=Ei`
317
+ from {
318
+ transform: scale(0) rotate(45deg);
319
+ opacity: 0;
320
+ }
321
+ to {
322
+ transform: scale(1) rotate(45deg);
323
+ opacity: 1;
324
+ }`,Oae=Ei`
325
+ 0% {
326
+ height: 0;
327
+ width: 0;
328
+ opacity: 0;
329
+ }
330
+ 40% {
331
+ height: 0;
332
+ width: 6px;
333
+ opacity: 1;
334
+ }
335
+ 100% {
336
+ opacity: 1;
337
+ height: 10px;
338
+ }`,Pae=Ea("div")`
339
+ width: 20px;
340
+ opacity: 0;
341
+ height: 20px;
342
+ border-radius: 10px;
343
+ background: ${e=>e.primary||"#61d345"};
344
+ position: relative;
345
+ transform: rotate(45deg);
346
+
347
+ animation: ${Nae} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
348
+ forwards;
349
+ animation-delay: 100ms;
350
+ &:after {
351
+ content: '';
352
+ box-sizing: border-box;
353
+ animation: ${Oae} 0.2s ease-out forwards;
354
+ opacity: 0;
355
+ animation-delay: 200ms;
356
+ position: absolute;
357
+ border-right: 2px solid;
358
+ border-bottom: 2px solid;
359
+ border-color: ${e=>e.secondary||"#fff"};
360
+ bottom: 6px;
361
+ left: 6px;
362
+ height: 10px;
363
+ width: 6px;
364
+ }
365
+ `,Iae=Ea("div")`
366
+ position: absolute;
367
+ `,Dae=Ea("div")`
368
+ position: relative;
369
+ display: flex;
370
+ justify-content: center;
371
+ align-items: center;
372
+ min-width: 20px;
373
+ min-height: 20px;
374
+ `,Lae=Ei`
375
+ from {
376
+ transform: scale(0.6);
377
+ opacity: 0.4;
378
+ }
379
+ to {
380
+ transform: scale(1);
381
+ opacity: 1;
382
+ }`,Mae=Ea("div")`
383
+ position: relative;
384
+ transform: scale(0.6);
385
+ opacity: 0.4;
386
+ min-width: 20px;
387
+ animation: ${Lae} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275)
388
+ forwards;
389
+ `,Fae=({toast:e})=>{let{icon:t,type:n,iconTheme:r}=e;return t!==void 0?typeof t=="string"?y.createElement(Mae,null,t):t:n==="blank"?null:y.createElement(Dae,null,y.createElement(Rae,{...r}),n!=="loading"&&y.createElement(Iae,null,n==="error"?y.createElement(Cae,{...r}):y.createElement(Pae,{...r})))},Bae=e=>`
390
+ 0% {transform: translate3d(0,${e*-200}%,0) scale(.6); opacity:.5;}
391
+ 100% {transform: translate3d(0,0,0) scale(1); opacity:1;}
392
+ `,jae=e=>`
393
+ 0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}
394
+ 100% {transform: translate3d(0,${e*-150}%,-1px) scale(.6); opacity:0;}
395
+ `,zae="0%{opacity:0;} 100%{opacity:1;}",Uae="0%{opacity:1;} 100%{opacity:0;}",Hae=Ea("div")`
396
+ display: flex;
397
+ align-items: center;
398
+ background: #fff;
399
+ color: #363636;
400
+ line-height: 1.3;
401
+ will-change: transform;
402
+ box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1), 0 3px 3px rgba(0, 0, 0, 0.05);
403
+ max-width: 350px;
404
+ pointer-events: auto;
405
+ padding: 8px 10px;
406
+ border-radius: 8px;
407
+ `,Vae=Ea("div")`
408
+ display: flex;
409
+ justify-content: center;
410
+ margin: 4px 10px;
411
+ color: inherit;
412
+ flex: 1 1 auto;
413
+ white-space: pre-line;
414
+ `,$ae=(e,t)=>{let n=e.includes("top")?1:-1,[r,i]=yae()?[zae,Uae]:[Bae(n),jae(n)];return{animation:t?`${Ei(r)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${Ei(i)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}};y.memo(({toast:e,position:t,style:n,children:r})=>{let i=e.height?$ae(e.position||t||"top-center",e.visible):{opacity:0},a=y.createElement(Fae,{toast:e}),o=y.createElement(Vae,{...e.ariaProps},pv(e.message,e));return y.createElement(Hae,{className:e.className,style:{...i,...n,...e.style}},typeof r=="function"?r({icon:a,message:o}):y.createElement(y.Fragment,null,a,o))}),mae(y.createElement),rh`
415
+ z-index: 9999;
416
+ > * {
417
+ pointer-events: auto;
418
+ }
419
+ `;var NI=br;function Wae({file:{status:e,file:t,error:n},onCancel:r}){const[i,a]=y.useState(null);y.useEffect(()=>{if(!t.type.startsWith("image/"))return;const l=new FileReader;return l.onload=()=>a(l.result),l.onerror=()=>console.error("Error reading file"),l.readAsDataURL(t),()=>l.abort()},[t]);const o=()=>{switch(e){case"uploading":return E.jsx($ee,{className:"size-4 animate-spin"});case"error":return E.jsx(Bee,{className:"size-4 text-destructive"});default:return null}},s=()=>{const l=t.type.split("/")[0];return l==="image"&&i?E.jsx("img",{src:typeof i=="string"?i:"",className:"object-cover bg-secondary size-full",alt:t.name}):l==="audio"?E.jsx(Hee,{}):E.jsx(Vee,{})};return E.jsx(mw,{content:e==="error"?E.jsxs("span",{className:"text-destructive",children:["Failed to upload: ",n]}):t.name,children:E.jsxs("div",{className:He(e==="uploading"&&"opacity-50","group","size-12 border rounded-2xl overflow-hidden relative","flex items-center justify-center shrink-0"),children:[E.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:o()}),E.jsx("button",{className:He("absolute bg-black/50 inset-0 size-full z-10 opacity-0","flex items-center justify-center","opacity-0 group-hover:opacity-100 transition"),onClick:r,children:E.jsx(JN,{className:"size-4 text-primary-foreground"})}),E.jsx(s,{})]})})}const OI=He("rounded-3xl");function Yae(){const{collectUserData:e}=Bt(),t=y.useRef(null),{sendMessage:n,hookState:r,session:i}=Ao(),{contact:a}=xm(),o=Qs(),[s,l]=y.useState(""),{allFiles:u,emptyTheFiles:c,handleCancelUpload:d,appendFiles:f,isUploading:p,successFiles:g}=T5(),w=i&&((i==null?void 0:i.isAssignedToHuman)||i.ai_closure_type===Yc.handed_off),x=P=>{w&&f(P)},m=async()=>{r.state!=="loading"&&(p&&NI.error("please wait for the file(s) to upload"),s.trim()&&(await n({content:{text:s.trim()},user:{email:(a==null?void 0:a.email)??void 0,name:(a==null?void 0:a.name)??void 0},attachments:g.map(P=>({url:P.fileUrl,type:P.file.type,name:P.file.name,id:P.id,size:P.file.size}))}),l(""),c()))},{getRootProps:v,getInputProps:b,open:T}=_I({onDrop:x,noClick:!0,onDropRejected(){w&&NI.error("unsupported file type, or the file is too large")},maxSize:5*1024*1024,accept:{"text/*":[".txt"],"image/*":[".png",".jpg",".jpeg",".gif"],"application/pdf":[".pdf"]}}),_=r.state==="loading",S=e&&!(a!=null&&a.id),R=P=>{const B=P.clipboardData;B&&B.files.length>0&&x(Array.from(B.files))};return E.jsxs("div",{className:"p-2 relative space-y-1",...v(),children:[E.jsx("input",{...b()}),E.jsxs("div",{className:He(OI,"relative space-y-2 border transition-all shadow py-2"),children:[E.jsx("div",{className:"flex items-center gap-1 px-2",children:E.jsx(lo,{mode:"popLayout",children:u.map(P=>E.jsx(vr,{snapExit:!0,children:E.jsx(Wae,{onCancel:()=>d(P.id),file:P})},P.id))})}),E.jsx("textarea",{onPaste:R,ref:t,id:"chat-input",dir:"auto",disabled:_,value:s,rows:3,className:He(OI,"w-full px-3","resize-none","bg-transparent outline-none","text-sm"),onChange:P=>l(P.target.value),onKeyDown:async P=>{P.key==="Enter"&&!P.shiftKey&&(P.preventDefault(),m())},placeholder:o.get("write-a-message")}),E.jsxs("div",{className:"px-2 flex justify-between",children:[E.jsx(mw,{side:"top",align:"end",content:"attach files, (maximum size 5mb)",children:E.jsx(uo,{onClick:()=>{w&&T()},size:"fit",variant:"outline",className:He("disabled:opacity-0","rounded-full size-8 flex items-center justify-center p-0"),disabled:!w,children:E.jsx(Wee,{className:"size-4"})})}),E.jsx(mw,{content:"send message",children:E.jsx(uo,{size:"fit",onClick:m,disabled:_||S||p,className:"rounded-full size-8 flex items-center justify-center p-0",children:_?E.jsx(jee,{className:"size-4 animate-spin animate-iteration-infinite"}):E.jsx(ZN,{className:"size-4 rtl:-scale-100"})})})]})]})]})}function qae(){const{state:e,hookState:t}=Ao(),{componentStore:n,initialMessages:r,...i}=Bt(),a=n.getComponent("loading"),o=y.useRef(null);function s(){setTimeout(()=>{const l=o.current;l&&(l.scrollTop=l.scrollHeight)},0)}return y.useEffect(()=>{s()},[e.messages]),E.jsxs("div",{"data-messages":!0,ref:o,className:"max-h-full scroll-smooth relative flex-1 py-4 px-3 space-y-3 overflow-auto",children:[e.messages.length===0&&((r==null?void 0:r.map((l,u)=>E.jsx(Pp,{message:{component:"text",data:{message:l},id:`initial-${u}`,type:"FROM_BOT"},Wrapper:k1,wrapperProps:{agent:i.bot}},u)))??E.jsx(Pp,{message:{component:"text",data:{message:"Hello, how can I help?"},id:"default-welcome",type:"FROM_BOT",agent:i.bot},Wrapper:k1,wrapperProps:{agent:i.bot}},"default-welcome")),e.messages.map(l=>l.type==="FROM_USER"?E.jsx(Qee,{message:l,user:i.user,children:l.content},l.id):l.type==="FROM_BOT"?l.component=="CHAT_EVENT"?E.jsx(Pp,{message:l},l.id):E.jsx(Pp,{message:l,Wrapper:k1,wrapperProps:{agent:l.agent}},l.id):null),t.state==="loading"&&E.jsx(a,{})]})}function Gae(){var s;const{state:e,sendMessage:t,noMessages:n,handleKeyboard:r}=Ao(),a=(s=Lm().data)==null?void 0:s.initial_questions,{observedElementRef:o}=Jb({fallbackHeight:zJ});return E.jsxs("div",{ref:o,className:He(A1.widgetHeight,"w-full flex flex-col overflow-hidden bg-background z-10 origin-bottom absolute bottom-0 inset-x-0"),children:[E.jsxs("div",{className:"w-full h-full justify-between flex flex-col relative",style:{background:"linear-gradient(333.89deg, rgba(75, 240, 171, 0.8) 58%, rgba(75, 240, 171, 0) 85.74%), linear-gradient(113.43deg, #46B1FF 19.77%, #1883FF 65.81%)"},children:[E.jsx(rie,{}),E.jsxs("div",{className:"flex bg-background shadow-lg flex-col w-full flex-1 overflow-auto",children:[E.jsx(qae,{}),E.jsxs("footer",{children:[e.keyboard&&E.jsx(nte,{options:e.keyboard.options,onKeyboardClick:r}),n&&a&&E.jsx("div",{className:"flex items-center flex-row justify-end gap-2 flex-wrap px-2",children:a==null?void 0:a.map((l,u)=>E.jsx(uo,{dir:"auto",variant:"outline",size:"sm",onClick:()=>{t({content:{text:l}})},children:l},u))}),E.jsx(Yae,{})]})]})]}),E.jsx(cie,{})]})}const gv=y.forwardRef(({className:e,type:t,...n},r)=>E.jsx(oc,{ref:r,children:E.jsx("input",{type:t,className:He("flex w-full rounded-xl border border-input bg-background p-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-primary-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 transition",e),...n})}));gv.displayName="Input";const Kae=Q.object({name:Q.string().min(2),email:Q.string().email()});function Xae(){const e=Qs(),{data:t}=Lm(),{createContactAsync:n}=xm(),{assets:r}=Bt(),{observedElementRef:i}=Jb({fallbackHeight:jJ}),[a,o]=Js(async s=>{s.preventDefault();const l=new FormData(s.currentTarget),u=Object.fromEntries(l.entries()),c=Kae.safeParse(u);c.success&&await n(c.data)});return E.jsxs("div",{ref:i,className:He(A1.widgetMinHeight,"h-fit bg-primary rounded-3xl flex flex-col"),children:[E.jsxs("div",{className:"flex-1 flex flex-col px-4 py-12 text-start space-y-4 relative z-10",children:[E.jsx("div",{className:"flex items-center justify-between w-full mb-2",children:r!=null&&r.organizationLogo?E.jsx("img",{src:r==null?void 0:r.organizationLogo,alt:"Company Logo",className:"h-8 w-auto object-contain"}):E.jsx("h2",{className:"font-bold text-xl text-primary-foreground",children:t==null?void 0:t.organization_name})}),E.jsxs("div",{className:"space-y-2",children:[E.jsx("h1",{className:"text-2xl font-bold text-primary-foreground",children:e.get("welcome-title")}),E.jsx("p",{className:"text-primary-foreground/90 text-sm max-w-[320px] leading-relaxed",children:e.get("welcome-description")})]})]}),E.jsx("div",{className:"p-2 bg-background rounded-3xl",children:E.jsxs("form",{onSubmit:o,className:"space-y-2",children:[E.jsxs("div",{className:"space-y-2",children:[E.jsx(gv,{required:!0,dir:"auto",autoFocus:!0,placeholder:e.get("your-name"),name:"name",className:"rounded-3xl pl-3"}),E.jsx(gv,{required:!0,dir:"auto",type:"email",placeholder:e.get("your-email"),name:"email",className:"rounded-3xl pl-3"})]}),E.jsxs(uo,{disabled:a.loading,className:"w-full rounded-3xl",children:[a.loading?e.get("starting-chat"):e.get("start-chat"),E.jsx(ZN,{className:"size-4"})]})]})})]})}function Qae(){const{shouldCollectDataFirst:e}=VJ();return E.jsx("div",{className:"bg-background size-full",children:E.jsx(lo,{mode:"wait",children:e?E.jsx(vr,{fadeIn:"right",className:"size-full",snapExit:!0,children:E.jsx(Xae,{})},"welcome-screen"):E.jsx(vr,{fadeIn:"right",className:"size-full",snapExit:!0,children:E.jsx(Gae,{})},"chat-screen")})})}var wv="focusScope.autoFocusOnMount",yv="focusScope.autoFocusOnUnmount",PI={bubbles:!1,cancelable:!0},Zae="FocusScope",II=y.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,l]=y.useState(null),u=Dt(i),c=Dt(a),d=y.useRef(null),f=ar(t,w=>l(w)),p=y.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;y.useEffect(()=>{if(r){let w=function(b){if(p.paused||!s)return;const T=b.target;s.contains(T)?d.current=T:Ta(d.current,{select:!0})},x=function(b){if(p.paused||!s)return;const T=b.relatedTarget;T!==null&&(s.contains(T)||Ta(d.current,{select:!0}))},m=function(b){if(document.activeElement===document.body)for(const _ of b)_.removedNodes.length>0&&Ta(s)};document.addEventListener("focusin",w),document.addEventListener("focusout",x);const v=new MutationObserver(m);return s&&v.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",w),document.removeEventListener("focusout",x),v.disconnect()}}},[r,s,p.paused]),y.useEffect(()=>{if(s){MI.add(p);const w=document.activeElement;if(!s.contains(w)){const m=new CustomEvent(wv,PI);s.addEventListener(wv,u),s.dispatchEvent(m),m.defaultPrevented||(Jae(ioe(DI(s)),{select:!0}),document.activeElement===w&&Ta(s))}return()=>{s.removeEventListener(wv,u),setTimeout(()=>{const m=new CustomEvent(yv,PI);s.addEventListener(yv,c),s.dispatchEvent(m),m.defaultPrevented||Ta(w??document.body,{select:!0}),s.removeEventListener(yv,c),MI.remove(p)},0)}}},[s,u,c,p]);const g=y.useCallback(w=>{if(!n&&!r||p.paused)return;const x=w.key==="Tab"&&!w.altKey&&!w.ctrlKey&&!w.metaKey,m=document.activeElement;if(x&&m){const v=w.currentTarget,[b,T]=eoe(v);b&&T?!w.shiftKey&&m===T?(w.preventDefault(),n&&Ta(b,{select:!0})):w.shiftKey&&m===b&&(w.preventDefault(),n&&Ta(T,{select:!0})):m===v&&w.preventDefault()}},[n,r,p.paused]);return E.jsx(rn.div,{tabIndex:-1,...o,ref:f,onKeyDown:g})});II.displayName=Zae;function Jae(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Ta(r,{select:t}),document.activeElement!==n)return}function eoe(e){const t=DI(e),n=LI(t,e),r=LI(t.reverse(),e);return[n,r]}function DI(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function LI(e,t){for(const n of e)if(!toe(n,{upTo:t}))return n}function toe(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function noe(e){return e instanceof HTMLInputElement&&"select"in e}function Ta(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&noe(e)&&t&&e.select()}}var MI=roe();function roe(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=FI(e,t),e.unshift(t)},remove(t){var n;e=FI(e,t),(n=e[0])==null||n.resume()}}}function FI(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function ioe(e){return e.filter(t=>t.tagName!=="A")}var oh="right-scroll-bar-position",sh="width-before-scroll-bar",aoe="with-scroll-bars-hidden",ooe="--removed-body-scroll-bar-size";function vv(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function soe(e,t){var n=y.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=t,n.facade}var loe=typeof window<"u"?y.useLayoutEffect:y.useEffect,BI=new WeakMap;function uoe(e,t){var n=soe(null,function(r){return e.forEach(function(i){return vv(i,r)})});return loe(function(){var r=BI.get(n);if(r){var i=new Set(r),a=new Set(e),o=n.current;i.forEach(function(s){a.has(s)||vv(s,null)}),a.forEach(function(s){i.has(s)||vv(s,o)})}BI.set(n,e)},[e]),n}var jI=UO(),bv=function(){},lh=y.forwardRef(function(e,t){var n=y.useRef(null),r=y.useState({onScrollCapture:bv,onWheelCapture:bv,onTouchMoveCapture:bv}),i=r[0],a=r[1],o=e.forwardProps,s=e.children,l=e.className,u=e.removeScrollBar,c=e.enabled,d=e.shards,f=e.sideCar,p=e.noIsolation,g=e.inert,w=e.allowPinchZoom,x=e.as,m=x===void 0?"div":x,v=e.gapMode,b=Zs(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),T=f,_=uoe([n,t]),S=St(St({},b),i);return y.createElement(y.Fragment,null,c&&y.createElement(T,{sideCar:jI,removeScrollBar:u,shards:d,noIsolation:p,inert:g,setCallbacks:a,allowPinchZoom:!!w,lockRef:n,gapMode:v}),o?y.cloneElement(y.Children.only(s),St(St({},S),{ref:_})):y.createElement(m,St({},S,{className:l,ref:_}),s))});lh.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},lh.classNames={fullWidth:sh,zeroRight:oh};var coe={left:0,top:0,right:0,gap:0},xv=function(e){return parseInt(e||"",10)||0},doe=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[xv(n),xv(r),xv(i)]},foe=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return coe;var t=doe(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},poe=$1(),Bs="data-scroll-locked",hoe=function(e,t,n,r){var i=e.left,a=e.top,o=e.right,s=e.gap;return n===void 0&&(n="margin"),`
420
+ .`.concat(aoe,` {
421
+ overflow: hidden `).concat(r,`;
422
+ padding-right: `).concat(s,"px ").concat(r,`;
423
+ }
424
+ body[`).concat(Bs,`] {
425
+ overflow: hidden `).concat(r,`;
426
+ overscroll-behavior: contain;
427
+ `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
428
+ padding-left: `.concat(i,`px;
429
+ padding-top: `).concat(a,`px;
430
+ padding-right: `).concat(o,`px;
431
+ margin-left:0;
432
+ margin-top:0;
433
+ margin-right: `).concat(s,"px ").concat(r,`;
434
+ `),n==="padding"&&"padding-right: ".concat(s,"px ").concat(r,";")].filter(Boolean).join(""),`
435
+ }
436
+
437
+ .`).concat(oh,` {
438
+ right: `).concat(s,"px ").concat(r,`;
439
+ }
440
+
441
+ .`).concat(sh,` {
442
+ margin-right: `).concat(s,"px ").concat(r,`;
443
+ }
444
+
445
+ .`).concat(oh," .").concat(oh,` {
446
+ right: 0 `).concat(r,`;
447
+ }
448
+
449
+ .`).concat(sh," .").concat(sh,` {
450
+ margin-right: 0 `).concat(r,`;
451
+ }
452
+
453
+ body[`).concat(Bs,`] {
454
+ `).concat(ooe,": ").concat(s,`px;
455
+ }
456
+ `)},zI=function(){var e=parseInt(document.body.getAttribute(Bs)||"0",10);return isFinite(e)?e:0},moe=function(){y.useEffect(function(){return document.body.setAttribute(Bs,(zI()+1).toString()),function(){var e=zI()-1;e<=0?document.body.removeAttribute(Bs):document.body.setAttribute(Bs,e.toString())}},[])},goe=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?"margin":r;moe();var a=y.useMemo(function(){return foe(i)},[i]);return y.createElement(poe,{styles:hoe(a,!t,i,n?"":"!important")})},Ev=!1;if(typeof window<"u")try{var uh=Object.defineProperty({},"passive",{get:function(){return Ev=!0,!0}});window.addEventListener("test",uh,uh),window.removeEventListener("test",uh,uh)}catch{Ev=!1}var js=Ev?{passive:!1}:!1,woe=function(e){return e.tagName==="TEXTAREA"},UI=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!woe(e)&&n[t]==="visible")},yoe=function(e){return UI(e,"overflowY")},voe=function(e){return UI(e,"overflowX")},HI=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var i=VI(e,r);if(i){var a=$I(e,r),o=a[1],s=a[2];if(o>s)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},boe=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},xoe=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},VI=function(e,t){return e==="v"?yoe(t):voe(t)},$I=function(e,t){return e==="v"?boe(t):xoe(t)},Eoe=function(e,t){return e==="h"&&t==="rtl"?-1:1},Toe=function(e,t,n,r,i){var a=Eoe(e,window.getComputedStyle(t).direction),o=a*r,s=n.target,l=t.contains(s),u=!1,c=o>0,d=0,f=0;do{var p=$I(e,s),g=p[0],w=p[1],x=p[2],m=w-x-a*g;(g||m)&&VI(e,s)&&(d+=m,f+=g),s instanceof ShadowRoot?s=s.host:s=s.parentNode}while(!l&&s!==document.body||l&&(t.contains(s)||t===s));return(c&&(Math.abs(d)<1||!i)||!c&&(Math.abs(f)<1||!i))&&(u=!0),u},ch=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},WI=function(e){return[e.deltaX,e.deltaY]},YI=function(e){return e&&"current"in e?e.current:e},_oe=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Soe=function(e){return`
457
+ .block-interactivity-`.concat(e,` {pointer-events: none;}
458
+ .allow-interactivity-`).concat(e,` {pointer-events: all;}
459
+ `)},koe=0,zs=[];function Coe(e){var t=y.useRef([]),n=y.useRef([0,0]),r=y.useRef(),i=y.useState(koe++)[0],a=y.useState($1)[0],o=y.useRef(e);y.useEffect(function(){o.current=e},[e]),y.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var w=Pc([e.lockRef.current],(e.shards||[]).map(YI),!0).filter(Boolean);return w.forEach(function(x){return x.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),w.forEach(function(x){return x.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var s=y.useCallback(function(w,x){if("touches"in w&&w.touches.length===2||w.type==="wheel"&&w.ctrlKey)return!o.current.allowPinchZoom;var m=ch(w),v=n.current,b="deltaX"in w?w.deltaX:v[0]-m[0],T="deltaY"in w?w.deltaY:v[1]-m[1],_,S=w.target,R=Math.abs(b)>Math.abs(T)?"h":"v";if("touches"in w&&R==="h"&&S.type==="range")return!1;var P=HI(R,S);if(!P)return!0;if(P?_=R:(_=R==="v"?"h":"v",P=HI(R,S)),!P)return!1;if(!r.current&&"changedTouches"in w&&(b||T)&&(r.current=_),!_)return!0;var B=r.current||_;return Toe(B,x,w,B==="h"?b:T,!0)},[]),l=y.useCallback(function(w){var x=w;if(!(!zs.length||zs[zs.length-1]!==a)){var m="deltaY"in x?WI(x):ch(x),v=t.current.filter(function(_){return _.name===x.type&&(_.target===x.target||x.target===_.shadowParent)&&_oe(_.delta,m)})[0];if(v&&v.should){x.cancelable&&x.preventDefault();return}if(!v){var b=(o.current.shards||[]).map(YI).filter(Boolean).filter(function(_){return _.contains(x.target)}),T=b.length>0?s(x,b[0]):!o.current.noIsolation;T&&x.cancelable&&x.preventDefault()}}},[]),u=y.useCallback(function(w,x,m,v){var b={name:w,delta:x,target:m,should:v,shadowParent:Aoe(m)};t.current.push(b),setTimeout(function(){t.current=t.current.filter(function(T){return T!==b})},1)},[]),c=y.useCallback(function(w){n.current=ch(w),r.current=void 0},[]),d=y.useCallback(function(w){u(w.type,WI(w),w.target,s(w,e.lockRef.current))},[]),f=y.useCallback(function(w){u(w.type,ch(w),w.target,s(w,e.lockRef.current))},[]);y.useEffect(function(){return zs.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener("wheel",l,js),document.addEventListener("touchmove",l,js),document.addEventListener("touchstart",c,js),function(){zs=zs.filter(function(w){return w!==a}),document.removeEventListener("wheel",l,js),document.removeEventListener("touchmove",l,js),document.removeEventListener("touchstart",c,js)}},[]);var p=e.removeScrollBar,g=e.inert;return y.createElement(y.Fragment,null,g?y.createElement(a,{styles:Soe(i)}):null,p?y.createElement(goe,{gapMode:e.gapMode}):null)}function Aoe(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const Roe=VO(jI,Coe);var qI=y.forwardRef(function(e,t){return y.createElement(lh,St({},e,{ref:t,sideCar:Roe}))});qI.classNames=lh.classNames;var Tv="Popover",[GI,gle]=Zr(Tv,[Nf]),mc=Nf(),[Noe,po]=GI(Tv),KI=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!1}=e,s=mc(t),l=y.useRef(null),[u,c]=y.useState(!1),[d=!1,f]=vu({prop:r,defaultProp:i,onChange:a});return E.jsx(dS,{...s,children:E.jsx(Noe,{scope:t,contentId:mu(),triggerRef:l,open:d,onOpenChange:f,onOpenToggle:y.useCallback(()=>f(p=>!p),[f]),hasCustomAnchor:u,onCustomAnchorAdd:y.useCallback(()=>c(!0),[]),onCustomAnchorRemove:y.useCallback(()=>c(!1),[]),modal:o,children:n})})};KI.displayName=Tv;var XI="PopoverAnchor",Ooe=y.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,i=po(XI,n),a=mc(n),{onCustomAnchorAdd:o,onCustomAnchorRemove:s}=i;return y.useEffect(()=>(o(),()=>s()),[o,s]),E.jsx(sw,{...a,...r,ref:t})});Ooe.displayName=XI;var QI="PopoverTrigger",ZI=y.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,i=po(QI,n),a=mc(n),o=ar(t,i.triggerRef),s=E.jsx(rn.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":n6(i.open),...r,ref:o,onClick:Jt(e.onClick,i.onOpenToggle)});return i.hasCustomAnchor?s:E.jsx(sw,{asChild:!0,...a,children:s})});ZI.displayName=QI;var Poe="PopoverPortal",[wle,Ioe]=GI(Poe,{forceMount:void 0}),Us="PopoverContent",JI=y.forwardRef((e,t)=>{const n=Ioe(Us,e.__scopePopover),{forceMount:r=n.forceMount,...i}=e,a=po(Us,e.__scopePopover);return E.jsx(lw,{present:r||a.open,children:a.modal?E.jsx(Doe,{...i,ref:t}):E.jsx(Loe,{...i,ref:t})})});JI.displayName=Us;var Doe=y.forwardRef((e,t)=>{const n=po(Us,e.__scopePopover),r=y.useRef(null),i=ar(t,r),a=y.useRef(!1);return y.useEffect(()=>{const o=r.current;if(o)return jO(o)},[]),E.jsx(qI,{as:bf,allowPinchZoom:!0,children:E.jsx(e6,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Jt(e.onCloseAutoFocus,o=>{var s;o.preventDefault(),a.current||(s=n.triggerRef.current)==null||s.focus()}),onPointerDownOutside:Jt(e.onPointerDownOutside,o=>{const s=o.detail.originalEvent,l=s.button===0&&s.ctrlKey===!0,u=s.button===2||l;a.current=u},{checkForDefaultPrevented:!1}),onFocusOutside:Jt(e.onFocusOutside,o=>o.preventDefault(),{checkForDefaultPrevented:!1})})})}),Loe=y.forwardRef((e,t)=>{const n=po(Us,e.__scopePopover),r=y.useRef(!1),i=y.useRef(!1);return E.jsx(e6,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var o,s;(o=e.onCloseAutoFocus)==null||o.call(e,a),a.defaultPrevented||(r.current||(s=n.triggerRef.current)==null||s.focus(),a.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:a=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const o=a.target;((u=n.triggerRef.current)==null?void 0:u.contains(o))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&i.current&&a.preventDefault()}})}),e6=y.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:o,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:u,onInteractOutside:c,...d}=e,f=po(Us,n),p=mc(n);return pO(),E.jsx(II,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:E.jsx(W0,{asChild:!0,disableOutsidePointerEvents:o,onInteractOutside:c,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:u,onDismiss:()=>f.onOpenChange(!1),children:E.jsx(fS,{"data-state":n6(f.open),role:"dialog",id:f.contentId,...p,...d,ref:t,style:{...d.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),t6="PopoverClose",Moe=y.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,i=po(t6,n);return E.jsx(rn.button,{type:"button",...r,ref:t,onClick:Jt(e.onClick,()=>i.onOpenChange(!1))})});Moe.displayName=t6;var Foe="PopoverArrow",Boe=y.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,i=mc(n);return E.jsx(pS,{...i,...r,ref:t})});Boe.displayName=Foe;function n6(e){return e?"open":"closed"}var joe=KI,zoe=JI;function _v(){return _v=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_v.apply(null,arguments)}function Uoe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.includes(r))continue;n[r]=e[r]}return n}var r6,i6;typeof document<"u"&&(r6=document),typeof window<"u"&&(i6=window);var Hoe=_t.createContext({document:r6,window:i6}),Voe=["children","head","initialContent","src","mountTarget"],a6=y.forwardRef((e,t)=>{var{children:n,head:r,initialContent:i,src:a,mountTarget:o}=e,s=Uoe(e,Voe),[l,u]=y.useState(!1),[c,d]=y.useState(),f=T=>{T&&d(T)};y.useImperativeHandle(t,()=>c,[c]);var p=i||"<!DOCTYPE html><html><head></head><body></body></html>",g=()=>c?c.contentDocument:null,w=()=>{var T=g();return o?T==null?void 0:T.querySelector(o):T==null?void 0:T.body},x=y.useRef(),m=y.useCallback(T=>{x.current=T;var _=()=>setInterval(()=>m(T),500);clearInterval(_()),l||u(!0)},[l]);y.useMemo(()=>{!a&&s.onLoad&&l&&s.onLoad(x.current)},[l]),y.useEffect(()=>{if(c&&!a){var T;(T=c.contentWindow)==null||T.addEventListener("DOMContentLoaded",m)}return()=>{if(c&&!a){var _;(_=c.contentWindow)==null||_.removeEventListener("DOMContentLoaded",m)}}},[c,m]);var v=()=>{var T,_=g(),S=(T=g())==null?void 0:T.head,R=w(),P=(_==null?void 0:_.defaultView)||(_==null?void 0:_.parentView),B=E.jsx(Hoe.Provider,{value:{document:_,window:P},children:n});return[S&&r&&is.createPortal(r,S),c&&R&&is.createPortal(B,R)]},b={};return a?(delete b.srcDoc,b.src=a,b.onLoad=s.onLoad):b.srcDoc=p,E.jsx("iframe",_v({title:s.title,ref:f},s,{onLoad:m},b,{children:l&&v()}))});a6.displayName="IFrame";const o6='@import"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..700;1,14..32,100..700&display=swap";[data-chat-widget] *,[data-chat-widget] :before,[data-chat-widget] :after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }[data-chat-widget] ::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }[data-chat-widget] *,[data-chat-widget] :before,[data-chat-widget] :after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}[data-chat-widget] :before,[data-chat-widget] :after{--tw-content: ""}[data-chat-widget] html,[data-chat-widget] :host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}[data-chat-widget] body{margin:0;line-height:inherit}[data-chat-widget] hr{height:0;color:inherit;border-top-width:1px}[data-chat-widget] abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}[data-chat-widget] h1,[data-chat-widget] h2,[data-chat-widget] h3,[data-chat-widget] h4,[data-chat-widget] h5,[data-chat-widget] h6{font-size:inherit;font-weight:inherit}[data-chat-widget] a{color:inherit;text-decoration:inherit}[data-chat-widget] b,[data-chat-widget] strong{font-weight:bolder}[data-chat-widget] code,[data-chat-widget] kbd,[data-chat-widget] samp,[data-chat-widget] pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}[data-chat-widget] small{font-size:80%}[data-chat-widget] sub,[data-chat-widget] sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}[data-chat-widget] sub{bottom:-.25em}[data-chat-widget] sup{top:-.5em}[data-chat-widget] table{text-indent:0;border-color:inherit;border-collapse:collapse}[data-chat-widget] button,[data-chat-widget] input,[data-chat-widget] optgroup,[data-chat-widget] select,[data-chat-widget] textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}[data-chat-widget] button,[data-chat-widget] select{text-transform:none}[data-chat-widget] button,[data-chat-widget] input:where([type=button]),[data-chat-widget] input:where([type=reset]),[data-chat-widget] input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}[data-chat-widget] :-moz-focusring{outline:auto}[data-chat-widget] :-moz-ui-invalid{box-shadow:none}[data-chat-widget] progress{vertical-align:baseline}[data-chat-widget] ::-webkit-inner-spin-button,[data-chat-widget] ::-webkit-outer-spin-button{height:auto}[data-chat-widget] [type=search]{-webkit-appearance:textfield;outline-offset:-2px}[data-chat-widget] ::-webkit-search-decoration{-webkit-appearance:none}[data-chat-widget] ::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}[data-chat-widget] summary{display:list-item}[data-chat-widget] blockquote,[data-chat-widget] dl,[data-chat-widget] dd,[data-chat-widget] h1,[data-chat-widget] h2,[data-chat-widget] h3,[data-chat-widget] h4,[data-chat-widget] h5,[data-chat-widget] h6,[data-chat-widget] hr,[data-chat-widget] figure,[data-chat-widget] p,[data-chat-widget] pre{margin:0}[data-chat-widget] fieldset{margin:0;padding:0}[data-chat-widget] legend{padding:0}[data-chat-widget] ol,[data-chat-widget] ul,[data-chat-widget] menu{list-style:none;margin:0;padding:0}[data-chat-widget] dialog{padding:0}[data-chat-widget] textarea{resize:vertical}[data-chat-widget] input::-moz-placeholder,[data-chat-widget] textarea::-moz-placeholder{opacity:1;color:#9ca3af}[data-chat-widget] input::placeholder,[data-chat-widget] textarea::placeholder{opacity:1;color:#9ca3af}[data-chat-widget] button,[data-chat-widget] [role=button]{cursor:pointer}[data-chat-widget] :disabled{cursor:default}[data-chat-widget] img,[data-chat-widget] svg,[data-chat-widget] video,[data-chat-widget] canvas,[data-chat-widget] audio,[data-chat-widget] iframe,[data-chat-widget] embed,[data-chat-widget] object{display:block;vertical-align:middle}[data-chat-widget] img,[data-chat-widget] video{max-width:100%;height:auto}[data-chat-widget] [hidden]:where(:not([hidden=until-found])){display:none}[data-chat-widget] *{-ms-overflow-style:none;scrollbar-width:none}[data-chat-widget] *::-webkit-scrollbar{display:none}[data-chat-widget] *{border-color:hsl(var(--opencx-border))}[data-chat-widget] .container{width:100%}@media (min-width: 640px){[data-chat-widget] .container{max-width:640px}}@media (min-width: 768px){[data-chat-widget] .container{max-width:768px}}@media (min-width: 1024px){[data-chat-widget] .container{max-width:1024px}}@media (min-width: 1280px){[data-chat-widget] .container{max-width:1280px}}@media (min-width: 1536px){[data-chat-widget] .container{max-width:1536px}}[data-chat-widget] .prose{color:var(--tw-prose-body);max-width:65ch}[data-chat-widget] .prose :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}[data-chat-widget] .prose :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-lead);font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}[data-chat-widget] .prose :where(a):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-links);text-decoration:underline;font-weight:500}[data-chat-widget] .prose :where(strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-bold);font-weight:600}[data-chat-widget] .prose :where(a strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(blockquote strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(thead th strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}[data-chat-widget] .prose :where(ol[type=A]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}[data-chat-widget] .prose :where(ol[type=a]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}[data-chat-widget] .prose :where(ol[type=A s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}[data-chat-widget] .prose :where(ol[type=a s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}[data-chat-widget] .prose :where(ol[type=I]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}[data-chat-widget] .prose :where(ol[type=i]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}[data-chat-widget] .prose :where(ol[type=I s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}[data-chat-widget] .prose :where(ol[type=i s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}[data-chat-widget] .prose :where(ol[type="1"]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal}[data-chat-widget] .prose :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:disc;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}[data-chat-widget] .prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{font-weight:400;color:var(--tw-prose-counters)}[data-chat-widget] .prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{color:var(--tw-prose-bullets)}[data-chat-widget] .prose :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.25em}[data-chat-widget] .prose :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){border-color:var(--tw-prose-hr);border-top-width:1px;margin-top:3em;margin-bottom:3em}[data-chat-widget] .prose :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-style:italic;color:var(--tw-prose-quotes);border-inline-start-width:.25rem;border-inline-start-color:var(--tw-prose-quote-borders);quotes:"“""”""‘""’";margin-top:1.6em;margin-bottom:1.6em;padding-inline-start:1em}[data-chat-widget] .prose :where(blockquote p:first-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:open-quote}[data-chat-widget] .prose :where(blockquote p:last-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:close-quote}[data-chat-widget] .prose :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}[data-chat-widget] .prose :where(h1 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:900;color:inherit}[data-chat-widget] .prose :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}[data-chat-widget] .prose :where(h2 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:800;color:inherit}[data-chat-widget] .prose :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}[data-chat-widget] .prose :where(h3 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}[data-chat-widget] .prose :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}[data-chat-widget] .prose :where(h4 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}[data-chat-widget] .prose :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}[data-chat-widget] .prose :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){display:block;margin-top:2em;margin-bottom:2em}[data-chat-widget] .prose :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}[data-chat-widget] .prose :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-family:inherit;color:var(--tw-prose-kbd);box-shadow:0 0 0 1px rgb(var(--tw-prose-kbd-shadows) / 10%),0 3px rgb(var(--tw-prose-kbd-shadows) / 10%);font-size:.875em;border-radius:.3125rem;padding-top:.1875em;padding-inline-end:.375em;padding-bottom:.1875em;padding-inline-start:.375em}[data-chat-widget] .prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-code);font-weight:600;font-size:.875em}[data-chat-widget] .prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:"`"}[data-chat-widget] .prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:"`"}[data-chat-widget] .prose :where(a code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(h1 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.875em}[data-chat-widget] .prose :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.9em}[data-chat-widget] .prose :where(h4 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(blockquote code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(thead th code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}[data-chat-widget] .prose :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-pre-code);background-color:var(--tw-prose-pre-bg);overflow-x:auto;font-weight:400;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding-top:.8571429em;padding-inline-end:1.1428571em;padding-bottom:.8571429em;padding-inline-start:1.1428571em}[data-chat-widget] .prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)){background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:inherit;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}[data-chat-widget] .prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:none}[data-chat-widget] .prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:none}[data-chat-widget] .prose :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){width:100%;table-layout:auto;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}[data-chat-widget] .prose :where(thead):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-th-borders)}[data-chat-widget] .prose :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;vertical-align:bottom;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}[data-chat-widget] .prose :where(tbody tr):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-td-borders)}[data-chat-widget] .prose :where(tbody tr:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:0}[data-chat-widget] .prose :where(tbody td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:baseline}[data-chat-widget] .prose :where(tfoot):not(:where([class~=not-prose],[class~=not-prose] *)){border-top-width:1px;border-top-color:var(--tw-prose-th-borders)}[data-chat-widget] .prose :where(tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:top}[data-chat-widget] .prose :where(th,td):not(:where([class~=not-prose],[class~=not-prose] *)){text-align:start}[data-chat-widget] .prose :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}[data-chat-widget] .prose :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-captions);font-size:.875em;line-height:1.4285714;margin-top:.8571429em}[data-chat-widget] .prose{--tw-prose-body: #374151;--tw-prose-headings: #111827;--tw-prose-lead: #4b5563;--tw-prose-links: #111827;--tw-prose-bold: #111827;--tw-prose-counters: #6b7280;--tw-prose-bullets: #d1d5db;--tw-prose-hr: #e5e7eb;--tw-prose-quotes: #111827;--tw-prose-quote-borders: #e5e7eb;--tw-prose-captions: #6b7280;--tw-prose-kbd: #111827;--tw-prose-kbd-shadows: 17 24 39;--tw-prose-code: #111827;--tw-prose-pre-code: #e5e7eb;--tw-prose-pre-bg: #1f2937;--tw-prose-th-borders: #d1d5db;--tw-prose-td-borders: #e5e7eb;--tw-prose-invert-body: #d1d5db;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #9ca3af;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #9ca3af;--tw-prose-invert-bullets: #4b5563;--tw-prose-invert-hr: #374151;--tw-prose-invert-quotes: #f3f4f6;--tw-prose-invert-quote-borders: #374151;--tw-prose-invert-captions: #9ca3af;--tw-prose-invert-kbd: #fff;--tw-prose-invert-kbd-shadows: 255 255 255;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #d1d5db;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #4b5563;--tw-prose-invert-td-borders: #374151;font-size:1rem;line-height:1.75}[data-chat-widget] .prose :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}[data-chat-widget] .prose :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;margin-bottom:.5em}[data-chat-widget] .prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}[data-chat-widget] .prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}[data-chat-widget] .prose :where(.prose>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}[data-chat-widget] .prose :where(.prose>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}[data-chat-widget] .prose :where(.prose>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}[data-chat-widget] .prose :where(.prose>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}[data-chat-widget] .prose :where(.prose>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}[data-chat-widget] .prose :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}[data-chat-widget] .prose :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}[data-chat-widget] .prose :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;padding-inline-start:1.625em}[data-chat-widget] .prose :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}[data-chat-widget] .prose :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}[data-chat-widget] .prose :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.5714286em;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}[data-chat-widget] .prose :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}[data-chat-widget] .prose :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}[data-chat-widget] .prose :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}[data-chat-widget] .prose :where(.prose>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose :where(.prose>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}[data-chat-widget] .prose-sm{font-size:.875rem;line-height:1.7142857}[data-chat-widget] .prose-sm :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}[data-chat-widget] .prose-sm :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;line-height:1.5555556;margin-top:.8888889em;margin-bottom:.8888889em}[data-chat-widget] .prose-sm :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-inline-start:1.1111111em}[data-chat-widget] .prose-sm :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:2.1428571em;margin-top:0;margin-bottom:.8em;line-height:1.2}[data-chat-widget] .prose-sm :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.4285714em;margin-top:1.6em;margin-bottom:.8em;line-height:1.4}[data-chat-widget] .prose-sm :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;margin-top:1.5555556em;margin-bottom:.4444444em;line-height:1.5555556}[data-chat-widget] .prose-sm :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.4285714em;margin-bottom:.5714286em;line-height:1.4285714}[data-chat-widget] .prose-sm :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}[data-chat-widget] .prose-sm :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}[data-chat-widget] .prose-sm :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}[data-chat-widget] .prose-sm :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}[data-chat-widget] .prose-sm :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;border-radius:.3125rem;padding-top:.1428571em;padding-inline-end:.3571429em;padding-bottom:.1428571em;padding-inline-start:.3571429em}[data-chat-widget] .prose-sm :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em}[data-chat-widget] .prose-sm :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.9em}[data-chat-widget] .prose-sm :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em}[data-chat-widget] .prose-sm :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.6666667;margin-top:1.6666667em;margin-bottom:1.6666667em;border-radius:.25rem;padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}[data-chat-widget] .prose-sm :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}[data-chat-widget] .prose-sm :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}[data-chat-widget] .prose-sm :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;margin-bottom:.2857143em}[data-chat-widget] .prose-sm :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}[data-chat-widget] .prose-sm :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}[data-chat-widget] .prose-sm :where(.prose-sm>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}[data-chat-widget] .prose-sm :where(.prose-sm>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}[data-chat-widget] .prose-sm :where(.prose-sm>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}[data-chat-widget] .prose-sm :where(.prose-sm>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}[data-chat-widget] .prose-sm :where(.prose-sm>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}[data-chat-widget] .prose-sm :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}[data-chat-widget] .prose-sm :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}[data-chat-widget] .prose-sm :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}[data-chat-widget] .prose-sm :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;padding-inline-start:1.5714286em}[data-chat-widget] .prose-sm :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2.8571429em;margin-bottom:2.8571429em}[data-chat-widget] .prose-sm :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.5}[data-chat-widget] .prose-sm :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}[data-chat-widget] .prose-sm :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}[data-chat-widget] .prose-sm :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}[data-chat-widget] .prose-sm :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}[data-chat-widget] .prose-sm :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}[data-chat-widget] .prose-sm :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}[data-chat-widget] .prose-sm :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}[data-chat-widget] .prose-sm :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}[data-chat-widget] .prose-sm :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.3333333;margin-top:.6666667em}[data-chat-widget] .prose-sm :where(.prose-sm>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}[data-chat-widget] .prose-sm :where(.prose-sm>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}[data-chat-widget] .prose-slate{--tw-prose-body: #334155;--tw-prose-headings: #0f172a;--tw-prose-lead: #475569;--tw-prose-links: #0f172a;--tw-prose-bold: #0f172a;--tw-prose-counters: #64748b;--tw-prose-bullets: #cbd5e1;--tw-prose-hr: #e2e8f0;--tw-prose-quotes: #0f172a;--tw-prose-quote-borders: #e2e8f0;--tw-prose-captions: #64748b;--tw-prose-kbd: #0f172a;--tw-prose-kbd-shadows: 15 23 42;--tw-prose-code: #0f172a;--tw-prose-pre-code: #e2e8f0;--tw-prose-pre-bg: #1e293b;--tw-prose-th-borders: #cbd5e1;--tw-prose-td-borders: #e2e8f0;--tw-prose-invert-body: #cbd5e1;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #94a3b8;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #94a3b8;--tw-prose-invert-bullets: #475569;--tw-prose-invert-hr: #334155;--tw-prose-invert-quotes: #f1f5f9;--tw-prose-invert-quote-borders: #334155;--tw-prose-invert-captions: #94a3b8;--tw-prose-invert-kbd: #fff;--tw-prose-invert-kbd-shadows: 255 255 255;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #cbd5e1;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #475569;--tw-prose-invert-td-borders: #334155}[data-chat-widget] .pointer-events-none{pointer-events:none}[data-chat-widget] .visible{visibility:visible}[data-chat-widget] .fixed{position:fixed}[data-chat-widget] .absolute{position:absolute}[data-chat-widget] .relative{position:relative}[data-chat-widget] .inset-0{top:0;right:0;bottom:0;left:0}[data-chat-widget] .inset-x-0{left:0;right:0}[data-chat-widget] .bottom-0{bottom:0}[data-chat-widget] .bottom-2{bottom:.5rem}[data-chat-widget] .left-0{left:0}[data-chat-widget] .left-1\\/2{left:50%}[data-chat-widget] .left-2{left:.5rem}[data-chat-widget] .right-0{right:0}[data-chat-widget] .top-1\\/2{top:50%}[data-chat-widget] .isolate{isolation:isolate}[data-chat-widget] .z-0{z-index:0}[data-chat-widget] .z-10{z-index:10}[data-chat-widget] .z-50{z-index:50}[data-chat-widget] .z-\\[24\\]{z-index:24}[data-chat-widget] .z-\\[25\\]{z-index:25}[data-chat-widget] .-mx-1{margin-left:-.25rem;margin-right:-.25rem}[data-chat-widget] .my-1{margin-top:.25rem;margin-bottom:.25rem}[data-chat-widget] .my-2{margin-top:.5rem;margin-bottom:.5rem}[data-chat-widget] .mb-1{margin-bottom:.25rem}[data-chat-widget] .mb-2{margin-bottom:.5rem}[data-chat-widget] .ml-auto{margin-left:auto}[data-chat-widget] .mt-1{margin-top:.25rem}[data-chat-widget] .mt-2{margin-top:.5rem}[data-chat-widget] .line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}[data-chat-widget] .block{display:block}[data-chat-widget] .inline{display:inline}[data-chat-widget] .flex{display:flex}[data-chat-widget] .inline-flex{display:inline-flex}[data-chat-widget] .grid{display:grid}[data-chat-widget] .contents{display:contents}[data-chat-widget] .hidden{display:none}[data-chat-widget] .aspect-square{aspect-ratio:1 / 1}[data-chat-widget] .size-12{width:3rem;height:3rem}[data-chat-widget] .size-16{width:4rem;height:4rem}[data-chat-widget] .size-3{width:.75rem;height:.75rem}[data-chat-widget] .size-4{width:1rem;height:1rem}[data-chat-widget] .size-5{width:1.25rem;height:1.25rem}[data-chat-widget] .size-6{width:1.5rem;height:1.5rem}[data-chat-widget] .size-7{width:1.75rem;height:1.75rem}[data-chat-widget] .size-8{width:2rem;height:2rem}[data-chat-widget] .size-fit{width:-moz-fit-content;width:fit-content;height:-moz-fit-content;height:fit-content}[data-chat-widget] .size-full{width:100%;height:100%}[data-chat-widget] .h-10{height:2.5rem}[data-chat-widget] .h-11{height:2.75rem}[data-chat-widget] .h-2{height:.5rem}[data-chat-widget] .h-3\\.5{height:.875rem}[data-chat-widget] .h-4{height:1rem}[data-chat-widget] .h-5{height:1.25rem}[data-chat-widget] .h-8{height:2rem}[data-chat-widget] .h-\\[600px\\]{height:600px}[data-chat-widget] .h-fit{height:-moz-fit-content;height:fit-content}[data-chat-widget] .h-full{height:100%}[data-chat-widget] .h-px{height:1px}[data-chat-widget] .max-h-\\[600px\\]{max-height:600px}[data-chat-widget] .max-h-full{max-height:100%}[data-chat-widget] .min-h-\\[400px\\]{min-height:400px}[data-chat-widget] .w-10{width:2.5rem}[data-chat-widget] .w-2{width:.5rem}[data-chat-widget] .w-2\\/3{width:66.666667%}[data-chat-widget] .w-3\\.5{width:.875rem}[data-chat-widget] .w-4{width:1rem}[data-chat-widget] .w-60{width:15rem}[data-chat-widget] .w-9{width:2.25rem}[data-chat-widget] .w-auto{width:auto}[data-chat-widget] .w-fit{width:-moz-fit-content;width:fit-content}[data-chat-widget] .w-full{width:100%}[data-chat-widget] .min-w-56{min-width:14rem}[data-chat-widget] .min-w-\\[80\\%\\]{min-width:80%}[data-chat-widget] .min-w-\\[8rem\\]{min-width:8rem}[data-chat-widget] .min-w-fit{min-width:-moz-fit-content;min-width:fit-content}[data-chat-widget] .max-w-\\[320px\\]{max-width:320px}[data-chat-widget] .max-w-\\[85\\%\\]{max-width:85%}[data-chat-widget] .max-w-\\[90\\%\\]{max-width:90%}[data-chat-widget] .max-w-full{max-width:100%}[data-chat-widget] .max-w-xs{max-width:20rem}[data-chat-widget] .flex-1{flex:1 1 0%}[data-chat-widget] .shrink-0{flex-shrink:0}[data-chat-widget] .origin-bottom{transform-origin:bottom}[data-chat-widget] .-translate-x-1\\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .-translate-y-1\\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .translate-x-\\[var\\(--opencx-wobble-x\\)\\]{--tw-translate-x: var(--opencx-wobble-x);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .translate-y-\\[var\\(--opencx-wobble-y\\)\\]{--tw-translate-y: var(--opencx-wobble-y);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .scale-\\[1\\.01\\]{--tw-scale-x: 1.01;--tw-scale-y: 1.01;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .scale-\\[1\\.02\\]{--tw-scale-x: 1.02;--tw-scale-y: 1.02;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .scale-\\[1\\.1\\]{--tw-scale-x: 1.1;--tw-scale-y: 1.1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .scale-\\[1\\]{--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes bounce{0%,to{transform:translateY(-25%);animation-timing-function:cubic-bezier(.8,0,1,1)}50%{transform:none;animation-timing-function:cubic-bezier(0,0,.2,1)}}[data-chat-widget] .animate-bounce{animation:bounce 1s infinite}@keyframes pulse{50%{opacity:.5}}[data-chat-widget] .animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}[data-chat-widget] .animate-spin{animation:spin 1s linear infinite}[data-chat-widget] .cursor-default{cursor:default}[data-chat-widget] .cursor-pointer{cursor:pointer}[data-chat-widget] .select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}[data-chat-widget] .resize-none{resize:none}[data-chat-widget] .grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}[data-chat-widget] .flex-row{flex-direction:row}[data-chat-widget] .flex-col{flex-direction:column}[data-chat-widget] .flex-wrap{flex-wrap:wrap}[data-chat-widget] .items-start{align-items:flex-start}[data-chat-widget] .items-end{align-items:flex-end}[data-chat-widget] .items-center{align-items:center}[data-chat-widget] .justify-start{justify-content:flex-start}[data-chat-widget] .justify-end{justify-content:flex-end}[data-chat-widget] .justify-center{justify-content:center}[data-chat-widget] .justify-between{justify-content:space-between}[data-chat-widget] .gap-0\\.5{gap:.125rem}[data-chat-widget] .gap-1{gap:.25rem}[data-chat-widget] .gap-2{gap:.5rem}[data-chat-widget] .space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}[data-chat-widget] .space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}[data-chat-widget] .space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}[data-chat-widget] .space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}[data-chat-widget] .overflow-auto{overflow:auto}[data-chat-widget] .overflow-hidden{overflow:hidden}[data-chat-widget] .scroll-smooth{scroll-behavior:smooth}[data-chat-widget] .whitespace-nowrap{white-space:nowrap}[data-chat-widget] .rounded-2xl{border-radius:1rem}[data-chat-widget] .rounded-3xl{border-radius:1.5rem}[data-chat-widget] .rounded-full{border-radius:9999px}[data-chat-widget] .rounded-lg{border-radius:.5rem}[data-chat-widget] .rounded-md{border-radius:.375rem}[data-chat-widget] .rounded-sm{border-radius:.125rem}[data-chat-widget] .rounded-xl{border-radius:.75rem}[data-chat-widget] .rounded-bl-none{border-bottom-left-radius:0}[data-chat-widget] .border{border-width:1px}[data-chat-widget] .border-0{border-width:0px}[data-chat-widget] .border-2{border-width:2px}[data-chat-widget] .border-b{border-bottom-width:1px}[data-chat-widget] .border-destructive{border-color:hsl(var(--opencx-destructive))}[data-chat-widget] .border-input{border-color:hsl(var(--opencx-input))}[data-chat-widget] .border-primary{border-color:hsl(var(--opencx-primary))}[data-chat-widget] .border-transparent{border-color:transparent}[data-chat-widget] .bg-background{background-color:hsl(var(--opencx-background))}[data-chat-widget] .bg-black{--tw-bg-opacity: 1;background-color:rgb(0 0 0 / var(--tw-bg-opacity))}[data-chat-widget] .bg-black\\/50{background-color:#00000080}[data-chat-widget] .bg-destructive{background-color:hsl(var(--opencx-destructive))}[data-chat-widget] .bg-muted{background-color:hsl(var(--opencx-muted))}[data-chat-widget] .bg-primary{background-color:hsl(var(--opencx-primary))}[data-chat-widget] .bg-secondary{background-color:hsl(var(--opencx-secondary))}[data-chat-widget] .bg-transparent{background-color:transparent}[data-chat-widget] .bg-zinc-100{--tw-bg-opacity: 1;background-color:rgb(244 244 245 / var(--tw-bg-opacity))}[data-chat-widget] .bg-gradient-to-t{background-image:linear-gradient(to top,var(--tw-gradient-stops))}[data-chat-widget] .from-gray-100\\/30{--tw-gradient-from: rgb(243 244 246 / .3) var(--tw-gradient-from-position);--tw-gradient-to: rgb(243 244 246 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}[data-chat-widget] .from-primary\\/50{--tw-gradient-from: hsl(var(--opencx-primary) / .5) var(--tw-gradient-from-position);--tw-gradient-to: hsl(var(--opencx-primary) / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}[data-chat-widget] .via-primary{--tw-gradient-to: hsl(var(--opencx-primary) / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), hsl(var(--opencx-primary)) var(--tw-gradient-via-position), var(--tw-gradient-to)}[data-chat-widget] .to-gray-50\\/30{--tw-gradient-to: rgb(249 250 251 / .3) var(--tw-gradient-to-position)}[data-chat-widget] .to-primary{--tw-gradient-to: hsl(var(--opencx-primary)) var(--tw-gradient-to-position)}[data-chat-widget] .fill-current{fill:currentColor}[data-chat-widget] .object-contain{-o-object-fit:contain;object-fit:contain}[data-chat-widget] .object-cover{-o-object-fit:cover;object-fit:cover}[data-chat-widget] .p-0{padding:0}[data-chat-widget] .p-1{padding:.25rem}[data-chat-widget] .p-2{padding:.5rem}[data-chat-widget] .p-2\\.5{padding:.625rem}[data-chat-widget] .p-3{padding:.75rem}[data-chat-widget] .p-4{padding:1rem}[data-chat-widget] .px-2{padding-left:.5rem;padding-right:.5rem}[data-chat-widget] .px-3{padding-left:.75rem;padding-right:.75rem}[data-chat-widget] .px-4{padding-left:1rem;padding-right:1rem}[data-chat-widget] .px-8{padding-left:2rem;padding-right:2rem}[data-chat-widget] .py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}[data-chat-widget] .py-12{padding-top:3rem;padding-bottom:3rem}[data-chat-widget] .py-2{padding-top:.5rem;padding-bottom:.5rem}[data-chat-widget] .py-3{padding-top:.75rem;padding-bottom:.75rem}[data-chat-widget] .py-4{padding-top:1rem;padding-bottom:1rem}[data-chat-widget] .pl-2{padding-left:.5rem}[data-chat-widget] .pl-3{padding-left:.75rem}[data-chat-widget] .pl-8{padding-left:2rem}[data-chat-widget] .pr-2{padding-right:.5rem}[data-chat-widget] .text-center{text-align:center}[data-chat-widget] .text-start{text-align:start}[data-chat-widget] .align-middle{vertical-align:middle}[data-chat-widget] .font-inter{font-family:Inter,sans-serif}[data-chat-widget] .text-2xl{font-size:1.5rem;line-height:2rem}[data-chat-widget] .text-\\[10px\\]{font-size:10px}[data-chat-widget] .text-base{font-size:1rem;line-height:1.5rem}[data-chat-widget] .text-sm{font-size:.875rem;line-height:1.25rem}[data-chat-widget] .text-xl{font-size:1.25rem;line-height:1.75rem}[data-chat-widget] .text-xs{font-size:.75rem;line-height:1rem}[data-chat-widget] .font-bold{font-weight:700}[data-chat-widget] .font-medium{font-weight:500}[data-chat-widget] .font-semibold{font-weight:600}[data-chat-widget] .leading-relaxed{line-height:1.625}[data-chat-widget] .leading-snug{line-height:1.375}[data-chat-widget] .leading-tight{line-height:1.25}[data-chat-widget] .tracking-widest{letter-spacing:.1em}[data-chat-widget] .text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity))}[data-chat-widget] .text-destructive{color:hsl(var(--opencx-destructive))}[data-chat-widget] .text-destructive-foreground{color:hsl(var(--opencx-destructive-foreground))}[data-chat-widget] .text-emerald-500{--tw-text-opacity: 1;color:rgb(16 185 129 / var(--tw-text-opacity))}[data-chat-widget] .text-foreground{color:hsl(var(--opencx-foreground))}[data-chat-widget] .text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity))}[data-chat-widget] .text-primary{color:hsl(var(--opencx-primary))}[data-chat-widget] .text-primary-foreground{color:hsl(var(--opencx-primary-foreground))}[data-chat-widget] .text-primary-foreground\\/90{color:hsl(var(--opencx-primary-foreground) / .9)}[data-chat-widget] .text-secondary-foreground{color:hsl(var(--opencx-secondary-foreground))}[data-chat-widget] .text-zinc-500{--tw-text-opacity: 1;color:rgb(113 113 122 / var(--tw-text-opacity))}[data-chat-widget] .text-zinc-600{--tw-text-opacity: 1;color:rgb(82 82 91 / var(--tw-text-opacity))}[data-chat-widget] .underline{text-decoration-line:underline}[data-chat-widget] .underline-offset-4{text-underline-offset:4px}[data-chat-widget] .antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}[data-chat-widget] .opacity-0{opacity:0}[data-chat-widget] .opacity-50{opacity:.5}[data-chat-widget] .opacity-60{opacity:.6}[data-chat-widget] .shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-2xl{--tw-shadow: 0 25px 50px -12px rgb(0 0 0 / .25);--tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .outline-none{outline:2px solid transparent;outline-offset:2px}[data-chat-widget] .outline{outline-style:solid}[data-chat-widget] .ring-0{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}[data-chat-widget] .ring-2{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}[data-chat-widget] .ring-white{--tw-ring-opacity: 1;--tw-ring-color: rgb(255 255 255 / var(--tw-ring-opacity))}[data-chat-widget] .ring-offset-background{--tw-ring-offset-color: hsl(var(--opencx-background))}[data-chat-widget] .backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}[data-chat-widget] .transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}[data-chat-widget] .duration-200{transition-duration:.2s}[data-chat-widget] .ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity, 1);transform:translate3d(var(--tw-enter-translate-x, 0),var(--tw-enter-translate-y, 0),0) scale3d(var(--tw-enter-scale, 1),var(--tw-enter-scale, 1),var(--tw-enter-scale, 1)) rotate(var(--tw-enter-rotate, 0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity, 1);transform:translate3d(var(--tw-exit-translate-x, 0),var(--tw-exit-translate-y, 0),0) scale3d(var(--tw-exit-scale, 1),var(--tw-exit-scale, 1),var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0))}}[data-chat-widget] .animate-in{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}[data-chat-widget] .fade-in-0{--tw-enter-opacity: 0}[data-chat-widget] .zoom-in-95{--tw-enter-scale: .95}[data-chat-widget] .duration-200{animation-duration:.2s}[data-chat-widget] .ease-out{animation-timing-function:cubic-bezier(0,0,.2,1)}[data-chat-widget] .\\[animation-delay\\:-0\\.15s\\]{animation-delay:-.15s}[data-chat-widget] .\\[animation-delay\\:-0\\.3s\\]{animation-delay:-.3s}[data-chat-widget] .\\[background\\:radial-gradient\\(68\\.75\\%_68\\.75\\%_at_50\\%_100\\%\\,_\\#717171_0\\%\\,_\\#000000_100\\%\\)\\]{background:radial-gradient(68.75% 68.75% at 50% 100%,#717171,#000)}[data-chat-widget] .required:after{content:" *";color:red}[data-chat-widget] .file\\:border-0::file-selector-button{border-width:0px}[data-chat-widget] .file\\:bg-transparent::file-selector-button{background-color:transparent}[data-chat-widget] .file\\:text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}[data-chat-widget] .file\\:font-medium::file-selector-button{font-weight:500}[data-chat-widget] .file\\:text-primary-foreground::file-selector-button{color:hsl(var(--opencx-primary-foreground))}[data-chat-widget] .placeholder\\:text-muted-foreground::-moz-placeholder{color:hsl(var(--opencx-muted-foreground))}[data-chat-widget] .placeholder\\:text-muted-foreground::placeholder{color:hsl(var(--opencx-muted-foreground))}[data-chat-widget] .hover\\:bg-accent:hover{background-color:hsl(var(--opencx-accent))}[data-chat-widget] .hover\\:text-accent-foreground:hover{color:hsl(var(--opencx-accent-foreground))}[data-chat-widget] .hover\\:text-blue-600:hover{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity))}[data-chat-widget] .hover\\:underline:hover{text-decoration-line:underline}[data-chat-widget] .hover\\:brightness-110:hover{--tw-brightness: brightness(1.1);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}[data-chat-widget] .focus\\:bg-accent:focus{background-color:hsl(var(--opencx-accent))}[data-chat-widget] .focus\\:text-accent-foreground:focus{color:hsl(var(--opencx-accent-foreground))}[data-chat-widget] .focus-visible\\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}[data-chat-widget] .focus-visible\\:ring-2:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}[data-chat-widget] .focus-visible\\:ring-ring:focus-visible{--tw-ring-color: hsl(var(--opencx-ring))}[data-chat-widget] .focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width: 2px}[data-chat-widget] .focus-visible\\:ring-offset-background:focus-visible{--tw-ring-offset-color: hsl(var(--opencx-background))}[data-chat-widget] .active\\:scale-90:active{--tw-scale-x: .9;--tw-scale-y: .9;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .active\\:scale-95:active{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .active\\:shadow-none:active{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}[data-chat-widget] .hover\\:active\\:scale-95:active:hover{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .disabled\\:pointer-events-none:disabled{pointer-events:none}[data-chat-widget] .disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}[data-chat-widget] .disabled\\:opacity-0:disabled{opacity:0}[data-chat-widget] .disabled\\:opacity-50:disabled{opacity:.5}[data-chat-widget] .group:hover .group-hover\\:opacity-100{opacity:1}[data-chat-widget] .group:hover .group-hover\\:active\\:scale-90:active,[data-chat-widget] .group:active .group-active\\:scale-90{--tw-scale-x: .9;--tw-scale-y: .9;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .data-\\[disabled\\]\\:pointer-events-none[data-disabled]{pointer-events:none}[data-chat-widget] .data-\\[state\\=checked\\]\\:translate-x-4[data-state=checked]{--tw-translate-x: 1rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .data-\\[state\\=unchecked\\]\\:translate-x-0[data-state=unchecked]{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .data-\\[state\\=checked\\]\\:bg-primary[data-state=checked]{background-color:hsl(var(--opencx-primary))}[data-chat-widget] .data-\\[state\\=open\\]\\:bg-accent[data-state=open]{background-color:hsl(var(--opencx-accent))}[data-chat-widget] .data-\\[state\\=unchecked\\]\\:bg-input[data-state=unchecked]{background-color:hsl(var(--opencx-input))}[data-chat-widget] .data-\\[disabled\\]\\:opacity-50[data-disabled]{opacity:.5}[data-chat-widget] .data-\\[state\\=open\\]\\:animate-in[data-state=open]{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}[data-chat-widget] .data-\\[state\\=closed\\]\\:animate-out[data-state=closed]{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}[data-chat-widget] .data-\\[state\\=closed\\]\\:fade-out-0[data-state=closed]{--tw-exit-opacity: 0}[data-chat-widget] .data-\\[state\\=open\\]\\:fade-in-0[data-state=open]{--tw-enter-opacity: 0}[data-chat-widget] .data-\\[state\\=closed\\]\\:zoom-out-95[data-state=closed]{--tw-exit-scale: .95}[data-chat-widget] .data-\\[state\\=open\\]\\:zoom-in-95[data-state=open]{--tw-enter-scale: .95}[data-chat-widget] .data-\\[side\\=bottom\\]\\:slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y: -.5rem}[data-chat-widget] .data-\\[side\\=left\\]\\:slide-in-from-right-2[data-side=left]{--tw-enter-translate-x: .5rem}[data-chat-widget] .data-\\[side\\=right\\]\\:slide-in-from-left-2[data-side=right]{--tw-enter-translate-x: -.5rem}[data-chat-widget] .data-\\[side\\=top\\]\\:slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y: .5rem}[data-chat-widget] .prose-a\\:underline :is(:where(a):not(:where([class~=not-prose],[class~=not-prose] *))){text-decoration-line:underline}[data-chat-widget] .prose-a\\:decoration-primary :is(:where(a):not(:where([class~=not-prose],[class~=not-prose] *))){text-decoration-color:hsl(var(--opencx-primary))}[data-chat-widget] .rtl\\:-scale-100:where([dir=rtl],[dir=rtl] *){--tw-scale-x: -1;--tw-scale-y: -1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}[data-chat-widget] .\\[\\&_span\\]\\:size-1 span{width:.25rem;height:.25rem}[data-chat-widget] .\\[\\&_span\\]\\:bg-secondary-foreground span{background-color:hsl(var(--opencx-secondary-foreground))}[data-chat-widget] .\\[\\&_svg\\]\\:pointer-events-none svg{pointer-events:none}[data-chat-widget] .\\[\\&_svg\\]\\:size-4 svg{width:1rem;height:1rem}[data-chat-widget] .\\[\\&_svg\\]\\:size-6 svg{width:1.5rem;height:1.5rem}[data-chat-widget] .\\[\\&_svg\\]\\:shrink-0 svg{flex-shrink:0}';function $oe({className:e}){return E.jsx("svg",{width:"26",height:"32",viewBox:"0 0 26 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:He("text-primary-foreground",e),children:E.jsx("path",{d:"M1.34103 25.6132H5.44245C5.74203 25.6228 6.02673 25.7462 6.23867 25.9582C6.45062 26.1703 6.5739 26.4551 6.58348 26.7548V30.8584C6.59305 31.1581 6.71634 31.443 6.92828 31.655C7.14023 31.8671 7.42492 31.9904 7.7245 32H18.2894C18.589 31.9904 18.8737 31.8671 19.0856 31.655C19.2976 31.443 19.4209 31.1581 19.4304 30.8584V26.7548C19.4401 26.4545 19.5638 26.1692 19.7765 25.957C19.9892 25.7449 20.2748 25.6219 20.5749 25.6132H24.659C24.9586 25.6036 25.2433 25.4803 25.4552 25.2682C25.6671 25.0562 25.7904 24.7713 25.8 24.4716V7.52839C25.7904 7.22865 25.6671 6.94381 25.4552 6.73176C25.2433 6.5197 24.9586 6.39635 24.659 6.38677H20.561C20.2603 6.37802 19.9742 6.25457 19.7614 6.04169C19.5487 5.82881 19.4253 5.54261 19.4165 5.24168V1.14161C19.4072 0.84419 19.2858 0.561291 19.0768 0.349589C18.8678 0.137887 18.5865 0.0130193 18.2894 0L7.7245 0C7.42492 0.00957792 7.14023 0.132929 6.92828 0.344983C6.71634 0.557036 6.59305 0.841878 6.58348 1.14161V5.24168C6.57477 5.54203 6.45187 5.82773 6.23983 6.04052C6.0278 6.25331 5.74262 6.37715 5.44245 6.38677H1.34103C1.04144 6.39635 0.756749 6.5197 0.544805 6.73176C0.332861 6.94381 0.209574 7.22865 0.200001 7.52839V24.4716C0.209574 24.7713 0.332861 25.0562 0.544805 25.2682C0.756749 25.4803 1.04144 25.6036 1.34103 25.6132ZM6.58348 24.4716V7.52839C6.59305 7.22865 6.71634 6.94381 6.92828 6.73176C7.14023 6.5197 7.42492 6.39635 7.7245 6.38677H18.2894C18.589 6.39635 18.8737 6.5197 19.0856 6.73176C19.2976 6.94381 19.4209 7.22865 19.4304 7.52839V24.4716C19.4209 24.7713 19.2976 25.0562 19.0856 25.2682C18.8737 25.4803 18.589 25.6036 18.2894 25.6132H7.7245C7.42492 25.6036 7.14023 25.4803 6.92828 25.2682C6.71634 25.0562 6.59305 24.7713 6.58348 24.4716Z",fill:"currentColor"})})}function Woe({isOpen:e}){const{theme:t}=Bt();return E.jsx(ZI,{"data-chat-widget":!0,style:{fontSize:"16px",position:"fixed",zIndex:1e7,...WN({primary:t.primaryColor},{triggerOffset:t.triggerOffset}),right:t.triggerOffset,bottom:t.triggerOffset},className:He("size-12 font-inter flex items-center justify-center"),children:E.jsx(oc,{children:E.jsx("div",{className:He("relative size-full rounded-full","flex items-center justify-center","transition-all","[background:radial-gradient(68.75%_68.75%_at_50%_100%,_#717171_0%,_#000000_100%)]","text-primary-foreground","shadow-xl","active:scale-90","[&_svg]:size-6"),children:E.jsx(lo,{mode:"wait",children:e?E.jsx(vr,{snapExit:!0,fadeIn:"up",overrides:{initial:{rotate:45},animate:{rotate:0}},children:E.jsx(JN,{})},"x-icon"):E.jsx(vr,{snapExit:!0,overrides:{initial:{rotate:45},animate:{rotate:0}},children:E.jsx($oe,{})},"message-icon")})})})})}const Yoe=`<!DOCTYPE html>
460
+ <html>
461
+ <head>
462
+ <style>
463
+ ${o6}
464
+ html, body {
465
+ height: 100%;
466
+ width: 100%;
467
+ margin: 0;
468
+ padding: 0;
469
+ font-size: 16px;
470
+ }
471
+ </style>
472
+ </head>
473
+ <body>
474
+ </body>
475
+ </html>`;function qoe({className:e,...t}){const n=Ao(),{theme:r}=Bt(),[i,a]=y.useState(!1);return E.jsxs(joe,{open:i,onOpenChange:a,children:[E.jsx("style",{children:o6}),E.jsx(zoe,{onInteractOutside:o=>o.preventDefault(),side:"top",forceMount:!0,style:{zIndex:1e6,fontSize:"16px"},sideOffset:8,"data-chat-widget":!0,"data-chat-widget-content-root":!0,align:"end",asChild:!0,children:E.jsx(vi.div,{animate:i?"visible":"hidden",initial:"hidden",variants:{hidden:{opacity:0,y:8,transitionEnd:{display:"none"},transition:{duration:.15}},visible:{opacity:1,y:0,display:"block"}},children:E.jsx(a6,{initialContent:Yoe,allowFullScreen:!0,"data-chat-widget":!0,style:{maxHeight:"85dvh",width:"350px",minHeight:A1.widgetMinHeight,height:"var(--opencx-widget-height)",overflow:"hidden",outline:"1px solid",outlineColor:"hsl(240 10% 3.9% / 0.2)",borderRadius:"32px",boxShadow:"0 25px 50px -12px rgb(0 0 0 / 0.25)",transitionProperty:"height",transitionTimingFunction:"ease-out",transitionDuration:"150ms"},children:E.jsx(ij,{delayDuration:200,disableHoverableContent:!0,children:E.jsx("div",{style:{display:"contents",...WN({primary:r.primaryColor},{triggerOffset:r.triggerOffset})},"data-chat-widget":!0,children:E.jsx("div",{...t,"data-version":n.version,"data-chat-widget":!0,className:He("antialiased font-inter size-full overflow-hidden isolate relative text-secondary-foreground",e),children:E.jsx(Qae,{})})})})})})}),E.jsx(Woe,{isOpen:i})]})}function Goe({options:e}){return E.jsx(JM,{options:{...e,components:[{key:"LOADING",component:pJ},{key:"FALLBACK",component:hJ},{key:"TEXT",component:zG}]},children:E.jsx(qoe,{})})}var s6,l6=is;s6=l6.createRoot,l6.hydrateRoot;function Koe(e,t){let n=document.getElementById(e);return n||(n=document.createElement("div"),n.id=e,n.setAttribute("data-chat-widget",""),document.body.appendChild(n)),s6(n).render(t)}const Xoe="opencopilot-root";function Qoe(e){Koe(Xoe,E.jsx(Goe,{options:e}))}window.initOpenScript=Qoe,window.openCopilotWidgetVersion=wh})();
476
+ //# sourceMappingURL=script.js.map