@elevenlabs/convai-widget-core 0.0.12 → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -2,9 +2,9 @@ var Ho = Object.defineProperty;
2
2
  var jo = (e, t, n) => t in e ? Ho(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
3
  var J = (e, t, n) => jo(e, typeof t != "symbol" ? t + "" : t, n);
4
4
  import Yo from "preact-custom-element";
5
- import { jsx as h, jsxs as P, Fragment as wt } from "preact/jsx-runtime";
6
- import * as u from "preact/compat";
7
- import _e, { useContext as Xo, createContext as he, useMemo as Ie, useRef as be, useEffect as Oe, memo as sr, useState as ke, useCallback as le, forwardRef as Ko, useLayoutEffect as Go } from "preact/compat";
5
+ import { jsx as h, jsxs as I, Fragment as wt } from "preact/jsx-runtime";
6
+ import * as d from "preact/compat";
7
+ import _e, { useContext as Ko, createContext as he, useMemo as Ie, useRef as be, useEffect as Oe, memo as sr, useState as ke, useCallback as le, forwardRef as Xo, useLayoutEffect as Go } from "preact/compat";
8
8
  import { signal as de, computed as xe, useSignal as ce, useComputed as Y, useSignalEffect as ze } from "@preact/signals";
9
9
  import { Conversation as Zo } from "@elevenlabs/client";
10
10
  import { clsx as j } from "clsx";
@@ -34,7 +34,8 @@ const rn = [
34
34
  "mic-muting",
35
35
  "transcript",
36
36
  "text-input",
37
- "text-contents"
37
+ "text-contents",
38
+ "user-id"
38
39
  ], qo = '@import"https://fonts.googleapis.com/css2?family=Inter:wght@400,500&display=swap";*,:before,: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: }::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: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:currentColor}:before,:after{--tw-content: ""}html,: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}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,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}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,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}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.pointer-events-auto{pointer-events:auto}.\\!visible{visibility:visible!important}.visible{visibility:visible}.collapse{visibility:collapse}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-0{top:0;right:0;bottom:0;left:0}.-bottom-3{bottom:-12px}.bottom-0{bottom:0}.bottom-1{bottom:4px}.bottom-20{bottom:80px}.left-0{left:0}.left-1\\/2{left:50%}.left-4{left:16px}.right-0{right:0}.right-1{right:4px}.top-0{top:0}.top-1\\/2{top:50%}.top-20{top:80px}.top-4{top:16px}.z-1{z-index:1}.z-10{z-index:10}.m-1{margin:4px}.-mx-0\\.5{margin-left:-2px;margin-right:-2px}.mx-1{margin-left:4px;margin-right:4px}.-mr-1\\.5{margin-right:-6px}.ml-auto{margin-left:auto}.mt-2{margin-top:8px}.block{display:block}.inline{display:inline}.\\!flex{display:flex!important}.flex{display:flex}.inline-flex{display:inline-flex}.contents{display:contents}.hidden{display:none}.h-11{height:44px}.h-16{height:64px}.h-4{height:16px}.h-48{height:192px}.h-5{height:20px}.h-6{height:24px}.h-7{height:28px}.h-9{height:36px}.h-\\[calc\\(100\\%-80px\\)\\]{height:calc(100% - 80px)}.h-full{height:100%}.h-screen{height:100vh}.max-h-\\[550px\\]{max-height:550px}.max-h-\\[8lh\\]{max-height:8lh}.max-h-\\[min\\(384px\\,var\\(--radix-select-content-available-height\\)\\)\\]{max-height:min(384px,var(--radix-select-content-available-height))}.min-h-min{min-height:-moz-min-content;min-height:min-content}.w-16{width:64px}.w-4{width:16px}.w-48{width:192px}.w-5{width:20px}.w-6{width:24px}.w-64{width:256px}.w-7{width:28px}.w-9{width:36px}.w-full{width:100%}.w-screen{width:100vw}.\\!min-w-60{min-width:240px!important}.min-w-0{min-width:0px}.min-w-60{min-width:240px}.min-w-9{min-width:36px}.min-w-\\[var\\(--radix-select-trigger-width\\)\\]{min-width:var(--radix-select-trigger-width)}.min-w-max{min-width:-moz-max-content;min-width:max-content}.min-w-min{min-width:-moz-min-content;min-width:min-content}.max-w-64{max-width:256px}.max-w-\\[400px\\]{max-width:400px}.shrink-0{flex-shrink:0}.grow{flex-grow:1}.origin-bottom{transform-origin:bottom}.origin-bottom-left{transform-origin:bottom left}.origin-bottom-right{transform-origin:bottom right}.origin-top{transform-origin:top}.origin-top-left{transform-origin:top left}.origin-top-right{transform-origin:top right}.-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))}.-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))}.-translate-y-\\[calc\\(var\\(--el-overlay-padding\\)\\)\\]{--tw-translate-y: calc(calc(var(--el-overlay-padding)) * -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))}.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))}.translate-y-\\[calc\\(var\\(--el-overlay-padding\\)\\)\\]{--tw-translate-y: calc(var(--el-overlay-padding));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))}.translate-y-full{--tw-translate-y: 100%;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))}.-rotate-180{--tw-rotate: -180deg;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))}.scale-100{--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))}.scale-150{--tw-scale-x: 1.5;--tw-scale-y: 1.5;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))}.scale-75{--tw-scale-x: .75;--tw-scale-y: .75;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))}.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))}.scale-\\[0\\.333\\]{--tw-scale-x: .333;--tw-scale-y: .333;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))}.transform{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))}.cursor-default{cursor:default}.cursor-pointer{cursor:pointer}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize-none{resize:none}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.gap-1{gap:4px}.gap-2{gap:8px}.gap-2\\.5{gap:10px}.gap-3{gap:12px}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.whitespace-nowrap{white-space:nowrap}.break-all{word-break:break-all}.rounded-\\[calc\\(var\\(--el-button-radius\\)\\+4px\\)\\]{border-radius:calc(var(--el-button-radius) + 4px)}.rounded-bubble{border-radius:var(--el-bubble-radius)}.rounded-button{border-radius:var(--el-button-radius)}.rounded-compact-sheet{border-radius:var(--el-compact-sheet-radius)}.rounded-dropdown-sheet{border-radius:var(--el-dropdown-sheet-radius)}.rounded-full{border-radius:9999px}.rounded-input{border-radius:var(--el-input-radius)}.rounded-sheet{border-radius:var(--el-sheet-radius)}.rounded-bl-\\[calc\\(var\\(--el-bubble-radius\\)\\/3\\)\\]{border-bottom-left-radius:calc(var(--el-bubble-radius) / 3)}.border{border-width:1px}.border-accent{border-color:var(--el-accent)}.border-base-border{border-color:var(--el-base-border)}.bg-accent{background-color:var(--el-accent)}.bg-base{background-color:var(--el-base)}.bg-base-active{background-color:var(--el-base-active)}.bg-base-border{background-color:var(--el-base-border)}.bg-base-hover{background-color:var(--el-base-hover)}.bg-cover{background-size:cover}.object-cover{-o-object-fit:cover;object-fit:cover}.p-1{padding:4px}.p-1\\.5{padding:6px}.p-2{padding:8px}.p-3{padding:12px}.p-4{padding:16px}.px-1{padding-left:4px;padding-right:4px}.px-1\\.5{padding-left:6px;padding-right:6px}.px-2{padding-left:8px;padding-right:8px}.px-2\\.5{padding-left:10px;padding-right:10px}.px-3{padding-left:12px;padding-right:12px}.px-4{padding-left:16px;padding-right:16px}.px-8{padding-left:32px;padding-right:32px}.py-1\\.5{padding-top:6px;padding-bottom:6px}.py-2\\.5{padding-top:10px;padding-bottom:10px}.py-\\[calc\\(theme\\(spacing\\.2\\)-1px\\)\\]{padding-top:7px;padding-bottom:7px}.pb-1{padding-bottom:4px}.pb-3{padding-bottom:12px}.pl-16{padding-left:64px}.pr-16{padding-right:64px}.pr-3{padding-right:12px}.pr-9{padding-right:36px}.pt-1{padding-top:4px}.text-center{text-align:center}.text-\\[10px\\]{font-size:10px}.text-lg{font-size:18px;line-height:26px}.text-md{font-size:16px;line-height:24px}.text-sm{font-size:14px;line-height:20px}.text-xs{font-size:12px;line-height:16px}.font-medium{font-weight:500}.text-accent-primary{color:var(--el-accent-primary)}.text-base-error{color:var(--el-base-error)}.text-base-primary{color:var(--el-base-primary)}.text-base-subtle{color:var(--el-base-subtle)}.underline{text-decoration-line:underline}.opacity-0{opacity:0}.opacity-30{opacity:.3}.shadow-lg{--tw-shadow: 0 2px 40px 1px rgba(0, 0, 0, .12);--tw-shadow-colored: 0 2px 40px 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)}.shadow-md{--tw-shadow: 0 2px 24px 1px rgba(0, 0, 0, .16);--tw-shadow-colored: 0 2px 24px 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)}.filter{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)}.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}.transition-\\[border-radius\\]{transition-property:border-radius;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\\[margin\\]{transition-property:margin;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\\[opacity\\,transform\\]{transition-property:opacity,transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\\[opacity\\,width\\,height\\,transform\\,flex-grow\\]{transition-property:opacity,width,height,transform,flex-grow;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\\[transform\\,left\\,top\\]{transition-property:transform,left,top;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\\[transform\\,opacity\\]{transition-property:transform,opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.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}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-200{transition-duration:.2s}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.overlay{position:absolute;inset:var(--el-overlay-padding);right:calc(var(--el-overlay-padding) + var(--removed-body-scroll-bar-size, 0px))}.focus-ring{--tw-ring-color: var(--el-accent);--tw-ring-offset-width: 2px;--tw-ring-offset-color: var(--el-base)}.focus-ring:focus-visible{outline:2px solid transparent;outline-offset:2px;--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)}.animate-text{background-image:linear-gradient(75deg,var(--el-base-primary),var(--el-base-subtle),var(--el-base-primary),var(--el-base-subtle));background-size:300% 100%;-webkit-background-clip:text;background-clip:text;color:transparent;animation:TextAnimation 2s linear infinite}@keyframes TextAnimation{0%{background-position:0 0}to{background-position:100% 0}}.\\!terms h6,.terms h6{font-size:12px;line-height:16px;font-weight:500;color:var(--el-base-primary)}.\\!terms h5,.terms h5{font-size:14px;line-height:20px;font-weight:500;color:var(--el-base-primary)}.\\!terms h4,.terms h4{font-size:16px;line-height:24px;font-weight:500;color:var(--el-base-primary)}.\\!terms h3,.terms h3{font-size:18px;line-height:26px;font-weight:500;color:var(--el-base-primary)}.\\!terms h2,.terms h2{font-size:20px;line-height:28px;font-weight:500;color:var(--el-base-primary)}.\\!terms h2,.terms h2{font-size:24px;line-height:30px;font-weight:500;color:var(--el-base-primary)}.\\[field-sizing\\:content\\]{field-sizing:content}.\\[line-height\\:var\\(--el-overlay-padding\\)\\]{line-height:var(--el-overlay-padding)}.\\[overflow-wrap\\:break-word\\]{overflow-wrap:break-word}.dev-host,:host{pointer-events:none;position:fixed;top:0;right:0;bottom:0;left:0;z-index:1000;font-size:16px;line-height:24px;color:var(--el-base-primary);font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;scrollbar-color:#e5e7eb transparent}.placeholder\\:text-base-subtle::-moz-placeholder{color:var(--el-base-subtle)}.placeholder\\:text-base-subtle::placeholder{color:var(--el-base-subtle)}.hover\\:border-accent-hover:hover{border-color:var(--el-accent-hover)}.hover\\:bg-accent-hover:hover{background-color:var(--el-accent-hover)}.hover\\:bg-base-hover:hover{background-color:var(--el-base-hover)}.hover\\:opacity-50:hover{opacity:.5}.focus-visible\\:underline-offset-2:focus-visible{text-underline-offset:2px}.focus-visible\\:opacity-100:focus-visible{opacity:1}.focus-visible\\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.active\\:border-accent-active:active{border-color:var(--el-accent-active)}.active\\:bg-accent-active:active{background-color:var(--el-accent-active)}.active\\:bg-base-active:active{background-color:var(--el-base-active)}.data-hidden\\:-translate-y-4[data-shown=false]{--tw-translate-y: -16px;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-hidden\\:translate-y-2[data-shown=false]{--tw-translate-y: 8px;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-hidden\\:scale-100[data-shown=false]{--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-hidden\\:scale-75[data-shown=false]{--tw-scale-x: .75;--tw-scale-y: .75;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-hidden\\:scale-90[data-shown=false]{--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-hidden\\:opacity-0[data-shown=false]{opacity:0}.data-\\[highlighted\\]\\:bg-base-active[data-highlighted]{background-color:var(--el-base-active)}', Dn = ["tiny", "compact", "full"];
39
40
  function Qo(e) {
40
41
  return Dn.includes(e) ? e : Dn[0];
@@ -117,7 +118,7 @@ function ra(e = "us") {
117
118
  }
118
119
  }
119
120
  function ve(e) {
120
- const t = Xo(e);
121
+ const t = Ko(e);
121
122
  if (t == null)
122
123
  throw new Error(
123
124
  `${e.displayName} cannot be used outside of provider`
@@ -142,14 +143,14 @@ function oa({
142
143
  function aa() {
143
144
  return ve(ur);
144
145
  }
145
- function H(e) {
146
+ function W(e) {
146
147
  return aa()[e];
147
148
  }
148
149
  const dr = he(null);
149
150
  function ia({
150
151
  children: e
151
152
  }) {
152
- const t = H("server-location"), n = Ie(() => {
153
+ const t = W("server-location"), n = Ie(() => {
153
154
  const r = xe(() => ra(t.value)), o = {
154
155
  us: "https://api.us.elevenlabs.io",
155
156
  "eu-residency": "https://api.eu.residency.elevenlabs.io",
@@ -217,7 +218,7 @@ const pr = he(null);
217
218
  function sa({
218
219
  children: e
219
220
  }) {
220
- const t = q(), n = H("language"), r = H("override-language"), o = ce(
221
+ const t = q(), n = W("language"), r = W("override-language"), o = ce(
221
222
  n.peek() ?? t.peek().language
222
223
  ), a = Y(
223
224
  () => (t.value.supported_language_overrides ?? []).filter(
@@ -243,8 +244,8 @@ function sa({
243
244
  function rt() {
244
245
  return ve(pr);
245
246
  }
246
- const hr = he(null);
247
- function la({ children: e }) {
247
+ const la = "0.1.0", hr = he(null);
248
+ function ca({ children: e }) {
248
249
  const t = q(), n = Y(
249
250
  () => t.value.mic_muting_enabled ?? !1
250
251
  ), r = ce(!1), o = Ie(
@@ -269,10 +270,10 @@ function vr() {
269
270
  return ve(hr);
270
271
  }
271
272
  const gr = he(null);
272
- function ca({
273
+ function ua({
273
274
  children: e
274
275
  }) {
275
- const { language: t } = rt(), n = H("override-prompt"), r = H("override-first-message"), o = H("override-voice-id"), a = H("override-text-only"), i = Y(() => ({
276
+ const { language: t } = rt(), n = W("override-prompt"), r = W("override-first-message"), o = W("override-voice-id"), a = W("override-text-only"), i = W("user-id"), s = Y(() => ({
276
277
  agent: {
277
278
  prompt: {
278
279
  prompt: n.value
@@ -286,46 +287,48 @@ function ca({
286
287
  conversation: {
287
288
  textOnly: Je(a.value) ?? void 0
288
289
  }
289
- })), s = H("dynamic-variables"), l = Y(() => {
290
- if (s.value)
290
+ })), l = W("dynamic-variables"), c = Y(() => {
291
+ if (l.value)
291
292
  try {
292
- return JSON.parse(s.value);
293
- } catch (m) {
293
+ return JSON.parse(l.value);
294
+ } catch (u) {
294
295
  console.error(
295
- `[ConversationalAI] Cannot parse dynamic-variables: ${m == null ? void 0 : m.message}`
296
+ `[ConversationalAI] Cannot parse dynamic-variables: ${u == null ? void 0 : u.message}`
296
297
  );
297
298
  }
298
- }), { webSocketUrl: c } = fr(), f = H("agent-id"), p = H("signed-url"), g = wn(), w = Y(() => {
299
- const m = {
300
- dynamicVariables: l.value,
301
- overrides: i.value,
299
+ }), { webSocketUrl: f } = fr(), p = W("agent-id"), g = W("signed-url"), w = wn(), m = Y(() => {
300
+ const u = {
301
+ dynamicVariables: c.value,
302
+ overrides: s.value,
302
303
  connectionDelay: { default: 300 },
303
- textOnly: g.value
304
+ textOnly: w.value,
305
+ connectionType: "websocket",
306
+ userId: i.value || void 0
304
307
  };
305
- return f.value ? {
306
- agentId: f.value,
307
- origin: c.value,
308
- ...m
309
- } : p.value ? {
310
- signedUrl: p.value,
311
- ...m
308
+ return p.value ? {
309
+ agentId: p.value,
310
+ origin: f.value,
311
+ ...u
312
+ } : g.value ? {
313
+ signedUrl: g.value,
314
+ ...u
312
315
  } : (console.error(
313
316
  "[ConversationalAI] Either agent-id or signed-url is required"
314
317
  ), null);
315
318
  });
316
- return w.value ? /* @__PURE__ */ h(
319
+ return m.value ? /* @__PURE__ */ h(
317
320
  gr.Provider,
318
321
  {
319
- value: w,
322
+ value: m,
320
323
  children: e
321
324
  }
322
325
  ) : null;
323
326
  }
324
- function ua() {
327
+ function da() {
325
328
  return ve(gr);
326
329
  }
327
330
  const mr = he(null);
328
- function da({ children: e }) {
331
+ function fa({ children: e }) {
329
332
  const t = q(), n = Ie(() => {
330
333
  const r = t.peek().terms_key, o = r ? !!localStorage.getItem(r) : !1, a = de(!1), i = de(o), s = xe(
331
334
  () => !t.value.terms_html || i.value
@@ -355,8 +358,8 @@ function Bt() {
355
358
  return ve(mr);
356
359
  }
357
360
  const wr = he(null);
358
- function fa({ children: e }) {
359
- const t = pa();
361
+ function pa({ children: e }) {
362
+ const t = ha();
360
363
  return ze(() => {
361
364
  if (t.conversationTextOnly.value === !0) {
362
365
  t.transcript.value;
@@ -376,8 +379,8 @@ function fa({ children: e }) {
376
379
  function ne() {
377
380
  return ve(wr);
378
381
  }
379
- function pa() {
380
- const e = be(null), t = be(null), n = q(), r = xr(), o = Bt(), a = ua(), { isMuted: i } = vr();
382
+ function ha() {
383
+ const e = be(null), t = be(null), n = q(), r = xr(), o = Bt(), a = da(), { isMuted: i } = vr();
381
384
  return ze(() => {
382
385
  var l;
383
386
  const s = i.value;
@@ -386,7 +389,7 @@ function pa() {
386
389
  var s;
387
390
  (s = e.current) == null || s.endSession();
388
391
  }, []), Ie(() => {
389
- const s = de("disconnected"), l = xe(() => s.value === "disconnected"), c = de("listening"), f = xe(() => c.value === "speaking"), p = de(null), g = de(null), w = de(!1), m = de([]), d = de(0), v = de(null);
392
+ const s = de("disconnected"), l = xe(() => s.value === "disconnected"), c = de("listening"), f = xe(() => c.value === "speaking"), p = de(null), g = de(null), w = de(!1), m = de([]), u = de(0), v = de(null);
390
393
  return {
391
394
  status: s,
392
395
  isSpeaking: f,
@@ -395,23 +398,23 @@ function pa() {
395
398
  lastId: g,
396
399
  error: p,
397
400
  canSendFeedback: w,
398
- conversationIndex: d,
401
+ conversationIndex: u,
399
402
  conversationTextOnly: v,
400
403
  transcript: m,
401
404
  startSession: async (b, x) => {
402
- var S, E;
403
- if (await o.requestTerms(), (S = e.current) != null && S.isOpen())
405
+ var C, S, T, E, R, M, L;
406
+ if (await o.requestTerms(), (C = e.current) != null && C.isOpen())
404
407
  return e.current.getId();
405
408
  if (t.current)
406
409
  return (await t.current).getId();
407
410
  let y = structuredClone(a.peek());
408
- x && n.value.supports_text_only && (y.textOnly = !0, n.value.text_only || (y.overrides ?? (y.overrides = {}), (E = y.overrides).conversation ?? (E.conversation = {}), y.overrides.conversation.textOnly = !0));
411
+ x && n.value.supports_text_only && (y.textOnly = !0, n.value.text_only || (y.overrides ?? (y.overrides = {}), (S = y.overrides).conversation ?? (S.conversation = {}), y.overrides.conversation.textOnly = !0));
409
412
  try {
410
- y = ha(b, y);
411
- } catch (T) {
413
+ y = va(b, y);
414
+ } catch (N) {
412
415
  console.error(
413
416
  "[ConversationalAI] Error triggering call event:",
414
- T
417
+ N
415
418
  );
416
419
  }
417
420
  v.value = y.textOnly ?? !1, m.value = x ? [
@@ -420,64 +423,72 @@ function pa() {
420
423
  role: "user",
421
424
  message: x,
422
425
  isText: !0,
423
- conversationIndex: d.peek()
426
+ conversationIndex: u.peek()
424
427
  }
425
428
  ] : [];
426
429
  try {
427
430
  if (t.current = Zo.startSession({
428
431
  ...y,
429
- onModeChange: (C) => {
430
- c.value = C.mode;
432
+ overrides: {
433
+ ...y.overrides,
434
+ client: {
435
+ ...(T = y.overrides) == null ? void 0 : T.client,
436
+ source: ((R = (E = y.overrides) == null ? void 0 : E.client) == null ? void 0 : R.source) || "widget",
437
+ version: ((L = (M = y.overrides) == null ? void 0 : M.client) == null ? void 0 : L.version) || la
438
+ }
439
+ },
440
+ onModeChange: (A) => {
441
+ c.value = A.mode;
431
442
  },
432
- onStatusChange: (C) => {
433
- s.value = C.status;
443
+ onStatusChange: (A) => {
444
+ s.value = A.status;
434
445
  },
435
- onCanSendFeedbackChange: (C) => {
436
- w.value = C.canSendFeedback;
446
+ onCanSendFeedbackChange: (A) => {
447
+ w.value = A.canSendFeedback;
437
448
  },
438
- onMessage: ({ source: C, message: I }) => {
439
- v.peek() === !0 && C === "ai" && I === r.peek() || (m.value = [
449
+ onMessage: ({ source: A, message: D }) => {
450
+ v.peek() === !0 && A === "ai" && D === r.peek() || (m.value = [
440
451
  ...m.value,
441
452
  {
442
453
  type: "message",
443
- role: C,
444
- message: I,
454
+ role: A,
455
+ message: D,
445
456
  isText: !1,
446
- conversationIndex: d.peek()
457
+ conversationIndex: u.peek()
447
458
  }
448
459
  ]);
449
460
  },
450
- onDisconnect: (C) => {
461
+ onDisconnect: (A) => {
451
462
  v.value = null, m.value = [
452
463
  ...m.value,
453
- C.reason === "error" ? {
464
+ A.reason === "error" ? {
454
465
  type: "error",
455
- message: C.message,
456
- conversationIndex: d.peek()
466
+ message: A.message,
467
+ conversationIndex: u.peek()
457
468
  } : {
458
469
  type: "disconnection",
459
- role: C.reason === "user" ? "user" : "ai",
460
- conversationIndex: d.peek()
470
+ role: A.reason === "user" ? "user" : "ai",
471
+ conversationIndex: u.peek()
461
472
  }
462
- ], d.value++, C.reason === "error" && (p.value = C.message, console.error(
473
+ ], u.value++, A.reason === "error" && (p.value = A.message, console.error(
463
474
  "[ConversationalAI] Disconnected due to an error:",
464
- C.message
475
+ A.message
465
476
  ));
466
477
  }
467
478
  }), e.current = await t.current, e.current.setMicMuted(i.peek()), x) {
468
- const C = e.current;
469
- setTimeout(() => C.sendUserMessage(x), 100);
479
+ const A = e.current;
480
+ setTimeout(() => A.sendUserMessage(x), 100);
470
481
  }
471
- const T = e.current.getId();
472
- return g.value = T, p.value = null, T;
473
- } catch (T) {
474
- let C = "Could not start a conversation.";
475
- T instanceof CloseEvent ? C = T.reason || C : T instanceof Error && (C = T.message || C), p.value = C, m.value = [
482
+ const N = e.current.getId();
483
+ return g.value = N, p.value = null, N;
484
+ } catch (N) {
485
+ let A = "Could not start a conversation.";
486
+ N instanceof CloseEvent ? A = N.reason || A : N instanceof Error && (A = N.message || A), p.value = A, m.value = [
476
487
  ...m.value,
477
488
  {
478
489
  type: "error",
479
- message: C,
480
- conversationIndex: d.peek()
490
+ message: A,
491
+ conversationIndex: u.peek()
481
492
  }
482
493
  ];
483
494
  } finally {
@@ -509,7 +520,7 @@ function pa() {
509
520
  role: "user",
510
521
  message: b,
511
522
  isText: !0,
512
- conversationIndex: d.peek()
523
+ conversationIndex: u.peek()
513
524
  }
514
525
  ];
515
526
  },
@@ -520,7 +531,7 @@ function pa() {
520
531
  };
521
532
  }, [a, i]);
522
533
  }
523
- function ha(e, t) {
534
+ function va(e, t) {
524
535
  try {
525
536
  const n = new CustomEvent("elevenlabs-convai:call", {
526
537
  bubbles: !0,
@@ -535,8 +546,8 @@ function ha(e, t) {
535
546
  const br = he(
536
547
  null
537
548
  );
538
- function va({ children: e }) {
539
- const { serverUrl: t } = fr(), n = H("agent-id"), r = H("override-config"), o = ce(null);
549
+ function ga({ children: e }) {
550
+ const { serverUrl: t } = fr(), n = W("agent-id"), r = W("override-config"), o = ce(null);
540
551
  ze(() => {
541
552
  if (r.value)
542
553
  try {
@@ -555,7 +566,7 @@ function va({ children: e }) {
555
566
  return;
556
567
  }
557
568
  const w = new AbortController();
558
- return ga(n.value, t.value, w.signal).then((m) => {
569
+ return ma(n.value, t.value, w.signal).then((m) => {
559
570
  w.signal.aborted || (o.value = m);
560
571
  }).catch((m) => {
561
572
  console.error(
@@ -565,15 +576,15 @@ function va({ children: e }) {
565
576
  w.abort();
566
577
  };
567
578
  });
568
- const a = H("variant"), i = H("placement"), s = H("terms-key"), l = H("mic-muting"), c = H("transcript"), f = H("text-input"), p = H("override-text-only"), g = Y(() => {
579
+ const a = W("variant"), i = W("placement"), s = W("terms-key"), l = W("mic-muting"), c = W("transcript"), f = W("text-input"), p = W("override-text-only"), g = Y(() => {
569
580
  if (!o.value)
570
581
  return null;
571
- const w = a.value ?? o.value.variant, m = i.value ?? o.value.placement, d = s.value ?? o.value.terms_key, v = Je(p.value) ?? o.value.text_only ?? !1, b = Je(l.value) ?? o.value.mic_muting_enabled, x = Je(c.value) ?? o.value.transcript_enabled, y = Je(f.value) ?? o.value.text_input_enabled;
582
+ const w = a.value ?? o.value.variant, m = i.value ?? o.value.placement, u = s.value ?? o.value.terms_key, v = Je(p.value) ?? o.value.text_only ?? !1, b = Je(l.value) ?? o.value.mic_muting_enabled, x = Je(c.value) ?? o.value.transcript_enabled, y = Je(f.value) ?? o.value.text_input_enabled;
572
583
  return {
573
584
  ...o.value,
574
585
  variant: Qo(w),
575
586
  placement: ea(m),
576
- terms_key: d,
587
+ terms_key: u,
577
588
  mic_muting_enabled: !v && b,
578
589
  transcript_enabled: v || x,
579
590
  text_input_enabled: v || y
@@ -585,7 +596,7 @@ function q() {
585
596
  return ve(br);
586
597
  }
587
598
  function wn() {
588
- const e = H("override-text-only"), t = q();
599
+ const e = W("override-text-only"), t = q();
589
600
  return Y(
590
601
  () => Je(e.value) ?? t.value.text_only ?? !1
591
602
  );
@@ -595,7 +606,7 @@ function zt() {
595
606
  return Y(() => t.value ?? e.value);
596
607
  }
597
608
  function xr() {
598
- const e = H("override-first-message"), t = q(), { language: n } = rt();
609
+ const e = W("override-first-message"), t = q(), { language: n } = rt();
599
610
  return Y(
600
611
  () => {
601
612
  var r, o;
@@ -603,7 +614,7 @@ function xr() {
603
614
  }
604
615
  );
605
616
  }
606
- async function ga(e, t, n) {
617
+ async function ma(e, t, n) {
607
618
  const o = await (await fetch(
608
619
  `${t}/v1/convai/agents/${e}/widget`,
609
620
  {
@@ -614,30 +625,30 @@ async function ga(e, t, n) {
614
625
  throw new Error("Response does not contain widget_config");
615
626
  return o.widget_config;
616
627
  }
617
- const ma = sr(function() {
628
+ const wa = sr(function() {
618
629
  const t = q(), n = Y(() => {
619
630
  const r = t.value.styles;
620
631
  return `:host, :root {
621
632
  ${na.map(
622
- (o) => `${wa(o)}: ${ba((r == null ? void 0 : r[o]) ?? cr[o])};`
633
+ (o) => `${ba(o)}: ${xa((r == null ? void 0 : r[o]) ?? cr[o])};`
623
634
  ).join(`
624
635
  `)}
625
636
  }`;
626
637
  });
627
- return /* @__PURE__ */ P("style", { children: [
638
+ return /* @__PURE__ */ I("style", { children: [
628
639
  n,
629
640
  qo
630
641
  ] });
631
642
  });
632
- function wa(e) {
643
+ function ba(e) {
633
644
  return `--el-${e.replace(/_/g, "-")}`;
634
645
  }
635
- function ba(e) {
646
+ function xa(e) {
636
647
  return typeof e == "number" ? `${e}px` : e;
637
648
  }
638
649
  const yr = he(null);
639
- function xa({ children: e }) {
640
- const t = q(), { language: n } = rt(), r = H("text-contents"), o = Y(() => {
650
+ function ya({ children: e }) {
651
+ const t = q(), { language: n } = rt(), r = W("text-contents"), o = Y(() => {
641
652
  try {
642
653
  if (r.value) {
643
654
  const i = JSON.parse(r.value);
@@ -665,8 +676,8 @@ function re() {
665
676
  return ve(yr);
666
677
  }
667
678
  const Cr = he(null);
668
- function ya({ children: e }) {
669
- const t = q(), n = H("avatar-image-url"), r = H("avatar-orb-color-1"), o = H("avatar-orb-color-2"), a = ce(""), i = Y(() => n.value ? {
679
+ function Ca({ children: e }) {
680
+ const t = q(), n = W("avatar-image-url"), r = W("avatar-orb-color-1"), o = W("avatar-orb-color-2"), a = ce(""), i = Y(() => n.value ? {
670
681
  type: "image",
671
682
  url: n.value
672
683
  } : r.value && o.value ? {
@@ -693,20 +704,20 @@ function yt({ children: e, ...t }) {
693
704
  const [n, r] = ke(null);
694
705
  return /* @__PURE__ */ h("div", { ref: r, ...t, children: n && /* @__PURE__ */ h(Sr.Provider, { value: n, children: e }) });
695
706
  }
696
- function Ca() {
707
+ function Sa() {
697
708
  return ve(Sr);
698
709
  }
699
710
  function xn(e) {
700
711
  return e && typeof e == "object" && "peek" in e;
701
712
  }
702
- function Sa(e) {
713
+ function Ea(e) {
703
714
  const t = xn(e), n = ce(t ? e.peek() : e);
704
715
  return t ? e : (n.value = e, n);
705
716
  }
706
717
  function Er(e) {
707
718
  return xn(e) ? e.value : e;
708
719
  }
709
- function Ea(e) {
720
+ function ka(e) {
710
721
  return xn(e) ? e.peek() : e;
711
722
  }
712
723
  function Bn(e, t) {
@@ -731,15 +742,15 @@ function kr(...e) {
731
742
  };
732
743
  }
733
744
  function Z(...e) {
734
- return u.useCallback(kr(...e), e);
745
+ return d.useCallback(kr(...e), e);
735
746
  }
736
747
  // @__NO_SIDE_EFFECTS__
737
748
  function vt(e) {
738
- const t = /* @__PURE__ */ ka(e), n = u.forwardRef((r, o) => {
739
- const { children: a, ...i } = r, s = u.Children.toArray(a), l = s.find(Aa);
749
+ const t = /* @__PURE__ */ Ta(e), n = d.forwardRef((r, o) => {
750
+ const { children: a, ...i } = r, s = d.Children.toArray(a), l = s.find(Pa);
740
751
  if (l) {
741
- const c = l.props.children, f = s.map((p) => p === l ? u.Children.count(c) > 1 ? u.Children.only(null) : u.isValidElement(c) ? c.props.children : null : p);
742
- return /* @__PURE__ */ k(t, { ...i, ref: o, children: u.isValidElement(c) ? u.cloneElement(c, void 0, f) : null });
752
+ const c = l.props.children, f = s.map((p) => p === l ? d.Children.count(c) > 1 ? d.Children.only(null) : d.isValidElement(c) ? c.props.children : null : p);
753
+ return /* @__PURE__ */ k(t, { ...i, ref: o, children: d.isValidElement(c) ? d.cloneElement(c, void 0, f) : null });
743
754
  }
744
755
  return /* @__PURE__ */ k(t, { ...i, ref: o, children: a });
745
756
  });
@@ -747,22 +758,22 @@ function vt(e) {
747
758
  }
748
759
  var Tr = /* @__PURE__ */ vt("Slot");
749
760
  // @__NO_SIDE_EFFECTS__
750
- function ka(e) {
751
- const t = u.forwardRef((n, r) => {
761
+ function Ta(e) {
762
+ const t = d.forwardRef((n, r) => {
752
763
  const { children: o, ...a } = n;
753
- if (u.isValidElement(o)) {
754
- const i = Ia(o), s = Pa(a, o.props);
755
- return o.type !== u.Fragment && (s.ref = r ? kr(r, i) : i), u.cloneElement(o, s);
764
+ if (d.isValidElement(o)) {
765
+ const i = Ra(o), s = Ia(a, o.props);
766
+ return o.type !== d.Fragment && (s.ref = r ? kr(r, i) : i), d.cloneElement(o, s);
756
767
  }
757
- return u.Children.count(o) > 1 ? u.Children.only(null) : null;
768
+ return d.Children.count(o) > 1 ? d.Children.only(null) : null;
758
769
  });
759
770
  return t.displayName = `${e}.SlotClone`, t;
760
771
  }
761
- var Ta = Symbol("radix.slottable");
762
- function Aa(e) {
763
- return u.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === Ta;
772
+ var Aa = Symbol("radix.slottable");
773
+ function Pa(e) {
774
+ return d.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === Aa;
764
775
  }
765
- function Pa(e, t) {
776
+ function Ia(e, t) {
766
777
  const n = { ...t };
767
778
  for (const r in t) {
768
779
  const o = e[r], a = t[r];
@@ -772,19 +783,19 @@ function Pa(e, t) {
772
783
  }
773
784
  return { ...e, ...n };
774
785
  }
775
- function Ia(e) {
786
+ function Ra(e) {
776
787
  var r, o;
777
788
  let t = (r = Object.getOwnPropertyDescriptor(e.props, "ref")) == null ? void 0 : r.get, n = t && "isReactWarning" in t && t.isReactWarning;
778
789
  return n ? e.ref : (t = (o = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : o.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
779
790
  }
780
- const Xt = window.matchMedia("(prefers-reduced-motion: reduce)");
791
+ const Kt = window.matchMedia("(prefers-reduced-motion: reduce)");
781
792
  function Ar() {
782
- const e = ce(Xt.matches);
793
+ const e = ce(Kt.matches);
783
794
  return Oe(() => {
784
795
  const t = (n) => {
785
796
  e.value = n.matches;
786
797
  };
787
- return Xt.addEventListener("change", t), () => Xt.removeEventListener("change", t);
798
+ return Kt.addEventListener("change", t), () => Kt.removeEventListener("change", t);
788
799
  }, []), e;
789
800
  }
790
801
  function Pr({ onStart: e, onEnd: t }) {
@@ -813,18 +824,18 @@ function Pr({ onStart: e, onEnd: t }) {
813
824
  };
814
825
  }
815
826
  function se(e) {
816
- const t = Ar().value ? Ra : _a;
827
+ const t = Ar().value ? _a : Na;
817
828
  return /* @__PURE__ */ h(t, { ...e });
818
829
  }
819
- function Ra({ active: e, ...t }) {
830
+ function _a({ active: e, ...t }) {
820
831
  return Er(e) ? /* @__PURE__ */ h(Tr, { "data-shown": !0, ...t }) : null;
821
832
  }
822
- function _a({
833
+ function Na({
823
834
  active: e,
824
835
  initial: t = e,
825
836
  ...n
826
837
  }) {
827
- const r = Sa(e), o = ce(Ea(t));
838
+ const r = Ea(e), o = ce(ka(t));
828
839
  ze(() => {
829
840
  r.value && (o.value = r.value);
830
841
  });
@@ -835,7 +846,7 @@ function _a({
835
846
  });
836
847
  return !r.value && !o.value ? null : /* @__PURE__ */ h(Tr, { "data-shown": r.value && o.value, ...a, ...n });
837
848
  }
838
- const Na = `#version 300 es
849
+ const Oa = `#version 300 es
839
850
  precision highp float;
840
851
 
841
852
  uniform float uTime;
@@ -999,7 +1010,7 @@ void main() {
999
1010
 
1000
1011
  outColor = color;
1001
1012
  }
1002
- `, Oa = `#version 300 es
1013
+ `, Ma = `#version 300 es
1003
1014
  precision highp float;
1004
1015
 
1005
1016
  in vec2 position;
@@ -1010,7 +1021,7 @@ void main() {
1010
1021
  vUv = position * 0.5 + 0.5;
1011
1022
  gl_Position = vec4(position, 0, 1);
1012
1023
  }
1013
- `, zn = 0, Ma = new Float32Array([
1024
+ `, zn = 0, La = new Float32Array([
1014
1025
  -1,
1015
1026
  1,
1016
1027
  -1,
@@ -1019,7 +1030,7 @@ void main() {
1019
1030
  1,
1020
1031
  1,
1021
1032
  -1
1022
- ]), La = "https://storage.googleapis.com/eleven-public-cdn/images/perlin-noise.png", me = class me {
1033
+ ]), Da = "https://storage.googleapis.com/eleven-public-cdn/images/perlin-noise.png", me = class me {
1023
1034
  constructor(t) {
1024
1035
  J(this, "gl");
1025
1036
  J(this, "program");
@@ -1054,7 +1065,7 @@ void main() {
1054
1065
  depth: !1,
1055
1066
  stencil: !1
1056
1067
  });
1057
- this.gl = n, this.program = this.setupProgram(Na, Oa);
1068
+ this.gl = n, this.program = this.setupProgram(Oa, Ma);
1058
1069
  const r = n.createTexture();
1059
1070
  n.bindTexture(n.TEXTURE_2D, r), n.texImage2D(
1060
1071
  n.TEXTURE_2D,
@@ -1066,9 +1077,9 @@ void main() {
1066
1077
  n.RGBA,
1067
1078
  n.UNSIGNED_BYTE,
1068
1079
  new Uint8Array([128, 128, 128, 255])
1069
- ), me.noiseImage || (me.noiseImage = new Image(), me.noiseImage.crossOrigin = "anonymous", me.noiseImage.src = La), me.noiseImage.complete ? this.copyNoiseImage() : me.noiseImage.addEventListener("load", this.copyNoiseImage);
1080
+ ), me.noiseImage || (me.noiseImage = new Image(), me.noiseImage.crossOrigin = "anonymous", me.noiseImage.src = Da), me.noiseImage.complete ? this.copyNoiseImage() : me.noiseImage.addEventListener("load", this.copyNoiseImage);
1070
1081
  const o = n.createBuffer();
1071
- n.bindBuffer(n.ARRAY_BUFFER, o), n.bufferData(n.ARRAY_BUFFER, Ma, n.STATIC_DRAW), n.vertexAttribPointer(zn, 2, n.FLOAT, !1, 0, 0), n.enableVertexAttribArray(zn), this.updateColors("#2792DC", "#9CE6E6"), this.resizeObserver = new ResizeObserver((i) => {
1082
+ n.bindBuffer(n.ARRAY_BUFFER, o), n.bufferData(n.ARRAY_BUFFER, La, n.STATIC_DRAW), n.vertexAttribPointer(zn, 2, n.FLOAT, !1, 0, 0), n.enableVertexAttribArray(zn), this.updateColors("#2792DC", "#9CE6E6"), this.resizeObserver = new ResizeObserver((i) => {
1072
1083
  const s = i[0], l = s.devicePixelContentBoxSize ? s.devicePixelContentBoxSize[0] : s.contentBoxSize[0];
1073
1084
  t.width = Math.min(512, l.inlineSize), t.height = Math.min(512, l.blockSize), this.updateViewport();
1074
1085
  });
@@ -1137,7 +1148,7 @@ void main() {
1137
1148
  };
1138
1149
  J(me, "noiseImage");
1139
1150
  let on = me;
1140
- const Da = {
1151
+ const Ba = {
1141
1152
  sm: "w-9 h-9",
1142
1153
  lg: "w-48 h-48"
1143
1154
  };
@@ -1150,8 +1161,8 @@ function ot({ size: e = "sm", className: t }) {
1150
1161
  }
1151
1162
  let f;
1152
1163
  function p() {
1153
- const g = n(), w = r(), m = o.peek() ? 1 : 1 - g * 0.4, d = o.peek() ? 1 + w * 0.4 : 1;
1154
- s.current.style.transform = `scale(${d})`, l.current.style.transform = `scale(${m})`, f = requestAnimationFrame(p);
1164
+ const g = n(), w = r(), m = o.peek() ? 1 : 1 - g * 0.4, u = o.peek() ? 1 + w * 0.4 : 1;
1165
+ s.current.style.transform = `scale(${u})`, l.current.style.transform = `scale(${m})`, f = requestAnimationFrame(p);
1155
1166
  }
1156
1167
  return p(), () => {
1157
1168
  cancelAnimationFrame(f);
@@ -1160,7 +1171,7 @@ function ot({ size: e = "sm", className: t }) {
1160
1171
  const c = Y(() => ({
1161
1172
  backgroundImage: i.value.type === "image" ? `url(${i.value.url})` : i.value.type === "url" ? `url(${i.value.custom_url})` : void 0
1162
1173
  }));
1163
- return /* @__PURE__ */ P("div", { className: j("relative shrink-0", Da[e], t), children: [
1174
+ return /* @__PURE__ */ I("div", { className: j("relative shrink-0", Ba[e], t), children: [
1164
1175
  /* @__PURE__ */ h(
1165
1176
  "div",
1166
1177
  {
@@ -1175,7 +1186,7 @@ function ot({ size: e = "sm", className: t }) {
1175
1186
  style: c,
1176
1187
  className: "absolute inset-0 rounded-full overflow-hidden bg-base bg-cover",
1177
1188
  children: i.value.type === "orb" && /* @__PURE__ */ h(
1178
- Ba,
1189
+ za,
1179
1190
  {
1180
1191
  color1: i.value.color_1,
1181
1192
  color2: i.value.color_2
@@ -1185,7 +1196,7 @@ function ot({ size: e = "sm", className: t }) {
1185
1196
  )
1186
1197
  ] });
1187
1198
  }
1188
- function Ba({ color1: e, color2: t }) {
1199
+ function za({ color1: e, color2: t }) {
1189
1200
  const { canvasUrl: n } = bn(), [r, o] = ke(null);
1190
1201
  Oe(() => {
1191
1202
  r && (r.updateColors(e, t), r.render(), n.value = r.toDataURL());
@@ -1202,33 +1213,33 @@ function Ba({ color1: e, color2: t }) {
1202
1213
  );
1203
1214
  return /* @__PURE__ */ h("canvas", { className: "w-full h-full", ref: a });
1204
1215
  }
1205
- const za = {
1206
- phone: Va,
1207
- "phone-off": $a,
1208
- chat: Wa,
1209
- mic: Ua,
1210
- "mic-off": Ha,
1216
+ const Fa = {
1217
+ phone: $a,
1218
+ "phone-off": Wa,
1219
+ chat: Ua,
1220
+ mic: Ha,
1221
+ "mic-off": ja,
1211
1222
  check: Xa,
1212
- "chevron-down": ja,
1213
- "chevron-up": Ya,
1214
- send: Ka
1215
- }, Fa = {
1223
+ "chevron-down": Ya,
1224
+ "chevron-up": Ka,
1225
+ send: Ga
1226
+ }, Va = {
1216
1227
  sm: "text-xs",
1217
1228
  md: "text-lg"
1218
1229
  };
1219
1230
  function We({ name: e, size: t = "md", className: n }) {
1220
- const r = za[e];
1231
+ const r = Fa[e];
1221
1232
  return /* @__PURE__ */ h(
1222
1233
  "slot",
1223
1234
  {
1224
1235
  name: `icon-${e}`,
1225
- className: j("flex", Fa[t], n),
1236
+ className: j("flex", Va[t], n),
1226
1237
  "aria-hidden": !0,
1227
1238
  children: /* @__PURE__ */ h(r, {})
1228
1239
  }
1229
1240
  );
1230
1241
  }
1231
- function Va(e) {
1242
+ function $a(e) {
1232
1243
  return /* @__PURE__ */ h(
1233
1244
  "svg",
1234
1245
  {
@@ -1242,8 +1253,8 @@ function Va(e) {
1242
1253
  }
1243
1254
  );
1244
1255
  }
1245
- function $a(e) {
1246
- return /* @__PURE__ */ P(
1256
+ function Wa(e) {
1257
+ return /* @__PURE__ */ I(
1247
1258
  "svg",
1248
1259
  {
1249
1260
  height: "1em",
@@ -1259,7 +1270,7 @@ function $a(e) {
1259
1270
  }
1260
1271
  );
1261
1272
  }
1262
- function Wa(e) {
1273
+ function Ua(e) {
1263
1274
  return /* @__PURE__ */ h(
1264
1275
  "svg",
1265
1276
  {
@@ -1280,8 +1291,8 @@ function Wa(e) {
1280
1291
  }
1281
1292
  );
1282
1293
  }
1283
- function Ua(e) {
1284
- return /* @__PURE__ */ P(
1294
+ function Ha(e) {
1295
+ return /* @__PURE__ */ I(
1285
1296
  "svg",
1286
1297
  {
1287
1298
  height: "1em",
@@ -1297,8 +1308,8 @@ function Ua(e) {
1297
1308
  }
1298
1309
  );
1299
1310
  }
1300
- function Ha(e) {
1301
- return /* @__PURE__ */ P(
1311
+ function ja(e) {
1312
+ return /* @__PURE__ */ I(
1302
1313
  "svg",
1303
1314
  {
1304
1315
  height: "1em",
@@ -1314,7 +1325,7 @@ function Ha(e) {
1314
1325
  }
1315
1326
  );
1316
1327
  }
1317
- function ja(e) {
1328
+ function Ya(e) {
1318
1329
  return /* @__PURE__ */ h(
1319
1330
  "svg",
1320
1331
  {
@@ -1332,7 +1343,7 @@ function ja(e) {
1332
1343
  }
1333
1344
  );
1334
1345
  }
1335
- function Ya(e) {
1346
+ function Ka(e) {
1336
1347
  return /* @__PURE__ */ h(
1337
1348
  "svg",
1338
1349
  {
@@ -1368,7 +1379,7 @@ function Xa(e) {
1368
1379
  }
1369
1380
  );
1370
1381
  }
1371
- function Ka(e) {
1382
+ function Ga(e) {
1372
1383
  return /* @__PURE__ */ h(
1373
1384
  "svg",
1374
1385
  {
@@ -1389,10 +1400,10 @@ function Ka(e) {
1389
1400
  );
1390
1401
  }
1391
1402
  function Te(e) {
1392
- const t = Ar().value ? Ga : Za;
1403
+ const t = Ar().value ? Za : qa;
1393
1404
  return /* @__PURE__ */ h(t, { ...e });
1394
1405
  }
1395
- function Ga({
1406
+ function Za({
1396
1407
  visible: e,
1397
1408
  className: t,
1398
1409
  grow: n,
@@ -1401,7 +1412,7 @@ function Ga({
1401
1412
  }) {
1402
1413
  return e ? /* @__PURE__ */ h("div", { className: j(n && "grow", t), ...o }) : null;
1403
1414
  }
1404
- function Za({
1415
+ function qa({
1405
1416
  visible: e,
1406
1417
  children: t,
1407
1418
  className: n,
@@ -1437,7 +1448,7 @@ function Za({
1437
1448
  o
1438
1449
  // node's content changed
1439
1450
  ]);
1440
- const { transitioning: m, handlers: d } = Pr({
1451
+ const { transitioning: m, handlers: u } = Pr({
1441
1452
  onEnd: () => {
1442
1453
  e ? (l.style.width = "", l.style.height = "") : s(!1);
1443
1454
  }
@@ -1452,7 +1463,7 @@ function Za({
1452
1463
  e && r && "grow",
1453
1464
  e && i && !m.value && "z-1"
1454
1465
  ),
1455
- ...d,
1466
+ ...u,
1456
1467
  children: /* @__PURE__ */ h(
1457
1468
  "div",
1458
1469
  {
@@ -1469,10 +1480,10 @@ function Za({
1469
1480
  }
1470
1481
  );
1471
1482
  }
1472
- const qa = {
1483
+ const Qa = {
1473
1484
  primary: "text-accent-primary border border-accent bg-accent hover:border-accent-hover hover:bg-accent-hover active:border-accent-active active:bg-accent-active",
1474
1485
  secondary: "text-base-primary border border-base-border bg-base hover:bg-base-hover active:bg-base-active"
1475
- }, Me = Ko(
1486
+ }, Me = Xo(
1476
1487
  function({
1477
1488
  variant: t = "secondary",
1478
1489
  children: n,
@@ -1483,13 +1494,13 @@ const qa = {
1483
1494
  ...s
1484
1495
  }, l) {
1485
1496
  const c = !!r && !n;
1486
- return /* @__PURE__ */ P(
1497
+ return /* @__PURE__ */ I(
1487
1498
  "button",
1488
1499
  {
1489
1500
  ref: l,
1490
1501
  className: j(
1491
1502
  "h-9 flex px-2.5 text-sm items-center transition-colors justify-center rounded-button duration-200 focus-ring overflow-hidden select-none",
1492
- qa[t],
1503
+ Qa[t],
1493
1504
  c && "min-w-9",
1494
1505
  o
1495
1506
  ),
@@ -1554,17 +1565,17 @@ function G(e, t, { checkForDefaultPrevented: n = !0 } = {}) {
1554
1565
  function yn(e, t = []) {
1555
1566
  let n = [];
1556
1567
  function r(a, i) {
1557
- const s = u.createContext(i), l = n.length;
1568
+ const s = d.createContext(i), l = n.length;
1558
1569
  n = [...n, i];
1559
1570
  const c = (p) => {
1560
1571
  var b;
1561
- const { scope: g, children: w, ...m } = p, d = ((b = g == null ? void 0 : g[e]) == null ? void 0 : b[l]) || s, v = u.useMemo(() => m, Object.values(m));
1562
- return /* @__PURE__ */ k(d.Provider, { value: v, children: w });
1572
+ const { scope: g, children: w, ...m } = p, u = ((b = g == null ? void 0 : g[e]) == null ? void 0 : b[l]) || s, v = d.useMemo(() => m, Object.values(m));
1573
+ return /* @__PURE__ */ k(u.Provider, { value: v, children: w });
1563
1574
  };
1564
1575
  c.displayName = a + "Provider";
1565
1576
  function f(p, g) {
1566
- var d;
1567
- const w = ((d = g == null ? void 0 : g[e]) == null ? void 0 : d[l]) || s, m = u.useContext(w);
1577
+ var u;
1578
+ const w = ((u = g == null ? void 0 : g[e]) == null ? void 0 : u[l]) || s, m = d.useContext(w);
1568
1579
  if (m) return m;
1569
1580
  if (i !== void 0) return i;
1570
1581
  throw new Error(`\`${p}\` must be used within \`${a}\``);
@@ -1572,18 +1583,18 @@ function yn(e, t = []) {
1572
1583
  return [c, f];
1573
1584
  }
1574
1585
  const o = () => {
1575
- const a = n.map((i) => u.createContext(i));
1586
+ const a = n.map((i) => d.createContext(i));
1576
1587
  return function(s) {
1577
1588
  const l = (s == null ? void 0 : s[e]) || a;
1578
- return u.useMemo(
1589
+ return d.useMemo(
1579
1590
  () => ({ [`__scope${e}`]: { ...s, [e]: l } }),
1580
1591
  [s, l]
1581
1592
  );
1582
1593
  };
1583
1594
  };
1584
- return o.scopeName = e, [r, Qa(o, ...t)];
1595
+ return o.scopeName = e, [r, Ja(o, ...t)];
1585
1596
  }
1586
- function Qa(...e) {
1597
+ function Ja(...e) {
1587
1598
  const t = e[0];
1588
1599
  if (e.length === 1) return t;
1589
1600
  const n = () => {
@@ -1596,42 +1607,42 @@ function Qa(...e) {
1596
1607
  const p = l(a)[`__scope${c}`];
1597
1608
  return { ...s, ...p };
1598
1609
  }, {});
1599
- return u.useMemo(() => ({ [`__scope${t.scopeName}`]: i }), [i]);
1610
+ return d.useMemo(() => ({ [`__scope${t.scopeName}`]: i }), [i]);
1600
1611
  };
1601
1612
  };
1602
1613
  return n.scopeName = t.scopeName, n;
1603
1614
  }
1604
- function Ja(e) {
1615
+ function ei(e) {
1605
1616
  const t = e + "CollectionProvider", [n, r] = yn(t), [o, a] = n(
1606
1617
  t,
1607
1618
  { collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }
1608
- ), i = (d) => {
1609
- const { scope: v, children: b } = d, x = _e.useRef(null), y = _e.useRef(/* @__PURE__ */ new Map()).current;
1619
+ ), i = (u) => {
1620
+ const { scope: v, children: b } = u, x = _e.useRef(null), y = _e.useRef(/* @__PURE__ */ new Map()).current;
1610
1621
  return /* @__PURE__ */ k(o, { scope: v, itemMap: y, collectionRef: x, children: b });
1611
1622
  };
1612
1623
  i.displayName = t;
1613
1624
  const s = e + "CollectionSlot", l = /* @__PURE__ */ vt(s), c = _e.forwardRef(
1614
- (d, v) => {
1615
- const { scope: b, children: x } = d, y = a(s, b), S = Z(v, y.collectionRef);
1616
- return /* @__PURE__ */ k(l, { ref: S, children: x });
1625
+ (u, v) => {
1626
+ const { scope: b, children: x } = u, y = a(s, b), C = Z(v, y.collectionRef);
1627
+ return /* @__PURE__ */ k(l, { ref: C, children: x });
1617
1628
  }
1618
1629
  );
1619
1630
  c.displayName = s;
1620
1631
  const f = e + "CollectionItemSlot", p = "data-radix-collection-item", g = /* @__PURE__ */ vt(f), w = _e.forwardRef(
1621
- (d, v) => {
1622
- const { scope: b, children: x, ...y } = d, S = _e.useRef(null), E = Z(v, S), T = a(f, b);
1623
- return _e.useEffect(() => (T.itemMap.set(S, { ref: S, ...y }), () => void T.itemMap.delete(S))), /* @__PURE__ */ k(g, { [p]: "", ref: E, children: x });
1632
+ (u, v) => {
1633
+ const { scope: b, children: x, ...y } = u, C = _e.useRef(null), S = Z(v, C), T = a(f, b);
1634
+ return _e.useEffect(() => (T.itemMap.set(C, { ref: C, ...y }), () => void T.itemMap.delete(C))), /* @__PURE__ */ k(g, { [p]: "", ref: S, children: x });
1624
1635
  }
1625
1636
  );
1626
1637
  w.displayName = f;
1627
- function m(d) {
1628
- const v = a(e + "CollectionConsumer", d);
1638
+ function m(u) {
1639
+ const v = a(e + "CollectionConsumer", u);
1629
1640
  return _e.useCallback(() => {
1630
1641
  const x = v.collectionRef.current;
1631
1642
  if (!x) return [];
1632
1643
  const y = Array.from(x.querySelectorAll(`[${p}]`));
1633
1644
  return Array.from(v.itemMap.values()).sort(
1634
- (T, C) => y.indexOf(T.ref.current) - y.indexOf(C.ref.current)
1645
+ (T, E) => y.indexOf(T.ref.current) - y.indexOf(E.ref.current)
1635
1646
  );
1636
1647
  }, [v.collectionRef, v.itemMap]);
1637
1648
  }
@@ -1641,12 +1652,12 @@ function Ja(e) {
1641
1652
  r
1642
1653
  ];
1643
1654
  }
1644
- var ei = u.createContext(void 0);
1645
- function ti(e) {
1646
- const t = u.useContext(ei);
1655
+ var ti = d.createContext(void 0);
1656
+ function ni(e) {
1657
+ const t = d.useContext(ti);
1647
1658
  return e || t || "ltr";
1648
1659
  }
1649
- var ni = [
1660
+ var ri = [
1650
1661
  "a",
1651
1662
  "button",
1652
1663
  "div",
@@ -1664,39 +1675,39 @@ var ni = [
1664
1675
  "span",
1665
1676
  "svg",
1666
1677
  "ul"
1667
- ], K = ni.reduce((e, t) => {
1668
- const n = /* @__PURE__ */ vt(`Primitive.${t}`), r = u.forwardRef((o, a) => {
1678
+ ], X = ri.reduce((e, t) => {
1679
+ const n = /* @__PURE__ */ vt(`Primitive.${t}`), r = d.forwardRef((o, a) => {
1669
1680
  const { asChild: i, ...s } = o, l = i ? n : t;
1670
1681
  return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ k(l, { ...s, ref: a });
1671
1682
  });
1672
1683
  return r.displayName = `Primitive.${t}`, { ...e, [t]: r };
1673
1684
  }, {});
1674
- function ri(e, t) {
1675
- e && u.flushSync(() => e.dispatchEvent(t));
1685
+ function oi(e, t) {
1686
+ e && d.flushSync(() => e.dispatchEvent(t));
1676
1687
  }
1677
1688
  function Ue(e) {
1678
- const t = u.useRef(e);
1679
- return u.useEffect(() => {
1689
+ const t = d.useRef(e);
1690
+ return d.useEffect(() => {
1680
1691
  t.current = e;
1681
- }), u.useMemo(() => (...n) => {
1692
+ }), d.useMemo(() => (...n) => {
1682
1693
  var r;
1683
1694
  return (r = t.current) == null ? void 0 : r.call(t, ...n);
1684
1695
  }, []);
1685
1696
  }
1686
- function oi(e, t = globalThis == null ? void 0 : globalThis.document) {
1697
+ function ai(e, t = globalThis == null ? void 0 : globalThis.document) {
1687
1698
  const n = Ue(e);
1688
- u.useEffect(() => {
1699
+ d.useEffect(() => {
1689
1700
  const r = (o) => {
1690
1701
  o.key === "Escape" && n(o);
1691
1702
  };
1692
1703
  return t.addEventListener("keydown", r, { capture: !0 }), () => t.removeEventListener("keydown", r, { capture: !0 });
1693
1704
  }, [n, t]);
1694
1705
  }
1695
- var ai = "DismissableLayer", sn = "dismissableLayer.update", ii = "dismissableLayer.pointerDownOutside", si = "dismissableLayer.focusOutside", Vn, Ir = u.createContext({
1706
+ var ii = "DismissableLayer", sn = "dismissableLayer.update", si = "dismissableLayer.pointerDownOutside", li = "dismissableLayer.focusOutside", Vn, Ir = d.createContext({
1696
1707
  layers: /* @__PURE__ */ new Set(),
1697
1708
  layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
1698
1709
  branches: /* @__PURE__ */ new Set()
1699
- }), Rr = u.forwardRef(
1710
+ }), Rr = d.forwardRef(
1700
1711
  (e, t) => {
1701
1712
  const {
1702
1713
  disableOutsidePointerEvents: n = !1,
@@ -1706,65 +1717,65 @@ var ai = "DismissableLayer", sn = "dismissableLayer.update", ii = "dismissableLa
1706
1717
  onInteractOutside: i,
1707
1718
  onDismiss: s,
1708
1719
  ...l
1709
- } = e, c = u.useContext(Ir), [f, p] = u.useState(null), g = (f == null ? void 0 : f.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document), [, w] = u.useState({}), m = Z(t, (C) => p(C)), d = Array.from(c.layers), [v] = [...c.layersWithOutsidePointerEventsDisabled].slice(-1), b = d.indexOf(v), x = f ? d.indexOf(f) : -1, y = c.layersWithOutsidePointerEventsDisabled.size > 0, S = x >= b, E = ui((C) => {
1710
- const I = C.target, O = [...c.branches].some((M) => M.contains(I));
1711
- !S || O || (o == null || o(C), i == null || i(C), C.defaultPrevented || s == null || s());
1712
- }, g), T = di((C) => {
1713
- const I = C.target;
1714
- [...c.branches].some((M) => M.contains(I)) || (a == null || a(C), i == null || i(C), C.defaultPrevented || s == null || s());
1720
+ } = e, c = d.useContext(Ir), [f, p] = d.useState(null), g = (f == null ? void 0 : f.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document), [, w] = d.useState({}), m = Z(t, (E) => p(E)), u = Array.from(c.layers), [v] = [...c.layersWithOutsidePointerEventsDisabled].slice(-1), b = u.indexOf(v), x = f ? u.indexOf(f) : -1, y = c.layersWithOutsidePointerEventsDisabled.size > 0, C = x >= b, S = di((E) => {
1721
+ const R = E.target, M = [...c.branches].some((L) => L.contains(R));
1722
+ !C || M || (o == null || o(E), i == null || i(E), E.defaultPrevented || s == null || s());
1723
+ }, g), T = fi((E) => {
1724
+ const R = E.target;
1725
+ [...c.branches].some((L) => L.contains(R)) || (a == null || a(E), i == null || i(E), E.defaultPrevented || s == null || s());
1715
1726
  }, g);
1716
- return oi((C) => {
1717
- x === c.layers.size - 1 && (r == null || r(C), !C.defaultPrevented && s && (C.preventDefault(), s()));
1718
- }, g), u.useEffect(() => {
1727
+ return ai((E) => {
1728
+ x === c.layers.size - 1 && (r == null || r(E), !E.defaultPrevented && s && (E.preventDefault(), s()));
1729
+ }, g), d.useEffect(() => {
1719
1730
  if (f)
1720
1731
  return n && (c.layersWithOutsidePointerEventsDisabled.size === 0 && (Vn = g.body.style.pointerEvents, g.body.style.pointerEvents = "none"), c.layersWithOutsidePointerEventsDisabled.add(f)), c.layers.add(f), $n(), () => {
1721
1732
  n && c.layersWithOutsidePointerEventsDisabled.size === 1 && (g.body.style.pointerEvents = Vn);
1722
1733
  };
1723
- }, [f, g, n, c]), u.useEffect(() => () => {
1734
+ }, [f, g, n, c]), d.useEffect(() => () => {
1724
1735
  f && (c.layers.delete(f), c.layersWithOutsidePointerEventsDisabled.delete(f), $n());
1725
- }, [f, c]), u.useEffect(() => {
1726
- const C = () => w({});
1727
- return document.addEventListener(sn, C), () => document.removeEventListener(sn, C);
1736
+ }, [f, c]), d.useEffect(() => {
1737
+ const E = () => w({});
1738
+ return document.addEventListener(sn, E), () => document.removeEventListener(sn, E);
1728
1739
  }, []), /* @__PURE__ */ k(
1729
- K.div,
1740
+ X.div,
1730
1741
  {
1731
1742
  ...l,
1732
1743
  ref: m,
1733
1744
  style: {
1734
- pointerEvents: y ? S ? "auto" : "none" : void 0,
1745
+ pointerEvents: y ? C ? "auto" : "none" : void 0,
1735
1746
  ...e.style
1736
1747
  },
1737
1748
  onFocusCapture: G(e.onFocusCapture, T.onFocusCapture),
1738
1749
  onBlurCapture: G(e.onBlurCapture, T.onBlurCapture),
1739
1750
  onPointerDownCapture: G(
1740
1751
  e.onPointerDownCapture,
1741
- E.onPointerDownCapture
1752
+ S.onPointerDownCapture
1742
1753
  )
1743
1754
  }
1744
1755
  );
1745
1756
  }
1746
1757
  );
1747
- Rr.displayName = ai;
1748
- var li = "DismissableLayerBranch", ci = u.forwardRef((e, t) => {
1749
- const n = u.useContext(Ir), r = u.useRef(null), o = Z(t, r);
1750
- return u.useEffect(() => {
1758
+ Rr.displayName = ii;
1759
+ var ci = "DismissableLayerBranch", ui = d.forwardRef((e, t) => {
1760
+ const n = d.useContext(Ir), r = d.useRef(null), o = Z(t, r);
1761
+ return d.useEffect(() => {
1751
1762
  const a = r.current;
1752
1763
  if (a)
1753
1764
  return n.branches.add(a), () => {
1754
1765
  n.branches.delete(a);
1755
1766
  };
1756
- }, [n.branches]), /* @__PURE__ */ k(K.div, { ...e, ref: o });
1767
+ }, [n.branches]), /* @__PURE__ */ k(X.div, { ...e, ref: o });
1757
1768
  });
1758
- ci.displayName = li;
1759
- function ui(e, t = globalThis == null ? void 0 : globalThis.document) {
1760
- const n = Ue(e), r = u.useRef(!1), o = u.useRef(() => {
1769
+ ui.displayName = ci;
1770
+ function di(e, t = globalThis == null ? void 0 : globalThis.document) {
1771
+ const n = Ue(e), r = d.useRef(!1), o = d.useRef(() => {
1761
1772
  });
1762
- return u.useEffect(() => {
1773
+ return d.useEffect(() => {
1763
1774
  const a = (s) => {
1764
1775
  if (s.target && !r.current) {
1765
1776
  let l = function() {
1766
1777
  _r(
1767
- ii,
1778
+ si,
1768
1779
  n,
1769
1780
  c,
1770
1781
  { discrete: !0 }
@@ -1786,11 +1797,11 @@ function ui(e, t = globalThis == null ? void 0 : globalThis.document) {
1786
1797
  onPointerDownCapture: () => r.current = !0
1787
1798
  };
1788
1799
  }
1789
- function di(e, t = globalThis == null ? void 0 : globalThis.document) {
1790
- const n = Ue(e), r = u.useRef(!1);
1791
- return u.useEffect(() => {
1800
+ function fi(e, t = globalThis == null ? void 0 : globalThis.document) {
1801
+ const n = Ue(e), r = d.useRef(!1);
1802
+ return d.useEffect(() => {
1792
1803
  const o = (a) => {
1793
- a.target && !r.current && _r(si, n, { originalEvent: a }, {
1804
+ a.target && !r.current && _r(li, n, { originalEvent: a }, {
1794
1805
  discrete: !1
1795
1806
  });
1796
1807
  };
@@ -1806,14 +1817,14 @@ function $n() {
1806
1817
  }
1807
1818
  function _r(e, t, n, { discrete: r }) {
1808
1819
  const o = n.originalEvent.target, a = new CustomEvent(e, { bubbles: !1, cancelable: !0, detail: n });
1809
- t && o.addEventListener(e, t, { once: !0 }), r ? ri(o, a) : o.dispatchEvent(a);
1820
+ t && o.addEventListener(e, t, { once: !0 }), r ? oi(o, a) : o.dispatchEvent(a);
1810
1821
  }
1811
- var Kt = 0;
1812
- function fi() {
1813
- u.useEffect(() => {
1822
+ var Xt = 0;
1823
+ function pi() {
1824
+ d.useEffect(() => {
1814
1825
  const e = document.querySelectorAll("[data-radix-focus-guard]");
1815
- return document.body.insertAdjacentElement("afterbegin", e[0] ?? Wn()), document.body.insertAdjacentElement("beforeend", e[1] ?? Wn()), Kt++, () => {
1816
- Kt === 1 && document.querySelectorAll("[data-radix-focus-guard]").forEach((t) => t.remove()), Kt--;
1826
+ return document.body.insertAdjacentElement("afterbegin", e[0] ?? Wn()), document.body.insertAdjacentElement("beforeend", e[1] ?? Wn()), Xt++, () => {
1827
+ Xt === 1 && document.querySelectorAll("[data-radix-focus-guard]").forEach((t) => t.remove()), Xt--;
1817
1828
  };
1818
1829
  }, []);
1819
1830
  }
@@ -1821,14 +1832,14 @@ function Wn() {
1821
1832
  const e = document.createElement("span");
1822
1833
  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;
1823
1834
  }
1824
- var Gt = "focusScope.autoFocusOnMount", Zt = "focusScope.autoFocusOnUnmount", Un = { bubbles: !1, cancelable: !0 }, pi = "FocusScope", Nr = u.forwardRef((e, t) => {
1835
+ var Gt = "focusScope.autoFocusOnMount", Zt = "focusScope.autoFocusOnUnmount", Un = { bubbles: !1, cancelable: !0 }, hi = "FocusScope", Nr = d.forwardRef((e, t) => {
1825
1836
  const {
1826
1837
  loop: n = !1,
1827
1838
  trapped: r = !1,
1828
1839
  onMountAutoFocus: o,
1829
1840
  onUnmountAutoFocus: a,
1830
1841
  ...i
1831
- } = e, [s, l] = u.useState(null), c = Ue(o), f = Ue(a), p = u.useRef(null), g = Z(t, (d) => l(d)), w = u.useRef({
1842
+ } = e, [s, l] = d.useState(null), c = Ue(o), f = Ue(a), p = d.useRef(null), g = Z(t, (u) => l(u)), w = d.useRef({
1832
1843
  paused: !1,
1833
1844
  pause() {
1834
1845
  this.paused = !0;
@@ -1837,63 +1848,63 @@ var Gt = "focusScope.autoFocusOnMount", Zt = "focusScope.autoFocusOnUnmount", Un
1837
1848
  this.paused = !1;
1838
1849
  }
1839
1850
  }).current;
1840
- u.useEffect(() => {
1851
+ d.useEffect(() => {
1841
1852
  if (r) {
1842
- let d = function(y) {
1853
+ let u = function(y) {
1843
1854
  if (w.paused || !s) return;
1844
- const S = y.target;
1845
- s.contains(S) ? p.current = S : Ne(p.current, { select: !0 });
1855
+ const C = y.target;
1856
+ s.contains(C) ? p.current = C : Ne(p.current, { select: !0 });
1846
1857
  }, v = function(y) {
1847
1858
  if (w.paused || !s) return;
1848
- const S = y.relatedTarget;
1849
- S !== null && (s.contains(S) || Ne(p.current, { select: !0 }));
1859
+ const C = y.relatedTarget;
1860
+ C !== null && (s.contains(C) || Ne(p.current, { select: !0 }));
1850
1861
  }, b = function(y) {
1851
1862
  if (document.activeElement === document.body)
1852
- for (const E of y)
1853
- E.removedNodes.length > 0 && Ne(s);
1863
+ for (const S of y)
1864
+ S.removedNodes.length > 0 && Ne(s);
1854
1865
  };
1855
- document.addEventListener("focusin", d), document.addEventListener("focusout", v);
1866
+ document.addEventListener("focusin", u), document.addEventListener("focusout", v);
1856
1867
  const x = new MutationObserver(b);
1857
1868
  return s && x.observe(s, { childList: !0, subtree: !0 }), () => {
1858
- document.removeEventListener("focusin", d), document.removeEventListener("focusout", v), x.disconnect();
1869
+ document.removeEventListener("focusin", u), document.removeEventListener("focusout", v), x.disconnect();
1859
1870
  };
1860
1871
  }
1861
- }, [r, s, w.paused]), u.useEffect(() => {
1872
+ }, [r, s, w.paused]), d.useEffect(() => {
1862
1873
  if (s) {
1863
1874
  jn.add(w);
1864
- const d = document.activeElement;
1865
- if (!s.contains(d)) {
1875
+ const u = document.activeElement;
1876
+ if (!s.contains(u)) {
1866
1877
  const b = new CustomEvent(Gt, Un);
1867
- s.addEventListener(Gt, c), s.dispatchEvent(b), b.defaultPrevented || (hi(bi(Or(s)), { select: !0 }), document.activeElement === d && Ne(s));
1878
+ s.addEventListener(Gt, c), s.dispatchEvent(b), b.defaultPrevented || (vi(xi(Or(s)), { select: !0 }), document.activeElement === u && Ne(s));
1868
1879
  }
1869
1880
  return () => {
1870
1881
  s.removeEventListener(Gt, c), setTimeout(() => {
1871
1882
  const b = new CustomEvent(Zt, Un);
1872
- s.addEventListener(Zt, f), s.dispatchEvent(b), b.defaultPrevented || Ne(d ?? document.body, { select: !0 }), s.removeEventListener(Zt, f), jn.remove(w);
1883
+ s.addEventListener(Zt, f), s.dispatchEvent(b), b.defaultPrevented || Ne(u ?? document.body, { select: !0 }), s.removeEventListener(Zt, f), jn.remove(w);
1873
1884
  }, 0);
1874
1885
  };
1875
1886
  }
1876
1887
  }, [s, c, f, w]);
1877
- const m = u.useCallback(
1878
- (d) => {
1888
+ const m = d.useCallback(
1889
+ (u) => {
1879
1890
  if (!n && !r || w.paused) return;
1880
- const v = d.key === "Tab" && !d.altKey && !d.ctrlKey && !d.metaKey, b = document.activeElement;
1891
+ const v = u.key === "Tab" && !u.altKey && !u.ctrlKey && !u.metaKey, b = document.activeElement;
1881
1892
  if (v && b) {
1882
- const x = d.currentTarget, [y, S] = vi(x);
1883
- y && S ? !d.shiftKey && b === S ? (d.preventDefault(), n && Ne(y, { select: !0 })) : d.shiftKey && b === y && (d.preventDefault(), n && Ne(S, { select: !0 })) : b === x && d.preventDefault();
1893
+ const x = u.currentTarget, [y, C] = gi(x);
1894
+ y && C ? !u.shiftKey && b === C ? (u.preventDefault(), n && Ne(y, { select: !0 })) : u.shiftKey && b === y && (u.preventDefault(), n && Ne(C, { select: !0 })) : b === x && u.preventDefault();
1884
1895
  }
1885
1896
  },
1886
1897
  [n, r, w.paused]
1887
1898
  );
1888
- return /* @__PURE__ */ k(K.div, { tabIndex: -1, ...i, ref: g, onKeyDown: m });
1899
+ return /* @__PURE__ */ k(X.div, { tabIndex: -1, ...i, ref: g, onKeyDown: m });
1889
1900
  });
1890
- Nr.displayName = pi;
1891
- function hi(e, { select: t = !1 } = {}) {
1901
+ Nr.displayName = hi;
1902
+ function vi(e, { select: t = !1 } = {}) {
1892
1903
  const n = document.activeElement;
1893
1904
  for (const r of e)
1894
1905
  if (Ne(r, { select: t }), document.activeElement !== n) return;
1895
1906
  }
1896
- function vi(e) {
1907
+ function gi(e) {
1897
1908
  const t = Or(e), n = Hn(t, e), r = Hn(t.reverse(), e);
1898
1909
  return [n, r];
1899
1910
  }
@@ -1909,9 +1920,9 @@ function Or(e) {
1909
1920
  }
1910
1921
  function Hn(e, t) {
1911
1922
  for (const n of e)
1912
- if (!gi(n, { upTo: t })) return n;
1923
+ if (!mi(n, { upTo: t })) return n;
1913
1924
  }
1914
- function gi(e, { upTo: t }) {
1925
+ function mi(e, { upTo: t }) {
1915
1926
  if (getComputedStyle(e).visibility === "hidden") return !0;
1916
1927
  for (; e; ) {
1917
1928
  if (t !== void 0 && e === t) return !1;
@@ -1920,17 +1931,17 @@ function gi(e, { upTo: t }) {
1920
1931
  }
1921
1932
  return !1;
1922
1933
  }
1923
- function mi(e) {
1934
+ function wi(e) {
1924
1935
  return e instanceof HTMLInputElement && "select" in e;
1925
1936
  }
1926
1937
  function Ne(e, { select: t = !1 } = {}) {
1927
1938
  if (e && e.focus) {
1928
1939
  const n = document.activeElement;
1929
- e.focus({ preventScroll: !0 }), e !== n && mi(e) && t && e.select();
1940
+ e.focus({ preventScroll: !0 }), e !== n && wi(e) && t && e.select();
1930
1941
  }
1931
1942
  }
1932
- var jn = wi();
1933
- function wi() {
1943
+ var jn = bi();
1944
+ function bi() {
1934
1945
  let e = [];
1935
1946
  return {
1936
1947
  add(t) {
@@ -1947,27 +1958,27 @@ function Yn(e, t) {
1947
1958
  const n = [...e], r = n.indexOf(t);
1948
1959
  return r !== -1 && n.splice(r, 1), n;
1949
1960
  }
1950
- function bi(e) {
1961
+ function xi(e) {
1951
1962
  return e.filter((t) => t.tagName !== "A");
1952
1963
  }
1953
- var te = globalThis != null && globalThis.document ? u.useLayoutEffect : () => {
1954
- }, xi = u[" useId ".trim().toString()] || (() => {
1955
- }), yi = 0;
1964
+ var te = globalThis != null && globalThis.document ? d.useLayoutEffect : () => {
1965
+ }, yi = d[" useId ".trim().toString()] || (() => {
1966
+ }), Ci = 0;
1956
1967
  function Cn(e) {
1957
- const [t, n] = u.useState(xi());
1968
+ const [t, n] = d.useState(yi());
1958
1969
  return te(() => {
1959
- n((r) => r ?? String(yi++));
1970
+ n((r) => r ?? String(Ci++));
1960
1971
  }, [e]), e || (t ? `radix-${t}` : "");
1961
1972
  }
1962
- const Ci = ["top", "right", "bottom", "left"], Le = Math.min, ae = Math.max, Nt = Math.round, Ct = Math.floor, ye = (e) => ({
1973
+ const Si = ["top", "right", "bottom", "left"], Le = Math.min, ae = Math.max, Nt = Math.round, Ct = Math.floor, ye = (e) => ({
1963
1974
  x: e,
1964
1975
  y: e
1965
- }), Si = {
1976
+ }), Ei = {
1966
1977
  left: "right",
1967
1978
  right: "left",
1968
1979
  bottom: "top",
1969
1980
  top: "bottom"
1970
- }, Ei = {
1981
+ }, ki = {
1971
1982
  start: "end",
1972
1983
  end: "start"
1973
1984
  };
@@ -1995,20 +2006,20 @@ function De(e) {
1995
2006
  function kn(e) {
1996
2007
  return Sn(De(e));
1997
2008
  }
1998
- function ki(e, t, n) {
2009
+ function Ti(e, t, n) {
1999
2010
  n === void 0 && (n = !1);
2000
2011
  const r = at(e), o = kn(e), a = En(o);
2001
2012
  let i = o === "x" ? r === (n ? "end" : "start") ? "right" : "left" : r === "start" ? "bottom" : "top";
2002
2013
  return t.reference[a] > t.floating[a] && (i = Ot(i)), [i, Ot(i)];
2003
2014
  }
2004
- function Ti(e) {
2015
+ function Ai(e) {
2005
2016
  const t = Ot(e);
2006
2017
  return [cn(e), t, cn(t)];
2007
2018
  }
2008
2019
  function cn(e) {
2009
- return e.replace(/start|end/g, (t) => Ei[t]);
2020
+ return e.replace(/start|end/g, (t) => ki[t]);
2010
2021
  }
2011
- function Ai(e, t, n) {
2022
+ function Pi(e, t, n) {
2012
2023
  const r = ["left", "right"], o = ["right", "left"], a = ["top", "bottom"], i = ["bottom", "top"];
2013
2024
  switch (e) {
2014
2025
  case "top":
@@ -2021,15 +2032,15 @@ function Ai(e, t, n) {
2021
2032
  return [];
2022
2033
  }
2023
2034
  }
2024
- function Pi(e, t, n, r) {
2035
+ function Ii(e, t, n, r) {
2025
2036
  const o = at(e);
2026
- let a = Ai(Pe(e), n === "start", r);
2037
+ let a = Pi(Pe(e), n === "start", r);
2027
2038
  return o && (a = a.map((i) => i + "-" + o), t && (a = a.concat(a.map(cn)))), a;
2028
2039
  }
2029
2040
  function Ot(e) {
2030
- return e.replace(/left|right|bottom|top/g, (t) => Si[t]);
2041
+ return e.replace(/left|right|bottom|top/g, (t) => Ei[t]);
2031
2042
  }
2032
- function Ii(e) {
2043
+ function Ri(e) {
2033
2044
  return {
2034
2045
  top: 0,
2035
2046
  right: 0,
@@ -2039,7 +2050,7 @@ function Ii(e) {
2039
2050
  };
2040
2051
  }
2041
2052
  function Mr(e) {
2042
- return typeof e != "number" ? Ii(e) : {
2053
+ return typeof e != "number" ? Ri(e) : {
2043
2054
  top: e,
2044
2055
  right: e,
2045
2056
  bottom: e,
@@ -2064,7 +2075,7 @@ function Mt(e) {
2064
2075
  y: n
2065
2076
  };
2066
2077
  }
2067
- function Xn(e, t, n) {
2078
+ function Kn(e, t, n) {
2068
2079
  let {
2069
2080
  reference: r,
2070
2081
  floating: o
@@ -2112,7 +2123,7 @@ function Xn(e, t, n) {
2112
2123
  }
2113
2124
  return w;
2114
2125
  }
2115
- const Ri = async (e, t, n) => {
2126
+ const _i = async (e, t, n) => {
2116
2127
  const {
2117
2128
  placement: r = "bottom",
2118
2129
  strategy: o = "absolute",
@@ -2126,16 +2137,16 @@ const Ri = async (e, t, n) => {
2126
2137
  }), {
2127
2138
  x: f,
2128
2139
  y: p
2129
- } = Xn(c, r, l), g = r, w = {}, m = 0;
2130
- for (let d = 0; d < s.length; d++) {
2140
+ } = Kn(c, r, l), g = r, w = {}, m = 0;
2141
+ for (let u = 0; u < s.length; u++) {
2131
2142
  const {
2132
2143
  name: v,
2133
2144
  fn: b
2134
- } = s[d], {
2145
+ } = s[u], {
2135
2146
  x,
2136
2147
  y,
2137
- data: S,
2138
- reset: E
2148
+ data: C,
2149
+ reset: S
2139
2150
  } = await b({
2140
2151
  x: f,
2141
2152
  y: p,
@@ -2154,16 +2165,16 @@ const Ri = async (e, t, n) => {
2154
2165
  ...w,
2155
2166
  [v]: {
2156
2167
  ...w[v],
2157
- ...S
2168
+ ...C
2158
2169
  }
2159
- }, E && m <= 50 && (m++, typeof E == "object" && (E.placement && (g = E.placement), E.rects && (c = E.rects === !0 ? await i.getElementRects({
2170
+ }, S && m <= 50 && (m++, typeof S == "object" && (S.placement && (g = S.placement), S.rects && (c = S.rects === !0 ? await i.getElementRects({
2160
2171
  reference: e,
2161
2172
  floating: t,
2162
2173
  strategy: o
2163
- }) : E.rects), {
2174
+ }) : S.rects), {
2164
2175
  x: f,
2165
2176
  y: p
2166
- } = Xn(c, g, l)), d = -1);
2177
+ } = Kn(c, g, l)), u = -1);
2167
2178
  }
2168
2179
  return {
2169
2180
  x: f,
@@ -2199,26 +2210,26 @@ async function gt(e, t) {
2199
2210
  y: o,
2200
2211
  width: i.floating.width,
2201
2212
  height: i.floating.height
2202
- } : i.reference, y = await (a.getOffsetParent == null ? void 0 : a.getOffsetParent(s.floating)), S = await (a.isElement == null ? void 0 : a.isElement(y)) ? await (a.getScale == null ? void 0 : a.getScale(y)) || {
2213
+ } : i.reference, y = await (a.getOffsetParent == null ? void 0 : a.getOffsetParent(s.floating)), C = await (a.isElement == null ? void 0 : a.isElement(y)) ? await (a.getScale == null ? void 0 : a.getScale(y)) || {
2203
2214
  x: 1,
2204
2215
  y: 1
2205
2216
  } : {
2206
2217
  x: 1,
2207
2218
  y: 1
2208
- }, E = Mt(a.convertOffsetParentRelativeRectToViewportRelativeRect ? await a.convertOffsetParentRelativeRectToViewportRelativeRect({
2219
+ }, S = Mt(a.convertOffsetParentRelativeRectToViewportRelativeRect ? await a.convertOffsetParentRelativeRectToViewportRelativeRect({
2209
2220
  elements: s,
2210
2221
  rect: x,
2211
2222
  offsetParent: y,
2212
2223
  strategy: l
2213
2224
  }) : x);
2214
2225
  return {
2215
- top: (b.top - E.top + m.top) / S.y,
2216
- bottom: (E.bottom - b.bottom + m.bottom) / S.y,
2217
- left: (b.left - E.left + m.left) / S.x,
2218
- right: (E.right - b.right + m.right) / S.x
2226
+ top: (b.top - S.top + m.top) / C.y,
2227
+ bottom: (S.bottom - b.bottom + m.bottom) / C.y,
2228
+ left: (b.left - S.left + m.left) / C.x,
2229
+ right: (S.right - b.right + m.right) / C.x
2219
2230
  };
2220
2231
  }
2221
- const _i = (e) => ({
2232
+ const Ni = (e) => ({
2222
2233
  name: "arrow",
2223
2234
  options: e,
2224
2235
  async fn(t) {
@@ -2239,23 +2250,23 @@ const _i = (e) => ({
2239
2250
  const p = Mr(f), g = {
2240
2251
  x: n,
2241
2252
  y: r
2242
- }, w = kn(o), m = En(w), d = await i.getDimensions(c), v = w === "y", b = v ? "top" : "left", x = v ? "bottom" : "right", y = v ? "clientHeight" : "clientWidth", S = a.reference[m] + a.reference[w] - g[w] - a.floating[m], E = g[w] - a.reference[w], T = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(c));
2243
- let C = T ? T[y] : 0;
2244
- (!C || !await (i.isElement == null ? void 0 : i.isElement(T))) && (C = s.floating[y] || a.floating[m]);
2245
- const I = S / 2 - E / 2, O = C / 2 - d[m] / 2 - 1, M = Le(p[b], O), V = Le(p[x], O), $ = M, D = C - d[m] - V, N = C / 2 - d[m] / 2 + I, X = ln($, N, D), _ = !l.arrow && at(o) != null && N !== X && a.reference[m] / 2 - (N < $ ? M : V) - d[m] / 2 < 0, L = _ ? N < $ ? N - $ : N - D : 0;
2253
+ }, w = kn(o), m = En(w), u = await i.getDimensions(c), v = w === "y", b = v ? "top" : "left", x = v ? "bottom" : "right", y = v ? "clientHeight" : "clientWidth", C = a.reference[m] + a.reference[w] - g[w] - a.floating[m], S = g[w] - a.reference[w], T = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(c));
2254
+ let E = T ? T[y] : 0;
2255
+ (!E || !await (i.isElement == null ? void 0 : i.isElement(T))) && (E = s.floating[y] || a.floating[m]);
2256
+ const R = C / 2 - S / 2, M = E / 2 - u[m] / 2 - 1, L = Le(p[b], M), N = Le(p[x], M), A = L, D = E - u[m] - N, B = E / 2 - u[m] / 2 + R, K = ln(A, B, D), O = !l.arrow && at(o) != null && B !== K && a.reference[m] / 2 - (B < A ? L : N) - u[m] / 2 < 0, z = O ? B < A ? B - A : B - D : 0;
2246
2257
  return {
2247
- [w]: g[w] + L,
2258
+ [w]: g[w] + z,
2248
2259
  data: {
2249
- [w]: X,
2250
- centerOffset: N - X - L,
2251
- ..._ && {
2252
- alignmentOffset: L
2260
+ [w]: K,
2261
+ centerOffset: B - K - z,
2262
+ ...O && {
2263
+ alignmentOffset: z
2253
2264
  }
2254
2265
  },
2255
- reset: _
2266
+ reset: O
2256
2267
  };
2257
2268
  }
2258
- }), Ni = function(e) {
2269
+ }), Oi = function(e) {
2259
2270
  return e === void 0 && (e = {}), {
2260
2271
  name: "flip",
2261
2272
  options: e,
@@ -2274,60 +2285,60 @@ const _i = (e) => ({
2274
2285
  fallbackPlacements: g,
2275
2286
  fallbackStrategy: w = "bestFit",
2276
2287
  fallbackAxisSideDirection: m = "none",
2277
- flipAlignment: d = !0,
2288
+ flipAlignment: u = !0,
2278
2289
  ...v
2279
2290
  } = Ae(e, t);
2280
2291
  if ((n = a.arrow) != null && n.alignmentOffset)
2281
2292
  return {};
2282
- const b = Pe(o), x = De(s), y = Pe(s) === s, S = await (l.isRTL == null ? void 0 : l.isRTL(c.floating)), E = g || (y || !d ? [Ot(s)] : Ti(s)), T = m !== "none";
2283
- !g && T && E.push(...Pi(s, d, m, S));
2284
- const C = [s, ...E], I = await gt(t, v), O = [];
2285
- let M = ((r = a.flip) == null ? void 0 : r.overflows) || [];
2286
- if (f && O.push(I[b]), p) {
2287
- const N = ki(o, i, S);
2288
- O.push(I[N[0]], I[N[1]]);
2293
+ const b = Pe(o), x = De(s), y = Pe(s) === s, C = await (l.isRTL == null ? void 0 : l.isRTL(c.floating)), S = g || (y || !u ? [Ot(s)] : Ai(s)), T = m !== "none";
2294
+ !g && T && S.push(...Ii(s, u, m, C));
2295
+ const E = [s, ...S], R = await gt(t, v), M = [];
2296
+ let L = ((r = a.flip) == null ? void 0 : r.overflows) || [];
2297
+ if (f && M.push(R[b]), p) {
2298
+ const B = Ti(o, i, C);
2299
+ M.push(R[B[0]], R[B[1]]);
2289
2300
  }
2290
- if (M = [...M, {
2301
+ if (L = [...L, {
2291
2302
  placement: o,
2292
- overflows: O
2293
- }], !O.every((N) => N <= 0)) {
2294
- var V, $;
2295
- const N = (((V = a.flip) == null ? void 0 : V.index) || 0) + 1, X = C[N];
2296
- if (X)
2303
+ overflows: M
2304
+ }], !M.every((B) => B <= 0)) {
2305
+ var N, A;
2306
+ const B = (((N = a.flip) == null ? void 0 : N.index) || 0) + 1, K = E[B];
2307
+ if (K)
2297
2308
  return {
2298
2309
  data: {
2299
- index: N,
2300
- overflows: M
2310
+ index: B,
2311
+ overflows: L
2301
2312
  },
2302
2313
  reset: {
2303
- placement: X
2314
+ placement: K
2304
2315
  }
2305
2316
  };
2306
- let _ = ($ = M.filter((L) => L.overflows[0] <= 0).sort((L, R) => L.overflows[1] - R.overflows[1])[0]) == null ? void 0 : $.placement;
2307
- if (!_)
2317
+ let O = (A = L.filter((z) => z.overflows[0] <= 0).sort((z, _) => z.overflows[1] - _.overflows[1])[0]) == null ? void 0 : A.placement;
2318
+ if (!O)
2308
2319
  switch (w) {
2309
2320
  case "bestFit": {
2310
2321
  var D;
2311
- const L = (D = M.filter((R) => {
2322
+ const z = (D = L.filter((_) => {
2312
2323
  if (T) {
2313
- const W = De(R.placement);
2314
- return W === x || // Create a bias to the `y` side axis due to horizontal
2324
+ const U = De(_.placement);
2325
+ return U === x || // Create a bias to the `y` side axis due to horizontal
2315
2326
  // reading directions favoring greater width.
2316
- W === "y";
2327
+ U === "y";
2317
2328
  }
2318
2329
  return !0;
2319
- }).map((R) => [R.placement, R.overflows.filter((W) => W > 0).reduce((W, ee) => W + ee, 0)]).sort((R, W) => R[1] - W[1])[0]) == null ? void 0 : D[0];
2320
- L && (_ = L);
2330
+ }).map((_) => [_.placement, _.overflows.filter((U) => U > 0).reduce((U, ee) => U + ee, 0)]).sort((_, U) => _[1] - U[1])[0]) == null ? void 0 : D[0];
2331
+ z && (O = z);
2321
2332
  break;
2322
2333
  }
2323
2334
  case "initialPlacement":
2324
- _ = s;
2335
+ O = s;
2325
2336
  break;
2326
2337
  }
2327
- if (o !== _)
2338
+ if (o !== O)
2328
2339
  return {
2329
2340
  reset: {
2330
- placement: _
2341
+ placement: O
2331
2342
  }
2332
2343
  };
2333
2344
  }
@@ -2335,7 +2346,7 @@ const _i = (e) => ({
2335
2346
  }
2336
2347
  };
2337
2348
  };
2338
- function Kn(e, t) {
2349
+ function Xn(e, t) {
2339
2350
  return {
2340
2351
  top: e.top - t.height,
2341
2352
  right: e.right - t.width,
@@ -2344,9 +2355,9 @@ function Kn(e, t) {
2344
2355
  };
2345
2356
  }
2346
2357
  function Gn(e) {
2347
- return Ci.some((t) => e[t] >= 0);
2358
+ return Si.some((t) => e[t] >= 0);
2348
2359
  }
2349
- const Oi = function(e) {
2360
+ const Mi = function(e) {
2350
2361
  return e === void 0 && (e = {}), {
2351
2362
  name: "hide",
2352
2363
  options: e,
@@ -2362,7 +2373,7 @@ const Oi = function(e) {
2362
2373
  const a = await gt(t, {
2363
2374
  ...o,
2364
2375
  elementContext: "reference"
2365
- }), i = Kn(a, n.reference);
2376
+ }), i = Xn(a, n.reference);
2366
2377
  return {
2367
2378
  data: {
2368
2379
  referenceHiddenOffsets: i,
@@ -2374,7 +2385,7 @@ const Oi = function(e) {
2374
2385
  const a = await gt(t, {
2375
2386
  ...o,
2376
2387
  altBoundary: !0
2377
- }), i = Kn(a, n.floating);
2388
+ }), i = Xn(a, n.floating);
2378
2389
  return {
2379
2390
  data: {
2380
2391
  escapedOffsets: i,
@@ -2388,7 +2399,7 @@ const Oi = function(e) {
2388
2399
  }
2389
2400
  };
2390
2401
  };
2391
- async function Mi(e, t) {
2402
+ async function Li(e, t) {
2392
2403
  const {
2393
2404
  placement: n,
2394
2405
  platform: r,
@@ -2415,7 +2426,7 @@ async function Mi(e, t) {
2415
2426
  y: w * f
2416
2427
  };
2417
2428
  }
2418
- const Li = function(e) {
2429
+ const Di = function(e) {
2419
2430
  return e === void 0 && (e = 0), {
2420
2431
  name: "offset",
2421
2432
  options: e,
@@ -2426,7 +2437,7 @@ const Li = function(e) {
2426
2437
  y: a,
2427
2438
  placement: i,
2428
2439
  middlewareData: s
2429
- } = t, l = await Mi(t, e);
2440
+ } = t, l = await Li(t, e);
2430
2441
  return i === ((n = s.offset) == null ? void 0 : n.placement) && (r = s.arrow) != null && r.alignmentOffset ? {} : {
2431
2442
  x: o + l.x,
2432
2443
  y: a + l.y,
@@ -2437,7 +2448,7 @@ const Li = function(e) {
2437
2448
  };
2438
2449
  }
2439
2450
  };
2440
- }, Di = function(e) {
2451
+ }, Bi = function(e) {
2441
2452
  return e === void 0 && (e = {}), {
2442
2453
  name: "shift",
2443
2454
  options: e,
@@ -2475,16 +2486,16 @@ const Li = function(e) {
2475
2486
  const v = p === "y" ? "top" : "left", b = p === "y" ? "bottom" : "right", x = m + f[v], y = m - f[b];
2476
2487
  m = ln(x, m, y);
2477
2488
  }
2478
- const d = s.fn({
2489
+ const u = s.fn({
2479
2490
  ...t,
2480
2491
  [g]: w,
2481
2492
  [p]: m
2482
2493
  });
2483
2494
  return {
2484
- ...d,
2495
+ ...u,
2485
2496
  data: {
2486
- x: d.x - n,
2487
- y: d.y - r,
2497
+ x: u.x - n,
2498
+ y: u.y - r,
2488
2499
  enabled: {
2489
2500
  [g]: a,
2490
2501
  [p]: i
@@ -2493,7 +2504,7 @@ const Li = function(e) {
2493
2504
  };
2494
2505
  }
2495
2506
  };
2496
- }, Bi = function(e) {
2507
+ }, zi = function(e) {
2497
2508
  return e === void 0 && (e = {}), {
2498
2509
  options: e,
2499
2510
  fn(t) {
@@ -2512,22 +2523,22 @@ const Li = function(e) {
2512
2523
  y: r
2513
2524
  }, p = De(o), g = Sn(p);
2514
2525
  let w = f[g], m = f[p];
2515
- const d = Ae(s, t), v = typeof d == "number" ? {
2516
- mainAxis: d,
2526
+ const u = Ae(s, t), v = typeof u == "number" ? {
2527
+ mainAxis: u,
2517
2528
  crossAxis: 0
2518
2529
  } : {
2519
2530
  mainAxis: 0,
2520
2531
  crossAxis: 0,
2521
- ...d
2532
+ ...u
2522
2533
  };
2523
2534
  if (l) {
2524
- const y = g === "y" ? "height" : "width", S = a.reference[g] - a.floating[y] + v.mainAxis, E = a.reference[g] + a.reference[y] - v.mainAxis;
2525
- w < S ? w = S : w > E && (w = E);
2535
+ const y = g === "y" ? "height" : "width", C = a.reference[g] - a.floating[y] + v.mainAxis, S = a.reference[g] + a.reference[y] - v.mainAxis;
2536
+ w < C ? w = C : w > S && (w = S);
2526
2537
  }
2527
2538
  if (c) {
2528
2539
  var b, x;
2529
- const y = g === "y" ? "width" : "height", S = ["top", "left"].includes(Pe(o)), E = a.reference[p] - a.floating[y] + (S && ((b = i.offset) == null ? void 0 : b[p]) || 0) + (S ? 0 : v.crossAxis), T = a.reference[p] + a.reference[y] + (S ? 0 : ((x = i.offset) == null ? void 0 : x[p]) || 0) - (S ? v.crossAxis : 0);
2530
- m < E ? m = E : m > T && (m = T);
2540
+ const y = g === "y" ? "width" : "height", C = ["top", "left"].includes(Pe(o)), S = a.reference[p] - a.floating[y] + (C && ((b = i.offset) == null ? void 0 : b[p]) || 0) + (C ? 0 : v.crossAxis), T = a.reference[p] + a.reference[y] + (C ? 0 : ((x = i.offset) == null ? void 0 : x[p]) || 0) - (C ? v.crossAxis : 0);
2541
+ m < S ? m = S : m > T && (m = T);
2531
2542
  }
2532
2543
  return {
2533
2544
  [g]: w,
@@ -2535,7 +2546,7 @@ const Li = function(e) {
2535
2546
  };
2536
2547
  }
2537
2548
  };
2538
- }, zi = function(e) {
2549
+ }, Fi = function(e) {
2539
2550
  return e === void 0 && (e = {}), {
2540
2551
  name: "size",
2541
2552
  options: e,
@@ -2552,23 +2563,23 @@ const Li = function(e) {
2552
2563
  ...c
2553
2564
  } = Ae(e, t), f = await gt(t, c), p = Pe(o), g = at(o), w = De(o) === "y", {
2554
2565
  width: m,
2555
- height: d
2566
+ height: u
2556
2567
  } = a.floating;
2557
2568
  let v, b;
2558
2569
  p === "top" || p === "bottom" ? (v = p, b = g === (await (i.isRTL == null ? void 0 : i.isRTL(s.floating)) ? "start" : "end") ? "left" : "right") : (b = p, v = g === "end" ? "top" : "bottom");
2559
- const x = d - f.top - f.bottom, y = m - f.left - f.right, S = Le(d - f[v], x), E = Le(m - f[b], y), T = !t.middlewareData.shift;
2560
- let C = S, I = E;
2561
- if ((n = t.middlewareData.shift) != null && n.enabled.x && (I = y), (r = t.middlewareData.shift) != null && r.enabled.y && (C = x), T && !g) {
2562
- const M = ae(f.left, 0), V = ae(f.right, 0), $ = ae(f.top, 0), D = ae(f.bottom, 0);
2563
- w ? I = m - 2 * (M !== 0 || V !== 0 ? M + V : ae(f.left, f.right)) : C = d - 2 * ($ !== 0 || D !== 0 ? $ + D : ae(f.top, f.bottom));
2570
+ const x = u - f.top - f.bottom, y = m - f.left - f.right, C = Le(u - f[v], x), S = Le(m - f[b], y), T = !t.middlewareData.shift;
2571
+ let E = C, R = S;
2572
+ if ((n = t.middlewareData.shift) != null && n.enabled.x && (R = y), (r = t.middlewareData.shift) != null && r.enabled.y && (E = x), T && !g) {
2573
+ const L = ae(f.left, 0), N = ae(f.right, 0), A = ae(f.top, 0), D = ae(f.bottom, 0);
2574
+ w ? R = m - 2 * (L !== 0 || N !== 0 ? L + N : ae(f.left, f.right)) : E = u - 2 * (A !== 0 || D !== 0 ? A + D : ae(f.top, f.bottom));
2564
2575
  }
2565
2576
  await l({
2566
2577
  ...t,
2567
- availableWidth: I,
2568
- availableHeight: C
2578
+ availableWidth: R,
2579
+ availableHeight: E
2569
2580
  });
2570
- const O = await i.getDimensions(s.floating);
2571
- return m !== O.width || d !== O.height ? {
2581
+ const M = await i.getDimensions(s.floating);
2582
+ return m !== M.width || u !== M.height ? {
2572
2583
  reset: {
2573
2584
  rects: !0
2574
2585
  }
@@ -2611,7 +2622,7 @@ function bt(e) {
2611
2622
  } = pe(e);
2612
2623
  return /auto|scroll|overlay|hidden|clip/.test(t + r + n) && !["inline", "contents"].includes(o);
2613
2624
  }
2614
- function Fi(e) {
2625
+ function Vi(e) {
2615
2626
  return ["table", "td", "th"].includes(it(e));
2616
2627
  }
2617
2628
  function Vt(e) {
@@ -2627,7 +2638,7 @@ function Tn(e) {
2627
2638
  const t = An(), n = fe(e) ? pe(e) : e;
2628
2639
  return ["transform", "translate", "scale", "rotate", "perspective"].some((r) => n[r] ? n[r] !== "none" : !1) || (n.containerType ? n.containerType !== "normal" : !1) || !t && (n.backdropFilter ? n.backdropFilter !== "none" : !1) || !t && (n.filter ? n.filter !== "none" : !1) || ["transform", "translate", "scale", "rotate", "perspective", "filter"].some((r) => (n.willChange || "").includes(r)) || ["paint", "layout", "strict", "content"].some((r) => (n.contain || "").includes(r));
2629
2640
  }
2630
- function Vi(e) {
2641
+ function $i(e) {
2631
2642
  let t = Be(e);
2632
2643
  for (; Ce(t) && !nt(t); ) {
2633
2644
  if (Tn(t))
@@ -2713,15 +2724,15 @@ function et(e) {
2713
2724
  y: s
2714
2725
  };
2715
2726
  }
2716
- const $i = /* @__PURE__ */ ye(0);
2727
+ const Wi = /* @__PURE__ */ ye(0);
2717
2728
  function zr(e) {
2718
2729
  const t = ie(e);
2719
- return !An() || !t.visualViewport ? $i : {
2730
+ return !An() || !t.visualViewport ? Wi : {
2720
2731
  x: t.visualViewport.offsetLeft,
2721
2732
  y: t.visualViewport.offsetTop
2722
2733
  };
2723
2734
  }
2724
- function Wi(e, t, n) {
2735
+ function Ui(e, t, n) {
2725
2736
  return t === void 0 && (t = !1), !n || t && n !== ie(e) ? !1 : t;
2726
2737
  }
2727
2738
  function He(e, t, n, r) {
@@ -2729,14 +2740,14 @@ function He(e, t, n, r) {
2729
2740
  const o = e.getBoundingClientRect(), a = Pn(e);
2730
2741
  let i = ye(1);
2731
2742
  t && (r ? fe(r) && (i = et(r)) : i = et(e));
2732
- const s = Wi(a, n, r) ? zr(a) : ye(0);
2743
+ const s = Ui(a, n, r) ? zr(a) : ye(0);
2733
2744
  let l = (o.left + s.x) / i.x, c = (o.top + s.y) / i.y, f = o.width / i.x, p = o.height / i.y;
2734
2745
  if (a) {
2735
2746
  const g = ie(a), w = r && fe(r) ? ie(r) : r;
2736
- let m = g, d = un(m);
2737
- for (; d && r && w !== m; ) {
2738
- const v = et(d), b = d.getBoundingClientRect(), x = pe(d), y = b.left + (d.clientLeft + parseFloat(x.paddingLeft)) * v.x, S = b.top + (d.clientTop + parseFloat(x.paddingTop)) * v.y;
2739
- l *= v.x, c *= v.y, f *= v.x, p *= v.y, l += y, c += S, m = ie(d), d = un(m);
2747
+ let m = g, u = un(m);
2748
+ for (; u && r && w !== m; ) {
2749
+ const v = et(u), b = u.getBoundingClientRect(), x = pe(u), y = b.left + (u.clientLeft + parseFloat(x.paddingLeft)) * v.x, C = b.top + (u.clientTop + parseFloat(x.paddingTop)) * v.y;
2750
+ l *= v.x, c *= v.y, f *= v.x, p *= v.y, l += y, c += C, m = ie(u), u = un(m);
2740
2751
  }
2741
2752
  }
2742
2753
  return Mt({
@@ -2761,7 +2772,7 @@ function Fr(e, t, n) {
2761
2772
  y: a
2762
2773
  };
2763
2774
  }
2764
- function Ui(e) {
2775
+ function Hi(e) {
2765
2776
  let {
2766
2777
  elements: t,
2767
2778
  rect: n,
@@ -2788,10 +2799,10 @@ function Ui(e) {
2788
2799
  y: n.y * c.y - l.scrollTop * c.y + f.y + g.y
2789
2800
  };
2790
2801
  }
2791
- function Hi(e) {
2802
+ function ji(e) {
2792
2803
  return Array.from(e.getClientRects());
2793
2804
  }
2794
- function ji(e) {
2805
+ function Yi(e) {
2795
2806
  const t = Se(e), n = $t(e), r = e.ownerDocument.body, o = ae(t.scrollWidth, t.clientWidth, r.scrollWidth, r.clientWidth), a = ae(t.scrollHeight, t.clientHeight, r.scrollHeight, r.clientHeight);
2796
2807
  let i = -n.scrollLeft + In(e);
2797
2808
  const s = -n.scrollTop;
@@ -2802,7 +2813,7 @@ function ji(e) {
2802
2813
  y: s
2803
2814
  };
2804
2815
  }
2805
- function Yi(e, t) {
2816
+ function Ki(e, t) {
2806
2817
  const n = ie(e), r = Se(e), o = n.visualViewport;
2807
2818
  let a = r.clientWidth, i = r.clientHeight, s = 0, l = 0;
2808
2819
  if (o) {
@@ -2829,9 +2840,9 @@ function Xi(e, t) {
2829
2840
  function qn(e, t, n) {
2830
2841
  let r;
2831
2842
  if (t === "viewport")
2832
- r = Yi(e, n);
2843
+ r = Ki(e, n);
2833
2844
  else if (t === "document")
2834
- r = ji(Se(e));
2845
+ r = Yi(Se(e));
2835
2846
  else if (fe(t))
2836
2847
  r = Xi(t, n);
2837
2848
  else {
@@ -2849,7 +2860,7 @@ function Vr(e, t) {
2849
2860
  const n = Be(e);
2850
2861
  return n === t || !fe(n) || nt(n) ? !1 : pe(n).position === "fixed" || Vr(n, t);
2851
2862
  }
2852
- function Ki(e, t) {
2863
+ function Gi(e, t) {
2853
2864
  const n = t.get(e);
2854
2865
  if (n)
2855
2866
  return n;
@@ -2862,14 +2873,14 @@ function Ki(e, t) {
2862
2873
  }
2863
2874
  return t.set(e, r), r;
2864
2875
  }
2865
- function Gi(e) {
2876
+ function Zi(e) {
2866
2877
  let {
2867
2878
  element: t,
2868
2879
  boundary: n,
2869
2880
  rootBoundary: r,
2870
2881
  strategy: o
2871
2882
  } = e;
2872
- const i = [...n === "clippingAncestors" ? Vt(t) ? [] : Ki(t, this._c) : [].concat(n), r], s = i[0], l = i.reduce((c, f) => {
2883
+ const i = [...n === "clippingAncestors" ? Vt(t) ? [] : Gi(t, this._c) : [].concat(n), r], s = i[0], l = i.reduce((c, f) => {
2873
2884
  const p = qn(t, f, o);
2874
2885
  return c.top = ae(p.top, c.top), c.right = Le(p.right, c.right), c.bottom = Le(p.bottom, c.bottom), c.left = ae(p.left, c.left), c;
2875
2886
  }, qn(t, s, o));
@@ -2880,7 +2891,7 @@ function Gi(e) {
2880
2891
  y: l.top
2881
2892
  };
2882
2893
  }
2883
- function Zi(e) {
2894
+ function qi(e) {
2884
2895
  const {
2885
2896
  width: t,
2886
2897
  height: n
@@ -2890,7 +2901,7 @@ function Zi(e) {
2890
2901
  height: n
2891
2902
  };
2892
2903
  }
2893
- function qi(e, t, n) {
2904
+ function Qi(e, t, n) {
2894
2905
  const r = Ce(t), o = Se(t), a = n === "fixed", i = He(e, !0, a, t);
2895
2906
  let s = {
2896
2907
  scrollLeft: 0,
@@ -2935,14 +2946,14 @@ function $r(e, t) {
2935
2946
  return n;
2936
2947
  }
2937
2948
  let r = Qn(e, t);
2938
- for (; r && Fi(r) && qt(r); )
2949
+ for (; r && Vi(r) && qt(r); )
2939
2950
  r = Qn(r, t);
2940
- return r && nt(r) && qt(r) && !Tn(r) ? n : r || Vi(e) || n;
2951
+ return r && nt(r) && qt(r) && !Tn(r) ? n : r || $i(e) || n;
2941
2952
  }
2942
- const Qi = async function(e) {
2953
+ const Ji = async function(e) {
2943
2954
  const t = this.getOffsetParent || $r, n = this.getDimensions, r = await n(e.floating);
2944
2955
  return {
2945
- reference: qi(e.reference, await t(e.floating), e.strategy),
2956
+ reference: Qi(e.reference, await t(e.floating), e.strategy),
2946
2957
  floating: {
2947
2958
  x: 0,
2948
2959
  y: 0,
@@ -2951,25 +2962,25 @@ const Qi = async function(e) {
2951
2962
  }
2952
2963
  };
2953
2964
  };
2954
- function Ji(e) {
2965
+ function es(e) {
2955
2966
  return pe(e).direction === "rtl";
2956
2967
  }
2957
- const es = {
2958
- convertOffsetParentRelativeRectToViewportRelativeRect: Ui,
2968
+ const ts = {
2969
+ convertOffsetParentRelativeRectToViewportRelativeRect: Hi,
2959
2970
  getDocumentElement: Se,
2960
- getClippingRect: Gi,
2971
+ getClippingRect: Zi,
2961
2972
  getOffsetParent: $r,
2962
- getElementRects: Qi,
2963
- getClientRects: Hi,
2964
- getDimensions: Zi,
2973
+ getElementRects: Ji,
2974
+ getClientRects: ji,
2975
+ getDimensions: qi,
2965
2976
  getScale: et,
2966
2977
  isElement: fe,
2967
- isRTL: Ji
2978
+ isRTL: es
2968
2979
  };
2969
2980
  function Wr(e, t) {
2970
2981
  return e.x === t.x && e.y === t.y && e.width === t.width && e.height === t.height;
2971
2982
  }
2972
- function ts(e, t) {
2983
+ function ns(e, t) {
2973
2984
  let n = null, r;
2974
2985
  const o = Se(e);
2975
2986
  function a() {
@@ -2986,36 +2997,36 @@ function ts(e, t) {
2986
2997
  } = c;
2987
2998
  if (s || t(), !g || !w)
2988
2999
  return;
2989
- const m = Ct(p), d = Ct(o.clientWidth - (f + g)), v = Ct(o.clientHeight - (p + w)), b = Ct(f), y = {
2990
- rootMargin: -m + "px " + -d + "px " + -v + "px " + -b + "px",
3000
+ const m = Ct(p), u = Ct(o.clientWidth - (f + g)), v = Ct(o.clientHeight - (p + w)), b = Ct(f), y = {
3001
+ rootMargin: -m + "px " + -u + "px " + -v + "px " + -b + "px",
2991
3002
  threshold: ae(0, Le(1, l)) || 1
2992
3003
  };
2993
- let S = !0;
2994
- function E(T) {
2995
- const C = T[0].intersectionRatio;
2996
- if (C !== l) {
2997
- if (!S)
3004
+ let C = !0;
3005
+ function S(T) {
3006
+ const E = T[0].intersectionRatio;
3007
+ if (E !== l) {
3008
+ if (!C)
2998
3009
  return i();
2999
- C ? i(!1, C) : r = setTimeout(() => {
3010
+ E ? i(!1, E) : r = setTimeout(() => {
3000
3011
  i(!1, 1e-7);
3001
3012
  }, 1e3);
3002
3013
  }
3003
- C === 1 && !Wr(c, e.getBoundingClientRect()) && i(), S = !1;
3014
+ E === 1 && !Wr(c, e.getBoundingClientRect()) && i(), C = !1;
3004
3015
  }
3005
3016
  try {
3006
- n = new IntersectionObserver(E, {
3017
+ n = new IntersectionObserver(S, {
3007
3018
  ...y,
3008
3019
  // Handle <iframe>s
3009
3020
  root: o.ownerDocument
3010
3021
  });
3011
3022
  } catch {
3012
- n = new IntersectionObserver(E, y);
3023
+ n = new IntersectionObserver(S, y);
3013
3024
  }
3014
3025
  n.observe(e);
3015
3026
  }
3016
3027
  return i(!0), a;
3017
3028
  }
3018
- function ns(e, t, n, r) {
3029
+ function rs(e, t, n, r) {
3019
3030
  r === void 0 && (r = {});
3020
3031
  const {
3021
3032
  ancestorScroll: o = !0,
@@ -3029,7 +3040,7 @@ function ns(e, t, n, r) {
3029
3040
  passive: !0
3030
3041
  }), a && b.addEventListener("resize", n);
3031
3042
  });
3032
- const p = c && s ? ts(c, n) : null;
3043
+ const p = c && s ? ns(c, n) : null;
3033
3044
  let g = -1, w = null;
3034
3045
  i && (w = new ResizeObserver((b) => {
3035
3046
  let [x] = b;
@@ -3038,11 +3049,11 @@ function ns(e, t, n, r) {
3038
3049
  (y = w) == null || y.observe(t);
3039
3050
  })), n();
3040
3051
  }), c && !l && w.observe(c), w.observe(t));
3041
- let m, d = l ? He(e) : null;
3052
+ let m, u = l ? He(e) : null;
3042
3053
  l && v();
3043
3054
  function v() {
3044
3055
  const b = He(e);
3045
- d && !Wr(d, b) && n(), d = b, m = requestAnimationFrame(v);
3056
+ u && !Wr(u, b) && n(), u = b, m = requestAnimationFrame(v);
3046
3057
  }
3047
3058
  return n(), () => {
3048
3059
  var b;
@@ -3051,15 +3062,15 @@ function ns(e, t, n, r) {
3051
3062
  }), p == null || p(), (b = w) == null || b.disconnect(), w = null, l && cancelAnimationFrame(m);
3052
3063
  };
3053
3064
  }
3054
- const rs = Li, os = Di, as = Ni, is = zi, ss = Oi, Jn = _i, ls = Bi, cs = (e, t, n) => {
3065
+ const os = Di, as = Bi, is = Oi, ss = Fi, ls = Mi, Jn = Ni, cs = zi, us = (e, t, n) => {
3055
3066
  const r = /* @__PURE__ */ new Map(), o = {
3056
- platform: es,
3067
+ platform: ts,
3057
3068
  ...n
3058
3069
  }, a = {
3059
3070
  ...o.platform,
3060
3071
  _c: r
3061
3072
  };
3062
- return Ri(e, t, {
3073
+ return _i(e, t, {
3063
3074
  ...o,
3064
3075
  platform: a
3065
3076
  });
@@ -3103,12 +3114,12 @@ function er(e, t) {
3103
3114
  return Math.round(t * n) / n;
3104
3115
  }
3105
3116
  function Qt(e) {
3106
- const t = u.useRef(e);
3117
+ const t = d.useRef(e);
3107
3118
  return Pt(() => {
3108
3119
  t.current = e;
3109
3120
  }), t;
3110
3121
  }
3111
- function us(e) {
3122
+ function ds(e) {
3112
3123
  e === void 0 && (e = {});
3113
3124
  const {
3114
3125
  placement: t = "bottom",
@@ -3122,95 +3133,95 @@ function us(e) {
3122
3133
  transform: s = !0,
3123
3134
  whileElementsMounted: l,
3124
3135
  open: c
3125
- } = e, [f, p] = u.useState({
3136
+ } = e, [f, p] = d.useState({
3126
3137
  x: 0,
3127
3138
  y: 0,
3128
3139
  strategy: n,
3129
3140
  placement: t,
3130
3141
  middlewareData: {},
3131
3142
  isPositioned: !1
3132
- }), [g, w] = u.useState(r);
3143
+ }), [g, w] = d.useState(r);
3133
3144
  Lt(g, r) || w(r);
3134
- const [m, d] = u.useState(null), [v, b] = u.useState(null), x = u.useCallback((R) => {
3135
- R !== T.current && (T.current = R, d(R));
3136
- }, []), y = u.useCallback((R) => {
3137
- R !== C.current && (C.current = R, b(R));
3138
- }, []), S = a || m, E = i || v, T = u.useRef(null), C = u.useRef(null), I = u.useRef(f), O = l != null, M = Qt(l), V = Qt(o), $ = Qt(c), D = u.useCallback(() => {
3139
- if (!T.current || !C.current)
3145
+ const [m, u] = d.useState(null), [v, b] = d.useState(null), x = d.useCallback((_) => {
3146
+ _ !== T.current && (T.current = _, u(_));
3147
+ }, []), y = d.useCallback((_) => {
3148
+ _ !== E.current && (E.current = _, b(_));
3149
+ }, []), C = a || m, S = i || v, T = d.useRef(null), E = d.useRef(null), R = d.useRef(f), M = l != null, L = Qt(l), N = Qt(o), A = Qt(c), D = d.useCallback(() => {
3150
+ if (!T.current || !E.current)
3140
3151
  return;
3141
- const R = {
3152
+ const _ = {
3142
3153
  placement: t,
3143
3154
  strategy: n,
3144
3155
  middleware: g
3145
3156
  };
3146
- V.current && (R.platform = V.current), cs(T.current, C.current, R).then((W) => {
3157
+ N.current && (_.platform = N.current), us(T.current, E.current, _).then((U) => {
3147
3158
  const ee = {
3148
- ...W,
3159
+ ...U,
3149
3160
  // The floating element's position may be recomputed while it's closed
3150
3161
  // but still mounted (such as when transitioning out). To ensure
3151
3162
  // `isPositioned` will be `false` initially on the next open, avoid
3152
3163
  // setting it to `true` when `open === false` (must be specified).
3153
- isPositioned: $.current !== !1
3164
+ isPositioned: A.current !== !1
3154
3165
  };
3155
- N.current && !Lt(I.current, ee) && (I.current = ee, u.flushSync(() => {
3166
+ B.current && !Lt(R.current, ee) && (R.current = ee, d.flushSync(() => {
3156
3167
  p(ee);
3157
3168
  }));
3158
3169
  });
3159
- }, [g, t, n, V, $]);
3170
+ }, [g, t, n, N, A]);
3160
3171
  Pt(() => {
3161
- c === !1 && I.current.isPositioned && (I.current.isPositioned = !1, p((R) => ({
3162
- ...R,
3172
+ c === !1 && R.current.isPositioned && (R.current.isPositioned = !1, p((_) => ({
3173
+ ..._,
3163
3174
  isPositioned: !1
3164
3175
  })));
3165
3176
  }, [c]);
3166
- const N = u.useRef(!1);
3167
- Pt(() => (N.current = !0, () => {
3168
- N.current = !1;
3177
+ const B = d.useRef(!1);
3178
+ Pt(() => (B.current = !0, () => {
3179
+ B.current = !1;
3169
3180
  }), []), Pt(() => {
3170
- if (S && (T.current = S), E && (C.current = E), S && E) {
3171
- if (M.current)
3172
- return M.current(S, E, D);
3181
+ if (C && (T.current = C), S && (E.current = S), C && S) {
3182
+ if (L.current)
3183
+ return L.current(C, S, D);
3173
3184
  D();
3174
3185
  }
3175
- }, [S, E, D, M, O]);
3176
- const X = u.useMemo(() => ({
3186
+ }, [C, S, D, L, M]);
3187
+ const K = d.useMemo(() => ({
3177
3188
  reference: T,
3178
- floating: C,
3189
+ floating: E,
3179
3190
  setReference: x,
3180
3191
  setFloating: y
3181
- }), [x, y]), _ = u.useMemo(() => ({
3182
- reference: S,
3183
- floating: E
3184
- }), [S, E]), L = u.useMemo(() => {
3185
- const R = {
3192
+ }), [x, y]), O = d.useMemo(() => ({
3193
+ reference: C,
3194
+ floating: S
3195
+ }), [C, S]), z = d.useMemo(() => {
3196
+ const _ = {
3186
3197
  position: n,
3187
3198
  left: 0,
3188
3199
  top: 0
3189
3200
  };
3190
- if (!_.floating)
3191
- return R;
3192
- const W = er(_.floating, f.x), ee = er(_.floating, f.y);
3201
+ if (!O.floating)
3202
+ return _;
3203
+ const U = er(O.floating, f.x), ee = er(O.floating, f.y);
3193
3204
  return s ? {
3194
- ...R,
3195
- transform: "translate(" + W + "px, " + ee + "px)",
3196
- ...Ur(_.floating) >= 1.5 && {
3205
+ ..._,
3206
+ transform: "translate(" + U + "px, " + ee + "px)",
3207
+ ...Ur(O.floating) >= 1.5 && {
3197
3208
  willChange: "transform"
3198
3209
  }
3199
3210
  } : {
3200
3211
  position: n,
3201
- left: W,
3212
+ left: U,
3202
3213
  top: ee
3203
3214
  };
3204
- }, [n, s, _.floating, f.x, f.y]);
3205
- return u.useMemo(() => ({
3215
+ }, [n, s, O.floating, f.x, f.y]);
3216
+ return d.useMemo(() => ({
3206
3217
  ...f,
3207
3218
  update: D,
3208
- refs: X,
3209
- elements: _,
3210
- floatingStyles: L
3211
- }), [f, D, X, _, L]);
3219
+ refs: K,
3220
+ elements: O,
3221
+ floatingStyles: z
3222
+ }), [f, D, K, O, z]);
3212
3223
  }
3213
- const ds = (e) => {
3224
+ const fs = (e) => {
3214
3225
  function t(n) {
3215
3226
  return {}.hasOwnProperty.call(n, "current");
3216
3227
  }
@@ -3231,17 +3242,14 @@ const ds = (e) => {
3231
3242
  }).fn(n) : {};
3232
3243
  }
3233
3244
  };
3234
- }, fs = (e, t) => ({
3235
- ...rs(e),
3236
- options: [e, t]
3237
- }), ps = (e, t) => ({
3245
+ }, ps = (e, t) => ({
3238
3246
  ...os(e),
3239
3247
  options: [e, t]
3240
3248
  }), hs = (e, t) => ({
3241
- ...ls(e),
3249
+ ...as(e),
3242
3250
  options: [e, t]
3243
3251
  }), vs = (e, t) => ({
3244
- ...as(e),
3252
+ ...cs(e),
3245
3253
  options: [e, t]
3246
3254
  }), gs = (e, t) => ({
3247
3255
  ...is(e),
@@ -3250,13 +3258,16 @@ const ds = (e) => {
3250
3258
  ...ss(e),
3251
3259
  options: [e, t]
3252
3260
  }), ws = (e, t) => ({
3253
- ...ds(e),
3261
+ ...ls(e),
3262
+ options: [e, t]
3263
+ }), bs = (e, t) => ({
3264
+ ...fs(e),
3254
3265
  options: [e, t]
3255
3266
  });
3256
- var bs = "Arrow", Hr = u.forwardRef((e, t) => {
3267
+ var xs = "Arrow", Hr = d.forwardRef((e, t) => {
3257
3268
  const { children: n, width: r = 10, height: o = 5, ...a } = e;
3258
3269
  return /* @__PURE__ */ k(
3259
- K.svg,
3270
+ X.svg,
3260
3271
  {
3261
3272
  ...a,
3262
3273
  ref: t,
@@ -3268,10 +3279,10 @@ var bs = "Arrow", Hr = u.forwardRef((e, t) => {
3268
3279
  }
3269
3280
  );
3270
3281
  });
3271
- Hr.displayName = bs;
3272
- var xs = Hr;
3273
- function ys(e) {
3274
- const [t, n] = u.useState(void 0);
3282
+ Hr.displayName = xs;
3283
+ var ys = Hr;
3284
+ function Cs(e) {
3285
+ const [t, n] = d.useState(void 0);
3275
3286
  return te(() => {
3276
3287
  if (e) {
3277
3288
  n({ width: e.offsetWidth, height: e.offsetHeight });
@@ -3292,23 +3303,23 @@ function ys(e) {
3292
3303
  n(void 0);
3293
3304
  }, [e]), t;
3294
3305
  }
3295
- var Rn = "Popper", [jr, Yr] = yn(Rn), [Cs, Xr] = jr(Rn), Kr = (e) => {
3296
- const { __scopePopper: t, children: n } = e, [r, o] = u.useState(null);
3297
- return /* @__PURE__ */ k(Cs, { scope: t, anchor: r, onAnchorChange: o, children: n });
3306
+ var Rn = "Popper", [jr, Yr] = yn(Rn), [Ss, Kr] = jr(Rn), Xr = (e) => {
3307
+ const { __scopePopper: t, children: n } = e, [r, o] = d.useState(null);
3308
+ return /* @__PURE__ */ k(Ss, { scope: t, anchor: r, onAnchorChange: o, children: n });
3298
3309
  };
3299
- Kr.displayName = Rn;
3300
- var Gr = "PopperAnchor", Zr = u.forwardRef(
3310
+ Xr.displayName = Rn;
3311
+ var Gr = "PopperAnchor", Zr = d.forwardRef(
3301
3312
  (e, t) => {
3302
- const { __scopePopper: n, virtualRef: r, ...o } = e, a = Xr(Gr, n), i = u.useRef(null), s = Z(t, i);
3303
- return u.useEffect(() => {
3313
+ const { __scopePopper: n, virtualRef: r, ...o } = e, a = Kr(Gr, n), i = d.useRef(null), s = Z(t, i);
3314
+ return d.useEffect(() => {
3304
3315
  a.onAnchorChange((r == null ? void 0 : r.current) || i.current);
3305
- }), r ? null : /* @__PURE__ */ k(K.div, { ...o, ref: s });
3316
+ }), r ? null : /* @__PURE__ */ k(X.div, { ...o, ref: s });
3306
3317
  }
3307
3318
  );
3308
3319
  Zr.displayName = Gr;
3309
- var _n = "PopperContent", [Ss, Es] = jr(_n), qr = u.forwardRef(
3320
+ var _n = "PopperContent", [Es, ks] = jr(_n), qr = d.forwardRef(
3310
3321
  (e, t) => {
3311
- var A, U, Q, F, B, z;
3322
+ var P, H, Q, $, F, V;
3312
3323
  const {
3313
3324
  __scopePopper: n,
3314
3325
  side: r = "bottom",
@@ -3323,94 +3334,94 @@ var _n = "PopperContent", [Ss, Es] = jr(_n), qr = u.forwardRef(
3323
3334
  hideWhenDetached: g = !1,
3324
3335
  updatePositionStrategy: w = "optimized",
3325
3336
  onPlaced: m,
3326
- ...d
3327
- } = e, v = Xr(_n, n), [b, x] = u.useState(null), y = Z(t, (oe) => x(oe)), [S, E] = u.useState(null), T = ys(S), C = (T == null ? void 0 : T.width) ?? 0, I = (T == null ? void 0 : T.height) ?? 0, O = r + (a !== "center" ? "-" + a : ""), M = typeof f == "number" ? f : { top: 0, right: 0, bottom: 0, left: 0, ...f }, V = Array.isArray(c) ? c : [c], $ = V.length > 0, D = {
3328
- padding: M,
3329
- boundary: V.filter(Ts),
3337
+ ...u
3338
+ } = e, v = Kr(_n, n), [b, x] = d.useState(null), y = Z(t, (oe) => x(oe)), [C, S] = d.useState(null), T = Cs(C), E = (T == null ? void 0 : T.width) ?? 0, R = (T == null ? void 0 : T.height) ?? 0, M = r + (a !== "center" ? "-" + a : ""), L = typeof f == "number" ? f : { top: 0, right: 0, bottom: 0, left: 0, ...f }, N = Array.isArray(c) ? c : [c], A = N.length > 0, D = {
3339
+ padding: L,
3340
+ boundary: N.filter(As),
3330
3341
  // with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
3331
- altBoundary: $
3332
- }, { refs: N, floatingStyles: X, placement: _, isPositioned: L, middlewareData: R } = us({
3342
+ altBoundary: A
3343
+ }, { refs: B, floatingStyles: K, placement: O, isPositioned: z, middlewareData: _ } = ds({
3333
3344
  // default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues
3334
3345
  strategy: "fixed",
3335
- placement: O,
3336
- whileElementsMounted: (...oe) => ns(...oe, {
3346
+ placement: M,
3347
+ whileElementsMounted: (...oe) => rs(...oe, {
3337
3348
  animationFrame: w === "always"
3338
3349
  }),
3339
3350
  elements: {
3340
3351
  reference: v.anchor
3341
3352
  },
3342
3353
  middleware: [
3343
- fs({ mainAxis: o + I, alignmentAxis: i }),
3344
- l && ps({
3354
+ ps({ mainAxis: o + R, alignmentAxis: i }),
3355
+ l && hs({
3345
3356
  mainAxis: !0,
3346
3357
  crossAxis: !1,
3347
- limiter: p === "partial" ? hs() : void 0,
3358
+ limiter: p === "partial" ? vs() : void 0,
3348
3359
  ...D
3349
3360
  }),
3350
- l && vs({ ...D }),
3351
- gs({
3361
+ l && gs({ ...D }),
3362
+ ms({
3352
3363
  ...D,
3353
3364
  apply: ({ elements: oe, rects: ge, availableWidth: ut, availableHeight: dt }) => {
3354
3365
  const { width: ft, height: Uo } = ge.reference, xt = oe.floating.style;
3355
3366
  xt.setProperty("--radix-popper-available-width", `${ut}px`), xt.setProperty("--radix-popper-available-height", `${dt}px`), xt.setProperty("--radix-popper-anchor-width", `${ft}px`), xt.setProperty("--radix-popper-anchor-height", `${Uo}px`);
3356
3367
  }
3357
3368
  }),
3358
- S && ws({ element: S, padding: s }),
3359
- As({ arrowWidth: C, arrowHeight: I }),
3360
- g && ms({ strategy: "referenceHidden", ...D })
3369
+ C && bs({ element: C, padding: s }),
3370
+ Ps({ arrowWidth: E, arrowHeight: R }),
3371
+ g && ws({ strategy: "referenceHidden", ...D })
3361
3372
  ]
3362
- }), [W, ee] = eo(_), Ee = Ue(m);
3373
+ }), [U, ee] = eo(O), Ee = Ue(m);
3363
3374
  te(() => {
3364
- L && (Ee == null || Ee());
3365
- }, [L, Ee]);
3366
- const lt = (A = R.arrow) == null ? void 0 : A.x, ct = (U = R.arrow) == null ? void 0 : U.y, Re = ((Q = R.arrow) == null ? void 0 : Q.centerOffset) !== 0, [Xe, $e] = u.useState();
3375
+ z && (Ee == null || Ee());
3376
+ }, [z, Ee]);
3377
+ const lt = (P = _.arrow) == null ? void 0 : P.x, ct = (H = _.arrow) == null ? void 0 : H.y, Re = ((Q = _.arrow) == null ? void 0 : Q.centerOffset) !== 0, [Ke, $e] = d.useState();
3367
3378
  return te(() => {
3368
3379
  b && $e(window.getComputedStyle(b).zIndex);
3369
3380
  }, [b]), /* @__PURE__ */ k(
3370
3381
  "div",
3371
3382
  {
3372
- ref: N.setFloating,
3383
+ ref: B.setFloating,
3373
3384
  "data-radix-popper-content-wrapper": "",
3374
3385
  style: {
3375
- ...X,
3376
- transform: L ? X.transform : "translate(0, -200%)",
3386
+ ...K,
3387
+ transform: z ? K.transform : "translate(0, -200%)",
3377
3388
  // keep off the page when measuring
3378
3389
  minWidth: "max-content",
3379
- zIndex: Xe,
3390
+ zIndex: Ke,
3380
3391
  "--radix-popper-transform-origin": [
3381
- (F = R.transformOrigin) == null ? void 0 : F.x,
3382
- (B = R.transformOrigin) == null ? void 0 : B.y
3392
+ ($ = _.transformOrigin) == null ? void 0 : $.x,
3393
+ (F = _.transformOrigin) == null ? void 0 : F.y
3383
3394
  ].join(" "),
3384
3395
  // hide the content if using the hide middleware and should be hidden
3385
3396
  // set visibility to hidden and disable pointer events so the UI behaves
3386
3397
  // as if the PopperContent isn't there at all
3387
- ...((z = R.hide) == null ? void 0 : z.referenceHidden) && {
3398
+ ...((V = _.hide) == null ? void 0 : V.referenceHidden) && {
3388
3399
  visibility: "hidden",
3389
3400
  pointerEvents: "none"
3390
3401
  }
3391
3402
  },
3392
3403
  dir: e.dir,
3393
3404
  children: /* @__PURE__ */ k(
3394
- Ss,
3405
+ Es,
3395
3406
  {
3396
3407
  scope: n,
3397
- placedSide: W,
3398
- onArrowChange: E,
3408
+ placedSide: U,
3409
+ onArrowChange: S,
3399
3410
  arrowX: lt,
3400
3411
  arrowY: ct,
3401
3412
  shouldHideArrow: Re,
3402
3413
  children: /* @__PURE__ */ k(
3403
- K.div,
3414
+ X.div,
3404
3415
  {
3405
- "data-side": W,
3416
+ "data-side": U,
3406
3417
  "data-align": ee,
3407
- ...d,
3418
+ ...u,
3408
3419
  ref: y,
3409
3420
  style: {
3410
- ...d.style,
3421
+ ...u.style,
3411
3422
  // if the PopperContent hasn't been placed yet (not all measurements done)
3412
3423
  // we prevent animations so that users's animation don't kick in too early referring wrong sides
3413
- animation: L ? void 0 : "none"
3424
+ animation: z ? void 0 : "none"
3414
3425
  }
3415
3426
  }
3416
3427
  )
@@ -3421,13 +3432,13 @@ var _n = "PopperContent", [Ss, Es] = jr(_n), qr = u.forwardRef(
3421
3432
  }
3422
3433
  );
3423
3434
  qr.displayName = _n;
3424
- var Qr = "PopperArrow", ks = {
3435
+ var Qr = "PopperArrow", Ts = {
3425
3436
  top: "bottom",
3426
3437
  right: "left",
3427
3438
  bottom: "top",
3428
3439
  left: "right"
3429
- }, Jr = u.forwardRef(function(t, n) {
3430
- const { __scopePopper: r, ...o } = t, a = Es(Qr, r), i = ks[a.placedSide];
3440
+ }, Jr = d.forwardRef(function(t, n) {
3441
+ const { __scopePopper: r, ...o } = t, a = ks(Qr, r), i = Ts[a.placedSide];
3431
3442
  return (
3432
3443
  // we have to use an extra wrapper because `ResizeObserver` (used by `useSize`)
3433
3444
  // doesn't report size as we'd expect on SVG elements.
@@ -3456,7 +3467,7 @@ var Qr = "PopperArrow", ks = {
3456
3467
  visibility: a.shouldHideArrow ? "hidden" : void 0
3457
3468
  },
3458
3469
  children: /* @__PURE__ */ k(
3459
- xs,
3470
+ ys,
3460
3471
  {
3461
3472
  ...o,
3462
3473
  ref: n,
@@ -3472,32 +3483,32 @@ var Qr = "PopperArrow", ks = {
3472
3483
  );
3473
3484
  });
3474
3485
  Jr.displayName = Qr;
3475
- function Ts(e) {
3486
+ function As(e) {
3476
3487
  return e !== null;
3477
3488
  }
3478
- var As = (e) => ({
3489
+ var Ps = (e) => ({
3479
3490
  name: "transformOrigin",
3480
3491
  options: e,
3481
3492
  fn(t) {
3482
3493
  var v, b, x;
3483
3494
  const { placement: n, rects: r, middlewareData: o } = t, i = ((v = o.arrow) == null ? void 0 : v.centerOffset) !== 0, s = i ? 0 : e.arrowWidth, l = i ? 0 : e.arrowHeight, [c, f] = eo(n), p = { start: "0%", center: "50%", end: "100%" }[f], g = (((b = o.arrow) == null ? void 0 : b.x) ?? 0) + s / 2, w = (((x = o.arrow) == null ? void 0 : x.y) ?? 0) + l / 2;
3484
- let m = "", d = "";
3485
- return c === "bottom" ? (m = i ? p : `${g}px`, d = `${-l}px`) : c === "top" ? (m = i ? p : `${g}px`, d = `${r.floating.height + l}px`) : c === "right" ? (m = `${-l}px`, d = i ? p : `${w}px`) : c === "left" && (m = `${r.floating.width + l}px`, d = i ? p : `${w}px`), { data: { x: m, y: d } };
3495
+ let m = "", u = "";
3496
+ return c === "bottom" ? (m = i ? p : `${g}px`, u = `${-l}px`) : c === "top" ? (m = i ? p : `${g}px`, u = `${r.floating.height + l}px`) : c === "right" ? (m = `${-l}px`, u = i ? p : `${w}px`) : c === "left" && (m = `${r.floating.width + l}px`, u = i ? p : `${w}px`), { data: { x: m, y: u } };
3486
3497
  }
3487
3498
  });
3488
3499
  function eo(e) {
3489
3500
  const [t, n = "center"] = e.split("-");
3490
3501
  return [t, n];
3491
3502
  }
3492
- var Ps = Kr, Is = Zr, Rs = qr, _s = Jr, Ns = "Portal", to = u.forwardRef((e, t) => {
3503
+ var Is = Xr, Rs = Zr, _s = qr, Ns = Jr, Os = "Portal", to = d.forwardRef((e, t) => {
3493
3504
  var s;
3494
- const { container: n, ...r } = e, [o, a] = u.useState(!1);
3505
+ const { container: n, ...r } = e, [o, a] = d.useState(!1);
3495
3506
  te(() => a(!0), []);
3496
3507
  const i = n || o && ((s = globalThis == null ? void 0 : globalThis.document) == null ? void 0 : s.body);
3497
- return i ? _e.createPortal(/* @__PURE__ */ k(K.div, { ...r, ref: t }), i) : null;
3508
+ return i ? _e.createPortal(/* @__PURE__ */ k(X.div, { ...r, ref: t }), i) : null;
3498
3509
  });
3499
- to.displayName = Ns;
3500
- var Os = u[" useInsertionEffect ".trim().toString()] || te;
3510
+ to.displayName = Os;
3511
+ var Ms = d[" useInsertionEffect ".trim().toString()] || te;
3501
3512
  function tr({
3502
3513
  prop: e,
3503
3514
  defaultProp: t,
@@ -3505,24 +3516,24 @@ function tr({
3505
3516
  },
3506
3517
  caller: r
3507
3518
  }) {
3508
- const [o, a, i] = Ms({
3519
+ const [o, a, i] = Ls({
3509
3520
  defaultProp: t,
3510
3521
  onChange: n
3511
3522
  }), s = e !== void 0, l = s ? e : o;
3512
3523
  {
3513
- const f = u.useRef(e !== void 0);
3514
- u.useEffect(() => {
3524
+ const f = d.useRef(e !== void 0);
3525
+ d.useEffect(() => {
3515
3526
  const p = f.current;
3516
3527
  p !== s && console.warn(
3517
3528
  `${r} is changing from ${p ? "controlled" : "uncontrolled"} to ${s ? "controlled" : "uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`
3518
3529
  ), f.current = s;
3519
3530
  }, [s, r]);
3520
3531
  }
3521
- const c = u.useCallback(
3532
+ const c = d.useCallback(
3522
3533
  (f) => {
3523
3534
  var p;
3524
3535
  if (s) {
3525
- const g = Ls(f) ? f(e) : f;
3536
+ const g = Ds(f) ? f(e) : f;
3526
3537
  g !== e && ((p = i.current) == null || p.call(i, g));
3527
3538
  } else
3528
3539
  a(f);
@@ -3531,24 +3542,24 @@ function tr({
3531
3542
  );
3532
3543
  return [l, c];
3533
3544
  }
3534
- function Ms({
3545
+ function Ls({
3535
3546
  defaultProp: e,
3536
3547
  onChange: t
3537
3548
  }) {
3538
- const [n, r] = u.useState(e), o = u.useRef(n), a = u.useRef(t);
3539
- return Os(() => {
3549
+ const [n, r] = d.useState(e), o = d.useRef(n), a = d.useRef(t);
3550
+ return Ms(() => {
3540
3551
  a.current = t;
3541
- }, [t]), u.useEffect(() => {
3552
+ }, [t]), d.useEffect(() => {
3542
3553
  var i;
3543
3554
  o.current !== n && ((i = a.current) == null || i.call(a, n), o.current = n);
3544
3555
  }, [n, o]), [n, r, a];
3545
3556
  }
3546
- function Ls(e) {
3557
+ function Ds(e) {
3547
3558
  return typeof e == "function";
3548
3559
  }
3549
- function Ds(e) {
3550
- const t = u.useRef({ value: e, previous: e });
3551
- return u.useMemo(() => (t.current.value !== e && (t.current.previous = t.current.value, t.current.value = e), t.current.previous), [e]);
3560
+ function Bs(e) {
3561
+ const t = d.useRef({ value: e, previous: e });
3562
+ return d.useMemo(() => (t.current.value !== e && (t.current.previous = t.current.value, t.current.value = e), t.current.previous), [e]);
3552
3563
  }
3553
3564
  var no = Object.freeze({
3554
3565
  // See: https://github.com/twbs/bootstrap/blob/main/scss/mixins/_visually-hidden.scss
@@ -3562,9 +3573,9 @@ var no = Object.freeze({
3562
3573
  clip: "rect(0, 0, 0, 0)",
3563
3574
  whiteSpace: "nowrap",
3564
3575
  wordWrap: "normal"
3565
- }), Bs = "VisuallyHidden", zs = u.forwardRef(
3576
+ }), zs = "VisuallyHidden", Fs = d.forwardRef(
3566
3577
  (e, t) => /* @__PURE__ */ k(
3567
- K.span,
3578
+ X.span,
3568
3579
  {
3569
3580
  ...e,
3570
3581
  ref: t,
@@ -3572,15 +3583,15 @@ var no = Object.freeze({
3572
3583
  }
3573
3584
  )
3574
3585
  );
3575
- zs.displayName = Bs;
3576
- var Fs = function(e) {
3586
+ Fs.displayName = zs;
3587
+ var Vs = function(e) {
3577
3588
  if (typeof document > "u")
3578
3589
  return null;
3579
3590
  var t = Array.isArray(e) ? e[0] : e;
3580
3591
  return t.ownerDocument.body;
3581
- }, Ke = /* @__PURE__ */ new WeakMap(), St = /* @__PURE__ */ new WeakMap(), Et = {}, Jt = 0, ro = function(e) {
3592
+ }, Xe = /* @__PURE__ */ new WeakMap(), St = /* @__PURE__ */ new WeakMap(), Et = {}, Jt = 0, ro = function(e) {
3582
3593
  return e && (e.host || ro(e.parentNode));
3583
- }, Vs = function(e, t) {
3594
+ }, $s = function(e, t) {
3584
3595
  return t.map(function(n) {
3585
3596
  if (e.contains(n))
3586
3597
  return n;
@@ -3589,8 +3600,8 @@ var Fs = function(e) {
3589
3600
  }).filter(function(n) {
3590
3601
  return !!n;
3591
3602
  });
3592
- }, $s = function(e, t, n, r) {
3593
- var o = Vs(t, Array.isArray(e) ? e : [e]);
3603
+ }, Ws = function(e, t, n, r) {
3604
+ var o = $s(t, Array.isArray(e) ? e : [e]);
3594
3605
  Et[n] || (Et[n] = /* @__PURE__ */ new WeakMap());
3595
3606
  var a = Et[n], i = [], s = /* @__PURE__ */ new Set(), l = new Set(o), c = function(p) {
3596
3607
  !p || s.has(p) || (s.add(p), c(p.parentNode));
@@ -3602,8 +3613,8 @@ var Fs = function(e) {
3602
3613
  f(g);
3603
3614
  else
3604
3615
  try {
3605
- var w = g.getAttribute(r), m = w !== null && w !== "false", d = (Ke.get(g) || 0) + 1, v = (a.get(g) || 0) + 1;
3606
- Ke.set(g, d), a.set(g, v), i.push(g), d === 1 && m && St.set(g, !0), v === 1 && g.setAttribute(n, "true"), m || g.setAttribute(r, "true");
3616
+ var w = g.getAttribute(r), m = w !== null && w !== "false", u = (Xe.get(g) || 0) + 1, v = (a.get(g) || 0) + 1;
3617
+ Xe.set(g, u), a.set(g, v), i.push(g), u === 1 && m && St.set(g, !0), v === 1 && g.setAttribute(n, "true"), m || g.setAttribute(r, "true");
3607
3618
  } catch (b) {
3608
3619
  console.error("aria-hidden: cannot operate on ", g, b);
3609
3620
  }
@@ -3611,14 +3622,14 @@ var Fs = function(e) {
3611
3622
  };
3612
3623
  return f(t), s.clear(), Jt++, function() {
3613
3624
  i.forEach(function(p) {
3614
- var g = Ke.get(p) - 1, w = a.get(p) - 1;
3615
- Ke.set(p, g), a.set(p, w), g || (St.has(p) || p.removeAttribute(r), St.delete(p)), w || p.removeAttribute(n);
3616
- }), Jt--, Jt || (Ke = /* @__PURE__ */ new WeakMap(), Ke = /* @__PURE__ */ new WeakMap(), St = /* @__PURE__ */ new WeakMap(), Et = {});
3625
+ var g = Xe.get(p) - 1, w = a.get(p) - 1;
3626
+ Xe.set(p, g), a.set(p, w), g || (St.has(p) || p.removeAttribute(r), St.delete(p)), w || p.removeAttribute(n);
3627
+ }), Jt--, Jt || (Xe = /* @__PURE__ */ new WeakMap(), Xe = /* @__PURE__ */ new WeakMap(), St = /* @__PURE__ */ new WeakMap(), Et = {});
3617
3628
  };
3618
- }, Ws = function(e, t, n) {
3629
+ }, Us = function(e, t, n) {
3619
3630
  n === void 0 && (n = "data-aria-hidden");
3620
- var r = Array.from(Array.isArray(e) ? e : [e]), o = Fs(e);
3621
- return o ? (r.push.apply(r, Array.from(o.querySelectorAll("[aria-live]"))), $s(r, o, n, "aria-hidden")) : function() {
3631
+ var r = Array.from(Array.isArray(e) ? e : [e]), o = Vs(e);
3632
+ return o ? (r.push.apply(r, Array.from(o.querySelectorAll("[aria-live]"))), Ws(r, o, n, "aria-hidden")) : function() {
3622
3633
  return null;
3623
3634
  };
3624
3635
  }, we = function() {
@@ -3638,16 +3649,16 @@ function oo(e, t) {
3638
3649
  t.indexOf(r[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, r[o]) && (n[r[o]] = e[r[o]]);
3639
3650
  return n;
3640
3651
  }
3641
- function Us(e, t, n) {
3652
+ function Hs(e, t, n) {
3642
3653
  if (n || arguments.length === 2) for (var r = 0, o = t.length, a; r < o; r++)
3643
3654
  (a || !(r in t)) && (a || (a = Array.prototype.slice.call(t, 0, r)), a[r] = t[r]);
3644
3655
  return e.concat(a || Array.prototype.slice.call(t));
3645
3656
  }
3646
- var It = "right-scroll-bar-position", Rt = "width-before-scroll-bar", Hs = "with-scroll-bars-hidden", js = "--removed-body-scroll-bar-size";
3657
+ var It = "right-scroll-bar-position", Rt = "width-before-scroll-bar", js = "with-scroll-bars-hidden", Ys = "--removed-body-scroll-bar-size";
3647
3658
  function en(e, t) {
3648
3659
  return typeof e == "function" ? e(t) : e && (e.current = t), e;
3649
3660
  }
3650
- function Ys(e, t) {
3661
+ function Ks(e, t) {
3651
3662
  var n = ke(function() {
3652
3663
  return {
3653
3664
  // value
@@ -3668,9 +3679,9 @@ function Ys(e, t) {
3668
3679
  })[0];
3669
3680
  return n.callback = t, n.facade;
3670
3681
  }
3671
- var Xs = typeof window < "u" ? u.useLayoutEffect : u.useEffect, nr = /* @__PURE__ */ new WeakMap();
3672
- function Ks(e, t) {
3673
- var n = Ys(null, function(r) {
3682
+ var Xs = typeof window < "u" ? d.useLayoutEffect : d.useEffect, nr = /* @__PURE__ */ new WeakMap();
3683
+ function Gs(e, t) {
3684
+ var n = Ks(null, function(r) {
3674
3685
  return e.forEach(function(o) {
3675
3686
  return en(o, r);
3676
3687
  });
@@ -3688,11 +3699,11 @@ function Ks(e, t) {
3688
3699
  nr.set(n, e);
3689
3700
  }, [e]), n;
3690
3701
  }
3691
- function Gs(e) {
3702
+ function Zs(e) {
3692
3703
  return e;
3693
3704
  }
3694
- function Zs(e, t) {
3695
- t === void 0 && (t = Gs);
3705
+ function qs(e, t) {
3706
+ t === void 0 && (t = Zs);
3696
3707
  var n = [], r = !1, o = {
3697
3708
  read: function() {
3698
3709
  if (r)
@@ -3746,9 +3757,9 @@ function Zs(e, t) {
3746
3757
  };
3747
3758
  return o;
3748
3759
  }
3749
- function qs(e) {
3760
+ function Qs(e) {
3750
3761
  e === void 0 && (e = {});
3751
- var t = Zs(null);
3762
+ var t = qs(null);
3752
3763
  return t.options = we({ async: !0, ssr: !1 }, e), t;
3753
3764
  }
3754
3765
  var ao = function(e) {
@@ -3758,24 +3769,24 @@ var ao = function(e) {
3758
3769
  var r = t.read();
3759
3770
  if (!r)
3760
3771
  throw new Error("Sidecar medium not found");
3761
- return u.createElement(r, we({}, n));
3772
+ return d.createElement(r, we({}, n));
3762
3773
  };
3763
3774
  ao.isSideCarExport = !0;
3764
- function Qs(e, t) {
3775
+ function Js(e, t) {
3765
3776
  return e.useMedium(t), ao;
3766
3777
  }
3767
- var io = qs(), tn = function() {
3768
- }, Wt = u.forwardRef(function(e, t) {
3769
- var n = u.useRef(null), r = u.useState({
3778
+ var io = Qs(), tn = function() {
3779
+ }, Wt = d.forwardRef(function(e, t) {
3780
+ var n = d.useRef(null), r = d.useState({
3770
3781
  onScrollCapture: tn,
3771
3782
  onWheelCapture: tn,
3772
3783
  onTouchMoveCapture: tn
3773
- }), o = r[0], a = r[1], i = e.forwardProps, s = e.children, l = e.className, c = e.removeScrollBar, f = e.enabled, p = e.shards, g = e.sideCar, w = e.noIsolation, m = e.inert, d = e.allowPinchZoom, v = e.as, b = v === void 0 ? "div" : v, x = e.gapMode, y = oo(e, ["forwardProps", "children", "className", "removeScrollBar", "enabled", "shards", "sideCar", "noIsolation", "inert", "allowPinchZoom", "as", "gapMode"]), S = g, E = Ks([n, t]), T = we(we({}, y), o);
3774
- return u.createElement(
3775
- u.Fragment,
3784
+ }), o = r[0], a = r[1], i = e.forwardProps, s = e.children, l = e.className, c = e.removeScrollBar, f = e.enabled, p = e.shards, g = e.sideCar, w = e.noIsolation, m = e.inert, u = e.allowPinchZoom, v = e.as, b = v === void 0 ? "div" : v, x = e.gapMode, y = oo(e, ["forwardProps", "children", "className", "removeScrollBar", "enabled", "shards", "sideCar", "noIsolation", "inert", "allowPinchZoom", "as", "gapMode"]), C = g, S = Gs([n, t]), T = we(we({}, y), o);
3785
+ return d.createElement(
3786
+ d.Fragment,
3776
3787
  null,
3777
- f && u.createElement(S, { sideCar: io, removeScrollBar: c, shards: p, noIsolation: w, inert: m, setCallbacks: a, allowPinchZoom: !!d, lockRef: n, gapMode: x }),
3778
- i ? u.cloneElement(u.Children.only(s), we(we({}, T), { ref: E })) : u.createElement(b, we({}, T, { className: l, ref: E }), s)
3788
+ f && d.createElement(C, { sideCar: io, removeScrollBar: c, shards: p, noIsolation: w, inert: m, setCallbacks: a, allowPinchZoom: !!u, lockRef: n, gapMode: x }),
3789
+ i ? d.cloneElement(d.Children.only(s), we(we({}, T), { ref: S })) : d.createElement(b, we({}, T, { className: l, ref: S }), s)
3779
3790
  );
3780
3791
  });
3781
3792
  Wt.defaultProps = {
@@ -3787,74 +3798,74 @@ Wt.classNames = {
3787
3798
  fullWidth: Rt,
3788
3799
  zeroRight: It
3789
3800
  };
3790
- var Js = function() {
3801
+ var el = function() {
3791
3802
  if (typeof __webpack_nonce__ < "u")
3792
3803
  return __webpack_nonce__;
3793
3804
  };
3794
- function el() {
3805
+ function tl() {
3795
3806
  if (!document)
3796
3807
  return null;
3797
3808
  var e = document.createElement("style");
3798
3809
  e.type = "text/css";
3799
- var t = Js();
3810
+ var t = el();
3800
3811
  return t && e.setAttribute("nonce", t), e;
3801
3812
  }
3802
- function tl(e, t) {
3813
+ function nl(e, t) {
3803
3814
  e.styleSheet ? e.styleSheet.cssText = t : e.appendChild(document.createTextNode(t));
3804
3815
  }
3805
- function nl(e) {
3816
+ function rl(e) {
3806
3817
  var t = document.head || document.getElementsByTagName("head")[0];
3807
3818
  t.appendChild(e);
3808
3819
  }
3809
- var rl = function() {
3820
+ var ol = function() {
3810
3821
  var e = 0, t = null;
3811
3822
  return {
3812
3823
  add: function(n) {
3813
- e == 0 && (t = el()) && (tl(t, n), nl(t)), e++;
3824
+ e == 0 && (t = tl()) && (nl(t, n), rl(t)), e++;
3814
3825
  },
3815
3826
  remove: function() {
3816
3827
  e--, !e && t && (t.parentNode && t.parentNode.removeChild(t), t = null);
3817
3828
  }
3818
3829
  };
3819
- }, ol = function() {
3820
- var e = rl();
3830
+ }, al = function() {
3831
+ var e = ol();
3821
3832
  return function(t, n) {
3822
- u.useEffect(function() {
3833
+ d.useEffect(function() {
3823
3834
  return e.add(t), function() {
3824
3835
  e.remove();
3825
3836
  };
3826
3837
  }, [t && n]);
3827
3838
  };
3828
3839
  }, so = function() {
3829
- var e = ol(), t = function(n) {
3840
+ var e = al(), t = function(n) {
3830
3841
  var r = n.styles, o = n.dynamic;
3831
3842
  return e(r, o), null;
3832
3843
  };
3833
3844
  return t;
3834
- }, al = {
3845
+ }, il = {
3835
3846
  left: 0,
3836
3847
  top: 0,
3837
3848
  right: 0,
3838
3849
  gap: 0
3839
3850
  }, nn = function(e) {
3840
3851
  return parseInt(e || "", 10) || 0;
3841
- }, il = function(e) {
3852
+ }, sl = function(e) {
3842
3853
  var t = window.getComputedStyle(document.body), n = t[e === "padding" ? "paddingLeft" : "marginLeft"], r = t[e === "padding" ? "paddingTop" : "marginTop"], o = t[e === "padding" ? "paddingRight" : "marginRight"];
3843
3854
  return [nn(n), nn(r), nn(o)];
3844
- }, sl = function(e) {
3855
+ }, ll = function(e) {
3845
3856
  if (e === void 0 && (e = "margin"), typeof window > "u")
3846
- return al;
3847
- var t = il(e), n = document.documentElement.clientWidth, r = window.innerWidth;
3857
+ return il;
3858
+ var t = sl(e), n = document.documentElement.clientWidth, r = window.innerWidth;
3848
3859
  return {
3849
3860
  left: t[0],
3850
3861
  top: t[1],
3851
3862
  right: t[2],
3852
3863
  gap: Math.max(0, r - n + t[2] - t[0])
3853
3864
  };
3854
- }, ll = so(), tt = "data-scroll-locked", cl = function(e, t, n, r) {
3865
+ }, cl = so(), tt = "data-scroll-locked", ul = function(e, t, n, r) {
3855
3866
  var o = e.left, a = e.top, i = e.right, s = e.gap;
3856
3867
  return n === void 0 && (n = "margin"), `
3857
- .`.concat(Hs, ` {
3868
+ .`.concat(js, ` {
3858
3869
  overflow: hidden `).concat(r, `;
3859
3870
  padding-right: `).concat(s, "px ").concat(r, `;
3860
3871
  }
@@ -3892,26 +3903,26 @@ var rl = function() {
3892
3903
  }
3893
3904
 
3894
3905
  body[`).concat(tt, `] {
3895
- `).concat(js, ": ").concat(s, `px;
3906
+ `).concat(Ys, ": ").concat(s, `px;
3896
3907
  }
3897
3908
  `);
3898
3909
  }, rr = function() {
3899
3910
  var e = parseInt(document.body.getAttribute(tt) || "0", 10);
3900
3911
  return isFinite(e) ? e : 0;
3901
- }, ul = function() {
3902
- u.useEffect(function() {
3912
+ }, dl = function() {
3913
+ d.useEffect(function() {
3903
3914
  return document.body.setAttribute(tt, (rr() + 1).toString()), function() {
3904
3915
  var e = rr() - 1;
3905
3916
  e <= 0 ? document.body.removeAttribute(tt) : document.body.setAttribute(tt, e.toString());
3906
3917
  };
3907
3918
  }, []);
3908
- }, dl = function(e) {
3919
+ }, fl = function(e) {
3909
3920
  var t = e.noRelative, n = e.noImportant, r = e.gapMode, o = r === void 0 ? "margin" : r;
3910
- ul();
3911
- var a = u.useMemo(function() {
3912
- return sl(o);
3921
+ dl();
3922
+ var a = d.useMemo(function() {
3923
+ return ll(o);
3913
3924
  }, [o]);
3914
- return u.createElement(ll, { styles: cl(a, !t, o, n ? "" : "!important") });
3925
+ return d.createElement(cl, { styles: ul(a, !t, o, n ? "" : "!important") });
3915
3926
  }, dn = !1;
3916
3927
  if (typeof window < "u")
3917
3928
  try {
@@ -3924,7 +3935,7 @@ if (typeof window < "u")
3924
3935
  } catch {
3925
3936
  dn = !1;
3926
3937
  }
3927
- var Ge = dn ? { passive: !1 } : !1, fl = function(e) {
3938
+ var Ge = dn ? { passive: !1 } : !1, pl = function(e) {
3928
3939
  return e.tagName === "TEXTAREA";
3929
3940
  }, lo = function(e, t) {
3930
3941
  if (!(e instanceof Element))
@@ -3933,11 +3944,11 @@ var Ge = dn ? { passive: !1 } : !1, fl = function(e) {
3933
3944
  return (
3934
3945
  // not-not-scrollable
3935
3946
  n[t] !== "hidden" && // contains scroll inside self
3936
- !(n.overflowY === n.overflowX && !fl(e) && n[t] === "visible")
3947
+ !(n.overflowY === n.overflowX && !pl(e) && n[t] === "visible")
3937
3948
  );
3938
- }, pl = function(e) {
3939
- return lo(e, "overflowY");
3940
3949
  }, hl = function(e) {
3950
+ return lo(e, "overflowY");
3951
+ }, vl = function(e) {
3941
3952
  return lo(e, "overflowX");
3942
3953
  }, or = function(e, t) {
3943
3954
  var n = t.ownerDocument, r = t;
@@ -3952,14 +3963,14 @@ var Ge = dn ? { passive: !1 } : !1, fl = function(e) {
3952
3963
  r = r.parentNode;
3953
3964
  } while (r && r !== n.body);
3954
3965
  return !1;
3955
- }, vl = function(e) {
3966
+ }, gl = function(e) {
3956
3967
  var t = e.scrollTop, n = e.scrollHeight, r = e.clientHeight;
3957
3968
  return [
3958
3969
  t,
3959
3970
  n,
3960
3971
  r
3961
3972
  ];
3962
- }, gl = function(e) {
3973
+ }, ml = function(e) {
3963
3974
  var t = e.scrollLeft, n = e.scrollWidth, r = e.clientWidth;
3964
3975
  return [
3965
3976
  t,
@@ -3967,15 +3978,15 @@ var Ge = dn ? { passive: !1 } : !1, fl = function(e) {
3967
3978
  r
3968
3979
  ];
3969
3980
  }, co = function(e, t) {
3970
- return e === "v" ? pl(t) : hl(t);
3981
+ return e === "v" ? hl(t) : vl(t);
3971
3982
  }, uo = function(e, t) {
3972
- return e === "v" ? vl(t) : gl(t);
3973
- }, ml = function(e, t) {
3983
+ return e === "v" ? gl(t) : ml(t);
3984
+ }, wl = function(e, t) {
3974
3985
  return e === "h" && t === "rtl" ? -1 : 1;
3975
- }, wl = function(e, t, n, r, o) {
3976
- var a = ml(e, window.getComputedStyle(t).direction), i = a * r, s = n.target, l = t.contains(s), c = !1, f = i > 0, p = 0, g = 0;
3986
+ }, bl = function(e, t, n, r, o) {
3987
+ var a = wl(e, window.getComputedStyle(t).direction), i = a * r, s = n.target, l = t.contains(s), c = !1, f = i > 0, p = 0, g = 0;
3977
3988
  do {
3978
- var w = uo(e, s), m = w[0], d = w[1], v = w[2], b = d - v - a * m;
3989
+ var w = uo(e, s), m = w[0], u = w[1], v = w[2], b = u - v - a * m;
3979
3990
  (m || b) && co(e, s) && (p += b, g += m), s instanceof ShadowRoot ? s = s.host : s = s.parentNode;
3980
3991
  } while (
3981
3992
  // portaled content
@@ -3989,110 +4000,110 @@ var Ge = dn ? { passive: !1 } : !1, fl = function(e) {
3989
4000
  return [e.deltaX, e.deltaY];
3990
4001
  }, ir = function(e) {
3991
4002
  return e && "current" in e ? e.current : e;
3992
- }, bl = function(e, t) {
4003
+ }, xl = function(e, t) {
3993
4004
  return e[0] === t[0] && e[1] === t[1];
3994
- }, xl = function(e) {
4005
+ }, yl = function(e) {
3995
4006
  return `
3996
4007
  .block-interactivity-`.concat(e, ` {pointer-events: none;}
3997
4008
  .allow-interactivity-`).concat(e, ` {pointer-events: all;}
3998
4009
  `);
3999
- }, yl = 0, Ze = [];
4000
- function Cl(e) {
4001
- var t = u.useRef([]), n = u.useRef([0, 0]), r = u.useRef(), o = u.useState(yl++)[0], a = u.useState(so)[0], i = u.useRef(e);
4002
- u.useEffect(function() {
4010
+ }, Cl = 0, Ze = [];
4011
+ function Sl(e) {
4012
+ var t = d.useRef([]), n = d.useRef([0, 0]), r = d.useRef(), o = d.useState(Cl++)[0], a = d.useState(so)[0], i = d.useRef(e);
4013
+ d.useEffect(function() {
4003
4014
  i.current = e;
4004
- }, [e]), u.useEffect(function() {
4015
+ }, [e]), d.useEffect(function() {
4005
4016
  if (e.inert) {
4006
4017
  document.body.classList.add("block-interactivity-".concat(o));
4007
- var d = Us([e.lockRef.current], (e.shards || []).map(ir), !0).filter(Boolean);
4008
- return d.forEach(function(v) {
4018
+ var u = Hs([e.lockRef.current], (e.shards || []).map(ir), !0).filter(Boolean);
4019
+ return u.forEach(function(v) {
4009
4020
  return v.classList.add("allow-interactivity-".concat(o));
4010
4021
  }), function() {
4011
- document.body.classList.remove("block-interactivity-".concat(o)), d.forEach(function(v) {
4022
+ document.body.classList.remove("block-interactivity-".concat(o)), u.forEach(function(v) {
4012
4023
  return v.classList.remove("allow-interactivity-".concat(o));
4013
4024
  });
4014
4025
  };
4015
4026
  }
4016
4027
  }, [e.inert, e.lockRef.current, e.shards]);
4017
- var s = u.useCallback(function(d, v) {
4018
- if ("touches" in d && d.touches.length === 2 || d.type === "wheel" && d.ctrlKey)
4028
+ var s = d.useCallback(function(u, v) {
4029
+ if ("touches" in u && u.touches.length === 2 || u.type === "wheel" && u.ctrlKey)
4019
4030
  return !i.current.allowPinchZoom;
4020
- var b = Tt(d), x = n.current, y = "deltaX" in d ? d.deltaX : x[0] - b[0], S = "deltaY" in d ? d.deltaY : x[1] - b[1], E, T = d.target, C = Math.abs(y) > Math.abs(S) ? "h" : "v";
4021
- if ("touches" in d && C === "h" && T.type === "range")
4031
+ var b = Tt(u), x = n.current, y = "deltaX" in u ? u.deltaX : x[0] - b[0], C = "deltaY" in u ? u.deltaY : x[1] - b[1], S, T = u.target, E = Math.abs(y) > Math.abs(C) ? "h" : "v";
4032
+ if ("touches" in u && E === "h" && T.type === "range")
4022
4033
  return !1;
4023
- var I = or(C, T);
4024
- if (!I)
4034
+ var R = or(E, T);
4035
+ if (!R)
4025
4036
  return !0;
4026
- if (I ? E = C : (E = C === "v" ? "h" : "v", I = or(C, T)), !I)
4037
+ if (R ? S = E : (S = E === "v" ? "h" : "v", R = or(E, T)), !R)
4027
4038
  return !1;
4028
- if (!r.current && "changedTouches" in d && (y || S) && (r.current = E), !E)
4039
+ if (!r.current && "changedTouches" in u && (y || C) && (r.current = S), !S)
4029
4040
  return !0;
4030
- var O = r.current || E;
4031
- return wl(O, v, d, O === "h" ? y : S);
4032
- }, []), l = u.useCallback(function(d) {
4033
- var v = d;
4041
+ var M = r.current || S;
4042
+ return bl(M, v, u, M === "h" ? y : C);
4043
+ }, []), l = d.useCallback(function(u) {
4044
+ var v = u;
4034
4045
  if (!(!Ze.length || Ze[Ze.length - 1] !== a)) {
4035
- var b = "deltaY" in v ? ar(v) : Tt(v), x = t.current.filter(function(E) {
4036
- return E.name === v.type && (E.target === v.target || v.target === E.shadowParent) && bl(E.delta, b);
4046
+ var b = "deltaY" in v ? ar(v) : Tt(v), x = t.current.filter(function(S) {
4047
+ return S.name === v.type && (S.target === v.target || v.target === S.shadowParent) && xl(S.delta, b);
4037
4048
  })[0];
4038
4049
  if (x && x.should) {
4039
4050
  v.cancelable && v.preventDefault();
4040
4051
  return;
4041
4052
  }
4042
4053
  if (!x) {
4043
- var y = (i.current.shards || []).map(ir).filter(Boolean).filter(function(E) {
4044
- return E.contains(v.target);
4045
- }), S = y.length > 0 ? s(v, y[0]) : !i.current.noIsolation;
4046
- S && v.cancelable && v.preventDefault();
4054
+ var y = (i.current.shards || []).map(ir).filter(Boolean).filter(function(S) {
4055
+ return S.contains(v.target);
4056
+ }), C = y.length > 0 ? s(v, y[0]) : !i.current.noIsolation;
4057
+ C && v.cancelable && v.preventDefault();
4047
4058
  }
4048
4059
  }
4049
- }, []), c = u.useCallback(function(d, v, b, x) {
4050
- var y = { name: d, delta: v, target: b, should: x, shadowParent: Sl(b) };
4060
+ }, []), c = d.useCallback(function(u, v, b, x) {
4061
+ var y = { name: u, delta: v, target: b, should: x, shadowParent: El(b) };
4051
4062
  t.current.push(y), setTimeout(function() {
4052
- t.current = t.current.filter(function(S) {
4053
- return S !== y;
4063
+ t.current = t.current.filter(function(C) {
4064
+ return C !== y;
4054
4065
  });
4055
4066
  }, 1);
4056
- }, []), f = u.useCallback(function(d) {
4057
- n.current = Tt(d), r.current = void 0;
4058
- }, []), p = u.useCallback(function(d) {
4059
- c(d.type, ar(d), d.target, s(d, e.lockRef.current));
4060
- }, []), g = u.useCallback(function(d) {
4061
- c(d.type, Tt(d), d.target, s(d, e.lockRef.current));
4067
+ }, []), f = d.useCallback(function(u) {
4068
+ n.current = Tt(u), r.current = void 0;
4069
+ }, []), p = d.useCallback(function(u) {
4070
+ c(u.type, ar(u), u.target, s(u, e.lockRef.current));
4071
+ }, []), g = d.useCallback(function(u) {
4072
+ c(u.type, Tt(u), u.target, s(u, e.lockRef.current));
4062
4073
  }, []);
4063
- u.useEffect(function() {
4074
+ d.useEffect(function() {
4064
4075
  return Ze.push(a), e.setCallbacks({
4065
4076
  onScrollCapture: p,
4066
4077
  onWheelCapture: p,
4067
4078
  onTouchMoveCapture: g
4068
4079
  }), document.addEventListener("wheel", l, Ge), document.addEventListener("touchmove", l, Ge), document.addEventListener("touchstart", f, Ge), function() {
4069
- Ze = Ze.filter(function(d) {
4070
- return d !== a;
4080
+ Ze = Ze.filter(function(u) {
4081
+ return u !== a;
4071
4082
  }), document.removeEventListener("wheel", l, Ge), document.removeEventListener("touchmove", l, Ge), document.removeEventListener("touchstart", f, Ge);
4072
4083
  };
4073
4084
  }, []);
4074
4085
  var w = e.removeScrollBar, m = e.inert;
4075
- return u.createElement(
4076
- u.Fragment,
4086
+ return d.createElement(
4087
+ d.Fragment,
4077
4088
  null,
4078
- m ? u.createElement(a, { styles: xl(o) }) : null,
4079
- w ? u.createElement(dl, { gapMode: e.gapMode }) : null
4089
+ m ? d.createElement(a, { styles: yl(o) }) : null,
4090
+ w ? d.createElement(fl, { gapMode: e.gapMode }) : null
4080
4091
  );
4081
4092
  }
4082
- function Sl(e) {
4093
+ function El(e) {
4083
4094
  for (var t = null; e !== null; )
4084
4095
  e instanceof ShadowRoot && (t = e.host, e = e.host), e = e.parentNode;
4085
4096
  return t;
4086
4097
  }
4087
- const El = Qs(io, Cl);
4088
- var fo = u.forwardRef(function(e, t) {
4089
- return u.createElement(Wt, we({}, e, { ref: t, sideCar: El }));
4098
+ const kl = Js(io, Sl);
4099
+ var fo = d.forwardRef(function(e, t) {
4100
+ return d.createElement(Wt, we({}, e, { ref: t, sideCar: kl }));
4090
4101
  });
4091
4102
  fo.classNames = Wt.classNames;
4092
- var kl = [" ", "Enter", "ArrowUp", "ArrowDown"], Tl = [" ", "Enter"], je = "Select", [Ut, Ht, Al] = Ja(je), [st, Mc] = yn(je, [
4093
- Al,
4103
+ var Tl = [" ", "Enter", "ArrowUp", "ArrowDown"], Al = [" ", "Enter"], je = "Select", [Ut, Ht, Pl] = ei(je), [st, Lc] = yn(je, [
4104
+ Pl,
4094
4105
  Yr
4095
- ]), jt = Yr(), [Pl, Fe] = st(je), [Il, Rl] = st(je), po = (e) => {
4106
+ ]), jt = Yr(), [Il, Fe] = st(je), [Rl, _l] = st(je), po = (e) => {
4096
4107
  const {
4097
4108
  __scopeSelect: t,
4098
4109
  children: n,
@@ -4108,19 +4119,19 @@ var kl = [" ", "Enter", "ArrowUp", "ArrowDown"], Tl = [" ", "Enter"], je = "Sele
4108
4119
  disabled: g,
4109
4120
  required: w,
4110
4121
  form: m
4111
- } = e, d = jt(t), [v, b] = u.useState(null), [x, y] = u.useState(null), [S, E] = u.useState(!1), T = ti(c), [C, I] = tr({
4122
+ } = e, u = jt(t), [v, b] = d.useState(null), [x, y] = d.useState(null), [C, S] = d.useState(!1), T = ni(c), [E, R] = tr({
4112
4123
  prop: r,
4113
4124
  defaultProp: o ?? !1,
4114
4125
  onChange: a,
4115
4126
  caller: je
4116
- }), [O, M] = tr({
4127
+ }), [M, L] = tr({
4117
4128
  prop: i,
4118
4129
  defaultProp: s,
4119
4130
  onChange: l,
4120
4131
  caller: je
4121
- }), V = u.useRef(null), $ = v ? m || !!v.closest("form") : !0, [D, N] = u.useState(/* @__PURE__ */ new Set()), X = Array.from(D).map((_) => _.props.value).join(";");
4122
- return /* @__PURE__ */ k(Ps, { ...d, children: /* @__PURE__ */ _t(
4123
- Pl,
4132
+ }), N = d.useRef(null), A = v ? m || !!v.closest("form") : !0, [D, B] = d.useState(/* @__PURE__ */ new Set()), K = Array.from(D).map((O) => O.props.value).join(";");
4133
+ return /* @__PURE__ */ k(Is, { ...u, children: /* @__PURE__ */ _t(
4134
+ Il,
4124
4135
  {
4125
4136
  required: w,
4126
4137
  scope: t,
@@ -4128,34 +4139,34 @@ var kl = [" ", "Enter", "ArrowUp", "ArrowDown"], Tl = [" ", "Enter"], je = "Sele
4128
4139
  onTriggerChange: b,
4129
4140
  valueNode: x,
4130
4141
  onValueNodeChange: y,
4131
- valueNodeHasChildren: S,
4132
- onValueNodeHasChildrenChange: E,
4142
+ valueNodeHasChildren: C,
4143
+ onValueNodeHasChildrenChange: S,
4133
4144
  contentId: Cn(),
4134
- value: O,
4135
- onValueChange: M,
4136
- open: C,
4137
- onOpenChange: I,
4145
+ value: M,
4146
+ onValueChange: L,
4147
+ open: E,
4148
+ onOpenChange: R,
4138
4149
  dir: T,
4139
- triggerPointerDownPosRef: V,
4150
+ triggerPointerDownPosRef: N,
4140
4151
  disabled: g,
4141
4152
  children: [
4142
4153
  /* @__PURE__ */ k(Ut.Provider, { scope: t, children: /* @__PURE__ */ k(
4143
- Il,
4154
+ Rl,
4144
4155
  {
4145
4156
  scope: e.__scopeSelect,
4146
- onNativeOptionAdd: u.useCallback((_) => {
4147
- N((L) => new Set(L).add(_));
4157
+ onNativeOptionAdd: d.useCallback((O) => {
4158
+ B((z) => new Set(z).add(O));
4148
4159
  }, []),
4149
- onNativeOptionRemove: u.useCallback((_) => {
4150
- N((L) => {
4151
- const R = new Set(L);
4152
- return R.delete(_), R;
4160
+ onNativeOptionRemove: d.useCallback((O) => {
4161
+ B((z) => {
4162
+ const _ = new Set(z);
4163
+ return _.delete(O), _;
4153
4164
  });
4154
4165
  }, []),
4155
4166
  children: n
4156
4167
  }
4157
4168
  ) }),
4158
- $ ? /* @__PURE__ */ _t(
4169
+ A ? /* @__PURE__ */ _t(
4159
4170
  Mo,
4160
4171
  {
4161
4172
  "aria-hidden": !0,
@@ -4163,35 +4174,35 @@ var kl = [" ", "Enter", "ArrowUp", "ArrowDown"], Tl = [" ", "Enter"], je = "Sele
4163
4174
  tabIndex: -1,
4164
4175
  name: f,
4165
4176
  autoComplete: p,
4166
- value: O,
4167
- onChange: (_) => M(_.target.value),
4177
+ value: M,
4178
+ onChange: (O) => L(O.target.value),
4168
4179
  disabled: g,
4169
4180
  form: m,
4170
4181
  children: [
4171
- O === void 0 ? /* @__PURE__ */ k("option", { value: "" }) : null,
4182
+ M === void 0 ? /* @__PURE__ */ k("option", { value: "" }) : null,
4172
4183
  Array.from(D)
4173
4184
  ]
4174
4185
  },
4175
- X
4186
+ K
4176
4187
  ) : null
4177
4188
  ]
4178
4189
  }
4179
4190
  ) });
4180
4191
  };
4181
4192
  po.displayName = je;
4182
- var ho = "SelectTrigger", vo = u.forwardRef(
4193
+ var ho = "SelectTrigger", vo = d.forwardRef(
4183
4194
  (e, t) => {
4184
- const { __scopeSelect: n, disabled: r = !1, ...o } = e, a = jt(n), i = Fe(ho, n), s = i.disabled || r, l = Z(t, i.onTriggerChange), c = Ht(n), f = u.useRef("touch"), [p, g, w] = Do((d) => {
4185
- const v = c().filter((y) => !y.disabled), b = v.find((y) => y.value === i.value), x = Bo(v, d, b);
4195
+ const { __scopeSelect: n, disabled: r = !1, ...o } = e, a = jt(n), i = Fe(ho, n), s = i.disabled || r, l = Z(t, i.onTriggerChange), c = Ht(n), f = d.useRef("touch"), [p, g, w] = Do((u) => {
4196
+ const v = c().filter((y) => !y.disabled), b = v.find((y) => y.value === i.value), x = Bo(v, u, b);
4186
4197
  x !== void 0 && i.onValueChange(x.value);
4187
- }), m = (d) => {
4188
- s || (i.onOpenChange(!0), w()), d && (i.triggerPointerDownPosRef.current = {
4189
- x: Math.round(d.pageX),
4190
- y: Math.round(d.pageY)
4198
+ }), m = (u) => {
4199
+ s || (i.onOpenChange(!0), w()), u && (i.triggerPointerDownPosRef.current = {
4200
+ x: Math.round(u.pageX),
4201
+ y: Math.round(u.pageY)
4191
4202
  });
4192
4203
  };
4193
- return /* @__PURE__ */ k(Is, { asChild: !0, ...a, children: /* @__PURE__ */ k(
4194
- K.button,
4204
+ return /* @__PURE__ */ k(Rs, { asChild: !0, ...a, children: /* @__PURE__ */ k(
4205
+ X.button,
4195
4206
  {
4196
4207
  type: "button",
4197
4208
  role: "combobox",
@@ -4206,30 +4217,30 @@ var ho = "SelectTrigger", vo = u.forwardRef(
4206
4217
  "data-placeholder": Lo(i.value) ? "" : void 0,
4207
4218
  ...o,
4208
4219
  ref: l,
4209
- onClick: G(o.onClick, (d) => {
4210
- d.currentTarget.focus(), f.current !== "mouse" && m(d);
4220
+ onClick: G(o.onClick, (u) => {
4221
+ u.currentTarget.focus(), f.current !== "mouse" && m(u);
4211
4222
  }),
4212
- onPointerDown: G(o.onPointerDown, (d) => {
4213
- f.current = d.pointerType;
4214
- const v = d.target;
4215
- v.hasPointerCapture(d.pointerId) && v.releasePointerCapture(d.pointerId), d.button === 0 && d.ctrlKey === !1 && d.pointerType === "mouse" && (m(d), d.preventDefault());
4223
+ onPointerDown: G(o.onPointerDown, (u) => {
4224
+ f.current = u.pointerType;
4225
+ const v = u.target;
4226
+ v.hasPointerCapture(u.pointerId) && v.releasePointerCapture(u.pointerId), u.button === 0 && u.ctrlKey === !1 && u.pointerType === "mouse" && (m(u), u.preventDefault());
4216
4227
  }),
4217
- onKeyDown: G(o.onKeyDown, (d) => {
4228
+ onKeyDown: G(o.onKeyDown, (u) => {
4218
4229
  const v = p.current !== "";
4219
- !(d.ctrlKey || d.altKey || d.metaKey) && d.key.length === 1 && g(d.key), !(v && d.key === " ") && kl.includes(d.key) && (m(), d.preventDefault());
4230
+ !(u.ctrlKey || u.altKey || u.metaKey) && u.key.length === 1 && g(u.key), !(v && u.key === " ") && Tl.includes(u.key) && (m(), u.preventDefault());
4220
4231
  })
4221
4232
  }
4222
4233
  ) });
4223
4234
  }
4224
4235
  );
4225
4236
  vo.displayName = ho;
4226
- var go = "SelectValue", _l = u.forwardRef(
4237
+ var go = "SelectValue", Nl = d.forwardRef(
4227
4238
  (e, t) => {
4228
4239
  const { __scopeSelect: n, className: r, style: o, children: a, placeholder: i = "", ...s } = e, l = Fe(go, n), { onValueNodeHasChildrenChange: c } = l, f = a !== void 0, p = Z(t, l.onValueNodeChange);
4229
4240
  return te(() => {
4230
4241
  c(f);
4231
4242
  }, [c, f]), /* @__PURE__ */ k(
4232
- K.span,
4243
+ X.span,
4233
4244
  {
4234
4245
  ...s,
4235
4246
  ref: p,
@@ -4239,24 +4250,24 @@ var go = "SelectValue", _l = u.forwardRef(
4239
4250
  );
4240
4251
  }
4241
4252
  );
4242
- _l.displayName = go;
4243
- var Nl = "SelectIcon", mo = u.forwardRef(
4253
+ Nl.displayName = go;
4254
+ var Ol = "SelectIcon", mo = d.forwardRef(
4244
4255
  (e, t) => {
4245
4256
  const { __scopeSelect: n, children: r, ...o } = e;
4246
- return /* @__PURE__ */ k(K.span, { "aria-hidden": !0, ...o, ref: t, children: r || "▼" });
4257
+ return /* @__PURE__ */ k(X.span, { "aria-hidden": !0, ...o, ref: t, children: r || "▼" });
4247
4258
  }
4248
4259
  );
4249
- mo.displayName = Nl;
4250
- var Ol = "SelectPortal", wo = (e) => /* @__PURE__ */ k(to, { asChild: !0, ...e });
4251
- wo.displayName = Ol;
4252
- var Ye = "SelectContent", bo = u.forwardRef(
4260
+ mo.displayName = Ol;
4261
+ var Ml = "SelectPortal", wo = (e) => /* @__PURE__ */ k(to, { asChild: !0, ...e });
4262
+ wo.displayName = Ml;
4263
+ var Ye = "SelectContent", bo = d.forwardRef(
4253
4264
  (e, t) => {
4254
- const n = Fe(Ye, e.__scopeSelect), [r, o] = u.useState();
4265
+ const n = Fe(Ye, e.__scopeSelect), [r, o] = d.useState();
4255
4266
  if (te(() => {
4256
4267
  o(new DocumentFragment());
4257
4268
  }, []), !n.open) {
4258
4269
  const a = r;
4259
- return a ? u.createPortal(
4270
+ return a ? d.createPortal(
4260
4271
  /* @__PURE__ */ k(xo, { scope: e.__scopeSelect, children: /* @__PURE__ */ k(Ut.Slot, { scope: e.__scopeSelect, children: /* @__PURE__ */ k("div", { children: e.children }) }) }),
4261
4272
  a
4262
4273
  ) : null;
@@ -4265,7 +4276,7 @@ var Ye = "SelectContent", bo = u.forwardRef(
4265
4276
  }
4266
4277
  );
4267
4278
  bo.displayName = Ye;
4268
- var ue = 10, [xo, Ve] = st(Ye), Ml = "SelectContentImpl", Ll = /* @__PURE__ */ vt("SelectContent.RemoveScroll"), yo = u.forwardRef(
4279
+ var ue = 10, [xo, Ve] = st(Ye), Ll = "SelectContentImpl", Dl = /* @__PURE__ */ vt("SelectContent.RemoveScroll"), yo = d.forwardRef(
4269
4280
  (e, t) => {
4270
4281
  const {
4271
4282
  __scopeSelect: n,
@@ -4283,69 +4294,69 @@ var ue = 10, [xo, Ve] = st(Ye), Ml = "SelectContentImpl", Ll = /* @__PURE__ */ v
4283
4294
  collisionBoundary: g,
4284
4295
  collisionPadding: w,
4285
4296
  sticky: m,
4286
- hideWhenDetached: d,
4297
+ hideWhenDetached: u,
4287
4298
  avoidCollisions: v,
4288
4299
  //
4289
4300
  ...b
4290
- } = e, x = Fe(Ye, n), [y, S] = u.useState(null), [E, T] = u.useState(null), C = Z(t, (A) => S(A)), [I, O] = u.useState(null), [M, V] = u.useState(
4301
+ } = e, x = Fe(Ye, n), [y, C] = d.useState(null), [S, T] = d.useState(null), E = Z(t, (P) => C(P)), [R, M] = d.useState(null), [L, N] = d.useState(
4291
4302
  null
4292
- ), $ = Ht(n), [D, N] = u.useState(!1), X = u.useRef(!1);
4293
- u.useEffect(() => {
4294
- if (y) return Ws(y);
4295
- }, [y]), fi();
4296
- const _ = u.useCallback(
4297
- (A) => {
4298
- const [U, ...Q] = $().map((z) => z.ref.current), [F] = Q.slice(-1), B = document.activeElement;
4299
- for (const z of A)
4300
- if (z === B || (z == null || z.scrollIntoView({ block: "nearest" }), z === U && E && (E.scrollTop = 0), z === F && E && (E.scrollTop = E.scrollHeight), z == null || z.focus(), document.activeElement !== B)) return;
4303
+ ), A = Ht(n), [D, B] = d.useState(!1), K = d.useRef(!1);
4304
+ d.useEffect(() => {
4305
+ if (y) return Us(y);
4306
+ }, [y]), pi();
4307
+ const O = d.useCallback(
4308
+ (P) => {
4309
+ const [H, ...Q] = A().map((V) => V.ref.current), [$] = Q.slice(-1), F = document.activeElement;
4310
+ for (const V of P)
4311
+ if (V === F || (V == null || V.scrollIntoView({ block: "nearest" }), V === H && S && (S.scrollTop = 0), V === $ && S && (S.scrollTop = S.scrollHeight), V == null || V.focus(), document.activeElement !== F)) return;
4301
4312
  },
4302
- [$, E]
4303
- ), L = u.useCallback(
4304
- () => _([I, y]),
4305
- [_, I, y]
4313
+ [A, S]
4314
+ ), z = d.useCallback(
4315
+ () => O([R, y]),
4316
+ [O, R, y]
4306
4317
  );
4307
- u.useEffect(() => {
4308
- D && L();
4309
- }, [D, L]);
4310
- const { onOpenChange: R, triggerPointerDownPosRef: W } = x;
4311
- u.useEffect(() => {
4318
+ d.useEffect(() => {
4319
+ D && z();
4320
+ }, [D, z]);
4321
+ const { onOpenChange: _, triggerPointerDownPosRef: U } = x;
4322
+ d.useEffect(() => {
4312
4323
  if (y) {
4313
- let A = { x: 0, y: 0 };
4314
- const U = (F) => {
4315
- var B, z;
4316
- A = {
4317
- x: Math.abs(Math.round(F.pageX) - (((B = W.current) == null ? void 0 : B.x) ?? 0)),
4318
- y: Math.abs(Math.round(F.pageY) - (((z = W.current) == null ? void 0 : z.y) ?? 0))
4324
+ let P = { x: 0, y: 0 };
4325
+ const H = ($) => {
4326
+ var F, V;
4327
+ P = {
4328
+ x: Math.abs(Math.round($.pageX) - (((F = U.current) == null ? void 0 : F.x) ?? 0)),
4329
+ y: Math.abs(Math.round($.pageY) - (((V = U.current) == null ? void 0 : V.y) ?? 0))
4319
4330
  };
4320
- }, Q = (F) => {
4321
- A.x <= 10 && A.y <= 10 ? F.preventDefault() : y.contains(F.target) || R(!1), document.removeEventListener("pointermove", U), W.current = null;
4331
+ }, Q = ($) => {
4332
+ P.x <= 10 && P.y <= 10 ? $.preventDefault() : y.contains($.target) || _(!1), document.removeEventListener("pointermove", H), U.current = null;
4322
4333
  };
4323
- return W.current !== null && (document.addEventListener("pointermove", U), document.addEventListener("pointerup", Q, { capture: !0, once: !0 })), () => {
4324
- document.removeEventListener("pointermove", U), document.removeEventListener("pointerup", Q, { capture: !0 });
4334
+ return U.current !== null && (document.addEventListener("pointermove", H), document.addEventListener("pointerup", Q, { capture: !0, once: !0 })), () => {
4335
+ document.removeEventListener("pointermove", H), document.removeEventListener("pointerup", Q, { capture: !0 });
4325
4336
  };
4326
4337
  }
4327
- }, [y, R, W]), u.useEffect(() => {
4328
- const A = () => R(!1);
4329
- return window.addEventListener("blur", A), window.addEventListener("resize", A), () => {
4330
- window.removeEventListener("blur", A), window.removeEventListener("resize", A);
4338
+ }, [y, _, U]), d.useEffect(() => {
4339
+ const P = () => _(!1);
4340
+ return window.addEventListener("blur", P), window.addEventListener("resize", P), () => {
4341
+ window.removeEventListener("blur", P), window.removeEventListener("resize", P);
4331
4342
  };
4332
- }, [R]);
4333
- const [ee, Ee] = Do((A) => {
4334
- const U = $().filter((B) => !B.disabled), Q = U.find((B) => B.ref.current === document.activeElement), F = Bo(U, A, Q);
4335
- F && setTimeout(() => F.ref.current.focus());
4336
- }), lt = u.useCallback(
4337
- (A, U, Q) => {
4338
- const F = !X.current && !Q;
4339
- (x.value !== void 0 && x.value === U || F) && (O(A), F && (X.current = !0));
4343
+ }, [_]);
4344
+ const [ee, Ee] = Do((P) => {
4345
+ const H = A().filter((F) => !F.disabled), Q = H.find((F) => F.ref.current === document.activeElement), $ = Bo(H, P, Q);
4346
+ $ && setTimeout(() => $.ref.current.focus());
4347
+ }), lt = d.useCallback(
4348
+ (P, H, Q) => {
4349
+ const $ = !K.current && !Q;
4350
+ (x.value !== void 0 && x.value === H || $) && (M(P), $ && (K.current = !0));
4340
4351
  },
4341
4352
  [x.value]
4342
- ), ct = u.useCallback(() => y == null ? void 0 : y.focus(), [y]), Re = u.useCallback(
4343
- (A, U, Q) => {
4344
- const F = !X.current && !Q;
4345
- (x.value !== void 0 && x.value === U || F) && V(A);
4353
+ ), ct = d.useCallback(() => y == null ? void 0 : y.focus(), [y]), Re = d.useCallback(
4354
+ (P, H, Q) => {
4355
+ const $ = !K.current && !Q;
4356
+ (x.value !== void 0 && x.value === H || $) && N(P);
4346
4357
  },
4347
4358
  [x.value]
4348
- ), Xe = r === "popper" ? fn : Co, $e = Xe === fn ? {
4359
+ ), Ke = r === "popper" ? fn : Co, $e = Ke === fn ? {
4349
4360
  side: s,
4350
4361
  sideOffset: l,
4351
4362
  align: c,
@@ -4354,7 +4365,7 @@ var ue = 10, [xo, Ve] = st(Ye), Ml = "SelectContentImpl", Ll = /* @__PURE__ */ v
4354
4365
  collisionBoundary: g,
4355
4366
  collisionPadding: w,
4356
4367
  sticky: m,
4357
- hideWhenDetached: d,
4368
+ hideWhenDetached: u,
4358
4369
  avoidCollisions: v
4359
4370
  } : {};
4360
4371
  return /* @__PURE__ */ k(
@@ -4362,28 +4373,28 @@ var ue = 10, [xo, Ve] = st(Ye), Ml = "SelectContentImpl", Ll = /* @__PURE__ */ v
4362
4373
  {
4363
4374
  scope: n,
4364
4375
  content: y,
4365
- viewport: E,
4376
+ viewport: S,
4366
4377
  onViewportChange: T,
4367
4378
  itemRefCallback: lt,
4368
- selectedItem: I,
4379
+ selectedItem: R,
4369
4380
  onItemLeave: ct,
4370
4381
  itemTextRefCallback: Re,
4371
- focusSelectedItem: L,
4372
- selectedItemText: M,
4382
+ focusSelectedItem: z,
4383
+ selectedItemText: L,
4373
4384
  position: r,
4374
4385
  isPositioned: D,
4375
4386
  searchRef: ee,
4376
- children: /* @__PURE__ */ k(fo, { as: Ll, allowPinchZoom: !0, children: /* @__PURE__ */ k(
4387
+ children: /* @__PURE__ */ k(fo, { as: Dl, allowPinchZoom: !0, children: /* @__PURE__ */ k(
4377
4388
  Nr,
4378
4389
  {
4379
4390
  asChild: !0,
4380
4391
  trapped: x.open,
4381
- onMountAutoFocus: (A) => {
4382
- A.preventDefault();
4392
+ onMountAutoFocus: (P) => {
4393
+ P.preventDefault();
4383
4394
  },
4384
- onUnmountAutoFocus: G(o, (A) => {
4385
- var U;
4386
- (U = x.trigger) == null || U.focus({ preventScroll: !0 }), A.preventDefault();
4395
+ onUnmountAutoFocus: G(o, (P) => {
4396
+ var H;
4397
+ (H = x.trigger) == null || H.focus({ preventScroll: !0 }), P.preventDefault();
4387
4398
  }),
4388
4399
  children: /* @__PURE__ */ k(
4389
4400
  Rr,
@@ -4392,20 +4403,20 @@ var ue = 10, [xo, Ve] = st(Ye), Ml = "SelectContentImpl", Ll = /* @__PURE__ */ v
4392
4403
  disableOutsidePointerEvents: !0,
4393
4404
  onEscapeKeyDown: a,
4394
4405
  onPointerDownOutside: i,
4395
- onFocusOutside: (A) => A.preventDefault(),
4406
+ onFocusOutside: (P) => P.preventDefault(),
4396
4407
  onDismiss: () => x.onOpenChange(!1),
4397
4408
  children: /* @__PURE__ */ k(
4398
- Xe,
4409
+ Ke,
4399
4410
  {
4400
4411
  role: "listbox",
4401
4412
  id: x.contentId,
4402
4413
  "data-state": x.open ? "open" : "closed",
4403
4414
  dir: x.dir,
4404
- onContextMenu: (A) => A.preventDefault(),
4415
+ onContextMenu: (P) => P.preventDefault(),
4405
4416
  ...b,
4406
4417
  ...$e,
4407
- onPlaced: () => N(!0),
4408
- ref: C,
4418
+ onPlaced: () => B(!0),
4419
+ ref: E,
4409
4420
  style: {
4410
4421
  // flex layout so we can place the scroll buttons properly
4411
4422
  display: "flex",
@@ -4414,15 +4425,15 @@ var ue = 10, [xo, Ve] = st(Ye), Ml = "SelectContentImpl", Ll = /* @__PURE__ */ v
4414
4425
  outline: "none",
4415
4426
  ...b.style
4416
4427
  },
4417
- onKeyDown: G(b.onKeyDown, (A) => {
4418
- const U = A.ctrlKey || A.altKey || A.metaKey;
4419
- if (A.key === "Tab" && A.preventDefault(), !U && A.key.length === 1 && Ee(A.key), ["ArrowUp", "ArrowDown", "Home", "End"].includes(A.key)) {
4420
- let F = $().filter((B) => !B.disabled).map((B) => B.ref.current);
4421
- if (["ArrowUp", "End"].includes(A.key) && (F = F.slice().reverse()), ["ArrowUp", "ArrowDown"].includes(A.key)) {
4422
- const B = A.target, z = F.indexOf(B);
4423
- F = F.slice(z + 1);
4428
+ onKeyDown: G(b.onKeyDown, (P) => {
4429
+ const H = P.ctrlKey || P.altKey || P.metaKey;
4430
+ if (P.key === "Tab" && P.preventDefault(), !H && P.key.length === 1 && Ee(P.key), ["ArrowUp", "ArrowDown", "Home", "End"].includes(P.key)) {
4431
+ let $ = A().filter((F) => !F.disabled).map((F) => F.ref.current);
4432
+ if (["ArrowUp", "End"].includes(P.key) && ($ = $.slice().reverse()), ["ArrowUp", "ArrowDown"].includes(P.key)) {
4433
+ const F = P.target, V = $.indexOf(F);
4434
+ $ = $.slice(V + 1);
4424
4435
  }
4425
- setTimeout(() => _(F)), A.preventDefault();
4436
+ setTimeout(() => O($)), P.preventDefault();
4426
4437
  }
4427
4438
  })
4428
4439
  }
@@ -4435,13 +4446,13 @@ var ue = 10, [xo, Ve] = st(Ye), Ml = "SelectContentImpl", Ll = /* @__PURE__ */ v
4435
4446
  );
4436
4447
  }
4437
4448
  );
4438
- yo.displayName = Ml;
4439
- var Dl = "SelectItemAlignedPosition", Co = u.forwardRef((e, t) => {
4440
- const { __scopeSelect: n, onPlaced: r, ...o } = e, a = Fe(Ye, n), i = Ve(Ye, n), [s, l] = u.useState(null), [c, f] = u.useState(null), p = Z(t, (C) => f(C)), g = Ht(n), w = u.useRef(!1), m = u.useRef(!0), { viewport: d, selectedItem: v, selectedItemText: b, focusSelectedItem: x } = i, y = u.useCallback(() => {
4441
- if (a.trigger && a.valueNode && s && c && d && v && b) {
4442
- const C = a.trigger.getBoundingClientRect(), I = c.getBoundingClientRect(), O = a.valueNode.getBoundingClientRect(), M = b.getBoundingClientRect();
4449
+ yo.displayName = Ll;
4450
+ var Bl = "SelectItemAlignedPosition", Co = d.forwardRef((e, t) => {
4451
+ const { __scopeSelect: n, onPlaced: r, ...o } = e, a = Fe(Ye, n), i = Ve(Ye, n), [s, l] = d.useState(null), [c, f] = d.useState(null), p = Z(t, (E) => f(E)), g = Ht(n), w = d.useRef(!1), m = d.useRef(!0), { viewport: u, selectedItem: v, selectedItemText: b, focusSelectedItem: x } = i, y = d.useCallback(() => {
4452
+ if (a.trigger && a.valueNode && s && c && u && v && b) {
4453
+ const E = a.trigger.getBoundingClientRect(), R = c.getBoundingClientRect(), M = a.valueNode.getBoundingClientRect(), L = b.getBoundingClientRect();
4443
4454
  if (a.dir !== "rtl") {
4444
- const B = M.left - I.left, z = O.left - B, oe = C.left - z, ge = C.width + oe, ut = Math.max(ge, I.width), dt = window.innerWidth - ue, ft = Fn(z, [
4455
+ const F = L.left - R.left, V = M.left - F, oe = E.left - V, ge = E.width + oe, ut = Math.max(ge, R.width), dt = window.innerWidth - ue, ft = Fn(V, [
4445
4456
  ue,
4446
4457
  // Prevents the content from going off the starting edge of the
4447
4458
  // viewport. It may still go off the ending edge, but this can be
@@ -4452,33 +4463,33 @@ var Dl = "SelectItemAlignedPosition", Co = u.forwardRef((e, t) => {
4452
4463
  ]);
4453
4464
  s.style.minWidth = ge + "px", s.style.left = ft + "px";
4454
4465
  } else {
4455
- const B = I.right - M.right, z = window.innerWidth - O.right - B, oe = window.innerWidth - C.right - z, ge = C.width + oe, ut = Math.max(ge, I.width), dt = window.innerWidth - ue, ft = Fn(z, [
4466
+ const F = R.right - L.right, V = window.innerWidth - M.right - F, oe = window.innerWidth - E.right - V, ge = E.width + oe, ut = Math.max(ge, R.width), dt = window.innerWidth - ue, ft = Fn(V, [
4456
4467
  ue,
4457
4468
  Math.max(ue, dt - ut)
4458
4469
  ]);
4459
4470
  s.style.minWidth = ge + "px", s.style.right = ft + "px";
4460
4471
  }
4461
- const V = g(), $ = window.innerHeight - ue * 2, D = d.scrollHeight, N = window.getComputedStyle(c), X = parseInt(N.borderTopWidth, 10), _ = parseInt(N.paddingTop, 10), L = parseInt(N.borderBottomWidth, 10), R = parseInt(N.paddingBottom, 10), W = X + _ + D + R + L, ee = Math.min(v.offsetHeight * 5, W), Ee = window.getComputedStyle(d), lt = parseInt(Ee.paddingTop, 10), ct = parseInt(Ee.paddingBottom, 10), Re = C.top + C.height / 2 - ue, Xe = $ - Re, $e = v.offsetHeight / 2, A = v.offsetTop + $e, U = X + _ + A, Q = W - U;
4462
- if (U <= Re) {
4463
- const B = V.length > 0 && v === V[V.length - 1].ref.current;
4472
+ const N = g(), A = window.innerHeight - ue * 2, D = u.scrollHeight, B = window.getComputedStyle(c), K = parseInt(B.borderTopWidth, 10), O = parseInt(B.paddingTop, 10), z = parseInt(B.borderBottomWidth, 10), _ = parseInt(B.paddingBottom, 10), U = K + O + D + _ + z, ee = Math.min(v.offsetHeight * 5, U), Ee = window.getComputedStyle(u), lt = parseInt(Ee.paddingTop, 10), ct = parseInt(Ee.paddingBottom, 10), Re = E.top + E.height / 2 - ue, Ke = A - Re, $e = v.offsetHeight / 2, P = v.offsetTop + $e, H = K + O + P, Q = U - H;
4473
+ if (H <= Re) {
4474
+ const F = N.length > 0 && v === N[N.length - 1].ref.current;
4464
4475
  s.style.bottom = "0px";
4465
- const z = c.clientHeight - d.offsetTop - d.offsetHeight, oe = Math.max(
4466
- Xe,
4476
+ const V = c.clientHeight - u.offsetTop - u.offsetHeight, oe = Math.max(
4477
+ Ke,
4467
4478
  $e + // viewport might have padding bottom, include it to avoid a scrollable viewport
4468
- (B ? ct : 0) + z + L
4469
- ), ge = U + oe;
4479
+ (F ? ct : 0) + V + z
4480
+ ), ge = H + oe;
4470
4481
  s.style.height = ge + "px";
4471
4482
  } else {
4472
- const B = V.length > 0 && v === V[0].ref.current;
4483
+ const F = N.length > 0 && v === N[0].ref.current;
4473
4484
  s.style.top = "0px";
4474
4485
  const oe = Math.max(
4475
4486
  Re,
4476
- X + d.offsetTop + // viewport might have padding top, include it to avoid a scrollable viewport
4477
- (B ? lt : 0) + $e
4487
+ K + u.offsetTop + // viewport might have padding top, include it to avoid a scrollable viewport
4488
+ (F ? lt : 0) + $e
4478
4489
  ) + Q;
4479
- s.style.height = oe + "px", d.scrollTop = U - Re + d.offsetTop;
4490
+ s.style.height = oe + "px", u.scrollTop = H - Re + u.offsetTop;
4480
4491
  }
4481
- s.style.margin = `${ue}px 0`, s.style.minHeight = ee + "px", s.style.maxHeight = $ + "px", r == null || r(), requestAnimationFrame(() => w.current = !0);
4492
+ s.style.margin = `${ue}px 0`, s.style.minHeight = ee + "px", s.style.maxHeight = A + "px", r == null || r(), requestAnimationFrame(() => w.current = !0);
4482
4493
  }
4483
4494
  }, [
4484
4495
  g,
@@ -4486,25 +4497,25 @@ var Dl = "SelectItemAlignedPosition", Co = u.forwardRef((e, t) => {
4486
4497
  a.valueNode,
4487
4498
  s,
4488
4499
  c,
4489
- d,
4500
+ u,
4490
4501
  v,
4491
4502
  b,
4492
4503
  a.dir,
4493
4504
  r
4494
4505
  ]);
4495
4506
  te(() => y(), [y]);
4496
- const [S, E] = u.useState();
4507
+ const [C, S] = d.useState();
4497
4508
  te(() => {
4498
- c && E(window.getComputedStyle(c).zIndex);
4509
+ c && S(window.getComputedStyle(c).zIndex);
4499
4510
  }, [c]);
4500
- const T = u.useCallback(
4501
- (C) => {
4502
- C && m.current === !0 && (y(), x == null || x(), m.current = !1);
4511
+ const T = d.useCallback(
4512
+ (E) => {
4513
+ E && m.current === !0 && (y(), x == null || x(), m.current = !1);
4503
4514
  },
4504
4515
  [y, x]
4505
4516
  );
4506
4517
  return /* @__PURE__ */ k(
4507
- zl,
4518
+ Fl,
4508
4519
  {
4509
4520
  scope: n,
4510
4521
  contentWrapper: s,
@@ -4518,10 +4529,10 @@ var Dl = "SelectItemAlignedPosition", Co = u.forwardRef((e, t) => {
4518
4529
  display: "flex",
4519
4530
  flexDirection: "column",
4520
4531
  position: "fixed",
4521
- zIndex: S
4532
+ zIndex: C
4522
4533
  },
4523
4534
  children: /* @__PURE__ */ k(
4524
- K.div,
4535
+ X.div,
4525
4536
  {
4526
4537
  ...o,
4527
4538
  ref: p,
@@ -4540,8 +4551,8 @@ var Dl = "SelectItemAlignedPosition", Co = u.forwardRef((e, t) => {
4540
4551
  }
4541
4552
  );
4542
4553
  });
4543
- Co.displayName = Dl;
4544
- var Bl = "SelectPopperPosition", fn = u.forwardRef((e, t) => {
4554
+ Co.displayName = Bl;
4555
+ var zl = "SelectPopperPosition", fn = d.forwardRef((e, t) => {
4545
4556
  const {
4546
4557
  __scopeSelect: n,
4547
4558
  align: r = "start",
@@ -4549,7 +4560,7 @@ var Bl = "SelectPopperPosition", fn = u.forwardRef((e, t) => {
4549
4560
  ...a
4550
4561
  } = e, i = jt(n);
4551
4562
  return /* @__PURE__ */ k(
4552
- Rs,
4563
+ _s,
4553
4564
  {
4554
4565
  ...i,
4555
4566
  ...a,
@@ -4569,10 +4580,10 @@ var Bl = "SelectPopperPosition", fn = u.forwardRef((e, t) => {
4569
4580
  }
4570
4581
  );
4571
4582
  });
4572
- fn.displayName = Bl;
4573
- var [zl, Nn] = st(Ye, {}), pn = "SelectViewport", So = u.forwardRef(
4583
+ fn.displayName = zl;
4584
+ var [Fl, Nn] = st(Ye, {}), pn = "SelectViewport", So = d.forwardRef(
4574
4585
  (e, t) => {
4575
- const { __scopeSelect: n, nonce: r, ...o } = e, a = Ve(pn, n), i = Nn(pn, n), s = Z(t, a.onViewportChange), l = u.useRef(0);
4586
+ const { __scopeSelect: n, nonce: r, ...o } = e, a = Ve(pn, n), i = Nn(pn, n), s = Z(t, a.onViewportChange), l = d.useRef(0);
4576
4587
  return /* @__PURE__ */ _t(mn, { children: [
4577
4588
  /* @__PURE__ */ k(
4578
4589
  "style",
@@ -4584,7 +4595,7 @@ var [zl, Nn] = st(Ye, {}), pn = "SelectViewport", So = u.forwardRef(
4584
4595
  }
4585
4596
  ),
4586
4597
  /* @__PURE__ */ k(Ut.Slot, { scope: n, children: /* @__PURE__ */ k(
4587
- K.div,
4598
+ X.div,
4588
4599
  {
4589
4600
  "data-radix-select-viewport": "",
4590
4601
  role: "presentation",
@@ -4608,10 +4619,10 @@ var [zl, Nn] = st(Ye, {}), pn = "SelectViewport", So = u.forwardRef(
4608
4619
  if (g != null && g.current && p) {
4609
4620
  const w = Math.abs(l.current - f.scrollTop);
4610
4621
  if (w > 0) {
4611
- const m = window.innerHeight - ue * 2, d = parseFloat(p.style.minHeight), v = parseFloat(p.style.height), b = Math.max(d, v);
4622
+ const m = window.innerHeight - ue * 2, u = parseFloat(p.style.minHeight), v = parseFloat(p.style.height), b = Math.max(u, v);
4612
4623
  if (b < m) {
4613
- const x = b + w, y = Math.min(m, x), S = x - y;
4614
- p.style.height = y + "px", p.style.bottom === "0px" && (f.scrollTop = S > 0 ? S : 0, p.style.justifyContent = "flex-end");
4624
+ const x = b + w, y = Math.min(m, x), C = x - y;
4625
+ p.style.height = y + "px", p.style.bottom === "0px" && (f.scrollTop = C > 0 ? C : 0, p.style.justifyContent = "flex-end");
4615
4626
  }
4616
4627
  }
4617
4628
  }
@@ -4623,21 +4634,21 @@ var [zl, Nn] = st(Ye, {}), pn = "SelectViewport", So = u.forwardRef(
4623
4634
  }
4624
4635
  );
4625
4636
  So.displayName = pn;
4626
- var Eo = "SelectGroup", [Fl, Vl] = st(Eo), $l = u.forwardRef(
4637
+ var Eo = "SelectGroup", [Vl, $l] = st(Eo), Wl = d.forwardRef(
4627
4638
  (e, t) => {
4628
4639
  const { __scopeSelect: n, ...r } = e, o = Cn();
4629
- return /* @__PURE__ */ k(Fl, { scope: n, id: o, children: /* @__PURE__ */ k(K.div, { role: "group", "aria-labelledby": o, ...r, ref: t }) });
4640
+ return /* @__PURE__ */ k(Vl, { scope: n, id: o, children: /* @__PURE__ */ k(X.div, { role: "group", "aria-labelledby": o, ...r, ref: t }) });
4630
4641
  }
4631
4642
  );
4632
- $l.displayName = Eo;
4633
- var ko = "SelectLabel", Wl = u.forwardRef(
4643
+ Wl.displayName = Eo;
4644
+ var ko = "SelectLabel", Ul = d.forwardRef(
4634
4645
  (e, t) => {
4635
- const { __scopeSelect: n, ...r } = e, o = Vl(ko, n);
4636
- return /* @__PURE__ */ k(K.div, { id: o.id, ...r, ref: t });
4646
+ const { __scopeSelect: n, ...r } = e, o = $l(ko, n);
4647
+ return /* @__PURE__ */ k(X.div, { id: o.id, ...r, ref: t });
4637
4648
  }
4638
4649
  );
4639
- Wl.displayName = ko;
4640
- var Dt = "SelectItem", [Ul, To] = st(Dt), Ao = u.forwardRef(
4650
+ Ul.displayName = ko;
4651
+ var Dt = "SelectItem", [Hl, To] = st(Dt), Ao = d.forwardRef(
4641
4652
  (e, t) => {
4642
4653
  const {
4643
4654
  __scopeSelect: n,
@@ -4645,13 +4656,13 @@ var Dt = "SelectItem", [Ul, To] = st(Dt), Ao = u.forwardRef(
4645
4656
  disabled: o = !1,
4646
4657
  textValue: a,
4647
4658
  ...i
4648
- } = e, s = Fe(Dt, n), l = Ve(Dt, n), c = s.value === r, [f, p] = u.useState(a ?? ""), [g, w] = u.useState(!1), m = Z(
4659
+ } = e, s = Fe(Dt, n), l = Ve(Dt, n), c = s.value === r, [f, p] = d.useState(a ?? ""), [g, w] = d.useState(!1), m = Z(
4649
4660
  t,
4650
4661
  (x) => {
4651
4662
  var y;
4652
4663
  return (y = l.itemRefCallback) == null ? void 0 : y.call(l, x, r, o);
4653
4664
  }
4654
- ), d = Cn(), v = u.useRef("touch"), b = () => {
4665
+ ), u = Cn(), v = d.useRef("touch"), b = () => {
4655
4666
  o || (s.onValueChange(r), s.onOpenChange(!1));
4656
4667
  };
4657
4668
  if (r === "")
@@ -4659,14 +4670,14 @@ var Dt = "SelectItem", [Ul, To] = st(Dt), Ao = u.forwardRef(
4659
4670
  "A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder."
4660
4671
  );
4661
4672
  return /* @__PURE__ */ k(
4662
- Ul,
4673
+ Hl,
4663
4674
  {
4664
4675
  scope: n,
4665
4676
  value: r,
4666
4677
  disabled: o,
4667
- textId: d,
4678
+ textId: u,
4668
4679
  isSelected: c,
4669
- onItemTextChange: u.useCallback((x) => {
4680
+ onItemTextChange: d.useCallback((x) => {
4670
4681
  p((y) => y || ((x == null ? void 0 : x.textContent) ?? "").trim());
4671
4682
  }, []),
4672
4683
  children: /* @__PURE__ */ k(
@@ -4677,10 +4688,10 @@ var Dt = "SelectItem", [Ul, To] = st(Dt), Ao = u.forwardRef(
4677
4688
  disabled: o,
4678
4689
  textValue: f,
4679
4690
  children: /* @__PURE__ */ k(
4680
- K.div,
4691
+ X.div,
4681
4692
  {
4682
4693
  role: "option",
4683
- "aria-labelledby": d,
4694
+ "aria-labelledby": u,
4684
4695
  "data-highlighted": g ? "" : void 0,
4685
4696
  "aria-selected": c && g,
4686
4697
  "data-state": c ? "checked" : "unchecked",
@@ -4709,8 +4720,8 @@ var Dt = "SelectItem", [Ul, To] = st(Dt), Ao = u.forwardRef(
4709
4720
  x.currentTarget === document.activeElement && ((y = l.onItemLeave) == null || y.call(l));
4710
4721
  }),
4711
4722
  onKeyDown: G(i.onKeyDown, (x) => {
4712
- var S;
4713
- ((S = l.searchRef) == null ? void 0 : S.current) !== "" && x.key === " " || (Tl.includes(x.key) && b(), x.key === " " && x.preventDefault());
4723
+ var C;
4724
+ ((C = l.searchRef) == null ? void 0 : C.current) !== "" && x.key === " " || (Al.includes(x.key) && b(), x.key === " " && x.preventDefault());
4714
4725
  })
4715
4726
  }
4716
4727
  )
@@ -4721,9 +4732,9 @@ var Dt = "SelectItem", [Ul, To] = st(Dt), Ao = u.forwardRef(
4721
4732
  }
4722
4733
  );
4723
4734
  Ao.displayName = Dt;
4724
- var ht = "SelectItemText", Po = u.forwardRef(
4735
+ var ht = "SelectItemText", Po = d.forwardRef(
4725
4736
  (e, t) => {
4726
- const { __scopeSelect: n, className: r, style: o, ...a } = e, i = Fe(ht, n), s = Ve(ht, n), l = To(ht, n), c = Rl(ht, n), [f, p] = u.useState(null), g = Z(
4737
+ const { __scopeSelect: n, className: r, style: o, ...a } = e, i = Fe(ht, n), s = Ve(ht, n), l = To(ht, n), c = _l(ht, n), [f, p] = d.useState(null), g = Z(
4727
4738
  t,
4728
4739
  (b) => p(b),
4729
4740
  l.onItemTextChange,
@@ -4731,26 +4742,26 @@ var ht = "SelectItemText", Po = u.forwardRef(
4731
4742
  var x;
4732
4743
  return (x = s.itemTextRefCallback) == null ? void 0 : x.call(s, b, l.value, l.disabled);
4733
4744
  }
4734
- ), w = f == null ? void 0 : f.textContent, m = u.useMemo(
4745
+ ), w = f == null ? void 0 : f.textContent, m = d.useMemo(
4735
4746
  () => /* @__PURE__ */ k("option", { value: l.value, disabled: l.disabled, children: w }, l.value),
4736
4747
  [l.disabled, l.value, w]
4737
- ), { onNativeOptionAdd: d, onNativeOptionRemove: v } = c;
4738
- return te(() => (d(m), () => v(m)), [d, v, m]), /* @__PURE__ */ _t(mn, { children: [
4739
- /* @__PURE__ */ k(K.span, { id: l.textId, ...a, ref: g }),
4740
- l.isSelected && i.valueNode && !i.valueNodeHasChildren ? u.createPortal(a.children, i.valueNode) : null
4748
+ ), { onNativeOptionAdd: u, onNativeOptionRemove: v } = c;
4749
+ return te(() => (u(m), () => v(m)), [u, v, m]), /* @__PURE__ */ _t(mn, { children: [
4750
+ /* @__PURE__ */ k(X.span, { id: l.textId, ...a, ref: g }),
4751
+ l.isSelected && i.valueNode && !i.valueNodeHasChildren ? d.createPortal(a.children, i.valueNode) : null
4741
4752
  ] });
4742
4753
  }
4743
4754
  );
4744
4755
  Po.displayName = ht;
4745
- var Io = "SelectItemIndicator", Ro = u.forwardRef(
4756
+ var Io = "SelectItemIndicator", Ro = d.forwardRef(
4746
4757
  (e, t) => {
4747
4758
  const { __scopeSelect: n, ...r } = e;
4748
- return To(Io, n).isSelected ? /* @__PURE__ */ k(K.span, { "aria-hidden": !0, ...r, ref: t }) : null;
4759
+ return To(Io, n).isSelected ? /* @__PURE__ */ k(X.span, { "aria-hidden": !0, ...r, ref: t }) : null;
4749
4760
  }
4750
4761
  );
4751
4762
  Ro.displayName = Io;
4752
- var hn = "SelectScrollUpButton", _o = u.forwardRef((e, t) => {
4753
- const n = Ve(hn, e.__scopeSelect), r = Nn(hn, e.__scopeSelect), [o, a] = u.useState(!1), i = Z(t, r.onScrollButtonChange);
4763
+ var hn = "SelectScrollUpButton", _o = d.forwardRef((e, t) => {
4764
+ const n = Ve(hn, e.__scopeSelect), r = Nn(hn, e.__scopeSelect), [o, a] = d.useState(!1), i = Z(t, r.onScrollButtonChange);
4754
4765
  return te(() => {
4755
4766
  if (n.viewport && n.isPositioned) {
4756
4767
  let s = function() {
@@ -4773,8 +4784,8 @@ var hn = "SelectScrollUpButton", _o = u.forwardRef((e, t) => {
4773
4784
  ) : null;
4774
4785
  });
4775
4786
  _o.displayName = hn;
4776
- var vn = "SelectScrollDownButton", No = u.forwardRef((e, t) => {
4777
- const n = Ve(vn, e.__scopeSelect), r = Nn(vn, e.__scopeSelect), [o, a] = u.useState(!1), i = Z(t, r.onScrollButtonChange);
4787
+ var vn = "SelectScrollDownButton", No = d.forwardRef((e, t) => {
4788
+ const n = Ve(vn, e.__scopeSelect), r = Nn(vn, e.__scopeSelect), [o, a] = d.useState(!1), i = Z(t, r.onScrollButtonChange);
4778
4789
  return te(() => {
4779
4790
  if (n.viewport && n.isPositioned) {
4780
4791
  let s = function() {
@@ -4797,16 +4808,16 @@ var vn = "SelectScrollDownButton", No = u.forwardRef((e, t) => {
4797
4808
  ) : null;
4798
4809
  });
4799
4810
  No.displayName = vn;
4800
- var Oo = u.forwardRef((e, t) => {
4801
- const { __scopeSelect: n, onAutoScroll: r, ...o } = e, a = Ve("SelectScrollButton", n), i = u.useRef(null), s = Ht(n), l = u.useCallback(() => {
4811
+ var Oo = d.forwardRef((e, t) => {
4812
+ const { __scopeSelect: n, onAutoScroll: r, ...o } = e, a = Ve("SelectScrollButton", n), i = d.useRef(null), s = Ht(n), l = d.useCallback(() => {
4802
4813
  i.current !== null && (window.clearInterval(i.current), i.current = null);
4803
4814
  }, []);
4804
- return u.useEffect(() => () => l(), [l]), te(() => {
4815
+ return d.useEffect(() => () => l(), [l]), te(() => {
4805
4816
  var f;
4806
4817
  const c = s().find((p) => p.ref.current === document.activeElement);
4807
4818
  (f = c == null ? void 0 : c.ref.current) == null || f.scrollIntoView({ block: "nearest" });
4808
4819
  }, [s]), /* @__PURE__ */ k(
4809
- K.div,
4820
+ X.div,
4810
4821
  {
4811
4822
  "aria-hidden": !0,
4812
4823
  ...o,
@@ -4824,24 +4835,24 @@ var Oo = u.forwardRef((e, t) => {
4824
4835
  })
4825
4836
  }
4826
4837
  );
4827
- }), Hl = "SelectSeparator", jl = u.forwardRef(
4838
+ }), jl = "SelectSeparator", Yl = d.forwardRef(
4828
4839
  (e, t) => {
4829
4840
  const { __scopeSelect: n, ...r } = e;
4830
- return /* @__PURE__ */ k(K.div, { "aria-hidden": !0, ...r, ref: t });
4841
+ return /* @__PURE__ */ k(X.div, { "aria-hidden": !0, ...r, ref: t });
4831
4842
  }
4832
4843
  );
4833
- jl.displayName = Hl;
4834
- var gn = "SelectArrow", Yl = u.forwardRef(
4844
+ Yl.displayName = jl;
4845
+ var gn = "SelectArrow", Kl = d.forwardRef(
4835
4846
  (e, t) => {
4836
4847
  const { __scopeSelect: n, ...r } = e, o = jt(n), a = Fe(gn, n), i = Ve(gn, n);
4837
- return a.open && i.position === "popper" ? /* @__PURE__ */ k(_s, { ...o, ...r, ref: t }) : null;
4848
+ return a.open && i.position === "popper" ? /* @__PURE__ */ k(Ns, { ...o, ...r, ref: t }) : null;
4838
4849
  }
4839
4850
  );
4840
- Yl.displayName = gn;
4841
- var Xl = "SelectBubbleInput", Mo = u.forwardRef(
4851
+ Kl.displayName = gn;
4852
+ var Xl = "SelectBubbleInput", Mo = d.forwardRef(
4842
4853
  ({ __scopeSelect: e, value: t, ...n }, r) => {
4843
- const o = u.useRef(null), a = Z(r, o), i = Ds(t);
4844
- return u.useEffect(() => {
4854
+ const o = d.useRef(null), a = Z(r, o), i = Bs(t);
4855
+ return d.useEffect(() => {
4845
4856
  const s = o.current;
4846
4857
  if (!s) return;
4847
4858
  const l = window.HTMLSelectElement.prototype, f = Object.getOwnPropertyDescriptor(
@@ -4853,7 +4864,7 @@ var Xl = "SelectBubbleInput", Mo = u.forwardRef(
4853
4864
  f.call(s, t), s.dispatchEvent(p);
4854
4865
  }
4855
4866
  }, [i, t]), /* @__PURE__ */ k(
4856
- K.select,
4867
+ X.select,
4857
4868
  {
4858
4869
  ...n,
4859
4870
  style: { ...no, ...n.style },
@@ -4868,7 +4879,7 @@ function Lo(e) {
4868
4879
  return e === "" || e === void 0;
4869
4880
  }
4870
4881
  function Do(e) {
4871
- const t = Ue(e), n = u.useRef(""), r = u.useRef(0), o = u.useCallback(
4882
+ const t = Ue(e), n = d.useRef(""), r = d.useRef(0), o = d.useCallback(
4872
4883
  (i) => {
4873
4884
  const s = n.current + i;
4874
4885
  t(s), function l(c) {
@@ -4876,25 +4887,25 @@ function Do(e) {
4876
4887
  }(s);
4877
4888
  },
4878
4889
  [t]
4879
- ), a = u.useCallback(() => {
4890
+ ), a = d.useCallback(() => {
4880
4891
  n.current = "", window.clearTimeout(r.current);
4881
4892
  }, []);
4882
- return u.useEffect(() => () => window.clearTimeout(r.current), []), [n, o, a];
4893
+ return d.useEffect(() => () => window.clearTimeout(r.current), []), [n, o, a];
4883
4894
  }
4884
4895
  function Bo(e, t, n) {
4885
4896
  const o = t.length > 1 && Array.from(t).every((c) => c === t[0]) ? t[0] : t, a = n ? e.indexOf(n) : -1;
4886
- let i = Kl(e, Math.max(a, 0));
4897
+ let i = Gl(e, Math.max(a, 0));
4887
4898
  o.length === 1 && (i = i.filter((c) => c !== n));
4888
4899
  const l = i.find(
4889
4900
  (c) => c.textValue.toLowerCase().startsWith(o.toLowerCase())
4890
4901
  );
4891
4902
  return l !== n ? l : void 0;
4892
4903
  }
4893
- function Kl(e, t) {
4904
+ function Gl(e, t) {
4894
4905
  return e.map((n, r) => e[(t + r) % e.length]);
4895
4906
  }
4896
- var Gl = po, zo = vo, Fo = mo, Zl = wo, ql = bo, Ql = So, Jl = Ao, ec = Po, tc = Ro, nc = _o, rc = No;
4897
- const oc = {
4907
+ var Zl = po, zo = vo, Fo = mo, ql = wo, Ql = bo, Jl = So, ec = Ao, tc = Po, nc = Ro, rc = _o, oc = No;
4908
+ const ac = {
4898
4909
  sm: "w-4 h-4",
4899
4910
  md: "w-6 h-6"
4900
4911
  };
@@ -4909,7 +4920,7 @@ function On({
4909
4920
  {
4910
4921
  className: j(
4911
4922
  "rounded-full object-cover",
4912
- oc[e],
4923
+ ac[e],
4913
4924
  n
4914
4925
  ),
4915
4926
  src: `https://storage.googleapis.com/eleven-public-cdn/images/flags/circle-flags/${t}.svg`,
@@ -4919,9 +4930,9 @@ function On({
4919
4930
  );
4920
4931
  }
4921
4932
  function Vo({ children: e, ...t }) {
4922
- const [n, r] = ke(!1), { language: o, setLanguage: a, options: i } = rt(), s = Ca();
4923
- return /* @__PURE__ */ P(
4924
- Gl,
4933
+ const [n, r] = ke(!1), { language: o, setLanguage: a, options: i } = rt(), s = Sa();
4934
+ return /* @__PURE__ */ I(
4935
+ Zl,
4925
4936
  {
4926
4937
  open: n,
4927
4938
  value: o.value.languageCode,
@@ -4933,8 +4944,8 @@ function Vo({ children: e, ...t }) {
4933
4944
  },
4934
4945
  children: [
4935
4946
  e,
4936
- /* @__PURE__ */ h(Zl, { container: s, children: /* @__PURE__ */ P(
4937
- ql,
4947
+ /* @__PURE__ */ h(ql, { container: s, children: /* @__PURE__ */ I(
4948
+ Ql,
4938
4949
  {
4939
4950
  className: "overflow-hidden bg-base border border-base-border rounded-dropdown-sheet max-h-[min(384px,var(--radix-select-content-available-height))] min-w-[var(--radix-select-trigger-width)] z-10",
4940
4951
  position: "popper",
@@ -4946,21 +4957,21 @@ function Vo({ children: e, ...t }) {
4946
4957
  onEscapeKeyDown: () => r(!1),
4947
4958
  ...t,
4948
4959
  children: [
4949
- /* @__PURE__ */ h(nc, { className: "flex items-center justify-center h-6 bg-base text-base-subtle cursor-default", children: /* @__PURE__ */ h(We, { size: "sm", name: "chevron-up" }) }),
4950
- /* @__PURE__ */ h(Ql, { className: "p-1.5", children: i.value.map((l) => /* @__PURE__ */ P(
4951
- Jl,
4960
+ /* @__PURE__ */ h(rc, { className: "flex items-center justify-center h-6 bg-base text-base-subtle cursor-default", children: /* @__PURE__ */ h(We, { size: "sm", name: "chevron-up" }) }),
4961
+ /* @__PURE__ */ h(Jl, { className: "p-1.5", children: i.value.map((l) => /* @__PURE__ */ I(
4962
+ ec,
4952
4963
  {
4953
4964
  value: l.languageCode,
4954
4965
  className: "flex select-none items-center p-1.5 pr-3 gap-2 cursor-pointer rounded-input relative focus-visible:outline-none data-[highlighted]:bg-base-active text-sm",
4955
4966
  children: [
4956
4967
  /* @__PURE__ */ h(On, { flagCode: l.flagCode }),
4957
- /* @__PURE__ */ h(ec, { children: l.name }),
4958
- /* @__PURE__ */ h(tc, { className: "text-base-primary p-1.5 -mr-1.5 ml-auto", children: /* @__PURE__ */ h(We, { size: "sm", name: "check" }) })
4968
+ /* @__PURE__ */ h(tc, { children: l.name }),
4969
+ /* @__PURE__ */ h(nc, { className: "text-base-primary p-1.5 -mr-1.5 ml-auto", children: /* @__PURE__ */ h(We, { size: "sm", name: "check" }) })
4959
4970
  ]
4960
4971
  },
4961
4972
  l.languageCode
4962
4973
  )) }),
4963
- /* @__PURE__ */ h(rc, { className: "flex items-center justify-center h-6 bg-base text-base-subtle cursor-default", children: /* @__PURE__ */ h(We, { size: "sm", name: "chevron-down" }) })
4974
+ /* @__PURE__ */ h(oc, { className: "flex items-center justify-center h-6 bg-base text-base-subtle cursor-default", children: /* @__PURE__ */ h(We, { size: "sm", name: "chevron-down" }) })
4964
4975
  ]
4965
4976
  }
4966
4977
  ) })
@@ -4968,12 +4979,12 @@ function Vo({ children: e, ...t }) {
4968
4979
  }
4969
4980
  );
4970
4981
  }
4971
- function ac({
4982
+ function ic({
4972
4983
  className: e,
4973
4984
  ...t
4974
4985
  }) {
4975
4986
  const n = re(), { language: r, showPicker: o } = rt();
4976
- return o.value ? /* @__PURE__ */ h(Vo, { align: "center", children: /* @__PURE__ */ P(
4987
+ return o.value ? /* @__PURE__ */ h(Vo, { align: "center", children: /* @__PURE__ */ I(
4977
4988
  zo,
4978
4989
  {
4979
4990
  className: j(
@@ -4990,7 +5001,7 @@ function ac({
4990
5001
  }
4991
5002
  ) }) : null;
4992
5003
  }
4993
- function ic({
5004
+ function sc({
4994
5005
  className: e,
4995
5006
  ...t
4996
5007
  }) {
@@ -5042,7 +5053,7 @@ function Ln({
5042
5053
  }
5043
5054
  );
5044
5055
  }
5045
- function sc({
5056
+ function lc({
5046
5057
  showTranscript: e,
5047
5058
  scrollPinned: t
5048
5059
  }) {
@@ -5070,11 +5081,11 @@ function sc({
5070
5081
  n.value = v.currentTarget.value;
5071
5082
  },
5072
5083
  [n]
5073
- ), d = Y(() => !!n.value.trim());
5074
- return /* @__PURE__ */ P("div", { className: "shrink-0 overflow-hidden flex p-3 items-end justify-end", children: [
5075
- o && /* @__PURE__ */ P("div", { className: "relative grow min-w-0 flex z-1 m-1", children: [
5084
+ ), u = Y(() => !!n.value.trim());
5085
+ return /* @__PURE__ */ I("div", { className: "shrink-0 overflow-hidden flex p-3 items-end justify-end", children: [
5086
+ o && /* @__PURE__ */ I("div", { className: "relative grow min-w-0 flex z-1 m-1", children: [
5076
5087
  /* @__PURE__ */ h(
5077
- ic,
5088
+ sc,
5078
5089
  {
5079
5090
  rows: 1,
5080
5091
  "aria-label": a.input_label,
@@ -5086,7 +5097,7 @@ function sc({
5086
5097
  placeholder: r.value ? i.value && p.value > 0 ? a.input_placeholder_new_conversation : a.input_placeholder_text_only : a.input_placeholder
5087
5098
  }
5088
5099
  ),
5089
- /* @__PURE__ */ h(se, { active: d, children: /* @__PURE__ */ h(
5100
+ /* @__PURE__ */ h(se, { active: u, children: /* @__PURE__ */ h(
5090
5101
  "button",
5091
5102
  {
5092
5103
  "aria-label": a.send_message,
@@ -5096,7 +5107,7 @@ function sc({
5096
5107
  }
5097
5108
  ) })
5098
5109
  ] }),
5099
- /* @__PURE__ */ P("div", { className: "flex h-11 items-center", children: [
5110
+ /* @__PURE__ */ I("div", { className: "flex h-11 items-center", children: [
5100
5111
  /* @__PURE__ */ h(Mn, { visible: !r.value && !i.value }),
5101
5112
  /* @__PURE__ */ h(
5102
5113
  Te,
@@ -5117,12 +5128,12 @@ function sc({
5117
5128
  ] })
5118
5129
  ] });
5119
5130
  }
5120
- function lc({
5131
+ function cc({
5121
5132
  entry: e,
5122
5133
  animateIn: t
5123
5134
  }) {
5124
5135
  const n = re(), { previewUrl: r } = bn(), { lastId: o } = ne();
5125
- return /* @__PURE__ */ h(se, { initial: !t, active: !0, children: e.type === "message" ? /* @__PURE__ */ P(
5136
+ return /* @__PURE__ */ h(se, { initial: !t, active: !0, children: e.type === "message" ? /* @__PURE__ */ I(
5126
5137
  "div",
5127
5138
  {
5128
5139
  className: j(
@@ -5151,21 +5162,21 @@ function lc({
5151
5162
  )
5152
5163
  ]
5153
5164
  }
5154
- ) : e.type === "disconnection" ? /* @__PURE__ */ P("div", { className: "mt-2 px-8 text-xs text-base-subtle text-center transition-opacity duration-200 data-hidden:opacity-0", children: [
5165
+ ) : e.type === "disconnection" ? /* @__PURE__ */ I("div", { className: "mt-2 px-8 text-xs text-base-subtle text-center transition-opacity duration-200 data-hidden:opacity-0", children: [
5155
5166
  e.role === "user" ? n.user_ended_conversation : n.agent_ended_conversation,
5156
5167
  /* @__PURE__ */ h("br", {}),
5157
- o.value && /* @__PURE__ */ P("span", { className: "break-all", children: [
5168
+ o.value && /* @__PURE__ */ I("span", { className: "break-all", children: [
5158
5169
  n.conversation_id,
5159
5170
  ": ",
5160
5171
  o.value
5161
5172
  ] })
5162
- ] }) : /* @__PURE__ */ P("div", { className: "mt-2 px-8 text-xs text-base-error text-center transition-opacity duration-200 data-hidden:opacity-0", children: [
5173
+ ] }) : /* @__PURE__ */ I("div", { className: "mt-2 px-8 text-xs text-base-error text-center transition-opacity duration-200 data-hidden:opacity-0", children: [
5163
5174
  n.error_occurred,
5164
5175
  /* @__PURE__ */ h("br", {}),
5165
5176
  e.message,
5166
- o.value && /* @__PURE__ */ P(wt, { children: [
5177
+ o.value && /* @__PURE__ */ I(wt, { children: [
5167
5178
  /* @__PURE__ */ h("br", {}),
5168
- /* @__PURE__ */ P("span", { className: "text-base-subtle break-all", children: [
5179
+ /* @__PURE__ */ I("span", { className: "text-base-subtle break-all", children: [
5169
5180
  n.conversation_id,
5170
5181
  ": ",
5171
5182
  o.value
@@ -5173,8 +5184,8 @@ function lc({
5173
5184
  ] })
5174
5185
  ] }) });
5175
5186
  }
5176
- const cc = 16;
5177
- function uc({ scrollPinned: e, transcript: t }) {
5187
+ const uc = 16;
5188
+ function dc({ scrollPinned: e, transcript: t }) {
5178
5189
  const n = be(null), r = (a) => {
5179
5190
  var i;
5180
5191
  (i = n.current) == null || i.scrollTo({
@@ -5191,11 +5202,11 @@ function uc({ scrollPinned: e, transcript: t }) {
5191
5202
  {
5192
5203
  ref: n,
5193
5204
  onScroll: (a) => {
5194
- e.value = a.currentTarget.scrollTop >= a.currentTarget.scrollHeight - a.currentTarget.clientHeight - cc;
5205
+ e.value = a.currentTarget.scrollTop >= a.currentTarget.scrollHeight - a.currentTarget.clientHeight - uc;
5195
5206
  },
5196
5207
  className: "px-4 pb-3 grow flex flex-col gap-3 overflow-x-hidden overflow-y-auto",
5197
5208
  children: t.value.map((a, i) => /* @__PURE__ */ h(
5198
- lc,
5209
+ cc,
5199
5210
  {
5200
5211
  entry: a,
5201
5212
  animateIn: !o.current
@@ -5205,7 +5216,7 @@ function uc({ scrollPinned: e, transcript: t }) {
5205
5216
  }
5206
5217
  );
5207
5218
  }
5208
- const dc = {
5219
+ const fc = {
5209
5220
  "top-left": "origin-top-left",
5210
5221
  top: "origin-top",
5211
5222
  "top-right": "origin-top-right",
@@ -5213,7 +5224,7 @@ const dc = {
5213
5224
  "bottom-right": "origin-bottom-right",
5214
5225
  bottom: "origin-bottom"
5215
5226
  };
5216
- function fc({ open: e }) {
5227
+ function pc({ open: e }) {
5217
5228
  const t = re(), n = wn(), r = zt(), o = q(), a = o.value.placement, { isDisconnected: i, startSession: s, transcript: l, conversationIndex: c } = ne(), f = xr(), p = Y(() => {
5218
5229
  var m;
5219
5230
  return n.value || r.value ? !f.value || !n.value ? l.value : [
@@ -5226,39 +5237,39 @@ function fc({ open: e }) {
5226
5237
  },
5227
5238
  ...l.value
5228
5239
  ] : o.value.transcript_enabled ? l.value : l.value.filter(
5229
- (d) => d.type !== "message" || d.isText
5240
+ (u) => u.type !== "message" || u.isText
5230
5241
  );
5231
5242
  }), g = p.value.length > 0 || !i.value && o.value.transcript_enabled, w = ce(!0);
5232
- return /* @__PURE__ */ h(se, { initial: !1, active: e, children: /* @__PURE__ */ P(
5243
+ return /* @__PURE__ */ h(se, { initial: !1, active: e, children: /* @__PURE__ */ I(
5233
5244
  "div",
5234
5245
  {
5235
5246
  className: j(
5236
5247
  "flex flex-col overflow-hidden absolute bg-base shadow-lg pointer-events-auto rounded-sheet w-full max-w-[400px] h-[calc(100%-80px)] max-h-[550px]",
5237
5248
  "transition-[transform,opacity] duration-200 data-hidden:scale-90 data-hidden:opacity-0",
5238
- dc[a],
5249
+ fc[a],
5239
5250
  a.startsWith("top") ? "top-20" : "bottom-20"
5240
5251
  ),
5241
5252
  children: [
5242
- /* @__PURE__ */ P("div", { className: "bg-base shrink-0 flex gap-2 p-4 items-start", children: [
5253
+ /* @__PURE__ */ I("div", { className: "bg-base shrink-0 flex gap-2 p-4 items-start", children: [
5243
5254
  /* @__PURE__ */ h("div", { className: "relative w-16 h-16" }),
5244
5255
  /* @__PURE__ */ h(se, { active: g && !i.value, children: /* @__PURE__ */ h(an, { className: "rounded-bl-[calc(var(--el-bubble-radius)/3)] transition-opacity data-hidden:opacity-0" }) })
5245
5256
  ] }),
5246
5257
  /* @__PURE__ */ h(
5247
- uc,
5258
+ dc,
5248
5259
  {
5249
5260
  transcript: p,
5250
5261
  scrollPinned: w
5251
5262
  }
5252
5263
  ),
5253
5264
  /* @__PURE__ */ h(
5254
- sc,
5265
+ lc,
5255
5266
  {
5256
5267
  scrollPinned: w,
5257
5268
  showTranscript: g
5258
5269
  }
5259
5270
  ),
5260
- /* @__PURE__ */ h(se, { active: !g || i.value, children: /* @__PURE__ */ h("div", { className: "absolute top-0 left-0 right-0 p-4 flex justify-center transition-[opacity,transform] duration-200 data-hidden:opacity-0 data-hidden:-translate-y-4", children: /* @__PURE__ */ h(ac, {}) }) }),
5261
- /* @__PURE__ */ P(
5271
+ /* @__PURE__ */ h(se, { active: !g || i.value, children: /* @__PURE__ */ h("div", { className: "absolute top-0 left-0 right-0 p-4 flex justify-center transition-[opacity,transform] duration-200 data-hidden:opacity-0 data-hidden:-translate-y-4", children: /* @__PURE__ */ h(ic, {}) }) }),
5272
+ /* @__PURE__ */ I(
5262
5273
  "div",
5263
5274
  {
5264
5275
  className: j(
@@ -5294,7 +5305,7 @@ function $o({ expanded: e }) {
5294
5305
  const t = zt(), n = q().value.variant, { isDisconnected: r } = ne(), o = re(), a = le(() => {
5295
5306
  e.value = !e.value;
5296
5307
  }, [e]);
5297
- return /* @__PURE__ */ P(wt, { children: [
5308
+ return /* @__PURE__ */ I(wt, { children: [
5298
5309
  n === "full" && /* @__PURE__ */ h(
5299
5310
  Te,
5300
5311
  {
@@ -5335,13 +5346,13 @@ function $o({ expanded: e }) {
5335
5346
  ) })
5336
5347
  ] });
5337
5348
  }
5338
- function pc({
5349
+ function hc({
5339
5350
  expanded: e,
5340
5351
  className: t,
5341
5352
  ...n
5342
5353
  }) {
5343
5354
  const { isDisconnected: r } = ne(), o = re();
5344
- return /* @__PURE__ */ P(
5355
+ return /* @__PURE__ */ I(
5345
5356
  "div",
5346
5357
  {
5347
5358
  className: j(
@@ -5356,7 +5367,7 @@ function pc({
5356
5367
  {
5357
5368
  visible: !e.value && r.value,
5358
5369
  className: "p-1 !min-w-60",
5359
- children: /* @__PURE__ */ P("div", { className: "flex items-center gap-2", children: [
5370
+ children: /* @__PURE__ */ I("div", { className: "flex items-center gap-2", children: [
5360
5371
  /* @__PURE__ */ h(ot, {}),
5361
5372
  /* @__PURE__ */ h("div", { className: "text-sm max-w-64", children: o.main_label })
5362
5373
  ] })
@@ -5367,12 +5378,12 @@ function pc({
5367
5378
  }
5368
5379
  );
5369
5380
  }
5370
- function hc({
5381
+ function vc({
5371
5382
  expanded: e,
5372
5383
  className: t,
5373
5384
  ...n
5374
5385
  }) {
5375
- return /* @__PURE__ */ P(
5386
+ return /* @__PURE__ */ I(
5376
5387
  "div",
5377
5388
  {
5378
5389
  className: j("rounded-compact-sheet flex items-center p-2", t),
@@ -5384,9 +5395,9 @@ function hc({
5384
5395
  }
5385
5396
  );
5386
5397
  }
5387
- function vc({ visible: e, className: t, ...n }) {
5398
+ function gc({ visible: e, className: t, ...n }) {
5388
5399
  const r = re(), { language: o, showPicker: a } = rt();
5389
- return a.value ? /* @__PURE__ */ h(Te, { visible: e, className: "p-1", children: /* @__PURE__ */ h(Vo, { children: /* @__PURE__ */ P(
5400
+ return a.value ? /* @__PURE__ */ h(Te, { visible: e, className: "p-1", children: /* @__PURE__ */ h(Vo, { children: /* @__PURE__ */ I(
5390
5401
  zo,
5391
5402
  {
5392
5403
  className: j(
@@ -5404,7 +5415,7 @@ function vc({ visible: e, className: t, ...n }) {
5404
5415
  }
5405
5416
  function Wo() {
5406
5417
  const e = q().value.variant, { isDisconnected: t, status: n } = ne();
5407
- return /* @__PURE__ */ P(wt, { children: [
5418
+ return /* @__PURE__ */ I(wt, { children: [
5408
5419
  /* @__PURE__ */ h(
5409
5420
  Ln,
5410
5421
  {
@@ -5414,19 +5425,19 @@ function Wo() {
5414
5425
  disabled: n.value === "disconnecting" || n.value === "connecting"
5415
5426
  }
5416
5427
  ),
5417
- /* @__PURE__ */ h(vc, { visible: t.value }),
5428
+ /* @__PURE__ */ h(gc, { visible: t.value }),
5418
5429
  /* @__PURE__ */ h(Mn, { visible: !t.value })
5419
5430
  ] });
5420
5431
  }
5421
- function gc({
5432
+ function mc({
5422
5433
  className: e,
5423
5434
  ...t
5424
5435
  }) {
5425
5436
  const { isDisconnected: n } = ne(), r = re();
5426
- return /* @__PURE__ */ P("div", { className: j("flex flex-col p-2 rounded-sheet", e), ...t, children: [
5427
- /* @__PURE__ */ P("div", { className: "flex items-center p-1 gap-2 min-w-60", children: [
5437
+ return /* @__PURE__ */ I("div", { className: j("flex flex-col p-2 rounded-sheet", e), ...t, children: [
5438
+ /* @__PURE__ */ I("div", { className: "flex items-center p-1 gap-2 min-w-60", children: [
5428
5439
  /* @__PURE__ */ h(ot, {}),
5429
- /* @__PURE__ */ P("div", { className: "relative text-sm max-w-64", children: [
5440
+ /* @__PURE__ */ I("div", { className: "relative text-sm max-w-64", children: [
5430
5441
  /* @__PURE__ */ h(
5431
5442
  "span",
5432
5443
  {
@@ -5443,11 +5454,11 @@ function gc({
5443
5454
  /* @__PURE__ */ h("div", { className: "flex items-center", children: /* @__PURE__ */ h(Wo, {}) })
5444
5455
  ] });
5445
5456
  }
5446
- function mc({
5457
+ function wc({
5447
5458
  className: e,
5448
5459
  ...t
5449
5460
  }) {
5450
- return /* @__PURE__ */ P(
5461
+ return /* @__PURE__ */ I(
5451
5462
  "div",
5452
5463
  {
5453
5464
  className: j("rounded-compact-sheet flex items-center p-2", e),
@@ -5459,12 +5470,12 @@ function mc({
5459
5470
  }
5460
5471
  );
5461
5472
  }
5462
- function wc({ expandable: e, expanded: t }) {
5473
+ function bc({ expandable: e, expanded: t }) {
5463
5474
  const n = q().value.variant, r = Bt(), { isDisconnected: o } = ne(), a = le(async () => {
5464
5475
  await r.requestTerms(), t.value = !t.peek();
5465
5476
  }, [t]), i = n === "full";
5466
5477
  return e ? /* @__PURE__ */ h(
5467
- i ? pc : hc,
5478
+ i ? hc : vc,
5468
5479
  {
5469
5480
  expanded: t,
5470
5481
  className: j(
@@ -5473,11 +5484,11 @@ function wc({ expandable: e, expanded: t }) {
5473
5484
  ),
5474
5485
  onClick: o.value || t.value ? a : void 0
5475
5486
  }
5476
- ) : /* @__PURE__ */ h(i ? gc : mc, { className: "bg-base shadow-md pointer-events-auto overflow-hidden" });
5487
+ ) : /* @__PURE__ */ h(i ? mc : wc, { className: "bg-base shadow-md pointer-events-auto overflow-hidden" });
5477
5488
  }
5478
- function bc() {
5489
+ function xc() {
5479
5490
  const e = re(), t = q(), { dismissTerms: n, acceptTerms: r } = Bt();
5480
- return /* @__PURE__ */ P("div", { className: "max-w-[400px] flex flex-col gap-2 bg-base shadow-md pointer-events-auto rounded-sheet p-3 text-sm", children: [
5491
+ return /* @__PURE__ */ I("div", { className: "max-w-[400px] flex flex-col gap-2 bg-base shadow-md pointer-events-auto rounded-sheet p-3 text-sm", children: [
5481
5492
  /* @__PURE__ */ h(
5482
5493
  "div",
5483
5494
  {
@@ -5485,13 +5496,13 @@ function bc() {
5485
5496
  dangerouslySetInnerHTML: { __html: t.value.terms_html ?? "" }
5486
5497
  }
5487
5498
  ),
5488
- /* @__PURE__ */ P("div", { className: "flex justify-end gap-2", children: [
5499
+ /* @__PURE__ */ I("div", { className: "flex justify-end gap-2", children: [
5489
5500
  /* @__PURE__ */ h(Me, { onClick: n, children: e.dismiss_terms }),
5490
5501
  /* @__PURE__ */ h(Me, { onClick: r, variant: "primary", children: e.accept_terms })
5491
5502
  ] })
5492
5503
  ] });
5493
5504
  }
5494
- function xc({ copyText: e, children: t }) {
5505
+ function yc({ copyText: e, children: t }) {
5495
5506
  const n = re(), [r, o] = ke(!1);
5496
5507
  Oe(() => {
5497
5508
  if (r) {
@@ -5509,32 +5520,32 @@ function xc({ copyText: e, children: t }) {
5509
5520
  }, []);
5510
5521
  return /* @__PURE__ */ h(Me, { onClick: a, children: r ? n.copied : t });
5511
5522
  }
5512
- function yc({ sawError: e }) {
5523
+ function Cc({ sawError: e }) {
5513
5524
  const t = re(), { error: n, lastId: r } = ne(), o = le(() => {
5514
5525
  e.value = !0;
5515
5526
  }, []);
5516
- return /* @__PURE__ */ P("div", { className: "max-w-[400px] flex flex-col gap-2 bg-base shadow-md pointer-events-auto rounded-sheet p-3 text-sm", children: [
5517
- /* @__PURE__ */ P("div", { className: "p-2 pt-1", children: [
5527
+ return /* @__PURE__ */ I("div", { className: "max-w-[400px] flex flex-col gap-2 bg-base shadow-md pointer-events-auto rounded-sheet p-3 text-sm", children: [
5528
+ /* @__PURE__ */ I("div", { className: "p-2 pt-1", children: [
5518
5529
  /* @__PURE__ */ h("h1", { className: "text-md font-medium pb-1", children: t.error_occurred }),
5519
5530
  n.value,
5520
- r.value && /* @__PURE__ */ P(wt, { children: [
5531
+ r.value && /* @__PURE__ */ I(wt, { children: [
5521
5532
  /* @__PURE__ */ h("br", {}),
5522
- /* @__PURE__ */ P("span", { className: "text-base-subtle", children: [
5533
+ /* @__PURE__ */ I("span", { className: "text-base-subtle", children: [
5523
5534
  t.conversation_id,
5524
5535
  ": ",
5525
5536
  r.value
5526
5537
  ] })
5527
5538
  ] })
5528
5539
  ] }),
5529
- /* @__PURE__ */ P("div", { className: "flex justify-end gap-2", children: [
5530
- /* @__PURE__ */ h(xc, { copyText: r, children: t.copy_id }),
5540
+ /* @__PURE__ */ I("div", { className: "flex justify-end gap-2", children: [
5541
+ /* @__PURE__ */ h(yc, { copyText: r, children: t.copy_id }),
5531
5542
  /* @__PURE__ */ h(Me, { variant: "primary", onClick: o, children: "Close" })
5532
5543
  ] })
5533
5544
  ] });
5534
5545
  }
5535
- function Cc() {
5546
+ function Sc() {
5536
5547
  const e = q();
5537
- return e.value.disable_banner ? null : /* @__PURE__ */ P(
5548
+ return e.value.disable_banner ? null : /* @__PURE__ */ I(
5538
5549
  "p",
5539
5550
  {
5540
5551
  className: j(
@@ -5564,7 +5575,7 @@ const qe = {
5564
5575
  }, Qe = {
5565
5576
  top: "flex-col-reverse justify-end",
5566
5577
  bottom: "flex-col justify-end"
5567
- }, Sc = {
5578
+ }, Ec = {
5568
5579
  "top-left": `${Qe.top} ${qe.left}`,
5569
5580
  top: `${Qe.top} ${qe.center}`,
5570
5581
  "top-right": `${Qe.top} ${qe.right}`,
@@ -5573,40 +5584,40 @@ const qe = {
5573
5584
  "bottom-right": `${Qe.bottom} ${qe.right}`
5574
5585
  }, At = {
5575
5586
  display: "none"
5576
- }, Ec = sr(function() {
5587
+ }, kc = sr(function() {
5577
5588
  const t = ce(!1), n = q(), r = ce(!1), { error: o } = ne(), a = Bt(), i = Y(
5578
5589
  () => n.value.transcript_enabled || n.value.text_input_enabled
5579
5590
  ), s = Y(
5580
5591
  () => j(
5581
5592
  "overlay !flex transition-opacity duration-200 data-hidden:opacity-0",
5582
- Sc[n.value.placement]
5593
+ Ec[n.value.placement]
5583
5594
  )
5584
5595
  );
5585
5596
  ze(() => {
5586
5597
  o.value && (i.value ? (r.value = !0, t.value = !0) : r.value = !1);
5587
5598
  });
5588
5599
  const l = Y(() => !i.value && o.value && !r.value ? "error" : !a.termsAccepted.value && a.termsShown.value ? "terms" : "conversation"), c = Y(() => l.value === "error"), f = Y(() => l.value === "terms"), p = Y(() => l.value === "conversation");
5589
- return /* @__PURE__ */ P(wt, { children: [
5590
- /* @__PURE__ */ h(se, { initial: !1, active: p, children: /* @__PURE__ */ P(yt, { className: s, style: At, children: [
5591
- i.value && /* @__PURE__ */ h(fc, { open: t }),
5592
- /* @__PURE__ */ h(wc, { expandable: i.value, expanded: t })
5600
+ return /* @__PURE__ */ I(wt, { children: [
5601
+ /* @__PURE__ */ h(se, { initial: !1, active: p, children: /* @__PURE__ */ I(yt, { className: s, style: At, children: [
5602
+ i.value && /* @__PURE__ */ h(pc, { open: t }),
5603
+ /* @__PURE__ */ h(bc, { expandable: i.value, expanded: t })
5593
5604
  ] }) }),
5594
- /* @__PURE__ */ h(se, { initial: !1, active: f, children: /* @__PURE__ */ h(yt, { className: s, style: At, children: /* @__PURE__ */ h(bc, {}) }) }),
5595
- /* @__PURE__ */ h(se, { initial: !1, active: c, children: /* @__PURE__ */ h(yt, { className: s, style: At, children: /* @__PURE__ */ h(yc, { sawError: r }) }) }),
5596
- /* @__PURE__ */ h(yt, { className: s, style: At, children: /* @__PURE__ */ h(Cc, {}) })
5605
+ /* @__PURE__ */ h(se, { initial: !1, active: f, children: /* @__PURE__ */ h(yt, { className: s, style: At, children: /* @__PURE__ */ h(xc, {}) }) }),
5606
+ /* @__PURE__ */ h(se, { initial: !1, active: c, children: /* @__PURE__ */ h(yt, { className: s, style: At, children: /* @__PURE__ */ h(Cc, { sawError: r }) }) }),
5607
+ /* @__PURE__ */ h(yt, { className: s, style: At, children: /* @__PURE__ */ h(Sc, {}) })
5597
5608
  ] });
5598
5609
  });
5599
- function kc(e) {
5600
- return /* @__PURE__ */ h(oa, { value: e, children: /* @__PURE__ */ h(ia, { children: /* @__PURE__ */ h(va, { children: /* @__PURE__ */ h(da, { children: /* @__PURE__ */ h(sa, { children: /* @__PURE__ */ h(la, { children: /* @__PURE__ */ h(ca, { children: /* @__PURE__ */ h(fa, { children: /* @__PURE__ */ h(xa, { children: /* @__PURE__ */ P(ya, { children: [
5601
- /* @__PURE__ */ h(ma, {}),
5602
- /* @__PURE__ */ h(Ec, {})
5610
+ function Tc(e) {
5611
+ return /* @__PURE__ */ h(oa, { value: e, children: /* @__PURE__ */ h(ia, { children: /* @__PURE__ */ h(ga, { children: /* @__PURE__ */ h(fa, { children: /* @__PURE__ */ h(sa, { children: /* @__PURE__ */ h(ca, { children: /* @__PURE__ */ h(ua, { children: /* @__PURE__ */ h(pa, { children: /* @__PURE__ */ h(ya, { children: /* @__PURE__ */ I(Ca, { children: [
5612
+ /* @__PURE__ */ h(wa, {}),
5613
+ /* @__PURE__ */ h(kc, {})
5603
5614
  ] }) }) }) }) }) }) }) }) }) });
5604
5615
  }
5605
- function Lc(e = "elevenlabs-convai") {
5606
- Yo(kc, e, [...rn], {
5616
+ function Dc(e = "elevenlabs-convai") {
5617
+ Yo(Tc, e, [...rn], {
5607
5618
  shadow: !0
5608
5619
  });
5609
5620
  }
5610
5621
  export {
5611
- Lc as registerWidget
5622
+ Dc as registerWidget
5612
5623
  };