From 0f562ac5f43ab6252a9571ceb7d44f03773cebd0 Mon Sep 17 00:00:00 2001 From: allanice001 Date: Tue, 6 Jan 2026 17:05:52 +0000 Subject: [PATCH] ui fixes --- internal/web/dist/assets/index-Cdjh6IZW.css | 2 + internal/web/dist/assets/index-CyGsiYei.js | 4167 ---------------- internal/web/dist/assets/index-CyGsiYei.js.br | Bin 402599 -> 0 bytes internal/web/dist/assets/index-CyGsiYei.js.gz | Bin 490636 -> 0 bytes internal/web/dist/assets/index-GteqH5KT.js | 4186 +++++++++++++++++ ...-CyGsiYei.js.map => index-GteqH5KT.js.map} | 2 +- internal/web/dist/assets/index-VHZG0dIU.css | 2 - .../web/dist/assets/index-VHZG0dIU.css.br | Bin 15565 -> 0 bytes .../web/dist/assets/index-VHZG0dIU.css.gz | Bin 18906 -> 0 bytes internal/web/dist/assets/react-Dt2M6tWj.js | 4 - internal/web/dist/assets/react-Dt2M6tWj.js.br | Bin 14622 -> 0 bytes internal/web/dist/assets/react-Dt2M6tWj.js.gz | Bin 16276 -> 0 bytes .../web/dist/assets/react-Dt2M6tWj.js.map | 1 - internal/web/dist/assets/react-v1TLhXpT.js | 4 + .../web/dist/assets/react-v1TLhXpT.js.map | 1 + internal/web/dist/index.html | 6 +- internal/web/dist/index.html.br | Bin 202 -> 0 bytes internal/web/dist/index.html.gz | Bin 331 -> 0 bytes internal/web/dist/vite.svg | 3 +- ui/package.json | 2 +- ui/src/pages/credential-page.tsx | 215 +- ui/src/pages/dns-page.tsx | 114 +- ui/src/pages/server-page.tsx | 65 +- ui/yarn.lock | 2 +- 24 files changed, 4518 insertions(+), 4258 deletions(-) create mode 100644 internal/web/dist/assets/index-Cdjh6IZW.css delete mode 100644 internal/web/dist/assets/index-CyGsiYei.js delete mode 100644 internal/web/dist/assets/index-CyGsiYei.js.br delete mode 100644 internal/web/dist/assets/index-CyGsiYei.js.gz create mode 100644 internal/web/dist/assets/index-GteqH5KT.js rename internal/web/dist/assets/{index-CyGsiYei.js.map => index-GteqH5KT.js.map} (67%) delete mode 100644 internal/web/dist/assets/index-VHZG0dIU.css delete mode 100644 internal/web/dist/assets/index-VHZG0dIU.css.br delete mode 100644 internal/web/dist/assets/index-VHZG0dIU.css.gz delete mode 100644 internal/web/dist/assets/react-Dt2M6tWj.js delete mode 100644 internal/web/dist/assets/react-Dt2M6tWj.js.br delete mode 100644 internal/web/dist/assets/react-Dt2M6tWj.js.gz delete mode 100644 internal/web/dist/assets/react-Dt2M6tWj.js.map create mode 100644 internal/web/dist/assets/react-v1TLhXpT.js create mode 100644 internal/web/dist/assets/react-v1TLhXpT.js.map delete mode 100644 internal/web/dist/index.html.br delete mode 100644 internal/web/dist/index.html.gz diff --git a/internal/web/dist/assets/index-Cdjh6IZW.css b/internal/web/dist/assets/index-Cdjh6IZW.css new file mode 100644 index 0000000..e605051 --- /dev/null +++ b/internal/web/dist/assets/index-Cdjh6IZW.css @@ -0,0 +1,2 @@ +/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */ +@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-space-x-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial;--tw-ease:initial;--tw-content:"";--tw-animation-delay:0s;--tw-animation-direction:normal;--tw-animation-duration:initial;--tw-animation-fill-mode:none;--tw-animation-iteration-count:1;--tw-enter-blur:0;--tw-enter-opacity:1;--tw-enter-rotate:0;--tw-enter-scale:1;--tw-enter-translate-x:0;--tw-enter-translate-y:0;--tw-exit-blur:0;--tw-exit-opacity:1;--tw-exit-rotate:0;--tw-exit-scale:1;--tw-exit-translate-x:0;--tw-exit-translate-y:0}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-red-100:#ffe2e2;--color-red-500:#fb2c36;--color-red-600:#e40014;--color-red-800:#9f0712;--color-orange-100:#ffedd5;--color-orange-800:#9f2d00;--color-amber-50:#fffbeb;--color-amber-100:#fef3c6;--color-amber-200:#fee685;--color-amber-800:#953d00;--color-amber-900:#7b3306;--color-emerald-100:#d0fae5;--color-emerald-600:#009767;--color-emerald-800:#005f46;--color-sky-100:#dff2fe;--color-sky-800:#005986;--color-blue-600:#155dfc;--color-violet-100:#ede9fe;--color-violet-800:#5d0ec0;--color-zinc-200:#e4e4e7;--color-zinc-700:#3f3f46;--color-black:#000;--color-white:#fff;--spacing:.25rem;--breakpoint-2xl:96rem;--container-sm:24rem;--container-md:28rem;--container-lg:32rem;--container-xl:36rem;--container-2xl:42rem;--container-3xl:48rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-sm:.875rem;--text-sm--line-height:calc(1.25/.875);--text-base:1rem;--text-base--line-height:calc(1.5/1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75/1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75/1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2/1.5);--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--tracking-tight:-.025em;--tracking-wide:.025em;--tracking-widest:.1em;--leading-snug:1.375;--leading-normal:1.5;--leading-relaxed:1.625;--radius-xs:.125rem;--radius-2xl:1rem;--ease-in-out:cubic-bezier(.4,0,.2,1);--animate-spin:spin 1s linear infinite;--animate-pulse:pulse 2s cubic-bezier(.4,0,.6,1)infinite;--aspect-video:16/9;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono);--color-border:var(--border)}@supports (color:lab(0% 0 0)){:root,:host{--color-red-100:lab(92.243% 10.2865 3.83865);--color-red-500:lab(55.4814% 75.0732 48.8528);--color-red-600:lab(48.4493% 77.4328 61.5452);--color-red-800:lab(33.7174% 55.8993 41.0293);--color-orange-100:lab(94.7127% 3.58394 14.3151);--color-orange-800:lab(37.1566% 46.6433 50.5562);--color-amber-50:lab(98.6252% -.635922 8.42309);--color-amber-100:lab(95.916% -1.21653 23.111);--color-amber-200:lab(91.7203% -.505269 49.9084);--color-amber-800:lab(37.8822% 37.1699 52.2718);--color-amber-900:lab(31.2288% 30.2627 40.0378);--color-emerald-100:lab(94.9004% -17.0769 5.63836);--color-emerald-600:lab(55.0481% -49.9246 15.93);--color-emerald-800:lab(35.3675% -33.1188 8.04002);--color-sky-100:lab(94.3709% -4.56053 -8.23453);--color-sky-800:lab(35.164% -9.57692 -34.4068);--color-blue-600:lab(44.0605% 29.0279 -86.0352);--color-violet-100:lab(93.0838% 4.35197 -9.88284);--color-violet-800:lab(29.3188% 57.7986 -76.1493);--color-zinc-200:lab(90.6853% .399232 -1.45452);--color-zinc-700:lab(26.8019% 1.35387 -4.68303)}}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}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;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}*{border-color:var(--border);outline-color:var(--ring)}@supports (color:color-mix(in lab, red, red)){*{outline-color:color-mix(in oklab,var(--ring)50%,transparent)}}body{background-color:var(--background);color:var(--foreground)}}@layer components;@layer utilities{.\@container\/card-header{container:card-header/inline-size}.\@container\/field-group{container:field-group/inline-size}.pointer-events-none{pointer-events:none}.invisible{visibility:hidden}.sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.inset-0{inset:calc(var(--spacing)*0)}.inset-x-0{inset-inline:calc(var(--spacing)*0)}.inset-y-0{inset-block:calc(var(--spacing)*0)}.-top-12{top:calc(var(--spacing)*-12)}.top-0{top:calc(var(--spacing)*0)}.top-1\.5{top:calc(var(--spacing)*1.5)}.top-1\/2{top:50%}.top-2\.5{top:calc(var(--spacing)*2.5)}.top-3\.5{top:calc(var(--spacing)*3.5)}.top-4{top:calc(var(--spacing)*4)}.top-\[1px\]{top:1px}.top-\[50\%\]{top:50%}.top-\[60\%\]{top:60%}.top-full{top:100%}.-right-12{right:calc(var(--spacing)*-12)}.right-0{right:calc(var(--spacing)*0)}.right-1{right:calc(var(--spacing)*1)}.right-2{right:calc(var(--spacing)*2)}.right-3{right:calc(var(--spacing)*3)}.right-4{right:calc(var(--spacing)*4)}.-bottom-12{bottom:calc(var(--spacing)*-12)}.bottom-0{bottom:calc(var(--spacing)*0)}.-left-12{left:calc(var(--spacing)*-12)}.left-0{left:calc(var(--spacing)*0)}.left-1\/2{left:50%}.left-2{left:calc(var(--spacing)*2)}.left-\[50\%\]{left:50%}.isolate{isolation:isolate}.z-10{z-index:10}.z-20{z-index:20}.z-50{z-index:50}.z-\[1\]{z-index:1}.order-first{order:-9999}.order-last{order:9999}.col-span-2{grid-column:span 2/span 2}.col-start-2{grid-column-start:2}.row-span-2{grid-row:span 2/span 2}.row-start-1{grid-row-start:1}.container{width:100%}@media (min-width:40rem){.container{max-width:40rem}}@media (min-width:48rem){.container{max-width:48rem}}@media (min-width:64rem){.container{max-width:64rem}}@media (min-width:80rem){.container{max-width:80rem}}@media (min-width:96rem){.container{max-width:96rem}}.\!m-0{margin:calc(var(--spacing)*0)!important}.-mx-1{margin-inline:calc(var(--spacing)*-1)}.mx-2{margin-inline:calc(var(--spacing)*2)}.mx-3\.5{margin-inline:calc(var(--spacing)*3.5)}.mx-auto{margin-inline:auto}.-my-2{margin-block:calc(var(--spacing)*-2)}.my-0{margin-block:calc(var(--spacing)*0)}.my-0\.5{margin-block:calc(var(--spacing)*.5)}.my-1{margin-block:calc(var(--spacing)*1)}.-mt-4{margin-top:calc(var(--spacing)*-4)}.mt-0\.5{margin-top:calc(var(--spacing)*.5)}.mt-1{margin-top:calc(var(--spacing)*1)}.mt-1\.5{margin-top:calc(var(--spacing)*1.5)}.mt-2{margin-top:calc(var(--spacing)*2)}.mt-3{margin-top:calc(var(--spacing)*3)}.mt-4{margin-top:calc(var(--spacing)*4)}.mt-auto{margin-top:auto}.mr-1{margin-right:calc(var(--spacing)*1)}.mr-2{margin-right:calc(var(--spacing)*2)}.mb-1{margin-bottom:calc(var(--spacing)*1)}.mb-2{margin-bottom:calc(var(--spacing)*2)}.mb-3{margin-bottom:calc(var(--spacing)*3)}.mb-4{margin-bottom:calc(var(--spacing)*4)}.-ml-4{margin-left:calc(var(--spacing)*-4)}.ml-1{margin-left:calc(var(--spacing)*1)}.ml-2{margin-left:calc(var(--spacing)*2)}.ml-4{margin-left:calc(var(--spacing)*4)}.ml-auto{margin-left:auto}.line-clamp-1{-webkit-line-clamp:1;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-2{-webkit-line-clamp:2;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.block{display:block}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-flex{display:inline-flex}.table{display:table}.table-caption{display:table-caption}.table-cell{display:table-cell}.table-row{display:table-row}.field-sizing-content{field-sizing:content}.aspect-square{aspect-ratio:1}.aspect-video{aspect-ratio:var(--aspect-video)}.size-\(--cell-size\){width:var(--cell-size);height:var(--cell-size)}.size-2{width:calc(var(--spacing)*2);height:calc(var(--spacing)*2)}.size-2\.5{width:calc(var(--spacing)*2.5);height:calc(var(--spacing)*2.5)}.size-3{width:calc(var(--spacing)*3);height:calc(var(--spacing)*3)}.size-3\.5{width:calc(var(--spacing)*3.5);height:calc(var(--spacing)*3.5)}.size-4{width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.size-6{width:calc(var(--spacing)*6);height:calc(var(--spacing)*6)}.size-7{width:calc(var(--spacing)*7);height:calc(var(--spacing)*7)}.size-8{width:calc(var(--spacing)*8);height:calc(var(--spacing)*8)}.size-9{width:calc(var(--spacing)*9);height:calc(var(--spacing)*9)}.size-10{width:calc(var(--spacing)*10);height:calc(var(--spacing)*10)}.size-auto{width:auto;height:auto}.size-full{width:100%;height:100%}.h-\(--cell-size\){height:var(--cell-size)}.h-1\.5{height:calc(var(--spacing)*1.5)}.h-2{height:calc(var(--spacing)*2)}.h-2\.5{height:calc(var(--spacing)*2.5)}.h-3{height:calc(var(--spacing)*3)}.h-3\.5{height:calc(var(--spacing)*3.5)}.h-4{height:calc(var(--spacing)*4)}.h-5{height:calc(var(--spacing)*5)}.h-6{height:calc(var(--spacing)*6)}.h-7{height:calc(var(--spacing)*7)}.h-8{height:calc(var(--spacing)*8)}.h-9{height:calc(var(--spacing)*9)}.h-10{height:calc(var(--spacing)*10)}.h-12{height:calc(var(--spacing)*12)}.h-64{height:calc(var(--spacing)*64)}.h-\[1\.15rem\]{height:1.15rem}.h-\[100svh\]{height:100svh}.h-\[calc\(100\%-1px\)\]{height:calc(100% - 1px)}.h-\[var\(--radix-navigation-menu-viewport-height\)\]{height:var(--radix-navigation-menu-viewport-height)}.h-\[var\(--radix-select-trigger-height\)\]{height:var(--radix-select-trigger-height)}.h-auto{height:auto}.h-full{height:100%}.h-px{height:1px}.h-svh{height:100svh}.max-h-\(--radix-context-menu-content-available-height\){max-height:var(--radix-context-menu-content-available-height)}.max-h-\(--radix-dropdown-menu-content-available-height\){max-height:var(--radix-dropdown-menu-content-available-height)}.max-h-\(--radix-select-content-available-height\){max-height:var(--radix-select-content-available-height)}.max-h-\[50vh\]{max-height:50vh}.max-h-\[60vh\]{max-height:60vh}.max-h-\[90vh\]{max-height:90vh}.max-h-\[300px\]{max-height:300px}.min-h-0{min-height:calc(var(--spacing)*0)}.min-h-4{min-height:calc(var(--spacing)*4)}.min-h-16{min-height:calc(var(--spacing)*16)}.min-h-\[120px\]{min-height:120px}.min-h-screen{min-height:100vh}.min-h-svh{min-height:100svh}.w-\(--cell-size\){width:var(--cell-size)}.w-\(--sidebar-width\){width:var(--sidebar-width)}.w-0{width:calc(var(--spacing)*0)}.w-1{width:calc(var(--spacing)*1)}.w-2{width:calc(var(--spacing)*2)}.w-2\.5{width:calc(var(--spacing)*2.5)}.w-3{width:calc(var(--spacing)*3)}.w-3\.5{width:calc(var(--spacing)*3.5)}.w-3\/4{width:75%}.w-4{width:calc(var(--spacing)*4)}.w-5{width:calc(var(--spacing)*5)}.w-6{width:calc(var(--spacing)*6)}.w-7{width:calc(var(--spacing)*7)}.w-8{width:calc(var(--spacing)*8)}.w-9{width:calc(var(--spacing)*9)}.w-24{width:calc(var(--spacing)*24)}.w-28{width:calc(var(--spacing)*28)}.w-36{width:calc(var(--spacing)*36)}.w-40{width:calc(var(--spacing)*40)}.w-64{width:calc(var(--spacing)*64)}.w-72{width:calc(var(--spacing)*72)}.w-80{width:calc(var(--spacing)*80)}.w-\[26\%\]{width:26%}.w-\[48px\]{width:48px}.w-\[100px\]{width:100px}.w-\[120px\]{width:120px}.w-\[140px\]{width:140px}.w-\[160px\]{width:160px}.w-\[180px\]{width:180px}.w-\[220px\]{width:220px}.w-\[260px\]{width:260px}.w-\[280px\]{width:280px}.w-\[320px\]{width:320px}.w-auto{width:auto}.w-fit{width:fit-content}.w-full{width:100%}.w-max{width:max-content}.w-px{width:1px}.max-w-\(--skeleton-width\){max-width:var(--skeleton-width)}.max-w-2xl{max-width:var(--container-2xl)}.max-w-\[70vw\]{max-width:70vw}.max-w-\[420px\]{max-width:420px}.max-w-\[680px\]{max-width:680px}.max-w-\[calc\(100\%-2rem\)\]{max-width:calc(100% - 2rem)}.max-w-full{max-width:100%}.max-w-max{max-width:max-content}.max-w-md{max-width:var(--container-md)}.max-w-screen-2xl{max-width:var(--breakpoint-2xl)}.max-w-sm{max-width:var(--container-sm)}.min-w-\(--cell-size\){min-width:var(--cell-size)}.min-w-0{min-width:calc(var(--spacing)*0)}.min-w-5{min-width:calc(var(--spacing)*5)}.min-w-8{min-width:calc(var(--spacing)*8)}.min-w-9{min-width:calc(var(--spacing)*9)}.min-w-10{min-width:calc(var(--spacing)*10)}.min-w-\[8rem\]{min-width:8rem}.min-w-\[12rem\]{min-width:12rem}.min-w-\[220px\]{min-width:220px}.min-w-\[var\(--radix-select-trigger-width\)\]{min-width:var(--radix-select-trigger-width)}.min-w-full{min-width:100%}.flex-1{flex:1}.shrink-0{flex-shrink:0}.grow{flex-grow:1}.grow-0{flex-grow:0}.basis-full{flex-basis:100%}.caption-bottom{caption-side:bottom}.border-collapse{border-collapse:collapse}.origin-\(--radix-context-menu-content-transform-origin\){transform-origin:var(--radix-context-menu-content-transform-origin)}.origin-\(--radix-dropdown-menu-content-transform-origin\){transform-origin:var(--radix-dropdown-menu-content-transform-origin)}.origin-\(--radix-hover-card-content-transform-origin\){transform-origin:var(--radix-hover-card-content-transform-origin)}.origin-\(--radix-menubar-content-transform-origin\){transform-origin:var(--radix-menubar-content-transform-origin)}.origin-\(--radix-popover-content-transform-origin\){transform-origin:var(--radix-popover-content-transform-origin)}.origin-\(--radix-select-content-transform-origin\){transform-origin:var(--radix-select-content-transform-origin)}.origin-\(--radix-tooltip-content-transform-origin\){transform-origin:var(--radix-tooltip-content-transform-origin)}.-translate-x-1\/2{--tw-translate-x:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-x-px{--tw-translate-x:-1px;translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-x-\[-50\%\]{--tw-translate-x:-50%;translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-x-px{--tw-translate-x:1px;translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-y-1\/2{--tw-translate-y:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-0\.5{--tw-translate-y:calc(var(--spacing)*.5);translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-\[-50\%\]{--tw-translate-y:-50%;translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-\[calc\(-50\%_-_2px\)\]{--tw-translate-y:calc(-50% - 2px);translate:var(--tw-translate-x)var(--tw-translate-y)}.rotate-45{rotate:45deg}.rotate-90{rotate:90deg}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.animate-caret-blink{animation:1.25s ease-out infinite caret-blink}.animate-in{animation:enter var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.animate-pulse{animation:var(--animate-pulse)}.animate-spin{animation:var(--animate-spin)}.cursor-default{cursor:default}.cursor-pointer{cursor:pointer}.cursor-text{cursor:text}.touch-none{touch-action:none}.resize-none{resize:none}.scroll-my-1{scroll-margin-block:calc(var(--spacing)*1)}.scroll-py-1{scroll-padding-block:calc(var(--spacing)*1)}.list-disc{list-style-type:disc}.list-none{list-style-type:none}.auto-rows-min{grid-auto-rows:min-content}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-\[0_1fr\]{grid-template-columns:0 1fr}.grid-rows-\[auto_auto\]{grid-template-rows:auto auto}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.place-content-center{place-content:center}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.items-stretch{align-items:stretch}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.justify-start{justify-content:flex-start}.justify-items-start{justify-items:start}.gap-0\.5{gap:calc(var(--spacing)*.5)}.gap-1{gap:calc(var(--spacing)*1)}.gap-1\.5{gap:calc(var(--spacing)*1.5)}.gap-2{gap:calc(var(--spacing)*2)}.gap-2\.5{gap:calc(var(--spacing)*2.5)}.gap-3{gap:calc(var(--spacing)*3)}.gap-4{gap:calc(var(--spacing)*4)}.gap-6{gap:calc(var(--spacing)*6)}.gap-7{gap:calc(var(--spacing)*7)}.gap-\[--spacing\(var\(--gap\)\)\]{gap:calc(var(--spacing)*var(--gap))}:where(.space-y-0>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*0)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*0)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*1)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*1)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*2)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*2)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*3)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*3)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*4)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*4)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*5)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*5)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-6>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*6)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*6)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-x-2>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*2)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*2)*calc(1 - var(--tw-space-x-reverse)))}.gap-y-0\.5{row-gap:calc(var(--spacing)*.5)}:where(.divide-border>:not(:last-child)){border-color:var(--border)}.self-start{align-self:flex-start}.self-stretch{align-self:stretch}.justify-self-end{justify-self:flex-end}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-auto{overflow-y:auto}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:var(--radius-2xl)}.rounded-\[2px\]{border-radius:2px}.rounded-\[4px\]{border-radius:4px}.rounded-\[calc\(var\(--radius\)-5px\)\]{border-radius:calc(var(--radius) - 5px)}.rounded-\[inherit\]{border-radius:inherit}.rounded-full{border-radius:3.40282e38px}.rounded-lg{border-radius:var(--radius)}.rounded-md{border-radius:calc(var(--radius) - 2px)}.rounded-none{border-radius:0}.rounded-sm{border-radius:calc(var(--radius) - 4px)}.rounded-xl{border-radius:calc(var(--radius) + 4px)}.rounded-xs{border-radius:var(--radius-xs)}.rounded-l-md{border-top-left-radius:calc(var(--radius) - 2px);border-bottom-left-radius:calc(var(--radius) - 2px)}.rounded-tl-sm{border-top-left-radius:calc(var(--radius) - 4px)}.rounded-r-md{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}.border{border-style:var(--tw-border-style);border-width:1px}.border-0{border-style:var(--tw-border-style);border-width:0}.border-\[1\.5px\]{border-style:var(--tw-border-style);border-width:1.5px}.border-y{border-block-style:var(--tw-border-style);border-block-width:1px}.border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.border-r{border-right-style:var(--tw-border-style);border-right-width:1px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.border-dashed{--tw-border-style:dashed;border-style:dashed}.border-\(--color-border\){border-color:var(--color-border)}.border-amber-200{border-color:var(--color-amber-200)}.border-border,.border-border\/50{border-color:var(--border)}@supports (color:color-mix(in lab, red, red)){.border-border\/50{border-color:color-mix(in oklab,var(--border)50%,transparent)}}.border-destructive{border-color:var(--destructive)}.border-input{border-color:var(--input)}.border-primary{border-color:var(--primary)}.border-sidebar-border{border-color:var(--sidebar-border)}.border-transparent{border-color:#0000}.border-t-transparent{border-top-color:#0000}.border-l-transparent{border-left-color:#0000}.bg-\(--color-bg\){background-color:var(--color-bg)}.bg-accent{background-color:var(--accent)}.bg-amber-50{background-color:var(--color-amber-50)}.bg-amber-100{background-color:var(--color-amber-100)}.bg-background{background-color:var(--background)}.bg-black\/50{background-color:#00000080}@supports (color:color-mix(in lab, red, red)){.bg-black\/50{background-color:color-mix(in oklab,var(--color-black)50%,transparent)}}.bg-border{background-color:var(--border)}.bg-card{background-color:var(--card)}.bg-destructive{background-color:var(--destructive)}.bg-emerald-100{background-color:var(--color-emerald-100)}.bg-foreground{background-color:var(--foreground)}.bg-input{background-color:var(--input)}.bg-muted,.bg-muted\/30{background-color:var(--muted)}@supports (color:color-mix(in lab, red, red)){.bg-muted\/30{background-color:color-mix(in oklab,var(--muted)30%,transparent)}}.bg-muted\/40{background-color:var(--muted)}@supports (color:color-mix(in lab, red, red)){.bg-muted\/40{background-color:color-mix(in oklab,var(--muted)40%,transparent)}}.bg-muted\/50{background-color:var(--muted)}@supports (color:color-mix(in lab, red, red)){.bg-muted\/50{background-color:color-mix(in oklab,var(--muted)50%,transparent)}}.bg-muted\/70{background-color:var(--muted)}@supports (color:color-mix(in lab, red, red)){.bg-muted\/70{background-color:color-mix(in oklab,var(--muted)70%,transparent)}}.bg-orange-100{background-color:var(--color-orange-100)}.bg-popover{background-color:var(--popover)}.bg-primary,.bg-primary\/20{background-color:var(--primary)}@supports (color:color-mix(in lab, red, red)){.bg-primary\/20{background-color:color-mix(in oklab,var(--primary)20%,transparent)}}.bg-red-100{background-color:var(--color-red-100)}.bg-secondary{background-color:var(--secondary)}.bg-sidebar{background-color:var(--sidebar)}.bg-sidebar-border{background-color:var(--sidebar-border)}.bg-sky-100{background-color:var(--color-sky-100)}.bg-transparent{background-color:#0000}.bg-violet-100{background-color:var(--color-violet-100)}.bg-white{background-color:var(--color-white)}.bg-zinc-200{background-color:var(--color-zinc-200)}.fill-current{fill:currentColor}.fill-foreground{fill:var(--foreground)}.fill-primary{fill:var(--primary)}.p-0{padding:calc(var(--spacing)*0)}.p-1{padding:calc(var(--spacing)*1)}.p-2{padding:calc(var(--spacing)*2)}.p-3{padding:calc(var(--spacing)*3)}.p-4{padding:calc(var(--spacing)*4)}.p-6{padding:calc(var(--spacing)*6)}.p-\[3px\]{padding:3px}.p-px{padding:1px}.px-\(--cell-size\){padding-inline:var(--cell-size)}.px-1{padding-inline:calc(var(--spacing)*1)}.px-1\.5{padding-inline:calc(var(--spacing)*1.5)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-2\.5{padding-inline:calc(var(--spacing)*2.5)}.px-3{padding-inline:calc(var(--spacing)*3)}.px-4{padding-inline:calc(var(--spacing)*4)}.px-6{padding-inline:calc(var(--spacing)*6)}.py-0{padding-block:calc(var(--spacing)*0)}.py-0\.5{padding-block:calc(var(--spacing)*.5)}.py-1{padding-block:calc(var(--spacing)*1)}.py-1\.5{padding-block:calc(var(--spacing)*1.5)}.py-2{padding-block:calc(var(--spacing)*2)}.py-3{padding-block:calc(var(--spacing)*3)}.py-4{padding-block:calc(var(--spacing)*4)}.py-6{padding-block:calc(var(--spacing)*6)}.py-8{padding-block:calc(var(--spacing)*8)}.py-10{padding-block:calc(var(--spacing)*10)}.py-12{padding-block:calc(var(--spacing)*12)}.pt-0{padding-top:calc(var(--spacing)*0)}.pt-2{padding-top:calc(var(--spacing)*2)}.pt-3{padding-top:calc(var(--spacing)*3)}.pt-4{padding-top:calc(var(--spacing)*4)}.pr-1{padding-right:calc(var(--spacing)*1)}.pr-2{padding-right:calc(var(--spacing)*2)}.pr-2\.5{padding-right:calc(var(--spacing)*2.5)}.pr-3{padding-right:calc(var(--spacing)*3)}.pr-4{padding-right:calc(var(--spacing)*4)}.pr-8{padding-right:calc(var(--spacing)*8)}.pb-2{padding-bottom:calc(var(--spacing)*2)}.pb-3{padding-bottom:calc(var(--spacing)*3)}.pb-4{padding-bottom:calc(var(--spacing)*4)}.pl-2{padding-left:calc(var(--spacing)*2)}.pl-3{padding-left:calc(var(--spacing)*3)}.pl-4{padding-left:calc(var(--spacing)*4)}.pl-8{padding-left:calc(var(--spacing)*8)}.text-center{text-align:center}.text-left{text-align:left}.text-right{text-align:right}.align-middle{vertical-align:middle}.font-mono{font-family:var(--font-mono)}.font-sans{font-family:var(--font-sans)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-sm\/relaxed{font-size:var(--text-sm);line-height:var(--leading-relaxed)}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-\[0\.8rem\]{font-size:.8rem}.text-\[11px\]{font-size:11px}.leading-none{--tw-leading:1;line-height:1}.leading-normal{--tw-leading:var(--leading-normal);line-height:var(--leading-normal)}.leading-relaxed{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}.leading-snug{--tw-leading:var(--leading-snug);line-height:var(--leading-snug)}.font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-normal{--tw-font-weight:var(--font-weight-normal);font-weight:var(--font-weight-normal)}.font-semibold{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.tracking-tight{--tw-tracking:var(--tracking-tight);letter-spacing:var(--tracking-tight)}.tracking-wide{--tw-tracking:var(--tracking-wide);letter-spacing:var(--tracking-wide)}.tracking-widest{--tw-tracking:var(--tracking-widest);letter-spacing:var(--tracking-widest)}.text-balance{text-wrap:balance}.break-words{overflow-wrap:break-word}.break-all{word-break:break-all}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-wrap{white-space:pre-wrap}.text-accent-foreground{color:var(--accent-foreground)}.text-amber-800{color:var(--color-amber-800)}.text-amber-900{color:var(--color-amber-900)}.text-background{color:var(--background)}.text-blue-600{color:var(--color-blue-600)}.text-card-foreground{color:var(--card-foreground)}.text-current{color:currentColor}.text-destructive{color:var(--destructive)}.text-emerald-600{color:var(--color-emerald-600)}.text-emerald-800{color:var(--color-emerald-800)}.text-foreground{color:var(--foreground)}.text-muted-foreground{color:var(--muted-foreground)}.text-orange-800{color:var(--color-orange-800)}.text-popover-foreground{color:var(--popover-foreground)}.text-primary{color:var(--primary)}.text-primary-foreground{color:var(--primary-foreground)}.text-red-500{color:var(--color-red-500)}.text-red-600{color:var(--color-red-600)}.text-red-800{color:var(--color-red-800)}.text-secondary-foreground{color:var(--secondary-foreground)}.text-sidebar-foreground,.text-sidebar-foreground\/70{color:var(--sidebar-foreground)}@supports (color:color-mix(in lab, red, red)){.text-sidebar-foreground\/70{color:color-mix(in oklab,var(--sidebar-foreground)70%,transparent)}}.text-sky-800{color:var(--color-sky-800)}.text-violet-800{color:var(--color-violet-800)}.text-white{color:var(--color-white)}.text-zinc-700{color:var(--color-zinc-700)}.capitalize{text-transform:capitalize}.uppercase{text-transform:uppercase}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,)var(--tw-slashed-zero,)var(--tw-numeric-figure,)var(--tw-numeric-spacing,)var(--tw-numeric-fraction,)}.underline-offset-4{text-underline-offset:4px}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-80{opacity:.8}.opacity-100{opacity:1}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[0_0_0_1px_hsl\(var\(--sidebar-border\)\)\]{--tw-shadow:0 0 0 1px var(--tw-shadow-color,hsl(var(--sidebar-border)));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-md{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a),0 2px 4px -2px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-none{--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-xl{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a),0 8px 10px -6px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-xs{--tw-shadow:0 1px 2px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-0{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(0px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-ring\/50{--tw-ring-color:var(--ring)}@supports (color:color-mix(in lab, red, red)){.ring-ring\/50{--tw-ring-color:color-mix(in oklab,var(--ring)50%,transparent)}}.ring-sidebar-ring{--tw-ring-color:var(--sidebar-ring)}.ring-offset-background{--tw-ring-offset-color:var(--background)}.outline-hidden{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.outline-hidden{outline-offset:2px;outline:2px solid #0000}}.outline{outline-style:var(--tw-outline-style);outline-width:1px}.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,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\[color\,box-shadow\]{transition-property:color,box-shadow;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\[left\,right\,width\]{transition-property:left,right,width;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\[margin\,opacity\]{transition-property:margin,opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\[width\,height\,padding\]{transition-property:width,height,padding;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\[width\]{transition-property:width;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-shadow{transition-property:box-shadow;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-none{transition-property:none}.duration-100{--tw-duration:.1s;transition-duration:.1s}.duration-200{--tw-duration:.2s;transition-duration:.2s}.duration-300{--tw-duration:.3s;transition-duration:.3s}.duration-1000{--tw-duration:1s;transition-duration:1s}.ease-in-out{--tw-ease:var(--ease-in-out);transition-timing-function:var(--ease-in-out)}.ease-linear{--tw-ease:linear;transition-timing-function:linear}.fade-in-0{--tw-enter-opacity:0}.outline-none{--tw-outline-style:none;outline-style:none}.select-none{-webkit-user-select:none;user-select:none}.zoom-in-95{--tw-enter-scale:.95}.\[--cell-size\:--spacing\(8\)\]{--cell-size:calc(var(--spacing)*8)}.running{animation-play-state:running}.group-focus-within\/menu-item\:opacity-100:is(:where(.group\/menu-item):focus-within *){opacity:1}@media (hover:hover){.group-hover\/menu-item\:opacity-100:is(:where(.group\/menu-item):hover *){opacity:1}}.group-has-data-\[sidebar\=menu-action\]\/menu-item\:pr-8:is(:where(.group\/menu-item):has([data-sidebar=menu-action]) *){padding-right:calc(var(--spacing)*8)}.group-has-\[\[data-orientation\=horizontal\]\]\/field\:text-balance:is(:where(.group\/field):has([data-orientation=horizontal]) *){text-wrap:balance}.group-has-\[\[data-slot\=item-description\]\]\/item\:translate-y-0\.5:is(:where(.group\/item):has([data-slot=item-description]) *){--tw-translate-y:calc(var(--spacing)*.5);translate:var(--tw-translate-x)var(--tw-translate-y)}.group-has-\[\[data-slot\=item-description\]\]\/item\:self-start:is(:where(.group\/item):has([data-slot=item-description]) *){align-self:flex-start}.group-has-\[\>input\]\/input-group\:pt-2\.5:is(:where(.group\/input-group):has(>input) *){padding-top:calc(var(--spacing)*2.5)}.group-has-\[\>input\]\/input-group\:pb-2\.5:is(:where(.group\/input-group):has(>input) *){padding-bottom:calc(var(--spacing)*2.5)}.group-data-\[collapsible\=icon\]\:-mt-8:is(:where(.group)[data-collapsible=icon] *){margin-top:calc(var(--spacing)*-8)}.group-data-\[collapsible\=icon\]\:hidden:is(:where(.group)[data-collapsible=icon] *){display:none}.group-data-\[collapsible\=icon\]\:size-8\!:is(:where(.group)[data-collapsible=icon] *){width:calc(var(--spacing)*8)!important;height:calc(var(--spacing)*8)!important}.group-data-\[collapsible\=icon\]\:w-\(--sidebar-width-icon\):is(:where(.group)[data-collapsible=icon] *){width:var(--sidebar-width-icon)}.group-data-\[collapsible\=icon\]\:w-\[calc\(var\(--sidebar-width-icon\)\+\(--spacing\(4\)\)\)\]:is(:where(.group)[data-collapsible=icon] *){width:calc(var(--sidebar-width-icon) + (calc(var(--spacing)*4)))}.group-data-\[collapsible\=icon\]\:w-\[calc\(var\(--sidebar-width-icon\)\+\(--spacing\(4\)\)\+2px\)\]:is(:where(.group)[data-collapsible=icon] *){width:calc(var(--sidebar-width-icon) + (calc(var(--spacing)*4)) + 2px)}.group-data-\[collapsible\=icon\]\:overflow-hidden:is(:where(.group)[data-collapsible=icon] *){overflow:hidden}.group-data-\[collapsible\=icon\]\:p-0\!:is(:where(.group)[data-collapsible=icon] *){padding:calc(var(--spacing)*0)!important}.group-data-\[collapsible\=icon\]\:p-2\!:is(:where(.group)[data-collapsible=icon] *){padding:calc(var(--spacing)*2)!important}.group-data-\[collapsible\=icon\]\:opacity-0:is(:where(.group)[data-collapsible=icon] *){opacity:0}.group-data-\[collapsible\=offcanvas\]\:right-\[calc\(var\(--sidebar-width\)\*-1\)\]:is(:where(.group)[data-collapsible=offcanvas] *){right:calc(var(--sidebar-width)*-1)}.group-data-\[collapsible\=offcanvas\]\:left-\[calc\(var\(--sidebar-width\)\*-1\)\]:is(:where(.group)[data-collapsible=offcanvas] *){left:calc(var(--sidebar-width)*-1)}.group-data-\[collapsible\=offcanvas\]\:w-0:is(:where(.group)[data-collapsible=offcanvas] *){width:calc(var(--spacing)*0)}.group-data-\[collapsible\=offcanvas\]\:translate-x-0:is(:where(.group)[data-collapsible=offcanvas] *){--tw-translate-x:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.group-data-\[disabled\=true\]\:pointer-events-none:is(:where(.group)[data-disabled=true] *){pointer-events:none}.group-data-\[disabled\=true\]\:opacity-50:is(:where(.group)[data-disabled=true] *),.group-data-\[disabled\=true\]\/field\:opacity-50:is(:where(.group\/field)[data-disabled=true] *),.group-data-\[disabled\=true\]\/input-group\:opacity-50:is(:where(.group\/input-group)[data-disabled=true] *){opacity:.5}.group-data-\[focused\=true\]\/day\:relative:is(:where(.group\/day)[data-focused=true] *){position:relative}.group-data-\[focused\=true\]\/day\:z-10:is(:where(.group\/day)[data-focused=true] *){z-index:10}.group-data-\[focused\=true\]\/day\:border-ring:is(:where(.group\/day)[data-focused=true] *){border-color:var(--ring)}.group-data-\[focused\=true\]\/day\:ring-\[3px\]:is(:where(.group\/day)[data-focused=true] *){--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(3px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.group-data-\[focused\=true\]\/day\:ring-ring\/50:is(:where(.group\/day)[data-focused=true] *){--tw-ring-color:var(--ring)}@supports (color:color-mix(in lab, red, red)){.group-data-\[focused\=true\]\/day\:ring-ring\/50:is(:where(.group\/day)[data-focused=true] *){--tw-ring-color:color-mix(in oklab,var(--ring)50%,transparent)}}.group-data-\[side\=left\]\:-right-4:is(:where(.group)[data-side=left] *){right:calc(var(--spacing)*-4)}.group-data-\[side\=left\]\:border-r:is(:where(.group)[data-side=left] *){border-right-style:var(--tw-border-style);border-right-width:1px}.group-data-\[side\=right\]\:left-0:is(:where(.group)[data-side=right] *){left:calc(var(--spacing)*0)}.group-data-\[side\=right\]\:rotate-180:is(:where(.group)[data-side=right] *){rotate:180deg}.group-data-\[side\=right\]\:border-l:is(:where(.group)[data-side=right] *){border-left-style:var(--tw-border-style);border-left-width:1px}.group-data-\[state\=open\]\:rotate-180:is(:where(.group)[data-state=open] *){rotate:180deg}.group-data-\[variant\=floating\]\:rounded-lg:is(:where(.group)[data-variant=floating] *){border-radius:var(--radius)}.group-data-\[variant\=floating\]\:border:is(:where(.group)[data-variant=floating] *){border-style:var(--tw-border-style);border-width:1px}.group-data-\[variant\=floating\]\:border-sidebar-border:is(:where(.group)[data-variant=floating] *){border-color:var(--sidebar-border)}.group-data-\[variant\=floating\]\:shadow-sm:is(:where(.group)[data-variant=floating] *){--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.group-data-\[variant\=outline\]\/field-group\:-mb-2:is(:where(.group\/field-group)[data-variant=outline] *){margin-bottom:calc(var(--spacing)*-2)}.group-data-\[vaul-drawer-direction\=bottom\]\/drawer-content\:block:is(:where(.group\/drawer-content)[data-vaul-drawer-direction=bottom] *){display:block}.group-data-\[vaul-drawer-direction\=bottom\]\/drawer-content\:text-center:is(:where(.group\/drawer-content)[data-vaul-drawer-direction=bottom] *),.group-data-\[vaul-drawer-direction\=top\]\/drawer-content\:text-center:is(:where(.group\/drawer-content)[data-vaul-drawer-direction=top] *){text-align:center}.group-data-\[viewport\=false\]\/navigation-menu\:top-full:is(:where(.group\/navigation-menu)[data-viewport=false] *){top:100%}.group-data-\[viewport\=false\]\/navigation-menu\:mt-1\.5:is(:where(.group\/navigation-menu)[data-viewport=false] *){margin-top:calc(var(--spacing)*1.5)}.group-data-\[viewport\=false\]\/navigation-menu\:overflow-hidden:is(:where(.group\/navigation-menu)[data-viewport=false] *){overflow:hidden}.group-data-\[viewport\=false\]\/navigation-menu\:rounded-md:is(:where(.group\/navigation-menu)[data-viewport=false] *){border-radius:calc(var(--radius) - 2px)}.group-data-\[viewport\=false\]\/navigation-menu\:border:is(:where(.group\/navigation-menu)[data-viewport=false] *){border-style:var(--tw-border-style);border-width:1px}.group-data-\[viewport\=false\]\/navigation-menu\:bg-popover:is(:where(.group\/navigation-menu)[data-viewport=false] *){background-color:var(--popover)}.group-data-\[viewport\=false\]\/navigation-menu\:text-popover-foreground:is(:where(.group\/navigation-menu)[data-viewport=false] *){color:var(--popover-foreground)}.group-data-\[viewport\=false\]\/navigation-menu\:shadow:is(:where(.group\/navigation-menu)[data-viewport=false] *){--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.group-data-\[viewport\=false\]\/navigation-menu\:duration-200:is(:where(.group\/navigation-menu)[data-viewport=false] *){--tw-duration:.2s;transition-duration:.2s}@media (hover:hover){.peer-hover\/menu-button\:text-sidebar-accent-foreground:is(:where(.peer\/menu-button):hover~*){color:var(--sidebar-accent-foreground)}}.peer-disabled\:cursor-not-allowed:is(:where(.peer):disabled~*){cursor:not-allowed}.peer-disabled\:opacity-50:is(:where(.peer):disabled~*){opacity:.5}.peer-data-\[active\=true\]\/menu-button\:text-sidebar-accent-foreground:is(:where(.peer\/menu-button)[data-active=true]~*){color:var(--sidebar-accent-foreground)}.peer-data-\[size\=default\]\/menu-button\:top-1\.5:is(:where(.peer\/menu-button)[data-size=default]~*){top:calc(var(--spacing)*1.5)}.peer-data-\[size\=lg\]\/menu-button\:top-2\.5:is(:where(.peer\/menu-button)[data-size=lg]~*){top:calc(var(--spacing)*2.5)}.peer-data-\[size\=sm\]\/menu-button\:top-1:is(:where(.peer\/menu-button)[data-size=sm]~*){top:calc(var(--spacing)*1)}.selection\:bg-primary ::selection,.selection\:bg-primary::selection{background-color:var(--primary)}.selection\:text-primary-foreground ::selection,.selection\:text-primary-foreground::selection{color:var(--primary-foreground)}.file\:inline-flex::file-selector-button{display:inline-flex}.file\:h-7::file-selector-button{height:calc(var(--spacing)*7)}.file\:border-0::file-selector-button{border-style:var(--tw-border-style);border-width:0}.file\:bg-transparent::file-selector-button{background-color:#0000}.file\:text-sm::file-selector-button{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.file\:font-medium::file-selector-button{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.file\:text-foreground::file-selector-button{color:var(--foreground)}.placeholder\:text-muted-foreground::placeholder{color:var(--muted-foreground)}.after\:absolute:after{content:var(--tw-content);position:absolute}.after\:-inset-2:after{content:var(--tw-content);inset:calc(var(--spacing)*-2)}.after\:inset-y-0:after{content:var(--tw-content);inset-block:calc(var(--spacing)*0)}.after\:left-1\/2:after{content:var(--tw-content);left:50%}.after\:w-1:after{content:var(--tw-content);width:calc(var(--spacing)*1)}.after\:w-\[2px\]:after{content:var(--tw-content);width:2px}.after\:-translate-x-1\/2:after{content:var(--tw-content);--tw-translate-x:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.group-data-\[collapsible\=offcanvas\]\:after\:left-full:is(:where(.group)[data-collapsible=offcanvas] *):after{content:var(--tw-content);left:100%}.first\:rounded-l-md:first-child{border-top-left-radius:calc(var(--radius) - 2px);border-bottom-left-radius:calc(var(--radius) - 2px)}.first\:border-l:first-child{border-left-style:var(--tw-border-style);border-left-width:1px}.last\:mt-0:last-child{margin-top:calc(var(--spacing)*0)}.last\:rounded-r-md:last-child{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}.last\:border-b-0:last-child{border-bottom-style:var(--tw-border-style);border-bottom-width:0}@media (hover:hover){.hover\:bg-accent:hover{background-color:var(--accent)}.hover\:bg-destructive\/90:hover{background-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.hover\:bg-destructive\/90:hover{background-color:color-mix(in oklab,var(--destructive)90%,transparent)}}.hover\:bg-muted:hover,.hover\:bg-muted\/30:hover{background-color:var(--muted)}@supports (color:color-mix(in lab, red, red)){.hover\:bg-muted\/30:hover{background-color:color-mix(in oklab,var(--muted)30%,transparent)}}.hover\:bg-muted\/50:hover{background-color:var(--muted)}@supports (color:color-mix(in lab, red, red)){.hover\:bg-muted\/50:hover{background-color:color-mix(in oklab,var(--muted)50%,transparent)}}.hover\:bg-primary\/90:hover{background-color:var(--primary)}@supports (color:color-mix(in lab, red, red)){.hover\:bg-primary\/90:hover{background-color:color-mix(in oklab,var(--primary)90%,transparent)}}.hover\:bg-secondary\/80:hover{background-color:var(--secondary)}@supports (color:color-mix(in lab, red, red)){.hover\:bg-secondary\/80:hover{background-color:color-mix(in oklab,var(--secondary)80%,transparent)}}.hover\:bg-sidebar-accent:hover{background-color:var(--sidebar-accent)}.hover\:text-accent-foreground:hover{color:var(--accent-foreground)}.hover\:text-foreground:hover{color:var(--foreground)}.hover\:text-muted-foreground:hover{color:var(--muted-foreground)}.hover\:text-sidebar-accent-foreground:hover{color:var(--sidebar-accent-foreground)}.hover\:underline:hover{text-decoration-line:underline}.hover\:opacity-100:hover{opacity:1}.hover\:shadow-\[0_0_0_1px_hsl\(var\(--sidebar-accent\)\)\]:hover{--tw-shadow:0 0 0 1px var(--tw-shadow-color,hsl(var(--sidebar-accent)));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.hover\:ring-4:hover{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(4px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.hover\:group-data-\[collapsible\=offcanvas\]\:bg-sidebar:hover:is(:where(.group)[data-collapsible=offcanvas] *){background-color:var(--sidebar)}.hover\:after\:bg-sidebar-border:hover:after{content:var(--tw-content);background-color:var(--sidebar-border)}}.focus\:z-10:focus{z-index:10}.focus\:bg-accent:focus{background-color:var(--accent)}.focus\:text-accent-foreground:focus{color:var(--accent-foreground)}.focus\:text-red-600:focus{color:var(--color-red-600)}.focus\:ring-2:focus{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(2px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus\:ring-ring:focus{--tw-ring-color:var(--ring)}.focus\:ring-offset-2:focus{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,)0 0 0 var(--tw-ring-offset-width)var(--tw-ring-offset-color)}.focus\:outline-hidden:focus{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.focus\:outline-hidden:focus{outline-offset:2px;outline:2px solid #0000}}.focus-visible\:z-10:focus-visible{z-index:10}.focus-visible\:border-ring:focus-visible{border-color:var(--ring)}.focus-visible\:ring-0:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(0px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus-visible\:ring-1:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(1px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus-visible\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(2px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus-visible\:ring-4:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(4px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus-visible\:ring-\[3px\]:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(3px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus-visible\:ring-destructive:focus-visible,.focus-visible\:ring-destructive\/20:focus-visible{--tw-ring-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.focus-visible\:ring-destructive\/20:focus-visible{--tw-ring-color:color-mix(in oklab,var(--destructive)20%,transparent)}}.focus-visible\:ring-ring:focus-visible,.focus-visible\:ring-ring\/50:focus-visible{--tw-ring-color:var(--ring)}@supports (color:color-mix(in lab, red, red)){.focus-visible\:ring-ring\/50:focus-visible{--tw-ring-color:color-mix(in oklab,var(--ring)50%,transparent)}}.focus-visible\:ring-offset-1:focus-visible{--tw-ring-offset-width:1px;--tw-ring-offset-shadow:var(--tw-ring-inset,)0 0 0 var(--tw-ring-offset-width)var(--tw-ring-offset-color)}.focus-visible\:ring-offset-2:focus-visible{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,)0 0 0 var(--tw-ring-offset-width)var(--tw-ring-offset-color)}.focus-visible\:ring-offset-background:focus-visible{--tw-ring-offset-color:var(--background)}.focus-visible\:outline-hidden:focus-visible{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.focus-visible\:outline-hidden:focus-visible{outline-offset:2px;outline:2px solid #0000}}.focus-visible\:outline-1:focus-visible{outline-style:var(--tw-outline-style);outline-width:1px}.focus-visible\:outline-ring:focus-visible{outline-color:var(--ring)}.focus-visible\:outline-none:focus-visible{--tw-outline-style:none;outline-style:none}.active\:bg-sidebar-accent:active{background-color:var(--sidebar-accent)}.active\:text-sidebar-accent-foreground:active{color:var(--sidebar-accent-foreground)}.disabled\:pointer-events-none:disabled{pointer-events:none}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:opacity-50:disabled{opacity:.5}:where([data-side=left]) .in-data-\[side\=left\]\:cursor-w-resize{cursor:w-resize}:where([data-side=right]) .in-data-\[side\=right\]\:cursor-e-resize{cursor:e-resize}.has-focus\:border-ring:has(:focus){border-color:var(--ring)}.has-focus\:ring-\[3px\]:has(:focus){--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(3px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.has-focus\:ring-ring\/50:has(:focus){--tw-ring-color:var(--ring)}@supports (color:color-mix(in lab, red, red)){.has-focus\:ring-ring\/50:has(:focus){--tw-ring-color:color-mix(in oklab,var(--ring)50%,transparent)}}.has-disabled\:opacity-50:has(:disabled){opacity:.5}.has-data-\[slot\=card-action\]\:grid-cols-\[1fr_auto\]:has([data-slot=card-action]){grid-template-columns:1fr auto}.has-data-\[state\=checked\]\:border-primary:has([data-state=checked]){border-color:var(--primary)}.has-data-\[state\=checked\]\:bg-primary\/5:has([data-state=checked]){background-color:var(--primary)}@supports (color:color-mix(in lab, red, red)){.has-data-\[state\=checked\]\:bg-primary\/5:has([data-state=checked]){background-color:color-mix(in oklab,var(--primary)5%,transparent)}}.has-data-\[variant\=inset\]\:bg-sidebar:has([data-variant=inset]){background-color:var(--sidebar)}.has-\[\[data-slot\=input-group-control\]\:focus-visible\]\:border-ring:has([data-slot=input-group-control]:focus-visible){border-color:var(--ring)}.has-\[\[data-slot\=input-group-control\]\:focus-visible\]\:ring-\[3px\]:has([data-slot=input-group-control]:focus-visible){--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(3px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.has-\[\[data-slot\=input-group-control\]\:focus-visible\]\:ring-ring\/50:has([data-slot=input-group-control]:focus-visible){--tw-ring-color:var(--ring)}@supports (color:color-mix(in lab, red, red)){.has-\[\[data-slot\=input-group-control\]\:focus-visible\]\:ring-ring\/50:has([data-slot=input-group-control]:focus-visible){--tw-ring-color:color-mix(in oklab,var(--ring)50%,transparent)}}.has-\[\[data-slot\]\[aria-invalid\=true\]\]\:border-destructive:has([data-slot][aria-invalid=true]){border-color:var(--destructive)}.has-\[\[data-slot\]\[aria-invalid\=true\]\]\:ring-destructive\/20:has([data-slot][aria-invalid=true]){--tw-ring-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.has-\[\[data-slot\]\[aria-invalid\=true\]\]\:ring-destructive\/20:has([data-slot][aria-invalid=true]){--tw-ring-color:color-mix(in oklab,var(--destructive)20%,transparent)}}.has-\[\>\[data-align\=block-end\]\]\:h-auto:has(>[data-align=block-end]){height:auto}.has-\[\>\[data-align\=block-end\]\]\:flex-col:has(>[data-align=block-end]){flex-direction:column}.has-\[\>\[data-align\=block-start\]\]\:h-auto:has(>[data-align=block-start]){height:auto}.has-\[\>\[data-align\=block-start\]\]\:flex-col:has(>[data-align=block-start]){flex-direction:column}.has-\[\>\[data-slot\=button-group\]\]\:gap-2:has(>[data-slot=button-group]){gap:calc(var(--spacing)*2)}.has-\[\>\[data-slot\=checkbox-group\]\]\:gap-3:has(>[data-slot=checkbox-group]){gap:calc(var(--spacing)*3)}.has-\[\>\[data-slot\=field-content\]\]\:items-start:has(>[data-slot=field-content]){align-items:flex-start}.has-\[\>\[data-slot\=field\]\]\:w-full:has(>[data-slot=field]){width:100%}.has-\[\>\[data-slot\=field\]\]\:flex-col:has(>[data-slot=field]){flex-direction:column}.has-\[\>\[data-slot\=field\]\]\:rounded-md:has(>[data-slot=field]){border-radius:calc(var(--radius) - 2px)}.has-\[\>\[data-slot\=field\]\]\:border:has(>[data-slot=field]){border-style:var(--tw-border-style);border-width:1px}.has-\[\>\[data-slot\=radio-group\]\]\:gap-3:has(>[data-slot=radio-group]){gap:calc(var(--spacing)*3)}.has-\[\>button\]\:mr-\[-0\.45rem\]:has(>button){margin-right:-.45rem}.has-\[\>button\]\:ml-\[-0\.45rem\]:has(>button){margin-left:-.45rem}.has-\[\>kbd\]\:mr-\[-0\.35rem\]:has(>kbd){margin-right:-.35rem}.has-\[\>kbd\]\:ml-\[-0\.35rem\]:has(>kbd){margin-left:-.35rem}.has-\[\>svg\]\:grid-cols-\[calc\(var\(--spacing\)\*4\)_1fr\]:has(>svg){grid-template-columns:calc(var(--spacing)*4)1fr}.has-\[\>svg\]\:gap-x-3:has(>svg){column-gap:calc(var(--spacing)*3)}.has-\[\>svg\]\:p-0:has(>svg){padding:calc(var(--spacing)*0)}.has-\[\>svg\]\:px-2:has(>svg){padding-inline:calc(var(--spacing)*2)}.has-\[\>svg\]\:px-2\.5:has(>svg){padding-inline:calc(var(--spacing)*2.5)}.has-\[\>svg\]\:px-3:has(>svg){padding-inline:calc(var(--spacing)*3)}.has-\[\>svg\]\:px-4:has(>svg){padding-inline:calc(var(--spacing)*4)}.has-\[\>textarea\]\:h-auto:has(>textarea){height:auto}.aria-disabled\:pointer-events-none[aria-disabled=true]{pointer-events:none}.aria-disabled\:opacity-50[aria-disabled=true]{opacity:.5}.aria-invalid\:border-destructive[aria-invalid=true]{border-color:var(--destructive)}.aria-invalid\:ring-destructive\/20[aria-invalid=true]{--tw-ring-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.aria-invalid\:ring-destructive\/20[aria-invalid=true]{--tw-ring-color:color-mix(in oklab,var(--destructive)20%,transparent)}}.aria-selected\:text-muted-foreground[aria-selected=true]{color:var(--muted-foreground)}.data-\[active\=true\]\:z-10[data-active=true]{z-index:10}.data-\[active\=true\]\:border-ring[data-active=true]{border-color:var(--ring)}.data-\[active\=true\]\:bg-accent\/50[data-active=true]{background-color:var(--accent)}@supports (color:color-mix(in lab, red, red)){.data-\[active\=true\]\:bg-accent\/50[data-active=true]{background-color:color-mix(in oklab,var(--accent)50%,transparent)}}.data-\[active\=true\]\:bg-sidebar-accent[data-active=true]{background-color:var(--sidebar-accent)}.data-\[active\=true\]\:font-medium[data-active=true]{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.data-\[active\=true\]\:text-accent-foreground[data-active=true]{color:var(--accent-foreground)}.data-\[active\=true\]\:text-sidebar-accent-foreground[data-active=true]{color:var(--sidebar-accent-foreground)}.data-\[active\=true\]\:ring-\[3px\][data-active=true]{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(3px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.data-\[active\=true\]\:ring-ring\/50[data-active=true]{--tw-ring-color:var(--ring)}@supports (color:color-mix(in lab, red, red)){.data-\[active\=true\]\:ring-ring\/50[data-active=true]{--tw-ring-color:color-mix(in oklab,var(--ring)50%,transparent)}}@media (hover:hover){.data-\[active\=true\]\:hover\:bg-accent[data-active=true]:hover{background-color:var(--accent)}}.data-\[active\=true\]\:focus\:bg-accent[data-active=true]:focus{background-color:var(--accent)}.data-\[active\=true\]\:aria-invalid\:border-destructive[data-active=true][aria-invalid=true]{border-color:var(--destructive)}.data-\[active\=true\]\:aria-invalid\:ring-destructive\/20[data-active=true][aria-invalid=true]{--tw-ring-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.data-\[active\=true\]\:aria-invalid\:ring-destructive\/20[data-active=true][aria-invalid=true]{--tw-ring-color:color-mix(in oklab,var(--destructive)20%,transparent)}}.data-\[disabled\]\:pointer-events-none[data-disabled]{pointer-events:none}.data-\[disabled\]\:opacity-50[data-disabled]{opacity:.5}.data-\[disabled\=true\]\:pointer-events-none[data-disabled=true]{pointer-events:none}.data-\[disabled\=true\]\:opacity-50[data-disabled=true]{opacity:.5}.data-\[error\=true\]\:text-destructive[data-error=true]{color:var(--destructive)}.data-\[inset\]\:pl-8[data-inset]{padding-left:calc(var(--spacing)*8)}.data-\[invalid\=true\]\:text-destructive[data-invalid=true]{color:var(--destructive)}.data-\[motion\=from-end\]\:slide-in-from-right-52[data-motion=from-end]{--tw-enter-translate-x:calc(52*var(--spacing))}.data-\[motion\=from-start\]\:slide-in-from-left-52[data-motion=from-start]{--tw-enter-translate-x:calc(52*var(--spacing)*-1)}.data-\[motion\=to-end\]\:slide-out-to-right-52[data-motion=to-end]{--tw-exit-translate-x:calc(52*var(--spacing))}.data-\[motion\=to-start\]\:slide-out-to-left-52[data-motion=to-start]{--tw-exit-translate-x:calc(52*var(--spacing)*-1)}.data-\[motion\^\=from-\]\:animate-in[data-motion^=from-]{animation:enter var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.data-\[motion\^\=from-\]\:fade-in[data-motion^=from-]{--tw-enter-opacity:0}.data-\[motion\^\=to-\]\:animate-out[data-motion^=to-]{animation:exit var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.data-\[motion\^\=to-\]\:fade-out[data-motion^=to-]{--tw-exit-opacity:0}.data-\[orientation\=horizontal\]\:h-1\.5[data-orientation=horizontal]{height:calc(var(--spacing)*1.5)}.data-\[orientation\=horizontal\]\:h-full[data-orientation=horizontal]{height:100%}.data-\[orientation\=horizontal\]\:h-px[data-orientation=horizontal]{height:1px}.data-\[orientation\=horizontal\]\:w-full[data-orientation=horizontal]{width:100%}.data-\[orientation\=vertical\]\:h-auto[data-orientation=vertical]{height:auto}.data-\[orientation\=vertical\]\:h-full[data-orientation=vertical]{height:100%}.data-\[orientation\=vertical\]\:min-h-44[data-orientation=vertical]{min-height:calc(var(--spacing)*44)}.data-\[orientation\=vertical\]\:w-1\.5[data-orientation=vertical]{width:calc(var(--spacing)*1.5)}.data-\[orientation\=vertical\]\:w-auto[data-orientation=vertical]{width:auto}.data-\[orientation\=vertical\]\:w-full[data-orientation=vertical]{width:100%}.data-\[orientation\=vertical\]\:w-px[data-orientation=vertical]{width:1px}.data-\[orientation\=vertical\]\:flex-col[data-orientation=vertical]{flex-direction:column}.data-\[panel-group-direction\=vertical\]\:h-px[data-panel-group-direction=vertical]{height:1px}.data-\[panel-group-direction\=vertical\]\:w-full[data-panel-group-direction=vertical]{width:100%}.data-\[panel-group-direction\=vertical\]\:flex-col[data-panel-group-direction=vertical]{flex-direction:column}.data-\[panel-group-direction\=vertical\]\:after\:left-0[data-panel-group-direction=vertical]:after{content:var(--tw-content);left:calc(var(--spacing)*0)}.data-\[panel-group-direction\=vertical\]\:after\:h-1[data-panel-group-direction=vertical]:after{content:var(--tw-content);height:calc(var(--spacing)*1)}.data-\[panel-group-direction\=vertical\]\:after\:w-full[data-panel-group-direction=vertical]:after{content:var(--tw-content);width:100%}.data-\[panel-group-direction\=vertical\]\:after\:translate-x-0[data-panel-group-direction=vertical]:after{content:var(--tw-content);--tw-translate-x:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[panel-group-direction\=vertical\]\:after\:-translate-y-1\/2[data-panel-group-direction=vertical]:after{content:var(--tw-content);--tw-translate-y:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[placeholder\]\:text-muted-foreground[data-placeholder]{color:var(--muted-foreground)}.data-\[range-end\=true\]\:rounded-md[data-range-end=true]{border-radius:calc(var(--radius) - 2px)}.data-\[range-end\=true\]\:rounded-r-md[data-range-end=true]{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}.data-\[range-end\=true\]\:bg-primary[data-range-end=true]{background-color:var(--primary)}.data-\[range-end\=true\]\:text-primary-foreground[data-range-end=true]{color:var(--primary-foreground)}.data-\[range-middle\=true\]\:rounded-none[data-range-middle=true]{border-radius:0}.data-\[range-middle\=true\]\:bg-accent[data-range-middle=true]{background-color:var(--accent)}.data-\[range-middle\=true\]\:text-accent-foreground[data-range-middle=true]{color:var(--accent-foreground)}.data-\[range-start\=true\]\:rounded-md[data-range-start=true]{border-radius:calc(var(--radius) - 2px)}.data-\[range-start\=true\]\:rounded-l-md[data-range-start=true]{border-top-left-radius:calc(var(--radius) - 2px);border-bottom-left-radius:calc(var(--radius) - 2px)}.data-\[range-start\=true\]\:bg-primary[data-range-start=true]{background-color:var(--primary)}.data-\[range-start\=true\]\:text-primary-foreground[data-range-start=true]{color:var(--primary-foreground)}.data-\[selected-single\=true\]\:bg-primary[data-selected-single=true]{background-color:var(--primary)}.data-\[selected-single\=true\]\:text-primary-foreground[data-selected-single=true]{color:var(--primary-foreground)}.data-\[selected\=true\]\:rounded-none[data-selected=true]{border-radius:0}.data-\[selected\=true\]\:bg-accent[data-selected=true]{background-color:var(--accent)}.data-\[selected\=true\]\:text-accent-foreground[data-selected=true]{color:var(--accent-foreground)}.data-\[side\=bottom\]\:translate-y-1[data-side=bottom]{--tw-translate-y:calc(var(--spacing)*1);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[side\=bottom\]\:slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y:calc(2*var(--spacing)*-1)}.data-\[side\=left\]\:-translate-x-1[data-side=left]{--tw-translate-x:calc(var(--spacing)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[side\=left\]\:slide-in-from-right-2[data-side=left]{--tw-enter-translate-x:calc(2*var(--spacing))}.data-\[side\=right\]\:translate-x-1[data-side=right]{--tw-translate-x:calc(var(--spacing)*1);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[side\=right\]\:slide-in-from-left-2[data-side=right]{--tw-enter-translate-x:calc(2*var(--spacing)*-1)}.data-\[side\=top\]\:-translate-y-1[data-side=top]{--tw-translate-y:calc(var(--spacing)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[side\=top\]\:slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y:calc(2*var(--spacing))}.data-\[size\=default\]\:h-9[data-size=default]{height:calc(var(--spacing)*9)}.data-\[size\=sm\]\:h-8[data-size=sm]{height:calc(var(--spacing)*8)}:is(.\*\:data-\[slot\=alert-description\]\:text-destructive\/90>*)[data-slot=alert-description]{color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){:is(.\*\:data-\[slot\=alert-description\]\:text-destructive\/90>*)[data-slot=alert-description]{color:color-mix(in oklab,var(--destructive)90%,transparent)}}.data-\[slot\=checkbox-group\]\:gap-3[data-slot=checkbox-group]{gap:calc(var(--spacing)*3)}:is(.\*\*\:data-\[slot\=command-input-wrapper\]\:h-12 *)[data-slot=command-input-wrapper]{height:calc(var(--spacing)*12)}:is(.\*\*\:data-\[slot\=navigation-menu-link\]\:focus\:ring-0 *)[data-slot=navigation-menu-link]:focus{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(0px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}:is(.\*\*\:data-\[slot\=navigation-menu-link\]\:focus\:outline-none *)[data-slot=navigation-menu-link]:focus{--tw-outline-style:none;outline-style:none}:is(.\*\:data-\[slot\=select-value\]\:line-clamp-1>*)[data-slot=select-value]{-webkit-line-clamp:1;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}:is(.\*\:data-\[slot\=select-value\]\:flex>*)[data-slot=select-value]{display:flex}:is(.\*\:data-\[slot\=select-value\]\:items-center>*)[data-slot=select-value]{align-items:center}:is(.\*\:data-\[slot\=select-value\]\:gap-2>*)[data-slot=select-value]{gap:calc(var(--spacing)*2)}.data-\[spacing\=0\]\:rounded-none[data-spacing="0"]{border-radius:0}.data-\[spacing\=0\]\:shadow-none[data-spacing="0"]{--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.data-\[spacing\=0\]\:first\:rounded-l-md[data-spacing="0"]:first-child{border-top-left-radius:calc(var(--radius) - 2px);border-bottom-left-radius:calc(var(--radius) - 2px)}.data-\[spacing\=0\]\:last\:rounded-r-md[data-spacing="0"]:last-child{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}.data-\[state\=active\]\:bg-background[data-state=active]{background-color:var(--background)}.data-\[state\=active\]\:shadow-sm[data-state=active]{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.data-\[state\=checked\]\:translate-x-\[calc\(100\%-2px\)\][data-state=checked]{--tw-translate-x:calc(100% - 2px);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[state\=checked\]\:border-primary[data-state=checked]{border-color:var(--primary)}.data-\[state\=checked\]\:bg-primary[data-state=checked]{background-color:var(--primary)}.data-\[state\=checked\]\:text-primary-foreground[data-state=checked]{color:var(--primary-foreground)}.data-\[state\=closed\]\:animate-accordion-up[data-state=closed]{animation:accordion-up var(--tw-animation-duration,var(--tw-duration,.2s))var(--tw-ease,ease-out)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.data-\[state\=closed\]\:animate-out[data-state=closed]{animation:exit var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.data-\[state\=closed\]\:duration-300[data-state=closed]{--tw-duration:.3s;transition-duration:.3s}.data-\[state\=closed\]\:fade-out-0[data-state=closed]{--tw-exit-opacity:0}.data-\[state\=closed\]\:zoom-out-95[data-state=closed]{--tw-exit-scale:.95}.data-\[state\=closed\]\:slide-out-to-bottom[data-state=closed]{--tw-exit-translate-y:100%}.data-\[state\=closed\]\:slide-out-to-left[data-state=closed]{--tw-exit-translate-x:-100%}.data-\[state\=closed\]\:slide-out-to-right[data-state=closed]{--tw-exit-translate-x:100%}.data-\[state\=closed\]\:slide-out-to-top[data-state=closed]{--tw-exit-translate-y:-100%}.group-data-\[viewport\=false\]\/navigation-menu\:data-\[state\=closed\]\:animate-out:is(:where(.group\/navigation-menu)[data-viewport=false] *)[data-state=closed]{animation:exit var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.group-data-\[viewport\=false\]\/navigation-menu\:data-\[state\=closed\]\:fade-out-0:is(:where(.group\/navigation-menu)[data-viewport=false] *)[data-state=closed]{--tw-exit-opacity:0}.group-data-\[viewport\=false\]\/navigation-menu\:data-\[state\=closed\]\:zoom-out-95:is(:where(.group\/navigation-menu)[data-viewport=false] *)[data-state=closed]{--tw-exit-scale:.95}.data-\[state\=hidden\]\:animate-out[data-state=hidden]{animation:exit var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.data-\[state\=hidden\]\:fade-out[data-state=hidden]{--tw-exit-opacity:0}.data-\[state\=on\]\:bg-accent[data-state=on]{background-color:var(--accent)}.data-\[state\=on\]\:text-accent-foreground[data-state=on]{color:var(--accent-foreground)}.data-\[state\=open\]\:animate-accordion-down[data-state=open]{animation:accordion-down var(--tw-animation-duration,var(--tw-duration,.2s))var(--tw-ease,ease-out)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.data-\[state\=open\]\:animate-in[data-state=open]{animation:enter var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.data-\[state\=open\]\:bg-accent[data-state=open],.data-\[state\=open\]\:bg-accent\/50[data-state=open]{background-color:var(--accent)}@supports (color:color-mix(in lab, red, red)){.data-\[state\=open\]\:bg-accent\/50[data-state=open]{background-color:color-mix(in oklab,var(--accent)50%,transparent)}}.data-\[state\=open\]\:bg-secondary[data-state=open]{background-color:var(--secondary)}.data-\[state\=open\]\:text-accent-foreground[data-state=open]{color:var(--accent-foreground)}.data-\[state\=open\]\:text-muted-foreground[data-state=open]{color:var(--muted-foreground)}.data-\[state\=open\]\:opacity-100[data-state=open]{opacity:1}.data-\[state\=open\]\:duration-500[data-state=open]{--tw-duration:.5s;transition-duration:.5s}.data-\[state\=open\]\:fade-in-0[data-state=open]{--tw-enter-opacity:0}.data-\[state\=open\]\:zoom-in-90[data-state=open]{--tw-enter-scale:.9}.data-\[state\=open\]\:zoom-in-95[data-state=open]{--tw-enter-scale:.95}.data-\[state\=open\]\:slide-in-from-bottom[data-state=open]{--tw-enter-translate-y:100%}.data-\[state\=open\]\:slide-in-from-left[data-state=open]{--tw-enter-translate-x:-100%}.data-\[state\=open\]\:slide-in-from-right[data-state=open]{--tw-enter-translate-x:100%}.data-\[state\=open\]\:slide-in-from-top[data-state=open]{--tw-enter-translate-y:-100%}.group-data-\[viewport\=false\]\/navigation-menu\:data-\[state\=open\]\:animate-in:is(:where(.group\/navigation-menu)[data-viewport=false] *)[data-state=open]{animation:enter var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.group-data-\[viewport\=false\]\/navigation-menu\:data-\[state\=open\]\:fade-in-0:is(:where(.group\/navigation-menu)[data-viewport=false] *)[data-state=open]{--tw-enter-opacity:0}.group-data-\[viewport\=false\]\/navigation-menu\:data-\[state\=open\]\:zoom-in-95:is(:where(.group\/navigation-menu)[data-viewport=false] *)[data-state=open]{--tw-enter-scale:.95}@media (hover:hover){.data-\[state\=open\]\:hover\:bg-accent[data-state=open]:hover{background-color:var(--accent)}.data-\[state\=open\]\:hover\:bg-sidebar-accent[data-state=open]:hover{background-color:var(--sidebar-accent)}.data-\[state\=open\]\:hover\:text-sidebar-accent-foreground[data-state=open]:hover{color:var(--sidebar-accent-foreground)}}.data-\[state\=open\]\:focus\:bg-accent[data-state=open]:focus{background-color:var(--accent)}.data-\[state\=selected\]\:bg-muted[data-state=selected]{background-color:var(--muted)}.data-\[state\=unchecked\]\:translate-x-0[data-state=unchecked]{--tw-translate-x:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[state\=unchecked\]\:bg-input[data-state=unchecked]{background-color:var(--input)}.data-\[state\=visible\]\:animate-in[data-state=visible]{animation:enter var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none)}.data-\[state\=visible\]\:fade-in[data-state=visible]{--tw-enter-opacity:0}.data-\[variant\=destructive\]\:text-destructive[data-variant=destructive]{color:var(--destructive)}.data-\[variant\=destructive\]\:focus\:bg-destructive\/10[data-variant=destructive]:focus{background-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.data-\[variant\=destructive\]\:focus\:bg-destructive\/10[data-variant=destructive]:focus{background-color:color-mix(in oklab,var(--destructive)10%,transparent)}}.data-\[variant\=destructive\]\:focus\:text-destructive[data-variant=destructive]:focus{color:var(--destructive)}.data-\[variant\=label\]\:text-sm[data-variant=label]{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.data-\[variant\=legend\]\:text-base[data-variant=legend]{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.data-\[spacing\=0\]\:data-\[variant\=outline\]\:border-l-0[data-spacing="0"][data-variant=outline]{border-left-style:var(--tw-border-style);border-left-width:0}.data-\[spacing\=0\]\:data-\[variant\=outline\]\:first\:border-l[data-spacing="0"][data-variant=outline]:first-child{border-left-style:var(--tw-border-style);border-left-width:1px}.data-\[spacing\=default\]\:data-\[variant\=outline\]\:shadow-xs[data-spacing=default][data-variant=outline]{--tw-shadow:0 1px 2px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.data-\[vaul-drawer-direction\=bottom\]\:inset-x-0[data-vaul-drawer-direction=bottom]{inset-inline:calc(var(--spacing)*0)}.data-\[vaul-drawer-direction\=bottom\]\:bottom-0[data-vaul-drawer-direction=bottom]{bottom:calc(var(--spacing)*0)}.data-\[vaul-drawer-direction\=bottom\]\:mt-24[data-vaul-drawer-direction=bottom]{margin-top:calc(var(--spacing)*24)}.data-\[vaul-drawer-direction\=bottom\]\:max-h-\[80vh\][data-vaul-drawer-direction=bottom]{max-height:80vh}.data-\[vaul-drawer-direction\=bottom\]\:rounded-t-lg[data-vaul-drawer-direction=bottom]{border-top-left-radius:var(--radius);border-top-right-radius:var(--radius)}.data-\[vaul-drawer-direction\=bottom\]\:border-t[data-vaul-drawer-direction=bottom]{border-top-style:var(--tw-border-style);border-top-width:1px}.data-\[vaul-drawer-direction\=left\]\:inset-y-0[data-vaul-drawer-direction=left]{inset-block:calc(var(--spacing)*0)}.data-\[vaul-drawer-direction\=left\]\:left-0[data-vaul-drawer-direction=left]{left:calc(var(--spacing)*0)}.data-\[vaul-drawer-direction\=left\]\:w-3\/4[data-vaul-drawer-direction=left]{width:75%}.data-\[vaul-drawer-direction\=left\]\:border-r[data-vaul-drawer-direction=left]{border-right-style:var(--tw-border-style);border-right-width:1px}.data-\[vaul-drawer-direction\=right\]\:inset-y-0[data-vaul-drawer-direction=right]{inset-block:calc(var(--spacing)*0)}.data-\[vaul-drawer-direction\=right\]\:right-0[data-vaul-drawer-direction=right]{right:calc(var(--spacing)*0)}.data-\[vaul-drawer-direction\=right\]\:w-3\/4[data-vaul-drawer-direction=right]{width:75%}.data-\[vaul-drawer-direction\=right\]\:border-l[data-vaul-drawer-direction=right]{border-left-style:var(--tw-border-style);border-left-width:1px}.data-\[vaul-drawer-direction\=top\]\:inset-x-0[data-vaul-drawer-direction=top]{inset-inline:calc(var(--spacing)*0)}.data-\[vaul-drawer-direction\=top\]\:top-0[data-vaul-drawer-direction=top]{top:calc(var(--spacing)*0)}.data-\[vaul-drawer-direction\=top\]\:mb-24[data-vaul-drawer-direction=top]{margin-bottom:calc(var(--spacing)*24)}.data-\[vaul-drawer-direction\=top\]\:max-h-\[80vh\][data-vaul-drawer-direction=top]{max-height:80vh}.data-\[vaul-drawer-direction\=top\]\:rounded-b-lg[data-vaul-drawer-direction=top]{border-bottom-right-radius:var(--radius);border-bottom-left-radius:var(--radius)}.data-\[vaul-drawer-direction\=top\]\:border-b[data-vaul-drawer-direction=top]{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.nth-last-2\:-mt-1:nth-last-child(2){margin-top:calc(var(--spacing)*-1)}@media (min-width:40rem){.sm\:block{display:block}.sm\:flex{display:flex}.sm\:inline{display:inline}.sm\:max-w-2xl{max-width:var(--container-2xl)}.sm\:max-w-3xl{max-width:var(--container-3xl)}.sm\:max-w-lg{max-width:var(--container-lg)}.sm\:max-w-md{max-width:var(--container-md)}.sm\:max-w-sm{max-width:var(--container-sm)}.sm\:max-w-xl{max-width:var(--container-xl)}.sm\:flex-row{flex-direction:row}.sm\:justify-end{justify-content:flex-end}.sm\:gap-2\.5{gap:calc(var(--spacing)*2.5)}.sm\:pr-2\.5{padding-right:calc(var(--spacing)*2.5)}.sm\:pl-2\.5{padding-left:calc(var(--spacing)*2.5)}.sm\:text-left{text-align:left}.sm\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.data-\[vaul-drawer-direction\=left\]\:sm\:max-w-sm[data-vaul-drawer-direction=left],.data-\[vaul-drawer-direction\=right\]\:sm\:max-w-sm[data-vaul-drawer-direction=right]{max-width:var(--container-sm)}}@media (min-width:48rem){.md\:absolute{position:absolute}.md\:col-span-1{grid-column:span 1/span 1}.md\:col-span-2{grid-column:span 2/span 2}.md\:col-span-4{grid-column:span 4/span 4}.md\:col-span-5{grid-column:span 5/span 5}.md\:col-span-6{grid-column:span 6/span 6}.md\:col-span-7{grid-column:span 7/span 7}.md\:block{display:block}.md\:flex{display:flex}.md\:w-\[var\(--radix-navigation-menu-viewport-width\)\]{width:var(--radix-navigation-menu-viewport-width)}.md\:w-auto{width:auto}.md\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.md\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.md\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.md\:grid-cols-12{grid-template-columns:repeat(12,minmax(0,1fr))}.md\:flex-row{flex-direction:row}.md\:items-center{align-items:center}.md\:items-end{align-items:flex-end}.md\:justify-between{justify-content:space-between}.md\:gap-1\.5{gap:calc(var(--spacing)*1.5)}.md\:p-12{padding:calc(var(--spacing)*12)}.md\:text-left{text-align:left}.md\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.md\:text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.md\:opacity-0{opacity:0}.md\:peer-data-\[variant\=inset\]\:m-2:is(:where(.peer)[data-variant=inset]~*){margin:calc(var(--spacing)*2)}.md\:peer-data-\[variant\=inset\]\:ml-0:is(:where(.peer)[data-variant=inset]~*){margin-left:calc(var(--spacing)*0)}.md\:peer-data-\[variant\=inset\]\:rounded-xl:is(:where(.peer)[data-variant=inset]~*){border-radius:calc(var(--radius) + 4px)}.md\:peer-data-\[variant\=inset\]\:shadow-sm:is(:where(.peer)[data-variant=inset]~*){--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.md\:peer-data-\[variant\=inset\]\:peer-data-\[state\=collapsed\]\:ml-2:is(:where(.peer)[data-variant=inset]~*):is(:where(.peer)[data-state=collapsed]~*){margin-left:calc(var(--spacing)*2)}.md\:after\:hidden:after{content:var(--tw-content);display:none}}@media (min-width:64rem){.lg\:max-w-250{max-width:calc(var(--spacing)*250)}.lg\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}}@container field-group (width>=28rem){.\@md\/field-group\:flex-row{flex-direction:row}.\@md\/field-group\:items-center{align-items:center}.\@md\/field-group\:has-\[\>\[data-slot\=field-content\]\]\:items-start:has(>[data-slot=field-content]){align-items:flex-start}}.dark\:border-input:is(.dark *){border-color:var(--input)}.dark\:bg-amber-900:is(.dark *){background-color:var(--color-amber-900)}.dark\:bg-destructive\/60:is(.dark *){background-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.dark\:bg-destructive\/60:is(.dark *){background-color:color-mix(in oklab,var(--destructive)60%,transparent)}}.dark\:bg-input\/30:is(.dark *){background-color:var(--input)}@supports (color:color-mix(in lab, red, red)){.dark\:bg-input\/30:is(.dark *){background-color:color-mix(in oklab,var(--input)30%,transparent)}}.dark\:bg-transparent:is(.dark *){background-color:#0000}.dark\:text-muted-foreground:is(.dark *){color:var(--muted-foreground)}@media (hover:hover){.dark\:hover\:bg-accent\/50:is(.dark *):hover{background-color:var(--accent)}@supports (color:color-mix(in lab, red, red)){.dark\:hover\:bg-accent\/50:is(.dark *):hover{background-color:color-mix(in oklab,var(--accent)50%,transparent)}}.dark\:hover\:bg-input\/50:is(.dark *):hover{background-color:var(--input)}@supports (color:color-mix(in lab, red, red)){.dark\:hover\:bg-input\/50:is(.dark *):hover{background-color:color-mix(in oklab,var(--input)50%,transparent)}}.dark\:hover\:text-accent-foreground:is(.dark *):hover{color:var(--accent-foreground)}}.dark\:focus-visible\:ring-destructive\/40:is(.dark *):focus-visible{--tw-ring-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.dark\:focus-visible\:ring-destructive\/40:is(.dark *):focus-visible{--tw-ring-color:color-mix(in oklab,var(--destructive)40%,transparent)}}.dark\:has-data-\[state\=checked\]\:bg-primary\/10:is(.dark *):has([data-state=checked]){background-color:var(--primary)}@supports (color:color-mix(in lab, red, red)){.dark\:has-data-\[state\=checked\]\:bg-primary\/10:is(.dark *):has([data-state=checked]){background-color:color-mix(in oklab,var(--primary)10%,transparent)}}.dark\:has-\[\[data-slot\]\[aria-invalid\=true\]\]\:ring-destructive\/40:is(.dark *):has([data-slot][aria-invalid=true]){--tw-ring-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.dark\:has-\[\[data-slot\]\[aria-invalid\=true\]\]\:ring-destructive\/40:is(.dark *):has([data-slot][aria-invalid=true]){--tw-ring-color:color-mix(in oklab,var(--destructive)40%,transparent)}}.dark\:aria-invalid\:ring-destructive\/40:is(.dark *)[aria-invalid=true]{--tw-ring-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.dark\:aria-invalid\:ring-destructive\/40:is(.dark *)[aria-invalid=true]{--tw-ring-color:color-mix(in oklab,var(--destructive)40%,transparent)}}.dark\:data-\[active\=true\]\:aria-invalid\:ring-destructive\/40:is(.dark *)[data-active=true][aria-invalid=true]{--tw-ring-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.dark\:data-\[active\=true\]\:aria-invalid\:ring-destructive\/40:is(.dark *)[data-active=true][aria-invalid=true]{--tw-ring-color:color-mix(in oklab,var(--destructive)40%,transparent)}}.dark\:data-\[state\=active\]\:border-input:is(.dark *)[data-state=active]{border-color:var(--input)}.dark\:data-\[state\=active\]\:bg-input\/30:is(.dark *)[data-state=active]{background-color:var(--input)}@supports (color:color-mix(in lab, red, red)){.dark\:data-\[state\=active\]\:bg-input\/30:is(.dark *)[data-state=active]{background-color:color-mix(in oklab,var(--input)30%,transparent)}}.dark\:data-\[state\=active\]\:text-foreground:is(.dark *)[data-state=active]{color:var(--foreground)}.dark\:data-\[state\=checked\]\:bg-primary:is(.dark *)[data-state=checked]{background-color:var(--primary)}.dark\:data-\[state\=checked\]\:bg-primary-foreground:is(.dark *)[data-state=checked]{background-color:var(--primary-foreground)}.dark\:data-\[state\=unchecked\]\:bg-foreground:is(.dark *)[data-state=unchecked]{background-color:var(--foreground)}.dark\:data-\[state\=unchecked\]\:bg-input\/80:is(.dark *)[data-state=unchecked]{background-color:var(--input)}@supports (color:color-mix(in lab, red, red)){.dark\:data-\[state\=unchecked\]\:bg-input\/80:is(.dark *)[data-state=unchecked]{background-color:color-mix(in oklab,var(--input)80%,transparent)}}.dark\:data-\[variant\=destructive\]\:focus\:bg-destructive\/20:is(.dark *)[data-variant=destructive]:focus{background-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){.dark\:data-\[variant\=destructive\]\:focus\:bg-destructive\/20:is(.dark *)[data-variant=destructive]:focus{background-color:color-mix(in oklab,var(--destructive)20%,transparent)}}.\[\&_\.recharts-cartesian-axis-tick_text\]\:fill-muted-foreground .recharts-cartesian-axis-tick text{fill:var(--muted-foreground)}.\[\&_\.recharts-cartesian-grid_line\[stroke\=\'\#ccc\'\]\]\:stroke-border\/50 .recharts-cartesian-grid line[stroke=\#ccc]{stroke:var(--border)}@supports (color:color-mix(in lab, red, red)){.\[\&_\.recharts-cartesian-grid_line\[stroke\=\'\#ccc\'\]\]\:stroke-border\/50 .recharts-cartesian-grid line[stroke=\#ccc]{stroke:color-mix(in oklab,var(--border)50%,transparent)}}.\[\&_\.recharts-curve\.recharts-tooltip-cursor\]\:stroke-border .recharts-curve.recharts-tooltip-cursor{stroke:var(--border)}.\[\&_\.recharts-dot\[stroke\=\'\#fff\'\]\]\:stroke-transparent .recharts-dot[stroke=\#fff]{stroke:#0000}.\[\&_\.recharts-layer\]\:outline-hidden .recharts-layer{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.\[\&_\.recharts-layer\]\:outline-hidden .recharts-layer{outline-offset:2px;outline:2px solid #0000}}.\[\&_\.recharts-polar-grid_\[stroke\=\'\#ccc\'\]\]\:stroke-border .recharts-polar-grid [stroke=\#ccc]{stroke:var(--border)}.\[\&_\.recharts-radial-bar-background-sector\]\:fill-muted .recharts-radial-bar-background-sector,.\[\&_\.recharts-rectangle\.recharts-tooltip-cursor\]\:fill-muted .recharts-rectangle.recharts-tooltip-cursor{fill:var(--muted)}.\[\&_\.recharts-reference-line_\[stroke\=\'\#ccc\'\]\]\:stroke-border .recharts-reference-line [stroke=\#ccc]{stroke:var(--border)}.\[\&_\.recharts-sector\]\:outline-hidden .recharts-sector{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.\[\&_\.recharts-sector\]\:outline-hidden .recharts-sector{outline-offset:2px;outline:2px solid #0000}}.\[\&_\.recharts-sector\[stroke\=\'\#fff\'\]\]\:stroke-transparent .recharts-sector[stroke=\#fff]{stroke:#0000}.\[\&_\.recharts-surface\]\:outline-hidden .recharts-surface{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.\[\&_\.recharts-surface\]\:outline-hidden .recharts-surface{outline-offset:2px;outline:2px solid #0000}}.\[\&_\[cmdk-group-heading\]\]\:px-2 [cmdk-group-heading]{padding-inline:calc(var(--spacing)*2)}.\[\&_\[cmdk-group-heading\]\]\:py-1\.5 [cmdk-group-heading]{padding-block:calc(var(--spacing)*1.5)}.\[\&_\[cmdk-group-heading\]\]\:text-xs [cmdk-group-heading]{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.\[\&_\[cmdk-group-heading\]\]\:font-medium [cmdk-group-heading]{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.\[\&_\[cmdk-group-heading\]\]\:text-muted-foreground [cmdk-group-heading]{color:var(--muted-foreground)}.\[\&_\[cmdk-group\]\]\:px-2 [cmdk-group]{padding-inline:calc(var(--spacing)*2)}.\[\&_\[cmdk-group\]\:not\(\[hidden\]\)_\~\[cmdk-group\]\]\:pt-0 [cmdk-group]:not([hidden])~[cmdk-group]{padding-top:calc(var(--spacing)*0)}.\[\&_\[cmdk-input-wrapper\]_svg\]\:h-5 [cmdk-input-wrapper] svg{height:calc(var(--spacing)*5)}.\[\&_\[cmdk-input-wrapper\]_svg\]\:w-5 [cmdk-input-wrapper] svg{width:calc(var(--spacing)*5)}.\[\&_\[cmdk-input\]\]\:h-12 [cmdk-input]{height:calc(var(--spacing)*12)}.\[\&_\[cmdk-item\]\]\:px-2 [cmdk-item]{padding-inline:calc(var(--spacing)*2)}.\[\&_\[cmdk-item\]\]\:py-3 [cmdk-item]{padding-block:calc(var(--spacing)*3)}.\[\&_\[cmdk-item\]_svg\]\:h-5 [cmdk-item] svg{height:calc(var(--spacing)*5)}.\[\&_\[cmdk-item\]_svg\]\:w-5 [cmdk-item] svg{width:calc(var(--spacing)*5)}.\[\&_img\]\:size-full img{width:100%;height:100%}.\[\&_img\]\:object-cover img{object-fit:cover}.\[\&_p\]\:leading-relaxed p{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}.\[\&_svg\]\:pointer-events-none svg{pointer-events:none}.\[\&_svg\]\:shrink-0 svg{flex-shrink:0}.\[\&_svg\:not\(\[class\*\=\'size-\'\]\)\]\:size-3 svg:not([class*=size-]){width:calc(var(--spacing)*3);height:calc(var(--spacing)*3)}.\[\&_svg\:not\(\[class\*\=\'size-\'\]\)\]\:size-4 svg:not([class*=size-]){width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.\[\&_svg\:not\(\[class\*\=\'size-\'\]\)\]\:size-6 svg:not([class*=size-]){width:calc(var(--spacing)*6);height:calc(var(--spacing)*6)}.\[\&_svg\:not\(\[class\*\=\'text-\'\]\)\]\:text-muted-foreground svg:not([class*=text-]){color:var(--muted-foreground)}.\[\&_tr\]\:border-b tr{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.\[\&_tr\:last-child\]\:border-0 tr:last-child{border-style:var(--tw-border-style);border-width:0}.\[\&\+\[data-slot\=item-content\]\]\:flex-none+[data-slot=item-content]{flex:none}.\[\&\:first-child\[data-selected\=true\]_button\]\:rounded-l-md:first-child[data-selected=true] button{border-top-left-radius:calc(var(--radius) - 2px);border-bottom-left-radius:calc(var(--radius) - 2px)}.\[\&\:has\(\[role\=checkbox\]\)\]\:pr-0:has([role=checkbox]){padding-right:calc(var(--spacing)*0)}.\[\.border-b\]\:pb-3.border-b{padding-bottom:calc(var(--spacing)*3)}.\[\.border-b\]\:pb-6.border-b{padding-bottom:calc(var(--spacing)*6)}.\[\.border-t\]\:pt-3.border-t{padding-top:calc(var(--spacing)*3)}.\[\.border-t\]\:pt-6.border-t{padding-top:calc(var(--spacing)*6)}:is(.rtl\:\*\*\:\[\.rdp-button\\_next\>svg\]\:rotate-180:where(:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)),[dir=rtl],[dir=rtl] *) *):is(.rdp-button_next>svg),:is(.rtl\:\*\*\:\[\.rdp-button\\_previous\>svg\]\:rotate-180:where(:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)),[dir=rtl],[dir=rtl] *) *):is(.rdp-button_previous>svg){rotate:180deg}.\[a\]\:transition-colors:is(a){transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}@media (hover:hover){.\[a\]\:hover\:bg-accent\/50:is(a):hover{background-color:var(--accent)}@supports (color:color-mix(in lab, red, red)){.\[a\]\:hover\:bg-accent\/50:is(a):hover{background-color:color-mix(in oklab,var(--accent)50%,transparent)}}}:is(.\*\:\[span\]\:last\:flex>*):is(span):last-child{display:flex}:is(.\*\:\[span\]\:last\:items-center>*):is(span):last-child{align-items:center}:is(.\*\:\[span\]\:last\:gap-2>*):is(span):last-child{gap:calc(var(--spacing)*2)}:is(.data-\[variant\=destructive\]\:\*\:\[svg\]\:\!text-destructive[data-variant=destructive]>*):is(svg){color:var(--destructive)!important}.\[\&\:last-child\[data-selected\=true\]_button\]\:rounded-r-md:last-child[data-selected=true] button{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}.\[\&\:nth-child\(2\)\[data-selected\=true\]_button\]\:rounded-l-md:nth-child(2)[data-selected=true] button{border-top-left-radius:calc(var(--radius) - 2px);border-bottom-left-radius:calc(var(--radius) - 2px)}.\[\&\>\*\]\:w-full>*{width:100%}.\[\&\>\*\]\:focus-visible\:relative>:focus-visible{position:relative}.\[\&\>\*\]\:focus-visible\:z-10>:focus-visible{z-index:10}.\[\&\>\*\]\:data-\[slot\=field\]\:p-4>[data-slot=field]{padding:calc(var(--spacing)*4)}@container field-group (width>=28rem){.\@md\/field-group\:\[\&\>\*\]\:w-auto>*{width:auto}}.\[\&\>\*\:not\(\:first-child\)\]\:rounded-t-none>:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}.\[\&\>\*\:not\(\:first-child\)\]\:rounded-l-none>:not(:first-child){border-top-left-radius:0;border-bottom-left-radius:0}.\[\&\>\*\:not\(\:first-child\)\]\:border-t-0>:not(:first-child){border-top-style:var(--tw-border-style);border-top-width:0}.\[\&\>\*\:not\(\:first-child\)\]\:border-l-0>:not(:first-child){border-left-style:var(--tw-border-style);border-left-width:0}.\[\&\>\*\:not\(\:last-child\)\]\:rounded-r-none>:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.\[\&\>\*\:not\(\:last-child\)\]\:rounded-b-none>:not(:last-child){border-bottom-right-radius:0;border-bottom-left-radius:0}.\[\&\>\.sr-only\]\:w-auto>.sr-only{width:auto}.\[\&\>\[data-slot\=field-group\]\]\:gap-4>[data-slot=field-group]{gap:calc(var(--spacing)*4)}.\[\&\>\[data-slot\=field-label\]\]\:flex-auto>[data-slot=field-label]{flex:auto}@container field-group (width>=28rem){.\@md\/field-group\:\[\&\>\[data-slot\=field-label\]\]\:flex-auto>[data-slot=field-label]{flex:auto}}.has-\[select\[aria-hidden\=true\]\:last-child\]\:\[\&\>\[data-slot\=select-trigger\]\:last-of-type\]\:rounded-r-md:has(:is(select[aria-hidden=true]:last-child))>[data-slot=select-trigger]:last-of-type{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}.\[\&\>\[data-slot\=select-trigger\]\:not\(\[class\*\=\'w-\'\]\)\]\:w-fit>[data-slot=select-trigger]:not([class*=w-]){width:fit-content}.\[\&\>\[role\=checkbox\]\]\:translate-y-\[2px\]>[role=checkbox]{--tw-translate-y:2px;translate:var(--tw-translate-x)var(--tw-translate-y)}:is(.has-\[\>\[data-slot\=field-content\]\]\:\[\&\>\[role\=checkbox\]\,\[role\=radio\]\]\:mt-px:has(>[data-slot=field-content])>[role=checkbox],.has-\[\>\[data-slot\=field-content\]\]\:\[\&\>\[role\=checkbox\]\,\[role\=radio\]\]\:mt-px:has(>[data-slot=field-content]) [role=radio]){margin-top:1px}@container field-group (width>=28rem){:is(.\@md\/field-group\:has-\[\>\[data-slot\=field-content\]\]\:\[\&\>\[role\=checkbox\]\,\[role\=radio\]\]\:mt-px:has(>[data-slot=field-content])>[role=checkbox],.\@md\/field-group\:has-\[\>\[data-slot\=field-content\]\]\:\[\&\>\[role\=checkbox\]\,\[role\=radio\]\]\:mt-px:has(>[data-slot=field-content]) [role=radio]){margin-top:1px}}.\[\&\>a\]\:underline>a{text-decoration-line:underline}.\[\&\>a\]\:underline-offset-4>a{text-underline-offset:4px}.\[\&\>a\:hover\]\:text-primary>a:hover{color:var(--primary)}.\[\&\>button\]\:hidden>button{display:none}.\[\&\>input\]\:flex-1>input{flex:1}.has-\[\>\[data-align\=block-end\]\]\:\[\&\>input\]\:pt-3:has(>[data-align=block-end])>input{padding-top:calc(var(--spacing)*3)}.has-\[\>\[data-align\=block-start\]\]\:\[\&\>input\]\:pb-3:has(>[data-align=block-start])>input{padding-bottom:calc(var(--spacing)*3)}.has-\[\>\[data-align\=inline-end\]\]\:\[\&\>input\]\:pr-2:has(>[data-align=inline-end])>input{padding-right:calc(var(--spacing)*2)}.has-\[\>\[data-align\=inline-start\]\]\:\[\&\>input\]\:pl-2:has(>[data-align=inline-start])>input{padding-left:calc(var(--spacing)*2)}.\[\&\>kbd\]\:rounded-\[calc\(var\(--radius\)-5px\)\]>kbd{border-radius:calc(var(--radius) - 5px)}.\[\&\>span\]\:text-xs>span{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.\[\&\>span\]\:opacity-70>span{opacity:.7}.\[\&\>span\:last-child\]\:truncate>span:last-child{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.\[\&\>svg\]\:pointer-events-none>svg{pointer-events:none}.\[\&\>svg\]\:size-3>svg{width:calc(var(--spacing)*3);height:calc(var(--spacing)*3)}.\[\&\>svg\]\:size-3\.5>svg{width:calc(var(--spacing)*3.5);height:calc(var(--spacing)*3.5)}.\[\&\>svg\]\:size-4>svg{width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.\[\&\>svg\]\:h-2\.5>svg{height:calc(var(--spacing)*2.5)}.\[\&\>svg\]\:h-3>svg{height:calc(var(--spacing)*3)}.\[\&\>svg\]\:w-2\.5>svg{width:calc(var(--spacing)*2.5)}.\[\&\>svg\]\:w-3>svg{width:calc(var(--spacing)*3)}.\[\&\>svg\]\:shrink-0>svg{flex-shrink:0}.\[\&\>svg\]\:translate-y-0\.5>svg{--tw-translate-y:calc(var(--spacing)*.5);translate:var(--tw-translate-x)var(--tw-translate-y)}.\[\&\>svg\]\:text-current>svg{color:currentColor}.\[\&\>svg\]\:text-muted-foreground>svg{color:var(--muted-foreground)}.\[\&\>svg\]\:text-sidebar-accent-foreground>svg{color:var(--sidebar-accent-foreground)}.\[\&\>svg\:not\(\[class\*\=\'size-\'\]\)\]\:size-3\.5>svg:not([class*=size-]){width:calc(var(--spacing)*3.5);height:calc(var(--spacing)*3.5)}.\[\&\>svg\:not\(\[class\*\=\'size-\'\]\)\]\:size-4>svg:not([class*=size-]){width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.\[\&\>tr\]\:last\:border-b-0>tr:last-child{border-bottom-style:var(--tw-border-style);border-bottom-width:0}.\[\&\[data-panel-group-direction\=vertical\]\>div\]\:rotate-90[data-panel-group-direction=vertical]>div{rotate:90deg}.\[\&\[data-state\=open\]\>svg\]\:rotate-180[data-state=open]>svg{rotate:180deg}[data-side=left][data-collapsible=offcanvas] .\[\[data-side\=left\]\[data-collapsible\=offcanvas\]_\&\]\:-right-2{right:calc(var(--spacing)*-2)}[data-side=left][data-state=collapsed] .\[\[data-side\=left\]\[data-state\=collapsed\]_\&\]\:cursor-e-resize{cursor:e-resize}[data-side=right][data-collapsible=offcanvas] .\[\[data-side\=right\]\[data-collapsible\=offcanvas\]_\&\]\:-left-2{left:calc(var(--spacing)*-2)}[data-side=right][data-state=collapsed] .\[\[data-side\=right\]\[data-state\=collapsed\]_\&\]\:cursor-w-resize{cursor:w-resize}[data-slot=card-content] .\[\[data-slot\=card-content\]_\&\]\:bg-transparent,[data-slot=popover-content] .\[\[data-slot\=popover-content\]_\&\]\:bg-transparent{background-color:#0000}[data-slot=tooltip-content] .\[\[data-slot\=tooltip-content\]_\&\]\:bg-background\/20{background-color:var(--background)}@supports (color:color-mix(in lab, red, red)){[data-slot=tooltip-content] .\[\[data-slot\=tooltip-content\]_\&\]\:bg-background\/20{background-color:color-mix(in oklab,var(--background)20%,transparent)}}[data-slot=tooltip-content] .\[\[data-slot\=tooltip-content\]_\&\]\:text-background{color:var(--background)}[data-slot=tooltip-content] .dark\:\[\[data-slot\=tooltip-content\]_\&\]\:bg-background\/10:is(.dark *){background-color:var(--background)}@supports (color:color-mix(in lab, red, red)){[data-slot=tooltip-content] .dark\:\[\[data-slot\=tooltip-content\]_\&\]\:bg-background\/10:is(.dark *){background-color:color-mix(in oklab,var(--background)10%,transparent)}}[data-variant=legend]+.\[\[data-variant\=legend\]\+\&\]\:-mt-1\.5{margin-top:calc(var(--spacing)*-1.5)}@media (hover:hover){a.\[a\&\]\:hover\:bg-accent:hover{background-color:var(--accent)}a.\[a\&\]\:hover\:bg-destructive\/90:hover{background-color:var(--destructive)}@supports (color:color-mix(in lab, red, red)){a.\[a\&\]\:hover\:bg-destructive\/90:hover{background-color:color-mix(in oklab,var(--destructive)90%,transparent)}}a.\[a\&\]\:hover\:bg-primary\/90:hover{background-color:var(--primary)}@supports (color:color-mix(in lab, red, red)){a.\[a\&\]\:hover\:bg-primary\/90:hover{background-color:color-mix(in oklab,var(--primary)90%,transparent)}}a.\[a\&\]\:hover\:bg-secondary\/90:hover{background-color:var(--secondary)}@supports (color:color-mix(in lab, red, red)){a.\[a\&\]\:hover\:bg-secondary\/90:hover{background-color:color-mix(in oklab,var(--secondary)90%,transparent)}}a.\[a\&\]\:hover\:text-accent-foreground:hover{color:var(--accent-foreground)}}}@property --tw-animation-delay{syntax:"*";inherits:false;initial-value:0s}@property --tw-animation-direction{syntax:"*";inherits:false;initial-value:normal}@property --tw-animation-duration{syntax:"*";inherits:false}@property --tw-animation-fill-mode{syntax:"*";inherits:false;initial-value:none}@property --tw-animation-iteration-count{syntax:"*";inherits:false;initial-value:1}@property --tw-enter-blur{syntax:"*";inherits:false;initial-value:0}@property --tw-enter-opacity{syntax:"*";inherits:false;initial-value:1}@property --tw-enter-rotate{syntax:"*";inherits:false;initial-value:0}@property --tw-enter-scale{syntax:"*";inherits:false;initial-value:1}@property --tw-enter-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-enter-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-exit-blur{syntax:"*";inherits:false;initial-value:0}@property --tw-exit-opacity{syntax:"*";inherits:false;initial-value:1}@property --tw-exit-rotate{syntax:"*";inherits:false;initial-value:0}@property --tw-exit-scale{syntax:"*";inherits:false;initial-value:1}@property --tw-exit-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-exit-translate-y{syntax:"*";inherits:false;initial-value:0}:root{--radius:.625rem;--background:#fff;--foreground:#09090b;--card:#fff;--card-foreground:#09090b;--popover:#fff;--popover-foreground:#09090b;--primary:#18181b;--primary-foreground:#fafafa;--secondary:#f4f4f5;--secondary-foreground:#18181b;--muted:#f4f4f5;--muted-foreground:#71717b;--accent:#f4f4f5;--accent-foreground:#18181b;--destructive:#e40014;--border:#e4e4e7;--input:#e4e4e7;--ring:#9f9fa9;--chart-1:#f05100;--chart-2:#009588;--chart-3:#104e64;--chart-4:#fcbb00;--chart-5:#f99c00;--sidebar:#fafafa;--sidebar-foreground:#09090b;--sidebar-primary:#18181b;--sidebar-primary-foreground:#fafafa;--sidebar-accent:#f4f4f5;--sidebar-accent-foreground:#18181b;--sidebar-border:#e4e4e7;--sidebar-ring:#9f9fa9}@supports (color:lab(0% 0 0)){:root{--background:lab(100% 0 0);--foreground:lab(2.51107% .242703 -.886115);--card:lab(100% 0 0);--card-foreground:lab(2.51107% .242703 -.886115);--popover:lab(100% 0 0);--popover-foreground:lab(2.51107% .242703 -.886115);--primary:lab(8.30603% .618205 -2.16572);--primary-foreground:lab(98.26% 0 0);--secondary:lab(96.1634% .0993311 -.364041);--secondary-foreground:lab(8.30603% .618205 -2.16572);--muted:lab(96.1634% .0993311 -.364041);--muted-foreground:lab(47.8878% 1.65477 -5.77283);--accent:lab(96.1634% .0993311 -.364041);--accent-foreground:lab(8.30603% .618205 -2.16572);--destructive:lab(48.4493% 77.4328 61.5452);--border:lab(90.6853% .399232 -1.45452);--input:lab(90.6853% .399232 -1.45452);--ring:lab(65.6464% 1.53497 -5.42429);--chart-1:lab(57.1026% 64.2584 89.8886);--chart-2:lab(55.0223% -41.0774 -3.90277);--chart-3:lab(30.372% -13.1853 -18.7887);--chart-4:lab(80.1641% 16.6016 99.2089);--chart-5:lab(72.7183% 31.8672 97.9407);--sidebar:lab(98.26% 0 0);--sidebar-foreground:lab(2.51107% .242703 -.886115);--sidebar-primary:lab(8.30603% .618205 -2.16572);--sidebar-primary-foreground:lab(98.26% 0 0);--sidebar-accent:lab(96.1634% .0993311 -.364041);--sidebar-accent-foreground:lab(8.30603% .618205 -2.16572);--sidebar-border:lab(90.6853% .399232 -1.45452);--sidebar-ring:lab(65.6464% 1.53497 -5.42429)}}.dark{--background:#09090b;--foreground:#fafafa;--card:#18181b;--card-foreground:#fafafa;--popover:#18181b;--popover-foreground:#fafafa;--primary:#e4e4e7;--primary-foreground:#18181b;--secondary:#27272a;--secondary-foreground:#fafafa;--muted:#27272a;--muted-foreground:#9f9fa9;--accent:#27272a;--accent-foreground:#fafafa;--destructive:#ff6568;--border:#ffffff1a;--input:#ffffff26;--ring:#71717b;--chart-1:#1447e6;--chart-2:#00bb7f;--chart-3:#f99c00;--chart-4:#ac4bff;--chart-5:#ff2357;--sidebar:#18181b;--sidebar-foreground:#fafafa;--sidebar-primary:#1447e6;--sidebar-primary-foreground:#fafafa;--sidebar-accent:#27272a;--sidebar-accent-foreground:#fafafa;--sidebar-border:#ffffff1a;--sidebar-ring:#71717b}@supports (color:lab(0% 0 0)){.dark{--background:lab(2.51107% .242703 -.886115);--foreground:lab(98.26% 0 0);--card:lab(8.30603% .618205 -2.16572);--card-foreground:lab(98.26% 0 0);--popover:lab(8.30603% .618205 -2.16572);--popover-foreground:lab(98.26% 0 0);--primary:lab(90.6853% .399232 -1.45452);--primary-foreground:lab(8.30603% .618205 -2.16572);--secondary:lab(15.7305% .613764 -2.16959);--secondary-foreground:lab(98.26% 0 0);--muted:lab(15.7305% .613764 -2.16959);--muted-foreground:lab(65.6464% 1.53497 -5.42429);--accent:lab(15.7305% .613764 -2.16959);--accent-foreground:lab(98.26% 0 0);--destructive:lab(63.7053% 60.745 31.3109);--border:lab(100% 0 0/.1);--input:lab(100% 0 0/.15);--ring:lab(47.8878% 1.65477 -5.77283);--chart-1:lab(36.9089% 35.0961 -85.6872);--chart-2:lab(66.9756% -58.27 19.5419);--chart-3:lab(72.7183% 31.8672 97.9407);--chart-4:lab(52.0183% 66.11 -78.2316);--chart-5:lab(56.101% 79.4328 31.4532);--sidebar:lab(8.30603% .618205 -2.16572);--sidebar-foreground:lab(98.26% 0 0);--sidebar-primary:lab(36.9089% 35.0961 -85.6872);--sidebar-primary-foreground:lab(98.26% 0 0);--sidebar-accent:lab(15.7305% .613764 -2.16959);--sidebar-accent-foreground:lab(98.26% 0 0);--sidebar-border:lab(100% 0 0/.1);--sidebar-ring:lab(47.8878% 1.65477 -5.77283)}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-space-x-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@property --tw-content{syntax:"*";inherits:false;initial-value:""}@keyframes spin{to{transform:rotate(360deg)}}@keyframes pulse{50%{opacity:.5}}@keyframes enter{0%{opacity:var(--tw-enter-opacity,1);transform:translate3d(var(--tw-enter-translate-x,0),var(--tw-enter-translate-y,0),0)scale3d(var(--tw-enter-scale,1),var(--tw-enter-scale,1),var(--tw-enter-scale,1))rotate(var(--tw-enter-rotate,0));filter:blur(var(--tw-enter-blur,0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity,1);transform:translate3d(var(--tw-exit-translate-x,0),var(--tw-exit-translate-y,0),0)scale3d(var(--tw-exit-scale,1),var(--tw-exit-scale,1),var(--tw-exit-scale,1))rotate(var(--tw-exit-rotate,0));filter:blur(var(--tw-exit-blur,0))}}@keyframes accordion-down{0%{height:0}to{height:var(--radix-accordion-content-height,var(--bits-accordion-content-height,var(--reka-accordion-content-height,var(--kb-accordion-content-height,var(--ngp-accordion-content-height,auto)))))}}@keyframes accordion-up{0%{height:var(--radix-accordion-content-height,var(--bits-accordion-content-height,var(--reka-accordion-content-height,var(--kb-accordion-content-height,var(--ngp-accordion-content-height,auto)))))}to{height:0}}@keyframes caret-blink{0%,70%,to{opacity:1}20%,50%{opacity:0}} diff --git a/internal/web/dist/assets/index-CyGsiYei.js b/internal/web/dist/assets/index-CyGsiYei.js deleted file mode 100644 index f76f5dc..0000000 --- a/internal/web/dist/assets/index-CyGsiYei.js +++ /dev/null @@ -1,4167 +0,0 @@ -import{r as R,R as Je,a as B3,b as U3,c as pY,d as T_,e as fC,u as __,L as AR,N as ME,O as K3,f as fY,g as Um,h as mY,i as gY,j as hs,B as yY}from"./react-Dt2M6tWj.js";(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const d of document.querySelectorAll('link[rel="modulepreload"]'))o(d);new MutationObserver(d=>{for(const p of d)if(p.type==="childList")for(const m of p.addedNodes)m.tagName==="LINK"&&m.rel==="modulepreload"&&o(m)}).observe(document,{childList:!0,subtree:!0});function s(d){const p={};return d.integrity&&(p.integrity=d.integrity),d.referrerPolicy&&(p.referrerPolicy=d.referrerPolicy),d.crossOrigin==="use-credentials"?p.credentials="include":d.crossOrigin==="anonymous"?p.credentials="omit":p.credentials="same-origin",p}function o(d){if(d.ep)return;d.ep=!0;const p=s(d);fetch(d.href,p)}})();var OR={exports:{}},nb={};var pM;function vY(){if(pM)return nb;pM=1;var e=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function s(o,d,p){var m=null;if(p!==void 0&&(m=""+p),d.key!==void 0&&(m=""+d.key),"key"in d){p={};for(var g in d)g!=="key"&&(p[g]=d[g])}else p=d;return d=p.ref,{$$typeof:e,type:o,key:m,ref:d!==void 0?d:null,props:p}}return nb.Fragment=r,nb.jsx=s,nb.jsxs=s,nb}var fM;function xY(){return fM||(fM=1,OR.exports=vY()),OR.exports}var u=xY(),bY=(e,r,s,o,d,p,m,g)=>{let b=document.documentElement,S=["light","dark"];function j(T){(Array.isArray(e)?e:[e]).forEach(M=>{let I=M==="class",q=I&&p?d.map(G=>p[G]||G):d;I?(b.classList.remove(...q),b.classList.add(p&&p[T]?p[T]:T)):b.setAttribute(M,T)}),A(T)}function A(T){g&&S.includes(T)&&(b.style.colorScheme=T)}function k(){return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}if(o)j(o);else try{let T=localStorage.getItem(r)||s,M=m&&T==="system"?k():T;j(M)}catch{}},mM=["light","dark"],V3="(prefers-color-scheme: dark)",wY=typeof window>"u",$_=R.createContext(void 0),SY={setTheme:e=>{},themes:[]},N_=()=>{var e;return(e=R.useContext($_))!=null?e:SY},EY=e=>R.useContext($_)?R.createElement(R.Fragment,null,e.children):R.createElement(CY,{...e}),jY=["light","dark"],CY=({forcedTheme:e,disableTransitionOnChange:r=!1,enableSystem:s=!0,enableColorScheme:o=!0,storageKey:d="theme",themes:p=jY,defaultTheme:m=s?"system":"light",attribute:g="data-theme",value:b,children:S,nonce:j,scriptProps:A})=>{let[k,T]=R.useState(()=>OY(d,m)),[M,I]=R.useState(()=>k==="system"?kR():k),q=b?Object.values(b):p,G=R.useCallback(ee=>{let oe=ee;if(!oe)return;ee==="system"&&s&&(oe=kR());let Q=b?b[oe]:oe,ne=r?kY(j):null,de=document.documentElement,je=ve=>{ve==="class"?(de.classList.remove(...q),Q&&de.classList.add(Q)):ve.startsWith("data-")&&(Q?de.setAttribute(ve,Q):de.removeAttribute(ve))};if(Array.isArray(g)?g.forEach(je):je(g),o){let ve=mM.includes(m)?m:null,le=mM.includes(oe)?oe:ve;de.style.colorScheme=le}ne?.()},[j]),K=R.useCallback(ee=>{let oe=typeof ee=="function"?ee(k):ee;T(oe);try{localStorage.setItem(d,oe)}catch{}},[k]),X=R.useCallback(ee=>{let oe=kR(ee);I(oe),k==="system"&&s&&!e&&G("system")},[k,e]);R.useEffect(()=>{let ee=window.matchMedia(V3);return ee.addListener(X),X(ee),()=>ee.removeListener(X)},[X]),R.useEffect(()=>{let ee=oe=>{oe.key===d&&(oe.newValue?T(oe.newValue):K(m))};return window.addEventListener("storage",ee),()=>window.removeEventListener("storage",ee)},[K]),R.useEffect(()=>{G(e??k)},[e,k]);let L=R.useMemo(()=>({theme:k,setTheme:K,forcedTheme:e,resolvedTheme:k==="system"?M:k,themes:s?[...p,"system"]:p,systemTheme:s?M:void 0}),[k,K,e,M,s,p]);return R.createElement($_.Provider,{value:L},R.createElement(AY,{forcedTheme:e,storageKey:d,attribute:g,enableSystem:s,enableColorScheme:o,defaultTheme:m,value:b,themes:p,nonce:j,scriptProps:A}),S)},AY=R.memo(({forcedTheme:e,storageKey:r,attribute:s,enableSystem:o,enableColorScheme:d,defaultTheme:p,value:m,themes:g,nonce:b,scriptProps:S})=>{let j=JSON.stringify([s,r,p,e,g,m,o,d]).slice(1,-1);return R.createElement("script",{...S,suppressHydrationWarning:!0,nonce:typeof window>"u"?b:"",dangerouslySetInnerHTML:{__html:`(${bY.toString()})(${j})`}})}),OY=(e,r)=>{if(wY)return;let s;try{s=localStorage.getItem(e)||void 0}catch{}return s||r},kY=e=>{let r=document.createElement("style");return e&&r.setAttribute("nonce",e),r.appendChild(document.createTextNode("*,*::before,*::after{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}")),document.head.appendChild(r),()=>{window.getComputedStyle(document.body),setTimeout(()=>{document.head.removeChild(r)},1)}},kR=e=>(e||(e=window.matchMedia(V3)),e.matches?"dark":"light");function RY({children:e,defaultTheme:r="system",storageKey:s="vite-ui-theme"}){return u.jsx(EY,{attribute:"class",defaultTheme:r,enableSystem:!0,storageKey:s,disableTransitionOnChange:!0,children:e})}var jg=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},TY={setTimeout:(e,r)=>setTimeout(e,r),clearTimeout:e=>clearTimeout(e),setInterval:(e,r)=>setInterval(e,r),clearInterval:e=>clearInterval(e)},_Y=class{#e=TY;#t=!1;setTimeoutProvider(e){this.#e=e}setTimeout(e,r){return this.#e.setTimeout(e,r)}clearTimeout(e){this.#e.clearTimeout(e)}setInterval(e,r){return this.#e.setInterval(e,r)}clearInterval(e){this.#e.clearInterval(e)}},vp=new _Y;function $Y(e){setTimeout(e,0)}var Cp=typeof window>"u"||"Deno"in globalThis;function Pi(){}function NY(e,r){return typeof e=="function"?e(r):e}function ST(e){return typeof e=="number"&&e>=0&&e!==1/0}function H3(e,r){return Math.max(e+(r||0)-Date.now(),0)}function Ld(e,r){return typeof e=="function"?e(r):e}function no(e,r){return typeof e=="function"?e(r):e}function gM(e,r){const{type:s="all",exact:o,fetchStatus:d,predicate:p,queryKey:m,stale:g}=e;if(m){if(o){if(r.queryHash!==D_(m,r.options))return!1}else if(!Mb(r.queryKey,m))return!1}if(s!=="all"){const b=r.isActive();if(s==="active"&&!b||s==="inactive"&&b)return!1}return!(typeof g=="boolean"&&r.isStale()!==g||d&&d!==r.state.fetchStatus||p&&!p(r))}function yM(e,r){const{exact:s,status:o,predicate:d,mutationKey:p}=e;if(p){if(!r.options.mutationKey)return!1;if(s){if(Ap(r.options.mutationKey)!==Ap(p))return!1}else if(!Mb(r.options.mutationKey,p))return!1}return!(o&&r.state.status!==o||d&&!d(r))}function D_(e,r){return(r?.queryKeyHashFn||Ap)(e)}function Ap(e){return JSON.stringify(e,(r,s)=>ET(s)?Object.keys(s).sort().reduce((o,d)=>(o[d]=s[d],o),{}):s)}function Mb(e,r){return e===r?!0:typeof e!=typeof r?!1:e&&r&&typeof e=="object"&&typeof r=="object"?Object.keys(r).every(s=>Mb(e[s],r[s])):!1}var DY=Object.prototype.hasOwnProperty;function G3(e,r){if(e===r)return e;const s=vM(e)&&vM(r);if(!s&&!(ET(e)&&ET(r)))return r;const d=(s?e:Object.keys(e)).length,p=s?r:Object.keys(r),m=p.length,g=s?new Array(m):{};let b=0;for(let S=0;S{vp.setTimeout(r,e)})}function jT(e,r,s){return typeof s.structuralSharing=="function"?s.structuralSharing(e,r):s.structuralSharing!==!1?G3(e,r):r}function MY(e,r,s=0){const o=[...e,r];return s&&o.length>s?o.slice(1):o}function IY(e,r,s=0){const o=[r,...e];return s&&o.length>s?o.slice(0,-1):o}var P_=Symbol();function X3(e,r){return!e.queryFn&&r?.initialPromise?()=>r.initialPromise:!e.queryFn||e.queryFn===P_?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function Y3(e,r){return typeof e=="function"?e(...r):!!e}var LY=class extends jg{#e;#t;#n;constructor(){super(),this.#n=e=>{if(!Cp&&window.addEventListener){const r=()=>e();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()})}setFocused(e){this.#e!==e&&(this.#e=e,this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach(r=>{r(e)})}isFocused(){return typeof this.#e=="boolean"?this.#e:globalThis.document?.visibilityState!=="hidden"}},M_=new LY;function CT(){let e,r;const s=new Promise((d,p)=>{e=d,r=p});s.status="pending",s.catch(()=>{});function o(d){Object.assign(s,d),delete s.resolve,delete s.reject}return s.resolve=d=>{o({status:"fulfilled",value:d}),e(d)},s.reject=d=>{o({status:"rejected",reason:d}),r(d)},s}var zY=$Y;function FY(){let e=[],r=0,s=g=>{g()},o=g=>{g()},d=zY;const p=g=>{r?e.push(g):d(()=>{s(g)})},m=()=>{const g=e;e=[],g.length&&d(()=>{o(()=>{g.forEach(b=>{s(b)})})})};return{batch:g=>{let b;r++;try{b=g()}finally{r--,r||m()}return b},batchCalls:g=>(...b)=>{p(()=>{g(...b)})},schedule:p,setNotifyFunction:g=>{s=g},setBatchNotifyFunction:g=>{o=g},setScheduler:g=>{d=g}}}var Cs=FY(),qY=class extends jg{#e=!0;#t;#n;constructor(){super(),this.#n=e=>{if(!Cp&&window.addEventListener){const r=()=>e(!0),s=()=>e(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",s,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",s)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(this.setOnline.bind(this))}setOnline(e){this.#e!==e&&(this.#e=e,this.listeners.forEach(s=>{s(e)}))}isOnline(){return this.#e}},Oj=new qY;function BY(e){return Math.min(1e3*2**e,3e4)}function Z3(e){return(e??"online")==="online"?Oj.isOnline():!0}var AT=class extends Error{constructor(e){super("CancelledError"),this.revert=e?.revert,this.silent=e?.silent}};function W3(e){let r=!1,s=0,o;const d=CT(),p=()=>d.status!=="pending",m=I=>{if(!p()){const q=new AT(I);k(q),e.onCancel?.(q)}},g=()=>{r=!0},b=()=>{r=!1},S=()=>M_.isFocused()&&(e.networkMode==="always"||Oj.isOnline())&&e.canRun(),j=()=>Z3(e.networkMode)&&e.canRun(),A=I=>{p()||(o?.(),d.resolve(I))},k=I=>{p()||(o?.(),d.reject(I))},T=()=>new Promise(I=>{o=q=>{(p()||S())&&I(q)},e.onPause?.()}).then(()=>{o=void 0,p()||e.onContinue?.()}),M=()=>{if(p())return;let I;const q=s===0?e.initialPromise:void 0;try{I=q??e.fn()}catch(G){I=Promise.reject(G)}Promise.resolve(I).then(A).catch(G=>{if(p())return;const K=e.retry??(Cp?0:3),X=e.retryDelay??BY,L=typeof X=="function"?X(s,G):X,ee=K===!0||typeof K=="number"&&sS()?void 0:T()).then(()=>{r?k(G):M()})})};return{promise:d,status:()=>d.status,cancel:m,continue:()=>(o?.(),d),cancelRetry:g,continueRetry:b,canStart:j,start:()=>(j()?M():T().then(M),d)}}var J3=class{#e;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),ST(this.gcTime)&&(this.#e=vp.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Cp?1/0:300*1e3))}clearGcTimeout(){this.#e&&(vp.clearTimeout(this.#e),this.#e=void 0)}},UY=class extends J3{#e;#t;#n;#s;#r;#a;#o;constructor(e){super(),this.#o=!1,this.#a=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.#s=e.client,this.#n=this.#s.getQueryCache(),this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#e=wM(this.options),this.state=e.state??this.#e,this.scheduleGc()}get meta(){return this.options.meta}get promise(){return this.#r?.promise}setOptions(e){if(this.options={...this.#a,...e},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const r=wM(this.options);r.data!==void 0&&(this.setState(bM(r.data,r.dataUpdatedAt)),this.#e=r)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&this.#n.remove(this)}setData(e,r){const s=jT(this.state.data,e,this.options);return this.#i({data:s,type:"success",dataUpdatedAt:r?.updatedAt,manual:r?.manual}),s}setState(e,r){this.#i({type:"setState",state:e,setStateOptions:r})}cancel(e){const r=this.#r?.promise;return this.#r?.cancel(e),r?r.then(Pi).catch(Pi):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#e)}isActive(){return this.observers.some(e=>no(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===P_||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>Ld(e.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e==="static"?!1:this.state.isInvalidated?!0:!H3(this.state.dataUpdatedAt,e)}onFocus(){this.observers.find(r=>r.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#r?.continue()}onOnline(){this.observers.find(r=>r.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#r?.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(r=>r!==e),this.observers.length||(this.#r&&(this.#o?this.#r.cancel({revert:!0}):this.#r.cancelRetry()),this.scheduleGc()),this.#n.notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.#i({type:"invalidate"})}async fetch(e,r){if(this.state.fetchStatus!=="idle"&&this.#r?.status()!=="rejected"){if(this.state.data!==void 0&&r?.cancelRefetch)this.cancel({silent:!0});else if(this.#r)return this.#r.continueRetry(),this.#r.promise}if(e&&this.setOptions(e),!this.options.queryFn){const g=this.observers.find(b=>b.options.queryFn);g&&this.setOptions(g.options)}const s=new AbortController,o=g=>{Object.defineProperty(g,"signal",{enumerable:!0,get:()=>(this.#o=!0,s.signal)})},d=()=>{const g=X3(this.options,r),S=(()=>{const j={client:this.#s,queryKey:this.queryKey,meta:this.meta};return o(j),j})();return this.#o=!1,this.options.persister?this.options.persister(g,S,this):g(S)},m=(()=>{const g={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:this.#s,state:this.state,fetchFn:d};return o(g),g})();this.options.behavior?.onFetch(m,this),this.#t=this.state,(this.state.fetchStatus==="idle"||this.state.fetchMeta!==m.fetchOptions?.meta)&&this.#i({type:"fetch",meta:m.fetchOptions?.meta}),this.#r=W3({initialPromise:r?.initialPromise,fn:m.fetchFn,onCancel:g=>{g instanceof AT&&g.revert&&this.setState({...this.#t,fetchStatus:"idle"}),s.abort()},onFail:(g,b)=>{this.#i({type:"failed",failureCount:g,error:b})},onPause:()=>{this.#i({type:"pause"})},onContinue:()=>{this.#i({type:"continue"})},retry:m.options.retry,retryDelay:m.options.retryDelay,networkMode:m.options.networkMode,canRun:()=>!0});try{const g=await this.#r.start();if(g===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(g),this.#n.config.onSuccess?.(g,this),this.#n.config.onSettled?.(g,this.state.error,this),g}catch(g){if(g instanceof AT){if(g.silent)return this.#r.promise;if(g.revert){if(this.state.data===void 0)throw g;return this.state.data}}throw this.#i({type:"error",error:g}),this.#n.config.onError?.(g,this),this.#n.config.onSettled?.(this.state.data,g,this),g}finally{this.scheduleGc()}}#i(e){const r=s=>{switch(e.type){case"failed":return{...s,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...s,fetchStatus:"paused"};case"continue":return{...s,fetchStatus:"fetching"};case"fetch":return{...s,...Q3(s.data,this.options),fetchMeta:e.meta??null};case"success":const o={...s,...bM(e.data,e.dataUpdatedAt),dataUpdateCount:s.dataUpdateCount+1,...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return this.#t=e.manual?o:void 0,o;case"error":const d=e.error;return{...s,error:d,errorUpdateCount:s.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:s.fetchFailureCount+1,fetchFailureReason:d,fetchStatus:"idle",status:"error"};case"invalidate":return{...s,isInvalidated:!0};case"setState":return{...s,...e.state}}};this.state=r(this.state),Cs.batch(()=>{this.observers.forEach(s=>{s.onQueryUpdate()}),this.#n.notify({query:this,type:"updated",action:e})})}};function Q3(e,r){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Z3(r.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function bM(e,r){return{data:e,dataUpdatedAt:r??Date.now(),error:null,isInvalidated:!1,status:"success"}}function wM(e){const r=typeof e.initialData=="function"?e.initialData():e.initialData,s=r!==void 0,o=s?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:r,dataUpdateCount:0,dataUpdatedAt:s?o??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:s?"success":"pending",fetchStatus:"idle"}}var KY=class extends jg{constructor(e,r){super(),this.options=r,this.#e=e,this.#i=null,this.#o=CT(),this.bindMethods(),this.setOptions(r)}#e;#t=void 0;#n=void 0;#s=void 0;#r;#a;#o;#i;#m;#h;#p;#c;#u;#l;#f=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.#t.addObserver(this),SM(this.#t,this.options)?this.#d():this.updateResult(),this.#x())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return OT(this.#t,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return OT(this.#t,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#b(),this.#w(),this.#t.removeObserver(this)}setOptions(e){const r=this.options,s=this.#t;if(this.options=this.#e.defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof no(this.options.enabled,this.#t)!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");this.#S(),this.#t.setOptions(this.options),r._defaulted&&!Aj(this.options,r)&&this.#e.getQueryCache().notify({type:"observerOptionsUpdated",query:this.#t,observer:this});const o=this.hasListeners();o&&EM(this.#t,s,this.options,r)&&this.#d(),this.updateResult(),o&&(this.#t!==s||no(this.options.enabled,this.#t)!==no(r.enabled,this.#t)||Ld(this.options.staleTime,this.#t)!==Ld(r.staleTime,this.#t))&&this.#g();const d=this.#y();o&&(this.#t!==s||no(this.options.enabled,this.#t)!==no(r.enabled,this.#t)||d!==this.#l)&&this.#v(d)}getOptimisticResult(e){const r=this.#e.getQueryCache().build(this.#e,e),s=this.createResult(r,e);return HY(this,s)&&(this.#s=s,this.#a=this.options,this.#r=this.#t.state),s}getCurrentResult(){return this.#s}trackResult(e,r){return new Proxy(e,{get:(s,o)=>(this.trackProp(o),r?.(o),o==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&this.#o.status==="pending"&&this.#o.reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(s,o))})}trackProp(e){this.#f.add(e)}getCurrentQuery(){return this.#t}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const r=this.#e.defaultQueryOptions(e),s=this.#e.getQueryCache().build(this.#e,r);return s.fetch().then(()=>this.createResult(s,r))}fetch(e){return this.#d({...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),this.#s))}#d(e){this.#S();let r=this.#t.fetch(this.options,e);return e?.throwOnError||(r=r.catch(Pi)),r}#g(){this.#b();const e=Ld(this.options.staleTime,this.#t);if(Cp||this.#s.isStale||!ST(e))return;const s=H3(this.#s.dataUpdatedAt,e)+1;this.#c=vp.setTimeout(()=>{this.#s.isStale||this.updateResult()},s)}#y(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.#t):this.options.refetchInterval)??!1}#v(e){this.#w(),this.#l=e,!(Cp||no(this.options.enabled,this.#t)===!1||!ST(this.#l)||this.#l===0)&&(this.#u=vp.setInterval(()=>{(this.options.refetchIntervalInBackground||M_.isFocused())&&this.#d()},this.#l))}#x(){this.#g(),this.#v(this.#y())}#b(){this.#c&&(vp.clearTimeout(this.#c),this.#c=void 0)}#w(){this.#u&&(vp.clearInterval(this.#u),this.#u=void 0)}createResult(e,r){const s=this.#t,o=this.options,d=this.#s,p=this.#r,m=this.#a,b=e!==s?e.state:this.#n,{state:S}=e;let j={...S},A=!1,k;if(r._optimisticResults){const ne=this.hasListeners(),de=!ne&&SM(e,r),je=ne&&EM(e,s,r,o);(de||je)&&(j={...j,...Q3(S.data,e.options)}),r._optimisticResults==="isRestoring"&&(j.fetchStatus="idle")}let{error:T,errorUpdatedAt:M,status:I}=j;k=j.data;let q=!1;if(r.placeholderData!==void 0&&k===void 0&&I==="pending"){let ne;d?.isPlaceholderData&&r.placeholderData===m?.placeholderData?(ne=d.data,q=!0):ne=typeof r.placeholderData=="function"?r.placeholderData(this.#p?.state.data,this.#p):r.placeholderData,ne!==void 0&&(I="success",k=jT(d?.data,ne,r),A=!0)}if(r.select&&k!==void 0&&!q)if(d&&k===p?.data&&r.select===this.#m)k=this.#h;else try{this.#m=r.select,k=r.select(k),k=jT(d?.data,k,r),this.#h=k,this.#i=null}catch(ne){this.#i=ne}this.#i&&(T=this.#i,k=this.#h,M=Date.now(),I="error");const G=j.fetchStatus==="fetching",K=I==="pending",X=I==="error",L=K&&G,ee=k!==void 0,Q={status:I,fetchStatus:j.fetchStatus,isPending:K,isSuccess:I==="success",isError:X,isInitialLoading:L,isLoading:L,data:k,dataUpdatedAt:j.dataUpdatedAt,error:T,errorUpdatedAt:M,failureCount:j.fetchFailureCount,failureReason:j.fetchFailureReason,errorUpdateCount:j.errorUpdateCount,isFetched:j.dataUpdateCount>0||j.errorUpdateCount>0,isFetchedAfterMount:j.dataUpdateCount>b.dataUpdateCount||j.errorUpdateCount>b.errorUpdateCount,isFetching:G,isRefetching:G&&!K,isLoadingError:X&&!ee,isPaused:j.fetchStatus==="paused",isPlaceholderData:A,isRefetchError:X&&ee,isStale:I_(e,r),refetch:this.refetch,promise:this.#o,isEnabled:no(r.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){const ne=ve=>{Q.status==="error"?ve.reject(Q.error):Q.data!==void 0&&ve.resolve(Q.data)},de=()=>{const ve=this.#o=Q.promise=CT();ne(ve)},je=this.#o;switch(je.status){case"pending":e.queryHash===s.queryHash&&ne(je);break;case"fulfilled":(Q.status==="error"||Q.data!==je.value)&&de();break;case"rejected":(Q.status!=="error"||Q.error!==je.reason)&&de();break}}return Q}updateResult(){const e=this.#s,r=this.createResult(this.#t,this.options);if(this.#r=this.#t.state,this.#a=this.options,this.#r.data!==void 0&&(this.#p=this.#t),Aj(r,e))return;this.#s=r;const s=()=>{if(!e)return!0;const{notifyOnChangeProps:o}=this.options,d=typeof o=="function"?o():o;if(d==="all"||!d&&!this.#f.size)return!0;const p=new Set(d??this.#f);return this.options.throwOnError&&p.add("error"),Object.keys(this.#s).some(m=>{const g=m;return this.#s[g]!==e[g]&&p.has(g)})};this.#E({listeners:s()})}#S(){const e=this.#e.getQueryCache().build(this.#e,this.options);if(e===this.#t)return;const r=this.#t;this.#t=e,this.#n=e.state,this.hasListeners()&&(r?.removeObserver(this),e.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#x()}#E(e){Cs.batch(()=>{e.listeners&&this.listeners.forEach(r=>{r(this.#s)}),this.#e.getQueryCache().notify({query:this.#t,type:"observerResultsUpdated"})})}};function VY(e,r){return no(r.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&r.retryOnMount===!1)}function SM(e,r){return VY(e,r)||e.state.data!==void 0&&OT(e,r,r.refetchOnMount)}function OT(e,r,s){if(no(r.enabled,e)!==!1&&Ld(r.staleTime,e)!=="static"){const o=typeof s=="function"?s(e):s;return o==="always"||o!==!1&&I_(e,r)}return!1}function EM(e,r,s,o){return(e!==r||no(o.enabled,e)===!1)&&(!s.suspense||e.state.status!=="error")&&I_(e,s)}function I_(e,r){return no(r.enabled,e)!==!1&&e.isStaleByTime(Ld(r.staleTime,e))}function HY(e,r){return!Aj(e.getCurrentResult(),r)}function jM(e){return{onFetch:(r,s)=>{const o=r.options,d=r.fetchOptions?.meta?.fetchMore?.direction,p=r.state.data?.pages||[],m=r.state.data?.pageParams||[];let g={pages:[],pageParams:[]},b=0;const S=async()=>{let j=!1;const A=M=>{Object.defineProperty(M,"signal",{enumerable:!0,get:()=>(r.signal.aborted?j=!0:r.signal.addEventListener("abort",()=>{j=!0}),r.signal)})},k=X3(r.options,r.fetchOptions),T=async(M,I,q)=>{if(j)return Promise.reject();if(I==null&&M.pages.length)return Promise.resolve(M);const K=(()=>{const oe={client:r.client,queryKey:r.queryKey,pageParam:I,direction:q?"backward":"forward",meta:r.options.meta};return A(oe),oe})(),X=await k(K),{maxPages:L}=r.options,ee=q?IY:MY;return{pages:ee(M.pages,X,L),pageParams:ee(M.pageParams,I,L)}};if(d&&p.length){const M=d==="backward",I=M?GY:CM,q={pages:p,pageParams:m},G=I(o,q);g=await T(q,G,M)}else{const M=e??p.length;do{const I=b===0?m[0]??o.initialPageParam:CM(o,g);if(b>0&&I==null)break;g=await T(g,I),b++}while(br.options.persister?.(S,{client:r.client,queryKey:r.queryKey,meta:r.options.meta,signal:r.signal},s):r.fetchFn=S}}}function CM(e,{pages:r,pageParams:s}){const o=r.length-1;return r.length>0?e.getNextPageParam(r[o],r,s[o],s):void 0}function GY(e,{pages:r,pageParams:s}){return r.length>0?e.getPreviousPageParam?.(r[0],r,s[0],s):void 0}var XY=class extends J3{#e;#t;#n;#s;constructor(e){super(),this.#e=e.client,this.mutationId=e.mutationId,this.#n=e.mutationCache,this.#t=[],this.state=e.state||eL(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#t.includes(e)||(this.#t.push(e),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){this.#t=this.#t.filter(r=>r!==e),this.scheduleGc(),this.#n.notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){this.#t.length||(this.state.status==="pending"?this.scheduleGc():this.#n.remove(this))}continue(){return this.#s?.continue()??this.execute(this.state.variables)}async execute(e){const r=()=>{this.#r({type:"continue"})},s={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#s=W3({fn:()=>this.options.mutationFn?this.options.mutationFn(e,s):Promise.reject(new Error("No mutationFn found")),onFail:(p,m)=>{this.#r({type:"failed",failureCount:p,error:m})},onPause:()=>{this.#r({type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#n.canRun(this)});const o=this.state.status==="pending",d=!this.#s.canStart();try{if(o)r();else{this.#r({type:"pending",variables:e,isPaused:d}),await this.#n.config.onMutate?.(e,this,s);const m=await this.options.onMutate?.(e,s);m!==this.state.context&&this.#r({type:"pending",context:m,variables:e,isPaused:d})}const p=await this.#s.start();return await this.#n.config.onSuccess?.(p,e,this.state.context,this,s),await this.options.onSuccess?.(p,e,this.state.context,s),await this.#n.config.onSettled?.(p,null,this.state.variables,this.state.context,this,s),await this.options.onSettled?.(p,null,e,this.state.context,s),this.#r({type:"success",data:p}),p}catch(p){try{throw await this.#n.config.onError?.(p,e,this.state.context,this,s),await this.options.onError?.(p,e,this.state.context,s),await this.#n.config.onSettled?.(void 0,p,this.state.variables,this.state.context,this,s),await this.options.onSettled?.(void 0,p,e,this.state.context,s),p}finally{this.#r({type:"error",error:p})}}finally{this.#n.runNext(this)}}#r(e){const r=s=>{switch(e.type){case"failed":return{...s,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...s,isPaused:!0};case"continue":return{...s,isPaused:!1};case"pending":return{...s,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...s,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...s,data:void 0,error:e.error,failureCount:s.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Cs.batch(()=>{this.#t.forEach(s=>{s.onMutationUpdate(e)}),this.#n.notify({mutation:this,type:"updated",action:e})})}};function eL(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var YY=class extends jg{constructor(e={}){super(),this.config=e,this.#e=new Set,this.#t=new Map,this.#n=0}#e;#t;#n;build(e,r,s){const o=new XY({client:e,mutationCache:this,mutationId:++this.#n,options:e.defaultMutationOptions(r),state:s});return this.add(o),o}add(e){this.#e.add(e);const r=IE(e);if(typeof r=="string"){const s=this.#t.get(r);s?s.push(e):this.#t.set(r,[e])}this.notify({type:"added",mutation:e})}remove(e){if(this.#e.delete(e)){const r=IE(e);if(typeof r=="string"){const s=this.#t.get(r);if(s)if(s.length>1){const o=s.indexOf(e);o!==-1&&s.splice(o,1)}else s[0]===e&&this.#t.delete(r)}}this.notify({type:"removed",mutation:e})}canRun(e){const r=IE(e);if(typeof r=="string"){const o=this.#t.get(r)?.find(d=>d.state.status==="pending");return!o||o===e}else return!0}runNext(e){const r=IE(e);return typeof r=="string"?this.#t.get(r)?.find(o=>o!==e&&o.state.isPaused)?.continue()??Promise.resolve():Promise.resolve()}clear(){Cs.batch(()=>{this.#e.forEach(e=>{this.notify({type:"removed",mutation:e})}),this.#e.clear(),this.#t.clear()})}getAll(){return Array.from(this.#e)}find(e){const r={exact:!0,...e};return this.getAll().find(s=>yM(r,s))}findAll(e={}){return this.getAll().filter(r=>yM(e,r))}notify(e){Cs.batch(()=>{this.listeners.forEach(r=>{r(e)})})}resumePausedMutations(){const e=this.getAll().filter(r=>r.state.isPaused);return Cs.batch(()=>Promise.all(e.map(r=>r.continue().catch(Pi))))}};function IE(e){return e.options.scope?.id}var ZY=class extends jg{#e;#t=void 0;#n;#s;constructor(r,s){super(),this.#e=r,this.setOptions(s),this.bindMethods(),this.#r()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(r){const s=this.options;this.options=this.#e.defaultMutationOptions(r),Aj(this.options,s)||this.#e.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#n,observer:this}),s?.mutationKey&&this.options.mutationKey&&Ap(s.mutationKey)!==Ap(this.options.mutationKey)?this.reset():this.#n?.state.status==="pending"&&this.#n.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#n?.removeObserver(this)}onMutationUpdate(r){this.#r(),this.#a(r)}getCurrentResult(){return this.#t}reset(){this.#n?.removeObserver(this),this.#n=void 0,this.#r(),this.#a()}mutate(r,s){return this.#s=s,this.#n?.removeObserver(this),this.#n=this.#e.getMutationCache().build(this.#e,this.options),this.#n.addObserver(this),this.#n.execute(r)}#r(){const r=this.#n?.state??eL();this.#t={...r,isPending:r.status==="pending",isSuccess:r.status==="success",isError:r.status==="error",isIdle:r.status==="idle",mutate:this.mutate,reset:this.reset}}#a(r){Cs.batch(()=>{if(this.#s&&this.hasListeners()){const s=this.#t.variables,o=this.#t.context,d={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};r?.type==="success"?(this.#s.onSuccess?.(r.data,s,o,d),this.#s.onSettled?.(r.data,null,s,o,d)):r?.type==="error"&&(this.#s.onError?.(r.error,s,o,d),this.#s.onSettled?.(void 0,r.error,s,o,d))}this.listeners.forEach(s=>{s(this.#t)})})}},WY=class extends jg{constructor(e={}){super(),this.config=e,this.#e=new Map}#e;build(e,r,s){const o=r.queryKey,d=r.queryHash??D_(o,r);let p=this.get(d);return p||(p=new UY({client:e,queryKey:o,queryHash:d,options:e.defaultQueryOptions(r),state:s,defaultOptions:e.getQueryDefaults(o)}),this.add(p)),p}add(e){this.#e.has(e.queryHash)||(this.#e.set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const r=this.#e.get(e.queryHash);r&&(e.destroy(),r===e&&this.#e.delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){Cs.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return this.#e.get(e)}getAll(){return[...this.#e.values()]}find(e){const r={exact:!0,...e};return this.getAll().find(s=>gM(r,s))}findAll(e={}){const r=this.getAll();return Object.keys(e).length>0?r.filter(s=>gM(e,s)):r}notify(e){Cs.batch(()=>{this.listeners.forEach(r=>{r(e)})})}onFocus(){Cs.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){Cs.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},JY=class{#e;#t;#n;#s;#r;#a;#o;#i;constructor(e={}){this.#e=e.queryCache||new WY,this.#t=e.mutationCache||new YY,this.#n=e.defaultOptions||{},this.#s=new Map,this.#r=new Map,this.#a=0}mount(){this.#a++,this.#a===1&&(this.#o=M_.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onFocus())}),this.#i=Oj.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onOnline())}))}unmount(){this.#a--,this.#a===0&&(this.#o?.(),this.#o=void 0,this.#i?.(),this.#i=void 0)}isFetching(e){return this.#e.findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return this.#t.findAll({...e,status:"pending"}).length}getQueryData(e){const r=this.defaultQueryOptions({queryKey:e});return this.#e.get(r.queryHash)?.state.data}ensureQueryData(e){const r=this.defaultQueryOptions(e),s=this.#e.build(this,r),o=s.state.data;return o===void 0?this.fetchQuery(e):(e.revalidateIfStale&&s.isStaleByTime(Ld(r.staleTime,s))&&this.prefetchQuery(r),Promise.resolve(o))}getQueriesData(e){return this.#e.findAll(e).map(({queryKey:r,state:s})=>{const o=s.data;return[r,o]})}setQueryData(e,r,s){const o=this.defaultQueryOptions({queryKey:e}),p=this.#e.get(o.queryHash)?.state.data,m=NY(r,p);if(m!==void 0)return this.#e.build(this,o).setData(m,{...s,manual:!0})}setQueriesData(e,r,s){return Cs.batch(()=>this.#e.findAll(e).map(({queryKey:o})=>[o,this.setQueryData(o,r,s)]))}getQueryState(e){const r=this.defaultQueryOptions({queryKey:e});return this.#e.get(r.queryHash)?.state}removeQueries(e){const r=this.#e;Cs.batch(()=>{r.findAll(e).forEach(s=>{r.remove(s)})})}resetQueries(e,r){const s=this.#e;return Cs.batch(()=>(s.findAll(e).forEach(o=>{o.reset()}),this.refetchQueries({type:"active",...e},r)))}cancelQueries(e,r={}){const s={revert:!0,...r},o=Cs.batch(()=>this.#e.findAll(e).map(d=>d.cancel(s)));return Promise.all(o).then(Pi).catch(Pi)}invalidateQueries(e,r={}){return Cs.batch(()=>(this.#e.findAll(e).forEach(s=>{s.invalidate()}),e?.refetchType==="none"?Promise.resolve():this.refetchQueries({...e,type:e?.refetchType??e?.type??"active"},r)))}refetchQueries(e,r={}){const s={...r,cancelRefetch:r.cancelRefetch??!0},o=Cs.batch(()=>this.#e.findAll(e).filter(d=>!d.isDisabled()&&!d.isStatic()).map(d=>{let p=d.fetch(void 0,s);return s.throwOnError||(p=p.catch(Pi)),d.state.fetchStatus==="paused"?Promise.resolve():p}));return Promise.all(o).then(Pi)}fetchQuery(e){const r=this.defaultQueryOptions(e);r.retry===void 0&&(r.retry=!1);const s=this.#e.build(this,r);return s.isStaleByTime(Ld(r.staleTime,s))?s.fetch(r):Promise.resolve(s.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Pi).catch(Pi)}fetchInfiniteQuery(e){return e.behavior=jM(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Pi).catch(Pi)}ensureInfiniteQueryData(e){return e.behavior=jM(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Oj.isOnline()?this.#t.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#e}getMutationCache(){return this.#t}getDefaultOptions(){return this.#n}setDefaultOptions(e){this.#n=e}setQueryDefaults(e,r){this.#s.set(Ap(e),{queryKey:e,defaultOptions:r})}getQueryDefaults(e){const r=[...this.#s.values()],s={};return r.forEach(o=>{Mb(e,o.queryKey)&&Object.assign(s,o.defaultOptions)}),s}setMutationDefaults(e,r){this.#r.set(Ap(e),{mutationKey:e,defaultOptions:r})}getMutationDefaults(e){const r=[...this.#r.values()],s={};return r.forEach(o=>{Mb(e,o.mutationKey)&&Object.assign(s,o.defaultOptions)}),s}defaultQueryOptions(e){if(e._defaulted)return e;const r={...this.#n.queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return r.queryHash||(r.queryHash=D_(r.queryKey,r)),r.refetchOnReconnect===void 0&&(r.refetchOnReconnect=r.networkMode!=="always"),r.throwOnError===void 0&&(r.throwOnError=!!r.suspense),!r.networkMode&&r.persister&&(r.networkMode="offlineFirst"),r.queryFn===P_&&(r.enabled=!1),r}defaultMutationOptions(e){return e?._defaulted?e:{...this.#n.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#e.clear(),this.#t.clear()}},tL=R.createContext(void 0),Hs=e=>{const r=R.useContext(tL);if(!r)throw new Error("No QueryClient set, use QueryClientProvider to set one");return r},QY=({client:e,children:r})=>(R.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),u.jsx(tL.Provider,{value:e,children:r})),nL=R.createContext(!1),eZ=()=>R.useContext(nL);nL.Provider;function tZ(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var nZ=R.createContext(tZ()),rZ=()=>R.useContext(nZ),sZ=(e,r)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(r.isReset()||(e.retryOnMount=!1))},iZ=e=>{R.useEffect(()=>{e.clearReset()},[e])},aZ=({result:e,errorResetBoundary:r,throwOnError:s,query:o,suspense:d})=>e.isError&&!r.isReset()&&!e.isFetching&&o&&(d&&e.data===void 0||Y3(s,[e.error,o])),oZ=e=>{if(e.suspense){const s=d=>d==="static"?d:Math.max(d??1e3,1e3),o=e.staleTime;e.staleTime=typeof o=="function"?(...d)=>s(o(...d)):s(o),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},lZ=(e,r)=>e.isLoading&&e.isFetching&&!r,cZ=(e,r)=>e?.suspense&&r.isPending,AM=(e,r,s)=>r.fetchOptimistic(e).catch(()=>{s.clearReset()});function uZ(e,r,s){const o=eZ(),d=rZ(),p=Hs(),m=p.defaultQueryOptions(e);p.getDefaultOptions().queries?._experimental_beforeQuery?.(m),m._optimisticResults=o?"isRestoring":"optimistic",oZ(m),sZ(m,d),iZ(d);const g=!p.getQueryCache().get(m.queryHash),[b]=R.useState(()=>new r(p,m)),S=b.getOptimisticResult(m),j=!o&&e.subscribed!==!1;if(R.useSyncExternalStore(R.useCallback(A=>{const k=j?b.subscribe(Cs.batchCalls(A)):Pi;return b.updateResult(),k},[b,j]),()=>b.getCurrentResult(),()=>b.getCurrentResult()),R.useEffect(()=>{b.setOptions(m)},[m,b]),cZ(m,S))throw AM(m,b,d);if(aZ({result:S,errorResetBoundary:d,throwOnError:m.throwOnError,query:p.getQueryCache().get(m.queryHash),suspense:m.suspense}))throw S.error;return p.getDefaultOptions().queries?._experimental_afterQuery?.(m,S),m.experimental_prefetchInRender&&!Cp&&lZ(S,o)&&(g?AM(m,b,d):p.getQueryCache().get(m.queryHash)?.promise)?.catch(Pi).finally(()=>{b.updateResult()}),m.notifyOnChangeProps?S:b.trackResult(S)}function rr(e,r){return uZ(e,KY)}function nn(e,r){const s=Hs(),[o]=R.useState(()=>new ZY(s,e));R.useEffect(()=>{o.setOptions(e)},[o,e]);const d=R.useSyncExternalStore(R.useCallback(m=>o.subscribe(Cs.batchCalls(m)),[o]),()=>o.getCurrentResult(),()=>o.getCurrentResult()),p=R.useCallback((m,g)=>{o.mutate(m,g).catch(Pi)},[o]);if(d.error&&Y3(o.options.throwOnError,[d.error]))throw d.error;return{...d,mutate:p,mutateAsync:d.mutate}}const dZ=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),hZ=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(r,s,o)=>o?o.toUpperCase():s.toLowerCase()),OM=e=>{const r=hZ(e);return r.charAt(0).toUpperCase()+r.slice(1)},rL=(...e)=>e.filter((r,s,o)=>!!r&&r.trim()!==""&&o.indexOf(r)===s).join(" ").trim(),pZ=e=>{for(const r in e)if(r.startsWith("aria-")||r==="role"||r==="title")return!0};var fZ={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const mZ=R.forwardRef(({color:e="currentColor",size:r=24,strokeWidth:s=2,absoluteStrokeWidth:o,className:d="",children:p,iconNode:m,...g},b)=>R.createElement("svg",{ref:b,...fZ,width:r,height:r,stroke:e,strokeWidth:o?Number(s)*24/Number(r):s,className:rL("lucide",d),...!p&&!pZ(g)&&{"aria-hidden":"true"},...g},[...m.map(([S,j])=>R.createElement(S,j)),...Array.isArray(p)?p:[p]]));const ln=(e,r)=>{const s=R.forwardRef(({className:o,...d},p)=>R.createElement(mZ,{ref:p,iconNode:r,className:rL(`lucide-${dZ(OM(e))}`,`lucide-${e}`,o),...d}));return s.displayName=OM(e),s};const gZ=[["path",{d:"M2.97 12.92A2 2 0 0 0 2 14.63v3.24a2 2 0 0 0 .97 1.71l3 1.8a2 2 0 0 0 2.06 0L12 19v-5.5l-5-3-4.03 2.42Z",key:"lc1i9w"}],["path",{d:"m7 16.5-4.74-2.85",key:"1o9zyk"}],["path",{d:"m7 16.5 5-3",key:"va8pkn"}],["path",{d:"M7 16.5v5.17",key:"jnp8gn"}],["path",{d:"M12 13.5V19l3.97 2.38a2 2 0 0 0 2.06 0l3-1.8a2 2 0 0 0 .97-1.71v-3.24a2 2 0 0 0-.97-1.71L17 10.5l-5 3Z",key:"8zsnat"}],["path",{d:"m17 16.5-5-3",key:"8arw3v"}],["path",{d:"m17 16.5 4.74-2.85",key:"8rfmw"}],["path",{d:"M17 16.5v5.17",key:"k6z78m"}],["path",{d:"M7.97 4.42A2 2 0 0 0 7 6.13v4.37l5 3 5-3V6.13a2 2 0 0 0-.97-1.71l-3-1.8a2 2 0 0 0-2.06 0l-3 1.8Z",key:"1xygjf"}],["path",{d:"M12 8 7.26 5.15",key:"1vbdud"}],["path",{d:"m12 8 4.74-2.85",key:"3rx089"}],["path",{d:"M12 13.5V8",key:"1io7kd"}]],yZ=ln("boxes",gZ);const vZ=[["path",{d:"M10 12h4",key:"a56b0p"}],["path",{d:"M10 8h4",key:"1sr2af"}],["path",{d:"M14 21v-3a2 2 0 0 0-4 0v3",key:"1rgiei"}],["path",{d:"M6 10H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2",key:"secmi2"}],["path",{d:"M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16",key:"16ra0t"}]],sL=ln("building-2",vZ);const xZ=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],iL=ln("check",xZ);const bZ=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],aL=ln("chevron-down",bZ);const wZ=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],SZ=ln("chevron-right",wZ);const EZ=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],jZ=ln("chevron-up",EZ);const CZ=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],AZ=ln("chevrons-up-down",CZ);const OZ=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],kM=ln("circle-alert",OZ);const kZ=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],L_=ln("circle-check",kZ);const RZ=[["path",{d:"M22 2 2 22",key:"y4kqgn"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],Jb=ln("circle-slash-2",RZ);const TZ=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],_Z=ln("circle",TZ);const $Z=[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}]],NZ=ln("clipboard",$Z);const DZ=[["path",{d:"M15.536 11.293a1 1 0 0 0 0 1.414l2.376 2.377a1 1 0 0 0 1.414 0l2.377-2.377a1 1 0 0 0 0-1.414l-2.377-2.377a1 1 0 0 0-1.414 0z",key:"1uwlt4"}],["path",{d:"M2.297 11.293a1 1 0 0 0 0 1.414l2.377 2.377a1 1 0 0 0 1.414 0l2.377-2.377a1 1 0 0 0 0-1.414L6.088 8.916a1 1 0 0 0-1.414 0z",key:"10291m"}],["path",{d:"M8.916 17.912a1 1 0 0 0 0 1.415l2.377 2.376a1 1 0 0 0 1.414 0l2.377-2.376a1 1 0 0 0 0-1.415l-2.377-2.376a1 1 0 0 0-1.414 0z",key:"1tqoq1"}],["path",{d:"M8.916 4.674a1 1 0 0 0 0 1.414l2.377 2.376a1 1 0 0 0 1.414 0l2.377-2.376a1 1 0 0 0 0-1.414l-2.377-2.377a1 1 0 0 0-1.414 0z",key:"1x6lto"}]],PZ=ln("component",DZ);const MZ=[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]],IZ=ln("download",MZ);const LZ=[["path",{d:"M21.54 15H17a2 2 0 0 0-2 2v4.54",key:"1djwo0"}],["path",{d:"M7 3.34V5a3 3 0 0 0 3 3a2 2 0 0 1 2 2c0 1.1.9 2 2 2a2 2 0 0 0 2-2c0-1.1.9-2 2-2h3.17",key:"1tzkfa"}],["path",{d:"M11 21.95V18a2 2 0 0 0-2-2a2 2 0 0 1-2-2v-1a2 2 0 0 0-2-2H2.05",key:"14pb5j"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],zZ=ln("earth",LZ);const FZ=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],z_=ln("ellipsis",FZ);const qZ=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],BZ=ln("external-link",qZ);const UZ=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],kT=ln("eye",UZ);const KZ=[["path",{d:"M4 12.15V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2h-3.35",key:"1wthlu"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"m5 16-3 3 3 3",key:"331omg"}],["path",{d:"m9 22 3-3-3-3",key:"lsp7cz"}]],VZ=ln("file-code-corner",KZ);const HZ=[["path",{d:"M10.65 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v10.1",key:"1a2hbp"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"m10 15 1 1",key:"1h4vmv"}],["path",{d:"m11 14-4.586 4.586",key:"maylof"}],["circle",{cx:"5",cy:"20",r:"2",key:"860zyv"}]],GZ=ln("file-key",HZ);const XZ=[["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}],["line",{x1:"3",x2:"9",y1:"12",y2:"12",key:"1dyftd"}],["line",{x1:"15",x2:"21",y1:"12",y2:"12",key:"oup4p8"}]],YZ=ln("git-commit-horizontal",XZ);const ZZ=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],oL=ln("info",ZZ);const WZ=[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]],JZ=ln("key-round",WZ);const QZ=[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]],LE=ln("link",QZ);const eW=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],Ds=ln("loader-circle",eW);const tW=[["circle",{cx:"12",cy:"16",r:"1",key:"1au0dj"}],["rect",{x:"3",y:"10",width:"18",height:"12",rx:"2",key:"6s8ecr"}],["path",{d:"M7 10V7a5 5 0 0 1 10 0v3",key:"1pqi11"}]],nW=ln("lock-keyhole",tW);const rW=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],sW=ln("map-pin",rW);const iW=[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]],aW=ln("monitor",iW);const oW=[["path",{d:"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",key:"kfwtm"}]],lW=ln("moon",oW);const cW=[["rect",{x:"16",y:"16",width:"6",height:"6",rx:"1",key:"4q2zg0"}],["rect",{x:"2",y:"16",width:"6",height:"6",rx:"1",key:"8cvhb9"}],["rect",{x:"9",y:"2",width:"6",height:"6",rx:"1",key:"1egb70"}],["path",{d:"M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3",key:"1jsf9p"}],["path",{d:"M12 12V8",key:"2874zd"}]],uW=ln("network",cW);const dW=[["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"M2.586 16.726A2 2 0 0 1 2 15.312V8.688a2 2 0 0 1 .586-1.414l4.688-4.688A2 2 0 0 1 8.688 2h6.624a2 2 0 0 1 1.414.586l4.688 4.688A2 2 0 0 1 22 8.688v6.624a2 2 0 0 1-.586 1.414l-4.688 4.688a2 2 0 0 1-1.414.586H8.688a2 2 0 0 1-1.414-.586z",key:"2d38gg"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],hW=ln("octagon-x",dW);const pW=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]],fW=ln("panel-left",pW);const mW=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]],pu=ln("pencil",mW);const gW=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],oo=ln("plus",gW);const yW=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],vW=ln("refresh-cw",yW);const xW=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],Pa=ln("search",xW);const bW=[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]],F_=ln("server",bW);const wW=[["path",{d:"M3 3h.01",key:"159qn6"}],["path",{d:"M7 5h.01",key:"1hq22a"}],["path",{d:"M11 7h.01",key:"1osv80"}],["path",{d:"M3 7h.01",key:"1xzrh3"}],["path",{d:"M7 9h.01",key:"19b3jx"}],["path",{d:"M3 11h.01",key:"1eifu7"}],["rect",{width:"4",height:"4",x:"15",y:"5",key:"mri9e4"}],["path",{d:"m19 9 2 2v10c0 .6-.4 1-1 1h-6c-.6 0-1-.4-1-1V11l2-2",key:"aib6hk"}],["path",{d:"m13 14 8-2",key:"1d7bmk"}],["path",{d:"m13 19 8-2",key:"1y2vml"}]],SW=ln("spray-can",wW);const EW=[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]],jW=ln("sun",EW);const CW=[["path",{d:"M13.172 2a2 2 0 0 1 1.414.586l6.71 6.71a2.4 2.4 0 0 1 0 3.408l-4.592 4.592a2.4 2.4 0 0 1-3.408 0l-6.71-6.71A2 2 0 0 1 6 9.172V3a1 1 0 0 1 1-1z",key:"16rjxf"}],["path",{d:"M2 7v6.172a2 2 0 0 0 .586 1.414l6.71 6.71a2.4 2.4 0 0 0 3.191.193",key:"178nd4"}],["circle",{cx:"10.5",cy:"6.5",r:".5",fill:"currentColor",key:"12ikhr"}]],mC=ln("tags",CW);const AW=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],Ib=ln("trash-2",AW);const OW=[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]],kj=ln("triangle-alert",OW);const kW=[["circle",{cx:"12",cy:"8",r:"5",key:"1hypcn"}],["path",{d:"M20 21a8 8 0 0 0-16 0",key:"rfgkzh"}]],RW=ln("user-round",kW);const TW=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],lL=ln("users",TW);const _W=[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]],$W=ln("wrench",_W);const NW=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],q_=ln("x",NW);function DW(e){if(typeof document>"u")return;let r=document.head||document.getElementsByTagName("head")[0],s=document.createElement("style");s.type="text/css",r.appendChild(s),s.styleSheet?s.styleSheet.cssText=e:s.appendChild(document.createTextNode(e))}const PW=e=>{switch(e){case"success":return LW;case"info":return FW;case"warning":return zW;case"error":return qW;default:return null}},MW=Array(12).fill(0),IW=({visible:e,className:r})=>Je.createElement("div",{className:["sonner-loading-wrapper",r].filter(Boolean).join(" "),"data-visible":e},Je.createElement("div",{className:"sonner-spinner"},MW.map((s,o)=>Je.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${o}`})))),LW=Je.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},Je.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),zW=Je.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},Je.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),FW=Je.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},Je.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),qW=Je.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},Je.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),BW=Je.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},Je.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),Je.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),UW=()=>{const[e,r]=Je.useState(document.hidden);return Je.useEffect(()=>{const s=()=>{r(document.hidden)};return document.addEventListener("visibilitychange",s),()=>window.removeEventListener("visibilitychange",s)},[]),e};let RT=1;class KW{constructor(){this.subscribe=r=>(this.subscribers.push(r),()=>{const s=this.subscribers.indexOf(r);this.subscribers.splice(s,1)}),this.publish=r=>{this.subscribers.forEach(s=>s(r))},this.addToast=r=>{this.publish(r),this.toasts=[...this.toasts,r]},this.create=r=>{var s;const{message:o,...d}=r,p=typeof r?.id=="number"||((s=r.id)==null?void 0:s.length)>0?r.id:RT++,m=this.toasts.find(b=>b.id===p),g=r.dismissible===void 0?!0:r.dismissible;return this.dismissedToasts.has(p)&&this.dismissedToasts.delete(p),m?this.toasts=this.toasts.map(b=>b.id===p?(this.publish({...b,...r,id:p,title:o}),{...b,...r,id:p,dismissible:g,title:o}):b):this.addToast({title:o,...d,dismissible:g,id:p}),p},this.dismiss=r=>(r?(this.dismissedToasts.add(r),requestAnimationFrame(()=>this.subscribers.forEach(s=>s({id:r,dismiss:!0})))):this.toasts.forEach(s=>{this.subscribers.forEach(o=>o({id:s.id,dismiss:!0}))}),r),this.message=(r,s)=>this.create({...s,message:r}),this.error=(r,s)=>this.create({...s,message:r,type:"error"}),this.success=(r,s)=>this.create({...s,type:"success",message:r}),this.info=(r,s)=>this.create({...s,type:"info",message:r}),this.warning=(r,s)=>this.create({...s,type:"warning",message:r}),this.loading=(r,s)=>this.create({...s,type:"loading",message:r}),this.promise=(r,s)=>{if(!s)return;let o;s.loading!==void 0&&(o=this.create({...s,promise:r,type:"loading",message:s.loading,description:typeof s.description!="function"?s.description:void 0}));const d=Promise.resolve(r instanceof Function?r():r);let p=o!==void 0,m;const g=d.then(async S=>{if(m=["resolve",S],Je.isValidElement(S))p=!1,this.create({id:o,type:"default",message:S});else if(HW(S)&&!S.ok){p=!1;const A=typeof s.error=="function"?await s.error(`HTTP error! status: ${S.status}`):s.error,k=typeof s.description=="function"?await s.description(`HTTP error! status: ${S.status}`):s.description,M=typeof A=="object"&&!Je.isValidElement(A)?A:{message:A};this.create({id:o,type:"error",description:k,...M})}else if(S instanceof Error){p=!1;const A=typeof s.error=="function"?await s.error(S):s.error,k=typeof s.description=="function"?await s.description(S):s.description,M=typeof A=="object"&&!Je.isValidElement(A)?A:{message:A};this.create({id:o,type:"error",description:k,...M})}else if(s.success!==void 0){p=!1;const A=typeof s.success=="function"?await s.success(S):s.success,k=typeof s.description=="function"?await s.description(S):s.description,M=typeof A=="object"&&!Je.isValidElement(A)?A:{message:A};this.create({id:o,type:"success",description:k,...M})}}).catch(async S=>{if(m=["reject",S],s.error!==void 0){p=!1;const j=typeof s.error=="function"?await s.error(S):s.error,A=typeof s.description=="function"?await s.description(S):s.description,T=typeof j=="object"&&!Je.isValidElement(j)?j:{message:j};this.create({id:o,type:"error",description:A,...T})}}).finally(()=>{p&&(this.dismiss(o),o=void 0),s.finally==null||s.finally.call(s)}),b=()=>new Promise((S,j)=>g.then(()=>m[0]==="reject"?j(m[1]):S(m[1])).catch(j));return typeof o!="string"&&typeof o!="number"?{unwrap:b}:Object.assign(o,{unwrap:b})},this.custom=(r,s)=>{const o=s?.id||RT++;return this.create({jsx:r(o),id:o,...s}),o},this.getActiveToasts=()=>this.toasts.filter(r=>!this.dismissedToasts.has(r.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const ca=new KW,VW=(e,r)=>{const s=r?.id||RT++;return ca.addToast({title:e,...r,id:s}),s},HW=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",GW=VW,XW=()=>ca.toasts,YW=()=>ca.getActiveToasts(),Ze=Object.assign(GW,{success:ca.success,info:ca.info,warning:ca.warning,error:ca.error,custom:ca.custom,message:ca.message,promise:ca.promise,dismiss:ca.dismiss,loading:ca.loading},{getHistory:XW,getToasts:YW});DW("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function zE(e){return e.label!==void 0}const ZW=3,WW="24px",JW="16px",RM=4e3,QW=356,eJ=14,tJ=45,nJ=200;function Wl(...e){return e.filter(Boolean).join(" ")}function rJ(e){const[r,s]=e.split("-"),o=[];return r&&o.push(r),s&&o.push(s),o}const sJ=e=>{var r,s,o,d,p,m,g,b,S;const{invert:j,toast:A,unstyled:k,interacting:T,setHeights:M,visibleToasts:I,heights:q,index:G,toasts:K,expanded:X,removeToast:L,defaultRichColors:ee,closeButton:oe,style:Q,cancelButtonStyle:ne,actionButtonStyle:de,className:je="",descriptionClassName:ve="",duration:le,position:be,gap:Ce,expandByDefault:Ke,classNames:ce,icons:re,closeButtonAriaLabel:ue="Close toast"}=e,[_e,fe]=Je.useState(null),[He,Oe]=Je.useState(null),[ke,Ve]=Je.useState(!1),[ie,De]=Je.useState(!1),[Le,tt]=Je.useState(!1),[yt,Ot]=Je.useState(!1),[Ft,kt]=Je.useState(!1),[Jt,ze]=Je.useState(0),[zt,Rt]=Je.useState(0),V=Je.useRef(A.duration||le||RM),Dn=Je.useRef(null),cn=Je.useRef(null),xe=G===0,Ne=G+1<=I,Ge=A.type,D=A.dismissible!==!1,z=A.className||"",H=A.descriptionClassName||"",Z=Je.useMemo(()=>q.findIndex(Lt=>Lt.toastId===A.id)||0,[q,A.id]),we=Je.useMemo(()=>{var Lt;return(Lt=A.closeButton)!=null?Lt:oe},[A.closeButton,oe]),Re=Je.useMemo(()=>A.duration||le||RM,[A.duration,le]),st=Je.useRef(0),Kt=Je.useRef(0),Qt=Je.useRef(0),Fn=Je.useRef(null),[dn,Ht]=be.split("-"),wi=Je.useMemo(()=>q.reduce((Lt,vr,Yr)=>Yr>=Z?Lt:Lt+vr.height,0),[q,Z]),Xr=UW(),fa=A.invert||j,uo=Ge==="loading";Kt.current=Je.useMemo(()=>Z*Ce+wi,[Z,wi]),Je.useEffect(()=>{V.current=Re},[Re]),Je.useEffect(()=>{Ve(!0)},[]),Je.useEffect(()=>{const Lt=cn.current;if(Lt){const vr=Lt.getBoundingClientRect().height;return Rt(vr),M(Yr=>[{toastId:A.id,height:vr,position:A.position},...Yr]),()=>M(Yr=>Yr.filter(Os=>Os.toastId!==A.id))}},[M,A.id]),Je.useLayoutEffect(()=>{if(!ke)return;const Lt=cn.current,vr=Lt.style.height;Lt.style.height="auto";const Yr=Lt.getBoundingClientRect().height;Lt.style.height=vr,Rt(Yr),M(Os=>Os.find(Er=>Er.toastId===A.id)?Os.map(Er=>Er.toastId===A.id?{...Er,height:Yr}:Er):[{toastId:A.id,height:Yr,position:A.position},...Os])},[ke,A.title,A.description,M,A.id,A.jsx,A.action,A.cancel]);const Ma=Je.useCallback(()=>{De(!0),ze(Kt.current),M(Lt=>Lt.filter(vr=>vr.toastId!==A.id)),setTimeout(()=>{L(A)},nJ)},[A,L,M,Kt]);Je.useEffect(()=>{if(A.promise&&Ge==="loading"||A.duration===1/0||A.type==="loading")return;let Lt;return X||T||Xr?(()=>{if(Qt.current{V.current!==1/0&&(st.current=new Date().getTime(),Lt=setTimeout(()=>{A.onAutoClose==null||A.onAutoClose.call(A,A),Ma()},V.current))})(),()=>clearTimeout(Lt)},[X,T,A,Ge,Xr,Ma]),Je.useEffect(()=>{A.delete&&(Ma(),A.onDismiss==null||A.onDismiss.call(A,A))},[Ma,A.delete]);function cc(){var Lt;if(re?.loading){var vr;return Je.createElement("div",{className:Wl(ce?.loader,A==null||(vr=A.classNames)==null?void 0:vr.loader,"sonner-loader"),"data-visible":Ge==="loading"},re.loading)}return Je.createElement(IW,{className:Wl(ce?.loader,A==null||(Lt=A.classNames)==null?void 0:Lt.loader),visible:Ge==="loading"})}const xu=A.icon||re?.[Ge]||PW(Ge);var uc,ma;return Je.createElement("li",{tabIndex:0,ref:cn,className:Wl(je,z,ce?.toast,A==null||(r=A.classNames)==null?void 0:r.toast,ce?.default,ce?.[Ge],A==null||(s=A.classNames)==null?void 0:s[Ge]),"data-sonner-toast":"","data-rich-colors":(uc=A.richColors)!=null?uc:ee,"data-styled":!(A.jsx||A.unstyled||k),"data-mounted":ke,"data-promise":!!A.promise,"data-swiped":Ft,"data-removed":ie,"data-visible":Ne,"data-y-position":dn,"data-x-position":Ht,"data-index":G,"data-front":xe,"data-swiping":Le,"data-dismissible":D,"data-type":Ge,"data-invert":fa,"data-swipe-out":yt,"data-swipe-direction":He,"data-expanded":!!(X||Ke&&ke),"data-testid":A.testId,style:{"--index":G,"--toasts-before":G,"--z-index":K.length-G,"--offset":`${ie?Jt:Kt.current}px`,"--initial-height":Ke?"auto":`${zt}px`,...Q,...A.style},onDragEnd:()=>{tt(!1),fe(null),Fn.current=null},onPointerDown:Lt=>{Lt.button!==2&&(uo||!D||(Dn.current=new Date,ze(Kt.current),Lt.target.setPointerCapture(Lt.pointerId),Lt.target.tagName!=="BUTTON"&&(tt(!0),Fn.current={x:Lt.clientX,y:Lt.clientY})))},onPointerUp:()=>{var Lt,vr,Yr;if(yt||!D)return;Fn.current=null;const Os=Number(((Lt=cn.current)==null?void 0:Lt.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Pn=Number(((vr=cn.current)==null?void 0:vr.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Er=new Date().getTime()-((Yr=Dn.current)==null?void 0:Yr.getTime()),Ys=_e==="x"?Os:Pn,ll=Math.abs(Ys)/Er;if(Math.abs(Ys)>=tJ||ll>.11){ze(Kt.current),A.onDismiss==null||A.onDismiss.call(A,A),Oe(_e==="x"?Os>0?"right":"left":Pn>0?"down":"up"),Ma(),Ot(!0);return}else{var gs,Zs;(gs=cn.current)==null||gs.style.setProperty("--swipe-amount-x","0px"),(Zs=cn.current)==null||Zs.style.setProperty("--swipe-amount-y","0px")}kt(!1),tt(!1),fe(null)},onPointerMove:Lt=>{var vr,Yr,Os;if(!Fn.current||!D||((vr=window.getSelection())==null?void 0:vr.toString().length)>0)return;const Er=Lt.clientY-Fn.current.y,Ys=Lt.clientX-Fn.current.x;var ll;const gs=(ll=e.swipeDirections)!=null?ll:rJ(be);!_e&&(Math.abs(Ys)>1||Math.abs(Er)>1)&&fe(Math.abs(Ys)>Math.abs(Er)?"x":"y");let Zs={x:0,y:0};const bu=ga=>1/(1.5+Math.abs(ga)/20);if(_e==="y"){if(gs.includes("top")||gs.includes("bottom"))if(gs.includes("top")&&Er<0||gs.includes("bottom")&&Er>0)Zs.y=Er;else{const ga=Er*bu(Er);Zs.y=Math.abs(ga)0)Zs.x=Ys;else{const ga=Ys*bu(Ys);Zs.x=Math.abs(ga)0||Math.abs(Zs.y)>0)&&kt(!0),(Yr=cn.current)==null||Yr.style.setProperty("--swipe-amount-x",`${Zs.x}px`),(Os=cn.current)==null||Os.style.setProperty("--swipe-amount-y",`${Zs.y}px`)}},we&&!A.jsx&&Ge!=="loading"?Je.createElement("button",{"aria-label":ue,"data-disabled":uo,"data-close-button":!0,onClick:uo||!D?()=>{}:()=>{Ma(),A.onDismiss==null||A.onDismiss.call(A,A)},className:Wl(ce?.closeButton,A==null||(o=A.classNames)==null?void 0:o.closeButton)},(ma=re?.close)!=null?ma:BW):null,(Ge||A.icon||A.promise)&&A.icon!==null&&(re?.[Ge]!==null||A.icon)?Je.createElement("div",{"data-icon":"",className:Wl(ce?.icon,A==null||(d=A.classNames)==null?void 0:d.icon)},A.promise||A.type==="loading"&&!A.icon?A.icon||cc():null,A.type!=="loading"?xu:null):null,Je.createElement("div",{"data-content":"",className:Wl(ce?.content,A==null||(p=A.classNames)==null?void 0:p.content)},Je.createElement("div",{"data-title":"",className:Wl(ce?.title,A==null||(m=A.classNames)==null?void 0:m.title)},A.jsx?A.jsx:typeof A.title=="function"?A.title():A.title),A.description?Je.createElement("div",{"data-description":"",className:Wl(ve,H,ce?.description,A==null||(g=A.classNames)==null?void 0:g.description)},typeof A.description=="function"?A.description():A.description):null),Je.isValidElement(A.cancel)?A.cancel:A.cancel&&zE(A.cancel)?Je.createElement("button",{"data-button":!0,"data-cancel":!0,style:A.cancelButtonStyle||ne,onClick:Lt=>{zE(A.cancel)&&D&&(A.cancel.onClick==null||A.cancel.onClick.call(A.cancel,Lt),Ma())},className:Wl(ce?.cancelButton,A==null||(b=A.classNames)==null?void 0:b.cancelButton)},A.cancel.label):null,Je.isValidElement(A.action)?A.action:A.action&&zE(A.action)?Je.createElement("button",{"data-button":!0,"data-action":!0,style:A.actionButtonStyle||de,onClick:Lt=>{zE(A.action)&&(A.action.onClick==null||A.action.onClick.call(A.action,Lt),!Lt.defaultPrevented&&Ma())},className:Wl(ce?.actionButton,A==null||(S=A.classNames)==null?void 0:S.actionButton)},A.action.label):null)};function TM(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function iJ(e,r){const s={};return[e,r].forEach((o,d)=>{const p=d===1,m=p?"--mobile-offset":"--offset",g=p?JW:WW;function b(S){["top","right","bottom","left"].forEach(j=>{s[`${m}-${j}`]=typeof S=="number"?`${S}px`:S})}typeof o=="number"||typeof o=="string"?b(o):typeof o=="object"?["top","right","bottom","left"].forEach(S=>{o[S]===void 0?s[`${m}-${S}`]=g:s[`${m}-${S}`]=typeof o[S]=="number"?`${o[S]}px`:o[S]}):b(g)}),s}const aJ=Je.forwardRef(function(r,s){const{id:o,invert:d,position:p="bottom-right",hotkey:m=["altKey","KeyT"],expand:g,closeButton:b,className:S,offset:j,mobileOffset:A,theme:k="light",richColors:T,duration:M,style:I,visibleToasts:q=ZW,toastOptions:G,dir:K=TM(),gap:X=eJ,icons:L,containerAriaLabel:ee="Notifications"}=r,[oe,Q]=Je.useState([]),ne=Je.useMemo(()=>o?oe.filter(ke=>ke.toasterId===o):oe.filter(ke=>!ke.toasterId),[oe,o]),de=Je.useMemo(()=>Array.from(new Set([p].concat(ne.filter(ke=>ke.position).map(ke=>ke.position)))),[ne,p]),[je,ve]=Je.useState([]),[le,be]=Je.useState(!1),[Ce,Ke]=Je.useState(!1),[ce,re]=Je.useState(k!=="system"?k:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),ue=Je.useRef(null),_e=m.join("+").replace(/Key/g,"").replace(/Digit/g,""),fe=Je.useRef(null),He=Je.useRef(!1),Oe=Je.useCallback(ke=>{Q(Ve=>{var ie;return(ie=Ve.find(De=>De.id===ke.id))!=null&&ie.delete||ca.dismiss(ke.id),Ve.filter(({id:De})=>De!==ke.id)})},[]);return Je.useEffect(()=>ca.subscribe(ke=>{if(ke.dismiss){requestAnimationFrame(()=>{Q(Ve=>Ve.map(ie=>ie.id===ke.id?{...ie,delete:!0}:ie))});return}setTimeout(()=>{B3.flushSync(()=>{Q(Ve=>{const ie=Ve.findIndex(De=>De.id===ke.id);return ie!==-1?[...Ve.slice(0,ie),{...Ve[ie],...ke},...Ve.slice(ie+1)]:[ke,...Ve]})})})}),[oe]),Je.useEffect(()=>{if(k!=="system"){re(k);return}if(k==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?re("dark"):re("light")),typeof window>"u")return;const ke=window.matchMedia("(prefers-color-scheme: dark)");try{ke.addEventListener("change",({matches:Ve})=>{re(Ve?"dark":"light")})}catch{ke.addListener(({matches:ie})=>{try{re(ie?"dark":"light")}catch(De){console.error(De)}})}},[k]),Je.useEffect(()=>{oe.length<=1&&be(!1)},[oe]),Je.useEffect(()=>{const ke=Ve=>{var ie;if(m.every(tt=>Ve[tt]||Ve.code===tt)){var Le;be(!0),(Le=ue.current)==null||Le.focus()}Ve.code==="Escape"&&(document.activeElement===ue.current||(ie=ue.current)!=null&&ie.contains(document.activeElement))&&be(!1)};return document.addEventListener("keydown",ke),()=>document.removeEventListener("keydown",ke)},[m]),Je.useEffect(()=>{if(ue.current)return()=>{fe.current&&(fe.current.focus({preventScroll:!0}),fe.current=null,He.current=!1)}},[ue.current]),Je.createElement("section",{ref:s,"aria-label":`${ee} ${_e}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},de.map((ke,Ve)=>{var ie;const[De,Le]=ke.split("-");return ne.length?Je.createElement("ol",{key:ke,dir:K==="auto"?TM():K,tabIndex:-1,ref:ue,className:S,"data-sonner-toaster":!0,"data-sonner-theme":ce,"data-y-position":De,"data-x-position":Le,style:{"--front-toast-height":`${((ie=je[0])==null?void 0:ie.height)||0}px`,"--width":`${QW}px`,"--gap":`${X}px`,...I,...iJ(j,A)},onBlur:tt=>{He.current&&!tt.currentTarget.contains(tt.relatedTarget)&&(He.current=!1,fe.current&&(fe.current.focus({preventScroll:!0}),fe.current=null))},onFocus:tt=>{tt.target instanceof HTMLElement&&tt.target.dataset.dismissible==="false"||He.current||(He.current=!0,fe.current=tt.relatedTarget)},onMouseEnter:()=>be(!0),onMouseMove:()=>be(!0),onMouseLeave:()=>{Ce||be(!1)},onDragEnd:()=>be(!1),onPointerDown:tt=>{tt.target instanceof HTMLElement&&tt.target.dataset.dismissible==="false"||Ke(!0)},onPointerUp:()=>Ke(!1)},ne.filter(tt=>!tt.position&&Ve===0||tt.position===ke).map((tt,yt)=>{var Ot,Ft;return Je.createElement(sJ,{key:tt.id,icons:L,index:yt,toast:tt,defaultRichColors:T,duration:(Ot=G?.duration)!=null?Ot:M,className:G?.className,descriptionClassName:G?.descriptionClassName,invert:d,visibleToasts:q,closeButton:(Ft=G?.closeButton)!=null?Ft:b,interacting:Ce,position:ke,style:G?.style,unstyled:G?.unstyled,classNames:G?.classNames,cancelButtonStyle:G?.cancelButtonStyle,actionButtonStyle:G?.actionButtonStyle,closeButtonAriaLabel:G?.closeButtonAriaLabel,removeToast:Oe,toasts:ne.filter(kt=>kt.position==tt.position),heights:je.filter(kt=>kt.position==tt.position),setHeights:ve,expandByDefault:g,gap:X,expanded:le,swipeDirections:r.swipeDirections})})):null}))}),oJ=({...e})=>{const{theme:r="system"}=N_();return u.jsx(aJ,{theme:r,className:"toaster group",icons:{success:u.jsx(L_,{className:"size-4"}),info:u.jsx(oL,{className:"size-4"}),warning:u.jsx(kj,{className:"size-4"}),error:u.jsx(hW,{className:"size-4"}),loading:u.jsx(Ds,{className:"size-4 animate-spin"})},style:{"--normal-bg":"var(--popover)","--normal-text":"var(--popover-foreground)","--normal-border":"var(--border)","--border-radius":"var(--radius)"},...e})},lJ=new JY,cJ=({children:e})=>u.jsx(QY,{client:lJ,children:u.jsxs(RY,{defaultTheme:"system",storageKey:"dragon-theme",children:[e,u.jsx(oJ,{richColors:!0,expand:!0,position:"top-center"})]})});var RR={exports:{}},rb={},TR={exports:{}},_R={};var _M;function uJ(){return _M||(_M=1,(function(e){function r(ce,re){var ue=ce.length;ce.push(re);e:for(;0>>1,fe=ce[_e];if(0>>1;_ed(ke,ue))Ved(ie,ke)?(ce[_e]=ie,ce[Ve]=ue,_e=Ve):(ce[_e]=ke,ce[Oe]=ue,_e=Oe);else if(Ved(ie,ue))ce[_e]=ie,ce[Ve]=ue,_e=Ve;else break e}}return re}function d(ce,re){var ue=ce.sortIndex-re.sortIndex;return ue!==0?ue:ce.id-re.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var p=performance;e.unstable_now=function(){return p.now()}}else{var m=Date,g=m.now();e.unstable_now=function(){return m.now()-g}}var b=[],S=[],j=1,A=null,k=3,T=!1,M=!1,I=!1,q=!1,G=typeof setTimeout=="function"?setTimeout:null,K=typeof clearTimeout=="function"?clearTimeout:null,X=typeof setImmediate<"u"?setImmediate:null;function L(ce){for(var re=s(S);re!==null;){if(re.callback===null)o(S);else if(re.startTime<=ce)o(S),re.sortIndex=re.expirationTime,r(b,re);else break;re=s(S)}}function ee(ce){if(I=!1,L(ce),!M)if(s(b)!==null)M=!0,oe||(oe=!0,le());else{var re=s(S);re!==null&&Ke(ee,re.startTime-ce)}}var oe=!1,Q=-1,ne=5,de=-1;function je(){return q?!0:!(e.unstable_now()-dece&&je());){var _e=A.callback;if(typeof _e=="function"){A.callback=null,k=A.priorityLevel;var fe=_e(A.expirationTime<=ce);if(ce=e.unstable_now(),typeof fe=="function"){A.callback=fe,L(ce),re=!0;break t}A===s(b)&&o(b),L(ce)}else o(b);A=s(b)}if(A!==null)re=!0;else{var He=s(S);He!==null&&Ke(ee,He.startTime-ce),re=!1}}break e}finally{A=null,k=ue,T=!1}re=void 0}}finally{re?le():oe=!1}}}var le;if(typeof X=="function")le=function(){X(ve)};else if(typeof MessageChannel<"u"){var be=new MessageChannel,Ce=be.port2;be.port1.onmessage=ve,le=function(){Ce.postMessage(null)}}else le=function(){G(ve,0)};function Ke(ce,re){Q=G(function(){ce(e.unstable_now())},re)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(ce){ce.callback=null},e.unstable_forceFrameRate=function(ce){0>ce||125_e?(ce.sortIndex=ue,r(S,ce),s(b)===null&&ce===s(S)&&(I?(K(Q),Q=-1):I=!0,Ke(ee,ue-_e))):(ce.sortIndex=fe,r(b,ce),M||T||(M=!0,oe||(oe=!0,le()))),ce},e.unstable_shouldYield=je,e.unstable_wrapCallback=function(ce){var re=k;return function(){var ue=k;k=re;try{return ce.apply(this,arguments)}finally{k=ue}}}})(_R)),_R}var $M;function dJ(){return $M||($M=1,TR.exports=uJ()),TR.exports}var NM;function hJ(){if(NM)return rb;NM=1;var e=dJ(),r=U3(),s=pY();function o(a){var c="https://react.dev/errors/"+a;if(1fe||(a.current=_e[fe],_e[fe]=null,fe--)}function ke(a,c){fe++,_e[fe]=a.current,a.current=c}var Ve=He(null),ie=He(null),De=He(null),Le=He(null);function tt(a,c){switch(ke(De,c),ke(ie,a),ke(Ve,null),c.nodeType){case 9:case 11:a=(a=c.documentElement)&&(a=a.namespaceURI)?gd(a):0;break;default:if(a=c.tagName,c=c.namespaceURI)c=gd(c),a=qh(c,a);else switch(a){case"svg":a=1;break;case"math":a=2;break;default:a=0}}Oe(Ve),ke(Ve,a)}function yt(){Oe(Ve),Oe(ie),Oe(De)}function Ot(a){a.memoizedState!==null&&ke(Le,a);var c=Ve.current,f=qh(c,a.type);c!==f&&(ke(ie,a),ke(Ve,f))}function Ft(a){ie.current===a&&(Oe(Ve),Oe(ie)),Le.current===a&&(Oe(Le),bd._currentValue=ue)}var kt,Jt;function ze(a){if(kt===void 0)try{throw Error()}catch(f){var c=f.stack.trim().match(/\n( *(at )?)/);kt=c&&c[1]||"",Jt=-1)":-1E||ye[y]!==Be[E]){var We=` -`+ye[y].replace(" at new "," at ");return a.displayName&&We.includes("")&&(We=We.replace("",a.displayName)),We}while(1<=y&&0<=E);break}}}finally{zt=!1,Error.prepareStackTrace=f}return(f=a?a.displayName||a.name:"")?ze(f):""}function V(a,c){switch(a.tag){case 26:case 27:case 5:return ze(a.type);case 16:return ze("Lazy");case 13:return a.child!==c&&c!==null?ze("Suspense Fallback"):ze("Suspense");case 19:return ze("SuspenseList");case 0:case 15:return Rt(a.type,!1);case 11:return Rt(a.type.render,!1);case 1:return Rt(a.type,!0);case 31:return ze("Activity");default:return""}}function Dn(a){try{var c="",f=null;do c+=V(a,f),f=a,a=a.return;while(a);return c}catch(y){return` -Error generating stack: `+y.message+` -`+y.stack}}var cn=Object.prototype.hasOwnProperty,xe=e.unstable_scheduleCallback,Ne=e.unstable_cancelCallback,Ge=e.unstable_shouldYield,D=e.unstable_requestPaint,z=e.unstable_now,H=e.unstable_getCurrentPriorityLevel,Z=e.unstable_ImmediatePriority,we=e.unstable_UserBlockingPriority,Re=e.unstable_NormalPriority,st=e.unstable_LowPriority,Kt=e.unstable_IdlePriority,Qt=e.log,Fn=e.unstable_setDisableYieldValue,dn=null,Ht=null;function wi(a){if(typeof Qt=="function"&&Fn(a),Ht&&typeof Ht.setStrictMode=="function")try{Ht.setStrictMode(dn,a)}catch{}}var Xr=Math.clz32?Math.clz32:Ma,fa=Math.log,uo=Math.LN2;function Ma(a){return a>>>=0,a===0?32:31-(fa(a)/uo|0)|0}var cc=256,xu=262144,uc=4194304;function ma(a){var c=a&42;if(c!==0)return c;switch(a&-a){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return a&261888;case 262144:case 524288:case 1048576:case 2097152:return a&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return a&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return a}}function Lt(a,c,f){var y=a.pendingLanes;if(y===0)return 0;var E=0,O=a.suspendedLanes,B=a.pingedLanes;a=a.warmLanes;var te=y&134217727;return te!==0?(y=te&~O,y!==0?E=ma(y):(B&=te,B!==0?E=ma(B):f||(f=te&~a,f!==0&&(E=ma(f))))):(te=y&~O,te!==0?E=ma(te):B!==0?E=ma(B):f||(f=y&~a,f!==0&&(E=ma(f)))),E===0?0:c!==0&&c!==E&&(c&O)===0&&(O=E&-E,f=c&-c,O>=f||O===32&&(f&4194048)!==0)?c:E}function vr(a,c){return(a.pendingLanes&~(a.suspendedLanes&~a.pingedLanes)&c)===0}function Yr(a,c){switch(a){case 1:case 2:case 4:case 8:case 64:return c+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return c+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Os(){var a=uc;return uc<<=1,(uc&62914560)===0&&(uc=4194304),a}function Pn(a){for(var c=[],f=0;31>f;f++)c.push(a);return c}function Er(a,c){a.pendingLanes|=c,c!==268435456&&(a.suspendedLanes=0,a.pingedLanes=0,a.warmLanes=0)}function Ys(a,c,f,y,E,O){var B=a.pendingLanes;a.pendingLanes=f,a.suspendedLanes=0,a.pingedLanes=0,a.warmLanes=0,a.expiredLanes&=f,a.entangledLanes&=f,a.errorRecoveryDisabledLanes&=f,a.shellSuspendCounter=0;var te=a.entanglements,ye=a.expirationTimes,Be=a.hiddenUpdates;for(f=B&~f;0"u")return null;try{return a.activeElement||a.body}catch{return a.body}}var th=/[\n"\\]/g;function Js(a){return a.replace(th,function(c){return"\\"+c.charCodeAt(0).toString(16)+" "})}function Lp(a,c,f,y,E,O,B,te){a.name="",B!=null&&typeof B!="function"&&typeof B!="symbol"&&typeof B!="boolean"?a.type=B:a.removeAttribute("type"),c!=null?B==="number"?(c===0&&a.value===""||a.value!=c)&&(a.value=""+Ws(c)):a.value!==""+Ws(c)&&(a.value=""+Ws(c)):B!=="submit"&&B!=="reset"||a.removeAttribute("value"),c!=null?zp(a,B,Ws(c)):f!=null?zp(a,B,Ws(f)):y!=null&&a.removeAttribute("value"),E==null&&O!=null&&(a.defaultChecked=!!O),E!=null&&(a.checked=E&&typeof E!="function"&&typeof E!="symbol"),te!=null&&typeof te!="function"&&typeof te!="symbol"&&typeof te!="boolean"?a.name=""+Ws(te):a.removeAttribute("name")}function qg(a,c,f,y,E,O,B,te){if(O!=null&&typeof O!="function"&&typeof O!="symbol"&&typeof O!="boolean"&&(a.type=O),c!=null||f!=null){if(!(O!=="submit"&&O!=="reset"||c!=null)){ho(a);return}f=f!=null?""+Ws(f):"",c=c!=null?""+Ws(c):f,te||c===a.value||(a.value=c),a.defaultValue=c}y=y??E,y=typeof y!="function"&&typeof y!="symbol"&&!!y,a.checked=te?a.checked:!!y,a.defaultChecked=!!y,B!=null&&typeof B!="function"&&typeof B!="symbol"&&typeof B!="boolean"&&(a.name=B),ho(a)}function zp(a,c,f){c==="number"&&hl(a.ownerDocument)===a||a.defaultValue===""+f||(a.defaultValue=""+f)}function Au(a,c,f,y){if(a=a.options,c){c={};for(var E=0;E"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Bp=!1;if(ar)try{var po={};Object.defineProperty(po,"passive",{get:function(){Bp=!0}}),window.addEventListener("test",po,po),window.removeEventListener("test",po,po)}catch{Bp=!1}var Rr=null,sh=null,Tu=null;function jw(){if(Tu)return Tu;var a,c=sh,f=c.length,y,E="value"in Rr?Rr.value:Rr.textContent,O=E.length;for(a=0;a=ba),Bw=" ",Zg=!1;function Uw(a,c){switch(a){case"keyup":return qw.indexOf(c.keyCode)!==-1;case"keydown":return c.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Wg(a){return a=a.detail,typeof a=="object"&&"data"in a?a.data:null}var yc=!1;function Nu(a,c){switch(a){case"compositionend":return Wg(c);case"keypress":return c.which!==32?null:(Zg=!0,Bw);case"textInput":return a=c.data,a===Bw&&Zg?null:a;default:return null}}function cA(a,c){if(yc)return a==="compositionend"||!Gi&&Uw(a,c)?(a=jw(),Tu=sh=Rr=null,yc=!1,a):null;switch(a){case"paste":return null;case"keypress":if(!(c.ctrlKey||c.altKey||c.metaKey)||c.ctrlKey&&c.altKey){if(c.char&&1=c)return{node:f,offset:c-a};a=y}e:{for(;f;){if(f.nextSibling){f=f.nextSibling;break e}f=f.parentNode}f=void 0}f=Yw(f)}}function Ww(a,c){return a&&c?a===c?!0:a&&a.nodeType===3?!1:c&&c.nodeType===3?Ww(a,c.parentNode):"contains"in a?a.contains(c):a.compareDocumentPosition?!!(a.compareDocumentPosition(c)&16):!1:!1}function Jw(a){a=a!=null&&a.ownerDocument!=null&&a.ownerDocument.defaultView!=null?a.ownerDocument.defaultView:window;for(var c=hl(a.document);c instanceof a.HTMLIFrameElement;){try{var f=typeof c.contentWindow.location.href=="string"}catch{f=!1}if(f)a=c.contentWindow;else break;c=hl(a.document)}return c}function Qg(a){var c=a&&a.nodeName&&a.nodeName.toLowerCase();return c&&(c==="input"&&(a.type==="text"||a.type==="search"||a.type==="tel"||a.type==="url"||a.type==="password")||c==="textarea"||a.contentEditable==="true")}var Qw=ar&&"documentMode"in document&&11>=document.documentMode,fl=null,Lu=null,go=null,Xp=!1;function ey(a,c,f){var y=f.window===f?f.document:f.nodeType===9?f:f.ownerDocument;Xp||fl==null||fl!==hl(y)||(y=fl,"selectionStart"in y&&Qg(y)?y={start:y.selectionStart,end:y.selectionEnd}:(y=(y.ownerDocument&&y.ownerDocument.defaultView||window).getSelection(),y={anchorNode:y.anchorNode,anchorOffset:y.anchorOffset,focusNode:y.focusNode,focusOffset:y.focusOffset}),go&&Iu(go,y)||(go=y,y=Yf(Lu,"onSelect"),0>=B,E-=B,Kn=1<<32-Xr(c)+E|f<rn?(wn=Pt,Pt=null):wn=Pt.sibling;var On=Ue($e,Pt,Pe[rn],nt);if(On===null){Pt===null&&(Pt=wn);break}a&&Pt&&On.alternate===null&&c($e,Pt),Ee=O(On,Ee,rn),pn===null?Ut=On:pn.sibling=On,pn=On,Pt=wn}if(rn===Pe.length)return f($e,Pt),vn&&ii($e,rn),Ut;if(Pt===null){for(;rnrn?(wn=Pt,Pt=null):wn=Pt.sibling;var Bl=Ue($e,Pt,On.value,nt);if(Bl===null){Pt===null&&(Pt=wn);break}a&&Pt&&Bl.alternate===null&&c($e,Pt),Ee=O(Bl,Ee,rn),pn===null?Ut=Bl:pn.sibling=Bl,pn=Bl,Pt=wn}if(On.done)return f($e,Pt),vn&&ii($e,rn),Ut;if(Pt===null){for(;!On.done;rn++,On=Pe.next())On=rt($e,On.value,nt),On!==null&&(Ee=O(On,Ee,rn),pn===null?Ut=On:pn.sibling=On,pn=On);return vn&&ii($e,rn),Ut}for(Pt=y(Pt);!On.done;rn++,On=Pe.next())On=Xe(Pt,$e,rn,On.value,nt),On!==null&&(a&&On.alternate!==null&&Pt.delete(On.key===null?rn:On.key),Ee=O(On,Ee,rn),pn===null?Ut=On:pn.sibling=On,pn=On);return a&&Pt.forEach(function(HS){return c($e,HS)}),vn&&ii($e,rn),Ut}function Qn($e,Ee,Pe,nt){if(typeof Pe=="object"&&Pe!==null&&Pe.type===I&&Pe.key===null&&(Pe=Pe.props.children),typeof Pe=="object"&&Pe!==null){switch(Pe.$$typeof){case T:e:{for(var Ut=Pe.key;Ee!==null;){if(Ee.key===Ut){if(Ut=Pe.type,Ut===I){if(Ee.tag===7){f($e,Ee.sibling),nt=E(Ee,Pe.props.children),nt.return=$e,$e=nt;break e}}else if(Ee.elementType===Ut||typeof Ut=="object"&&Ut!==null&&Ut.$$typeof===ne&&kc(Ut)===Ee.type){f($e,Ee.sibling),nt=E(Ee,Pe.props),ks(nt,Pe),nt.return=$e,$e=nt;break e}f($e,Ee);break}else c($e,Ee);Ee=Ee.sibling}Pe.type===I?(nt=gl(Pe.props.children,$e.mode,nt,Pe.key),nt.return=$e,$e=nt):(nt=Bu(Pe.type,Pe.key,Pe.props,null,$e.mode,nt),ks(nt,Pe),nt.return=$e,$e=nt)}return B($e);case M:e:{for(Ut=Pe.key;Ee!==null;){if(Ee.key===Ut)if(Ee.tag===4&&Ee.stateNode.containerInfo===Pe.containerInfo&&Ee.stateNode.implementation===Pe.implementation){f($e,Ee.sibling),nt=E(Ee,Pe.children||[]),nt.return=$e,$e=nt;break e}else{f($e,Ee);break}else c($e,Ee);Ee=Ee.sibling}nt=dy(Pe,$e.mode,nt),nt.return=$e,$e=nt}return B($e);case ne:return Pe=kc(Pe),Qn($e,Ee,Pe,nt)}if(Ke(Pe))return Dt($e,Ee,Pe,nt);if(le(Pe)){if(Ut=le(Pe),typeof Ut!="function")throw Error(o(150));return Pe=Ut.call(Pe),Xt($e,Ee,Pe,nt)}if(typeof Pe.then=="function")return Qn($e,Ee,Wu(Pe),nt);if(Pe.$$typeof===X)return Qn($e,Ee,Hu($e,Pe),nt);Ju($e,Pe)}return typeof Pe=="string"&&Pe!==""||typeof Pe=="number"||typeof Pe=="bigint"?(Pe=""+Pe,Ee!==null&&Ee.tag===6?(f($e,Ee.sibling),nt=E(Ee,Pe),nt.return=$e,$e=nt):(f($e,Ee),nt=Uu(Pe,$e.mode,nt),nt.return=$e,$e=nt),B($e)):f($e,Ee)}return function($e,Ee,Pe,nt){try{Tc=0;var Ut=Qn($e,Ee,Pe,nt);return Zu=null,Ut}catch(Pt){if(Pt===Oc||Pt===Yu)throw Pt;var pn=ti(29,Pt,null,$e.mode);return pn.lanes=nt,pn.return=$e,pn}finally{}}}var _c=So(!0),hh=So(!1),li=!1;function df(a){a.updateQueue={baseState:a.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function hf(a,c){a=a.updateQueue,c.updateQueue===a&&(c.updateQueue={baseState:a.baseState,firstBaseUpdate:a.firstBaseUpdate,lastBaseUpdate:a.lastBaseUpdate,shared:a.shared,callbacks:null})}function Eo(a){return{lane:a,tag:0,payload:null,callback:null,next:null}}function jl(a,c,f){var y=a.updateQueue;if(y===null)return null;if(y=y.shared,(Hn&2)!==0){var E=y.pending;return E===null?c.next=c:(c.next=E.next,E.next=c),y.pending=c,c=Jp(a),t0(a,null,f),c}return Wp(a,y,c,f),Jp(a)}function Ji(a,c,f){if(c=c.updateQueue,c!==null&&(c=c.shared,(f&4194048)!==0)){var y=c.lanes;y&=a.pendingLanes,f|=y,c.lanes=f,gs(a,f)}}function Qu(a,c){var f=a.updateQueue,y=a.alternate;if(y!==null&&(y=y.updateQueue,f===y)){var E=null,O=null;if(f=f.firstBaseUpdate,f!==null){do{var B={lane:f.lane,tag:f.tag,payload:f.payload,callback:null,next:null};O===null?E=O=B:O=O.next=B,f=f.next}while(f!==null);O===null?E=O=c:O=O.next=c}else E=O=c;f={baseState:y.baseState,firstBaseUpdate:E,lastBaseUpdate:O,shared:y.shared,callbacks:y.callbacks},a.updateQueue=f;return}a=f.lastBaseUpdate,a===null?f.firstBaseUpdate=c:a.next=c,f.lastBaseUpdate=c}var $c=!1;function ph(){if($c){var a=qa;if(a!==null)throw a}}function fh(a,c,f,y){$c=!1;var E=a.updateQueue;li=!1;var O=E.firstBaseUpdate,B=E.lastBaseUpdate,te=E.shared.pending;if(te!==null){E.shared.pending=null;var ye=te,Be=ye.next;ye.next=null,B===null?O=Be:B.next=Be,B=ye;var We=a.alternate;We!==null&&(We=We.updateQueue,te=We.lastBaseUpdate,te!==B&&(te===null?We.firstBaseUpdate=Be:te.next=Be,We.lastBaseUpdate=ye))}if(O!==null){var rt=E.baseState;B=0,We=Be=ye=null,te=O;do{var Ue=te.lane&-536870913,Xe=Ue!==te.lane;if(Xe?(An&Ue)===Ue:(y&Ue)===Ue){Ue!==0&&Ue===Sl&&($c=!0),We!==null&&(We=We.next={lane:0,tag:te.tag,payload:te.payload,callback:null,next:null});e:{var Dt=a,Xt=te;Ue=c;var Qn=f;switch(Xt.tag){case 1:if(Dt=Xt.payload,typeof Dt=="function"){rt=Dt.call(Qn,rt,Ue);break e}rt=Dt;break e;case 3:Dt.flags=Dt.flags&-65537|128;case 0:if(Dt=Xt.payload,Ue=typeof Dt=="function"?Dt.call(Qn,rt,Ue):Dt,Ue==null)break e;rt=A({},rt,Ue);break e;case 2:li=!0}}Ue=te.callback,Ue!==null&&(a.flags|=64,Xe&&(a.flags|=8192),Xe=E.callbacks,Xe===null?E.callbacks=[Ue]:Xe.push(Ue))}else Xe={lane:Ue,tag:te.tag,payload:te.payload,callback:te.callback,next:null},We===null?(Be=We=Xe,ye=rt):We=We.next=Xe,B|=Ue;if(te=te.next,te===null){if(te=E.shared.pending,te===null)break;Xe=te,te=Xe.next,Xe.next=null,E.lastBaseUpdate=Xe,E.shared.pending=null}}while(!0);We===null&&(ye=rt),E.baseState=ye,E.firstBaseUpdate=Be,E.lastBaseUpdate=We,O===null&&(E.shared.lanes=0),Ga|=B,a.lanes=B,a.memoizedState=rt}}function pf(a,c){if(typeof a!="function")throw Error(o(191,a));a.call(c)}function o0(a,c){var f=a.callbacks;if(f!==null)for(a.callbacks=null,a=0;aO?O:8;var B=ce.T,te={};ce.T=te,Yy(a,!1,c,f);try{var ye=E(),Be=ce.S;if(Be!==null&&Be(te,ye),ye!==null&&typeof ye=="object"&&typeof ye.then=="function"){var We=sf(ye,y);wh(a,c,We,ki(a))}else wh(a,c,y,ki(a))}catch(rt){wh(a,c,{then:function(){},status:"rejected",reason:rt},ki())}finally{re.p=O,B!==null&&te.types!==null&&(B.types=te.types),ce.T=B}}function yA(){}function Vy(a,c,f,y){if(a.tag!==5)throw Error(o(476));var E=Hy(a).queue;w0(a,E,c,ue,f===null?yA:function(){return Gy(a),f(y)})}function Hy(a){var c=a.memoizedState;if(c!==null)return c;c={memoizedState:ue,baseState:ue,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ta,lastRenderedState:ue},next:null};var f={};return c.next={memoizedState:f,baseState:f,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ta,lastRenderedState:f},next:null},a.memoizedState=c,a=a.alternate,a!==null&&(a.memoizedState=c),c}function Gy(a){var c=Hy(a);c.next===null&&(c=a.alternate.memoizedState),wh(a,c.next.queue,{},ki())}function bh(){return Wr(bd)}function S0(){return Mr().memoizedState}function Xy(){return Mr().memoizedState}function vA(a){for(var c=a.return;c!==null;){switch(c.tag){case 24:case 3:var f=ki();a=Eo(f);var y=jl(c,a,f);y!==null&&(_s(y,c,f),Ji(y,c,f)),c={cache:rf()},a.payload=c;return}c=c.return}}function E0(a,c,f){var y=ki();f={lane:y,revertLane:0,gesture:null,action:f,hasEagerState:!1,eagerState:null,next:null},xf(a)?C0(c,f):(f=cy(a,c,f,y),f!==null&&(_s(f,a,y),A0(f,c,y)))}function j0(a,c,f){var y=ki();wh(a,c,f,y)}function wh(a,c,f,y){var E={lane:y,revertLane:0,gesture:null,action:f,hasEagerState:!1,eagerState:null,next:null};if(xf(a))C0(c,E);else{var O=a.alternate;if(a.lanes===0&&(O===null||O.lanes===0)&&(O=c.lastRenderedReducer,O!==null))try{var B=c.lastRenderedState,te=O(B,f);if(E.hasEagerState=!0,E.eagerState=te,ei(te,B))return Wp(a,c,E,0),lr===null&&Zp(),!1}catch{}finally{}if(f=cy(a,c,E,y),f!==null)return _s(f,a,y),A0(f,c,y),!0}return!1}function Yy(a,c,f,y){if(y={lane:2,revertLane:Nv(),gesture:null,action:y,hasEagerState:!1,eagerState:null,next:null},xf(a)){if(c)throw Error(o(479))}else c=cy(a,f,y,2),c!==null&&_s(c,a,2)}function xf(a){var c=a.alternate;return a===en||c!==null&&c===en}function C0(a,c){Nc=mh=!0;var f=a.pending;f===null?c.next=c:(c.next=f.next,f.next=c),a.pending=c}function A0(a,c,f){if((f&4194048)!==0){var y=c.lanes;y&=a.pendingLanes,f|=y,c.lanes=f,gs(a,f)}}var Sh={readContext:Wr,use:mf,useCallback:Cr,useContext:Cr,useEffect:Cr,useImperativeHandle:Cr,useLayoutEffect:Cr,useInsertionEffect:Cr,useMemo:Cr,useReducer:Cr,useRef:Cr,useState:Cr,useDebugValue:Cr,useDeferredValue:Cr,useTransition:Cr,useSyncExternalStore:Cr,useId:Cr,useHostTransitionStatus:Cr,useFormState:Cr,useActionState:Cr,useOptimistic:Cr,useMemoCache:Cr,useCacheRefresh:Cr};Sh.useEffectEvent=Cr;var O0={readContext:Wr,use:mf,useCallback:function(a,c){return Rs().memoizedState=[a,c===void 0?null:c],a},useContext:Wr,useEffect:zy,useImperativeHandle:function(a,c,f){f=f!=null?f.concat([a]):null,xh(4194308,4,x0.bind(null,c,a),f)},useLayoutEffect:function(a,c){return xh(4194308,4,a,c)},useInsertionEffect:function(a,c){xh(4,2,a,c)},useMemo:function(a,c){var f=Rs();c=c===void 0?null:c;var y=a();if(jo){wi(!0);try{a()}finally{wi(!1)}}return f.memoizedState=[y,c],y},useReducer:function(a,c,f){var y=Rs();if(f!==void 0){var E=f(c);if(jo){wi(!0);try{f(c)}finally{wi(!1)}}}else E=c;return y.memoizedState=y.baseState=E,a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:a,lastRenderedState:E},y.queue=a,a=a.dispatch=E0.bind(null,en,a),[y.memoizedState,a]},useRef:function(a){var c=Rs();return a={current:a},c.memoizedState=a},useState:function(a){a=Ny(a);var c=a.queue,f=j0.bind(null,en,c);return c.dispatch=f,[a.memoizedState,f]},useDebugValue:qy,useDeferredValue:function(a,c){var f=Rs();return Ky(f,a,c)},useTransition:function(){var a=Ny(!1);return a=w0.bind(null,en,a.queue,!0,!1),Rs().memoizedState=a,[!1,a]},useSyncExternalStore:function(a,c,f){var y=en,E=Rs();if(vn){if(f===void 0)throw Error(o(407));f=f()}else{if(f=c(),lr===null)throw Error(o(349));(An&127)!==0||Ry(y,c,f)}E.memoizedState=f;var O={value:f,getSnapshot:c};return E.queue=O,zy(u0.bind(null,y,O,a),[a]),y.flags|=2048,id(9,{destroy:void 0},Ty.bind(null,y,O,f,c),null),f},useId:function(){var a=Rs(),c=lr.identifierPrefix;if(vn){var f=La,y=Kn;f=(y&~(1<<32-Xr(y)-1)).toString(32)+f,c="_"+c+"R_"+f,f=gh++,0<\/script>",O=O.removeChild(O.firstChild);break;case"select":O=typeof y.is=="string"?B.createElement("select",{is:y.is}):B.createElement("select"),y.multiple?O.multiple=!0:y.size&&(O.size=y.size);break;default:O=typeof y.is=="string"?B.createElement(E,{is:y.is}):B.createElement(E)}}O[ss]=c,O[Ps]=y;e:for(B=c.child;B!==null;){if(B.tag===5||B.tag===6)O.appendChild(B.stateNode);else if(B.tag!==4&&B.tag!==27&&B.child!==null){B.child.return=B,B=B.child;continue}if(B===c)break e;for(;B.sibling===null;){if(B.return===null||B.return===c)break e;B=B.return}B.sibling.return=B.return,B=B.sibling}c.stateNode=O;e:switch(vs(O,E,y),E){case"button":case"input":case"select":case"textarea":y=!!y.autoFocus;break e;case"img":y=!0;break e;default:y=!1}y&&Oo(c)}}return or(c),cv(c,c.type,a===null?null:a.memoizedProps,c.pendingProps,f),null;case 6:if(a&&c.stateNode!=null)a.memoizedProps!==y&&Oo(c);else{if(typeof y!="string"&&c.stateNode===null)throw Error(o(166));if(a=De.current,Vu(c)){if(a=c.stateNode,f=c.memoizedProps,y=null,E=Fr,E!==null)switch(E.tag){case 27:case 5:y=E.memoizedProps}a[ss]=c,a=!!(a.nodeValue===f||y!==null&&y.suppressHydrationWarning===!0||zh(a.nodeValue,f)),a||xl(c,!0)}else a=qc(a).createTextNode(y),a[ss]=c,c.stateNode=a}return or(c),null;case 31:if(f=c.memoizedState,a===null||a.memoizedState!==null){if(y=Vu(c),f!==null){if(a===null){if(!y)throw Error(o(318));if(a=c.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(o(557));a[ss]=c}else za(),(c.flags&128)===0&&(c.memoizedState=null),c.flags|=4;or(c),a=!1}else f=py(),a!==null&&a.memoizedState!==null&&(a.memoizedState.hydrationErrors=f),a=!0;if(!a)return c.flags&256?(Is(c),c):(Is(c),null);if((c.flags&128)!==0)throw Error(o(558))}return or(c),null;case 13:if(y=c.memoizedState,a===null||a.memoizedState!==null&&a.memoizedState.dehydrated!==null){if(E=Vu(c),y!==null&&y.dehydrated!==null){if(a===null){if(!E)throw Error(o(318));if(E=c.memoizedState,E=E!==null?E.dehydrated:null,!E)throw Error(o(317));E[ss]=c}else za(),(c.flags&128)===0&&(c.memoizedState=null),c.flags|=4;or(c),E=!1}else E=py(),a!==null&&a.memoizedState!==null&&(a.memoizedState.hydrationErrors=E),E=!0;if(!E)return c.flags&256?(Is(c),c):(Is(c),null)}return Is(c),(c.flags&128)!==0?(c.lanes=f,c):(f=y!==null,a=a!==null&&a.memoizedState!==null,f&&(y=c.child,E=null,y.alternate!==null&&y.alternate.memoizedState!==null&&y.alternate.memoizedState.cachePool!==null&&(E=y.alternate.memoizedState.cachePool.pool),O=null,y.memoizedState!==null&&y.memoizedState.cachePool!==null&&(O=y.memoizedState.cachePool.pool),O!==E&&(y.flags|=2048)),f!==a&&f&&(c.child.flags|=8192),Of(c,c.updateQueue),or(c),null);case 4:return yt(),a===null&&Xf(c.stateNode.containerInfo),or(c),null;case 10:return oi(c.type),or(c),null;case 19:if(Oe(jr),y=c.memoizedState,y===null)return or(c),null;if(E=(c.flags&128)!==0,O=y.rendering,O===null)if(E)ld(y,!1);else{if(Ar!==0||a!==null&&(a.flags&128)!==0)for(a=c.child;a!==null;){if(O=ff(a),O!==null){for(c.flags|=128,ld(y,!1),a=O.updateQueue,c.updateQueue=a,Of(c,a),c.subtreeFlags=0,a=f,f=c.child;f!==null;)uy(f,a),f=f.sibling;return ke(jr,jr.current&1|2),vn&&ii(c,y.treeForkCount),c.child}a=a.sibling}y.tail!==null&&z()>Df&&(c.flags|=128,E=!0,ld(y,!1),c.lanes=4194304)}else{if(!E)if(a=ff(O),a!==null){if(c.flags|=128,E=!0,a=a.updateQueue,c.updateQueue=a,Of(c,a),ld(y,!0),y.tail===null&&y.tailMode==="hidden"&&!O.alternate&&!vn)return or(c),null}else 2*z()-y.renderingStartTime>Df&&f!==536870912&&(c.flags|=128,E=!0,ld(y,!1),c.lanes=4194304);y.isBackwards?(O.sibling=c.child,c.child=O):(a=y.last,a!==null?a.sibling=O:c.child=O,y.last=O)}return y.tail!==null?(a=y.tail,y.rendering=a,y.tail=a.sibling,y.renderingStartTime=z(),a.sibling=null,f=jr.current,ke(jr,E?f&1|2:f&1),vn&&ii(c,y.treeForkCount),a):(or(c),null);case 22:case 23:return Is(c),nd(),y=c.memoizedState!==null,a!==null?a.memoizedState!==null!==y&&(c.flags|=8192):y&&(c.flags|=8192),y?(f&536870912)!==0&&(c.flags&128)===0&&(or(c),c.subtreeFlags&6&&(c.flags|=8192)):or(c),f=c.updateQueue,f!==null&&Of(c,f.retryQueue),f=null,a!==null&&a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(f=a.memoizedState.cachePool.pool),y=null,c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(y=c.memoizedState.cachePool.pool),y!==f&&(c.flags|=2048),a!==null&&Oe(El),null;case 24:return f=null,a!==null&&(f=a.memoizedState.cache),c.memoizedState.cache!==f&&(c.flags|=2048),oi(Dr),or(c),null;case 25:return null;case 30:return null}throw Error(o(156,c.tag))}function uv(a,c){switch(xo(c),c.tag){case 1:return a=c.flags,a&65536?(c.flags=a&-65537|128,c):null;case 3:return oi(Dr),yt(),a=c.flags,(a&65536)!==0&&(a&128)===0?(c.flags=a&-65537|128,c):null;case 26:case 27:case 5:return Ft(c),null;case 31:if(c.memoizedState!==null){if(Is(c),c.alternate===null)throw Error(o(340));za()}return a=c.flags,a&65536?(c.flags=a&-65537|128,c):null;case 13:if(Is(c),a=c.memoizedState,a!==null&&a.dehydrated!==null){if(c.alternate===null)throw Error(o(340));za()}return a=c.flags,a&65536?(c.flags=a&-65537|128,c):null;case 19:return Oe(jr),null;case 4:return yt(),null;case 10:return oi(c.type),null;case 22:case 23:return Is(c),nd(),a!==null&&Oe(El),a=c.flags,a&65536?(c.flags=a&-65537|128,c):null;case 24:return oi(Dr),null;case 25:return null;default:return null}}function B0(a,c){switch(xo(c),c.tag){case 3:oi(Dr),yt();break;case 26:case 27:case 5:Ft(c);break;case 4:yt();break;case 31:c.memoizedState!==null&&Is(c);break;case 13:Is(c);break;case 19:Oe(jr);break;case 10:oi(c.type);break;case 22:case 23:Is(c),nd(),a!==null&&Oe(El);break;case 24:oi(Dr)}}function jh(a,c){try{var f=c.updateQueue,y=f!==null?f.lastEffect:null;if(y!==null){var E=y.next;f=E;do{if((f.tag&a)===a){y=void 0;var O=f.create,B=f.inst;y=O(),B.destroy=y}f=f.next}while(f!==E)}}catch(te){Xn(c,c.return,te)}}function Tl(a,c,f){try{var y=c.updateQueue,E=y!==null?y.lastEffect:null;if(E!==null){var O=E.next;y=O;do{if((y.tag&a)===a){var B=y.inst,te=B.destroy;if(te!==void 0){B.destroy=void 0,E=c;var ye=f,Be=te;try{Be()}catch(We){Xn(E,ye,We)}}}y=y.next}while(y!==O)}}catch(We){Xn(c,c.return,We)}}function U0(a){var c=a.updateQueue;if(c!==null){var f=a.stateNode;try{o0(c,f)}catch(y){Xn(a,a.return,y)}}}function K0(a,c,f){f.props=Mc(a.type,a.memoizedProps),f.state=a.memoizedState;try{f.componentWillUnmount()}catch(y){Xn(a,c,y)}}function Ch(a,c){try{var f=a.ref;if(f!==null){switch(a.tag){case 26:case 27:case 5:var y=a.stateNode;break;case 30:y=a.stateNode;break;default:y=a.stateNode}typeof f=="function"?a.refCleanup=f(y):f.current=y}}catch(E){Xn(a,c,E)}}function Ha(a,c){var f=a.ref,y=a.refCleanup;if(f!==null)if(typeof y=="function")try{y()}catch(E){Xn(a,c,E)}finally{a.refCleanup=null,a=a.alternate,a!=null&&(a.refCleanup=null)}else if(typeof f=="function")try{f(null)}catch(E){Xn(a,c,E)}else f.current=null}function V0(a){var c=a.type,f=a.memoizedProps,y=a.stateNode;try{e:switch(c){case"button":case"input":case"select":case"textarea":f.autoFocus&&y.focus();break e;case"img":f.src?y.src=f.src:f.srcSet&&(y.srcset=f.srcSet)}}catch(E){Xn(a,a.return,E)}}function Ah(a,c,f){try{var y=a.stateNode;$A(y,a.type,f,c),y[Ps]=c}catch(E){Xn(a,a.return,E)}}function dv(a){return a.tag===5||a.tag===3||a.tag===26||a.tag===27&&Il(a.type)||a.tag===4}function hv(a){e:for(;;){for(;a.sibling===null;){if(a.return===null||dv(a.return))return null;a=a.return}for(a.sibling.return=a.return,a=a.sibling;a.tag!==5&&a.tag!==6&&a.tag!==18;){if(a.tag===27&&Il(a.type)||a.flags&2||a.child===null||a.tag===4)continue e;a.child.return=a,a=a.child}if(!(a.flags&2))return a.stateNode}}function pv(a,c,f){var y=a.tag;if(y===5||y===6)a=a.stateNode,c?(f.nodeType===9?f.body:f.nodeName==="HTML"?f.ownerDocument.body:f).insertBefore(a,c):(c=f.nodeType===9?f.body:f.nodeName==="HTML"?f.ownerDocument.body:f,c.appendChild(a),f=f._reactRootContainer,f!=null||c.onclick!==null||(c.onclick=xa));else if(y!==4&&(y===27&&Il(a.type)&&(f=a.stateNode,c=null),a=a.child,a!==null))for(pv(a,c,f),a=a.sibling;a!==null;)pv(a,c,f),a=a.sibling}function kf(a,c,f){var y=a.tag;if(y===5||y===6)a=a.stateNode,c?f.insertBefore(a,c):f.appendChild(a);else if(y!==4&&(y===27&&Il(a.type)&&(f=a.stateNode),a=a.child,a!==null))for(kf(a,c,f),a=a.sibling;a!==null;)kf(a,c,f),a=a.sibling}function Rf(a){var c=a.stateNode,f=a.memoizedProps;try{for(var y=a.type,E=c.attributes;E.length;)c.removeAttributeNode(E[0]);vs(c,y,f),c[ss]=a,c[Ps]=f}catch(O){Xn(a,a.return,O)}}var ko=!1,Br=!1,fv=!1,H0=typeof WeakSet=="function"?WeakSet:Set,ls=null;function G0(a,c){if(a=a.containerInfo,Zf=lm,a=Jw(a),Qg(a)){if("selectionStart"in a)var f={start:a.selectionStart,end:a.selectionEnd};else e:{f=(f=a.ownerDocument)&&f.defaultView||window;var y=f.getSelection&&f.getSelection();if(y&&y.rangeCount!==0){f=y.anchorNode;var E=y.anchorOffset,O=y.focusNode;y=y.focusOffset;try{f.nodeType,O.nodeType}catch{f=null;break e}var B=0,te=-1,ye=-1,Be=0,We=0,rt=a,Ue=null;t:for(;;){for(var Xe;rt!==f||E!==0&&rt.nodeType!==3||(te=B+E),rt!==O||y!==0&&rt.nodeType!==3||(ye=B+y),rt.nodeType===3&&(B+=rt.nodeValue.length),(Xe=rt.firstChild)!==null;)Ue=rt,rt=Xe;for(;;){if(rt===a)break t;if(Ue===f&&++Be===E&&(te=B),Ue===O&&++We===y&&(ye=B),(Xe=rt.nextSibling)!==null)break;rt=Ue,Ue=rt.parentNode}rt=Xe}f=te===-1||ye===-1?null:{start:te,end:ye}}else f=null}f=f||{start:0,end:0}}else f=null;for(Wf={focusedElem:a,selectionRange:f},lm=!1,ls=c;ls!==null;)if(c=ls,a=c.child,(c.subtreeFlags&1028)!==0&&a!==null)a.return=c,ls=a;else for(;ls!==null;){switch(c=ls,O=c.alternate,a=c.flags,c.tag){case 0:if((a&4)!==0&&(a=c.updateQueue,a=a!==null?a.events:null,a!==null))for(f=0;f title"))),vs(O,y,f),O[ss]=a,Zr(O),y=O;break e;case"link":var B=MS("link","href",E).get(y+(f.href||""));if(B){for(var te=0;teQn&&(B=Qn,Qn=Xt,Xt=B);var $e=Zw(te,Xt),Ee=Zw(te,Qn);if($e&&Ee&&(Xe.rangeCount!==1||Xe.anchorNode!==$e.node||Xe.anchorOffset!==$e.offset||Xe.focusNode!==Ee.node||Xe.focusOffset!==Ee.offset)){var Pe=rt.createRange();Pe.setStart($e.node,$e.offset),Xe.removeAllRanges(),Xt>Qn?(Xe.addRange(Pe),Xe.extend(Ee.node,Ee.offset)):(Pe.setEnd(Ee.node,Ee.offset),Xe.addRange(Pe))}}}}for(rt=[],Xe=te;Xe=Xe.parentNode;)Xe.nodeType===1&&rt.push({element:Xe,left:Xe.scrollLeft,top:Xe.scrollTop});for(typeof te.focus=="function"&&te.focus(),te=0;tef?32:f,ce.T=null,f=Mf,Mf=null;var O=Dl,B=No;if(Jr=0,dd=Dl=null,No=0,(Hn&6)!==0)throw Error(o(331));var te=Hn;if(Hn|=4,eS(O.current),vv(O,O.current,B,f),Hn=te,pd(0,!1),Ht&&typeof Ht.onPostCommitFiberRoot=="function")try{Ht.onPostCommitFiberRoot(dn,O)}catch{}return!0}finally{re.p=E,ce.T=y,fS(a,c)}}function mS(a,c,f){c=ri(f,c),c=Jy(a.stateNode,c,2),a=jl(a,c,2),a!==null&&(Er(a,2),Xa(a))}function Xn(a,c,f){if(a.tag===3)mS(a,a,f);else for(;c!==null;){if(c.tag===3){mS(c,a,f);break}else if(c.tag===1){var y=c.stateNode;if(typeof c.type.getDerivedStateFromError=="function"||typeof y.componentDidCatch=="function"&&(Nl===null||!Nl.has(y))){a=ri(f,a),f=Qy(2),y=jl(c,f,2),y!==null&&(Cl(f,y,c,a),Er(y,2),Xa(y));break}}c=c.return}}function Ov(a,c,f){var y=a.pingCache;if(y===null){y=a.pingCache=new EA;var E=new Set;y.set(c,E)}else E=y.get(c),E===void 0&&(E=new Set,y.set(c,E));E.has(f)||(bv=!0,E.add(f),a=Uf.bind(null,a,c,f),c.then(a,a))}function Uf(a,c,f){var y=a.pingCache;y!==null&&y.delete(c),a.pingedLanes|=a.suspendedLanes&f,a.warmLanes&=~f,lr===a&&(An&f)===f&&(Ar===4||Ar===3&&(An&62914560)===An&&300>z()-$h?(Hn&2)===0&&Ml(a,0):$f|=f,$l===An&&($l=0)),Xa(a)}function kv(a,c){c===0&&(c=Os()),a=bc(a,c),a!==null&&(Er(a,c),Xa(a))}function OA(a){var c=a.memoizedState,f=0;c!==null&&(f=c.retryLane),kv(a,f)}function kA(a,c){var f=0;switch(a.tag){case 31:case 13:var y=a.stateNode,E=a.memoizedState;E!==null&&(f=E.retryLane);break;case 19:y=a.stateNode;break;case 22:y=a.stateNode._retryCache;break;default:throw Error(o(314))}y!==null&&y.delete(c),kv(a,f)}function Rv(a,c){return xe(a,c)}var Kf=null,Fc=null,Tv=!1,Vf=!1,_v=!1,Aa=0;function Xa(a){a!==Fc&&a.next===null&&(Fc===null?Kf=Fc=a:Fc=Fc.next=a),Vf=!0,Tv||(Tv=!0,RA())}function pd(a,c){if(!_v&&Vf){_v=!0;do for(var f=!1,y=Kf;y!==null;){if(a!==0){var E=y.pendingLanes;if(E===0)var O=0;else{var B=y.suspendedLanes,te=y.pingedLanes;O=(1<<31-Xr(42|a)+1)-1,O&=E&~(B&~te),O=O&201326741?O&201326741|1:O?O|2:0}O!==0&&(f=!0,vS(y,O))}else O=An,O=Lt(y,y===lr?O:0,y.cancelPendingCommit!==null||y.timeoutHandle!==-1),(O&3)===0||vr(y,O)||(f=!0,vS(y,O));y=y.next}while(f);_v=!1}}function $v(){Hf()}function Hf(){Vf=Tv=!1;var a=0;Aa!==0&&DA()&&(a=Aa);for(var c=z(),f=null,y=Kf;y!==null;){var E=y.next,O=gS(y,c);O===0?(y.next=null,f===null?Kf=E:f.next=E,E===null&&(Fc=f)):(f=y,(a!==0||(O&3)!==0)&&(Vf=!0)),y=E}Jr!==0&&Jr!==5||pd(a),Aa!==0&&(Aa=0)}function gS(a,c){for(var f=a.suspendedLanes,y=a.pingedLanes,E=a.expirationTimes,O=a.pendingLanes&-62914561;0te)break;var We=ye.transferSize,rt=ye.initiatorType;We&&Lv(rt)&&(ye=ye.responseEnd,B+=We*(ye"u"?null:document;function RS(a,c,f){var y=Bc;if(y&&typeof c=="string"&&c){var E=Js(c);E='link[rel="'+a+'"][href="'+E+'"]',typeof f=="string"&&(E+='[crossorigin="'+f+'"]'),Gv.has(E)||(Gv.add(E),a={rel:a,crossOrigin:f,href:c},y.querySelector(E)===null&&(c=y.createElement("link"),vs(c,"link",a),Zr(c),y.head.appendChild(c)))}}function Xv(a){Do.D(a),RS("dns-prefetch",a,null)}function TS(a,c){Do.C(a,c),RS("preconnect",a,c)}function LA(a,c,f){Do.L(a,c,f);var y=Bc;if(y&&a&&c){var E='link[rel="preload"][as="'+Js(c)+'"]';c==="image"&&f&&f.imageSrcSet?(E+='[imagesrcset="'+Js(f.imageSrcSet)+'"]',typeof f.imageSizes=="string"&&(E+='[imagesizes="'+Js(f.imageSizes)+'"]')):E+='[href="'+Js(a)+'"]';var O=E;switch(c){case"style":O=vd(a);break;case"script":O=zl(a)}na.has(O)||(a=A({rel:"preload",href:c==="image"&&f&&f.imageSrcSet?void 0:a,as:c},f),na.set(O,a),y.querySelector(E)!==null||c==="style"&&y.querySelector(Uh(O))||c==="script"&&y.querySelector(Kh(O))||(c=y.createElement("link"),vs(c,"link",a),Zr(c),y.head.appendChild(c)))}}function _S(a,c){Do.m(a,c);var f=Bc;if(f&&a){var y=c&&typeof c.as=="string"?c.as:"script",E='link[rel="modulepreload"][as="'+Js(y)+'"][href="'+Js(a)+'"]',O=E;switch(y){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":O=zl(a)}if(!na.has(O)&&(a=A({rel:"modulepreload",href:a},c),na.set(O,a),f.querySelector(E)===null)){switch(y){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(f.querySelector(Kh(O)))return}y=f.createElement("link"),vs(y,"link",a),Zr(y),f.head.appendChild(y)}}}function zA(a,c,f){Do.S(a,c,f);var y=Bc;if(y&&a){var E=ul(y).hoistableStyles,O=vd(a);c=c||"default";var B=E.get(O);if(!B){var te={loading:0,preload:null};if(B=y.querySelector(Uh(O)))te.loading=5;else{a=A({rel:"stylesheet",href:a,"data-precedence":c},f),(f=na.get(O))&&Yv(a,f);var ye=B=y.createElement("link");Zr(ye),vs(ye,"link",a),ye._p=new Promise(function(Be,We){ye.onload=Be,ye.onerror=We}),ye.addEventListener("load",function(){te.loading|=1}),ye.addEventListener("error",function(){te.loading|=2}),te.loading|=4,rm(B,c,y)}B={type:"stylesheet",instance:B,count:1,state:te},E.set(O,B)}}}function FA(a,c){Do.X(a,c);var f=Bc;if(f&&a){var y=ul(f).hoistableScripts,E=zl(a),O=y.get(E);O||(O=f.querySelector(Kh(E)),O||(a=A({src:a,async:!0},c),(c=na.get(E))&&Zv(a,c),O=f.createElement("script"),Zr(O),vs(O,"link",a),f.head.appendChild(O)),O={type:"script",instance:O,count:1,state:null},y.set(E,O))}}function qA(a,c){Do.M(a,c);var f=Bc;if(f&&a){var y=ul(f).hoistableScripts,E=zl(a),O=y.get(E);O||(O=f.querySelector(Kh(E)),O||(a=A({src:a,async:!0,type:"module"},c),(c=na.get(E))&&Zv(a,c),O=f.createElement("script"),Zr(O),vs(O,"link",a),f.head.appendChild(O)),O={type:"script",instance:O,count:1,state:null},y.set(E,O))}}function $S(a,c,f,y){var E=(E=De.current)?nm(E):null;if(!E)throw Error(o(446));switch(a){case"meta":case"title":return null;case"style":return typeof f.precedence=="string"&&typeof f.href=="string"?(c=vd(f.href),f=ul(E).hoistableStyles,y=f.get(c),y||(y={type:"style",instance:null,count:0,state:null},f.set(c,y)),y):{type:"void",instance:null,count:0,state:null};case"link":if(f.rel==="stylesheet"&&typeof f.href=="string"&&typeof f.precedence=="string"){a=vd(f.href);var O=ul(E).hoistableStyles,B=O.get(a);if(B||(E=E.ownerDocument||E,B={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},O.set(a,B),(O=E.querySelector(Uh(a)))&&!O._p&&(B.instance=O,B.state.loading=5),na.has(a)||(f={rel:"preload",as:"style",href:f.href,crossOrigin:f.crossOrigin,integrity:f.integrity,media:f.media,hrefLang:f.hrefLang,referrerPolicy:f.referrerPolicy},na.set(a,f),O||DS(E,a,f,B.state))),c&&y===null)throw Error(o(528,""));return B}if(c&&y!==null)throw Error(o(529,""));return null;case"script":return c=f.async,f=f.src,typeof f=="string"&&c&&typeof c!="function"&&typeof c!="symbol"?(c=zl(f),f=ul(E).hoistableScripts,y=f.get(c),y||(y={type:"script",instance:null,count:0,state:null},f.set(c,y)),y):{type:"void",instance:null,count:0,state:null};default:throw Error(o(444,a))}}function vd(a){return'href="'+Js(a)+'"'}function Uh(a){return'link[rel="stylesheet"]['+a+"]"}function NS(a){return A({},a,{"data-precedence":a.precedence,precedence:null})}function DS(a,c,f,y){a.querySelector('link[rel="preload"][as="style"]['+c+"]")?y.loading=1:(c=a.createElement("link"),y.preload=c,c.addEventListener("load",function(){return y.loading|=1}),c.addEventListener("error",function(){return y.loading|=2}),vs(c,"link",f),Zr(c),a.head.appendChild(c))}function zl(a){return'[src="'+Js(a)+'"]'}function Kh(a){return"script[async]"+a}function PS(a,c,f){if(c.count++,c.instance===null)switch(c.type){case"style":var y=a.querySelector('style[data-href~="'+Js(f.href)+'"]');if(y)return c.instance=y,Zr(y),y;var E=A({},f,{"data-href":f.href,"data-precedence":f.precedence,href:null,precedence:null});return y=(a.ownerDocument||a).createElement("style"),Zr(y),vs(y,"style",E),rm(y,f.precedence,a),c.instance=y;case"stylesheet":E=vd(f.href);var O=a.querySelector(Uh(E));if(O)return c.state.loading|=4,c.instance=O,Zr(O),O;y=NS(f),(E=na.get(E))&&Yv(y,E),O=(a.ownerDocument||a).createElement("link"),Zr(O);var B=O;return B._p=new Promise(function(te,ye){B.onload=te,B.onerror=ye}),vs(O,"link",y),c.state.loading|=4,rm(O,f.precedence,a),c.instance=O;case"script":return O=zl(f.src),(E=a.querySelector(Kh(O)))?(c.instance=E,Zr(E),E):(y=f,(E=na.get(O))&&(y=A({},f),Zv(y,E)),a=a.ownerDocument||a,E=a.createElement("script"),Zr(E),vs(E,"link",y),a.head.appendChild(E),c.instance=E);case"void":return null;default:throw Error(o(443,c.type))}else c.type==="stylesheet"&&(c.state.loading&4)===0&&(y=c.instance,c.state.loading|=4,rm(y,f.precedence,a));return c.instance}function rm(a,c,f){for(var y=f.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),E=y.length?y[y.length-1]:null,O=E,B=0;B title"):null)}function BA(a,c,f){if(f===1||c.itemProp!=null)return!1;switch(a){case"meta":case"title":return!0;case"style":if(typeof c.precedence!="string"||typeof c.href!="string"||c.href==="")break;return!0;case"link":if(typeof c.rel!="string"||typeof c.href!="string"||c.href===""||c.onLoad||c.onError)break;switch(c.rel){case"stylesheet":return a=c.disabled,typeof c.precedence=="string"&&a==null;default:return!0}case"script":if(c.async&&typeof c.async!="function"&&typeof c.async!="symbol"&&!c.onLoad&&!c.onError&&c.src&&typeof c.src=="string")return!0}return!1}function LS(a){return!(a.type==="stylesheet"&&(a.state.loading&3)===0)}function zS(a,c,f,y){if(f.type==="stylesheet"&&(typeof y.media!="string"||matchMedia(y.media).matches!==!1)&&(f.state.loading&4)===0){if(f.instance===null){var E=vd(y.href),O=c.querySelector(Uh(E));if(O){c=O._p,c!==null&&typeof c=="object"&&typeof c.then=="function"&&(a.count++,a=Uc.bind(a),c.then(a,a)),f.state.loading|=4,f.instance=O,Zr(O);return}O=c.ownerDocument||c,y=NS(y),(E=na.get(E))&&Yv(y,E),O=O.createElement("link"),Zr(O);var B=O;B._p=new Promise(function(te,ye){B.onload=te,B.onerror=ye}),vs(O,"link",y),f.instance=O}a.stylesheets===null&&(a.stylesheets=new Map),a.stylesheets.set(f,c),(c=f.state.preload)&&(f.state.loading&3)===0&&(a.count++,f=Uc.bind(a),c.addEventListener("load",f),c.addEventListener("error",f))}}var im=0;function UA(a,c){return a.stylesheets&&a.count===0&&am(a,a.stylesheets),0im?50:800)+c);return a.unsuspend=f,function(){a.unsuspend=null,clearTimeout(y),clearTimeout(E)}}:null}function Uc(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)am(this,this.stylesheets);else if(this.unsuspend){var a=this.unsuspend;this.unsuspend=null,a()}}}var xd=null;function am(a,c){a.stylesheets=null,a.unsuspend!==null&&(a.count++,xd=new Map,c.forEach(FS,a),xd=null,Uc.call(a))}function FS(a,c){if(!(c.state.loading&4)){var f=xd.get(a);if(f)var y=f.get(null);else{f=new Map,xd.set(a,f);for(var E=a.querySelectorAll("link[data-precedence],style[data-precedence]"),O=0;O"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(r){console.error(r)}}return e(),RR.exports=hJ(),RR.exports}var fJ=pJ();const Rj="autoglue.tokens",TT="autoglue.auth-change";let Jl=_T();function _T(){try{const e=localStorage.getItem(Rj);return e?JSON.parse(e):null}catch{return null}}function mJ(e){e?localStorage.setItem(Rj,JSON.stringify(e)):localStorage.removeItem(Rj)}function gJ(e){window.dispatchEvent(new CustomEvent(TT,{detail:e}))}const Ks={get(){return Jl},set(e){Jl=e,mJ(e),gJ(e)},reload(){return Jl=_T(),Jl},isAuthed(){return!!Jl?.access_token},getAccessToken(){return Jl?.access_token??null},isExpired(e=Math.floor(Date.now()/1e3)){const r=PM(Jl?.access_token);return r!==null?e>=r:!0},willExpireSoon(e=60,r=Math.floor(Date.now()/1e3)){const s=PM(Jl?.access_token);return s!==null?s-r<=e:!0},logout(){Ks.set(null)},subscribe(e){const r=o=>e(o.detail??null),s=o=>{o.key===Rj&&(Jl=_T(),e(Jl))};return window.addEventListener(TT,r),window.addEventListener("storage",s),()=>{window.removeEventListener(TT,r),window.removeEventListener("storage",s)}}};function PM(e){if(!e)return null;const r=e.split(".");if(r.length<2)return null;try{const s=JSON.parse(atob(yJ(r[1])));return(typeof s?.exp=="number"?s.exp:null)??null}catch{return null}}function yJ(e){return e.replace(/-/g,"+").replace(/_/g,"/")+"==".slice((2-e.length*3%4)%4)}const $T="autoglue.org";let FE=localStorage.getItem($T);const Qo={get(){return FE},set(e){FE=e,localStorage.setItem($T,e),window.dispatchEvent(new CustomEvent("autoglue:org-change",{detail:e}))},subscribe(e){const r=o=>e(o.detail??null),s=o=>{o.key===$T&&(FE=o.newValue,e(FE))};return window.addEventListener("autoglue:org-change",r),window.addEventListener("storage",s),()=>{window.removeEventListener("autoglue:org-change",r),window.removeEventListener("storage",s)}}},vJ="https://autoglue.glueopshosted.com/api/v1".replace(/\/+$/,"");class cL{constructor(r={}){this.configuration=r}set config(r){this.configuration=r}get basePath(){return this.configuration.basePath!=null?this.configuration.basePath:vJ}get fetchApi(){return this.configuration.fetchApi}get middleware(){return this.configuration.middleware||[]}get queryParamsStringify(){return this.configuration.queryParamsStringify||uL}get username(){return this.configuration.username}get password(){return this.configuration.password}get apiKey(){const r=this.configuration.apiKey;if(r)return typeof r=="function"?r:()=>r}get accessToken(){const r=this.configuration.accessToken;if(r)return typeof r=="function"?r:async()=>r}get headers(){return this.configuration.headers}get credentials(){return this.configuration.credentials}}const xJ=new cL;class Gs{constructor(r=xJ){this.configuration=r,this.middleware=r.middleware}static jsonRegex=new RegExp("^(:?application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(:?;.*)?$","i");middleware;withMiddleware(...r){const s=this.clone();return s.middleware=s.middleware.concat(...r),s}withPreMiddleware(...r){const s=r.map(o=>({pre:o}));return this.withMiddleware(...s)}withPostMiddleware(...r){const s=r.map(o=>({post:o}));return this.withMiddleware(...s)}isJsonMime(r){return r?Gs.jsonRegex.test(r):!1}async request(r,s){const{url:o,init:d}=await this.createFetchParams(r,s),p=await this.fetchApi(o,d);if(p&&p.status>=200&&p.status<300)return p;throw new SJ(p,"Response returned an error code")}async createFetchParams(r,s){let o=this.configuration.basePath+r.path;r.query!==void 0&&Object.keys(r.query).length!==0&&(o+="?"+this.configuration.queryParamsStringify(r.query));const d=Object.assign({},this.configuration.headers,r.headers);Object.keys(d).forEach(j=>d[j]===void 0?delete d[j]:{});const p=typeof s=="function"?s:async()=>s,m={method:r.method,headers:d,body:r.body,credentials:this.configuration.credentials},g={...m,...await p({init:m,context:r})};let b;wJ(g.body)||g.body instanceof URLSearchParams||bJ(g.body)?b=g.body:this.isJsonMime(d["Content-Type"])?b=JSON.stringify(g.body):b=g.body;const S={...g,body:b};return{url:o,init:S}}fetchApi=async(r,s)=>{let o={url:r,init:s};for(const p of this.middleware)p.pre&&(o=await p.pre({fetch:this.fetchApi,...o})||o);let d;try{d=await(this.configuration.fetchApi||fetch)(o.url,o.init)}catch(p){for(const m of this.middleware)m.onError&&(d=await m.onError({fetch:this.fetchApi,url:o.url,init:o.init,error:p,response:d?d.clone():void 0})||d);if(d===void 0)throw p instanceof Error?new EJ(p,"The request failed and the interceptors did not return an alternative response"):p}for(const p of this.middleware)p.post&&(d=await p.post({fetch:this.fetchApi,url:o.url,init:o.init,response:d.clone()})||d);return d};clone(){const r=this.constructor,s=new r(this.configuration);return s.middleware=this.middleware.slice(),s}}function bJ(e){return typeof Blob<"u"&&e instanceof Blob}function wJ(e){return typeof FormData<"u"&&e instanceof FormData}class SJ extends Error{constructor(r,s){super(s),this.response=r}name="ResponseError"}class EJ extends Error{constructor(r,s){super(s),this.cause=r}name="FetchError"}class et extends Error{constructor(r,s){super(s),this.field=r}name="RequiredError"}function uL(e,r=""){return Object.keys(e).map(s=>dL(s,e[s],r)).filter(s=>s.length>0).join("&")}function dL(e,r,s=""){const o=s+(s.length?`[${e}]`:e);if(r instanceof Array){const d=r.map(p=>encodeURIComponent(String(p))).join(`&${encodeURIComponent(o)}=`);return`${encodeURIComponent(o)}=${d}`}if(r instanceof Set){const d=Array.from(r);return dL(e,d,s)}return r instanceof Date?`${encodeURIComponent(o)}=${encodeURIComponent(r.toISOString())}`:r instanceof Object?uL(r,o):`${encodeURIComponent(o)}=${encodeURIComponent(String(r))}`}class mt{constructor(r,s=o=>o){this.raw=r,this.transformer=s}async value(){return this.transformer(await this.raw.json())}}class Ii{constructor(r){this.raw=r}async value(){}}class ec{constructor(r){this.raw=r}async value(){return await this.raw.text()}}function tg(e){return jJ(e)}function jJ(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,id:e.id==null?void 0:e.id,key:e.key==null?void 0:e.key,organization_id:e.organization_id==null?void 0:e.organization_id,updated_at:e.updated_at==null?void 0:e.updated_at,value:e.value==null?void 0:e.value}}function CJ(e){return AJ(e,!1)}function AJ(e,r=!1){return e==null?e:{annotation_ids:e.annotation_ids}}function OJ(e){return kJ(e,!1)}function kJ(e,r=!1){return e==null?e:{server_id:e.server_id}}function RJ(e){return TJ(e,!1)}function TJ(e,r=!1){return e==null?e:{domain_id:e.domain_id}}function _J(e){return $J(e,!1)}function $J(e,r=!1){return e==null?e:{label_ids:e.label_ids}}function MM(e){return NJ(e,!1)}function NJ(e,r=!1){return e==null?e:{load_balancer_id:e.load_balancer_id}}function DJ(e){return PJ(e,!1)}function PJ(e,r=!1){return e==null?e:{node_pool_id:e.node_pool_id}}function MJ(e){return IJ(e,!1)}function IJ(e,r=!1){return e==null?e:{record_set_id:e.record_set_id}}function LJ(e){return zJ(e,!1)}function zJ(e,r=!1){return e==null?e:{server_ids:e.server_ids}}function FJ(e){return qJ(e,!1)}function qJ(e,r=!1){return e==null?e:{taint_ids:e.taint_ids}}function BJ(e){return UJ(e)}function UJ(e,r){return e==null?e:{auth_url:e.auth_url==null?void 0:e.auth_url}}function yb(e){return KJ(e)}function KJ(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,credential_id:e.credential_id==null?void 0:e.credential_id,domain_name:e.domain_name==null?void 0:e.domain_name,id:e.id==null?void 0:e.id,last_error:e.last_error==null?void 0:e.last_error,organization_id:e.organization_id==null?void 0:e.organization_id,status:e.status==null?void 0:e.status,updated_at:e.updated_at==null?void 0:e.updated_at,zone_id:e.zone_id==null?void 0:e.zone_id}}function ng(e){return VJ(e)}function VJ(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,id:e.id==null?void 0:e.id,kind:e.kind==null?void 0:e.kind,name:e.name==null?void 0:e.name,organization_id:e.organization_id==null?void 0:e.organization_id,private_ip_address:e.private_ip_address==null?void 0:e.private_ip_address,public_ip_address:e.public_ip_address==null?void 0:e.public_ip_address,updated_at:e.updated_at==null?void 0:e.updated_at}}function rg(e){return HJ(e)}function HJ(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,effect:e.effect==null?void 0:e.effect,id:e.id==null?void 0:e.id,key:e.key==null?void 0:e.key,organization_id:e.organization_id==null?void 0:e.organization_id,updated_at:e.updated_at==null?void 0:e.updated_at,value:e.value==null?void 0:e.value}}function sg(e){return GJ(e)}function GJ(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,id:e.id==null?void 0:e.id,key:e.key==null?void 0:e.key,organization_id:e.organization_id==null?void 0:e.organization_id,updated_at:e.updated_at==null?void 0:e.updated_at,value:e.value==null?void 0:e.value}}function Id(e){return XJ(e)}function XJ(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,hostname:e.hostname==null?void 0:e.hostname,id:e.id==null?void 0:e.id,organization_id:e.organization_id==null?void 0:e.organization_id,private_ip_address:e.private_ip_address==null?void 0:e.private_ip_address,public_ip_address:e.public_ip_address==null?void 0:e.public_ip_address,role:e.role==null?void 0:e.role,ssh_key_id:e.ssh_key_id==null?void 0:e.ssh_key_id,ssh_user:e.ssh_user==null?void 0:e.ssh_user,status:e.status==null?void 0:e.status,updated_at:e.updated_at==null?void 0:e.updated_at}}function vb(e){return YJ(e)}function YJ(e,r){return e==null?e:{annotations:e.annotations==null?void 0:e.annotations.map(tg),created_at:e.created_at==null?void 0:e.created_at,id:e.id==null?void 0:e.id,labels:e.labels==null?void 0:e.labels.map(sg),name:e.name==null?void 0:e.name,organization_id:e.organization_id==null?void 0:e.organization_id,role:e.role==null?void 0:e.role,servers:e.servers==null?void 0:e.servers.map(Id),taints:e.taints==null?void 0:e.taints.map(rg),updated_at:e.updated_at==null?void 0:e.updated_at}}function pj(e){return ZJ(e)}function ZJ(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,domain_id:e.domain_id==null?void 0:e.domain_id,fingerprint:e.fingerprint==null?void 0:e.fingerprint,id:e.id==null?void 0:e.id,last_error:e.last_error==null?void 0:e.last_error,name:e.name==null?void 0:e.name,owner:e.owner==null?void 0:e.owner,status:e.status==null?void 0:e.status,ttl:e.ttl==null?void 0:e.ttl,type:e.type==null?void 0:e.type,updated_at:e.updated_at==null?void 0:e.updated_at,values:e.values==null?void 0:e.values}}function Ns(e){return WJ(e)}function WJ(e,r){return e==null?e:{apps_load_balancer:e.apps_load_balancer==null?void 0:ng(e.apps_load_balancer),bastion_server:e.bastion_server==null?void 0:Id(e.bastion_server),captain_domain:e.captain_domain==null?void 0:yb(e.captain_domain),certificate_key:e.certificate_key==null?void 0:e.certificate_key,cluster_provider:e.cluster_provider==null?void 0:e.cluster_provider,control_plane_fqdn:e.control_plane_fqdn==null?void 0:e.control_plane_fqdn,control_plane_record_set:e.control_plane_record_set==null?void 0:pj(e.control_plane_record_set),created_at:e.created_at==null?void 0:e.created_at,docker_image:e.docker_image==null?void 0:e.docker_image,docker_tag:e.docker_tag==null?void 0:e.docker_tag,glueops_load_balancer:e.glueops_load_balancer==null?void 0:ng(e.glueops_load_balancer),id:e.id==null?void 0:e.id,last_error:e.last_error==null?void 0:e.last_error,name:e.name==null?void 0:e.name,node_pools:e.node_pools==null?void 0:e.node_pools.map(vb),random_token:e.random_token==null?void 0:e.random_token,region:e.region==null?void 0:e.region,status:e.status==null?void 0:e.status,updated_at:e.updated_at==null?void 0:e.updated_at}}function JJ(e){return QJ(e,!1)}function QJ(e,r=!1){return e==null?e:{key:e.key,value:e.value}}function eQ(e){return tQ(e,!1)}function tQ(e,r=!1){return e==null?e:{cluster_provider:e.cluster_provider,docker_image:e.docker_image,docker_tag:e.docker_tag,name:e.name,region:e.region}}function nQ(e){return rQ(e,!1)}function rQ(e,r=!1){return e==null?e:{account_id:e.account_id,credential_provider:e.credential_provider,kind:e.kind,name:e.name,region:e.region,schema_version:e.schema_version,scope:e.scope,scope_kind:e.scope_kind,scope_version:e.scope_version,secret:e.secret}}function sQ(e){return iQ(e,!1)}function iQ(e,r=!1){return e==null?e:{credential_id:e.credential_id,domain_name:e.domain_name,zone_id:e.zone_id}}function aQ(e){return oQ(e,!1)}function oQ(e,r=!1){return e==null?e:{key:e.key,value:e.value}}function lQ(e){return cQ(e,!1)}function cQ(e,r=!1){return e==null?e:{kind:e.kind,name:e.name,private_ip_address:e.private_ip_address,public_ip_address:e.public_ip_address}}function uQ(e){return dQ(e,!1)}function dQ(e,r=!1){return e==null?e:{name:e.name,role:e.role}}function hQ(e){return pQ(e,!1)}function pQ(e,r=!1){return e==null?e:{name:e.name,ttl:e.ttl,type:e.type,values:e.values}}function fQ(e){return mQ(e,!1)}function mQ(e,r=!1){return e==null?e:{bits:e.bits,comment:e.comment,name:e.name,type:e.type}}function gQ(e){return yQ(e,!1)}function yQ(e,r=!1){return e==null?e:{hostname:e.hostname,private_ip_address:e.private_ip_address,public_ip_address:e.public_ip_address,role:e.role,ssh_key_id:e.ssh_key_id,ssh_user:e.ssh_user,status:e.status}}function vQ(e){return xQ(e,!1)}function xQ(e,r=!1){return e==null?e:{effect:e.effect,key:e.key,value:e.value}}function qE(e){return bQ(e)}function bQ(e,r){return e==null?e:{account_id:e.account_id==null?void 0:e.account_id,created_at:e.created_at==null?void 0:e.created_at,credential_provider:e.credential_provider==null?void 0:e.credential_provider,id:e.id==null?void 0:e.id,kind:e.kind==null?void 0:e.kind,name:e.name==null?void 0:e.name,region:e.region==null?void 0:e.region,schema_version:e.schema_version==null?void 0:e.schema_version,scope:e.scope==null?void 0:e.scope,scope_kind:e.scope_kind==null?void 0:e.scope_kind,scope_version:e.scope_version==null?void 0:e.scope_version,updated_at:e.updated_at==null?void 0:e.updated_at}}function wQ(e){return SQ(e,!1)}function SQ(e,r=!1){return e==null?e:{payload:e.payload,queue:e.queue,run_at:e.run_at,type:e.type}}function EQ(e){return jQ(e)}function jQ(e,r){return e==null?e:{alg:e.alg==null?void 0:e.alg,e:e.e==null?void 0:e.e,kid:e.kid==null?void 0:e.kid,kty:e.kty==null?void 0:e.kty,n:e.n==null?void 0:e.n,use:e.use==null?void 0:e.use,x:e.x==null?void 0:e.x}}function CQ(e){return AQ(e)}function AQ(e,r){return e==null?e:{keys:e.keys==null?void 0:e.keys.map(EQ)}}function OQ(e){return kQ(e)}function kQ(e,r){return e}function fj(e){return RQ(e)}function RQ(e,r){return e==null?e:{attempts:e.attempts==null?void 0:e.attempts,created_at:e.created_at==null?void 0:e.created_at,id:e.id==null?void 0:e.id,last_error:e.last_error==null?void 0:e.last_error,max_attempts:e.max_attempts==null?void 0:e.max_attempts,payload:e.payload==null?void 0:e.payload,queue:e.queue==null?void 0:e.queue,run_at:e.run_at==null?void 0:e.run_at,status:e.status==null?void 0:OQ(e.status),type:e.type==null?void 0:e.type,updated_at:e.updated_at==null?void 0:e.updated_at}}function TQ(e){return _Q(e,!1)}function _Q(e,r=!1){return e==null?e:{refresh_token:e.refresh_token}}function $Q(e){return NQ(e)}function NQ(e,r){return e==null?e:{items:e.items==null?void 0:e.items.map(fj),page:e.page==null?void 0:e.page,page_size:e.page_size==null?void 0:e.page_size,total:e.total==null?void 0:e.total}}function DQ(e){return PQ(e)}function PQ(e,r){return e==null?e:{failed:e.failed==null?void 0:e.failed,name:e.name==null?void 0:e.name,pending:e.pending==null?void 0:e.pending,running:e.running==null?void 0:e.running,scheduled:e.scheduled==null?void 0:e.scheduled}}function MQ(e){return IQ(e,!1)}function IQ(e,r=!1){return e==null?e:{refresh_token:e.refresh_token}}function LQ(e){return zQ(e,!1)}function zQ(e,r=!1){return e==null?e:{kubeconfig:e.kubeconfig}}function IM(e){return hL(e)}function hL(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,fingerprint:e.fingerprint==null?void 0:e.fingerprint,id:e.id==null?void 0:e.id,name:e.name==null?void 0:e.name,organization_id:e.organization_id==null?void 0:e.organization_id,public_key:e.public_key==null?void 0:e.public_key,updated_at:e.updated_at==null?void 0:e.updated_at}}function LM(e){return FQ(e)}function FQ(e,r){return e==null?e:{access_token:e.access_token==null?void 0:e.access_token,expires_in:e.expires_in==null?void 0:e.expires_in,refresh_token:e.refresh_token==null?void 0:e.refresh_token,token_type:e.token_type==null?void 0:e.token_type}}function qQ(e){return BQ(e,!1)}function BQ(e,r=!1){return e==null?e:{key:e.key,value:e.value}}function UQ(e){return KQ(e,!1)}function KQ(e,r=!1){return e==null?e:{cluster_provider:e.cluster_provider,docker_image:e.docker_image,docker_tag:e.docker_tag,name:e.name,region:e.region}}function VQ(e){return HQ(e,!1)}function HQ(e,r=!1){return e==null?e:{account_id:e.account_id,name:e.name,region:e.region,scope:e.scope,scope_kind:e.scope_kind,scope_version:e.scope_version,secret:e.secret}}function GQ(e){return XQ(e,!1)}function XQ(e,r=!1){return e==null?e:{credential_id:e.credential_id,domain_name:e.domain_name,status:e.status,zone_id:e.zone_id}}function YQ(e){return ZQ(e,!1)}function ZQ(e,r=!1){return e==null?e:{key:e.key,value:e.value}}function WQ(e){return JQ(e,!1)}function JQ(e,r=!1){return e==null?e:{kind:e.kind,name:e.name,private_ip_address:e.private_ip_address,public_ip_address:e.public_ip_address}}function QQ(e){return eee(e,!1)}function eee(e,r=!1){return e==null?e:{name:e.name,role:e.role}}function tee(e){return nee(e,!1)}function nee(e,r=!1){return e==null?e:{name:e.name,status:e.status,ttl:e.ttl,type:e.type,values:e.values}}function ree(e){return see(e,!1)}function see(e,r=!1){return e==null?e:{hostname:e.hostname,private_ip_address:e.private_ip_address,public_ip_address:e.public_ip_address,role:e.role,ssh_key_id:e.ssh_key_id,ssh_user:e.ssh_user,status:e.status}}function iee(e){return aee(e,!1)}function aee(e,r=!1){return e==null?e:{effect:e.effect,key:e.key,value:e.value}}function oee(e){return lee(e)}function lee(e,r){return e==null||typeof e!="object"?e:hL(e)}function cee(e){return uee(e,!1)}function uee(e,r=!1){return e==null?e:{expires_in_hours:e.expires_in_hours,name:e.name}}function pL(e){return dee(e)}function dee(e,r){return e==null?e:{avatar_url:e.avatar_url==null?void 0:e.avatar_url,created_at:e.created_at==null?void 0:new Date(e.created_at),display_name:e.display_name==null?void 0:e.display_name,id:e.id==null?void 0:e.id,is_admin:e.is_admin==null?void 0:e.is_admin,is_disabled:e.is_disabled==null?void 0:e.is_disabled,primary_email:e.primary_email==null?void 0:e.primary_email,updated_at:e.updated_at==null?void 0:new Date(e.updated_at)}}function hee(e){return pee(e)}function pee(e,r){return e==null?e:{created_at:e.created_at==null?void 0:new Date(e.created_at),email:e.email==null?void 0:e.email,id:e.id==null?void 0:e.id,is_primary:e.is_primary==null?void 0:e.is_primary,is_verified:e.is_verified==null?void 0:e.is_verified,updated_at:e.updated_at==null?void 0:new Date(e.updated_at),user:e.user==null?void 0:pL(e.user),user_id:e.user_id==null?void 0:e.user_id}}function xb(e){return fee(e)}function fee(e,r){return e==null?e:{created_at:e.created_at==null?void 0:new Date(e.created_at),domain:e.domain==null?void 0:e.domain,id:e.id==null?void 0:e.id,name:e.name==null?void 0:e.name,updated_at:e.updated_at==null?void 0:new Date(e.updated_at)}}function mee(e){return gee(e)}function gee(e,r){return e==null?e:{avatar_url:e.avatar_url==null?void 0:e.avatar_url,created_at:e.created_at==null?void 0:new Date(e.created_at),display_name:e.display_name==null?void 0:e.display_name,emails:e.emails==null?void 0:e.emails.map(hee),id:e.id==null?void 0:e.id,is_admin:e.is_admin==null?void 0:e.is_admin,is_disabled:e.is_disabled==null?void 0:e.is_disabled,organizations:e.organizations==null?void 0:e.organizations.map(xb),primary_email:e.primary_email==null?void 0:e.primary_email,updated_at:e.updated_at==null?void 0:new Date(e.updated_at)}}function zM(e){return yee(e)}function yee(e,r){return e==null?e:{email:e.email==null?void 0:e.email,role:e.role==null?void 0:e.role,user_id:e.user_id==null?void 0:e.user_id}}function vee(e){return xee(e,!1)}function xee(e,r=!1){return e==null?e:{role:e.role,user_id:e.user_id}}function bee(e){return wee(e,!1)}function wee(e,r=!1){return e==null?e:{domain:e.domain,name:e.name}}function See(e){return Eee(e,!1)}function Eee(e,r=!1){return e==null?e:{expires_in_hours:e.expires_in_hours,name:e.name}}function jee(e){return Cee(e)}function Cee(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,expires_at:e.expires_at==null?void 0:e.expires_at,id:e.id==null?void 0:e.id,name:e.name==null?void 0:e.name,org_key:e.org_key==null?void 0:e.org_key,org_secret:e.org_secret==null?void 0:e.org_secret,scope:e.scope==null?void 0:e.scope}}function Aee(e){return Oee(e,!1)}function Oee(e,r=!1){return e==null?e:{domain:e.domain,name:e.name}}function kee(e){return Ree(e,!1)}function Ree(e,r=!1){return e==null?e:{display_name:e.display_name}}function FM(e){return Tee(e)}function Tee(e,r){return e==null?e:{created_at:e.created_at==null?void 0:e.created_at,expires_at:e.expires_at==null?void 0:e.expires_at,id:e.id==null?void 0:e.id,last_used_at:e.last_used_at==null?void 0:e.last_used_at,name:e.name==null?void 0:e.name,plain:e.plain==null?void 0:e.plain,scope:e.scope==null?void 0:e.scope}}function _ee(e){return $ee(e)}function $ee(e,r){return e==null?e:{created_at:e.created_at==null?void 0:new Date(e.created_at),expires_at:e.expires_at==null?void 0:new Date(e.expires_at),id:e.id==null?void 0:e.id,last_used_at:e.last_used_at==null?void 0:new Date(e.last_used_at),name:e.name==null?void 0:e.name,org_id:e.org_id==null?void 0:e.org_id,prefix:e.prefix==null?void 0:e.prefix,revoked:e.revoked==null?void 0:e.revoked,scope:e.scope==null?void 0:e.scope,updated_at:e.updated_at==null?void 0:new Date(e.updated_at),user_id:e.user_id==null?void 0:e.user_id}}class Nee extends Gs{async createAnnotationRaw(r,s){if(r.dtoCreateAnnotationRequest==null)throw new et("dtoCreateAnnotationRequest",'Required parameter "dtoCreateAnnotationRequest" was null or undefined when calling createAnnotation().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/annotations",method:"POST",headers:d,query:o,body:JJ(r.dtoCreateAnnotationRequest)},s);return new mt(m,g=>tg(g))}async createAnnotation(r,s){return await(await this.createAnnotationRaw(r,s)).value()}async deleteAnnotationRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteAnnotation().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/annotations/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteAnnotation(r,s){await this.deleteAnnotationRaw(r,s)}async getAnnotationRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getAnnotation().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/annotations/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>tg(g))}async getAnnotation(r,s){return await(await this.getAnnotationRaw(r,s)).value()}async listAnnotationsRaw(r,s){const o={};r.key!=null&&(o.key=r.key),r.value!=null&&(o.value=r.value),r.q!=null&&(o.q=r.q);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/annotations",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(tg))}async listAnnotations(r={},s){return await(await this.listAnnotationsRaw(r,s)).value()}async updateAnnotationRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateAnnotation().');if(r.dtoUpdateAnnotationRequest==null)throw new et("dtoUpdateAnnotationRequest",'Required parameter "dtoUpdateAnnotationRequest" was null or undefined when calling updateAnnotation().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/annotations/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:qQ(r.dtoUpdateAnnotationRequest)},s);return new mt(m,g=>tg(g))}async updateAnnotation(r,s){return await(await this.updateAnnotationRaw(r,s)).value()}}class Dee extends Gs{async adminCancelArcherJobRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling adminCancelArcherJob().');const o={},d={};d["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/admin/archer/jobs/{id}/cancel";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:r.body},s);return new mt(m,g=>fj(g))}async adminCancelArcherJob(r,s){return await(await this.adminCancelArcherJobRaw(r,s)).value()}async adminEnqueueArcherJobRaw(r,s){if(r.dtoEnqueueRequest==null)throw new et("dtoEnqueueRequest",'Required parameter "dtoEnqueueRequest" was null or undefined when calling adminEnqueueArcherJob().');const o={},d={};d["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/admin/archer/jobs",method:"POST",headers:d,query:o,body:wQ(r.dtoEnqueueRequest)},s);return new mt(m,g=>fj(g))}async adminEnqueueArcherJob(r,s){return await(await this.adminEnqueueArcherJobRaw(r,s)).value()}async adminListArcherJobsRaw(r,s){const o={};r.status!=null&&(o.status=r.status),r.queue!=null&&(o.queue=r.queue),r.q!=null&&(o.q=r.q),r.page!=null&&(o.page=r.page),r.pageSize!=null&&(o.page_size=r.pageSize);const d={};this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/admin/archer/jobs",method:"GET",headers:d,query:o},s);return new mt(m,g=>$Q(g))}async adminListArcherJobs(r={},s){return await(await this.adminListArcherJobsRaw(r,s)).value()}async adminListArcherQueuesRaw(r){const s={},o={};this.configuration&&this.configuration.apiKey&&(o.Authorization=await this.configuration.apiKey("Authorization"));const p=await this.request({path:"/admin/archer/queues",method:"GET",headers:o,query:s},r);return new mt(p,m=>m.map(DQ))}async adminListArcherQueues(r){return await(await this.adminListArcherQueuesRaw(r)).value()}async adminRetryArcherJobRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling adminRetryArcherJob().');const o={},d={};d["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/admin/archer/jobs/{id}/retry";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:r.body},s);return new mt(m,g=>fj(g))}async adminRetryArcherJob(r,s){return await(await this.adminRetryArcherJobRaw(r,s)).value()}}const Ra={queued:"queued",running:"running",succeeded:"succeeded",failed:"failed",canceled:"canceled",retrying:"retrying",scheduled:"scheduled"};class Pee extends Gs{async authCallbackRaw(r,s){if(r.provider==null)throw new et("provider",'Required parameter "provider" was null or undefined when calling authCallback().');const o={},d={};let p="/auth/{provider}/callback";p=p.replace("{provider}",encodeURIComponent(String(r.provider)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>LM(g))}async authCallback(r,s){return await(await this.authCallbackRaw(r,s)).value()}async authStartRaw(r,s){if(r.provider==null)throw new et("provider",'Required parameter "provider" was null or undefined when calling authStart().');const o={},d={};let p="/auth/{provider}/start";p=p.replace("{provider}",encodeURIComponent(String(r.provider)));const m=await this.request({path:p,method:"POST",headers:d,query:o},s);return new mt(m,g=>BJ(g))}async authStart(r,s){return await(await this.authStartRaw(r,s)).value()}async getJWKSRaw(r){const s={},o={},p=await this.request({path:"/.well-known/jwks.json",method:"GET",headers:o,query:s},r);return new mt(p,m=>CQ(m))}async getJWKS(r){return await(await this.getJWKSRaw(r)).value()}async logoutRaw(r,s){if(r.dtoLogoutRequest==null)throw new et("dtoLogoutRequest",'Required parameter "dtoLogoutRequest" was null or undefined when calling logout().');const o={},d={};d["Content-Type"]="application/json";const m=await this.request({path:"/auth/logout",method:"POST",headers:d,query:o,body:TQ(r.dtoLogoutRequest)},s);return new Ii(m)}async logout(r,s){await this.logoutRaw(r,s)}async refreshRaw(r,s){if(r.dtoRefreshRequest==null)throw new et("dtoRefreshRequest",'Required parameter "dtoRefreshRequest" was null or undefined when calling refresh().');const o={},d={};d["Content-Type"]="application/json";const m=await this.request({path:"/auth/refresh",method:"POST",headers:d,query:o,body:MQ(r.dtoRefreshRequest)},s);return new mt(m,g=>LM(g))}async refresh(r,s){return await(await this.refreshRaw(r,s)).value()}}class Mee extends Gs{async attachAppsLoadBalancerRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling attachAppsLoadBalancer().');if(r.dtoAttachLoadBalancerRequest==null)throw new et("dtoAttachLoadBalancerRequest",'Required parameter "dtoAttachLoadBalancerRequest" was null or undefined when calling attachAppsLoadBalancer().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/apps-load-balancer";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:MM(r.dtoAttachLoadBalancerRequest)},s);return new mt(m,g=>Ns(g))}async attachAppsLoadBalancer(r,s){return await(await this.attachAppsLoadBalancerRaw(r,s)).value()}async attachBastionServerRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling attachBastionServer().');if(r.dtoAttachBastionRequest==null)throw new et("dtoAttachBastionRequest",'Required parameter "dtoAttachBastionRequest" was null or undefined when calling attachBastionServer().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/bastion";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:OJ(r.dtoAttachBastionRequest)},s);return new mt(m,g=>Ns(g))}async attachBastionServer(r,s){return await(await this.attachBastionServerRaw(r,s)).value()}async attachCaptainDomainRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling attachCaptainDomain().');if(r.dtoAttachCaptainDomainRequest==null)throw new et("dtoAttachCaptainDomainRequest",'Required parameter "dtoAttachCaptainDomainRequest" was null or undefined when calling attachCaptainDomain().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/captain-domain";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:RJ(r.dtoAttachCaptainDomainRequest)},s);return new mt(m,g=>Ns(g))}async attachCaptainDomain(r,s){return await(await this.attachCaptainDomainRaw(r,s)).value()}async attachControlPlaneRecordSetRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling attachControlPlaneRecordSet().');if(r.dtoAttachRecordSetRequest==null)throw new et("dtoAttachRecordSetRequest",'Required parameter "dtoAttachRecordSetRequest" was null or undefined when calling attachControlPlaneRecordSet().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/control-plane-record-set";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:MJ(r.dtoAttachRecordSetRequest)},s);return new mt(m,g=>Ns(g))}async attachControlPlaneRecordSet(r,s){return await(await this.attachControlPlaneRecordSetRaw(r,s)).value()}async attachGlueOpsLoadBalancerRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling attachGlueOpsLoadBalancer().');if(r.dtoAttachLoadBalancerRequest==null)throw new et("dtoAttachLoadBalancerRequest",'Required parameter "dtoAttachLoadBalancerRequest" was null or undefined when calling attachGlueOpsLoadBalancer().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/glueops-load-balancer";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:MM(r.dtoAttachLoadBalancerRequest)},s);return new mt(m,g=>Ns(g))}async attachGlueOpsLoadBalancer(r,s){return await(await this.attachGlueOpsLoadBalancerRaw(r,s)).value()}async attachNodePoolRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling attachNodePool().');if(r.dtoAttachNodePoolRequest==null)throw new et("dtoAttachNodePoolRequest",'Required parameter "dtoAttachNodePoolRequest" was null or undefined when calling attachNodePool().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/node-pools";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:DJ(r.dtoAttachNodePoolRequest)},s);return new mt(m,g=>Ns(g))}async attachNodePool(r,s){return await(await this.attachNodePoolRaw(r,s)).value()}async clearClusterKubeconfigRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling clearClusterKubeconfig().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/kubeconfig";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new mt(m,g=>Ns(g))}async clearClusterKubeconfig(r,s){return await(await this.clearClusterKubeconfigRaw(r,s)).value()}async createClusterRaw(r,s){if(r.dtoCreateClusterRequest==null)throw new et("dtoCreateClusterRequest",'Required parameter "dtoCreateClusterRequest" was null or undefined when calling createCluster().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/clusters",method:"POST",headers:d,query:o,body:eQ(r.dtoCreateClusterRequest)},s);return new mt(m,g=>Ns(g))}async createCluster(r,s){return await(await this.createClusterRaw(r,s)).value()}async deleteClusterRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling deleteCluster().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async deleteCluster(r,s){return await(await this.deleteClusterRaw(r,s)).value()}async detachAppsLoadBalancerRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling detachAppsLoadBalancer().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/apps-load-balancer";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new mt(m,g=>Ns(g))}async detachAppsLoadBalancer(r,s){return await(await this.detachAppsLoadBalancerRaw(r,s)).value()}async detachBastionServerRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling detachBastionServer().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/bastion";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new mt(m,g=>Ns(g))}async detachBastionServer(r,s){return await(await this.detachBastionServerRaw(r,s)).value()}async detachCaptainDomainRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling detachCaptainDomain().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/captain-domain";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new mt(m,g=>Ns(g))}async detachCaptainDomain(r,s){return await(await this.detachCaptainDomainRaw(r,s)).value()}async detachControlPlaneRecordSetRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling detachControlPlaneRecordSet().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/control-plane-record-set";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new mt(m,g=>Ns(g))}async detachControlPlaneRecordSet(r,s){return await(await this.detachControlPlaneRecordSetRaw(r,s)).value()}async detachGlueOpsLoadBalancerRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling detachGlueOpsLoadBalancer().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/glueops-load-balancer";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new mt(m,g=>Ns(g))}async detachGlueOpsLoadBalancer(r,s){return await(await this.detachGlueOpsLoadBalancerRaw(r,s)).value()}async detachNodePoolRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling detachNodePool().');if(r.nodePoolID==null)throw new et("nodePoolID",'Required parameter "nodePoolID" was null or undefined when calling detachNodePool().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/node-pools/{nodePoolID}";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID))),p=p.replace("{nodePoolID}",encodeURIComponent(String(r.nodePoolID)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new mt(m,g=>Ns(g))}async detachNodePool(r,s){return await(await this.detachNodePoolRaw(r,s)).value()}async getClusterRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling getCluster().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>Ns(g))}async getCluster(r,s){return await(await this.getClusterRaw(r,s)).value()}async listClustersRaw(r,s){const o={};r.q!=null&&(o.q=r.q);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/clusters",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(Ns))}async listClusters(r={},s){return await(await this.listClustersRaw(r,s)).value()}async setClusterKubeconfigRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling setClusterKubeconfig().');if(r.dtoSetKubeconfigRequest==null)throw new et("dtoSetKubeconfigRequest",'Required parameter "dtoSetKubeconfigRequest" was null or undefined when calling setClusterKubeconfig().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}/kubeconfig";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:LQ(r.dtoSetKubeconfigRequest)},s);return new mt(m,g=>Ns(g))}async setClusterKubeconfig(r,s){return await(await this.setClusterKubeconfigRaw(r,s)).value()}async updateClusterRaw(r,s){if(r.clusterID==null)throw new et("clusterID",'Required parameter "clusterID" was null or undefined when calling updateCluster().');if(r.dtoUpdateClusterRequest==null)throw new et("dtoUpdateClusterRequest",'Required parameter "dtoUpdateClusterRequest" was null or undefined when calling updateCluster().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/clusters/{clusterID}";p=p.replace("{clusterID}",encodeURIComponent(String(r.clusterID)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:UQ(r.dtoUpdateClusterRequest)},s);return new mt(m,g=>Ns(g))}async updateCluster(r,s){return await(await this.updateClusterRaw(r,s)).value()}}class Iee extends Gs{async createCredentialRaw(r,s){if(r.dtoCreateCredentialRequest==null)throw new et("dtoCreateCredentialRequest",'Required parameter "dtoCreateCredentialRequest" was null or undefined when calling createCredential().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/credentials",method:"POST",headers:d,query:o,body:nQ(r.dtoCreateCredentialRequest)},s);return new mt(m,g=>qE(g))}async createCredential(r,s){return await(await this.createCredentialRaw(r,s)).value()}async deleteCredentialRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteCredential().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/credentials/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteCredential(r,s){await this.deleteCredentialRaw(r,s)}async getCredentialRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getCredential().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/credentials/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>qE(g))}async getCredential(r,s){return await(await this.getCredentialRaw(r,s)).value()}async listCredentialsRaw(r,s){const o={};r.credentialProvider!=null&&(o.credential_provider=r.credentialProvider),r.kind!=null&&(o.kind=r.kind),r.scopeKind!=null&&(o.scope_kind=r.scopeKind);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/credentials",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(qE))}async listCredentials(r={},s){return await(await this.listCredentialsRaw(r,s)).value()}async revealCredentialRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling revealCredential().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/credentials/{id}/reveal";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:r.body},s);return new mt(m)}async revealCredential(r,s){return await(await this.revealCredentialRaw(r,s)).value()}async updateCredentialRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateCredential().');if(r.dtoUpdateCredentialRequest==null)throw new et("dtoUpdateCredentialRequest",'Required parameter "dtoUpdateCredentialRequest" was null or undefined when calling updateCredential().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/credentials/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:VQ(r.dtoUpdateCredentialRequest)},s);return new mt(m,g=>qE(g))}async updateCredential(r,s){return await(await this.updateCredentialRaw(r,s)).value()}}class Lee extends Gs{async createDomainRaw(r,s){if(r.dtoCreateDomainRequest==null)throw new et("dtoCreateDomainRequest",'Required parameter "dtoCreateDomainRequest" was null or undefined when calling createDomain().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/dns/domains",method:"POST",headers:d,query:o,body:sQ(r.dtoCreateDomainRequest)},s);return new mt(m,g=>yb(g))}async createDomain(r,s){return await(await this.createDomainRaw(r,s)).value()}async createRecordSetRaw(r,s){if(r.domainId==null)throw new et("domainId",'Required parameter "domainId" was null or undefined when calling createRecordSet().');if(r.dtoCreateRecordSetRequest==null)throw new et("dtoCreateRecordSetRequest",'Required parameter "dtoCreateRecordSetRequest" was null or undefined when calling createRecordSet().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/dns/domains/{domain_id}/records";p=p.replace("{domain_id}",encodeURIComponent(String(r.domainId)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:hQ(r.dtoCreateRecordSetRequest)},s);return new mt(m,g=>pj(g))}async createRecordSet(r,s){return await(await this.createRecordSetRaw(r,s)).value()}async deleteDomainRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteDomain().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/dns/domains/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteDomain(r,s){await this.deleteDomainRaw(r,s)}async deleteRecordSetRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteRecordSet().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/dns/records/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteRecordSet(r,s){await this.deleteRecordSetRaw(r,s)}async getDomainRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getDomain().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/dns/domains/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>yb(g))}async getDomain(r,s){return await(await this.getDomainRaw(r,s)).value()}async listDomainsRaw(r,s){const o={};r.domainName!=null&&(o.domain_name=r.domainName),r.status!=null&&(o.status=r.status),r.q!=null&&(o.q=r.q);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/dns/domains",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(yb))}async listDomains(r={},s){return await(await this.listDomainsRaw(r,s)).value()}async listRecordSetsRaw(r,s){if(r.domainId==null)throw new et("domainId",'Required parameter "domainId" was null or undefined when calling listRecordSets().');const o={};r.name!=null&&(o.name=r.name),r.type!=null&&(o.type=r.type),r.status!=null&&(o.status=r.status);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/dns/domains/{domain_id}/records";p=p.replace("{domain_id}",encodeURIComponent(String(r.domainId)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(pj))}async listRecordSets(r,s){return await(await this.listRecordSetsRaw(r,s)).value()}async updateDomainRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateDomain().');if(r.dtoUpdateDomainRequest==null)throw new et("dtoUpdateDomainRequest",'Required parameter "dtoUpdateDomainRequest" was null or undefined when calling updateDomain().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/dns/domains/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:GQ(r.dtoUpdateDomainRequest)},s);return new mt(m,g=>yb(g))}async updateDomain(r,s){return await(await this.updateDomainRaw(r,s)).value()}async updateRecordSetRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateRecordSet().');if(r.dtoUpdateRecordSetRequest==null)throw new et("dtoUpdateRecordSetRequest",'Required parameter "dtoUpdateRecordSetRequest" was null or undefined when calling updateRecordSet().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/dns/records/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:tee(r.dtoUpdateRecordSetRequest)},s);return new mt(m,g=>pj(g))}async updateRecordSet(r,s){return await(await this.updateRecordSetRaw(r,s)).value()}}class zee extends Gs{async createLabelRaw(r,s){if(r.dtoCreateLabelRequest==null)throw new et("dtoCreateLabelRequest",'Required parameter "dtoCreateLabelRequest" was null or undefined when calling createLabel().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/labels",method:"POST",headers:d,query:o,body:aQ(r.dtoCreateLabelRequest)},s);return new mt(m,g=>sg(g))}async createLabel(r,s){return await(await this.createLabelRaw(r,s)).value()}async deleteLabelRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteLabel().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/labels/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteLabel(r,s){await this.deleteLabelRaw(r,s)}async getLabelRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getLabel().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/labels/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>sg(g))}async getLabel(r,s){return await(await this.getLabelRaw(r,s)).value()}async listLabelsRaw(r,s){const o={};r.key!=null&&(o.key=r.key),r.value!=null&&(o.value=r.value),r.q!=null&&(o.q=r.q);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/labels",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(sg))}async listLabels(r={},s){return await(await this.listLabelsRaw(r,s)).value()}async updateLabelRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateLabel().');if(r.dtoUpdateLabelRequest==null)throw new et("dtoUpdateLabelRequest",'Required parameter "dtoUpdateLabelRequest" was null or undefined when calling updateLabel().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/labels/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:YQ(r.dtoUpdateLabelRequest)},s);return new mt(m,g=>sg(g))}async updateLabel(r,s){return await(await this.updateLabelRaw(r,s)).value()}}class Fee extends Gs{async createLoadBalancerRaw(r,s){if(r.dtoCreateLoadBalancerRequest==null)throw new et("dtoCreateLoadBalancerRequest",'Required parameter "dtoCreateLoadBalancerRequest" was null or undefined when calling createLoadBalancer().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/load-balancers",method:"POST",headers:d,query:o,body:lQ(r.dtoCreateLoadBalancerRequest)},s);return new mt(m,g=>ng(g))}async createLoadBalancer(r,s){return await(await this.createLoadBalancerRaw(r,s)).value()}async deleteLoadBalancerRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteLoadBalancer().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/load-balancers/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteLoadBalancer(r,s){await this.deleteLoadBalancerRaw(r,s)}async getLoadBalancersRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getLoadBalancers().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/load-balancers/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(ng))}async getLoadBalancers(r,s){return await(await this.getLoadBalancersRaw(r,s)).value()}async listLoadBalancersRaw(r,s){const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/load-balancers",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(ng))}async listLoadBalancers(r={},s){return await(await this.listLoadBalancersRaw(r,s)).value()}async updateLoadBalancerRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateLoadBalancer().');if(r.dtoUpdateLoadBalancerRequest==null)throw new et("dtoUpdateLoadBalancerRequest",'Required parameter "dtoUpdateLoadBalancerRequest" was null or undefined when calling updateLoadBalancer().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/load-balancers/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:WQ(r.dtoUpdateLoadBalancerRequest)},s);return new mt(m,g=>ng(g))}async updateLoadBalancer(r,s){return await(await this.updateLoadBalancerRaw(r,s)).value()}}class qee extends Gs{async getMeRaw(r){const s={},o={};this.configuration&&this.configuration.apiKey&&(o["X-API-KEY"]=await this.configuration.apiKey("X-API-KEY")),this.configuration&&this.configuration.apiKey&&(o.Authorization=await this.configuration.apiKey("Authorization"));const p=await this.request({path:"/me",method:"GET",headers:o,query:s},r);return new mt(p,m=>mee(m))}async getMe(r){return await(await this.getMeRaw(r)).value()}async updateMeRaw(r,s){if(r.handlersUpdateMeRequest==null)throw new et("handlersUpdateMeRequest",'Required parameter "handlersUpdateMeRequest" was null or undefined when calling updateMe().');const o={},d={};d["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(d["X-API-KEY"]=await this.configuration.apiKey("X-API-KEY")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/me",method:"PATCH",headers:d,query:o,body:kee(r.handlersUpdateMeRequest)},s);return new mt(m,g=>pL(g))}async updateMe(r,s){return await(await this.updateMeRaw(r,s)).value()}}class Bee extends Gs{async createUserAPIKeyRaw(r,s){if(r.handlersCreateUserKeyRequest==null)throw new et("handlersCreateUserKeyRequest",'Required parameter "handlersCreateUserKeyRequest" was null or undefined when calling createUserAPIKey().');const o={},d={};d["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(d["X-API-KEY"]=await this.configuration.apiKey("X-API-KEY")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/me/api-keys",method:"POST",headers:d,query:o,body:cee(r.handlersCreateUserKeyRequest)},s);return new mt(m,g=>FM(g))}async createUserAPIKey(r,s){return await(await this.createUserAPIKeyRaw(r,s)).value()}async deleteUserAPIKeyRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteUserAPIKey().');const o={},d={};this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/me/api-keys/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteUserAPIKey(r,s){await this.deleteUserAPIKeyRaw(r,s)}async listUserAPIKeysRaw(r){const s={},o={};this.configuration&&this.configuration.apiKey&&(o["X-API-KEY"]=await this.configuration.apiKey("X-API-KEY")),this.configuration&&this.configuration.apiKey&&(o.Authorization=await this.configuration.apiKey("Authorization"));const p=await this.request({path:"/me/api-keys",method:"GET",headers:o,query:s},r);return new mt(p,m=>m.map(FM))}async listUserAPIKeys(r){return await(await this.listUserAPIKeysRaw(r)).value()}}class Uee extends Gs{async attachNodePoolAnnotationsRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling attachNodePoolAnnotations().');if(r.dtoAttachAnnotationsRequest==null)throw new et("dtoAttachAnnotationsRequest",'Required parameter "dtoAttachAnnotationsRequest" was null or undefined when calling attachNodePoolAnnotations().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/annotations";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:CJ(r.dtoAttachAnnotationsRequest)},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async attachNodePoolAnnotations(r,s){return await(await this.attachNodePoolAnnotationsRaw(r,s)).value()}async attachNodePoolLabelsRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling attachNodePoolLabels().');if(r.dtoAttachLabelsRequest==null)throw new et("dtoAttachLabelsRequest",'Required parameter "dtoAttachLabelsRequest" was null or undefined when calling attachNodePoolLabels().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/labels";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:_J(r.dtoAttachLabelsRequest)},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async attachNodePoolLabels(r,s){return await(await this.attachNodePoolLabelsRaw(r,s)).value()}async attachNodePoolServersRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling attachNodePoolServers().');if(r.dtoAttachServersRequest==null)throw new et("dtoAttachServersRequest",'Required parameter "dtoAttachServersRequest" was null or undefined when calling attachNodePoolServers().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/servers";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:LJ(r.dtoAttachServersRequest)},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async attachNodePoolServers(r,s){return await(await this.attachNodePoolServersRaw(r,s)).value()}async attachNodePoolTaintsRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling attachNodePoolTaints().');if(r.dtoAttachTaintsRequest==null)throw new et("dtoAttachTaintsRequest",'Required parameter "dtoAttachTaintsRequest" was null or undefined when calling attachNodePoolTaints().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/taints";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:FJ(r.dtoAttachTaintsRequest)},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async attachNodePoolTaints(r,s){return await(await this.attachNodePoolTaintsRaw(r,s)).value()}async createNodePoolRaw(r,s){if(r.dtoCreateNodePoolRequest==null)throw new et("dtoCreateNodePoolRequest",'Required parameter "dtoCreateNodePoolRequest" was null or undefined when calling createNodePool().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/node-pools",method:"POST",headers:d,query:o,body:uQ(r.dtoCreateNodePoolRequest)},s);return new mt(m,g=>vb(g))}async createNodePool(r,s){return await(await this.createNodePoolRaw(r,s)).value()}async deleteNodePoolRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteNodePool().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteNodePool(r,s){await this.deleteNodePoolRaw(r,s)}async detachNodePoolAnnotationRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling detachNodePoolAnnotation().');if(r.annotationId==null)throw new et("annotationId",'Required parameter "annotationId" was null or undefined when calling detachNodePoolAnnotation().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/annotations/{annotationId}";p=p.replace("{id}",encodeURIComponent(String(r.id))),p=p.replace("{annotationId}",encodeURIComponent(String(r.annotationId)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async detachNodePoolAnnotation(r,s){return await(await this.detachNodePoolAnnotationRaw(r,s)).value()}async detachNodePoolLabelRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling detachNodePoolLabel().');if(r.labelId==null)throw new et("labelId",'Required parameter "labelId" was null or undefined when calling detachNodePoolLabel().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/labels/{labelId}";p=p.replace("{id}",encodeURIComponent(String(r.id))),p=p.replace("{labelId}",encodeURIComponent(String(r.labelId)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async detachNodePoolLabel(r,s){return await(await this.detachNodePoolLabelRaw(r,s)).value()}async detachNodePoolServerRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling detachNodePoolServer().');if(r.serverId==null)throw new et("serverId",'Required parameter "serverId" was null or undefined when calling detachNodePoolServer().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/servers/{serverId}";p=p.replace("{id}",encodeURIComponent(String(r.id))),p=p.replace("{serverId}",encodeURIComponent(String(r.serverId)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async detachNodePoolServer(r,s){return await(await this.detachNodePoolServerRaw(r,s)).value()}async detachNodePoolTaintRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling detachNodePoolTaint().');if(r.taintId==null)throw new et("taintId",'Required parameter "taintId" was null or undefined when calling detachNodePoolTaint().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/taints/{taintId}";p=p.replace("{id}",encodeURIComponent(String(r.id))),p=p.replace("{taintId}",encodeURIComponent(String(r.taintId)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async detachNodePoolTaint(r,s){return await(await this.detachNodePoolTaintRaw(r,s)).value()}async getNodePoolRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getNodePool().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>vb(g))}async getNodePool(r,s){return await(await this.getNodePoolRaw(r,s)).value()}async listNodePoolAnnotationsRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling listNodePoolAnnotations().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/annotations";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(tg))}async listNodePoolAnnotations(r,s){return await(await this.listNodePoolAnnotationsRaw(r,s)).value()}async listNodePoolLabelsRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling listNodePoolLabels().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/labels";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(sg))}async listNodePoolLabels(r,s){return await(await this.listNodePoolLabelsRaw(r,s)).value()}async listNodePoolServersRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling listNodePoolServers().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/servers";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(Id))}async listNodePoolServers(r,s){return await(await this.listNodePoolServersRaw(r,s)).value()}async listNodePoolTaintsRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling listNodePoolTaints().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}/taints";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(rg))}async listNodePoolTaints(r,s){return await(await this.listNodePoolTaintsRaw(r,s)).value()}async listNodePoolsRaw(r,s){const o={};r.q!=null&&(o.q=r.q);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/node-pools",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(vb))}async listNodePools(r={},s){return await(await this.listNodePoolsRaw(r,s)).value()}async updateNodePoolRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateNodePool().');if(r.dtoUpdateNodePoolRequest==null)throw new et("dtoUpdateNodePoolRequest",'Required parameter "dtoUpdateNodePoolRequest" was null or undefined when calling updateNodePool().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/node-pools/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:QQ(r.dtoUpdateNodePoolRequest)},s);return new mt(m,g=>vb(g))}async updateNodePool(r,s){return await(await this.updateNodePoolRaw(r,s)).value()}}class Kee extends Gs{async addOrUpdateMemberRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling addOrUpdateMember().');if(r.handlersMemberUpsertReq==null)throw new et("handlersMemberUpsertReq",'Required parameter "handlersMemberUpsertReq" was null or undefined when calling addOrUpdateMember().');const o={},d={};d["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/orgs/{id}/members";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:vee(r.handlersMemberUpsertReq)},s);return new mt(m,g=>zM(g))}async addOrUpdateMember(r,s){return await(await this.addOrUpdateMemberRaw(r,s)).value()}async createOrgRaw(r,s){if(r.handlersOrgCreateReq==null)throw new et("handlersOrgCreateReq",'Required parameter "handlersOrgCreateReq" was null or undefined when calling createOrg().');const o={},d={};d["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/orgs",method:"POST",headers:d,query:o,body:bee(r.handlersOrgCreateReq)},s);return new mt(m,g=>xb(g))}async createOrg(r,s){return await(await this.createOrgRaw(r,s)).value()}async createOrgKeyRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling createOrgKey().');if(r.handlersOrgKeyCreateReq==null)throw new et("handlersOrgKeyCreateReq",'Required parameter "handlersOrgKeyCreateReq" was null or undefined when calling createOrgKey().');const o={},d={};d["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/orgs/{id}/api-keys";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:See(r.handlersOrgKeyCreateReq)},s);return new mt(m,g=>jee(g))}async createOrgKey(r,s){return await(await this.createOrgKeyRaw(r,s)).value()}async deleteOrgRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteOrg().');const o={},d={};this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/orgs/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteOrg(r,s){await this.deleteOrgRaw(r,s)}async deleteOrgKeyRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteOrgKey().');if(r.keyId==null)throw new et("keyId",'Required parameter "keyId" was null or undefined when calling deleteOrgKey().');const o={},d={};this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/orgs/{id}/api-keys/{key_id}";p=p.replace("{id}",encodeURIComponent(String(r.id))),p=p.replace("{key_id}",encodeURIComponent(String(r.keyId)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteOrgKey(r,s){await this.deleteOrgKeyRaw(r,s)}async getOrgRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getOrg().');const o={},d={};this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/orgs/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>xb(g))}async getOrg(r,s){return await(await this.getOrgRaw(r,s)).value()}async listMembersRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling listMembers().');const o={},d={};this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/orgs/{id}/members";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(zM))}async listMembers(r,s){return await(await this.listMembersRaw(r,s)).value()}async listMyOrgsRaw(r){const s={},o={};this.configuration&&this.configuration.apiKey&&(o.Authorization=await this.configuration.apiKey("Authorization"));const p=await this.request({path:"/orgs",method:"GET",headers:o,query:s},r);return new mt(p,m=>m.map(xb))}async listMyOrgs(r){return await(await this.listMyOrgsRaw(r)).value()}async listOrgKeysRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling listOrgKeys().');const o={},d={};this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/orgs/{id}/api-keys";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(_ee))}async listOrgKeys(r,s){return await(await this.listOrgKeysRaw(r,s)).value()}async removeMemberRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling removeMember().');if(r.userId==null)throw new et("userId",'Required parameter "userId" was null or undefined when calling removeMember().');const o={},d={};this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/orgs/{id}/members/{user_id}";p=p.replace("{id}",encodeURIComponent(String(r.id))),p=p.replace("{user_id}",encodeURIComponent(String(r.userId)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async removeMember(r,s){await this.removeMemberRaw(r,s)}async updateOrgRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateOrg().');if(r.handlersOrgUpdateReq==null)throw new et("handlersOrgUpdateReq",'Required parameter "handlersOrgUpdateReq" was null or undefined when calling updateOrg().');const o={},d={};d["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/orgs/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:Aee(r.handlersOrgUpdateReq)},s);return new mt(m,g=>xb(g))}async updateOrg(r,s){return await(await this.updateOrgRaw(r,s)).value()}}class Vee extends Gs{async createServerRaw(r,s){if(r.dtoCreateServerRequest==null)throw new et("dtoCreateServerRequest",'Required parameter "dtoCreateServerRequest" was null or undefined when calling createServer().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/servers",method:"POST",headers:d,query:o,body:gQ(r.dtoCreateServerRequest)},s);return new mt(m,g=>Id(g))}async createServer(r,s){return await(await this.createServerRaw(r,s)).value()}async deleteServerRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteServer().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/servers/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteServer(r,s){await this.deleteServerRaw(r,s)}async getServerRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getServer().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/servers/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>Id(g))}async getServer(r,s){return await(await this.getServerRaw(r,s)).value()}async listServersRaw(r,s){const o={};r.status!=null&&(o.status=r.status),r.role!=null&&(o.role=r.role);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/servers",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(Id))}async listServers(r={},s){return await(await this.listServersRaw(r,s)).value()}async resetServerHostKeyRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling resetServerHostKey().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/servers/{id}/reset-hostkey";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"POST",headers:d,query:o,body:r.body},s);return new mt(m,g=>Id(g))}async resetServerHostKey(r,s){return await(await this.resetServerHostKeyRaw(r,s)).value()}async updateServerRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateServer().');if(r.dtoUpdateServerRequest==null)throw new et("dtoUpdateServerRequest",'Required parameter "dtoUpdateServerRequest" was null or undefined when calling updateServer().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/servers/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:ree(r.dtoUpdateServerRequest)},s);return new mt(m,g=>Id(g))}async updateServer(r,s){return await(await this.updateServerRaw(r,s)).value()}}class Hee extends Gs{async createSSHKeyRaw(r,s){if(r.dtoCreateSSHRequest==null)throw new et("dtoCreateSSHRequest",'Required parameter "dtoCreateSSHRequest" was null or undefined when calling createSSHKey().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/ssh",method:"POST",headers:d,query:o,body:fQ(r.dtoCreateSSHRequest)},s);return new mt(m,g=>IM(g))}async createSSHKey(r,s){return await(await this.createSSHKeyRaw(r,s)).value()}async deleteSSHKeyRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteSSHKey().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/ssh/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteSSHKey(r,s){await this.deleteSSHKeyRaw(r,s)}async downloadSSHKeyRaw(r,s){if(r.xOrgID==null)throw new et("xOrgID",'Required parameter "xOrgID" was null or undefined when calling downloadSSHKey().');if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling downloadSSHKey().');if(r.part==null)throw new et("part",'Required parameter "part" was null or undefined when calling downloadSSHKey().');const o={};r.part!=null&&(o.part=r.part);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/ssh/{id}/download";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return this.isJsonMime(m.headers.get("content-type"))?new mt(m):new ec(m)}async downloadSSHKey(r,s){return await(await this.downloadSSHKeyRaw(r,s)).value()}async getSSHKeyRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getSSHKey().');const o={};r.reveal!=null&&(o.reveal=r.reveal);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/ssh/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>oee(g))}async getSSHKey(r,s){return await(await this.getSSHKeyRaw(r,s)).value()}async listPublicSshKeysRaw(r,s){const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/ssh",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(IM))}async listPublicSshKeys(r={},s){return await(await this.listPublicSshKeysRaw(r,s)).value()}}class Gee extends Gs{async createTaintRaw(r,s){if(r.dtoCreateTaintRequest==null)throw new et("dtoCreateTaintRequest",'Required parameter "dtoCreateTaintRequest" was null or undefined when calling createTaint().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/taints",method:"POST",headers:d,query:o,body:vQ(r.dtoCreateTaintRequest)},s);return new mt(m,g=>rg(g))}async createTaint(r,s){return await(await this.createTaintRaw(r,s)).value()}async deleteTaintRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling deleteTaint().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/taints/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"DELETE",headers:d,query:o},s);return new Ii(m)}async deleteTaint(r,s){await this.deleteTaintRaw(r,s)}async getTaintRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling getTaint().');const o={},d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/taints/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"GET",headers:d,query:o},s);return new mt(m,g=>rg(g))}async getTaint(r,s){return await(await this.getTaintRaw(r,s)).value()}async listTaintsRaw(r,s){const o={};r.key!=null&&(o.key=r.key),r.value!=null&&(o.value=r.value),r.q!=null&&(o.q=r.q);const d={};r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));const m=await this.request({path:"/taints",method:"GET",headers:d,query:o},s);return new mt(m,g=>g.map(rg))}async listTaints(r={},s){return await(await this.listTaintsRaw(r,s)).value()}async updateTaintRaw(r,s){if(r.id==null)throw new et("id",'Required parameter "id" was null or undefined when calling updateTaint().');if(r.dtoUpdateTaintRequest==null)throw new et("dtoUpdateTaintRequest",'Required parameter "dtoUpdateTaintRequest" was null or undefined when calling updateTaint().');const o={},d={};d["Content-Type"]="application/json",r.xOrgID!=null&&(d["X-Org-ID"]=String(r.xOrgID)),this.configuration&&this.configuration.apiKey&&(d["X-ORG-KEY"]=await this.configuration.apiKey("X-ORG-KEY")),this.configuration&&this.configuration.apiKey&&(d["X-ORG-SECRET"]=await this.configuration.apiKey("X-ORG-SECRET")),this.configuration&&this.configuration.apiKey&&(d.Authorization=await this.configuration.apiKey("Authorization"));let p="/taints/{id}";p=p.replace("{id}",encodeURIComponent(String(r.id)));const m=await this.request({path:p,method:"PATCH",headers:d,query:o,body:iee(r.dtoUpdateTaintRequest)},s);return new mt(m,g=>rg(g))}async updateTaint(r,s){return await(await this.updateTaintRaw(r,s)).value()}}const B_="/api/v1";function Xee(){return new cL({basePath:B_,accessToken:async()=>Ks.getAccessToken()??"",middleware:[{async pre(e){const r=new Headers(e.init?.headers??{});e.init?.body!=null&&!(e.init.body instanceof FormData)&&!(e.init.body instanceof Blob)&&!r.has("Content-Type")&&r.set("Content-Type","application/json");const o=Ks.getAccessToken();o&&r.set("Authorization",`Bearer ${o}`);const d=Qo.get();return d&&r.set("X-Org-ID",d),{...e,init:{...e.init,headers:r}}},async post(e){return e.response}}]})}function Ui(e){return new e(Xee())}function Yee(){return Ui(Pee)}function Zee(){return Ui(qee)}function Wee(){return Ui(Bee)}function gC(){return Ui(Kee)}function Jee(){return Ui(Hee)}function Qee(){return Ui(Vee)}function ete(){return Ui(Gee)}function tte(){return Ui(zee)}function nte(){return Ui(Nee)}function rte(){return Ui(Dee)}function ste(){return Ui(Uee)}function ite(){return Ui(Iee)}function ate(){return Ui(Lee)}function ote(){return Ui(Fee)}function lte(){return Ui(Mee)}let BE=null;async function cte(){const e=Ks.get();if(!e?.refresh_token)return!1;try{const r=await fetch(`${B_}/auth/refresh`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({refresh_token:e.refresh_token})});if(!r.ok)return!1;const s=await r.json();return Ks.set(s),!0}catch{return!1}}async function qM(){return BE||(BE=cte().finally(()=>{BE=null})),BE}function ute(e){return e?.status===401||e?.cause?.status===401||e?.response?.status===401||e instanceof Response&&e.status===401}async function ut(e){Ks.willExpireSoon?.(30)&&await qM();try{return await e()}catch(r){if(!ute(r)||!await qM())throw r;return await e()}}const BM=Zee(),$R=Wee(),yp={getMe:()=>ut(async()=>await BM.getMe()),updateMe:e=>ut(async()=>await BM.updateMe({handlersUpdateMeRequest:e})),listKeys:()=>ut(async()=>await $R.listUserAPIKeys()),createKey:e=>ut(async()=>await $R.createUserAPIKey({handlersCreateUserKeyRequest:e})),deleteKey:e=>ut(async()=>(await $R.deleteUserAPIKey({id:e}),!0))},dte={footer:async()=>{const e=await fetch("/api/v1/version",{cache:"no-store"});if(!e.ok)throw new Error("failed to fetch version");return await e.json()}};function UM(e,r){if(typeof e=="function")return e(r);e!=null&&(e.current=r)}function Li(...e){return r=>{let s=!1;const o=e.map(d=>{const p=UM(d,r);return!s&&typeof p=="function"&&(s=!0),p});if(s)return()=>{for(let d=0;d{let{children:p,...m}=o;fL(p)&&typeof Tj=="function"&&(p=Tj(p._payload));const g=R.Children.toArray(p),b=g.find(gte);if(b){const S=b.props.children,j=g.map(A=>A===b?R.Children.count(S)>1?R.Children.only(null):R.isValidElement(S)?S.props.children:null:A);return u.jsx(r,{...m,ref:d,children:R.isValidElement(S)?R.cloneElement(S,void 0,j):null})}return u.jsx(r,{...m,ref:d,children:p})});return s.displayName=`${e}.Slot`,s}var Cg=Qb("Slot");function fte(e){const r=R.forwardRef((s,o)=>{let{children:d,...p}=s;if(fL(d)&&typeof Tj=="function"&&(d=Tj(d._payload)),R.isValidElement(d)){const m=vte(d),g=yte(p,d.props);return d.type!==R.Fragment&&(g.ref=o?Li(o,m):m),R.cloneElement(d,g)}return R.Children.count(d)>1?R.Children.only(null):null});return r.displayName=`${e}.SlotClone`,r}var mte=Symbol("radix.slottable");function gte(e){return R.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===mte}function yte(e,r){const s={...r};for(const o in r){const d=e[o],p=r[o];/^on[A-Z]/.test(o)?d&&p?s[o]=(...g)=>{const b=p(...g);return d(...g),b}:d&&(s[o]=d):o==="style"?s[o]={...d,...p}:o==="className"&&(s[o]=[d,p].filter(Boolean).join(" "))}return{...e,...s}}function vte(e){let r=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning;return s?e.ref:(r=Object.getOwnPropertyDescriptor(e,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning,s?e.props.ref:e.props.ref||e.ref)}function mL(e){var r,s,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var d=e.length;for(r=0;rtypeof e=="boolean"?`${e}`:e===0?"0":e,VM=gL,U_=(e,r)=>s=>{var o;if(r?.variants==null)return VM(e,s?.class,s?.className);const{variants:d,defaultVariants:p}=r,m=Object.keys(d).map(S=>{const j=s?.[S],A=p?.[S];if(j===null)return null;const k=KM(j)||KM(A);return d[S][k]}),g=s&&Object.entries(s).reduce((S,j)=>{let[A,k]=j;return k===void 0||(S[A]=k),S},{}),b=r==null||(o=r.compoundVariants)===null||o===void 0?void 0:o.reduce((S,j)=>{let{class:A,className:k,...T}=j;return Object.entries(T).every(M=>{let[I,q]=M;return Array.isArray(q)?q.includes({...p,...g}[I]):{...p,...g}[I]===q})?[...S,A,k]:S},[]);return VM(e,m,b,s?.class,s?.className)},xte=(e,r)=>{const s=new Array(e.length+r.length);for(let o=0;o({classGroupId:e,validator:r}),yL=(e=new Map,r=null,s)=>({nextPart:e,validators:r,classGroupId:s}),_j="-",HM=[],wte="arbitrary..",Ste=e=>{const r=jte(e),{conflictingClassGroups:s,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:m=>{if(m.startsWith("[")&&m.endsWith("]"))return Ete(m);const g=m.split(_j),b=g[0]===""&&g.length>1?1:0;return vL(g,b,r)},getConflictingClassGroupIds:(m,g)=>{if(g){const b=o[m],S=s[m];return b?S?xte(S,b):b:S||HM}return s[m]||HM}}},vL=(e,r,s)=>{if(e.length-r===0)return s.classGroupId;const d=e[r],p=s.nextPart.get(d);if(p){const S=vL(e,r+1,p);if(S)return S}const m=s.validators;if(m===null)return;const g=r===0?e.join(_j):e.slice(r).join(_j),b=m.length;for(let S=0;Se.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const r=e.slice(1,-1),s=r.indexOf(":"),o=r.slice(0,s);return o?wte+o:void 0})(),jte=e=>{const{theme:r,classGroups:s}=e;return Cte(s,r)},Cte=(e,r)=>{const s=yL();for(const o in e){const d=e[o];K_(d,s,o,r)}return s},K_=(e,r,s,o)=>{const d=e.length;for(let p=0;p{if(typeof e=="string"){Ote(e,r,s);return}if(typeof e=="function"){kte(e,r,s,o);return}Rte(e,r,s,o)},Ote=(e,r,s)=>{const o=e===""?r:xL(r,e);o.classGroupId=s},kte=(e,r,s,o)=>{if(Tte(e)){K_(e(o),r,s,o);return}r.validators===null&&(r.validators=[]),r.validators.push(bte(s,e))},Rte=(e,r,s,o)=>{const d=Object.entries(e),p=d.length;for(let m=0;m{let s=e;const o=r.split(_j),d=o.length;for(let p=0;p"isThemeGetter"in e&&e.isThemeGetter===!0,_te=e=>{if(e<1)return{get:()=>{},set:()=>{}};let r=0,s=Object.create(null),o=Object.create(null);const d=(p,m)=>{s[p]=m,r++,r>e&&(r=0,o=s,s=Object.create(null))};return{get(p){let m=s[p];if(m!==void 0)return m;if((m=o[p])!==void 0)return d(p,m),m},set(p,m){p in s?s[p]=m:d(p,m)}}},NT="!",GM=":",$te=[],XM=(e,r,s,o,d)=>({modifiers:e,hasImportantModifier:r,baseClassName:s,maybePostfixModifierPosition:o,isExternal:d}),Nte=e=>{const{prefix:r,experimentalParseClassName:s}=e;let o=d=>{const p=[];let m=0,g=0,b=0,S;const j=d.length;for(let I=0;Ib?S-b:void 0;return XM(p,T,k,M)};if(r){const d=r+GM,p=o;o=m=>m.startsWith(d)?p(m.slice(d.length)):XM($te,!1,m,void 0,!0)}if(s){const d=o;o=p=>s({className:p,parseClassName:d})}return o},Dte=e=>{const r=new Map;return e.orderSensitiveModifiers.forEach((s,o)=>{r.set(s,1e6+o)}),s=>{const o=[];let d=[];for(let p=0;p0&&(d.sort(),o.push(...d),d=[]),o.push(m)):d.push(m)}return d.length>0&&(d.sort(),o.push(...d)),o}},Pte=e=>({cache:_te(e.cacheSize),parseClassName:Nte(e),sortModifiers:Dte(e),...Ste(e)}),Mte=/\s+/,Ite=(e,r)=>{const{parseClassName:s,getClassGroupId:o,getConflictingClassGroupIds:d,sortModifiers:p}=r,m=[],g=e.trim().split(Mte);let b="";for(let S=g.length-1;S>=0;S-=1){const j=g[S],{isExternal:A,modifiers:k,hasImportantModifier:T,baseClassName:M,maybePostfixModifierPosition:I}=s(j);if(A){b=j+(b.length>0?" "+b:b);continue}let q=!!I,G=o(q?M.substring(0,I):M);if(!G){if(!q){b=j+(b.length>0?" "+b:b);continue}if(G=o(M),!G){b=j+(b.length>0?" "+b:b);continue}q=!1}const K=k.length===0?"":k.length===1?k[0]:p(k).join(":"),X=T?K+NT:K,L=X+G;if(m.indexOf(L)>-1)continue;m.push(L);const ee=d(G,q);for(let oe=0;oe0?" "+b:b)}return b},Lte=(...e)=>{let r=0,s,o,d="";for(;r{if(typeof e=="string")return e;let r,s="";for(let o=0;o{let s,o,d,p;const m=b=>{const S=r.reduce((j,A)=>A(j),e());return s=Pte(S),o=s.cache.get,d=s.cache.set,p=g,g(b)},g=b=>{const S=o(b);if(S)return S;const j=Ite(b,s);return d(b,j),j};return p=m,(...b)=>p(Lte(...b))},Fte=[],bs=e=>{const r=s=>s[e]||Fte;return r.isThemeGetter=!0,r},wL=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,SL=/^\((?:(\w[\w-]*):)?(.+)\)$/i,qte=/^\d+\/\d+$/,Bte=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Ute=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Kte=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Vte=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Hte=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Km=e=>qte.test(e),jn=e=>!!e&&!Number.isNaN(Number(e)),Nd=e=>!!e&&Number.isInteger(Number(e)),NR=e=>e.endsWith("%")&&jn(e.slice(0,-1)),lu=e=>Bte.test(e),Gte=()=>!0,Xte=e=>Ute.test(e)&&!Kte.test(e),EL=()=>!1,Yte=e=>Vte.test(e),Zte=e=>Hte.test(e),Wte=e=>!Mt(e)&&!It(e),Jte=e=>Ag(e,AL,EL),Mt=e=>wL.test(e),fp=e=>Ag(e,OL,Xte),DR=e=>Ag(e,rne,jn),YM=e=>Ag(e,jL,EL),Qte=e=>Ag(e,CL,Zte),UE=e=>Ag(e,kL,Yte),It=e=>SL.test(e),sb=e=>Og(e,OL),ene=e=>Og(e,sne),ZM=e=>Og(e,jL),tne=e=>Og(e,AL),nne=e=>Og(e,CL),KE=e=>Og(e,kL,!0),Ag=(e,r,s)=>{const o=wL.exec(e);return o?o[1]?r(o[1]):s(o[2]):!1},Og=(e,r,s=!1)=>{const o=SL.exec(e);return o?o[1]?r(o[1]):s:!1},jL=e=>e==="position"||e==="percentage",CL=e=>e==="image"||e==="url",AL=e=>e==="length"||e==="size"||e==="bg-size",OL=e=>e==="length",rne=e=>e==="number",sne=e=>e==="family-name",kL=e=>e==="shadow",ine=()=>{const e=bs("color"),r=bs("font"),s=bs("text"),o=bs("font-weight"),d=bs("tracking"),p=bs("leading"),m=bs("breakpoint"),g=bs("container"),b=bs("spacing"),S=bs("radius"),j=bs("shadow"),A=bs("inset-shadow"),k=bs("text-shadow"),T=bs("drop-shadow"),M=bs("blur"),I=bs("perspective"),q=bs("aspect"),G=bs("ease"),K=bs("animate"),X=()=>["auto","avoid","all","avoid-page","page","left","right","column"],L=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],ee=()=>[...L(),It,Mt],oe=()=>["auto","hidden","clip","visible","scroll"],Q=()=>["auto","contain","none"],ne=()=>[It,Mt,b],de=()=>[Km,"full","auto",...ne()],je=()=>[Nd,"none","subgrid",It,Mt],ve=()=>["auto",{span:["full",Nd,It,Mt]},Nd,It,Mt],le=()=>[Nd,"auto",It,Mt],be=()=>["auto","min","max","fr",It,Mt],Ce=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],Ke=()=>["start","end","center","stretch","center-safe","end-safe"],ce=()=>["auto",...ne()],re=()=>[Km,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...ne()],ue=()=>[e,It,Mt],_e=()=>[...L(),ZM,YM,{position:[It,Mt]}],fe=()=>["no-repeat",{repeat:["","x","y","space","round"]}],He=()=>["auto","cover","contain",tne,Jte,{size:[It,Mt]}],Oe=()=>[NR,sb,fp],ke=()=>["","none","full",S,It,Mt],Ve=()=>["",jn,sb,fp],ie=()=>["solid","dashed","dotted","double"],De=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Le=()=>[jn,NR,ZM,YM],tt=()=>["","none",M,It,Mt],yt=()=>["none",jn,It,Mt],Ot=()=>["none",jn,It,Mt],Ft=()=>[jn,It,Mt],kt=()=>[Km,"full",...ne()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[lu],breakpoint:[lu],color:[Gte],container:[lu],"drop-shadow":[lu],ease:["in","out","in-out"],font:[Wte],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[lu],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[lu],shadow:[lu],spacing:["px",jn],text:[lu],"text-shadow":[lu],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Km,Mt,It,q]}],container:["container"],columns:[{columns:[jn,Mt,It,g]}],"break-after":[{"break-after":X()}],"break-before":[{"break-before":X()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:ee()}],overflow:[{overflow:oe()}],"overflow-x":[{"overflow-x":oe()}],"overflow-y":[{"overflow-y":oe()}],overscroll:[{overscroll:Q()}],"overscroll-x":[{"overscroll-x":Q()}],"overscroll-y":[{"overscroll-y":Q()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:de()}],"inset-x":[{"inset-x":de()}],"inset-y":[{"inset-y":de()}],start:[{start:de()}],end:[{end:de()}],top:[{top:de()}],right:[{right:de()}],bottom:[{bottom:de()}],left:[{left:de()}],visibility:["visible","invisible","collapse"],z:[{z:[Nd,"auto",It,Mt]}],basis:[{basis:[Km,"full","auto",g,...ne()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[jn,Km,"auto","initial","none",Mt]}],grow:[{grow:["",jn,It,Mt]}],shrink:[{shrink:["",jn,It,Mt]}],order:[{order:[Nd,"first","last","none",It,Mt]}],"grid-cols":[{"grid-cols":je()}],"col-start-end":[{col:ve()}],"col-start":[{"col-start":le()}],"col-end":[{"col-end":le()}],"grid-rows":[{"grid-rows":je()}],"row-start-end":[{row:ve()}],"row-start":[{"row-start":le()}],"row-end":[{"row-end":le()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":be()}],"auto-rows":[{"auto-rows":be()}],gap:[{gap:ne()}],"gap-x":[{"gap-x":ne()}],"gap-y":[{"gap-y":ne()}],"justify-content":[{justify:[...Ce(),"normal"]}],"justify-items":[{"justify-items":[...Ke(),"normal"]}],"justify-self":[{"justify-self":["auto",...Ke()]}],"align-content":[{content:["normal",...Ce()]}],"align-items":[{items:[...Ke(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...Ke(),{baseline:["","last"]}]}],"place-content":[{"place-content":Ce()}],"place-items":[{"place-items":[...Ke(),"baseline"]}],"place-self":[{"place-self":["auto",...Ke()]}],p:[{p:ne()}],px:[{px:ne()}],py:[{py:ne()}],ps:[{ps:ne()}],pe:[{pe:ne()}],pt:[{pt:ne()}],pr:[{pr:ne()}],pb:[{pb:ne()}],pl:[{pl:ne()}],m:[{m:ce()}],mx:[{mx:ce()}],my:[{my:ce()}],ms:[{ms:ce()}],me:[{me:ce()}],mt:[{mt:ce()}],mr:[{mr:ce()}],mb:[{mb:ce()}],ml:[{ml:ce()}],"space-x":[{"space-x":ne()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":ne()}],"space-y-reverse":["space-y-reverse"],size:[{size:re()}],w:[{w:[g,"screen",...re()]}],"min-w":[{"min-w":[g,"screen","none",...re()]}],"max-w":[{"max-w":[g,"screen","none","prose",{screen:[m]},...re()]}],h:[{h:["screen","lh",...re()]}],"min-h":[{"min-h":["screen","lh","none",...re()]}],"max-h":[{"max-h":["screen","lh",...re()]}],"font-size":[{text:["base",s,sb,fp]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[o,It,DR]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",NR,Mt]}],"font-family":[{font:[ene,Mt,r]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[d,It,Mt]}],"line-clamp":[{"line-clamp":[jn,"none",It,DR]}],leading:[{leading:[p,...ne()]}],"list-image":[{"list-image":["none",It,Mt]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",It,Mt]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:ue()}],"text-color":[{text:ue()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ie(),"wavy"]}],"text-decoration-thickness":[{decoration:[jn,"from-font","auto",It,fp]}],"text-decoration-color":[{decoration:ue()}],"underline-offset":[{"underline-offset":[jn,"auto",It,Mt]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:ne()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",It,Mt]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",It,Mt]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:_e()}],"bg-repeat":[{bg:fe()}],"bg-size":[{bg:He()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Nd,It,Mt],radial:["",It,Mt],conic:[Nd,It,Mt]},nne,Qte]}],"bg-color":[{bg:ue()}],"gradient-from-pos":[{from:Oe()}],"gradient-via-pos":[{via:Oe()}],"gradient-to-pos":[{to:Oe()}],"gradient-from":[{from:ue()}],"gradient-via":[{via:ue()}],"gradient-to":[{to:ue()}],rounded:[{rounded:ke()}],"rounded-s":[{"rounded-s":ke()}],"rounded-e":[{"rounded-e":ke()}],"rounded-t":[{"rounded-t":ke()}],"rounded-r":[{"rounded-r":ke()}],"rounded-b":[{"rounded-b":ke()}],"rounded-l":[{"rounded-l":ke()}],"rounded-ss":[{"rounded-ss":ke()}],"rounded-se":[{"rounded-se":ke()}],"rounded-ee":[{"rounded-ee":ke()}],"rounded-es":[{"rounded-es":ke()}],"rounded-tl":[{"rounded-tl":ke()}],"rounded-tr":[{"rounded-tr":ke()}],"rounded-br":[{"rounded-br":ke()}],"rounded-bl":[{"rounded-bl":ke()}],"border-w":[{border:Ve()}],"border-w-x":[{"border-x":Ve()}],"border-w-y":[{"border-y":Ve()}],"border-w-s":[{"border-s":Ve()}],"border-w-e":[{"border-e":Ve()}],"border-w-t":[{"border-t":Ve()}],"border-w-r":[{"border-r":Ve()}],"border-w-b":[{"border-b":Ve()}],"border-w-l":[{"border-l":Ve()}],"divide-x":[{"divide-x":Ve()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":Ve()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ie(),"hidden","none"]}],"divide-style":[{divide:[...ie(),"hidden","none"]}],"border-color":[{border:ue()}],"border-color-x":[{"border-x":ue()}],"border-color-y":[{"border-y":ue()}],"border-color-s":[{"border-s":ue()}],"border-color-e":[{"border-e":ue()}],"border-color-t":[{"border-t":ue()}],"border-color-r":[{"border-r":ue()}],"border-color-b":[{"border-b":ue()}],"border-color-l":[{"border-l":ue()}],"divide-color":[{divide:ue()}],"outline-style":[{outline:[...ie(),"none","hidden"]}],"outline-offset":[{"outline-offset":[jn,It,Mt]}],"outline-w":[{outline:["",jn,sb,fp]}],"outline-color":[{outline:ue()}],shadow:[{shadow:["","none",j,KE,UE]}],"shadow-color":[{shadow:ue()}],"inset-shadow":[{"inset-shadow":["none",A,KE,UE]}],"inset-shadow-color":[{"inset-shadow":ue()}],"ring-w":[{ring:Ve()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:ue()}],"ring-offset-w":[{"ring-offset":[jn,fp]}],"ring-offset-color":[{"ring-offset":ue()}],"inset-ring-w":[{"inset-ring":Ve()}],"inset-ring-color":[{"inset-ring":ue()}],"text-shadow":[{"text-shadow":["none",k,KE,UE]}],"text-shadow-color":[{"text-shadow":ue()}],opacity:[{opacity:[jn,It,Mt]}],"mix-blend":[{"mix-blend":[...De(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":De()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[jn]}],"mask-image-linear-from-pos":[{"mask-linear-from":Le()}],"mask-image-linear-to-pos":[{"mask-linear-to":Le()}],"mask-image-linear-from-color":[{"mask-linear-from":ue()}],"mask-image-linear-to-color":[{"mask-linear-to":ue()}],"mask-image-t-from-pos":[{"mask-t-from":Le()}],"mask-image-t-to-pos":[{"mask-t-to":Le()}],"mask-image-t-from-color":[{"mask-t-from":ue()}],"mask-image-t-to-color":[{"mask-t-to":ue()}],"mask-image-r-from-pos":[{"mask-r-from":Le()}],"mask-image-r-to-pos":[{"mask-r-to":Le()}],"mask-image-r-from-color":[{"mask-r-from":ue()}],"mask-image-r-to-color":[{"mask-r-to":ue()}],"mask-image-b-from-pos":[{"mask-b-from":Le()}],"mask-image-b-to-pos":[{"mask-b-to":Le()}],"mask-image-b-from-color":[{"mask-b-from":ue()}],"mask-image-b-to-color":[{"mask-b-to":ue()}],"mask-image-l-from-pos":[{"mask-l-from":Le()}],"mask-image-l-to-pos":[{"mask-l-to":Le()}],"mask-image-l-from-color":[{"mask-l-from":ue()}],"mask-image-l-to-color":[{"mask-l-to":ue()}],"mask-image-x-from-pos":[{"mask-x-from":Le()}],"mask-image-x-to-pos":[{"mask-x-to":Le()}],"mask-image-x-from-color":[{"mask-x-from":ue()}],"mask-image-x-to-color":[{"mask-x-to":ue()}],"mask-image-y-from-pos":[{"mask-y-from":Le()}],"mask-image-y-to-pos":[{"mask-y-to":Le()}],"mask-image-y-from-color":[{"mask-y-from":ue()}],"mask-image-y-to-color":[{"mask-y-to":ue()}],"mask-image-radial":[{"mask-radial":[It,Mt]}],"mask-image-radial-from-pos":[{"mask-radial-from":Le()}],"mask-image-radial-to-pos":[{"mask-radial-to":Le()}],"mask-image-radial-from-color":[{"mask-radial-from":ue()}],"mask-image-radial-to-color":[{"mask-radial-to":ue()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":L()}],"mask-image-conic-pos":[{"mask-conic":[jn]}],"mask-image-conic-from-pos":[{"mask-conic-from":Le()}],"mask-image-conic-to-pos":[{"mask-conic-to":Le()}],"mask-image-conic-from-color":[{"mask-conic-from":ue()}],"mask-image-conic-to-color":[{"mask-conic-to":ue()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:_e()}],"mask-repeat":[{mask:fe()}],"mask-size":[{mask:He()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",It,Mt]}],filter:[{filter:["","none",It,Mt]}],blur:[{blur:tt()}],brightness:[{brightness:[jn,It,Mt]}],contrast:[{contrast:[jn,It,Mt]}],"drop-shadow":[{"drop-shadow":["","none",T,KE,UE]}],"drop-shadow-color":[{"drop-shadow":ue()}],grayscale:[{grayscale:["",jn,It,Mt]}],"hue-rotate":[{"hue-rotate":[jn,It,Mt]}],invert:[{invert:["",jn,It,Mt]}],saturate:[{saturate:[jn,It,Mt]}],sepia:[{sepia:["",jn,It,Mt]}],"backdrop-filter":[{"backdrop-filter":["","none",It,Mt]}],"backdrop-blur":[{"backdrop-blur":tt()}],"backdrop-brightness":[{"backdrop-brightness":[jn,It,Mt]}],"backdrop-contrast":[{"backdrop-contrast":[jn,It,Mt]}],"backdrop-grayscale":[{"backdrop-grayscale":["",jn,It,Mt]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[jn,It,Mt]}],"backdrop-invert":[{"backdrop-invert":["",jn,It,Mt]}],"backdrop-opacity":[{"backdrop-opacity":[jn,It,Mt]}],"backdrop-saturate":[{"backdrop-saturate":[jn,It,Mt]}],"backdrop-sepia":[{"backdrop-sepia":["",jn,It,Mt]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":ne()}],"border-spacing-x":[{"border-spacing-x":ne()}],"border-spacing-y":[{"border-spacing-y":ne()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",It,Mt]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[jn,"initial",It,Mt]}],ease:[{ease:["linear","initial",G,It,Mt]}],delay:[{delay:[jn,It,Mt]}],animate:[{animate:["none",K,It,Mt]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[I,It,Mt]}],"perspective-origin":[{"perspective-origin":ee()}],rotate:[{rotate:yt()}],"rotate-x":[{"rotate-x":yt()}],"rotate-y":[{"rotate-y":yt()}],"rotate-z":[{"rotate-z":yt()}],scale:[{scale:Ot()}],"scale-x":[{"scale-x":Ot()}],"scale-y":[{"scale-y":Ot()}],"scale-z":[{"scale-z":Ot()}],"scale-3d":["scale-3d"],skew:[{skew:Ft()}],"skew-x":[{"skew-x":Ft()}],"skew-y":[{"skew-y":Ft()}],transform:[{transform:[It,Mt,"","none","gpu","cpu"]}],"transform-origin":[{origin:ee()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:kt()}],"translate-x":[{"translate-x":kt()}],"translate-y":[{"translate-y":kt()}],"translate-z":[{"translate-z":kt()}],"translate-none":["translate-none"],accent:[{accent:ue()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:ue()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",It,Mt]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":ne()}],"scroll-mx":[{"scroll-mx":ne()}],"scroll-my":[{"scroll-my":ne()}],"scroll-ms":[{"scroll-ms":ne()}],"scroll-me":[{"scroll-me":ne()}],"scroll-mt":[{"scroll-mt":ne()}],"scroll-mr":[{"scroll-mr":ne()}],"scroll-mb":[{"scroll-mb":ne()}],"scroll-ml":[{"scroll-ml":ne()}],"scroll-p":[{"scroll-p":ne()}],"scroll-px":[{"scroll-px":ne()}],"scroll-py":[{"scroll-py":ne()}],"scroll-ps":[{"scroll-ps":ne()}],"scroll-pe":[{"scroll-pe":ne()}],"scroll-pt":[{"scroll-pt":ne()}],"scroll-pr":[{"scroll-pr":ne()}],"scroll-pb":[{"scroll-pb":ne()}],"scroll-pl":[{"scroll-pl":ne()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",It,Mt]}],fill:[{fill:["none",...ue()]}],"stroke-w":[{stroke:[jn,sb,fp,DR]}],stroke:[{stroke:["none",...ue()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},ane=zte(ine);function ft(...e){return ane(gL(e))}function el(e,r=24){return!e||e.length<=r*2+3?e:`${e.slice(0,r)}…${e.slice(-r)}`}const one=U_("inline-flex items-center justify-center rounded-full border px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground [a&]:hover:bg-primary/90",secondary:"border-transparent bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",destructive:"border-transparent bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground"}},defaultVariants:{variant:"default"}});function ns({className:e,variant:r,asChild:s=!1,...o}){const d=s?Cg:"span";return u.jsx(d,{"data-slot":"badge",className:ft(one({variant:r}),e),...o})}const V_=U_("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",sm:"h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9","icon-sm":"size-8","icon-lg":"size-10"}},defaultVariants:{variant:"default",size:"default"}});function Fe({className:e,variant:r,size:s,asChild:o=!1,...d}){const p=o?Cg:"button";return u.jsx(p,{"data-slot":"button",className:ft(V_({variant:r,size:s,className:e})),...d})}var lne=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],cne=lne.reduce((e,r)=>{const s=Qb(`Primitive.${r}`),o=R.forwardRef((d,p)=>{const{asChild:m,...g}=d,b=m?s:r;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(b,{...g,ref:p})});return o.displayName=`Primitive.${r}`,{...e,[r]:o}},{}),une="Separator",WM="horizontal",dne=["horizontal","vertical"],RL=R.forwardRef((e,r)=>{const{decorative:s,orientation:o=WM,...d}=e,p=hne(o)?o:WM,g=s?{role:"none"}:{"aria-orientation":p==="vertical"?p:void 0,role:"separator"};return u.jsx(cne.div,{"data-orientation":p,...g,...d,ref:r})});RL.displayName=une;function hne(e){return dne.includes(e)}var pne=RL;function bb({className:e,orientation:r="horizontal",decorative:s=!0,...o}){return u.jsx(pne,{"data-slot":"separator",decorative:s,orientation:r,className:ft("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",e),...o})}function $t(e,r,{checkForDefaultPrevented:s=!0}={}){return function(d){if(e?.(d),s===!1||!d.defaultPrevented)return r?.(d)}}function fne(e,r){const s=R.createContext(r),o=p=>{const{children:m,...g}=p,b=R.useMemo(()=>g,Object.values(g));return u.jsx(s.Provider,{value:b,children:m})};o.displayName=e+"Provider";function d(p){const m=R.useContext(s);if(m)return m;if(r!==void 0)return r;throw new Error(`\`${p}\` must be used within \`${e}\``)}return[o,d]}function al(e,r=[]){let s=[];function o(p,m){const g=R.createContext(m),b=s.length;s=[...s,m];const S=A=>{const{scope:k,children:T,...M}=A,I=k?.[e]?.[b]||g,q=R.useMemo(()=>M,Object.values(M));return u.jsx(I.Provider,{value:q,children:T})};S.displayName=p+"Provider";function j(A,k){const T=k?.[e]?.[b]||g,M=R.useContext(T);if(M)return M;if(m!==void 0)return m;throw new Error(`\`${A}\` must be used within \`${p}\``)}return[S,j]}const d=()=>{const p=s.map(m=>R.createContext(m));return function(g){const b=g?.[e]||p;return R.useMemo(()=>({[`__scope${e}`]:{...g,[e]:b}}),[g,b])}};return d.scopeName=e,[o,mne(d,...r)]}function mne(...e){const r=e[0];if(e.length===1)return r;const s=()=>{const o=e.map(d=>({useScope:d(),scopeName:d.scopeName}));return function(p){const m=o.reduce((g,{useScope:b,scopeName:S})=>{const A=b(p)[`__scope${S}`];return{...g,...A}},{});return R.useMemo(()=>({[`__scope${r.scopeName}`]:m}),[m])}};return s.scopeName=r.scopeName,s}function gne(e){const r=yne(e),s=R.forwardRef((o,d)=>{const{children:p,...m}=o,g=R.Children.toArray(p),b=g.find(xne);if(b){const S=b.props.children,j=g.map(A=>A===b?R.Children.count(S)>1?R.Children.only(null):R.isValidElement(S)?S.props.children:null:A);return u.jsx(r,{...m,ref:d,children:R.isValidElement(S)?R.cloneElement(S,void 0,j):null})}return u.jsx(r,{...m,ref:d,children:p})});return s.displayName=`${e}.Slot`,s}function yne(e){const r=R.forwardRef((s,o)=>{const{children:d,...p}=s;if(R.isValidElement(d)){const m=wne(d),g=bne(p,d.props);return d.type!==R.Fragment&&(g.ref=o?Li(o,m):m),R.cloneElement(d,g)}return R.Children.count(d)>1?R.Children.only(null):null});return r.displayName=`${e}.SlotClone`,r}var vne=Symbol("radix.slottable");function xne(e){return R.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===vne}function bne(e,r){const s={...r};for(const o in r){const d=e[o],p=r[o];/^on[A-Z]/.test(o)?d&&p?s[o]=(...g)=>{const b=p(...g);return d(...g),b}:d&&(s[o]=d):o==="style"?s[o]={...d,...p}:o==="className"&&(s[o]=[d,p].filter(Boolean).join(" "))}return{...e,...s}}function wne(e){let r=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning;return s?e.ref:(r=Object.getOwnPropertyDescriptor(e,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning,s?e.props.ref:e.props.ref||e.ref)}var Sne=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Cn=Sne.reduce((e,r)=>{const s=gne(`Primitive.${r}`),o=R.forwardRef((d,p)=>{const{asChild:m,...g}=d,b=m?s:r;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(b,{...g,ref:p})});return o.displayName=`Primitive.${r}`,{...e,[r]:o}},{});function TL(e,r){e&&fC.flushSync(()=>e.dispatchEvent(r))}function tl(e){const r=R.useRef(e);return R.useEffect(()=>{r.current=e}),R.useMemo(()=>(...s)=>r.current?.(...s),[])}function Ene(e,r=globalThis?.document){const s=tl(e);R.useEffect(()=>{const o=d=>{d.key==="Escape"&&s(d)};return r.addEventListener("keydown",o,{capture:!0}),()=>r.removeEventListener("keydown",o,{capture:!0})},[s,r])}var jne="DismissableLayer",DT="dismissableLayer.update",Cne="dismissableLayer.pointerDownOutside",Ane="dismissableLayer.focusOutside",JM,_L=R.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),kg=R.forwardRef((e,r)=>{const{disableOutsidePointerEvents:s=!1,onEscapeKeyDown:o,onPointerDownOutside:d,onFocusOutside:p,onInteractOutside:m,onDismiss:g,...b}=e,S=R.useContext(_L),[j,A]=R.useState(null),k=j?.ownerDocument??globalThis?.document,[,T]=R.useState({}),M=zn(r,Q=>A(Q)),I=Array.from(S.layers),[q]=[...S.layersWithOutsidePointerEventsDisabled].slice(-1),G=I.indexOf(q),K=j?I.indexOf(j):-1,X=S.layersWithOutsidePointerEventsDisabled.size>0,L=K>=G,ee=Rne(Q=>{const ne=Q.target,de=[...S.branches].some(je=>je.contains(ne));!L||de||(d?.(Q),m?.(Q),Q.defaultPrevented||g?.())},k),oe=Tne(Q=>{const ne=Q.target;[...S.branches].some(je=>je.contains(ne))||(p?.(Q),m?.(Q),Q.defaultPrevented||g?.())},k);return Ene(Q=>{K===S.layers.size-1&&(o?.(Q),!Q.defaultPrevented&&g&&(Q.preventDefault(),g()))},k),R.useEffect(()=>{if(j)return s&&(S.layersWithOutsidePointerEventsDisabled.size===0&&(JM=k.body.style.pointerEvents,k.body.style.pointerEvents="none"),S.layersWithOutsidePointerEventsDisabled.add(j)),S.layers.add(j),QM(),()=>{s&&S.layersWithOutsidePointerEventsDisabled.size===1&&(k.body.style.pointerEvents=JM)}},[j,k,s,S]),R.useEffect(()=>()=>{j&&(S.layers.delete(j),S.layersWithOutsidePointerEventsDisabled.delete(j),QM())},[j,S]),R.useEffect(()=>{const Q=()=>T({});return document.addEventListener(DT,Q),()=>document.removeEventListener(DT,Q)},[]),u.jsx(Cn.div,{...b,ref:M,style:{pointerEvents:X?L?"auto":"none":void 0,...e.style},onFocusCapture:$t(e.onFocusCapture,oe.onFocusCapture),onBlurCapture:$t(e.onBlurCapture,oe.onBlurCapture),onPointerDownCapture:$t(e.onPointerDownCapture,ee.onPointerDownCapture)})});kg.displayName=jne;var One="DismissableLayerBranch",kne=R.forwardRef((e,r)=>{const s=R.useContext(_L),o=R.useRef(null),d=zn(r,o);return R.useEffect(()=>{const p=o.current;if(p)return s.branches.add(p),()=>{s.branches.delete(p)}},[s.branches]),u.jsx(Cn.div,{...e,ref:d})});kne.displayName=One;function Rne(e,r=globalThis?.document){const s=tl(e),o=R.useRef(!1),d=R.useRef(()=>{});return R.useEffect(()=>{const p=g=>{if(g.target&&!o.current){let b=function(){$L(Cne,s,S,{discrete:!0})};const S={originalEvent:g};g.pointerType==="touch"?(r.removeEventListener("click",d.current),d.current=b,r.addEventListener("click",d.current,{once:!0})):b()}else r.removeEventListener("click",d.current);o.current=!1},m=window.setTimeout(()=>{r.addEventListener("pointerdown",p)},0);return()=>{window.clearTimeout(m),r.removeEventListener("pointerdown",p),r.removeEventListener("click",d.current)}},[r,s]),{onPointerDownCapture:()=>o.current=!0}}function Tne(e,r=globalThis?.document){const s=tl(e),o=R.useRef(!1);return R.useEffect(()=>{const d=p=>{p.target&&!o.current&&$L(Ane,s,{originalEvent:p},{discrete:!1})};return r.addEventListener("focusin",d),()=>r.removeEventListener("focusin",d)},[r,s]),{onFocusCapture:()=>o.current=!0,onBlurCapture:()=>o.current=!1}}function QM(){const e=new CustomEvent(DT);document.dispatchEvent(e)}function $L(e,r,s,{discrete:o}){const d=s.originalEvent.target,p=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:s});r&&d.addEventListener(e,r,{once:!0}),o?TL(d,p):d.dispatchEvent(p)}var As=globalThis?.document?R.useLayoutEffect:()=>{},_ne=T_[" useId ".trim().toString()]||(()=>{}),$ne=0;function Vs(e){const[r,s]=R.useState(_ne());return As(()=>{s(o=>o??String($ne++))},[e]),r?`radix-${r}`:""}const Nne=["top","right","bottom","left"],zd=Math.min,_a=Math.max,$j=Math.round,VE=Math.floor,sc=e=>({x:e,y:e}),Dne={left:"right",right:"left",bottom:"top",top:"bottom"},Pne={start:"end",end:"start"};function PT(e,r,s){return _a(e,zd(r,s))}function fu(e,r){return typeof e=="function"?e(r):e}function mu(e){return e.split("-")[0]}function Rg(e){return e.split("-")[1]}function H_(e){return e==="x"?"y":"x"}function G_(e){return e==="y"?"height":"width"}const Mne=new Set(["top","bottom"]);function rc(e){return Mne.has(mu(e))?"y":"x"}function X_(e){return H_(rc(e))}function Ine(e,r,s){s===void 0&&(s=!1);const o=Rg(e),d=X_(e),p=G_(d);let m=d==="x"?o===(s?"end":"start")?"right":"left":o==="start"?"bottom":"top";return r.reference[p]>r.floating[p]&&(m=Nj(m)),[m,Nj(m)]}function Lne(e){const r=Nj(e);return[MT(e),r,MT(r)]}function MT(e){return e.replace(/start|end/g,r=>Pne[r])}const eI=["left","right"],tI=["right","left"],zne=["top","bottom"],Fne=["bottom","top"];function qne(e,r,s){switch(e){case"top":case"bottom":return s?r?tI:eI:r?eI:tI;case"left":case"right":return r?zne:Fne;default:return[]}}function Bne(e,r,s,o){const d=Rg(e);let p=qne(mu(e),s==="start",o);return d&&(p=p.map(m=>m+"-"+d),r&&(p=p.concat(p.map(MT)))),p}function Nj(e){return e.replace(/left|right|bottom|top/g,r=>Dne[r])}function Une(e){return{top:0,right:0,bottom:0,left:0,...e}}function NL(e){return typeof e!="number"?Une(e):{top:e,right:e,bottom:e,left:e}}function Dj(e){const{x:r,y:s,width:o,height:d}=e;return{width:o,height:d,top:s,left:r,right:r+o,bottom:s+d,x:r,y:s}}function nI(e,r,s){let{reference:o,floating:d}=e;const p=rc(r),m=X_(r),g=G_(m),b=mu(r),S=p==="y",j=o.x+o.width/2-d.width/2,A=o.y+o.height/2-d.height/2,k=o[g]/2-d[g]/2;let T;switch(b){case"top":T={x:j,y:o.y-d.height};break;case"bottom":T={x:j,y:o.y+o.height};break;case"right":T={x:o.x+o.width,y:A};break;case"left":T={x:o.x-d.width,y:A};break;default:T={x:o.x,y:o.y}}switch(Rg(r)){case"start":T[m]-=k*(s&&S?-1:1);break;case"end":T[m]+=k*(s&&S?-1:1);break}return T}const Kne=async(e,r,s)=>{const{placement:o="bottom",strategy:d="absolute",middleware:p=[],platform:m}=s,g=p.filter(Boolean),b=await(m.isRTL==null?void 0:m.isRTL(r));let S=await m.getElementRects({reference:e,floating:r,strategy:d}),{x:j,y:A}=nI(S,o,b),k=o,T={},M=0;for(let I=0;I({name:"arrow",options:e,async fn(r){const{x:s,y:o,placement:d,rects:p,platform:m,elements:g,middlewareData:b}=r,{element:S,padding:j=0}=fu(e,r)||{};if(S==null)return{};const A=NL(j),k={x:s,y:o},T=X_(d),M=G_(T),I=await m.getDimensions(S),q=T==="y",G=q?"top":"left",K=q?"bottom":"right",X=q?"clientHeight":"clientWidth",L=p.reference[M]+p.reference[T]-k[T]-p.floating[M],ee=k[T]-p.reference[T],oe=await(m.getOffsetParent==null?void 0:m.getOffsetParent(S));let Q=oe?oe[X]:0;(!Q||!await(m.isElement==null?void 0:m.isElement(oe)))&&(Q=g.floating[X]||p.floating[M]);const ne=L/2-ee/2,de=Q/2-I[M]/2-1,je=zd(A[G],de),ve=zd(A[K],de),le=je,be=Q-I[M]-ve,Ce=Q/2-I[M]/2+ne,Ke=PT(le,Ce,be),ce=!b.arrow&&Rg(d)!=null&&Ce!==Ke&&p.reference[M]/2-(CeCe<=0)){var ve,le;const Ce=(((ve=p.flip)==null?void 0:ve.index)||0)+1,Ke=Q[Ce];if(Ke&&(!(A==="alignment"?K!==rc(Ke):!1)||je.every(ue=>rc(ue.placement)===K?ue.overflows[0]>0:!0)))return{data:{index:Ce,overflows:je},reset:{placement:Ke}};let ce=(le=je.filter(re=>re.overflows[0]<=0).sort((re,ue)=>re.overflows[1]-ue.overflows[1])[0])==null?void 0:le.placement;if(!ce)switch(T){case"bestFit":{var be;const re=(be=je.filter(ue=>{if(oe){const _e=rc(ue.placement);return _e===K||_e==="y"}return!0}).map(ue=>[ue.placement,ue.overflows.filter(_e=>_e>0).reduce((_e,fe)=>_e+fe,0)]).sort((ue,_e)=>ue[1]-_e[1])[0])==null?void 0:be[0];re&&(ce=re);break}case"initialPlacement":ce=g;break}if(d!==ce)return{reset:{placement:ce}}}return{}}}};function rI(e,r){return{top:e.top-r.height,right:e.right-r.width,bottom:e.bottom-r.height,left:e.left-r.width}}function sI(e){return Nne.some(r=>e[r]>=0)}const Gne=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(r){const{rects:s}=r,{strategy:o="referenceHidden",...d}=fu(e,r);switch(o){case"referenceHidden":{const p=await Lb(r,{...d,elementContext:"reference"}),m=rI(p,s.reference);return{data:{referenceHiddenOffsets:m,referenceHidden:sI(m)}}}case"escaped":{const p=await Lb(r,{...d,altBoundary:!0}),m=rI(p,s.floating);return{data:{escapedOffsets:m,escaped:sI(m)}}}default:return{}}}}},DL=new Set(["left","top"]);async function Xne(e,r){const{placement:s,platform:o,elements:d}=e,p=await(o.isRTL==null?void 0:o.isRTL(d.floating)),m=mu(s),g=Rg(s),b=rc(s)==="y",S=DL.has(m)?-1:1,j=p&&b?-1:1,A=fu(r,e);let{mainAxis:k,crossAxis:T,alignmentAxis:M}=typeof A=="number"?{mainAxis:A,crossAxis:0,alignmentAxis:null}:{mainAxis:A.mainAxis||0,crossAxis:A.crossAxis||0,alignmentAxis:A.alignmentAxis};return g&&typeof M=="number"&&(T=g==="end"?M*-1:M),b?{x:T*j,y:k*S}:{x:k*S,y:T*j}}const Yne=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(r){var s,o;const{x:d,y:p,placement:m,middlewareData:g}=r,b=await Xne(r,e);return m===((s=g.offset)==null?void 0:s.placement)&&(o=g.arrow)!=null&&o.alignmentOffset?{}:{x:d+b.x,y:p+b.y,data:{...b,placement:m}}}}},Zne=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(r){const{x:s,y:o,placement:d}=r,{mainAxis:p=!0,crossAxis:m=!1,limiter:g={fn:q=>{let{x:G,y:K}=q;return{x:G,y:K}}},...b}=fu(e,r),S={x:s,y:o},j=await Lb(r,b),A=rc(mu(d)),k=H_(A);let T=S[k],M=S[A];if(p){const q=k==="y"?"top":"left",G=k==="y"?"bottom":"right",K=T+j[q],X=T-j[G];T=PT(K,T,X)}if(m){const q=A==="y"?"top":"left",G=A==="y"?"bottom":"right",K=M+j[q],X=M-j[G];M=PT(K,M,X)}const I=g.fn({...r,[k]:T,[A]:M});return{...I,data:{x:I.x-s,y:I.y-o,enabled:{[k]:p,[A]:m}}}}}},Wne=function(e){return e===void 0&&(e={}),{options:e,fn(r){const{x:s,y:o,placement:d,rects:p,middlewareData:m}=r,{offset:g=0,mainAxis:b=!0,crossAxis:S=!0}=fu(e,r),j={x:s,y:o},A=rc(d),k=H_(A);let T=j[k],M=j[A];const I=fu(g,r),q=typeof I=="number"?{mainAxis:I,crossAxis:0}:{mainAxis:0,crossAxis:0,...I};if(b){const X=k==="y"?"height":"width",L=p.reference[k]-p.floating[X]+q.mainAxis,ee=p.reference[k]+p.reference[X]-q.mainAxis;Tee&&(T=ee)}if(S){var G,K;const X=k==="y"?"width":"height",L=DL.has(mu(d)),ee=p.reference[A]-p.floating[X]+(L&&((G=m.offset)==null?void 0:G[A])||0)+(L?0:q.crossAxis),oe=p.reference[A]+p.reference[X]+(L?0:((K=m.offset)==null?void 0:K[A])||0)-(L?q.crossAxis:0);Moe&&(M=oe)}return{[k]:T,[A]:M}}}},Jne=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(r){var s,o;const{placement:d,rects:p,platform:m,elements:g}=r,{apply:b=()=>{},...S}=fu(e,r),j=await Lb(r,S),A=mu(d),k=Rg(d),T=rc(d)==="y",{width:M,height:I}=p.floating;let q,G;A==="top"||A==="bottom"?(q=A,G=k===(await(m.isRTL==null?void 0:m.isRTL(g.floating))?"start":"end")?"left":"right"):(G=A,q=k==="end"?"top":"bottom");const K=I-j.top-j.bottom,X=M-j.left-j.right,L=zd(I-j[q],K),ee=zd(M-j[G],X),oe=!r.middlewareData.shift;let Q=L,ne=ee;if((s=r.middlewareData.shift)!=null&&s.enabled.x&&(ne=X),(o=r.middlewareData.shift)!=null&&o.enabled.y&&(Q=K),oe&&!k){const je=_a(j.left,0),ve=_a(j.right,0),le=_a(j.top,0),be=_a(j.bottom,0);T?ne=M-2*(je!==0||ve!==0?je+ve:_a(j.left,j.right)):Q=I-2*(le!==0||be!==0?le+be:_a(j.top,j.bottom))}await b({...r,availableWidth:ne,availableHeight:Q});const de=await m.getDimensions(g.floating);return M!==de.width||I!==de.height?{reset:{rects:!0}}:{}}}};function yC(){return typeof window<"u"}function Tg(e){return PL(e)?(e.nodeName||"").toLowerCase():"#document"}function Na(e){var r;return(e==null||(r=e.ownerDocument)==null?void 0:r.defaultView)||window}function lc(e){var r;return(r=(PL(e)?e.ownerDocument:e.document)||window.document)==null?void 0:r.documentElement}function PL(e){return yC()?e instanceof Node||e instanceof Na(e).Node:!1}function nl(e){return yC()?e instanceof Element||e instanceof Na(e).Element:!1}function oc(e){return yC()?e instanceof HTMLElement||e instanceof Na(e).HTMLElement:!1}function iI(e){return!yC()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Na(e).ShadowRoot}const Qne=new Set(["inline","contents"]);function ew(e){const{overflow:r,overflowX:s,overflowY:o,display:d}=rl(e);return/auto|scroll|overlay|hidden|clip/.test(r+o+s)&&!Qne.has(d)}const ere=new Set(["table","td","th"]);function tre(e){return ere.has(Tg(e))}const nre=[":popover-open",":modal"];function vC(e){return nre.some(r=>{try{return e.matches(r)}catch{return!1}})}const rre=["transform","translate","scale","rotate","perspective"],sre=["transform","translate","scale","rotate","perspective","filter"],ire=["paint","layout","strict","content"];function Y_(e){const r=Z_(),s=nl(e)?rl(e):e;return rre.some(o=>s[o]?s[o]!=="none":!1)||(s.containerType?s.containerType!=="normal":!1)||!r&&(s.backdropFilter?s.backdropFilter!=="none":!1)||!r&&(s.filter?s.filter!=="none":!1)||sre.some(o=>(s.willChange||"").includes(o))||ire.some(o=>(s.contain||"").includes(o))}function are(e){let r=Fd(e);for(;oc(r)&&!vg(r);){if(Y_(r))return r;if(vC(r))return null;r=Fd(r)}return null}function Z_(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const ore=new Set(["html","body","#document"]);function vg(e){return ore.has(Tg(e))}function rl(e){return Na(e).getComputedStyle(e)}function xC(e){return nl(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Fd(e){if(Tg(e)==="html")return e;const r=e.assignedSlot||e.parentNode||iI(e)&&e.host||lc(e);return iI(r)?r.host:r}function ML(e){const r=Fd(e);return vg(r)?e.ownerDocument?e.ownerDocument.body:e.body:oc(r)&&ew(r)?r:ML(r)}function zb(e,r,s){var o;r===void 0&&(r=[]),s===void 0&&(s=!0);const d=ML(e),p=d===((o=e.ownerDocument)==null?void 0:o.body),m=Na(d);if(p){const g=IT(m);return r.concat(m,m.visualViewport||[],ew(d)?d:[],g&&s?zb(g):[])}return r.concat(d,zb(d,[],s))}function IT(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function IL(e){const r=rl(e);let s=parseFloat(r.width)||0,o=parseFloat(r.height)||0;const d=oc(e),p=d?e.offsetWidth:s,m=d?e.offsetHeight:o,g=$j(s)!==p||$j(o)!==m;return g&&(s=p,o=m),{width:s,height:o,$:g}}function W_(e){return nl(e)?e:e.contextElement}function pg(e){const r=W_(e);if(!oc(r))return sc(1);const s=r.getBoundingClientRect(),{width:o,height:d,$:p}=IL(r);let m=(p?$j(s.width):s.width)/o,g=(p?$j(s.height):s.height)/d;return(!m||!Number.isFinite(m))&&(m=1),(!g||!Number.isFinite(g))&&(g=1),{x:m,y:g}}const lre=sc(0);function LL(e){const r=Na(e);return!Z_()||!r.visualViewport?lre:{x:r.visualViewport.offsetLeft,y:r.visualViewport.offsetTop}}function cre(e,r,s){return r===void 0&&(r=!1),!s||r&&s!==Na(e)?!1:r}function Op(e,r,s,o){r===void 0&&(r=!1),s===void 0&&(s=!1);const d=e.getBoundingClientRect(),p=W_(e);let m=sc(1);r&&(o?nl(o)&&(m=pg(o)):m=pg(e));const g=cre(p,s,o)?LL(p):sc(0);let b=(d.left+g.x)/m.x,S=(d.top+g.y)/m.y,j=d.width/m.x,A=d.height/m.y;if(p){const k=Na(p),T=o&&nl(o)?Na(o):o;let M=k,I=IT(M);for(;I&&o&&T!==M;){const q=pg(I),G=I.getBoundingClientRect(),K=rl(I),X=G.left+(I.clientLeft+parseFloat(K.paddingLeft))*q.x,L=G.top+(I.clientTop+parseFloat(K.paddingTop))*q.y;b*=q.x,S*=q.y,j*=q.x,A*=q.y,b+=X,S+=L,M=Na(I),I=IT(M)}}return Dj({width:j,height:A,x:b,y:S})}function bC(e,r){const s=xC(e).scrollLeft;return r?r.left+s:Op(lc(e)).left+s}function zL(e,r){const s=e.getBoundingClientRect(),o=s.left+r.scrollLeft-bC(e,s),d=s.top+r.scrollTop;return{x:o,y:d}}function ure(e){let{elements:r,rect:s,offsetParent:o,strategy:d}=e;const p=d==="fixed",m=lc(o),g=r?vC(r.floating):!1;if(o===m||g&&p)return s;let b={scrollLeft:0,scrollTop:0},S=sc(1);const j=sc(0),A=oc(o);if((A||!A&&!p)&&((Tg(o)!=="body"||ew(m))&&(b=xC(o)),oc(o))){const T=Op(o);S=pg(o),j.x=T.x+o.clientLeft,j.y=T.y+o.clientTop}const k=m&&!A&&!p?zL(m,b):sc(0);return{width:s.width*S.x,height:s.height*S.y,x:s.x*S.x-b.scrollLeft*S.x+j.x+k.x,y:s.y*S.y-b.scrollTop*S.y+j.y+k.y}}function dre(e){return Array.from(e.getClientRects())}function hre(e){const r=lc(e),s=xC(e),o=e.ownerDocument.body,d=_a(r.scrollWidth,r.clientWidth,o.scrollWidth,o.clientWidth),p=_a(r.scrollHeight,r.clientHeight,o.scrollHeight,o.clientHeight);let m=-s.scrollLeft+bC(e);const g=-s.scrollTop;return rl(o).direction==="rtl"&&(m+=_a(r.clientWidth,o.clientWidth)-d),{width:d,height:p,x:m,y:g}}const aI=25;function pre(e,r){const s=Na(e),o=lc(e),d=s.visualViewport;let p=o.clientWidth,m=o.clientHeight,g=0,b=0;if(d){p=d.width,m=d.height;const j=Z_();(!j||j&&r==="fixed")&&(g=d.offsetLeft,b=d.offsetTop)}const S=bC(o);if(S<=0){const j=o.ownerDocument,A=j.body,k=getComputedStyle(A),T=j.compatMode==="CSS1Compat"&&parseFloat(k.marginLeft)+parseFloat(k.marginRight)||0,M=Math.abs(o.clientWidth-A.clientWidth-T);M<=aI&&(p-=M)}else S<=aI&&(p+=S);return{width:p,height:m,x:g,y:b}}const fre=new Set(["absolute","fixed"]);function mre(e,r){const s=Op(e,!0,r==="fixed"),o=s.top+e.clientTop,d=s.left+e.clientLeft,p=oc(e)?pg(e):sc(1),m=e.clientWidth*p.x,g=e.clientHeight*p.y,b=d*p.x,S=o*p.y;return{width:m,height:g,x:b,y:S}}function oI(e,r,s){let o;if(r==="viewport")o=pre(e,s);else if(r==="document")o=hre(lc(e));else if(nl(r))o=mre(r,s);else{const d=LL(e);o={x:r.x-d.x,y:r.y-d.y,width:r.width,height:r.height}}return Dj(o)}function FL(e,r){const s=Fd(e);return s===r||!nl(s)||vg(s)?!1:rl(s).position==="fixed"||FL(s,r)}function gre(e,r){const s=r.get(e);if(s)return s;let o=zb(e,[],!1).filter(g=>nl(g)&&Tg(g)!=="body"),d=null;const p=rl(e).position==="fixed";let m=p?Fd(e):e;for(;nl(m)&&!vg(m);){const g=rl(m),b=Y_(m);!b&&g.position==="fixed"&&(d=null),(p?!b&&!d:!b&&g.position==="static"&&!!d&&fre.has(d.position)||ew(m)&&!b&&FL(e,m))?o=o.filter(j=>j!==m):d=g,m=Fd(m)}return r.set(e,o),o}function yre(e){let{element:r,boundary:s,rootBoundary:o,strategy:d}=e;const m=[...s==="clippingAncestors"?vC(r)?[]:gre(r,this._c):[].concat(s),o],g=m[0],b=m.reduce((S,j)=>{const A=oI(r,j,d);return S.top=_a(A.top,S.top),S.right=zd(A.right,S.right),S.bottom=zd(A.bottom,S.bottom),S.left=_a(A.left,S.left),S},oI(r,g,d));return{width:b.right-b.left,height:b.bottom-b.top,x:b.left,y:b.top}}function vre(e){const{width:r,height:s}=IL(e);return{width:r,height:s}}function xre(e,r,s){const o=oc(r),d=lc(r),p=s==="fixed",m=Op(e,!0,p,r);let g={scrollLeft:0,scrollTop:0};const b=sc(0);function S(){b.x=bC(d)}if(o||!o&&!p)if((Tg(r)!=="body"||ew(d))&&(g=xC(r)),o){const T=Op(r,!0,p,r);b.x=T.x+r.clientLeft,b.y=T.y+r.clientTop}else d&&S();p&&!o&&d&&S();const j=d&&!o&&!p?zL(d,g):sc(0),A=m.left+g.scrollLeft-b.x-j.x,k=m.top+g.scrollTop-b.y-j.y;return{x:A,y:k,width:m.width,height:m.height}}function PR(e){return rl(e).position==="static"}function lI(e,r){if(!oc(e)||rl(e).position==="fixed")return null;if(r)return r(e);let s=e.offsetParent;return lc(e)===s&&(s=s.ownerDocument.body),s}function qL(e,r){const s=Na(e);if(vC(e))return s;if(!oc(e)){let d=Fd(e);for(;d&&!vg(d);){if(nl(d)&&!PR(d))return d;d=Fd(d)}return s}let o=lI(e,r);for(;o&&tre(o)&&PR(o);)o=lI(o,r);return o&&vg(o)&&PR(o)&&!Y_(o)?s:o||are(e)||s}const bre=async function(e){const r=this.getOffsetParent||qL,s=this.getDimensions,o=await s(e.floating);return{reference:xre(e.reference,await r(e.floating),e.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function wre(e){return rl(e).direction==="rtl"}const Sre={convertOffsetParentRelativeRectToViewportRelativeRect:ure,getDocumentElement:lc,getClippingRect:yre,getOffsetParent:qL,getElementRects:bre,getClientRects:dre,getDimensions:vre,getScale:pg,isElement:nl,isRTL:wre};function BL(e,r){return e.x===r.x&&e.y===r.y&&e.width===r.width&&e.height===r.height}function Ere(e,r){let s=null,o;const d=lc(e);function p(){var g;clearTimeout(o),(g=s)==null||g.disconnect(),s=null}function m(g,b){g===void 0&&(g=!1),b===void 0&&(b=1),p();const S=e.getBoundingClientRect(),{left:j,top:A,width:k,height:T}=S;if(g||r(),!k||!T)return;const M=VE(A),I=VE(d.clientWidth-(j+k)),q=VE(d.clientHeight-(A+T)),G=VE(j),X={rootMargin:-M+"px "+-I+"px "+-q+"px "+-G+"px",threshold:_a(0,zd(1,b))||1};let L=!0;function ee(oe){const Q=oe[0].intersectionRatio;if(Q!==b){if(!L)return m();Q?m(!1,Q):o=setTimeout(()=>{m(!1,1e-7)},1e3)}Q===1&&!BL(S,e.getBoundingClientRect())&&m(),L=!1}try{s=new IntersectionObserver(ee,{...X,root:d.ownerDocument})}catch{s=new IntersectionObserver(ee,X)}s.observe(e)}return m(!0),p}function jre(e,r,s,o){o===void 0&&(o={});const{ancestorScroll:d=!0,ancestorResize:p=!0,elementResize:m=typeof ResizeObserver=="function",layoutShift:g=typeof IntersectionObserver=="function",animationFrame:b=!1}=o,S=W_(e),j=d||p?[...S?zb(S):[],...zb(r)]:[];j.forEach(G=>{d&&G.addEventListener("scroll",s,{passive:!0}),p&&G.addEventListener("resize",s)});const A=S&&g?Ere(S,s):null;let k=-1,T=null;m&&(T=new ResizeObserver(G=>{let[K]=G;K&&K.target===S&&T&&(T.unobserve(r),cancelAnimationFrame(k),k=requestAnimationFrame(()=>{var X;(X=T)==null||X.observe(r)})),s()}),S&&!b&&T.observe(S),T.observe(r));let M,I=b?Op(e):null;b&&q();function q(){const G=Op(e);I&&!BL(I,G)&&s(),I=G,M=requestAnimationFrame(q)}return s(),()=>{var G;j.forEach(K=>{d&&K.removeEventListener("scroll",s),p&&K.removeEventListener("resize",s)}),A?.(),(G=T)==null||G.disconnect(),T=null,b&&cancelAnimationFrame(M)}}const Cre=Yne,Are=Zne,Ore=Hne,kre=Jne,Rre=Gne,cI=Vne,Tre=Wne,_re=(e,r,s)=>{const o=new Map,d={platform:Sre,...s},p={...d.platform,_c:o};return Kne(e,r,{...d,platform:p})};var $re=typeof document<"u",Nre=function(){},mj=$re?R.useLayoutEffect:Nre;function Pj(e,r){if(e===r)return!0;if(typeof e!=typeof r)return!1;if(typeof e=="function"&&e.toString()===r.toString())return!0;let s,o,d;if(e&&r&&typeof e=="object"){if(Array.isArray(e)){if(s=e.length,s!==r.length)return!1;for(o=s;o--!==0;)if(!Pj(e[o],r[o]))return!1;return!0}if(d=Object.keys(e),s=d.length,s!==Object.keys(r).length)return!1;for(o=s;o--!==0;)if(!{}.hasOwnProperty.call(r,d[o]))return!1;for(o=s;o--!==0;){const p=d[o];if(!(p==="_owner"&&e.$$typeof)&&!Pj(e[p],r[p]))return!1}return!0}return e!==e&&r!==r}function UL(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function uI(e,r){const s=UL(e);return Math.round(r*s)/s}function MR(e){const r=R.useRef(e);return mj(()=>{r.current=e}),r}function Dre(e){e===void 0&&(e={});const{placement:r="bottom",strategy:s="absolute",middleware:o=[],platform:d,elements:{reference:p,floating:m}={},transform:g=!0,whileElementsMounted:b,open:S}=e,[j,A]=R.useState({x:0,y:0,strategy:s,placement:r,middlewareData:{},isPositioned:!1}),[k,T]=R.useState(o);Pj(k,o)||T(o);const[M,I]=R.useState(null),[q,G]=R.useState(null),K=R.useCallback(ue=>{ue!==oe.current&&(oe.current=ue,I(ue))},[]),X=R.useCallback(ue=>{ue!==Q.current&&(Q.current=ue,G(ue))},[]),L=p||M,ee=m||q,oe=R.useRef(null),Q=R.useRef(null),ne=R.useRef(j),de=b!=null,je=MR(b),ve=MR(d),le=MR(S),be=R.useCallback(()=>{if(!oe.current||!Q.current)return;const ue={placement:r,strategy:s,middleware:k};ve.current&&(ue.platform=ve.current),_re(oe.current,Q.current,ue).then(_e=>{const fe={..._e,isPositioned:le.current!==!1};Ce.current&&!Pj(ne.current,fe)&&(ne.current=fe,fC.flushSync(()=>{A(fe)}))})},[k,r,s,ve,le]);mj(()=>{S===!1&&ne.current.isPositioned&&(ne.current.isPositioned=!1,A(ue=>({...ue,isPositioned:!1})))},[S]);const Ce=R.useRef(!1);mj(()=>(Ce.current=!0,()=>{Ce.current=!1}),[]),mj(()=>{if(L&&(oe.current=L),ee&&(Q.current=ee),L&&ee){if(je.current)return je.current(L,ee,be);be()}},[L,ee,be,je,de]);const Ke=R.useMemo(()=>({reference:oe,floating:Q,setReference:K,setFloating:X}),[K,X]),ce=R.useMemo(()=>({reference:L,floating:ee}),[L,ee]),re=R.useMemo(()=>{const ue={position:s,left:0,top:0};if(!ce.floating)return ue;const _e=uI(ce.floating,j.x),fe=uI(ce.floating,j.y);return g?{...ue,transform:"translate("+_e+"px, "+fe+"px)",...UL(ce.floating)>=1.5&&{willChange:"transform"}}:{position:s,left:_e,top:fe}},[s,g,ce.floating,j.x,j.y]);return R.useMemo(()=>({...j,update:be,refs:Ke,elements:ce,floatingStyles:re}),[j,be,Ke,ce,re])}const Pre=e=>{function r(s){return{}.hasOwnProperty.call(s,"current")}return{name:"arrow",options:e,fn(s){const{element:o,padding:d}=typeof e=="function"?e(s):e;return o&&r(o)?o.current!=null?cI({element:o.current,padding:d}).fn(s):{}:o?cI({element:o,padding:d}).fn(s):{}}}},Mre=(e,r)=>({...Cre(e),options:[e,r]}),Ire=(e,r)=>({...Are(e),options:[e,r]}),Lre=(e,r)=>({...Tre(e),options:[e,r]}),zre=(e,r)=>({...Ore(e),options:[e,r]}),Fre=(e,r)=>({...kre(e),options:[e,r]}),qre=(e,r)=>({...Rre(e),options:[e,r]}),Bre=(e,r)=>({...Pre(e),options:[e,r]});var Ure="Arrow",KL=R.forwardRef((e,r)=>{const{children:s,width:o=10,height:d=5,...p}=e;return u.jsx(Cn.svg,{...p,ref:r,width:o,height:d,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?s:u.jsx("polygon",{points:"0,0 30,0 15,10"})})});KL.displayName=Ure;var Kre=KL;function VL(e){const[r,s]=R.useState(void 0);return As(()=>{if(e){s({width:e.offsetWidth,height:e.offsetHeight});const o=new ResizeObserver(d=>{if(!Array.isArray(d)||!d.length)return;const p=d[0];let m,g;if("borderBoxSize"in p){const b=p.borderBoxSize,S=Array.isArray(b)?b[0]:b;m=S.inlineSize,g=S.blockSize}else m=e.offsetWidth,g=e.offsetHeight;s({width:m,height:g})});return o.observe(e,{box:"border-box"}),()=>o.unobserve(e)}else s(void 0)},[e]),r}var J_="Popper",[HL,Hd]=al(J_),[Vre,GL]=HL(J_),XL=e=>{const{__scopePopper:r,children:s}=e,[o,d]=R.useState(null);return u.jsx(Vre,{scope:r,anchor:o,onAnchorChange:d,children:s})};XL.displayName=J_;var YL="PopperAnchor",ZL=R.forwardRef((e,r)=>{const{__scopePopper:s,virtualRef:o,...d}=e,p=GL(YL,s),m=R.useRef(null),g=zn(r,m),b=R.useRef(null);return R.useEffect(()=>{const S=b.current;b.current=o?.current||m.current,S!==b.current&&p.onAnchorChange(b.current)}),o?null:u.jsx(Cn.div,{...d,ref:g})});ZL.displayName=YL;var Q_="PopperContent",[Hre,Gre]=HL(Q_),WL=R.forwardRef((e,r)=>{const{__scopePopper:s,side:o="bottom",sideOffset:d=0,align:p="center",alignOffset:m=0,arrowPadding:g=0,avoidCollisions:b=!0,collisionBoundary:S=[],collisionPadding:j=0,sticky:A="partial",hideWhenDetached:k=!1,updatePositionStrategy:T="optimized",onPlaced:M,...I}=e,q=GL(Q_,s),[G,K]=R.useState(null),X=zn(r,Le=>K(Le)),[L,ee]=R.useState(null),oe=VL(L),Q=oe?.width??0,ne=oe?.height??0,de=o+(p!=="center"?"-"+p:""),je=typeof j=="number"?j:{top:0,right:0,bottom:0,left:0,...j},ve=Array.isArray(S)?S:[S],le=ve.length>0,be={padding:je,boundary:ve.filter(Yre),altBoundary:le},{refs:Ce,floatingStyles:Ke,placement:ce,isPositioned:re,middlewareData:ue}=Dre({strategy:"fixed",placement:de,whileElementsMounted:(...Le)=>jre(...Le,{animationFrame:T==="always"}),elements:{reference:q.anchor},middleware:[Mre({mainAxis:d+ne,alignmentAxis:m}),b&&Ire({mainAxis:!0,crossAxis:!1,limiter:A==="partial"?Lre():void 0,...be}),b&&zre({...be}),Fre({...be,apply:({elements:Le,rects:tt,availableWidth:yt,availableHeight:Ot})=>{const{width:Ft,height:kt}=tt.reference,Jt=Le.floating.style;Jt.setProperty("--radix-popper-available-width",`${yt}px`),Jt.setProperty("--radix-popper-available-height",`${Ot}px`),Jt.setProperty("--radix-popper-anchor-width",`${Ft}px`),Jt.setProperty("--radix-popper-anchor-height",`${kt}px`)}}),L&&Bre({element:L,padding:g}),Zre({arrowWidth:Q,arrowHeight:ne}),k&&qre({strategy:"referenceHidden",...be})]}),[_e,fe]=ez(ce),He=tl(M);As(()=>{re&&He?.()},[re,He]);const Oe=ue.arrow?.x,ke=ue.arrow?.y,Ve=ue.arrow?.centerOffset!==0,[ie,De]=R.useState();return As(()=>{G&&De(window.getComputedStyle(G).zIndex)},[G]),u.jsx("div",{ref:Ce.setFloating,"data-radix-popper-content-wrapper":"",style:{...Ke,transform:re?Ke.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ie,"--radix-popper-transform-origin":[ue.transformOrigin?.x,ue.transformOrigin?.y].join(" "),...ue.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:u.jsx(Hre,{scope:s,placedSide:_e,onArrowChange:ee,arrowX:Oe,arrowY:ke,shouldHideArrow:Ve,children:u.jsx(Cn.div,{"data-side":_e,"data-align":fe,...I,ref:X,style:{...I.style,animation:re?void 0:"none"}})})})});WL.displayName=Q_;var JL="PopperArrow",Xre={top:"bottom",right:"left",bottom:"top",left:"right"},QL=R.forwardRef(function(r,s){const{__scopePopper:o,...d}=r,p=Gre(JL,o),m=Xre[p.placedSide];return u.jsx("span",{ref:p.onArrowChange,style:{position:"absolute",left:p.arrowX,top:p.arrowY,[m]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[p.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[p.placedSide],visibility:p.shouldHideArrow?"hidden":void 0},children:u.jsx(Kre,{...d,ref:s,style:{...d.style,display:"block"}})})});QL.displayName=JL;function Yre(e){return e!==null}var Zre=e=>({name:"transformOrigin",options:e,fn(r){const{placement:s,rects:o,middlewareData:d}=r,m=d.arrow?.centerOffset!==0,g=m?0:e.arrowWidth,b=m?0:e.arrowHeight,[S,j]=ez(s),A={start:"0%",center:"50%",end:"100%"}[j],k=(d.arrow?.x??0)+g/2,T=(d.arrow?.y??0)+b/2;let M="",I="";return S==="bottom"?(M=m?A:`${k}px`,I=`${-b}px`):S==="top"?(M=m?A:`${k}px`,I=`${o.floating.height+b}px`):S==="right"?(M=`${-b}px`,I=m?A:`${T}px`):S==="left"&&(M=`${o.floating.width+b}px`,I=m?A:`${T}px`),{data:{x:M,y:I}}}});function ez(e){const[r,s="center"]=e.split("-");return[r,s]}var wC=XL,tw=ZL,SC=WL,EC=QL,Wre="Portal",_g=R.forwardRef((e,r)=>{const{container:s,...o}=e,[d,p]=R.useState(!1);As(()=>p(!0),[]);const m=s||d&&globalThis?.document?.body;return m?B3.createPortal(u.jsx(Cn.div,{...o,ref:r}),m):null});_g.displayName=Wre;function Jre(e,r){return R.useReducer((s,o)=>r[s][o]??s,e)}var lo=e=>{const{present:r,children:s}=e,o=Qre(r),d=typeof s=="function"?s({present:o.isPresent}):R.Children.only(s),p=zn(o.ref,ese(d));return typeof s=="function"||o.isPresent?R.cloneElement(d,{ref:p}):null};lo.displayName="Presence";function Qre(e){const[r,s]=R.useState(),o=R.useRef(null),d=R.useRef(e),p=R.useRef("none"),m=e?"mounted":"unmounted",[g,b]=Jre(m,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return R.useEffect(()=>{const S=HE(o.current);p.current=g==="mounted"?S:"none"},[g]),As(()=>{const S=o.current,j=d.current;if(j!==e){const k=p.current,T=HE(S);e?b("MOUNT"):T==="none"||S?.display==="none"?b("UNMOUNT"):b(j&&k!==T?"ANIMATION_OUT":"UNMOUNT"),d.current=e}},[e,b]),As(()=>{if(r){let S;const j=r.ownerDocument.defaultView??window,A=T=>{const I=HE(o.current).includes(CSS.escape(T.animationName));if(T.target===r&&I&&(b("ANIMATION_END"),!d.current)){const q=r.style.animationFillMode;r.style.animationFillMode="forwards",S=j.setTimeout(()=>{r.style.animationFillMode==="forwards"&&(r.style.animationFillMode=q)})}},k=T=>{T.target===r&&(p.current=HE(o.current))};return r.addEventListener("animationstart",k),r.addEventListener("animationcancel",A),r.addEventListener("animationend",A),()=>{j.clearTimeout(S),r.removeEventListener("animationstart",k),r.removeEventListener("animationcancel",A),r.removeEventListener("animationend",A)}}else b("ANIMATION_END")},[r,b]),{isPresent:["mounted","unmountSuspended"].includes(g),ref:R.useCallback(S=>{o.current=S?getComputedStyle(S):null,s(S)},[])}}function HE(e){return e?.animationName||"none"}function ese(e){let r=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning;return s?e.ref:(r=Object.getOwnPropertyDescriptor(e,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning,s?e.props.ref:e.props.ref||e.ref)}var tse=Symbol("radix.slottable");function nse(e){const r=({children:s})=>u.jsx(u.Fragment,{children:s});return r.displayName=`${e}.Slottable`,r.__radixId=tse,r}var rse=T_[" useInsertionEffect ".trim().toString()]||As;function qd({prop:e,defaultProp:r,onChange:s=()=>{},caller:o}){const[d,p,m]=sse({defaultProp:r,onChange:s}),g=e!==void 0,b=g?e:d;{const j=R.useRef(e!==void 0);R.useEffect(()=>{const A=j.current;A!==g&&console.warn(`${o} is changing from ${A?"controlled":"uncontrolled"} to ${g?"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.`),j.current=g},[g,o])}const S=R.useCallback(j=>{if(g){const A=ise(j)?j(e):j;A!==e&&m.current?.(A)}else p(j)},[g,e,p,m]);return[b,S]}function sse({defaultProp:e,onChange:r}){const[s,o]=R.useState(e),d=R.useRef(s),p=R.useRef(r);return rse(()=>{p.current=r},[r]),R.useEffect(()=>{d.current!==s&&(p.current?.(s),d.current=s)},[s,d]),[s,o,p]}function ise(e){return typeof e=="function"}var tz=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),ase="VisuallyHidden",nz=R.forwardRef((e,r)=>u.jsx(Cn.span,{...e,ref:r,style:{...tz,...e.style}}));nz.displayName=ase;var ose=nz,[jC]=al("Tooltip",[Hd]),CC=Hd(),rz="TooltipProvider",lse=700,LT="tooltip.open",[cse,e2]=jC(rz),sz=e=>{const{__scopeTooltip:r,delayDuration:s=lse,skipDelayDuration:o=300,disableHoverableContent:d=!1,children:p}=e,m=R.useRef(!0),g=R.useRef(!1),b=R.useRef(0);return R.useEffect(()=>{const S=b.current;return()=>window.clearTimeout(S)},[]),u.jsx(cse,{scope:r,isOpenDelayedRef:m,delayDuration:s,onOpen:R.useCallback(()=>{window.clearTimeout(b.current),m.current=!1},[]),onClose:R.useCallback(()=>{window.clearTimeout(b.current),b.current=window.setTimeout(()=>m.current=!0,o)},[o]),isPointerInTransitRef:g,onPointerInTransitChange:R.useCallback(S=>{g.current=S},[]),disableHoverableContent:d,children:p})};sz.displayName=rz;var Fb="Tooltip",[use,nw]=jC(Fb),iz=e=>{const{__scopeTooltip:r,children:s,open:o,defaultOpen:d,onOpenChange:p,disableHoverableContent:m,delayDuration:g}=e,b=e2(Fb,e.__scopeTooltip),S=CC(r),[j,A]=R.useState(null),k=Vs(),T=R.useRef(0),M=m??b.disableHoverableContent,I=g??b.delayDuration,q=R.useRef(!1),[G,K]=qd({prop:o,defaultProp:d??!1,onChange:Q=>{Q?(b.onOpen(),document.dispatchEvent(new CustomEvent(LT))):b.onClose(),p?.(Q)},caller:Fb}),X=R.useMemo(()=>G?q.current?"delayed-open":"instant-open":"closed",[G]),L=R.useCallback(()=>{window.clearTimeout(T.current),T.current=0,q.current=!1,K(!0)},[K]),ee=R.useCallback(()=>{window.clearTimeout(T.current),T.current=0,K(!1)},[K]),oe=R.useCallback(()=>{window.clearTimeout(T.current),T.current=window.setTimeout(()=>{q.current=!0,K(!0),T.current=0},I)},[I,K]);return R.useEffect(()=>()=>{T.current&&(window.clearTimeout(T.current),T.current=0)},[]),u.jsx(wC,{...S,children:u.jsx(use,{scope:r,contentId:k,open:G,stateAttribute:X,trigger:j,onTriggerChange:A,onTriggerEnter:R.useCallback(()=>{b.isOpenDelayedRef.current?oe():L()},[b.isOpenDelayedRef,oe,L]),onTriggerLeave:R.useCallback(()=>{M?ee():(window.clearTimeout(T.current),T.current=0)},[ee,M]),onOpen:L,onClose:ee,disableHoverableContent:M,children:s})})};iz.displayName=Fb;var zT="TooltipTrigger",az=R.forwardRef((e,r)=>{const{__scopeTooltip:s,...o}=e,d=nw(zT,s),p=e2(zT,s),m=CC(s),g=R.useRef(null),b=zn(r,g,d.onTriggerChange),S=R.useRef(!1),j=R.useRef(!1),A=R.useCallback(()=>S.current=!1,[]);return R.useEffect(()=>()=>document.removeEventListener("pointerup",A),[A]),u.jsx(tw,{asChild:!0,...m,children:u.jsx(Cn.button,{"aria-describedby":d.open?d.contentId:void 0,"data-state":d.stateAttribute,...o,ref:b,onPointerMove:$t(e.onPointerMove,k=>{k.pointerType!=="touch"&&!j.current&&!p.isPointerInTransitRef.current&&(d.onTriggerEnter(),j.current=!0)}),onPointerLeave:$t(e.onPointerLeave,()=>{d.onTriggerLeave(),j.current=!1}),onPointerDown:$t(e.onPointerDown,()=>{d.open&&d.onClose(),S.current=!0,document.addEventListener("pointerup",A,{once:!0})}),onFocus:$t(e.onFocus,()=>{S.current||d.onOpen()}),onBlur:$t(e.onBlur,d.onClose),onClick:$t(e.onClick,d.onClose)})})});az.displayName=zT;var t2="TooltipPortal",[dse,hse]=jC(t2,{forceMount:void 0}),oz=e=>{const{__scopeTooltip:r,forceMount:s,children:o,container:d}=e,p=nw(t2,r);return u.jsx(dse,{scope:r,forceMount:s,children:u.jsx(lo,{present:s||p.open,children:u.jsx(_g,{asChild:!0,container:d,children:o})})})};oz.displayName=t2;var xg="TooltipContent",lz=R.forwardRef((e,r)=>{const s=hse(xg,e.__scopeTooltip),{forceMount:o=s.forceMount,side:d="top",...p}=e,m=nw(xg,e.__scopeTooltip);return u.jsx(lo,{present:o||m.open,children:m.disableHoverableContent?u.jsx(cz,{side:d,...p,ref:r}):u.jsx(pse,{side:d,...p,ref:r})})}),pse=R.forwardRef((e,r)=>{const s=nw(xg,e.__scopeTooltip),o=e2(xg,e.__scopeTooltip),d=R.useRef(null),p=zn(r,d),[m,g]=R.useState(null),{trigger:b,onClose:S}=s,j=d.current,{onPointerInTransitChange:A}=o,k=R.useCallback(()=>{g(null),A(!1)},[A]),T=R.useCallback((M,I)=>{const q=M.currentTarget,G={x:M.clientX,y:M.clientY},K=yse(G,q.getBoundingClientRect()),X=vse(G,K),L=xse(I.getBoundingClientRect()),ee=wse([...X,...L]);g(ee),A(!0)},[A]);return R.useEffect(()=>()=>k(),[k]),R.useEffect(()=>{if(b&&j){const M=q=>T(q,j),I=q=>T(q,b);return b.addEventListener("pointerleave",M),j.addEventListener("pointerleave",I),()=>{b.removeEventListener("pointerleave",M),j.removeEventListener("pointerleave",I)}}},[b,j,T,k]),R.useEffect(()=>{if(m){const M=I=>{const q=I.target,G={x:I.clientX,y:I.clientY},K=b?.contains(q)||j?.contains(q),X=!bse(G,m);K?k():X&&(k(),S())};return document.addEventListener("pointermove",M),()=>document.removeEventListener("pointermove",M)}},[b,j,m,S,k]),u.jsx(cz,{...e,ref:p})}),[fse,mse]=jC(Fb,{isInside:!1}),gse=nse("TooltipContent"),cz=R.forwardRef((e,r)=>{const{__scopeTooltip:s,children:o,"aria-label":d,onEscapeKeyDown:p,onPointerDownOutside:m,...g}=e,b=nw(xg,s),S=CC(s),{onClose:j}=b;return R.useEffect(()=>(document.addEventListener(LT,j),()=>document.removeEventListener(LT,j)),[j]),R.useEffect(()=>{if(b.trigger){const A=k=>{k.target?.contains(b.trigger)&&j()};return window.addEventListener("scroll",A,{capture:!0}),()=>window.removeEventListener("scroll",A,{capture:!0})}},[b.trigger,j]),u.jsx(kg,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:p,onPointerDownOutside:m,onFocusOutside:A=>A.preventDefault(),onDismiss:j,children:u.jsxs(SC,{"data-state":b.stateAttribute,...S,...g,ref:r,style:{...g.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[u.jsx(gse,{children:o}),u.jsx(fse,{scope:s,isInside:!0,children:u.jsx(ose,{id:b.contentId,role:"tooltip",children:d||o})})]})})});lz.displayName=xg;var uz="TooltipArrow",dz=R.forwardRef((e,r)=>{const{__scopeTooltip:s,...o}=e,d=CC(s);return mse(uz,s).isInside?null:u.jsx(EC,{...d,...o,ref:r})});dz.displayName=uz;function yse(e,r){const s=Math.abs(r.top-e.y),o=Math.abs(r.bottom-e.y),d=Math.abs(r.right-e.x),p=Math.abs(r.left-e.x);switch(Math.min(s,o,d,p)){case p:return"left";case d:return"right";case s:return"top";case o:return"bottom";default:throw new Error("unreachable")}}function vse(e,r,s=5){const o=[];switch(r){case"top":o.push({x:e.x-s,y:e.y+s},{x:e.x+s,y:e.y+s});break;case"bottom":o.push({x:e.x-s,y:e.y-s},{x:e.x+s,y:e.y-s});break;case"left":o.push({x:e.x+s,y:e.y-s},{x:e.x+s,y:e.y+s});break;case"right":o.push({x:e.x-s,y:e.y-s},{x:e.x-s,y:e.y+s});break}return o}function xse(e){const{top:r,right:s,bottom:o,left:d}=e;return[{x:d,y:r},{x:s,y:r},{x:s,y:o},{x:d,y:o}]}function bse(e,r){const{x:s,y:o}=e;let d=!1;for(let p=0,m=r.length-1;po!=k>o&&s<(A-S)*(o-j)/(k-j)+S&&(d=!d)}return d}function wse(e){const r=e.slice();return r.sort((s,o)=>s.xo.x?1:s.yo.y?1:0),Sse(r)}function Sse(e){if(e.length<=1)return e.slice();const r=[];for(let o=0;o=2;){const p=r[r.length-1],m=r[r.length-2];if((p.x-m.x)*(d.y-m.y)>=(p.y-m.y)*(d.x-m.x))r.pop();else break}r.push(d)}r.pop();const s=[];for(let o=e.length-1;o>=0;o--){const d=e[o];for(;s.length>=2;){const p=s[s.length-1],m=s[s.length-2];if((p.x-m.x)*(d.y-m.y)>=(p.y-m.y)*(d.x-m.x))s.pop();else break}s.push(d)}return s.pop(),r.length===1&&s.length===1&&r[0].x===s[0].x&&r[0].y===s[0].y?r:r.concat(s)}var Ese=sz,jse=iz,Cse=az,Ase=oz,Ose=lz,kse=dz;function rw({delayDuration:e=0,...r}){return u.jsx(Ese,{"data-slot":"tooltip-provider",delayDuration:e,...r})}function Mj({...e}){return u.jsx(rw,{children:u.jsx(jse,{"data-slot":"tooltip",...e})})}function Ij({...e}){return u.jsx(Cse,{"data-slot":"tooltip-trigger",...e})}function Lj({className:e,sideOffset:r=0,children:s,...o}){return u.jsx(Ase,{children:u.jsxs(Ose,{"data-slot":"tooltip-content",sideOffset:r,className:ft("bg-foreground text-background animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-fit origin-(--radix-tooltip-content-transform-origin) rounded-md px-3 py-1.5 text-xs text-balance",e),...o,children:[s,u.jsx(kse,{className:"bg-foreground fill-foreground z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px]"})]})})}function hz(e){return e&&e!=="none"?e.slice(0,7):"none"}function Rse(e){if(!e||e==="unknown")return"unknown";const r=new Date(e);return isNaN(+r)?e:r.toLocaleString()}function Tse(e){return e?`v${e.version} (${hz(e.commit)}) • built ${e.built} • ${e.go} ${e.goOS}/${e.goArch}`:""}const _se=R.memo(function(){const r=rr({queryKey:["footer"],queryFn:()=>dte.footer(),staleTime:6e4,refetchOnWindowFocus:!1}),s=r.data,o=R.useMemo(()=>Tse(s),[s]);return u.jsx("footer",{className:"bg-background text-muted-foreground w-full border-t px-3 py-2 text-xs sm:text-sm",children:u.jsxs("div",{className:"mx-auto flex max-w-screen-2xl items-center justify-between",children:[u.jsxs("div",{className:"flex items-center gap-2 text-xs sm:text-sm",children:[u.jsxs("span",{children:["© ",new Date().getFullYear()," GlueOps"]}),u.jsx(bb,{orientation:"vertical",className:"hidden h-4 sm:block"}),u.jsx("span",{className:"hidden sm:block",children:"All systems nominal."})]}),u.jsx("div",{className:"flex flex-wrap items-center gap-2 text-xs sm:text-sm",children:r.isLoading?u.jsx("span",{className:"animate-pulse",children:"loading version…"}):r.isError?u.jsx("span",{className:"text-destructive",children:"version unavailable"}):s?u.jsx(rw,{children:u.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[u.jsx(ns,{variant:"secondary",className:"font-mono",children:s.version}),u.jsxs(Mj,{children:[u.jsx(Ij,{asChild:!0,children:u.jsxs("span",{className:"inline-flex items-center gap-1",children:[u.jsx(YZ,{className:"h-3.5 w-3.5"}),u.jsx("span",{className:"font-mono",children:hz(s.commit)})]})}),u.jsx(Lj,{side:"top",children:u.jsx("div",{className:"font-mono text-xs",children:s.commit})})]}),u.jsx(bb,{orientation:"vertical",className:"h-4"}),u.jsxs(Mj,{children:[u.jsx(Ij,{asChild:!0,children:u.jsxs("span",{className:"inline-flex items-center gap-1",children:[u.jsx(oL,{className:"h-3.5 w-3.5"}),u.jsx("span",{children:s.go})]})}),u.jsx(Lj,{side:"top",children:u.jsxs("div",{className:"font-mono text-xs",children:[s.goOS,"/",s.goArch]})})]}),u.jsx(bb,{orientation:"vertical",className:"hidden h-4 sm:block"}),u.jsxs("span",{className:"hidden sm:inline",children:["built ",u.jsx("span",{className:"font-mono",children:Rse(s.built)})]}),u.jsx(bb,{orientation:"vertical",className:"hidden h-4 sm:block"}),u.jsx(Fe,{variant:"ghost",size:"icon",className:"h-7 w-7",onClick:()=>{navigator.clipboard?.writeText(o).catch(()=>{})},title:"Copy version details",children:u.jsx(NZ,{className:"h-4 w-4"})}),u.jsxs("a",{href:"/api/v1/version",target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-1 text-xs underline-offset-4 hover:underline",title:"Open raw version JSON",children:["JSON ",u.jsx(BZ,{className:"h-3.5 w-3.5"})]})]})}):null})]})})});var pz={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},dI=Je.createContext&&Je.createContext(pz),$se=["attr","size","title"];function Nse(e,r){if(e==null)return{};var s=Dse(e,r),o,d;if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(e);for(d=0;d=0)&&Object.prototype.propertyIsEnumerable.call(e,o)&&(s[o]=e[o])}return s}function Dse(e,r){if(e==null)return{};var s={};for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){if(r.indexOf(o)>=0)continue;s[o]=e[o]}return s}function zj(){return zj=Object.assign?Object.assign.bind():function(e){for(var r=1;rJe.createElement(r.tag,Fj({key:s},r.attr),fz(r.child)))}function sw(e){return r=>Je.createElement(Lse,zj({attr:Fj({},e.attr)},r),fz(e.child))}function Lse(e){var r=s=>{var{attr:o,size:d,title:p}=e,m=Nse(e,$se),g=d||s.size||"1em",b;return s.className&&(b=s.className),e.className&&(b=(b?b+" ":"")+e.className),Je.createElement("svg",zj({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},s.attr,o,m,{className:b,style:Fj(Fj({color:e.color||s.color},s.style),e.style),height:g,width:g,xmlns:"http://www.w3.org/2000/svg"}),p&&Je.createElement("title",null,p),e.children)};return dI!==void 0?Je.createElement(dI.Consumer,null,s=>r(s)):r(pz)}function zse(e){return sw({attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M888 680h-54V540H546v-92h238c8.8 0 16-7.2 16-16V168c0-8.8-7.2-16-16-16H240c-8.8 0-16 7.2-16 16v264c0 8.8 7.2 16 16 16h238v92H190v140h-54c-4.4 0-8 3.6-8 8v176c0 4.4 3.6 8 8 8h176c4.4 0 8-3.6 8-8V688c0-4.4-3.6-8-8-8h-54v-72h220v72h-54c-4.4 0-8 3.6-8 8v176c0 4.4 3.6 8 8 8h176c4.4 0 8-3.6 8-8V688c0-4.4-3.6-8-8-8h-54v-72h220v72h-54c-4.4 0-8 3.6-8 8v176c0 4.4 3.6 8 8 8h176c4.4 0 8-3.6 8-8V688c0-4.4-3.6-8-8-8zM256 805.3c0 1.5-1.2 2.7-2.7 2.7h-58.7c-1.5 0-2.7-1.2-2.7-2.7v-58.7c0-1.5 1.2-2.7 2.7-2.7h58.7c1.5 0 2.7 1.2 2.7 2.7v58.7zm288 0c0 1.5-1.2 2.7-2.7 2.7h-58.7c-1.5 0-2.7-1.2-2.7-2.7v-58.7c0-1.5 1.2-2.7 2.7-2.7h58.7c1.5 0 2.7 1.2 2.7 2.7v58.7zM288 384V216h448v168H288zm544 421.3c0 1.5-1.2 2.7-2.7 2.7h-58.7c-1.5 0-2.7-1.2-2.7-2.7v-58.7c0-1.5 1.2-2.7 2.7-2.7h58.7c1.5 0 2.7 1.2 2.7 2.7v58.7zM360 300a40 40 0 1 0 80 0 40 40 0 1 0-80 0z"},child:[]}]})(e)}function Fse(e){return sw({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",strokeWidth:"2",d:"M3,6 L21,6 L3,6 Z M10,2 L10,4 M14,2 L14,4 M16,12 C18.3736719,13.1826446 20,15.6506255 20,19 L20,23 L4,23 L4,19 C4,15.6457258 5.6310898,13.1754259 8,12 M12,16.5 L12,23 M12,13 C15.3137085,13 18,10.3137085 18,7 C18,3.6862915 15.3137085,1 12,1 C8.6862915,1 6,3.6862915 6,7 C6,10.3137085 8.6862915,13 12,13 Z M8,12 C8,14.209139 9.790861,16 12,16 L12,16 C14.209139,16 16,14.209139 16,12"},child:[]}]})(e)}function qse(e){return sw({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"},child:[]},{tag:"path",attr:{d:"M19 15v4H5v-4h14m1-2H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1v-6c0-.55-.45-1-1-1zM7 18.5c-.82 0-1.5-.67-1.5-1.5s.68-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM19 5v4H5V5h14m1-2H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1V4c0-.55-.45-1-1-1zM7 8.5c-.82 0-1.5-.67-1.5-1.5S6.18 5.5 7 5.5s1.5.68 1.5 1.5S7.83 8.5 7 8.5z"},child:[]}]})(e)}function Bse(e){return sw({attr:{role:"img",viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M12 0C5.383 0 0 5.383 0 12s5.383 12 12 12c6.616 0 12-5.383 12-12S18.616 0 12 0zm0 1.144c5.995 0 10.856 4.86 10.856 10.856 0 5.995-4.86 10.856-10.856 10.856-5.996 0-10.856-4.86-10.856-10.856C1.144 6.004 6.004 1.144 12 1.144zM8.37 5.868a6.707 6.707 0 0 0-.423.005c-.983.056-1.573.517-1.735 1.472-.115.665-.096 1.348-.143 2.017-.013.35-.05.697-.115 1.038-.134.609-.397.798-1.016.83a2.65 2.65 0 0 0-.244.042v1.463c1.126.055 1.278.452 1.37 1.629.033.429-.013.858.015 1.287.018.406.073.808.156 1.2.259 1.075 1.307 1.435 2.575 1.218v-1.283c-.203 0-.383.005-.558 0-.43-.013-.591-.12-.632-.535-.056-.535-.042-1.08-.075-1.62-.064-1.001-.175-1.988-1.153-2.625.503-.37.868-.812.983-1.398.083-.41.134-.821.166-1.237.028-.415-.023-.84.014-1.25.06-.665.102-.937.9-.91.12 0 .235-.017.369-.027v-1.31c-.16 0-.31-.004-.454-.006zm7.593.009a4.247 4.247 0 0 0-.813.06v1.274c.245 0 .434 0 .623.005.328.004.577.13.61.494.032.332.031.669.064 1.006.065.669.101 1.347.217 2.007.102.544.475.95.941 1.283-.817.549-1.057 1.333-1.098 2.215-.023.604-.037 1.213-.069 1.822-.028.554-.222.734-.78.748-.157.004-.31.018-.484.028v1.305c.327 0 .627.019.927 0 .932-.055 1.495-.507 1.68-1.412.078-.498.124-1 .138-1.504.032-.461.028-.927.074-1.384.069-.715.397-1.01 1.112-1.057a.972.972 0 0 0 .199-.046v-1.463c-.12-.014-.204-.027-.291-.032-.536-.023-.804-.203-.937-.71a5.146 5.146 0 0 1-.152-.993c-.037-.618-.033-1.241-.074-1.86-.08-1.192-.794-1.753-1.887-1.786zm-6.89 5.28a.844.844 0 0 0-.083 1.684h.055a.83.83 0 0 0 .877-.78v-.046a.845.845 0 0 0-.83-.858zm2.911 0a.808.808 0 0 0-.834.78c0 .027 0 .05.004.078 0 .503.342.826.859.826.507 0 .826-.332.826-.853-.005-.503-.342-.836-.855-.831zm2.963 0a.861.861 0 0 0-.876.835c0 .47.378.849.849.849h.009c.425.074.853-.337.881-.83.023-.457-.392-.854-.863-.854z"},child:[]}]})(e)}function Use(e){return sw({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M12 13m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0"},child:[]},{tag:"path",attr:{d:"M12 20m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},child:[]},{tag:"path",attr:{d:"M12 16v3"},child:[]},{tag:"path",attr:{d:"M12 10v-7"},child:[]},{tag:"path",attr:{d:"M9 6l3 -3l3 3"},child:[]},{tag:"path",attr:{d:"M12 10v-7"},child:[]},{tag:"path",attr:{d:"M9 6l3 -3l3 3"},child:[]},{tag:"path",attr:{d:"M14.894 12.227l6.11 -2.224"},child:[]},{tag:"path",attr:{d:"M17.159 8.21l3.845 1.793l-1.793 3.845"},child:[]},{tag:"path",attr:{d:"M9.101 12.214l-6.075 -2.211"},child:[]},{tag:"path",attr:{d:"M6.871 8.21l-3.845 1.793l1.793 3.845"},child:[]}]})(e)}const Kse=[{to:"/clusters",label:"Clusters",icon:zse},{to:"/load-balancers",label:"Load Balancers",icon:Use},{to:"/dns",label:"DNS",icon:qse},{to:"/node-pools",label:"Node Pools",icon:yZ},{to:"/annotations",label:"Annotations",icon:PZ},{to:"/labels",label:"Labels",icon:mC},{to:"/taints",label:"Taints",icon:SW},{to:"/servers",label:"Servers",icon:F_},{to:"/ssh",label:"SSH Keys",icon:GZ},{to:"/credentials",label:"Credentials",icon:nW}],Vse=[{to:"/org/members",label:"Members",icon:lL},{to:"/org/api-keys",label:"Org API Keys",icon:JZ},{to:"/org/settings",label:"Org Settings",icon:sL}],Hse=[{to:"/me",label:"Profile",icon:RW}],Gse=[{to:"/admin/users",label:"Users Admin",icon:lL},{to:"/admin/jobs",label:"Jobs Admin",icon:Fse},{to:"/docs",label:"API Docs ",icon:Bse,target:"_blank"}];var pI=1,Xse=.9,Yse=.8,Zse=.17,IR=.1,LR=.999,Wse=.9999,Jse=.99,Qse=/[\\\/_+.#"@\[\(\{&]/,eie=/[\\\/_+.#"@\[\(\{&]/g,tie=/[\s-]/,mz=/[\s-]/g;function FT(e,r,s,o,d,p,m){if(p===r.length)return d===e.length?pI:Jse;var g=`${d},${p}`;if(m[g]!==void 0)return m[g];for(var b=o.charAt(p),S=s.indexOf(b,d),j=0,A,k,T,M;S>=0;)A=FT(e,r,s,o,S+1,p+1,m),A>j&&(S===d?A*=pI:Qse.test(e.charAt(S-1))?(A*=Yse,T=e.slice(d,S-1).match(eie),T&&d>0&&(A*=Math.pow(LR,T.length))):tie.test(e.charAt(S-1))?(A*=Xse,M=e.slice(d,S-1).match(mz),M&&d>0&&(A*=Math.pow(LR,M.length))):(A*=Zse,d>0&&(A*=Math.pow(LR,S-d))),e.charAt(S)!==r.charAt(p)&&(A*=Wse)),(AA&&(A=k*IR)),A>j&&(j=A),S=s.indexOf(b,S+1);return m[g]=j,j}function fI(e){return e.toLowerCase().replace(mz," ")}function nie(e,r,s){return e=s&&s.length>0?`${e+" "+s.join(" ")}`:e,FT(e,r,fI(e),fI(r),0,0,{})}var zR="focusScope.autoFocusOnMount",FR="focusScope.autoFocusOnUnmount",mI={bubbles:!1,cancelable:!0},rie="FocusScope",iw=R.forwardRef((e,r)=>{const{loop:s=!1,trapped:o=!1,onMountAutoFocus:d,onUnmountAutoFocus:p,...m}=e,[g,b]=R.useState(null),S=tl(d),j=tl(p),A=R.useRef(null),k=zn(r,I=>b(I)),T=R.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;R.useEffect(()=>{if(o){let I=function(X){if(T.paused||!g)return;const L=X.target;g.contains(L)?A.current=L:Pd(A.current,{select:!0})},q=function(X){if(T.paused||!g)return;const L=X.relatedTarget;L!==null&&(g.contains(L)||Pd(A.current,{select:!0}))},G=function(X){if(document.activeElement===document.body)for(const ee of X)ee.removedNodes.length>0&&Pd(g)};document.addEventListener("focusin",I),document.addEventListener("focusout",q);const K=new MutationObserver(G);return g&&K.observe(g,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",I),document.removeEventListener("focusout",q),K.disconnect()}}},[o,g,T.paused]),R.useEffect(()=>{if(g){yI.add(T);const I=document.activeElement;if(!g.contains(I)){const G=new CustomEvent(zR,mI);g.addEventListener(zR,S),g.dispatchEvent(G),G.defaultPrevented||(sie(cie(gz(g)),{select:!0}),document.activeElement===I&&Pd(g))}return()=>{g.removeEventListener(zR,S),setTimeout(()=>{const G=new CustomEvent(FR,mI);g.addEventListener(FR,j),g.dispatchEvent(G),G.defaultPrevented||Pd(I??document.body,{select:!0}),g.removeEventListener(FR,j),yI.remove(T)},0)}}},[g,S,j,T]);const M=R.useCallback(I=>{if(!s&&!o||T.paused)return;const q=I.key==="Tab"&&!I.altKey&&!I.ctrlKey&&!I.metaKey,G=document.activeElement;if(q&&G){const K=I.currentTarget,[X,L]=iie(K);X&&L?!I.shiftKey&&G===L?(I.preventDefault(),s&&Pd(X,{select:!0})):I.shiftKey&&G===X&&(I.preventDefault(),s&&Pd(L,{select:!0})):G===K&&I.preventDefault()}},[s,o,T.paused]);return u.jsx(Cn.div,{tabIndex:-1,...m,ref:k,onKeyDown:M})});iw.displayName=rie;function sie(e,{select:r=!1}={}){const s=document.activeElement;for(const o of e)if(Pd(o,{select:r}),document.activeElement!==s)return}function iie(e){const r=gz(e),s=gI(r,e),o=gI(r.reverse(),e);return[s,o]}function gz(e){const r=[],s=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:o=>{const d=o.tagName==="INPUT"&&o.type==="hidden";return o.disabled||o.hidden||d?NodeFilter.FILTER_SKIP:o.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;s.nextNode();)r.push(s.currentNode);return r}function gI(e,r){for(const s of e)if(!aie(s,{upTo:r}))return s}function aie(e,{upTo:r}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(r!==void 0&&e===r)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function oie(e){return e instanceof HTMLInputElement&&"select"in e}function Pd(e,{select:r=!1}={}){if(e&&e.focus){const s=document.activeElement;e.focus({preventScroll:!0}),e!==s&&oie(e)&&r&&e.select()}}var yI=lie();function lie(){let e=[];return{add(r){const s=e[0];r!==s&&s?.pause(),e=vI(e,r),e.unshift(r)},remove(r){e=vI(e,r),e[0]?.resume()}}}function vI(e,r){const s=[...e],o=s.indexOf(r);return o!==-1&&s.splice(o,1),s}function cie(e){return e.filter(r=>r.tagName!=="A")}var qR=0;function AC(){R.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??xI()),document.body.insertAdjacentElement("beforeend",e[1]??xI()),qR++,()=>{qR===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),qR--}},[])}function xI(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var nc=function(){return nc=Object.assign||function(r){for(var s,o=1,d=arguments.length;o"u")return Aie;var r=Oie(e),s=document.documentElement.clientWidth,o=window.innerWidth;return{left:r[0],top:r[1],right:r[2],gap:Math.max(0,o-s+r[2]-r[0])}},Rie=bz(),fg="data-scroll-locked",Tie=function(e,r,s,o){var d=e.left,p=e.top,m=e.right,g=e.gap;return s===void 0&&(s="margin"),` - .`.concat(die,` { - overflow: hidden `).concat(o,`; - padding-right: `).concat(g,"px ").concat(o,`; - } - body[`).concat(fg,`] { - overflow: hidden `).concat(o,`; - overscroll-behavior: contain; - `).concat([r&&"position: relative ".concat(o,";"),s==="margin"&&` - padding-left: `.concat(d,`px; - padding-top: `).concat(p,`px; - padding-right: `).concat(m,`px; - margin-left:0; - margin-top:0; - margin-right: `).concat(g,"px ").concat(o,`; - `),s==="padding"&&"padding-right: ".concat(g,"px ").concat(o,";")].filter(Boolean).join(""),` - } - - .`).concat(gj,` { - right: `).concat(g,"px ").concat(o,`; - } - - .`).concat(yj,` { - margin-right: `).concat(g,"px ").concat(o,`; - } - - .`).concat(gj," .").concat(gj,` { - right: 0 `).concat(o,`; - } - - .`).concat(yj," .").concat(yj,` { - margin-right: 0 `).concat(o,`; - } - - body[`).concat(fg,`] { - `).concat(hie,": ").concat(g,`px; - } -`)},wI=function(){var e=parseInt(document.body.getAttribute(fg)||"0",10);return isFinite(e)?e:0},_ie=function(){R.useEffect(function(){return document.body.setAttribute(fg,(wI()+1).toString()),function(){var e=wI()-1;e<=0?document.body.removeAttribute(fg):document.body.setAttribute(fg,e.toString())}},[])},$ie=function(e){var r=e.noRelative,s=e.noImportant,o=e.gapMode,d=o===void 0?"margin":o;_ie();var p=R.useMemo(function(){return kie(d)},[d]);return R.createElement(Rie,{styles:Tie(p,!r,d,s?"":"!important")})},qT=!1;if(typeof window<"u")try{var GE=Object.defineProperty({},"passive",{get:function(){return qT=!0,!0}});window.addEventListener("test",GE,GE),window.removeEventListener("test",GE,GE)}catch{qT=!1}var Vm=qT?{passive:!1}:!1,Nie=function(e){return e.tagName==="TEXTAREA"},wz=function(e,r){if(!(e instanceof Element))return!1;var s=window.getComputedStyle(e);return s[r]!=="hidden"&&!(s.overflowY===s.overflowX&&!Nie(e)&&s[r]==="visible")},Die=function(e){return wz(e,"overflowY")},Pie=function(e){return wz(e,"overflowX")},SI=function(e,r){var s=r.ownerDocument,o=r;do{typeof ShadowRoot<"u"&&o instanceof ShadowRoot&&(o=o.host);var d=Sz(e,o);if(d){var p=Ez(e,o),m=p[1],g=p[2];if(m>g)return!0}o=o.parentNode}while(o&&o!==s.body);return!1},Mie=function(e){var r=e.scrollTop,s=e.scrollHeight,o=e.clientHeight;return[r,s,o]},Iie=function(e){var r=e.scrollLeft,s=e.scrollWidth,o=e.clientWidth;return[r,s,o]},Sz=function(e,r){return e==="v"?Die(r):Pie(r)},Ez=function(e,r){return e==="v"?Mie(r):Iie(r)},Lie=function(e,r){return e==="h"&&r==="rtl"?-1:1},zie=function(e,r,s,o,d){var p=Lie(e,window.getComputedStyle(r).direction),m=p*o,g=s.target,b=r.contains(g),S=!1,j=m>0,A=0,k=0;do{if(!g)break;var T=Ez(e,g),M=T[0],I=T[1],q=T[2],G=I-q-p*M;(M||G)&&Sz(e,g)&&(A+=G,k+=M);var K=g.parentNode;g=K&&K.nodeType===Node.DOCUMENT_FRAGMENT_NODE?K.host:K}while(!b&&g!==document.body||b&&(r.contains(g)||r===g));return(j&&Math.abs(A)<1||!j&&Math.abs(k)<1)&&(S=!0),S},XE=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},EI=function(e){return[e.deltaX,e.deltaY]},jI=function(e){return e&&"current"in e?e.current:e},Fie=function(e,r){return e[0]===r[0]&&e[1]===r[1]},qie=function(e){return` - .block-interactivity-`.concat(e,` {pointer-events: none;} - .allow-interactivity-`).concat(e,` {pointer-events: all;} -`)},Bie=0,Hm=[];function Uie(e){var r=R.useRef([]),s=R.useRef([0,0]),o=R.useRef(),d=R.useState(Bie++)[0],p=R.useState(bz)[0],m=R.useRef(e);R.useEffect(function(){m.current=e},[e]),R.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(d));var I=uie([e.lockRef.current],(e.shards||[]).map(jI),!0).filter(Boolean);return I.forEach(function(q){return q.classList.add("allow-interactivity-".concat(d))}),function(){document.body.classList.remove("block-interactivity-".concat(d)),I.forEach(function(q){return q.classList.remove("allow-interactivity-".concat(d))})}}},[e.inert,e.lockRef.current,e.shards]);var g=R.useCallback(function(I,q){if("touches"in I&&I.touches.length===2||I.type==="wheel"&&I.ctrlKey)return!m.current.allowPinchZoom;var G=XE(I),K=s.current,X="deltaX"in I?I.deltaX:K[0]-G[0],L="deltaY"in I?I.deltaY:K[1]-G[1],ee,oe=I.target,Q=Math.abs(X)>Math.abs(L)?"h":"v";if("touches"in I&&Q==="h"&&oe.type==="range")return!1;var ne=window.getSelection(),de=ne&&ne.anchorNode,je=de?de===oe||de.contains(oe):!1;if(je)return!1;var ve=SI(Q,oe);if(!ve)return!0;if(ve?ee=Q:(ee=Q==="v"?"h":"v",ve=SI(Q,oe)),!ve)return!1;if(!o.current&&"changedTouches"in I&&(X||L)&&(o.current=ee),!ee)return!0;var le=o.current||ee;return zie(le,q,I,le==="h"?X:L)},[]),b=R.useCallback(function(I){var q=I;if(!(!Hm.length||Hm[Hm.length-1]!==p)){var G="deltaY"in q?EI(q):XE(q),K=r.current.filter(function(ee){return ee.name===q.type&&(ee.target===q.target||q.target===ee.shadowParent)&&Fie(ee.delta,G)})[0];if(K&&K.should){q.cancelable&&q.preventDefault();return}if(!K){var X=(m.current.shards||[]).map(jI).filter(Boolean).filter(function(ee){return ee.contains(q.target)}),L=X.length>0?g(q,X[0]):!m.current.noIsolation;L&&q.cancelable&&q.preventDefault()}}},[]),S=R.useCallback(function(I,q,G,K){var X={name:I,delta:q,target:G,should:K,shadowParent:Kie(G)};r.current.push(X),setTimeout(function(){r.current=r.current.filter(function(L){return L!==X})},1)},[]),j=R.useCallback(function(I){s.current=XE(I),o.current=void 0},[]),A=R.useCallback(function(I){S(I.type,EI(I),I.target,g(I,e.lockRef.current))},[]),k=R.useCallback(function(I){S(I.type,XE(I),I.target,g(I,e.lockRef.current))},[]);R.useEffect(function(){return Hm.push(p),e.setCallbacks({onScrollCapture:A,onWheelCapture:A,onTouchMoveCapture:k}),document.addEventListener("wheel",b,Vm),document.addEventListener("touchmove",b,Vm),document.addEventListener("touchstart",j,Vm),function(){Hm=Hm.filter(function(I){return I!==p}),document.removeEventListener("wheel",b,Vm),document.removeEventListener("touchmove",b,Vm),document.removeEventListener("touchstart",j,Vm)}},[]);var T=e.removeScrollBar,M=e.inert;return R.createElement(R.Fragment,null,M?R.createElement(p,{styles:qie(d)}):null,T?R.createElement($ie,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Kie(e){for(var r=null;e!==null;)e instanceof ShadowRoot&&(r=e.host,e=e.host),e=e.parentNode;return r}const Vie=xie(xz,Uie);var aw=R.forwardRef(function(e,r){return R.createElement(OC,nc({},e,{ref:r,sideCar:Vie}))});aw.classNames=OC.classNames;var Hie=function(e){if(typeof document>"u")return null;var r=Array.isArray(e)?e[0]:e;return r.ownerDocument.body},Gm=new WeakMap,YE=new WeakMap,ZE={},VR=0,jz=function(e){return e&&(e.host||jz(e.parentNode))},Gie=function(e,r){return r.map(function(s){if(e.contains(s))return s;var o=jz(s);return o&&e.contains(o)?o:(console.error("aria-hidden",s,"in not contained inside",e,". Doing nothing"),null)}).filter(function(s){return!!s})},Xie=function(e,r,s,o){var d=Gie(r,Array.isArray(e)?e:[e]);ZE[s]||(ZE[s]=new WeakMap);var p=ZE[s],m=[],g=new Set,b=new Set(d),S=function(A){!A||g.has(A)||(g.add(A),S(A.parentNode))};d.forEach(S);var j=function(A){!A||b.has(A)||Array.prototype.forEach.call(A.children,function(k){if(g.has(k))j(k);else try{var T=k.getAttribute(o),M=T!==null&&T!=="false",I=(Gm.get(k)||0)+1,q=(p.get(k)||0)+1;Gm.set(k,I),p.set(k,q),m.push(k),I===1&&M&&YE.set(k,!0),q===1&&k.setAttribute(s,"true"),M||k.setAttribute(o,"true")}catch(G){console.error("aria-hidden: cannot operate on ",k,G)}})};return j(r),g.clear(),VR++,function(){m.forEach(function(A){var k=Gm.get(A)-1,T=p.get(A)-1;Gm.set(A,k),p.set(A,T),k||(YE.has(A)||A.removeAttribute(o),YE.delete(A)),T||A.removeAttribute(s)}),VR--,VR||(Gm=new WeakMap,Gm=new WeakMap,YE=new WeakMap,ZE={})}},kC=function(e,r,s){s===void 0&&(s="data-aria-hidden");var o=Array.from(Array.isArray(e)?e:[e]),d=Hie(e);return d?(o.push.apply(o,Array.from(d.querySelectorAll("[aria-live], script"))),Xie(o,d,s,"aria-hidden")):function(){return null}};function Yie(e){const r=Zie(e),s=R.forwardRef((o,d)=>{const{children:p,...m}=o,g=R.Children.toArray(p),b=g.find(Jie);if(b){const S=b.props.children,j=g.map(A=>A===b?R.Children.count(S)>1?R.Children.only(null):R.isValidElement(S)?S.props.children:null:A);return u.jsx(r,{...m,ref:d,children:R.isValidElement(S)?R.cloneElement(S,void 0,j):null})}return u.jsx(r,{...m,ref:d,children:p})});return s.displayName=`${e}.Slot`,s}function Zie(e){const r=R.forwardRef((s,o)=>{const{children:d,...p}=s;if(R.isValidElement(d)){const m=eae(d),g=Qie(p,d.props);return d.type!==R.Fragment&&(g.ref=o?Li(o,m):m),R.cloneElement(d,g)}return R.Children.count(d)>1?R.Children.only(null):null});return r.displayName=`${e}.SlotClone`,r}var Wie=Symbol("radix.slottable");function Jie(e){return R.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Wie}function Qie(e,r){const s={...r};for(const o in r){const d=e[o],p=r[o];/^on[A-Z]/.test(o)?d&&p?s[o]=(...g)=>{const b=p(...g);return d(...g),b}:d&&(s[o]=d):o==="style"?s[o]={...d,...p}:o==="className"&&(s[o]=[d,p].filter(Boolean).join(" "))}return{...e,...s}}function eae(e){let r=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning;return s?e.ref:(r=Object.getOwnPropertyDescriptor(e,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning,s?e.props.ref:e.props.ref||e.ref)}var RC="Dialog",[Cz,Az]=al(RC),[tae,ol]=Cz(RC),Oz=e=>{const{__scopeDialog:r,children:s,open:o,defaultOpen:d,onOpenChange:p,modal:m=!0}=e,g=R.useRef(null),b=R.useRef(null),[S,j]=qd({prop:o,defaultProp:d??!1,onChange:p,caller:RC});return u.jsx(tae,{scope:r,triggerRef:g,contentRef:b,contentId:Vs(),titleId:Vs(),descriptionId:Vs(),open:S,onOpenChange:j,onOpenToggle:R.useCallback(()=>j(A=>!A),[j]),modal:m,children:s})};Oz.displayName=RC;var kz="DialogTrigger",Rz=R.forwardRef((e,r)=>{const{__scopeDialog:s,...o}=e,d=ol(kz,s),p=zn(r,d.triggerRef);return u.jsx(Cn.button,{type:"button","aria-haspopup":"dialog","aria-expanded":d.open,"aria-controls":d.contentId,"data-state":s2(d.open),...o,ref:p,onClick:$t(e.onClick,d.onOpenToggle)})});Rz.displayName=kz;var n2="DialogPortal",[nae,Tz]=Cz(n2,{forceMount:void 0}),_z=e=>{const{__scopeDialog:r,forceMount:s,children:o,container:d}=e,p=ol(n2,r);return u.jsx(nae,{scope:r,forceMount:s,children:R.Children.map(o,m=>u.jsx(lo,{present:s||p.open,children:u.jsx(_g,{asChild:!0,container:d,children:m})}))})};_z.displayName=n2;var qj="DialogOverlay",$z=R.forwardRef((e,r)=>{const s=Tz(qj,e.__scopeDialog),{forceMount:o=s.forceMount,...d}=e,p=ol(qj,e.__scopeDialog);return p.modal?u.jsx(lo,{present:o||p.open,children:u.jsx(sae,{...d,ref:r})}):null});$z.displayName=qj;var rae=Yie("DialogOverlay.RemoveScroll"),sae=R.forwardRef((e,r)=>{const{__scopeDialog:s,...o}=e,d=ol(qj,s);return u.jsx(aw,{as:rae,allowPinchZoom:!0,shards:[d.contentRef],children:u.jsx(Cn.div,{"data-state":s2(d.open),...o,ref:r,style:{pointerEvents:"auto",...o.style}})})}),kp="DialogContent",Nz=R.forwardRef((e,r)=>{const s=Tz(kp,e.__scopeDialog),{forceMount:o=s.forceMount,...d}=e,p=ol(kp,e.__scopeDialog);return u.jsx(lo,{present:o||p.open,children:p.modal?u.jsx(iae,{...d,ref:r}):u.jsx(aae,{...d,ref:r})})});Nz.displayName=kp;var iae=R.forwardRef((e,r)=>{const s=ol(kp,e.__scopeDialog),o=R.useRef(null),d=zn(r,s.contentRef,o);return R.useEffect(()=>{const p=o.current;if(p)return kC(p)},[]),u.jsx(Dz,{...e,ref:d,trapFocus:s.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:$t(e.onCloseAutoFocus,p=>{p.preventDefault(),s.triggerRef.current?.focus()}),onPointerDownOutside:$t(e.onPointerDownOutside,p=>{const m=p.detail.originalEvent,g=m.button===0&&m.ctrlKey===!0;(m.button===2||g)&&p.preventDefault()}),onFocusOutside:$t(e.onFocusOutside,p=>p.preventDefault())})}),aae=R.forwardRef((e,r)=>{const s=ol(kp,e.__scopeDialog),o=R.useRef(!1),d=R.useRef(!1);return u.jsx(Dz,{...e,ref:r,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:p=>{e.onCloseAutoFocus?.(p),p.defaultPrevented||(o.current||s.triggerRef.current?.focus(),p.preventDefault()),o.current=!1,d.current=!1},onInteractOutside:p=>{e.onInteractOutside?.(p),p.defaultPrevented||(o.current=!0,p.detail.originalEvent.type==="pointerdown"&&(d.current=!0));const m=p.target;s.triggerRef.current?.contains(m)&&p.preventDefault(),p.detail.originalEvent.type==="focusin"&&d.current&&p.preventDefault()}})}),Dz=R.forwardRef((e,r)=>{const{__scopeDialog:s,trapFocus:o,onOpenAutoFocus:d,onCloseAutoFocus:p,...m}=e,g=ol(kp,s),b=R.useRef(null),S=zn(r,b);return AC(),u.jsxs(u.Fragment,{children:[u.jsx(iw,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:d,onUnmountAutoFocus:p,children:u.jsx(kg,{role:"dialog",id:g.contentId,"aria-describedby":g.descriptionId,"aria-labelledby":g.titleId,"data-state":s2(g.open),...m,ref:S,onDismiss:()=>g.onOpenChange(!1)})}),u.jsxs(u.Fragment,{children:[u.jsx(lae,{titleId:g.titleId}),u.jsx(uae,{contentRef:b,descriptionId:g.descriptionId})]})]})}),r2="DialogTitle",Pz=R.forwardRef((e,r)=>{const{__scopeDialog:s,...o}=e,d=ol(r2,s);return u.jsx(Cn.h2,{id:d.titleId,...o,ref:r})});Pz.displayName=r2;var Mz="DialogDescription",Iz=R.forwardRef((e,r)=>{const{__scopeDialog:s,...o}=e,d=ol(Mz,s);return u.jsx(Cn.p,{id:d.descriptionId,...o,ref:r})});Iz.displayName=Mz;var Lz="DialogClose",zz=R.forwardRef((e,r)=>{const{__scopeDialog:s,...o}=e,d=ol(Lz,s);return u.jsx(Cn.button,{type:"button",...o,ref:r,onClick:$t(e.onClick,()=>d.onOpenChange(!1))})});zz.displayName=Lz;function s2(e){return e?"open":"closed"}var Fz="DialogTitleWarning",[oae,qz]=fne(Fz,{contentName:kp,titleName:r2,docsSlug:"dialog"}),lae=({titleId:e})=>{const r=qz(Fz),s=`\`${r.contentName}\` requires a \`${r.titleName}\` for the component to be accessible for screen reader users. - -If you want to hide the \`${r.titleName}\`, you can wrap it with our VisuallyHidden component. - -For more information, see https://radix-ui.com/primitives/docs/components/${r.docsSlug}`;return R.useEffect(()=>{e&&(document.getElementById(e)||console.error(s))},[s,e]),null},cae="DialogDescriptionWarning",uae=({contentRef:e,descriptionId:r})=>{const o=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${qz(cae).contentName}}.`;return R.useEffect(()=>{const d=e.current?.getAttribute("aria-describedby");r&&d&&(document.getElementById(r)||console.warn(o))},[o,e,r]),null},TC=Oz,Bz=Rz,_C=_z,$C=$z,NC=Nz,i2=Pz,a2=Iz,ow=zz,dae=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Gd=dae.reduce((e,r)=>{const s=Qb(`Primitive.${r}`),o=R.forwardRef((d,p)=>{const{asChild:m,...g}=d,b=m?s:r;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(b,{...g,ref:p})});return o.displayName=`Primitive.${r}`,{...e,[r]:o}},{}),ib='[cmdk-group=""]',HR='[cmdk-group-items=""]',hae='[cmdk-group-heading=""]',Uz='[cmdk-item=""]',CI=`${Uz}:not([aria-disabled="true"])`,BT="cmdk-item-select",Zm="data-value",pae=(e,r,s)=>nie(e,r,s),Kz=R.createContext(void 0),lw=()=>R.useContext(Kz),Vz=R.createContext(void 0),o2=()=>R.useContext(Vz),Hz=R.createContext(void 0),Gz=R.forwardRef((e,r)=>{let s=Wm(()=>{var Oe,ke;return{search:"",value:(ke=(Oe=e.value)!=null?Oe:e.defaultValue)!=null?ke:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),o=Wm(()=>new Set),d=Wm(()=>new Map),p=Wm(()=>new Map),m=Wm(()=>new Set),g=Xz(e),{label:b,children:S,value:j,onValueChange:A,filter:k,shouldFilter:T,loop:M,disablePointerSelection:I=!1,vimBindings:q=!0,...G}=e,K=Vs(),X=Vs(),L=Vs(),ee=R.useRef(null),oe=jae();Rp(()=>{if(j!==void 0){let Oe=j.trim();s.current.value=Oe,Q.emit()}},[j]),Rp(()=>{oe(6,be)},[]);let Q=R.useMemo(()=>({subscribe:Oe=>(m.current.add(Oe),()=>m.current.delete(Oe)),snapshot:()=>s.current,setState:(Oe,ke,Ve)=>{var ie,De,Le,tt;if(!Object.is(s.current[Oe],ke)){if(s.current[Oe]=ke,Oe==="search")le(),je(),oe(1,ve);else if(Oe==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let yt=document.getElementById(L);yt?yt.focus():(ie=document.getElementById(K))==null||ie.focus()}if(oe(7,()=>{var yt;s.current.selectedItemId=(yt=Ce())==null?void 0:yt.id,Q.emit()}),Ve||oe(5,be),((De=g.current)==null?void 0:De.value)!==void 0){let yt=ke??"";(tt=(Le=g.current).onValueChange)==null||tt.call(Le,yt);return}}Q.emit()}},emit:()=>{m.current.forEach(Oe=>Oe())}}),[]),ne=R.useMemo(()=>({value:(Oe,ke,Ve)=>{var ie;ke!==((ie=p.current.get(Oe))==null?void 0:ie.value)&&(p.current.set(Oe,{value:ke,keywords:Ve}),s.current.filtered.items.set(Oe,de(ke,Ve)),oe(2,()=>{je(),Q.emit()}))},item:(Oe,ke)=>(o.current.add(Oe),ke&&(d.current.has(ke)?d.current.get(ke).add(Oe):d.current.set(ke,new Set([Oe]))),oe(3,()=>{le(),je(),s.current.value||ve(),Q.emit()}),()=>{p.current.delete(Oe),o.current.delete(Oe),s.current.filtered.items.delete(Oe);let Ve=Ce();oe(4,()=>{le(),Ve?.getAttribute("id")===Oe&&ve(),Q.emit()})}),group:Oe=>(d.current.has(Oe)||d.current.set(Oe,new Set),()=>{p.current.delete(Oe),d.current.delete(Oe)}),filter:()=>g.current.shouldFilter,label:b||e["aria-label"],getDisablePointerSelection:()=>g.current.disablePointerSelection,listId:K,inputId:L,labelId:X,listInnerRef:ee}),[]);function de(Oe,ke){var Ve,ie;let De=(ie=(Ve=g.current)==null?void 0:Ve.filter)!=null?ie:pae;return Oe?De(Oe,s.current.search,ke):0}function je(){if(!s.current.search||g.current.shouldFilter===!1)return;let Oe=s.current.filtered.items,ke=[];s.current.filtered.groups.forEach(ie=>{let De=d.current.get(ie),Le=0;De.forEach(tt=>{let yt=Oe.get(tt);Le=Math.max(yt,Le)}),ke.push([ie,Le])});let Ve=ee.current;Ke().sort((ie,De)=>{var Le,tt;let yt=ie.getAttribute("id"),Ot=De.getAttribute("id");return((Le=Oe.get(Ot))!=null?Le:0)-((tt=Oe.get(yt))!=null?tt:0)}).forEach(ie=>{let De=ie.closest(HR);De?De.appendChild(ie.parentElement===De?ie:ie.closest(`${HR} > *`)):Ve.appendChild(ie.parentElement===Ve?ie:ie.closest(`${HR} > *`))}),ke.sort((ie,De)=>De[1]-ie[1]).forEach(ie=>{var De;let Le=(De=ee.current)==null?void 0:De.querySelector(`${ib}[${Zm}="${encodeURIComponent(ie[0])}"]`);Le?.parentElement.appendChild(Le)})}function ve(){let Oe=Ke().find(Ve=>Ve.getAttribute("aria-disabled")!=="true"),ke=Oe?.getAttribute(Zm);Q.setState("value",ke||void 0)}function le(){var Oe,ke,Ve,ie;if(!s.current.search||g.current.shouldFilter===!1){s.current.filtered.count=o.current.size;return}s.current.filtered.groups=new Set;let De=0;for(let Le of o.current){let tt=(ke=(Oe=p.current.get(Le))==null?void 0:Oe.value)!=null?ke:"",yt=(ie=(Ve=p.current.get(Le))==null?void 0:Ve.keywords)!=null?ie:[],Ot=de(tt,yt);s.current.filtered.items.set(Le,Ot),Ot>0&&De++}for(let[Le,tt]of d.current)for(let yt of tt)if(s.current.filtered.items.get(yt)>0){s.current.filtered.groups.add(Le);break}s.current.filtered.count=De}function be(){var Oe,ke,Ve;let ie=Ce();ie&&(((Oe=ie.parentElement)==null?void 0:Oe.firstChild)===ie&&((Ve=(ke=ie.closest(ib))==null?void 0:ke.querySelector(hae))==null||Ve.scrollIntoView({block:"nearest"})),ie.scrollIntoView({block:"nearest"}))}function Ce(){var Oe;return(Oe=ee.current)==null?void 0:Oe.querySelector(`${Uz}[aria-selected="true"]`)}function Ke(){var Oe;return Array.from(((Oe=ee.current)==null?void 0:Oe.querySelectorAll(CI))||[])}function ce(Oe){let ke=Ke()[Oe];ke&&Q.setState("value",ke.getAttribute(Zm))}function re(Oe){var ke;let Ve=Ce(),ie=Ke(),De=ie.findIndex(tt=>tt===Ve),Le=ie[De+Oe];(ke=g.current)!=null&&ke.loop&&(Le=De+Oe<0?ie[ie.length-1]:De+Oe===ie.length?ie[0]:ie[De+Oe]),Le&&Q.setState("value",Le.getAttribute(Zm))}function ue(Oe){let ke=Ce(),Ve=ke?.closest(ib),ie;for(;Ve&&!ie;)Ve=Oe>0?Sae(Ve,ib):Eae(Ve,ib),ie=Ve?.querySelector(CI);ie?Q.setState("value",ie.getAttribute(Zm)):re(Oe)}let _e=()=>ce(Ke().length-1),fe=Oe=>{Oe.preventDefault(),Oe.metaKey?_e():Oe.altKey?ue(1):re(1)},He=Oe=>{Oe.preventDefault(),Oe.metaKey?ce(0):Oe.altKey?ue(-1):re(-1)};return R.createElement(Gd.div,{ref:r,tabIndex:-1,...G,"cmdk-root":"",onKeyDown:Oe=>{var ke;(ke=G.onKeyDown)==null||ke.call(G,Oe);let Ve=Oe.nativeEvent.isComposing||Oe.keyCode===229;if(!(Oe.defaultPrevented||Ve))switch(Oe.key){case"n":case"j":{q&&Oe.ctrlKey&&fe(Oe);break}case"ArrowDown":{fe(Oe);break}case"p":case"k":{q&&Oe.ctrlKey&&He(Oe);break}case"ArrowUp":{He(Oe);break}case"Home":{Oe.preventDefault(),ce(0);break}case"End":{Oe.preventDefault(),_e();break}case"Enter":{Oe.preventDefault();let ie=Ce();if(ie){let De=new Event(BT);ie.dispatchEvent(De)}}}}},R.createElement("label",{"cmdk-label":"",htmlFor:ne.inputId,id:ne.labelId,style:Aae},b),DC(e,Oe=>R.createElement(Vz.Provider,{value:Q},R.createElement(Kz.Provider,{value:ne},Oe))))}),fae=R.forwardRef((e,r)=>{var s,o;let d=Vs(),p=R.useRef(null),m=R.useContext(Hz),g=lw(),b=Xz(e),S=(o=(s=b.current)==null?void 0:s.forceMount)!=null?o:m?.forceMount;Rp(()=>{if(!S)return g.item(d,m?.id)},[S]);let j=Yz(d,p,[e.value,e.children,p],e.keywords),A=o2(),k=Bd(oe=>oe.value&&oe.value===j.current),T=Bd(oe=>S||g.filter()===!1?!0:oe.search?oe.filtered.items.get(d)>0:!0);R.useEffect(()=>{let oe=p.current;if(!(!oe||e.disabled))return oe.addEventListener(BT,M),()=>oe.removeEventListener(BT,M)},[T,e.onSelect,e.disabled]);function M(){var oe,Q;I(),(Q=(oe=b.current).onSelect)==null||Q.call(oe,j.current)}function I(){A.setState("value",j.current,!0)}if(!T)return null;let{disabled:q,value:G,onSelect:K,forceMount:X,keywords:L,...ee}=e;return R.createElement(Gd.div,{ref:Li(p,r),...ee,id:d,"cmdk-item":"",role:"option","aria-disabled":!!q,"aria-selected":!!k,"data-disabled":!!q,"data-selected":!!k,onPointerMove:q||g.getDisablePointerSelection()?void 0:I,onClick:q?void 0:M},e.children)}),mae=R.forwardRef((e,r)=>{let{heading:s,children:o,forceMount:d,...p}=e,m=Vs(),g=R.useRef(null),b=R.useRef(null),S=Vs(),j=lw(),A=Bd(T=>d||j.filter()===!1?!0:T.search?T.filtered.groups.has(m):!0);Rp(()=>j.group(m),[]),Yz(m,g,[e.value,e.heading,b]);let k=R.useMemo(()=>({id:m,forceMount:d}),[d]);return R.createElement(Gd.div,{ref:Li(g,r),...p,"cmdk-group":"",role:"presentation",hidden:A?void 0:!0},s&&R.createElement("div",{ref:b,"cmdk-group-heading":"","aria-hidden":!0,id:S},s),DC(e,T=>R.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":s?S:void 0},R.createElement(Hz.Provider,{value:k},T))))}),gae=R.forwardRef((e,r)=>{let{alwaysRender:s,...o}=e,d=R.useRef(null),p=Bd(m=>!m.search);return!s&&!p?null:R.createElement(Gd.div,{ref:Li(d,r),...o,"cmdk-separator":"",role:"separator"})}),yae=R.forwardRef((e,r)=>{let{onValueChange:s,...o}=e,d=e.value!=null,p=o2(),m=Bd(S=>S.search),g=Bd(S=>S.selectedItemId),b=lw();return R.useEffect(()=>{e.value!=null&&p.setState("search",e.value)},[e.value]),R.createElement(Gd.input,{ref:r,...o,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":b.listId,"aria-labelledby":b.labelId,"aria-activedescendant":g,id:b.inputId,type:"text",value:d?e.value:m,onChange:S=>{d||p.setState("search",S.target.value),s?.(S.target.value)}})}),vae=R.forwardRef((e,r)=>{let{children:s,label:o="Suggestions",...d}=e,p=R.useRef(null),m=R.useRef(null),g=Bd(S=>S.selectedItemId),b=lw();return R.useEffect(()=>{if(m.current&&p.current){let S=m.current,j=p.current,A,k=new ResizeObserver(()=>{A=requestAnimationFrame(()=>{let T=S.offsetHeight;j.style.setProperty("--cmdk-list-height",T.toFixed(1)+"px")})});return k.observe(S),()=>{cancelAnimationFrame(A),k.unobserve(S)}}},[]),R.createElement(Gd.div,{ref:Li(p,r),...d,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":g,"aria-label":o,id:b.listId},DC(e,S=>R.createElement("div",{ref:Li(m,b.listInnerRef),"cmdk-list-sizer":""},S)))}),xae=R.forwardRef((e,r)=>{let{open:s,onOpenChange:o,overlayClassName:d,contentClassName:p,container:m,...g}=e;return R.createElement(TC,{open:s,onOpenChange:o},R.createElement(_C,{container:m},R.createElement($C,{"cmdk-overlay":"",className:d}),R.createElement(NC,{"aria-label":e.label,"cmdk-dialog":"",className:p},R.createElement(Gz,{ref:r,...g}))))}),bae=R.forwardRef((e,r)=>Bd(s=>s.filtered.count===0)?R.createElement(Gd.div,{ref:r,...e,"cmdk-empty":"",role:"presentation"}):null),wae=R.forwardRef((e,r)=>{let{progress:s,children:o,label:d="Loading...",...p}=e;return R.createElement(Gd.div,{ref:r,...p,"cmdk-loading":"",role:"progressbar","aria-valuenow":s,"aria-valuemin":0,"aria-valuemax":100,"aria-label":d},DC(e,m=>R.createElement("div",{"aria-hidden":!0},m)))}),$g=Object.assign(Gz,{List:vae,Item:fae,Input:yae,Group:mae,Separator:gae,Dialog:xae,Empty:bae,Loading:wae});function Sae(e,r){let s=e.nextElementSibling;for(;s;){if(s.matches(r))return s;s=s.nextElementSibling}}function Eae(e,r){let s=e.previousElementSibling;for(;s;){if(s.matches(r))return s;s=s.previousElementSibling}}function Xz(e){let r=R.useRef(e);return Rp(()=>{r.current=e}),r}var Rp=typeof window>"u"?R.useEffect:R.useLayoutEffect;function Wm(e){let r=R.useRef();return r.current===void 0&&(r.current=e()),r}function Bd(e){let r=o2(),s=()=>e(r.snapshot());return R.useSyncExternalStore(r.subscribe,s,s)}function Yz(e,r,s,o=[]){let d=R.useRef(),p=lw();return Rp(()=>{var m;let g=(()=>{var S;for(let j of s){if(typeof j=="string")return j.trim();if(typeof j=="object"&&"current"in j)return j.current?(S=j.current.textContent)==null?void 0:S.trim():d.current}})(),b=o.map(S=>S.trim());p.value(e,g,b),(m=r.current)==null||m.setAttribute(Zm,g),d.current=g}),d}var jae=()=>{let[e,r]=R.useState(),s=Wm(()=>new Map);return Rp(()=>{s.current.forEach(o=>o()),s.current=new Map},[e]),(o,d)=>{s.current.set(o,d),r({})}};function Cae(e){let r=e.type;return typeof r=="function"?r(e.props):"render"in r?r.render(e.props):e}function DC({asChild:e,children:r},s){return e&&R.isValidElement(r)?R.cloneElement(Cae(r),{ref:r.ref},s(r.props.children)):s(r)}var Aae={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};function fn({...e}){return u.jsx(TC,{"data-slot":"dialog",...e})}function zi({...e}){return u.jsx(Bz,{"data-slot":"dialog-trigger",...e})}function Oae({...e}){return u.jsx(_C,{"data-slot":"dialog-portal",...e})}function Bj({...e}){return u.jsx(ow,{"data-slot":"dialog-close",...e})}function kae({className:e,...r}){return u.jsx($C,{"data-slot":"dialog-overlay",className:ft("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",e),...r})}function mn({className:e,children:r,showCloseButton:s=!0,...o}){return u.jsxs(Oae,{"data-slot":"dialog-portal",children:[u.jsx(kae,{}),u.jsxs(NC,{"data-slot":"dialog-content",className:ft("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",e),...o,children:[r,s&&u.jsxs(ow,{"data-slot":"dialog-close",className:"ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",children:[u.jsx(q_,{}),u.jsx("span",{className:"sr-only",children:"Close"})]})]})]})}function gn({className:e,...r}){return u.jsx("div",{"data-slot":"dialog-header",className:ft("flex flex-col gap-2 text-center sm:text-left",e),...r})}function Sn({className:e,...r}){return u.jsx("div",{"data-slot":"dialog-footer",className:ft("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",e),...r})}function yn({className:e,...r}){return u.jsx(i2,{"data-slot":"dialog-title",className:ft("text-lg leading-none font-semibold",e),...r})}function GR({className:e,...r}){return u.jsx(a2,{"data-slot":"dialog-description",className:ft("text-muted-foreground text-sm",e),...r})}function Rae({className:e,...r}){return u.jsx($g,{"data-slot":"command",className:ft("bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md",e),...r})}function Tae({className:e,...r}){return u.jsxs("div",{"data-slot":"command-input-wrapper",className:"flex h-9 items-center gap-2 border-b px-3",children:[u.jsx(Pa,{className:"size-4 shrink-0 opacity-50"}),u.jsx($g.Input,{"data-slot":"command-input",className:ft("placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",e),...r})]})}function _ae({className:e,...r}){return u.jsx($g.List,{"data-slot":"command-list",className:ft("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",e),...r})}function $ae({...e}){return u.jsx($g.Empty,{"data-slot":"command-empty",className:"py-6 text-center text-sm",...e})}function Nae({className:e,...r}){return u.jsx($g.Group,{"data-slot":"command-group",className:ft("text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium",e),...r})}function Dae({className:e,...r}){return u.jsx($g.Item,{"data-slot":"command-item",className:ft("data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...r})}function Pae(e){const r=Mae(e),s=R.forwardRef((o,d)=>{const{children:p,...m}=o,g=R.Children.toArray(p),b=g.find(Lae);if(b){const S=b.props.children,j=g.map(A=>A===b?R.Children.count(S)>1?R.Children.only(null):R.isValidElement(S)?S.props.children:null:A);return u.jsx(r,{...m,ref:d,children:R.isValidElement(S)?R.cloneElement(S,void 0,j):null})}return u.jsx(r,{...m,ref:d,children:p})});return s.displayName=`${e}.Slot`,s}function Mae(e){const r=R.forwardRef((s,o)=>{const{children:d,...p}=s;if(R.isValidElement(d)){const m=Fae(d),g=zae(p,d.props);return d.type!==R.Fragment&&(g.ref=o?Li(o,m):m),R.cloneElement(d,g)}return R.Children.count(d)>1?R.Children.only(null):null});return r.displayName=`${e}.SlotClone`,r}var Iae=Symbol("radix.slottable");function Lae(e){return R.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Iae}function zae(e,r){const s={...r};for(const o in r){const d=e[o],p=r[o];/^on[A-Z]/.test(o)?d&&p?s[o]=(...g)=>{const b=p(...g);return d(...g),b}:d&&(s[o]=d):o==="style"?s[o]={...d,...p}:o==="className"&&(s[o]=[d,p].filter(Boolean).join(" "))}return{...e,...s}}function Fae(e){let r=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning;return s?e.ref:(r=Object.getOwnPropertyDescriptor(e,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning,s?e.props.ref:e.props.ref||e.ref)}var PC="Popover",[Zz]=al(PC,[Hd]),cw=Hd(),[qae,Xd]=Zz(PC),Wz=e=>{const{__scopePopover:r,children:s,open:o,defaultOpen:d,onOpenChange:p,modal:m=!1}=e,g=cw(r),b=R.useRef(null),[S,j]=R.useState(!1),[A,k]=qd({prop:o,defaultProp:d??!1,onChange:p,caller:PC});return u.jsx(wC,{...g,children:u.jsx(qae,{scope:r,contentId:Vs(),triggerRef:b,open:A,onOpenChange:k,onOpenToggle:R.useCallback(()=>k(T=>!T),[k]),hasCustomAnchor:S,onCustomAnchorAdd:R.useCallback(()=>j(!0),[]),onCustomAnchorRemove:R.useCallback(()=>j(!1),[]),modal:m,children:s})})};Wz.displayName=PC;var Jz="PopoverAnchor",Bae=R.forwardRef((e,r)=>{const{__scopePopover:s,...o}=e,d=Xd(Jz,s),p=cw(s),{onCustomAnchorAdd:m,onCustomAnchorRemove:g}=d;return R.useEffect(()=>(m(),()=>g()),[m,g]),u.jsx(tw,{...p,...o,ref:r})});Bae.displayName=Jz;var Qz="PopoverTrigger",e5=R.forwardRef((e,r)=>{const{__scopePopover:s,...o}=e,d=Xd(Qz,s),p=cw(s),m=zn(r,d.triggerRef),g=u.jsx(Cn.button,{type:"button","aria-haspopup":"dialog","aria-expanded":d.open,"aria-controls":d.contentId,"data-state":i5(d.open),...o,ref:m,onClick:$t(e.onClick,d.onOpenToggle)});return d.hasCustomAnchor?g:u.jsx(tw,{asChild:!0,...p,children:g})});e5.displayName=Qz;var l2="PopoverPortal",[Uae,Kae]=Zz(l2,{forceMount:void 0}),t5=e=>{const{__scopePopover:r,forceMount:s,children:o,container:d}=e,p=Xd(l2,r);return u.jsx(Uae,{scope:r,forceMount:s,children:u.jsx(lo,{present:s||p.open,children:u.jsx(_g,{asChild:!0,container:d,children:o})})})};t5.displayName=l2;var bg="PopoverContent",n5=R.forwardRef((e,r)=>{const s=Kae(bg,e.__scopePopover),{forceMount:o=s.forceMount,...d}=e,p=Xd(bg,e.__scopePopover);return u.jsx(lo,{present:o||p.open,children:p.modal?u.jsx(Hae,{...d,ref:r}):u.jsx(Gae,{...d,ref:r})})});n5.displayName=bg;var Vae=Pae("PopoverContent.RemoveScroll"),Hae=R.forwardRef((e,r)=>{const s=Xd(bg,e.__scopePopover),o=R.useRef(null),d=zn(r,o),p=R.useRef(!1);return R.useEffect(()=>{const m=o.current;if(m)return kC(m)},[]),u.jsx(aw,{as:Vae,allowPinchZoom:!0,children:u.jsx(r5,{...e,ref:d,trapFocus:s.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:$t(e.onCloseAutoFocus,m=>{m.preventDefault(),p.current||s.triggerRef.current?.focus()}),onPointerDownOutside:$t(e.onPointerDownOutside,m=>{const g=m.detail.originalEvent,b=g.button===0&&g.ctrlKey===!0,S=g.button===2||b;p.current=S},{checkForDefaultPrevented:!1}),onFocusOutside:$t(e.onFocusOutside,m=>m.preventDefault(),{checkForDefaultPrevented:!1})})})}),Gae=R.forwardRef((e,r)=>{const s=Xd(bg,e.__scopePopover),o=R.useRef(!1),d=R.useRef(!1);return u.jsx(r5,{...e,ref:r,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:p=>{e.onCloseAutoFocus?.(p),p.defaultPrevented||(o.current||s.triggerRef.current?.focus(),p.preventDefault()),o.current=!1,d.current=!1},onInteractOutside:p=>{e.onInteractOutside?.(p),p.defaultPrevented||(o.current=!0,p.detail.originalEvent.type==="pointerdown"&&(d.current=!0));const m=p.target;s.triggerRef.current?.contains(m)&&p.preventDefault(),p.detail.originalEvent.type==="focusin"&&d.current&&p.preventDefault()}})}),r5=R.forwardRef((e,r)=>{const{__scopePopover:s,trapFocus:o,onOpenAutoFocus:d,onCloseAutoFocus:p,disableOutsidePointerEvents:m,onEscapeKeyDown:g,onPointerDownOutside:b,onFocusOutside:S,onInteractOutside:j,...A}=e,k=Xd(bg,s),T=cw(s);return AC(),u.jsx(iw,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:d,onUnmountAutoFocus:p,children:u.jsx(kg,{asChild:!0,disableOutsidePointerEvents:m,onInteractOutside:j,onEscapeKeyDown:g,onPointerDownOutside:b,onFocusOutside:S,onDismiss:()=>k.onOpenChange(!1),children:u.jsx(SC,{"data-state":i5(k.open),role:"dialog",id:k.contentId,...T,...A,ref:r,style:{...A.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),s5="PopoverClose",Xae=R.forwardRef((e,r)=>{const{__scopePopover:s,...o}=e,d=Xd(s5,s);return u.jsx(Cn.button,{type:"button",...o,ref:r,onClick:$t(e.onClick,()=>d.onOpenChange(!1))})});Xae.displayName=s5;var Yae="PopoverArrow",Zae=R.forwardRef((e,r)=>{const{__scopePopover:s,...o}=e,d=cw(s);return u.jsx(EC,{...d,...o,ref:r})});Zae.displayName=Yae;function i5(e){return e?"open":"closed"}var Wae=Wz,Jae=e5,Qae=t5,eoe=n5;function toe({...e}){return u.jsx(Wae,{"data-slot":"popover",...e})}function noe({...e}){return u.jsx(Jae,{"data-slot":"popover-trigger",...e})}function roe({className:e,align:r="center",sideOffset:s=4,...o}){return u.jsx(Qae,{children:u.jsx(eoe,{"data-slot":"popover-content",align:r,sideOffset:s,className:ft("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",e),...o})})}const soe=({orgs:e})=>{const[r,s]=R.useState(!1),[o,d]=R.useState(Qo.get()??"");R.useEffect(()=>Qo.subscribe(m=>d(m??"")),[]);const p=e.find(m=>m.id===o);return u.jsxs(toe,{open:r,onOpenChange:s,children:[u.jsx(noe,{asChild:!0,children:u.jsxs(Fe,{variant:"ghost",className:"h-9 w-full justify-between px-2","aria-label":"Switch organization",children:[u.jsxs("span",{className:"flex items-center gap-2 truncate",children:[u.jsx(sL,{className:"h-4 w-4"}),u.jsx("span",{className:"truncate",children:p?.name??"Select org"})]}),u.jsx(AZ,{className:"ml-2 h-4 w-4 opacity-50"})]})}),u.jsx(roe,{className:"w-[280px] p-0",align:"start",children:u.jsxs(Rae,{children:[u.jsx(Tae,{placeholder:"Search orgs..."}),u.jsxs(_ae,{children:[u.jsx($ae,{children:"No orgs found."}),u.jsx(Nae,{heading:"Organizations",children:e.map(m=>u.jsxs(Dae,{value:m.id,onSelect:g=>{Qo.set(g),s(!1)},children:[u.jsx(iL,{className:ft("mr-2 h-4 w-4",o===m.id?"opacity-100":"opacity-0")}),u.jsx("span",{className:"truncate",children:m.name})]},m.id))})]})]})})]})},a5=R.createContext({});function ioe(e){const r=R.useRef(null);return r.current===null&&(r.current=e()),r.current}const c2=typeof window<"u",aoe=c2?R.useLayoutEffect:R.useEffect,u2=R.createContext(null);function d2(e,r){e.indexOf(r)===-1&&e.push(r)}function h2(e,r){const s=e.indexOf(r);s>-1&&e.splice(s,1)}const gu=(e,r,s)=>s>r?r:s{};const yu={},o5=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function l5(e){return typeof e=="object"&&e!==null}const c5=e=>/^0[^.\s]+$/u.test(e);function f2(e){let r;return()=>(r===void 0&&(r=e()),r)}const so=e=>e,ooe=(e,r)=>s=>r(e(s)),uw=(...e)=>e.reduce(ooe),qb=(e,r,s)=>{const o=r-e;return o===0?1:(s-e)/o};class m2{constructor(){this.subscriptions=[]}add(r){return d2(this.subscriptions,r),()=>h2(this.subscriptions,r)}notify(r,s,o){const d=this.subscriptions.length;if(d)if(d===1)this.subscriptions[0](r,s,o);else for(let p=0;pe*1e3,ro=e=>e/1e3;function u5(e,r){return r?e*(1e3/r):0}const d5=(e,r,s)=>(((1-3*s+3*r)*e+(3*s-6*r))*e+3*r)*e,loe=1e-7,coe=12;function uoe(e,r,s,o,d){let p,m,g=0;do m=r+(s-r)/2,p=d5(m,o,d)-e,p>0?s=m:r=m;while(Math.abs(p)>loe&&++guoe(p,0,1,e,s);return p=>p===0||p===1?p:d5(d(p),r,o)}const h5=e=>r=>r<=.5?e(2*r)/2:(2-e(2*(1-r)))/2,p5=e=>r=>1-e(1-r),f5=dw(.33,1.53,.69,.99),g2=p5(f5),m5=h5(g2),g5=e=>(e*=2)<1?.5*g2(e):.5*(2-Math.pow(2,-10*(e-1))),y2=e=>1-Math.sin(Math.acos(e)),y5=p5(y2),v5=h5(y2),doe=dw(.42,0,1,1),hoe=dw(0,0,.58,1),x5=dw(.42,0,.58,1),poe=e=>Array.isArray(e)&&typeof e[0]!="number",b5=e=>Array.isArray(e)&&typeof e[0]=="number",foe={linear:so,easeIn:doe,easeInOut:x5,easeOut:hoe,circIn:y2,circInOut:v5,circOut:y5,backIn:g2,backInOut:m5,backOut:f5,anticipate:g5},moe=e=>typeof e=="string",AI=e=>{if(b5(e)){p2(e.length===4);const[r,s,o,d]=e;return dw(r,s,o,d)}else if(moe(e))return foe[e];return e},WE=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function goe(e,r){let s=new Set,o=new Set,d=!1,p=!1;const m=new WeakSet;let g={delta:0,timestamp:0,isProcessing:!1};function b(j){m.has(j)&&(S.schedule(j),e()),j(g)}const S={schedule:(j,A=!1,k=!1)=>{const M=k&&d?s:o;return A&&m.add(j),M.has(j)||M.add(j),j},cancel:j=>{o.delete(j),m.delete(j)},process:j=>{if(g=j,d){p=!0;return}d=!0,[s,o]=[o,s],s.forEach(b),s.clear(),d=!1,p&&(p=!1,S.process(j))}};return S}const yoe=40;function w5(e,r){let s=!1,o=!0;const d={delta:0,timestamp:0,isProcessing:!1},p=()=>s=!0,m=WE.reduce((X,L)=>(X[L]=goe(p),X),{}),{setup:g,read:b,resolveKeyframes:S,preUpdate:j,update:A,preRender:k,render:T,postRender:M}=m,I=()=>{const X=yu.useManualTiming?d.timestamp:performance.now();s=!1,yu.useManualTiming||(d.delta=o?1e3/60:Math.max(Math.min(X-d.timestamp,yoe),1)),d.timestamp=X,d.isProcessing=!0,g.process(d),b.process(d),S.process(d),j.process(d),A.process(d),k.process(d),T.process(d),M.process(d),d.isProcessing=!1,s&&r&&(o=!1,e(I))},q=()=>{s=!0,o=!0,d.isProcessing||e(I)};return{schedule:WE.reduce((X,L)=>{const ee=m[L];return X[L]=(oe,Q=!1,ne=!1)=>(s||q(),ee.schedule(oe,Q,ne)),X},{}),cancel:X=>{for(let L=0;L(vj===void 0&&da.set(Us.isProcessing||yu.useManualTiming?Us.timestamp:performance.now()),vj),set:e=>{vj=e,queueMicrotask(voe)}},S5=e=>r=>typeof r=="string"&&r.startsWith(e),E5=S5("--"),xoe=S5("var(--"),v2=e=>xoe(e)?boe.test(e.split("/*")[0].trim()):!1,boe=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Ng={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Bb={...Ng,transform:e=>gu(0,1,e)},JE={...Ng,default:1},Tb=e=>Math.round(e*1e5)/1e5,x2=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function woe(e){return e==null}const Soe=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,b2=(e,r)=>s=>!!(typeof s=="string"&&Soe.test(s)&&s.startsWith(e)||r&&!woe(s)&&Object.prototype.hasOwnProperty.call(s,r)),j5=(e,r,s)=>o=>{if(typeof o!="string")return o;const[d,p,m,g]=o.match(x2);return{[e]:parseFloat(d),[r]:parseFloat(p),[s]:parseFloat(m),alpha:g!==void 0?parseFloat(g):1}},Eoe=e=>gu(0,255,e),YR={...Ng,transform:e=>Math.round(Eoe(e))},xp={test:b2("rgb","red"),parse:j5("red","green","blue"),transform:({red:e,green:r,blue:s,alpha:o=1})=>"rgba("+YR.transform(e)+", "+YR.transform(r)+", "+YR.transform(s)+", "+Tb(Bb.transform(o))+")"};function joe(e){let r="",s="",o="",d="";return e.length>5?(r=e.substring(1,3),s=e.substring(3,5),o=e.substring(5,7),d=e.substring(7,9)):(r=e.substring(1,2),s=e.substring(2,3),o=e.substring(3,4),d=e.substring(4,5),r+=r,s+=s,o+=o,d+=d),{red:parseInt(r,16),green:parseInt(s,16),blue:parseInt(o,16),alpha:d?parseInt(d,16)/255:1}}const UT={test:b2("#"),parse:joe,transform:xp.transform},hw=e=>({test:r=>typeof r=="string"&&r.endsWith(e)&&r.split(" ").length===1,parse:parseFloat,transform:r=>`${r}${e}`}),Md=hw("deg"),ac=hw("%"),tn=hw("px"),Coe=hw("vh"),Aoe=hw("vw"),OI={...ac,parse:e=>ac.parse(e)/100,transform:e=>ac.transform(e*100)},ig={test:b2("hsl","hue"),parse:j5("hue","saturation","lightness"),transform:({hue:e,saturation:r,lightness:s,alpha:o=1})=>"hsla("+Math.round(e)+", "+ac.transform(Tb(r))+", "+ac.transform(Tb(s))+", "+Tb(Bb.transform(o))+")"},fs={test:e=>xp.test(e)||UT.test(e)||ig.test(e),parse:e=>xp.test(e)?xp.parse(e):ig.test(e)?ig.parse(e):UT.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?xp.transform(e):ig.transform(e),getAnimatableNone:e=>{const r=fs.parse(e);return r.alpha=0,fs.transform(r)}},Ooe=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function koe(e){return isNaN(e)&&typeof e=="string"&&(e.match(x2)?.length||0)+(e.match(Ooe)?.length||0)>0}const C5="number",A5="color",Roe="var",Toe="var(",kI="${}",_oe=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Ub(e){const r=e.toString(),s=[],o={color:[],number:[],var:[]},d=[];let p=0;const g=r.replace(_oe,b=>(fs.test(b)?(o.color.push(p),d.push(A5),s.push(fs.parse(b))):b.startsWith(Toe)?(o.var.push(p),d.push(Roe),s.push(b)):(o.number.push(p),d.push(C5),s.push(parseFloat(b))),++p,kI)).split(kI);return{values:s,split:g,indexes:o,types:d}}function O5(e){return Ub(e).values}function k5(e){const{split:r,types:s}=Ub(e),o=r.length;return d=>{let p="";for(let m=0;mtypeof e=="number"?0:fs.test(e)?fs.getAnimatableNone(e):e;function Noe(e){const r=O5(e);return k5(e)(r.map($oe))}const Kd={test:koe,parse:O5,createTransformer:k5,getAnimatableNone:Noe};function ZR(e,r,s){return s<0&&(s+=1),s>1&&(s-=1),s<1/6?e+(r-e)*6*s:s<1/2?r:s<2/3?e+(r-e)*(2/3-s)*6:e}function Doe({hue:e,saturation:r,lightness:s,alpha:o}){e/=360,r/=100,s/=100;let d=0,p=0,m=0;if(!r)d=p=m=s;else{const g=s<.5?s*(1+r):s+r-s*r,b=2*s-g;d=ZR(b,g,e+1/3),p=ZR(b,g,e),m=ZR(b,g,e-1/3)}return{red:Math.round(d*255),green:Math.round(p*255),blue:Math.round(m*255),alpha:o}}function Uj(e,r){return s=>s>0?r:e}const Lr=(e,r,s)=>e+(r-e)*s,WR=(e,r,s)=>{const o=e*e,d=s*(r*r-o)+o;return d<0?0:Math.sqrt(d)},Poe=[UT,xp,ig],Moe=e=>Poe.find(r=>r.test(e));function RI(e){const r=Moe(e);if(!r)return!1;let s=r.parse(e);return r===ig&&(s=Doe(s)),s}const TI=(e,r)=>{const s=RI(e),o=RI(r);if(!s||!o)return Uj(e,r);const d={...s};return p=>(d.red=WR(s.red,o.red,p),d.green=WR(s.green,o.green,p),d.blue=WR(s.blue,o.blue,p),d.alpha=Lr(s.alpha,o.alpha,p),xp.transform(d))},KT=new Set(["none","hidden"]);function Ioe(e,r){return KT.has(e)?s=>s<=0?e:r:s=>s>=1?r:e}function Loe(e,r){return s=>Lr(e,r,s)}function w2(e){return typeof e=="number"?Loe:typeof e=="string"?v2(e)?Uj:fs.test(e)?TI:qoe:Array.isArray(e)?R5:typeof e=="object"?fs.test(e)?TI:zoe:Uj}function R5(e,r){const s=[...e],o=s.length,d=e.map((p,m)=>w2(p)(p,r[m]));return p=>{for(let m=0;m{for(const p in o)s[p]=o[p](d);return s}}function Foe(e,r){const s=[],o={color:0,var:0,number:0};for(let d=0;d{const s=Kd.createTransformer(r),o=Ub(e),d=Ub(r);return o.indexes.var.length===d.indexes.var.length&&o.indexes.color.length===d.indexes.color.length&&o.indexes.number.length>=d.indexes.number.length?KT.has(e)&&!d.values.length||KT.has(r)&&!o.values.length?Ioe(e,r):uw(R5(Foe(o,d),d.values),s):Uj(e,r)};function T5(e,r,s){return typeof e=="number"&&typeof r=="number"&&typeof s=="number"?Lr(e,r,s):w2(e)(e,r)}const Boe=e=>{const r=({timestamp:s})=>e(s);return{start:(s=!0)=>_r.update(r,s),stop:()=>Ud(r),now:()=>Us.isProcessing?Us.timestamp:da.now()}},_5=(e,r,s=10)=>{let o="";const d=Math.max(Math.round(r/s),2);for(let p=0;p=Kj?1/0:r}function Uoe(e,r=100,s){const o=s({...e,keyframes:[0,r]}),d=Math.min(S2(o),Kj);return{type:"keyframes",ease:p=>o.next(d*p).value/r,duration:ro(d)}}const Koe=5;function $5(e,r,s){const o=Math.max(r-Koe,0);return u5(s-e(o),r-o)}const Vr={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},JR=.001;function Voe({duration:e=Vr.duration,bounce:r=Vr.bounce,velocity:s=Vr.velocity,mass:o=Vr.mass}){let d,p,m=1-r;m=gu(Vr.minDamping,Vr.maxDamping,m),e=gu(Vr.minDuration,Vr.maxDuration,ro(e)),m<1?(d=S=>{const j=S*m,A=j*e,k=j-s,T=VT(S,m),M=Math.exp(-A);return JR-k/T*M},p=S=>{const A=S*m*e,k=A*s+s,T=Math.pow(m,2)*Math.pow(S,2)*e,M=Math.exp(-A),I=VT(Math.pow(S,2),m);return(-d(S)+JR>0?-1:1)*((k-T)*M)/I}):(d=S=>{const j=Math.exp(-S*e),A=(S-s)*e+1;return-JR+j*A},p=S=>{const j=Math.exp(-S*e),A=(s-S)*(e*e);return j*A});const g=5/e,b=Goe(d,p,g);if(e=ic(e),isNaN(b))return{stiffness:Vr.stiffness,damping:Vr.damping,duration:e};{const S=Math.pow(b,2)*o;return{stiffness:S,damping:m*2*Math.sqrt(o*S),duration:e}}}const Hoe=12;function Goe(e,r,s){let o=s;for(let d=1;de[s]!==void 0)}function Zoe(e){let r={velocity:Vr.velocity,stiffness:Vr.stiffness,damping:Vr.damping,mass:Vr.mass,isResolvedFromDuration:!1,...e};if(!_I(e,Yoe)&&_I(e,Xoe))if(e.visualDuration){const s=e.visualDuration,o=2*Math.PI/(s*1.2),d=o*o,p=2*gu(.05,1,1-(e.bounce||0))*Math.sqrt(d);r={...r,mass:Vr.mass,stiffness:d,damping:p}}else{const s=Voe(e);r={...r,...s,mass:Vr.mass},r.isResolvedFromDuration=!0}return r}function Vj(e=Vr.visualDuration,r=Vr.bounce){const s=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:r}:e;let{restSpeed:o,restDelta:d}=s;const p=s.keyframes[0],m=s.keyframes[s.keyframes.length-1],g={done:!1,value:p},{stiffness:b,damping:S,mass:j,duration:A,velocity:k,isResolvedFromDuration:T}=Zoe({...s,velocity:-ro(s.velocity||0)}),M=k||0,I=S/(2*Math.sqrt(b*j)),q=m-p,G=ro(Math.sqrt(b/j)),K=Math.abs(q)<5;o||(o=K?Vr.restSpeed.granular:Vr.restSpeed.default),d||(d=K?Vr.restDelta.granular:Vr.restDelta.default);let X;if(I<1){const ee=VT(G,I);X=oe=>{const Q=Math.exp(-I*G*oe);return m-Q*((M+I*G*q)/ee*Math.sin(ee*oe)+q*Math.cos(ee*oe))}}else if(I===1)X=ee=>m-Math.exp(-G*ee)*(q+(M+G*q)*ee);else{const ee=G*Math.sqrt(I*I-1);X=oe=>{const Q=Math.exp(-I*G*oe),ne=Math.min(ee*oe,300);return m-Q*((M+I*G*q)*Math.sinh(ne)+ee*q*Math.cosh(ne))/ee}}const L={calculatedDuration:T&&A||null,next:ee=>{const oe=X(ee);if(T)g.done=ee>=A;else{let Q=ee===0?M:0;I<1&&(Q=ee===0?ic(M):$5(X,ee,oe));const ne=Math.abs(Q)<=o,de=Math.abs(m-oe)<=d;g.done=ne&&de}return g.value=g.done?m:oe,g},toString:()=>{const ee=Math.min(S2(L),Kj),oe=_5(Q=>L.next(ee*Q).value,ee,30);return ee+"ms "+oe},toTransition:()=>{}};return L}Vj.applyToOptions=e=>{const r=Uoe(e,100,Vj);return e.ease=r.ease,e.duration=ic(r.duration),e.type="keyframes",e};function HT({keyframes:e,velocity:r=0,power:s=.8,timeConstant:o=325,bounceDamping:d=10,bounceStiffness:p=500,modifyTarget:m,min:g,max:b,restDelta:S=.5,restSpeed:j}){const A=e[0],k={done:!1,value:A},T=ne=>g!==void 0&&neb,M=ne=>g===void 0?b:b===void 0||Math.abs(g-ne)-I*Math.exp(-ne/o),X=ne=>G+K(ne),L=ne=>{const de=K(ne),je=X(ne);k.done=Math.abs(de)<=S,k.value=k.done?G:je};let ee,oe;const Q=ne=>{T(k.value)&&(ee=ne,oe=Vj({keyframes:[k.value,M(k.value)],velocity:$5(X,ne,k.value),damping:d,stiffness:p,restDelta:S,restSpeed:j}))};return Q(0),{calculatedDuration:null,next:ne=>{let de=!1;return!oe&&ee===void 0&&(de=!0,L(ne),Q(ne)),ee!==void 0&&ne>=ee?oe.next(ne-ee):(!de&&L(ne),k)}}}function Woe(e,r,s){const o=[],d=s||yu.mix||T5,p=e.length-1;for(let m=0;mr[0];if(p===2&&r[0]===r[1])return()=>r[1];const m=e[0]===e[1];e[0]>e[p-1]&&(e=[...e].reverse(),r=[...r].reverse());const g=Woe(r,o,d),b=g.length,S=j=>{if(m&&j1)for(;AS(gu(e[0],e[p-1],j)):S}function Qoe(e,r){const s=e[e.length-1];for(let o=1;o<=r;o++){const d=qb(0,r,o);e.push(Lr(s,1,d))}}function ele(e){const r=[0];return Qoe(r,e.length-1),r}function tle(e,r){return e.map(s=>s*r)}function nle(e,r){return e.map(()=>r||x5).splice(0,e.length-1)}function _b({duration:e=300,keyframes:r,times:s,ease:o="easeInOut"}){const d=poe(o)?o.map(AI):AI(o),p={done:!1,value:r[0]},m=tle(s&&s.length===r.length?s:ele(r),e),g=Joe(m,r,{ease:Array.isArray(d)?d:nle(r,d)});return{calculatedDuration:e,next:b=>(p.value=g(b),p.done=b>=e,p)}}const rle=e=>e!==null;function E2(e,{repeat:r,repeatType:s="loop"},o,d=1){const p=e.filter(rle),g=d<0||r&&s!=="loop"&&r%2===1?0:p.length-1;return!g||o===void 0?p[g]:o}const sle={decay:HT,inertia:HT,tween:_b,keyframes:_b,spring:Vj};function N5(e){typeof e.type=="string"&&(e.type=sle[e.type])}class j2{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(r=>{this.resolve=r})}notifyFinished(){this.resolve()}then(r,s){return this.finished.then(r,s)}}const ile=e=>e/100;class C2 extends j2{constructor(r){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{const{motionValue:s}=this.options;s&&s.updatedAt!==da.now()&&this.tick(da.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=r,this.initAnimation(),this.play(),r.autoplay===!1&&this.pause()}initAnimation(){const{options:r}=this;N5(r);const{type:s=_b,repeat:o=0,repeatDelay:d=0,repeatType:p,velocity:m=0}=r;let{keyframes:g}=r;const b=s||_b;b!==_b&&typeof g[0]!="number"&&(this.mixKeyframes=uw(ile,T5(g[0],g[1])),g=[0,100]);const S=b({...r,keyframes:g});p==="mirror"&&(this.mirroredGenerator=b({...r,keyframes:[...g].reverse(),velocity:-m})),S.calculatedDuration===null&&(S.calculatedDuration=S2(S));const{calculatedDuration:j}=S;this.calculatedDuration=j,this.resolvedDuration=j+d,this.totalDuration=this.resolvedDuration*(o+1)-d,this.generator=S}updateTime(r){const s=Math.round(r-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=s}tick(r,s=!1){const{generator:o,totalDuration:d,mixKeyframes:p,mirroredGenerator:m,resolvedDuration:g,calculatedDuration:b}=this;if(this.startTime===null)return o.next(0);const{delay:S=0,keyframes:j,repeat:A,repeatType:k,repeatDelay:T,type:M,onUpdate:I,finalKeyframe:q}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,r):this.speed<0&&(this.startTime=Math.min(r-d/this.speed,this.startTime)),s?this.currentTime=r:this.updateTime(r);const G=this.currentTime-S*(this.playbackSpeed>=0?1:-1),K=this.playbackSpeed>=0?G<0:G>d;this.currentTime=Math.max(G,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=d);let X=this.currentTime,L=o;if(A){const ne=Math.min(this.currentTime,d)/g;let de=Math.floor(ne),je=ne%1;!je&&ne>=1&&(je=1),je===1&&de--,de=Math.min(de,A+1),!!(de%2)&&(k==="reverse"?(je=1-je,T&&(je-=T/g)):k==="mirror"&&(L=m)),X=gu(0,1,je)*g}const ee=K?{done:!1,value:j[0]}:L.next(X);p&&(ee.value=p(ee.value));let{done:oe}=ee;!K&&b!==null&&(oe=this.playbackSpeed>=0?this.currentTime>=d:this.currentTime<=0);const Q=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&oe);return Q&&M!==HT&&(ee.value=E2(j,this.options,q,this.speed)),I&&I(ee.value),Q&&this.finish(),ee}then(r,s){return this.finished.then(r,s)}get duration(){return ro(this.calculatedDuration)}get iterationDuration(){const{delay:r=0}=this.options||{};return this.duration+ro(r)}get time(){return ro(this.currentTime)}set time(r){r=ic(r),this.currentTime=r,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=r:this.driver&&(this.startTime=this.driver.now()-r/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(r){this.updateTime(da.now());const s=this.playbackSpeed!==r;this.playbackSpeed=r,s&&(this.time=ro(this.currentTime))}play(){if(this.isStopped)return;const{driver:r=Boe,startTime:s}=this.options;this.driver||(this.driver=r(d=>this.tick(d))),this.options.onPlay?.();const o=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=o):this.holdTime!==null?this.startTime=o-this.holdTime:this.startTime||(this.startTime=s??o),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(da.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(r){return this.startTime=0,this.tick(r,!0)}attachTimeline(r){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),r.observe(this)}}function ale(e){for(let r=1;re*180/Math.PI,GT=e=>{const r=bp(Math.atan2(e[1],e[0]));return XT(r)},ole={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:GT,rotateZ:GT,skewX:e=>bp(Math.atan(e[1])),skewY:e=>bp(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},XT=e=>(e=e%360,e<0&&(e+=360),e),$I=GT,NI=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),DI=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),lle={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:NI,scaleY:DI,scale:e=>(NI(e)+DI(e))/2,rotateX:e=>XT(bp(Math.atan2(e[6],e[5]))),rotateY:e=>XT(bp(Math.atan2(-e[2],e[0]))),rotateZ:$I,rotate:$I,skewX:e=>bp(Math.atan(e[4])),skewY:e=>bp(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function YT(e){return e.includes("scale")?1:0}function ZT(e,r){if(!e||e==="none")return YT(r);const s=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let o,d;if(s)o=lle,d=s;else{const g=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);o=ole,d=g}if(!d)return YT(r);const p=o[r],m=d[1].split(",").map(ule);return typeof p=="function"?p(m):m[p]}const cle=(e,r)=>{const{transform:s="none"}=getComputedStyle(e);return ZT(s,r)};function ule(e){return parseFloat(e.trim())}const Dg=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Pg=new Set(Dg),PI=e=>e===Ng||e===tn,dle=new Set(["x","y","z"]),hle=Dg.filter(e=>!dle.has(e));function ple(e){const r=[];return hle.forEach(s=>{const o=e.getValue(s);o!==void 0&&(r.push([s,o.get()]),o.set(s.startsWith("scale")?1:0))}),r}const Sp={width:({x:e},{paddingLeft:r="0",paddingRight:s="0"})=>e.max-e.min-parseFloat(r)-parseFloat(s),height:({y:e},{paddingTop:r="0",paddingBottom:s="0"})=>e.max-e.min-parseFloat(r)-parseFloat(s),top:(e,{top:r})=>parseFloat(r),left:(e,{left:r})=>parseFloat(r),bottom:({y:e},{top:r})=>parseFloat(r)+(e.max-e.min),right:({x:e},{left:r})=>parseFloat(r)+(e.max-e.min),x:(e,{transform:r})=>ZT(r,"x"),y:(e,{transform:r})=>ZT(r,"y")};Sp.translateX=Sp.x;Sp.translateY=Sp.y;const Ep=new Set;let WT=!1,JT=!1,QT=!1;function D5(){if(JT){const e=Array.from(Ep).filter(o=>o.needsMeasurement),r=new Set(e.map(o=>o.element)),s=new Map;r.forEach(o=>{const d=ple(o);d.length&&(s.set(o,d),o.render())}),e.forEach(o=>o.measureInitialState()),r.forEach(o=>{o.render();const d=s.get(o);d&&d.forEach(([p,m])=>{o.getValue(p)?.set(m)})}),e.forEach(o=>o.measureEndState()),e.forEach(o=>{o.suspendedScrollY!==void 0&&window.scrollTo(0,o.suspendedScrollY)})}JT=!1,WT=!1,Ep.forEach(e=>e.complete(QT)),Ep.clear()}function P5(){Ep.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(JT=!0)})}function fle(){QT=!0,P5(),D5(),QT=!1}class A2{constructor(r,s,o,d,p,m=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...r],this.onComplete=s,this.name=o,this.motionValue=d,this.element=p,this.isAsync=m}scheduleResolve(){this.state="scheduled",this.isAsync?(Ep.add(this),WT||(WT=!0,_r.read(P5),_r.resolveKeyframes(D5))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:r,name:s,element:o,motionValue:d}=this;if(r[0]===null){const p=d?.get(),m=r[r.length-1];if(p!==void 0)r[0]=p;else if(o&&s){const g=o.readValue(s,m);g!=null&&(r[0]=g)}r[0]===void 0&&(r[0]=m),d&&p===void 0&&d.set(r[0])}ale(r)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(r=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,r),Ep.delete(this)}cancel(){this.state==="scheduled"&&(Ep.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const mle=e=>e.startsWith("--");function gle(e,r,s){mle(r)?e.style.setProperty(r,s):e.style[r]=s}const yle=f2(()=>window.ScrollTimeline!==void 0),vle={};function xle(e,r){const s=f2(e);return()=>vle[r]??s()}const M5=xle(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),wb=([e,r,s,o])=>`cubic-bezier(${e}, ${r}, ${s}, ${o})`,MI={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:wb([0,.65,.55,1]),circOut:wb([.55,0,1,.45]),backIn:wb([.31,.01,.66,-.59]),backOut:wb([.33,1.53,.69,.99])};function I5(e,r){if(e)return typeof e=="function"?M5()?_5(e,r):"ease-out":b5(e)?wb(e):Array.isArray(e)?e.map(s=>I5(s,r)||MI.easeOut):MI[e]}function ble(e,r,s,{delay:o=0,duration:d=300,repeat:p=0,repeatType:m="loop",ease:g="easeOut",times:b}={},S=void 0){const j={[r]:s};b&&(j.offset=b);const A=I5(g,d);Array.isArray(A)&&(j.easing=A);const k={delay:o,duration:d,easing:Array.isArray(A)?"linear":A,fill:"both",iterations:p+1,direction:m==="reverse"?"alternate":"normal"};return S&&(k.pseudoElement=S),e.animate(j,k)}function L5(e){return typeof e=="function"&&"applyToOptions"in e}function wle({type:e,...r}){return L5(e)&&M5()?e.applyToOptions(r):(r.duration??(r.duration=300),r.ease??(r.ease="easeOut"),r)}class Sle extends j2{constructor(r){if(super(),this.finishedTime=null,this.isStopped=!1,!r)return;const{element:s,name:o,keyframes:d,pseudoElement:p,allowFlatten:m=!1,finalKeyframe:g,onComplete:b}=r;this.isPseudoElement=!!p,this.allowFlatten=m,this.options=r,p2(typeof r.type!="string");const S=wle(r);this.animation=ble(s,o,d,S,p),S.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!p){const j=E2(d,this.options,g,this.speed);this.updateMotionValue?this.updateMotionValue(j):gle(s,o,j),this.animation.cancel()}b?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:r}=this;r==="idle"||r==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const r=this.animation.effect?.getComputedTiming?.().duration||0;return ro(Number(r))}get iterationDuration(){const{delay:r=0}=this.options||{};return this.duration+ro(r)}get time(){return ro(Number(this.animation.currentTime)||0)}set time(r){this.finishedTime=null,this.animation.currentTime=ic(r)}get speed(){return this.animation.playbackRate}set speed(r){r<0&&(this.finishedTime=null),this.animation.playbackRate=r}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(r){this.animation.startTime=r}attachTimeline({timeline:r,observe:s}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,r&&yle()?(this.animation.timeline=r,so):s(this)}}const z5={anticipate:g5,backInOut:m5,circInOut:v5};function Ele(e){return e in z5}function jle(e){typeof e.ease=="string"&&Ele(e.ease)&&(e.ease=z5[e.ease])}const II=10;class Cle extends Sle{constructor(r){jle(r),N5(r),super(r),r.startTime&&(this.startTime=r.startTime),this.options=r}updateMotionValue(r){const{motionValue:s,onUpdate:o,onComplete:d,element:p,...m}=this.options;if(!s)return;if(r!==void 0){s.set(r);return}const g=new C2({...m,autoplay:!1}),b=ic(this.finishedTime??this.time);s.setWithVelocity(g.sample(b-II).value,g.sample(b).value,II),g.stop()}}const LI=(e,r)=>r==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Kd.test(e)||e==="0")&&!e.startsWith("url("));function Ale(e){const r=e[0];if(e.length===1)return!0;for(let s=0;sObject.hasOwnProperty.call(Element.prototype,"animate"));function Tle(e){const{motionValue:r,name:s,repeatDelay:o,repeatType:d,damping:p,type:m}=e;if(!(r?.owner?.current instanceof HTMLElement))return!1;const{onUpdate:b,transformTemplate:S}=r.owner.getProps();return Rle()&&s&&kle.has(s)&&(s!=="transform"||!S)&&!b&&!o&&d!=="mirror"&&p!==0&&m!=="inertia"}const _le=40;class $le extends j2{constructor({autoplay:r=!0,delay:s=0,type:o="keyframes",repeat:d=0,repeatDelay:p=0,repeatType:m="loop",keyframes:g,name:b,motionValue:S,element:j,...A}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=da.now();const k={autoplay:r,delay:s,type:o,repeat:d,repeatDelay:p,repeatType:m,name:b,motionValue:S,element:j,...A},T=j?.KeyframeResolver||A2;this.keyframeResolver=new T(g,(M,I,q)=>this.onKeyframesResolved(M,I,k,!q),b,S,j),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(r,s,o,d){this.keyframeResolver=void 0;const{name:p,type:m,velocity:g,delay:b,isHandoff:S,onUpdate:j}=o;this.resolvedAt=da.now(),Ole(r,p,m,g)||((yu.instantAnimations||!b)&&j?.(E2(r,o,s)),r[0]=r[r.length-1],e_(o),o.repeat=0);const k={startTime:d?this.resolvedAt?this.resolvedAt-this.createdAt>_le?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:s,...o,keyframes:r},T=!S&&Tle(k)?new Cle({...k,element:k.motionValue.owner.current}):new C2(k);T.finished.then(()=>this.notifyFinished()).catch(so),this.pendingTimeline&&(this.stopTimeline=T.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=T}get finished(){return this._animation?this.animation.finished:this._finished}then(r,s){return this.finished.finally(r).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),fle()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(r){this.animation.time=r}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(r){this.animation.speed=r}get startTime(){return this.animation.startTime}attachTimeline(r){return this._animation?this.stopTimeline=this.animation.attachTimeline(r):this.pendingTimeline=r,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}const Nle=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Dle(e){const r=Nle.exec(e);if(!r)return[,];const[,s,o,d]=r;return[`--${s??o}`,d]}function F5(e,r,s=1){const[o,d]=Dle(e);if(!o)return;const p=window.getComputedStyle(r).getPropertyValue(o);if(p){const m=p.trim();return o5(m)?parseFloat(m):m}return v2(d)?F5(d,r,s+1):d}function O2(e,r){return e?.[r]??e?.default??e}const q5=new Set(["width","height","top","left","right","bottom",...Dg]),Ple={test:e=>e==="auto",parse:e=>e},B5=e=>r=>r.test(e),U5=[Ng,tn,ac,Md,Aoe,Coe,Ple],zI=e=>U5.find(B5(e));function Mle(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||c5(e):!0}const Ile=new Set(["brightness","contrast","saturate","opacity"]);function Lle(e){const[r,s]=e.slice(0,-1).split("(");if(r==="drop-shadow")return e;const[o]=s.match(x2)||[];if(!o)return e;const d=s.replace(o,"");let p=Ile.has(r)?1:0;return o!==s&&(p*=100),r+"("+p+d+")"}const zle=/\b([a-z-]*)\(.*?\)/gu,t_={...Kd,getAnimatableNone:e=>{const r=e.match(zle);return r?r.map(Lle).join(" "):e}},FI={...Ng,transform:Math.round},Fle={rotate:Md,rotateX:Md,rotateY:Md,rotateZ:Md,scale:JE,scaleX:JE,scaleY:JE,scaleZ:JE,skew:Md,skewX:Md,skewY:Md,distance:tn,translateX:tn,translateY:tn,translateZ:tn,x:tn,y:tn,z:tn,perspective:tn,transformPerspective:tn,opacity:Bb,originX:OI,originY:OI,originZ:tn},k2={borderWidth:tn,borderTopWidth:tn,borderRightWidth:tn,borderBottomWidth:tn,borderLeftWidth:tn,borderRadius:tn,radius:tn,borderTopLeftRadius:tn,borderTopRightRadius:tn,borderBottomRightRadius:tn,borderBottomLeftRadius:tn,width:tn,maxWidth:tn,height:tn,maxHeight:tn,top:tn,right:tn,bottom:tn,left:tn,padding:tn,paddingTop:tn,paddingRight:tn,paddingBottom:tn,paddingLeft:tn,margin:tn,marginTop:tn,marginRight:tn,marginBottom:tn,marginLeft:tn,backgroundPositionX:tn,backgroundPositionY:tn,...Fle,zIndex:FI,fillOpacity:Bb,strokeOpacity:Bb,numOctaves:FI},qle={...k2,color:fs,backgroundColor:fs,outlineColor:fs,fill:fs,stroke:fs,borderColor:fs,borderTopColor:fs,borderRightColor:fs,borderBottomColor:fs,borderLeftColor:fs,filter:t_,WebkitFilter:t_},K5=e=>qle[e];function V5(e,r){let s=K5(e);return s!==t_&&(s=Kd),s.getAnimatableNone?s.getAnimatableNone(r):void 0}const Ble=new Set(["auto","none","0"]);function Ule(e,r,s){let o=0,d;for(;o{r.getValue(g).set(b)}),this.resolveNoneKeyframes()}}function Vle(e,r,s){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let o=document;const d=s?.[e]??o.querySelectorAll(e);return d?Array.from(d):[]}return Array.from(e)}const H5=(e,r)=>r&&typeof e=="number"?r.transform(e):e;function Hle(e){return l5(e)&&"offsetHeight"in e}const qI=30,Gle=e=>!isNaN(parseFloat(e));class Xle{constructor(r,s={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=o=>{const d=da.now();if(this.updatedAt!==d&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(o),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const p of this.dependents)p.dirty()},this.hasAnimated=!1,this.setCurrent(r),this.owner=s.owner}setCurrent(r){this.current=r,this.updatedAt=da.now(),this.canTrackVelocity===null&&r!==void 0&&(this.canTrackVelocity=Gle(this.current))}setPrevFrameValue(r=this.current){this.prevFrameValue=r,this.prevUpdatedAt=this.updatedAt}onChange(r){return this.on("change",r)}on(r,s){this.events[r]||(this.events[r]=new m2);const o=this.events[r].add(s);return r==="change"?()=>{o(),_r.read(()=>{this.events.change.getSize()||this.stop()})}:o}clearListeners(){for(const r in this.events)this.events[r].clear()}attach(r,s){this.passiveEffect=r,this.stopPassiveEffect=s}set(r){this.passiveEffect?this.passiveEffect(r,this.updateAndNotify):this.updateAndNotify(r)}setWithVelocity(r,s,o){this.set(s),this.prev=void 0,this.prevFrameValue=r,this.prevUpdatedAt=this.updatedAt-o}jump(r,s=!0){this.updateAndNotify(r),this.prev=r,this.prevUpdatedAt=this.prevFrameValue=void 0,s&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(r){this.dependents||(this.dependents=new Set),this.dependents.add(r)}removeDependent(r){this.dependents&&this.dependents.delete(r)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const r=da.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||r-this.updatedAt>qI)return 0;const s=Math.min(this.updatedAt-this.prevUpdatedAt,qI);return u5(parseFloat(this.current)-parseFloat(this.prevFrameValue),s)}start(r){return this.stop(),new Promise(s=>{this.hasAnimated=!0,this.animation=r(s),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function wg(e,r){return new Xle(e,r)}const{schedule:R2}=w5(queueMicrotask,!1),Xo={x:!1,y:!1};function G5(){return Xo.x||Xo.y}function Yle(e){return e==="x"||e==="y"?Xo[e]?null:(Xo[e]=!0,()=>{Xo[e]=!1}):Xo.x||Xo.y?null:(Xo.x=Xo.y=!0,()=>{Xo.x=Xo.y=!1})}function X5(e,r){const s=Vle(e),o=new AbortController,d={passive:!0,...r,signal:o.signal};return[s,d,()=>o.abort()]}function BI(e){return!(e.pointerType==="touch"||G5())}function Zle(e,r,s={}){const[o,d,p]=X5(e,s),m=g=>{if(!BI(g))return;const{target:b}=g,S=r(b,g);if(typeof S!="function"||!b)return;const j=A=>{BI(A)&&(S(A),b.removeEventListener("pointerleave",j))};b.addEventListener("pointerleave",j,d)};return o.forEach(g=>{g.addEventListener("pointerenter",m,d)}),p}const Y5=(e,r)=>r?e===r?!0:Y5(e,r.parentElement):!1,T2=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Wle=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Jle(e){return Wle.has(e.tagName)||e.tabIndex!==-1}const xj=new WeakSet;function UI(e){return r=>{r.key==="Enter"&&e(r)}}function QR(e,r){e.dispatchEvent(new PointerEvent("pointer"+r,{isPrimary:!0,bubbles:!0}))}const Qle=(e,r)=>{const s=e.currentTarget;if(!s)return;const o=UI(()=>{if(xj.has(s))return;QR(s,"down");const d=UI(()=>{QR(s,"up")}),p=()=>QR(s,"cancel");s.addEventListener("keyup",d,r),s.addEventListener("blur",p,r)});s.addEventListener("keydown",o,r),s.addEventListener("blur",()=>s.removeEventListener("keydown",o),r)};function KI(e){return T2(e)&&!G5()}function ece(e,r,s={}){const[o,d,p]=X5(e,s),m=g=>{const b=g.currentTarget;if(!KI(g))return;xj.add(b);const S=r(b,g),j=(T,M)=>{window.removeEventListener("pointerup",A),window.removeEventListener("pointercancel",k),xj.has(b)&&xj.delete(b),KI(T)&&typeof S=="function"&&S(T,{success:M})},A=T=>{j(T,b===window||b===document||s.useGlobalTarget||Y5(b,T.target))},k=T=>{j(T,!1)};window.addEventListener("pointerup",A,d),window.addEventListener("pointercancel",k,d)};return o.forEach(g=>{(s.useGlobalTarget?window:g).addEventListener("pointerdown",m,d),Hle(g)&&(g.addEventListener("focus",S=>Qle(S,d)),!Jle(g)&&!g.hasAttribute("tabindex")&&(g.tabIndex=0))}),p}function Z5(e){return l5(e)&&"ownerSVGElement"in e}function tce(e){return Z5(e)&&e.tagName==="svg"}const bi=e=>!!(e&&e.getVelocity),nce=[...U5,fs,Kd],rce=e=>nce.find(B5(e)),W5=R.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function sce(e=!0){const r=R.useContext(u2);if(r===null)return[!0,null];const{isPresent:s,onExitComplete:o,register:d}=r,p=R.useId();R.useEffect(()=>{if(e)return d(p)},[e]);const m=R.useCallback(()=>e&&o&&o(p),[p,o,e]);return!s&&o?[!1,m]:[!0]}const J5=R.createContext({strict:!1}),VI={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Sg={};for(const e in VI)Sg[e]={isEnabled:r=>VI[e].some(s=>!!r[s])};function ice(e){for(const r in e)Sg[r]={...Sg[r],...e[r]}}const ace=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Hj(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||ace.has(e)}let Q5=e=>!Hj(e);function oce(e){typeof e=="function"&&(Q5=r=>r.startsWith("on")?!Hj(r):e(r))}try{oce(require("@emotion/is-prop-valid").default)}catch{}function lce(e,r,s){const o={};for(const d in e)d==="values"&&typeof e.values=="object"||(Q5(d)||s===!0&&Hj(d)||!r&&!Hj(d)||e.draggable&&d.startsWith("onDrag"))&&(o[d]=e[d]);return o}const MC=R.createContext({});function IC(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Kb(e){return typeof e=="string"||Array.isArray(e)}const _2=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],$2=["initial",..._2];function LC(e){return IC(e.animate)||$2.some(r=>Kb(e[r]))}function eF(e){return!!(LC(e)||e.variants)}function cce(e,r){if(LC(e)){const{initial:s,animate:o}=e;return{initial:s===!1||Kb(s)?s:void 0,animate:Kb(o)?o:void 0}}return e.inherit!==!1?r:{}}function uce(e){const{initial:r,animate:s}=cce(e,R.useContext(MC));return R.useMemo(()=>({initial:r,animate:s}),[HI(r),HI(s)])}function HI(e){return Array.isArray(e)?e.join(" "):e}function GI(e,r){return r.max===r.min?0:e/(r.max-r.min)*100}const ab={correct:(e,r)=>{if(!r.target)return e;if(typeof e=="string")if(tn.test(e))e=parseFloat(e);else return e;const s=GI(e,r.target.x),o=GI(e,r.target.y);return`${s}% ${o}%`}},dce={correct:(e,{treeScale:r,projectionDelta:s})=>{const o=e,d=Kd.parse(e);if(d.length>5)return o;const p=Kd.createTransformer(e),m=typeof d[0]!="number"?1:0,g=s.x.scale*r.x,b=s.y.scale*r.y;d[0+m]/=g,d[1+m]/=b;const S=Lr(g,b,.5);return typeof d[2+m]=="number"&&(d[2+m]/=S),typeof d[3+m]=="number"&&(d[3+m]/=S),p(d)}},n_={borderRadius:{...ab,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:ab,borderTopRightRadius:ab,borderBottomLeftRadius:ab,borderBottomRightRadius:ab,boxShadow:dce};function tF(e,{layout:r,layoutId:s}){return Pg.has(e)||e.startsWith("origin")||(r||s!==void 0)&&(!!n_[e]||e==="opacity")}const hce={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},pce=Dg.length;function fce(e,r,s){let o="",d=!0;for(let p=0;p({style:{},transform:{},transformOrigin:{},vars:{}});function nF(e,r,s){for(const o in r)!bi(r[o])&&!tF(o,s)&&(e[o]=r[o])}function mce({transformTemplate:e},r){return R.useMemo(()=>{const s=D2();return N2(s,r,e),Object.assign({},s.vars,s.style)},[r])}function gce(e,r){const s=e.style||{},o={};return nF(o,s,e),Object.assign(o,mce(e,r)),o}function yce(e,r){const s={},o=gce(e,r);return e.drag&&e.dragListener!==!1&&(s.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(s.tabIndex=0),s.style=o,s}const vce={offset:"stroke-dashoffset",array:"stroke-dasharray"},xce={offset:"strokeDashoffset",array:"strokeDasharray"};function bce(e,r,s=1,o=0,d=!0){e.pathLength=1;const p=d?vce:xce;e[p.offset]=tn.transform(-o);const m=tn.transform(r),g=tn.transform(s);e[p.array]=`${m} ${g}`}function rF(e,{attrX:r,attrY:s,attrScale:o,pathLength:d,pathSpacing:p=1,pathOffset:m=0,...g},b,S,j){if(N2(e,g,S),b){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:A,style:k}=e;A.transform&&(k.transform=A.transform,delete A.transform),(k.transform||A.transformOrigin)&&(k.transformOrigin=A.transformOrigin??"50% 50%",delete A.transformOrigin),k.transform&&(k.transformBox=j?.transformBox??"fill-box",delete A.transformBox),r!==void 0&&(A.x=r),s!==void 0&&(A.y=s),o!==void 0&&(A.scale=o),d!==void 0&&bce(A,d,p,m,!1)}const sF=()=>({...D2(),attrs:{}}),iF=e=>typeof e=="string"&&e.toLowerCase()==="svg";function wce(e,r,s,o){const d=R.useMemo(()=>{const p=sF();return rF(p,r,iF(o),e.transformTemplate,e.style),{...p.attrs,style:{...p.style}}},[r]);if(e.style){const p={};nF(p,e.style,e),d.style={...p,...d.style}}return d}const Sce=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function P2(e){return typeof e!="string"||e.includes("-")?!1:!!(Sce.indexOf(e)>-1||/[A-Z]/u.test(e))}function Ece(e,r,s,{latestValues:o},d,p=!1){const g=(P2(e)?wce:yce)(r,o,d,e),b=lce(r,typeof e=="string",p),S=e!==R.Fragment?{...b,...g,ref:s}:{},{children:j}=r,A=R.useMemo(()=>bi(j)?j.get():j,[j]);return R.createElement(e,{...S,children:A})}function XI(e){const r=[{},{}];return e?.values.forEach((s,o)=>{r[0][o]=s.get(),r[1][o]=s.getVelocity()}),r}function M2(e,r,s,o){if(typeof r=="function"){const[d,p]=XI(o);r=r(s!==void 0?s:e.custom,d,p)}if(typeof r=="string"&&(r=e.variants&&e.variants[r]),typeof r=="function"){const[d,p]=XI(o);r=r(s!==void 0?s:e.custom,d,p)}return r}function bj(e){return bi(e)?e.get():e}function jce({scrapeMotionValuesFromProps:e,createRenderState:r},s,o,d){return{latestValues:Cce(s,o,d,e),renderState:r()}}function Cce(e,r,s,o){const d={},p=o(e,{});for(const k in p)d[k]=bj(p[k]);let{initial:m,animate:g}=e;const b=LC(e),S=eF(e);r&&S&&!b&&e.inherit!==!1&&(m===void 0&&(m=r.initial),g===void 0&&(g=r.animate));let j=s?s.initial===!1:!1;j=j||m===!1;const A=j?g:m;if(A&&typeof A!="boolean"&&!IC(A)){const k=Array.isArray(A)?A:[A];for(let T=0;T(r,s)=>{const o=R.useContext(MC),d=R.useContext(u2),p=()=>jce(e,r,o,d);return s?p():ioe(p)};function I2(e,r,s){const{style:o}=e,d={};for(const p in o)(bi(o[p])||r.style&&bi(r.style[p])||tF(p,e)||s?.getValue(p)?.liveStyle!==void 0)&&(d[p]=o[p]);return d}const Ace=aF({scrapeMotionValuesFromProps:I2,createRenderState:D2});function oF(e,r,s){const o=I2(e,r,s);for(const d in e)if(bi(e[d])||bi(r[d])){const p=Dg.indexOf(d)!==-1?"attr"+d.charAt(0).toUpperCase()+d.substring(1):d;o[p]=e[d]}return o}const Oce=aF({scrapeMotionValuesFromProps:oF,createRenderState:sF}),kce=Symbol.for("motionComponentSymbol");function ag(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function Rce(e,r,s){return R.useCallback(o=>{o&&e.onMount&&e.onMount(o),r&&(o?r.mount(o):r.unmount()),s&&(typeof s=="function"?s(o):ag(s)&&(s.current=o))},[r])}const L2=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),Tce="framerAppearId",lF="data-"+L2(Tce),cF=R.createContext({});function _ce(e,r,s,o,d){const{visualElement:p}=R.useContext(MC),m=R.useContext(J5),g=R.useContext(u2),b=R.useContext(W5).reducedMotion,S=R.useRef(null);o=o||m.renderer,!S.current&&o&&(S.current=o(e,{visualState:r,parent:p,props:s,presenceContext:g,blockInitialAnimation:g?g.initial===!1:!1,reducedMotionConfig:b}));const j=S.current,A=R.useContext(cF);j&&!j.projection&&d&&(j.type==="html"||j.type==="svg")&&$ce(S.current,s,d,A);const k=R.useRef(!1);R.useInsertionEffect(()=>{j&&k.current&&j.update(s,g)});const T=s[lF],M=R.useRef(!!T&&!window.MotionHandoffIsComplete?.(T)&&window.MotionHasOptimisedAnimation?.(T));return aoe(()=>{j&&(k.current=!0,window.MotionIsMounted=!0,j.updateFeatures(),j.scheduleRenderMicrotask(),M.current&&j.animationState&&j.animationState.animateChanges())}),R.useEffect(()=>{j&&(!M.current&&j.animationState&&j.animationState.animateChanges(),M.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(T)}),M.current=!1),j.enteringChildren=void 0)}),j}function $ce(e,r,s,o){const{layoutId:d,layout:p,drag:m,dragConstraints:g,layoutScroll:b,layoutRoot:S,layoutCrossfade:j}=r;e.projection=new s(e.latestValues,r["data-framer-portal-id"]?void 0:uF(e.parent)),e.projection.setOptions({layoutId:d,layout:p,alwaysMeasureLayout:!!m||g&&ag(g),visualElement:e,animationType:typeof p=="string"?p:"both",initialPromotionConfig:o,crossfade:j,layoutScroll:b,layoutRoot:S})}function uF(e){if(e)return e.options.allowProjection!==!1?e.projection:uF(e.parent)}function eT(e,{forwardMotionProps:r=!1}={},s,o){s&&ice(s);const d=P2(e)?Oce:Ace;function p(g,b){let S;const j={...R.useContext(W5),...g,layoutId:Nce(g)},{isStatic:A}=j,k=uce(g),T=d(g,A);if(!A&&c2){Dce();const M=Pce(j);S=M.MeasureLayout,k.visualElement=_ce(e,T,j,o,M.ProjectionNode)}return u.jsxs(MC.Provider,{value:k,children:[S&&k.visualElement?u.jsx(S,{visualElement:k.visualElement,...j}):null,Ece(e,g,Rce(T,k.visualElement,b),T,A,r)]})}p.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const m=R.forwardRef(p);return m[kce]=e,m}function Nce({layoutId:e}){const r=R.useContext(a5).id;return r&&e!==void 0?r+"-"+e:e}function Dce(e,r){R.useContext(J5).strict}function Pce(e){const{drag:r,layout:s}=Sg;if(!r&&!s)return{};const o={...r,...s};return{MeasureLayout:r?.isEnabled(e)||s?.isEnabled(e)?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}function Mce(e,r){if(typeof Proxy>"u")return eT;const s=new Map,o=(p,m)=>eT(p,m,e,r),d=(p,m)=>o(p,m);return new Proxy(d,{get:(p,m)=>m==="create"?o:(s.has(m)||s.set(m,eT(m,void 0,e,r)),s.get(m))})}function dF({top:e,left:r,right:s,bottom:o}){return{x:{min:r,max:s},y:{min:e,max:o}}}function Ice({x:e,y:r}){return{top:r.min,right:e.max,bottom:r.max,left:e.min}}function Lce(e,r){if(!r)return e;const s=r({x:e.left,y:e.top}),o=r({x:e.right,y:e.bottom});return{top:s.y,left:s.x,bottom:o.y,right:o.x}}function tT(e){return e===void 0||e===1}function r_({scale:e,scaleX:r,scaleY:s}){return!tT(e)||!tT(r)||!tT(s)}function gp(e){return r_(e)||hF(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function hF(e){return YI(e.x)||YI(e.y)}function YI(e){return e&&e!=="0%"}function Gj(e,r,s){const o=e-s,d=r*o;return s+d}function ZI(e,r,s,o,d){return d!==void 0&&(e=Gj(e,d,o)),Gj(e,s,o)+r}function s_(e,r=0,s=1,o,d){e.min=ZI(e.min,r,s,o,d),e.max=ZI(e.max,r,s,o,d)}function pF(e,{x:r,y:s}){s_(e.x,r.translate,r.scale,r.originPoint),s_(e.y,s.translate,s.scale,s.originPoint)}const WI=.999999999999,JI=1.0000000000001;function zce(e,r,s,o=!1){const d=s.length;if(!d)return;r.x=r.y=1;let p,m;for(let g=0;gWI&&(r.x=1),r.yWI&&(r.y=1)}function og(e,r){e.min=e.min+r,e.max=e.max+r}function QI(e,r,s,o,d=.5){const p=Lr(e.min,e.max,d);s_(e,r,s,p,o)}function lg(e,r){QI(e.x,r.x,r.scaleX,r.scale,r.originX),QI(e.y,r.y,r.scaleY,r.scale,r.originY)}function fF(e,r){return dF(Lce(e.getBoundingClientRect(),r))}function Fce(e,r,s){const o=fF(e,s),{scroll:d}=r;return d&&(og(o.x,d.offset.x),og(o.y,d.offset.y)),o}const e4=()=>({translate:0,scale:1,origin:0,originPoint:0}),cg=()=>({x:e4(),y:e4()}),t4=()=>({min:0,max:0}),js=()=>({x:t4(),y:t4()}),i_={current:null},mF={current:!1};function qce(){if(mF.current=!0,!!c2)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),r=()=>i_.current=e.matches;e.addEventListener("change",r),r()}else i_.current=!1}const Bce=new WeakMap;function Uce(e,r,s){for(const o in r){const d=r[o],p=s[o];if(bi(d))e.addValue(o,d);else if(bi(p))e.addValue(o,wg(d,{owner:e}));else if(p!==d)if(e.hasValue(o)){const m=e.getValue(o);m.liveStyle===!0?m.jump(d):m.hasAnimated||m.set(d)}else{const m=e.getStaticValue(o);e.addValue(o,wg(m!==void 0?m:d,{owner:e}))}}for(const o in s)r[o]===void 0&&e.removeValue(o);return r}const n4=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class Kce{scrapeMotionValuesFromProps(r,s,o){return{}}constructor({parent:r,props:s,presenceContext:o,reducedMotionConfig:d,blockInitialAnimation:p,visualState:m},g={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=A2,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const k=da.now();this.renderScheduledAtthis.bindToMotionValue(o,s)),mF.current||qce(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:i_.current,this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),Ud(this.notifyUpdate),Ud(this.render),this.valueSubscriptions.forEach(r=>r()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const r in this.events)this.events[r].clear();for(const r in this.features){const s=this.features[r];s&&(s.unmount(),s.isMounted=!1)}this.current=null}addChild(r){this.children.add(r),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(r)}removeChild(r){this.children.delete(r),this.enteringChildren&&this.enteringChildren.delete(r)}bindToMotionValue(r,s){this.valueSubscriptions.has(r)&&this.valueSubscriptions.get(r)();const o=Pg.has(r);o&&this.onBindTransform&&this.onBindTransform();const d=s.on("change",m=>{this.latestValues[r]=m,this.props.onUpdate&&_r.preRender(this.notifyUpdate),o&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let p;window.MotionCheckAppearSync&&(p=window.MotionCheckAppearSync(this,r,s)),this.valueSubscriptions.set(r,()=>{d(),p&&p(),s.owner&&s.stop()})}sortNodePosition(r){return!this.current||!this.sortInstanceNodePosition||this.type!==r.type?0:this.sortInstanceNodePosition(this.current,r.current)}updateFeatures(){let r="animation";for(r in Sg){const s=Sg[r];if(!s)continue;const{isEnabled:o,Feature:d}=s;if(!this.features[r]&&d&&o(this.props)&&(this.features[r]=new d(this)),this.features[r]){const p=this.features[r];p.isMounted?p.update():(p.mount(),p.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):js()}getStaticValue(r){return this.latestValues[r]}setStaticValue(r,s){this.latestValues[r]=s}update(r,s){(r.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=r,this.prevPresenceContext=this.presenceContext,this.presenceContext=s;for(let o=0;os.variantChildren.delete(r)}addValue(r,s){const o=this.values.get(r);s!==o&&(o&&this.removeValue(r),this.bindToMotionValue(r,s),this.values.set(r,s),this.latestValues[r]=s.get())}removeValue(r){this.values.delete(r);const s=this.valueSubscriptions.get(r);s&&(s(),this.valueSubscriptions.delete(r)),delete this.latestValues[r],this.removeValueFromRenderState(r,this.renderState)}hasValue(r){return this.values.has(r)}getValue(r,s){if(this.props.values&&this.props.values[r])return this.props.values[r];let o=this.values.get(r);return o===void 0&&s!==void 0&&(o=wg(s===null?void 0:s,{owner:this}),this.addValue(r,o)),o}readValue(r,s){let o=this.latestValues[r]!==void 0||!this.current?this.latestValues[r]:this.getBaseTargetFromProps(this.props,r)??this.readValueFromInstance(this.current,r,this.options);return o!=null&&(typeof o=="string"&&(o5(o)||c5(o))?o=parseFloat(o):!rce(o)&&Kd.test(s)&&(o=V5(r,s)),this.setBaseTarget(r,bi(o)?o.get():o)),bi(o)?o.get():o}setBaseTarget(r,s){this.baseTarget[r]=s}getBaseTarget(r){const{initial:s}=this.props;let o;if(typeof s=="string"||typeof s=="object"){const p=M2(this.props,s,this.presenceContext?.custom);p&&(o=p[r])}if(s&&o!==void 0)return o;const d=this.getBaseTargetFromProps(this.props,r);return d!==void 0&&!bi(d)?d:this.initialValues[r]!==void 0&&o===void 0?void 0:this.baseTarget[r]}on(r,s){return this.events[r]||(this.events[r]=new m2),this.events[r].add(s)}notify(r,...s){this.events[r]&&this.events[r].notify(...s)}scheduleRenderMicrotask(){R2.render(this.render)}}class gF extends Kce{constructor(){super(...arguments),this.KeyframeResolver=Kle}sortInstanceNodePosition(r,s){return r.compareDocumentPosition(s)&2?1:-1}getBaseTargetFromProps(r,s){return r.style?r.style[s]:void 0}removeValueFromRenderState(r,{vars:s,style:o}){delete s[r],delete o[r]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:r}=this.props;bi(r)&&(this.childSubscription=r.on("change",s=>{this.current&&(this.current.textContent=`${s}`)}))}}function yF(e,{style:r,vars:s},o,d){const p=e.style;let m;for(m in r)p[m]=r[m];d?.applyProjectionStyles(p,o);for(m in s)p.setProperty(m,s[m])}function Vce(e){return window.getComputedStyle(e)}class Hce extends gF{constructor(){super(...arguments),this.type="html",this.renderInstance=yF}readValueFromInstance(r,s){if(Pg.has(s))return this.projection?.isProjecting?YT(s):cle(r,s);{const o=Vce(r),d=(E5(s)?o.getPropertyValue(s):o[s])||0;return typeof d=="string"?d.trim():d}}measureInstanceViewportBox(r,{transformPagePoint:s}){return fF(r,s)}build(r,s,o){N2(r,s,o.transformTemplate)}scrapeMotionValuesFromProps(r,s,o){return I2(r,s,o)}}const vF=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function Gce(e,r,s,o){yF(e,r,void 0,o);for(const d in r.attrs)e.setAttribute(vF.has(d)?d:L2(d),r.attrs[d])}class Xce extends gF{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=js}getBaseTargetFromProps(r,s){return r[s]}readValueFromInstance(r,s){if(Pg.has(s)){const o=K5(s);return o&&o.default||0}return s=vF.has(s)?s:L2(s),r.getAttribute(s)}scrapeMotionValuesFromProps(r,s,o){return oF(r,s,o)}build(r,s,o){rF(r,s,this.isSVGTag,o.transformTemplate,o.style)}renderInstance(r,s,o,d){Gce(r,s,o,d)}mount(r){this.isSVGTag=iF(r.tagName),super.mount(r)}}const Yce=(e,r)=>P2(e)?new Xce(r):new Hce(r,{allowProjection:e!==R.Fragment});function mg(e,r,s){const o=e.getProps();return M2(o,r,s!==void 0?s:o.custom,e)}const a_=e=>Array.isArray(e);function Zce(e,r,s){e.hasValue(r)?e.getValue(r).set(s):e.addValue(r,wg(s))}function Wce(e){return a_(e)?e[e.length-1]||0:e}function Jce(e,r){const s=mg(e,r);let{transitionEnd:o={},transition:d={},...p}=s||{};p={...p,...o};for(const m in p){const g=Wce(p[m]);Zce(e,m,g)}}function Qce(e){return!!(bi(e)&&e.add)}function o_(e,r){const s=e.getValue("willChange");if(Qce(s))return s.add(r);if(!s&&yu.WillChange){const o=new yu.WillChange("auto");e.addValue("willChange",o),o.add(r)}}function xF(e){return e.props[lF]}const eue=e=>e!==null;function tue(e,{repeat:r,repeatType:s="loop"},o){const d=e.filter(eue),p=r&&s!=="loop"&&r%2===1?0:d.length-1;return d[p]}const nue={type:"spring",stiffness:500,damping:25,restSpeed:10},rue=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),sue={type:"keyframes",duration:.8},iue={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},aue=(e,{keyframes:r})=>r.length>2?sue:Pg.has(e)?e.startsWith("scale")?rue(r[1]):nue:iue;function oue({when:e,delay:r,delayChildren:s,staggerChildren:o,staggerDirection:d,repeat:p,repeatType:m,repeatDelay:g,from:b,elapsed:S,...j}){return!!Object.keys(j).length}const z2=(e,r,s,o={},d,p)=>m=>{const g=O2(o,e)||{},b=g.delay||o.delay||0;let{elapsed:S=0}=o;S=S-ic(b);const j={keyframes:Array.isArray(s)?s:[null,s],ease:"easeOut",velocity:r.getVelocity(),...g,delay:-S,onUpdate:k=>{r.set(k),g.onUpdate&&g.onUpdate(k)},onComplete:()=>{m(),g.onComplete&&g.onComplete()},name:e,motionValue:r,element:p?void 0:d};oue(g)||Object.assign(j,aue(e,j)),j.duration&&(j.duration=ic(j.duration)),j.repeatDelay&&(j.repeatDelay=ic(j.repeatDelay)),j.from!==void 0&&(j.keyframes[0]=j.from);let A=!1;if((j.type===!1||j.duration===0&&!j.repeatDelay)&&(e_(j),j.delay===0&&(A=!0)),(yu.instantAnimations||yu.skipAnimations)&&(A=!0,e_(j),j.delay=0),j.allowFlatten=!g.type&&!g.ease,A&&!p&&r.get()!==void 0){const k=tue(j.keyframes,g);if(k!==void 0){_r.update(()=>{j.onUpdate(k),j.onComplete()});return}}return g.isSync?new C2(j):new $le(j)};function lue({protectedKeys:e,needsAnimating:r},s){const o=e.hasOwnProperty(s)&&r[s]!==!0;return r[s]=!1,o}function bF(e,r,{delay:s=0,transitionOverride:o,type:d}={}){let{transition:p=e.getDefaultTransition(),transitionEnd:m,...g}=r;o&&(p=o);const b=[],S=d&&e.animationState&&e.animationState.getState()[d];for(const j in g){const A=e.getValue(j,e.latestValues[j]??null),k=g[j];if(k===void 0||S&&lue(S,j))continue;const T={delay:s,...O2(p||{},j)},M=A.get();if(M!==void 0&&!A.isAnimating&&!Array.isArray(k)&&k===M&&!T.velocity)continue;let I=!1;if(window.MotionHandoffAnimation){const G=xF(e);if(G){const K=window.MotionHandoffAnimation(G,j,_r);K!==null&&(T.startTime=K,I=!0)}}o_(e,j),A.start(z2(j,A,k,e.shouldReduceMotion&&q5.has(j)?{type:!1}:T,e,I));const q=A.animation;q&&b.push(q)}return m&&Promise.all(b).then(()=>{_r.update(()=>{m&&Jce(e,m)})}),b}function wF(e,r,s,o=0,d=1){const p=Array.from(e).sort((S,j)=>S.sortNodePosition(j)).indexOf(r),m=e.size,g=(m-1)*o;return typeof s=="function"?s(p,m):d===1?p*o:g-p*o}function l_(e,r,s={}){const o=mg(e,r,s.type==="exit"?e.presenceContext?.custom:void 0);let{transition:d=e.getDefaultTransition()||{}}=o||{};s.transitionOverride&&(d=s.transitionOverride);const p=o?()=>Promise.all(bF(e,o,s)):()=>Promise.resolve(),m=e.variantChildren&&e.variantChildren.size?(b=0)=>{const{delayChildren:S=0,staggerChildren:j,staggerDirection:A}=d;return cue(e,r,b,S,j,A,s)}:()=>Promise.resolve(),{when:g}=d;if(g){const[b,S]=g==="beforeChildren"?[p,m]:[m,p];return b().then(()=>S())}else return Promise.all([p(),m(s.delay)])}function cue(e,r,s=0,o=0,d=0,p=1,m){const g=[];for(const b of e.variantChildren)b.notify("AnimationStart",r),g.push(l_(b,r,{...m,delay:s+(typeof o=="function"?0:o)+wF(e.variantChildren,b,o,d,p)}).then(()=>b.notify("AnimationComplete",r)));return Promise.all(g)}function uue(e,r,s={}){e.notify("AnimationStart",r);let o;if(Array.isArray(r)){const d=r.map(p=>l_(e,p,s));o=Promise.all(d)}else if(typeof r=="string")o=l_(e,r,s);else{const d=typeof r=="function"?mg(e,r,s.custom):r;o=Promise.all(bF(e,d,s))}return o.then(()=>{e.notify("AnimationComplete",r)})}function SF(e,r){if(!Array.isArray(r))return!1;const s=r.length;if(s!==e.length)return!1;for(let o=0;oPromise.all(r.map(({animation:s,options:o})=>uue(e,s,o)))}function mue(e){let r=fue(e),s=r4(),o=!0;const d=b=>(S,j)=>{const A=mg(e,j,b==="exit"?e.presenceContext?.custom:void 0);if(A){const{transition:k,transitionEnd:T,...M}=A;S={...S,...M,...T}}return S};function p(b){r=b(e)}function m(b){const{props:S}=e,j=EF(e.parent)||{},A=[],k=new Set;let T={},M=1/0;for(let q=0;qM&&L,de=!1;const je=Array.isArray(X)?X:[X];let ve=je.reduce(d(G),{});ee===!1&&(ve={});const{prevResolvedValues:le={}}=K,be={...le,...ve},Ce=re=>{ne=!0,k.has(re)&&(de=!0,k.delete(re)),K.needsAnimating[re]=!0;const ue=e.getValue(re);ue&&(ue.liveStyle=!1)};for(const re in be){const ue=ve[re],_e=le[re];if(T.hasOwnProperty(re))continue;let fe=!1;a_(ue)&&a_(_e)?fe=!SF(ue,_e):fe=ue!==_e,fe?ue!=null?Ce(re):k.add(re):ue!==void 0&&k.has(re)?Ce(re):K.protectedKeys[re]=!0}K.prevProp=X,K.prevResolvedValues=ve,K.isActive&&(T={...T,...ve}),o&&e.blockInitialAnimation&&(ne=!1);const Ke=oe&&Q;ne&&(!Ke||de)&&A.push(...je.map(re=>{const ue={type:G};if(typeof re=="string"&&o&&!Ke&&e.manuallyAnimateOnMount&&e.parent){const{parent:_e}=e,fe=mg(_e,re);if(_e.enteringChildren&&fe){const{delayChildren:He}=fe.transition||{};ue.delay=wF(_e.enteringChildren,e,He)}}return{animation:re,options:ue}}))}if(k.size){const q={};if(typeof S.initial!="boolean"){const G=mg(e,Array.isArray(S.initial)?S.initial[0]:S.initial);G&&G.transition&&(q.transition=G.transition)}k.forEach(G=>{const K=e.getBaseTarget(G),X=e.getValue(G);X&&(X.liveStyle=!0),q[G]=K??null}),A.push({animation:q})}let I=!!A.length;return o&&(S.initial===!1||S.initial===S.animate)&&!e.manuallyAnimateOnMount&&(I=!1),o=!1,I?r(A):Promise.resolve()}function g(b,S){if(s[b].isActive===S)return Promise.resolve();e.variantChildren?.forEach(A=>A.animationState?.setActive(b,S)),s[b].isActive=S;const j=m(b);for(const A in s)s[A].protectedKeys={};return j}return{animateChanges:m,setActive:g,setAnimateFunction:p,getState:()=>s,reset:()=>{s=r4()}}}function gue(e,r){return typeof r=="string"?r!==e:Array.isArray(r)?!SF(r,e):!1}function mp(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function r4(){return{animate:mp(!0),whileInView:mp(),whileHover:mp(),whileTap:mp(),whileDrag:mp(),whileFocus:mp(),exit:mp()}}class Yd{constructor(r){this.isMounted=!1,this.node=r}update(){}}class yue extends Yd{constructor(r){super(r),r.animationState||(r.animationState=mue(r))}updateAnimationControlsSubscription(){const{animate:r}=this.node.getProps();IC(r)&&(this.unmountControls=r.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:r}=this.node.getProps(),{animate:s}=this.node.prevProps||{};r!==s&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let vue=0;class xue extends Yd{constructor(){super(...arguments),this.id=vue++}update(){if(!this.node.presenceContext)return;const{isPresent:r,onExitComplete:s}=this.node.presenceContext,{isPresent:o}=this.node.prevPresenceContext||{};if(!this.node.animationState||r===o)return;const d=this.node.animationState.setActive("exit",!r);s&&!r&&d.then(()=>{s(this.id)})}mount(){const{register:r,onExitComplete:s}=this.node.presenceContext||{};s&&s(this.id),r&&(this.unmount=r(this.id))}unmount(){}}const bue={animation:{Feature:yue},exit:{Feature:xue}};function Vb(e,r,s,o={passive:!0}){return e.addEventListener(r,s,o),()=>e.removeEventListener(r,s)}function pw(e){return{point:{x:e.pageX,y:e.pageY}}}const wue=e=>r=>T2(r)&&e(r,pw(r));function $b(e,r,s,o){return Vb(e,r,wue(s),o)}const jF=1e-4,Sue=1-jF,Eue=1+jF,CF=.01,jue=0-CF,Cue=0+CF;function Mi(e){return e.max-e.min}function Aue(e,r,s){return Math.abs(e-r)<=s}function s4(e,r,s,o=.5){e.origin=o,e.originPoint=Lr(r.min,r.max,e.origin),e.scale=Mi(s)/Mi(r),e.translate=Lr(s.min,s.max,e.origin)-e.originPoint,(e.scale>=Sue&&e.scale<=Eue||isNaN(e.scale))&&(e.scale=1),(e.translate>=jue&&e.translate<=Cue||isNaN(e.translate))&&(e.translate=0)}function Nb(e,r,s,o){s4(e.x,r.x,s.x,o?o.originX:void 0),s4(e.y,r.y,s.y,o?o.originY:void 0)}function i4(e,r,s){e.min=s.min+r.min,e.max=e.min+Mi(r)}function Oue(e,r,s){i4(e.x,r.x,s.x),i4(e.y,r.y,s.y)}function a4(e,r,s){e.min=r.min-s.min,e.max=e.min+Mi(r)}function Xj(e,r,s){a4(e.x,r.x,s.x),a4(e.y,r.y,s.y)}function to(e){return[e("x"),e("y")]}const AF=({current:e})=>e?e.ownerDocument.defaultView:null,o4=(e,r)=>Math.abs(e-r);function kue(e,r){const s=o4(e.x,r.x),o=o4(e.y,r.y);return Math.sqrt(s**2+o**2)}class OF{constructor(r,s,{transformPagePoint:o,contextWindow:d=window,dragSnapToOrigin:p=!1,distanceThreshold:m=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const k=rT(this.lastMoveEventInfo,this.history),T=this.startEvent!==null,M=kue(k.offset,{x:0,y:0})>=this.distanceThreshold;if(!T&&!M)return;const{point:I}=k,{timestamp:q}=Us;this.history.push({...I,timestamp:q});const{onStart:G,onMove:K}=this.handlers;T||(G&&G(this.lastMoveEvent,k),this.startEvent=this.lastMoveEvent),K&&K(this.lastMoveEvent,k)},this.handlePointerMove=(k,T)=>{this.lastMoveEvent=k,this.lastMoveEventInfo=nT(T,this.transformPagePoint),_r.update(this.updatePoint,!0)},this.handlePointerUp=(k,T)=>{this.end();const{onEnd:M,onSessionEnd:I,resumeAnimation:q}=this.handlers;if(this.dragSnapToOrigin&&q&&q(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const G=rT(k.type==="pointercancel"?this.lastMoveEventInfo:nT(T,this.transformPagePoint),this.history);this.startEvent&&M&&M(k,G),I&&I(k,G)},!T2(r))return;this.dragSnapToOrigin=p,this.handlers=s,this.transformPagePoint=o,this.distanceThreshold=m,this.contextWindow=d||window;const g=pw(r),b=nT(g,this.transformPagePoint),{point:S}=b,{timestamp:j}=Us;this.history=[{...S,timestamp:j}];const{onSessionStart:A}=s;A&&A(r,rT(b,this.history)),this.removeListeners=uw($b(this.contextWindow,"pointermove",this.handlePointerMove),$b(this.contextWindow,"pointerup",this.handlePointerUp),$b(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(r){this.handlers=r}end(){this.removeListeners&&this.removeListeners(),Ud(this.updatePoint)}}function nT(e,r){return r?{point:r(e.point)}:e}function l4(e,r){return{x:e.x-r.x,y:e.y-r.y}}function rT({point:e},r){return{point:e,delta:l4(e,kF(r)),offset:l4(e,Rue(r)),velocity:Tue(r,.1)}}function Rue(e){return e[0]}function kF(e){return e[e.length-1]}function Tue(e,r){if(e.length<2)return{x:0,y:0};let s=e.length-1,o=null;const d=kF(e);for(;s>=0&&(o=e[s],!(d.timestamp-o.timestamp>ic(r)));)s--;if(!o)return{x:0,y:0};const p=ro(d.timestamp-o.timestamp);if(p===0)return{x:0,y:0};const m={x:(d.x-o.x)/p,y:(d.y-o.y)/p};return m.x===1/0&&(m.x=0),m.y===1/0&&(m.y=0),m}function _ue(e,{min:r,max:s},o){return r!==void 0&&es&&(e=o?Lr(s,e,o.max):Math.min(e,s)),e}function c4(e,r,s){return{min:r!==void 0?e.min+r:void 0,max:s!==void 0?e.max+s-(e.max-e.min):void 0}}function $ue(e,{top:r,left:s,bottom:o,right:d}){return{x:c4(e.x,s,d),y:c4(e.y,r,o)}}function u4(e,r){let s=r.min-e.min,o=r.max-e.max;return r.max-r.mino?s=qb(r.min,r.max-o,e.min):o>d&&(s=qb(e.min,e.max-d,r.min)),gu(0,1,s)}function Pue(e,r){const s={};return r.min!==void 0&&(s.min=r.min-e.min),r.max!==void 0&&(s.max=r.max-e.min),s}const c_=.35;function Mue(e=c_){return e===!1?e=0:e===!0&&(e=c_),{x:d4(e,"left","right"),y:d4(e,"top","bottom")}}function d4(e,r,s){return{min:h4(e,r),max:h4(e,s)}}function h4(e,r){return typeof e=="number"?e:e[r]||0}const Iue=new WeakMap;class Lue{constructor(r){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=js(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=r}start(r,{snapToCursor:s=!1,distanceThreshold:o}={}){const{presenceContext:d}=this.visualElement;if(d&&d.isPresent===!1)return;const p=A=>{const{dragSnapToOrigin:k}=this.getProps();k?this.pauseAnimation():this.stopAnimation(),s&&this.snapToCursor(pw(A).point)},m=(A,k)=>{const{drag:T,dragPropagation:M,onDragStart:I}=this.getProps();if(T&&!M&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Yle(T),!this.openDragLock))return;this.latestPointerEvent=A,this.latestPanInfo=k,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),to(G=>{let K=this.getAxisMotionValue(G).get()||0;if(ac.test(K)){const{projection:X}=this.visualElement;if(X&&X.layout){const L=X.layout.layoutBox[G];L&&(K=Mi(L)*(parseFloat(K)/100))}}this.originPoint[G]=K}),I&&_r.postRender(()=>I(A,k)),o_(this.visualElement,"transform");const{animationState:q}=this.visualElement;q&&q.setActive("whileDrag",!0)},g=(A,k)=>{this.latestPointerEvent=A,this.latestPanInfo=k;const{dragPropagation:T,dragDirectionLock:M,onDirectionLock:I,onDrag:q}=this.getProps();if(!T&&!this.openDragLock)return;const{offset:G}=k;if(M&&this.currentDirection===null){this.currentDirection=zue(G),this.currentDirection!==null&&I&&I(this.currentDirection);return}this.updateAxis("x",k.point,G),this.updateAxis("y",k.point,G),this.visualElement.render(),q&&q(A,k)},b=(A,k)=>{this.latestPointerEvent=A,this.latestPanInfo=k,this.stop(A,k),this.latestPointerEvent=null,this.latestPanInfo=null},S=()=>to(A=>this.getAnimationState(A)==="paused"&&this.getAxisMotionValue(A).animation?.play()),{dragSnapToOrigin:j}=this.getProps();this.panSession=new OF(r,{onSessionStart:p,onStart:m,onMove:g,onSessionEnd:b,resumeAnimation:S},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:j,distanceThreshold:o,contextWindow:AF(this.visualElement)})}stop(r,s){const o=r||this.latestPointerEvent,d=s||this.latestPanInfo,p=this.isDragging;if(this.cancel(),!p||!d||!o)return;const{velocity:m}=d;this.startAnimation(m);const{onDragEnd:g}=this.getProps();g&&_r.postRender(()=>g(o,d))}cancel(){this.isDragging=!1;const{projection:r,animationState:s}=this.visualElement;r&&(r.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:o}=this.getProps();!o&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),s&&s.setActive("whileDrag",!1)}updateAxis(r,s,o){const{drag:d}=this.getProps();if(!o||!QE(r,d,this.currentDirection))return;const p=this.getAxisMotionValue(r);let m=this.originPoint[r]+o[r];this.constraints&&this.constraints[r]&&(m=_ue(m,this.constraints[r],this.elastic[r])),p.set(m)}resolveConstraints(){const{dragConstraints:r,dragElastic:s}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,d=this.constraints;r&&ag(r)?this.constraints||(this.constraints=this.resolveRefConstraints()):r&&o?this.constraints=$ue(o.layoutBox,r):this.constraints=!1,this.elastic=Mue(s),d!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&to(p=>{this.constraints!==!1&&this.getAxisMotionValue(p)&&(this.constraints[p]=Pue(o.layoutBox[p],this.constraints[p]))})}resolveRefConstraints(){const{dragConstraints:r,onMeasureDragConstraints:s}=this.getProps();if(!r||!ag(r))return!1;const o=r.current,{projection:d}=this.visualElement;if(!d||!d.layout)return!1;const p=Fce(o,d.root,this.visualElement.getTransformPagePoint());let m=Nue(d.layout.layoutBox,p);if(s){const g=s(Ice(m));this.hasMutatedConstraints=!!g,g&&(m=dF(g))}return m}startAnimation(r){const{drag:s,dragMomentum:o,dragElastic:d,dragTransition:p,dragSnapToOrigin:m,onDragTransitionEnd:g}=this.getProps(),b=this.constraints||{},S=to(j=>{if(!QE(j,s,this.currentDirection))return;let A=b&&b[j]||{};m&&(A={min:0,max:0});const k=d?200:1e6,T=d?40:1e7,M={type:"inertia",velocity:o?r[j]:0,bounceStiffness:k,bounceDamping:T,timeConstant:750,restDelta:1,restSpeed:10,...p,...A};return this.startAxisValueAnimation(j,M)});return Promise.all(S).then(g)}startAxisValueAnimation(r,s){const o=this.getAxisMotionValue(r);return o_(this.visualElement,r),o.start(z2(r,o,0,s,this.visualElement,!1))}stopAnimation(){to(r=>this.getAxisMotionValue(r).stop())}pauseAnimation(){to(r=>this.getAxisMotionValue(r).animation?.pause())}getAnimationState(r){return this.getAxisMotionValue(r).animation?.state}getAxisMotionValue(r){const s=`_drag${r.toUpperCase()}`,o=this.visualElement.getProps(),d=o[s];return d||this.visualElement.getValue(r,(o.initial?o.initial[r]:void 0)||0)}snapToCursor(r){to(s=>{const{drag:o}=this.getProps();if(!QE(s,o,this.currentDirection))return;const{projection:d}=this.visualElement,p=this.getAxisMotionValue(s);if(d&&d.layout){const{min:m,max:g}=d.layout.layoutBox[s];p.set(r[s]-Lr(m,g,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:r,dragConstraints:s}=this.getProps(),{projection:o}=this.visualElement;if(!ag(s)||!o||!this.constraints)return;this.stopAnimation();const d={x:0,y:0};to(m=>{const g=this.getAxisMotionValue(m);if(g&&this.constraints!==!1){const b=g.get();d[m]=Due({min:b,max:b},this.constraints[m])}});const{transformTemplate:p}=this.visualElement.getProps();this.visualElement.current.style.transform=p?p({},""):"none",o.root&&o.root.updateScroll(),o.updateLayout(),this.resolveConstraints(),to(m=>{if(!QE(m,r,null))return;const g=this.getAxisMotionValue(m),{min:b,max:S}=this.constraints[m];g.set(Lr(b,S,d[m]))})}addListeners(){if(!this.visualElement.current)return;Iue.set(this.visualElement,this);const r=this.visualElement.current,s=$b(r,"pointerdown",b=>{const{drag:S,dragListener:j=!0}=this.getProps();S&&j&&this.start(b)}),o=()=>{const{dragConstraints:b}=this.getProps();ag(b)&&b.current&&(this.constraints=this.resolveRefConstraints())},{projection:d}=this.visualElement,p=d.addEventListener("measure",o);d&&!d.layout&&(d.root&&d.root.updateScroll(),d.updateLayout()),_r.read(o);const m=Vb(window,"resize",()=>this.scalePositionWithinConstraints()),g=d.addEventListener("didUpdate",(({delta:b,hasLayoutChanged:S})=>{this.isDragging&&S&&(to(j=>{const A=this.getAxisMotionValue(j);A&&(this.originPoint[j]+=b[j].translate,A.set(A.get()+b[j].translate))}),this.visualElement.render())}));return()=>{m(),s(),p(),g&&g()}}getProps(){const r=this.visualElement.getProps(),{drag:s=!1,dragDirectionLock:o=!1,dragPropagation:d=!1,dragConstraints:p=!1,dragElastic:m=c_,dragMomentum:g=!0}=r;return{...r,drag:s,dragDirectionLock:o,dragPropagation:d,dragConstraints:p,dragElastic:m,dragMomentum:g}}}function QE(e,r,s){return(r===!0||r===e)&&(s===null||s===e)}function zue(e,r=10){let s=null;return Math.abs(e.y)>r?s="y":Math.abs(e.x)>r&&(s="x"),s}class Fue extends Yd{constructor(r){super(r),this.removeGroupControls=so,this.removeListeners=so,this.controls=new Lue(r)}mount(){const{dragControls:r}=this.node.getProps();r&&(this.removeGroupControls=r.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||so}unmount(){this.removeGroupControls(),this.removeListeners()}}const p4=e=>(r,s)=>{e&&_r.postRender(()=>e(r,s))};class que extends Yd{constructor(){super(...arguments),this.removePointerDownListener=so}onPointerDown(r){this.session=new OF(r,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:AF(this.node)})}createPanHandlers(){const{onPanSessionStart:r,onPanStart:s,onPan:o,onPanEnd:d}=this.node.getProps();return{onSessionStart:p4(r),onStart:p4(s),onMove:o,onEnd:(p,m)=>{delete this.session,d&&_r.postRender(()=>d(p,m))}}}mount(){this.removePointerDownListener=$b(this.node.current,"pointerdown",r=>this.onPointerDown(r))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const wj={hasAnimatedSinceResize:!0,hasEverUpdated:!1};let sT=!1;class Bue extends R.Component{componentDidMount(){const{visualElement:r,layoutGroup:s,switchLayoutGroup:o,layoutId:d}=this.props,{projection:p}=r;p&&(s.group&&s.group.add(p),o&&o.register&&d&&o.register(p),sT&&p.root.didUpdate(),p.addEventListener("animationComplete",()=>{this.safeToRemove()}),p.setOptions({...p.options,onExitComplete:()=>this.safeToRemove()})),wj.hasEverUpdated=!0}getSnapshotBeforeUpdate(r){const{layoutDependency:s,visualElement:o,drag:d,isPresent:p}=this.props,{projection:m}=o;return m&&(m.isPresent=p,sT=!0,d||r.layoutDependency!==s||s===void 0||r.isPresent!==p?m.willUpdate():this.safeToRemove(),r.isPresent!==p&&(p?m.promote():m.relegate()||_r.postRender(()=>{const g=m.getStack();(!g||!g.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:r}=this.props.visualElement;r&&(r.root.didUpdate(),R2.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:r,layoutGroup:s,switchLayoutGroup:o}=this.props,{projection:d}=r;sT=!0,d&&(d.scheduleCheckAfterUnmount(),s&&s.group&&s.group.remove(d),o&&o.deregister&&o.deregister(d))}safeToRemove(){const{safeToRemove:r}=this.props;r&&r()}render(){return null}}function RF(e){const[r,s]=sce(),o=R.useContext(a5);return u.jsx(Bue,{...e,layoutGroup:o,switchLayoutGroup:R.useContext(cF),isPresent:r,safeToRemove:s})}function Uue(e,r,s){const o=bi(e)?e:wg(e);return o.start(z2("",o,r,s)),o.animation}const Kue=(e,r)=>e.depth-r.depth;class Vue{constructor(){this.children=[],this.isDirty=!1}add(r){d2(this.children,r),this.isDirty=!0}remove(r){h2(this.children,r),this.isDirty=!0}forEach(r){this.isDirty&&this.children.sort(Kue),this.isDirty=!1,this.children.forEach(r)}}function Hue(e,r){const s=da.now(),o=({timestamp:d})=>{const p=d-s;p>=r&&(Ud(o),e(p-r))};return _r.setup(o,!0),()=>Ud(o)}const TF=["TopLeft","TopRight","BottomLeft","BottomRight"],Gue=TF.length,f4=e=>typeof e=="string"?parseFloat(e):e,m4=e=>typeof e=="number"||tn.test(e);function Xue(e,r,s,o,d,p){d?(e.opacity=Lr(0,s.opacity??1,Yue(o)),e.opacityExit=Lr(r.opacity??1,0,Zue(o))):p&&(e.opacity=Lr(r.opacity??1,s.opacity??1,o));for(let m=0;mor?1:s(qb(e,r,o))}function y4(e,r){e.min=r.min,e.max=r.max}function Ho(e,r){y4(e.x,r.x),y4(e.y,r.y)}function v4(e,r){e.translate=r.translate,e.scale=r.scale,e.originPoint=r.originPoint,e.origin=r.origin}function x4(e,r,s,o,d){return e-=r,e=Gj(e,1/s,o),d!==void 0&&(e=Gj(e,1/d,o)),e}function Wue(e,r=0,s=1,o=.5,d,p=e,m=e){if(ac.test(r)&&(r=parseFloat(r),r=Lr(m.min,m.max,r/100)-m.min),typeof r!="number")return;let g=Lr(p.min,p.max,o);e===p&&(g-=r),e.min=x4(e.min,r,s,g,d),e.max=x4(e.max,r,s,g,d)}function b4(e,r,[s,o,d],p,m){Wue(e,r[s],r[o],r[d],r.scale,p,m)}const Jue=["x","scaleX","originX"],Que=["y","scaleY","originY"];function w4(e,r,s,o){b4(e.x,r,Jue,s?s.x:void 0,o?o.x:void 0),b4(e.y,r,Que,s?s.y:void 0,o?o.y:void 0)}function S4(e){return e.translate===0&&e.scale===1}function $F(e){return S4(e.x)&&S4(e.y)}function E4(e,r){return e.min===r.min&&e.max===r.max}function ede(e,r){return E4(e.x,r.x)&&E4(e.y,r.y)}function j4(e,r){return Math.round(e.min)===Math.round(r.min)&&Math.round(e.max)===Math.round(r.max)}function NF(e,r){return j4(e.x,r.x)&&j4(e.y,r.y)}function C4(e){return Mi(e.x)/Mi(e.y)}function A4(e,r){return e.translate===r.translate&&e.scale===r.scale&&e.originPoint===r.originPoint}class tde{constructor(){this.members=[]}add(r){d2(this.members,r),r.scheduleRender()}remove(r){if(h2(this.members,r),r===this.prevLead&&(this.prevLead=void 0),r===this.lead){const s=this.members[this.members.length-1];s&&this.promote(s)}}relegate(r){const s=this.members.findIndex(d=>r===d);if(s===0)return!1;let o;for(let d=s;d>=0;d--){const p=this.members[d];if(p.isPresent!==!1){o=p;break}}return o?(this.promote(o),!0):!1}promote(r,s){const o=this.lead;if(r!==o&&(this.prevLead=o,this.lead=r,r.show(),o)){o.instance&&o.scheduleRender(),r.scheduleRender(),r.resumeFrom=o,s&&(r.resumeFrom.preserveOpacity=!0),o.snapshot&&(r.snapshot=o.snapshot,r.snapshot.latestValues=o.animationValues||o.latestValues),r.root&&r.root.isUpdating&&(r.isLayoutDirty=!0);const{crossfade:d}=r.options;d===!1&&o.hide()}}exitAnimationComplete(){this.members.forEach(r=>{const{options:s,resumingFrom:o}=r;s.onExitComplete&&s.onExitComplete(),o&&o.options.onExitComplete&&o.options.onExitComplete()})}scheduleRender(){this.members.forEach(r=>{r.instance&&r.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function nde(e,r,s){let o="";const d=e.x.translate/r.x,p=e.y.translate/r.y,m=s?.z||0;if((d||p||m)&&(o=`translate3d(${d}px, ${p}px, ${m}px) `),(r.x!==1||r.y!==1)&&(o+=`scale(${1/r.x}, ${1/r.y}) `),s){const{transformPerspective:S,rotate:j,rotateX:A,rotateY:k,skewX:T,skewY:M}=s;S&&(o=`perspective(${S}px) ${o}`),j&&(o+=`rotate(${j}deg) `),A&&(o+=`rotateX(${A}deg) `),k&&(o+=`rotateY(${k}deg) `),T&&(o+=`skewX(${T}deg) `),M&&(o+=`skewY(${M}deg) `)}const g=e.x.scale*r.x,b=e.y.scale*r.y;return(g!==1||b!==1)&&(o+=`scale(${g}, ${b})`),o||"none"}const iT=["","X","Y","Z"],rde=1e3;let sde=0;function aT(e,r,s,o){const{latestValues:d}=r;d[e]&&(s[e]=d[e],r.setStaticValue(e,0),o&&(o[e]=0))}function DF(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:r}=e.options;if(!r)return;const s=xF(r);if(window.MotionHasOptimisedAnimation(s,"transform")){const{layout:d,layoutId:p}=e.options;window.MotionCancelOptimisedAnimation(s,"transform",_r,!(d||p))}const{parent:o}=e;o&&!o.hasCheckedOptimisedAppear&&DF(o)}function PF({attachResizeListener:e,defaultParent:r,measureScroll:s,checkIsScrollRoot:o,resetTransform:d}){return class{constructor(m={},g=r?.()){this.id=sde++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(ode),this.nodes.forEach(dde),this.nodes.forEach(hde),this.nodes.forEach(lde)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=m,this.root=g?g.root||g:this,this.path=g?[...g.path,g]:[],this.parent=g,this.depth=g?g.depth+1:0;for(let b=0;bthis.root.updateBlockedByResize=!1;_r.read(()=>{A=window.innerWidth}),e(m,()=>{const T=window.innerWidth;T!==A&&(A=T,this.root.updateBlockedByResize=!0,j&&j(),j=Hue(k,250),wj.hasAnimatedSinceResize&&(wj.hasAnimatedSinceResize=!1,this.nodes.forEach(R4)))})}g&&this.root.registerSharedNode(g,this),this.options.animate!==!1&&S&&(g||b)&&this.addEventListener("didUpdate",({delta:j,hasLayoutChanged:A,hasRelativeLayoutChanged:k,layout:T})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const M=this.options.transition||S.getDefaultTransition()||yde,{onLayoutAnimationStart:I,onLayoutAnimationComplete:q}=S.getProps(),G=!this.targetLayout||!NF(this.targetLayout,T),K=!A&&k;if(this.options.layoutRoot||this.resumeFrom||K||A&&(G||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const X={...O2(M,"layout"),onPlay:I,onComplete:q};(S.shouldReduceMotion||this.options.layoutRoot)&&(X.delay=0,X.type=!1),this.startAnimation(X),this.setAnimationOrigin(j,K)}else A||R4(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=T})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const m=this.getStack();m&&m.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Ud(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(pde),this.animationId++)}getTransformTemplate(){const{visualElement:m}=this.options;return m&&m.getProps().transformTemplate}willUpdate(m=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&DF(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let j=0;j{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Mi(this.snapshot.measuredBox.x)&&!Mi(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let b=0;b{const ee=L/1e3;T4(A.x,m.x,ee),T4(A.y,m.y,ee),this.setTargetDelta(A),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Xj(k,this.layout.layoutBox,this.relativeParent.layout.layoutBox),mde(this.relativeTarget,this.relativeTargetOrigin,k,ee),X&&ede(this.relativeTarget,X)&&(this.isProjectionDirty=!1),X||(X=js()),Ho(X,this.relativeTarget)),I&&(this.animationValues=j,Xue(j,S,this.latestValues,ee,K,G)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=ee},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(m){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(Ud(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=_r.update(()=>{wj.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=wg(0)),this.currentAnimation=Uue(this.motionValue,[0,1e3],{...m,velocity:0,isSync:!0,onUpdate:g=>{this.mixTargetDelta(g),m.onUpdate&&m.onUpdate(g)},onStop:()=>{},onComplete:()=>{m.onComplete&&m.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const m=this.getStack();m&&m.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(rde),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const m=this.getLead();let{targetWithTransforms:g,target:b,layout:S,latestValues:j}=m;if(!(!g||!b||!S)){if(this!==m&&this.layout&&S&&MF(this.options.animationType,this.layout.layoutBox,S.layoutBox)){b=this.target||js();const A=Mi(this.layout.layoutBox.x);b.x.min=m.target.x.min,b.x.max=b.x.min+A;const k=Mi(this.layout.layoutBox.y);b.y.min=m.target.y.min,b.y.max=b.y.min+k}Ho(g,b),lg(g,j),Nb(this.projectionDeltaWithTransform,this.layoutCorrected,g,j)}}registerSharedNode(m,g){this.sharedNodes.has(m)||this.sharedNodes.set(m,new tde),this.sharedNodes.get(m).add(g);const S=g.options.initialPromotionConfig;g.promote({transition:S?S.transition:void 0,preserveFollowOpacity:S&&S.shouldPreserveFollowOpacity?S.shouldPreserveFollowOpacity(g):void 0})}isLead(){const m=this.getStack();return m?m.lead===this:!0}getLead(){const{layoutId:m}=this.options;return m?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:m}=this.options;return m?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:m}=this.options;if(m)return this.root.sharedNodes.get(m)}promote({needsReset:m,transition:g,preserveFollowOpacity:b}={}){const S=this.getStack();S&&S.promote(this,b),m&&(this.projectionDelta=void 0,this.needsReset=!0),g&&this.setOptions({transition:g})}relegate(){const m=this.getStack();return m?m.relegate(this):!1}resetSkewAndRotation(){const{visualElement:m}=this.options;if(!m)return;let g=!1;const{latestValues:b}=m;if((b.z||b.rotate||b.rotateX||b.rotateY||b.rotateZ||b.skewX||b.skewY)&&(g=!0),!g)return;const S={};b.z&&aT("z",m,S,this.animationValues);for(let j=0;jm.currentAnimation?.stop()),this.root.nodes.forEach(O4),this.root.sharedNodes.clear()}}}function ide(e){e.updateLayout()}function ade(e){const r=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&r&&e.hasListeners("didUpdate")){const{layoutBox:s,measuredBox:o}=e.layout,{animationType:d}=e.options,p=r.source!==e.layout.source;d==="size"?to(j=>{const A=p?r.measuredBox[j]:r.layoutBox[j],k=Mi(A);A.min=s[j].min,A.max=A.min+k}):MF(d,r.layoutBox,s)&&to(j=>{const A=p?r.measuredBox[j]:r.layoutBox[j],k=Mi(s[j]);A.max=A.min+k,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[j].max=e.relativeTarget[j].min+k)});const m=cg();Nb(m,s,r.layoutBox);const g=cg();p?Nb(g,e.applyTransform(o,!0),r.measuredBox):Nb(g,s,r.layoutBox);const b=!$F(m);let S=!1;if(!e.resumeFrom){const j=e.getClosestProjectingParent();if(j&&!j.resumeFrom){const{snapshot:A,layout:k}=j;if(A&&k){const T=js();Xj(T,r.layoutBox,A.layoutBox);const M=js();Xj(M,s,k.layoutBox),NF(T,M)||(S=!0),j.options.layoutRoot&&(e.relativeTarget=M,e.relativeTargetOrigin=T,e.relativeParent=j)}}}e.notifyListeners("didUpdate",{layout:s,snapshot:r,delta:g,layoutDelta:m,hasLayoutChanged:b,hasRelativeLayoutChanged:S})}else if(e.isLead()){const{onExitComplete:s}=e.options;s&&s()}e.options.transition=void 0}function ode(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function lde(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function cde(e){e.clearSnapshot()}function O4(e){e.clearMeasurements()}function k4(e){e.isLayoutDirty=!1}function ude(e){const{visualElement:r}=e.options;r&&r.getProps().onBeforeLayoutMeasure&&r.notify("BeforeLayoutMeasure"),e.resetTransform()}function R4(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function dde(e){e.resolveTargetDelta()}function hde(e){e.calcProjection()}function pde(e){e.resetSkewAndRotation()}function fde(e){e.removeLeadSnapshot()}function T4(e,r,s){e.translate=Lr(r.translate,0,s),e.scale=Lr(r.scale,1,s),e.origin=r.origin,e.originPoint=r.originPoint}function _4(e,r,s,o){e.min=Lr(r.min,s.min,o),e.max=Lr(r.max,s.max,o)}function mde(e,r,s,o){_4(e.x,r.x,s.x,o),_4(e.y,r.y,s.y,o)}function gde(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const yde={duration:.45,ease:[.4,0,.1,1]},$4=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),N4=$4("applewebkit/")&&!$4("chrome/")?Math.round:so;function D4(e){e.min=N4(e.min),e.max=N4(e.max)}function vde(e){D4(e.x),D4(e.y)}function MF(e,r,s){return e==="position"||e==="preserve-aspect"&&!Aue(C4(r),C4(s),.2)}function xde(e){return e!==e.root&&e.scroll?.wasRoot}const bde=PF({attachResizeListener:(e,r)=>Vb(e,"resize",r),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),oT={current:void 0},IF=PF({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!oT.current){const e=new bde({});e.mount(window),e.setOptions({layoutScroll:!0}),oT.current=e}return oT.current},resetTransform:(e,r)=>{e.style.transform=r!==void 0?r:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),wde={pan:{Feature:que},drag:{Feature:Fue,ProjectionNode:IF,MeasureLayout:RF}};function P4(e,r,s){const{props:o}=e;e.animationState&&o.whileHover&&e.animationState.setActive("whileHover",s==="Start");const d="onHover"+s,p=o[d];p&&_r.postRender(()=>p(r,pw(r)))}class Sde extends Yd{mount(){const{current:r}=this.node;r&&(this.unmount=Zle(r,(s,o)=>(P4(this.node,o,"Start"),d=>P4(this.node,d,"End"))))}unmount(){}}class Ede extends Yd{constructor(){super(...arguments),this.isActive=!1}onFocus(){let r=!1;try{r=this.node.current.matches(":focus-visible")}catch{r=!0}!r||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=uw(Vb(this.node.current,"focus",()=>this.onFocus()),Vb(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function M4(e,r,s){const{props:o}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&o.whileTap&&e.animationState.setActive("whileTap",s==="Start");const d="onTap"+(s==="End"?"":s),p=o[d];p&&_r.postRender(()=>p(r,pw(r)))}class jde extends Yd{mount(){const{current:r}=this.node;r&&(this.unmount=ece(r,(s,o)=>(M4(this.node,o,"Start"),(d,{success:p})=>M4(this.node,d,p?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const u_=new WeakMap,lT=new WeakMap,Cde=e=>{const r=u_.get(e.target);r&&r(e)},Ade=e=>{e.forEach(Cde)};function Ode({root:e,...r}){const s=e||document;lT.has(s)||lT.set(s,{});const o=lT.get(s),d=JSON.stringify(r);return o[d]||(o[d]=new IntersectionObserver(Ade,{root:e,...r})),o[d]}function kde(e,r,s){const o=Ode(r);return u_.set(e,s),o.observe(e),()=>{u_.delete(e),o.unobserve(e)}}const Rde={some:0,all:1};class Tde extends Yd{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:r={}}=this.node.getProps(),{root:s,margin:o,amount:d="some",once:p}=r,m={root:s?s.current:void 0,rootMargin:o,threshold:typeof d=="number"?d:Rde[d]},g=b=>{const{isIntersecting:S}=b;if(this.isInView===S||(this.isInView=S,p&&!S&&this.hasEnteredView))return;S&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",S);const{onViewportEnter:j,onViewportLeave:A}=this.node.getProps(),k=S?j:A;k&&k(b)};return kde(this.node.current,m,g)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:r,prevProps:s}=this.node;["amount","margin","root"].some(_de(r,s))&&this.startObserver()}unmount(){}}function _de({viewport:e={}},{viewport:r={}}={}){return s=>e[s]!==r[s]}const $de={inView:{Feature:Tde},tap:{Feature:jde},focus:{Feature:Ede},hover:{Feature:Sde}},Nde={layout:{ProjectionNode:IF,MeasureLayout:RF}},Dde={...bue,...$de,...wde,...Nde},Pde=Mce(Dde,Yce),Mde=[{id:"light",icon:jW,label:"Light"},{id:"dark",icon:lW,label:"Dark"},{id:"system",icon:aW,label:"System"}],LF=({className:e="",variant:r="pill",ariaLabel:s="Toggle theme"})=>{const{theme:o,setTheme:d}=N_(),p=o??"system",m=r==="pill";return u.jsx("div",{className:ft("inline-flex items-center",m&&"bg-muted/70 rounded-full p-1 text-xs shadow-sm",!m&&"gap-2",e),"aria-label":s,role:"radiogroup",children:Mde.map(({id:g,icon:b,label:S})=>{const j=p===g;return u.jsxs("button",{type:"button",role:"radio","aria-checked":j,onClick:()=>d(g),"aria-label":m?S:void 0,className:ft("focus-visible:ring-ring focus-visible:ring-offset-background relative flex items-center justify-center rounded-full transition-colors focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none",j?"text-foreground border":"text-muted-foreground hover:text-foreground",m&&"h-8 w-8",!m&&"h-8 gap-2 px-3 text-sm font-medium"),children:[j&&u.jsx(Pde.span,{layoutId:"theme-switcher-pill",className:"bg-background absolute inset-0 rounded-full shadow-sm",transition:{type:"spring",stiffness:350,damping:26}}),u.jsx(b,{className:"relative z-10 h-4 w-4"}),!m&&u.jsx("span",{className:"relative z-10",children:S})]},g)})})};function Ide(){return rr({queryKey:["me"],queryFn:()=>yp.getMe(),staleTime:300*1e3})}function Lde(e,r=[]){let s=[];function o(p,m){const g=R.createContext(m);g.displayName=p+"Context";const b=s.length;s=[...s,m];const S=A=>{const{scope:k,children:T,...M}=A,I=k?.[e]?.[b]||g,q=R.useMemo(()=>M,Object.values(M));return u.jsx(I.Provider,{value:q,children:T})};S.displayName=p+"Provider";function j(A,k){const T=k?.[e]?.[b]||g,M=R.useContext(T);if(M)return M;if(m!==void 0)return m;throw new Error(`\`${A}\` must be used within \`${p}\``)}return[S,j]}const d=()=>{const p=s.map(m=>R.createContext(m));return function(g){const b=g?.[e]||p;return R.useMemo(()=>({[`__scope${e}`]:{...g,[e]:b}}),[g,b])}};return d.scopeName=e,[o,zde(d,...r)]}function zde(...e){const r=e[0];if(e.length===1)return r;const s=()=>{const o=e.map(d=>({useScope:d(),scopeName:d.scopeName}));return function(p){const m=o.reduce((g,{useScope:b,scopeName:S})=>{const A=b(p)[`__scope${S}`];return{...g,...A}},{});return R.useMemo(()=>({[`__scope${r.scopeName}`]:m}),[m])}};return s.scopeName=r.scopeName,s}var Fde=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],F2=Fde.reduce((e,r)=>{const s=Qb(`Primitive.${r}`),o=R.forwardRef((d,p)=>{const{asChild:m,...g}=d,b=m?s:r;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(b,{...g,ref:p})});return o.displayName=`Primitive.${r}`,{...e,[r]:o}},{}),cT={exports:{}},uT={};var I4;function qde(){if(I4)return uT;I4=1;var e=U3();function r(A,k){return A===k&&(A!==0||1/A===1/k)||A!==A&&k!==k}var s=typeof Object.is=="function"?Object.is:r,o=e.useState,d=e.useEffect,p=e.useLayoutEffect,m=e.useDebugValue;function g(A,k){var T=k(),M=o({inst:{value:T,getSnapshot:k}}),I=M[0].inst,q=M[1];return p(function(){I.value=T,I.getSnapshot=k,b(I)&&q({inst:I})},[A,T,k]),d(function(){return b(I)&&q({inst:I}),A(function(){b(I)&&q({inst:I})})},[A]),m(T),T}function b(A){var k=A.getSnapshot;A=A.value;try{var T=k();return!s(A,T)}catch{return!0}}function S(A,k){return k()}var j=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?S:g;return uT.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:j,uT}var L4;function Bde(){return L4||(L4=1,cT.exports=qde()),cT.exports}var Ude=Bde();function Kde(){return Ude.useSyncExternalStore(Vde,()=>!0,()=>!1)}function Vde(){return()=>{}}var q2="Avatar",[Hde]=Lde(q2),[Gde,zF]=Hde(q2),FF=R.forwardRef((e,r)=>{const{__scopeAvatar:s,...o}=e,[d,p]=R.useState("idle");return u.jsx(Gde,{scope:s,imageLoadingStatus:d,onImageLoadingStatusChange:p,children:u.jsx(F2.span,{...o,ref:r})})});FF.displayName=q2;var qF="AvatarImage",Xde=R.forwardRef((e,r)=>{const{__scopeAvatar:s,src:o,onLoadingStatusChange:d=()=>{},...p}=e,m=zF(qF,s),g=Yde(o,p),b=tl(S=>{d(S),m.onImageLoadingStatusChange(S)});return As(()=>{g!=="idle"&&b(g)},[g,b]),g==="loaded"?u.jsx(F2.img,{...p,ref:r,src:o}):null});Xde.displayName=qF;var BF="AvatarFallback",UF=R.forwardRef((e,r)=>{const{__scopeAvatar:s,delayMs:o,...d}=e,p=zF(BF,s),[m,g]=R.useState(o===void 0);return R.useEffect(()=>{if(o!==void 0){const b=window.setTimeout(()=>g(!0),o);return()=>window.clearTimeout(b)}},[o]),m&&p.imageLoadingStatus!=="loaded"?u.jsx(F2.span,{...d,ref:r}):null});UF.displayName=BF;function z4(e,r){return e?r?(e.src!==r&&(e.src=r),e.complete&&e.naturalWidth>0?"loaded":"loading"):"error":"idle"}function Yde(e,{referrerPolicy:r,crossOrigin:s}){const o=Kde(),d=R.useRef(null),p=o?(d.current||(d.current=new window.Image),d.current):null,[m,g]=R.useState(()=>z4(p,e));return As(()=>{g(z4(p,e))},[p,e]),As(()=>{const b=A=>()=>{g(A)};if(!p)return;const S=b("loaded"),j=b("error");return p.addEventListener("load",S),p.addEventListener("error",j),r&&(p.referrerPolicy=r),typeof s=="string"&&(p.crossOrigin=s),()=>{p.removeEventListener("load",S),p.removeEventListener("error",j)}},[p,s,r]),m}var Zde=FF,Wde=UF;function Jde({className:e,...r}){return u.jsx(Zde,{"data-slot":"avatar",className:ft("relative flex size-8 shrink-0 overflow-hidden rounded-full",e),...r})}function Qde({className:e,...r}){return u.jsx(Wde,{"data-slot":"avatar-fallback",className:ft("bg-muted flex size-full items-center justify-center rounded-full",e),...r})}function ehe({...e}){return u.jsx("nav",{"aria-label":"breadcrumb","data-slot":"breadcrumb",...e})}function the({className:e,...r}){return u.jsx("ol",{"data-slot":"breadcrumb-list",className:ft("text-muted-foreground flex flex-wrap items-center gap-1.5 text-sm break-words sm:gap-2.5",e),...r})}function F4({className:e,...r}){return u.jsx("li",{"data-slot":"breadcrumb-item",className:ft("inline-flex items-center gap-1.5",e),...r})}function q4({asChild:e,className:r,...s}){const o=e?Cg:"a";return u.jsx(o,{"data-slot":"breadcrumb-link",className:ft("hover:text-foreground transition-colors",r),...s})}function nhe({className:e,...r}){return u.jsx("span",{"data-slot":"breadcrumb-page",role:"link","aria-disabled":"true","aria-current":"page",className:ft("text-foreground font-normal",e),...r})}function rhe({children:e,className:r,...s}){return u.jsx("li",{"data-slot":"breadcrumb-separator",role:"presentation","aria-hidden":"true",className:ft("[&>svg]:size-3.5",r),...s,children:e??u.jsx(SZ,{})})}const dT=768;function she(){const[e,r]=R.useState(void 0);return R.useEffect(()=>{const s=window.matchMedia(`(max-width: ${dT-1}px)`),o=()=>{r(window.innerWidths.removeEventListener("change",o)},[]),!!e}function gt({className:e,type:r,...s}){return u.jsx("input",{type:r,"data-slot":"input",className:ft("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm","focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]","aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",e),...s})}function ihe({...e}){return u.jsx(TC,{"data-slot":"sheet",...e})}function ahe({...e}){return u.jsx(_C,{"data-slot":"sheet-portal",...e})}function ohe({className:e,...r}){return u.jsx($C,{"data-slot":"sheet-overlay",className:ft("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",e),...r})}function lhe({className:e,children:r,side:s="right",...o}){return u.jsxs(ahe,{children:[u.jsx(ohe,{}),u.jsxs(NC,{"data-slot":"sheet-content",className:ft("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500",s==="right"&&"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",s==="left"&&"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",s==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",s==="bottom"&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",e),...o,children:[r,u.jsxs(ow,{className:"ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none",children:[u.jsx(q_,{className:"size-4"}),u.jsx("span",{className:"sr-only",children:"Close"})]})]})]})}function che({className:e,...r}){return u.jsx("div",{"data-slot":"sheet-header",className:ft("flex flex-col gap-1.5 p-4",e),...r})}function uhe({className:e,...r}){return u.jsx(i2,{"data-slot":"sheet-title",className:ft("text-foreground font-semibold",e),...r})}function dhe({className:e,...r}){return u.jsx(a2,{"data-slot":"sheet-description",className:ft("text-muted-foreground text-sm",e),...r})}const hhe="sidebar_state",phe=3600*24*7,fhe="16rem",mhe="18rem",ghe="3rem",yhe="b",KF=R.createContext(null);function B2(){const e=R.useContext(KF);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}function vhe({defaultOpen:e=!0,open:r,onOpenChange:s,className:o,style:d,children:p,...m}){const g=she(),[b,S]=R.useState(!1),[j,A]=R.useState(e),k=r??j,T=R.useCallback(G=>{const K=typeof G=="function"?G(k):G;s?s(K):A(K),document.cookie=`${hhe}=${K}; path=/; max-age=${phe}`},[s,k]),M=R.useCallback(()=>g?S(G=>!G):T(G=>!G),[g,T,S]);R.useEffect(()=>{const G=K=>{K.key===yhe&&(K.metaKey||K.ctrlKey)&&(K.preventDefault(),M())};return window.addEventListener("keydown",G),()=>window.removeEventListener("keydown",G)},[M]);const I=k?"expanded":"collapsed",q=R.useMemo(()=>({state:I,open:k,setOpen:T,isMobile:g,openMobile:b,setOpenMobile:S,toggleSidebar:M}),[I,k,T,g,b,S,M]);return u.jsx(KF.Provider,{value:q,children:u.jsx(rw,{delayDuration:0,children:u.jsx("div",{"data-slot":"sidebar-wrapper",style:{"--sidebar-width":fhe,"--sidebar-width-icon":ghe,...d},className:ft("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full",o),...m,children:p})})})}function xhe({side:e="left",variant:r="sidebar",collapsible:s="offcanvas",className:o,children:d,...p}){const{isMobile:m,state:g,openMobile:b,setOpenMobile:S}=B2();return s==="none"?u.jsx("div",{"data-slot":"sidebar",className:ft("bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col",o),...p,children:d}):m?u.jsx(ihe,{open:b,onOpenChange:S,...p,children:u.jsxs(lhe,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"bg-sidebar text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",style:{"--sidebar-width":mhe},side:e,children:[u.jsxs(che,{className:"sr-only",children:[u.jsx(uhe,{children:"Sidebar"}),u.jsx(dhe,{children:"Displays the mobile sidebar."})]}),u.jsx("div",{className:"flex h-full w-full flex-col",children:d})]})}):u.jsxs("div",{className:"group peer text-sidebar-foreground hidden md:block","data-state":g,"data-collapsible":g==="collapsed"?s:"","data-variant":r,"data-side":e,"data-slot":"sidebar",children:[u.jsx("div",{"data-slot":"sidebar-gap",className:ft("relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",r==="floating"||r==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon)")}),u.jsx("div",{"data-slot":"sidebar-container",className:ft("fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",r==="floating"||r==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l",o),...p,children:u.jsx("div",{"data-sidebar":"sidebar","data-slot":"sidebar-inner",className:"bg-sidebar group-data-[variant=floating]:border-sidebar-border flex h-full w-full flex-col group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:shadow-sm",children:d})})]})}function bhe({className:e,onClick:r,...s}){const{toggleSidebar:o}=B2();return u.jsxs(Fe,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:ft("size-7",e),onClick:d=>{r?.(d),o()},...s,children:[u.jsx(fW,{}),u.jsx("span",{className:"sr-only",children:"Toggle Sidebar"})]})}function whe({className:e,...r}){return u.jsx("main",{"data-slot":"sidebar-inset",className:ft("bg-background relative flex w-full flex-1 flex-col","md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2",e),...r})}function She({className:e,...r}){return u.jsx("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:ft("flex flex-col gap-2 p-2",e),...r})}function Ehe({className:e,...r}){return u.jsx("div",{"data-slot":"sidebar-footer","data-sidebar":"footer",className:ft("flex flex-col gap-2 p-2",e),...r})}function jhe({className:e,...r}){return u.jsx("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:ft("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...r})}function ej({className:e,...r}){return u.jsx("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:ft("relative flex w-full min-w-0 flex-col p-2",e),...r})}function tj({className:e,asChild:r=!1,...s}){const o=r?Cg:"div";return u.jsx(o,{"data-slot":"sidebar-group-label","data-sidebar":"group-label",className:ft("text-sidebar-foreground/70 ring-sidebar-ring flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium outline-hidden transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",e),...s})}function nj({className:e,...r}){return u.jsx("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:ft("w-full text-sm",e),...r})}function rj({className:e,...r}){return u.jsx("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:ft("flex w-full min-w-0 flex-col gap-1",e),...r})}function sj({className:e,...r}){return u.jsx("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:ft("group/menu-item relative",e),...r})}const Che=U_("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-hidden ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-data-[sidebar=menu-action]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:p-0!"}},defaultVariants:{variant:"default",size:"default"}});function ij({asChild:e=!1,isActive:r=!1,variant:s="default",size:o="default",tooltip:d,className:p,...m}){const g=e?Cg:"button",{isMobile:b,state:S}=B2(),j=u.jsx(g,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":o,"data-active":r,className:ft(Che({variant:s,size:o}),p),...m});return d?(typeof d=="string"&&(d={children:d}),u.jsxs(Mj,{children:[u.jsx(Ij,{asChild:!0,children:j}),u.jsx(Lj,{side:"right",align:"center",hidden:S!=="collapsed"||b,...d})]})):j}const Ahe=()=>{const e=__(),{data:r,isLoading:s}=Ide(),o=R.useMemo(()=>{const p=e.pathname.split("/").filter(Boolean),m=[];let g="";for(const b of p)g+=`/${b}`,m.push({to:g,label:b});return m},[e.pathname]),d=R.useMemo(()=>{if(!r)return"U";const m=(r.display_name||r.primary_email||"").trim().split(/\s+/);return m.length>=2?(m[0][0]+m[1][0]).toUpperCase():m.length===1&&m[0]?m[0][0].toUpperCase():"U"},[r]);return u.jsxs("div",{className:"flex h-12 items-center gap-2 border-b px-3",children:[u.jsx(bhe,{}),u.jsx("div",{className:"flex-1",children:u.jsx(ehe,{children:u.jsxs(the,{children:[u.jsx(F4,{children:u.jsx(q4,{asChild:!0,children:u.jsx(AR,{to:"/",children:"Home"})})}),o.map((p,m)=>u.jsxs("span",{className:"flex items-center",children:[u.jsx(rhe,{}),u.jsx(F4,{children:m===o.length-1?u.jsx(nhe,{className:"capitalize",children:p.label}):u.jsx(q4,{asChild:!0,children:u.jsx(AR,{to:p.to,className:"capitalize",children:p.label})})})]},p.to))]})})}),u.jsx(LF,{variant:"wide"}),u.jsx(Fe,{variant:"ghost",size:"sm",asChild:!0,children:u.jsx(AR,{to:"/me",children:s?"…":r?.display_name||"Profile"})}),u.jsx(Jde,{className:"h-7 w-7",children:u.jsx(Qde,{children:d})})]})};async function Ohe(){const e=Ks.get();if(!e?.refresh_token){Ks.logout();return}try{const r={refresh_token:e.refresh_token};await Yee().logout({dtoLogoutRequest:r})}catch(r){console.warn("Logout API failed; clearing local state anyway",r)}finally{Ks.logout()}}function khe(){return{logout:R.useCallback(()=>Ohe(),[])}}const Rhe=()=>{const[e,r]=R.useState([]),{logout:s}=khe();return R.useEffect(()=>{let o=!0;return(async()=>{try{const p=((await yp.getMe()).organizations??[]).map(m=>({id:m.id,name:m.name??m.id}));if(!o)return;r(p),!Qo.get()&&p.length>0&&Qo.set(p[0].id)}catch{}})(),()=>{o=!1}},[]),u.jsxs(vhe,{defaultOpen:!0,children:[u.jsxs(xhe,{collapsible:"icon",variant:"floating",children:[u.jsx(She,{children:u.jsx("div",{className:"px-2 py-2",children:u.jsx(soe,{orgs:e})})}),u.jsxs(jhe,{children:[u.jsxs(ej,{children:[u.jsx(tj,{children:"Navigation"}),u.jsx(nj,{children:u.jsx(rj,{children:Kse.map(o=>u.jsx(sj,{children:u.jsx(ij,{asChild:!0,tooltip:o.label,children:u.jsxs(ME,{to:o.to,className:({isActive:d})=>ft("flex items-center gap-2",d&&"text-primary"),children:[u.jsx(o.icon,{className:"h-4 w-4"}),u.jsx("span",{children:o.label})]})})},o.to))})})]}),u.jsxs(ej,{children:[u.jsx(tj,{children:"Organization"}),u.jsx(nj,{children:u.jsx(rj,{children:Vse.map(o=>u.jsx(sj,{children:u.jsx(ij,{asChild:!0,tooltip:o.label,children:u.jsxs(ME,{to:o.to,className:({isActive:d})=>ft("flex items-center gap-2",d&&"text-primary"),children:[u.jsx(o.icon,{className:"h-4 w-4"}),u.jsx("span",{children:o.label})]})})},o.to))})})]}),u.jsxs(ej,{children:[u.jsx(tj,{children:"User"}),u.jsx(nj,{children:u.jsx(rj,{children:Hse.map(o=>u.jsx(sj,{children:u.jsx(ij,{asChild:!0,tooltip:o.label,children:u.jsxs(ME,{to:o.to,className:({isActive:d})=>ft("flex items-center gap-2",d&&"text-primary"),children:[u.jsx(o.icon,{className:"h-4 w-4"}),u.jsx("span",{children:o.label})]})})},o.to))})})]}),u.jsxs(ej,{children:[u.jsx(tj,{children:"Admin"}),u.jsx(nj,{children:u.jsx(rj,{children:Gse.map(o=>u.jsx(sj,{children:u.jsx(ij,{asChild:!0,tooltip:o.label,children:u.jsxs(ME,{to:o.to,target:o.target?o.target:"_self",className:({isActive:d})=>ft("flex items-center gap-2",d&&"text-primary"),children:[u.jsx(o.icon,{className:"h-4 w-4"}),u.jsx("span",{children:o.label})]})})},o.to))})})]}),u.jsx("div",{className:"mt-auto flex items-center justify-center p-3",children:u.jsx(LF,{})})]}),u.jsx(Ehe,{children:u.jsx("div",{className:"px-2 py-2",children:u.jsx(Fe,{variant:"ghost",size:"sm",className:"w-full",onClick:()=>void s(),children:"Sign out"})})})]}),u.jsxs(whe,{className:"flex min-h-screen flex-col",children:[u.jsx(Ahe,{}),u.jsx("main",{className:"p-4",children:u.jsx(K3,{})}),u.jsx(_se,{})]})]})},The=()=>{const e=R.useSyncExternalStore(r=>Ks.subscribe(r),()=>Ks.get(),()=>Ks.get());return{tokens:e,authed:!!e?.access_token,isExpired:Ks.isExpired(),willExpireSoon:Ks.willExpireSoon()}},_he=()=>{const{authed:e}=The(),r=__();return e?u.jsx(K3,{}):u.jsx(fY,{to:`/login?to=${encodeURIComponent(r.pathname+r.search)}`,replace:!0})},ob=nte(),Sb={listAnnotations:()=>ut(async()=>await ob.listAnnotations()),createAnnotation:e=>ut(async()=>await ob.createAnnotation({dtoCreateAnnotationRequest:e})),getAnnotation:e=>ut(async()=>await ob.getAnnotation({id:e})),deleteAnnotation:e=>ut(async()=>{await ob.deleteAnnotation({id:e})}),updateAnnotation:(e,r)=>ut(async()=>await ob.updateAnnotation({id:e,dtoUpdateAnnotationRequest:r}))};var fw=e=>e.type==="checkbox",wp=e=>e instanceof Date,ua=e=>e==null;const VF=e=>typeof e=="object";var ms=e=>!ua(e)&&!Array.isArray(e)&&VF(e)&&!wp(e),HF=e=>ms(e)&&e.target?fw(e.target)?e.target.checked:e.target.value:e,$he=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,GF=(e,r)=>e.has($he(r)),Nhe=e=>{const r=e.constructor&&e.constructor.prototype;return ms(r)&&r.hasOwnProperty("isPrototypeOf")},U2=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function Es(e){let r;const s=Array.isArray(e),o=typeof FileList<"u"?e instanceof FileList:!1;if(e instanceof Date)r=new Date(e);else if(!(U2&&(e instanceof Blob||o))&&(s||ms(e)))if(r=s?[]:Object.create(Object.getPrototypeOf(e)),!s&&!Nhe(e))r=e;else for(const d in e)e.hasOwnProperty(d)&&(r[d]=Es(e[d]));else return e;return r}var zC=e=>/^\w*$/.test(e),Hr=e=>e===void 0,K2=e=>Array.isArray(e)?e.filter(Boolean):[],V2=e=>K2(e.replace(/["|']|\]/g,"").split(/\.|\[/)),Et=(e,r,s)=>{if(!r||!ms(e))return s;const o=(zC(r)?[r]:V2(r)).reduce((d,p)=>ua(d)?d:d[p],e);return Hr(o)||o===e?Hr(e[r])?s:e[r]:o},Ta=e=>typeof e=="boolean",dr=(e,r,s)=>{let o=-1;const d=zC(r)?[r]:V2(r),p=d.length,m=p-1;for(;++oJe.useContext(H2),Dhe=e=>{const{children:r,...s}=e;return Je.createElement(H2.Provider,{value:s},r)};var XF=(e,r,s,o=!0)=>{const d={defaultValues:r._defaultValues};for(const p in e)Object.defineProperty(d,p,{get:()=>{const m=p;return r._proxyFormState[m]!==Zo.all&&(r._proxyFormState[m]=!o||Zo.all),s&&(s[m]=!0),e[m]}});return d};const G2=typeof window<"u"?Je.useLayoutEffect:Je.useEffect;function YF(e){const r=FC(),{control:s=r.control,disabled:o,name:d,exact:p}=e||{},[m,g]=Je.useState(s._formState),b=Je.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return G2(()=>s._subscribe({name:d,formState:b.current,exact:p,callback:S=>{!o&&g({...s._formState,...S})}}),[d,o,p]),Je.useEffect(()=>{b.current.isValid&&s._setValid(!0)},[s]),Je.useMemo(()=>XF(m,s,b.current,!1),[m,s])}var $a=e=>typeof e=="string",d_=(e,r,s,o,d)=>$a(e)?(o&&r.watch.add(e),Et(s,e,d)):Array.isArray(e)?e.map(p=>(o&&r.watch.add(p),Et(s,p))):(o&&(r.watchAll=!0),s),h_=e=>ua(e)||!VF(e);function Wo(e,r,s=new WeakSet){if(h_(e)||h_(r))return Object.is(e,r);if(wp(e)&&wp(r))return e.getTime()===r.getTime();const o=Object.keys(e),d=Object.keys(r);if(o.length!==d.length)return!1;if(s.has(e)||s.has(r))return!0;s.add(e),s.add(r);for(const p of o){const m=e[p];if(!d.includes(p))return!1;if(p!=="ref"){const g=r[p];if(wp(m)&&wp(g)||ms(m)&&ms(g)||Array.isArray(m)&&Array.isArray(g)?!Wo(m,g,s):!Object.is(m,g))return!1}}return!0}function ug(e){const r=FC(),{control:s=r.control,name:o,defaultValue:d,disabled:p,exact:m,compute:g}=e||{},b=Je.useRef(d),S=Je.useRef(g),j=Je.useRef(void 0),A=Je.useRef(s),k=Je.useRef(o);S.current=g;const[T,M]=Je.useState(()=>{const L=s._getWatch(o,b.current);return S.current?S.current(L):L}),I=Je.useCallback(L=>{const ee=d_(o,s._names,L||s._formValues,!1,b.current);return S.current?S.current(ee):ee},[s._formValues,s._names,o]),q=Je.useCallback(L=>{if(!p){const ee=d_(o,s._names,L||s._formValues,!1,b.current);if(S.current){const oe=S.current(ee);Wo(oe,j.current)||(M(oe),j.current=oe)}else M(ee)}},[s._formValues,s._names,p,o]);G2(()=>((A.current!==s||!Wo(k.current,o))&&(A.current=s,k.current=o,q()),s._subscribe({name:o,formState:{values:!0},exact:m,callback:L=>{q(L.values)}})),[s,m,o,q]),Je.useEffect(()=>s._removeUnmounted());const G=A.current!==s,K=k.current,X=Je.useMemo(()=>{if(p)return null;const L=!G&&!Wo(K,o);return G||L?I():null},[p,G,o,K,I]);return X!==null?X:T}function Phe(e){const r=FC(),{name:s,disabled:o,control:d=r.control,shouldUnregister:p,defaultValue:m,exact:g=!0}=e,b=GF(d._names.array,s),S=Je.useMemo(()=>Et(d._formValues,s,Et(d._defaultValues,s,m)),[d,s,m]),j=ug({control:d,name:s,defaultValue:S,exact:g}),A=YF({control:d,name:s,exact:g}),k=Je.useRef(e),T=Je.useRef(void 0),M=Je.useRef(d.register(s,{...e.rules,value:j,...Ta(e.disabled)?{disabled:e.disabled}:{}}));k.current=e;const I=Je.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Et(A.errors,s)},isDirty:{enumerable:!0,get:()=>!!Et(A.dirtyFields,s)},isTouched:{enumerable:!0,get:()=>!!Et(A.touchedFields,s)},isValidating:{enumerable:!0,get:()=>!!Et(A.validatingFields,s)},error:{enumerable:!0,get:()=>Et(A.errors,s)}}),[A,s]),q=Je.useCallback(L=>M.current.onChange({target:{value:HF(L),name:s},type:Yj.CHANGE}),[s]),G=Je.useCallback(()=>M.current.onBlur({target:{value:Et(d._formValues,s),name:s},type:Yj.BLUR}),[s,d._formValues]),K=Je.useCallback(L=>{const ee=Et(d._fields,s);ee&&L&&(ee._f.ref={focus:()=>L.focus&&L.focus(),select:()=>L.select&&L.select(),setCustomValidity:oe=>L.setCustomValidity(oe),reportValidity:()=>L.reportValidity()})},[d._fields,s]),X=Je.useMemo(()=>({name:s,value:j,...Ta(o)||A.disabled?{disabled:A.disabled||o}:{},onChange:q,onBlur:G,ref:K}),[s,o,A.disabled,q,G,K,j]);return Je.useEffect(()=>{const L=d._options.shouldUnregister||p,ee=T.current;ee&&ee!==s&&!b&&d.unregister(ee),d.register(s,{...k.current.rules,...Ta(k.current.disabled)?{disabled:k.current.disabled}:{}});const oe=(Q,ne)=>{const de=Et(d._fields,Q);de&&de._f&&(de._f.mount=ne)};if(oe(s,!0),L){const Q=Es(Et(d._options.defaultValues,s,k.current.defaultValue));dr(d._defaultValues,s,Q),Hr(Et(d._formValues,s))&&dr(d._formValues,s,Q)}return!b&&d.register(s),T.current=s,()=>{(b?L&&!d._state.action:L)?d.unregister(s):oe(s,!1)}},[s,d,b,p]),Je.useEffect(()=>{d._setDisabledField({disabled:o,name:s})},[o,s,d]),Je.useMemo(()=>({field:X,formState:A,fieldState:I}),[X,A,I])}const Go=e=>e.render(Phe(e));var X2=(e,r,s,o,d)=>r?{...s[e],types:{...s[e]&&s[e].types?s[e].types:{},[o]:d||!0}}:{},Db=e=>Array.isArray(e)?e:[e],B4=()=>{let e=[];return{get observers(){return e},next:d=>{for(const p of e)p.next&&p.next(d)},subscribe:d=>(e.push(d),{unsubscribe:()=>{e=e.filter(p=>p!==d)}}),unsubscribe:()=>{e=[]}}};function ZF(e,r){const s={};for(const o in e)if(e.hasOwnProperty(o)){const d=e[o],p=r[o];if(d&&ms(d)&&p){const m=ZF(d,p);ms(m)&&(s[o]=m)}else e[o]&&(s[o]=p)}return s}var Di=e=>ms(e)&&!Object.keys(e).length,Y2=e=>e.type==="file",Jo=e=>typeof e=="function",Zj=e=>{if(!U2)return!1;const r=e?e.ownerDocument:0;return e instanceof(r&&r.defaultView?r.defaultView.HTMLElement:HTMLElement)},WF=e=>e.type==="select-multiple",Z2=e=>e.type==="radio",Mhe=e=>Z2(e)||fw(e),hT=e=>Zj(e)&&e.isConnected;function Ihe(e,r){const s=r.slice(0,-1).length;let o=0;for(;o{for(const r in e)if(Jo(e[r]))return!0;return!1};function JF(e){return Array.isArray(e)||ms(e)&&!zhe(e)}function p_(e,r={}){for(const s in e){const o=e[s];JF(o)?(r[s]=Array.isArray(o)?[]:{},p_(o,r[s])):Hr(o)||(r[s]=!0)}return r}function Jm(e,r,s){s||(s=p_(r));for(const o in e){const d=e[o];if(JF(d))Hr(r)||h_(s[o])?s[o]=p_(d,Array.isArray(d)?[]:{}):Jm(d,ua(r)?{}:r[o],s[o]);else{const p=r[o];s[o]=!Wo(d,p)}}return s}const U4={value:!1,isValid:!1},K4={value:!0,isValid:!0};var QF=e=>{if(Array.isArray(e)){if(e.length>1){const r=e.filter(s=>s&&s.checked&&!s.disabled).map(s=>s.value);return{value:r,isValid:!!r.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!Hr(e[0].attributes.value)?Hr(e[0].value)||e[0].value===""?K4:{value:e[0].value,isValid:!0}:K4:U4}return U4},e6=(e,{valueAsNumber:r,valueAsDate:s,setValueAs:o})=>Hr(e)?e:r?e===""?NaN:e&&+e:s&&$a(e)?new Date(e):o?o(e):e;const V4={isValid:!1,value:null};var t6=e=>Array.isArray(e)?e.reduce((r,s)=>s&&s.checked&&!s.disabled?{isValid:!0,value:s.value}:r,V4):V4;function H4(e){const r=e.ref;return Y2(r)?r.files:Z2(r)?t6(e.refs).value:WF(r)?[...r.selectedOptions].map(({value:s})=>s):fw(r)?QF(e.refs).value:e6(Hr(r.value)?e.ref.value:r.value,e)}var Fhe=(e,r,s,o)=>{const d={};for(const p of e){const m=Et(r,p);m&&dr(d,p,m._f)}return{criteriaMode:s,names:[...e],fields:d,shouldUseNativeValidation:o}},Wj=e=>e instanceof RegExp,lb=e=>Hr(e)?e:Wj(e)?e.source:ms(e)?Wj(e.value)?e.value.source:e.value:e,G4=e=>({isOnSubmit:!e||e===Zo.onSubmit,isOnBlur:e===Zo.onBlur,isOnChange:e===Zo.onChange,isOnAll:e===Zo.all,isOnTouch:e===Zo.onTouched});const X4="AsyncFunction";var qhe=e=>!!e&&!!e.validate&&!!(Jo(e.validate)&&e.validate.constructor.name===X4||ms(e.validate)&&Object.values(e.validate).find(r=>r.constructor.name===X4)),Bhe=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate),Y4=(e,r,s)=>!s&&(r.watchAll||r.watch.has(e)||[...r.watch].some(o=>e.startsWith(o)&&/^\.\w+/.test(e.slice(o.length))));const Pb=(e,r,s,o)=>{for(const d of s||Object.keys(e)){const p=Et(e,d);if(p){const{_f:m,...g}=p;if(m){if(m.refs&&m.refs[0]&&r(m.refs[0],d)&&!o)return!0;if(m.ref&&r(m.ref,m.name)&&!o)return!0;if(Pb(g,r))break}else if(ms(g)&&Pb(g,r))break}}};function Z4(e,r,s){const o=Et(e,s);if(o||zC(s))return{error:o,name:s};const d=s.split(".");for(;d.length;){const p=d.join("."),m=Et(r,p),g=Et(e,p);if(m&&!Array.isArray(m)&&s!==p)return{name:s};if(g&&g.type)return{name:p,error:g};if(g&&g.root&&g.root.type)return{name:`${p}.root`,error:g.root};d.pop()}return{name:s}}var Uhe=(e,r,s,o)=>{s(e);const{name:d,...p}=e;return Di(p)||Object.keys(p).length>=Object.keys(r).length||Object.keys(p).find(m=>r[m]===(!o||Zo.all))},Khe=(e,r,s)=>!e||!r||e===r||Db(e).some(o=>o&&(s?o===r:o.startsWith(r)||r.startsWith(o))),Vhe=(e,r,s,o,d)=>d.isOnAll?!1:!s&&d.isOnTouch?!(r||e):(s?o.isOnBlur:d.isOnBlur)?!e:(s?o.isOnChange:d.isOnChange)?e:!0,Hhe=(e,r)=>!K2(Et(e,r)).length&&ps(e,r),Ghe=(e,r,s)=>{const o=Db(Et(e,s));return dr(o,"root",r[s]),dr(e,s,o),e};function W4(e,r,s="validate"){if($a(e)||Array.isArray(e)&&e.every($a)||Ta(e)&&!e)return{type:s,message:$a(e)?e:"",ref:r}}var Xm=e=>ms(e)&&!Wj(e)?e:{value:e,message:""},J4=async(e,r,s,o,d,p)=>{const{ref:m,refs:g,required:b,maxLength:S,minLength:j,min:A,max:k,pattern:T,validate:M,name:I,valueAsNumber:q,mount:G}=e._f,K=Et(s,I);if(!G||r.has(I))return{};const X=g?g[0]:m,L=le=>{d&&X.reportValidity&&(X.setCustomValidity(Ta(le)?"":le||""),X.reportValidity())},ee={},oe=Z2(m),Q=fw(m),ne=oe||Q,de=(q||Y2(m))&&Hr(m.value)&&Hr(K)||Zj(m)&&m.value===""||K===""||Array.isArray(K)&&!K.length,je=X2.bind(null,I,o,ee),ve=(le,be,Ce,Ke=cu.maxLength,ce=cu.minLength)=>{const re=le?be:Ce;ee[I]={type:le?Ke:ce,message:re,ref:m,...je(le?Ke:ce,re)}};if(p?!Array.isArray(K)||!K.length:b&&(!ne&&(de||ua(K))||Ta(K)&&!K||Q&&!QF(g).isValid||oe&&!t6(g).isValid)){const{value:le,message:be}=$a(b)?{value:!!b,message:b}:Xm(b);if(le&&(ee[I]={type:cu.required,message:be,ref:X,...je(cu.required,be)},!o))return L(be),ee}if(!de&&(!ua(A)||!ua(k))){let le,be;const Ce=Xm(k),Ke=Xm(A);if(!ua(K)&&!isNaN(K)){const ce=m.valueAsNumber||K&&+K;ua(Ce.value)||(le=ce>Ce.value),ua(Ke.value)||(be=cenew Date(new Date().toDateString()+" "+fe),ue=m.type=="time",_e=m.type=="week";$a(Ce.value)&&K&&(le=ue?re(K)>re(Ce.value):_e?K>Ce.value:ce>new Date(Ce.value)),$a(Ke.value)&&K&&(be=ue?re(K)+le.value,Ke=!ua(be.value)&&K.length<+be.value;if((Ce||Ke)&&(ve(Ce,le.message,be.message),!o))return L(ee[I].message),ee}if(T&&!de&&$a(K)){const{value:le,message:be}=Xm(T);if(Wj(le)&&!K.match(le)&&(ee[I]={type:cu.pattern,message:be,ref:m,...je(cu.pattern,be)},!o))return L(be),ee}if(M){if(Jo(M)){const le=await M(K,s),be=W4(le,X);if(be&&(ee[I]={...be,...je(cu.validate,be.message)},!o))return L(be.message),ee}else if(ms(M)){let le={};for(const be in M){if(!Di(le)&&!o)break;const Ce=W4(await M[be](K,s),X,be);Ce&&(le={...Ce,...je(be,Ce.message)},L(Ce.message),o&&(ee[I]=le))}if(!Di(le)&&(ee[I]={ref:X,...le},!o))return ee}}return L(!0),ee};const Xhe={mode:Zo.onSubmit,reValidateMode:Zo.onChange,shouldFocusError:!0};function Yhe(e={}){let r={...Xhe,...e},s={submitCount:0,isDirty:!1,isReady:!1,isLoading:Jo(r.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:r.errors||{},disabled:r.disabled||!1},o={},d=ms(r.defaultValues)||ms(r.values)?Es(r.defaultValues||r.values)||{}:{},p=r.shouldUnregister?{}:Es(d),m={action:!1,mount:!1,watch:!1},g={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},b,S=0;const j={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1};let A={...j};const k={array:B4(),state:B4()},T=r.criteriaMode===Zo.all,M=xe=>Ne=>{clearTimeout(S),S=setTimeout(xe,Ne)},I=async xe=>{if(!r.disabled&&(j.isValid||A.isValid||xe)){const Ne=r.resolver?Di((await Q()).errors):await de(o,!0);Ne!==s.isValid&&k.state.next({isValid:Ne})}},q=(xe,Ne)=>{!r.disabled&&(j.isValidating||j.validatingFields||A.isValidating||A.validatingFields)&&((xe||Array.from(g.mount)).forEach(Ge=>{Ge&&(Ne?dr(s.validatingFields,Ge,Ne):ps(s.validatingFields,Ge))}),k.state.next({validatingFields:s.validatingFields,isValidating:!Di(s.validatingFields)}))},G=(xe,Ne=[],Ge,D,z=!0,H=!0)=>{if(D&&Ge&&!r.disabled){if(m.action=!0,H&&Array.isArray(Et(o,xe))){const Z=Ge(Et(o,xe),D.argA,D.argB);z&&dr(o,xe,Z)}if(H&&Array.isArray(Et(s.errors,xe))){const Z=Ge(Et(s.errors,xe),D.argA,D.argB);z&&dr(s.errors,xe,Z),Hhe(s.errors,xe)}if((j.touchedFields||A.touchedFields)&&H&&Array.isArray(Et(s.touchedFields,xe))){const Z=Ge(Et(s.touchedFields,xe),D.argA,D.argB);z&&dr(s.touchedFields,xe,Z)}(j.dirtyFields||A.dirtyFields)&&(s.dirtyFields=Jm(d,p)),k.state.next({name:xe,isDirty:ve(xe,Ne),dirtyFields:s.dirtyFields,errors:s.errors,isValid:s.isValid})}else dr(p,xe,Ne)},K=(xe,Ne)=>{dr(s.errors,xe,Ne),k.state.next({errors:s.errors})},X=xe=>{s.errors=xe,k.state.next({errors:s.errors,isValid:!1})},L=(xe,Ne,Ge,D)=>{const z=Et(o,xe);if(z){const H=Et(p,xe,Hr(Ge)?Et(d,xe):Ge);Hr(H)||D&&D.defaultChecked||Ne?dr(p,xe,Ne?H:H4(z._f)):Ce(xe,H),m.mount&&!m.action&&I()}},ee=(xe,Ne,Ge,D,z)=>{let H=!1,Z=!1;const we={name:xe};if(!r.disabled){if(!Ge||D){(j.isDirty||A.isDirty)&&(Z=s.isDirty,s.isDirty=we.isDirty=ve(),H=Z!==we.isDirty);const Re=Wo(Et(d,xe),Ne);Z=!!Et(s.dirtyFields,xe),Re?ps(s.dirtyFields,xe):dr(s.dirtyFields,xe,!0),we.dirtyFields=s.dirtyFields,H=H||(j.dirtyFields||A.dirtyFields)&&Z!==!Re}if(Ge){const Re=Et(s.touchedFields,xe);Re||(dr(s.touchedFields,xe,Ge),we.touchedFields=s.touchedFields,H=H||(j.touchedFields||A.touchedFields)&&Re!==Ge)}H&&z&&k.state.next(we)}return H?we:{}},oe=(xe,Ne,Ge,D)=>{const z=Et(s.errors,xe),H=(j.isValid||A.isValid)&&Ta(Ne)&&s.isValid!==Ne;if(r.delayError&&Ge?(b=M(()=>K(xe,Ge)),b(r.delayError)):(clearTimeout(S),b=null,Ge?dr(s.errors,xe,Ge):ps(s.errors,xe)),(Ge?!Wo(z,Ge):z)||!Di(D)||H){const Z={...D,...H&&Ta(Ne)?{isValid:Ne}:{},errors:s.errors,name:xe};s={...s,...Z},k.state.next(Z)}},Q=async xe=>{q(xe,!0);const Ne=await r.resolver(p,r.context,Fhe(xe||g.mount,o,r.criteriaMode,r.shouldUseNativeValidation));return q(xe),Ne},ne=async xe=>{const{errors:Ne}=await Q(xe);if(xe)for(const Ge of xe){const D=Et(Ne,Ge);D?dr(s.errors,Ge,D):ps(s.errors,Ge)}else s.errors=Ne;return Ne},de=async(xe,Ne,Ge={valid:!0})=>{for(const D in xe){const z=xe[D];if(z){const{_f:H,...Z}=z;if(H){const we=g.array.has(H.name),Re=z._f&&qhe(z._f);Re&&j.validatingFields&&q([H.name],!0);const st=await J4(z,g.disabled,p,T,r.shouldUseNativeValidation&&!Ne,we);if(Re&&j.validatingFields&&q([H.name]),st[H.name]&&(Ge.valid=!1,Ne))break;!Ne&&(Et(st,H.name)?we?Ghe(s.errors,st,H.name):dr(s.errors,H.name,st[H.name]):ps(s.errors,H.name))}!Di(Z)&&await de(Z,Ne,Ge)}}return Ge.valid},je=()=>{for(const xe of g.unMount){const Ne=Et(o,xe);Ne&&(Ne._f.refs?Ne._f.refs.every(Ge=>!hT(Ge)):!hT(Ne._f.ref))&&Le(xe)}g.unMount=new Set},ve=(xe,Ne)=>!r.disabled&&(xe&&Ne&&dr(p,xe,Ne),!Wo(fe(),d)),le=(xe,Ne,Ge)=>d_(xe,g,{...m.mount?p:Hr(Ne)?d:$a(xe)?{[xe]:Ne}:Ne},Ge,Ne),be=xe=>K2(Et(m.mount?p:d,xe,r.shouldUnregister?Et(d,xe,[]):[])),Ce=(xe,Ne,Ge={})=>{const D=Et(o,xe);let z=Ne;if(D){const H=D._f;H&&(!H.disabled&&dr(p,xe,e6(Ne,H)),z=Zj(H.ref)&&ua(Ne)?"":Ne,WF(H.ref)?[...H.ref.options].forEach(Z=>Z.selected=z.includes(Z.value)):H.refs?fw(H.ref)?H.refs.forEach(Z=>{(!Z.defaultChecked||!Z.disabled)&&(Array.isArray(z)?Z.checked=!!z.find(we=>we===Z.value):Z.checked=z===Z.value||!!z)}):H.refs.forEach(Z=>Z.checked=Z.value===z):Y2(H.ref)?H.ref.value="":(H.ref.value=z,H.ref.type||k.state.next({name:xe,values:Es(p)})))}(Ge.shouldDirty||Ge.shouldTouch)&&ee(xe,z,Ge.shouldTouch,Ge.shouldDirty,!0),Ge.shouldValidate&&_e(xe)},Ke=(xe,Ne,Ge)=>{for(const D in Ne){if(!Ne.hasOwnProperty(D))return;const z=Ne[D],H=xe+"."+D,Z=Et(o,H);(g.array.has(xe)||ms(z)||Z&&!Z._f)&&!wp(z)?Ke(H,z,Ge):Ce(H,z,Ge)}},ce=(xe,Ne,Ge={})=>{const D=Et(o,xe),z=g.array.has(xe),H=Es(Ne);dr(p,xe,H),z?(k.array.next({name:xe,values:Es(p)}),(j.isDirty||j.dirtyFields||A.isDirty||A.dirtyFields)&&Ge.shouldDirty&&k.state.next({name:xe,dirtyFields:Jm(d,p),isDirty:ve(xe,H)})):D&&!D._f&&!ua(H)?Ke(xe,H,Ge):Ce(xe,H,Ge),Y4(xe,g)&&k.state.next({...s,name:xe}),k.state.next({name:m.mount?xe:void 0,values:Es(p)})},re=async xe=>{m.mount=!0;const Ne=xe.target;let Ge=Ne.name,D=!0;const z=Et(o,Ge),H=Re=>{D=Number.isNaN(Re)||wp(Re)&&isNaN(Re.getTime())||Wo(Re,Et(p,Ge,Re))},Z=G4(r.mode),we=G4(r.reValidateMode);if(z){let Re,st;const Kt=Ne.type?H4(z._f):HF(xe),Qt=xe.type===Yj.BLUR||xe.type===Yj.FOCUS_OUT,Fn=!Bhe(z._f)&&!r.resolver&&!Et(s.errors,Ge)&&!z._f.deps||Vhe(Qt,Et(s.touchedFields,Ge),s.isSubmitted,we,Z),dn=Y4(Ge,g,Qt);dr(p,Ge,Kt),Qt?(!Ne||!Ne.readOnly)&&(z._f.onBlur&&z._f.onBlur(xe),b&&b(0)):z._f.onChange&&z._f.onChange(xe);const Ht=ee(Ge,Kt,Qt),wi=!Di(Ht)||dn;if(!Qt&&k.state.next({name:Ge,type:xe.type,values:Es(p)}),Fn)return(j.isValid||A.isValid)&&(r.mode==="onBlur"?Qt&&I():Qt||I()),wi&&k.state.next({name:Ge,...dn?{}:Ht});if(!Qt&&dn&&k.state.next({...s}),r.resolver){const{errors:Xr}=await Q([Ge]);if(H(Kt),D){const fa=Z4(s.errors,o,Ge),uo=Z4(Xr,o,fa.name||Ge);Re=uo.error,Ge=uo.name,st=Di(Xr)}}else q([Ge],!0),Re=(await J4(z,g.disabled,p,T,r.shouldUseNativeValidation))[Ge],q([Ge]),H(Kt),D&&(Re?st=!1:(j.isValid||A.isValid)&&(st=await de(o,!0)));D&&(z._f.deps&&(!Array.isArray(z._f.deps)||z._f.deps.length>0)&&_e(z._f.deps),oe(Ge,st,Re,Ht))}},ue=(xe,Ne)=>{if(Et(s.errors,Ne)&&xe.focus)return xe.focus(),1},_e=async(xe,Ne={})=>{let Ge,D;const z=Db(xe);if(r.resolver){const H=await ne(Hr(xe)?xe:z);Ge=Di(H),D=xe?!z.some(Z=>Et(H,Z)):Ge}else xe?(D=(await Promise.all(z.map(async H=>{const Z=Et(o,H);return await de(Z&&Z._f?{[H]:Z}:Z)}))).every(Boolean),!(!D&&!s.isValid)&&I()):D=Ge=await de(o);return k.state.next({...!$a(xe)||(j.isValid||A.isValid)&&Ge!==s.isValid?{}:{name:xe},...r.resolver||!xe?{isValid:Ge}:{},errors:s.errors}),Ne.shouldFocus&&!D&&Pb(o,ue,xe?z:g.mount),D},fe=(xe,Ne)=>{let Ge={...m.mount?p:d};return Ne&&(Ge=ZF(Ne.dirtyFields?s.dirtyFields:s.touchedFields,Ge)),Hr(xe)?Ge:$a(xe)?Et(Ge,xe):xe.map(D=>Et(Ge,D))},He=(xe,Ne)=>({invalid:!!Et((Ne||s).errors,xe),isDirty:!!Et((Ne||s).dirtyFields,xe),error:Et((Ne||s).errors,xe),isValidating:!!Et(s.validatingFields,xe),isTouched:!!Et((Ne||s).touchedFields,xe)}),Oe=xe=>{xe&&Db(xe).forEach(Ne=>ps(s.errors,Ne)),k.state.next({errors:xe?s.errors:{}})},ke=(xe,Ne,Ge)=>{const D=(Et(o,xe,{_f:{}})._f||{}).ref,z=Et(s.errors,xe)||{},{ref:H,message:Z,type:we,...Re}=z;dr(s.errors,xe,{...Re,...Ne,ref:D}),k.state.next({name:xe,errors:s.errors,isValid:!1}),Ge&&Ge.shouldFocus&&D&&D.focus&&D.focus()},Ve=(xe,Ne)=>Jo(xe)?k.state.subscribe({next:Ge=>"values"in Ge&&xe(le(void 0,Ne),Ge)}):le(xe,Ne,!0),ie=xe=>k.state.subscribe({next:Ne=>{Khe(xe.name,Ne.name,xe.exact)&&Uhe(Ne,xe.formState||j,V,xe.reRenderRoot)&&xe.callback({values:{...p},...s,...Ne,defaultValues:d})}}).unsubscribe,De=xe=>(m.mount=!0,A={...A,...xe.formState},ie({...xe,formState:A})),Le=(xe,Ne={})=>{for(const Ge of xe?Db(xe):g.mount)g.mount.delete(Ge),g.array.delete(Ge),Ne.keepValue||(ps(o,Ge),ps(p,Ge)),!Ne.keepError&&ps(s.errors,Ge),!Ne.keepDirty&&ps(s.dirtyFields,Ge),!Ne.keepTouched&&ps(s.touchedFields,Ge),!Ne.keepIsValidating&&ps(s.validatingFields,Ge),!r.shouldUnregister&&!Ne.keepDefaultValue&&ps(d,Ge);k.state.next({values:Es(p)}),k.state.next({...s,...Ne.keepDirty?{isDirty:ve()}:{}}),!Ne.keepIsValid&&I()},tt=({disabled:xe,name:Ne})=>{(Ta(xe)&&m.mount||xe||g.disabled.has(Ne))&&(xe?g.disabled.add(Ne):g.disabled.delete(Ne))},yt=(xe,Ne={})=>{let Ge=Et(o,xe);const D=Ta(Ne.disabled)||Ta(r.disabled);return dr(o,xe,{...Ge||{},_f:{...Ge&&Ge._f?Ge._f:{ref:{name:xe}},name:xe,mount:!0,...Ne}}),g.mount.add(xe),Ge?tt({disabled:Ta(Ne.disabled)?Ne.disabled:r.disabled,name:xe}):L(xe,!0,Ne.value),{...D?{disabled:Ne.disabled||r.disabled}:{},...r.progressive?{required:!!Ne.required,min:lb(Ne.min),max:lb(Ne.max),minLength:lb(Ne.minLength),maxLength:lb(Ne.maxLength),pattern:lb(Ne.pattern)}:{},name:xe,onChange:re,onBlur:re,ref:z=>{if(z){yt(xe,Ne),Ge=Et(o,xe);const H=Hr(z.value)&&z.querySelectorAll&&z.querySelectorAll("input,select,textarea")[0]||z,Z=Mhe(H),we=Ge._f.refs||[];if(Z?we.find(Re=>Re===H):H===Ge._f.ref)return;dr(o,xe,{_f:{...Ge._f,...Z?{refs:[...we.filter(hT),H,...Array.isArray(Et(d,xe))?[{}]:[]],ref:{type:H.type,name:xe}}:{ref:H}}}),L(xe,!1,void 0,H)}else Ge=Et(o,xe,{}),Ge._f&&(Ge._f.mount=!1),(r.shouldUnregister||Ne.shouldUnregister)&&!(GF(g.array,xe)&&m.action)&&g.unMount.add(xe)}}},Ot=()=>r.shouldFocusError&&Pb(o,ue,g.mount),Ft=xe=>{Ta(xe)&&(k.state.next({disabled:xe}),Pb(o,(Ne,Ge)=>{const D=Et(o,Ge);D&&(Ne.disabled=D._f.disabled||xe,Array.isArray(D._f.refs)&&D._f.refs.forEach(z=>{z.disabled=D._f.disabled||xe}))},0,!1))},kt=(xe,Ne)=>async Ge=>{let D;Ge&&(Ge.preventDefault&&Ge.preventDefault(),Ge.persist&&Ge.persist());let z=Es(p);if(k.state.next({isSubmitting:!0}),r.resolver){const{errors:H,values:Z}=await Q();s.errors=H,z=Es(Z)}else await de(o);if(g.disabled.size)for(const H of g.disabled)ps(z,H);if(ps(s.errors,"root"),Di(s.errors)){k.state.next({errors:{}});try{await xe(z,Ge)}catch(H){D=H}}else Ne&&await Ne({...s.errors},Ge),Ot(),setTimeout(Ot);if(k.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:Di(s.errors)&&!D,submitCount:s.submitCount+1,errors:s.errors}),D)throw D},Jt=(xe,Ne={})=>{Et(o,xe)&&(Hr(Ne.defaultValue)?ce(xe,Es(Et(d,xe))):(ce(xe,Ne.defaultValue),dr(d,xe,Es(Ne.defaultValue))),Ne.keepTouched||ps(s.touchedFields,xe),Ne.keepDirty||(ps(s.dirtyFields,xe),s.isDirty=Ne.defaultValue?ve(xe,Es(Et(d,xe))):ve()),Ne.keepError||(ps(s.errors,xe),j.isValid&&I()),k.state.next({...s}))},ze=(xe,Ne={})=>{const Ge=xe?Es(xe):d,D=Es(Ge),z=Di(xe),H=z?d:D;if(Ne.keepDefaultValues||(d=Ge),!Ne.keepValues){if(Ne.keepDirtyValues){const Z=new Set([...g.mount,...Object.keys(Jm(d,p))]);for(const we of Array.from(Z))Et(s.dirtyFields,we)?dr(H,we,Et(p,we)):ce(we,Et(H,we))}else{if(U2&&Hr(xe))for(const Z of g.mount){const we=Et(o,Z);if(we&&we._f){const Re=Array.isArray(we._f.refs)?we._f.refs[0]:we._f.ref;if(Zj(Re)){const st=Re.closest("form");if(st){st.reset();break}}}}if(Ne.keepFieldsRef)for(const Z of g.mount)ce(Z,Et(H,Z));else o={}}p=r.shouldUnregister?Ne.keepDefaultValues?Es(d):{}:Es(H),k.array.next({values:{...H}}),k.state.next({values:{...H}})}g={mount:Ne.keepDirtyValues?g.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},m.mount=!j.isValid||!!Ne.keepIsValid||!!Ne.keepDirtyValues||!r.shouldUnregister&&!Di(H),m.watch=!!r.shouldUnregister,m.action=!1,Ne.keepErrors||(s.errors={}),k.state.next({submitCount:Ne.keepSubmitCount?s.submitCount:0,isDirty:z?!1:Ne.keepDirty?s.isDirty:!!(Ne.keepDefaultValues&&!Wo(xe,d)),isSubmitted:Ne.keepIsSubmitted?s.isSubmitted:!1,dirtyFields:z?{}:Ne.keepDirtyValues?Ne.keepDefaultValues&&p?Jm(d,p):s.dirtyFields:Ne.keepDefaultValues&&xe?Jm(d,xe):Ne.keepDirty?s.dirtyFields:{},touchedFields:Ne.keepTouched?s.touchedFields:{},errors:Ne.keepErrors?s.errors:{},isSubmitSuccessful:Ne.keepIsSubmitSuccessful?s.isSubmitSuccessful:!1,isSubmitting:!1,defaultValues:d})},zt=(xe,Ne)=>ze(Jo(xe)?xe(p):xe,Ne),Rt=(xe,Ne={})=>{const Ge=Et(o,xe),D=Ge&&Ge._f;if(D){const z=D.refs?D.refs[0]:D.ref;z.focus&&(z.focus(),Ne.shouldSelect&&Jo(z.select)&&z.select())}},V=xe=>{s={...s,...xe}},cn={control:{register:yt,unregister:Le,getFieldState:He,handleSubmit:kt,setError:ke,_subscribe:ie,_runSchema:Q,_focusError:Ot,_getWatch:le,_getDirty:ve,_setValid:I,_setFieldArray:G,_setDisabledField:tt,_setErrors:X,_getFieldArray:be,_reset:ze,_resetDefaultValues:()=>Jo(r.defaultValues)&&r.defaultValues().then(xe=>{zt(xe,r.resetOptions),k.state.next({isLoading:!1})}),_removeUnmounted:je,_disableForm:Ft,_subjects:k,_proxyFormState:j,get _fields(){return o},get _formValues(){return p},get _state(){return m},set _state(xe){m=xe},get _defaultValues(){return d},get _names(){return g},set _names(xe){g=xe},get _formState(){return s},get _options(){return r},set _options(xe){r={...r,...xe}}},subscribe:De,trigger:_e,register:yt,handleSubmit:kt,watch:Ve,setValue:ce,getValues:fe,reset:zt,resetField:Jt,clearErrors:Oe,unregister:Le,setError:ke,setFocus:Rt,getFieldState:He};return{...cn,formControl:cn}}function mr(e={}){const r=Je.useRef(void 0),s=Je.useRef(void 0),[o,d]=Je.useState({isDirty:!1,isValidating:!1,isLoading:Jo(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,isReady:!1,defaultValues:Jo(e.defaultValues)?void 0:e.defaultValues});if(!r.current)if(e.formControl)r.current={...e.formControl,formState:o},e.defaultValues&&!Jo(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{const{formControl:m,...g}=Yhe(e);r.current={...g,formState:o}}const p=r.current.control;return p._options=e,G2(()=>{const m=p._subscribe({formState:p._proxyFormState,callback:()=>d({...p._formState}),reRenderRoot:!0});return d(g=>({...g,isReady:!0})),p._formState.isReady=!0,m},[p]),Je.useEffect(()=>p._disableForm(e.disabled),[p,e.disabled]),Je.useEffect(()=>{e.mode&&(p._options.mode=e.mode),e.reValidateMode&&(p._options.reValidateMode=e.reValidateMode)},[p,e.mode,e.reValidateMode]),Je.useEffect(()=>{e.errors&&(p._setErrors(e.errors),p._focusError())},[p,e.errors]),Je.useEffect(()=>{e.shouldUnregister&&p._subjects.state.next({values:p._getWatch()})},[p,e.shouldUnregister]),Je.useEffect(()=>{if(p._proxyFormState.isDirty){const m=p._getDirty();m!==o.isDirty&&p._subjects.state.next({isDirty:m})}},[p,o.isDirty]),Je.useEffect(()=>{var m;e.values&&!Wo(e.values,s.current)?(p._reset(e.values,{keepFieldsRef:!0,...p._options.resetOptions}),!((m=p._options.resetOptions)===null||m===void 0)&&m.keepIsValid||p._setValid(),s.current=e.values,d(g=>({...g}))):p._resetDefaultValues()},[p,e.values]),Je.useEffect(()=>{p._state.mount||(p._setValid(),p._state.mount=!0),p._state.watch&&(p._state.watch=!1,p._subjects.state.next({...p._formState})),p._removeUnmounted()}),r.current.formState=XF(o,p),r.current}const Q4=(e,r,s)=>{if(e&&"reportValidity"in e){const o=Et(s,r);e.setCustomValidity(o&&o.message||""),e.reportValidity()}},f_=(e,r)=>{for(const s in r.fields){const o=r.fields[s];o&&o.ref&&"reportValidity"in o.ref?Q4(o.ref,s,e):o&&o.refs&&o.refs.forEach(d=>Q4(d,s,e))}},e3=(e,r)=>{r.shouldUseNativeValidation&&f_(e,r);const s={};for(const o in e){const d=Et(r.fields,o),p=Object.assign(e[o]||{},{ref:d&&d.ref});if(Zhe(r.names||Object.keys(e),o)){const m=Object.assign({},Et(s,o));dr(m,"root",p),dr(s,o,m)}else dr(s,o,p)}return s},Zhe=(e,r)=>{const s=t3(r);return e.some(o=>t3(o).match(`^${s}\\.\\d+`))};function t3(e){return e.replace(/\]|\[/g,"")}function at(e,r,s){function o(g,b){if(g._zod||Object.defineProperty(g,"_zod",{value:{def:b,constr:m,traits:new Set},enumerable:!1}),g._zod.traits.has(e))return;g._zod.traits.add(e),r(g,b);const S=m.prototype,j=Object.keys(S);for(let A=0;As?.Parent&&g instanceof s.Parent?!0:g?._zod?.traits?.has(e)}),Object.defineProperty(m,"name",{value:e}),m}class gg extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class n6 extends Error{constructor(r){super(`Encountered unidirectional transform during encode: ${r}`),this.name="ZodEncodeError"}}const r6={};function Tp(e){return r6}function Whe(e){const r=Object.values(e).filter(o=>typeof o=="number");return Object.entries(e).filter(([o,d])=>r.indexOf(+o)===-1).map(([o,d])=>d)}function m_(e,r){return typeof r=="bigint"?r.toString():r}function W2(e){return{get value(){{const r=e();return Object.defineProperty(this,"value",{value:r}),r}}}}function J2(e){return e==null}function Q2(e){const r=e.startsWith("^")?1:0,s=e.endsWith("$")?e.length-1:e.length;return e.slice(r,s)}function Jhe(e,r){const s=(e.toString().split(".")[1]||"").length,o=r.toString();let d=(o.split(".")[1]||"").length;if(d===0&&/\d?e-\d?/.test(o)){const b=o.match(/\d?e-(\d?)/);b?.[1]&&(d=Number.parseInt(b[1]))}const p=s>d?s:d,m=Number.parseInt(e.toFixed(p).replace(".","")),g=Number.parseInt(r.toFixed(p).replace(".",""));return m%g/10**p}const n3=Symbol("evaluating");function Sr(e,r,s){let o;Object.defineProperty(e,r,{get(){if(o!==n3)return o===void 0&&(o=n3,o=s()),o},set(d){Object.defineProperty(e,r,{value:d})},configurable:!0})}function Dp(e,r,s){Object.defineProperty(e,r,{value:s,writable:!0,enumerable:!0,configurable:!0})}function Pp(...e){const r={};for(const s of e){const o=Object.getOwnPropertyDescriptors(s);Object.assign(r,o)}return Object.defineProperties({},r)}function r3(e){return JSON.stringify(e)}function Qhe(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}const s6="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function Jj(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}const epe=W2(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{const e=Function;return new e(""),!0}catch{return!1}});function Hb(e){if(Jj(e)===!1)return!1;const r=e.constructor;if(r===void 0||typeof r!="function")return!0;const s=r.prototype;return!(Jj(s)===!1||Object.prototype.hasOwnProperty.call(s,"isPrototypeOf")===!1)}function i6(e){return Hb(e)?{...e}:Array.isArray(e)?[...e]:e}const tpe=new Set(["string","number","symbol"]);function Eg(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Zd(e,r,s){const o=new e._zod.constr(r??e._zod.def);return(!r||s?.parent)&&(o._zod.parent=e),o}function Yt(e){const r=e;if(!r)return{};if(typeof r=="string")return{error:()=>r};if(r?.message!==void 0){if(r?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");r.error=r.message}return delete r.message,typeof r.error=="string"?{...r,error:()=>r.error}:r}function npe(e){return Object.keys(e).filter(r=>e[r]._zod.optin==="optional"&&e[r]._zod.optout==="optional")}const rpe={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]};function spe(e,r){const s=e._zod.def,o=Pp(e._zod.def,{get shape(){const d={};for(const p in r){if(!(p in s.shape))throw new Error(`Unrecognized key: "${p}"`);r[p]&&(d[p]=s.shape[p])}return Dp(this,"shape",d),d},checks:[]});return Zd(e,o)}function ipe(e,r){const s=e._zod.def,o=Pp(e._zod.def,{get shape(){const d={...e._zod.def.shape};for(const p in r){if(!(p in s.shape))throw new Error(`Unrecognized key: "${p}"`);r[p]&&delete d[p]}return Dp(this,"shape",d),d},checks:[]});return Zd(e,o)}function ape(e,r){if(!Hb(r))throw new Error("Invalid input to extend: expected a plain object");const s=e._zod.def.checks;if(s&&s.length>0)throw new Error("Object schemas containing refinements cannot be extended. Use `.safeExtend()` instead.");const d=Pp(e._zod.def,{get shape(){const p={...e._zod.def.shape,...r};return Dp(this,"shape",p),p},checks:[]});return Zd(e,d)}function ope(e,r){if(!Hb(r))throw new Error("Invalid input to safeExtend: expected a plain object");const s={...e._zod.def,get shape(){const o={...e._zod.def.shape,...r};return Dp(this,"shape",o),o},checks:e._zod.def.checks};return Zd(e,s)}function lpe(e,r){const s=Pp(e._zod.def,{get shape(){const o={...e._zod.def.shape,...r._zod.def.shape};return Dp(this,"shape",o),o},get catchall(){return r._zod.def.catchall},checks:[]});return Zd(e,s)}function cpe(e,r,s){const o=Pp(r._zod.def,{get shape(){const d=r._zod.def.shape,p={...d};if(s)for(const m in s){if(!(m in d))throw new Error(`Unrecognized key: "${m}"`);s[m]&&(p[m]=e?new e({type:"optional",innerType:d[m]}):d[m])}else for(const m in d)p[m]=e?new e({type:"optional",innerType:d[m]}):d[m];return Dp(this,"shape",p),p},checks:[]});return Zd(r,o)}function upe(e,r,s){const o=Pp(r._zod.def,{get shape(){const d=r._zod.def.shape,p={...d};if(s)for(const m in s){if(!(m in p))throw new Error(`Unrecognized key: "${m}"`);s[m]&&(p[m]=new e({type:"nonoptional",innerType:d[m]}))}else for(const m in d)p[m]=new e({type:"nonoptional",innerType:d[m]});return Dp(this,"shape",p),p},checks:[]});return Zd(r,o)}function dg(e,r=0){if(e.aborted===!0)return!0;for(let s=r;s{var o;return(o=s).path??(o.path=[]),s.path.unshift(e),s})}function aj(e){return typeof e=="string"?e:e?.message}function _p(e,r,s){const o={...e,path:e.path??[]};if(!e.message){const d=aj(e.inst?._zod.def?.error?.(e))??aj(r?.error?.(e))??aj(s.customError?.(e))??aj(s.localeError?.(e))??"Invalid input";o.message=d}return delete o.inst,delete o.continue,r?.reportInput||delete o.input,o}function e$(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function Gb(...e){const[r,s,o]=e;return typeof r=="string"?{message:r,code:"custom",input:s,inst:o}:{...r}}const o6=(e,r)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:r,enumerable:!1}),e.message=JSON.stringify(r,m_,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},t$=at("$ZodError",o6),qC=at("$ZodError",o6,{Parent:Error});function dpe(e,r=s=>s.message){const s={},o=[];for(const d of e.issues)d.path.length>0?(s[d.path[0]]=s[d.path[0]]||[],s[d.path[0]].push(r(d))):o.push(r(d));return{formErrors:o,fieldErrors:s}}function hpe(e,r=s=>s.message){const s={_errors:[]},o=d=>{for(const p of d.issues)if(p.code==="invalid_union"&&p.errors.length)p.errors.map(m=>o({issues:m}));else if(p.code==="invalid_key")o({issues:p.issues});else if(p.code==="invalid_element")o({issues:p.issues});else if(p.path.length===0)s._errors.push(r(p));else{let m=s,g=0;for(;g(r,s,o,d)=>{const p=o?Object.assign(o,{async:!1}):{async:!1},m=r._zod.run({value:s,issues:[]},p);if(m instanceof Promise)throw new gg;if(m.issues.length){const g=new(d?.Err??e)(m.issues.map(b=>_p(b,p,Tp())));throw s6(g,d?.callee),g}return m.value},ppe=BC(qC),UC=e=>async(r,s,o,d)=>{const p=o?Object.assign(o,{async:!0}):{async:!0};let m=r._zod.run({value:s,issues:[]},p);if(m instanceof Promise&&(m=await m),m.issues.length){const g=new(d?.Err??e)(m.issues.map(b=>_p(b,p,Tp())));throw s6(g,d?.callee),g}return m.value},fpe=UC(qC),KC=e=>(r,s,o)=>{const d=o?{...o,async:!1}:{async:!1},p=r._zod.run({value:s,issues:[]},d);if(p instanceof Promise)throw new gg;return p.issues.length?{success:!1,error:new(e??t$)(p.issues.map(m=>_p(m,d,Tp())))}:{success:!0,data:p.value}},mpe=KC(qC),VC=e=>async(r,s,o)=>{const d=o?Object.assign(o,{async:!0}):{async:!0};let p=r._zod.run({value:s,issues:[]},d);return p instanceof Promise&&(p=await p),p.issues.length?{success:!1,error:new e(p.issues.map(m=>_p(m,d,Tp())))}:{success:!0,data:p.value}},gpe=VC(qC),ype=e=>(r,s,o)=>{const d=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return BC(e)(r,s,d)},vpe=e=>(r,s,o)=>BC(e)(r,s,o),xpe=e=>async(r,s,o)=>{const d=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return UC(e)(r,s,d)},bpe=e=>async(r,s,o)=>UC(e)(r,s,o),wpe=e=>(r,s,o)=>{const d=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return KC(e)(r,s,d)},Spe=e=>(r,s,o)=>KC(e)(r,s,o),Epe=e=>async(r,s,o)=>{const d=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return VC(e)(r,s,d)},jpe=e=>async(r,s,o)=>VC(e)(r,s,o),Cpe=/^[cC][^\s-]{8,}$/,Ape=/^[0-9a-z]+$/,Ope=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,kpe=/^[0-9a-vA-V]{20}$/,Rpe=/^[A-Za-z0-9]{27}$/,Tpe=/^[a-zA-Z0-9_-]{21}$/,_pe=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,$pe=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,s3=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,Npe=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,Dpe="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function Ppe(){return new RegExp(Dpe,"u")}const Mpe=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,Ipe=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,Lpe=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,zpe=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Fpe=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,l6=/^[A-Za-z0-9_-]*$/,qpe=/^\+(?:[0-9]){6,14}[0-9]$/,c6="(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))",Bpe=new RegExp(`^${c6}$`);function u6(e){const r="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${r}`:e.precision===0?`${r}:[0-5]\\d`:`${r}:[0-5]\\d\\.\\d{${e.precision}}`:`${r}(?::[0-5]\\d(?:\\.\\d+)?)?`}function Upe(e){return new RegExp(`^${u6(e)}$`)}function Kpe(e){const r=u6({precision:e.precision}),s=["Z"];e.local&&s.push(""),e.offset&&s.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");const o=`${r}(?:${s.join("|")})`;return new RegExp(`^${c6}T(?:${o})$`)}const Vpe=e=>{const r=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${r}$`)},Hpe=/^-?\d+$/,Gpe=/^-?\d+(?:\.\d+)?/,Xpe=/^[^A-Z]*$/,Ype=/^[^a-z]*$/,pa=at("$ZodCheck",(e,r)=>{var s;e._zod??(e._zod={}),e._zod.def=r,(s=e._zod).onattach??(s.onattach=[])}),d6={number:"number",bigint:"bigint",object:"date"},h6=at("$ZodCheckLessThan",(e,r)=>{pa.init(e,r);const s=d6[typeof r.value];e._zod.onattach.push(o=>{const d=o._zod.bag,p=(r.inclusive?d.maximum:d.exclusiveMaximum)??Number.POSITIVE_INFINITY;r.value{(r.inclusive?o.value<=r.value:o.value{pa.init(e,r);const s=d6[typeof r.value];e._zod.onattach.push(o=>{const d=o._zod.bag,p=(r.inclusive?d.minimum:d.exclusiveMinimum)??Number.NEGATIVE_INFINITY;r.value>p&&(r.inclusive?d.minimum=r.value:d.exclusiveMinimum=r.value)}),e._zod.check=o=>{(r.inclusive?o.value>=r.value:o.value>r.value)||o.issues.push({origin:s,code:"too_small",minimum:r.value,input:o.value,inclusive:r.inclusive,inst:e,continue:!r.abort})}}),Zpe=at("$ZodCheckMultipleOf",(e,r)=>{pa.init(e,r),e._zod.onattach.push(s=>{var o;(o=s._zod.bag).multipleOf??(o.multipleOf=r.value)}),e._zod.check=s=>{if(typeof s.value!=typeof r.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof s.value=="bigint"?s.value%r.value===BigInt(0):Jhe(s.value,r.value)===0)||s.issues.push({origin:typeof s.value,code:"not_multiple_of",divisor:r.value,input:s.value,inst:e,continue:!r.abort})}}),Wpe=at("$ZodCheckNumberFormat",(e,r)=>{pa.init(e,r),r.format=r.format||"float64";const s=r.format?.includes("int"),o=s?"int":"number",[d,p]=rpe[r.format];e._zod.onattach.push(m=>{const g=m._zod.bag;g.format=r.format,g.minimum=d,g.maximum=p,s&&(g.pattern=Hpe)}),e._zod.check=m=>{const g=m.value;if(s){if(!Number.isInteger(g)){m.issues.push({expected:o,format:r.format,code:"invalid_type",continue:!1,input:g,inst:e});return}if(!Number.isSafeInteger(g)){g>0?m.issues.push({input:g,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:o,continue:!r.abort}):m.issues.push({input:g,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:o,continue:!r.abort});return}}gp&&m.issues.push({origin:"number",input:g,code:"too_big",maximum:p,inst:e})}}),Jpe=at("$ZodCheckMaxLength",(e,r)=>{var s;pa.init(e,r),(s=e._zod.def).when??(s.when=o=>{const d=o.value;return!J2(d)&&d.length!==void 0}),e._zod.onattach.push(o=>{const d=o._zod.bag.maximum??Number.POSITIVE_INFINITY;r.maximum{const d=o.value;if(d.length<=r.maximum)return;const m=e$(d);o.issues.push({origin:m,code:"too_big",maximum:r.maximum,inclusive:!0,input:d,inst:e,continue:!r.abort})}}),Qpe=at("$ZodCheckMinLength",(e,r)=>{var s;pa.init(e,r),(s=e._zod.def).when??(s.when=o=>{const d=o.value;return!J2(d)&&d.length!==void 0}),e._zod.onattach.push(o=>{const d=o._zod.bag.minimum??Number.NEGATIVE_INFINITY;r.minimum>d&&(o._zod.bag.minimum=r.minimum)}),e._zod.check=o=>{const d=o.value;if(d.length>=r.minimum)return;const m=e$(d);o.issues.push({origin:m,code:"too_small",minimum:r.minimum,inclusive:!0,input:d,inst:e,continue:!r.abort})}}),efe=at("$ZodCheckLengthEquals",(e,r)=>{var s;pa.init(e,r),(s=e._zod.def).when??(s.when=o=>{const d=o.value;return!J2(d)&&d.length!==void 0}),e._zod.onattach.push(o=>{const d=o._zod.bag;d.minimum=r.length,d.maximum=r.length,d.length=r.length}),e._zod.check=o=>{const d=o.value,p=d.length;if(p===r.length)return;const m=e$(d),g=p>r.length;o.issues.push({origin:m,...g?{code:"too_big",maximum:r.length}:{code:"too_small",minimum:r.length},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!r.abort})}}),HC=at("$ZodCheckStringFormat",(e,r)=>{var s,o;pa.init(e,r),e._zod.onattach.push(d=>{const p=d._zod.bag;p.format=r.format,r.pattern&&(p.patterns??(p.patterns=new Set),p.patterns.add(r.pattern))}),r.pattern?(s=e._zod).check??(s.check=d=>{r.pattern.lastIndex=0,!r.pattern.test(d.value)&&d.issues.push({origin:"string",code:"invalid_format",format:r.format,input:d.value,...r.pattern?{pattern:r.pattern.toString()}:{},inst:e,continue:!r.abort})}):(o=e._zod).check??(o.check=()=>{})}),tfe=at("$ZodCheckRegex",(e,r)=>{HC.init(e,r),e._zod.check=s=>{r.pattern.lastIndex=0,!r.pattern.test(s.value)&&s.issues.push({origin:"string",code:"invalid_format",format:"regex",input:s.value,pattern:r.pattern.toString(),inst:e,continue:!r.abort})}}),nfe=at("$ZodCheckLowerCase",(e,r)=>{r.pattern??(r.pattern=Xpe),HC.init(e,r)}),rfe=at("$ZodCheckUpperCase",(e,r)=>{r.pattern??(r.pattern=Ype),HC.init(e,r)}),sfe=at("$ZodCheckIncludes",(e,r)=>{pa.init(e,r);const s=Eg(r.includes),o=new RegExp(typeof r.position=="number"?`^.{${r.position}}${s}`:s);r.pattern=o,e._zod.onattach.push(d=>{const p=d._zod.bag;p.patterns??(p.patterns=new Set),p.patterns.add(o)}),e._zod.check=d=>{d.value.includes(r.includes,r.position)||d.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:r.includes,input:d.value,inst:e,continue:!r.abort})}}),ife=at("$ZodCheckStartsWith",(e,r)=>{pa.init(e,r);const s=new RegExp(`^${Eg(r.prefix)}.*`);r.pattern??(r.pattern=s),e._zod.onattach.push(o=>{const d=o._zod.bag;d.patterns??(d.patterns=new Set),d.patterns.add(s)}),e._zod.check=o=>{o.value.startsWith(r.prefix)||o.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:r.prefix,input:o.value,inst:e,continue:!r.abort})}}),afe=at("$ZodCheckEndsWith",(e,r)=>{pa.init(e,r);const s=new RegExp(`.*${Eg(r.suffix)}$`);r.pattern??(r.pattern=s),e._zod.onattach.push(o=>{const d=o._zod.bag;d.patterns??(d.patterns=new Set),d.patterns.add(s)}),e._zod.check=o=>{o.value.endsWith(r.suffix)||o.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:r.suffix,input:o.value,inst:e,continue:!r.abort})}}),ofe=at("$ZodCheckOverwrite",(e,r)=>{pa.init(e,r),e._zod.check=s=>{s.value=r.tx(s.value)}});class lfe{constructor(r=[]){this.content=[],this.indent=0,this&&(this.args=r)}indented(r){this.indent+=1,r(this),this.indent-=1}write(r){if(typeof r=="function"){r(this,{execution:"sync"}),r(this,{execution:"async"});return}const o=r.split(` -`).filter(m=>m),d=Math.min(...o.map(m=>m.length-m.trimStart().length)),p=o.map(m=>m.slice(d)).map(m=>" ".repeat(this.indent*2)+m);for(const m of p)this.content.push(m)}compile(){const r=Function,s=this?.args,d=[...(this?.content??[""]).map(p=>` ${p}`)];return new r(...s,d.join(` -`))}}const cfe={major:4,minor:1,patch:13},Gr=at("$ZodType",(e,r)=>{var s;e??(e={}),e._zod.def=r,e._zod.bag=e._zod.bag||{},e._zod.version=cfe;const o=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&o.unshift(e);for(const d of o)for(const p of d._zod.onattach)p(e);if(o.length===0)(s=e._zod).deferred??(s.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{const d=(m,g,b)=>{let S=dg(m),j;for(const A of g){if(A._zod.def.when){if(!A._zod.def.when(m))continue}else if(S)continue;const k=m.issues.length,T=A._zod.check(m);if(T instanceof Promise&&b?.async===!1)throw new gg;if(j||T instanceof Promise)j=(j??Promise.resolve()).then(async()=>{await T,m.issues.length!==k&&(S||(S=dg(m,k)))});else{if(m.issues.length===k)continue;S||(S=dg(m,k))}}return j?j.then(()=>m):m},p=(m,g,b)=>{if(dg(m))return m.aborted=!0,m;const S=d(g,o,b);if(S instanceof Promise){if(b.async===!1)throw new gg;return S.then(j=>e._zod.parse(j,b))}return e._zod.parse(S,b)};e._zod.run=(m,g)=>{if(g.skipChecks)return e._zod.parse(m,g);if(g.direction==="backward"){const S=e._zod.parse({value:m.value,issues:[]},{...g,skipChecks:!0});return S instanceof Promise?S.then(j=>p(j,m,g)):p(S,m,g)}const b=e._zod.parse(m,g);if(b instanceof Promise){if(g.async===!1)throw new gg;return b.then(S=>d(S,o,g))}return d(b,o,g)}}e["~standard"]={validate:d=>{try{const p=mpe(e,d);return p.success?{value:p.data}:{issues:p.error?.issues}}catch{return gpe(e,d).then(m=>m.success?{value:m.data}:{issues:m.error?.issues})}},vendor:"zod",version:1}}),n$=at("$ZodString",(e,r)=>{Gr.init(e,r),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??Vpe(e._zod.bag),e._zod.parse=(s,o)=>{if(r.coerce)try{s.value=String(s.value)}catch{}return typeof s.value=="string"||s.issues.push({expected:"string",code:"invalid_type",input:s.value,inst:e}),s}}),$r=at("$ZodStringFormat",(e,r)=>{HC.init(e,r),n$.init(e,r)}),ufe=at("$ZodGUID",(e,r)=>{r.pattern??(r.pattern=$pe),$r.init(e,r)}),dfe=at("$ZodUUID",(e,r)=>{if(r.version){const o={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[r.version];if(o===void 0)throw new Error(`Invalid UUID version: "${r.version}"`);r.pattern??(r.pattern=s3(o))}else r.pattern??(r.pattern=s3());$r.init(e,r)}),hfe=at("$ZodEmail",(e,r)=>{r.pattern??(r.pattern=Npe),$r.init(e,r)}),pfe=at("$ZodURL",(e,r)=>{$r.init(e,r),e._zod.check=s=>{try{const o=s.value.trim(),d=new URL(o);r.hostname&&(r.hostname.lastIndex=0,r.hostname.test(d.hostname)||s.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:r.hostname.source,input:s.value,inst:e,continue:!r.abort})),r.protocol&&(r.protocol.lastIndex=0,r.protocol.test(d.protocol.endsWith(":")?d.protocol.slice(0,-1):d.protocol)||s.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:r.protocol.source,input:s.value,inst:e,continue:!r.abort})),r.normalize?s.value=d.href:s.value=o;return}catch{s.issues.push({code:"invalid_format",format:"url",input:s.value,inst:e,continue:!r.abort})}}}),ffe=at("$ZodEmoji",(e,r)=>{r.pattern??(r.pattern=Ppe()),$r.init(e,r)}),mfe=at("$ZodNanoID",(e,r)=>{r.pattern??(r.pattern=Tpe),$r.init(e,r)}),gfe=at("$ZodCUID",(e,r)=>{r.pattern??(r.pattern=Cpe),$r.init(e,r)}),yfe=at("$ZodCUID2",(e,r)=>{r.pattern??(r.pattern=Ape),$r.init(e,r)}),vfe=at("$ZodULID",(e,r)=>{r.pattern??(r.pattern=Ope),$r.init(e,r)}),xfe=at("$ZodXID",(e,r)=>{r.pattern??(r.pattern=kpe),$r.init(e,r)}),bfe=at("$ZodKSUID",(e,r)=>{r.pattern??(r.pattern=Rpe),$r.init(e,r)}),wfe=at("$ZodISODateTime",(e,r)=>{r.pattern??(r.pattern=Kpe(r)),$r.init(e,r)}),Sfe=at("$ZodISODate",(e,r)=>{r.pattern??(r.pattern=Bpe),$r.init(e,r)}),Efe=at("$ZodISOTime",(e,r)=>{r.pattern??(r.pattern=Upe(r)),$r.init(e,r)}),jfe=at("$ZodISODuration",(e,r)=>{r.pattern??(r.pattern=_pe),$r.init(e,r)}),Cfe=at("$ZodIPv4",(e,r)=>{r.pattern??(r.pattern=Mpe),$r.init(e,r),e._zod.bag.format="ipv4"}),Afe=at("$ZodIPv6",(e,r)=>{r.pattern??(r.pattern=Ipe),$r.init(e,r),e._zod.bag.format="ipv6",e._zod.check=s=>{try{new URL(`http://[${s.value}]`)}catch{s.issues.push({code:"invalid_format",format:"ipv6",input:s.value,inst:e,continue:!r.abort})}}}),Ofe=at("$ZodCIDRv4",(e,r)=>{r.pattern??(r.pattern=Lpe),$r.init(e,r)}),kfe=at("$ZodCIDRv6",(e,r)=>{r.pattern??(r.pattern=zpe),$r.init(e,r),e._zod.check=s=>{const o=s.value.split("/");try{if(o.length!==2)throw new Error;const[d,p]=o;if(!p)throw new Error;const m=Number(p);if(`${m}`!==p)throw new Error;if(m<0||m>128)throw new Error;new URL(`http://[${d}]`)}catch{s.issues.push({code:"invalid_format",format:"cidrv6",input:s.value,inst:e,continue:!r.abort})}}});function f6(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}const Rfe=at("$ZodBase64",(e,r)=>{r.pattern??(r.pattern=Fpe),$r.init(e,r),e._zod.bag.contentEncoding="base64",e._zod.check=s=>{f6(s.value)||s.issues.push({code:"invalid_format",format:"base64",input:s.value,inst:e,continue:!r.abort})}});function Tfe(e){if(!l6.test(e))return!1;const r=e.replace(/[-_]/g,o=>o==="-"?"+":"/"),s=r.padEnd(Math.ceil(r.length/4)*4,"=");return f6(s)}const _fe=at("$ZodBase64URL",(e,r)=>{r.pattern??(r.pattern=l6),$r.init(e,r),e._zod.bag.contentEncoding="base64url",e._zod.check=s=>{Tfe(s.value)||s.issues.push({code:"invalid_format",format:"base64url",input:s.value,inst:e,continue:!r.abort})}}),$fe=at("$ZodE164",(e,r)=>{r.pattern??(r.pattern=qpe),$r.init(e,r)});function Nfe(e,r=null){try{const s=e.split(".");if(s.length!==3)return!1;const[o]=s;if(!o)return!1;const d=JSON.parse(atob(o));return!("typ"in d&&d?.typ!=="JWT"||!d.alg||r&&(!("alg"in d)||d.alg!==r))}catch{return!1}}const Dfe=at("$ZodJWT",(e,r)=>{$r.init(e,r),e._zod.check=s=>{Nfe(s.value,r.alg)||s.issues.push({code:"invalid_format",format:"jwt",input:s.value,inst:e,continue:!r.abort})}}),m6=at("$ZodNumber",(e,r)=>{Gr.init(e,r),e._zod.pattern=e._zod.bag.pattern??Gpe,e._zod.parse=(s,o)=>{if(r.coerce)try{s.value=Number(s.value)}catch{}const d=s.value;if(typeof d=="number"&&!Number.isNaN(d)&&Number.isFinite(d))return s;const p=typeof d=="number"?Number.isNaN(d)?"NaN":Number.isFinite(d)?void 0:"Infinity":void 0;return s.issues.push({expected:"number",code:"invalid_type",input:d,inst:e,...p?{received:p}:{}}),s}}),Pfe=at("$ZodNumberFormat",(e,r)=>{Wpe.init(e,r),m6.init(e,r)}),Mfe=at("$ZodAny",(e,r)=>{Gr.init(e,r),e._zod.parse=s=>s}),Ife=at("$ZodUnknown",(e,r)=>{Gr.init(e,r),e._zod.parse=s=>s}),Lfe=at("$ZodNever",(e,r)=>{Gr.init(e,r),e._zod.parse=(s,o)=>(s.issues.push({expected:"never",code:"invalid_type",input:s.value,inst:e}),s)});function i3(e,r,s){e.issues.length&&r.issues.push(...a6(s,e.issues)),r.value[s]=e.value}const zfe=at("$ZodArray",(e,r)=>{Gr.init(e,r),e._zod.parse=(s,o)=>{const d=s.value;if(!Array.isArray(d))return s.issues.push({expected:"array",code:"invalid_type",input:d,inst:e}),s;s.value=Array(d.length);const p=[];for(let m=0;mi3(S,s,m))):i3(b,s,m)}return p.length?Promise.all(p).then(()=>s):s}});function Qj(e,r,s,o){e.issues.length&&r.issues.push(...a6(s,e.issues)),e.value===void 0?s in o&&(r.value[s]=void 0):r.value[s]=e.value}function g6(e){const r=Object.keys(e.shape);for(const o of r)if(!e.shape?.[o]?._zod?.traits?.has("$ZodType"))throw new Error(`Invalid element at key "${o}": expected a Zod schema`);const s=npe(e.shape);return{...e,keys:r,keySet:new Set(r),numKeys:r.length,optionalKeys:new Set(s)}}function y6(e,r,s,o,d,p){const m=[],g=d.keySet,b=d.catchall._zod,S=b.def.type;for(const j in r){if(g.has(j))continue;if(S==="never"){m.push(j);continue}const A=b.run({value:r[j],issues:[]},o);A instanceof Promise?e.push(A.then(k=>Qj(k,s,j,r))):Qj(A,s,j,r)}return m.length&&s.issues.push({code:"unrecognized_keys",keys:m,input:r,inst:p}),e.length?Promise.all(e).then(()=>s):s}const Ffe=at("$ZodObject",(e,r)=>{if(Gr.init(e,r),!Object.getOwnPropertyDescriptor(r,"shape")?.get){const g=r.shape;Object.defineProperty(r,"shape",{get:()=>{const b={...g};return Object.defineProperty(r,"shape",{value:b}),b}})}const o=W2(()=>g6(r));Sr(e._zod,"propValues",()=>{const g=r.shape,b={};for(const S in g){const j=g[S]._zod;if(j.values){b[S]??(b[S]=new Set);for(const A of j.values)b[S].add(A)}}return b});const d=Jj,p=r.catchall;let m;e._zod.parse=(g,b)=>{m??(m=o.value);const S=g.value;if(!d(S))return g.issues.push({expected:"object",code:"invalid_type",input:S,inst:e}),g;g.value={};const j=[],A=m.shape;for(const k of m.keys){const M=A[k]._zod.run({value:S[k],issues:[]},b);M instanceof Promise?j.push(M.then(I=>Qj(I,g,k,S))):Qj(M,g,k,S)}return p?y6(j,S,g,b,o.value,e):j.length?Promise.all(j).then(()=>g):g}}),qfe=at("$ZodObjectJIT",(e,r)=>{Ffe.init(e,r);const s=e._zod.parse,o=W2(()=>g6(r)),d=k=>{const T=new lfe(["shape","payload","ctx"]),M=o.value,I=X=>{const L=r3(X);return`shape[${L}]._zod.run({ value: input[${L}], issues: [] }, ctx)`};T.write("const input = payload.value;");const q=Object.create(null);let G=0;for(const X of M.keys)q[X]=`key_${G++}`;T.write("const newResult = {};");for(const X of M.keys){const L=q[X],ee=r3(X);T.write(`const ${L} = ${I(X)};`),T.write(` - if (${L}.issues.length) { - payload.issues = payload.issues.concat(${L}.issues.map(iss => ({ - ...iss, - path: iss.path ? [${ee}, ...iss.path] : [${ee}] - }))); - } - - - if (${L}.value === undefined) { - if (${ee} in input) { - newResult[${ee}] = undefined; - } - } else { - newResult[${ee}] = ${L}.value; - } - - `)}T.write("payload.value = newResult;"),T.write("return payload;");const K=T.compile();return(X,L)=>K(k,X,L)};let p;const m=Jj,g=!r6.jitless,S=g&&epe.value,j=r.catchall;let A;e._zod.parse=(k,T)=>{A??(A=o.value);const M=k.value;return m(M)?g&&S&&T?.async===!1&&T.jitless!==!0?(p||(p=d(r.shape)),k=p(k,T),j?y6([],M,k,T,A,e):k):s(k,T):(k.issues.push({expected:"object",code:"invalid_type",input:M,inst:e}),k)}});function a3(e,r,s,o){for(const p of e)if(p.issues.length===0)return r.value=p.value,r;const d=e.filter(p=>!dg(p));return d.length===1?(r.value=d[0].value,d[0]):(r.issues.push({code:"invalid_union",input:r.value,inst:s,errors:e.map(p=>p.issues.map(m=>_p(m,o,Tp())))}),r)}const Bfe=at("$ZodUnion",(e,r)=>{Gr.init(e,r),Sr(e._zod,"optin",()=>r.options.some(d=>d._zod.optin==="optional")?"optional":void 0),Sr(e._zod,"optout",()=>r.options.some(d=>d._zod.optout==="optional")?"optional":void 0),Sr(e._zod,"values",()=>{if(r.options.every(d=>d._zod.values))return new Set(r.options.flatMap(d=>Array.from(d._zod.values)))}),Sr(e._zod,"pattern",()=>{if(r.options.every(d=>d._zod.pattern)){const d=r.options.map(p=>p._zod.pattern);return new RegExp(`^(${d.map(p=>Q2(p.source)).join("|")})$`)}});const s=r.options.length===1,o=r.options[0]._zod.run;e._zod.parse=(d,p)=>{if(s)return o(d,p);let m=!1;const g=[];for(const b of r.options){const S=b._zod.run({value:d.value,issues:[]},p);if(S instanceof Promise)g.push(S),m=!0;else{if(S.issues.length===0)return S;g.push(S)}}return m?Promise.all(g).then(b=>a3(b,d,e,p)):a3(g,d,e,p)}}),Ufe=at("$ZodIntersection",(e,r)=>{Gr.init(e,r),e._zod.parse=(s,o)=>{const d=s.value,p=r.left._zod.run({value:d,issues:[]},o),m=r.right._zod.run({value:d,issues:[]},o);return p instanceof Promise||m instanceof Promise?Promise.all([p,m]).then(([b,S])=>o3(s,b,S)):o3(s,p,m)}});function g_(e,r){if(e===r)return{valid:!0,data:e};if(e instanceof Date&&r instanceof Date&&+e==+r)return{valid:!0,data:e};if(Hb(e)&&Hb(r)){const s=Object.keys(r),o=Object.keys(e).filter(p=>s.indexOf(p)!==-1),d={...e,...r};for(const p of o){const m=g_(e[p],r[p]);if(!m.valid)return{valid:!1,mergeErrorPath:[p,...m.mergeErrorPath]};d[p]=m.data}return{valid:!0,data:d}}if(Array.isArray(e)&&Array.isArray(r)){if(e.length!==r.length)return{valid:!1,mergeErrorPath:[]};const s=[];for(let o=0;o{Gr.init(e,r);const s=Whe(r.entries),o=new Set(s);e._zod.values=o,e._zod.pattern=new RegExp(`^(${s.filter(d=>tpe.has(typeof d)).map(d=>typeof d=="string"?Eg(d):d.toString()).join("|")})$`),e._zod.parse=(d,p)=>{const m=d.value;return o.has(m)||d.issues.push({code:"invalid_value",values:s,input:m,inst:e}),d}}),Vfe=at("$ZodLiteral",(e,r)=>{if(Gr.init(e,r),r.values.length===0)throw new Error("Cannot create literal schema with no valid values");const s=new Set(r.values);e._zod.values=s,e._zod.pattern=new RegExp(`^(${r.values.map(o=>typeof o=="string"?Eg(o):o?Eg(o.toString()):String(o)).join("|")})$`),e._zod.parse=(o,d)=>{const p=o.value;return s.has(p)||o.issues.push({code:"invalid_value",values:r.values,input:p,inst:e}),o}}),Hfe=at("$ZodTransform",(e,r)=>{Gr.init(e,r),e._zod.parse=(s,o)=>{if(o.direction==="backward")throw new n6(e.constructor.name);const d=r.transform(s.value,s);if(o.async)return(d instanceof Promise?d:Promise.resolve(d)).then(m=>(s.value=m,s));if(d instanceof Promise)throw new gg;return s.value=d,s}});function l3(e,r){return e.issues.length&&r===void 0?{issues:[],value:void 0}:e}const Gfe=at("$ZodOptional",(e,r)=>{Gr.init(e,r),e._zod.optin="optional",e._zod.optout="optional",Sr(e._zod,"values",()=>r.innerType._zod.values?new Set([...r.innerType._zod.values,void 0]):void 0),Sr(e._zod,"pattern",()=>{const s=r.innerType._zod.pattern;return s?new RegExp(`^(${Q2(s.source)})?$`):void 0}),e._zod.parse=(s,o)=>{if(r.innerType._zod.optin==="optional"){const d=r.innerType._zod.run(s,o);return d instanceof Promise?d.then(p=>l3(p,s.value)):l3(d,s.value)}return s.value===void 0?s:r.innerType._zod.run(s,o)}}),Xfe=at("$ZodNullable",(e,r)=>{Gr.init(e,r),Sr(e._zod,"optin",()=>r.innerType._zod.optin),Sr(e._zod,"optout",()=>r.innerType._zod.optout),Sr(e._zod,"pattern",()=>{const s=r.innerType._zod.pattern;return s?new RegExp(`^(${Q2(s.source)}|null)$`):void 0}),Sr(e._zod,"values",()=>r.innerType._zod.values?new Set([...r.innerType._zod.values,null]):void 0),e._zod.parse=(s,o)=>s.value===null?s:r.innerType._zod.run(s,o)}),Yfe=at("$ZodDefault",(e,r)=>{Gr.init(e,r),e._zod.optin="optional",Sr(e._zod,"values",()=>r.innerType._zod.values),e._zod.parse=(s,o)=>{if(o.direction==="backward")return r.innerType._zod.run(s,o);if(s.value===void 0)return s.value=r.defaultValue,s;const d=r.innerType._zod.run(s,o);return d instanceof Promise?d.then(p=>c3(p,r)):c3(d,r)}});function c3(e,r){return e.value===void 0&&(e.value=r.defaultValue),e}const Zfe=at("$ZodPrefault",(e,r)=>{Gr.init(e,r),e._zod.optin="optional",Sr(e._zod,"values",()=>r.innerType._zod.values),e._zod.parse=(s,o)=>(o.direction==="backward"||s.value===void 0&&(s.value=r.defaultValue),r.innerType._zod.run(s,o))}),Wfe=at("$ZodNonOptional",(e,r)=>{Gr.init(e,r),Sr(e._zod,"values",()=>{const s=r.innerType._zod.values;return s?new Set([...s].filter(o=>o!==void 0)):void 0}),e._zod.parse=(s,o)=>{const d=r.innerType._zod.run(s,o);return d instanceof Promise?d.then(p=>u3(p,e)):u3(d,e)}});function u3(e,r){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:r}),e}const Jfe=at("$ZodCatch",(e,r)=>{Gr.init(e,r),Sr(e._zod,"optin",()=>r.innerType._zod.optin),Sr(e._zod,"optout",()=>r.innerType._zod.optout),Sr(e._zod,"values",()=>r.innerType._zod.values),e._zod.parse=(s,o)=>{if(o.direction==="backward")return r.innerType._zod.run(s,o);const d=r.innerType._zod.run(s,o);return d instanceof Promise?d.then(p=>(s.value=p.value,p.issues.length&&(s.value=r.catchValue({...s,error:{issues:p.issues.map(m=>_p(m,o,Tp()))},input:s.value}),s.issues=[]),s)):(s.value=d.value,d.issues.length&&(s.value=r.catchValue({...s,error:{issues:d.issues.map(p=>_p(p,o,Tp()))},input:s.value}),s.issues=[]),s)}}),Qfe=at("$ZodPipe",(e,r)=>{Gr.init(e,r),Sr(e._zod,"values",()=>r.in._zod.values),Sr(e._zod,"optin",()=>r.in._zod.optin),Sr(e._zod,"optout",()=>r.out._zod.optout),Sr(e._zod,"propValues",()=>r.in._zod.propValues),e._zod.parse=(s,o)=>{if(o.direction==="backward"){const p=r.out._zod.run(s,o);return p instanceof Promise?p.then(m=>oj(m,r.in,o)):oj(p,r.in,o)}const d=r.in._zod.run(s,o);return d instanceof Promise?d.then(p=>oj(p,r.out,o)):oj(d,r.out,o)}});function oj(e,r,s){return e.issues.length?(e.aborted=!0,e):r._zod.run({value:e.value,issues:e.issues},s)}const eme=at("$ZodReadonly",(e,r)=>{Gr.init(e,r),Sr(e._zod,"propValues",()=>r.innerType._zod.propValues),Sr(e._zod,"values",()=>r.innerType._zod.values),Sr(e._zod,"optin",()=>r.innerType?._zod?.optin),Sr(e._zod,"optout",()=>r.innerType?._zod?.optout),e._zod.parse=(s,o)=>{if(o.direction==="backward")return r.innerType._zod.run(s,o);const d=r.innerType._zod.run(s,o);return d instanceof Promise?d.then(d3):d3(d)}});function d3(e){return e.value=Object.freeze(e.value),e}const tme=at("$ZodCustom",(e,r)=>{pa.init(e,r),Gr.init(e,r),e._zod.parse=(s,o)=>s,e._zod.check=s=>{const o=s.value,d=r.fn(o);if(d instanceof Promise)return d.then(p=>h3(p,s,o,e));h3(d,s,o,e)}});function h3(e,r,s,o){if(!e){const d={code:"custom",input:s,inst:o,path:[...o._zod.def.path??[]],continue:!o._zod.def.abort};o._zod.def.params&&(d.params=o._zod.def.params),r.issues.push(Gb(d))}}var p3;class nme{constructor(){this._map=new WeakMap,this._idmap=new Map}add(r,...s){const o=s[0];if(this._map.set(r,o),o&&typeof o=="object"&&"id"in o){if(this._idmap.has(o.id))throw new Error(`ID ${o.id} already exists in the registry`);this._idmap.set(o.id,r)}return this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(r){const s=this._map.get(r);return s&&typeof s=="object"&&"id"in s&&this._idmap.delete(s.id),this._map.delete(r),this}get(r){const s=r._zod.parent;if(s){const o={...this.get(s)??{}};delete o.id;const d={...o,...this._map.get(r)};return Object.keys(d).length?d:void 0}return this._map.get(r)}has(r){return this._map.has(r)}}function rme(){return new nme}(p3=globalThis).__zod_globalRegistry??(p3.__zod_globalRegistry=rme());const lj=globalThis.__zod_globalRegistry;function sme(e,r){return new e({type:"string",...Yt(r)})}function ime(e,r){return new e({type:"string",format:"email",check:"string_format",abort:!1,...Yt(r)})}function f3(e,r){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...Yt(r)})}function v6(e,r){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...Yt(r)})}function ame(e,r){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...Yt(r)})}function ome(e,r){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...Yt(r)})}function lme(e,r){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...Yt(r)})}function cme(e,r){return new e({type:"string",format:"url",check:"string_format",abort:!1,...Yt(r)})}function ume(e,r){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...Yt(r)})}function dme(e,r){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...Yt(r)})}function hme(e,r){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...Yt(r)})}function pme(e,r){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...Yt(r)})}function fme(e,r){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...Yt(r)})}function mme(e,r){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...Yt(r)})}function gme(e,r){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...Yt(r)})}function yme(e,r){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...Yt(r)})}function vme(e,r){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...Yt(r)})}function xme(e,r){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...Yt(r)})}function bme(e,r){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...Yt(r)})}function wme(e,r){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...Yt(r)})}function Sme(e,r){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...Yt(r)})}function Eme(e,r){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...Yt(r)})}function jme(e,r){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...Yt(r)})}function Cme(e,r){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...Yt(r)})}function Ame(e,r){return new e({type:"string",format:"date",check:"string_format",...Yt(r)})}function Ome(e,r){return new e({type:"string",format:"time",check:"string_format",precision:null,...Yt(r)})}function kme(e,r){return new e({type:"string",format:"duration",check:"string_format",...Yt(r)})}function Rme(e,r){return new e({type:"number",checks:[],...Yt(r)})}function Tme(e,r){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...Yt(r)})}function _me(e){return new e({type:"any"})}function $me(e){return new e({type:"unknown"})}function Nme(e,r){return new e({type:"never",...Yt(r)})}function m3(e,r){return new h6({check:"less_than",...Yt(r),value:e,inclusive:!1})}function pT(e,r){return new h6({check:"less_than",...Yt(r),value:e,inclusive:!0})}function g3(e,r){return new p6({check:"greater_than",...Yt(r),value:e,inclusive:!1})}function fT(e,r){return new p6({check:"greater_than",...Yt(r),value:e,inclusive:!0})}function y3(e,r){return new Zpe({check:"multiple_of",...Yt(r),value:e})}function x6(e,r){return new Jpe({check:"max_length",...Yt(r),maximum:e})}function eC(e,r){return new Qpe({check:"min_length",...Yt(r),minimum:e})}function b6(e,r){return new efe({check:"length_equals",...Yt(r),length:e})}function Dme(e,r){return new tfe({check:"string_format",format:"regex",...Yt(r),pattern:e})}function Pme(e){return new nfe({check:"string_format",format:"lowercase",...Yt(e)})}function Mme(e){return new rfe({check:"string_format",format:"uppercase",...Yt(e)})}function Ime(e,r){return new sfe({check:"string_format",format:"includes",...Yt(r),includes:e})}function Lme(e,r){return new ife({check:"string_format",format:"starts_with",...Yt(r),prefix:e})}function zme(e,r){return new afe({check:"string_format",format:"ends_with",...Yt(r),suffix:e})}function Mg(e){return new ofe({check:"overwrite",tx:e})}function Fme(e){return Mg(r=>r.normalize(e))}function qme(){return Mg(e=>e.trim())}function Bme(){return Mg(e=>e.toLowerCase())}function Ume(){return Mg(e=>e.toUpperCase())}function Kme(){return Mg(e=>Qhe(e))}function Vme(e,r,s){return new e({type:"array",element:r,...Yt(s)})}function Hme(e,r,s){return new e({type:"custom",check:"custom",fn:r,...Yt(s)})}function Gme(e){const r=Xme(s=>(s.addIssue=o=>{if(typeof o=="string")s.issues.push(Gb(o,s.value,r._zod.def));else{const d=o;d.fatal&&(d.continue=!1),d.code??(d.code="custom"),d.input??(d.input=s.value),d.inst??(d.inst=r),d.continue??(d.continue=!r._zod.def.abort),s.issues.push(Gb(d))}},e(s.value,s)));return r}function Xme(e,r){const s=new pa({check:"custom",...Yt(r)});return s._zod.check=e,s}function v3(e,r){try{var s=e()}catch(o){return r(o)}return s&&s.then?s.then(void 0,r):s}function Yme(e,r){for(var s={};e.length;){var o=e[0],d=o.code,p=o.message,m=o.path.join(".");if(!s[m])if("unionErrors"in o){var g=o.unionErrors[0].errors[0];s[m]={message:g.message,type:g.code}}else s[m]={message:p,type:d};if("unionErrors"in o&&o.unionErrors.forEach(function(j){return j.errors.forEach(function(A){return e.push(A)})}),r){var b=s[m].types,S=b&&b[o.code];s[m]=X2(m,r,s,d,S?[].concat(S,o.message):o.message)}e.shift()}return s}function Zme(e,r){for(var s={};e.length;){var o=e[0],d=o.code,p=o.message,m=o.path.join(".");if(!s[m])if(o.code==="invalid_union"&&o.errors.length>0){var g=o.errors[0][0];s[m]={message:g.message,type:g.code}}else s[m]={message:p,type:d};if(o.code==="invalid_union"&&o.errors.forEach(function(j){return j.forEach(function(A){return e.push(A)})}),r){var b=s[m].types,S=b&&b[o.code];s[m]=X2(m,r,s,d,S?[].concat(S,o.message):o.message)}e.shift()}return s}function gr(e,r,s){if(s===void 0&&(s={}),(function(o){return"_def"in o&&typeof o._def=="object"&&"typeName"in o._def})(e))return function(o,d,p){try{return Promise.resolve(v3(function(){return Promise.resolve(e[s.mode==="sync"?"parse":"parseAsync"](o,r)).then(function(m){return p.shouldUseNativeValidation&&f_({},p),{errors:{},values:s.raw?Object.assign({},o):m}})},function(m){if((function(g){return Array.isArray(g?.issues)})(m))return{values:{},errors:e3(Yme(m.errors,!p.shouldUseNativeValidation&&p.criteriaMode==="all"),p)};throw m}))}catch(m){return Promise.reject(m)}};if((function(o){return"_zod"in o&&typeof o._zod=="object"})(e))return function(o,d,p){try{return Promise.resolve(v3(function(){return Promise.resolve((s.mode==="sync"?ppe:fpe)(e,o,r)).then(function(m){return p.shouldUseNativeValidation&&f_({},p),{errors:{},values:s.raw?Object.assign({},o):m}})},function(m){if((function(g){return g instanceof t$})(m))return{values:{},errors:e3(Zme(m.issues,!p.shouldUseNativeValidation&&p.criteriaMode==="all"),p)};throw m}))}catch(m){return Promise.reject(m)}};throw new Error("Invalid input: not a Zod schema")}const Wme=at("ZodISODateTime",(e,r)=>{wfe.init(e,r),zr.init(e,r)});function Jme(e){return Cme(Wme,e)}const Qme=at("ZodISODate",(e,r)=>{Sfe.init(e,r),zr.init(e,r)});function ege(e){return Ame(Qme,e)}const tge=at("ZodISOTime",(e,r)=>{Efe.init(e,r),zr.init(e,r)});function nge(e){return Ome(tge,e)}const rge=at("ZodISODuration",(e,r)=>{jfe.init(e,r),zr.init(e,r)});function sge(e){return kme(rge,e)}const ige=(e,r)=>{t$.init(e,r),e.name="ZodError",Object.defineProperties(e,{format:{value:s=>hpe(e,s)},flatten:{value:s=>dpe(e,s)},addIssue:{value:s=>{e.issues.push(s),e.message=JSON.stringify(e.issues,m_,2)}},addIssues:{value:s=>{e.issues.push(...s),e.message=JSON.stringify(e.issues,m_,2)}},isEmpty:{get(){return e.issues.length===0}}})},co=at("ZodError",ige,{Parent:Error}),age=BC(co),oge=UC(co),lge=KC(co),cge=VC(co),uge=ype(co),dge=vpe(co),hge=xpe(co),pge=bpe(co),fge=wpe(co),mge=Spe(co),gge=Epe(co),yge=jpe(co),rs=at("ZodType",(e,r)=>(Gr.init(e,r),e.def=r,e.type=r.type,Object.defineProperty(e,"_def",{value:r}),e.check=(...s)=>e.clone(Pp(r,{checks:[...r.checks??[],...s.map(o=>typeof o=="function"?{_zod:{check:o,def:{check:"custom"},onattach:[]}}:o)]})),e.clone=(s,o)=>Zd(e,s,o),e.brand=()=>e,e.register=((s,o)=>(s.add(e,o),e)),e.parse=(s,o)=>age(e,s,o,{callee:e.parse}),e.safeParse=(s,o)=>lge(e,s,o),e.parseAsync=async(s,o)=>oge(e,s,o,{callee:e.parseAsync}),e.safeParseAsync=async(s,o)=>cge(e,s,o),e.spa=e.safeParseAsync,e.encode=(s,o)=>uge(e,s,o),e.decode=(s,o)=>dge(e,s,o),e.encodeAsync=async(s,o)=>hge(e,s,o),e.decodeAsync=async(s,o)=>pge(e,s,o),e.safeEncode=(s,o)=>fge(e,s,o),e.safeDecode=(s,o)=>mge(e,s,o),e.safeEncodeAsync=async(s,o)=>gge(e,s,o),e.safeDecodeAsync=async(s,o)=>yge(e,s,o),e.refine=(s,o)=>e.check(lye(s,o)),e.superRefine=s=>e.check(cye(s)),e.overwrite=s=>e.check(Mg(s)),e.optional=()=>E3(e),e.nullable=()=>j3(e),e.nullish=()=>E3(j3(e)),e.nonoptional=s=>tye(e,s),e.array=()=>Bge(e),e.or=s=>j6([e,s]),e.and=s=>Hge(e,s),e.transform=s=>C3(e,Yge(s)),e.default=s=>Jge(e,s),e.prefault=s=>eye(e,s),e.catch=s=>rye(e,s),e.pipe=s=>C3(e,s),e.readonly=()=>aye(e),e.describe=s=>{const o=e.clone();return lj.add(o,{description:s}),o},Object.defineProperty(e,"description",{get(){return lj.get(e)?.description},configurable:!0}),e.meta=(...s)=>{if(s.length===0)return lj.get(e);const o=e.clone();return lj.add(o,s[0]),o},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),w6=at("_ZodString",(e,r)=>{n$.init(e,r),rs.init(e,r);const s=e._zod.bag;e.format=s.format??null,e.minLength=s.minimum??null,e.maxLength=s.maximum??null,e.regex=(...o)=>e.check(Dme(...o)),e.includes=(...o)=>e.check(Ime(...o)),e.startsWith=(...o)=>e.check(Lme(...o)),e.endsWith=(...o)=>e.check(zme(...o)),e.min=(...o)=>e.check(eC(...o)),e.max=(...o)=>e.check(x6(...o)),e.length=(...o)=>e.check(b6(...o)),e.nonempty=(...o)=>e.check(eC(1,...o)),e.lowercase=o=>e.check(Pme(o)),e.uppercase=o=>e.check(Mme(o)),e.trim=()=>e.check(qme()),e.normalize=(...o)=>e.check(Fme(...o)),e.toLowerCase=()=>e.check(Bme()),e.toUpperCase=()=>e.check(Ume()),e.slugify=()=>e.check(Kme())}),vge=at("ZodString",(e,r)=>{n$.init(e,r),w6.init(e,r),e.email=s=>e.check(ime(xge,s)),e.url=s=>e.check(cme(bge,s)),e.jwt=s=>e.check(jme(Pge,s)),e.emoji=s=>e.check(ume(wge,s)),e.guid=s=>e.check(f3(x3,s)),e.uuid=s=>e.check(v6(Eb,s)),e.uuidv4=s=>e.check(ame(Eb,s)),e.uuidv6=s=>e.check(ome(Eb,s)),e.uuidv7=s=>e.check(lme(Eb,s)),e.nanoid=s=>e.check(dme(Sge,s)),e.guid=s=>e.check(f3(x3,s)),e.cuid=s=>e.check(hme(Ege,s)),e.cuid2=s=>e.check(pme(jge,s)),e.ulid=s=>e.check(fme(Cge,s)),e.base64=s=>e.check(wme($ge,s)),e.base64url=s=>e.check(Sme(Nge,s)),e.xid=s=>e.check(mme(Age,s)),e.ksuid=s=>e.check(gme(Oge,s)),e.ipv4=s=>e.check(yme(kge,s)),e.ipv6=s=>e.check(vme(Rge,s)),e.cidrv4=s=>e.check(xme(Tge,s)),e.cidrv6=s=>e.check(bme(_ge,s)),e.e164=s=>e.check(Eme(Dge,s)),e.datetime=s=>e.check(Jme(s)),e.date=s=>e.check(ege(s)),e.time=s=>e.check(nge(s)),e.duration=s=>e.check(sge(s))});function Nn(e){return sme(vge,e)}const zr=at("ZodStringFormat",(e,r)=>{$r.init(e,r),w6.init(e,r)}),xge=at("ZodEmail",(e,r)=>{hfe.init(e,r),zr.init(e,r)}),x3=at("ZodGUID",(e,r)=>{ufe.init(e,r),zr.init(e,r)}),Eb=at("ZodUUID",(e,r)=>{dfe.init(e,r),zr.init(e,r)});function S6(e){return v6(Eb,e)}const bge=at("ZodURL",(e,r)=>{pfe.init(e,r),zr.init(e,r)}),wge=at("ZodEmoji",(e,r)=>{ffe.init(e,r),zr.init(e,r)}),Sge=at("ZodNanoID",(e,r)=>{mfe.init(e,r),zr.init(e,r)}),Ege=at("ZodCUID",(e,r)=>{gfe.init(e,r),zr.init(e,r)}),jge=at("ZodCUID2",(e,r)=>{yfe.init(e,r),zr.init(e,r)}),Cge=at("ZodULID",(e,r)=>{vfe.init(e,r),zr.init(e,r)}),Age=at("ZodXID",(e,r)=>{xfe.init(e,r),zr.init(e,r)}),Oge=at("ZodKSUID",(e,r)=>{bfe.init(e,r),zr.init(e,r)}),kge=at("ZodIPv4",(e,r)=>{Cfe.init(e,r),zr.init(e,r)}),Rge=at("ZodIPv6",(e,r)=>{Afe.init(e,r),zr.init(e,r)}),Tge=at("ZodCIDRv4",(e,r)=>{Ofe.init(e,r),zr.init(e,r)}),_ge=at("ZodCIDRv6",(e,r)=>{kfe.init(e,r),zr.init(e,r)}),$ge=at("ZodBase64",(e,r)=>{Rfe.init(e,r),zr.init(e,r)}),Nge=at("ZodBase64URL",(e,r)=>{_fe.init(e,r),zr.init(e,r)}),Dge=at("ZodE164",(e,r)=>{$fe.init(e,r),zr.init(e,r)}),Pge=at("ZodJWT",(e,r)=>{Dfe.init(e,r),zr.init(e,r)}),E6=at("ZodNumber",(e,r)=>{m6.init(e,r),rs.init(e,r),e.gt=(o,d)=>e.check(g3(o,d)),e.gte=(o,d)=>e.check(fT(o,d)),e.min=(o,d)=>e.check(fT(o,d)),e.lt=(o,d)=>e.check(m3(o,d)),e.lte=(o,d)=>e.check(pT(o,d)),e.max=(o,d)=>e.check(pT(o,d)),e.int=o=>e.check(b3(o)),e.safe=o=>e.check(b3(o)),e.positive=o=>e.check(g3(0,o)),e.nonnegative=o=>e.check(fT(0,o)),e.negative=o=>e.check(m3(0,o)),e.nonpositive=o=>e.check(pT(0,o)),e.multipleOf=(o,d)=>e.check(y3(o,d)),e.step=(o,d)=>e.check(y3(o,d)),e.finite=()=>e;const s=e._zod.bag;e.minValue=Math.max(s.minimum??Number.NEGATIVE_INFINITY,s.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(s.maximum??Number.POSITIVE_INFINITY,s.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(s.format??"").includes("int")||Number.isSafeInteger(s.multipleOf??.5),e.isFinite=!0,e.format=s.format??null});function Xb(e){return Rme(E6,e)}const Mge=at("ZodNumberFormat",(e,r)=>{Pfe.init(e,r),E6.init(e,r)});function b3(e){return Tme(Mge,e)}const Ige=at("ZodAny",(e,r)=>{Mfe.init(e,r),rs.init(e,r)});function w3(){return _me(Ige)}const Lge=at("ZodUnknown",(e,r)=>{Ife.init(e,r),rs.init(e,r)});function S3(){return $me(Lge)}const zge=at("ZodNever",(e,r)=>{Lfe.init(e,r),rs.init(e,r)});function Fge(e){return Nme(zge,e)}const qge=at("ZodArray",(e,r)=>{zfe.init(e,r),rs.init(e,r),e.element=r.element,e.min=(s,o)=>e.check(eC(s,o)),e.nonempty=s=>e.check(eC(1,s)),e.max=(s,o)=>e.check(x6(s,o)),e.length=(s,o)=>e.check(b6(s,o)),e.unwrap=()=>e.element});function Bge(e,r){return Vme(qge,e,r)}const Uge=at("ZodObject",(e,r)=>{qfe.init(e,r),rs.init(e,r),Sr(e,"shape",()=>r.shape),e.keyof=()=>Da(Object.keys(e._zod.def.shape)),e.catchall=s=>e.clone({...e._zod.def,catchall:s}),e.passthrough=()=>e.clone({...e._zod.def,catchall:S3()}),e.loose=()=>e.clone({...e._zod.def,catchall:S3()}),e.strict=()=>e.clone({...e._zod.def,catchall:Fge()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=s=>ape(e,s),e.safeExtend=s=>ope(e,s),e.merge=s=>lpe(e,s),e.pick=s=>spe(e,s),e.omit=s=>ipe(e,s),e.partial=(...s)=>cpe(C6,e,s[0]),e.required=(...s)=>upe(A6,e,s[0])});function Xs(e,r){const s={type:"object",shape:e??{},...Yt(r)};return new Uge(s)}const Kge=at("ZodUnion",(e,r)=>{Bfe.init(e,r),rs.init(e,r),e.options=r.options});function j6(e,r){return new Kge({type:"union",options:e,...Yt(r)})}const Vge=at("ZodIntersection",(e,r)=>{Ufe.init(e,r),rs.init(e,r)});function Hge(e,r){return new Vge({type:"intersection",left:e,right:r})}const y_=at("ZodEnum",(e,r)=>{Kfe.init(e,r),rs.init(e,r),e.enum=r.entries,e.options=Object.values(r.entries);const s=new Set(Object.keys(r.entries));e.extract=(o,d)=>{const p={};for(const m of o)if(s.has(m))p[m]=r.entries[m];else throw new Error(`Key ${m} not found in enum`);return new y_({...r,checks:[],...Yt(d),entries:p})},e.exclude=(o,d)=>{const p={...r.entries};for(const m of o)if(s.has(m))delete p[m];else throw new Error(`Key ${m} not found in enum`);return new y_({...r,checks:[],...Yt(d),entries:p})}});function Da(e,r){const s=Array.isArray(e)?Object.fromEntries(e.map(o=>[o,o])):e;return new y_({type:"enum",entries:s,...Yt(r)})}const Gge=at("ZodLiteral",(e,r)=>{Vfe.init(e,r),rs.init(e,r),e.values=new Set(r.values),Object.defineProperty(e,"value",{get(){if(r.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return r.values[0]}})});function Yb(e,r){return new Gge({type:"literal",values:Array.isArray(e)?e:[e],...Yt(r)})}const Xge=at("ZodTransform",(e,r)=>{Hfe.init(e,r),rs.init(e,r),e._zod.parse=(s,o)=>{if(o.direction==="backward")throw new n6(e.constructor.name);s.addIssue=p=>{if(typeof p=="string")s.issues.push(Gb(p,s.value,r));else{const m=p;m.fatal&&(m.continue=!1),m.code??(m.code="custom"),m.input??(m.input=s.value),m.inst??(m.inst=e),s.issues.push(Gb(m))}};const d=r.transform(s.value,s);return d instanceof Promise?d.then(p=>(s.value=p,s)):(s.value=d,s)}});function Yge(e){return new Xge({type:"transform",transform:e})}const C6=at("ZodOptional",(e,r)=>{Gfe.init(e,r),rs.init(e,r),e.unwrap=()=>e._zod.def.innerType});function E3(e){return new C6({type:"optional",innerType:e})}const Zge=at("ZodNullable",(e,r)=>{Xfe.init(e,r),rs.init(e,r),e.unwrap=()=>e._zod.def.innerType});function j3(e){return new Zge({type:"nullable",innerType:e})}const Wge=at("ZodDefault",(e,r)=>{Yfe.init(e,r),rs.init(e,r),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function Jge(e,r){return new Wge({type:"default",innerType:e,get defaultValue(){return typeof r=="function"?r():i6(r)}})}const Qge=at("ZodPrefault",(e,r)=>{Zfe.init(e,r),rs.init(e,r),e.unwrap=()=>e._zod.def.innerType});function eye(e,r){return new Qge({type:"prefault",innerType:e,get defaultValue(){return typeof r=="function"?r():i6(r)}})}const A6=at("ZodNonOptional",(e,r)=>{Wfe.init(e,r),rs.init(e,r),e.unwrap=()=>e._zod.def.innerType});function tye(e,r){return new A6({type:"nonoptional",innerType:e,...Yt(r)})}const nye=at("ZodCatch",(e,r)=>{Jfe.init(e,r),rs.init(e,r),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function rye(e,r){return new nye({type:"catch",innerType:e,catchValue:typeof r=="function"?r:()=>r})}const sye=at("ZodPipe",(e,r)=>{Qfe.init(e,r),rs.init(e,r),e.in=r.in,e.out=r.out});function C3(e,r){return new sye({type:"pipe",in:e,out:r})}const iye=at("ZodReadonly",(e,r)=>{eme.init(e,r),rs.init(e,r),e.unwrap=()=>e._zod.def.innerType});function aye(e){return new iye({type:"readonly",innerType:e})}const oye=at("ZodCustom",(e,r)=>{tme.init(e,r),rs.init(e,r)});function lye(e,r={}){return Hme(oye,e,r)}function cye(e){return Gme(e)}const Dd={custom:"custom"};var uye=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],dye=uye.reduce((e,r)=>{const s=Qb(`Primitive.${r}`),o=R.forwardRef((d,p)=>{const{asChild:m,...g}=d,b=m?s:r;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(b,{...g,ref:p})});return o.displayName=`Primitive.${r}`,{...e,[r]:o}},{}),hye="Label",O6=R.forwardRef((e,r)=>u.jsx(dye.label,{...e,ref:r,onMouseDown:s=>{s.target.closest("button, input, select, textarea")||(e.onMouseDown?.(s),!s.defaultPrevented&&s.detail>1&&s.preventDefault())}}));O6.displayName=hye;var pye=O6;function xi({className:e,...r}){return u.jsx(pye,{"data-slot":"label",className:ft("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",e),...r})}const yr=Dhe,k6=R.createContext({}),pt=({...e})=>u.jsx(k6.Provider,{value:{name:e.name},children:u.jsx(Go,{...e})}),r$=()=>{const e=R.useContext(k6),r=R.useContext(R6),{getFieldState:s}=FC(),o=YF({name:e.name}),d=s(e.name,o);if(!e)throw new Error("useFormField should be used within ");const{id:p}=r;return{id:p,name:e.name,formItemId:`${p}-form-item`,formDescriptionId:`${p}-form-item-description`,formMessageId:`${p}-form-item-message`,...d}},R6=R.createContext({});function ot({className:e,...r}){const s=R.useId();return u.jsx(R6.Provider,{value:{id:s},children:u.jsx("div",{"data-slot":"form-item",className:ft("grid gap-2",e),...r})})}function lt({className:e,...r}){const{error:s,formItemId:o}=r$();return u.jsx(xi,{"data-slot":"form-label","data-error":!!s,className:ft("data-[error=true]:text-destructive",e),htmlFor:o,...r})}function wt({...e}){const{error:r,formItemId:s,formDescriptionId:o,formMessageId:d}=r$();return u.jsx(Cg,{"data-slot":"form-control",id:s,"aria-describedby":r?`${o} ${d}`:`${o}`,"aria-invalid":!!r,...e})}function dt({className:e,...r}){const{error:s,formMessageId:o}=r$(),d=s?String(s?.message??""):r.children;return d?u.jsx("p",{"data-slot":"form-message",id:o,className:ft("text-destructive text-sm",e),...r,children:d}):null}function Fi({className:e,...r}){return u.jsx("div",{"data-slot":"table-container",className:"relative w-full overflow-x-auto",children:u.jsx("table",{"data-slot":"table",className:ft("w-full caption-bottom text-sm",e),...r})})}function qi({className:e,...r}){return u.jsx("thead",{"data-slot":"table-header",className:ft("[&_tr]:border-b",e),...r})}function Bi({className:e,...r}){return u.jsx("tbody",{"data-slot":"table-body",className:ft("[&_tr:last-child]:border-0",e),...r})}function an({className:e,...r}){return u.jsx("tr",{"data-slot":"table-row",className:ft("hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",e),...r})}function At({className:e,...r}){return u.jsx("th",{"data-slot":"table-head",className:ft("text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...r})}function xt({className:e,...r}){return u.jsx("td",{"data-slot":"table-cell",className:ft("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...r})}function fye({className:e,...r}){return u.jsx("caption",{"data-slot":"table-caption",className:ft("text-muted-foreground mt-4 text-sm",e),...r})}const T6=Xs({key:Nn().trim().min(1,"Key is required").max(120,"Max 120 chars"),value:Nn().trim().optional()}),mye=T6.partial();function gye({t:e}){const r=`${e.key}${e.value?`=${e.value}`:""}`;return u.jsxs(ns,{variant:"secondary",className:"font-mono text-xs",children:[u.jsx(mC,{className:"mr-1 h-3 w-3"}),r]})}const yye=()=>{const[e,r]=R.useState(""),[s,o]=R.useState(!1),[d,p]=R.useState(!1),[m,g]=R.useState(null),[b,S]=R.useState(null),j=Hs(),A=rr({queryKey:["annotations"],queryFn:()=>Sb.listAnnotations()}),k=mr({resolver:gr(T6),defaultValues:{key:"",value:""}}),T=nn({mutationFn:L=>Sb.createAnnotation(L),onSuccess:async()=>{await j.invalidateQueries({queryKey:["annotations"]}),k.reset(),o(!1),Ze.success("Annotation Created Successfully.")},onError:L=>{Ze.error(L.message??"There was an error while creating Annotation")}}),M=L=>{T.mutate(L)},I=mr({resolver:gr(mye),defaultValues:{}}),q=nn({mutationFn:({id:L,values:ee})=>Sb.updateAnnotation(L,ee),onSuccess:async()=>{await j.invalidateQueries({queryKey:["annotations"]}),I.reset(),p(!1),Ze.success("Annotation Updated Successfully.")},onError:L=>{Ze.error(L.message??"There was an error while updating Annotation")}}),G=L=>{S(L.id),I.reset({key:L.key,value:L.value}),p(!0)},K=nn({mutationFn:L=>Sb.deleteAnnotation(L),onSuccess:async()=>{await j.invalidateQueries({queryKey:["annotations"]}),g(null),Ze.success("Annotation Deleted Successfully.")},onError:L=>{Ze.error(L.message??"There was an error while deleting Annotation")}}),X=R.useMemo(()=>{const L=A.data??[],ee=e.trim().toLowerCase();return ee?L.filter(oe=>oe.key?.toLowerCase().includes(ee)||oe.value?.toLowerCase().includes(ee)):L},[e,A.data]);return A.isLoading?u.jsx("div",{className:"p-6",children:"Loading annotations…"}):A.error?u.jsxs("div",{className:"p-6 text-red-500",children:["Error loading annotations.",u.jsx("pre",{children:JSON.stringify(A,null,2)})]}):u.jsxs("div",{className:"space-y-4 p-6",children:[u.jsxs("div",{className:"flex flex-col gap-3 md:flex-row md:items-center md:justify-between",children:[u.jsx("h1",{className:"mb-4 text-2xl font-bold",children:"Annotations"}),u.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[u.jsxs("div",{className:"relative",children:[u.jsx(Pa,{className:"absolute top-2.5 left-2 h-4 w-4 opacity-60"}),u.jsx(gt,{value:e,onChange:L=>r(L.target.value),placeholder:"Search annotations",className:"w-64 pl-8"})]}),u.jsxs(fn,{open:s,onOpenChange:o,children:[u.jsx(zi,{asChild:!0,children:u.jsxs(Fe,{onClick:()=>o(!0),children:[u.jsx(oo,{className:"mr-2 h-4 w-4"}),"Create Annotation"]})}),u.jsxs(mn,{className:"sm:max-w-lg",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Create Label"})}),u.jsx(yr,{...k,children:u.jsxs("form",{className:"space-y-4",onSubmit:k.handleSubmit(M),children:[u.jsx(pt,{control:k.control,name:"key",render:({field:L})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Key"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"environment",...L})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:k.control,name:"value",render:({field:L})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Value"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"dev",...L})}),u.jsx(dt,{})]})}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{type:"button",variant:"outline",onClick:()=>o(!1),children:"Cancel"}),u.jsx(Fe,{type:"submit",disabled:k.formState.isSubmitting,children:k.formState.isSubmitting?"Creating…":"Create"})]})]})})]})]})]})]}),u.jsx("div",{className:"bg-background overflow-hidden rounded-2xl border shadow-sm",children:u.jsx("div",{className:"overflow-x-auto",children:u.jsxs(Fi,{children:[u.jsx(qi,{children:u.jsxs(an,{children:[u.jsx(At,{children:"Key"}),u.jsx(At,{children:"Value"}),u.jsx(At,{children:"Annotation"}),u.jsx(At,{className:"w-[180px] text-right",children:"Actions"})]})}),u.jsxs(Bi,{children:[X.map(L=>u.jsxs(an,{children:[u.jsx(xt,{children:L.key}),u.jsx(xt,{children:L.value}),u.jsx(xt,{children:u.jsxs("div",{className:"flex items-center gap-2",children:[u.jsx(gye,{t:L}),u.jsx("code",{className:"text-muted-foreground text-xs",children:el(L.id,6)})]})}),u.jsx(xt,{children:u.jsxs("div",{className:"flex justify-end gap-2",children:[u.jsxs(Fe,{variant:"outline",size:"sm",onClick:()=>G(L),children:[u.jsx(pu,{className:"mr-2 h-4 w-4"})," Edit"]}),u.jsx(Fe,{variant:"destructive",size:"sm",onClick:()=>g(L.id),disabled:K.isPending&&m===L.id,children:K.isPending&&m===L.id?"Deleting…":"Delete"})]})})]},L.id)),X.length===0&&u.jsx(an,{children:u.jsxs(xt,{colSpan:4,className:"text-muted-foreground py-10 text-center",children:[u.jsx(Jb,{className:"mx-auto mb-2 h-6 w-6 opacity-60"}),"No labels match your search."]})})]})]})})}),u.jsx(fn,{open:d,onOpenChange:p,children:u.jsxs(mn,{className:"sm:max-w-lg",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Edit Annotation"})}),u.jsx(yr,{...I,children:u.jsxs("form",{className:"space-y-4",onSubmit:I.handleSubmit(L=>{b&&q.mutate({id:b,values:L})}),children:[u.jsx(pt,{control:I.control,name:"key",render:({field:L})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Key"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"dedicated",...L})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:I.control,name:"value",render:({field:L})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Value (optional)"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"gpu",...L})}),u.jsx(dt,{})]})}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{type:"button",variant:"outline",onClick:()=>p(!1),children:"Cancel"}),u.jsx(Fe,{type:"submit",disabled:q.isPending,children:q.isPending?"Saving…":"Save changes"})]})]})})]})}),u.jsx(fn,{open:!!m,onOpenChange:L=>!L&&g(null),children:u.jsxs(mn,{className:"sm:max-w-md",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Delete annotation"})}),u.jsx("p",{className:"text-muted-foreground text-sm",children:"This action cannot be undone. Are you sure you want to delete this annotation?"}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{variant:"outline",onClick:()=>g(null),children:"Cancel"}),u.jsx(Fe,{variant:"destructive",onClick:()=>m&&K.mutate(m),disabled:K.isPending,children:K.isPending?"Deleting…":"Delete"})]})]})})]})},ws=lte(),Ss={listClusters:e=>ut(async()=>await ws.listClusters(e?{q:e}:{})),getCluster:e=>ut(async()=>await ws.getCluster({clusterID:e})),createCluster:e=>ut(async()=>await ws.createCluster({dtoCreateClusterRequest:e})),updateCluster:(e,r)=>ut(async()=>await ws.updateCluster({clusterID:e,dtoUpdateClusterRequest:r})),deleteCluster:e=>ut(async()=>await ws.deleteCluster({clusterID:e})),setKubeconfig:(e,r)=>ut(async()=>await ws.setClusterKubeconfig({clusterID:e,dtoSetKubeconfigRequest:r})),clearKubeconfig:e=>ut(async()=>await ws.clearClusterKubeconfig({clusterID:e})),attachCaptainDomain:(e,r)=>ut(async()=>await ws.attachCaptainDomain({clusterID:e,dtoAttachCaptainDomainRequest:r})),detachCaptainDomain:e=>ut(async()=>await ws.detachCaptainDomain({clusterID:e})),attachControlPlaneRecordSet:(e,r)=>ut(async()=>await ws.attachControlPlaneRecordSet({clusterID:e,dtoAttachRecordSetRequest:r})),detachControlPlaneRecordSet:e=>ut(async()=>await ws.detachControlPlaneRecordSet({clusterID:e})),attachAppsLoadBalancer:(e,r)=>ut(async()=>await ws.attachAppsLoadBalancer({clusterID:e,dtoAttachLoadBalancerRequest:r})),detachAppsLoadBalancer:e=>ut(async()=>await ws.detachAppsLoadBalancer({clusterID:e})),attachGlueOpsLoadBalancer:(e,r)=>ut(async()=>await ws.attachGlueOpsLoadBalancer({clusterID:e,dtoAttachLoadBalancerRequest:r})),detachGlueOpsLoadBalancer:e=>ut(async()=>await ws.detachGlueOpsLoadBalancer({clusterID:e})),attachBastion:(e,r)=>ut(async()=>await ws.attachBastionServer({clusterID:e,dtoAttachBastionRequest:r})),detachBastion:e=>ut(async()=>await ws.detachBastionServer({clusterID:e})),attachNodePool:(e,r)=>ut(async()=>await ws.attachNodePool({clusterID:e,dtoAttachNodePoolRequest:{node_pool_id:r}})),detachNodePool:(e,r)=>ut(async()=>await ws.detachNodePool({clusterID:e,nodePoolID:r}))},uu=ate(),tc={listDomains:()=>ut(async()=>await uu.listDomains()),getDomain:e=>ut(async()=>await uu.getDomain({id:e})),createDomain:async e=>ut(async()=>await uu.createDomain({dtoCreateDomainRequest:e})),updateDomain:async(e,r)=>ut(async()=>await uu.updateDomain({id:e,dtoUpdateDomainRequest:r})),deleteDomain:async e=>ut(async()=>await uu.deleteDomain({id:e})),listRecordSetsByDomain:async e=>ut(async()=>await uu.listRecordSets({domainId:e})),createRecordSetsByDomain:async(e,r)=>ut(async()=>await uu.createRecordSet({domainId:e,dtoCreateRecordSetRequest:r})),updateRecordSetsByDomain:async(e,r)=>ut(async()=>await uu.updateRecordSet({id:e,dtoUpdateRecordSetRequest:r})),deleteRecordSetsByDomain:async e=>ut(async()=>await uu.deleteRecordSet({id:e}))},cb=ote(),jb={listLoadBalancers:()=>ut(async()=>await cb.listLoadBalancers()),getLoadBalancer:e=>ut(async()=>await cb.getLoadBalancers({id:e})),createLoadBalancer:e=>ut(async()=>await cb.createLoadBalancer({dtoCreateLoadBalancerRequest:e})),updateLoadBalancer:(e,r)=>ut(async()=>await cb.updateLoadBalancer({id:e,dtoUpdateLoadBalancerRequest:r})),deleteLoadBalancer:e=>ut(async()=>await cb.deleteLoadBalancer({id:e}))},Bs=ste(),vye=(e,r)=>e?e===r:!0,ka={listNodePools:()=>ut(async()=>await Bs.listNodePools({})),createNodePool:e=>ut(async()=>await Bs.createNodePool({dtoCreateNodePoolRequest:e})),getNodePool:e=>ut(async()=>await Bs.getNodePool({id:e})),deleteNodePool:e=>ut(async()=>{await Bs.deleteNodePool({id:e})}),updateNodePool:(e,r)=>ut(async()=>await Bs.updateNodePool({id:e,dtoUpdateNodePoolRequest:r})),listNodePoolServers:e=>ut(async()=>await Bs.listNodePoolServers({id:e})),attachNodePoolServer:(e,r)=>ut(async()=>await Bs.attachNodePoolServers({id:e,dtoAttachServersRequest:r})),detachNodePoolServers:(e,r)=>ut(async()=>await Bs.detachNodePoolServer({id:e,serverId:r})),listNodePoolTaints:e=>ut(async()=>await Bs.listNodePoolTaints({id:e})),attachNodePoolTaints:(e,r)=>ut(async()=>await Bs.attachNodePoolTaints({id:e,dtoAttachTaintsRequest:r})),detachNodePoolTaints:(e,r)=>ut(async()=>await Bs.detachNodePoolTaint({id:e,taintId:r})),listNodePoolLabels:e=>ut(async()=>await Bs.listNodePoolLabels({id:e})),attachNodePoolLabels:(e,r)=>ut(async()=>await Bs.attachNodePoolLabels({id:e,dtoAttachLabelsRequest:r})),detachNodePoolLabels:(e,r)=>ut(async()=>await Bs.detachNodePoolLabel({id:e,labelId:r})),listNodePoolAnnotations:e=>ut(async()=>await Bs.listNodePoolAnnotations({id:e})),attachNodePoolAnnotations:(e,r)=>ut(async()=>await Bs.attachNodePoolAnnotations({id:e,dtoAttachAnnotationsRequest:r})),detachNodePoolAnnotations:(e,r)=>ut(async()=>await Bs.detachNodePoolAnnotation({id:e,annotationId:r}))},ub=Qee(),hg={listServers:()=>ut(async()=>await ub.listServers()),createServer:e=>ut(async()=>await ub.createServer({dtoCreateServerRequest:e})),getServer:e=>ut(async()=>await ub.getServer({id:e})),updateServer:(e,r)=>ut(async()=>await ub.updateServer({id:e,dtoUpdateServerRequest:r})),deleteServer:e=>ut(async()=>{await ub.deleteServer({id:e})})};function A3(e,[r,s]){return Math.min(s,Math.max(r,e))}function O3(e){const r=xye(e),s=R.forwardRef((o,d)=>{const{children:p,...m}=o,g=R.Children.toArray(p),b=g.find(wye);if(b){const S=b.props.children,j=g.map(A=>A===b?R.Children.count(S)>1?R.Children.only(null):R.isValidElement(S)?S.props.children:null:A);return u.jsx(r,{...m,ref:d,children:R.isValidElement(S)?R.cloneElement(S,void 0,j):null})}return u.jsx(r,{...m,ref:d,children:p})});return s.displayName=`${e}.Slot`,s}function xye(e){const r=R.forwardRef((s,o)=>{const{children:d,...p}=s;if(R.isValidElement(d)){const m=Eye(d),g=Sye(p,d.props);return d.type!==R.Fragment&&(g.ref=o?Li(o,m):m),R.cloneElement(d,g)}return R.Children.count(d)>1?R.Children.only(null):null});return r.displayName=`${e}.SlotClone`,r}var bye=Symbol("radix.slottable");function wye(e){return R.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===bye}function Sye(e,r){const s={...r};for(const o in r){const d=e[o],p=r[o];/^on[A-Z]/.test(o)?d&&p?s[o]=(...g)=>{const b=p(...g);return d(...g),b}:d&&(s[o]=d):o==="style"?s[o]={...d,...p}:o==="className"&&(s[o]=[d,p].filter(Boolean).join(" "))}return{...e,...s}}function Eye(e){let r=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning;return s?e.ref:(r=Object.getOwnPropertyDescriptor(e,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning,s?e.props.ref:e.props.ref||e.ref)}function s$(e){const r=e+"CollectionProvider",[s,o]=al(r),[d,p]=s(r,{collectionRef:{current:null},itemMap:new Map}),m=I=>{const{scope:q,children:G}=I,K=Je.useRef(null),X=Je.useRef(new Map).current;return u.jsx(d,{scope:q,itemMap:X,collectionRef:K,children:G})};m.displayName=r;const g=e+"CollectionSlot",b=O3(g),S=Je.forwardRef((I,q)=>{const{scope:G,children:K}=I,X=p(g,G),L=zn(q,X.collectionRef);return u.jsx(b,{ref:L,children:K})});S.displayName=g;const j=e+"CollectionItemSlot",A="data-radix-collection-item",k=O3(j),T=Je.forwardRef((I,q)=>{const{scope:G,children:K,...X}=I,L=Je.useRef(null),ee=zn(q,L),oe=p(j,G);return Je.useEffect(()=>(oe.itemMap.set(L,{ref:L,...X}),()=>void oe.itemMap.delete(L))),u.jsx(k,{[A]:"",ref:ee,children:K})});T.displayName=j;function M(I){const q=p(e+"CollectionConsumer",I);return Je.useCallback(()=>{const K=q.collectionRef.current;if(!K)return[];const X=Array.from(K.querySelectorAll(`[${A}]`));return Array.from(q.itemMap.values()).sort((oe,Q)=>X.indexOf(oe.ref.current)-X.indexOf(Q.ref.current))},[q.collectionRef,q.itemMap])}return[{Provider:m,Slot:S,ItemSlot:T},M,o]}var jye=R.createContext(void 0);function i$(e){const r=R.useContext(jye);return e||r||"ltr"}function Cye(e){const r=Aye(e),s=R.forwardRef((o,d)=>{const{children:p,...m}=o,g=R.Children.toArray(p),b=g.find(kye);if(b){const S=b.props.children,j=g.map(A=>A===b?R.Children.count(S)>1?R.Children.only(null):R.isValidElement(S)?S.props.children:null:A);return u.jsx(r,{...m,ref:d,children:R.isValidElement(S)?R.cloneElement(S,void 0,j):null})}return u.jsx(r,{...m,ref:d,children:p})});return s.displayName=`${e}.Slot`,s}function Aye(e){const r=R.forwardRef((s,o)=>{const{children:d,...p}=s;if(R.isValidElement(d)){const m=Tye(d),g=Rye(p,d.props);return d.type!==R.Fragment&&(g.ref=o?Li(o,m):m),R.cloneElement(d,g)}return R.Children.count(d)>1?R.Children.only(null):null});return r.displayName=`${e}.SlotClone`,r}var Oye=Symbol("radix.slottable");function kye(e){return R.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Oye}function Rye(e,r){const s={...r};for(const o in r){const d=e[o],p=r[o];/^on[A-Z]/.test(o)?d&&p?s[o]=(...g)=>{const b=p(...g);return d(...g),b}:d&&(s[o]=d):o==="style"?s[o]={...d,...p}:o==="className"&&(s[o]=[d,p].filter(Boolean).join(" "))}return{...e,...s}}function Tye(e){let r=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning;return s?e.ref:(r=Object.getOwnPropertyDescriptor(e,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning,s?e.props.ref:e.props.ref||e.ref)}function _6(e){const r=R.useRef({value:e,previous:e});return R.useMemo(()=>(r.current.value!==e&&(r.current.previous=r.current.value,r.current.value=e),r.current.previous),[e])}var _ye=[" ","Enter","ArrowUp","ArrowDown"],$ye=[" ","Enter"],$p="Select",[GC,XC,Nye]=s$($p),[Ig]=al($p,[Nye,Hd]),YC=Hd(),[Dye,Wd]=Ig($p),[Pye,Mye]=Ig($p),$6=e=>{const{__scopeSelect:r,children:s,open:o,defaultOpen:d,onOpenChange:p,value:m,defaultValue:g,onValueChange:b,dir:S,name:j,autoComplete:A,disabled:k,required:T,form:M}=e,I=YC(r),[q,G]=R.useState(null),[K,X]=R.useState(null),[L,ee]=R.useState(!1),oe=i$(S),[Q,ne]=qd({prop:o,defaultProp:d??!1,onChange:p,caller:$p}),[de,je]=qd({prop:m,defaultProp:g,onChange:b,caller:$p}),ve=R.useRef(null),le=q?M||!!q.closest("form"):!0,[be,Ce]=R.useState(new Set),Ke=Array.from(be).map(ce=>ce.props.value).join(";");return u.jsx(wC,{...I,children:u.jsxs(Dye,{required:T,scope:r,trigger:q,onTriggerChange:G,valueNode:K,onValueNodeChange:X,valueNodeHasChildren:L,onValueNodeHasChildrenChange:ee,contentId:Vs(),value:de,onValueChange:je,open:Q,onOpenChange:ne,dir:oe,triggerPointerDownPosRef:ve,disabled:k,children:[u.jsx(GC.Provider,{scope:r,children:u.jsx(Pye,{scope:e.__scopeSelect,onNativeOptionAdd:R.useCallback(ce=>{Ce(re=>new Set(re).add(ce))},[]),onNativeOptionRemove:R.useCallback(ce=>{Ce(re=>{const ue=new Set(re);return ue.delete(ce),ue})},[]),children:s})}),le?u.jsxs(eq,{"aria-hidden":!0,required:T,tabIndex:-1,name:j,autoComplete:A,value:de,onChange:ce=>je(ce.target.value),disabled:k,form:M,children:[de===void 0?u.jsx("option",{value:""}):null,Array.from(be)]},Ke):null]})})};$6.displayName=$p;var N6="SelectTrigger",D6=R.forwardRef((e,r)=>{const{__scopeSelect:s,disabled:o=!1,...d}=e,p=YC(s),m=Wd(N6,s),g=m.disabled||o,b=zn(r,m.onTriggerChange),S=XC(s),j=R.useRef("touch"),[A,k,T]=nq(I=>{const q=S().filter(X=>!X.disabled),G=q.find(X=>X.value===m.value),K=rq(q,I,G);K!==void 0&&m.onValueChange(K.value)}),M=I=>{g||(m.onOpenChange(!0),T()),I&&(m.triggerPointerDownPosRef.current={x:Math.round(I.pageX),y:Math.round(I.pageY)})};return u.jsx(tw,{asChild:!0,...p,children:u.jsx(Cn.button,{type:"button",role:"combobox","aria-controls":m.contentId,"aria-expanded":m.open,"aria-required":m.required,"aria-autocomplete":"none",dir:m.dir,"data-state":m.open?"open":"closed",disabled:g,"data-disabled":g?"":void 0,"data-placeholder":tq(m.value)?"":void 0,...d,ref:b,onClick:$t(d.onClick,I=>{I.currentTarget.focus(),j.current!=="mouse"&&M(I)}),onPointerDown:$t(d.onPointerDown,I=>{j.current=I.pointerType;const q=I.target;q.hasPointerCapture(I.pointerId)&&q.releasePointerCapture(I.pointerId),I.button===0&&I.ctrlKey===!1&&I.pointerType==="mouse"&&(M(I),I.preventDefault())}),onKeyDown:$t(d.onKeyDown,I=>{const q=A.current!=="";!(I.ctrlKey||I.altKey||I.metaKey)&&I.key.length===1&&k(I.key),!(q&&I.key===" ")&&_ye.includes(I.key)&&(M(),I.preventDefault())})})})});D6.displayName=N6;var P6="SelectValue",M6=R.forwardRef((e,r)=>{const{__scopeSelect:s,className:o,style:d,children:p,placeholder:m="",...g}=e,b=Wd(P6,s),{onValueNodeHasChildrenChange:S}=b,j=p!==void 0,A=zn(r,b.onValueNodeChange);return As(()=>{S(j)},[S,j]),u.jsx(Cn.span,{...g,ref:A,style:{pointerEvents:"none"},children:tq(b.value)?u.jsx(u.Fragment,{children:m}):p})});M6.displayName=P6;var Iye="SelectIcon",I6=R.forwardRef((e,r)=>{const{__scopeSelect:s,children:o,...d}=e;return u.jsx(Cn.span,{"aria-hidden":!0,...d,ref:r,children:o||"▼"})});I6.displayName=Iye;var Lye="SelectPortal",L6=e=>u.jsx(_g,{asChild:!0,...e});L6.displayName=Lye;var Np="SelectContent",z6=R.forwardRef((e,r)=>{const s=Wd(Np,e.__scopeSelect),[o,d]=R.useState();if(As(()=>{d(new DocumentFragment)},[]),!s.open){const p=o;return p?fC.createPortal(u.jsx(F6,{scope:e.__scopeSelect,children:u.jsx(GC.Slot,{scope:e.__scopeSelect,children:u.jsx("div",{children:e.children})})}),p):null}return u.jsx(q6,{...e,ref:r})});z6.displayName=Np;var Yo=10,[F6,Jd]=Ig(Np),zye="SelectContentImpl",Fye=Cye("SelectContent.RemoveScroll"),q6=R.forwardRef((e,r)=>{const{__scopeSelect:s,position:o="item-aligned",onCloseAutoFocus:d,onEscapeKeyDown:p,onPointerDownOutside:m,side:g,sideOffset:b,align:S,alignOffset:j,arrowPadding:A,collisionBoundary:k,collisionPadding:T,sticky:M,hideWhenDetached:I,avoidCollisions:q,...G}=e,K=Wd(Np,s),[X,L]=R.useState(null),[ee,oe]=R.useState(null),Q=zn(r,Le=>L(Le)),[ne,de]=R.useState(null),[je,ve]=R.useState(null),le=XC(s),[be,Ce]=R.useState(!1),Ke=R.useRef(!1);R.useEffect(()=>{if(X)return kC(X)},[X]),AC();const ce=R.useCallback(Le=>{const[tt,...yt]=le().map(kt=>kt.ref.current),[Ot]=yt.slice(-1),Ft=document.activeElement;for(const kt of Le)if(kt===Ft||(kt?.scrollIntoView({block:"nearest"}),kt===tt&&ee&&(ee.scrollTop=0),kt===Ot&&ee&&(ee.scrollTop=ee.scrollHeight),kt?.focus(),document.activeElement!==Ft))return},[le,ee]),re=R.useCallback(()=>ce([ne,X]),[ce,ne,X]);R.useEffect(()=>{be&&re()},[be,re]);const{onOpenChange:ue,triggerPointerDownPosRef:_e}=K;R.useEffect(()=>{if(X){let Le={x:0,y:0};const tt=Ot=>{Le={x:Math.abs(Math.round(Ot.pageX)-(_e.current?.x??0)),y:Math.abs(Math.round(Ot.pageY)-(_e.current?.y??0))}},yt=Ot=>{Le.x<=10&&Le.y<=10?Ot.preventDefault():X.contains(Ot.target)||ue(!1),document.removeEventListener("pointermove",tt),_e.current=null};return _e.current!==null&&(document.addEventListener("pointermove",tt),document.addEventListener("pointerup",yt,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",tt),document.removeEventListener("pointerup",yt,{capture:!0})}}},[X,ue,_e]),R.useEffect(()=>{const Le=()=>ue(!1);return window.addEventListener("blur",Le),window.addEventListener("resize",Le),()=>{window.removeEventListener("blur",Le),window.removeEventListener("resize",Le)}},[ue]);const[fe,He]=nq(Le=>{const tt=le().filter(Ft=>!Ft.disabled),yt=tt.find(Ft=>Ft.ref.current===document.activeElement),Ot=rq(tt,Le,yt);Ot&&setTimeout(()=>Ot.ref.current.focus())}),Oe=R.useCallback((Le,tt,yt)=>{const Ot=!Ke.current&&!yt;(K.value!==void 0&&K.value===tt||Ot)&&(de(Le),Ot&&(Ke.current=!0))},[K.value]),ke=R.useCallback(()=>X?.focus(),[X]),Ve=R.useCallback((Le,tt,yt)=>{const Ot=!Ke.current&&!yt;(K.value!==void 0&&K.value===tt||Ot)&&ve(Le)},[K.value]),ie=o==="popper"?v_:B6,De=ie===v_?{side:g,sideOffset:b,align:S,alignOffset:j,arrowPadding:A,collisionBoundary:k,collisionPadding:T,sticky:M,hideWhenDetached:I,avoidCollisions:q}:{};return u.jsx(F6,{scope:s,content:X,viewport:ee,onViewportChange:oe,itemRefCallback:Oe,selectedItem:ne,onItemLeave:ke,itemTextRefCallback:Ve,focusSelectedItem:re,selectedItemText:je,position:o,isPositioned:be,searchRef:fe,children:u.jsx(aw,{as:Fye,allowPinchZoom:!0,children:u.jsx(iw,{asChild:!0,trapped:K.open,onMountAutoFocus:Le=>{Le.preventDefault()},onUnmountAutoFocus:$t(d,Le=>{K.trigger?.focus({preventScroll:!0}),Le.preventDefault()}),children:u.jsx(kg,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:p,onPointerDownOutside:m,onFocusOutside:Le=>Le.preventDefault(),onDismiss:()=>K.onOpenChange(!1),children:u.jsx(ie,{role:"listbox",id:K.contentId,"data-state":K.open?"open":"closed",dir:K.dir,onContextMenu:Le=>Le.preventDefault(),...G,...De,onPlaced:()=>Ce(!0),ref:Q,style:{display:"flex",flexDirection:"column",outline:"none",...G.style},onKeyDown:$t(G.onKeyDown,Le=>{const tt=Le.ctrlKey||Le.altKey||Le.metaKey;if(Le.key==="Tab"&&Le.preventDefault(),!tt&&Le.key.length===1&&He(Le.key),["ArrowUp","ArrowDown","Home","End"].includes(Le.key)){let Ot=le().filter(Ft=>!Ft.disabled).map(Ft=>Ft.ref.current);if(["ArrowUp","End"].includes(Le.key)&&(Ot=Ot.slice().reverse()),["ArrowUp","ArrowDown"].includes(Le.key)){const Ft=Le.target,kt=Ot.indexOf(Ft);Ot=Ot.slice(kt+1)}setTimeout(()=>ce(Ot)),Le.preventDefault()}})})})})})})});q6.displayName=zye;var qye="SelectItemAlignedPosition",B6=R.forwardRef((e,r)=>{const{__scopeSelect:s,onPlaced:o,...d}=e,p=Wd(Np,s),m=Jd(Np,s),[g,b]=R.useState(null),[S,j]=R.useState(null),A=zn(r,Q=>j(Q)),k=XC(s),T=R.useRef(!1),M=R.useRef(!0),{viewport:I,selectedItem:q,selectedItemText:G,focusSelectedItem:K}=m,X=R.useCallback(()=>{if(p.trigger&&p.valueNode&&g&&S&&I&&q&&G){const Q=p.trigger.getBoundingClientRect(),ne=S.getBoundingClientRect(),de=p.valueNode.getBoundingClientRect(),je=G.getBoundingClientRect();if(p.dir!=="rtl"){const Ft=je.left-ne.left,kt=de.left-Ft,Jt=Q.left-kt,ze=Q.width+Jt,zt=Math.max(ze,ne.width),Rt=window.innerWidth-Yo,V=A3(kt,[Yo,Math.max(Yo,Rt-zt)]);g.style.minWidth=ze+"px",g.style.left=V+"px"}else{const Ft=ne.right-je.right,kt=window.innerWidth-de.right-Ft,Jt=window.innerWidth-Q.right-kt,ze=Q.width+Jt,zt=Math.max(ze,ne.width),Rt=window.innerWidth-Yo,V=A3(kt,[Yo,Math.max(Yo,Rt-zt)]);g.style.minWidth=ze+"px",g.style.right=V+"px"}const ve=k(),le=window.innerHeight-Yo*2,be=I.scrollHeight,Ce=window.getComputedStyle(S),Ke=parseInt(Ce.borderTopWidth,10),ce=parseInt(Ce.paddingTop,10),re=parseInt(Ce.borderBottomWidth,10),ue=parseInt(Ce.paddingBottom,10),_e=Ke+ce+be+ue+re,fe=Math.min(q.offsetHeight*5,_e),He=window.getComputedStyle(I),Oe=parseInt(He.paddingTop,10),ke=parseInt(He.paddingBottom,10),Ve=Q.top+Q.height/2-Yo,ie=le-Ve,De=q.offsetHeight/2,Le=q.offsetTop+De,tt=Ke+ce+Le,yt=_e-tt;if(tt<=Ve){const Ft=ve.length>0&&q===ve[ve.length-1].ref.current;g.style.bottom="0px";const kt=S.clientHeight-I.offsetTop-I.offsetHeight,Jt=Math.max(ie,De+(Ft?ke:0)+kt+re),ze=tt+Jt;g.style.height=ze+"px"}else{const Ft=ve.length>0&&q===ve[0].ref.current;g.style.top="0px";const Jt=Math.max(Ve,Ke+I.offsetTop+(Ft?Oe:0)+De)+yt;g.style.height=Jt+"px",I.scrollTop=tt-Ve+I.offsetTop}g.style.margin=`${Yo}px 0`,g.style.minHeight=fe+"px",g.style.maxHeight=le+"px",o?.(),requestAnimationFrame(()=>T.current=!0)}},[k,p.trigger,p.valueNode,g,S,I,q,G,p.dir,o]);As(()=>X(),[X]);const[L,ee]=R.useState();As(()=>{S&&ee(window.getComputedStyle(S).zIndex)},[S]);const oe=R.useCallback(Q=>{Q&&M.current===!0&&(X(),K?.(),M.current=!1)},[X,K]);return u.jsx(Uye,{scope:s,contentWrapper:g,shouldExpandOnScrollRef:T,onScrollButtonChange:oe,children:u.jsx("div",{ref:b,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:L},children:u.jsx(Cn.div,{...d,ref:A,style:{boxSizing:"border-box",maxHeight:"100%",...d.style}})})})});B6.displayName=qye;var Bye="SelectPopperPosition",v_=R.forwardRef((e,r)=>{const{__scopeSelect:s,align:o="start",collisionPadding:d=Yo,...p}=e,m=YC(s);return u.jsx(SC,{...m,...p,ref:r,align:o,collisionPadding:d,style:{boxSizing:"border-box",...p.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});v_.displayName=Bye;var[Uye,a$]=Ig(Np,{}),x_="SelectViewport",U6=R.forwardRef((e,r)=>{const{__scopeSelect:s,nonce:o,...d}=e,p=Jd(x_,s),m=a$(x_,s),g=zn(r,p.onViewportChange),b=R.useRef(0);return u.jsxs(u.Fragment,{children:[u.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:o}),u.jsx(GC.Slot,{scope:s,children:u.jsx(Cn.div,{"data-radix-select-viewport":"",role:"presentation",...d,ref:g,style:{position:"relative",flex:1,overflow:"hidden auto",...d.style},onScroll:$t(d.onScroll,S=>{const j=S.currentTarget,{contentWrapper:A,shouldExpandOnScrollRef:k}=m;if(k?.current&&A){const T=Math.abs(b.current-j.scrollTop);if(T>0){const M=window.innerHeight-Yo*2,I=parseFloat(A.style.minHeight),q=parseFloat(A.style.height),G=Math.max(I,q);if(G0?L:0,A.style.justifyContent="flex-end")}}}b.current=j.scrollTop})})})]})});U6.displayName=x_;var K6="SelectGroup",[Kye,Vye]=Ig(K6),Hye=R.forwardRef((e,r)=>{const{__scopeSelect:s,...o}=e,d=Vs();return u.jsx(Kye,{scope:s,id:d,children:u.jsx(Cn.div,{role:"group","aria-labelledby":d,...o,ref:r})})});Hye.displayName=K6;var V6="SelectLabel",Gye=R.forwardRef((e,r)=>{const{__scopeSelect:s,...o}=e,d=Vye(V6,s);return u.jsx(Cn.div,{id:d.id,...o,ref:r})});Gye.displayName=V6;var tC="SelectItem",[Xye,H6]=Ig(tC),G6=R.forwardRef((e,r)=>{const{__scopeSelect:s,value:o,disabled:d=!1,textValue:p,...m}=e,g=Wd(tC,s),b=Jd(tC,s),S=g.value===o,[j,A]=R.useState(p??""),[k,T]=R.useState(!1),M=zn(r,K=>b.itemRefCallback?.(K,o,d)),I=Vs(),q=R.useRef("touch"),G=()=>{d||(g.onValueChange(o),g.onOpenChange(!1))};if(o==="")throw new Error("A must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return u.jsx(Xye,{scope:s,value:o,disabled:d,textId:I,isSelected:S,onItemTextChange:R.useCallback(K=>{A(X=>X||(K?.textContent??"").trim())},[]),children:u.jsx(GC.ItemSlot,{scope:s,value:o,disabled:d,textValue:j,children:u.jsx(Cn.div,{role:"option","aria-labelledby":I,"data-highlighted":k?"":void 0,"aria-selected":S&&k,"data-state":S?"checked":"unchecked","aria-disabled":d||void 0,"data-disabled":d?"":void 0,tabIndex:d?void 0:-1,...m,ref:M,onFocus:$t(m.onFocus,()=>T(!0)),onBlur:$t(m.onBlur,()=>T(!1)),onClick:$t(m.onClick,()=>{q.current!=="mouse"&&G()}),onPointerUp:$t(m.onPointerUp,()=>{q.current==="mouse"&&G()}),onPointerDown:$t(m.onPointerDown,K=>{q.current=K.pointerType}),onPointerMove:$t(m.onPointerMove,K=>{q.current=K.pointerType,d?b.onItemLeave?.():q.current==="mouse"&&K.currentTarget.focus({preventScroll:!0})}),onPointerLeave:$t(m.onPointerLeave,K=>{K.currentTarget===document.activeElement&&b.onItemLeave?.()}),onKeyDown:$t(m.onKeyDown,K=>{b.searchRef?.current!==""&&K.key===" "||($ye.includes(K.key)&&G(),K.key===" "&&K.preventDefault())})})})})});G6.displayName=tC;var Cb="SelectItemText",X6=R.forwardRef((e,r)=>{const{__scopeSelect:s,className:o,style:d,...p}=e,m=Wd(Cb,s),g=Jd(Cb,s),b=H6(Cb,s),S=Mye(Cb,s),[j,A]=R.useState(null),k=zn(r,G=>A(G),b.onItemTextChange,G=>g.itemTextRefCallback?.(G,b.value,b.disabled)),T=j?.textContent,M=R.useMemo(()=>u.jsx("option",{value:b.value,disabled:b.disabled,children:T},b.value),[b.disabled,b.value,T]),{onNativeOptionAdd:I,onNativeOptionRemove:q}=S;return As(()=>(I(M),()=>q(M)),[I,q,M]),u.jsxs(u.Fragment,{children:[u.jsx(Cn.span,{id:b.textId,...p,ref:k}),b.isSelected&&m.valueNode&&!m.valueNodeHasChildren?fC.createPortal(p.children,m.valueNode):null]})});X6.displayName=Cb;var Y6="SelectItemIndicator",Z6=R.forwardRef((e,r)=>{const{__scopeSelect:s,...o}=e;return H6(Y6,s).isSelected?u.jsx(Cn.span,{"aria-hidden":!0,...o,ref:r}):null});Z6.displayName=Y6;var b_="SelectScrollUpButton",W6=R.forwardRef((e,r)=>{const s=Jd(b_,e.__scopeSelect),o=a$(b_,e.__scopeSelect),[d,p]=R.useState(!1),m=zn(r,o.onScrollButtonChange);return As(()=>{if(s.viewport&&s.isPositioned){let g=function(){const S=b.scrollTop>0;p(S)};const b=s.viewport;return g(),b.addEventListener("scroll",g),()=>b.removeEventListener("scroll",g)}},[s.viewport,s.isPositioned]),d?u.jsx(Q6,{...e,ref:m,onAutoScroll:()=>{const{viewport:g,selectedItem:b}=s;g&&b&&(g.scrollTop=g.scrollTop-b.offsetHeight)}}):null});W6.displayName=b_;var w_="SelectScrollDownButton",J6=R.forwardRef((e,r)=>{const s=Jd(w_,e.__scopeSelect),o=a$(w_,e.__scopeSelect),[d,p]=R.useState(!1),m=zn(r,o.onScrollButtonChange);return As(()=>{if(s.viewport&&s.isPositioned){let g=function(){const S=b.scrollHeight-b.clientHeight,j=Math.ceil(b.scrollTop)b.removeEventListener("scroll",g)}},[s.viewport,s.isPositioned]),d?u.jsx(Q6,{...e,ref:m,onAutoScroll:()=>{const{viewport:g,selectedItem:b}=s;g&&b&&(g.scrollTop=g.scrollTop+b.offsetHeight)}}):null});J6.displayName=w_;var Q6=R.forwardRef((e,r)=>{const{__scopeSelect:s,onAutoScroll:o,...d}=e,p=Jd("SelectScrollButton",s),m=R.useRef(null),g=XC(s),b=R.useCallback(()=>{m.current!==null&&(window.clearInterval(m.current),m.current=null)},[]);return R.useEffect(()=>()=>b(),[b]),As(()=>{g().find(j=>j.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:"nearest"})},[g]),u.jsx(Cn.div,{"aria-hidden":!0,...d,ref:r,style:{flexShrink:0,...d.style},onPointerDown:$t(d.onPointerDown,()=>{m.current===null&&(m.current=window.setInterval(o,50))}),onPointerMove:$t(d.onPointerMove,()=>{p.onItemLeave?.(),m.current===null&&(m.current=window.setInterval(o,50))}),onPointerLeave:$t(d.onPointerLeave,()=>{b()})})}),Yye="SelectSeparator",Zye=R.forwardRef((e,r)=>{const{__scopeSelect:s,...o}=e;return u.jsx(Cn.div,{"aria-hidden":!0,...o,ref:r})});Zye.displayName=Yye;var S_="SelectArrow",Wye=R.forwardRef((e,r)=>{const{__scopeSelect:s,...o}=e,d=YC(s),p=Wd(S_,s),m=Jd(S_,s);return p.open&&m.position==="popper"?u.jsx(EC,{...d,...o,ref:r}):null});Wye.displayName=S_;var Jye="SelectBubbleInput",eq=R.forwardRef(({__scopeSelect:e,value:r,...s},o)=>{const d=R.useRef(null),p=zn(o,d),m=_6(r);return R.useEffect(()=>{const g=d.current;if(!g)return;const b=window.HTMLSelectElement.prototype,j=Object.getOwnPropertyDescriptor(b,"value").set;if(m!==r&&j){const A=new Event("change",{bubbles:!0});j.call(g,r),g.dispatchEvent(A)}},[m,r]),u.jsx(Cn.select,{...s,style:{...tz,...s.style},ref:p,defaultValue:r})});eq.displayName=Jye;function tq(e){return e===""||e===void 0}function nq(e){const r=tl(e),s=R.useRef(""),o=R.useRef(0),d=R.useCallback(m=>{const g=s.current+m;r(g),(function b(S){s.current=S,window.clearTimeout(o.current),S!==""&&(o.current=window.setTimeout(()=>b(""),1e3))})(g)},[r]),p=R.useCallback(()=>{s.current="",window.clearTimeout(o.current)},[]);return R.useEffect(()=>()=>window.clearTimeout(o.current),[]),[s,d,p]}function rq(e,r,s){const d=r.length>1&&Array.from(r).every(S=>S===r[0])?r[0]:r,p=s?e.indexOf(s):-1;let m=Qye(e,Math.max(p,0));d.length===1&&(m=m.filter(S=>S!==s));const b=m.find(S=>S.textValue.toLowerCase().startsWith(d.toLowerCase()));return b!==s?b:void 0}function Qye(e,r){return e.map((s,o)=>e[(r+o)%e.length])}var eve=$6,tve=D6,nve=M6,rve=I6,sve=L6,ive=z6,ave=U6,ove=G6,lve=X6,cve=Z6,uve=W6,dve=J6;function Rn({...e}){return u.jsx(eve,{"data-slot":"select",...e})}function Tn({...e}){return u.jsx(nve,{"data-slot":"select-value",...e})}function _n({className:e,size:r="default",children:s,...o}){return u.jsxs(tve,{"data-slot":"select-trigger","data-size":r,className:ft("border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...o,children:[s,u.jsx(rve,{asChild:!0,children:u.jsx(aL,{className:"size-4 opacity-50"})})]})}function $n({className:e,children:r,position:s="popper",align:o="center",...d}){return u.jsx(sve,{children:u.jsxs(ive,{"data-slot":"select-content",className:ft("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md",s==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:s,align:o,...d,children:[u.jsx(hve,{}),u.jsx(ave,{className:ft("p-1",s==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:r}),u.jsx(pve,{})]})})}function jt({className:e,children:r,...s}){return u.jsxs(ove,{"data-slot":"select-item",className:ft("focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",e),...s,children:[u.jsx("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:u.jsx(cve,{children:u.jsx(iL,{className:"size-4"})})}),u.jsx(lve,{children:r})]})}function hve({className:e,...r}){return u.jsx(uve,{"data-slot":"select-scroll-up-button",className:ft("flex cursor-default items-center justify-center py-1",e),...r,children:u.jsx(jZ,{className:"size-4"})})}function pve({className:e,...r}){return u.jsx(dve,{"data-slot":"select-scroll-down-button",className:ft("flex cursor-default items-center justify-center py-1",e),...r,children:u.jsx(aL,{className:"size-4"})})}function hu({className:e,...r}){return u.jsx("textarea",{"data-slot":"textarea",className:ft("border-input placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 flex field-sizing-content min-h-16 w-full rounded-md border bg-transparent px-3 py-2 text-base shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),...r})}const sq=Xs({name:Nn().trim().min(1,"Name is required").max(120,"Max 120 chars"),cluster_provider:Nn().trim().min(1,"Provider is required").max(120,"Max 120 chars"),region:Nn().trim().min(1,"Region is required").max(120,"Max 120 chars"),docker_image:Nn().trim().min(1,"Docker Image is required"),docker_tag:Nn().trim().min(1,"Docker Tag is required")}),fve=sq.partial();function mve({status:e}){const r=(e??"").toLowerCase();return r?r==="ready"?u.jsxs(ns,{variant:"default",className:"flex items-center gap-1 text-xs",children:[u.jsx(L_,{className:"h-3 w-3"}),"ready"]}):r==="failed"?u.jsxs(ns,{variant:"destructive",className:"flex items-center gap-1 text-xs",children:[u.jsx(kM,{className:"h-3 w-3"}),"failed"]}):r==="provisioning"||r==="pending"||r==="pre_pending"?u.jsxs(ns,{variant:"secondary",className:"flex items-center gap-1 text-xs",children:[u.jsx(Ds,{className:"h-3 w-3 animate-spin"}),r.replace("_"," ")]}):r==="incomplete"?u.jsxs(ns,{variant:"outline",className:"flex items-center gap-1 text-xs",children:[u.jsx(kM,{className:"h-3 w-3"}),"incomplete"]}):u.jsx(ns,{variant:"outline",className:"text-xs",children:r}):u.jsx(ns,{variant:"outline",className:"text-xs",children:"unknown"})}function gve({c:e}){return u.jsxs("div",{className:"text-muted-foreground flex flex-col gap-1 text-xs",children:[u.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[e.cluster_provider&&u.jsxs("span",{className:"inline-flex items-center gap-1",children:[u.jsx(zZ,{className:"h-3 w-3"}),e.cluster_provider]}),e.region&&u.jsxs("span",{className:"inline-flex items-center gap-1",children:[u.jsx(sW,{className:"h-3 w-3"}),e.region]})]}),u.jsxs("div",{className:"flex flex-wrap items-center gap-2 font-mono",children:[e.random_token&&u.jsxs("span",{children:["token: ",u.jsx("span",{className:"ml-1",children:el(e.random_token,8)})]}),e.certificate_key&&u.jsxs("span",{children:["cert: ",u.jsx("span",{className:"ml-1",children:el(e.certificate_key,8)})]})]})]})}const yve=()=>{const[e,r]=R.useState(""),[s,o]=R.useState(!1),[d,p]=R.useState(!1),[m,g]=R.useState(null),[b,S]=R.useState(null),[j,A]=R.useState(null),[k,T]=R.useState(""),[M,I]=R.useState(""),[q,G]=R.useState(""),[K,X]=R.useState(""),[L,ee]=R.useState(""),[oe,Q]=R.useState(""),[ne,de]=R.useState(""),[je,ve]=R.useState(null),le=Z=>je===Z,be=Hs(),Ce=rr({queryKey:["clusters"],queryFn:()=>Ss.listClusters()}),Ke=rr({queryKey:["load-balancers"],queryFn:()=>jb.listLoadBalancers()}),ce=rr({queryKey:["domains"],queryFn:()=>tc.listDomains()}),re=rr({queryKey:["record-sets",k],enabled:!!k,queryFn:()=>tc.listRecordSetsByDomain(k)}),ue=rr({queryKey:["servers"],queryFn:()=>hg.listServers()}),_e=rr({queryKey:["node-pools"],queryFn:()=>ka.listNodePools()}),fe=mr({resolver:gr(sq),defaultValues:{name:"",cluster_provider:"",region:"",docker_image:"",docker_tag:""}}),He=nn({mutationFn:Z=>Ss.createCluster(Z),onSuccess:async()=>{await be.invalidateQueries({queryKey:["clusters"]}),fe.reset(),o(!1),Ze.success("Cluster created successfully.")},onError:Z=>{Ze.error(Z?.message??"There was an error while creating the cluster")}}),Oe=Z=>{He.mutate(Z)},ke=mr({resolver:gr(fve),defaultValues:{}}),Ve=nn({mutationFn:({id:Z,values:we})=>Ss.updateCluster(Z,we),onSuccess:async()=>{await be.invalidateQueries({queryKey:["clusters"]}),ke.reset(),p(!1),Ze.success("Cluster updated successfully.")},onError:Z=>{Ze.error(Z?.message??"There was an error while updating the cluster")}}),ie=Z=>{Z.id&&(S(Z.id),ke.reset({name:Z.name??"",cluster_provider:Z.cluster_provider??"",region:Z.region??"",docker_image:Z.docker_image??"",docker_tag:Z.docker_tag??""}),p(!0))},De=nn({mutationFn:Z=>Ss.deleteCluster(Z),onSuccess:async()=>{await be.invalidateQueries({queryKey:["clusters"]}),g(null),Ze.success("Cluster deleted successfully.")},onError:Z=>{Ze.error(Z?.message??"There was an error while deleting the cluster")}}),Le=R.useMemo(()=>{const Z=Ce.data??[],we=e.trim().toLowerCase();return we?Z.filter(Re=>Re.name?.toLowerCase().includes(we)||Re.cluster_provider?.toLowerCase().includes(we)||Re.region?.toLowerCase().includes(we)||Re.status?.toLowerCase().includes(we)):Z},[e,Ce.data]);R.useEffect(()=>{if(!j){T(""),I(""),G(""),X(""),ee(""),Q(""),de("");return}j.captain_domain?.id&&T(j.captain_domain.id),j.control_plane_record_set?.id&&I(j.control_plane_record_set.id),j.apps_load_balancer?.id&&G(j.apps_load_balancer.id),j.glueops_load_balancer?.id&&X(j.glueops_load_balancer.id),j.bastion_server?.id&&ee(j.bastion_server.id)},[j]);async function tt(){if(j?.id)try{const Z=await Ss.getCluster(j.id);A(Z),await be.invalidateQueries({queryKey:["clusters"]})}catch{}}async function yt(){if(j?.id){if(!k){Ze.error("Domain is required");return}ve("captain");try{await Ss.attachCaptainDomain(j.id,{domain_id:k}),Ze.success("Captain domain attached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to attach captain domain.")}finally{ve(null)}}}async function Ot(){if(j?.id){ve("captain");try{await Ss.detachCaptainDomain(j.id),Ze.success("Captain domain detached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to detach captain domain.")}finally{ve(null)}}}async function Ft(){if(j?.id){if(!M){Ze.error("Record set is required");return}ve("recordset");try{await Ss.attachControlPlaneRecordSet(j.id,{record_set_id:M}),Ze.success("Control plane record set attached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to attach record set.")}finally{ve(null)}}}async function kt(){if(j?.id){ve("recordset");try{await Ss.detachControlPlaneRecordSet(j.id),Ze.success("Control plane record set detached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to detach record set.")}finally{ve(null)}}}async function Jt(){if(j?.id){if(!q){Ze.error("Load balancer is required");return}ve("apps-lb");try{await Ss.attachAppsLoadBalancer(j.id,{load_balancer_id:q}),Ze.success("Apps load balancer attached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to attach apps load balancer.")}finally{ve(null)}}}async function ze(){if(j?.id){ve("apps-lb");try{await Ss.detachAppsLoadBalancer(j.id),Ze.success("Apps load balancer detached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to detach apps load balancer.")}finally{ve(null)}}}async function zt(){if(j?.id){if(!K){Ze.error("Load balancer is required");return}ve("glueops-lb");try{await Ss.attachGlueOpsLoadBalancer(j.id,{load_balancer_id:K}),Ze.success("GlueOps load balancer attached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to attach GlueOps load balancer.")}finally{ve(null)}}}async function Rt(){if(j?.id){ve("glueops-lb");try{await Ss.detachGlueOpsLoadBalancer(j.id),Ze.success("GlueOps load balancer detached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to detach GlueOps load balancer.")}finally{ve(null)}}}async function V(){if(j?.id){if(!L){Ze.error("Server is required");return}ve("bastion");try{await Ss.attachBastion(j.id,{server_id:L}),Ze.success("Bastion server attached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to attach bastion server.")}finally{ve(null)}}}async function Dn(){if(j?.id){ve("bastion");try{await Ss.detachBastion(j.id),Ze.success("Bastion server detached."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to detach bastion server.")}finally{ve(null)}}}async function cn(){if(j?.id){if(!oe){Ze.error("Node pool is required");return}ve("nodepool");try{await Ss.attachNodePool(j.id,oe),Ze.success("Node pool attached."),Q(""),await tt()}catch(Z){Ze.error(Z?.message??"Failed to attach node pool.")}finally{ve(null)}}}async function xe(Z){if(j?.id){ve("nodepool");try{await Ss.detachNodePool(j.id,Z),Ze.success("Node pool detached."),await tt()}catch(we){Ze.error(we?.message??"Failed to detach node pool.")}finally{ve(null)}}}async function Ne(){if(j?.id){if(!ne.trim()){Ze.error("Kubeconfig is required");return}ve("kubeconfig");try{await Ss.setKubeconfig(j.id,{kubeconfig:ne}),Ze.success("Kubeconfig updated."),de(""),await tt()}catch(Z){Ze.error(Z?.message??"Failed to set kubeconfig.")}finally{ve(null)}}}async function Ge(){if(j?.id){ve("kubeconfig");try{await Ss.clearKubeconfig(j.id),Ze.success("Kubeconfig cleared."),await tt()}catch(Z){Ze.error(Z?.message??"Failed to clear kubeconfig.")}finally{ve(null)}}}if(Ce.isLoading)return u.jsx("div",{className:"p-6",children:"Loading clusters…"});if(Ce.error)return u.jsx("div",{className:"p-6 text-red-500",children:"Error loading clusters."});const D=Ke.data??[],z=D.filter(Z=>Z.kind==="public"),H=D.filter(Z=>Z.kind==="glueops");return u.jsxs("div",{className:"space-y-4 p-6",children:[u.jsxs("div",{className:"flex flex-col gap-3 md:flex-row md:items-center md:justify-between",children:[u.jsx("h1",{className:"mb-4 text-2xl font-bold",children:"Clusters"}),u.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[u.jsxs("div",{className:"relative",children:[u.jsx(Pa,{className:"absolute top-2.5 left-2 h-4 w-4 opacity-60"}),u.jsx(gt,{value:e,onChange:Z=>r(Z.target.value),placeholder:"Search clusters",className:"w-64 pl-8"})]}),u.jsxs(fn,{open:s,onOpenChange:o,children:[u.jsx(zi,{asChild:!0,children:u.jsxs(Fe,{onClick:()=>o(!0),children:[u.jsx(oo,{className:"mr-2 h-4 w-4"}),"Create Cluster"]})}),u.jsxs(mn,{className:"sm:max-w-lg",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Create Cluster"})}),u.jsx(yr,{...fe,children:u.jsxs("form",{className:"space-y-4",onSubmit:fe.handleSubmit(Oe),children:[u.jsx(pt,{control:fe.control,name:"name",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Name"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"prod-cluster-eu-west-1",...Z})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:fe.control,name:"cluster_provider",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Provider"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"aws / hetzner / baremetal",...Z})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:fe.control,name:"region",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Region"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"eu-west-1",...Z})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:fe.control,name:"docker_image",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Docker Image"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"ghcr.io/glueops/gluekube",...Z})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:fe.control,name:"docker_tag",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Docker Tag"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"v1.33",...Z})}),u.jsx(dt,{})]})}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{type:"button",variant:"outline",onClick:()=>o(!1),children:"Cancel"}),u.jsx(Fe,{type:"submit",disabled:He.isPending,children:He.isPending?"Creating…":"Create"})]})]})})]})]})]})]}),u.jsx("div",{className:"bg-background overflow-hidden rounded-2xl border shadow-sm",children:u.jsx("div",{className:"overflow-x-auto",children:u.jsxs(Fi,{children:[u.jsx(qi,{children:u.jsxs(an,{children:[u.jsx(At,{children:"Name"}),u.jsx(At,{children:"Provider"}),u.jsx(At,{children:"Region"}),u.jsx(At,{children:"Status"}),u.jsx(At,{children:"Docker"}),u.jsx(At,{children:"Summary"}),u.jsx(At,{className:"w-[320px] text-right",children:"Actions"})]})}),u.jsxs(Bi,{children:[Le.map(Z=>u.jsxs(an,{children:[u.jsx(xt,{className:"font-medium",children:Z.name}),u.jsx(xt,{children:Z.cluster_provider}),u.jsx(xt,{children:Z.region}),u.jsxs(xt,{children:[u.jsx(mve,{status:Z.status}),Z.last_error&&u.jsx("div",{className:"mt-1 text-xs text-red-500",children:el(Z.last_error,80)})]}),u.jsx(xt,{children:Z.docker_image+":"+Z.docker_tag}),u.jsxs(xt,{children:[u.jsx(gve,{c:Z}),Z.id&&u.jsx("code",{className:"text-muted-foreground mt-1 block text-xs",children:el(Z.id,6)})]}),u.jsx(xt,{children:u.jsxs("div",{className:"flex flex-wrap justify-end gap-2",children:[u.jsxs(Fe,{variant:"ghost",size:"sm",onClick:()=>A(Z),children:[u.jsx($W,{className:"mr-1 h-4 w-4"})," Configure"]}),u.jsxs(Fe,{variant:"outline",size:"sm",onClick:()=>ie(Z),children:[u.jsx(pu,{className:"mr-2 h-4 w-4"})," Edit"]}),u.jsx(Fe,{variant:"destructive",size:"sm",onClick:()=>Z.id&&g(Z.id),disabled:De.isPending&&m===Z.id,children:De.isPending&&m===Z.id?"Deleting…":"Delete"})]})})]},Z.id)),Le.length===0&&u.jsx(an,{children:u.jsxs(xt,{colSpan:6,className:"text-muted-foreground py-10 text-center",children:[u.jsx(Jb,{className:"mx-auto mb-2 h-6 w-6 opacity-60"}),"No clusters match your search."]})})]})]})})}),u.jsx(fn,{open:d,onOpenChange:p,children:u.jsxs(mn,{className:"sm:max-w-lg",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Edit Cluster"})}),u.jsx(yr,{...ke,children:u.jsxs("form",{className:"space-y-4",onSubmit:ke.handleSubmit(Z=>{b&&Ve.mutate({id:b,values:Z})}),children:[u.jsx(pt,{control:ke.control,name:"name",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Name"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"prod-cluster-eu-west-1",...Z})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:ke.control,name:"cluster_provider",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Provider"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"aws / hetzner / baremetal",...Z})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:ke.control,name:"region",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Region"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"eu-west-1",...Z})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:ke.control,name:"docker_image",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Docker Image"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"ghcr.io/glueops/gluekube",...Z})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:ke.control,name:"docker_tag",render:({field:Z})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Docker Tag"}),u.jsx(wt,{children:u.jsx(gt,{placeholder:"v1.33",...Z})}),u.jsx(dt,{})]})}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{type:"button",variant:"outline",onClick:()=>p(!1),children:"Cancel"}),u.jsx(Fe,{type:"submit",disabled:Ve.isPending,children:Ve.isPending?"Saving…":"Save changes"})]})]})})]})}),u.jsx(fn,{open:!!j,onOpenChange:Z=>!Z&&A(null),children:u.jsxs(mn,{className:"max-h-[90vh] w-full max-w-3xl overflow-y-auto",children:[u.jsx(gn,{children:u.jsxs(yn,{children:["Configure Cluster",j?.name?`: ${j.name}`:""]})}),j&&u.jsxs("div",{className:"space-y-6 py-2",children:[u.jsxs("section",{className:"space-y-2 rounded-xl border p-4",children:[u.jsx("div",{className:"flex items-center justify-between gap-2",children:u.jsxs("div",{children:[u.jsxs("div",{className:"flex items-center gap-2",children:[u.jsx(VZ,{className:"h-4 w-4"}),u.jsx("h3",{className:"text-sm font-semibold",children:"Kubeconfig"})]}),u.jsx("p",{className:"text-muted-foreground text-xs",children:"Paste the kubeconfig for this cluster. It will be stored encrypted and never returned by the API."})]})}),u.jsx(hu,{value:ne,onChange:Z=>de(Z.target.value),rows:6,placeholder:`apiVersion: v1 -clusters: - - cluster: ...`,className:"font-mono text-xs"}),u.jsxs("div",{className:"flex flex-wrap gap-2",children:[u.jsx(Fe,{size:"sm",onClick:Ne,disabled:le("kubeconfig"),children:le("kubeconfig")?"Saving…":"Save kubeconfig"}),u.jsx(Fe,{size:"sm",variant:"outline",onClick:Ge,disabled:le("kubeconfig"),children:"Clear kubeconfig"})]})]}),u.jsxs("section",{className:"space-y-2 rounded-xl border p-4",children:[u.jsxs("div",{className:"flex items-center justify-between gap-2",children:[u.jsxs("div",{children:[u.jsx("h3",{className:"text-sm font-semibold",children:"Captain Domain"}),u.jsx("p",{className:"text-muted-foreground text-xs",children:"Domain used for the AutoGlue captain endpoint."})]}),u.jsx("div",{className:"text-right text-xs",children:u.jsx("div",{className:"font-mono",children:j.captain_domain?j.captain_domain.domain_name:"Not attached"})})]}),u.jsxs("div",{className:"flex flex-col gap-2 md:flex-row md:items-end",children:[u.jsxs("div",{className:"flex-1",children:[u.jsx(xi,{className:"text-xs",children:"Domain"}),u.jsxs(Rn,{value:k,onValueChange:Z=>{T(Z),I("")},children:[u.jsx(_n,{className:"w-full",children:u.jsx(Tn,{placeholder:ce.isLoading?"Loading domains…":"Select domain"})}),u.jsx($n,{children:(ce.data??[]).map(Z=>u.jsx(jt,{value:Z.id,children:Z.domain_name},Z.id))})]}),u.jsx("p",{className:"text-muted-foreground mt-1 text-[11px]",children:"Once a domain is attached, control plane record sets for that domain will be available below."})]}),u.jsxs("div",{className:"flex gap-2",children:[u.jsx(Fe,{size:"sm",onClick:yt,disabled:le("captain")||ce.isLoading,children:le("captain")?"Attaching…":"Attach"}),u.jsx(Fe,{size:"sm",variant:"outline",onClick:Ot,disabled:le("captain")||!j.captain_domain,children:"Detach"})]})]})]}),k&&u.jsxs("section",{className:"space-y-2 rounded-xl border p-4",children:[u.jsxs("div",{className:"flex items-center justify-between gap-2",children:[u.jsxs("div",{children:[u.jsx("h3",{className:"text-sm font-semibold",children:"Control Plane Record Set"}),u.jsx("p",{className:"text-muted-foreground text-xs",children:"DNS record set used for the cluster control plane endpoint."})]}),u.jsx("div",{className:"text-right text-xs",children:u.jsx("div",{className:"font-mono",children:j.control_plane_record_set?j.control_plane_record_set.name:"Not attached"})})]}),u.jsxs("div",{className:"flex flex-col gap-2 md:flex-row md:items-end",children:[u.jsxs("div",{className:"flex-1",children:[u.jsx(xi,{className:"text-xs",children:"Record Set"}),u.jsxs(Rn,{value:M,onValueChange:Z=>I(Z),children:[u.jsx(_n,{className:"w-full",children:u.jsx(Tn,{placeholder:re.isLoading?"Loading record sets…":"Select record set"})}),u.jsx($n,{children:(re.data??[]).map(Z=>u.jsxs(jt,{value:Z.id,children:[Z.name," · ",Z.type]},Z.id))})]})]}),u.jsxs("div",{className:"flex gap-2",children:[u.jsx(Fe,{size:"sm",onClick:Ft,disabled:le("recordset")||re.isLoading,children:le("recordset")?"Attaching…":"Attach"}),u.jsx(Fe,{size:"sm",variant:"outline",onClick:kt,disabled:le("recordset")||!j.control_plane_record_set,children:"Detach"})]})]})]}),u.jsxs("section",{className:"space-y-2 rounded-xl border p-4",children:[u.jsxs("div",{className:"flex items-center justify-between gap-2",children:[u.jsxs("div",{children:[u.jsx("h3",{className:"text-sm font-semibold",children:"Apps Load Balancer"}),u.jsx("p",{className:"text-muted-foreground text-xs",children:"Frontend load balancer for application traffic."})]}),u.jsx("div",{className:"text-right text-xs",children:u.jsx("div",{className:"font-mono",children:j.apps_load_balancer?j.apps_load_balancer.name:"Not attached"})})]}),u.jsxs("div",{className:"flex flex-col gap-2 md:flex-row md:items-end",children:[u.jsxs("div",{className:"flex-1",children:[u.jsx(xi,{className:"text-xs",children:"Apps Load Balancer"}),u.jsxs(Rn,{value:q,onValueChange:Z=>G(Z),children:[u.jsx(_n,{className:"w-full",children:u.jsx(Tn,{placeholder:Ke.isLoading?"Loading load balancers…":"Select apps LB"})}),u.jsx($n,{children:z.map(Z=>u.jsxs(jt,{value:Z.id,children:[Z.name," · ",Z.public_ip_address]},Z.id))})]})]}),u.jsxs("div",{className:"flex gap-2",children:[u.jsx(Fe,{size:"sm",onClick:Jt,disabled:le("apps-lb")||Ke.isLoading,children:le("apps-lb")?"Attaching…":"Attach"}),u.jsx(Fe,{size:"sm",variant:"outline",onClick:ze,disabled:le("apps-lb")||!j.apps_load_balancer,children:"Detach"})]})]})]}),u.jsxs("section",{className:"space-y-2 rounded-xl border p-4",children:[u.jsxs("div",{className:"flex items-center justify-between gap-2",children:[u.jsxs("div",{children:[u.jsx("h3",{className:"text-sm font-semibold",children:"GlueOps / Control-plane Load Balancer"}),u.jsx("p",{className:"text-muted-foreground text-xs",children:"Load balancer for GlueOps/control-plane traffic."})]}),u.jsx("div",{className:"text-right text-xs",children:u.jsx("div",{className:"font-mono",children:j.glueops_load_balancer?j.glueops_load_balancer.name:"Not attached"})})]}),u.jsxs("div",{className:"flex flex-col gap-2 md:flex-row md:items-end",children:[u.jsxs("div",{className:"flex-1",children:[u.jsx(xi,{className:"text-xs",children:"GlueOps Load Balancer"}),u.jsxs(Rn,{value:K,onValueChange:Z=>X(Z),children:[u.jsx(_n,{className:"w-full",children:u.jsx(Tn,{placeholder:Ke.isLoading?"Loading load balancers…":"Select GlueOps LB"})}),u.jsx($n,{children:H.map(Z=>u.jsxs(jt,{value:Z.id,children:[Z.name," · ",Z.private_ip_address]},Z.id))})]})]}),u.jsxs("div",{className:"flex gap-2",children:[u.jsx(Fe,{size:"sm",onClick:zt,disabled:le("glueops-lb")||Ke.isLoading,children:le("glueops-lb")?"Attaching…":"Attach"}),u.jsx(Fe,{size:"sm",variant:"outline",onClick:Rt,disabled:le("glueops-lb")||!j.glueops_load_balancer,children:"Detach"})]})]})]}),u.jsxs("section",{className:"space-y-2 rounded-xl border p-4",children:[u.jsxs("div",{className:"flex items-center justify-between gap-2",children:[u.jsxs("div",{children:[u.jsxs("div",{className:"flex items-center gap-2",children:[u.jsx(F_,{className:"h-4 w-4"}),u.jsx("h3",{className:"text-sm font-semibold",children:"Bastion Server"})]}),u.jsx("p",{className:"text-muted-foreground text-xs",children:"SSH bastion used to reach the cluster nodes."})]}),u.jsx("div",{className:"text-right text-xs",children:u.jsx("div",{className:"font-mono",children:j.bastion_server?j.bastion_server.hostname??j.bastion_server.id:"Not attached"})})]}),u.jsxs("div",{className:"flex flex-col gap-2 md:flex-row md:items-end",children:[u.jsxs("div",{className:"flex-1",children:[u.jsx(xi,{className:"text-xs",children:"Bastion Server"}),u.jsxs(Rn,{value:L,onValueChange:Z=>ee(Z),children:[u.jsx(_n,{className:"w-full",children:u.jsx(Tn,{placeholder:ue.isLoading?"Loading servers…":"Select server"})}),u.jsx($n,{children:(ue.data??[]).map(Z=>u.jsxs(jt,{value:Z.id,children:[Z.hostname??Z.id," · ",Z.private_ip_address]},Z.id))})]})]}),u.jsxs("div",{className:"flex gap-2",children:[u.jsx(Fe,{size:"sm",onClick:V,disabled:le("bastion")||ue.isLoading,children:le("bastion")?"Attaching…":"Attach"}),u.jsx(Fe,{size:"sm",variant:"outline",onClick:Dn,disabled:le("bastion")||!j.bastion_server,children:"Detach"})]})]})]}),u.jsxs("section",{className:"space-y-2 rounded-xl border p-4",children:[u.jsx("div",{className:"flex items-center justify-between gap-2",children:u.jsxs("div",{children:[u.jsx("h3",{className:"text-sm font-semibold",children:"Node Pools"}),u.jsx("p",{className:"text-muted-foreground text-xs",children:"Attach node pools to this cluster. Each node pool may have its own labels, taints, and backing servers."})]})}),u.jsxs("div",{className:"flex flex-col gap-2 md:flex-row md:items-end",children:[u.jsxs("div",{className:"flex-1",children:[u.jsx(xi,{className:"text-xs",children:"Available Node Pools"}),u.jsxs(Rn,{value:oe,onValueChange:Z=>Q(Z),children:[u.jsx(_n,{className:"w-full",children:u.jsx(Tn,{placeholder:_e.isLoading?"Loading node pools…":"Select node pool"})}),u.jsx($n,{children:(_e.data??[]).map(Z=>u.jsxs(jt,{value:Z.id,children:[Z.name," · ",Z.role]},Z.id))})]})]}),u.jsx("div",{className:"flex gap-2",children:u.jsx(Fe,{size:"sm",onClick:cn,disabled:le("nodepool")||_e.isLoading,children:le("nodepool")?"Attaching…":"Attach"})})]}),u.jsxs("div",{className:"mt-3 space-y-1",children:[u.jsx(xi,{className:"text-xs",children:"Attached Node Pools"}),j.node_pools&&j.node_pools.length>0?u.jsx("div",{className:"divide-border mt-1 rounded-md border",children:j.node_pools.map(Z=>u.jsxs("div",{className:"flex items-center justify-between gap-3 px-3 py-2 text-xs",children:[u.jsxs("div",{className:"flex flex-col",children:[u.jsx("span",{className:"font-medium",children:Z.name}),u.jsxs("span",{className:"text-muted-foreground",children:["role: ",Z.role," · servers: ",Z.servers?.length??0]})]}),u.jsx(Fe,{size:"sm",variant:"outline",onClick:()=>Z.id&&xe(Z.id),disabled:le("nodepool"),children:"Detach"})]},Z.id))}):u.jsx("p",{className:"text-muted-foreground mt-1 text-xs",children:"No node pools attached to this cluster yet."})]})]}),u.jsx(Sn,{className:"mt-2",children:u.jsx(Fe,{variant:"outline",onClick:()=>A(null),children:"Close"})})]})]})}),u.jsx(fn,{open:!!m,onOpenChange:Z=>!Z&&g(null),children:u.jsxs(mn,{className:"sm:max-w-md",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Delete cluster"})}),u.jsx("p",{className:"text-muted-foreground text-sm",children:"This action cannot be undone. Are you sure you want to delete this cluster?"}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{variant:"outline",onClick:()=>g(null),children:"Cancel"}),u.jsx(Fe,{variant:"destructive",onClick:()=>m&&De.mutate(m),disabled:De.isPending,children:De.isPending?"Deleting…":"Delete"})]})]})}),u.jsx("pre",{children:JSON.stringify(Ce.data,null,2)})]})},Ym=ite(),Qm={listCredentials:()=>ut(async()=>await Ym.listCredentials()),createCredential:async e=>ut(async()=>await Ym.createCredential({dtoCreateCredentialRequest:e})),getCredential:async e=>ut(async()=>await Ym.getCredential({id:e})),deleteCredential:async e=>ut(async()=>{await Ym.deleteCredential({id:e})}),updateCredential:async(e,r)=>ut(async()=>await Ym.updateCredential({id:e,dtoUpdateCredentialRequest:r})),revealCredential:async e=>ut(async()=>await Ym.revealCredential({id:e}))};var vve=Symbol("radix.slottable");function xve(e){const r=({children:s})=>u.jsx(u.Fragment,{children:s});return r.displayName=`${e}.Slottable`,r.__radixId=vve,r}var iq="AlertDialog",[bve]=al(iq,[Az]),vu=Az(),aq=e=>{const{__scopeAlertDialog:r,...s}=e,o=vu(r);return u.jsx(TC,{...o,...s,modal:!0})};aq.displayName=iq;var wve="AlertDialogTrigger",oq=R.forwardRef((e,r)=>{const{__scopeAlertDialog:s,...o}=e,d=vu(s);return u.jsx(Bz,{...d,...o,ref:r})});oq.displayName=wve;var Sve="AlertDialogPortal",lq=e=>{const{__scopeAlertDialog:r,...s}=e,o=vu(r);return u.jsx(_C,{...o,...s})};lq.displayName=Sve;var Eve="AlertDialogOverlay",cq=R.forwardRef((e,r)=>{const{__scopeAlertDialog:s,...o}=e,d=vu(s);return u.jsx($C,{...d,...o,ref:r})});cq.displayName=Eve;var yg="AlertDialogContent",[jve,Cve]=bve(yg),Ave=xve("AlertDialogContent"),uq=R.forwardRef((e,r)=>{const{__scopeAlertDialog:s,children:o,...d}=e,p=vu(s),m=R.useRef(null),g=zn(r,m),b=R.useRef(null);return u.jsx(oae,{contentName:yg,titleName:dq,docsSlug:"alert-dialog",children:u.jsx(jve,{scope:s,cancelRef:b,children:u.jsxs(NC,{role:"alertdialog",...p,...d,ref:g,onOpenAutoFocus:$t(d.onOpenAutoFocus,S=>{S.preventDefault(),b.current?.focus({preventScroll:!0})}),onPointerDownOutside:S=>S.preventDefault(),onInteractOutside:S=>S.preventDefault(),children:[u.jsx(Ave,{children:o}),u.jsx(kve,{contentRef:m})]})})})});uq.displayName=yg;var dq="AlertDialogTitle",hq=R.forwardRef((e,r)=>{const{__scopeAlertDialog:s,...o}=e,d=vu(s);return u.jsx(i2,{...d,...o,ref:r})});hq.displayName=dq;var pq="AlertDialogDescription",fq=R.forwardRef((e,r)=>{const{__scopeAlertDialog:s,...o}=e,d=vu(s);return u.jsx(a2,{...d,...o,ref:r})});fq.displayName=pq;var Ove="AlertDialogAction",mq=R.forwardRef((e,r)=>{const{__scopeAlertDialog:s,...o}=e,d=vu(s);return u.jsx(ow,{...d,...o,ref:r})});mq.displayName=Ove;var gq="AlertDialogCancel",yq=R.forwardRef((e,r)=>{const{__scopeAlertDialog:s,...o}=e,{cancelRef:d}=Cve(gq,s),p=vu(s),m=zn(r,d);return u.jsx(ow,{...p,...o,ref:m})});yq.displayName=gq;var kve=({contentRef:e})=>{const r=`\`${yg}\` requires a description for the component to be accessible for screen reader users. - -You can add a description to the \`${yg}\` by passing a \`${pq}\` component as a child, which also benefits sighted users by adding visible context to the dialog. - -Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${yg}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component. - -For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return R.useEffect(()=>{document.getElementById(e.current?.getAttribute("aria-describedby"))||console.warn(r)},[r,e]),null},Rve=aq,Tve=oq,_ve=lq,$ve=cq,Nve=uq,Dve=mq,Pve=yq,Mve=hq,Ive=fq;function nC({...e}){return u.jsx(Rve,{"data-slot":"alert-dialog",...e})}function rC({...e}){return u.jsx(Tve,{"data-slot":"alert-dialog-trigger",...e})}function Lve({...e}){return u.jsx(_ve,{"data-slot":"alert-dialog-portal",...e})}function zve({className:e,...r}){return u.jsx($ve,{"data-slot":"alert-dialog-overlay",className:ft("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",e),...r})}function sC({className:e,...r}){return u.jsxs(Lve,{children:[u.jsx(zve,{}),u.jsx(Nve,{"data-slot":"alert-dialog-content",className:ft("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",e),...r})]})}function iC({className:e,...r}){return u.jsx("div",{"data-slot":"alert-dialog-header",className:ft("flex flex-col gap-2 text-center sm:text-left",e),...r})}function aC({className:e,...r}){return u.jsx("div",{"data-slot":"alert-dialog-footer",className:ft("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",e),...r})}function oC({className:e,...r}){return u.jsx(Mve,{"data-slot":"alert-dialog-title",className:ft("text-lg font-semibold",e),...r})}function lC({className:e,...r}){return u.jsx(Ive,{"data-slot":"alert-dialog-description",className:ft("text-muted-foreground text-sm",e),...r})}function cC({className:e,...r}){return u.jsx(Dve,{className:ft(V_(),e),...r})}function uC({className:e,...r}){return u.jsx(Pve,{className:ft(V_({variant:"outline"}),e),...r})}var mT="rovingFocusGroup.onEntryFocus",Fve={bubbles:!1,cancelable:!0},mw="RovingFocusGroup",[E_,vq,qve]=s$(mw),[Bve,xq]=al(mw,[qve]),[Uve,Kve]=Bve(mw),bq=R.forwardRef((e,r)=>u.jsx(E_.Provider,{scope:e.__scopeRovingFocusGroup,children:u.jsx(E_.Slot,{scope:e.__scopeRovingFocusGroup,children:u.jsx(Vve,{...e,ref:r})})}));bq.displayName=mw;var Vve=R.forwardRef((e,r)=>{const{__scopeRovingFocusGroup:s,orientation:o,loop:d=!1,dir:p,currentTabStopId:m,defaultCurrentTabStopId:g,onCurrentTabStopIdChange:b,onEntryFocus:S,preventScrollOnEntryFocus:j=!1,...A}=e,k=R.useRef(null),T=zn(r,k),M=i$(p),[I,q]=qd({prop:m,defaultProp:g??null,onChange:b,caller:mw}),[G,K]=R.useState(!1),X=tl(S),L=vq(s),ee=R.useRef(!1),[oe,Q]=R.useState(0);return R.useEffect(()=>{const ne=k.current;if(ne)return ne.addEventListener(mT,X),()=>ne.removeEventListener(mT,X)},[X]),u.jsx(Uve,{scope:s,orientation:o,dir:M,loop:d,currentTabStopId:I,onItemFocus:R.useCallback(ne=>q(ne),[q]),onItemShiftTab:R.useCallback(()=>K(!0),[]),onFocusableItemAdd:R.useCallback(()=>Q(ne=>ne+1),[]),onFocusableItemRemove:R.useCallback(()=>Q(ne=>ne-1),[]),children:u.jsx(Cn.div,{tabIndex:G||oe===0?-1:0,"data-orientation":o,...A,ref:T,style:{outline:"none",...e.style},onMouseDown:$t(e.onMouseDown,()=>{ee.current=!0}),onFocus:$t(e.onFocus,ne=>{const de=!ee.current;if(ne.target===ne.currentTarget&&de&&!G){const je=new CustomEvent(mT,Fve);if(ne.currentTarget.dispatchEvent(je),!je.defaultPrevented){const ve=L().filter(ce=>ce.focusable),le=ve.find(ce=>ce.active),be=ve.find(ce=>ce.id===I),Ke=[le,be,...ve].filter(Boolean).map(ce=>ce.ref.current);Eq(Ke,j)}}ee.current=!1}),onBlur:$t(e.onBlur,()=>K(!1))})})}),wq="RovingFocusGroupItem",Sq=R.forwardRef((e,r)=>{const{__scopeRovingFocusGroup:s,focusable:o=!0,active:d=!1,tabStopId:p,children:m,...g}=e,b=Vs(),S=p||b,j=Kve(wq,s),A=j.currentTabStopId===S,k=vq(s),{onFocusableItemAdd:T,onFocusableItemRemove:M,currentTabStopId:I}=j;return R.useEffect(()=>{if(o)return T(),()=>M()},[o,T,M]),u.jsx(E_.ItemSlot,{scope:s,id:S,focusable:o,active:d,children:u.jsx(Cn.span,{tabIndex:A?0:-1,"data-orientation":j.orientation,...g,ref:r,onMouseDown:$t(e.onMouseDown,q=>{o?j.onItemFocus(S):q.preventDefault()}),onFocus:$t(e.onFocus,()=>j.onItemFocus(S)),onKeyDown:$t(e.onKeyDown,q=>{if(q.key==="Tab"&&q.shiftKey){j.onItemShiftTab();return}if(q.target!==q.currentTarget)return;const G=Xve(q,j.orientation,j.dir);if(G!==void 0){if(q.metaKey||q.ctrlKey||q.altKey||q.shiftKey)return;q.preventDefault();let X=k().filter(L=>L.focusable).map(L=>L.ref.current);if(G==="last")X.reverse();else if(G==="prev"||G==="next"){G==="prev"&&X.reverse();const L=X.indexOf(q.currentTarget);X=j.loop?Yve(X,L+1):X.slice(L+1)}setTimeout(()=>Eq(X))}}),children:typeof m=="function"?m({isCurrentTabStop:A,hasTabStop:I!=null}):m})})});Sq.displayName=wq;var Hve={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Gve(e,r){return r!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Xve(e,r,s){const o=Gve(e.key,s);if(!(r==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(r==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return Hve[o]}function Eq(e,r=!1){const s=document.activeElement;for(const o of e)if(o===s||(o.focus({preventScroll:r}),document.activeElement!==s))return}function Yve(e,r){return e.map((s,o)=>e[(r+o)%e.length])}var Zve=bq,Wve=Sq;function Jve(e){const r=Qve(e),s=R.forwardRef((o,d)=>{const{children:p,...m}=o,g=R.Children.toArray(p),b=g.find(txe);if(b){const S=b.props.children,j=g.map(A=>A===b?R.Children.count(S)>1?R.Children.only(null):R.isValidElement(S)?S.props.children:null:A);return u.jsx(r,{...m,ref:d,children:R.isValidElement(S)?R.cloneElement(S,void 0,j):null})}return u.jsx(r,{...m,ref:d,children:p})});return s.displayName=`${e}.Slot`,s}function Qve(e){const r=R.forwardRef((s,o)=>{const{children:d,...p}=s;if(R.isValidElement(d)){const m=rxe(d),g=nxe(p,d.props);return d.type!==R.Fragment&&(g.ref=o?Li(o,m):m),R.cloneElement(d,g)}return R.Children.count(d)>1?R.Children.only(null):null});return r.displayName=`${e}.SlotClone`,r}var exe=Symbol("radix.slottable");function txe(e){return R.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===exe}function nxe(e,r){const s={...r};for(const o in r){const d=e[o],p=r[o];/^on[A-Z]/.test(o)?d&&p?s[o]=(...g)=>{const b=p(...g);return d(...g),b}:d&&(s[o]=d):o==="style"?s[o]={...d,...p}:o==="className"&&(s[o]=[d,p].filter(Boolean).join(" "))}return{...e,...s}}function rxe(e){let r=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning;return s?e.ref:(r=Object.getOwnPropertyDescriptor(e,"ref")?.get,s=r&&"isReactWarning"in r&&r.isReactWarning,s?e.props.ref:e.props.ref||e.ref)}var j_=["Enter"," "],sxe=["ArrowDown","PageUp","Home"],jq=["ArrowUp","PageDown","End"],ixe=[...sxe,...jq],axe={ltr:[...j_,"ArrowRight"],rtl:[...j_,"ArrowLeft"]},oxe={ltr:["ArrowLeft"],rtl:["ArrowRight"]},gw="Menu",[Zb,lxe,cxe]=s$(gw),[Mp,Cq]=al(gw,[cxe,Hd,xq]),ZC=Hd(),Aq=xq(),[uxe,Ip]=Mp(gw),[dxe,yw]=Mp(gw),Oq=e=>{const{__scopeMenu:r,open:s=!1,children:o,dir:d,onOpenChange:p,modal:m=!0}=e,g=ZC(r),[b,S]=R.useState(null),j=R.useRef(!1),A=tl(p),k=i$(d);return R.useEffect(()=>{const T=()=>{j.current=!0,document.addEventListener("pointerdown",M,{capture:!0,once:!0}),document.addEventListener("pointermove",M,{capture:!0,once:!0})},M=()=>j.current=!1;return document.addEventListener("keydown",T,{capture:!0}),()=>{document.removeEventListener("keydown",T,{capture:!0}),document.removeEventListener("pointerdown",M,{capture:!0}),document.removeEventListener("pointermove",M,{capture:!0})}},[]),u.jsx(wC,{...g,children:u.jsx(uxe,{scope:r,open:s,onOpenChange:A,content:b,onContentChange:S,children:u.jsx(dxe,{scope:r,onClose:R.useCallback(()=>A(!1),[A]),isUsingKeyboardRef:j,dir:k,modal:m,children:o})})})};Oq.displayName=gw;var hxe="MenuAnchor",o$=R.forwardRef((e,r)=>{const{__scopeMenu:s,...o}=e,d=ZC(s);return u.jsx(tw,{...d,...o,ref:r})});o$.displayName=hxe;var l$="MenuPortal",[pxe,kq]=Mp(l$,{forceMount:void 0}),Rq=e=>{const{__scopeMenu:r,forceMount:s,children:o,container:d}=e,p=Ip(l$,r);return u.jsx(pxe,{scope:r,forceMount:s,children:u.jsx(lo,{present:s||p.open,children:u.jsx(_g,{asChild:!0,container:d,children:o})})})};Rq.displayName=l$;var io="MenuContent",[fxe,c$]=Mp(io),Tq=R.forwardRef((e,r)=>{const s=kq(io,e.__scopeMenu),{forceMount:o=s.forceMount,...d}=e,p=Ip(io,e.__scopeMenu),m=yw(io,e.__scopeMenu);return u.jsx(Zb.Provider,{scope:e.__scopeMenu,children:u.jsx(lo,{present:o||p.open,children:u.jsx(Zb.Slot,{scope:e.__scopeMenu,children:m.modal?u.jsx(mxe,{...d,ref:r}):u.jsx(gxe,{...d,ref:r})})})})}),mxe=R.forwardRef((e,r)=>{const s=Ip(io,e.__scopeMenu),o=R.useRef(null),d=zn(r,o);return R.useEffect(()=>{const p=o.current;if(p)return kC(p)},[]),u.jsx(u$,{...e,ref:d,trapFocus:s.open,disableOutsidePointerEvents:s.open,disableOutsideScroll:!0,onFocusOutside:$t(e.onFocusOutside,p=>p.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>s.onOpenChange(!1)})}),gxe=R.forwardRef((e,r)=>{const s=Ip(io,e.__scopeMenu);return u.jsx(u$,{...e,ref:r,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>s.onOpenChange(!1)})}),yxe=Jve("MenuContent.ScrollLock"),u$=R.forwardRef((e,r)=>{const{__scopeMenu:s,loop:o=!1,trapFocus:d,onOpenAutoFocus:p,onCloseAutoFocus:m,disableOutsidePointerEvents:g,onEntryFocus:b,onEscapeKeyDown:S,onPointerDownOutside:j,onFocusOutside:A,onInteractOutside:k,onDismiss:T,disableOutsideScroll:M,...I}=e,q=Ip(io,s),G=yw(io,s),K=ZC(s),X=Aq(s),L=lxe(s),[ee,oe]=R.useState(null),Q=R.useRef(null),ne=zn(r,Q,q.onContentChange),de=R.useRef(0),je=R.useRef(""),ve=R.useRef(0),le=R.useRef(null),be=R.useRef("right"),Ce=R.useRef(0),Ke=M?aw:R.Fragment,ce=M?{as:yxe,allowPinchZoom:!0}:void 0,re=_e=>{const fe=je.current+_e,He=L().filter(Le=>!Le.disabled),Oe=document.activeElement,ke=He.find(Le=>Le.ref.current===Oe)?.textValue,Ve=He.map(Le=>Le.textValue),ie=Rxe(Ve,fe,ke),De=He.find(Le=>Le.textValue===ie)?.ref.current;(function Le(tt){je.current=tt,window.clearTimeout(de.current),tt!==""&&(de.current=window.setTimeout(()=>Le(""),1e3))})(fe),De&&setTimeout(()=>De.focus())};R.useEffect(()=>()=>window.clearTimeout(de.current),[]),AC();const ue=R.useCallback(_e=>be.current===le.current?.side&&_xe(_e,le.current?.area),[]);return u.jsx(fxe,{scope:s,searchRef:je,onItemEnter:R.useCallback(_e=>{ue(_e)&&_e.preventDefault()},[ue]),onItemLeave:R.useCallback(_e=>{ue(_e)||(Q.current?.focus(),oe(null))},[ue]),onTriggerLeave:R.useCallback(_e=>{ue(_e)&&_e.preventDefault()},[ue]),pointerGraceTimerRef:ve,onPointerGraceIntentChange:R.useCallback(_e=>{le.current=_e},[]),children:u.jsx(Ke,{...ce,children:u.jsx(iw,{asChild:!0,trapped:d,onMountAutoFocus:$t(p,_e=>{_e.preventDefault(),Q.current?.focus({preventScroll:!0})}),onUnmountAutoFocus:m,children:u.jsx(kg,{asChild:!0,disableOutsidePointerEvents:g,onEscapeKeyDown:S,onPointerDownOutside:j,onFocusOutside:A,onInteractOutside:k,onDismiss:T,children:u.jsx(Zve,{asChild:!0,...X,dir:G.dir,orientation:"vertical",loop:o,currentTabStopId:ee,onCurrentTabStopIdChange:oe,onEntryFocus:$t(b,_e=>{G.isUsingKeyboardRef.current||_e.preventDefault()}),preventScrollOnEntryFocus:!0,children:u.jsx(SC,{role:"menu","aria-orientation":"vertical","data-state":Hq(q.open),"data-radix-menu-content":"",dir:G.dir,...K,...I,ref:ne,style:{outline:"none",...I.style},onKeyDown:$t(I.onKeyDown,_e=>{const He=_e.target.closest("[data-radix-menu-content]")===_e.currentTarget,Oe=_e.ctrlKey||_e.altKey||_e.metaKey,ke=_e.key.length===1;He&&(_e.key==="Tab"&&_e.preventDefault(),!Oe&&ke&&re(_e.key));const Ve=Q.current;if(_e.target!==Ve||!ixe.includes(_e.key))return;_e.preventDefault();const De=L().filter(Le=>!Le.disabled).map(Le=>Le.ref.current);jq.includes(_e.key)&&De.reverse(),Oxe(De)}),onBlur:$t(e.onBlur,_e=>{_e.currentTarget.contains(_e.target)||(window.clearTimeout(de.current),je.current="")}),onPointerMove:$t(e.onPointerMove,Wb(_e=>{const fe=_e.target,He=Ce.current!==_e.clientX;if(_e.currentTarget.contains(fe)&&He){const Oe=_e.clientX>Ce.current?"right":"left";be.current=Oe,Ce.current=_e.clientX}}))})})})})})})});Tq.displayName=io;var vxe="MenuGroup",d$=R.forwardRef((e,r)=>{const{__scopeMenu:s,...o}=e;return u.jsx(Cn.div,{role:"group",...o,ref:r})});d$.displayName=vxe;var xxe="MenuLabel",_q=R.forwardRef((e,r)=>{const{__scopeMenu:s,...o}=e;return u.jsx(Cn.div,{...o,ref:r})});_q.displayName=xxe;var dC="MenuItem",k3="menu.itemSelect",WC=R.forwardRef((e,r)=>{const{disabled:s=!1,onSelect:o,...d}=e,p=R.useRef(null),m=yw(dC,e.__scopeMenu),g=c$(dC,e.__scopeMenu),b=zn(r,p),S=R.useRef(!1),j=()=>{const A=p.current;if(!s&&A){const k=new CustomEvent(k3,{bubbles:!0,cancelable:!0});A.addEventListener(k3,T=>o?.(T),{once:!0}),TL(A,k),k.defaultPrevented?S.current=!1:m.onClose()}};return u.jsx($q,{...d,ref:b,disabled:s,onClick:$t(e.onClick,j),onPointerDown:A=>{e.onPointerDown?.(A),S.current=!0},onPointerUp:$t(e.onPointerUp,A=>{S.current||A.currentTarget?.click()}),onKeyDown:$t(e.onKeyDown,A=>{const k=g.searchRef.current!=="";s||k&&A.key===" "||j_.includes(A.key)&&(A.currentTarget.click(),A.preventDefault())})})});WC.displayName=dC;var $q=R.forwardRef((e,r)=>{const{__scopeMenu:s,disabled:o=!1,textValue:d,...p}=e,m=c$(dC,s),g=Aq(s),b=R.useRef(null),S=zn(r,b),[j,A]=R.useState(!1),[k,T]=R.useState("");return R.useEffect(()=>{const M=b.current;M&&T((M.textContent??"").trim())},[p.children]),u.jsx(Zb.ItemSlot,{scope:s,disabled:o,textValue:d??k,children:u.jsx(Wve,{asChild:!0,...g,focusable:!o,children:u.jsx(Cn.div,{role:"menuitem","data-highlighted":j?"":void 0,"aria-disabled":o||void 0,"data-disabled":o?"":void 0,...p,ref:S,onPointerMove:$t(e.onPointerMove,Wb(M=>{o?m.onItemLeave(M):(m.onItemEnter(M),M.defaultPrevented||M.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:$t(e.onPointerLeave,Wb(M=>m.onItemLeave(M))),onFocus:$t(e.onFocus,()=>A(!0)),onBlur:$t(e.onBlur,()=>A(!1))})})})}),bxe="MenuCheckboxItem",Nq=R.forwardRef((e,r)=>{const{checked:s=!1,onCheckedChange:o,...d}=e;return u.jsx(Lq,{scope:e.__scopeMenu,checked:s,children:u.jsx(WC,{role:"menuitemcheckbox","aria-checked":hC(s)?"mixed":s,...d,ref:r,"data-state":p$(s),onSelect:$t(d.onSelect,()=>o?.(hC(s)?!0:!s),{checkForDefaultPrevented:!1})})})});Nq.displayName=bxe;var Dq="MenuRadioGroup",[wxe,Sxe]=Mp(Dq,{value:void 0,onValueChange:()=>{}}),Pq=R.forwardRef((e,r)=>{const{value:s,onValueChange:o,...d}=e,p=tl(o);return u.jsx(wxe,{scope:e.__scopeMenu,value:s,onValueChange:p,children:u.jsx(d$,{...d,ref:r})})});Pq.displayName=Dq;var Mq="MenuRadioItem",Iq=R.forwardRef((e,r)=>{const{value:s,...o}=e,d=Sxe(Mq,e.__scopeMenu),p=s===d.value;return u.jsx(Lq,{scope:e.__scopeMenu,checked:p,children:u.jsx(WC,{role:"menuitemradio","aria-checked":p,...o,ref:r,"data-state":p$(p),onSelect:$t(o.onSelect,()=>d.onValueChange?.(s),{checkForDefaultPrevented:!1})})})});Iq.displayName=Mq;var h$="MenuItemIndicator",[Lq,Exe]=Mp(h$,{checked:!1}),zq=R.forwardRef((e,r)=>{const{__scopeMenu:s,forceMount:o,...d}=e,p=Exe(h$,s);return u.jsx(lo,{present:o||hC(p.checked)||p.checked===!0,children:u.jsx(Cn.span,{...d,ref:r,"data-state":p$(p.checked)})})});zq.displayName=h$;var jxe="MenuSeparator",Fq=R.forwardRef((e,r)=>{const{__scopeMenu:s,...o}=e;return u.jsx(Cn.div,{role:"separator","aria-orientation":"horizontal",...o,ref:r})});Fq.displayName=jxe;var Cxe="MenuArrow",qq=R.forwardRef((e,r)=>{const{__scopeMenu:s,...o}=e,d=ZC(s);return u.jsx(EC,{...d,...o,ref:r})});qq.displayName=Cxe;var Axe="MenuSub",[E0e,Bq]=Mp(Axe),Ab="MenuSubTrigger",Uq=R.forwardRef((e,r)=>{const s=Ip(Ab,e.__scopeMenu),o=yw(Ab,e.__scopeMenu),d=Bq(Ab,e.__scopeMenu),p=c$(Ab,e.__scopeMenu),m=R.useRef(null),{pointerGraceTimerRef:g,onPointerGraceIntentChange:b}=p,S={__scopeMenu:e.__scopeMenu},j=R.useCallback(()=>{m.current&&window.clearTimeout(m.current),m.current=null},[]);return R.useEffect(()=>j,[j]),R.useEffect(()=>{const A=g.current;return()=>{window.clearTimeout(A),b(null)}},[g,b]),u.jsx(o$,{asChild:!0,...S,children:u.jsx($q,{id:d.triggerId,"aria-haspopup":"menu","aria-expanded":s.open,"aria-controls":d.contentId,"data-state":Hq(s.open),...e,ref:Li(r,d.onTriggerChange),onClick:A=>{e.onClick?.(A),!(e.disabled||A.defaultPrevented)&&(A.currentTarget.focus(),s.open||s.onOpenChange(!0))},onPointerMove:$t(e.onPointerMove,Wb(A=>{p.onItemEnter(A),!A.defaultPrevented&&!e.disabled&&!s.open&&!m.current&&(p.onPointerGraceIntentChange(null),m.current=window.setTimeout(()=>{s.onOpenChange(!0),j()},100))})),onPointerLeave:$t(e.onPointerLeave,Wb(A=>{j();const k=s.content?.getBoundingClientRect();if(k){const T=s.content?.dataset.side,M=T==="right",I=M?-5:5,q=k[M?"left":"right"],G=k[M?"right":"left"];p.onPointerGraceIntentChange({area:[{x:A.clientX+I,y:A.clientY},{x:q,y:k.top},{x:G,y:k.top},{x:G,y:k.bottom},{x:q,y:k.bottom}],side:T}),window.clearTimeout(g.current),g.current=window.setTimeout(()=>p.onPointerGraceIntentChange(null),300)}else{if(p.onTriggerLeave(A),A.defaultPrevented)return;p.onPointerGraceIntentChange(null)}})),onKeyDown:$t(e.onKeyDown,A=>{const k=p.searchRef.current!=="";e.disabled||k&&A.key===" "||axe[o.dir].includes(A.key)&&(s.onOpenChange(!0),s.content?.focus(),A.preventDefault())})})})});Uq.displayName=Ab;var Kq="MenuSubContent",Vq=R.forwardRef((e,r)=>{const s=kq(io,e.__scopeMenu),{forceMount:o=s.forceMount,...d}=e,p=Ip(io,e.__scopeMenu),m=yw(io,e.__scopeMenu),g=Bq(Kq,e.__scopeMenu),b=R.useRef(null),S=zn(r,b);return u.jsx(Zb.Provider,{scope:e.__scopeMenu,children:u.jsx(lo,{present:o||p.open,children:u.jsx(Zb.Slot,{scope:e.__scopeMenu,children:u.jsx(u$,{id:g.contentId,"aria-labelledby":g.triggerId,...d,ref:S,align:"start",side:m.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:j=>{m.isUsingKeyboardRef.current&&b.current?.focus(),j.preventDefault()},onCloseAutoFocus:j=>j.preventDefault(),onFocusOutside:$t(e.onFocusOutside,j=>{j.target!==g.trigger&&p.onOpenChange(!1)}),onEscapeKeyDown:$t(e.onEscapeKeyDown,j=>{m.onClose(),j.preventDefault()}),onKeyDown:$t(e.onKeyDown,j=>{const A=j.currentTarget.contains(j.target),k=oxe[m.dir].includes(j.key);A&&k&&(p.onOpenChange(!1),g.trigger?.focus(),j.preventDefault())})})})})})});Vq.displayName=Kq;function Hq(e){return e?"open":"closed"}function hC(e){return e==="indeterminate"}function p$(e){return hC(e)?"indeterminate":e?"checked":"unchecked"}function Oxe(e){const r=document.activeElement;for(const s of e)if(s===r||(s.focus(),document.activeElement!==r))return}function kxe(e,r){return e.map((s,o)=>e[(r+o)%e.length])}function Rxe(e,r,s){const d=r.length>1&&Array.from(r).every(S=>S===r[0])?r[0]:r,p=s?e.indexOf(s):-1;let m=kxe(e,Math.max(p,0));d.length===1&&(m=m.filter(S=>S!==s));const b=m.find(S=>S.toLowerCase().startsWith(d.toLowerCase()));return b!==s?b:void 0}function Txe(e,r){const{x:s,y:o}=e;let d=!1;for(let p=0,m=r.length-1;po!=k>o&&s<(A-S)*(o-j)/(k-j)+S&&(d=!d)}return d}function _xe(e,r){if(!r)return!1;const s={x:e.clientX,y:e.clientY};return Txe(s,r)}function Wb(e){return r=>r.pointerType==="mouse"?e(r):void 0}var $xe=Oq,Nxe=o$,Dxe=Rq,Pxe=Tq,Mxe=d$,Ixe=_q,Lxe=WC,zxe=Nq,Fxe=Pq,qxe=Iq,Bxe=zq,Uxe=Fq,Kxe=qq,Vxe=Uq,Hxe=Vq,JC="DropdownMenu",[Gxe]=al(JC,[Cq]),Ki=Cq(),[Xxe,Gq]=Gxe(JC),Xq=e=>{const{__scopeDropdownMenu:r,children:s,dir:o,open:d,defaultOpen:p,onOpenChange:m,modal:g=!0}=e,b=Ki(r),S=R.useRef(null),[j,A]=qd({prop:d,defaultProp:p??!1,onChange:m,caller:JC});return u.jsx(Xxe,{scope:r,triggerId:Vs(),triggerRef:S,contentId:Vs(),open:j,onOpenChange:A,onOpenToggle:R.useCallback(()=>A(k=>!k),[A]),modal:g,children:u.jsx($xe,{...b,open:j,onOpenChange:A,dir:o,modal:g,children:s})})};Xq.displayName=JC;var Yq="DropdownMenuTrigger",Zq=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,disabled:o=!1,...d}=e,p=Gq(Yq,s),m=Ki(s);return u.jsx(Nxe,{asChild:!0,...m,children:u.jsx(Cn.button,{type:"button",id:p.triggerId,"aria-haspopup":"menu","aria-expanded":p.open,"aria-controls":p.open?p.contentId:void 0,"data-state":p.open?"open":"closed","data-disabled":o?"":void 0,disabled:o,...d,ref:Li(r,p.triggerRef),onPointerDown:$t(e.onPointerDown,g=>{!o&&g.button===0&&g.ctrlKey===!1&&(p.onOpenToggle(),p.open||g.preventDefault())}),onKeyDown:$t(e.onKeyDown,g=>{o||(["Enter"," "].includes(g.key)&&p.onOpenToggle(),g.key==="ArrowDown"&&p.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(g.key)&&g.preventDefault())})})})});Zq.displayName=Yq;var Yxe="DropdownMenuPortal",Wq=e=>{const{__scopeDropdownMenu:r,...s}=e,o=Ki(r);return u.jsx(Dxe,{...o,...s})};Wq.displayName=Yxe;var Jq="DropdownMenuContent",Qq=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Gq(Jq,s),p=Ki(s),m=R.useRef(!1);return u.jsx(Pxe,{id:d.contentId,"aria-labelledby":d.triggerId,...p,...o,ref:r,onCloseAutoFocus:$t(e.onCloseAutoFocus,g=>{m.current||d.triggerRef.current?.focus(),m.current=!1,g.preventDefault()}),onInteractOutside:$t(e.onInteractOutside,g=>{const b=g.detail.originalEvent,S=b.button===0&&b.ctrlKey===!0,j=b.button===2||S;(!d.modal||j)&&(m.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Qq.displayName=Jq;var Zxe="DropdownMenuGroup",Wxe=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(Mxe,{...d,...o,ref:r})});Wxe.displayName=Zxe;var Jxe="DropdownMenuLabel",Qxe=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(Ixe,{...d,...o,ref:r})});Qxe.displayName=Jxe;var ebe="DropdownMenuItem",eB=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(Lxe,{...d,...o,ref:r})});eB.displayName=ebe;var tbe="DropdownMenuCheckboxItem",nbe=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(zxe,{...d,...o,ref:r})});nbe.displayName=tbe;var rbe="DropdownMenuRadioGroup",sbe=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(Fxe,{...d,...o,ref:r})});sbe.displayName=rbe;var ibe="DropdownMenuRadioItem",abe=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(qxe,{...d,...o,ref:r})});abe.displayName=ibe;var obe="DropdownMenuItemIndicator",lbe=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(Bxe,{...d,...o,ref:r})});lbe.displayName=obe;var cbe="DropdownMenuSeparator",ube=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(Uxe,{...d,...o,ref:r})});ube.displayName=cbe;var dbe="DropdownMenuArrow",hbe=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(Kxe,{...d,...o,ref:r})});hbe.displayName=dbe;var pbe="DropdownMenuSubTrigger",fbe=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(Vxe,{...d,...o,ref:r})});fbe.displayName=pbe;var mbe="DropdownMenuSubContent",gbe=R.forwardRef((e,r)=>{const{__scopeDropdownMenu:s,...o}=e,d=Ki(s);return u.jsx(Hxe,{...d,...o,ref:r,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});gbe.displayName=mbe;var ybe=Xq,vbe=Zq,xbe=Wq,bbe=Qq,wbe=eB;function f$({...e}){return u.jsx(ybe,{"data-slot":"dropdown-menu",...e})}function m$({...e}){return u.jsx(vbe,{"data-slot":"dropdown-menu-trigger",...e})}function g$({className:e,sideOffset:r=4,...s}){return u.jsx(xbe,{children:u.jsx(bbe,{"data-slot":"dropdown-menu-content",sideOffset:r,className:ft("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md",e),...s})})}function jp({className:e,inset:r,variant:s="default",...o}){return u.jsx(wbe,{"data-slot":"dropdown-menu-item","data-inset":r,"data-variant":s,className:ft("focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...o})}var QC="Switch",[Sbe]=al(QC),[Ebe,jbe]=Sbe(QC),tB=R.forwardRef((e,r)=>{const{__scopeSwitch:s,name:o,checked:d,defaultChecked:p,required:m,disabled:g,value:b="on",onCheckedChange:S,form:j,...A}=e,[k,T]=R.useState(null),M=zn(r,X=>T(X)),I=R.useRef(!1),q=k?j||!!k.closest("form"):!0,[G,K]=qd({prop:d,defaultProp:p??!1,onChange:S,caller:QC});return u.jsxs(Ebe,{scope:s,checked:G,disabled:g,children:[u.jsx(Cn.button,{type:"button",role:"switch","aria-checked":G,"aria-required":m,"data-state":iB(G),"data-disabled":g?"":void 0,disabled:g,value:b,...A,ref:M,onClick:$t(e.onClick,X=>{K(L=>!L),q&&(I.current=X.isPropagationStopped(),I.current||X.stopPropagation())})}),q&&u.jsx(sB,{control:k,bubbles:!I.current,name:o,value:b,checked:G,required:m,disabled:g,form:j,style:{transform:"translateX(-100%)"}})]})});tB.displayName=QC;var nB="SwitchThumb",rB=R.forwardRef((e,r)=>{const{__scopeSwitch:s,...o}=e,d=jbe(nB,s);return u.jsx(Cn.span,{"data-state":iB(d.checked),"data-disabled":d.disabled?"":void 0,...o,ref:r})});rB.displayName=nB;var Cbe="SwitchBubbleInput",sB=R.forwardRef(({__scopeSwitch:e,control:r,checked:s,bubbles:o=!0,...d},p)=>{const m=R.useRef(null),g=zn(m,p),b=_6(s),S=VL(r);return R.useEffect(()=>{const j=m.current;if(!j)return;const A=window.HTMLInputElement.prototype,T=Object.getOwnPropertyDescriptor(A,"checked").set;if(b!==s&&T){const M=new Event("click",{bubbles:o});T.call(j,s),j.dispatchEvent(M)}},[b,s,o]),u.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:s,...d,tabIndex:-1,ref:g,style:{...d.style,...S,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});sB.displayName=Cbe;function iB(e){return e?"checked":"unchecked"}var Abe=tB,Obe=rB;function R3({className:e,...r}){return u.jsx(Abe,{"data-slot":"switch",className:ft("peer data-[state=checked]:bg-primary data-[state=unchecked]:bg-input focus-visible:border-ring focus-visible:ring-ring/50 dark:data-[state=unchecked]:bg-input/80 inline-flex h-[1.15rem] w-8 shrink-0 items-center rounded-full border border-transparent shadow-xs transition-all outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",e),...r,children:u.jsx(Obe,{"data-slot":"switch-thumb",className:ft("bg-background dark:data-[state=unchecked]:bg-foreground dark:data-[state=checked]:bg-primary-foreground pointer-events-none block size-4 rounded-full ring-0 transition-transform data-[state=checked]:translate-x-[calc(100%-2px)] data-[state=unchecked]:translate-x-0")})})}const pC=["route53","s3","ec2","iam","rds","dynamodb"],Sj=Xs({credential_provider:Da(["aws","cloudflare","hetzner","digitalocean","generic"]),kind:Da(["aws_access_key","api_token","basic_auth","oauth2"]),schema_version:Xb().default(1),name:Nn().min(1,"Name is required").max(100),scope_kind:Da(["provider","service","resource"]),scope_version:Xb().default(1),scope:w3(),account_id:Nn().optional().or(Yb("")).transform(e=>e||void 0),region:Nn().optional().or(Yb("")).transform(e=>e||void 0),secret:w3()}).superRefine((e,r)=>{if(e.credential_provider==="aws"){if(e.scope_kind==="service"){const s=e.scope?.service;pC.includes(s)||r.addIssue({code:Dd.custom,path:["scope"],message:`For AWS service scope, "service" must be one of: ${pC.join(", ")}`})}if(e.scope_kind==="resource"){const s=e.scope?.arn;(typeof s!="string"||!s.startsWith("arn:"))&&r.addIssue({code:Dd.custom,path:["scope"],message:'For AWS resource scope, "arn" must start with "arn:"'})}if(e.kind==="aws_access_key"){const s=e.secret??{},o=s.access_key_id;(typeof o!="string"||!/^[A-Z0-9]{20}$/.test(o))&&r.addIssue({code:Dd.custom,path:["secret"],message:"access_key_id must be 20 chars (A-Z0-9)"}),(typeof s.secret_access_key!="string"||s.secret_access_key.length<10)&&r.addIssue({code:Dd.custom,path:["secret"],message:"secret_access_key is required"})}}if(e.kind==="api_token"&&((e.secret??{}).token||r.addIssue({code:Dd.custom,path:["secret"],message:"token is required"})),e.kind==="basic_auth"){const s=e.secret??{};(!s.username||!s.password)&&r.addIssue({code:Dd.custom,path:["secret"],message:"username and password are required"})}if(e.kind==="oauth2"){const s=e.secret??{};(!s.client_id||!s.client_secret||!s.refresh_token)&&r.addIssue({code:Dd.custom,path:["secret"],message:"client_id, client_secret, and refresh_token are required"})}e.scope_kind!=="provider"&&!e.scope&&r.addIssue({code:Dd.custom,path:["scope"],message:"scope is required"})}),gT=Sj.partial().extend({name:Nn().min(1,"Name is required").max(100).optional()});function Ql(e){try{return JSON.stringify(JSON.parse(e),null,2)}catch{return""}}function cj(e){const r=e?.body??e?.response??e?.message;if(typeof r=="string")return r;try{const s=e?.response?.data?.message||e?.message;if(s)return String(s)}catch{return"Unknown error"}return"Unknown error"}function kbe({credential_provider:e,scope_kind:r}){return e==="aws"&&r==="service"}function Rbe({credential_provider:e,scope_kind:r}){return e==="aws"&&r==="resource"}function Tbe({scope_kind:e}){return e==="provider"}function T3(){return{credential_provider:"aws",kind:"aws_access_key",schema_version:1,name:"",scope_kind:"provider",scope_version:1,scope:{},account_id:"",region:"",secret:{}}}function _3(e){return{credential_provider:e.credential_provider,kind:e.kind,schema_version:e.schema_version??1,name:e.name,scope_kind:e.scope_kind,scope_version:e.scope_version??1,scope:e.scope??{},account_id:e.account_id,region:e.region,secret:e.secret??{}}}function $3(e){const r={},s=["name","account_id","region","scope_kind","scope_version","scope","secret","credential_provider","kind","schema_version"];for(const o of s)typeof e[o]<"u"&&e[o]!==""&&(r[o]=e[o]);return r}const _be=()=>{const[e,r]=R.useState(""),[s,o]=R.useState(!1),[d,p]=R.useState(!1),[m,g]=R.useState(!1),[b,S]=R.useState(null),[j,A]=R.useState(null),[k,T]=R.useState(!1),[M,I]=R.useState(!1),[q,G]=R.useState(!1),[K,X]=R.useState(null),[L,ee]=R.useState(!1),[oe,Q]=R.useState(null),ne=Hs(),de=rr({queryKey:["credentials"],queryFn:()=>Qm.listCredentials()}),je=nn({mutationFn:ie=>Qm.createCredential(_3(ie)),onSuccess:async()=>{await ne.invalidateQueries({queryKey:["credentials"]}),Ze.success("Credential created"),o(!1),Ce.reset(T3()),T(!1)},onError:ie=>{Ze.error("Failed to create credential",{description:cj(ie)})}}),ve=nn({mutationFn:ie=>Qm.updateCredential(ie.id,$3(ie.body)),onSuccess:async()=>{await ne.invalidateQueries({queryKey:["credentials"]}),Ze.success("Credential updated"),p(!1),A(null),I(!1)},onError:ie=>{Ze.error("Failed to update credential",{description:cj(ie)})}}),le=nn({mutationFn:ie=>Qm.deleteCredential(ie),onSuccess:async()=>{await ne.invalidateQueries({queryKey:["credentials"]}),Ze.success("Credential deleted")},onError:ie=>{Ze.error("Failed to delete credential",{description:cj(ie)})}}),be=nn({mutationFn:ie=>Qm.revealCredential(ie),onSuccess:ie=>{S(ie),g(!0)},onError:ie=>{Ze.error("Failed to reveal secret",{description:cj(ie)})}}),Ce=mr({resolver:gr(Sj),defaultValues:T3(),mode:"onBlur"}),Ke=mr({resolver:gr(gT),defaultValues:{},mode:"onBlur"});function ce(ie){A(ie.id),Ke.reset({provider:ie.provider,kind:ie.kind,schema_version:ie.schema_version??1,name:ie.name,scope_kind:ie.scope_kind,scope_version:ie.scope_version??1,account_id:ie.account_id??"",region:ie.region??"",scope:ie.scope??(ie.scope_kind==="provider"?{}:void 0),secret:void 0}),I(!1),p(!0)}const re=R.useMemo(()=>{const ie=de.data??[];if(!e.trim())return ie;const De=e.toLowerCase();return ie.filter(Le=>[Le.name,Le.provider,Le.kind,Le.scope_kind,Le.account_id,Le.region,JSON.stringify(Le.scope??{})].filter(Boolean).map(tt=>String(tt).toLowerCase()).some(tt=>tt.includes(De)))},[de.data,e]);if(de.isLoading)return u.jsxs("div",{className:"flex items-center gap-2 p-6",children:[u.jsx(Ds,{className:"h-4 w-4 animate-spin"})," Loading credentials…"]});if(de.error)return u.jsxs("div",{className:"p-6 text-red-500",children:["Error loading credentials.",u.jsx("pre",{className:"mt-2 text-xs opacity-80",children:JSON.stringify(de.error,null,2)})]});const ue=Ce.watch("credential_provider"),_e=Ce.watch("kind"),fe=Ce.watch("scope_kind"),He=ie=>Ce.setValue("scope",ie,{shouldDirty:!0,shouldValidate:!0}),Oe=ie=>Ce.setValue("secret",ie,{shouldDirty:!0,shouldValidate:!0});function ke(){if(!k){if(ue==="aws"&&_e==="aws_access_key"){const ie=Ce.getValues("secret")??{};Oe({access_key_id:ie.access_key_id??"",secret_access_key:ie.secret_access_key??""})}else if(_e==="api_token"){const ie=Ce.getValues("secret")??{};Oe({token:ie.token??""})}else if(_e==="basic_auth"){const ie=Ce.getValues("secret")??{};Oe({username:ie.username??"",password:ie.password??""})}else if(_e==="oauth2"){const ie=Ce.getValues("secret")??{};Oe({client_id:ie.client_id??"",client_secret:ie.client_secret??"",refresh_token:ie.refresh_token??""})}}}function Ve(ie){Ce.setValue("scope_kind",ie),ie==="provider"&&He({}),ie==="service"&&He({service:"route53"}),ie==="resource"&&He({arn:""})}return u.jsxs("div",{className:"space-y-4 p-6",children:[u.jsxs("div",{className:"flex flex-col gap-3 md:flex-row md:items-center md:justify-between",children:[u.jsxs("div",{children:[u.jsx("h1",{className:"mb-1 text-2xl font-bold",children:"Credentials"}),u.jsx("p",{className:"text-muted-foreground text-sm",children:"Store provider credentials. Secrets are encrypted server-side; revealing is a one-time read."})]}),u.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[u.jsxs("div",{className:"relative",children:[u.jsx(Pa,{className:"absolute top-2.5 left-2 h-4 w-4 opacity-60"}),u.jsx(gt,{value:e,onChange:ie=>r(ie.target.value),placeholder:"Search by name, provider, kind, scope…",className:"w-64 pl-8"})]}),u.jsxs(fn,{open:s,onOpenChange:o,children:[u.jsx(zi,{asChild:!0,children:u.jsxs(Fe,{onClick:()=>o(!0),children:[u.jsx(oo,{className:"mr-2 h-4 w-4"}),"Create Credential"]})}),u.jsxs(mn,{className:"sm:max-w-2xl",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Create Credential"})}),u.jsx(yr,{...Ce,children:u.jsxs("form",{onSubmit:Ce.handleSubmit(ie=>{const De=Sj.safeParse(ie);if(!De.success){Ze.error("Please fix validation errors");return}je.mutate(De.data)}),className:"space-y-5 pt-2",children:[u.jsxs("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[u.jsx(pt,{control:Ce.control,name:"credential_provider",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Provider"}),u.jsxs(Rn,{onValueChange:De=>{ie.onChange(De),ke()},defaultValue:ie.value,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{})})}),u.jsxs($n,{children:[u.jsx(jt,{value:"aws",children:"AWS"}),u.jsx(jt,{value:"cloudflare",children:"Cloudflare"}),u.jsx(jt,{value:"hetzner",children:"Hetzner"}),u.jsx(jt,{value:"digitalocean",children:"DigitalOcean"}),u.jsx(jt,{value:"generic",children:"Generic"})]})]}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ce.control,name:"kind",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Kind"}),u.jsxs(Rn,{onValueChange:De=>{ie.onChange(De),ke()},defaultValue:ie.value,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{})})}),u.jsxs($n,{children:[u.jsx(jt,{value:"aws_access_key",children:"AWS Access Key"}),u.jsx(jt,{value:"api_token",children:"API Token"}),u.jsx(jt,{value:"basic_auth",children:"Basic Auth"}),u.jsx(jt,{value:"oauth2",children:"OAuth2"})]})]}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ce.control,name:"scope_kind",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Scope Kind"}),u.jsxs(Rn,{onValueChange:De=>{Ve(De)},defaultValue:ie.value,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{})})}),u.jsxs($n,{children:[u.jsx(jt,{value:"provider",children:"Provider"}),u.jsx(jt,{value:"service",children:"Service"}),u.jsx(jt,{value:"resource",children:"Resource"})]})]}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ce.control,name:"name",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Name"}),u.jsx(gt,{...ie,placeholder:"My AWS Key"}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ce.control,name:"account_id",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Account ID (optional)"}),u.jsx(gt,{...ie,placeholder:"e.g. 123456789012"}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ce.control,name:"region",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Region (optional)"}),u.jsx(gt,{...ie,placeholder:"e.g. us-east-1"}),u.jsx(dt,{})]})})]}),!Tbe({scope_kind:fe})&&u.jsx(u.Fragment,{children:kbe({credential_provider:ue,scope_kind:fe})?u.jsxs(ot,{children:[u.jsx(lt,{children:"Service"}),u.jsx(Go,{control:Ce.control,name:"scope",render:({field:ie})=>u.jsxs(Rn,{onValueChange:De=>ie.onChange({service:De}),value:ie.value?.service??"route53",children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{placeholder:"Select an AWS service"})})}),u.jsx($n,{children:pC.map(De=>u.jsx(jt,{value:De,children:De.toUpperCase()},De))})]})}),u.jsxs("p",{className:"text-muted-foreground mt-1 text-xs",children:["Must be one of: ",pC.join(", "),"."]})]}):Rbe({credential_provider:ue,scope_kind:fe})?u.jsxs(ot,{children:[u.jsx(lt,{children:"Resource ARN"}),u.jsx(Go,{control:Ce.control,name:"scope",render:({field:ie})=>u.jsx(gt,{value:ie.value?.arn??"",onChange:De=>ie.onChange({arn:De.target.value}),placeholder:"arn:aws:service:region:account:resource"})}),u.jsx(dt,{})]}):u.jsx(pt,{control:Ce.control,name:"scope",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Scope (JSON)"}),u.jsx(hu,{value:Ql(ie.value??{}),onChange:De=>{try{const Le=JSON.parse(De.target.value);ie.onChange(Le)}catch{ie.onChange(De.target.value)}},rows:3,placeholder:'{"service":"route53"} or {"arn":"arn:aws:..."}',className:"font-mono"}),u.jsx(dt,{})]})})}),u.jsxs("div",{className:"flex items-center gap-2",children:[u.jsx(R3,{checked:k,onCheckedChange:ie=>{T(ie),ke()},id:"raw-secret-toggle"}),u.jsx("label",{htmlFor:"raw-secret-toggle",className:"text-sm",children:"Edit secret as raw JSON"})]}),k?u.jsx(pt,{control:Ce.control,name:"secret",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Secret (JSON)"}),u.jsx(hu,{value:Ql(ie.value??{}),onChange:De=>{try{ie.onChange(JSON.parse(De.target.value))}catch{ie.onChange(De.target.value)}},rows:6,placeholder:_e==="aws_access_key"?'{"access_key_id":"...","secret_access_key":"..."}':_e==="api_token"?'{"token":"..."}':_e==="basic_auth"?'{"username":"...","password":"..."}':'{"client_id":"...","client_secret":"...","refresh_token":"..."}',className:"font-mono"}),u.jsx(dt,{})]})}):u.jsxs(u.Fragment,{children:[ue==="aws"&&_e==="aws_access_key"&&u.jsxs("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[u.jsxs(ot,{children:[u.jsx(lt,{children:"Access Key ID"}),u.jsx(Go,{control:Ce.control,name:"secret",render:({field:ie})=>u.jsx(gt,{value:(ie.value??{}).access_key_id??"",onChange:De=>Oe({...ie.value??{},access_key_id:De.target.value.trim()}),placeholder:"AKIA..."})})]}),u.jsxs(ot,{children:[u.jsx(lt,{children:"Secret Access Key"}),u.jsx(Go,{control:Ce.control,name:"secret",render:({field:ie})=>u.jsx(gt,{type:"password",value:(ie.value??{}).secret_access_key??"",onChange:De=>Oe({...ie.value??{},secret_access_key:De.target.value}),placeholder:"•••••••••••••••"})})]})]}),_e==="api_token"&&u.jsxs(ot,{children:[u.jsx(lt,{children:"API Token"}),u.jsx(Go,{control:Ce.control,name:"secret",render:({field:ie})=>u.jsx(gt,{value:(ie.value??{}).token??"",onChange:De=>Oe({...ie.value??{},token:De.target.value}),placeholder:"token..."})})]}),_e==="basic_auth"&&u.jsxs("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[u.jsxs(ot,{children:[u.jsx(lt,{children:"Username"}),u.jsx(Go,{control:Ce.control,name:"secret",render:({field:ie})=>u.jsx(gt,{value:(ie.value??{}).username??"",onChange:De=>Oe({...ie.value??{},username:De.target.value})})})]}),u.jsxs(ot,{children:[u.jsx(lt,{children:"Password"}),u.jsx(Go,{control:Ce.control,name:"secret",render:({field:ie})=>u.jsx(gt,{type:"password",value:(ie.value??{}).password??"",onChange:De=>Oe({...ie.value??{},password:De.target.value})})})]})]}),_e==="oauth2"&&u.jsxs("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-3",children:[u.jsxs(ot,{children:[u.jsx(lt,{children:"Client ID"}),u.jsx(Go,{control:Ce.control,name:"secret",render:({field:ie})=>u.jsx(gt,{value:(ie.value??{}).client_id??"",onChange:De=>Oe({...ie.value??{},client_id:De.target.value})})})]}),u.jsxs(ot,{children:[u.jsx(lt,{children:"Client Secret"}),u.jsx(Go,{control:Ce.control,name:"secret",render:({field:ie})=>u.jsx(gt,{type:"password",value:(ie.value??{}).client_secret??"",onChange:De=>Oe({...ie.value??{},client_secret:De.target.value})})})]}),u.jsxs(ot,{children:[u.jsx(lt,{children:"Refresh Token"}),u.jsx(Go,{control:Ce.control,name:"secret",render:({field:ie})=>u.jsx(gt,{value:(ie.value??{}).refresh_token??"",onChange:De=>Oe({...ie.value??{},refresh_token:De.target.value})})})]})]})]}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{type:"button",variant:"secondary",onClick:()=>{const ie=Sj.safeParse(Ce.getValues());if(!ie.success){Ze.error("Fix validation errors before previewing");return}const De=_3(ie.data);X(De),G(!0)},children:"Preview request"}),u.jsx(Fe,{variant:"outline",type:"button",onClick:()=>o(!1),children:"Cancel"}),u.jsxs(Fe,{type:"submit",disabled:je.isPending,children:[je.isPending&&u.jsx(Ds,{className:"mr-2 h-4 w-4 animate-spin"}),"Create"]})]})]})})]})]})]})]}),u.jsx("div",{className:"overflow-x-auto rounded-xl border",children:u.jsxs("table",{className:"min-w-full text-sm",children:[u.jsx("thead",{className:"bg-muted/40 text-xs tracking-wide uppercase",children:u.jsxs("tr",{children:[u.jsx("th",{className:"w-[26%] px-4 py-2 text-left",children:"Name"}),u.jsx("th",{className:"px-4 py-2 text-left",children:"Provider"}),u.jsx("th",{className:"px-4 py-2 text-left",children:"Kind"}),u.jsx("th",{className:"px-4 py-2 text-left",children:"Scope"}),u.jsx("th",{className:"px-4 py-2 text-left",children:"Account"}),u.jsx("th",{className:"px-4 py-2 text-left",children:"Region"}),u.jsx("th",{className:"px-4 py-2 text-right",children:"Actions"})]})}),u.jsxs("tbody",{children:[re.map(ie=>u.jsxs("tr",{className:"border-t",children:[u.jsxs("td",{className:"px-4 py-2",children:[u.jsx("div",{className:"font-medium",children:ie.name}),u.jsxs("div",{className:"text-muted-foreground text-xs",children:[u.jsx("span",{className:"mr-1",children:"id:"}),u.jsxs("code",{className:"bg-muted rounded px-1",children:[ie.id.slice(0,8),"…"]})]})]}),u.jsx("td",{className:"px-4 py-2",children:ie.credential_provider}),u.jsx("td",{className:"px-4 py-2",children:ie.kind}),u.jsx("td",{className:"px-4 py-2",children:u.jsx(ns,{variant:"secondary",children:ie.scope_kind})}),u.jsx("td",{className:"px-4 py-2",children:ie.account_id??"—"}),u.jsx("td",{className:"px-4 py-2",children:ie.region??"—"}),u.jsx("td",{className:"px-4 py-2",children:u.jsxs("div",{className:"flex items-center justify-end gap-2",children:[u.jsx(Fe,{size:"icon",variant:"ghost",title:"Reveal secret (one-time read)",onClick:()=>be.mutate(ie.id),children:u.jsx(kT,{className:"h-4 w-4"})}),u.jsx(Fe,{size:"icon",variant:"ghost",title:"Edit",onClick:()=>ce(ie),children:u.jsx(pu,{className:"h-4 w-4"})}),u.jsxs(nC,{children:[u.jsx(rC,{asChild:!0,children:u.jsx(Fe,{size:"icon",variant:"ghost",title:"Delete",children:u.jsx(Ib,{className:"h-4 w-4"})})}),u.jsxs(sC,{children:[u.jsxs(iC,{children:[u.jsxs(oC,{children:["Delete “",ie.name,"”?"]}),u.jsx(lC,{children:"This will permanently remove the credential metadata. Secrets are not recoverable."})]}),u.jsxs(aC,{children:[u.jsx(uC,{disabled:le.isPending,children:"Cancel"}),u.jsxs(cC,{className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",onClick:()=>le.mutate(ie.id),disabled:le.isPending,children:[le.isPending&&u.jsx(Ds,{className:"mr-2 inline h-4 w-4 animate-spin"}),"Delete"]})]})]})]}),u.jsxs(f$,{children:[u.jsx(m$,{asChild:!0,children:u.jsx(Fe,{size:"icon",variant:"ghost",children:u.jsx(z_,{className:"h-4 w-4"})})}),u.jsxs(g$,{align:"end",children:[u.jsx(jp,{onClick:()=>ce(ie),children:"Edit"}),u.jsx(jp,{onClick:()=>be.mutate(ie.id),children:"Reveal secret"}),u.jsx(jp,{className:"text-destructive",onClick:()=>le.mutate(ie.id),children:"Delete"})]})]})]})})]},ie.id)),re.length===0&&u.jsx("tr",{children:u.jsx("td",{colSpan:7,className:"px-4 py-12 text-center",children:u.jsxs("div",{className:"mx-auto max-w-md",children:[u.jsx("div",{className:"mb-2 flex items-center justify-center",children:u.jsx(kj,{className:"text-muted-foreground h-5 w-5"})}),u.jsx("p",{className:"text-muted-foreground",children:"No credentials match your search."})]})})})]})]})}),u.jsx(fn,{open:d,onOpenChange:p,children:u.jsxs(mn,{className:"sm:max-w-2xl",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Edit Credential"})}),u.jsx(yr,{...Ke,children:u.jsxs("form",{onSubmit:Ke.handleSubmit(ie=>{if(!j)return;const De=gT.safeParse(ie);if(!De.success){Ze.error("Please fix validation errors");return}ve.mutate({id:j,body:De.data})}),className:"space-y-5 pt-2",children:[u.jsxs("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[u.jsx(pt,{control:Ke.control,name:"credential_provider",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Provider"}),u.jsxs(Rn,{onValueChange:ie.onChange,value:ie.value,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{})})}),u.jsxs($n,{children:[u.jsx(jt,{value:"aws",children:"AWS"}),u.jsx(jt,{value:"cloudflare",children:"Cloudflare"}),u.jsx(jt,{value:"hetzner",children:"Hetzner"}),u.jsx(jt,{value:"digitalocean",children:"DigitalOcean"}),u.jsx(jt,{value:"generic",children:"Generic"})]})]}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ke.control,name:"kind",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Kind"}),u.jsxs(Rn,{onValueChange:ie.onChange,value:ie.value,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{})})}),u.jsxs($n,{children:[u.jsx(jt,{value:"aws_access_key",children:"AWS Access Key"}),u.jsx(jt,{value:"api_token",children:"API Token"}),u.jsx(jt,{value:"basic_auth",children:"Basic Auth"}),u.jsx(jt,{value:"oauth2",children:"OAuth2"})]})]}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ke.control,name:"scope_kind",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Scope Kind"}),u.jsxs(Rn,{onValueChange:ie.onChange,value:ie.value,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{})})}),u.jsxs($n,{children:[u.jsx(jt,{value:"provider",children:"Provider"}),u.jsx(jt,{value:"service",children:"Service"}),u.jsx(jt,{value:"resource",children:"Resource"})]})]}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ke.control,name:"name",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Name"}),u.jsx(gt,{...ie}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ke.control,name:"account_id",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Account ID"}),u.jsx(gt,{...ie,placeholder:"optional"}),u.jsx(dt,{})]})}),u.jsx(pt,{control:Ke.control,name:"region",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Region"}),u.jsx(gt,{...ie,placeholder:"optional"}),u.jsx(dt,{})]})})]}),u.jsx(pt,{control:Ke.control,name:"scope",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Scope (JSON)"}),u.jsx(hu,{value:Ql(ie.value??(Ke.getValues("scope_kind")==="provider"?{}:void 0)),onChange:De=>{try{ie.onChange(JSON.parse(De.target.value))}catch{ie.onChange(De.target.value)}},rows:3,className:"font-mono"}),u.jsx(dt,{})]})}),u.jsxs("div",{className:"flex items-center gap-2",children:[u.jsx(R3,{checked:M,onCheckedChange:I,id:"raw-edit-secret-toggle"}),u.jsx("label",{htmlFor:"raw-edit-secret-toggle",className:"text-sm",children:"Rotate secret with raw JSON (leave empty to keep existing)"})]}),M&&u.jsx(pt,{control:Ke.control,name:"secret",render:({field:ie})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Rotate Secret (JSON)"}),u.jsx(hu,{value:typeof ie.value=="string"?ie.value:Ql(ie.value??{}),onChange:De=>{try{ie.onChange(JSON.parse(De.target.value))}catch{ie.onChange(De.target.value)}},rows:6,className:"font-mono",placeholder:'{"access_key_id":"...","secret_access_key":"..."}'}),u.jsx(dt,{})]})}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{type:"button",variant:"secondary",onClick:()=>{const ie=gT.safeParse(Ke.getValues());if(!ie.success){Ze.error("Fix validation errors before previewing");return}const De=$3(ie.data);Q(De),ee(!0)},children:"Preview request"}),u.jsx(Fe,{variant:"outline",type:"button",onClick:()=>p(!1),children:"Cancel"}),u.jsxs(Fe,{type:"submit",disabled:ve.isPending,children:[ve.isPending&&u.jsx(Ds,{className:"mr-2 h-4 w-4 animate-spin"}),"Save changes"]})]})]})})]})}),u.jsx(fn,{open:m,onOpenChange:g,children:u.jsxs(mn,{className:"sm:max-w-xl",children:[u.jsx(gn,{children:u.jsxs(yn,{className:"flex items-center gap-2",children:[u.jsx(kT,{className:"h-4 w-4"})," Decrypted Secret"]})}),u.jsx("div",{className:"bg-muted/40 rounded-lg border p-3",children:u.jsx("pre",{className:"max-h-[50vh] overflow-auto text-xs leading-relaxed",children:Ql(b??{})})}),u.jsxs("div",{className:"text-muted-foreground flex items-center gap-2 text-xs",children:[u.jsx(kj,{className:"h-3.5 w-3.5"}),"One-time read. Close this dialog to hide the secret."]}),u.jsxs(Sn,{children:[u.jsx(Fe,{variant:"outline",onClick:()=>{navigator.clipboard.writeText(Ql(b??{})),Ze.success("Copied to clipboard")},children:"Copy"}),u.jsx(Fe,{onClick:()=>g(!1),children:"Close"})]})]})}),u.jsx(fn,{open:q,onOpenChange:G,children:u.jsxs(mn,{className:"sm:max-w-2xl",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Preview: POST /api/v1/credentials"})}),u.jsx("div",{className:"bg-muted/40 rounded-lg border p-3",children:u.jsx("pre",{className:"max-h-[50vh] overflow-auto text-xs leading-relaxed",children:Ql(K??{})})}),u.jsxs(Sn,{children:[u.jsx(Fe,{variant:"outline",onClick:()=>{navigator.clipboard.writeText(Ql(K??{})),Ze.success("Copied body")},children:"Copy body"}),u.jsx(Fe,{onClick:()=>G(!1),children:"Close"})]})]})}),u.jsx(fn,{open:L,onOpenChange:ee,children:u.jsxs(mn,{className:"sm:max-w-2xl",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Preview: PATCH /api/v1/credentials/:id"})}),u.jsx("div",{className:"bg-muted/40 rounded-lg border p-3",children:u.jsx("pre",{className:"max-h-[50vh] overflow-auto text-xs leading-relaxed",children:Ql(oe??{})})}),u.jsxs(Sn,{children:[u.jsx(Fe,{variant:"outline",onClick:()=>{navigator.clipboard.writeText(Ql(oe??{})),Ze.success("Copied body")},children:"Copy body"}),u.jsx(Fe,{onClick:()=>ee(!1),children:"Close"})]})]})})]})};function ha({className:e,...r}){return u.jsx("div",{"data-slot":"card",className:ft("bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",e),...r})}function sl({className:e,...r}){return u.jsx("div",{"data-slot":"card-header",className:ft("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",e),...r})}function il({className:e,...r}){return u.jsx("div",{"data-slot":"card-title",className:ft("leading-none font-semibold",e),...r})}function C_({className:e,...r}){return u.jsx("div",{"data-slot":"card-description",className:ft("text-muted-foreground text-sm",e),...r})}function ao({className:e,...r}){return u.jsx("div",{"data-slot":"card-content",className:ft("px-6",e),...r})}const $be=e=>{switch(e){case"ready":return u.jsx(L_,{className:"h-4 w-4 text-emerald-600"});case"provisioning":return u.jsx(Ds,{className:"h-4 w-4 animate-spin text-blue-600"});case"failed":return u.jsx(kj,{className:"h-4 w-4 text-red-600"});default:return u.jsx(_Z,{className:"text-muted-foreground h-4 w-4"})}},yT=({s:e})=>u.jsxs(ns,{variant:e==="failed"?"destructive":e==="ready"?"default":"secondary",className:"gap-1",title:e,children:[$be(e),u.jsx("span",{className:"capitalize",children:e??"pending"})]}),A_=e=>e.split(",").map(r=>r.trim()).filter(Boolean),Nbe=e=>e&&e.length?e.join(","):"",O_=["A","AAAA","CNAME","TXT","MX","NS","SRV","CAA"],Dbe=e=>e.credential_provider==="aws"&&e.scope_kind==="service"&&(()=>{const r=e.scope;try{return(typeof r=="string"?JSON.parse(r):r||{})?.service==="route53"}catch{return!1}})(),N3=e=>[e.name||"Unnamed",e.account_id,e.region].filter(Boolean).join(" · "),aB=Xs({domain_name:Nn().min(1,"Domain is required").max(253).transform(e=>e.trim().replace(/\.$/,"").toLowerCase()),credential_id:Nn().uuid("Pick a credential"),zone_id:Nn().optional().or(Yb("")).transform(e=>e?e.trim():void 0)}),Pbe=aB.partial(),Mbe=j6([Xb(),Nn().regex(/^\d+$/).transform(e=>Number(e))]).optional().refine(e=>e===void 0||e>=1&&e<=86400,{message:"TTL must be between 1 and 86400"}),oB=Xs({name:Nn().min(1,"Name required").max(253).transform(e=>e.trim().replace(/\.$/,"").toLowerCase()),type:Da(O_),ttl:Mbe,valuesCsv:Nn().optional()}).superRefine((e,r)=>{const s=A_(e.valuesCsv??"");s.length===0&&r.addIssue({code:"custom",message:"At least one value is required"}),e.type==="CNAME"&&s.length!==1&&r.addIssue({code:"custom",message:"CNAME requires exactly one value"})}),Ibe=oB.partial(),Lbe=()=>{const[e,r]=R.useState(""),[s,o]=R.useState(null),[d,p]=R.useState(!1),[m,g]=R.useState(!1),[b,S]=R.useState(!1),[j,A]=R.useState(!1),[k,T]=R.useState(null),M=Hs(),I=rr({queryKey:["dns","domains"],queryFn:()=>tc.listDomains()}),q=rr({queryKey:["dns","records",s?.id],queryFn:async()=>s?await tc.listRecordSetsByDomain(s.id):[],enabled:!!s?.id}),G=rr({queryKey:["credentials","r53"],queryFn:()=>Qm.listCredentials()}),K=R.useMemo(()=>(G.data??[]).filter(Dbe),[G.data]);R.useEffect(()=>{(()=>{!s&&I.data&&I.data.length&&o(I.data[0])})()},[I.data,s]);const X=R.useMemo(()=>{const re=I.data??[];if(!e.trim())return re;const ue=e.toLowerCase();return re.filter(_e=>[_e.domain_name,_e.zone_id,_e.status,_e.domain_name].filter(Boolean).map(fe=>String(fe).toLowerCase()).some(fe=>fe.includes(ue)))},[I.data,e]),L=mr({resolver:gr(aB),defaultValues:{domain_name:"",credential_id:"",zone_id:""}}),ee=nn({mutationFn:re=>tc.createDomain(re),onSuccess:async re=>{Ze.success("Domain created"),p(!1),L.reset(),await M.invalidateQueries({queryKey:["dns","domains"]}),o(re)},onError:re=>Ze.error("Failed to create domain",{description:re?.message??"Unknown error"})}),oe=mr({resolver:gr(Pbe)}),Q=re=>{o(re),oe.reset({domain_name:re.domain_name,credential_id:re.credential_id,zone_id:re.zone_id||""}),g(!0)},ne=nn({mutationFn:re=>{if(!s)throw new Error("No domain selected");return tc.updateDomain(s.id,re)},onSuccess:async()=>{Ze.success("Domain updated"),g(!1),await M.invalidateQueries({queryKey:["dns","domains"]}),await M.invalidateQueries({queryKey:["dns","records",s?.id]})},onError:re=>Ze.error("Failed to update domain",{description:re?.message??"Unknown error"})}),de=nn({mutationFn:re=>tc.deleteDomain(re),onSuccess:async()=>{Ze.success("Domain deleted"),await M.invalidateQueries({queryKey:["dns","domains"]}),o(null)},onError:re=>Ze.error("Failed to delete domain",{description:re?.message??"Unknown error"})}),je=mr({resolver:gr(oB),defaultValues:{name:"",type:"A",ttl:300,valuesCsv:""}}),ve=re=>{const ue=re?.response?.data?.error||re?.message||"Unknown error";return ue.includes("ownership_conflict")?"Ownership conflict: this (name,type) exists but isn’t owned by autoglue.":ue.includes("already_exists")?"A record with this (name,type) already exists. Use Edit instead.":ue},le=nn({mutationFn:async re=>{if(!s)throw new Error("No domain selected");const ue={name:re.name,type:re.type,...re.ttl?{ttl:re.ttl}:{},values:A_(re.valuesCsv??"")};return tc.createRecordSetsByDomain(s.id,ue)},onSuccess:async()=>{Ze.success("Record set created"),S(!1),je.reset(),await M.invalidateQueries({queryKey:["dns","records",s?.id]})},onError:re=>Ze.error("Failed to create record set",{description:ve(re)})}),be=mr({resolver:gr(Ibe)}),Ce=re=>{T(re);const ue=re.values||[];be.reset({name:re.name,type:re.type,ttl:re.ttl?Number(re.ttl):void 0,valuesCsv:Nbe(ue)}),A(!0)},Ke=nn({mutationFn:async re=>{if(!k)throw new Error("No record selected");const ue={};return re.name!==void 0&&(ue.name=re.name),re.type!==void 0&&(ue.type=re.type),re.ttl!==void 0&&re.ttl!==null&&(ue.ttl=re.ttl),re.valuesCsv!==void 0&&(ue.values=A_(re.valuesCsv)),tc.updateRecordSetsByDomain(k.id,ue)},onSuccess:async()=>{Ze.success("Record set updated"),A(!1),T(null),await M.invalidateQueries({queryKey:["dns","records",s?.id]})},onError:re=>Ze.error("Failed to update record set",{description:ve(re)})}),ce=nn({mutationFn:re=>tc.deleteRecordSetsByDomain(re),onSuccess:async()=>{Ze.success("Record set deleted"),await M.invalidateQueries({queryKey:["dns","records",s?.id]})},onError:re=>Ze.error("Failed to delete record set",{description:re?.message??"Unknown error"})});return u.jsxs("div",{className:"space-y-5 p-6",children:[u.jsxs("div",{className:"flex flex-col gap-3 md:flex-row md:items-center md:justify-between",children:[u.jsx("h1",{className:"text-2xl font-bold",children:"DNS"}),u.jsxs("div",{className:"flex items-center gap-2",children:[u.jsxs("div",{className:"relative",children:[u.jsx(Pa,{className:"absolute top-2.5 left-2 h-4 w-4 opacity-60"}),u.jsx(gt,{value:e,onChange:re=>r(re.target.value),placeholder:"Search domains…",className:"w-64 pl-8"})]}),u.jsxs(fn,{open:d,onOpenChange:p,children:[u.jsx(zi,{asChild:!0,children:u.jsxs(Fe,{onClick:()=>p(!0),children:[u.jsx(oo,{className:"mr-2 h-4 w-4"}),"Add Domain"]})}),u.jsxs(mn,{className:"sm:max-w-lg",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Add Domain"})}),u.jsx(yr,{...L,children:u.jsxs("form",{className:"space-y-4 pt-2",onSubmit:L.handleSubmit(re=>ee.mutate(re)),children:[u.jsx(pt,{control:L.control,name:"domain_name",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Domain"}),u.jsx(wt,{children:u.jsx(gt,{...re,placeholder:"example.com"})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:L.control,name:"credential_id",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Route53 Credential"}),u.jsxs(Rn,{onValueChange:re.onChange,value:re.value,disabled:G.isLoading||(K?.length??0)===0,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{placeholder:G.isLoading?"Loading…":(K?.length??0)===0?"No Route53 credentials found":"Select credential"})})}),u.jsx($n,{children:(K??[]).map(ue=>u.jsx(jt,{value:ue.id,children:N3(ue)},ue.id))})]}),G.error&&u.jsx("p",{className:"text-destructive text-xs",children:"Failed to load credentials."}),u.jsx(dt,{})]})}),u.jsx(pt,{control:L.control,name:"zone_id",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Zone ID (optional)"}),u.jsx(wt,{children:u.jsx(gt,{...re,placeholder:"/hostedzone/Z123…"})}),u.jsx(dt,{})]})}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{type:"button",variant:"outline",onClick:()=>p(!1),children:"Cancel"}),u.jsxs(Fe,{type:"submit",disabled:ee.isPending,children:[ee.isPending&&u.jsx(Ds,{className:"mr-2 h-4 w-4 animate-spin"}),"Create"]})]})]})})]})]})]})]}),u.jsx("div",{children:u.jsxs(ha,{className:"p-3 md:col-span-5",children:[u.jsxs("div",{className:"mb-2 flex items-center justify-between",children:[u.jsx("div",{className:"text-sm font-semibold",children:"Domains"}),I.isFetching&&u.jsx(Ds,{className:"h-4 w-4 animate-spin"})]}),u.jsx("div",{className:"max-h-[60vh] overflow-auto rounded-md border",children:u.jsxs("table",{className:"min-w-full text-sm",children:[u.jsx("thead",{className:"bg-muted/40 text-xs tracking-wide uppercase",children:u.jsxs("tr",{children:[u.jsx("th",{className:"px-3 py-2 text-left",children:"Domain"}),u.jsx("th",{className:"px-3 py-2 text-left",children:"Zone"}),u.jsx("th",{className:"px-3 py-2 text-left",children:"Status"}),u.jsx("th",{className:"px-3 py-2 text-right",children:"Actions"})]})}),u.jsxs("tbody",{children:[(X??[]).map(re=>u.jsxs("tr",{className:`hover:bg-muted/30 border-t ${s?.id===re.id?"bg-muted/40":""}`,onClick:()=>o(re),children:[u.jsx("td",{className:"cursor-pointer px-3 py-2 font-medium",children:re.domain_name}),u.jsx("td",{className:"px-3 py-2",children:re.zone_id||"—"}),u.jsx("td",{className:"px-3 py-2",children:u.jsx(yT,{s:re.status})}),u.jsx("td",{className:"px-3 py-2",children:u.jsxs("div",{className:"flex items-center justify-end gap-2",children:[u.jsx(Fe,{size:"icon",variant:"ghost",onClick:()=>Q(re),children:u.jsx(pu,{className:"h-4 w-4"})}),u.jsxs(nC,{children:[u.jsx(rC,{asChild:!0,children:u.jsx(Fe,{size:"icon",variant:"ghost",onClick:ue=>ue.stopPropagation(),children:u.jsx(Ib,{className:"h-4 w-4"})})}),u.jsxs(sC,{children:[u.jsxs(iC,{children:[u.jsxs(oC,{children:["Delete “",re.domain_name,"”?"]}),u.jsx(lC,{children:"This deletes the domain metadata. External DNS records are not touched."})]}),u.jsxs(aC,{children:[u.jsx(uC,{children:"Cancel"}),u.jsx(cC,{className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",onClick:()=>de.mutate(re.id),children:"Delete"})]})]})]})]})})]},re.id)),(!X||X.length===0)&&u.jsx("tr",{children:u.jsx("td",{colSpan:4,className:"text-muted-foreground px-3 py-8 text-center",children:"No domains yet."})})]})]})})]})}),u.jsx("div",{children:u.jsxs(ha,{className:"p-3 md:col-span-7",children:[u.jsxs("div",{className:"mb-2 flex items-center justify-between",children:[u.jsxs("div",{className:"text-sm font-semibold",children:["Records ",s?`— ${s.domain_name}`:""]}),u.jsxs("div",{className:"flex items-center gap-2",children:[u.jsx(yT,{s:s?.status}),u.jsxs(fn,{open:b,onOpenChange:S,children:[u.jsx(zi,{asChild:!0,children:u.jsxs(Fe,{disabled:!s,children:[u.jsx(oo,{className:"mr-2 h-4 w-4"}),"Add Record"]})}),u.jsxs(mn,{className:"sm:max-w-xl",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Add Record"})}),u.jsx(yr,{...je,children:u.jsxs("form",{className:"space-y-4 pt-2",onSubmit:je.handleSubmit(re=>le.mutate(re)),children:[u.jsxs("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-3",children:[u.jsx(pt,{control:je.control,name:"name",render:({field:re})=>u.jsxs(ot,{className:"md:col-span-1",children:[u.jsx(lt,{children:"Name"}),u.jsx(wt,{children:u.jsx(gt,{...re,placeholder:"endpoint (or @)"})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:je.control,name:"type",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Type"}),u.jsxs(Rn,{onValueChange:re.onChange,defaultValue:re.value,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{})})}),u.jsx($n,{children:O_.map(ue=>u.jsx(jt,{value:ue,children:ue},ue))})]}),u.jsx(dt,{})]})}),u.jsx(pt,{control:je.control,name:"ttl",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"TTL (sec, optional)"}),u.jsx(wt,{children:u.jsx(gt,{type:"number",value:re.value,onChange:ue=>re.onChange(ue.target.value===""?void 0:Number(ue.target.value)),placeholder:"300"})}),u.jsx(dt,{})]})})]}),u.jsx(pt,{control:je.control,name:"valuesCsv",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Values (comma-separated)"}),u.jsx(wt,{children:u.jsx(hu,{...re,rows:3,placeholder:'e.g. 10.0.30.1, 10.0.30.2 or "v=spf1 ~all"',className:"font-mono"})}),u.jsx(dt,{})]})}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{variant:"outline",type:"button",onClick:()=>S(!1),children:"Cancel"}),u.jsxs(Fe,{type:"submit",disabled:le.isPending,children:[le.isPending&&u.jsx(Ds,{className:"mr-2 h-4 w-4 animate-spin"}),"Create"]})]})]})})]})]})]})]}),u.jsxs("div",{className:"overflow-x-auto rounded-md border",children:[q.isLoading&&u.jsxs("div",{className:"flex items-center gap-2 p-4",children:[u.jsx(Ds,{className:"h-4 w-4 animate-spin"})," Loading records…"]}),!q.isLoading&&u.jsxs("table",{className:"min-w-full text-sm",children:[u.jsx("thead",{className:"bg-muted/40 text-xs tracking-wide uppercase",children:u.jsxs("tr",{children:[u.jsx("th",{className:"px-3 py-2 text-left",children:"Name"}),u.jsx("th",{className:"px-3 py-2 text-left",children:"Type"}),u.jsx("th",{className:"px-3 py-2 text-left",children:"TTL"}),u.jsx("th",{className:"px-3 py-2 text-left",children:"Values"}),u.jsx("th",{className:"px-3 py-2 text-left",children:"Status"}),u.jsx("th",{className:"px-3 py-2 text-left",children:"Owner"}),u.jsx("th",{className:"px-3 py-2 text-right",children:"Actions"})]})}),u.jsxs("tbody",{children:[(q.data??[]).map(re=>{const ue=re.values||[];return u.jsxs("tr",{className:"border-t",children:[u.jsx("td",{className:"px-3 py-2 font-medium",children:re.name||"@"}),u.jsx("td",{className:"px-3 py-2",children:re.type}),u.jsx("td",{className:"px-3 py-2",children:re.ttl??"—"}),u.jsx("td",{className:"px-3 py-2",children:u.jsx("div",{className:"max-w-[420px] truncate",title:(ue||[]).join(", "),children:(ue||[]).join(", ")})}),u.jsx("td",{className:"px-3 py-2",children:u.jsx(yT,{s:re.status})}),u.jsx("td",{className:"px-3 py-2",children:re.owner}),u.jsx("td",{className:"px-3 py-2",children:u.jsxs("div",{className:"flex items-center justify-end gap-2",children:[u.jsx(Fe,{size:"icon",variant:"ghost",onClick:()=>Ce(re),children:u.jsx(pu,{className:"h-4 w-4"})}),u.jsxs(nC,{children:[u.jsx(rC,{asChild:!0,children:u.jsx(Fe,{size:"icon",variant:"ghost",children:u.jsx(Ib,{className:"h-4 w-4"})})}),u.jsxs(sC,{children:[u.jsxs(iC,{children:[u.jsxs(oC,{children:["Delete “",re.name||"@"," ",re.type,"”?"]}),u.jsx(lC,{children:"This removes the record set from your project. Your worker does not delete it from the DNS provider right now."})]}),u.jsxs(aC,{children:[u.jsx(uC,{children:"Cancel"}),u.jsx(cC,{className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",onClick:()=>ce.mutate(re.id),children:"Delete"})]})]})]}),u.jsxs(f$,{children:[u.jsx(m$,{asChild:!0,children:u.jsx(Fe,{variant:"ghost",size:"icon",children:u.jsx(z_,{className:"h-4 w-4"})})}),u.jsxs(g$,{align:"end",children:[u.jsx(jp,{onClick:()=>Ce(re),children:"Edit"}),u.jsx(jp,{className:"text-destructive",onClick:()=>ce.mutate(re.id),children:"Delete"})]})]})]})})]},re.id)}),(!q.data||q.data.length===0)&&u.jsx("tr",{children:u.jsx("td",{colSpan:7,className:"text-muted-foreground px-3 py-8 text-center",children:s?"No records yet — add one.":"Select a domain to view records."})})]})]})]})]})}),u.jsx(fn,{open:m,onOpenChange:g,children:u.jsxs(mn,{className:"sm:max-w-lg",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Edit Domain"})}),u.jsx(yr,{...oe,children:u.jsxs("form",{className:"space-y-4 pt-2",onSubmit:oe.handleSubmit(re=>ne.mutate(re)),children:[u.jsx(pt,{control:oe.control,name:"domain_name",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Domain"}),u.jsx(wt,{children:u.jsx(gt,{...re,placeholder:"example.com"})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:oe.control,name:"credential_id",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Route53 Credential"}),u.jsxs(Rn,{onValueChange:re.onChange,value:re.value??"",disabled:G.isLoading||(K?.length??0)===0,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{placeholder:G.isLoading?"Loading…":(K?.length??0)===0?"No Route53 credentials found":"Select credential"})})}),u.jsx($n,{children:(K??[]).map(ue=>u.jsx(jt,{value:ue.id,children:N3(ue)},ue.id))})]}),G.error&&u.jsx("p",{className:"text-destructive text-xs",children:"Failed to load credentials."}),u.jsx(dt,{})]})}),u.jsx(pt,{control:oe.control,name:"zone_id",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Zone ID"}),u.jsx(wt,{children:u.jsx(gt,{...re,placeholder:"/hostedzone/Z123…"})}),u.jsx(dt,{})]})}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{variant:"outline",type:"button",onClick:()=>g(!1),children:"Cancel"}),u.jsxs(Fe,{type:"submit",disabled:ne.isPending,children:[ne.isPending&&u.jsx(Ds,{className:"mr-2 h-4 w-4 animate-spin"}),"Save Changes"]})]})]})})]})}),u.jsx(fn,{open:j,onOpenChange:A,children:u.jsxs(mn,{className:"sm:max-w-xl",children:[u.jsx(gn,{children:u.jsx(yn,{children:"Edit Record"})}),u.jsx(yr,{...be,children:u.jsxs("form",{className:"space-y-4 pt-2",onSubmit:be.handleSubmit(re=>Ke.mutate(re)),children:[u.jsxs("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-3",children:[u.jsx(pt,{control:be.control,name:"name",render:({field:re})=>u.jsxs(ot,{className:"md:col-span-1",children:[u.jsx(lt,{children:"Name"}),u.jsx(wt,{children:u.jsx(gt,{...re})}),u.jsx(dt,{})]})}),u.jsx(pt,{control:be.control,name:"type",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Type"}),u.jsxs(Rn,{onValueChange:re.onChange,defaultValue:re.value,children:[u.jsx(wt,{children:u.jsx(_n,{children:u.jsx(Tn,{})})}),u.jsx($n,{children:O_.map(ue=>u.jsx(jt,{value:ue,children:ue},ue))})]}),u.jsx(dt,{})]})}),u.jsx(pt,{control:be.control,name:"ttl",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"TTL (sec, optional)"}),u.jsx(wt,{children:u.jsx(gt,{type:"number",value:re.value,onChange:ue=>re.onChange(ue.target.value===""?void 0:Number(ue.target.value)),placeholder:"300"})}),u.jsx(dt,{})]})})]}),u.jsx(pt,{control:be.control,name:"valuesCsv",render:({field:re})=>u.jsxs(ot,{children:[u.jsx(lt,{children:"Values (comma-separated)"}),u.jsx(wt,{children:u.jsx(hu,{...re,rows:3,className:"font-mono"})}),u.jsx(dt,{})]})}),u.jsxs(Sn,{className:"gap-2",children:[u.jsx(Fe,{variant:"outline",type:"button",onClick:()=>A(!1),children:"Cancel"}),u.jsxs(Fe,{type:"submit",disabled:Ke.isPending,children:[Ke.isPending&&u.jsx(Ds,{className:"mr-2 h-4 w-4 animate-spin"}),"Save Changes"]})]})]})})]})})]})};var D3={};var P3;function zbe(){return P3||(P3=1,(()=>{var e,r,s={557:(p,m,g)=>{const b=globalThis,S=b.ShadowRoot&&(b.ShadyCSS===void 0||b.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,j=Symbol(),A=new WeakMap;class k{constructor(n,i,l){if(this._$cssResult$=!0,l!==j)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=n,this.t=i}get styleSheet(){let n=this.o;const i=this.t;if(S&&n===void 0){const l=i!==void 0&&i.length===1;l&&(n=A.get(i)),n===void 0&&((this.o=n=new CSSStyleSheet).replaceSync(this.cssText),l&&A.set(i,n))}return n}toString(){return this.cssText}}const T=t=>new k(typeof t=="string"?t:t+"",void 0,j),M=(t,...n)=>{const i=t.length===1?t[0]:n.reduce(((l,h,v)=>l+(x=>{if(x._$cssResult$===!0)return x.cssText;if(typeof x=="number")return x;throw Error("Value passed to 'css' function must be a 'css' function result: "+x+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(h)+t[v+1]),t[0]);return new k(i,t,j)},I=(t,n)=>{if(S)t.adoptedStyleSheets=n.map((i=>i instanceof CSSStyleSheet?i:i.styleSheet));else for(const i of n){const l=document.createElement("style"),h=b.litNonce;h!==void 0&&l.setAttribute("nonce",h),l.textContent=i.cssText,t.appendChild(l)}},q=S?t=>t:t=>t instanceof CSSStyleSheet?(n=>{let i="";for(const l of n.cssRules)i+=l.cssText;return T(i)})(t):t,{is:G,defineProperty:K,getOwnPropertyDescriptor:X,getOwnPropertyNames:L,getOwnPropertySymbols:ee,getPrototypeOf:oe}=Object,Q=globalThis,ne=Q.trustedTypes,de=ne?ne.emptyScript:"",je=Q.reactiveElementPolyfillSupport,ve=(t,n)=>t,le={toAttribute(t,n){switch(n){case Boolean:t=t?de:null;break;case Object:case Array:t=t==null?t:JSON.stringify(t)}return t},fromAttribute(t,n){let i=t;switch(n){case Boolean:i=t!==null;break;case Number:i=t===null?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch{i=null}}return i}},be=(t,n)=>!G(t,n),Ce={attribute:!0,type:String,converter:le,reflect:!1,hasChanged:be};Symbol.metadata??=Symbol("metadata"),Q.litPropertyMetadata??=new WeakMap;class Ke extends HTMLElement{static addInitializer(n){this._$Ei(),(this.l??=[]).push(n)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(n,i=Ce){if(i.state&&(i.attribute=!1),this._$Ei(),this.elementProperties.set(n,i),!i.noAccessor){const l=Symbol(),h=this.getPropertyDescriptor(n,l,i);h!==void 0&&K(this.prototype,n,h)}}static getPropertyDescriptor(n,i,l){const{get:h,set:v}=X(this.prototype,n)??{get(){return this[i]},set(x){this[i]=x}};return{get(){return h?.call(this)},set(x){const w=h?.call(this);v.call(this,x),this.requestUpdate(n,w,l)},configurable:!0,enumerable:!0}}static getPropertyOptions(n){return this.elementProperties.get(n)??Ce}static _$Ei(){if(this.hasOwnProperty(ve("elementProperties")))return;const n=oe(this);n.finalize(),n.l!==void 0&&(this.l=[...n.l]),this.elementProperties=new Map(n.elementProperties)}static finalize(){if(this.hasOwnProperty(ve("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(ve("properties"))){const i=this.properties,l=[...L(i),...ee(i)];for(const h of l)this.createProperty(h,i[h])}const n=this[Symbol.metadata];if(n!==null){const i=litPropertyMetadata.get(n);if(i!==void 0)for(const[l,h]of i)this.elementProperties.set(l,h)}this._$Eh=new Map;for(const[i,l]of this.elementProperties){const h=this._$Eu(i,l);h!==void 0&&this._$Eh.set(h,i)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(n){const i=[];if(Array.isArray(n)){const l=new Set(n.flat(1/0).reverse());for(const h of l)i.unshift(q(h))}else n!==void 0&&i.push(q(n));return i}static _$Eu(n,i){const l=i.attribute;return l===!1?void 0:typeof l=="string"?l:typeof n=="string"?n.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise((n=>this.enableUpdating=n)),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach((n=>n(this)))}addController(n){(this._$EO??=new Set).add(n),this.renderRoot!==void 0&&this.isConnected&&n.hostConnected?.()}removeController(n){this._$EO?.delete(n)}_$E_(){const n=new Map,i=this.constructor.elementProperties;for(const l of i.keys())this.hasOwnProperty(l)&&(n.set(l,this[l]),delete this[l]);n.size>0&&(this._$Ep=n)}createRenderRoot(){const n=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return I(n,this.constructor.elementStyles),n}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach((n=>n.hostConnected?.()))}enableUpdating(n){}disconnectedCallback(){this._$EO?.forEach((n=>n.hostDisconnected?.()))}attributeChangedCallback(n,i,l){this._$AK(n,l)}_$EC(n,i){const l=this.constructor.elementProperties.get(n),h=this.constructor._$Eu(n,l);if(h!==void 0&&l.reflect===!0){const v=(l.converter?.toAttribute!==void 0?l.converter:le).toAttribute(i,l.type);this._$Em=n,v==null?this.removeAttribute(h):this.setAttribute(h,v),this._$Em=null}}_$AK(n,i){const l=this.constructor,h=l._$Eh.get(n);if(h!==void 0&&this._$Em!==h){const v=l.getPropertyOptions(h),x=typeof v.converter=="function"?{fromAttribute:v.converter}:v.converter?.fromAttribute!==void 0?v.converter:le;this._$Em=h,this[h]=x.fromAttribute(i,v.type),this._$Em=null}}requestUpdate(n,i,l){if(n!==void 0){if(l??=this.constructor.getPropertyOptions(n),!(l.hasChanged??be)(this[n],i))return;this.P(n,i,l)}this.isUpdatePending===!1&&(this._$ES=this._$ET())}P(n,i,l){this._$AL.has(n)||this._$AL.set(n,i),l.reflect===!0&&this._$Em!==n&&(this._$Ej??=new Set).add(n)}async _$ET(){this.isUpdatePending=!0;try{await this._$ES}catch(i){Promise.reject(i)}const n=this.scheduleUpdate();return n!=null&&await n,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[h,v]of this._$Ep)this[h]=v;this._$Ep=void 0}const l=this.constructor.elementProperties;if(l.size>0)for(const[h,v]of l)v.wrapped!==!0||this._$AL.has(h)||this[h]===void 0||this.P(h,this[h],v)}let n=!1;const i=this._$AL;try{n=this.shouldUpdate(i),n?(this.willUpdate(i),this._$EO?.forEach((l=>l.hostUpdate?.())),this.update(i)):this._$EU()}catch(l){throw n=!1,this._$EU(),l}n&&this._$AE(i)}willUpdate(n){}_$AE(n){this._$EO?.forEach((i=>i.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(n)),this.updated(n)}_$EU(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(n){return!0}update(n){this._$Ej&&=this._$Ej.forEach((i=>this._$EC(i,this[i]))),this._$EU()}updated(n){}firstUpdated(n){}}Ke.elementStyles=[],Ke.shadowRootOptions={mode:"open"},Ke[ve("elementProperties")]=new Map,Ke[ve("finalized")]=new Map,je?.({ReactiveElement:Ke}),(Q.reactiveElementVersions??=[]).push("2.0.4");const ce=globalThis,re=ce.trustedTypes,ue=re?re.createPolicy("lit-html",{createHTML:t=>t}):void 0,_e="$lit$",fe=`lit$${Math.random().toFixed(9).slice(2)}$`,He="?"+fe,Oe=`<${He}>`,ke=document,Ve=()=>ke.createComment(""),ie=t=>t===null||typeof t!="object"&&typeof t!="function",De=Array.isArray,Le=t=>De(t)||typeof t?.[Symbol.iterator]=="function",tt=`[ -\f\r]`,yt=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Ot=/-->/g,Ft=/>/g,kt=RegExp(`>|${tt}(?:([^\\s"'>=/]+)(${tt}*=${tt}*(?:[^ -\f\r"'\`<>=]|("|')|))|$)`,"g"),Jt=/'/g,ze=/"/g,zt=/^(?:script|style|textarea|title)$/i,Rt=t=>(n,...i)=>({_$litType$:t,strings:n,values:i}),V=Rt(1),Dn=Symbol.for("lit-noChange"),cn=Symbol.for("lit-nothing"),xe=new WeakMap,Ne=ke.createTreeWalker(ke,129);function Ge(t,n){if(!De(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return ue!==void 0?ue.createHTML(n):n}const D=(t,n)=>{const i=t.length-1,l=[];let h,v=n===2?"":n===3?"":"",x=yt;for(let w=0;w"?(x=h??yt,_=-1):N[1]===void 0?_=-2:(_=x.lastIndex-N[2].length,$=N[1],x=N[3]===void 0?kt:N[3]==='"'?ze:Jt):x===ze||x===Jt?x=kt:x===Ot||x===Ft?x=yt:(x=kt,h=void 0);const U=x===kt&&t[w+1].startsWith("/>")?" ":"";v+=x===yt?C+Oe:_>=0?(l.push($),C.slice(0,_)+_e+C.slice(_)+fe+U):C+fe+(_===-2?w:U)}return[Ge(t,v+(t[i]||"")+(n===2?"":n===3?"":"")),l]};class z{constructor({strings:n,_$litType$:i},l){let h;this.parts=[];let v=0,x=0;const w=n.length-1,C=this.parts,[$,N]=D(n,i);if(this.el=z.createElement($,l),Ne.currentNode=this.el.content,i===2||i===3){const _=this.el.content.firstChild;_.replaceWith(..._.childNodes)}for(;(h=Ne.nextNode())!==null&&C.length0){h.textContent=re?re.emptyScript:"";for(let U=0;U2||l[0]!==""||l[1]!==""?(this._$AH=Array(l.length-1).fill(new String),this.strings=l):this._$AH=cn}_$AI(n,i=this,l,h){const v=this.strings;let x=!1;if(v===void 0)n=H(this,n,i,0),x=!ie(n)||n!==this._$AH&&n!==Dn,x&&(this._$AH=n);else{const w=n;let C,$;for(n=v[0],C=0;C{const x=v?.renderBefore??h;let w=x._$litPart$;if(w===void 0){const C=v?.renderBefore??null;x._$litPart$=w=new we(h.insertBefore(Ve(),C),C,void 0,v??{})}return w._$AI(l),w})(i,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this.o?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this.o?.setConnected(!1)}render(){return Dn}}Ht._$litElement$=!0,Ht.finalized=!0,globalThis.litElementHydrateSupport?.({LitElement:Ht});const wi=globalThis.litElementPolyfillSupport;wi?.({LitElement:Ht});function Xr(){return{async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}(globalThis.litElementVersions??=[]).push("4.1.0");let fa={async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1};const uo=/[&<>"']/,Ma=new RegExp(uo.source,"g"),cc=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,xu=new RegExp(cc.source,"g"),uc={"&":"&","<":"<",">":">",'"':""","'":"'"},ma=t=>uc[t];function Lt(t,n){if(n){if(uo.test(t))return t.replace(Ma,ma)}else if(cc.test(t))return t.replace(xu,ma);return t}const vr=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function Yr(t){return t.replace(vr,((n,i)=>(i=i.toLowerCase())==="colon"?":":i.charAt(0)==="#"?i.charAt(1)==="x"?String.fromCharCode(parseInt(i.substring(2),16)):String.fromCharCode(+i.substring(1)):""))}const Os=/(^|[^\[])\^/g;function Pn(t,n){t=typeof t=="string"?t:t.source,n=n||"";const i={replace:(l,h)=>(h=(h=h.source||h).replace(Os,"$1"),t=t.replace(l,h),i),getRegex:()=>new RegExp(t,n)};return i}const Er=/[^\w:]/g,Ys=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function ll(t,n,i){if(t){let l;try{l=decodeURIComponent(Yr(i)).replace(Er,"").toLowerCase()}catch{return null}if(l.indexOf("javascript:")===0||l.indexOf("vbscript:")===0||l.indexOf("data:")===0)return null}n&&!Ys.test(i)&&(i=(function(l,h){gs[" "+l]||(Zs.test(l)?gs[" "+l]=l+"/":gs[" "+l]=ya(l,"/",!0)),l=gs[" "+l];const v=l.indexOf(":")===-1;return h.substring(0,2)==="//"?v?h:l.replace(bu,"$1")+h:h.charAt(0)==="/"?v?h:l.replace(ga,"$1")+h:l+h})(n,i));try{i=encodeURI(i).replace(/%25/g,"%")}catch{return null}return i}const gs={},Zs=/^[^:]+:\/*[^/]*$/,bu=/^([^:]+:)[\s\S]*$/,ga=/^([^:]+:\/*[^/]*)[\s\S]*$/,wu={exec:function(){}};function Lg(t,n){const i=t.replace(/\|/g,((h,v,x)=>{let w=!1,C=v;for(;--C>=0&&x[C]==="\\";)w=!w;return w?"|":" |"})).split(/ \|/);let l=0;if(i[0].trim()||i.shift(),i.length>0&&!i[i.length-1].trim()&&i.pop(),i.length>n)i.splice(n);else for(;i.length1;)1&n&&(i+=t),n>>=1,t+=t;return i+t}function Ps(t,n,i,l){const h=n.href,v=n.title?Lt(n.title):null,x=t[1].replace(/\\([\[\]])/g,"$1");if(t[0].charAt(0)!=="!"){l.state.inLink=!0;const w={type:"link",raw:i,href:h,title:v,text:x,tokens:l.inlineTokens(x)};return l.state.inLink=!1,w}return{type:"image",raw:i,href:h,title:v,text:Lt(x)}}class cl{constructor(n){this.options=n||fa}space(n){const i=this.rules.block.newline.exec(n);if(i&&i[0].length>0)return{type:"space",raw:i[0]}}code(n){const i=this.rules.block.code.exec(n);if(i){const l=i[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:i[0],codeBlockStyle:"indented",text:this.options.pedantic?l:ya(l,` -`)}}}fences(n){const i=this.rules.block.fences.exec(n);if(i){const l=i[0],h=(function(v,x){const w=v.match(/^(\s+)(?:```)/);if(w===null)return x;const C=w[1];return x.split(` -`).map(($=>{const N=$.match(/^\s+/);if(N===null)return $;const[_]=N;return _.length>=C.length?$.slice(C.length):$})).join(` -`)})(l,i[3]||"");return{type:"code",raw:l,lang:i[2]?i[2].trim().replace(this.rules.inline._escapes,"$1"):i[2],text:h}}}heading(n){const i=this.rules.block.heading.exec(n);if(i){let l=i[2].trim();if(/#$/.test(l)){const h=ya(l,"#");this.options.pedantic?l=h.trim():h&&!/ $/.test(h)||(l=h.trim())}return{type:"heading",raw:i[0],depth:i[1].length,text:l,tokens:this.lexer.inline(l)}}}hr(n){const i=this.rules.block.hr.exec(n);if(i)return{type:"hr",raw:i[0]}}blockquote(n){const i=this.rules.block.blockquote.exec(n);if(i){const l=i[0].replace(/^ *>[ \t]?/gm,""),h=this.lexer.state.top;this.lexer.state.top=!0;const v=this.lexer.blockTokens(l);return this.lexer.state.top=h,{type:"blockquote",raw:i[0],tokens:v,text:l}}}list(n){let i=this.rules.block.list.exec(n);if(i){let l,h,v,x,w,C,$,N,_,F,U,J,Y=i[1].trim();const W=Y.length>1,P={type:"list",raw:"",ordered:W,start:W?+Y.slice(0,-1):"",loose:!1,items:[]};Y=W?`\\d{1,9}\\${Y.slice(-1)}`:`\\${Y}`,this.options.pedantic&&(Y=W?Y:"[*+-]");const se=new RegExp(`^( {0,3}${Y})((?:[ ][^\\n]*)?(?:\\n|$))`);for(;n&&(J=!1,i=se.exec(n))&&!this.rules.block.hr.test(n);){if(l=i[0],n=n.substring(l.length),N=i[2].split(` -`,1)[0].replace(/^\t+/,(he=>" ".repeat(3*he.length))),_=n.split(` -`,1)[0],this.options.pedantic?(x=2,U=N.trimLeft()):(x=i[2].search(/[^ ]/),x=x>4?1:x,U=N.slice(x),x+=i[1].length),C=!1,!N&&/^ *$/.test(_)&&(l+=_+` -`,n=n.substring(_.length+1),J=!0),!J){const he=new RegExp(`^ {0,${Math.min(3,x-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),ge=new RegExp(`^ {0,${Math.min(3,x-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),pe=new RegExp(`^ {0,${Math.min(3,x-1)}}(?:\`\`\`|~~~)`),Te=new RegExp(`^ {0,${Math.min(3,x-1)}}#`);for(;n&&(F=n.split(` -`,1)[0],_=F,this.options.pedantic&&(_=_.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!pe.test(_))&&!Te.test(_)&&!he.test(_)&&!ge.test(n);){if(_.search(/[^ ]/)>=x||!_.trim())U+=` -`+_.slice(x);else{if(C||N.search(/[^ ]/)>=4||pe.test(N)||Te.test(N)||ge.test(N))break;U+=` -`+_}C||_.trim()||(C=!0),l+=F+` -`,n=n.substring(F.length+1),N=_.slice(x)}}P.loose||($?P.loose=!0:/\n *\n *$/.test(l)&&($=!0)),this.options.gfm&&(h=/^\[[ xX]\] /.exec(U),h&&(v=h[0]!=="[ ] ",U=U.replace(/^\[[ xX]\] +/,""))),P.items.push({type:"list_item",raw:l,task:!!h,checked:v,loose:!1,text:U}),P.raw+=l}P.items[P.items.length-1].raw=l.trimRight(),P.items[P.items.length-1].text=U.trimRight(),P.raw=P.raw.trimRight();const ae=P.items.length;for(w=0;wpe.type==="space")),ge=he.length>0&&he.some((pe=>/\n.*\n/.test(pe.raw)));P.loose=ge}if(P.loose)for(w=0;w$/,"$1").replace(this.rules.inline._escapes,"$1"):"",v=i[3]?i[3].substring(1,i[3].length-1).replace(this.rules.inline._escapes,"$1"):i[3];return{type:"def",tag:l,raw:i[0],href:h,title:v}}}table(n){const i=this.rules.block.table.exec(n);if(i){const l={type:"table",header:Lg(i[1]).map((h=>({text:h}))),align:i[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:i[3]&&i[3].trim()?i[3].replace(/\n[ \t]*$/,"").split(` -`):[]};if(l.header.length===l.align.length){l.raw=i[0];let h,v,x,w,C=l.align.length;for(h=0;h({text:$})));for(C=l.header.length,v=0;v/i.test(i[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(i[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(i[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:i[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(i[0]):Lt(i[0]):i[0]}}link(n){const i=this.rules.inline.link.exec(n);if(i){const l=i[2].trim();if(!this.options.pedantic&&/^$/.test(l))return;const x=ya(l.slice(0,-1),"\\");if((l.length-x.length)%2==0)return}else{const x=(function(w,C){if(w.indexOf(C[1])===-1)return-1;const $=w.length;let N=0,_=0;for(;_<$;_++)if(w[_]==="\\")_++;else if(w[_]===C[0])N++;else if(w[_]===C[1]&&(N--,N<0))return _;return-1})(i[2],"()");if(x>-1){const w=(i[0].indexOf("!")===0?5:4)+i[1].length+x;i[2]=i[2].substring(0,x),i[0]=i[0].substring(0,w).trim(),i[3]=""}}let h=i[2],v="";if(this.options.pedantic){const x=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(h);x&&(h=x[1],v=x[3])}else v=i[3]?i[3].slice(1,-1):"";return h=h.trim(),/^$/.test(l)?h.slice(1):h.slice(1,-1)),Ps(i,{href:h&&h.replace(this.rules.inline._escapes,"$1"),title:v&&v.replace(this.rules.inline._escapes,"$1")},i[0],this.lexer)}}reflink(n,i){let l;if((l=this.rules.inline.reflink.exec(n))||(l=this.rules.inline.nolink.exec(n))){let h=(l[2]||l[1]).replace(/\s+/g," ");if(h=i[h.toLowerCase()],!h){const v=l[0].charAt(0);return{type:"text",raw:v,text:v}}return Ps(l,h,l[0],this.lexer)}}emStrong(n,i,l=""){let h=this.rules.inline.emStrong.lDelim.exec(n);if(!h||h[3]&&l.match(/[\p{L}\p{N}]/u))return;const v=h[1]||h[2]||"";if(!v||v&&(l===""||this.rules.inline.punctuation.exec(l))){const x=h[0].length-1;let w,C,$=x,N=0;const _=h[0][0]==="*"?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(_.lastIndex=0,i=i.slice(-1*n.length+x);(h=_.exec(i))!=null;){if(w=h[1]||h[2]||h[3]||h[4]||h[5]||h[6],!w)continue;if(C=w.length,h[3]||h[4]){$+=C;continue}if((h[5]||h[6])&&x%3&&!((x+C)%3)){N+=C;continue}if($-=C,$>0)continue;C=Math.min(C,C+$+N);const F=n.slice(0,x+h.index+(h[0].length-w.length)+C);if(Math.min(x,C)%2){const J=F.slice(1,-1);return{type:"em",raw:F,text:J,tokens:this.lexer.inlineTokens(J)}}const U=F.slice(2,-2);return{type:"strong",raw:F,text:U,tokens:this.lexer.inlineTokens(U)}}}}codespan(n){const i=this.rules.inline.code.exec(n);if(i){let l=i[2].replace(/\n/g," ");const h=/[^ ]/.test(l),v=/^ /.test(l)&&/ $/.test(l);return h&&v&&(l=l.substring(1,l.length-1)),l=Lt(l,!0),{type:"codespan",raw:i[0],text:l}}}br(n){const i=this.rules.inline.br.exec(n);if(i)return{type:"br",raw:i[0]}}del(n){const i=this.rules.inline.del.exec(n);if(i)return{type:"del",raw:i[0],text:i[2],tokens:this.lexer.inlineTokens(i[2])}}autolink(n,i){const l=this.rules.inline.autolink.exec(n);if(l){let h,v;return l[2]==="@"?(h=Lt(this.options.mangle?i(l[1]):l[1]),v="mailto:"+h):(h=Lt(l[1]),v=h),{type:"link",raw:l[0],text:h,href:v,tokens:[{type:"text",raw:h,text:h}]}}}url(n,i){let l;if(l=this.rules.inline.url.exec(n)){let h,v;if(l[2]==="@")h=Lt(this.options.mangle?i(l[0]):l[0]),v="mailto:"+h;else{let x;do x=l[0],l[0]=this.rules.inline._backpedal.exec(l[0])[0];while(x!==l[0]);h=Lt(l[0]),v=l[1]==="www."?"http://"+l[0]:l[0]}return{type:"link",raw:l[0],text:h,href:v,tokens:[{type:"text",raw:h,text:h}]}}}inlineText(n,i){const l=this.rules.inline.text.exec(n);if(l){let h;return h=this.lexer.state.inRawBlock?this.options.sanitize?this.options.sanitizer?this.options.sanitizer(l[0]):Lt(l[0]):l[0]:Lt(this.options.smartypants?i(l[0]):l[0]),{type:"text",raw:l[0],text:h}}}}const Gt={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:wu,lheading:/^((?:.|\n(?!\n))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/,_label:/(?!\s*\])(?:\\.|[^\[\]\\])+/,_title:/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/};Gt.def=Pn(Gt.def).replace("label",Gt._label).replace("title",Gt._title).getRegex(),Gt.bullet=/(?:[*+-]|\d{1,9}[.)])/,Gt.listItemStart=Pn(/^( *)(bull) */).replace("bull",Gt.bullet).getRegex(),Gt.list=Pn(Gt.list).replace(/bull/g,Gt.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+Gt.def.source+")").getRegex(),Gt._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Gt._comment=/|$)/,Gt.html=Pn(Gt.html,"i").replace("comment",Gt._comment).replace("tag",Gt._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),Gt.paragraph=Pn(Gt._paragraph).replace("hr",Gt.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",Gt._tag).getRegex(),Gt.blockquote=Pn(Gt.blockquote).replace("paragraph",Gt.paragraph).getRegex(),Gt.normal={...Gt},Gt.gfm={...Gt.normal,table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"},Gt.gfm.table=Pn(Gt.gfm.table).replace("hr",Gt.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",Gt._tag).getRegex(),Gt.gfm.paragraph=Pn(Gt._paragraph).replace("hr",Gt.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",Gt.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",Gt._tag).getRegex(),Gt.pedantic={...Gt.normal,html:Pn(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Gt._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:wu,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Pn(Gt.normal._paragraph).replace("hr",Gt.hr).replace("heading",` *#{1,6} *[^ -]`).replace("lheading",Gt.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()};const Nt={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:wu,tag:"^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,rDelimUnd:/^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:wu,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\.5&&(i="x"+i.toString(16)),l+="&#"+i+";";return l}Nt._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~",Nt.punctuation=Pn(Nt.punctuation).replace(/punctuation/g,Nt._punctuation).getRegex(),Nt.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g,Nt.escapedEmSt=/(?:^|[^\\])(?:\\\\)*\\[*_]/g,Nt._comment=Pn(Gt._comment).replace("(?:-->|$)","-->").getRegex(),Nt.emStrong.lDelim=Pn(Nt.emStrong.lDelim).replace(/punct/g,Nt._punctuation).getRegex(),Nt.emStrong.rDelimAst=Pn(Nt.emStrong.rDelimAst,"g").replace(/punct/g,Nt._punctuation).getRegex(),Nt.emStrong.rDelimUnd=Pn(Nt.emStrong.rDelimUnd,"g").replace(/punct/g,Nt._punctuation).getRegex(),Nt._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,Nt._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,Nt._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,Nt.autolink=Pn(Nt.autolink).replace("scheme",Nt._scheme).replace("email",Nt._email).getRegex(),Nt._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,Nt.tag=Pn(Nt.tag).replace("comment",Nt._comment).replace("attribute",Nt._attribute).getRegex(),Nt._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,Nt._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/,Nt._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,Nt.link=Pn(Nt.link).replace("label",Nt._label).replace("href",Nt._href).replace("title",Nt._title).getRegex(),Nt.reflink=Pn(Nt.reflink).replace("label",Nt._label).replace("ref",Gt._label).getRegex(),Nt.nolink=Pn(Nt.nolink).replace("ref",Gt._label).getRegex(),Nt.reflinkSearch=Pn(Nt.reflinkSearch,"g").replace("reflink",Nt.reflink).replace("nolink",Nt.nolink).getRegex(),Nt.normal={...Nt},Nt.pedantic={...Nt.normal,strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:Pn(/^!?\[(label)\]\((.*?)\)/).replace("label",Nt._label).getRegex(),reflink:Pn(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",Nt._label).getRegex()},Nt.gfm={...Nt.normal,escape:Pn(Nt.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\C+" ".repeat($.length)));n;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some((w=>!!(l=w.call({lexer:this},n,i))&&(n=n.substring(l.raw.length),i.push(l),!0)))))if(l=this.tokenizer.space(n))n=n.substring(l.raw.length),l.raw.length===1&&i.length>0?i[i.length-1].raw+=` -`:i.push(l);else if(l=this.tokenizer.code(n))n=n.substring(l.raw.length),h=i[i.length-1],!h||h.type!=="paragraph"&&h.type!=="text"?i.push(l):(h.raw+=` -`+l.raw,h.text+=` -`+l.text,this.inlineQueue[this.inlineQueue.length-1].src=h.text);else if(l=this.tokenizer.fences(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.heading(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.hr(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.blockquote(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.list(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.html(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.def(n))n=n.substring(l.raw.length),h=i[i.length-1],!h||h.type!=="paragraph"&&h.type!=="text"?this.tokens.links[l.tag]||(this.tokens.links[l.tag]={href:l.href,title:l.title}):(h.raw+=` -`+l.raw,h.text+=` -`+l.raw,this.inlineQueue[this.inlineQueue.length-1].src=h.text);else if(l=this.tokenizer.table(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.lheading(n))n=n.substring(l.raw.length),i.push(l);else{if(v=n,this.options.extensions&&this.options.extensions.startBlock){let w=1/0;const C=n.slice(1);let $;this.options.extensions.startBlock.forEach((function(N){$=N.call({lexer:this},C),typeof $=="number"&&$>=0&&(w=Math.min(w,$))})),w<1/0&&w>=0&&(v=n.substring(0,w+1))}if(this.state.top&&(l=this.tokenizer.paragraph(v)))h=i[i.length-1],x&&h.type==="paragraph"?(h.raw+=` -`+l.raw,h.text+=` -`+l.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=h.text):i.push(l),x=v.length!==n.length,n=n.substring(l.raw.length);else if(l=this.tokenizer.text(n))n=n.substring(l.raw.length),h=i[i.length-1],h&&h.type==="text"?(h.raw+=` -`+l.raw,h.text+=` -`+l.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=h.text):i.push(l);else if(n){const w="Infinite loop on byte: "+n.charCodeAt(0);if(this.options.silent){console.error(w);break}throw new Error(w)}}return this.state.top=!0,i}inline(n,i=[]){return this.inlineQueue.push({src:n,tokens:i}),i}inlineTokens(n,i=[]){let l,h,v,x,w,C,$=n;if(this.tokens.links){const N=Object.keys(this.tokens.links);if(N.length>0)for(;(x=this.tokenizer.rules.inline.reflinkSearch.exec($))!=null;)N.includes(x[0].slice(x[0].lastIndexOf("[")+1,-1))&&($=$.slice(0,x.index)+"["+ss("a",x[0].length-2)+"]"+$.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(x=this.tokenizer.rules.inline.blockSkip.exec($))!=null;)$=$.slice(0,x.index)+"["+ss("a",x[0].length-2)+"]"+$.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(x=this.tokenizer.rules.inline.escapedEmSt.exec($))!=null;)$=$.slice(0,x.index+x[0].length-2)+"++"+$.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex),this.tokenizer.rules.inline.escapedEmSt.lastIndex--;for(;n;)if(w||(C=""),w=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some((N=>!!(l=N.call({lexer:this},n,i))&&(n=n.substring(l.raw.length),i.push(l),!0)))))if(l=this.tokenizer.escape(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.tag(n))n=n.substring(l.raw.length),h=i[i.length-1],h&&l.type==="text"&&h.type==="text"?(h.raw+=l.raw,h.text+=l.text):i.push(l);else if(l=this.tokenizer.link(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.reflink(n,this.tokens.links))n=n.substring(l.raw.length),h=i[i.length-1],h&&l.type==="text"&&h.type==="text"?(h.raw+=l.raw,h.text+=l.text):i.push(l);else if(l=this.tokenizer.emStrong(n,$,C))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.codespan(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.br(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.del(n))n=n.substring(l.raw.length),i.push(l);else if(l=this.tokenizer.autolink(n,zg))n=n.substring(l.raw.length),i.push(l);else if(this.state.inLink||!(l=this.tokenizer.url(n,zg))){if(v=n,this.options.extensions&&this.options.extensions.startInline){let N=1/0;const _=n.slice(1);let F;this.options.extensions.startInline.forEach((function(U){F=U.call({lexer:this},_),typeof F=="number"&&F>=0&&(N=Math.min(N,F))})),N<1/0&&N>=0&&(v=n.substring(0,N+1))}if(l=this.tokenizer.inlineText(v,eA))n=n.substring(l.raw.length),l.raw.slice(-1)!=="_"&&(C=l.raw.slice(-1)),w=!0,h=i[i.length-1],h&&h.type==="text"?(h.raw+=l.raw,h.text+=l.text):i.push(l);else if(n){const N="Infinite loop on byte: "+n.charCodeAt(0);if(this.options.silent){console.error(N);break}throw new Error(N)}}else n=n.substring(l.raw.length),i.push(l);return i}}class Qd{constructor(n){this.options=n||fa}code(n,i,l){const h=(i||"").match(/\S*/)[0];if(this.options.highlight){const v=this.options.highlight(n,h);v!=null&&v!==n&&(l=!0,n=v)}return n=n.replace(/\n$/,"")+` -`,h?'
'+(l?n:Lt(n,!0))+`
-`:"
"+(l?n:Lt(n,!0))+`
-`}blockquote(n){return`
-${n}
-`}html(n){return n}heading(n,i,l,h){return this.options.headerIds?`${n} -`:`${n} -`}hr(){return this.options.xhtml?`
-`:`
-`}list(n,i,l){const h=i?"ol":"ul";return"<"+h+(i&&l!==1?' start="'+l+'"':"")+`> -`+n+" -`}listitem(n){return`
  • ${n}
  • -`}checkbox(n){return" "}paragraph(n){return`

    ${n}

    -`}table(n,i){return i&&(i=`${i}`),` - -`+n+` -`+i+`
    -`}tablerow(n){return` -${n} -`}tablecell(n,i){const l=i.header?"th":"td";return(i.align?`<${l} align="${i.align}">`:`<${l}>`)+n+` -`}strong(n){return`${n}`}em(n){return`${n}`}codespan(n){return`${n}`}br(){return this.options.xhtml?"
    ":"
    "}del(n){return`${n}`}link(n,i,l){if((n=ll(this.options.sanitize,this.options.baseUrl,n))===null)return l;let h='",h}image(n,i,l){if((n=ll(this.options.sanitize,this.options.baseUrl,n))===null)return l;let h=`${l}":">",h}text(n){return n}}class dc{strong(n){return n}em(n){return n}codespan(n){return n}del(n){return n}html(n){return n}text(n){return n}link(n,i,l){return""+l}image(n,i,l){return""+l}br(){return""}}class hc{constructor(){this.seen={}}serialize(n){return n.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")}getNextSafeSlug(n,i){let l=n,h=0;if(this.seen.hasOwnProperty(l)){h=this.seen[n];do h++,l=n+"-"+h;while(this.seen.hasOwnProperty(l))}return i||(this.seen[n]=h,this.seen[l]=0),l}slug(n,i={}){const l=this.serialize(n);return this.getNextSafeSlug(l,i.dryrun)}}class Hi{constructor(n){this.options=n||fa,this.options.renderer=this.options.renderer||new Qd,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new dc,this.slugger=new hc}static parse(n,i){return new Hi(i).parse(n)}static parseInline(n,i){return new Hi(i).parseInline(n)}parse(n,i=!0){let l,h,v,x,w,C,$,N,_,F,U,J,Y,W,P,se,ae,he,ge,pe="";const Te=n.length;for(l=0;l0&&P.tokens[0].type==="paragraph"?(P.tokens[0].text=he+" "+P.tokens[0].text,P.tokens[0].tokens&&P.tokens[0].tokens.length>0&&P.tokens[0].tokens[0].type==="text"&&(P.tokens[0].tokens[0].text=he+" "+P.tokens[0].tokens[0].text)):P.tokens.unshift({type:"text",text:he}):W+=he),W+=this.parse(P.tokens,Y),_+=this.renderer.listitem(W,ae,se);pe+=this.renderer.list(_,U,J);continue;case"html":pe+=this.renderer.html(F.text);continue;case"paragraph":pe+=this.renderer.paragraph(this.parseInline(F.tokens));continue;case"text":for(_=F.tokens?this.parseInline(F.tokens):F.text;l+1{typeof l=="function"&&(h=l,l=null);const v={...l},x=(function(w,C,$){return N=>{if(N.message+=` -Please report this to https://github.com/markedjs/marked.`,w){const _="

    An error occurred:

    "+Lt(N.message+"",!0)+"
    ";return C?Promise.resolve(_):$?void $(null,_):_}if(C)return Promise.reject(N);if(!$)throw N;$(N)}})((l={...ht.defaults,...v}).silent,l.async,h);if(i==null)return x(new Error("marked(): input parameter is undefined or null"));if(typeof i!="string")return x(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(i)+", string expected"));if((function(w){w&&w.sanitize&&!w.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")})(l),l.hooks&&(l.hooks.options=l),h){const w=l.highlight;let C;try{l.hooks&&(i=l.hooks.preprocess(i)),C=t(i,l)}catch(_){return x(_)}const $=function(_){let F;if(!_)try{l.walkTokens&&ht.walkTokens(C,l.walkTokens),F=n(C,l),l.hooks&&(F=l.hooks.postprocess(F))}catch(U){_=U}return l.highlight=w,_?x(_):h(null,F)};if(!w||w.length<3||(delete l.highlight,!C.length))return $();let N=0;return ht.walkTokens(C,(function(_){_.type==="code"&&(N++,setTimeout((()=>{w(_.text,_.lang,(function(F,U){if(F)return $(F);U!=null&&U!==_.text&&(_.text=U,_.escaped=!0),N--,N===0&&$()}))}),0))})),void(N===0&&$())}if(l.async)return Promise.resolve(l.hooks?l.hooks.preprocess(i):i).then((w=>t(w,l))).then((w=>l.walkTokens?Promise.all(ht.walkTokens(w,l.walkTokens)).then((()=>w)):w)).then((w=>n(w,l))).then((w=>l.hooks?l.hooks.postprocess(w):w)).catch(x);try{l.hooks&&(i=l.hooks.preprocess(i));const w=t(i,l);l.walkTokens&&ht.walkTokens(w,l.walkTokens);let C=n(w,l);return l.hooks&&(C=l.hooks.postprocess(C)),C}catch(w){return x(w)}}}function ht(t,n,i){return Zr(Vi.lex,Hi.parse)(t,n,i)}ht.options=ht.setOptions=function(t){var n;return ht.defaults={...ht.defaults,...t},n=ht.defaults,fa=n,ht},ht.getDefaults=Xr,ht.defaults=fa,ht.use=function(...t){const n=ht.defaults.extensions||{renderers:{},childTokens:{}};t.forEach((i=>{const l={...i};if(l.async=ht.defaults.async||l.async||!1,i.extensions&&(i.extensions.forEach((h=>{if(!h.name)throw new Error("extension name required");if(h.renderer){const v=n.renderers[h.name];n.renderers[h.name]=v?function(...x){let w=h.renderer.apply(this,x);return w===!1&&(w=v.apply(this,x)),w}:h.renderer}if(h.tokenizer){if(!h.level||h.level!=="block"&&h.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");n[h.level]?n[h.level].unshift(h.tokenizer):n[h.level]=[h.tokenizer],h.start&&(h.level==="block"?n.startBlock?n.startBlock.push(h.start):n.startBlock=[h.start]:h.level==="inline"&&(n.startInline?n.startInline.push(h.start):n.startInline=[h.start]))}h.childTokens&&(n.childTokens[h.name]=h.childTokens)})),l.extensions=n),i.renderer){const h=ht.defaults.renderer||new Qd;for(const v in i.renderer){const x=h[v];h[v]=(...w)=>{let C=i.renderer[v].apply(h,w);return C===!1&&(C=x.apply(h,w)),C}}l.renderer=h}if(i.tokenizer){const h=ht.defaults.tokenizer||new cl;for(const v in i.tokenizer){const x=h[v];h[v]=(...w)=>{let C=i.tokenizer[v].apply(h,w);return C===!1&&(C=x.apply(h,w)),C}}l.tokenizer=h}if(i.hooks){const h=ht.defaults.hooks||new ul;for(const v in i.hooks){const x=h[v];ul.passThroughHooks.has(v)?h[v]=w=>{if(ht.defaults.async)return Promise.resolve(i.hooks[v].call(h,w)).then(($=>x.call(h,$)));const C=i.hooks[v].call(h,w);return x.call(h,C)}:h[v]=(...w)=>{let C=i.hooks[v].apply(h,w);return C===!1&&(C=x.apply(h,w)),C}}l.hooks=h}if(i.walkTokens){const h=ht.defaults.walkTokens;l.walkTokens=function(v){let x=[];return x.push(i.walkTokens.call(this,v)),h&&(x=x.concat(h.call(this,v))),x}}ht.setOptions(l)}))},ht.walkTokens=function(t,n){let i=[];for(const l of t)switch(i=i.concat(n.call(ht,l)),l.type){case"table":for(const h of l.header)i=i.concat(ht.walkTokens(h.tokens,n));for(const h of l.rows)for(const v of h)i=i.concat(ht.walkTokens(v.tokens,n));break;case"list":i=i.concat(ht.walkTokens(l.items,n));break;default:ht.defaults.extensions&&ht.defaults.extensions.childTokens&&ht.defaults.extensions.childTokens[l.type]?ht.defaults.extensions.childTokens[l.type].forEach((function(h){i=i.concat(ht.walkTokens(l[h],n))})):l.tokens&&(i=i.concat(ht.walkTokens(l.tokens,n)))}return i},ht.parseInline=Zr(Vi.lexInline,Hi.parseInline),ht.Parser=Hi,ht.parser=Hi.parse,ht.Renderer=Qd,ht.TextRenderer=dc,ht.Lexer=Vi,ht.lexer=Vi.lex,ht.Tokenizer=cl,ht.Slugger=hc,ht.Hooks=ul,ht.parse=ht,ht.options,ht.setOptions,ht.use,ht.walkTokens,ht.parseInline,Hi.parse,Vi.lex;var vw=g(848),sr=g.n(vw);g(113),g(83),g(378),g(976),g(514),g(22),g(342),g(784),g(651);const Si=M` - .hover-bg:hover { - background: var(--bg3); - } - ::selection { - background: var(--selection-bg); - color: var(--selection-fg); - } - .regular-font { - font-family:var(--font-regular); - } - .mono-font { - font-family:var(--font-mono); - } - .title { - font-size: calc(var(--font-size-small) + 18px); - font-weight: normal - } - .sub-title{ font-size: 20px; } - .req-res-title { - font-family: var(--font-regular); - font-size: calc(var(--font-size-small) + 4px); - font-weight:bold; - margin-bottom:8px; - text-align:left; - } - .tiny-title { - font-size:calc(var(--font-size-small) + 1px); - font-weight:bold; - } - .regular-font-size { font-size: var(--font-size-regular); } - .small-font-size { font-size: var(--font-size-small); } - .upper { text-transform: uppercase; } - .primary-text { color: var(--primary-color); } - .bold-text { font-weight:bold; } - .gray-text { color: var(--light-fg); } - .red-text { color: var(--red) } - .blue-text { color: var(--blue) } - .multiline { - overflow: scroll; - max-height: var(--resp-area-height, 400px); - color: var(--fg3); - } - .method-fg.put { color: var(--orange); } - .method-fg.post { color: var(--green); } - .method-fg.get { color: var(--blue); } - .method-fg.delete { color: var(--red); } - .method-fg.options, - .method-fg.head, - .method-fg.patch { - color: var(--yellow); - } - - h1 { font-family:var(--font-regular); font-size:28px; padding-top: 10px; letter-spacing:normal; font-weight:normal; } - h2 { font-family:var(--font-regular); font-size:24px; padding-top: 10px; letter-spacing:normal; font-weight:normal; } - h3 { font-family:var(--font-regular); font-size:18px; padding-top: 10px; letter-spacing:normal; font-weight:normal; } - h4 { font-family:var(--font-regular); font-size:16px; padding-top: 10px; letter-spacing:normal; font-weight:normal; } - h5 { font-family:var(--font-regular); font-size:14px; padding-top: 10px; letter-spacing:normal; font-weight:normal; } - h6 { font-family:var(--font-regular); font-size:14px; padding-top: 10px; letter-spacing:normal; font-weight:normal; } - - h1,h2,h3,h4,h5,h5 { - margin-block-end: 0.2em; - } - p { margin-block-start: 0.5em; } - a { color: var(--blue); cursor:pointer; } - a.inactive-link { - color:var(--fg); - text-decoration: none; - cursor:text; - } - - code, - pre { - margin: 0px; - font-family: var(--font-mono); - font-size: calc(var(--font-size-mono) - 1px); - } - - .m-markdown, - .m-markdown-small { - display:block; - } - - .m-markdown p, - .m-markdown span { - font-size: var(--font-size-regular); - line-height:calc(var(--font-size-regular) + 8px); - } - .m-markdown li { - font-size: var(--font-size-regular); - line-height:calc(var(--font-size-regular) + 10px); - } - - .m-markdown-small p, - .m-markdown-small span, - .m-markdown-small li { - font-size: var(--font-size-small); - line-height: calc(var(--font-size-small) + 6px); - } - .m-markdown-small li { - line-height: calc(var(--font-size-small) + 8px); - } - - .m-markdown p:not(:first-child) { - margin-block-start: 24px; - } - - .m-markdown-small p:not(:first-child) { - margin-block-start: 12px; - } - .m-markdown-small p:first-child { - margin-block-start: 0; - } - - .m-markdown p, - .m-markdown-small p { - margin-block-end: 0 - } - - .m-markdown code span { - font-size:var(--font-size-mono); - } - - .m-markdown-small code, - .m-markdown code { - padding: 1px 6px; - border-radius: 2px; - color: var(--inline-code-fg); - background-color: var(--bg3); - font-size: calc(var(--font-size-mono)); - line-height: 1.2; - } - - .m-markdown-small code { - font-size: calc(var(--font-size-mono) - 1px); - } - - .m-markdown-small pre, - .m-markdown pre { - white-space: pre-wrap; - overflow-x: auto; - line-height: normal; - border-radius: 2px; - border: 1px solid var(--code-border-color); - } - - .m-markdown pre { - padding: 12px; - background-color: var(--code-bg); - color:var(--code-fg); - } - - .m-markdown-small pre { - margin-top: 4px; - padding: 2px 4px; - background-color: var(--bg3); - color: var(--fg2); - } - - .m-markdown-small pre code, - .m-markdown pre code { - border:none; - padding:0; - } - - .m-markdown pre code { - color: var(--code-fg); - background-color: var(--code-bg); - background-color: transparent; - } - - .m-markdown-small pre code { - color: var(--fg2); - background-color: var(--bg3); - } - - .m-markdown ul, - .m-markdown ol { - padding-inline-start: 30px; - } - - .m-markdown-small ul, - .m-markdown-small ol { - padding-inline-start: 20px; - } - - .m-markdown-small a, - .m-markdown a { - color:var(--blue); - } - - .m-markdown-small img, - .m-markdown img { - max-width: 100%; - } - - /* Markdown table */ - - .m-markdown-small table, - .m-markdown table { - border-spacing: 0; - margin: 10px 0; - border-collapse: separate; - border: 1px solid var(--border-color); - border-radius: var(--border-radius); - font-size: calc(var(--font-size-small) + 1px); - line-height: calc(var(--font-size-small) + 4px); - max-width: 100%; - } - - .m-markdown-small table { - font-size: var(--font-size-small); - line-height: calc(var(--font-size-small) + 2px); - margin: 8px 0; - } - - .m-markdown-small td, - .m-markdown-small th, - .m-markdown td, - .m-markdown th { - vertical-align: top; - border-top: 1px solid var(--border-color); - line-height: calc(var(--font-size-small) + 4px); - } - - .m-markdown-small tr:first-child th, - .m-markdown tr:first-child th { - border-top: 0 none; - } - - .m-markdown th, - .m-markdown td { - padding: 10px 12px; - } - - .m-markdown-small th, - .m-markdown-small td { - padding: 8px 8px; - } - - .m-markdown th, - .m-markdown-small th { - font-weight: 600; - background-color: var(--bg2); - vertical-align: middle; - } - - .m-markdown-small table code { - font-size: calc(var(--font-size-mono) - 2px); - } - - .m-markdown table code { - font-size: calc(var(--font-size-mono) - 1px); - } - - .m-markdown blockquote, - .m-markdown-small blockquote { - margin-inline-start: 0; - margin-inline-end: 0; - border-left: 3px solid var(--border-color); - padding: 6px 0 6px 6px; - } - .m-markdown hr{ - border: 1px solid var(--border-color); - } -`,Su=M` -/* Button */ -.m-btn { - border-radius: var(--border-radius); - font-weight: 600; - display: inline-block; - padding: 6px 16px; - font-size: var(--font-size-small); - outline: 0; - line-height: 1; - text-align: center; - white-space: nowrap; - border: 2px solid var(--primary-color); - background-color:transparent; - user-select: none; - cursor: pointer; - box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24); - transition-duration: 0.75s; -} -.m-btn.primary { - background-color: var(--primary-color); - color: var(--primary-color-invert); -} -.m-btn.thin-border { border-width: 1px; } -.m-btn.large { padding:8px 14px; } -.m-btn.small { padding:5px 12px; } -.m-btn.tiny { padding:5px 6px; } -.m-btn.circle { border-radius: 50%; } -.m-btn:hover { - background-color: var(--primary-color); - color: var(--primary-color-invert); -} -.m-btn.nav { border: 2px solid var(--nav-accent-color); } -.m-btn.nav:hover { - background-color: var(--nav-accent-color); -} -.m-btn:disabled { - background-color: var(--bg3); - color: var(--fg3); - border-color: var(--fg3); - cursor: not-allowed; - opacity: 0.4; -} -.m-btn:active { - filter: brightness(75%); - transform: scale(0.95); - transition:scale 0s; -} -.toolbar-btn { - cursor: pointer; - padding: 4px; - margin:0 2px; - font-size: var(--font-size-small); - min-width: 50px; - color: var(--primary-color-invert); - border-radius: 2px; - border: none; - background-color: var(--primary-color); -} - -input, textarea, select, button, pre { - color:var(--fg); - outline: none; - background-color: var(--input-bg); - border: 1px solid var(--border-color); - border-radius: var(--border-radius); -} -button { - font-family: var(--font-regular); -} - -/* Form Inputs */ -pre, -select, -textarea, -input[type="file"], -input[type="text"], -input[type="password"] { - font-family: var(--font-mono); - font-weight: 400; - font-size: var(--font-size-small); - transition: border .2s; - padding: 6px 5px; -} - -select { - font-family: var(--font-regular); - padding: 5px 30px 5px 5px; - background-image: url("data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2212%22%20height%3D%2212%22%3E%3Cpath%20d%3D%22M10.3%203.3L6%207.6%201.7%203.3A1%201%200%2000.3%204.7l5%205a1%201%200%20001.4%200l5-5a1%201%200%2010-1.4-1.4z%22%20fill%3D%22%23777777%22%2F%3E%3C%2Fsvg%3E"); - background-position: calc(100% - 5px) center; - background-repeat: no-repeat; - background-size: 10px; - -webkit-appearance: none; - -moz-appearance: none; - appearance: none; - cursor: pointer; -} - -select:hover { - border-color: var(--primary-color); -} - -textarea::placeholder, -input[type="text"]::placeholder, -input[type="password"]::placeholder { - color: var(--placeholder-color); - opacity:1; -} - - -input[type="file"]{ - font-family: var(--font-regular); - padding:2px; - cursor:pointer; - border: 1px solid var(--primary-color); - min-height: calc(var(--font-size-small) + 18px); -} - -input[type="file"]::-webkit-file-upload-button { - font-family: var(--font-regular); - font-size: var(--font-size-small); - outline: none; - cursor:pointer; - padding: 3px 8px; - border: 1px solid var(--primary-color); - background-color: var(--primary-color); - color: var(--primary-color-invert); - border-radius: var(--border-radius);; - -webkit-appearance: none; -} - -pre, -textarea { - scrollbar-width: thin; - scrollbar-color: var(--border-color) var(--input-bg); -} - -pre::-webkit-scrollbar, -textarea::-webkit-scrollbar { - width: 8px; - height: 8px; -} - -pre::-webkit-scrollbar-track, -textarea::-webkit-scrollbar-track { - background:var(--input-bg); -} - -pre::-webkit-scrollbar-thumb, -textarea::-webkit-scrollbar-thumb { - border-radius: 2px; - background-color: var(--border-color); -} - -.link { - font-size:var(--font-size-small); - text-decoration: underline; - color:var(--blue); - font-family:var(--font-mono); - margin-bottom:2px; -} - -/* Toggle Body */ -input[type="checkbox"] { - appearance: none; - display: inline-block; - background-color: var(--light-bg); - border: 1px solid var(--light-bg); - border-radius: 9px; - cursor: pointer; - height: 18px; - position: relative; - transition: border .25s .15s, box-shadow .25s .3s, padding .25s; - min-width: 36px; - width: 36px; - vertical-align: top; -} -/* Toggle Thumb */ -input[type="checkbox"]:after { - position: absolute; - background-color: var(--bg); - border: 1px solid var(--light-bg); - border-radius: 8px; - content: ''; - top: 0px; - left: 0px; - right: 16px; - display: block; - height: 16px; - transition: border .25s .15s, left .25s .1s, right .15s .175s; -} - -/* Toggle Body - Checked */ -input[type="checkbox"]:checked { - background-color: var(--green); - border-color: var(--green); -} -/* Toggle Thumb - Checked*/ -input[type="checkbox"]:checked:after { - border: 1px solid var(--green); - left: 16px; - right: 1px; - transition: border .25s, left .15s .25s, right .25s .175s; -}`,Eu=M` -.row, .col { - display:flex; -} -.row { - align-items:center; - flex-direction: row; -} -.col { - align-items:stretch; - flex-direction: column; -} -`,ju=M` -.m-table { - border-spacing: 0; - border-collapse: separate; - border: 1px solid var(--light-border-color); - border-radius: var(--border-radius); - margin: 0; - max-width: 100%; - direction: ltr; -} -.m-table tr:first-child td, -.m-table tr:first-child th { - border-top: 0 none; -} -.m-table td, -.m-table th { - font-size: var(--font-size-small); - line-height: calc(var(--font-size-small) + 4px); - padding: 4px 5px 4px; - vertical-align: top; -} - -.m-table.padded-12 td, -.m-table.padded-12 th { - padding: 12px; -} - -.m-table td:not([align]), -.m-table th:not([align]) { - text-align: left; -} - -.m-table th { - color: var(--fg2); - font-size: var(--font-size-small); - line-height: calc(var(--font-size-small) + 18px); - font-weight: 600; - letter-spacing: normal; - background-color: var(--bg2); - vertical-align: bottom; - border-bottom: 1px solid var(--light-border-color); -} - -.m-table > tbody > tr > td, -.m-table > tr > td { - border-top: 1px solid var(--light-border-color); - text-overflow: ellipsis; - overflow: hidden; -} -.table-title { - font-size:var(--font-size-small); - font-weight:bold; - vertical-align: middle; - margin: 12px 0 4px 0; -} -`,Fg=M` -:host { - container-type: inline-size; -} -.only-large-screen { display:none; } -.endpoint-head .path { - display: flex; - font-family:var(--font-mono); - font-size: var(--font-size-small); - align-items: center; - overflow-wrap: break-word; - word-break: break-all; -} - -.endpoint-head .descr { - font-size: var(--font-size-small); - color:var(--light-fg); - font-weight:400; - align-items: center; - overflow-wrap: break-word; - word-break: break-all; - display:none; -} - -.m-endpoint.expanded { margin-bottom:16px; } -.m-endpoint > .endpoint-head{ - border-width:1px 1px 1px 5px; - border-style:solid; - border-color:transparent; - border-top-color:var(--light-border-color); - display:flex; - padding:6px 16px; - align-items: center; - cursor: pointer; -} -.m-endpoint > .endpoint-head.put:hover, -.m-endpoint > .endpoint-head.put.expanded { - border-color:var(--orange); - background-color:var(--light-orange); -} -.m-endpoint > .endpoint-head.post:hover, -.m-endpoint > .endpoint-head.post.expanded { - border-color:var(--green); - background-color:var(--light-green); -} -.m-endpoint > .endpoint-head.get:hover, -.m-endpoint > .endpoint-head.get.expanded { - border-color:var(--blue); - background-color:var(--light-blue); -} -.m-endpoint > .endpoint-head.delete:hover, -.m-endpoint > .endpoint-head.delete.expanded { - border-color:var(--red); - background-color:var(--light-red); -} - -.m-endpoint > .endpoint-head.head:hover, -.m-endpoint > .endpoint-head.head.expanded, -.m-endpoint > .endpoint-head.patch:hover, -.m-endpoint > .endpoint-head.patch.expanded, -.m-endpoint > .endpoint-head.options:hover, -.m-endpoint > .endpoint-head.options.expanded { - border-color:var(--yellow); - background-color:var(--light-yellow); -} - -.m-endpoint > .endpoint-head.deprecated:hover, -.m-endpoint > .endpoint-head.deprecated.expanded { - border-color:var(--border-color); - filter:opacity(0.6); -} - -.m-endpoint .endpoint-body { - flex-wrap:wrap; - padding:16px 0px 0 0px; - border-width:0px 1px 1px 5px; - border-style:solid; - box-shadow: 0px 4px 3px -3px rgba(0, 0, 0, 0.15); -} -.m-endpoint .endpoint-body.delete{ border-color:var(--red); } -.m-endpoint .endpoint-body.put{ border-color:var(--orange); } -.m-endpoint .endpoint-body.post { border-color:var(--green); } -.m-endpoint .endpoint-body.get { border-color:var(--blue); } -.m-endpoint .endpoint-body.head, -.m-endpoint .endpoint-body.patch, -.m-endpoint .endpoint-body.options { - border-color:var(--yellow); -} - -.m-endpoint .endpoint-body.deprecated { - border-color:var(--border-color); - filter:opacity(0.6); -} - -.endpoint-head .deprecated { - color: var(--light-fg); - filter:opacity(0.6); -} - -.summary{ - padding:8px 8px; -} -.summary .title { - font-size:calc(var(--font-size-regular) + 2px); - margin-bottom: 6px; - word-break: break-all; -} - -.endpoint-head .method { - padding:2px 5px; - vertical-align: middle; - font-size:var(--font-size-small); - height: calc(var(--font-size-small) + 16px); - line-height: calc(var(--font-size-small) + 8px); - width: 60px; - border-radius: 2px; - display:inline-block; - text-align: center; - font-weight: bold; - text-transform:uppercase; - margin-right:5px; -} -.endpoint-head .method.delete{ border: 2px solid var(--red);} -.endpoint-head .method.put{ border: 2px solid var(--orange); } -.endpoint-head .method.post{ border: 2px solid var(--green); } -.endpoint-head .method.get{ border: 2px solid var(--blue); } -.endpoint-head .method.get.deprecated{ border: 2px solid var(--border-color); } -.endpoint-head .method.head, -.endpoint-head .method.patch, -.endpoint-head .method.options { - border: 2px solid var(--yellow); -} - -.req-resp-container { - display: flex; - margin-top:16px; - align-items: stretch; - flex-wrap: wrap; - flex-direction: column; - border-top:1px solid var(--light-border-color); -} - -.view-mode-request, -api-response.view-mode { - flex:1; - min-height:100px; - padding:16px 8px; - overflow:hidden; -} -.view-mode-request { - border-width:0 0 1px 0; - border-style:dashed; -} - -.head .view-mode-request, -.patch .view-mode-request, -.options .view-mode-request { - border-color:var(--yellow); -} -.put .view-mode-request { - border-color:var(--orange); -} -.post .view-mode-request { - border-color:var(--green); -} -.get .view-mode-request { - border-color:var(--blue); -} -.delete .view-mode-request { - border-color:var(--red); -} - -@container (min-width: 1024px) { - .only-large-screen { display:block; } - .endpoint-head .path{ - font-size: var(--font-size-regular); - } - .endpoint-head .descr{ - display: flex; - } - .endpoint-head .m-markdown-small, - .descr .m-markdown-small{ - display:block; - } - .req-resp-container{ - flex-direction: var(--layout, row); - flex-wrap: nowrap; - } - api-response.view-mode { - padding:16px; - } - .view-mode-request.row-layout { - border-width:0 1px 0 0; - padding:16px; - } - .summary{ - padding:8px 16px; - } -} -`,pc=M` -code[class*="language-"], -pre[class*="language-"] { - text-align: left; - white-space: pre; - word-spacing: normal; - word-break: normal; - word-wrap: normal; - line-height: 1.5; - tab-size: 2; - - -webkit-hyphens: none; - -moz-hyphens: none; - -ms-hyphens: none; - hyphens: none; -} - -/* Code blocks */ -pre[class*="language-"] { - padding: 1em; - margin: .5em 0; - overflow: auto; -} - -/* Inline code */ -:not(pre) > code[class*="language-"] { - white-space: normal; -} - -.token.comment, -.token.block-comment, -.token.prolog, -.token.doctype, -.token.cdata { - color: var(--light-fg) -} - -.token.punctuation { - color: var(--fg); -} - -.token.tag, -.token.attr-name, -.token.namespace, -.token.deleted { - color:var(--pink); -} - -.token.function-name { - color: var(--blue); -} - -.token.boolean, -.token.number, -.token.function { - color: var(--red); -} - -.token.property, -.token.class-name, -.token.constant, -.token.symbol { - color: var(--code-property-color); -} - -.token.selector, -.token.important, -.token.atrule, -.token.keyword, -.token.builtin { - color: var(--code-keyword-color); -} - -.token.string, -.token.char, -.token.attr-value, -.token.regex, -.token.variable { - color: var(--green); -} - -.token.operator, -.token.entity, -.token.url { - color: var(--code-operator-color); -} - -.token.important, -.token.bold { - font-weight: bold; -} -.token.italic { - font-style: italic; -} - -.token.entity { - cursor: help; -} - -.token.inserted { - color: green; -} -`,dl=M` -.tab-panel { - border: none; -} -.tab-buttons { - height:30px; - padding: 4px 4px 0 4px; - border-bottom: 1px solid var(--light-border-color) ; - align-items: stretch; - overflow-y: hidden; - overflow-x: auto; - scrollbar-width: thin; -} -.tab-buttons::-webkit-scrollbar { - height: 1px; - background-color: var(--border-color); -} -.tab-btn { - border: none; - border-bottom: 3px solid transparent; - color: var(--light-fg); - background-color: transparent; - white-space: nowrap; - cursor:pointer; - outline:none; - font-family:var(--font-regular); - font-size:var(--font-size-small); - margin-right:16px; - padding:1px; -} -.tab-btn.active { - border-bottom: 3px solid var(--primary-color); - font-weight:bold; - color:var(--primary-color); -} - -.tab-btn:hover { - color:var(--primary-color); -} -.tab-content { - margin:-1px 0 0 0; - position:relative; - min-height: 50px; -} -`,va=M` -.nav-bar-info:focus-visible, -.nav-bar-tag:focus-visible, -.nav-bar-path:focus-visible { - outline: 1px solid; - box-shadow: none; - outline-offset: -4px; -} -.nav-bar-expand-all:focus-visible, -.nav-bar-collapse-all:focus-visible, -.nav-bar-tag-icon:focus-visible { - outline: 1px solid; - box-shadow: none; - outline-offset: 2px; -} -.nav-bar { - width:0; - height:100%; - overflow: hidden; - color:var(--nav-text-color); - background-color: var(--nav-bg-color); - background-blend-mode: multiply; - line-height: calc(var(--font-size-small) + 4px); - display:none; - position:relative; - flex-direction:column; - flex-wrap:nowrap; - word-break:break-word; -} -::slotted([slot=nav-logo]) { - padding:16px 16px 0 16px; -} -.nav-scroll { - overflow-x: hidden; - overflow-y: auto; - overflow-y: overlay; - scrollbar-width: thin; - scrollbar-color: var(--nav-hover-bg-color) transparent; -} - -.nav-bar-tag { - display: flex; - align-items: center; - justify-content: space-between; - flex-direction: row; -} -.nav-bar.read .nav-bar-tag-icon { - display:none; -} -.nav-bar-paths-under-tag { - overflow:hidden; - transition: max-height .2s ease-out, visibility .3s; -} -.collapsed .nav-bar-paths-under-tag { - visibility: hidden; -} - -.nav-bar-expand-all { - transform: rotate(90deg); - cursor:pointer; - margin-right:10px; -} -.nav-bar-collapse-all { - transform: rotate(270deg); - cursor:pointer; -} -.nav-bar-expand-all:hover, .nav-bar-collapse-all:hover { - color: var(--primary-color); -} - -.nav-bar-tag-icon { - color: var(--nav-text-color); - font-size: 20px; -} -.nav-bar-tag-icon:hover { - color:var(--nav-hover-text-color); -} -.nav-bar.focused .nav-bar-tag-and-paths.collapsed .nav-bar-tag-icon::after { - content: '⌵'; - width:16px; - height:16px; - text-align: center; - display: inline-block; - transform: rotate(-90deg); - transition: transform 0.2s ease-out 0s; -} -.nav-bar.focused .nav-bar-tag-and-paths.expanded .nav-bar-tag-icon::after { - content: '⌵'; - width:16px; - height:16px; - text-align: center; - display: inline-block; - transition: transform 0.2s ease-out 0s; -} -.nav-scroll::-webkit-scrollbar { - width: var(--scroll-bar-width, 8px); -} -.nav-scroll::-webkit-scrollbar-track { - background:transparent; -} -.nav-scroll::-webkit-scrollbar-thumb { - background-color: var(--nav-hover-bg-color); -} - -.nav-bar-tag { - font-size: var(--font-size-regular); - color: var(--nav-accent-color); - border-left:4px solid transparent; - font-weight:bold; - padding: 15px 15px 15px 10px; - text-transform: capitalize; -} - -.nav-bar-components, -.nav-bar-h1, -.nav-bar-h2, -.nav-bar-info, -.nav-bar-tag, -.nav-bar-path { - display:flex; - cursor: pointer; - width: 100%; - border: none; - border-radius:4px; - color: var(--nav-text-color); - background: transparent; - border-left:4px solid transparent; -} - -.nav-bar-h1, -.nav-bar-h2, -.nav-bar-path { - font-size: calc(var(--font-size-small) + 1px); - padding: var(--nav-item-padding); -} -.nav-bar-path.small-font { - font-size: var(--font-size-small); -} - -.nav-bar-info { - font-size: var(--font-size-regular); - padding: 16px 10px; - font-weight:bold; -} -.nav-bar-section { - display: flex; - flex-direction: row; - justify-content: space-between; - font-size: var(--font-size-small); - color: var(--nav-text-color); - padding: var(--nav-item-padding); - font-weight:bold; -} -.nav-bar-section.operations { - cursor:pointer; -} -.nav-bar-section.operations:hover { - color:var(--nav-hover-text-color); - background-color:var(--nav-hover-bg-color); -} - -.nav-bar-section:first-child { - display: none; -} -.nav-bar-h2 {margin-left:12px;} - -.nav-bar-h1.left-bar.active, -.nav-bar-h2.left-bar.active, -.nav-bar-info.left-bar.active, -.nav-bar-tag.left-bar.active, -.nav-bar-path.left-bar.active, -.nav-bar-section.left-bar.operations.active { - border-left:4px solid var(--nav-accent-color); - color:var(--nav-hover-text-color); -} - -.nav-bar-h1.colored-block.active, -.nav-bar-h2.colored-block.active, -.nav-bar-info.colored-block.active, -.nav-bar-tag.colored-block.active, -.nav-bar-path.colored-block.active, -.nav-bar-section.colored-block.operations.active { - background-color: var(--nav-accent-color); - color: var(--nav-accent-text-color); - border-radius: 0; -} - -.nav-bar-h1:hover, -.nav-bar-h2:hover, -.nav-bar-info:hover, -.nav-bar-tag:hover, -.nav-bar-path:hover { - color:var(--nav-hover-text-color); - background-color:var(--nav-hover-bg-color); -} -`,Ws=M` -#api-info { - font-size: calc(var(--font-size-regular) - 1px); - margin-top: 8px; - margin-left: -15px; -} - -#api-info span:before { - content: "|"; - display: inline-block; - opacity: 0.5; - width: 15px; - text-align: center; -} -#api-info span:first-child:before { - content: ""; - width: 0px; -} -`,fc=M` - -`,eh=/[\s#:?&={}]/g,ho="_rapidoc_api_key";function Cu(t){return new Promise((n=>setTimeout(n,t)))}function hl(t,n){const i=n.target,l=document.createElement("textarea");l.value=t,l.style.position="fixed",document.body.appendChild(l),l.focus(),l.select();try{document.execCommand("copy"),i.innerText="Copied",setTimeout((()=>{i.innerText="Copy"}),5e3)}catch(h){console.error("Unable to copy",h)}document.body.removeChild(l)}function th(t,n,i=""){return`${n.method} ${n.path} ${n.summary||""} ${n.description||""} ${n.operationId||""} ${i}`.toLowerCase().includes(t.toLowerCase())}function Js(t,n=new Set){return t&&Object.keys(t).forEach((i=>{var l;if(n.add(i),t[i].properties)Js(t[i].properties,n);else if((l=t[i].items)!==null&&l!==void 0&&l.properties){var h;Js((h=t[i].items)===null||h===void 0?void 0:h.properties,n)}})),n}function Lp(t,n){if(t){const i=document.createElement("a");document.body.appendChild(i),i.style="display: none",i.href=t,i.download=n,i.click(),i.remove()}}function qg(t){if(t){const n=document.createElement("a");document.body.appendChild(n),n.style="display: none",n.href=t,n.target="_blank",n.click(),n.remove()}}const zp=Object.freeze({url:"/"}),{fetch:Au,Response:xw,Headers:bw,Request:Ou,FormData:tA,File:ww,Blob:Sw}=globalThis;function nh(t,n){return n||typeof navigator>"u"||(n=navigator),n&&n.product==="ReactNative"?!(!t||typeof t!="object"||typeof t.uri!="string"):typeof File<"u"&&t instanceof File||typeof Blob<"u"&&t instanceof Blob||!!ArrayBuffer.isView(t)||t!==null&&typeof t=="object"&&typeof t.pipe=="function"}function Ew(t,n){return Array.isArray(t)&&t.some((i=>nh(i,n)))}globalThis.fetch===void 0&&(globalThis.fetch=Au),globalThis.Headers===void 0&&(globalThis.Headers=bw),globalThis.Request===void 0&&(globalThis.Request=Ou),globalThis.Response===void 0&&(globalThis.Response=xw),globalThis.FormData===void 0&&(globalThis.FormData=tA),globalThis.File===void 0&&(globalThis.File=ww),globalThis.Blob===void 0&&(globalThis.Blob=Sw);class Bg extends File{constructor(n,i="",l={}){super([n],i,l),this.data=n}valueOf(){return this.data}toString(){return this.valueOf()}}function rh(t,n="reserved"){return[...t].map((i=>{if((h=>/^[a-z0-9\-._~]+$/i.test(h))(i)||(h=>":/?#[]@!$&'()*+,;=".indexOf(h)>-1)(i)&&n==="unsafe")return i;const l=new TextEncoder;return Array.from(l.encode(i)).map((h=>`0${h.toString(16).toUpperCase()}`.slice(-2))).map((h=>`%${h}`)).join("")})).join("")}function xa(t){const{value:n}=t;return Array.isArray(n)?(function({key:i,value:l,style:h,explode:v,escape:x}){if(h==="simple")return l.map((w=>is(w,x))).join(",");if(h==="label")return`.${l.map((w=>is(w,x))).join(".")}`;if(h==="matrix")return l.map((w=>is(w,x))).reduce(((w,C)=>!w||v?`${w||""};${i}=${C}`:`${w},${C}`),"");if(h==="form"){const w=v?`&${i}=`:",";return l.map((C=>is(C,x))).join(w)}if(h==="spaceDelimited"){const w=v?`${i}=`:"";return l.map((C=>is(C,x))).join(` ${w}`)}if(h==="pipeDelimited"){const w=v?`${i}=`:"";return l.map((C=>is(C,x))).join(`|${w}`)}})(t):typeof n=="object"?(function({key:i,value:l,style:h,explode:v,escape:x}){const w=Object.keys(l);return h==="simple"?w.reduce(((C,$)=>{const N=is(l[$],x);return`${C?`${C},`:""}${$}${v?"=":","}${N}`}),""):h==="label"?w.reduce(((C,$)=>{const N=is(l[$],x);return`${C?`${C}.`:"."}${$}${v?"=":"."}${N}`}),""):h==="matrix"&&v?w.reduce(((C,$)=>`${C?`${C};`:";"}${$}=${is(l[$],x)}`),""):h==="matrix"?w.reduce(((C,$)=>{const N=is(l[$],x);return`${C?`${C},`:`;${i}=`}${$},${N}`}),""):h==="form"?w.reduce(((C,$)=>{const N=is(l[$],x);return`${C?`${C}${v?"&":","}`:""}${$}${v?"=":","}${N}`}),""):void 0})(t):(function({key:i,value:l,style:h,escape:v}){return h==="simple"?is(l,v):h==="label"?`.${is(l,v)}`:h==="matrix"?`;${i}=${is(l,v)}`:h==="form"||h==="deepObject"?is(l,v):void 0})(t)}function is(t,n=!1){return Array.isArray(t)||t!==null&&typeof t=="object"?t=JSON.stringify(t):typeof t!="number"&&typeof t!="boolean"||(t=String(t)),n&&t.length>0?rh(t,n):t}const Ug={form:",",spaceDelimited:"%20",pipeDelimited:"|"},ku={csv:",",ssv:"%20",tsv:"%09",pipes:"|"};function mc(t,n,i=!1){const{collectionFormat:l,allowEmptyValue:h,serializationOption:v,encoding:x}=n,w=typeof n!="object"||Array.isArray(n)?n:n.value,C=i?N=>N.toString():N=>encodeURIComponent(N),$=C(t);if(w===void 0&&h)return[[$,""]];if(nh(w)||Ew(w))return[[$,w]];if(v)return Kg(t,w,i,v);if(x){if([typeof x.style,typeof x.explode,typeof x.allowReserved].some((N=>N!=="undefined"))){const{style:N,explode:_,allowReserved:F}=x;return Kg(t,w,i,{style:N,explode:_,allowReserved:F})}if(typeof x.contentType=="string"){if(x.contentType.startsWith("application/json")){const _=C(typeof w=="string"?w:JSON.stringify(w));return[[$,new Bg(_,"blob",{type:x.contentType})]]}const N=C(String(w));return[[$,new Bg(N,"blob",{type:x.contentType})]]}return typeof w!="object"?[[$,C(w)]]:Array.isArray(w)&&w.every((N=>typeof N!="object"))?[[$,w.map(C).join(",")]]:[[$,C(JSON.stringify(w))]]}return typeof w!="object"?[[$,C(w)]]:Array.isArray(w)?l==="multi"?[[$,w.map(C)]]:[[$,w.map(C).join(ku[l||"csv"])]]:[[$,""]]}function Kg(t,n,i,l){const h=l.style||"form",v=l.explode===void 0?h==="form":l.explode,x=!i&&(l&&l.allowReserved?"unsafe":"reserved"),w=$=>is($,x),C=i?$=>$:$=>w($);return typeof n!="object"?[[C(t),w(n)]]:Array.isArray(n)?v?[[C(t),n.map(w)]]:[[C(t),n.map(w).join(Ug[h])]]:h==="deepObject"?Object.keys(n).map(($=>[C(`${t}[${$}]`),w(n[$])])):v?Object.keys(n).map(($=>[C($),w(n[$])])):[[C(t),Object.keys(n).map(($=>[`${C($)},${w(n[$])}`])).join(",")]]}function Fp(t){return((n,{encode:i=!0}={})=>{const l=(x,w,C)=>(C==null?x.append(w,""):Array.isArray(C)?C.reduce((($,N)=>l(x,w,N)),x):C instanceof Date?x.append(w,C.toISOString()):typeof C=="object"?Object.entries(C).reduce((($,[N,_])=>l(x,`${w}[${N}]`,_)),x):x.append(w,C),x),h=Object.entries(n).reduce(((x,[w,C])=>l(x,w,C)),new URLSearchParams),v=String(h);return i?v:decodeURIComponent(v)})(Object.keys(t).reduce(((n,i)=>{for(const[l,h]of mc(i,t[i]))n[l]=h instanceof Bg?h.valueOf():h;return n}),{}),{encode:!1})}function qp(t={}){const{url:n="",query:i,form:l}=t;if(l){const v=Object.keys(l).some((w=>{const{value:C}=l[w];return nh(C)||Ew(C)})),x=t.headers["content-type"]||t.headers["Content-Type"];if(v||/multipart\/form-data/i.test(x)){const w=(h=t.form,Object.entries(h).reduce(((C,[$,N])=>{for(const[_,F]of mc($,N,!0))if(Array.isArray(F))for(const U of F)if(ArrayBuffer.isView(U)){const J=new Blob([U]);C.append(_,J)}else C.append(_,U);else if(ArrayBuffer.isView(F)){const U=new Blob([F]);C.append(_,U)}else C.append(_,F);return C}),new FormData));t.formdata=w,t.body=w}else t.body=Fp(l);delete t.form}var h;if(i){const[v,x]=n.split("?");let w="";if(x){const $=new URLSearchParams(x);Object.keys(i).forEach((N=>$.delete(N))),w=String($)}const C=((...$)=>{const N=$.filter((_=>_)).join("&");return N?`?${N}`:""})(w,Fp(i));t.url=v+C,delete t.query}return t}function Ru(t){return t==null}var ar={isNothing:Ru,isObject:function(t){return typeof t=="object"&&t!==null},toArray:function(t){return Array.isArray(t)?t:Ru(t)?[]:[t]},repeat:function(t,n){var i,l="";for(i=0;iw&&(n=l-w+(v=" ... ").length),i-l>w&&(i=l+w-(x=" ...").length),{str:v+t.slice(n,i).replace(/\t/g,"→")+x,pos:l-n+v.length}}function Tu(t,n){return ar.repeat(" ",n-t.length)+t}var jw=function(t,n){if(n=Object.create(n||null),!t.buffer)return null;n.maxLength||(n.maxLength=79),typeof n.indent!="number"&&(n.indent=1),typeof n.linesBefore!="number"&&(n.linesBefore=3),typeof n.linesAfter!="number"&&(n.linesAfter=2);for(var i,l=/\r?\n|\r|\0/g,h=[0],v=[],x=-1;i=l.exec(t.buffer);)v.push(i.index),h.push(i.index+i[0].length),t.position<=i.index&&x<0&&(x=h.length-2);x<0&&(x=h.length-1);var w,C,$="",N=Math.min(t.line+n.linesAfter,v.length).toString().length,_=n.maxLength-(n.indent+N+3);for(w=1;w<=n.linesBefore&&!(x-w<0);w++)C=sh(t.buffer,h[x-w],v[x-w],t.position-(h[x]-h[x-w]),_),$=ar.repeat(" ",n.indent)+Tu((t.line-w+1).toString(),N)+" | "+C.str+` -`+$;for(C=sh(t.buffer,h[x],v[x],t.position,_),$+=ar.repeat(" ",n.indent)+Tu((t.line+1).toString(),N)+" | "+C.str+` -`,$+=ar.repeat("-",n.indent+N+3+C.pos)+`^ -`,w=1;w<=n.linesAfter&&!(x+w>=v.length);w++)C=sh(t.buffer,h[x+w],v[x+w],t.position-(h[x]-h[x+w]),_),$+=ar.repeat(" ",n.indent)+Tu((t.line+w+1).toString(),N)+" | "+C.str+` -`;return $.replace(/\n$/,"")},Up=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],Kp=["scalar","sequence","mapping"],as=function(t,n){if(n=n||{},Object.keys(n).forEach((function(i){if(Up.indexOf(i)===-1)throw new Rr('Unknown option "'+i+'" is met in definition of "'+t+'" YAML type.')})),this.options=n,this.tag=t,this.kind=n.kind||null,this.resolve=n.resolve||function(){return!0},this.construct=n.construct||function(i){return i},this.instanceOf=n.instanceOf||null,this.predicate=n.predicate||null,this.represent=n.represent||null,this.representName=n.representName||null,this.defaultStyle=n.defaultStyle||null,this.multi=n.multi||!1,this.styleAliases=(function(i){var l={};return i!==null&&Object.keys(i).forEach((function(h){i[h].forEach((function(v){l[String(v)]=h}))})),l})(n.styleAliases||null),Kp.indexOf(this.kind)===-1)throw new Rr('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')};function Ms(t,n){var i=[];return t[n].forEach((function(l){var h=i.length;i.forEach((function(v,x){v.tag===l.tag&&v.kind===l.kind&&v.multi===l.multi&&(h=x)})),i[h]=l})),i}function fo(t){return this.extend(t)}fo.prototype.extend=function(t){var n=[],i=[];if(t instanceof as)i.push(t);else if(Array.isArray(t))i=i.concat(t);else{if(!t||!Array.isArray(t.implicit)&&!Array.isArray(t.explicit))throw new Rr("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");t.implicit&&(n=n.concat(t.implicit)),t.explicit&&(i=i.concat(t.explicit))}n.forEach((function(h){if(!(h instanceof as))throw new Rr("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(h.loadKind&&h.loadKind!=="scalar")throw new Rr("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(h.multi)throw new Rr("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")})),i.forEach((function(h){if(!(h instanceof as))throw new Rr("Specified list of YAML types (or a single Type object) contains a non-Type object.")}));var l=Object.create(fo.prototype);return l.implicit=(this.implicit||[]).concat(n),l.explicit=(this.explicit||[]).concat(i),l.compiledImplicit=Ms(l,"implicit"),l.compiledExplicit=Ms(l,"explicit"),l.compiledTypeMap=(function(){var h,v,x={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function w(C){C.multi?(x.multi[C.kind].push(C),x.multi.fallback.push(C)):x[C.kind][C.tag]=x.fallback[C.tag]=C}for(h=0,v=arguments.length;h=0?"0b"+t.toString(2):"-0b"+t.toString(2).slice(1)},octal:function(t){return t>=0?"0o"+t.toString(8):"-0o"+t.toString(8).slice(1)},decimal:function(t){return t.toString(10)},hexadecimal:function(t){return t>=0?"0x"+t.toString(16).toUpperCase():"-0x"+t.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),rA=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),Vg=/^[-+]?[0-9]+e/,kw=new as("tag:yaml.org,2002:float",{kind:"scalar",resolve:function(t){return t!==null&&!(!rA.test(t)||t[t.length-1]==="_")},construct:function(t){var n,i;return i=(n=t.replace(/_/g,"").toLowerCase())[0]==="-"?-1:1,"+-".indexOf(n[0])>=0&&(n=n.slice(1)),n===".inf"?i===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:n===".nan"?NaN:i*parseFloat(n,10)},predicate:function(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!=0||ar.isNegativeZero(t))},represent:function(t,n){var i;if(isNaN(t))switch(n){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===t)switch(n){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===t)switch(n){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(ar.isNegativeZero(t))return"-0.0";return i=t.toString(10),Vg.test(i)?i.replace("e",".e"):i},defaultStyle:"lowercase"}),Rw=Hp.extend({implicit:[$u,ah,Ow,kw]}),Tw=Rw,_w=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),$w=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$"),Hg=new as("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:function(t){return t!==null&&(_w.exec(t)!==null||$w.exec(t)!==null)},construct:function(t){var n,i,l,h,v,x,w,C,$=0,N=null;if((n=_w.exec(t))===null&&(n=$w.exec(t)),n===null)throw new Error("Date resolve error");if(i=+n[1],l=+n[2]-1,h=+n[3],!n[4])return new Date(Date.UTC(i,l,h));if(v=+n[4],x=+n[5],w=+n[6],n[7]){for($=n[7].slice(0,3);$.length<3;)$+="0";$=+$}return n[9]&&(N=6e4*(60*+n[10]+ +(n[11]||0)),n[9]==="-"&&(N=-N)),C=new Date(Date.UTC(i,l,h,v,x,w,$)),N&&C.setTime(C.getTime()-N),C},instanceOf:Date,represent:function(t){return t.toISOString()}}),Nw=new as("tag:yaml.org,2002:merge",{kind:"scalar",resolve:function(t){return t==="<<"||t===null}}),Gg=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= -\r`,Dw=new as("tag:yaml.org,2002:binary",{kind:"scalar",resolve:function(t){if(t===null)return!1;var n,i,l=0,h=t.length,v=Gg;for(i=0;i64)){if(n<0)return!1;l+=6}return l%8==0},construct:function(t){var n,i,l=t.replace(/[\r\n=]/g,""),h=l.length,v=Gg,x=0,w=[];for(n=0;n>16&255),w.push(x>>8&255),w.push(255&x)),x=x<<6|v.indexOf(l.charAt(n));return(i=h%4*6)==0?(w.push(x>>16&255),w.push(x>>8&255),w.push(255&x)):i===18?(w.push(x>>10&255),w.push(x>>2&255)):i===12&&w.push(x>>4&255),new Uint8Array(w)},predicate:function(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"},represent:function(t){var n,i,l="",h=0,v=t.length,x=Gg;for(n=0;n>18&63],l+=x[h>>12&63],l+=x[h>>6&63],l+=x[63&h]),h=(h<<8)+t[n];return(i=v%3)==0?(l+=x[h>>18&63],l+=x[h>>12&63],l+=x[h>>6&63],l+=x[63&h]):i===2?(l+=x[h>>10&63],l+=x[h>>4&63],l+=x[h<<2&63],l+=x[64]):i===1&&(l+=x[h>>2&63],l+=x[h<<4&63],l+=x[64],l+=x[64]),l}}),sA=Object.prototype.hasOwnProperty,Xg=Object.prototype.toString,Pw=new as("tag:yaml.org,2002:omap",{kind:"sequence",resolve:function(t){if(t===null)return!0;var n,i,l,h,v,x=[],w=t;for(n=0,i=w.length;n>10),56320+(t-65536&1023))}for(var Wg=new Array(256),yc=new Array(256),Nu=0;Nu<256;Nu++)Wg[Nu]=Zg(Nu)?1:0,yc[Nu]=Zg(Nu);function cA(t,n){this.input=t,this.filename=n.filename||null,this.schema=n.schema||Yg,this.onWarning=n.onWarning||null,this.legacy=n.legacy||!1,this.json=n.json||!1,this.listener=n.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function Kw(t,n){var i={name:t.filename,buffer:t.input.slice(0,-1),position:t.position,line:t.line,column:t.position-t.lineStart};return i.snippet=jw(i),new Rr(n,i)}function Bt(t,n){throw Kw(t,n)}function oh(t,n){t.onWarning&&t.onWarning.call(null,Kw(t,n))}var Du={YAML:function(t,n,i){var l,h,v;t.version!==null&&Bt(t,"duplication of %YAML directive"),i.length!==1&&Bt(t,"YAML directive accepts exactly one argument"),(l=/^([0-9]+)\.([0-9]+)$/.exec(i[0]))===null&&Bt(t,"ill-formed argument of the YAML directive"),h=parseInt(l[1],10),v=parseInt(l[2],10),h!==1&&Bt(t,"unacceptable YAML version of the document"),t.version=i[0],t.checkLineBreaks=v<2,v!==1&&v!==2&&oh(t,"unsupported YAML version of the document")},TAG:function(t,n,i){var l,h;i.length!==2&&Bt(t,"TAG directive accepts exactly two arguments"),l=i[0],h=i[1],zw.test(l)||Bt(t,"ill-formed tag handle (first argument) of the TAG directive"),pl.call(t.tagMap,l)&&Bt(t,'there is a previously declared suffix for "'+l+'" tag handle'),Fw.test(h)||Bt(t,"ill-formed tag prefix (second argument) of the TAG directive");try{h=decodeURIComponent(h)}catch{Bt(t,"tag prefix is malformed: "+h)}t.tagMap[l]=h}};function Xi(t,n,i,l){var h,v,x,w;if(n1&&(t.result+=ar.repeat(` -`,n-1))}function Jg(t,n){var i,l,h=t.tag,v=t.anchor,x=[],w=!1;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=x),l=t.input.charCodeAt(t.position);l!==0&&(t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,Bt(t,"tab characters must not be used in indentation")),l===45)&&Qs(t.input.charCodeAt(t.position+1));)if(w=!0,t.position++,Nr(t,!0,-1)&&t.lineIndent<=n)x.push(null),l=t.input.charCodeAt(t.position);else if(i=t.line,Mu(t,n,3,!1,!0),x.push(t.result),Nr(t,!0,-1),l=t.input.charCodeAt(t.position),(t.line===i||t.lineIndent>n)&&l!==0)Bt(t,"bad indentation of a sequence entry");else if(t.lineIndentn?J=1:t.lineIndent===n?J=0:t.lineIndentn?J=1:t.lineIndent===n?J=0:t.lineIndentse)&&(Tt&&(Te=P.line,Ae=P.lineStart,qe=P.position),Mu(P,se,4,!0,ge)&&(Tt?qt=P.result:kn=P.result),Tt||(mo(P,Ie,Qe,ct,qt,kn,Te,Ae,qe),ct=qt=kn=null),Nr(P,!0,-1),Se=P.input.charCodeAt(P.position)),(P.line===pe||P.lineIndent>se)&&Se!==0)Bt(P,"bad indentation of a mapping entry");else if(P.lineIndent=0))break;ge===0?Bt(P,"bad explicit indentation width of a block scalar; it cannot be less than one"):Se?Bt(P,"repeat of an indentation width identifier"):(me=se+ge-1,Se=!0)}if(ba(pe)){do pe=P.input.charCodeAt(++P.position);while(ba(pe));if(pe===35)do pe=P.input.charCodeAt(++P.position);while(!Gi(pe)&&pe!==0)}for(;pe!==0;){for(Gp(P),P.lineIndent=0,pe=P.input.charCodeAt(P.position);(!Se||P.lineIndentme&&(me=P.lineIndent),Gi(pe))Me++;else{if(P.lineIndent0){for(ge=Te,pe=0;ge>0;ge--)(Te=Bw(Ae=P.input.charCodeAt(++P.position)))>=0?pe=(pe<<4)+Te:Bt(P,"expected hexadecimal character");P.result+=Uw(pe),P.position++}else Bt(P,"unknown escape sequence");ae=he=P.position}else Gi(Ae)?(Xi(P,ae,he,!0),lh(P,Nr(P,!1,se)),ae=he=P.position):P.position===P.lineStart&&Pu(P)?Bt(P,"unexpected end of the document within a double quoted scalar"):(P.position++,he=P.position)}Bt(P,"unexpected end of the stream within a double quoted scalar")})(t,F)?W=!0:(function(P){var se,ae,he;if((he=P.input.charCodeAt(P.position))!==42)return!1;for(he=P.input.charCodeAt(++P.position),se=P.position;he!==0&&!Qs(he)&&!gc(he);)he=P.input.charCodeAt(++P.position);return P.position===se&&Bt(P,"name of an alias node must contain at least one character"),ae=P.input.slice(se,P.position),pl.call(P.anchorMap,ae)||Bt(P,'unidentified alias "'+ae+'"'),P.result=P.anchorMap[ae],Nr(P,!0,-1),!0})(t)?(W=!0,t.tag===null&&t.anchor===null||Bt(t,"alias node should not have any properties")):(function(P,se,ae){var he,ge,pe,Te,Ae,qe,Se,me,Me=P.kind,Ie=P.result;if(Qs(me=P.input.charCodeAt(P.position))||gc(me)||me===35||me===38||me===42||me===33||me===124||me===62||me===39||me===34||me===37||me===64||me===96||(me===63||me===45)&&(Qs(he=P.input.charCodeAt(P.position+1))||ae&&gc(he)))return!1;for(P.kind="scalar",P.result="",ge=pe=P.position,Te=!1;me!==0;){if(me===58){if(Qs(he=P.input.charCodeAt(P.position+1))||ae&&gc(he))break}else if(me===35){if(Qs(P.input.charCodeAt(P.position-1)))break}else{if(P.position===P.lineStart&&Pu(P)||ae&&gc(me))break;if(Gi(me)){if(Ae=P.line,qe=P.lineStart,Se=P.lineIndent,Nr(P,!1,-1),P.lineIndent>=se){Te=!0,me=P.input.charCodeAt(P.position);continue}P.position=pe,P.line=Ae,P.lineStart=qe,P.lineIndent=Se;break}}Te&&(Xi(P,ge,pe,!1),lh(P,P.line-Ae),ge=pe=P.position,Te=!1),ba(me)||(pe=P.position+1),me=P.input.charCodeAt(++P.position)}return Xi(P,ge,pe,!1),!!P.result||(P.kind=Me,P.result=Ie,!1)})(t,F,i===1)&&(W=!0,t.tag===null&&(t.tag="?")),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):J===0&&(W=w&&Jg(t,U))),t.tag===null)t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);else if(t.tag==="?"){for(t.result!==null&&t.kind!=="scalar"&&Bt(t,'unacceptable node kind for ! tag; it should be "scalar", not "'+t.kind+'"'),C=0,$=t.implicitTypes.length;C<$;C+=1)if((_=t.implicitTypes[C]).resolve(t.result)){t.result=_.construct(t.result),t.tag=_.tag,t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);break}}else if(t.tag!=="!"){if(pl.call(t.typeMap[t.kind||"fallback"],t.tag))_=t.typeMap[t.kind||"fallback"][t.tag];else for(_=null,C=0,$=(N=t.typeMap.multi[t.kind||"fallback"]).length;C<$;C+=1)if(t.tag.slice(0,N[C].tag.length)===N[C].tag){_=N[C];break}_||Bt(t,"unknown tag !<"+t.tag+">"),t.result!==null&&_.kind!==t.kind&&Bt(t,"unacceptable node kind for !<"+t.tag+'> tag; it should be "'+_.kind+'", not "'+t.kind+'"'),_.resolve(t.result,t.tag)?(t.result=_.construct(t.result,t.tag),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):Bt(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||W}function uA(t){var n,i,l,h,v=t.position,x=!1;for(t.version=null,t.checkLineBreaks=t.legacy,t.tagMap=Object.create(null),t.anchorMap=Object.create(null);(h=t.input.charCodeAt(t.position))!==0&&(Nr(t,!0,-1),h=t.input.charCodeAt(t.position),!(t.lineIndent>0||h!==37));){for(x=!0,h=t.input.charCodeAt(++t.position),n=t.position;h!==0&&!Qs(h);)h=t.input.charCodeAt(++t.position);for(l=[],(i=t.input.slice(n,t.position)).length<1&&Bt(t,"directive name must not be less than one character in length");h!==0;){for(;ba(h);)h=t.input.charCodeAt(++t.position);if(h===35){do h=t.input.charCodeAt(++t.position);while(h!==0&&!Gi(h));break}if(Gi(h))break;for(n=t.position;h!==0&&!Qs(h);)h=t.input.charCodeAt(++t.position);l.push(t.input.slice(n,t.position))}h!==0&&Gp(t),pl.call(Du,i)?Du[i](t,i,l):oh(t,'unknown document directive "'+i+'"')}Nr(t,!0,-1),t.lineIndent===0&&t.input.charCodeAt(t.position)===45&&t.input.charCodeAt(t.position+1)===45&&t.input.charCodeAt(t.position+2)===45?(t.position+=3,Nr(t,!0,-1)):x&&Bt(t,"directives end mark is expected"),Mu(t,t.lineIndent-1,4,!1,!0),Nr(t,!0,-1),t.checkLineBreaks&&oA.test(t.input.slice(v,t.position))&&oh(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&Pu(t)?t.input.charCodeAt(t.position)===46&&(t.position+=3,Nr(t,!0,-1)):t.position=55296&&l<=56319&&n+1=56320&&i<=57343?1024*(l-55296)+i-56320+65536:l}function vc(t){return/^\n* /.test(t)}function ty(t,n,i,l,h){t.dump=(function(){if(n.length===0)return t.quotingType===2?'""':"''";if(!t.noCompatMode&&(Zw.indexOf(n)!==-1||Ww.test(n)))return t.quotingType===2?'"'+n+'"':"'"+n+"'";var v=t.indent*Math.max(1,i),x=t.lineWidth===-1?-1:Math.max(Math.min(t.lineWidth,40),t.lineWidth-v),w=l||t.flowLevel>-1&&i>=t.flowLevel;switch((function(C,$,N,_,F,U,J,Y){var W,P,se=0,ae=null,he=!1,ge=!1,pe=_!==-1,Te=-1,Ae=go(P=wa(C,0))&&P!==65279&&!Lu(P)&&P!==45&&P!==63&&P!==58&&P!==44&&P!==91&&P!==93&&P!==123&&P!==125&&P!==35&&P!==38&&P!==42&&P!==33&&P!==124&&P!==61&&P!==62&&P!==39&&P!==34&&P!==37&&P!==64&&P!==96&&(function(qe){return!Lu(qe)&&qe!==58})(wa(C,C.length-1));if($||J)for(W=0;W=65536?W+=2:W++){if(!go(se=wa(C,W)))return 5;Ae=Ae&&ey(se,ae,Y),ae=se}else{for(W=0;W=65536?W+=2:W++){if((se=wa(C,W))===10)he=!0,pe&&(ge=ge||W-Te-1>_&&C[Te+1]!==" ",Te=W);else if(!go(se))return 5;Ae=Ae&&ey(se,ae,Y),ae=se}ge=ge||pe&&W-Te-1>_&&C[Te+1]!==" "}return he||ge?N>9&&vc(C)?5:J?U===2?5:2:ge?4:3:!Ae||J||F(C)?U===2?5:2:1})(n,w,t.indent,x,(function(C){return(function($,N){var _,F;for(_=0,F=$.implicitTypes.length;_"+ny(n,t.indent)+ml(Qw((function(C,$){for(var N,_,F,U=/(\n+)([^\n]*)/g,J=(F=(F=C.indexOf(` -`))!==-1?F:C.length,U.lastIndex=F,ry(C.slice(0,F),$)),Y=C[0]===` -`||C[0]===" ";_=U.exec(C);){var W=_[1],P=_[2];N=P[0]===" ",J+=W+(Y||N||P===""?"":` -`)+ry(P,$),Y=N}return J})(n,x),v));case 5:return'"'+(function(C){for(var $,N="",_=0,F=0;F=65536?F+=2:F++)_=wa(C,F),!($=Yw[_])&&go(_)?(N+=C[F],_>=65536&&(N+=C[F+1])):N+=$||Jw(_);return N})(n)+'"';default:throw new Rr("impossible error: invalid scalar style")}})()}function ny(t,n){var i=vc(t)?String(n):"",l=t[t.length-1]===` -`;return i+(!l||t[t.length-2]!==` -`&&t!==` -`?l?"":"-":"+")+` -`}function ml(t){return t[t.length-1]===` -`?t.slice(0,-1):t}function ry(t,n){if(t===""||t[0]===" ")return t;for(var i,l,h=/ [^ ]/g,v=0,x=0,w=0,C="";i=h.exec(t);)(w=i.index)-v>n&&(l=x>v?x:w,C+=` -`+t.slice(v,l),v=l+1),x=w;return C+=` -`,t.length-v>n&&x>v?C+=t.slice(v,x)+` -`+t.slice(x+1):C+=t.slice(v),C.slice(1)}function sy(t,n,i,l){var h,v,x,w="",C=t.tag;for(h=0,v=i.length;h tag resolver accepts not "'+C+'" style');l=w.represent[C](n,C)}t.dump=l}return!0}return!1}function yo(t,n,i,l,h,v,x){t.tag=null,t.dump=i,iy(t,i,!1)||iy(t,i,!0);var w,C=ei.call(t.dump),$=l;l&&(l=t.flowLevel<0||t.flowLevel>n);var N,_,F=C==="[object Object]"||C==="[object Array]";if(F&&(_=(N=t.duplicates.indexOf(i))!==-1),(t.tag!==null&&t.tag!=="?"||_||t.indent!==2&&n>0)&&(h=!1),_&&t.usedDuplicates[N])t.dump="*ref_"+N;else{if(F&&_&&!t.usedDuplicates[N]&&(t.usedDuplicates[N]=!0),C==="[object Object]")l&&Object.keys(t.dump).length!==0?((function(U,J,Y,W){var P,se,ae,he,ge,pe,Te="",Ae=U.tag,qe=Object.keys(Y);if(U.sortKeys===!0)qe.sort();else if(typeof U.sortKeys=="function")qe.sort(U.sortKeys);else if(U.sortKeys)throw new Rr("sortKeys must be a boolean or a function");for(P=0,se=qe.length;P1024)&&(U.dump&&U.dump.charCodeAt(0)===10?pe+="?":pe+="? "),pe+=U.dump,ge&&(pe+=fl(U,J)),yo(U,J+1,he,!0,ge)&&(U.dump&&U.dump.charCodeAt(0)===10?pe+=":":pe+=": ",Te+=pe+=U.dump));U.tag=Ae,U.dump=Te||"{}"})(t,n,t.dump,h),_&&(t.dump="&ref_"+N+t.dump)):((function(U,J,Y){var W,P,se,ae,he,ge="",pe=U.tag,Te=Object.keys(Y);for(W=0,P=Te.length;W1024&&(he+="? "),he+=U.dump+(U.condenseFlow?'"':"")+":"+(U.condenseFlow?"":" "),yo(U,J,ae,!1,!1)&&(ge+=he+=U.dump));U.tag=pe,U.dump="{"+ge+"}"})(t,n,t.dump),_&&(t.dump="&ref_"+N+" "+t.dump));else if(C==="[object Array]")l&&t.dump.length!==0?(t.noArrayIndent&&!x&&n>0?sy(t,n-1,t.dump,h):sy(t,n,t.dump,h),_&&(t.dump="&ref_"+N+t.dump)):((function(U,J,Y){var W,P,se,ae="",he=U.tag;for(W=0,P=Y.length;W",t.dump=w+" "+t.dump)}return!0}function pA(t,n){var i,l,h=[],v=[];for(ay(t,h,v),i=0,l=v.length;i(n[i]=(function(h){return h.includes(", ")?h.split(", "):h})(l),n)),{})}function Qp(t,n,{loadSpec:i=!1}={}){const l={ok:t.ok,url:t.url||n,status:t.status,statusText:t.statusText,headers:ti(t.headers)},h=l.headers["content-type"],v=i||((x="")=>/(json|xml|yaml|text)\b/.test(x))(h);return(v?t.text:t.blob||t.buffer).call(t).then((x=>{if(l.text=x,l.data=x,v)try{const w=(function(C,$){return $&&($.indexOf("application/json")===0||$.indexOf("+json")>0)?JSON.parse(C):qu.load(C)})(x,h);l.body=w,l.obj=w}catch(w){l.parseError=w}return l}))}async function ni(t,n={}){typeof t=="object"&&(t=(n=t).url),n.headers=n.headers||{},(n=qp(n)).headers&&Object.keys(n.headers).forEach((h=>{const v=n.headers[h];typeof v=="string"&&(n.headers[h]=v.replace(/\n+/g," "))})),n.requestInterceptor&&(n=await n.requestInterceptor(n)||n);const i=n.headers["content-type"]||n.headers["Content-Type"];let l;/multipart\/form-data/i.test(i)&&(delete n.headers["content-type"],delete n.headers["Content-Type"]);try{l=await(n.userFetch||fetch)(n.url,n),l=await Qp(l,t,n),n.responseInterceptor&&(l=await n.responseInterceptor(l)||l)}catch(h){if(!l)throw h;const v=new Error(l.statusText||`response status is ${l.status}`);throw v.status=l.status,v.statusCode=l.status,v.responseError=h,v}if(!l.ok){const h=new Error(l.statusText||`response status is ${l.status}`);throw h.status=l.status,h.statusCode=l.status,h.response=l,h}return l}function uy(t,n={}){const{requestInterceptor:i,responseInterceptor:l}=n,h=t.withCredentials?"include":"same-origin";return v=>t({url:v,loadSpec:!0,requestInterceptor:i,responseInterceptor:l,headers:{Accept:"application/json, application/yaml"},credentials:h}).then((x=>x.body))}const Bu=t=>{var n,i;const{baseDoc:l,url:h}=t,v=(n=l??h)!==null&&n!==void 0?n:"";return typeof((i=globalThis.document)===null||i===void 0?void 0:i.baseURI)=="string"?String(new URL(v,globalThis.document.baseURI)):v},gl=t=>{const{fetch:n,http:i}=t;return n||i||ni};var Uu,n0=(Uu=function(t,n){return Uu=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,l){i.__proto__=l}||function(i,l){for(var h in l)l.hasOwnProperty(h)&&(i[h]=l[h])},Uu(t,n)},function(t,n){function i(){this.constructor=t}Uu(t,n),t.prototype=n===null?Object.create(n):(i.prototype=n.prototype,new i)}),dy=Object.prototype.hasOwnProperty;function ef(t,n){return dy.call(t,n)}function ri(t){if(Array.isArray(t)){for(var n=new Array(t.length),i=0;i=48&&n<=57))return!1;i++}return!0}function Ia(t){return t.indexOf("/")===-1&&t.indexOf("~")===-1?t:t.replace(/~/g,"~0").replace(/\//g,"~1")}function Ku(t){return t.replace(/~1/g,"/").replace(/~0/g,"~")}function si(t){if(t===void 0)return!0;if(t){if(Array.isArray(t)){for(var n=0,i=t.length;n0&&w[$-1]=="constructor"))throw new TypeError("JSON-Patch: modifying `__proto__` or `constructor/prototype` prop is banned for security reasons, if this was on purpose, please set `banPrototypeModifications` flag false and pass it to this function. More info in fast-json-patch README");if(i&&_===void 0&&(C[F]===void 0?_=w.slice(0,$).join("/"):$==N-1&&(_=n.path),_!==void 0&&U(n,0,t,_)),$++,Array.isArray(C)){if(F==="-")F=C.length;else{if(i&&!yl(F))throw new Kn("Expected an unsigned base-10 integer value, making the new referenced value the array element with the zero-based index","OPERATION_PATH_ILLEGAL_ARRAY_INDEX",v,n,t);yl(F)&&(F=~~F)}if($>=N){if(i&&n.op==="add"&&F>C.length)throw new Kn("The specified index MUST NOT be greater than the number of elements in the array","OPERATION_VALUE_OUT_OF_BOUNDS",v,n,t);if((x=r0[n.op].call(n,C,F,t)).test===!1)throw new Kn("Test operation failed","TEST_OPERATION_FAILED",v,n,t);return x}}else if($>=N){if((x=ii[n.op].call(n,C,F,t)).test===!1)throw new Kn("Test operation failed","TEST_OPERATION_FAILED",v,n,t);return x}if(C=C[F],i&&$0)throw new Kn('Operation `path` property must start with "/"',"OPERATION_PATH_INVALID",n,t,i);if((t.op==="move"||t.op==="copy")&&typeof t.from!="string")throw new Kn("Operation `from` property is not present (applicable in `move` and `copy` operations)","OPERATION_FROM_REQUIRED",n,t,i);if((t.op==="add"||t.op==="replace"||t.op==="test")&&t.value===void 0)throw new Kn("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_REQUIRED",n,t,i);if((t.op==="add"||t.op==="replace"||t.op==="test")&&si(t.value))throw new Kn("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED",n,t,i);if(i){if(t.op=="add"){var h=t.path.split("/").length,v=l.split("/").length;if(h!==v+1&&h!==v)throw new Kn("Cannot perform an `add` operation at the desired path","OPERATION_PATH_CANNOT_ADD",n,t,i)}else if(t.op==="replace"||t.op==="remove"||t.op==="_get"){if(t.path!==l)throw new Kn("Cannot perform the operation at a path that does not exist","OPERATION_PATH_UNRESOLVABLE",n,t,i)}else if(t.op==="move"||t.op==="copy"){var x=hr([{op:"_get",path:t.from,value:void 0}],i);if(x&&x.name==="OPERATION_PATH_UNRESOLVABLE")throw new Kn("Cannot perform the operation from a path that does not exist","OPERATION_FROM_UNRESOLVABLE",n,t,i)}}}function hr(t,n,i){try{if(!Array.isArray(t))throw new Kn("Patch sequence must be an array","SEQUENCE_NOT_AN_ARRAY");if(n)bo(os(n),os(t),i||!0);else{i=i||Fr;for(var l=0;l0&&(t.patches=[],t.callback&&t.callback(l)),l}function nf(t,n,i,l,h){if(n!==t){typeof n.toJSON=="function"&&(n=n.toJSON());for(var v=ri(n),x=ri(t),w=!1,C=x.length-1;C>=0;C--){var $=t[_=x[C]];if(!ef(n,_)||n[_]===void 0&&$!==void 0&&Array.isArray(n)===!1)Array.isArray(t)===Array.isArray(n)?(h&&i.push({op:"test",path:l+"/"+Ia(_),value:os($)}),i.push({op:"remove",path:l+"/"+Ia(_)}),w=!0):(h&&i.push({op:"test",path:l,value:t}),i.push({op:"replace",path:l,value:n}));else{var N=n[_];typeof $=="object"&&$!=null&&typeof N=="object"&&N!=null&&Array.isArray($)===Array.isArray(N)?nf($,N,i,l+"/"+Ia(_),h):$!==N&&(h&&i.push({op:"test",path:l+"/"+Ia(_),value:os($)}),i.push({op:"replace",path:l+"/"+Ia(_),value:os(N)}))}}if(w||v.length!=x.length)for(C=0;Cl!==void 0&&i?i[l]:i),t)},applyPatch:function(t,n,i){if(i=i||{},(n={...n,path:n.path&&jc(n.path)}).op==="merge"){const l=Sl(t,n.path);Object.assign(l,n.value),bo(t,[Cc(n.path,l)])}else if(n.op==="mergeDeep"){const l=Sl(t,n.path),h=fy(l,n.value);t=bo(t,[Cc(n.path,h)]).newDocument}else if(n.op==="add"&&n.path===""&&Ac(n.value)){const l=Object.keys(n.value).reduce(((h,v)=>(h.push({op:"add",path:`/${jc(v)}`,value:n.value[v]}),h)),[]);bo(t,l)}else if(n.op==="replace"&&n.path===""){let{value:l}=n;i.allowMetaPatches&&n.meta&&wl(n)&&(Array.isArray(n.value)||Ac(n.value))&&(l={...l,...n.meta}),t=l}else if(bo(t,[n]),i.allowMetaPatches&&n.meta&&wl(n)&&(Array.isArray(n.value)||Ac(n.value))){const l={...Sl(t,n.path),...n.meta};bo(t,[Cc(n.path,l)])}return t},parentPathMatch:function(t,n){if(!Array.isArray(n))return!1;for(let i=0,l=n.length;i(n+"").replace(/~/g,"~0").replace(/\//g,"~1"))).join("/")}`:t}function Cc(t,n,i){return{op:"replace",path:t,value:n,meta:i}}function bl(t,n,i){return s0(uh(t.filter(wl).map((l=>n(l.value,i,l.path)))||[]))}function Wr(t,n,i){return i=i||[],Array.isArray(t)?t.map(((l,h)=>Wr(l,n,i.concat(h)))):Ac(t)?Object.keys(t).map((l=>Wr(t[l],n,i.concat(l)))):n(t,i[i.length-1],i)}function Hu(t,n,i){let l=[];if((i=i||[]).length>0){const h=n(t,i[i.length-1],i);h&&(l=l.concat(h))}if(Array.isArray(t)){const h=t.map(((v,x)=>Hu(v,n,i.concat(x))));h&&(l=l.concat(h))}else if(Ac(t)){const h=Object.keys(t).map((v=>Hu(t[v],n,i.concat(v))));h&&(l=l.concat(h))}return l=uh(l),l}function my(t){return Array.isArray(t)?t:[t]}function uh(t){return[].concat(...t.map((n=>Array.isArray(n)?uh(n):n)))}function s0(t){return t.filter((n=>n!==void 0))}function Ac(t){return t&&typeof t=="object"}function Dr(t){return t&&typeof t=="function"}function rf(t){if(Xu(t)){const{op:n}=t;return n==="add"||n==="remove"||n==="replace"}return!1}function Gu(t){return rf(t)||Xu(t)&&t.type==="mutation"}function wl(t){return Gu(t)&&(t.op==="add"||t.op==="replace"||t.op==="merge"||t.op==="mergeDeep")}function Xu(t){return t&&typeof t=="object"}function Sl(t,n){try{return wc(t,n)}catch(i){return console.error(i),{}}}var qa=function(t){return t&&t.Math===Math&&t},ji=qa(typeof globalThis=="object"&&globalThis)||qa(typeof window=="object"&&window)||qa(typeof self=="object"&&self)||qa(typeof Um=="object"&&Um)||qa(!1)||(function(){return this})()||Function("return this")(),Zi=function(t){try{return!!t()}catch{return!0}},sf=!Zi((function(){var t=(function(){}).bind();return typeof t!="function"||t.hasOwnProperty("prototype")})),i0=sf,El=Function.prototype,af=El.apply,dh=El.call,of=typeof Reflect=="object"&&Reflect.apply||(i0?dh.bind(af):function(){return dh.apply(af,arguments)}),Oc=sf,lf=Function.prototype,Yu=lf.call,cf=Oc&&lf.bind.bind(Yu,Yu),Wi=Oc?cf:function(t){return function(){return Yu.apply(t,arguments)}},gy=Wi,kc=gy({}.toString),Rc=gy("".slice),uf=function(t){return Rc(kc(t),8,-1)},a0=uf,Zu=Wi,Tc=function(t){if(a0(t)==="Function")return Zu(t)},Wu=typeof document=="object"&&document.all,ks=Wu===void 0&&Wu!==void 0?function(t){return typeof t=="function"||t===Wu}:function(t){return typeof t=="function"},Ju={},So=!Zi((function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7})),_c=sf,hh=Function.prototype.call,li=_c?hh.bind(hh):function(){return hh.apply(hh,arguments)},df={},hf={}.propertyIsEnumerable,Eo=Object.getOwnPropertyDescriptor,jl=Eo&&!hf.call({1:2},1);df.f=jl?function(t){var n=Eo(this,t);return!!n&&n.enumerable}:hf;var Ji,Qu,$c=function(t,n){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:n}},ph=Zi,fh=uf,pf=Object,o0=Wi("".split),ed=ph((function(){return!pf("z").propertyIsEnumerable(0)}))?function(t){return fh(t)==="String"?o0(t,""):pf(t)}:pf,td=function(t){return t==null},l0=td,yy=TypeError,nd=function(t){if(l0(t))throw new yy("Can't call method on "+t);return t},Ci=ed,Qi=nd,ea=function(t){return Ci(Qi(t))},vy=ks,Ea=function(t){return typeof t=="object"?t!==null:vy(t)},Ba={},Is=Ba,jr=ji,ff=ks,Ua=function(t){return ff(t)?t:void 0},en=function(t,n){return arguments.length<2?Ua(Is[t])||Ua(jr[t]):Is[t]&&Is[t][n]||jr[t]&&jr[t][n]},Vn=Wi({}.isPrototypeOf),Pr=ji.navigator,mh=Pr&&Pr.userAgent,Nc=ji,jo=mh?String(mh):"",gh=Nc.process,rd=Nc.Deno,Dc=gh&&gh.versions||rd&&rd.version,c0=Dc&&Dc.v8;c0&&(Qu=(Ji=c0.split("."))[0]>0&&Ji[0]<4?1:+(Ji[0]+Ji[1])),!Qu&&jo&&(!(Ji=jo.match(/Edge\/(\d+)/))||Ji[1]>=74)&&(Ji=jo.match(/Chrome\/(\d+)/))&&(Qu=+Ji[1]);var Cr=Qu,xy=Zi,by=ji.String,wy=!!Object.getOwnPropertySymbols&&!xy((function(){var t=Symbol("symbol detection");return!by(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&Cr&&Cr<41})),Sy=wy&&!Symbol.sham&&typeof Symbol.iterator=="symbol",fA=en,Ey=ks,jy=Vn,Cy=Object,Rs=Sy?function(t){return typeof t=="symbol"}:function(t){var n=fA("Symbol");return Ey(n)&&jy(n.prototype,Cy(t))},Mr=String,sd=function(t){try{return Mr(t)}catch{return"Object"}},yh=ks,mf=sd,Ay=TypeError,ta=function(t){if(yh(t))return t;throw new Ay(mf(t)+" is not a function")},gf=ta,Oy=td,vh=function(t,n){var i=t[n];return Oy(i)?void 0:gf(i)},ky=li,Ry=ks,Ty=Ea,u0=TypeError,_y={exports:{}},$y=ji,Ny=Object.defineProperty,d0=ji,h0=_y.exports=d0.o||(function(t,n){try{Ny($y,t,{value:n,configurable:!0,writable:!0})}catch{$y[t]=n}return n})("__core-js_shared__",{});(h0.versions||(h0.versions=[])).push({version:"3.38.1",mode:"pure",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"});var Dy=_y.exports,Py=Dy,My=function(t,n){return Py[t]||(Py[t]=n||{})},Iy=nd,p0=Object,Ly=function(t){return p0(Iy(t))},f0=Ly,m0=Wi({}.hasOwnProperty),Ka=Object.hasOwn||function(t,n){return m0(f0(t),n)},mA=Wi,g0=0,id=Math.random(),y0=mA(1 .toString),xh=function(t){return"Symbol("+(t===void 0?"":t)+")_"+y0(++g0+id,36)},yf=My,zy=Ka,Fy=xh,gA=wy,v0=Sy,Pc=ji.Symbol,vf=yf("wks"),x0=v0?Pc.for||Pc:Pc&&Pc.withoutSetter||Fy,Va=function(t){return zy(vf,t)||(vf[t]=gA&&zy(Pc,t)?Pc[t]:x0("Symbol."+t)),vf[t]},qy=li,By=Ea,Uy=Rs,Ky=vh,b0=TypeError,w0=Va("toPrimitive"),yA=function(t,n){if(!By(t)||Uy(t))return t;var i,l=Ky(t,w0);if(l){if(i=qy(l,t,n),!By(i)||Uy(i))return i;throw new b0("Can't convert object to primitive value")}return(function(h,v){var x,w;if(Ry(x=h.toString)&&!Ty(w=ky(x,h))||Ry(x=h.valueOf)&&!Ty(w=ky(x,h)))return w;throw new u0("Can't convert object to primitive value")})(t)},Vy=Rs,Hy=function(t){var n=yA(t,"string");return Vy(n)?n:n+""},Gy=Ea,bh=ji.document,S0=Gy(bh)&&Gy(bh.createElement),Xy=function(t){return S0?bh.createElement(t):{}},vA=Xy,E0=!So&&!Zi((function(){return Object.defineProperty(vA("div"),"a",{get:function(){return 7}}).a!==7})),j0=So,wh=li,Yy=df,xf=$c,C0=ea,A0=Hy,Sh=Ka,O0=E0,bf=Object.getOwnPropertyDescriptor;Ju.f=j0?bf:function(t,n){if(t=C0(t),n=A0(n),O0)try{return bf(t,n)}catch{}if(Sh(t,n))return xf(!wh(Yy.f,t,n),t[n])};var k0=Zi,Zy=ks,Wy=/#|\.prototype\./,ad=function(t,n){var i=Mc[R0(t)];return i===_0||i!==T0&&(Zy(n)?k0(n):!!n)},R0=ad.normalize=function(t){return String(t).replace(Wy,".").toLowerCase()},Mc=ad.data={},T0=ad.NATIVE="N",_0=ad.POLYFILL="P",$0=ad,wf=ta,N0=sf,Jy=Tc(Tc.bind),Qy=function(t,n){return wf(t),n===void 0?t:N0?Jy(t,n):function(){return t.apply(n,arguments)}},Cl={},D0=So&&Zi((function(){return Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype!==42})),ev=Ea,qr=String,ys=TypeError,Al=function(t){if(ev(t))return t;throw new ys(qr(t)+" is not an object")},P0=So,M0=E0,I0=D0,Ol=Al,tv=Hy,Sf=TypeError,Ef=Object.defineProperty,xA=Object.getOwnPropertyDescriptor;Cl.f=P0?I0?function(t,n,i){if(Ol(t),n=tv(n),Ol(i),typeof t=="function"&&n==="prototype"&&"value"in i&&"writable"in i&&!i.writable){var l=xA(t,n);l&&l.writable&&(t[n]=i.value,i={configurable:"configurable"in i?i.configurable:l.configurable,enumerable:"enumerable"in i?i.enumerable:l.enumerable,writable:!1})}return Ef(t,n,i)}:Ef:function(t,n,i){if(Ol(t),n=tv(n),Ol(i),M0)try{return Ef(t,n,i)}catch{}if("get"in i||"set"in i)throw new Sf("Accessors not supported");return"value"in i&&(t[n]=i.value),t};var jf=Cl,nv=$c,Co=So?function(t,n,i){return jf.f(t,n,nv(1,i))}:function(t,n,i){return t[n]=i,t},od=ji,L0=of,rv=Tc,sv=ks,iv=Ju.f,z0=$0,kl=Ba,Cf=Qy,Rl=Co,av=Ka,ov=function(t){var n=function(i,l,h){if(this instanceof n){switch(arguments.length){case 0:return new t;case 1:return new t(i);case 2:return new t(i,l)}return new t(i,l,h)}return L0(t,this,arguments)};return n.prototype=t.prototype,n},Eh=function(t,n){var i,l,h,v,x,w,C,$,N,_=t.target,F=t.global,U=t.stat,J=t.proto,Y=F?od:U?od[_]:od[_]&&od[_].prototype,W=F?kl:kl[_]||Rl(kl,_,{})[_],P=W.prototype;for(v in n)l=!(i=z0(F?v:_+(U?".":"#")+v,t.forced))&&Y&&av(Y,v),w=W[v],l&&(C=t.dontCallGetSet?(N=iv(Y,v))&&N.value:Y[v]),x=l&&C?C:n[v],(i||J||typeof w!=typeof x)&&($=t.bind&&l?Cf(x,od):t.wrap&&l?ov(x):J&&sv(x)?rv(x):x,(t.sham||x&&x.sham||w&&w.sham)&&Rl($,"sham",!0),Rl(W,v,$),J&&(av(kl,h=_+"Prototype")||Rl(kl,h,{}),Rl(kl[h],v,x),t.real&&P&&(i||!P[v])&&Rl(P,v,x)))},Ao=xh,Af=My("keys"),lv=function(t){return Af[t]||(Af[t]=Ao(t))},F0=!Zi((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype})),Oo=Ka,cv=ks,q0=Ly,Of=F0,ld=lv("IE_PROTO"),or=Object,bA=or.prototype,uv=Of?or.getPrototypeOf:function(t){var n=q0(t);if(Oo(n,ld))return n[ld];var i=n.constructor;return cv(i)&&n instanceof i?i.prototype:n instanceof or?bA:null},B0=Wi,jh=ta,Tl=Ea,U0=String,K0=TypeError,Ch=Ea,Ha=nd,V0=function(t){if((function(n){return Tl(n)||n===null})(t))return t;throw new K0("Can't set "+U0(t)+" as a prototype")},Ah=Object.setPrototypeOf||("__proto__"in{}?(function(){var t,n=!1,i={};try{(t=(function(l,h,v){try{return B0(jh(Object.getOwnPropertyDescriptor(l,h)[v]))}catch{}})(Object.prototype,"__proto__","set"))(i,[]),n=i instanceof Array}catch{}return function(l,h){return Ha(l),V0(h),Ch(l)&&(n?t(l,h):l.__proto__=h),l}})():void 0),dv={},hv=Math.ceil,pv=Math.floor,kf=Math.trunc||function(t){var n=+t;return(n>0?pv:hv)(n)},Rf=function(t){var n=+t;return n!=n||n===0?0:kf(n)},ko=Rf,Br=Math.max,fv=Math.min,H0=Rf,ls=Math.min,G0=function(t){return(function(n){var i=H0(n);return i>0?ls(i,9007199254740991):0})(t.length)},X0=ea,Y0=G0,xr=function(t){return function(n,i,l){var h=X0(n),v=Y0(h);if(v===0)return!t&&-1;var x,w=(function(C,$){var N=ko(C);return N<0?Br(N+$,0):fv(N,$)})(l,v);if(t&&i!=i){for(;v>w;)if((x=h[w++])!=x)return!0}else for(;v>w;w++)if((t||w in h)&&h[w]===i)return t||w||0;return!t&&-1}},ci={indexOf:xr(!1)},ja={},Tf=Ka,Z0=ea,W0=ci.indexOf,wA=ja,Oh=Wi([].push),Ls=function(t,n){var i,l=Z0(t),h=0,v=[];for(i in l)!Tf(wA,i)&&Tf(l,i)&&Oh(v,i);for(;n.length>h;)Tf(l,i=n[h++])&&(~W0(v,i)||Oh(v,i));return v},Ai=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],J0=Ls,ui=Ai.concat("length","prototype");dv.f=Object.getOwnPropertyNames||function(t){return J0(t,ui)};var mv={};mv.f=Object.getOwnPropertySymbols;var Ro=en,Ic=dv,To=mv,gv=Al,yv=Wi([].concat),Ca=Ro("Reflect","ownKeys")||function(t){var n=Ic.f(gv(t)),i=To.f;return i?yv(n,i(t)):n},vv=Ka,cd=Ca,kh=Ju,Rh=Cl,Lc=function(t,n,i){for(var l=cd(n),h=Rh.f,v=kh.f,x=0;xx;)SA.f(t,i=h[x++],l[i]);return t};var hn,An=en("document","documentElement"),Wn=Al,Oi=xv,_o=Ai,ud=ja,bv=An,$o=Xy,Ar=lv("IE_PROTO"),Ga=function(){},_l=function(t){return" - - + + +
    diff --git a/internal/web/dist/index.html.br b/internal/web/dist/index.html.br deleted file mode 100644 index 48d498a988af5ff2a07b8fffd0b816e911de07f5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 202 zcmV;*05$)ikPraiIB;XdrZ|7mvcq+$U)>&TWOM}(AfW*Nxvh43Wbf{8z^I07D4Op^ z(9#T+WLDc6_!4|dG0tsfWmnd@p&jc5Stb@C{B+o4LPMM57^+i@e<6(DIs3fs z6-kFq8JpcAE=A4%W?vHK#YW5Xg`?;Q*u \ No newline at end of file + \ No newline at end of file diff --git a/ui/package.json b/ui/package.json index cac106c..66a6869 100644 --- a/ui/package.json +++ b/ui/package.json @@ -53,7 +53,7 @@ "react": "^19.2.3", "react-day-picker": "^9.13.0", "react-dom": "^19.2.3", - "react-hook-form": "^7.69.0", + "react-hook-form": "^7.70.0", "react-icons": "^5.5.0", "react-resizable-panels": "^3.0.6", "react-router-dom": "^7.11.0", diff --git a/ui/src/pages/credential-page.tsx b/ui/src/pages/credential-page.tsx index 6c4f8f5..55ce600 100644 --- a/ui/src/pages/credential-page.tsx +++ b/ui/src/pages/credential-page.tsx @@ -68,6 +68,10 @@ const AWS_ALLOWED_SERVICES = ["route53", "s3", "ec2", "iam", "rds", "dynamodb"] type AwsSvc = (typeof AWS_ALLOWED_SERVICES)[number] // -------------------- Schemas -------------------- +// Zod v4 gotchas you hit: +// - .partial() cannot be used if the object contains refinements/effects (often true once you have transforms/refines). +// - .extend() cannot overwrite keys after refinements (requires .safeExtend()). +// Easiest fix: define CREATE and UPDATE schemas separately (no .partial(), no post-refinement .extend()). const createCredentialSchema = z .object({ @@ -91,6 +95,16 @@ const createCredentialSchema = z secret: z.any(), }) .superRefine((val, ctx) => { + // scope required unless provider scope + if (val.scope_kind !== "provider" && !val.scope) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["scope"], + message: `scope is required`, + }) + } + + // AWS scope checks if (val.credential_provider === "aws") { if (val.scope_kind === "service") { const svc = (val.scope as any)?.service @@ -112,23 +126,25 @@ const createCredentialSchema = z }) } } - if (val.kind === "aws_access_key") { - const sk = val.secret ?? {} - const id = sk.access_key_id - if (typeof id !== "string" || !/^[A-Z0-9]{20}$/.test(id)) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: ["secret"], - message: `access_key_id must be 20 chars (A-Z0-9)`, - }) - } - if (typeof sk.secret_access_key !== "string" || sk.secret_access_key.length < 10) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: ["secret"], - message: `secret_access_key is required`, - }) - } + } + + // secret requiredness by kind (create always validates) + if (val.kind === "aws_access_key") { + const sk = val.secret ?? {} + const id = sk.access_key_id + if (typeof id !== "string" || !/^[A-Z0-9]{20}$/.test(id)) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["secret"], + message: `access_key_id must be 20 chars (A-Z0-9)`, + }) + } + if (typeof sk.secret_access_key !== "string" || sk.secret_access_key.length < 10) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["secret"], + message: `secret_access_key is required`, + }) } } @@ -142,6 +158,7 @@ const createCredentialSchema = z }) } } + if (val.kind === "basic_auth") { const s = val.secret ?? {} if (!s.username || !s.password) { @@ -152,6 +169,7 @@ const createCredentialSchema = z }) } } + if (val.kind === "oauth2") { const s = val.secret ?? {} if (!s.client_id || !s.client_secret || !s.refresh_token) { @@ -162,30 +180,144 @@ const createCredentialSchema = z }) } } - - if (val.scope_kind !== "provider" && !val.scope) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: ["scope"], - message: `scope is required`, - }) - } }) type CreateCredentialValues = z.input -const updateCredentialSchema = createCredentialSchema.partial().extend({ - name: z.string().min(1, "Name is required").max(100).optional(), -}) + +// UPDATE schema: all fields optional, and validations are "patch-friendly". +const updateCredentialSchema = z + .object({ + credential_provider: z + .enum(["aws", "cloudflare", "hetzner", "digitalocean", "generic"]) + .optional(), + kind: z.enum(["aws_access_key", "api_token", "basic_auth", "oauth2"]).optional(), + schema_version: z.number().optional(), + name: z.string().min(1, "Name is required").max(100).optional(), + scope_kind: z.enum(["provider", "service", "resource"]).optional(), + scope_version: z.number().optional(), + scope: z.any().optional(), + // allow "" so your form can keep empty strings; buildUpdateBody will drop them + account_id: z.string().optional().or(z.literal("")), + region: z.string().optional().or(z.literal("")), + secret: z.any().optional(), + }) + .superRefine((val, ctx) => { + // If scope_kind is being changed to non-provider, require scope in the patch + if (typeof val.scope_kind !== "undefined") { + if (val.scope_kind !== "provider" && !val.scope) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["scope"], + message: `scope is required`, + }) + } + } + + // AWS scope checks only if we have enough info + if (val.credential_provider === "aws") { + if (val.scope_kind === "service" && typeof val.scope !== "undefined") { + const svc = (val.scope as any)?.service + if (!AWS_ALLOWED_SERVICES.includes(svc)) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["scope"], + message: `For AWS service scope, "service" must be one of: ${AWS_ALLOWED_SERVICES.join(", ")}`, + }) + } + } + if (val.scope_kind === "resource" && typeof val.scope !== "undefined") { + const arn = (val.scope as any)?.arn + if (typeof arn !== "string" || !arn.startsWith("arn:")) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["scope"], + message: `For AWS resource scope, "arn" must start with "arn:"`, + }) + } + } + } + + // Secret validation on update: + // - only validate if rotating secret OR changing kind + // - if rotating secret but kind is NOT provided, skip kind-specific checks (backend can validate) + const rotatingSecret = typeof val.secret !== "undefined" + const changingKind = typeof val.kind !== "undefined" + if (!rotatingSecret && !changingKind) return + if (!val.kind) return + + if (val.kind === "aws_access_key") { + const sk = val.secret ?? {} + const id = sk.access_key_id + if (typeof id !== "string" || !/^[A-Z0-9]{20}$/.test(id)) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["secret"], + message: `access_key_id must be 20 chars (A-Z0-9)`, + }) + } + if (typeof sk.secret_access_key !== "string" || sk.secret_access_key.length < 10) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["secret"], + message: `secret_access_key is required`, + }) + } + } + + if (val.kind === "api_token") { + const token = (val.secret ?? {}).token + if (!token) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["secret"], + message: `token is required`, + }) + } + } + + if (val.kind === "basic_auth") { + const s = val.secret ?? {} + if (!s.username || !s.password) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["secret"], + message: `username and password are required`, + }) + } + } + + if (val.kind === "oauth2") { + const s = val.secret ?? {} + if (!s.client_id || !s.client_secret || !s.refresh_token) { + ctx.addIssue({ + code: z.ZodIssueCode.custom, + path: ["secret"], + message: `client_id, client_secret, and refresh_token are required`, + }) + } + } + }) + +type UpdateCredentialValues = z.input // -------------------- Helpers -------------------- function pretty(obj: unknown) { try { - return JSON.stringify(JSON.parse(obj as string), null, 2) + if (obj == null) return "" + if (typeof obj === "string") { + try { + return JSON.stringify(JSON.parse(obj), null, 2) + } catch { + return obj + } + } + return JSON.stringify(obj, null, 2) } catch { return "" } } + function extractErr(e: any): string { const raw = (e as any)?.body ?? (e as any)?.response ?? (e as any)?.message if (typeof raw === "string") return raw @@ -252,9 +384,9 @@ function buildCreateBody(v: CreateCredentialValues) { } // Build exact PATCH body (only provided fields) -function buildUpdateBody(v: z.infer) { +function buildUpdateBody(v: UpdateCredentialValues) { const body: any = {} - const keys: (keyof typeof v)[] = [ + const keys: (keyof UpdateCredentialValues)[] = [ "name", "account_id", "region", @@ -316,7 +448,7 @@ export const CredentialPage = () => { // Update const updateMutation = useMutation({ - mutationFn: (payload: { id: string; body: z.infer }) => + mutationFn: (payload: { id: string; body: UpdateCredentialValues }) => credentialsApi.updateCredential(payload.id, buildUpdateBody(payload.body)), onSuccess: async () => { await qc.invalidateQueries({ queryKey: ["credentials"] }) @@ -362,7 +494,7 @@ export const CredentialPage = () => { mode: "onBlur", }) - const editForm = useForm>({ + const editForm = useForm({ resolver: zodResolver(updateCredentialSchema), defaultValues: {}, mode: "onBlur", @@ -371,7 +503,8 @@ export const CredentialPage = () => { function openEdit(row: any) { setEditingId(row.id) editForm.reset({ - provider: row.provider, + // FIX: correct key (was "provider" in your original) + credential_provider: row.credential_provider, kind: row.kind, schema_version: row.schema_version ?? 1, name: row.name, @@ -380,7 +513,7 @@ export const CredentialPage = () => { account_id: row.account_id ?? "", region: row.region ?? "", scope: row.scope ?? (row.scope_kind === "provider" ? {} : undefined), - secret: undefined, + secret: undefined, // keep existing unless user rotates } as any) setUseRawEditSecretJSON(false) setEditOpen(true) @@ -394,7 +527,7 @@ export const CredentialPage = () => { return items.filter((c: any) => [ c.name, - c.provider, + c.credential_provider, c.kind, c.scope_kind, c.account_id, @@ -436,6 +569,7 @@ export const CredentialPage = () => { function ensureCreateDefaultsForSecret() { if (useRawSecretJSON) return + if (credential_provider === "aws" && kind === "aws_access_key") { const s = createForm.getValues("secret") ?? {} setCreateSecret({ @@ -459,7 +593,7 @@ export const CredentialPage = () => { } function onChangeCreateScopeKind(next: "provider" | "service" | "resource") { - createForm.setValue("scope_kind", next) + createForm.setValue("scope_kind", next, { shouldDirty: true, shouldValidate: true }) if (next === "provider") setCreateScope({}) if (next === "service") setCreateScope({ service: "route53" as AwsSvc }) if (next === "resource") setCreateScope({ arn: "" }) @@ -905,6 +1039,7 @@ export const CredentialPage = () => { client_secret: e.target.value, }) } + placeholder="••••••••••" /> )} /> @@ -933,7 +1068,6 @@ export const CredentialPage = () => { )} - {/* Preview Create button */}