From 8b0ced22e5cf99136c79f4bdf51a90903924b96d Mon Sep 17 00:00:00 2001 From: 9qeklajc <9qeklajc> Date: Sat, 25 Oct 2025 00:21:41 +0200 Subject: [PATCH] add dark mode --- ui/app/layout.tsx | 7 ++- ui/app/providers.tsx | 22 ++++++--- ui/components/site-header.tsx | 22 +++++---- ui/components/suppress-hydration-warning.tsx | 23 +++++++++ ui/components/theme-provider.tsx | 11 +++++ ui/components/theme-toggle.tsx | 24 ++++++++++ ui_out/404.html | 2 +- ui_out/404/index.html | 2 +- .../_buildManifest.js | 0 .../_ssgManifest.js | 0 ...8975c01d467.js => 222-23a547ab56ff9638.js} | 0 .../static/chunks/226-b955dd578f372adc.js | 1 + .../static/chunks/236-d1820fdf10fbc413.js | 1 - ...7fb1dd82bdc3.js => 29-2e340e48c1ca61fb.js} | 0 ...2fca35baa33.js => 363-c1e2b04767a3c84b.js} | 0 .../static/chunks/375-7943a6dae9b88f03.js | 1 + ...f8fe547e418.js => 481-7440db9fd9bb94b2.js} | 0 ...54bf6b2d14c.js => 497-cf9737613a43115a.js} | 0 .../static/chunks/578-9e08cd45b1eda688.js | 1 - ...408e968f9da.js => 601-3f92835872ce1c3b.js} | 0 ...299a4aa4df7.js => 651-7f1a745b0e3db11d.js} | 0 ...bb3ce1.js => 65b78783-daf30cffc34759e7.js} | 0 ...9af1fa345bd.js => 730-eb609e4385533b6b.js} | 0 .../static/chunks/808-6da586a06e4a6738.js | 1 - ...5d1c2416e5d.js => 826-03658aa28a2a895d.js} | 0 .../static/chunks/900-4ce6a1afa7029035.js | 1 + ...190a9f5efa7.js => 978-960e423dcb2d179d.js} | 0 ...d0e30e6255e.js => 982-dc9d2de6dd23b183.js} | 0 ...8830eb0233.js => page-67d68e30910d9cb7.js} | 0 .../chunks/app/layout-1e4148ea2d359141.js | 1 - .../chunks/app/layout-8cbedc9fb3669ba4.js | 1 + ...7b74a0707f.js => page-603b845ae6bd54c9.js} | 0 ...46fd1f0602.js => page-862224df2a15ab65.js} | 2 +- .../chunks/app/page-3876b4fb2023557a.js | 1 + .../chunks/app/page-cf122f9b514899ca.js | 1 - .../app/providers/page-24027db6adfd0b9b.js | 1 - .../app/providers/page-d7c9b193573b160c.js | 1 + ...be5044bf9e.js => page-36e251683a0d492c.js} | 2 +- .../app/transactions/page-114770ed3af4ceb6.js | 1 - .../app/transactions/page-b9cef669e0e237ee.js | 1 + ...6db4782139.js => page-96bd6a23715af694.js} | 0 ui_out/_next/static/css/2dee0244dc7d99bd.css | 1 - ui_out/_next/static/css/a2fcfb52b8f42d80.css | 1 + ui_out/index.html | 2 +- ui_out/index.txt | 47 ++++++++++--------- ui_out/login/index.html | 2 +- ui_out/login/index.txt | 41 ++++++++-------- ui_out/model/index.html | 2 +- ui_out/model/index.txt | 41 ++++++++-------- ui_out/providers/index.html | 2 +- ui_out/providers/index.txt | 41 ++++++++-------- ui_out/settings/index.html | 2 +- ui_out/settings/index.txt | 41 ++++++++-------- ui_out/transactions/index.html | 2 +- ui_out/transactions/index.txt | 41 ++++++++-------- ui_out/unauthorized/index.html | 2 +- ui_out/unauthorized/index.txt | 41 ++++++++-------- 57 files changed, 260 insertions(+), 180 deletions(-) create mode 100644 ui/components/suppress-hydration-warning.tsx create mode 100644 ui/components/theme-provider.tsx create mode 100644 ui/components/theme-toggle.tsx rename ui_out/_next/static/{4bJrP3zJGhvVQWjndHhpS => 6UzBhGpyRdJjWoKvuuFgP}/_buildManifest.js (100%) rename ui_out/_next/static/{4bJrP3zJGhvVQWjndHhpS => 6UzBhGpyRdJjWoKvuuFgP}/_ssgManifest.js (100%) rename ui_out/_next/static/chunks/{222-4bb848975c01d467.js => 222-23a547ab56ff9638.js} (100%) create mode 100644 ui_out/_next/static/chunks/226-b955dd578f372adc.js delete mode 100644 ui_out/_next/static/chunks/236-d1820fdf10fbc413.js rename ui_out/_next/static/chunks/{29-e3557fb1dd82bdc3.js => 29-2e340e48c1ca61fb.js} (100%) rename ui_out/_next/static/chunks/{363-119b32fca35baa33.js => 363-c1e2b04767a3c84b.js} (100%) create mode 100644 ui_out/_next/static/chunks/375-7943a6dae9b88f03.js rename ui_out/_next/static/chunks/{481-48cd0f8fe547e418.js => 481-7440db9fd9bb94b2.js} (100%) rename ui_out/_next/static/chunks/{497-baf4d54bf6b2d14c.js => 497-cf9737613a43115a.js} (100%) delete mode 100644 ui_out/_next/static/chunks/578-9e08cd45b1eda688.js rename ui_out/_next/static/chunks/{601-bd77b408e968f9da.js => 601-3f92835872ce1c3b.js} (100%) rename ui_out/_next/static/chunks/{651-4a58f299a4aa4df7.js => 651-7f1a745b0e3db11d.js} (100%) rename ui_out/_next/static/chunks/{65b78783-abd88d9e33bb3ce1.js => 65b78783-daf30cffc34759e7.js} (100%) rename ui_out/_next/static/chunks/{730-892209af1fa345bd.js => 730-eb609e4385533b6b.js} (100%) delete mode 100644 ui_out/_next/static/chunks/808-6da586a06e4a6738.js rename ui_out/_next/static/chunks/{826-c15935d1c2416e5d.js => 826-03658aa28a2a895d.js} (100%) create mode 100644 ui_out/_next/static/chunks/900-4ce6a1afa7029035.js rename ui_out/_next/static/chunks/{978-cd938190a9f5efa7.js => 978-960e423dcb2d179d.js} (100%) rename ui_out/_next/static/chunks/{982-5588ad0e30e6255e.js => 982-dc9d2de6dd23b183.js} (100%) rename ui_out/_next/static/chunks/app/_not-found/{page-c90bc08830eb0233.js => page-67d68e30910d9cb7.js} (100%) delete mode 100644 ui_out/_next/static/chunks/app/layout-1e4148ea2d359141.js create mode 100644 ui_out/_next/static/chunks/app/layout-8cbedc9fb3669ba4.js rename ui_out/_next/static/chunks/app/login/{page-9d2abe7b74a0707f.js => page-603b845ae6bd54c9.js} (100%) rename ui_out/_next/static/chunks/app/model/{page-8be1c146fd1f0602.js => page-862224df2a15ab65.js} (93%) create mode 100644 ui_out/_next/static/chunks/app/page-3876b4fb2023557a.js delete mode 100644 ui_out/_next/static/chunks/app/page-cf122f9b514899ca.js delete mode 100644 ui_out/_next/static/chunks/app/providers/page-24027db6adfd0b9b.js create mode 100644 ui_out/_next/static/chunks/app/providers/page-d7c9b193573b160c.js rename ui_out/_next/static/chunks/app/settings/{page-abf398be5044bf9e.js => page-36e251683a0d492c.js} (74%) delete mode 100644 ui_out/_next/static/chunks/app/transactions/page-114770ed3af4ceb6.js create mode 100644 ui_out/_next/static/chunks/app/transactions/page-b9cef669e0e237ee.js rename ui_out/_next/static/chunks/app/unauthorized/{page-bd10c76db4782139.js => page-96bd6a23715af694.js} (100%) delete mode 100644 ui_out/_next/static/css/2dee0244dc7d99bd.css create mode 100644 ui_out/_next/static/css/a2fcfb52b8f42d80.css diff --git a/ui/app/layout.tsx b/ui/app/layout.tsx index 6f388724..e9ba89cb 100644 --- a/ui/app/layout.tsx +++ b/ui/app/layout.tsx @@ -2,6 +2,7 @@ import type { Metadata } from 'next'; import { Geist, Geist_Mono } from 'next/font/google'; import './globals.css'; import { Providers } from './providers'; +import { SuppressHydrationWarning } from '@/components/suppress-hydration-warning'; const geistSans = Geist({ variable: '--font-geist-sans', @@ -27,11 +28,13 @@ export default function RootLayout({ children: React.ReactNode; }>) { return ( - + - {children} + + {children} + ); diff --git a/ui/app/providers.tsx b/ui/app/providers.tsx index af801e33..db29ca68 100644 --- a/ui/app/providers.tsx +++ b/ui/app/providers.tsx @@ -6,6 +6,7 @@ import { useState, type ReactNode } from 'react'; import { Toaster } from 'sonner'; import { AuthProvider } from '@/lib/auth/AuthContext'; import { ProtectedRoute } from '@/lib/auth/ProtectedRoute'; +import { ThemeProvider } from '@/components/theme-provider'; interface ProvidersProps { children: ReactNode; @@ -27,13 +28,20 @@ export function Providers({ children }: ProvidersProps) { return ( - - - {children} - - - - + + + + {children} + + + + + ); } diff --git a/ui/components/site-header.tsx b/ui/components/site-header.tsx index 31b86a14..1d217579 100644 --- a/ui/components/site-header.tsx +++ b/ui/components/site-header.tsx @@ -7,6 +7,7 @@ import { LogOut } from 'lucide-react'; import { useRouter } from 'next/navigation'; import { adminLogout } from '@/lib/api/services/auth'; import { toast } from 'sonner'; +import { ThemeToggle } from '@/components/theme-toggle'; export function SiteHeader() { const router = useRouter(); @@ -33,15 +34,18 @@ export function SiteHeader() { />

Routstr

- +
+ + +
); diff --git a/ui/components/suppress-hydration-warning.tsx b/ui/components/suppress-hydration-warning.tsx new file mode 100644 index 00000000..2444e92a --- /dev/null +++ b/ui/components/suppress-hydration-warning.tsx @@ -0,0 +1,23 @@ +'use client'; + +import { useEffect, useState } from 'react'; + +interface SuppressHydrationWarningProps { + children: React.ReactNode; +} + +export function SuppressHydrationWarning({ + children, +}: SuppressHydrationWarningProps) { + const [isClient, setIsClient] = useState(false); + + useEffect(() => { + setIsClient(true); + }, []); + + if (!isClient) { + return null; + } + + return <>{children}; +} diff --git a/ui/components/theme-provider.tsx b/ui/components/theme-provider.tsx new file mode 100644 index 00000000..9bf53d86 --- /dev/null +++ b/ui/components/theme-provider.tsx @@ -0,0 +1,11 @@ +'use client'; + +import * as React from 'react'; +import { ThemeProvider as NextThemesProvider } from 'next-themes'; + +export function ThemeProvider({ + children, + ...props +}: React.ComponentProps) { + return {children}; +} diff --git a/ui/components/theme-toggle.tsx b/ui/components/theme-toggle.tsx new file mode 100644 index 00000000..1008e0f4 --- /dev/null +++ b/ui/components/theme-toggle.tsx @@ -0,0 +1,24 @@ +'use client'; + +import * as React from 'react'; +import { Moon, Sun } from 'lucide-react'; +import { useTheme } from 'next-themes'; + +import { Button } from '@/components/ui/button'; + +export function ThemeToggle() { + const { setTheme, theme } = useTheme(); + + return ( + + ); +} diff --git a/ui_out/404.html b/ui_out/404.html index 01d83be5..340503a1 100644 --- a/ui_out/404.html +++ b/ui_out/404.html @@ -1 +1 @@ -404: This page could not be found.Routstr

404

This page could not be found.

\ No newline at end of file + \ No newline at end of file diff --git a/ui_out/404/index.html b/ui_out/404/index.html index 01d83be5..340503a1 100644 --- a/ui_out/404/index.html +++ b/ui_out/404/index.html @@ -1 +1 @@ -404: This page could not be found.Routstr

404

This page could not be found.

\ No newline at end of file + \ No newline at end of file diff --git a/ui_out/_next/static/4bJrP3zJGhvVQWjndHhpS/_buildManifest.js b/ui_out/_next/static/6UzBhGpyRdJjWoKvuuFgP/_buildManifest.js similarity index 100% rename from ui_out/_next/static/4bJrP3zJGhvVQWjndHhpS/_buildManifest.js rename to ui_out/_next/static/6UzBhGpyRdJjWoKvuuFgP/_buildManifest.js diff --git a/ui_out/_next/static/4bJrP3zJGhvVQWjndHhpS/_ssgManifest.js b/ui_out/_next/static/6UzBhGpyRdJjWoKvuuFgP/_ssgManifest.js similarity index 100% rename from ui_out/_next/static/4bJrP3zJGhvVQWjndHhpS/_ssgManifest.js rename to ui_out/_next/static/6UzBhGpyRdJjWoKvuuFgP/_ssgManifest.js diff --git a/ui_out/_next/static/chunks/222-4bb848975c01d467.js b/ui_out/_next/static/chunks/222-23a547ab56ff9638.js similarity index 100% rename from ui_out/_next/static/chunks/222-4bb848975c01d467.js rename to ui_out/_next/static/chunks/222-23a547ab56ff9638.js diff --git a/ui_out/_next/static/chunks/226-b955dd578f372adc.js b/ui_out/_next/static/chunks/226-b955dd578f372adc.js new file mode 100644 index 00000000..2230c6f0 --- /dev/null +++ b/ui_out/_next/static/chunks/226-b955dd578f372adc.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[226],{7:(e,t,n)=>{n.d(t,{Oh:()=>i});var r=n(4398),o=0;function i(){r.useEffect(()=>{var e,t;let n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!=(e=n[0])?e:l()),document.body.insertAdjacentElement("beforeend",null!=(t=n[1])?t:l()),o++,()=>{1===o&&document.querySelectorAll("[data-radix-focus-guard]").forEach(e=>e.remove()),o--}},[])}function l(){let 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}},202:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"RouterContext",{enumerable:!0,get:function(){return r}});let r=n(5348)._(n(4398)).default.createContext(null)},777:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"errorOnce",{enumerable:!0,get:function(){return n}});let n=e=>{}},940:(e,t,n)=>{n.d(t,{A:()=>l,q:()=>i});var r=n(4398),o=n(3422);function i(e,t){let n=r.createContext(t),i=e=>{let{children:t,...i}=e,l=r.useMemo(()=>i,Object.values(i));return(0,o.jsx)(n.Provider,{value:l,children:t})};return i.displayName=e+"Provider",[i,function(o){let i=r.useContext(n);if(i)return i;if(void 0!==t)return t;throw Error(`\`${o}\` must be used within \`${e}\``)}]}function l(e,t=[]){let n=[],i=()=>{let t=n.map(e=>r.createContext(e));return function(n){let o=n?.[e]||t;return r.useMemo(()=>({[`__scope${e}`]:{...n,[e]:o}}),[n,o])}};return i.scopeName=e,[function(t,i){let l=r.createContext(i),a=n.length;n=[...n,i];let u=t=>{let{scope:n,children:i,...u}=t,s=n?.[e]?.[a]||l,c=r.useMemo(()=>u,Object.values(u));return(0,o.jsx)(s.Provider,{value:c,children:i})};return u.displayName=t+"Provider",[u,function(n,o){let u=o?.[e]?.[a]||l,s=r.useContext(u);if(s)return s;if(void 0!==i)return i;throw Error(`\`${n}\` must be used within \`${t}\``)}]},function(...e){let t=e[0];if(1===e.length)return t;let n=()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return function(e){let o=n.reduce((t,{useScope:n,scopeName:r})=>{let o=n(e)[`__scope${r}`];return{...t,...o}},{});return r.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}(i,...t)]}},1200:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Image",{enumerable:!0,get:function(){return w}});let r=n(5348),o=n(4900),i=n(3422),l=o._(n(4398)),a=r._(n(5707)),u=r._(n(4653)),s=n(2287),c=n(8585),d=n(3891);n(5145);let f=n(202),p=r._(n(7352)),m=n(7525),h={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image/",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!0};function g(e,t,n,r,o,i,l){let a=null==e?void 0:e.src;e&&e["data-loaded-src"]!==a&&(e["data-loaded-src"]=a,("decode"in e?e.decode():Promise.resolve()).catch(()=>{}).then(()=>{if(e.parentElement&&e.isConnected){if("empty"!==t&&o(!0),null==n?void 0:n.current){let t=new Event("load");Object.defineProperty(t,"target",{writable:!1,value:e});let r=!1,o=!1;n.current({...t,nativeEvent:t,currentTarget:e,target:e,isDefaultPrevented:()=>r,isPropagationStopped:()=>o,persist:()=>{},preventDefault:()=>{r=!0,t.preventDefault()},stopPropagation:()=>{o=!0,t.stopPropagation()}})}(null==r?void 0:r.current)&&r.current(e)}}))}function v(e){return l.use?{fetchPriority:e}:{fetchpriority:e}}let y=(0,l.forwardRef)((e,t)=>{let{src:n,srcSet:r,sizes:o,height:a,width:u,decoding:s,className:c,style:d,fetchPriority:f,placeholder:p,loading:h,unoptimized:y,fill:b,onLoadRef:w,onLoadingCompleteRef:x,setBlurComplete:E,setShowAltText:C,sizesInput:S,onLoad:R,onError:O,...P}=e,A=(0,l.useCallback)(e=>{e&&(O&&(e.src=e.src),e.complete&&g(e,p,w,x,E,y,S))},[n,p,w,x,E,O,y,S]),T=(0,m.useMergedRef)(t,A);return(0,i.jsx)("img",{...P,...v(f),loading:h,width:u,height:a,decoding:s,"data-nimg":b?"fill":"1",className:c,style:d,sizes:o,srcSet:r,src:n,ref:T,onLoad:e=>{g(e.currentTarget,p,w,x,E,y,S)},onError:e=>{C(!0),"empty"!==p&&E(!0),O&&O(e)}})});function b(e){let{isAppRouter:t,imgAttributes:n}=e,r={as:"image",imageSrcSet:n.srcSet,imageSizes:n.sizes,crossOrigin:n.crossOrigin,referrerPolicy:n.referrerPolicy,...v(n.fetchPriority)};return t&&a.default.preload?(a.default.preload(n.src,r),null):(0,i.jsx)(u.default,{children:(0,i.jsx)("link",{rel:"preload",href:n.srcSet?void 0:n.src,...r},"__nimg-"+n.src+n.srcSet+n.sizes)})}let w=(0,l.forwardRef)((e,t)=>{let n=(0,l.useContext)(f.RouterContext),r=(0,l.useContext)(d.ImageConfigContext),o=(0,l.useMemo)(()=>{var e;let t=h||r||c.imageConfigDefault,n=[...t.deviceSizes,...t.imageSizes].sort((e,t)=>e-t),o=t.deviceSizes.sort((e,t)=>e-t),i=null==(e=t.qualities)?void 0:e.sort((e,t)=>e-t);return{...t,allSizes:n,deviceSizes:o,qualities:i}},[r]),{onLoad:a,onLoadingComplete:u}=e,m=(0,l.useRef)(a);(0,l.useEffect)(()=>{m.current=a},[a]);let g=(0,l.useRef)(u);(0,l.useEffect)(()=>{g.current=u},[u]);let[v,w]=(0,l.useState)(!1),[x,E]=(0,l.useState)(!1),{props:C,meta:S}=(0,s.getImgProps)(e,{defaultLoader:p.default,imgConf:o,blurComplete:v,showAltText:x});return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(y,{...C,unoptimized:S.unoptimized,placeholder:S.placeholder,fill:S.fill,onLoadRef:m,onLoadingCompleteRef:g,setBlurComplete:w,setShowAltText:E,sizesInput:e.sizes,ref:t}),S.priority?(0,i.jsx)(b,{isAppRouter:!n,imgAttributes:C}):null]})});("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},1262:(e,t,n)=>{n.d(t,{D:()=>c,N:()=>d});var r=n(4398),o=(e,t,n,r,o,i,l,a)=>{let u=document.documentElement,s=["light","dark"];function c(t){var n;(Array.isArray(e)?e:[e]).forEach(e=>{let n="class"===e,r=n&&i?o.map(e=>i[e]||e):o;n?(u.classList.remove(...r),u.classList.add(i&&i[t]?i[t]:t)):u.setAttribute(e,t)}),n=t,a&&s.includes(n)&&(u.style.colorScheme=n)}if(r)c(r);else try{let e=localStorage.getItem(t)||n,r=l&&"system"===e?window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":e;c(r)}catch(e){}},i=["light","dark"],l="(prefers-color-scheme: dark)",a="undefined"==typeof window,u=r.createContext(void 0),s={setTheme:e=>{},themes:[]},c=()=>{var e;return null!=(e=r.useContext(u))?e:s},d=e=>r.useContext(u)?r.createElement(r.Fragment,null,e.children):r.createElement(p,{...e}),f=["light","dark"],p=e=>{let{forcedTheme:t,disableTransitionOnChange:n=!1,enableSystem:o=!0,enableColorScheme:a=!0,storageKey:s="theme",themes:c=f,defaultTheme:d=o?"system":"light",attribute:p="data-theme",value:y,children:b,nonce:w,scriptProps:x}=e,[E,C]=r.useState(()=>h(s,d)),[S,R]=r.useState(()=>"system"===E?v():E),O=y?Object.values(y):c,P=r.useCallback(e=>{let t=e;if(!t)return;"system"===e&&o&&(t=v());let r=y?y[t]:t,l=n?g(w):null,u=document.documentElement,s=e=>{"class"===e?(u.classList.remove(...O),r&&u.classList.add(r)):e.startsWith("data-")&&(r?u.setAttribute(e,r):u.removeAttribute(e))};if(Array.isArray(p)?p.forEach(s):s(p),a){let e=i.includes(d)?d:null,n=i.includes(t)?t:e;u.style.colorScheme=n}null==l||l()},[w]),A=r.useCallback(e=>{let t="function"==typeof e?e(E):e;C(t);try{localStorage.setItem(s,t)}catch(e){}},[E]),T=r.useCallback(e=>{R(v(e)),"system"===E&&o&&!t&&P("system")},[E,t]);r.useEffect(()=>{let e=window.matchMedia(l);return e.addListener(T),T(e),()=>e.removeListener(T)},[T]),r.useEffect(()=>{let e=e=>{e.key===s&&(e.newValue?C(e.newValue):A(d))};return window.addEventListener("storage",e),()=>window.removeEventListener("storage",e)},[A]),r.useEffect(()=>{P(null!=t?t:E)},[t,E]);let j=r.useMemo(()=>({theme:E,setTheme:A,forcedTheme:t,resolvedTheme:"system"===E?S:E,themes:o?[...c,"system"]:c,systemTheme:o?S:void 0}),[E,A,t,S,o,c]);return r.createElement(u.Provider,{value:j},r.createElement(m,{forcedTheme:t,storageKey:s,attribute:p,enableSystem:o,enableColorScheme:a,defaultTheme:d,value:y,themes:c,nonce:w,scriptProps:x}),b)},m=r.memo(e=>{let{forcedTheme:t,storageKey:n,attribute:i,enableSystem:l,enableColorScheme:a,defaultTheme:u,value:s,themes:c,nonce:d,scriptProps:f}=e,p=JSON.stringify([i,n,u,t,c,s,l,a]).slice(1,-1);return r.createElement("script",{...f,suppressHydrationWarning:!0,nonce:"undefined"==typeof window?d:"",dangerouslySetInnerHTML:{__html:"(".concat(o.toString(),")(").concat(p,")")}})}),h=(e,t)=>{let n;if(!a){try{n=localStorage.getItem(e)||void 0}catch(e){}return n||t}},g=e=>{let t=document.createElement("style");return e&&t.setAttribute("nonce",e),t.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(t),()=>{window.getComputedStyle(document.body),setTimeout(()=>{document.head.removeChild(t)},1)}},v=e=>(e||(e=window.matchMedia(l)),e.matches?"dark":"light")},1581:(e,t,n)=>{n.d(t,{Qg:()=>l,bL:()=>u});var r=n(4398),o=n(3780),i=n(3422),l=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"}),a=r.forwardRef((e,t)=>(0,i.jsx)(o.sG.span,{...e,ref:t,style:{...l,...e.style}}));a.displayName="VisuallyHidden";var u=a},1732:(e,t,n)=>{n.d(t,{Z:()=>u});var r=n(4398),o=n(5707),i=n(3780),l=n(3177),a=n(3422),u=r.forwardRef((e,t)=>{var n,u;let{container:s,...c}=e,[d,f]=r.useState(!1);(0,l.N)(()=>f(!0),[]);let p=s||d&&(null==(u=globalThis)||null==(n=u.document)?void 0:n.body);return p?o.createPortal((0,a.jsx)(i.sG.div,{...c,ref:t}),p):null});u.displayName="Portal"},2287:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getImgProps",{enumerable:!0,get:function(){return u}}),n(5145);let r=n(3605),o=n(8585),i=["-moz-initial","fill","none","scale-down",void 0];function l(e){return void 0!==e.default}function a(e){return void 0===e?e:"number"==typeof e?Number.isFinite(e)?e:NaN:"string"==typeof e&&/^[0-9]+$/.test(e)?parseInt(e,10):NaN}function u(e,t){var n,u;let s,c,d,{src:f,sizes:p,unoptimized:m=!1,priority:h=!1,loading:g,className:v,quality:y,width:b,height:w,fill:x=!1,style:E,overrideSrc:C,onLoad:S,onLoadingComplete:R,placeholder:O="empty",blurDataURL:P,fetchPriority:A,decoding:T="async",layout:j,objectFit:k,objectPosition:_,lazyBoundary:L,lazyRoot:N,...M}=e,{imgConf:D,showAltText:I,blurComplete:F,defaultLoader:z}=t,W=D||o.imageConfigDefault;if("allSizes"in W)s=W;else{let e=[...W.deviceSizes,...W.imageSizes].sort((e,t)=>e-t),t=W.deviceSizes.sort((e,t)=>e-t),r=null==(n=W.qualities)?void 0:n.sort((e,t)=>e-t);s={...W,allSizes:e,deviceSizes:t,qualities:r}}if(void 0===z)throw Object.defineProperty(Error("images.loaderFile detected but the file is missing default export.\nRead more: https://nextjs.org/docs/messages/invalid-images-config"),"__NEXT_ERROR_CODE",{value:"E163",enumerable:!1,configurable:!0});let B=M.loader||z;delete M.loader,delete M.srcSet;let U="__next_img_default"in B;if(U){if("custom"===s.loader)throw Object.defineProperty(Error('Image with src "'+f+'" is missing "loader" prop.\nRead more: https://nextjs.org/docs/messages/next-image-missing-loader'),"__NEXT_ERROR_CODE",{value:"E252",enumerable:!1,configurable:!0})}else{let e=B;B=t=>{let{config:n,...r}=t;return e(r)}}if(j){"fill"===j&&(x=!0);let e={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}}[j];e&&(E={...E,...e});let t={responsive:"100vw",fill:"100vw"}[j];t&&!p&&(p=t)}let H="",K=a(b),q=a(w);if((u=f)&&"object"==typeof u&&(l(u)||void 0!==u.src)){let e=l(f)?f.default:f;if(!e.src)throw Object.defineProperty(Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received "+JSON.stringify(e)),"__NEXT_ERROR_CODE",{value:"E460",enumerable:!1,configurable:!0});if(!e.height||!e.width)throw Object.defineProperty(Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received "+JSON.stringify(e)),"__NEXT_ERROR_CODE",{value:"E48",enumerable:!1,configurable:!0});if(c=e.blurWidth,d=e.blurHeight,P=P||e.blurDataURL,H=e.src,!x)if(K||q){if(K&&!q){let t=K/e.width;q=Math.round(e.height*t)}else if(!K&&q){let t=q/e.height;K=Math.round(e.width*t)}}else K=e.width,q=e.height}let V=!h&&("lazy"===g||void 0===g);(!(f="string"==typeof f?f:H)||f.startsWith("data:")||f.startsWith("blob:"))&&(m=!0,V=!1),s.unoptimized&&(m=!0),U&&!s.dangerouslyAllowSVG&&f.split("?",1)[0].endsWith(".svg")&&(m=!0);let G=a(y),X=Object.assign(x?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:k,objectPosition:_}:{},I?{}:{color:"transparent"},E),$=F||"empty"===O?null:"blur"===O?'url("data:image/svg+xml;charset=utf-8,'+(0,r.getImageBlurSvg)({widthInt:K,heightInt:q,blurWidth:c,blurHeight:d,blurDataURL:P||"",objectFit:X.objectFit})+'")':'url("'+O+'")',Y=i.includes(X.objectFit)?"fill"===X.objectFit?"100% 100%":"cover":X.objectFit,Z=$?{backgroundSize:Y,backgroundPosition:X.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:$}:{},J=function(e){let{config:t,src:n,unoptimized:r,width:o,quality:i,sizes:l,loader:a}=e;if(r)return{src:n,srcSet:void 0,sizes:void 0};let{widths:u,kind:s}=function(e,t,n){let{deviceSizes:r,allSizes:o}=e;if(n){let e=/(^|\s)(1?\d?\d)vw/g,t=[];for(let r;r=e.exec(n);)t.push(parseInt(r[2]));if(t.length){let e=.01*Math.min(...t);return{widths:o.filter(t=>t>=r[0]*e),kind:"w"}}return{widths:o,kind:"w"}}return"number"!=typeof t?{widths:r,kind:"w"}:{widths:[...new Set([t,2*t].map(e=>o.find(t=>t>=e)||o[o.length-1]))],kind:"x"}}(t,o,l),c=u.length-1;return{sizes:l||"w"!==s?l:"100vw",srcSet:u.map((e,r)=>a({config:t,src:n,quality:i,width:e})+" "+("w"===s?e:r+1)+s).join(", "),src:a({config:t,src:n,quality:i,width:u[c]})}}({config:s,src:f,unoptimized:m,width:K,quality:G,sizes:p,loader:B});return{props:{...M,loading:V?"lazy":g,fetchPriority:A,width:K,height:q,decoding:T,className:v,style:{...X,...Z},sizes:J.sizes,srcSet:J.srcSet,src:C||J.src},meta:{unoptimized:m,priority:h,placeholder:O,fill:x}}}},2305:(e,t)=>{function n(e){let{ampFirst:t=!1,hybrid:n=!1,hasQuery:r=!1}=void 0===e?{}:e;return t||n&&r}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"isInAmpMode",{enumerable:!0,get:function(){return n}})},2335:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("server",[["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"}]])},2727:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("layout-dashboard",[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]])},3138:(e,t,n)=>{n.d(t,{n:()=>d});var r=n(4398),o=n(2050),i=n(3780),l=n(7589),a=n(3422),u="focusScope.autoFocusOnMount",s="focusScope.autoFocusOnUnmount",c={bubbles:!1,cancelable:!0},d=r.forwardRef((e,t)=>{let{loop:n=!1,trapped:d=!1,onMountAutoFocus:g,onUnmountAutoFocus:v,...y}=e,[b,w]=r.useState(null),x=(0,l.c)(g),E=(0,l.c)(v),C=r.useRef(null),S=(0,o.s)(t,e=>w(e)),R=r.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;r.useEffect(()=>{if(d){let e=function(e){if(R.paused||!b)return;let t=e.target;b.contains(t)?C.current=t:m(C.current,{select:!0})},t=function(e){if(R.paused||!b)return;let t=e.relatedTarget;null!==t&&(b.contains(t)||m(C.current,{select:!0}))};document.addEventListener("focusin",e),document.addEventListener("focusout",t);let n=new MutationObserver(function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&m(b)});return b&&n.observe(b,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),n.disconnect()}}},[d,b,R.paused]),r.useEffect(()=>{if(b){h.add(R);let e=document.activeElement;if(!b.contains(e)){let t=new CustomEvent(u,c);b.addEventListener(u,x),b.dispatchEvent(t),t.defaultPrevented||(function(e){let{select:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=document.activeElement;for(let r of e)if(m(r,{select:t}),document.activeElement!==n)return}(f(b).filter(e=>"A"!==e.tagName),{select:!0}),document.activeElement===e&&m(b))}return()=>{b.removeEventListener(u,x),setTimeout(()=>{let t=new CustomEvent(s,c);b.addEventListener(s,E),b.dispatchEvent(t),t.defaultPrevented||m(null!=e?e:document.body,{select:!0}),b.removeEventListener(s,E),h.remove(R)},0)}}},[b,x,E,R]);let O=r.useCallback(e=>{if(!n&&!d||R.paused)return;let t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,r=document.activeElement;if(t&&r){let t=e.currentTarget,[o,i]=function(e){let t=f(e);return[p(t,e),p(t.reverse(),e)]}(t);o&&i?e.shiftKey||r!==i?e.shiftKey&&r===o&&(e.preventDefault(),n&&m(i,{select:!0})):(e.preventDefault(),n&&m(o,{select:!0})):r===t&&e.preventDefault()}},[n,d,R.paused]);return(0,a.jsx)(i.sG.div,{tabIndex:-1,...y,ref:S,onKeyDown:O})});function f(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function p(e,t){for(let n of e)if(!function(e,t){let{upTo:n}=t;if("hidden"===getComputedStyle(e).visibility)return!0;for(;e&&(void 0===n||e!==n);){if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}(n,{upTo:t}))return n}function m(e){let{select:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e&&e.focus){var n;let r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&(n=e)instanceof HTMLInputElement&&"select"in n&&t&&e.select()}}d.displayName="FocusScope";var h=function(){let e=[];return{add(t){let n=e[0];t!==n&&(null==n||n.pause()),(e=g(e,t)).unshift(t)},remove(t){var n;null==(n=(e=g(e,t))[0])||n.resume()}}}();function g(e,t){let n=[...e],r=n.indexOf(t);return -1!==r&&n.splice(r,1),n}},3177:(e,t,n)=>{n.d(t,{N:()=>o});var r=n(4398),o=globalThis?.document?r.useLayoutEffect:()=>{}},3213:(e,t,n)=>{n.d(t,{qW:()=>f});var r,o=n(4398),i=n(6687),l=n(3780),a=n(2050),u=n(7589),s=n(3422),c="dismissableLayer.update",d=o.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),f=o.forwardRef((e,t)=>{var n,f;let{disableOutsidePointerEvents:h=!1,onEscapeKeyDown:g,onPointerDownOutside:v,onFocusOutside:y,onInteractOutside:b,onDismiss:w,...x}=e,E=o.useContext(d),[C,S]=o.useState(null),R=null!=(f=null==C?void 0:C.ownerDocument)?f:null==(n=globalThis)?void 0:n.document,[,O]=o.useState({}),P=(0,a.s)(t,e=>S(e)),A=Array.from(E.layers),[T]=[...E.layersWithOutsidePointerEventsDisabled].slice(-1),j=A.indexOf(T),k=C?A.indexOf(C):-1,_=E.layersWithOutsidePointerEventsDisabled.size>0,L=k>=j,N=function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null==(t=globalThis)?void 0:t.document,r=(0,u.c)(e),i=o.useRef(!1),l=o.useRef(()=>{});return o.useEffect(()=>{let e=e=>{if(e.target&&!i.current){let t=function(){m("dismissableLayer.pointerDownOutside",r,o,{discrete:!0})},o={originalEvent:e};"touch"===e.pointerType?(n.removeEventListener("click",l.current),l.current=t,n.addEventListener("click",l.current,{once:!0})):t()}else n.removeEventListener("click",l.current);i.current=!1},t=window.setTimeout(()=>{n.addEventListener("pointerdown",e)},0);return()=>{window.clearTimeout(t),n.removeEventListener("pointerdown",e),n.removeEventListener("click",l.current)}},[n,r]),{onPointerDownCapture:()=>i.current=!0}}(e=>{let t=e.target,n=[...E.branches].some(e=>e.contains(t));L&&!n&&(null==v||v(e),null==b||b(e),e.defaultPrevented||null==w||w())},R),M=function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null==(t=globalThis)?void 0:t.document,r=(0,u.c)(e),i=o.useRef(!1);return o.useEffect(()=>{let e=e=>{e.target&&!i.current&&m("dismissableLayer.focusOutside",r,{originalEvent:e},{discrete:!1})};return n.addEventListener("focusin",e),()=>n.removeEventListener("focusin",e)},[n,r]),{onFocusCapture:()=>i.current=!0,onBlurCapture:()=>i.current=!1}}(e=>{let t=e.target;![...E.branches].some(e=>e.contains(t))&&(null==y||y(e),null==b||b(e),e.defaultPrevented||null==w||w())},R);return!function(e,t=globalThis?.document){let n=(0,u.c)(e);o.useEffect(()=>{let e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})},[n,t])}(e=>{k===E.layers.size-1&&(null==g||g(e),!e.defaultPrevented&&w&&(e.preventDefault(),w()))},R),o.useEffect(()=>{if(C)return h&&(0===E.layersWithOutsidePointerEventsDisabled.size&&(r=R.body.style.pointerEvents,R.body.style.pointerEvents="none"),E.layersWithOutsidePointerEventsDisabled.add(C)),E.layers.add(C),p(),()=>{h&&1===E.layersWithOutsidePointerEventsDisabled.size&&(R.body.style.pointerEvents=r)}},[C,R,h,E]),o.useEffect(()=>()=>{C&&(E.layers.delete(C),E.layersWithOutsidePointerEventsDisabled.delete(C),p())},[C,E]),o.useEffect(()=>{let e=()=>O({});return document.addEventListener(c,e),()=>document.removeEventListener(c,e)},[]),(0,s.jsx)(l.sG.div,{...x,ref:P,style:{pointerEvents:_?L?"auto":"none":void 0,...e.style},onFocusCapture:(0,i.mK)(e.onFocusCapture,M.onFocusCapture),onBlurCapture:(0,i.mK)(e.onBlurCapture,M.onBlurCapture),onPointerDownCapture:(0,i.mK)(e.onPointerDownCapture,N.onPointerDownCapture)})});function p(){let e=new CustomEvent(c);document.dispatchEvent(e)}function m(e,t,n,r){let{discrete:o}=r,i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),o?(0,l.hO)(i,a):i.dispatchEvent(a)}f.displayName="DismissableLayer",o.forwardRef((e,t)=>{let n=o.useContext(d),r=o.useRef(null),i=(0,a.s)(t,r);return o.useEffect(()=>{let e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,s.jsx)(l.sG.div,{...e,ref:i})}).displayName="DismissableLayerBranch"},3276:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{DecodeError:function(){return m},MiddlewareNotFoundError:function(){return y},MissingStaticPage:function(){return v},NormalizeError:function(){return h},PageNotFoundError:function(){return g},SP:function(){return f},ST:function(){return p},WEB_VITALS:function(){return n},execOnce:function(){return r},getDisplayName:function(){return u},getLocationOrigin:function(){return l},getURL:function(){return a},isAbsoluteUrl:function(){return i},isResSent:function(){return s},loadGetInitialProps:function(){return d},normalizeRepeatedSlashes:function(){return c},stringifyError:function(){return b}});let n=["CLS","FCP","FID","INP","LCP","TTFB"];function r(e){let t,n=!1;return function(){for(var r=arguments.length,o=Array(r),i=0;io.test(e);function l(){let{protocol:e,hostname:t,port:n}=window.location;return e+"//"+t+(n?":"+n:"")}function a(){let{href:e}=window.location,t=l();return e.substring(t.length)}function u(e){return"string"==typeof e?e:e.displayName||e.name||"Unknown"}function s(e){return e.finished||e.headersSent}function c(e){let t=e.split("?");return t[0].replace(/\\/g,"/").replace(/\/\/+/g,"/")+(t[1]?"?"+t.slice(1).join("?"):"")}async function d(e,t){let n=t.res||t.ctx&&t.ctx.res;if(!e.getInitialProps)return t.ctx&&t.Component?{pageProps:await d(t.Component,t.ctx)}:{};let r=await e.getInitialProps(t);if(n&&s(n))return r;if(!r)throw Object.defineProperty(Error('"'+u(e)+'.getInitialProps()" should resolve to an object. But found "'+r+'" instead.'),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return r}let f="undefined"!=typeof performance,p=f&&["mark","measure","getEntriesByName"].every(e=>"function"==typeof performance[e]);class m extends Error{}class h extends Error{}class g extends Error{constructor(e){super(),this.code="ENOENT",this.name="PageNotFoundError",this.message="Cannot find module for page: "+e}}class v extends Error{constructor(e,t){super(),this.message="Failed to load static file for page: "+e+" "+t}}class y extends Error{constructor(){super(),this.code="ENOENT",this.message="Cannot find the middleware module"}}function b(e){return JSON.stringify({message:e.message,stack:e.stack})}},3292:(e,t,n)=>{n.d(t,{b:()=>s});var r=n(4398),o=n(3780),i=n(3422),l="horizontal",a=["horizontal","vertical"],u=r.forwardRef((e,t)=>{var n;let{decorative:r,orientation:u=l,...s}=e,c=(n=u,a.includes(n))?u:l;return(0,i.jsx)(o.sG.div,{"data-orientation":c,...r?{role:"none"}:{"aria-orientation":"vertical"===c?c:void 0,role:"separator"},...s,ref:t})});u.displayName="Separator";var s=u},3338:(e,t,n)=>{n.d(t,{A:()=>V});var r,o,i=function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;nt.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}Object.create;Object.create;var a=("function"==typeof SuppressedError&&SuppressedError,n(4398)),u="right-scroll-bar-position",s="width-before-scroll-bar";function c(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var d="undefined"!=typeof window?a.useLayoutEffect:a.useEffect,f=new WeakMap;function p(e){return e}var m=function(e){void 0===e&&(e={});var t,n,r,o,l=(t=null,void 0===n&&(n=p),r=[],o=!1,{read:function(){if(o)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:null},useMedium:function(e){var t=n(e,o);return r.push(t),function(){r=r.filter(function(e){return e!==t})}},assignSyncMedium:function(e){for(o=!0;r.length;){var t=r;r=[],t.forEach(e)}r={push:function(t){return e(t)},filter:function(){return r}}},assignMedium:function(e){o=!0;var t=[];if(r.length){var n=r;r=[],n.forEach(e),t=r}var i=function(){var n=t;t=[],n.forEach(e)},l=function(){return Promise.resolve().then(i)};l(),r={push:function(e){t.push(e),l()},filter:function(e){return t=t.filter(e),r}}}});return l.options=i({async:!0,ssr:!1},e),l}(),h=function(){},g=a.forwardRef(function(e,t){var n,r,o,u,s=a.useRef(null),p=a.useState({onScrollCapture:h,onWheelCapture:h,onTouchMoveCapture:h}),g=p[0],v=p[1],y=e.forwardProps,b=e.children,w=e.className,x=e.removeScrollBar,E=e.enabled,C=e.shards,S=e.sideCar,R=e.noRelative,O=e.noIsolation,P=e.inert,A=e.allowPinchZoom,T=e.as,j=e.gapMode,k=l(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),_=(n=[s,t],r=function(e){return n.forEach(function(t){return c(t,e)})},(o=(0,a.useState)(function(){return{value:null,callback:r,facade:{get current(){return o.value},set current(value){var e=o.value;e!==value&&(o.value=value,o.callback(value,e))}}}})[0]).callback=r,u=o.facade,d(function(){var e=f.get(u);if(e){var t=new Set(e),r=new Set(n),o=u.current;t.forEach(function(e){r.has(e)||c(e,null)}),r.forEach(function(e){t.has(e)||c(e,o)})}f.set(u,n)},[n]),u),L=i(i({},k),g);return a.createElement(a.Fragment,null,E&&a.createElement(S,{sideCar:m,removeScrollBar:x,shards:C,noRelative:R,noIsolation:O,inert:P,setCallbacks:v,allowPinchZoom:!!A,lockRef:s,gapMode:j}),y?a.cloneElement(a.Children.only(b),i(i({},L),{ref:_})):a.createElement(void 0===T?"div":T,i({},L,{className:w,ref:_}),b))});g.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},g.classNames={fullWidth:s,zeroRight:u};var v=function(e){var t=e.sideCar,n=l(e,["sideCar"]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw Error("Sidecar medium not found");return a.createElement(r,i({},n))};v.isSideCarExport=!0;var y=function(){var e=0,t=null;return{add:function(r){if(0==e&&(t=function(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=o||n.nc;return t&&e.setAttribute("nonce",t),e}())){var i,l;(i=t).styleSheet?i.styleSheet.cssText=r:i.appendChild(document.createTextNode(r)),l=t,(document.head||document.getElementsByTagName("head")[0]).appendChild(l)}e++},remove:function(){--e||!t||(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},b=function(){var e=y();return function(t,n){a.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},w=function(){var e=b();return function(t){return e(t.styles,t.dynamic),null}},x={left:0,top:0,right:0,gap:0},E=function(e){return parseInt(e||"",10)||0},C=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingLeft":"marginLeft"],r=t["padding"===e?"paddingTop":"marginTop"],o=t["padding"===e?"paddingRight":"marginRight"];return[E(n),E(r),E(o)]},S=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return x;var t=C(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},R=w(),O="data-scroll-locked",P=function(e,t,n,r){var o=e.left,i=e.top,l=e.right,a=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(r,";\n padding-right: ").concat(a,"px ").concat(r,";\n }\n body[").concat(O,"] {\n overflow: hidden ").concat(r,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(r,";"),"margin"===n&&"\n padding-left: ".concat(o,"px;\n padding-top: ").concat(i,"px;\n padding-right: ").concat(l,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(a,"px ").concat(r,";\n "),"padding"===n&&"padding-right: ".concat(a,"px ").concat(r,";")].filter(Boolean).join(""),"\n }\n \n .").concat(u," {\n right: ").concat(a,"px ").concat(r,";\n }\n \n .").concat(s," {\n margin-right: ").concat(a,"px ").concat(r,";\n }\n \n .").concat(u," .").concat(u," {\n right: 0 ").concat(r,";\n }\n \n .").concat(s," .").concat(s," {\n margin-right: 0 ").concat(r,";\n }\n \n body[").concat(O,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(a,"px;\n }\n")},A=function(){var e=parseInt(document.body.getAttribute(O)||"0",10);return isFinite(e)?e:0},T=function(){a.useEffect(function(){return document.body.setAttribute(O,(A()+1).toString()),function(){var e=A()-1;e<=0?document.body.removeAttribute(O):document.body.setAttribute(O,e.toString())}},[])},j=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=void 0===r?"margin":r;T();var i=a.useMemo(function(){return S(o)},[o]);return a.createElement(R,{styles:P(i,!t,o,n?"":"!important")})},k=!1;if("undefined"!=typeof window)try{var _=Object.defineProperty({},"passive",{get:function(){return k=!0,!0}});window.addEventListener("test",_,_),window.removeEventListener("test",_,_)}catch(e){k=!1}var L=!!k&&{passive:!1},N=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&(n.overflowY!==n.overflowX||"TEXTAREA"===e.tagName||"visible"!==n[t])},M=function(e,t){var n=t.ownerDocument,r=t;do{if("undefined"!=typeof ShadowRoot&&r instanceof ShadowRoot&&(r=r.host),D(e,r)){var o=I(e,r);if(o[1]>o[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},D=function(e,t){return"v"===e?N(t,"overflowY"):N(t,"overflowX")},I=function(e,t){return"v"===e?[t.scrollTop,t.scrollHeight,t.clientHeight]:[t.scrollLeft,t.scrollWidth,t.clientWidth]},F=function(e,t,n,r,o){var i,l=(i=window.getComputedStyle(t).direction,"h"===e&&"rtl"===i?-1:1),a=l*r,u=n.target,s=t.contains(u),c=!1,d=a>0,f=0,p=0;do{if(!u)break;var m=I(e,u),h=m[0],g=m[1]-m[2]-l*h;(h||g)&&D(e,u)&&(f+=g,p+=h);var v=u.parentNode;u=v&&v.nodeType===Node.DOCUMENT_FRAGMENT_NODE?v.host:v}while(!s&&u!==document.body||s&&(t.contains(u)||t===u));return d&&(o&&1>Math.abs(f)||!o&&a>f)?c=!0:!d&&(o&&1>Math.abs(p)||!o&&-a>p)&&(c=!0),c},z=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},W=function(e){return[e.deltaX,e.deltaY]},B=function(e){return e&&"current"in e?e.current:e},U=0,H=[];let K=(r=function(e){var t=a.useRef([]),n=a.useRef([0,0]),r=a.useRef(),o=a.useState(U++)[0],i=a.useState(w)[0],l=a.useRef(e);a.useEffect(function(){l.current=e},[e]),a.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var t=(function(e,t,n){if(n||2==arguments.length)for(var r,o=0,i=t.length;oMath.abs(s)?"h":"v";if("touches"in e&&"h"===d&&"range"===c.type)return!1;var f=M(d,c);if(!f)return!0;if(f?o=d:(o="v"===d?"h":"v",f=M(d,c)),!f)return!1;if(!r.current&&"changedTouches"in e&&(u||s)&&(r.current=o),!o)return!0;var p=r.current||o;return F(p,t,e,"h"===p?u:s,!0)},[]),s=a.useCallback(function(e){if(H.length&&H[H.length-1]===i){var n="deltaY"in e?W(e):z(e),r=t.current.filter(function(t){var r;return t.name===e.type&&(t.target===e.target||e.target===t.shadowParent)&&(r=t.delta,r[0]===n[0]&&r[1]===n[1])})[0];if(r&&r.should){e.cancelable&&e.preventDefault();return}if(!r){var o=(l.current.shards||[]).map(B).filter(Boolean).filter(function(t){return t.contains(e.target)});(o.length>0?u(e,o[0]):!l.current.noIsolation)&&e.cancelable&&e.preventDefault()}}},[]),c=a.useCallback(function(e,n,r,o){var i={name:e,delta:n,target:r,should:o,shadowParent:function(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}(r)};t.current.push(i),setTimeout(function(){t.current=t.current.filter(function(e){return e!==i})},1)},[]),d=a.useCallback(function(e){n.current=z(e),r.current=void 0},[]),f=a.useCallback(function(t){c(t.type,W(t),t.target,u(t,e.lockRef.current))},[]),p=a.useCallback(function(t){c(t.type,z(t),t.target,u(t,e.lockRef.current))},[]);a.useEffect(function(){return H.push(i),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener("wheel",s,L),document.addEventListener("touchmove",s,L),document.addEventListener("touchstart",d,L),function(){H=H.filter(function(e){return e!==i}),document.removeEventListener("wheel",s,L),document.removeEventListener("touchmove",s,L),document.removeEventListener("touchstart",d,L)}},[]);var m=e.removeScrollBar,h=e.inert;return a.createElement(a.Fragment,null,h?a.createElement(i,{styles:"\n .block-interactivity-".concat(o," {pointer-events: none;}\n .allow-interactivity-").concat(o," {pointer-events: all;}\n")}):null,m?a.createElement(j,{noRelative:e.noRelative,gapMode:e.gapMode}):null)},m.useMedium(r),v);var q=a.forwardRef(function(e,t){return a.createElement(g,i({},e,{ref:t,sideCar:K}))});q.classNames=g.classNames;let V=q},3605:(e,t)=>{function n(e){let{widthInt:t,heightInt:n,blurWidth:r,blurHeight:o,blurDataURL:i,objectFit:l}=e,a=r?40*r:t,u=o?40*o:n,s=a&&u?"viewBox='0 0 "+a+" "+u+"'":"";return"%3Csvg xmlns='http://www.w3.org/2000/svg' "+s+"%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='"+(s?"none":"contain"===l?"xMidYMid":"cover"===l?"xMidYMid slice":"none")+"' style='filter: url(%23b);' href='"+i+"'/%3E%3C/svg%3E"}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getImageBlurSvg",{enumerable:!0,get:function(){return n}})},3674:(e,t)=>{function n(e){let t={};for(let[n,r]of e.entries()){let e=t[n];void 0===e?t[n]=r:Array.isArray(e)?e.push(r):t[n]=[e,r]}return t}function r(e){return"string"==typeof e?e:("number"!=typeof e||isNaN(e))&&"boolean"!=typeof e?"":String(e)}function o(e){let t=new URLSearchParams;for(let[n,o]of Object.entries(e))if(Array.isArray(o))for(let e of o)t.append(n,r(e));else t.set(n,r(o));return t}function i(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r{n.d(t,{A:()=>r});let r=(0,n(3929).A)("panel-left",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]])},3780:(e,t,n)=>{n.d(t,{hO:()=>u,sG:()=>a});var r=n(4398),o=n(5707),i=n(6950),l=n(3422),a=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,t)=>{let n=(0,i.TL)(`Primitive.${t}`),o=r.forwardRef((e,r)=>{let{asChild:o,...i}=e;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,l.jsx)(o?n:t,{...i,ref:r})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function u(e,t){e&&o.flushSync(()=>e.dispatchEvent(t))}},3871:(e,t,n)=>{n.d(t,{Eq:()=>c});var r=function(e){return"undefined"==typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},o=new WeakMap,i=new WeakMap,l={},a=0,u=function(e){return e&&(e.host||u(e.parentNode))},s=function(e,t,n,r){var s=(Array.isArray(e)?e:[e]).map(function(e){if(t.contains(e))return e;var n=u(e);return n&&t.contains(n)?n:(console.error("aria-hidden",e,"in not contained inside",t,". Doing nothing"),null)}).filter(function(e){return!!e});l[n]||(l[n]=new WeakMap);var c=l[n],d=[],f=new Set,p=new Set(s),m=function(e){!e||f.has(e)||(f.add(e),m(e.parentNode))};s.forEach(m);var h=function(e){!e||p.has(e)||Array.prototype.forEach.call(e.children,function(e){if(f.has(e))h(e);else try{var t=e.getAttribute(r),l=null!==t&&"false"!==t,a=(o.get(e)||0)+1,u=(c.get(e)||0)+1;o.set(e,a),c.set(e,u),d.push(e),1===a&&l&&i.set(e,!0),1===u&&e.setAttribute(n,"true"),l||e.setAttribute(r,"true")}catch(t){console.error("aria-hidden: cannot operate on ",e,t)}})};return h(t),f.clear(),a++,function(){d.forEach(function(e){var t=o.get(e)-1,l=c.get(e)-1;o.set(e,t),c.set(e,l),t||(i.has(e)||e.removeAttribute(r),i.delete(e)),l||e.removeAttribute(n)}),--a||(o=new WeakMap,o=new WeakMap,i=new WeakMap,l={})}},c=function(e,t,n){void 0===n&&(n="data-aria-hidden");var o=Array.from(Array.isArray(e)?e:[e]),i=t||r(e);return i?(o.push.apply(o,Array.from(i.querySelectorAll("[aria-live], script"))),s(o,i,n,"aria-hidden")):function(){return null}}},3891:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"ImageConfigContext",{enumerable:!0,get:function(){return i}});let r=n(5348)._(n(4398)),o=n(8585),i=r.default.createContext(o.imageConfigDefault)},3929:(e,t,n)=>{n.d(t,{A:()=>d});var r=n(4398);let o=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),i=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),l=e=>{let t=i(e);return t.charAt(0).toUpperCase()+t.slice(1)},a=function(){for(var e=arguments.length,t=Array(e),n=0;n!!e&&""!==e.trim()&&n.indexOf(e)===t).join(" ").trim()},u=e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0};var s={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"};let c=(0,r.forwardRef)((e,t)=>{let{color:n="currentColor",size:o=24,strokeWidth:i=2,absoluteStrokeWidth:l,className:c="",children:d,iconNode:f,...p}=e;return(0,r.createElement)("svg",{ref:t,...s,width:o,height:o,stroke:n,strokeWidth:l?24*Number(i)/Number(o):i,className:a("lucide",c),...!d&&!u(p)&&{"aria-hidden":"true"},...p},[...f.map(e=>{let[t,n]=e;return(0,r.createElement)(t,n)}),...Array.isArray(d)?d:[d]])}),d=(e,t)=>{let n=(0,r.forwardRef)((n,i)=>{let{className:u,...s}=n;return(0,r.createElement)(c,{ref:i,iconNode:t,className:a("lucide-".concat(o(l(e))),"lucide-".concat(e),u),...s})});return n.displayName=l(e),n}},4032:(e,t,n)=>{n.d(t,{Kq:()=>K,UC:()=>X,ZL:()=>G,bL:()=>q,i3:()=>$,l9:()=>V});var r=n(4398),o=n(6687),i=n(2050),l=n(940),a=n(3213),u=n(6565),s=n(6387),c=n(1732),d=n(6175),f=n(3780),p=n(6950),m=n(6657),h=n(1581),g=n(3422),[v,y]=(0,l.A)("Tooltip",[s.Bk]),b=(0,s.Bk)(),w="TooltipProvider",x="tooltip.open",[E,C]=v(w),S=e=>{let{__scopeTooltip:t,delayDuration:n=700,skipDelayDuration:o=300,disableHoverableContent:i=!1,children:l}=e,a=r.useRef(!0),u=r.useRef(!1),s=r.useRef(0);return r.useEffect(()=>{let e=s.current;return()=>window.clearTimeout(e)},[]),(0,g.jsx)(E,{scope:t,isOpenDelayedRef:a,delayDuration:n,onOpen:r.useCallback(()=>{window.clearTimeout(s.current),a.current=!1},[]),onClose:r.useCallback(()=>{window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.current=!0,o)},[o]),isPointerInTransitRef:u,onPointerInTransitChange:r.useCallback(e=>{u.current=e},[]),disableHoverableContent:i,children:l})};S.displayName=w;var R="Tooltip",[O,P]=v(R),A=e=>{let{__scopeTooltip:t,children:n,open:o,defaultOpen:i,onOpenChange:l,disableHoverableContent:a,delayDuration:c}=e,d=C(R,e.__scopeTooltip),f=b(t),[p,h]=r.useState(null),v=(0,u.B)(),y=r.useRef(0),w=null!=a?a:d.disableHoverableContent,E=null!=c?c:d.delayDuration,S=r.useRef(!1),[P,A]=(0,m.i)({prop:o,defaultProp:null!=i&&i,onChange:e=>{e?(d.onOpen(),document.dispatchEvent(new CustomEvent(x))):d.onClose(),null==l||l(e)},caller:R}),T=r.useMemo(()=>P?S.current?"delayed-open":"instant-open":"closed",[P]),j=r.useCallback(()=>{window.clearTimeout(y.current),y.current=0,S.current=!1,A(!0)},[A]),k=r.useCallback(()=>{window.clearTimeout(y.current),y.current=0,A(!1)},[A]),_=r.useCallback(()=>{window.clearTimeout(y.current),y.current=window.setTimeout(()=>{S.current=!0,A(!0),y.current=0},E)},[E,A]);return r.useEffect(()=>()=>{y.current&&(window.clearTimeout(y.current),y.current=0)},[]),(0,g.jsx)(s.bL,{...f,children:(0,g.jsx)(O,{scope:t,contentId:v,open:P,stateAttribute:T,trigger:p,onTriggerChange:h,onTriggerEnter:r.useCallback(()=>{d.isOpenDelayedRef.current?_():j()},[d.isOpenDelayedRef,_,j]),onTriggerLeave:r.useCallback(()=>{w?k():(window.clearTimeout(y.current),y.current=0)},[k,w]),onOpen:j,onClose:k,disableHoverableContent:w,children:n})})};A.displayName=R;var T="TooltipTrigger",j=r.forwardRef((e,t)=>{let{__scopeTooltip:n,...l}=e,a=P(T,n),u=C(T,n),c=b(n),d=r.useRef(null),p=(0,i.s)(t,d,a.onTriggerChange),m=r.useRef(!1),h=r.useRef(!1),v=r.useCallback(()=>m.current=!1,[]);return r.useEffect(()=>()=>document.removeEventListener("pointerup",v),[v]),(0,g.jsx)(s.Mz,{asChild:!0,...c,children:(0,g.jsx)(f.sG.button,{"aria-describedby":a.open?a.contentId:void 0,"data-state":a.stateAttribute,...l,ref:p,onPointerMove:(0,o.mK)(e.onPointerMove,e=>{"touch"!==e.pointerType&&(h.current||u.isPointerInTransitRef.current||(a.onTriggerEnter(),h.current=!0))}),onPointerLeave:(0,o.mK)(e.onPointerLeave,()=>{a.onTriggerLeave(),h.current=!1}),onPointerDown:(0,o.mK)(e.onPointerDown,()=>{a.open&&a.onClose(),m.current=!0,document.addEventListener("pointerup",v,{once:!0})}),onFocus:(0,o.mK)(e.onFocus,()=>{m.current||a.onOpen()}),onBlur:(0,o.mK)(e.onBlur,a.onClose),onClick:(0,o.mK)(e.onClick,a.onClose)})})});j.displayName=T;var k="TooltipPortal",[_,L]=v(k,{forceMount:void 0}),N=e=>{let{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,i=P(k,t);return(0,g.jsx)(_,{scope:t,forceMount:n,children:(0,g.jsx)(d.C,{present:n||i.open,children:(0,g.jsx)(c.Z,{asChild:!0,container:o,children:r})})})};N.displayName=k;var M="TooltipContent",D=r.forwardRef((e,t)=>{let n=L(M,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...i}=e,l=P(M,e.__scopeTooltip);return(0,g.jsx)(d.C,{present:r||l.open,children:l.disableHoverableContent?(0,g.jsx)(B,{side:o,...i,ref:t}):(0,g.jsx)(I,{side:o,...i,ref:t})})}),I=r.forwardRef((e,t)=>{let n=P(M,e.__scopeTooltip),o=C(M,e.__scopeTooltip),l=r.useRef(null),a=(0,i.s)(t,l),[u,s]=r.useState(null),{trigger:c,onClose:d}=n,f=l.current,{onPointerInTransitChange:p}=o,m=r.useCallback(()=>{s(null),p(!1)},[p]),h=r.useCallback((e,t)=>{let n=e.currentTarget,r={x:e.clientX,y:e.clientY},o=function(e,t){let n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,o,i)){case i:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw Error("unreachable")}}(r,n.getBoundingClientRect());s(function(e){let t=e.slice();return t.sort((e,t)=>e.xt.x?1:e.yt.y)),function(e){if(e.length<=1)return e.slice();let t=[];for(let n=0;n=2;){let e=t[t.length-1],n=t[t.length-2];if((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x))t.pop();else break}t.push(r)}t.pop();let n=[];for(let t=e.length-1;t>=0;t--){let r=e[t];for(;n.length>=2;){let e=n[n.length-1],t=n[n.length-2];if((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.x))n.pop();else break}n.push(r)}return(n.pop(),1===t.length&&1===n.length&&t[0].x===n[0].x&&t[0].y===n[0].y)?t:t.concat(n)}(t)}([...function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n})}return r}(r,o),...function(e){let{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}(t.getBoundingClientRect())])),p(!0)},[p]);return r.useEffect(()=>()=>m(),[m]),r.useEffect(()=>{if(c&&f){let e=e=>h(e,f),t=e=>h(e,c);return c.addEventListener("pointerleave",e),f.addEventListener("pointerleave",t),()=>{c.removeEventListener("pointerleave",e),f.removeEventListener("pointerleave",t)}}},[c,f,h,m]),r.useEffect(()=>{if(u){let e=e=>{let t=e.target,n={x:e.clientX,y:e.clientY},r=(null==c?void 0:c.contains(t))||(null==f?void 0:f.contains(t)),o=!function(e,t){let{x:n,y:r}=e,o=!1;for(let e=0,i=t.length-1;er!=d>r&&n<(c-u)*(r-s)/(d-s)+u&&(o=!o)}return o}(n,u);r?m():o&&(m(),d())};return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}},[c,f,u,d,m]),(0,g.jsx)(B,{...e,ref:a})}),[F,z]=v(R,{isInside:!1}),W=(0,p.Dc)("TooltipContent"),B=r.forwardRef((e,t)=>{let{__scopeTooltip:n,children:o,"aria-label":i,onEscapeKeyDown:l,onPointerDownOutside:u,...c}=e,d=P(M,n),f=b(n),{onClose:p}=d;return r.useEffect(()=>(document.addEventListener(x,p),()=>document.removeEventListener(x,p)),[p]),r.useEffect(()=>{if(d.trigger){let e=e=>{let t=e.target;(null==t?void 0:t.contains(d.trigger))&&p()};return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}},[d.trigger,p]),(0,g.jsx)(a.qW,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:e=>e.preventDefault(),onDismiss:p,children:(0,g.jsxs)(s.UC,{"data-state":d.stateAttribute,...f,...c,ref:t,style:{...c.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:[(0,g.jsx)(W,{children:o}),(0,g.jsx)(F,{scope:n,isInside:!0,children:(0,g.jsx)(h.bL,{id:d.contentId,role:"tooltip",children:i||o})})]})})});D.displayName=M;var U="TooltipArrow",H=r.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,o=b(n);return z(U,n).isInside?null:(0,g.jsx)(s.i3,{...o,...r,ref:t})});H.displayName=U;var K=S,q=A,V=j,G=N,X=D,$=H},4059:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{default:function(){return u},getImageProps:function(){return a}});let r=n(5348),o=n(2287),i=n(1200),l=r._(n(7352));function a(e){let{props:t}=(0,o.getImgProps)(e,{defaultLoader:l.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image/",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!0}});for(let[e,n]of Object.entries(t))void 0===n&&delete t[e];return{props:t}}let u=i.Image},4316:(e,t,n)=>{n.d(t,{G$:()=>X,Hs:()=>x,UC:()=>en,VY:()=>eo,ZL:()=>ee,bL:()=>J,bm:()=>ei,hE:()=>er,hJ:()=>et,l9:()=>Q});var r=n(4398),o=n(6687),i=n(2050),l=n(940),a=n(6565),u=n(6657),s=n(3213),c=n(3138),d=n(1732),f=n(6175),p=n(3780),m=n(7),h=n(3338),g=n(3871),v=n(6950),y=n(3422),b="Dialog",[w,x]=(0,l.A)(b),[E,C]=w(b),S=e=>{let{__scopeDialog:t,children:n,open:o,defaultOpen:i,onOpenChange:l,modal:s=!0}=e,c=r.useRef(null),d=r.useRef(null),[f,p]=(0,u.i)({prop:o,defaultProp:null!=i&&i,onChange:l,caller:b});return(0,y.jsx)(E,{scope:t,triggerRef:c,contentRef:d,contentId:(0,a.B)(),titleId:(0,a.B)(),descriptionId:(0,a.B)(),open:f,onOpenChange:p,onOpenToggle:r.useCallback(()=>p(e=>!e),[p]),modal:s,children:n})};S.displayName=b;var R="DialogTrigger",O=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,l=C(R,n),a=(0,i.s)(t,l.triggerRef);return(0,y.jsx)(p.sG.button,{type:"button","aria-haspopup":"dialog","aria-expanded":l.open,"aria-controls":l.contentId,"data-state":V(l.open),...r,ref:a,onClick:(0,o.mK)(e.onClick,l.onOpenToggle)})});O.displayName=R;var P="DialogPortal",[A,T]=w(P,{forceMount:void 0}),j=e=>{let{__scopeDialog:t,forceMount:n,children:o,container:i}=e,l=C(P,t);return(0,y.jsx)(A,{scope:t,forceMount:n,children:r.Children.map(o,e=>(0,y.jsx)(f.C,{present:n||l.open,children:(0,y.jsx)(d.Z,{asChild:!0,container:i,children:e})}))})};j.displayName=P;var k="DialogOverlay",_=r.forwardRef((e,t)=>{let n=T(k,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=C(k,e.__scopeDialog);return i.modal?(0,y.jsx)(f.C,{present:r||i.open,children:(0,y.jsx)(N,{...o,ref:t})}):null});_.displayName=k;var L=(0,v.TL)("DialogOverlay.RemoveScroll"),N=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,o=C(k,n);return(0,y.jsx)(h.A,{as:L,allowPinchZoom:!0,shards:[o.contentRef],children:(0,y.jsx)(p.sG.div,{"data-state":V(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),M="DialogContent",D=r.forwardRef((e,t)=>{let n=T(M,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=C(M,e.__scopeDialog);return(0,y.jsx)(f.C,{present:r||i.open,children:i.modal?(0,y.jsx)(I,{...o,ref:t}):(0,y.jsx)(F,{...o,ref:t})})});D.displayName=M;var I=r.forwardRef((e,t)=>{let n=C(M,e.__scopeDialog),l=r.useRef(null),a=(0,i.s)(t,n.contentRef,l);return r.useEffect(()=>{let e=l.current;if(e)return(0,g.Eq)(e)},[]),(0,y.jsx)(z,{...e,ref:a,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:(0,o.mK)(e.onCloseAutoFocus,e=>{var t;e.preventDefault(),null==(t=n.triggerRef.current)||t.focus()}),onPointerDownOutside:(0,o.mK)(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey;(2===t.button||n)&&e.preventDefault()}),onFocusOutside:(0,o.mK)(e.onFocusOutside,e=>e.preventDefault())})}),F=r.forwardRef((e,t)=>{let n=C(M,e.__scopeDialog),o=r.useRef(!1),i=r.useRef(!1);return(0,y.jsx)(z,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var r,l;null==(r=e.onCloseAutoFocus)||r.call(e,t),t.defaultPrevented||(o.current||null==(l=n.triggerRef.current)||l.focus(),t.preventDefault()),o.current=!1,i.current=!1},onInteractOutside:t=>{var r,l;null==(r=e.onInteractOutside)||r.call(e,t),t.defaultPrevented||(o.current=!0,"pointerdown"===t.detail.originalEvent.type&&(i.current=!0));let a=t.target;(null==(l=n.triggerRef.current)?void 0:l.contains(a))&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&i.current&&t.preventDefault()}})}),z=r.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:o,onOpenAutoFocus:l,onCloseAutoFocus:a,...u}=e,d=C(M,n),f=r.useRef(null),p=(0,i.s)(t,f);return(0,m.Oh)(),(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(c.n,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:l,onUnmountAutoFocus:a,children:(0,y.jsx)(s.qW,{role:"dialog",id:d.contentId,"aria-describedby":d.descriptionId,"aria-labelledby":d.titleId,"data-state":V(d.open),...u,ref:p,onDismiss:()=>d.onOpenChange(!1)})}),(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(Y,{titleId:d.titleId}),(0,y.jsx)(Z,{contentRef:f,descriptionId:d.descriptionId})]})]})}),W="DialogTitle",B=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,o=C(W,n);return(0,y.jsx)(p.sG.h2,{id:o.titleId,...r,ref:t})});B.displayName=W;var U="DialogDescription",H=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,o=C(U,n);return(0,y.jsx)(p.sG.p,{id:o.descriptionId,...r,ref:t})});H.displayName=U;var K="DialogClose",q=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=C(K,n);return(0,y.jsx)(p.sG.button,{type:"button",...r,ref:t,onClick:(0,o.mK)(e.onClick,()=>i.onOpenChange(!1))})});function V(e){return e?"open":"closed"}q.displayName=K;var G="DialogTitleWarning",[X,$]=(0,l.q)(G,{contentName:M,titleName:W,docsSlug:"dialog"}),Y=e=>{let{titleId:t}=e,n=$(G),o="`".concat(n.contentName,"` requires a `").concat(n.titleName,"` for the component to be accessible for screen reader users.\n\nIf you want to hide the `").concat(n.titleName,"`, you can wrap it with our VisuallyHidden component.\n\nFor more information, see https://radix-ui.com/primitives/docs/components/").concat(n.docsSlug);return r.useEffect(()=>{t&&(document.getElementById(t)||console.error(o))},[o,t]),null},Z=e=>{let{contentRef:t,descriptionId:n}=e,o=$("DialogDescriptionWarning"),i="Warning: Missing `Description` or `aria-describedby={undefined}` for {".concat(o.contentName,"}.");return r.useEffect(()=>{var e;let r=null==(e=t.current)?void 0:e.getAttribute("aria-describedby");n&&r&&(document.getElementById(n)||console.warn(i))},[i,t,n]),null},J=S,Q=O,ee=j,et=_,en=D,er=B,eo=H,ei=q},4357:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]])},4450:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{formatUrl:function(){return i},formatWithValidation:function(){return a},urlObjectKeys:function(){return l}});let r=n(4900)._(n(3674)),o=/https?|ftp|gopher|file/;function i(e){let{auth:t,hostname:n}=e,i=e.protocol||"",l=e.pathname||"",a=e.hash||"",u=e.query||"",s=!1;t=t?encodeURIComponent(t).replace(/%3A/i,":")+"@":"",e.host?s=t+e.host:n&&(s=t+(~n.indexOf(":")?"["+n+"]":n),e.port&&(s+=":"+e.port)),u&&"object"==typeof u&&(u=String(r.urlQueryToSearchParams(u)));let c=e.search||u&&"?"+u||"";return i&&!i.endsWith(":")&&(i+=":"),e.slashes||(!i||o.test(i))&&!1!==s?(s="//"+(s||""),l&&"/"!==l[0]&&(l="/"+l)):s||(s=""),a&&"#"!==a[0]&&(a="#"+a),c&&"?"!==c[0]&&(c="?"+c),""+i+s+(l=l.replace(/[?#]/g,encodeURIComponent))+(c=c.replace("#","%23"))+a}let l=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function a(e){return i(e)}},4653:(e,t,n)=>{var r=n(3124);Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{default:function(){return g},defaultHead:function(){return f}});let o=n(5348),i=n(4900),l=n(3422),a=i._(n(4398)),u=o._(n(5178)),s=n(9749),c=n(5157),d=n(2305);function f(e){void 0===e&&(e=!1);let t=[(0,l.jsx)("meta",{charSet:"utf-8"},"charset")];return e||t.push((0,l.jsx)("meta",{name:"viewport",content:"width=device-width"},"viewport")),t}function p(e,t){return"string"==typeof t||"number"==typeof t?e:t.type===a.default.Fragment?e.concat(a.default.Children.toArray(t.props.children).reduce((e,t)=>"string"==typeof t||"number"==typeof t?e:e.concat(t),[])):e.concat(t)}n(5145);let m=["name","httpEquiv","charSet","itemProp"];function h(e,t){let{inAmpMode:n}=t;return e.reduce(p,[]).reverse().concat(f(n).reverse()).filter(function(){let e=new Set,t=new Set,n=new Set,r={};return o=>{let i=!0,l=!1;if(o.key&&"number"!=typeof o.key&&o.key.indexOf("$")>0){l=!0;let t=o.key.slice(o.key.indexOf("$")+1);e.has(t)?i=!1:e.add(t)}switch(o.type){case"title":case"base":t.has(o.type)?i=!1:t.add(o.type);break;case"meta":for(let e=0,t=m.length;e{let o=e.key||t;if(r.env.__NEXT_OPTIMIZE_FONTS&&!n&&"link"===e.type&&e.props.href&&["https://fonts.googleapis.com/css","https://use.typekit.net/"].some(t=>e.props.href.startsWith(t))){let t={...e.props||{}};return t["data-href"]=t.href,t.href=void 0,t["data-optimized-fonts"]=!0,a.default.cloneElement(e,t)}return a.default.cloneElement(e,{key:o})})}let g=function(e){let{children:t}=e,n=(0,a.useContext)(s.AmpStateContext),r=(0,a.useContext)(c.HeadManagerContext);return(0,l.jsx)(u.default,{reduceComponentsToState:h,headManager:r,inAmpMode:(0,d.isInAmpMode)(n),children:t})};("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},4753:(e,t,n)=>{n.d(t,{X:()=>i});var r=n(4398),o=n(3177);function i(e){let[t,n]=r.useState(void 0);return(0,o.N)(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{let r,o;if(!Array.isArray(t)||!t.length)return;let i=t[0];if("borderBoxSize"in i){let e=i.borderBoxSize,t=Array.isArray(e)?e[0]:e;r=t.inlineSize,o=t.blockSize}else r=e.offsetWidth,o=e.offsetHeight;n({width:r,height:o})});return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)},[e]),t}},5178:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return l}});let r=n(4398),o=r.useLayoutEffect,i=r.useEffect;function l(e){let{headManager:t,reduceComponentsToState:n}=e;function l(){if(t&&t.mountedInstances){let o=r.Children.toArray(Array.from(t.mountedInstances).filter(Boolean));t.updateHead(n(o,e))}}return o(()=>{var n;return null==t||null==(n=t.mountedInstances)||n.add(e.children),()=>{var n;null==t||null==(n=t.mountedInstances)||n.delete(e.children)}}),o(()=>(t&&(t._pendingUpdate=l),()=>{t&&(t._pendingUpdate=l)})),i(()=>(t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null),()=>{t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null)})),null}},5746:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("sun",[["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"}]])},6175:(e,t,n)=>{n.d(t,{C:()=>l});var r=n(4398),o=n(2050),i=n(3177),l=e=>{let{present:t,children:n}=e,l=function(e){var t,n;let[o,l]=r.useState(),u=r.useRef(null),s=r.useRef(e),c=r.useRef("none"),[d,f]=(t=e?"mounted":"unmounted",n={mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}},r.useReducer((e,t)=>{let r=n[e][t];return null!=r?r:e},t));return r.useEffect(()=>{let e=a(u.current);c.current="mounted"===d?e:"none"},[d]),(0,i.N)(()=>{let t=u.current,n=s.current;if(n!==e){let r=c.current,o=a(t);e?f("MOUNT"):"none"===o||(null==t?void 0:t.display)==="none"?f("UNMOUNT"):n&&r!==o?f("ANIMATION_OUT"):f("UNMOUNT"),s.current=e}},[e,f]),(0,i.N)(()=>{if(o){var e;let t,n=null!=(e=o.ownerDocument.defaultView)?e:window,r=e=>{let r=a(u.current).includes(CSS.escape(e.animationName));if(e.target===o&&r&&(f("ANIMATION_END"),!s.current)){let e=o.style.animationFillMode;o.style.animationFillMode="forwards",t=n.setTimeout(()=>{"forwards"===o.style.animationFillMode&&(o.style.animationFillMode=e)})}},i=e=>{e.target===o&&(c.current=a(u.current))};return o.addEventListener("animationstart",i),o.addEventListener("animationcancel",r),o.addEventListener("animationend",r),()=>{n.clearTimeout(t),o.removeEventListener("animationstart",i),o.removeEventListener("animationcancel",r),o.removeEventListener("animationend",r)}}f("ANIMATION_END")},[o,f]),{isPresent:["mounted","unmountSuspended"].includes(d),ref:r.useCallback(e=>{u.current=e?getComputedStyle(e):null,l(e)},[])}}(t),u="function"==typeof n?n({present:l.isPresent}):r.Children.only(n),s=(0,o.s)(l.ref,function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?e.ref:(o=(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get)&&"isReactWarning"in r&&r.isReactWarning)?e.props.ref:e.props.ref||e.ref}(u));return"function"==typeof n||l.isPresent?r.cloneElement(u,{ref:s}):null};function a(e){return(null==e?void 0:e.animationName)||"none"}l.displayName="Presence"},6387:(e,t,n)=>{n.d(t,{Mz:()=>te,i3:()=>tn,UC:()=>tt,bL:()=>e6,Bk:()=>eG});var r=n(4398);let o=["top","right","bottom","left"],i=Math.min,l=Math.max,a=Math.round,u=Math.floor,s=e=>({x:e,y:e}),c={left:"right",right:"left",bottom:"top",top:"bottom"},d={start:"end",end:"start"};function f(e,t){return"function"==typeof e?e(t):e}function p(e){return e.split("-")[0]}function m(e){return e.split("-")[1]}function h(e){return"x"===e?"y":"x"}function g(e){return"y"===e?"height":"width"}let v=new Set(["top","bottom"]);function y(e){return v.has(p(e))?"y":"x"}function b(e){return e.replace(/start|end/g,e=>d[e])}let w=["left","right"],x=["right","left"],E=["top","bottom"],C=["bottom","top"];function S(e){return e.replace(/left|right|bottom|top/g,e=>c[e])}function R(e){return"number"!=typeof e?{top:0,right:0,bottom:0,left:0,...e}:{top:e,right:e,bottom:e,left:e}}function O(e){let{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function P(e,t,n){let r,{reference:o,floating:i}=e,l=y(t),a=h(y(t)),u=g(a),s=p(t),c="y"===l,d=o.x+o.width/2-i.width/2,f=o.y+o.height/2-i.height/2,v=o[u]/2-i[u]/2;switch(s){case"top":r={x:d,y:o.y-i.height};break;case"bottom":r={x:d,y:o.y+o.height};break;case"right":r={x:o.x+o.width,y:f};break;case"left":r={x:o.x-i.width,y:f};break;default:r={x:o.x,y:o.y}}switch(m(t)){case"start":r[a]-=v*(n&&c?-1:1);break;case"end":r[a]+=v*(n&&c?-1:1)}return r}let A=async(e,t,n)=>{let{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:l}=n,a=i.filter(Boolean),u=await (null==l.isRTL?void 0:l.isRTL(t)),s=await l.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:d}=P(s,r,u),f=r,p={},m=0;for(let n=0;ne[t]>=0)}let _=new Set(["left","top"]);async function L(e,t){let{placement:n,platform:r,elements:o}=e,i=await (null==r.isRTL?void 0:r.isRTL(o.floating)),l=p(n),a=m(n),u="y"===y(n),s=_.has(l)?-1:1,c=i&&u?-1:1,d=f(t,e),{mainAxis:h,crossAxis:g,alignmentAxis:v}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&"number"==typeof v&&(g="end"===a?-1*v:v),u?{x:g*c,y:h*s}:{x:h*s,y:g*c}}function N(){return"undefined"!=typeof window}function M(e){return F(e)?(e.nodeName||"").toLowerCase():"#document"}function D(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function I(e){var t;return null==(t=(F(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function F(e){return!!N()&&(e instanceof Node||e instanceof D(e).Node)}function z(e){return!!N()&&(e instanceof Element||e instanceof D(e).Element)}function W(e){return!!N()&&(e instanceof HTMLElement||e instanceof D(e).HTMLElement)}function B(e){return!!N()&&"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof D(e).ShadowRoot)}let U=new Set(["inline","contents"]);function H(e){let{overflow:t,overflowX:n,overflowY:r,display:o}=ee(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!U.has(o)}let K=new Set(["table","td","th"]),q=[":popover-open",":modal"];function V(e){return q.some(t=>{try{return e.matches(t)}catch(e){return!1}})}let G=["transform","translate","scale","rotate","perspective"],X=["transform","translate","scale","rotate","perspective","filter"],$=["paint","layout","strict","content"];function Y(e){let t=Z(),n=z(e)?ee(e):e;return G.some(e=>!!n[e]&&"none"!==n[e])||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||X.some(e=>(n.willChange||"").includes(e))||$.some(e=>(n.contain||"").includes(e))}function Z(){return"undefined"!=typeof CSS&&!!CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")}let J=new Set(["html","body","#document"]);function Q(e){return J.has(M(e))}function ee(e){return D(e).getComputedStyle(e)}function et(e){return z(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function en(e){if("html"===M(e))return e;let t=e.assignedSlot||e.parentNode||B(e)&&e.host||I(e);return B(t)?t.host:t}function er(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);let o=function e(t){let n=en(t);return Q(n)?t.ownerDocument?t.ownerDocument.body:t.body:W(n)&&H(n)?n:e(n)}(e),i=o===(null==(r=e.ownerDocument)?void 0:r.body),l=D(o);if(i){let e=eo(l);return t.concat(l,l.visualViewport||[],H(o)?o:[],e&&n?er(e):[])}return t.concat(o,er(o,[],n))}function eo(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ei(e){let t=ee(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,o=W(e),i=o?e.offsetWidth:n,l=o?e.offsetHeight:r,u=a(n)!==i||a(r)!==l;return u&&(n=i,r=l),{width:n,height:r,$:u}}function el(e){return z(e)?e:e.contextElement}function ea(e){let t=el(e);if(!W(t))return s(1);let n=t.getBoundingClientRect(),{width:r,height:o,$:i}=ei(t),l=(i?a(n.width):n.width)/r,u=(i?a(n.height):n.height)/o;return l&&Number.isFinite(l)||(l=1),u&&Number.isFinite(u)||(u=1),{x:l,y:u}}let eu=s(0);function es(e){let t=D(e);return Z()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:eu}function ec(e,t,n,r){var o;void 0===t&&(t=!1),void 0===n&&(n=!1);let i=e.getBoundingClientRect(),l=el(e),a=s(1);t&&(r?z(r)&&(a=ea(r)):a=ea(e));let u=(void 0===(o=n)&&(o=!1),r&&(!o||r===D(l))&&o)?es(l):s(0),c=(i.left+u.x)/a.x,d=(i.top+u.y)/a.y,f=i.width/a.x,p=i.height/a.y;if(l){let e=D(l),t=r&&z(r)?D(r):r,n=e,o=eo(n);for(;o&&r&&t!==n;){let e=ea(o),t=o.getBoundingClientRect(),r=ee(o),i=t.left+(o.clientLeft+parseFloat(r.paddingLeft))*e.x,l=t.top+(o.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,d*=e.y,f*=e.x,p*=e.y,c+=i,d+=l,o=eo(n=D(o))}}return O({width:f,height:p,x:c,y:d})}function ed(e,t){let n=et(e).scrollLeft;return t?t.left+n:ec(I(e)).left+n}function ef(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-ed(e,n),y:n.top+t.scrollTop}}let ep=new Set(["absolute","fixed"]);function em(e,t,n){let r;if("viewport"===t)r=function(e,t){let n=D(e),r=I(e),o=n.visualViewport,i=r.clientWidth,l=r.clientHeight,a=0,u=0;if(o){i=o.width,l=o.height;let e=Z();(!e||e&&"fixed"===t)&&(a=o.offsetLeft,u=o.offsetTop)}let s=ed(r);if(s<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),o="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,l=Math.abs(r.clientWidth-t.clientWidth-o);l<=25&&(i-=l)}else s<=25&&(i+=s);return{width:i,height:l,x:a,y:u}}(e,n);else if("document"===t)r=function(e){let t=I(e),n=et(e),r=e.ownerDocument.body,o=l(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=l(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),a=-n.scrollLeft+ed(e),u=-n.scrollTop;return"rtl"===ee(r).direction&&(a+=l(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:a,y:u}}(I(e));else if(z(t))r=function(e,t){let n=ec(e,!0,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=W(e)?ea(e):s(1),l=e.clientWidth*i.x,a=e.clientHeight*i.y;return{width:l,height:a,x:o*i.x,y:r*i.y}}(t,n);else{let n=es(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return O(r)}function eh(e){return"static"===ee(e).position}function eg(e,t){if(!W(e)||"fixed"===ee(e).position)return null;if(t)return t(e);let n=e.offsetParent;return I(e)===n&&(n=n.ownerDocument.body),n}function ev(e,t){var n;let r=D(e);if(V(e))return r;if(!W(e)){let t=en(e);for(;t&&!Q(t);){if(z(t)&&!eh(t))return t;t=en(t)}return r}let o=eg(e,t);for(;o&&(n=o,K.has(M(n)))&&eh(o);)o=eg(o,t);return o&&Q(o)&&eh(o)&&!Y(o)?r:o||function(e){let t=en(e);for(;W(t)&&!Q(t);){if(Y(t))return t;if(V(t))break;t=en(t)}return null}(e)||r}let ey=async function(e){let t=this.getOffsetParent||ev,n=this.getDimensions,r=await n(e.floating);return{reference:function(e,t,n){let r=W(t),o=I(t),i="fixed"===n,l=ec(e,!0,i,t),a={scrollLeft:0,scrollTop:0},u=s(0);if(r||!r&&!i)if(("body"!==M(t)||H(o))&&(a=et(t)),r){let e=ec(t,!0,i,t);u.x=e.x+t.clientLeft,u.y=e.y+t.clientTop}else o&&(u.x=ed(o));i&&!r&&o&&(u.x=ed(o));let c=!o||r||i?s(0):ef(o,a);return{x:l.left+a.scrollLeft-u.x-c.x,y:l.top+a.scrollTop-u.y-c.y,width:l.width,height:l.height}}(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},eb={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e,i="fixed"===o,l=I(r),a=!!t&&V(t.floating);if(r===l||a&&i)return n;let u={scrollLeft:0,scrollTop:0},c=s(1),d=s(0),f=W(r);if((f||!f&&!i)&&(("body"!==M(r)||H(l))&&(u=et(r)),W(r))){let e=ec(r);c=ea(r),d.x=e.x+r.clientLeft,d.y=e.y+r.clientTop}let p=!l||f||i?s(0):ef(l,u);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-u.scrollLeft*c.x+d.x+p.x,y:n.y*c.y-u.scrollTop*c.y+d.y+p.y}},getDocumentElement:I,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e,a=[..."clippingAncestors"===n?V(t)?[]:function(e,t){let n=t.get(e);if(n)return n;let r=er(e,[],!1).filter(e=>z(e)&&"body"!==M(e)),o=null,i="fixed"===ee(e).position,l=i?en(e):e;for(;z(l)&&!Q(l);){let t=ee(l),n=Y(l);n||"fixed"!==t.position||(o=null),(i?!n&&!o:!n&&"static"===t.position&&!!o&&ep.has(o.position)||H(l)&&!n&&function e(t,n){let r=en(t);return!(r===n||!z(r)||Q(r))&&("fixed"===ee(r).position||e(r,n))}(e,l))?r=r.filter(e=>e!==l):o=t,l=en(l)}return t.set(e,r),r}(t,this._c):[].concat(n),r],u=a[0],s=a.reduce((e,n)=>{let r=em(t,n,o);return e.top=l(r.top,e.top),e.right=i(r.right,e.right),e.bottom=i(r.bottom,e.bottom),e.left=l(r.left,e.left),e},em(t,u,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:ev,getElementRects:ey,getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){let{width:t,height:n}=ei(e);return{width:t,height:n}},getScale:ea,isElement:z,isRTL:function(e){return"rtl"===ee(e).direction}};function ew(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}let ex=e=>({name:"arrow",options:e,async fn(t){let{x:n,y:r,placement:o,rects:a,platform:u,elements:s,middlewareData:c}=t,{element:d,padding:p=0}=f(e,t)||{};if(null==d)return{};let v=R(p),b={x:n,y:r},w=h(y(o)),x=g(w),E=await u.getDimensions(d),C="y"===w,S=C?"clientHeight":"clientWidth",O=a.reference[x]+a.reference[w]-b[w]-a.floating[x],P=b[w]-a.reference[w],A=await (null==u.getOffsetParent?void 0:u.getOffsetParent(d)),T=A?A[S]:0;T&&await (null==u.isElement?void 0:u.isElement(A))||(T=s.floating[S]||a.floating[x]);let j=T/2-E[x]/2-1,k=i(v[C?"top":"left"],j),_=i(v[C?"bottom":"right"],j),L=T-E[x]-_,N=T/2-E[x]/2+(O/2-P/2),M=l(k,i(N,L)),D=!c.arrow&&null!=m(o)&&N!==M&&a.reference[x]/2-(N{let r=new Map,o={platform:eb,...n},i={...o.platform,_c:r};return A(e,t,{...o,platform:i})};var eC=n(5707),eS="undefined"!=typeof document?r.useLayoutEffect:function(){};function eR(e,t){let n,r,o;if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if((n=e.length)!==t.length)return!1;for(r=n;0!=r--;)if(!eR(e[r],t[r]))return!1;return!0}if((n=(o=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!({}).hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){let n=o[r];if(("_owner"!==n||!e.$$typeof)&&!eR(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function eO(e){return"undefined"==typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function eP(e,t){let n=eO(e);return Math.round(t*n)/n}function eA(e){let t=r.useRef(e);return eS(()=>{t.current=e}),t}let eT=e=>({name:"arrow",options:e,fn(t){let{element:n,padding:r}="function"==typeof e?e(t):e;return n&&({}).hasOwnProperty.call(n,"current")?null!=n.current?ex({element:n.current,padding:r}).fn(t):{}:n?ex({element:n,padding:r}).fn(t):{}}}),ej=(e,t)=>({...function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;let{x:o,y:i,placement:l,middlewareData:a}=t,u=await L(t,e);return l===(null==(n=a.offset)?void 0:n.placement)&&null!=(r=a.arrow)&&r.alignmentOffset?{}:{x:o+u.x,y:i+u.y,data:{...u,placement:l}}}}}(e),options:[e,t]}),ek=(e,t)=>({...function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){let{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:u=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...c}=f(e,t),d={x:n,y:r},m=await T(t,c),g=y(p(o)),v=h(g),b=d[v],w=d[g];if(a){let e="y"===v?"top":"left",t="y"===v?"bottom":"right",n=b+m[e],r=b-m[t];b=l(n,i(b,r))}if(u){let e="y"===g?"top":"left",t="y"===g?"bottom":"right",n=w+m[e],r=w-m[t];w=l(n,i(w,r))}let x=s.fn({...t,[v]:b,[g]:w});return{...x,data:{x:x.x-n,y:x.y-r,enabled:{[v]:a,[g]:u}}}}}}(e),options:[e,t]}),e_=(e,t)=>({...function(e){return void 0===e&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:o,rects:i,middlewareData:l}=t,{offset:a=0,mainAxis:u=!0,crossAxis:s=!0}=f(e,t),c={x:n,y:r},d=y(o),m=h(d),g=c[m],v=c[d],b=f(a,t),w="number"==typeof b?{mainAxis:b,crossAxis:0}:{mainAxis:0,crossAxis:0,...b};if(u){let e="y"===m?"height":"width",t=i.reference[m]-i.floating[e]+w.mainAxis,n=i.reference[m]+i.reference[e]-w.mainAxis;gn&&(g=n)}if(s){var x,E;let e="y"===m?"width":"height",t=_.has(p(o)),n=i.reference[d]-i.floating[e]+(t&&(null==(x=l.offset)?void 0:x[d])||0)+(t?0:w.crossAxis),r=i.reference[d]+i.reference[e]+(t?0:(null==(E=l.offset)?void 0:E[d])||0)-(t?w.crossAxis:0);vr&&(v=r)}return{[m]:g,[d]:v}}}}(e),options:[e,t]}),eL=(e,t)=>({...function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r,o,i,l;let{placement:a,middlewareData:u,rects:s,initialPlacement:c,platform:d,elements:v}=t,{mainAxis:R=!0,crossAxis:O=!0,fallbackPlacements:P,fallbackStrategy:A="bestFit",fallbackAxisSideDirection:j="none",flipAlignment:k=!0,..._}=f(e,t);if(null!=(n=u.arrow)&&n.alignmentOffset)return{};let L=p(a),N=y(c),M=p(c)===c,D=await (null==d.isRTL?void 0:d.isRTL(v.floating)),I=P||(M||!k?[S(c)]:function(e){let t=S(e);return[b(e),t,b(t)]}(c)),F="none"!==j;!P&&F&&I.push(...function(e,t,n,r){let o=m(e),i=function(e,t,n){switch(e){case"top":case"bottom":if(n)return t?x:w;return t?w:x;case"left":case"right":return t?E:C;default:return[]}}(p(e),"start"===n,r);return o&&(i=i.map(e=>e+"-"+o),t&&(i=i.concat(i.map(b)))),i}(c,k,j,D));let z=[c,...I],W=await T(t,_),B=[],U=(null==(r=u.flip)?void 0:r.overflows)||[];if(R&&B.push(W[L]),O){let e=function(e,t,n){void 0===n&&(n=!1);let r=m(e),o=h(y(e)),i=g(o),l="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[i]>t.floating[i]&&(l=S(l)),[l,S(l)]}(a,s,D);B.push(W[e[0]],W[e[1]])}if(U=[...U,{placement:a,overflows:B}],!B.every(e=>e<=0)){let e=((null==(o=u.flip)?void 0:o.index)||0)+1,t=z[e];if(t&&("alignment"!==O||N===y(t)||U.every(e=>y(e.placement)!==N||e.overflows[0]>0)))return{data:{index:e,overflows:U},reset:{placement:t}};let n=null==(i=U.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:i.placement;if(!n)switch(A){case"bestFit":{let e=null==(l=U.filter(e=>{if(F){let t=y(e.placement);return t===N||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:l[0];e&&(n=e);break}case"initialPlacement":n=c}if(a!==n)return{reset:{placement:n}}}return{}}}}(e),options:[e,t]}),eN=(e,t)=>({...function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;let o,a,{placement:u,rects:s,platform:c,elements:d}=t,{apply:h=()=>{},...g}=f(e,t),v=await T(t,g),b=p(u),w=m(u),x="y"===y(u),{width:E,height:C}=s.floating;"top"===b||"bottom"===b?(o=b,a=w===(await (null==c.isRTL?void 0:c.isRTL(d.floating))?"start":"end")?"left":"right"):(a=b,o="end"===w?"top":"bottom");let S=C-v.top-v.bottom,R=E-v.left-v.right,O=i(C-v[o],S),P=i(E-v[a],R),A=!t.middlewareData.shift,j=O,k=P;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(k=R),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(j=S),A&&!w){let e=l(v.left,0),t=l(v.right,0),n=l(v.top,0),r=l(v.bottom,0);x?k=E-2*(0!==e||0!==t?e+t:l(v.left,v.right)):j=C-2*(0!==n||0!==r?n+r:l(v.top,v.bottom))}await h({...t,availableWidth:k,availableHeight:j});let _=await c.getDimensions(d.floating);return E!==_.width||C!==_.height?{reset:{rects:!0}}:{}}}}(e),options:[e,t]}),eM=(e,t)=>({...function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){let{rects:n}=t,{strategy:r="referenceHidden",...o}=f(e,t);switch(r){case"referenceHidden":{let e=j(await T(t,{...o,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:k(e)}}}case"escaped":{let e=j(await T(t,{...o,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:k(e)}}}default:return{}}}}}(e),options:[e,t]}),eD=(e,t)=>({...eT(e),options:[e,t]});var eI=n(3780),eF=n(3422),ez=r.forwardRef((e,t)=>{let{children:n,width:r=10,height:o=5,...i}=e;return(0,eF.jsx)(eI.sG.svg,{...i,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:(0,eF.jsx)("polygon",{points:"0,0 30,0 15,10"})})});ez.displayName="Arrow";var eW=n(2050),eB=n(940),eU=n(7589),eH=n(3177),eK=n(4753),eq="Popper",[eV,eG]=(0,eB.A)(eq),[eX,e$]=eV(eq),eY=e=>{let{__scopePopper:t,children:n}=e,[o,i]=r.useState(null);return(0,eF.jsx)(eX,{scope:t,anchor:o,onAnchorChange:i,children:n})};eY.displayName=eq;var eZ="PopperAnchor",eJ=r.forwardRef((e,t)=>{let{__scopePopper:n,virtualRef:o,...i}=e,l=e$(eZ,n),a=r.useRef(null),u=(0,eW.s)(t,a),s=r.useRef(null);return r.useEffect(()=>{let e=s.current;s.current=(null==o?void 0:o.current)||a.current,e!==s.current&&l.onAnchorChange(s.current)}),o?null:(0,eF.jsx)(eI.sG.div,{...i,ref:u})});eJ.displayName=eZ;var eQ="PopperContent",[e0,e1]=eV(eQ),e2=r.forwardRef((e,t)=>{var n,o,a,s,c,d,f,p;let{__scopePopper:m,side:h="bottom",sideOffset:g=0,align:v="center",alignOffset:y=0,arrowPadding:b=0,avoidCollisions:w=!0,collisionBoundary:x=[],collisionPadding:E=0,sticky:C="partial",hideWhenDetached:S=!1,updatePositionStrategy:R="optimized",onPlaced:O,...P}=e,A=e$(eQ,m),[T,j]=r.useState(null),k=(0,eW.s)(t,e=>j(e)),[_,L]=r.useState(null),N=(0,eK.X)(_),M=null!=(f=null==N?void 0:N.width)?f:0,D=null!=(p=null==N?void 0:N.height)?p:0,F="number"==typeof E?E:{top:0,right:0,bottom:0,left:0,...E},z=Array.isArray(x)?x:[x],W=z.length>0,B={padding:F,boundary:z.filter(e8),altBoundary:W},{refs:U,floatingStyles:H,placement:K,isPositioned:q,middlewareData:V}=function(e){void 0===e&&(e={});let{placement:t="bottom",strategy:n="absolute",middleware:o=[],platform:i,elements:{reference:l,floating:a}={},transform:u=!0,whileElementsMounted:s,open:c}=e,[d,f]=r.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,m]=r.useState(o);eR(p,o)||m(o);let[h,g]=r.useState(null),[v,y]=r.useState(null),b=r.useCallback(e=>{e!==C.current&&(C.current=e,g(e))},[]),w=r.useCallback(e=>{e!==S.current&&(S.current=e,y(e))},[]),x=l||h,E=a||v,C=r.useRef(null),S=r.useRef(null),R=r.useRef(d),O=null!=s,P=eA(s),A=eA(i),T=eA(c),j=r.useCallback(()=>{if(!C.current||!S.current)return;let e={placement:t,strategy:n,middleware:p};A.current&&(e.platform=A.current),eE(C.current,S.current,e).then(e=>{let t={...e,isPositioned:!1!==T.current};k.current&&!eR(R.current,t)&&(R.current=t,eC.flushSync(()=>{f(t)}))})},[p,t,n,A,T]);eS(()=>{!1===c&&R.current.isPositioned&&(R.current.isPositioned=!1,f(e=>({...e,isPositioned:!1})))},[c]);let k=r.useRef(!1);eS(()=>(k.current=!0,()=>{k.current=!1}),[]),eS(()=>{if(x&&(C.current=x),E&&(S.current=E),x&&E){if(P.current)return P.current(x,E,j);j()}},[x,E,j,P,O]);let _=r.useMemo(()=>({reference:C,floating:S,setReference:b,setFloating:w}),[b,w]),L=r.useMemo(()=>({reference:x,floating:E}),[x,E]),N=r.useMemo(()=>{let e={position:n,left:0,top:0};if(!L.floating)return e;let t=eP(L.floating,d.x),r=eP(L.floating,d.y);return u?{...e,transform:"translate("+t+"px, "+r+"px)",...eO(L.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}},[n,u,L.floating,d.x,d.y]);return r.useMemo(()=>({...d,update:j,refs:_,elements:L,floatingStyles:N}),[d,j,_,L,N])}({strategy:"fixed",placement:h+("center"!==v?"-"+v:""),whileElementsMounted:function(){for(var e=arguments.length,t=Array(e),n=0;n{a&&e.addEventListener("scroll",n,{passive:!0}),s&&e.addEventListener("resize",n)});let h=p&&d?function(e,t){let n,r=null,o=I(e);function a(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return!function s(c,d){void 0===c&&(c=!1),void 0===d&&(d=1),a();let f=e.getBoundingClientRect(),{left:p,top:m,width:h,height:g}=f;if(c||t(),!h||!g)return;let v=u(m),y=u(o.clientWidth-(p+h)),b={rootMargin:-v+"px "+-y+"px "+-u(o.clientHeight-(m+g))+"px "+-u(p)+"px",threshold:l(0,i(1,d))||1},w=!0;function x(t){let r=t[0].intersectionRatio;if(r!==d){if(!w)return s();r?s(!1,r):n=setTimeout(()=>{s(!1,1e-7)},1e3)}1!==r||ew(f,e.getBoundingClientRect())||s(),w=!1}try{r=new IntersectionObserver(x,{...b,root:o.ownerDocument})}catch(e){r=new IntersectionObserver(x,b)}r.observe(e)}(!0),a}(p,n):null,g=-1,v=null;c&&(v=new ResizeObserver(e=>{let[r]=e;r&&r.target===p&&v&&(v.unobserve(t),cancelAnimationFrame(g),g=requestAnimationFrame(()=>{var e;null==(e=v)||e.observe(t)})),n()}),p&&!f&&v.observe(p),v.observe(t));let y=f?ec(e):null;return f&&function t(){let r=ec(e);y&&!ew(y,r)&&n(),y=r,o=requestAnimationFrame(t)}(),n(),()=>{var e;m.forEach(e=>{a&&e.removeEventListener("scroll",n),s&&e.removeEventListener("resize",n)}),null==h||h(),null==(e=v)||e.disconnect(),v=null,f&&cancelAnimationFrame(o)}}(...t,{animationFrame:"always"===R})},elements:{reference:A.anchor},middleware:[ej({mainAxis:g+D,alignmentAxis:y}),w&&ek({mainAxis:!0,crossAxis:!1,limiter:"partial"===C?e_():void 0,...B}),w&&eL({...B}),eN({...B,apply:e=>{let{elements:t,rects:n,availableWidth:r,availableHeight:o}=e,{width:i,height:l}=n.reference,a=t.floating.style;a.setProperty("--radix-popper-available-width","".concat(r,"px")),a.setProperty("--radix-popper-available-height","".concat(o,"px")),a.setProperty("--radix-popper-anchor-width","".concat(i,"px")),a.setProperty("--radix-popper-anchor-height","".concat(l,"px"))}}),_&&eD({element:_,padding:b}),e5({arrowWidth:M,arrowHeight:D}),S&&eM({strategy:"referenceHidden",...B})]}),[G,X]=e9(K),$=(0,eU.c)(O);(0,eH.N)(()=>{q&&(null==$||$())},[q,$]);let Y=null==(n=V.arrow)?void 0:n.x,Z=null==(o=V.arrow)?void 0:o.y,J=(null==(a=V.arrow)?void 0:a.centerOffset)!==0,[Q,ee]=r.useState();return(0,eH.N)(()=>{T&&ee(window.getComputedStyle(T).zIndex)},[T]),(0,eF.jsx)("div",{ref:U.setFloating,"data-radix-popper-content-wrapper":"",style:{...H,transform:q?H.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Q,"--radix-popper-transform-origin":[null==(s=V.transformOrigin)?void 0:s.x,null==(c=V.transformOrigin)?void 0:c.y].join(" "),...(null==(d=V.hide)?void 0:d.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:(0,eF.jsx)(e0,{scope:m,placedSide:G,onArrowChange:L,arrowX:Y,arrowY:Z,shouldHideArrow:J,children:(0,eF.jsx)(eI.sG.div,{"data-side":G,"data-align":X,...P,ref:k,style:{...P.style,animation:q?void 0:"none"}})})})});e2.displayName=eQ;var e3="PopperArrow",e7={top:"bottom",right:"left",bottom:"top",left:"right"},e4=r.forwardRef(function(e,t){let{__scopePopper:n,...r}=e,o=e1(e3,n),i=e7[o.placedSide];return(0,eF.jsx)("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0},children:(0,eF.jsx)(ez,{...r,ref:t,style:{...r.style,display:"block"}})})});function e8(e){return null!==e}e4.displayName=e3;var e5=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,l;let{placement:a,rects:u,middlewareData:s}=t,c=(null==(n=s.arrow)?void 0:n.centerOffset)!==0,d=c?0:e.arrowWidth,f=c?0:e.arrowHeight,[p,m]=e9(a),h={start:"0%",center:"50%",end:"100%"}[m],g=(null!=(i=null==(r=s.arrow)?void 0:r.x)?i:0)+d/2,v=(null!=(l=null==(o=s.arrow)?void 0:o.y)?l:0)+f/2,y="",b="";return"bottom"===p?(y=c?h:"".concat(g,"px"),b="".concat(-f,"px")):"top"===p?(y=c?h:"".concat(g,"px"),b="".concat(u.floating.height+f,"px")):"right"===p?(y="".concat(-f,"px"),b=c?h:"".concat(v,"px")):"left"===p&&(y="".concat(u.floating.width+f,"px"),b=c?h:"".concat(v,"px")),{data:{x:y,y:b}}}});function e9(e){let[t,n="center"]=e.split("-");return[t,n]}var e6=eY,te=eJ,tt=e2,tn=e4},6565:(e,t,n)=>{n.d(t,{B:()=>u});var r,o=n(4398),i=n(3177),l=(r||(r=n.t(o,2)))[" useId ".trim().toString()]||(()=>void 0),a=0;function u(e){let[t,n]=o.useState(l());return(0,i.N)(()=>{e||n(e=>e??String(a++))},[e]),e||(t?`radix-${t}`:"")}},6631:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{default:function(){return g},useLinkStatus:function(){return y}});let r=n(4900),o=n(3422),i=r._(n(4398)),l=n(4450),a=n(9260),u=n(3051),s=n(7525),c=n(3276),d=n(2886);n(5145);let f=n(6863),p=n(7179),m=n(5747);function h(e){return"string"==typeof e?e:(0,l.formatUrl)(e)}function g(e){let t,n,r,[l,g]=(0,i.useOptimistic)(f.IDLE_LINK_STATUS),y=(0,i.useRef)(null),{href:b,as:w,children:x,prefetch:E=null,passHref:C,replace:S,shallow:R,scroll:O,onClick:P,onMouseEnter:A,onTouchStart:T,legacyBehavior:j=!1,onNavigate:k,ref:_,unstable_dynamicOnHover:L,...N}=e;t=x,j&&("string"==typeof t||"number"==typeof t)&&(t=(0,o.jsx)("a",{children:t}));let M=i.default.useContext(a.AppRouterContext),D=!1!==E,I=null===E?u.PrefetchKind.AUTO:u.PrefetchKind.FULL,{href:F,as:z}=i.default.useMemo(()=>{let e=h(b);return{href:e,as:w?h(w):e}},[b,w]);j&&(n=i.default.Children.only(t));let W=j?n&&"object"==typeof n&&n.ref:_,B=i.default.useCallback(e=>(null!==M&&(y.current=(0,f.mountLinkInstance)(e,F,M,I,D,g)),()=>{y.current&&((0,f.unmountLinkForCurrentNavigation)(y.current),y.current=null),(0,f.unmountPrefetchableInstance)(e)}),[D,F,M,I,g]),U={ref:(0,s.useMergedRef)(B,W),onClick(e){j||"function"!=typeof P||P(e),j&&n.props&&"function"==typeof n.props.onClick&&n.props.onClick(e),M&&(e.defaultPrevented||function(e,t,n,r,o,l,a){let{nodeName:u}=e.currentTarget;if(!("A"===u.toUpperCase()&&function(e){let t=e.currentTarget.getAttribute("target");return t&&"_self"!==t||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey||e.nativeEvent&&2===e.nativeEvent.which}(e)||e.currentTarget.hasAttribute("download"))){if(!(0,p.isLocalURL)(t)){o&&(e.preventDefault(),location.replace(t));return}e.preventDefault(),i.default.startTransition(()=>{if(a){let e=!1;if(a({preventDefault:()=>{e=!0}}),e)return}(0,m.dispatchNavigateAction)(n||t,o?"replace":"push",null==l||l,r.current)})}}(e,F,z,y,S,O,k))},onMouseEnter(e){j||"function"!=typeof A||A(e),j&&n.props&&"function"==typeof n.props.onMouseEnter&&n.props.onMouseEnter(e),M&&D&&(0,f.onNavigationIntent)(e.currentTarget,!0===L)},onTouchStart:function(e){j||"function"!=typeof T||T(e),j&&n.props&&"function"==typeof n.props.onTouchStart&&n.props.onTouchStart(e),M&&D&&(0,f.onNavigationIntent)(e.currentTarget,!0===L)}};return(0,c.isAbsoluteUrl)(z)?U.href=z:j&&!C&&("a"!==n.type||"href"in n.props)||(U.href=(0,d.addBasePath)(z)),r=j?i.default.cloneElement(n,U):(0,o.jsx)("a",{...N,...U,children:t}),(0,o.jsx)(v.Provider,{value:l,children:r})}n(777);let v=(0,i.createContext)(f.IDLE_LINK_STATUS),y=()=>(0,i.useContext)(v);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},6657:(e,t,n)=>{n.d(t,{i:()=>a});var r,o=n(4398),i=n(3177),l=(r||(r=n.t(o,2)))[" useInsertionEffect ".trim().toString()]||i.N;function a({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){let[i,a,u]=function({defaultProp:e,onChange:t}){let[n,r]=o.useState(e),i=o.useRef(n),a=o.useRef(t);return l(()=>{a.current=t},[t]),o.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}({defaultProp:t,onChange:n}),s=void 0!==e,c=s?e:i;{let t=o.useRef(void 0!==e);o.useEffect(()=>{let e=t.current;if(e!==s){let t=s?"controlled":"uncontrolled";console.warn(`${r} is changing from ${e?"controlled":"uncontrolled"} to ${t}. 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.`)}t.current=s},[s,r])}return[c,o.useCallback(t=>{if(s){let n="function"==typeof t?t(e):t;n!==e&&u.current?.(n)}else a(t)},[s,e,a,u])]}Symbol("RADIX:SYNC_STATE")},6687:(e,t,n)=>{n.d(t,{mK:()=>o});var r=!!("undefined"!=typeof window&&window.document&&window.document.createElement);function o(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r.defaultPrevented)return t?.(r)}}},6701:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]])},7179:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"isLocalURL",{enumerable:!0,get:function(){return i}});let r=n(3276),o=n(4970);function i(e){if(!(0,r.isAbsoluteUrl)(e))return!0;try{let t=(0,r.getLocationOrigin)(),n=new URL(e,t);return n.origin===t&&(0,o.hasBasePath)(n.pathname)}catch(e){return!1}}},7352:(e,t)=>{function n(e){var t;let{config:n,src:r,width:o,quality:i}=e,l=i||(null==(t=n.qualities)?void 0:t.reduce((e,t)=>Math.abs(t-75){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"useMergedRef",{enumerable:!0,get:function(){return o}});let r=n(4398);function o(e,t){let n=(0,r.useRef)(null),o=(0,r.useRef)(null);return(0,r.useCallback)(r=>{if(null===r){let e=n.current;e&&(n.current=null,e());let t=o.current;t&&(o.current=null,t())}else e&&(n.current=i(e,r)),t&&(o.current=i(t,r))},[e,t])}function i(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let n=e(t);return"function"==typeof n?n:()=>e(null)}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},7589:(e,t,n)=>{n.d(t,{c:()=>o});var r=n(4398);function o(e){let t=r.useRef(e);return r.useEffect(()=>{t.current=e}),r.useMemo(()=>(...e)=>t.current?.(...e),[])}},8019:(e,t,n)=>{n.d(t,{default:()=>o.a});var r=n(4059),o=n.n(r)},8585:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{VALID_LOADERS:function(){return n},imageConfigDefault:function(){return r}});let n=["default","imgix","cloudinary","akamai","custom"],r={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",loaderFile:"",domains:[],disableStaticImages:!1,minimumCacheTTL:60,formats:["image/webp"],dangerouslyAllowSVG:!1,contentSecurityPolicy:"script-src 'none'; frame-src 'none'; sandbox;",contentDispositionType:"attachment",localPatterns:void 0,remotePatterns:[],qualities:void 0,unoptimized:!1}},9285:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]])},9675:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("circle-alert",[["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"}]])},9680:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},9749:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"AmpStateContext",{enumerable:!0,get:function(){return r}});let r=n(5348)._(n(4398)).default.createContext({})},9779:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("log-out",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]])}}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/236-d1820fdf10fbc413.js b/ui_out/_next/static/chunks/236-d1820fdf10fbc413.js deleted file mode 100644 index 2f825960..00000000 --- a/ui_out/_next/static/chunks/236-d1820fdf10fbc413.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[236],{268:(e,t,a)=>{a.d(t,{p:()=>i});var r=a(3422);a(4398);var n=a(9183);function i(e){let{className:t,type:a,...i}=e;return(0,r.jsx)("input",{type:a,"data-slot":"input",className:(0,n.cn)("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input flex 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",t),...i})}},953:(e,t,a)=>{a.d(t,{Bx:()=>k,Yv:()=>C,Cn:()=>A,rQ:()=>z,Gh:()=>S,SidebarInset:()=>_,wZ:()=>I,Uj:()=>U,FX:()=>B,SidebarProvider:()=>j,x2:()=>N});var r=a(3422),n=a(4398),i=a(6950),o=a(4676),s=a(3712),l=a(9183),d=a(3648);a(268),a(5349);var c=a(4316),u=a(9680);function h(e){let{...t}=e;return(0,r.jsx)(c.bL,{"data-slot":"sheet",...t})}function g(e){let{...t}=e;return(0,r.jsx)(c.ZL,{"data-slot":"sheet-portal",...t})}function p(e){let{className:t,...a}=e;return(0,r.jsx)(c.hJ,{"data-slot":"sheet-overlay",className:(0,l.cn)("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",t),...a})}function f(e){let{className:t,children:a,side:n="right",...i}=e;return(0,r.jsxs)(g,{children:[(0,r.jsx)(p,{}),(0,r.jsxs)(c.UC,{"data-slot":"sheet-content",className:(0,l.cn)("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","right"===n&&"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","left"===n&&"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","top"===n&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b","bottom"===n&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",t),...i,children:[a,(0,r.jsxs)(c.bm,{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:[(0,r.jsx)(u.A,{className:"size-4"}),(0,r.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function m(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sheet-header",className:(0,l.cn)("flex flex-col gap-1.5 p-4",t),...a})}function b(e){let{className:t,...a}=e;return(0,r.jsx)(c.hE,{"data-slot":"sheet-title",className:(0,l.cn)("text-foreground font-semibold",t),...a})}function v(e){let{className:t,...a}=e;return(0,r.jsx)(c.VY,{"data-slot":"sheet-description",className:(0,l.cn)("text-muted-foreground text-sm",t),...a})}a(2745);var x=a(6545);let w=n.createContext(null);function y(){let e=n.useContext(w);if(!e)throw Error("useSidebar must be used within a SidebarProvider.");return e}function j(e){let{defaultOpen:t=!0,open:a,onOpenChange:i,className:o,style:s,children:d,...c}=e,u=function(){let[e,t]=n.useState(void 0);return n.useEffect(()=>{let e=window.matchMedia("(max-width: ".concat(767,"px)")),a=()=>{t(window.innerWidth<768)};return e.addEventListener("change",a),t(window.innerWidth<768),()=>e.removeEventListener("change",a)},[]),!!e}(),[h,g]=n.useState(!1),[p,f]=n.useState(t),m=null!=a?a:p,b=n.useCallback(e=>{let t="function"==typeof e?e(m):e;i?i(t):f(t),document.cookie="".concat("sidebar_state","=").concat(t,"; path=/; max-age=").concat(604800)},[i,m]),v=n.useCallback(()=>u?g(e=>!e):b(e=>!e),[u,b,g]);n.useEffect(()=>{let e=e=>{"b"===e.key&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),v())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[v]);let y=m?"expanded":"collapsed",j=n.useMemo(()=>({state:y,open:m,setOpen:b,isMobile:u,openMobile:h,setOpenMobile:g,toggleSidebar:v}),[y,m,b,u,h,g,v]);return(0,r.jsx)(w.Provider,{value:j,children:(0,r.jsx)(x.Bc,{delayDuration:0,children:(0,r.jsx)("div",{"data-slot":"sidebar-wrapper",style:{"--sidebar-width":"16rem","--sidebar-width-icon":"3rem",...s},className:(0,l.cn)("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full",o),...c,children:d})})})}function k(e){let{side:t="left",variant:a="sidebar",collapsible:n="offcanvas",className:i,children:o,...s}=e,{isMobile:d,state:c,openMobile:u,setOpenMobile:g}=y();return"none"===n?(0,r.jsx)("div",{"data-slot":"sidebar",className:(0,l.cn)("bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col",i),...s,children:o}):d?(0,r.jsx)(h,{open:u,onOpenChange:g,...s,children:(0,r.jsxs)(f,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"bg-sidebar text-sidebar-foreground fixed z-50 w-(--sidebar-width) p-0 [&>button]:hidden",style:{"--sidebar-width":"18rem"},side:t,children:[(0,r.jsxs)(m,{className:"sr-only",children:[(0,r.jsx)(b,{children:"Sidebar"}),(0,r.jsx)(v,{children:"Displays the mobile sidebar."})]}),(0,r.jsx)("div",{className:"flex h-full w-full flex-col overflow-y-auto",children:o})]})}):(0,r.jsxs)("div",{className:"group peer text-sidebar-foreground hidden md:block","data-state":c,"data-collapsible":"collapsed"===c?n:"","data-variant":a,"data-side":t,"data-slot":"sidebar",children:[(0,r.jsx)("div",{"data-slot":"sidebar-gap",className:(0,l.cn)("relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180","floating"===a||"inset"===a?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon)")}),(0,r.jsx)("div",{"data-slot":"sidebar-container",className:(0,l.cn)("fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex","left"===t?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]","floating"===a||"inset"===a?"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",i),...s,children:(0,r.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:o})})]})}function N(e){let{className:t,onClick:a,...n}=e,{toggleSidebar:i}=y();return(0,r.jsxs)(d.$,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:(0,l.cn)("size-7",t),onClick:e=>{null==a||a(e),i()},...n,children:[(0,r.jsx)(s.A,{}),(0,r.jsx)("span",{className:"sr-only",children:"Toggle Sidebar"})]})}function _(e){let{className:t,...a}=e;return(0,r.jsx)("main",{"data-slot":"sidebar-inset",className:(0,l.cn)("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","overflow-x-hidden",t),...a})}function S(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:(0,l.cn)("flex flex-col gap-2 p-2",t),...a})}function C(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:(0,l.cn)("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",t),...a})}function A(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:(0,l.cn)("relative flex w-full min-w-0 flex-col p-2",t),...a})}function z(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:(0,l.cn)("w-full text-sm",t),...a})}function I(e){let{className:t,...a}=e;return(0,r.jsx)("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:(0,l.cn)("flex w-full min-w-0 flex-col gap-1",t),...a})}function B(e){let{className:t,...a}=e;return(0,r.jsx)("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:(0,l.cn)("group/menu-item relative",t),...a})}let E=(0,o.F)("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 U(e){let{asChild:t=!1,isActive:a=!1,variant:n="default",size:o="default",tooltip:s,className:d,...c}=e,u=t?i.DX:"button",{isMobile:h,state:g}=y(),p=(0,r.jsx)(u,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":o,"data-active":a,className:(0,l.cn)(E({variant:n,size:o}),d),...c});return s?("string"==typeof s&&(s={children:s}),(0,r.jsxs)(x.m_,{children:[(0,r.jsx)(x.k$,{asChild:!0,children:p}),(0,r.jsx)(x.ZI,{side:"right",align:"center",hidden:"collapsed"!==g||h,...s})]})):p}},2745:(e,t,a)=>{a.d(t,{E:()=>i});var r=a(3422),n=a(9183);function i(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"skeleton",className:(0,n.cn)("bg-accent animate-pulse rounded-md",t),...a})}},3234:(e,t,a)=>{a.d(t,{s:()=>i});var r=a(9945),n=a(5842);r.Ik({endpoint:r.Yj().url().or(r.eu("")),apiKey:r.Yj(),enabled:r.zM()});class i{static getServerConfig(){return{endpoint:localStorage.getItem("server_endpoint")||"",apiKey:localStorage.getItem("server_api_key")||"",enabled:"true"===localStorage.getItem("server_enabled")}}static saveServerConfig(e){localStorage.setItem("server_endpoint",e.endpoint),localStorage.setItem("server_api_key",e.apiKey),localStorage.setItem("server_enabled",e.enabled.toString())}static isServerConfigValid(){let e=this.getServerConfig();return e.enabled&&!!e.endpoint&&!!e.apiKey}static getLocalBaseUrl(){return"http://127.0.0.1:8000"}static getBaseUrl(){let e=this.getServerConfig();return e.enabled&&e.endpoint?e.endpoint:this.getLocalBaseUrl()}static getAuthHeaders(){let e={"Content-Type":"application/json"};try{{let t=localStorage.getItem("admin_token"),a=localStorage.getItem("admin_token_expiry");if(t&&a){let r=parseInt(a,10);if(Date.now(){a.d(t,{bN:()=>o,wu:()=>s});var r=a(9945);a(7916);var n=a(3234),i=a(5842);async function o(e){try{let t=n.s.getLocalBaseUrl(),a=await i.A.post("".concat(t,"/admin/api/login"),{password:e},{headers:{"Content-Type":"application/json"}});return a.data.token&&a.data.expires_in&&n.s.setToken(a.data.token,a.data.expires_in),a.data}catch(e){throw console.error("Admin login error:",e),e}}async function s(){try{let e=localStorage.getItem("admin_token");if(e){let t=n.s.getLocalBaseUrl();await i.A.post("".concat(t,"/admin/api/logout"),{},{headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)}})}}catch(e){console.error("Admin logout error:",e)}finally{n.s.clearToken()}}r.Ik({username:r.Yj().optional(),password:r.Yj().optional()}),r.Ik({id:r.Yj()}),r.Ik({password:r.Yj().min(1,"Password is required")}),r.Ik({ok:r.zM(),token:r.Yj(),expires_in:r.ai()}),r.Ik({npub:r.Yj().min(10,{message:"must have at least 10 character"}),name:r.Yj().optional()}),r.Ik({user_id:r.Yj(),theme:r.Yj()})},3648:(e,t,a)=>{a.d(t,{$:()=>l,r:()=>s});var r=a(3422);a(4398);var n=a(6950),i=a(4676),o=a(9183);let s=(0,i.F)("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 shadow-xs hover:bg-primary/90",destructive:"bg-destructive text-white shadow-xs 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 shadow-xs 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"}},defaultVariants:{variant:"default",size:"default"}});function l(e){let{className:t,variant:a,size:i,asChild:l=!1,...d}=e,c=l?n.DX:"button";return(0,r.jsx)(c,{"data-slot":"button",className:(0,o.cn)(s({variant:a,size:i,className:t})),...d})}},4756:(e,t,a)=>{a.d(t,{SiteHeader:()=>u});var r=a(3422),n=a(5349),i=a(953),o=a(3648),s=a(9779),l=a(1064),d=a(3270),c=a(3831);function u(){let e=(0,l.useRouter)(),t=async()=>{try{await (0,d.wu)(),c.oR.success("Logged out successfully"),e.push("/login")}catch(e){console.error("Logout error:",e),c.oR.error("Failed to logout")}};return(0,r.jsx)("header",{className:"flex h-12 shrink-0 items-center gap-2 border-b transition-[width,height] ease-linear group-has-data-[collapsible=icon]/sidebar-wrapper:h-12",children:(0,r.jsxs)("div",{className:"flex w-full items-center justify-between gap-1 px-4 lg:gap-2 lg:px-6",children:[(0,r.jsxs)("div",{className:"flex items-center gap-1 lg:gap-2",children:[(0,r.jsx)(i.x2,{className:"-ml-1"}),(0,r.jsx)(n.w,{orientation:"vertical",className:"mx-2 data-[orientation=vertical]:h-4"}),(0,r.jsx)("h1",{className:"text-base font-medium",children:"Routstr"})]}),(0,r.jsxs)(o.$,{variant:"ghost",size:"sm",onClick:t,className:"gap-2",children:[(0,r.jsx)(s.A,{className:"h-4 w-4"}),(0,r.jsx)("span",{className:"hidden sm:inline",children:"Logout"})]})]})})}},5349:(e,t,a)=>{a.d(t,{w:()=>o});var r=a(3422);a(4398);var n=a(3292),i=a(9183);function o(e){let{className:t,orientation:a="horizontal",decorative:o=!0,...s}=e;return(0,r.jsx)(n.b,{"data-slot":"separator-root",decorative:o,orientation:a,className:(0,i.cn)("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",t),...s})}},6545:(e,t,a)=>{a.d(t,{Bc:()=>o,ZI:()=>d,k$:()=>l,m_:()=>s});var r=a(3422);a(4398);var n=a(4032),i=a(9183);function o(e){let{delayDuration:t=0,...a}=e;return(0,r.jsx)(n.Kq,{"data-slot":"tooltip-provider",delayDuration:t,...a})}function s(e){let{...t}=e;return(0,r.jsx)(o,{children:(0,r.jsx)(n.bL,{"data-slot":"tooltip",...t})})}function l(e){let{...t}=e;return(0,r.jsx)(n.l9,{"data-slot":"tooltip-trigger",...t})}function d(e){let{className:t,sideOffset:a=0,children:o,...s}=e;return(0,r.jsx)(n.ZL,{children:(0,r.jsxs)(n.UC,{"data-slot":"tooltip-content",sideOffset:a,className:(0,i.cn)("bg-primary text-primary-foreground 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",t),...s,children:[o,(0,r.jsx)(n.i3,{className:"bg-primary fill-primary z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px]"})]})})}},7569:(e,t,a)=>{a.d(t,{AppSidebar:()=>p});var r=a(3422);a(4398);var n=a(2727),i=a(9285),o=a(2335),s=a(6701),l=a(8019),d=a(6631),c=a.n(d),u=a(953);function h(e){let{items:t,...a}=e;return(0,r.jsx)(u.Cn,{...a,children:(0,r.jsx)(u.rQ,{children:(0,r.jsx)(u.wZ,{children:t.map(e=>(0,r.jsx)(u.FX,{children:(0,r.jsx)(u.Uj,{asChild:!0,tooltip:e.title,children:(0,r.jsxs)(c(),{href:e.url,children:[(0,r.jsx)(e.icon,{}),(0,r.jsx)("span",{children:e.title})]})})},e.title))})})})}let g={navMain:[{title:"Dashboard",url:"/",icon:n.A}],navClouds:[],navSecondary:[{title:"Dashboard",url:"/",icon:n.A},{title:"Models",url:"/model",icon:i.A},{title:"Providers",url:"/providers",icon:o.A},{title:"Settings",url:"/settings",icon:s.A}],documents:[]};function p(e){let{...t}=e;return(0,r.jsxs)(u.Bx,{collapsible:"offcanvas",...t,children:[(0,r.jsx)(u.Gh,{children:(0,r.jsx)(u.wZ,{children:(0,r.jsx)(u.FX,{children:(0,r.jsx)(u.Uj,{asChild:!0,className:"data-[slot=sidebar-menu-button]:!p-1.5",children:(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)(l.default,{src:"/icon.ico",alt:"Routstr",width:24,height:24,className:"rounded"}),(0,r.jsx)("span",{className:"text-base font-semibold",children:"Routstr"})]})})})})}),(0,r.jsx)(u.Yv,{className:"flex-1 overflow-y-auto",children:(0,r.jsx)(h,{items:g.navSecondary,className:"mt-auto"})})]})}},7916:(e,t,a)=>{a.d(t,{apiClient:()=>o});var r=a(5842),n=a(3234);class i{getBaseUrl(){return n.s.getLocalBaseUrl()}getHeaders(){return n.s.getAuthHeaders()}handleAuthError(e){if(r.A.isAxiosError(e)){var t,a;((null==(t=e.response)?void 0:t.status)===401||(null==(a=e.response)?void 0:a.status)===403)&&(n.s.clearToken(),window.location.href="/login")}}async get(e,t){let a={headers:this.getHeaders(),params:t,withCredentials:!1};try{return console.log("Making GET request to ".concat(this.getBaseUrl()).concat(e)),(await r.A.get("".concat(this.getBaseUrl()).concat(e),a)).data}catch(e){throw this.handleAuthError(e),e}}async post(e,t){let a={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making POST request to ".concat(this.getBaseUrl()).concat(e),t),(await r.A.post("".concat(this.getBaseUrl()).concat(e),t,a)).data}catch(t){throw this.handleAuthError(t),console.error("Error posting to ".concat(e,":"),t),t}}async put(e,t){let a={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making PUT request to ".concat(this.getBaseUrl()).concat(e),t),(await r.A.put("".concat(this.getBaseUrl()).concat(e),t,a)).data}catch(t){throw this.handleAuthError(t),console.error("Error updating ".concat(e,":"),t),t}}async patch(e,t){let a={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making PATCH request to ".concat(this.getBaseUrl()).concat(e),t),(await r.A.patch("".concat(this.getBaseUrl()).concat(e),t,a)).data}catch(t){throw this.handleAuthError(t),console.error("Error patching ".concat(e,":"),t),t}}async delete(e){let t={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making DELETE request to ".concat(this.getBaseUrl()).concat(e)),(await r.A.delete("".concat(this.getBaseUrl()).concat(e),t)).data}catch(t){throw this.handleAuthError(t),console.error("Error deleting from ".concat(e,":"),t),t}}}let o=new i},9183:(e,t,a)=>{a.d(t,{cn:()=>i});var r=a(8082),n=a(4966);function i(){for(var e=arguments.length,t=Array(e),a=0;a{"use strict";s.d(t,{D:()=>h,N:()=>c});var i=s(4398),a=(e,t,s,i,a,r,n,o)=>{let u=document.documentElement,l=["light","dark"];function h(t){var s;(Array.isArray(e)?e:[e]).forEach(e=>{let s="class"===e,i=s&&r?a.map(e=>r[e]||e):a;s?(u.classList.remove(...i),u.classList.add(r&&r[t]?r[t]:t)):u.setAttribute(e,t)}),s=t,o&&l.includes(s)&&(u.style.colorScheme=s)}if(i)h(i);else try{let e=localStorage.getItem(t)||s,i=n&&"system"===e?window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":e;h(i)}catch(e){}},r=["light","dark"],n="(prefers-color-scheme: dark)",o="undefined"==typeof window,u=i.createContext(void 0),l={setTheme:e=>{},themes:[]},h=()=>{var e;return null!=(e=i.useContext(u))?e:l},c=e=>i.useContext(u)?i.createElement(i.Fragment,null,e.children):i.createElement(m,{...e}),d=["light","dark"],m=e=>{let{forcedTheme:t,disableTransitionOnChange:s=!1,enableSystem:a=!0,enableColorScheme:o=!0,storageKey:l="theme",themes:h=d,defaultTheme:c=a?"system":"light",attribute:m="data-theme",value:b,children:v,nonce:C,scriptProps:w}=e,[q,O]=i.useState(()=>y(l,c)),[Q,P]=i.useState(()=>"system"===q?g():q),E=b?Object.values(b):h,M=i.useCallback(e=>{let t=e;if(!t)return;"system"===e&&a&&(t=g());let i=b?b[t]:t,n=s?p(C):null,u=document.documentElement,l=e=>{"class"===e?(u.classList.remove(...E),i&&u.classList.add(i)):e.startsWith("data-")&&(i?u.setAttribute(e,i):u.removeAttribute(e))};if(Array.isArray(m)?m.forEach(l):l(m),o){let e=r.includes(c)?c:null,s=r.includes(t)?t:e;u.style.colorScheme=s}null==n||n()},[C]),S=i.useCallback(e=>{let t="function"==typeof e?e(q):e;O(t);try{localStorage.setItem(l,t)}catch(e){}},[q]),A=i.useCallback(e=>{P(g(e)),"system"===q&&a&&!t&&M("system")},[q,t]);i.useEffect(()=>{let e=window.matchMedia(n);return e.addListener(A),A(e),()=>e.removeListener(A)},[A]),i.useEffect(()=>{let e=e=>{e.key===l&&(e.newValue?O(e.newValue):S(c))};return window.addEventListener("storage",e),()=>window.removeEventListener("storage",e)},[S]),i.useEffect(()=>{M(null!=t?t:q)},[t,q]);let D=i.useMemo(()=>({theme:q,setTheme:S,forcedTheme:t,resolvedTheme:"system"===q?Q:q,themes:a?[...h,"system"]:h,systemTheme:a?Q:void 0}),[q,S,t,Q,a,h]);return i.createElement(u.Provider,{value:D},i.createElement(f,{forcedTheme:t,storageKey:l,attribute:m,enableSystem:a,enableColorScheme:o,defaultTheme:c,value:b,themes:h,nonce:C,scriptProps:w}),v)},f=i.memo(e=>{let{forcedTheme:t,storageKey:s,attribute:r,enableSystem:n,enableColorScheme:o,defaultTheme:u,value:l,themes:h,nonce:c,scriptProps:d}=e,m=JSON.stringify([r,s,u,t,h,l,n,o]).slice(1,-1);return i.createElement("script",{...d,suppressHydrationWarning:!0,nonce:"undefined"==typeof window?c:"",dangerouslySetInnerHTML:{__html:"(".concat(a.toString(),")(").concat(m,")")}})}),y=(e,t)=>{let s;if(!o){try{s=localStorage.getItem(e)||void 0}catch(e){}return s||t}},p=e=>{let t=document.createElement("style");return e&&t.setAttribute("nonce",e),t.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(t),()=>{window.getComputedStyle(document.body),setTimeout(()=>{document.head.removeChild(t)},1)}},g=e=>(e||(e=window.matchMedia(n)),e.matches?"dark":"light")},1331:(e,t,s)=>{"use strict";s.d(t,{$:()=>o,s:()=>n});var i=s(5688),a=s(449),r=s(2925),n=class extends a.k{#e;#t;#s;#i;constructor(e){super(),this.#e=e.client,this.mutationId=e.mutationId,this.#s=e.mutationCache,this.#t=[],this.state=e.state||o(),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.#s.notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){this.#t=this.#t.filter(t=>t!==e),this.scheduleGc(),this.#s.notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){this.#t.length||("pending"===this.state.status?this.scheduleGc():this.#s.remove(this))}continue(){return this.#i?.continue()??this.execute(this.state.variables)}async execute(e){let t=()=>{this.#a({type:"continue"})},s={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#i=(0,r.II)({fn:()=>this.options.mutationFn?this.options.mutationFn(e,s):Promise.reject(Error("No mutationFn found")),onFail:(e,t)=>{this.#a({type:"failed",failureCount:e,error:t})},onPause:()=>{this.#a({type:"pause"})},onContinue:t,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#s.canRun(this)});let i="pending"===this.state.status,a=!this.#i.canStart();try{if(i)t();else{this.#a({type:"pending",variables:e,isPaused:a}),await this.#s.config.onMutate?.(e,this,s);let t=await this.options.onMutate?.(e,s);t!==this.state.context&&this.#a({type:"pending",context:t,variables:e,isPaused:a})}let r=await this.#i.start();return await this.#s.config.onSuccess?.(r,e,this.state.context,this,s),await this.options.onSuccess?.(r,e,this.state.context,s),await this.#s.config.onSettled?.(r,null,this.state.variables,this.state.context,this,s),await this.options.onSettled?.(r,null,e,this.state.context,s),this.#a({type:"success",data:r}),r}catch(t){try{throw await this.#s.config.onError?.(t,e,this.state.context,this,s),await this.options.onError?.(t,e,this.state.context,s),await this.#s.config.onSettled?.(void 0,t,this.state.variables,this.state.context,this,s),await this.options.onSettled?.(void 0,t,e,this.state.context,s),t}finally{this.#a({type:"error",error:t})}}finally{this.#s.runNext(this)}}#a(e){this.state=(t=>{switch(e.type){case"failed":return{...t,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...t,isPaused:!0};case"continue":return{...t,isPaused:!1};case"pending":return{...t,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{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}})(this.state),i.jG.batch(()=>{this.#t.forEach(t=>{t.onMutationUpdate(e)}),this.#s.notify({mutation:this,type:"updated",action:e})})}};function o(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}},5235:(e,t,s)=>{"use strict";s.d(t,{E:()=>y});var i=s(9205),a=s(8192),r=s(5688),n=s(3145),o=class extends n.Q{constructor(e={}){super(),this.config=e,this.#r=new Map}#r;build(e,t,s){let r=t.queryKey,n=t.queryHash??(0,i.F$)(r,t),o=this.get(n);return o||(o=new a.X({client:e,queryKey:r,queryHash:n,options:e.defaultQueryOptions(t),state:s,defaultOptions:e.getQueryDefaults(r)}),this.add(o)),o}add(e){this.#r.has(e.queryHash)||(this.#r.set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){let t=this.#r.get(e.queryHash);t&&(e.destroy(),t===e&&this.#r.delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){r.jG.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return this.#r.get(e)}getAll(){return[...this.#r.values()]}find(e){let t={exact:!0,...e};return this.getAll().find(e=>(0,i.MK)(t,e))}findAll(e={}){let t=this.getAll();return Object.keys(e).length>0?t.filter(t=>(0,i.MK)(e,t)):t}notify(e){r.jG.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){r.jG.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){r.jG.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},u=s(1331),l=class extends n.Q{constructor(e={}){super(),this.config=e,this.#n=new Set,this.#o=new Map,this.#u=0}#n;#o;#u;build(e,t,s){let i=new u.s({client:e,mutationCache:this,mutationId:++this.#u,options:e.defaultMutationOptions(t),state:s});return this.add(i),i}add(e){this.#n.add(e);let t=h(e);if("string"==typeof t){let s=this.#o.get(t);s?s.push(e):this.#o.set(t,[e])}this.notify({type:"added",mutation:e})}remove(e){if(this.#n.delete(e)){let t=h(e);if("string"==typeof t){let s=this.#o.get(t);if(s)if(s.length>1){let t=s.indexOf(e);-1!==t&&s.splice(t,1)}else s[0]===e&&this.#o.delete(t)}}this.notify({type:"removed",mutation:e})}canRun(e){let t=h(e);if("string"!=typeof t)return!0;{let s=this.#o.get(t),i=s?.find(e=>"pending"===e.state.status);return!i||i===e}}runNext(e){let t=h(e);if("string"!=typeof t)return Promise.resolve();{let s=this.#o.get(t)?.find(t=>t!==e&&t.state.isPaused);return s?.continue()??Promise.resolve()}}clear(){r.jG.batch(()=>{this.#n.forEach(e=>{this.notify({type:"removed",mutation:e})}),this.#n.clear(),this.#o.clear()})}getAll(){return Array.from(this.#n)}find(e){let t={exact:!0,...e};return this.getAll().find(e=>(0,i.nJ)(t,e))}findAll(e={}){return this.getAll().filter(t=>(0,i.nJ)(e,t))}notify(e){r.jG.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){let e=this.getAll().filter(e=>e.state.isPaused);return r.jG.batch(()=>Promise.all(e.map(e=>e.continue().catch(i.lQ))))}};function h(e){return e.options.scope?.id}var c=s(6479),d=s(7478);function m(e){return{onFetch:(t,s)=>{let a=t.options,r=t.fetchOptions?.meta?.fetchMore?.direction,n=t.state.data?.pages||[],o=t.state.data?.pageParams||[],u={pages:[],pageParams:[]},l=0,h=async()=>{let s=!1,h=e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(t.signal.aborted?s=!0:t.signal.addEventListener("abort",()=>{s=!0}),t.signal)})},c=(0,i.ZM)(t.options,t.fetchOptions),d=async(e,a,r)=>{if(s)return Promise.reject();if(null==a&&e.pages.length)return Promise.resolve(e);let n=(()=>{let e={client:t.client,queryKey:t.queryKey,pageParam:a,direction:r?"backward":"forward",meta:t.options.meta};return h(e),e})(),o=await c(n),{maxPages:u}=t.options,l=r?i.ZZ:i.y9;return{pages:l(e.pages,o,u),pageParams:l(e.pageParams,a,u)}};if(r&&n.length){let e="backward"===r,t={pages:n,pageParams:o},s=(e?function(e,{pages:t,pageParams:s}){return t.length>0?e.getPreviousPageParam?.(t[0],t,s[0],s):void 0}:f)(a,t);u=await d(t,s,e)}else{let t=e??n.length;do{let e=0===l?o[0]??a.initialPageParam:f(a,u);if(l>0&&null==e)break;u=await d(u,e),l++}while(lt.options.persister?.(h,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},s):t.fetchFn=h}}}function f(e,{pages:t,pageParams:s}){let i=t.length-1;return t.length>0?e.getNextPageParam(t[i],t,s[i],s):void 0}var y=class{#l;#s;#h;#c;#d;#m;#f;#y;constructor(e={}){this.#l=e.queryCache||new o,this.#s=e.mutationCache||new l,this.#h=e.defaultOptions||{},this.#c=new Map,this.#d=new Map,this.#m=0}mount(){this.#m++,1===this.#m&&(this.#f=c.m.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#l.onFocus())}),this.#y=d.t.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#l.onOnline())}))}unmount(){this.#m--,0===this.#m&&(this.#f?.(),this.#f=void 0,this.#y?.(),this.#y=void 0)}isFetching(e){return this.#l.findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return this.#s.findAll({...e,status:"pending"}).length}getQueryData(e){let t=this.defaultQueryOptions({queryKey:e});return this.#l.get(t.queryHash)?.state.data}ensureQueryData(e){let t=this.defaultQueryOptions(e),s=this.#l.build(this,t),a=s.state.data;return void 0===a?this.fetchQuery(e):(e.revalidateIfStale&&s.isStaleByTime((0,i.d2)(t.staleTime,s))&&this.prefetchQuery(t),Promise.resolve(a))}getQueriesData(e){return this.#l.findAll(e).map(({queryKey:e,state:t})=>[e,t.data])}setQueryData(e,t,s){let a=this.defaultQueryOptions({queryKey:e}),r=this.#l.get(a.queryHash),n=r?.state.data,o=(0,i.Zw)(t,n);if(void 0!==o)return this.#l.build(this,a).setData(o,{...s,manual:!0})}setQueriesData(e,t,s){return r.jG.batch(()=>this.#l.findAll(e).map(({queryKey:e})=>[e,this.setQueryData(e,t,s)]))}getQueryState(e){let t=this.defaultQueryOptions({queryKey:e});return this.#l.get(t.queryHash)?.state}removeQueries(e){let t=this.#l;r.jG.batch(()=>{t.findAll(e).forEach(e=>{t.remove(e)})})}resetQueries(e,t){let s=this.#l;return r.jG.batch(()=>(s.findAll(e).forEach(e=>{e.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){let s={revert:!0,...t};return Promise.all(r.jG.batch(()=>this.#l.findAll(e).map(e=>e.cancel(s)))).then(i.lQ).catch(i.lQ)}invalidateQueries(e,t={}){return r.jG.batch(()=>(this.#l.findAll(e).forEach(e=>{e.invalidate()}),e?.refetchType==="none")?Promise.resolve():this.refetchQueries({...e,type:e?.refetchType??e?.type??"active"},t))}refetchQueries(e,t={}){let s={...t,cancelRefetch:t.cancelRefetch??!0};return Promise.all(r.jG.batch(()=>this.#l.findAll(e).filter(e=>!e.isDisabled()&&!e.isStatic()).map(e=>{let t=e.fetch(void 0,s);return s.throwOnError||(t=t.catch(i.lQ)),"paused"===e.state.fetchStatus?Promise.resolve():t}))).then(i.lQ)}fetchQuery(e){let t=this.defaultQueryOptions(e);void 0===t.retry&&(t.retry=!1);let s=this.#l.build(this,t);return s.isStaleByTime((0,i.d2)(t.staleTime,s))?s.fetch(t):Promise.resolve(s.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(i.lQ).catch(i.lQ)}fetchInfiniteQuery(e){return e.behavior=m(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(i.lQ).catch(i.lQ)}ensureInfiniteQueryData(e){return e.behavior=m(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return d.t.isOnline()?this.#s.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#l}getMutationCache(){return this.#s}getDefaultOptions(){return this.#h}setDefaultOptions(e){this.#h=e}setQueryDefaults(e,t){this.#c.set((0,i.EN)(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){let t=[...this.#c.values()],s={};return t.forEach(t=>{(0,i.Cp)(e,t.queryKey)&&Object.assign(s,t.defaultOptions)}),s}setMutationDefaults(e,t){this.#d.set((0,i.EN)(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){let t=[...this.#d.values()],s={};return t.forEach(t=>{(0,i.Cp)(e,t.mutationKey)&&Object.assign(s,t.defaultOptions)}),s}defaultQueryOptions(e){if(e._defaulted)return e;let t={...this.#h.queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=(0,i.F$)(t.queryKey,t)),void 0===t.refetchOnReconnect&&(t.refetchOnReconnect="always"!==t.networkMode),void 0===t.throwOnError&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===i.hT&&(t.enabled=!1),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#h.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#l.clear(),this.#s.clear()}}},6126:(e,t,s)=>{"use strict";s.d(t,{E:()=>i});var i=function(){return null}},7248:e=>{e.exports={style:{fontFamily:"'Geist Mono', 'Geist Mono Fallback'",fontStyle:"normal"},className:"__className_9a8899",variable:"__variable_9a8899"}},8368:e=>{e.exports={style:{fontFamily:"'Geist', 'Geist Fallback'",fontStyle:"normal"},className:"__className_188709",variable:"__variable_188709"}}}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/481-48cd0f8fe547e418.js b/ui_out/_next/static/chunks/481-7440db9fd9bb94b2.js similarity index 100% rename from ui_out/_next/static/chunks/481-48cd0f8fe547e418.js rename to ui_out/_next/static/chunks/481-7440db9fd9bb94b2.js diff --git a/ui_out/_next/static/chunks/497-baf4d54bf6b2d14c.js b/ui_out/_next/static/chunks/497-cf9737613a43115a.js similarity index 100% rename from ui_out/_next/static/chunks/497-baf4d54bf6b2d14c.js rename to ui_out/_next/static/chunks/497-cf9737613a43115a.js diff --git a/ui_out/_next/static/chunks/578-9e08cd45b1eda688.js b/ui_out/_next/static/chunks/578-9e08cd45b1eda688.js deleted file mode 100644 index b3ed077b..00000000 --- a/ui_out/_next/static/chunks/578-9e08cd45b1eda688.js +++ /dev/null @@ -1 +0,0 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[578],{1331:(t,e,s)=>{"use strict";s.d(e,{$:()=>u,s:()=>n});var i=s(5688),a=s(449),r=s(2925),n=class extends a.k{#t;#e;#s;#i;constructor(t){super(),this.#t=t.client,this.mutationId=t.mutationId,this.#s=t.mutationCache,this.#e=[],this.state=t.state||u(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){this.#e.includes(t)||(this.#e.push(t),this.clearGcTimeout(),this.#s.notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){this.#e=this.#e.filter(e=>e!==t),this.scheduleGc(),this.#s.notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){this.#e.length||("pending"===this.state.status?this.scheduleGc():this.#s.remove(this))}continue(){return this.#i?.continue()??this.execute(this.state.variables)}async execute(t){let e=()=>{this.#a({type:"continue"})},s={client:this.#t,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#i=(0,r.II)({fn:()=>this.options.mutationFn?this.options.mutationFn(t,s):Promise.reject(Error("No mutationFn found")),onFail:(t,e)=>{this.#a({type:"failed",failureCount:t,error:e})},onPause:()=>{this.#a({type:"pause"})},onContinue:e,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#s.canRun(this)});let i="pending"===this.state.status,a=!this.#i.canStart();try{if(i)e();else{this.#a({type:"pending",variables:t,isPaused:a}),await this.#s.config.onMutate?.(t,this,s);let e=await this.options.onMutate?.(t,s);e!==this.state.context&&this.#a({type:"pending",context:e,variables:t,isPaused:a})}let r=await this.#i.start();return await this.#s.config.onSuccess?.(r,t,this.state.context,this,s),await this.options.onSuccess?.(r,t,this.state.context,s),await this.#s.config.onSettled?.(r,null,this.state.variables,this.state.context,this,s),await this.options.onSettled?.(r,null,t,this.state.context,s),this.#a({type:"success",data:r}),r}catch(e){try{throw await this.#s.config.onError?.(e,t,this.state.context,this,s),await this.options.onError?.(e,t,this.state.context,s),await this.#s.config.onSettled?.(void 0,e,this.state.variables,this.state.context,this,s),await this.options.onSettled?.(void 0,e,t,this.state.context,s),e}finally{this.#a({type:"error",error:e})}}finally{this.#s.runNext(this)}}#a(t){this.state=(e=>{switch(t.type){case"failed":return{...e,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...e,isPaused:!0};case"continue":return{...e,isPaused:!1};case"pending":return{...e,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...e,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...e,data:void 0,error:t.error,failureCount:e.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}})(this.state),i.jG.batch(()=>{this.#e.forEach(e=>{e.onMutationUpdate(t)}),this.#s.notify({mutation:this,type:"updated",action:t})})}};function u(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}},5235:(t,e,s)=>{"use strict";s.d(e,{E:()=>p});var i=s(9205),a=s(8192),r=s(5688),n=s(3145),u=class extends n.Q{constructor(t={}){super(),this.config=t,this.#r=new Map}#r;build(t,e,s){let r=e.queryKey,n=e.queryHash??(0,i.F$)(r,e),u=this.get(n);return u||(u=new a.X({client:t,queryKey:r,queryHash:n,options:t.defaultQueryOptions(e),state:s,defaultOptions:t.getQueryDefaults(r)}),this.add(u)),u}add(t){this.#r.has(t.queryHash)||(this.#r.set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){let e=this.#r.get(t.queryHash);e&&(t.destroy(),e===t&&this.#r.delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){r.jG.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return this.#r.get(t)}getAll(){return[...this.#r.values()]}find(t){let e={exact:!0,...t};return this.getAll().find(t=>(0,i.MK)(e,t))}findAll(t={}){let e=this.getAll();return Object.keys(t).length>0?e.filter(e=>(0,i.MK)(t,e)):e}notify(t){r.jG.batch(()=>{this.listeners.forEach(e=>{e(t)})})}onFocus(){r.jG.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){r.jG.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},o=s(1331),h=class extends n.Q{constructor(t={}){super(),this.config=t,this.#n=new Set,this.#u=new Map,this.#o=0}#n;#u;#o;build(t,e,s){let i=new o.s({client:t,mutationCache:this,mutationId:++this.#o,options:t.defaultMutationOptions(e),state:s});return this.add(i),i}add(t){this.#n.add(t);let e=l(t);if("string"==typeof e){let s=this.#u.get(e);s?s.push(t):this.#u.set(e,[t])}this.notify({type:"added",mutation:t})}remove(t){if(this.#n.delete(t)){let e=l(t);if("string"==typeof e){let s=this.#u.get(e);if(s)if(s.length>1){let e=s.indexOf(t);-1!==e&&s.splice(e,1)}else s[0]===t&&this.#u.delete(e)}}this.notify({type:"removed",mutation:t})}canRun(t){let e=l(t);if("string"!=typeof e)return!0;{let s=this.#u.get(e),i=s?.find(t=>"pending"===t.state.status);return!i||i===t}}runNext(t){let e=l(t);if("string"!=typeof e)return Promise.resolve();{let s=this.#u.get(e)?.find(e=>e!==t&&e.state.isPaused);return s?.continue()??Promise.resolve()}}clear(){r.jG.batch(()=>{this.#n.forEach(t=>{this.notify({type:"removed",mutation:t})}),this.#n.clear(),this.#u.clear()})}getAll(){return Array.from(this.#n)}find(t){let e={exact:!0,...t};return this.getAll().find(t=>(0,i.nJ)(e,t))}findAll(t={}){return this.getAll().filter(e=>(0,i.nJ)(t,e))}notify(t){r.jG.batch(()=>{this.listeners.forEach(e=>{e(t)})})}resumePausedMutations(){let t=this.getAll().filter(t=>t.state.isPaused);return r.jG.batch(()=>Promise.all(t.map(t=>t.continue().catch(i.lQ))))}};function l(t){return t.options.scope?.id}var c=s(6479),d=s(7478);function f(t){return{onFetch:(e,s)=>{let a=e.options,r=e.fetchOptions?.meta?.fetchMore?.direction,n=e.state.data?.pages||[],u=e.state.data?.pageParams||[],o={pages:[],pageParams:[]},h=0,l=async()=>{let s=!1,l=t=>{Object.defineProperty(t,"signal",{enumerable:!0,get:()=>(e.signal.aborted?s=!0:e.signal.addEventListener("abort",()=>{s=!0}),e.signal)})},c=(0,i.ZM)(e.options,e.fetchOptions),d=async(t,a,r)=>{if(s)return Promise.reject();if(null==a&&t.pages.length)return Promise.resolve(t);let n=(()=>{let t={client:e.client,queryKey:e.queryKey,pageParam:a,direction:r?"backward":"forward",meta:e.options.meta};return l(t),t})(),u=await c(n),{maxPages:o}=e.options,h=r?i.ZZ:i.y9;return{pages:h(t.pages,u,o),pageParams:h(t.pageParams,a,o)}};if(r&&n.length){let t="backward"===r,e={pages:n,pageParams:u},s=(t?function(t,{pages:e,pageParams:s}){return e.length>0?t.getPreviousPageParam?.(e[0],e,s[0],s):void 0}:y)(a,e);o=await d(e,s,t)}else{let e=t??n.length;do{let t=0===h?u[0]??a.initialPageParam:y(a,o);if(h>0&&null==t)break;o=await d(o,t),h++}while(he.options.persister?.(l,{client:e.client,queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},s):e.fetchFn=l}}}function y(t,{pages:e,pageParams:s}){let i=e.length-1;return e.length>0?t.getNextPageParam(e[i],e,s[i],s):void 0}var p=class{#h;#s;#l;#c;#d;#f;#y;#p;constructor(t={}){this.#h=t.queryCache||new u,this.#s=t.mutationCache||new h,this.#l=t.defaultOptions||{},this.#c=new Map,this.#d=new Map,this.#f=0}mount(){this.#f++,1===this.#f&&(this.#y=c.m.subscribe(async t=>{t&&(await this.resumePausedMutations(),this.#h.onFocus())}),this.#p=d.t.subscribe(async t=>{t&&(await this.resumePausedMutations(),this.#h.onOnline())}))}unmount(){this.#f--,0===this.#f&&(this.#y?.(),this.#y=void 0,this.#p?.(),this.#p=void 0)}isFetching(t){return this.#h.findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return this.#s.findAll({...t,status:"pending"}).length}getQueryData(t){let e=this.defaultQueryOptions({queryKey:t});return this.#h.get(e.queryHash)?.state.data}ensureQueryData(t){let e=this.defaultQueryOptions(t),s=this.#h.build(this,e),a=s.state.data;return void 0===a?this.fetchQuery(t):(t.revalidateIfStale&&s.isStaleByTime((0,i.d2)(e.staleTime,s))&&this.prefetchQuery(e),Promise.resolve(a))}getQueriesData(t){return this.#h.findAll(t).map(({queryKey:t,state:e})=>[t,e.data])}setQueryData(t,e,s){let a=this.defaultQueryOptions({queryKey:t}),r=this.#h.get(a.queryHash),n=r?.state.data,u=(0,i.Zw)(e,n);if(void 0!==u)return this.#h.build(this,a).setData(u,{...s,manual:!0})}setQueriesData(t,e,s){return r.jG.batch(()=>this.#h.findAll(t).map(({queryKey:t})=>[t,this.setQueryData(t,e,s)]))}getQueryState(t){let e=this.defaultQueryOptions({queryKey:t});return this.#h.get(e.queryHash)?.state}removeQueries(t){let e=this.#h;r.jG.batch(()=>{e.findAll(t).forEach(t=>{e.remove(t)})})}resetQueries(t,e){let s=this.#h;return r.jG.batch(()=>(s.findAll(t).forEach(t=>{t.reset()}),this.refetchQueries({type:"active",...t},e)))}cancelQueries(t,e={}){let s={revert:!0,...e};return Promise.all(r.jG.batch(()=>this.#h.findAll(t).map(t=>t.cancel(s)))).then(i.lQ).catch(i.lQ)}invalidateQueries(t,e={}){return r.jG.batch(()=>(this.#h.findAll(t).forEach(t=>{t.invalidate()}),t?.refetchType==="none")?Promise.resolve():this.refetchQueries({...t,type:t?.refetchType??t?.type??"active"},e))}refetchQueries(t,e={}){let s={...e,cancelRefetch:e.cancelRefetch??!0};return Promise.all(r.jG.batch(()=>this.#h.findAll(t).filter(t=>!t.isDisabled()&&!t.isStatic()).map(t=>{let e=t.fetch(void 0,s);return s.throwOnError||(e=e.catch(i.lQ)),"paused"===t.state.fetchStatus?Promise.resolve():e}))).then(i.lQ)}fetchQuery(t){let e=this.defaultQueryOptions(t);void 0===e.retry&&(e.retry=!1);let s=this.#h.build(this,e);return s.isStaleByTime((0,i.d2)(e.staleTime,s))?s.fetch(e):Promise.resolve(s.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(i.lQ).catch(i.lQ)}fetchInfiniteQuery(t){return t.behavior=f(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(i.lQ).catch(i.lQ)}ensureInfiniteQueryData(t){return t.behavior=f(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return d.t.isOnline()?this.#s.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#h}getMutationCache(){return this.#s}getDefaultOptions(){return this.#l}setDefaultOptions(t){this.#l=t}setQueryDefaults(t,e){this.#c.set((0,i.EN)(t),{queryKey:t,defaultOptions:e})}getQueryDefaults(t){let e=[...this.#c.values()],s={};return e.forEach(e=>{(0,i.Cp)(t,e.queryKey)&&Object.assign(s,e.defaultOptions)}),s}setMutationDefaults(t,e){this.#d.set((0,i.EN)(t),{mutationKey:t,defaultOptions:e})}getMutationDefaults(t){let e=[...this.#d.values()],s={};return e.forEach(e=>{(0,i.Cp)(t,e.mutationKey)&&Object.assign(s,e.defaultOptions)}),s}defaultQueryOptions(t){if(t._defaulted)return t;let e={...this.#l.queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return e.queryHash||(e.queryHash=(0,i.F$)(e.queryKey,e)),void 0===e.refetchOnReconnect&&(e.refetchOnReconnect="always"!==e.networkMode),void 0===e.throwOnError&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),e.queryFn===i.hT&&(e.enabled=!1),e}defaultMutationOptions(t){return t?._defaulted?t:{...this.#l.mutations,...t?.mutationKey&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){this.#h.clear(),this.#s.clear()}}},6126:(t,e,s)=>{"use strict";s.d(e,{E:()=>i});var i=function(){return null}},7248:t=>{t.exports={style:{fontFamily:"'Geist Mono', 'Geist Mono Fallback'",fontStyle:"normal"},className:"__className_9a8899",variable:"__variable_9a8899"}},8368:t=>{t.exports={style:{fontFamily:"'Geist', 'Geist Fallback'",fontStyle:"normal"},className:"__className_188709",variable:"__variable_188709"}}}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/601-bd77b408e968f9da.js b/ui_out/_next/static/chunks/601-3f92835872ce1c3b.js similarity index 100% rename from ui_out/_next/static/chunks/601-bd77b408e968f9da.js rename to ui_out/_next/static/chunks/601-3f92835872ce1c3b.js diff --git a/ui_out/_next/static/chunks/651-4a58f299a4aa4df7.js b/ui_out/_next/static/chunks/651-7f1a745b0e3db11d.js similarity index 100% rename from ui_out/_next/static/chunks/651-4a58f299a4aa4df7.js rename to ui_out/_next/static/chunks/651-7f1a745b0e3db11d.js diff --git a/ui_out/_next/static/chunks/65b78783-abd88d9e33bb3ce1.js b/ui_out/_next/static/chunks/65b78783-daf30cffc34759e7.js similarity index 100% rename from ui_out/_next/static/chunks/65b78783-abd88d9e33bb3ce1.js rename to ui_out/_next/static/chunks/65b78783-daf30cffc34759e7.js diff --git a/ui_out/_next/static/chunks/730-892209af1fa345bd.js b/ui_out/_next/static/chunks/730-eb609e4385533b6b.js similarity index 100% rename from ui_out/_next/static/chunks/730-892209af1fa345bd.js rename to ui_out/_next/static/chunks/730-eb609e4385533b6b.js diff --git a/ui_out/_next/static/chunks/808-6da586a06e4a6738.js b/ui_out/_next/static/chunks/808-6da586a06e4a6738.js deleted file mode 100644 index 65817d37..00000000 --- a/ui_out/_next/static/chunks/808-6da586a06e4a6738.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[808],{7:(e,t,n)=>{n.d(t,{Oh:()=>i});var r=n(4398),o=0;function i(){r.useEffect(()=>{var e,t;let n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!=(e=n[0])?e:l()),document.body.insertAdjacentElement("beforeend",null!=(t=n[1])?t:l()),o++,()=>{1===o&&document.querySelectorAll("[data-radix-focus-guard]").forEach(e=>e.remove()),o--}},[])}function l(){let 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}},202:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"RouterContext",{enumerable:!0,get:function(){return r}});let r=n(5348)._(n(4398)).default.createContext(null)},777:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"errorOnce",{enumerable:!0,get:function(){return n}});let n=e=>{}},940:(e,t,n)=>{n.d(t,{A:()=>l,q:()=>i});var r=n(4398),o=n(3422);function i(e,t){let n=r.createContext(t),i=e=>{let{children:t,...i}=e,l=r.useMemo(()=>i,Object.values(i));return(0,o.jsx)(n.Provider,{value:l,children:t})};return i.displayName=e+"Provider",[i,function(o){let i=r.useContext(n);if(i)return i;if(void 0!==t)return t;throw Error(`\`${o}\` must be used within \`${e}\``)}]}function l(e,t=[]){let n=[],i=()=>{let t=n.map(e=>r.createContext(e));return function(n){let o=n?.[e]||t;return r.useMemo(()=>({[`__scope${e}`]:{...n,[e]:o}}),[n,o])}};return i.scopeName=e,[function(t,i){let l=r.createContext(i),a=n.length;n=[...n,i];let u=t=>{let{scope:n,children:i,...u}=t,s=n?.[e]?.[a]||l,c=r.useMemo(()=>u,Object.values(u));return(0,o.jsx)(s.Provider,{value:c,children:i})};return u.displayName=t+"Provider",[u,function(n,o){let u=o?.[e]?.[a]||l,s=r.useContext(u);if(s)return s;if(void 0!==i)return i;throw Error(`\`${n}\` must be used within \`${t}\``)}]},function(...e){let t=e[0];if(1===e.length)return t;let n=()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return function(e){let o=n.reduce((t,{useScope:n,scopeName:r})=>{let o=n(e)[`__scope${r}`];return{...t,...o}},{});return r.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}(i,...t)]}},1200:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Image",{enumerable:!0,get:function(){return w}});let r=n(5348),o=n(4900),i=n(3422),l=o._(n(4398)),a=r._(n(5707)),u=r._(n(4653)),s=n(2287),c=n(8585),d=n(3891);n(5145);let f=n(202),p=r._(n(7352)),m=n(7525),h={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image/",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!0};function g(e,t,n,r,o,i,l){let a=null==e?void 0:e.src;e&&e["data-loaded-src"]!==a&&(e["data-loaded-src"]=a,("decode"in e?e.decode():Promise.resolve()).catch(()=>{}).then(()=>{if(e.parentElement&&e.isConnected){if("empty"!==t&&o(!0),null==n?void 0:n.current){let t=new Event("load");Object.defineProperty(t,"target",{writable:!1,value:e});let r=!1,o=!1;n.current({...t,nativeEvent:t,currentTarget:e,target:e,isDefaultPrevented:()=>r,isPropagationStopped:()=>o,persist:()=>{},preventDefault:()=>{r=!0,t.preventDefault()},stopPropagation:()=>{o=!0,t.stopPropagation()}})}(null==r?void 0:r.current)&&r.current(e)}}))}function v(e){return l.use?{fetchPriority:e}:{fetchpriority:e}}let y=(0,l.forwardRef)((e,t)=>{let{src:n,srcSet:r,sizes:o,height:a,width:u,decoding:s,className:c,style:d,fetchPriority:f,placeholder:p,loading:h,unoptimized:y,fill:b,onLoadRef:w,onLoadingCompleteRef:x,setBlurComplete:E,setShowAltText:C,sizesInput:R,onLoad:O,onError:S,...P}=e,A=(0,l.useCallback)(e=>{e&&(S&&(e.src=e.src),e.complete&&g(e,p,w,x,E,y,R))},[n,p,w,x,E,S,y,R]),j=(0,m.useMergedRef)(t,A);return(0,i.jsx)("img",{...P,...v(f),loading:h,width:u,height:a,decoding:s,"data-nimg":b?"fill":"1",className:c,style:d,sizes:o,srcSet:r,src:n,ref:j,onLoad:e=>{g(e.currentTarget,p,w,x,E,y,R)},onError:e=>{C(!0),"empty"!==p&&E(!0),S&&S(e)}})});function b(e){let{isAppRouter:t,imgAttributes:n}=e,r={as:"image",imageSrcSet:n.srcSet,imageSizes:n.sizes,crossOrigin:n.crossOrigin,referrerPolicy:n.referrerPolicy,...v(n.fetchPriority)};return t&&a.default.preload?(a.default.preload(n.src,r),null):(0,i.jsx)(u.default,{children:(0,i.jsx)("link",{rel:"preload",href:n.srcSet?void 0:n.src,...r},"__nimg-"+n.src+n.srcSet+n.sizes)})}let w=(0,l.forwardRef)((e,t)=>{let n=(0,l.useContext)(f.RouterContext),r=(0,l.useContext)(d.ImageConfigContext),o=(0,l.useMemo)(()=>{var e;let t=h||r||c.imageConfigDefault,n=[...t.deviceSizes,...t.imageSizes].sort((e,t)=>e-t),o=t.deviceSizes.sort((e,t)=>e-t),i=null==(e=t.qualities)?void 0:e.sort((e,t)=>e-t);return{...t,allSizes:n,deviceSizes:o,qualities:i}},[r]),{onLoad:a,onLoadingComplete:u}=e,m=(0,l.useRef)(a);(0,l.useEffect)(()=>{m.current=a},[a]);let g=(0,l.useRef)(u);(0,l.useEffect)(()=>{g.current=u},[u]);let[v,w]=(0,l.useState)(!1),[x,E]=(0,l.useState)(!1),{props:C,meta:R}=(0,s.getImgProps)(e,{defaultLoader:p.default,imgConf:o,blurComplete:v,showAltText:x});return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(y,{...C,unoptimized:R.unoptimized,placeholder:R.placeholder,fill:R.fill,onLoadRef:m,onLoadingCompleteRef:g,setBlurComplete:w,setShowAltText:E,sizesInput:e.sizes,ref:t}),R.priority?(0,i.jsx)(b,{isAppRouter:!n,imgAttributes:C}):null]})});("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},1581:(e,t,n)=>{n.d(t,{Qg:()=>l,bL:()=>u});var r=n(4398),o=n(3780),i=n(3422),l=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"}),a=r.forwardRef((e,t)=>(0,i.jsx)(o.sG.span,{...e,ref:t,style:{...l,...e.style}}));a.displayName="VisuallyHidden";var u=a},1732:(e,t,n)=>{n.d(t,{Z:()=>u});var r=n(4398),o=n(5707),i=n(3780),l=n(3177),a=n(3422),u=r.forwardRef((e,t)=>{var n,u;let{container:s,...c}=e,[d,f]=r.useState(!1);(0,l.N)(()=>f(!0),[]);let p=s||d&&(null==(u=globalThis)||null==(n=u.document)?void 0:n.body);return p?o.createPortal((0,a.jsx)(i.sG.div,{...c,ref:t}),p):null});u.displayName="Portal"},2287:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getImgProps",{enumerable:!0,get:function(){return u}}),n(5145);let r=n(3605),o=n(8585),i=["-moz-initial","fill","none","scale-down",void 0];function l(e){return void 0!==e.default}function a(e){return void 0===e?e:"number"==typeof e?Number.isFinite(e)?e:NaN:"string"==typeof e&&/^[0-9]+$/.test(e)?parseInt(e,10):NaN}function u(e,t){var n,u;let s,c,d,{src:f,sizes:p,unoptimized:m=!1,priority:h=!1,loading:g,className:v,quality:y,width:b,height:w,fill:x=!1,style:E,overrideSrc:C,onLoad:R,onLoadingComplete:O,placeholder:S="empty",blurDataURL:P,fetchPriority:A,decoding:j="async",layout:T,objectFit:_,objectPosition:N,lazyBoundary:k,lazyRoot:L,...M}=e,{imgConf:D,showAltText:I,blurComplete:F,defaultLoader:z}=t,W=D||o.imageConfigDefault;if("allSizes"in W)s=W;else{let e=[...W.deviceSizes,...W.imageSizes].sort((e,t)=>e-t),t=W.deviceSizes.sort((e,t)=>e-t),r=null==(n=W.qualities)?void 0:n.sort((e,t)=>e-t);s={...W,allSizes:e,deviceSizes:t,qualities:r}}if(void 0===z)throw Object.defineProperty(Error("images.loaderFile detected but the file is missing default export.\nRead more: https://nextjs.org/docs/messages/invalid-images-config"),"__NEXT_ERROR_CODE",{value:"E163",enumerable:!1,configurable:!0});let B=M.loader||z;delete M.loader,delete M.srcSet;let U="__next_img_default"in B;if(U){if("custom"===s.loader)throw Object.defineProperty(Error('Image with src "'+f+'" is missing "loader" prop.\nRead more: https://nextjs.org/docs/messages/next-image-missing-loader'),"__NEXT_ERROR_CODE",{value:"E252",enumerable:!1,configurable:!0})}else{let e=B;B=t=>{let{config:n,...r}=t;return e(r)}}if(T){"fill"===T&&(x=!0);let e={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}}[T];e&&(E={...E,...e});let t={responsive:"100vw",fill:"100vw"}[T];t&&!p&&(p=t)}let H="",K=a(b),q=a(w);if((u=f)&&"object"==typeof u&&(l(u)||void 0!==u.src)){let e=l(f)?f.default:f;if(!e.src)throw Object.defineProperty(Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received "+JSON.stringify(e)),"__NEXT_ERROR_CODE",{value:"E460",enumerable:!1,configurable:!0});if(!e.height||!e.width)throw Object.defineProperty(Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received "+JSON.stringify(e)),"__NEXT_ERROR_CODE",{value:"E48",enumerable:!1,configurable:!0});if(c=e.blurWidth,d=e.blurHeight,P=P||e.blurDataURL,H=e.src,!x)if(K||q){if(K&&!q){let t=K/e.width;q=Math.round(e.height*t)}else if(!K&&q){let t=q/e.height;K=Math.round(e.width*t)}}else K=e.width,q=e.height}let G=!h&&("lazy"===g||void 0===g);(!(f="string"==typeof f?f:H)||f.startsWith("data:")||f.startsWith("blob:"))&&(m=!0,G=!1),s.unoptimized&&(m=!0),U&&!s.dangerouslyAllowSVG&&f.split("?",1)[0].endsWith(".svg")&&(m=!0);let V=a(y),X=Object.assign(x?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:_,objectPosition:N}:{},I?{}:{color:"transparent"},E),$=F||"empty"===S?null:"blur"===S?'url("data:image/svg+xml;charset=utf-8,'+(0,r.getImageBlurSvg)({widthInt:K,heightInt:q,blurWidth:c,blurHeight:d,blurDataURL:P||"",objectFit:X.objectFit})+'")':'url("'+S+'")',Y=i.includes(X.objectFit)?"fill"===X.objectFit?"100% 100%":"cover":X.objectFit,Z=$?{backgroundSize:Y,backgroundPosition:X.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:$}:{},J=function(e){let{config:t,src:n,unoptimized:r,width:o,quality:i,sizes:l,loader:a}=e;if(r)return{src:n,srcSet:void 0,sizes:void 0};let{widths:u,kind:s}=function(e,t,n){let{deviceSizes:r,allSizes:o}=e;if(n){let e=/(^|\s)(1?\d?\d)vw/g,t=[];for(let r;r=e.exec(n);)t.push(parseInt(r[2]));if(t.length){let e=.01*Math.min(...t);return{widths:o.filter(t=>t>=r[0]*e),kind:"w"}}return{widths:o,kind:"w"}}return"number"!=typeof t?{widths:r,kind:"w"}:{widths:[...new Set([t,2*t].map(e=>o.find(t=>t>=e)||o[o.length-1]))],kind:"x"}}(t,o,l),c=u.length-1;return{sizes:l||"w"!==s?l:"100vw",srcSet:u.map((e,r)=>a({config:t,src:n,quality:i,width:e})+" "+("w"===s?e:r+1)+s).join(", "),src:a({config:t,src:n,quality:i,width:u[c]})}}({config:s,src:f,unoptimized:m,width:K,quality:V,sizes:p,loader:B});return{props:{...M,loading:G?"lazy":g,fetchPriority:A,width:K,height:q,decoding:j,className:v,style:{...X,...Z},sizes:J.sizes,srcSet:J.srcSet,src:C||J.src},meta:{unoptimized:m,priority:h,placeholder:S,fill:x}}}},2305:(e,t)=>{function n(e){let{ampFirst:t=!1,hybrid:n=!1,hasQuery:r=!1}=void 0===e?{}:e;return t||n&&r}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"isInAmpMode",{enumerable:!0,get:function(){return n}})},2335:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("server",[["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"}]])},2727:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("layout-dashboard",[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]])},3138:(e,t,n)=>{n.d(t,{n:()=>d});var r=n(4398),o=n(2050),i=n(3780),l=n(7589),a=n(3422),u="focusScope.autoFocusOnMount",s="focusScope.autoFocusOnUnmount",c={bubbles:!1,cancelable:!0},d=r.forwardRef((e,t)=>{let{loop:n=!1,trapped:d=!1,onMountAutoFocus:g,onUnmountAutoFocus:v,...y}=e,[b,w]=r.useState(null),x=(0,l.c)(g),E=(0,l.c)(v),C=r.useRef(null),R=(0,o.s)(t,e=>w(e)),O=r.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;r.useEffect(()=>{if(d){let e=function(e){if(O.paused||!b)return;let t=e.target;b.contains(t)?C.current=t:m(C.current,{select:!0})},t=function(e){if(O.paused||!b)return;let t=e.relatedTarget;null!==t&&(b.contains(t)||m(C.current,{select:!0}))};document.addEventListener("focusin",e),document.addEventListener("focusout",t);let n=new MutationObserver(function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&m(b)});return b&&n.observe(b,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),n.disconnect()}}},[d,b,O.paused]),r.useEffect(()=>{if(b){h.add(O);let e=document.activeElement;if(!b.contains(e)){let t=new CustomEvent(u,c);b.addEventListener(u,x),b.dispatchEvent(t),t.defaultPrevented||(function(e){let{select:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=document.activeElement;for(let r of e)if(m(r,{select:t}),document.activeElement!==n)return}(f(b).filter(e=>"A"!==e.tagName),{select:!0}),document.activeElement===e&&m(b))}return()=>{b.removeEventListener(u,x),setTimeout(()=>{let t=new CustomEvent(s,c);b.addEventListener(s,E),b.dispatchEvent(t),t.defaultPrevented||m(null!=e?e:document.body,{select:!0}),b.removeEventListener(s,E),h.remove(O)},0)}}},[b,x,E,O]);let S=r.useCallback(e=>{if(!n&&!d||O.paused)return;let t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,r=document.activeElement;if(t&&r){let t=e.currentTarget,[o,i]=function(e){let t=f(e);return[p(t,e),p(t.reverse(),e)]}(t);o&&i?e.shiftKey||r!==i?e.shiftKey&&r===o&&(e.preventDefault(),n&&m(i,{select:!0})):(e.preventDefault(),n&&m(o,{select:!0})):r===t&&e.preventDefault()}},[n,d,O.paused]);return(0,a.jsx)(i.sG.div,{tabIndex:-1,...y,ref:R,onKeyDown:S})});function f(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function p(e,t){for(let n of e)if(!function(e,t){let{upTo:n}=t;if("hidden"===getComputedStyle(e).visibility)return!0;for(;e&&(void 0===n||e!==n);){if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}(n,{upTo:t}))return n}function m(e){let{select:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e&&e.focus){var n;let r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&(n=e)instanceof HTMLInputElement&&"select"in n&&t&&e.select()}}d.displayName="FocusScope";var h=function(){let e=[];return{add(t){let n=e[0];t!==n&&(null==n||n.pause()),(e=g(e,t)).unshift(t)},remove(t){var n;null==(n=(e=g(e,t))[0])||n.resume()}}}();function g(e,t){let n=[...e],r=n.indexOf(t);return -1!==r&&n.splice(r,1),n}},3177:(e,t,n)=>{n.d(t,{N:()=>o});var r=n(4398),o=globalThis?.document?r.useLayoutEffect:()=>{}},3213:(e,t,n)=>{n.d(t,{qW:()=>f});var r,o=n(4398),i=n(6687),l=n(3780),a=n(2050),u=n(7589),s=n(3422),c="dismissableLayer.update",d=o.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),f=o.forwardRef((e,t)=>{var n,f;let{disableOutsidePointerEvents:h=!1,onEscapeKeyDown:g,onPointerDownOutside:v,onFocusOutside:y,onInteractOutside:b,onDismiss:w,...x}=e,E=o.useContext(d),[C,R]=o.useState(null),O=null!=(f=null==C?void 0:C.ownerDocument)?f:null==(n=globalThis)?void 0:n.document,[,S]=o.useState({}),P=(0,a.s)(t,e=>R(e)),A=Array.from(E.layers),[j]=[...E.layersWithOutsidePointerEventsDisabled].slice(-1),T=A.indexOf(j),_=C?A.indexOf(C):-1,N=E.layersWithOutsidePointerEventsDisabled.size>0,k=_>=T,L=function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null==(t=globalThis)?void 0:t.document,r=(0,u.c)(e),i=o.useRef(!1),l=o.useRef(()=>{});return o.useEffect(()=>{let e=e=>{if(e.target&&!i.current){let t=function(){m("dismissableLayer.pointerDownOutside",r,o,{discrete:!0})},o={originalEvent:e};"touch"===e.pointerType?(n.removeEventListener("click",l.current),l.current=t,n.addEventListener("click",l.current,{once:!0})):t()}else n.removeEventListener("click",l.current);i.current=!1},t=window.setTimeout(()=>{n.addEventListener("pointerdown",e)},0);return()=>{window.clearTimeout(t),n.removeEventListener("pointerdown",e),n.removeEventListener("click",l.current)}},[n,r]),{onPointerDownCapture:()=>i.current=!0}}(e=>{let t=e.target,n=[...E.branches].some(e=>e.contains(t));k&&!n&&(null==v||v(e),null==b||b(e),e.defaultPrevented||null==w||w())},O),M=function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null==(t=globalThis)?void 0:t.document,r=(0,u.c)(e),i=o.useRef(!1);return o.useEffect(()=>{let e=e=>{e.target&&!i.current&&m("dismissableLayer.focusOutside",r,{originalEvent:e},{discrete:!1})};return n.addEventListener("focusin",e),()=>n.removeEventListener("focusin",e)},[n,r]),{onFocusCapture:()=>i.current=!0,onBlurCapture:()=>i.current=!1}}(e=>{let t=e.target;![...E.branches].some(e=>e.contains(t))&&(null==y||y(e),null==b||b(e),e.defaultPrevented||null==w||w())},O);return!function(e,t=globalThis?.document){let n=(0,u.c)(e);o.useEffect(()=>{let e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})},[n,t])}(e=>{_===E.layers.size-1&&(null==g||g(e),!e.defaultPrevented&&w&&(e.preventDefault(),w()))},O),o.useEffect(()=>{if(C)return h&&(0===E.layersWithOutsidePointerEventsDisabled.size&&(r=O.body.style.pointerEvents,O.body.style.pointerEvents="none"),E.layersWithOutsidePointerEventsDisabled.add(C)),E.layers.add(C),p(),()=>{h&&1===E.layersWithOutsidePointerEventsDisabled.size&&(O.body.style.pointerEvents=r)}},[C,O,h,E]),o.useEffect(()=>()=>{C&&(E.layers.delete(C),E.layersWithOutsidePointerEventsDisabled.delete(C),p())},[C,E]),o.useEffect(()=>{let e=()=>S({});return document.addEventListener(c,e),()=>document.removeEventListener(c,e)},[]),(0,s.jsx)(l.sG.div,{...x,ref:P,style:{pointerEvents:N?k?"auto":"none":void 0,...e.style},onFocusCapture:(0,i.mK)(e.onFocusCapture,M.onFocusCapture),onBlurCapture:(0,i.mK)(e.onBlurCapture,M.onBlurCapture),onPointerDownCapture:(0,i.mK)(e.onPointerDownCapture,L.onPointerDownCapture)})});function p(){let e=new CustomEvent(c);document.dispatchEvent(e)}function m(e,t,n,r){let{discrete:o}=r,i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),o?(0,l.hO)(i,a):i.dispatchEvent(a)}f.displayName="DismissableLayer",o.forwardRef((e,t)=>{let n=o.useContext(d),r=o.useRef(null),i=(0,a.s)(t,r);return o.useEffect(()=>{let e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,s.jsx)(l.sG.div,{...e,ref:i})}).displayName="DismissableLayerBranch"},3276:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{DecodeError:function(){return m},MiddlewareNotFoundError:function(){return y},MissingStaticPage:function(){return v},NormalizeError:function(){return h},PageNotFoundError:function(){return g},SP:function(){return f},ST:function(){return p},WEB_VITALS:function(){return n},execOnce:function(){return r},getDisplayName:function(){return u},getLocationOrigin:function(){return l},getURL:function(){return a},isAbsoluteUrl:function(){return i},isResSent:function(){return s},loadGetInitialProps:function(){return d},normalizeRepeatedSlashes:function(){return c},stringifyError:function(){return b}});let n=["CLS","FCP","FID","INP","LCP","TTFB"];function r(e){let t,n=!1;return function(){for(var r=arguments.length,o=Array(r),i=0;io.test(e);function l(){let{protocol:e,hostname:t,port:n}=window.location;return e+"//"+t+(n?":"+n:"")}function a(){let{href:e}=window.location,t=l();return e.substring(t.length)}function u(e){return"string"==typeof e?e:e.displayName||e.name||"Unknown"}function s(e){return e.finished||e.headersSent}function c(e){let t=e.split("?");return t[0].replace(/\\/g,"/").replace(/\/\/+/g,"/")+(t[1]?"?"+t.slice(1).join("?"):"")}async function d(e,t){let n=t.res||t.ctx&&t.ctx.res;if(!e.getInitialProps)return t.ctx&&t.Component?{pageProps:await d(t.Component,t.ctx)}:{};let r=await e.getInitialProps(t);if(n&&s(n))return r;if(!r)throw Object.defineProperty(Error('"'+u(e)+'.getInitialProps()" should resolve to an object. But found "'+r+'" instead.'),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return r}let f="undefined"!=typeof performance,p=f&&["mark","measure","getEntriesByName"].every(e=>"function"==typeof performance[e]);class m extends Error{}class h extends Error{}class g extends Error{constructor(e){super(),this.code="ENOENT",this.name="PageNotFoundError",this.message="Cannot find module for page: "+e}}class v extends Error{constructor(e,t){super(),this.message="Failed to load static file for page: "+e+" "+t}}class y extends Error{constructor(){super(),this.code="ENOENT",this.message="Cannot find the middleware module"}}function b(e){return JSON.stringify({message:e.message,stack:e.stack})}},3292:(e,t,n)=>{n.d(t,{b:()=>s});var r=n(4398),o=n(3780),i=n(3422),l="horizontal",a=["horizontal","vertical"],u=r.forwardRef((e,t)=>{var n;let{decorative:r,orientation:u=l,...s}=e,c=(n=u,a.includes(n))?u:l;return(0,i.jsx)(o.sG.div,{"data-orientation":c,...r?{role:"none"}:{"aria-orientation":"vertical"===c?c:void 0,role:"separator"},...s,ref:t})});u.displayName="Separator";var s=u},3338:(e,t,n)=>{n.d(t,{A:()=>G});var r,o,i=function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;nt.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}Object.create;Object.create;var a=("function"==typeof SuppressedError&&SuppressedError,n(4398)),u="right-scroll-bar-position",s="width-before-scroll-bar";function c(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var d="undefined"!=typeof window?a.useLayoutEffect:a.useEffect,f=new WeakMap;function p(e){return e}var m=function(e){void 0===e&&(e={});var t,n,r,o,l=(t=null,void 0===n&&(n=p),r=[],o=!1,{read:function(){if(o)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:null},useMedium:function(e){var t=n(e,o);return r.push(t),function(){r=r.filter(function(e){return e!==t})}},assignSyncMedium:function(e){for(o=!0;r.length;){var t=r;r=[],t.forEach(e)}r={push:function(t){return e(t)},filter:function(){return r}}},assignMedium:function(e){o=!0;var t=[];if(r.length){var n=r;r=[],n.forEach(e),t=r}var i=function(){var n=t;t=[],n.forEach(e)},l=function(){return Promise.resolve().then(i)};l(),r={push:function(e){t.push(e),l()},filter:function(e){return t=t.filter(e),r}}}});return l.options=i({async:!0,ssr:!1},e),l}(),h=function(){},g=a.forwardRef(function(e,t){var n,r,o,u,s=a.useRef(null),p=a.useState({onScrollCapture:h,onWheelCapture:h,onTouchMoveCapture:h}),g=p[0],v=p[1],y=e.forwardProps,b=e.children,w=e.className,x=e.removeScrollBar,E=e.enabled,C=e.shards,R=e.sideCar,O=e.noRelative,S=e.noIsolation,P=e.inert,A=e.allowPinchZoom,j=e.as,T=e.gapMode,_=l(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),N=(n=[s,t],r=function(e){return n.forEach(function(t){return c(t,e)})},(o=(0,a.useState)(function(){return{value:null,callback:r,facade:{get current(){return o.value},set current(value){var e=o.value;e!==value&&(o.value=value,o.callback(value,e))}}}})[0]).callback=r,u=o.facade,d(function(){var e=f.get(u);if(e){var t=new Set(e),r=new Set(n),o=u.current;t.forEach(function(e){r.has(e)||c(e,null)}),r.forEach(function(e){t.has(e)||c(e,o)})}f.set(u,n)},[n]),u),k=i(i({},_),g);return a.createElement(a.Fragment,null,E&&a.createElement(R,{sideCar:m,removeScrollBar:x,shards:C,noRelative:O,noIsolation:S,inert:P,setCallbacks:v,allowPinchZoom:!!A,lockRef:s,gapMode:T}),y?a.cloneElement(a.Children.only(b),i(i({},k),{ref:N})):a.createElement(void 0===j?"div":j,i({},k,{className:w,ref:N}),b))});g.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},g.classNames={fullWidth:s,zeroRight:u};var v=function(e){var t=e.sideCar,n=l(e,["sideCar"]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw Error("Sidecar medium not found");return a.createElement(r,i({},n))};v.isSideCarExport=!0;var y=function(){var e=0,t=null;return{add:function(r){if(0==e&&(t=function(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=o||n.nc;return t&&e.setAttribute("nonce",t),e}())){var i,l;(i=t).styleSheet?i.styleSheet.cssText=r:i.appendChild(document.createTextNode(r)),l=t,(document.head||document.getElementsByTagName("head")[0]).appendChild(l)}e++},remove:function(){--e||!t||(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},b=function(){var e=y();return function(t,n){a.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},w=function(){var e=b();return function(t){return e(t.styles,t.dynamic),null}},x={left:0,top:0,right:0,gap:0},E=function(e){return parseInt(e||"",10)||0},C=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingLeft":"marginLeft"],r=t["padding"===e?"paddingTop":"marginTop"],o=t["padding"===e?"paddingRight":"marginRight"];return[E(n),E(r),E(o)]},R=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return x;var t=C(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},O=w(),S="data-scroll-locked",P=function(e,t,n,r){var o=e.left,i=e.top,l=e.right,a=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(r,";\n padding-right: ").concat(a,"px ").concat(r,";\n }\n body[").concat(S,"] {\n overflow: hidden ").concat(r,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(r,";"),"margin"===n&&"\n padding-left: ".concat(o,"px;\n padding-top: ").concat(i,"px;\n padding-right: ").concat(l,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(a,"px ").concat(r,";\n "),"padding"===n&&"padding-right: ".concat(a,"px ").concat(r,";")].filter(Boolean).join(""),"\n }\n \n .").concat(u," {\n right: ").concat(a,"px ").concat(r,";\n }\n \n .").concat(s," {\n margin-right: ").concat(a,"px ").concat(r,";\n }\n \n .").concat(u," .").concat(u," {\n right: 0 ").concat(r,";\n }\n \n .").concat(s," .").concat(s," {\n margin-right: 0 ").concat(r,";\n }\n \n body[").concat(S,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(a,"px;\n }\n")},A=function(){var e=parseInt(document.body.getAttribute(S)||"0",10);return isFinite(e)?e:0},j=function(){a.useEffect(function(){return document.body.setAttribute(S,(A()+1).toString()),function(){var e=A()-1;e<=0?document.body.removeAttribute(S):document.body.setAttribute(S,e.toString())}},[])},T=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=void 0===r?"margin":r;j();var i=a.useMemo(function(){return R(o)},[o]);return a.createElement(O,{styles:P(i,!t,o,n?"":"!important")})},_=!1;if("undefined"!=typeof window)try{var N=Object.defineProperty({},"passive",{get:function(){return _=!0,!0}});window.addEventListener("test",N,N),window.removeEventListener("test",N,N)}catch(e){_=!1}var k=!!_&&{passive:!1},L=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&(n.overflowY!==n.overflowX||"TEXTAREA"===e.tagName||"visible"!==n[t])},M=function(e,t){var n=t.ownerDocument,r=t;do{if("undefined"!=typeof ShadowRoot&&r instanceof ShadowRoot&&(r=r.host),D(e,r)){var o=I(e,r);if(o[1]>o[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},D=function(e,t){return"v"===e?L(t,"overflowY"):L(t,"overflowX")},I=function(e,t){return"v"===e?[t.scrollTop,t.scrollHeight,t.clientHeight]:[t.scrollLeft,t.scrollWidth,t.clientWidth]},F=function(e,t,n,r,o){var i,l=(i=window.getComputedStyle(t).direction,"h"===e&&"rtl"===i?-1:1),a=l*r,u=n.target,s=t.contains(u),c=!1,d=a>0,f=0,p=0;do{if(!u)break;var m=I(e,u),h=m[0],g=m[1]-m[2]-l*h;(h||g)&&D(e,u)&&(f+=g,p+=h);var v=u.parentNode;u=v&&v.nodeType===Node.DOCUMENT_FRAGMENT_NODE?v.host:v}while(!s&&u!==document.body||s&&(t.contains(u)||t===u));return d&&(o&&1>Math.abs(f)||!o&&a>f)?c=!0:!d&&(o&&1>Math.abs(p)||!o&&-a>p)&&(c=!0),c},z=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},W=function(e){return[e.deltaX,e.deltaY]},B=function(e){return e&&"current"in e?e.current:e},U=0,H=[];let K=(r=function(e){var t=a.useRef([]),n=a.useRef([0,0]),r=a.useRef(),o=a.useState(U++)[0],i=a.useState(w)[0],l=a.useRef(e);a.useEffect(function(){l.current=e},[e]),a.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var t=(function(e,t,n){if(n||2==arguments.length)for(var r,o=0,i=t.length;oMath.abs(s)?"h":"v";if("touches"in e&&"h"===d&&"range"===c.type)return!1;var f=M(d,c);if(!f)return!0;if(f?o=d:(o="v"===d?"h":"v",f=M(d,c)),!f)return!1;if(!r.current&&"changedTouches"in e&&(u||s)&&(r.current=o),!o)return!0;var p=r.current||o;return F(p,t,e,"h"===p?u:s,!0)},[]),s=a.useCallback(function(e){if(H.length&&H[H.length-1]===i){var n="deltaY"in e?W(e):z(e),r=t.current.filter(function(t){var r;return t.name===e.type&&(t.target===e.target||e.target===t.shadowParent)&&(r=t.delta,r[0]===n[0]&&r[1]===n[1])})[0];if(r&&r.should){e.cancelable&&e.preventDefault();return}if(!r){var o=(l.current.shards||[]).map(B).filter(Boolean).filter(function(t){return t.contains(e.target)});(o.length>0?u(e,o[0]):!l.current.noIsolation)&&e.cancelable&&e.preventDefault()}}},[]),c=a.useCallback(function(e,n,r,o){var i={name:e,delta:n,target:r,should:o,shadowParent:function(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}(r)};t.current.push(i),setTimeout(function(){t.current=t.current.filter(function(e){return e!==i})},1)},[]),d=a.useCallback(function(e){n.current=z(e),r.current=void 0},[]),f=a.useCallback(function(t){c(t.type,W(t),t.target,u(t,e.lockRef.current))},[]),p=a.useCallback(function(t){c(t.type,z(t),t.target,u(t,e.lockRef.current))},[]);a.useEffect(function(){return H.push(i),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener("wheel",s,k),document.addEventListener("touchmove",s,k),document.addEventListener("touchstart",d,k),function(){H=H.filter(function(e){return e!==i}),document.removeEventListener("wheel",s,k),document.removeEventListener("touchmove",s,k),document.removeEventListener("touchstart",d,k)}},[]);var m=e.removeScrollBar,h=e.inert;return a.createElement(a.Fragment,null,h?a.createElement(i,{styles:"\n .block-interactivity-".concat(o," {pointer-events: none;}\n .allow-interactivity-").concat(o," {pointer-events: all;}\n")}):null,m?a.createElement(T,{noRelative:e.noRelative,gapMode:e.gapMode}):null)},m.useMedium(r),v);var q=a.forwardRef(function(e,t){return a.createElement(g,i({},e,{ref:t,sideCar:K}))});q.classNames=g.classNames;let G=q},3605:(e,t)=>{function n(e){let{widthInt:t,heightInt:n,blurWidth:r,blurHeight:o,blurDataURL:i,objectFit:l}=e,a=r?40*r:t,u=o?40*o:n,s=a&&u?"viewBox='0 0 "+a+" "+u+"'":"";return"%3Csvg xmlns='http://www.w3.org/2000/svg' "+s+"%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='"+(s?"none":"contain"===l?"xMidYMid":"cover"===l?"xMidYMid slice":"none")+"' style='filter: url(%23b);' href='"+i+"'/%3E%3C/svg%3E"}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getImageBlurSvg",{enumerable:!0,get:function(){return n}})},3674:(e,t)=>{function n(e){let t={};for(let[n,r]of e.entries()){let e=t[n];void 0===e?t[n]=r:Array.isArray(e)?e.push(r):t[n]=[e,r]}return t}function r(e){return"string"==typeof e?e:("number"!=typeof e||isNaN(e))&&"boolean"!=typeof e?"":String(e)}function o(e){let t=new URLSearchParams;for(let[n,o]of Object.entries(e))if(Array.isArray(o))for(let e of o)t.append(n,r(e));else t.set(n,r(o));return t}function i(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r{n.d(t,{A:()=>r});let r=(0,n(3929).A)("panel-left",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]])},3780:(e,t,n)=>{n.d(t,{hO:()=>u,sG:()=>a});var r=n(4398),o=n(5707),i=n(6950),l=n(3422),a=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,t)=>{let n=(0,i.TL)(`Primitive.${t}`),o=r.forwardRef((e,r)=>{let{asChild:o,...i}=e;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,l.jsx)(o?n:t,{...i,ref:r})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function u(e,t){e&&o.flushSync(()=>e.dispatchEvent(t))}},3871:(e,t,n)=>{n.d(t,{Eq:()=>c});var r=function(e){return"undefined"==typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},o=new WeakMap,i=new WeakMap,l={},a=0,u=function(e){return e&&(e.host||u(e.parentNode))},s=function(e,t,n,r){var s=(Array.isArray(e)?e:[e]).map(function(e){if(t.contains(e))return e;var n=u(e);return n&&t.contains(n)?n:(console.error("aria-hidden",e,"in not contained inside",t,". Doing nothing"),null)}).filter(function(e){return!!e});l[n]||(l[n]=new WeakMap);var c=l[n],d=[],f=new Set,p=new Set(s),m=function(e){!e||f.has(e)||(f.add(e),m(e.parentNode))};s.forEach(m);var h=function(e){!e||p.has(e)||Array.prototype.forEach.call(e.children,function(e){if(f.has(e))h(e);else try{var t=e.getAttribute(r),l=null!==t&&"false"!==t,a=(o.get(e)||0)+1,u=(c.get(e)||0)+1;o.set(e,a),c.set(e,u),d.push(e),1===a&&l&&i.set(e,!0),1===u&&e.setAttribute(n,"true"),l||e.setAttribute(r,"true")}catch(t){console.error("aria-hidden: cannot operate on ",e,t)}})};return h(t),f.clear(),a++,function(){d.forEach(function(e){var t=o.get(e)-1,l=c.get(e)-1;o.set(e,t),c.set(e,l),t||(i.has(e)||e.removeAttribute(r),i.delete(e)),l||e.removeAttribute(n)}),--a||(o=new WeakMap,o=new WeakMap,i=new WeakMap,l={})}},c=function(e,t,n){void 0===n&&(n="data-aria-hidden");var o=Array.from(Array.isArray(e)?e:[e]),i=t||r(e);return i?(o.push.apply(o,Array.from(i.querySelectorAll("[aria-live], script"))),s(o,i,n,"aria-hidden")):function(){return null}}},3891:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"ImageConfigContext",{enumerable:!0,get:function(){return i}});let r=n(5348)._(n(4398)),o=n(8585),i=r.default.createContext(o.imageConfigDefault)},3929:(e,t,n)=>{n.d(t,{A:()=>d});var r=n(4398);let o=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),i=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),l=e=>{let t=i(e);return t.charAt(0).toUpperCase()+t.slice(1)},a=function(){for(var e=arguments.length,t=Array(e),n=0;n!!e&&""!==e.trim()&&n.indexOf(e)===t).join(" ").trim()},u=e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0};var s={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"};let c=(0,r.forwardRef)((e,t)=>{let{color:n="currentColor",size:o=24,strokeWidth:i=2,absoluteStrokeWidth:l,className:c="",children:d,iconNode:f,...p}=e;return(0,r.createElement)("svg",{ref:t,...s,width:o,height:o,stroke:n,strokeWidth:l?24*Number(i)/Number(o):i,className:a("lucide",c),...!d&&!u(p)&&{"aria-hidden":"true"},...p},[...f.map(e=>{let[t,n]=e;return(0,r.createElement)(t,n)}),...Array.isArray(d)?d:[d]])}),d=(e,t)=>{let n=(0,r.forwardRef)((n,i)=>{let{className:u,...s}=n;return(0,r.createElement)(c,{ref:i,iconNode:t,className:a("lucide-".concat(o(l(e))),"lucide-".concat(e),u),...s})});return n.displayName=l(e),n}},4032:(e,t,n)=>{n.d(t,{Kq:()=>K,UC:()=>X,ZL:()=>V,bL:()=>q,i3:()=>$,l9:()=>G});var r=n(4398),o=n(6687),i=n(2050),l=n(940),a=n(3213),u=n(6565),s=n(6387),c=n(1732),d=n(6175),f=n(3780),p=n(6950),m=n(6657),h=n(1581),g=n(3422),[v,y]=(0,l.A)("Tooltip",[s.Bk]),b=(0,s.Bk)(),w="TooltipProvider",x="tooltip.open",[E,C]=v(w),R=e=>{let{__scopeTooltip:t,delayDuration:n=700,skipDelayDuration:o=300,disableHoverableContent:i=!1,children:l}=e,a=r.useRef(!0),u=r.useRef(!1),s=r.useRef(0);return r.useEffect(()=>{let e=s.current;return()=>window.clearTimeout(e)},[]),(0,g.jsx)(E,{scope:t,isOpenDelayedRef:a,delayDuration:n,onOpen:r.useCallback(()=>{window.clearTimeout(s.current),a.current=!1},[]),onClose:r.useCallback(()=>{window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.current=!0,o)},[o]),isPointerInTransitRef:u,onPointerInTransitChange:r.useCallback(e=>{u.current=e},[]),disableHoverableContent:i,children:l})};R.displayName=w;var O="Tooltip",[S,P]=v(O),A=e=>{let{__scopeTooltip:t,children:n,open:o,defaultOpen:i,onOpenChange:l,disableHoverableContent:a,delayDuration:c}=e,d=C(O,e.__scopeTooltip),f=b(t),[p,h]=r.useState(null),v=(0,u.B)(),y=r.useRef(0),w=null!=a?a:d.disableHoverableContent,E=null!=c?c:d.delayDuration,R=r.useRef(!1),[P,A]=(0,m.i)({prop:o,defaultProp:null!=i&&i,onChange:e=>{e?(d.onOpen(),document.dispatchEvent(new CustomEvent(x))):d.onClose(),null==l||l(e)},caller:O}),j=r.useMemo(()=>P?R.current?"delayed-open":"instant-open":"closed",[P]),T=r.useCallback(()=>{window.clearTimeout(y.current),y.current=0,R.current=!1,A(!0)},[A]),_=r.useCallback(()=>{window.clearTimeout(y.current),y.current=0,A(!1)},[A]),N=r.useCallback(()=>{window.clearTimeout(y.current),y.current=window.setTimeout(()=>{R.current=!0,A(!0),y.current=0},E)},[E,A]);return r.useEffect(()=>()=>{y.current&&(window.clearTimeout(y.current),y.current=0)},[]),(0,g.jsx)(s.bL,{...f,children:(0,g.jsx)(S,{scope:t,contentId:v,open:P,stateAttribute:j,trigger:p,onTriggerChange:h,onTriggerEnter:r.useCallback(()=>{d.isOpenDelayedRef.current?N():T()},[d.isOpenDelayedRef,N,T]),onTriggerLeave:r.useCallback(()=>{w?_():(window.clearTimeout(y.current),y.current=0)},[_,w]),onOpen:T,onClose:_,disableHoverableContent:w,children:n})})};A.displayName=O;var j="TooltipTrigger",T=r.forwardRef((e,t)=>{let{__scopeTooltip:n,...l}=e,a=P(j,n),u=C(j,n),c=b(n),d=r.useRef(null),p=(0,i.s)(t,d,a.onTriggerChange),m=r.useRef(!1),h=r.useRef(!1),v=r.useCallback(()=>m.current=!1,[]);return r.useEffect(()=>()=>document.removeEventListener("pointerup",v),[v]),(0,g.jsx)(s.Mz,{asChild:!0,...c,children:(0,g.jsx)(f.sG.button,{"aria-describedby":a.open?a.contentId:void 0,"data-state":a.stateAttribute,...l,ref:p,onPointerMove:(0,o.mK)(e.onPointerMove,e=>{"touch"!==e.pointerType&&(h.current||u.isPointerInTransitRef.current||(a.onTriggerEnter(),h.current=!0))}),onPointerLeave:(0,o.mK)(e.onPointerLeave,()=>{a.onTriggerLeave(),h.current=!1}),onPointerDown:(0,o.mK)(e.onPointerDown,()=>{a.open&&a.onClose(),m.current=!0,document.addEventListener("pointerup",v,{once:!0})}),onFocus:(0,o.mK)(e.onFocus,()=>{m.current||a.onOpen()}),onBlur:(0,o.mK)(e.onBlur,a.onClose),onClick:(0,o.mK)(e.onClick,a.onClose)})})});T.displayName=j;var _="TooltipPortal",[N,k]=v(_,{forceMount:void 0}),L=e=>{let{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,i=P(_,t);return(0,g.jsx)(N,{scope:t,forceMount:n,children:(0,g.jsx)(d.C,{present:n||i.open,children:(0,g.jsx)(c.Z,{asChild:!0,container:o,children:r})})})};L.displayName=_;var M="TooltipContent",D=r.forwardRef((e,t)=>{let n=k(M,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...i}=e,l=P(M,e.__scopeTooltip);return(0,g.jsx)(d.C,{present:r||l.open,children:l.disableHoverableContent?(0,g.jsx)(B,{side:o,...i,ref:t}):(0,g.jsx)(I,{side:o,...i,ref:t})})}),I=r.forwardRef((e,t)=>{let n=P(M,e.__scopeTooltip),o=C(M,e.__scopeTooltip),l=r.useRef(null),a=(0,i.s)(t,l),[u,s]=r.useState(null),{trigger:c,onClose:d}=n,f=l.current,{onPointerInTransitChange:p}=o,m=r.useCallback(()=>{s(null),p(!1)},[p]),h=r.useCallback((e,t)=>{let n=e.currentTarget,r={x:e.clientX,y:e.clientY},o=function(e,t){let n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,o,i)){case i:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw Error("unreachable")}}(r,n.getBoundingClientRect());s(function(e){let t=e.slice();return t.sort((e,t)=>e.xt.x?1:e.yt.y)),function(e){if(e.length<=1)return e.slice();let t=[];for(let n=0;n=2;){let e=t[t.length-1],n=t[t.length-2];if((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x))t.pop();else break}t.push(r)}t.pop();let n=[];for(let t=e.length-1;t>=0;t--){let r=e[t];for(;n.length>=2;){let e=n[n.length-1],t=n[n.length-2];if((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.x))n.pop();else break}n.push(r)}return(n.pop(),1===t.length&&1===n.length&&t[0].x===n[0].x&&t[0].y===n[0].y)?t:t.concat(n)}(t)}([...function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n})}return r}(r,o),...function(e){let{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}(t.getBoundingClientRect())])),p(!0)},[p]);return r.useEffect(()=>()=>m(),[m]),r.useEffect(()=>{if(c&&f){let e=e=>h(e,f),t=e=>h(e,c);return c.addEventListener("pointerleave",e),f.addEventListener("pointerleave",t),()=>{c.removeEventListener("pointerleave",e),f.removeEventListener("pointerleave",t)}}},[c,f,h,m]),r.useEffect(()=>{if(u){let e=e=>{let t=e.target,n={x:e.clientX,y:e.clientY},r=(null==c?void 0:c.contains(t))||(null==f?void 0:f.contains(t)),o=!function(e,t){let{x:n,y:r}=e,o=!1;for(let e=0,i=t.length-1;er!=d>r&&n<(c-u)*(r-s)/(d-s)+u&&(o=!o)}return o}(n,u);r?m():o&&(m(),d())};return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}},[c,f,u,d,m]),(0,g.jsx)(B,{...e,ref:a})}),[F,z]=v(O,{isInside:!1}),W=(0,p.Dc)("TooltipContent"),B=r.forwardRef((e,t)=>{let{__scopeTooltip:n,children:o,"aria-label":i,onEscapeKeyDown:l,onPointerDownOutside:u,...c}=e,d=P(M,n),f=b(n),{onClose:p}=d;return r.useEffect(()=>(document.addEventListener(x,p),()=>document.removeEventListener(x,p)),[p]),r.useEffect(()=>{if(d.trigger){let e=e=>{let t=e.target;(null==t?void 0:t.contains(d.trigger))&&p()};return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}},[d.trigger,p]),(0,g.jsx)(a.qW,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:e=>e.preventDefault(),onDismiss:p,children:(0,g.jsxs)(s.UC,{"data-state":d.stateAttribute,...f,...c,ref:t,style:{...c.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:[(0,g.jsx)(W,{children:o}),(0,g.jsx)(F,{scope:n,isInside:!0,children:(0,g.jsx)(h.bL,{id:d.contentId,role:"tooltip",children:i||o})})]})})});D.displayName=M;var U="TooltipArrow",H=r.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,o=b(n);return z(U,n).isInside?null:(0,g.jsx)(s.i3,{...o,...r,ref:t})});H.displayName=U;var K=R,q=A,G=T,V=L,X=D,$=H},4059:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{default:function(){return u},getImageProps:function(){return a}});let r=n(5348),o=n(2287),i=n(1200),l=r._(n(7352));function a(e){let{props:t}=(0,o.getImgProps)(e,{defaultLoader:l.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image/",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!0}});for(let[e,n]of Object.entries(t))void 0===n&&delete t[e];return{props:t}}let u=i.Image},4316:(e,t,n)=>{n.d(t,{G$:()=>X,Hs:()=>x,UC:()=>en,VY:()=>eo,ZL:()=>ee,bL:()=>J,bm:()=>ei,hE:()=>er,hJ:()=>et,l9:()=>Q});var r=n(4398),o=n(6687),i=n(2050),l=n(940),a=n(6565),u=n(6657),s=n(3213),c=n(3138),d=n(1732),f=n(6175),p=n(3780),m=n(7),h=n(3338),g=n(3871),v=n(6950),y=n(3422),b="Dialog",[w,x]=(0,l.A)(b),[E,C]=w(b),R=e=>{let{__scopeDialog:t,children:n,open:o,defaultOpen:i,onOpenChange:l,modal:s=!0}=e,c=r.useRef(null),d=r.useRef(null),[f,p]=(0,u.i)({prop:o,defaultProp:null!=i&&i,onChange:l,caller:b});return(0,y.jsx)(E,{scope:t,triggerRef:c,contentRef:d,contentId:(0,a.B)(),titleId:(0,a.B)(),descriptionId:(0,a.B)(),open:f,onOpenChange:p,onOpenToggle:r.useCallback(()=>p(e=>!e),[p]),modal:s,children:n})};R.displayName=b;var O="DialogTrigger",S=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,l=C(O,n),a=(0,i.s)(t,l.triggerRef);return(0,y.jsx)(p.sG.button,{type:"button","aria-haspopup":"dialog","aria-expanded":l.open,"aria-controls":l.contentId,"data-state":G(l.open),...r,ref:a,onClick:(0,o.mK)(e.onClick,l.onOpenToggle)})});S.displayName=O;var P="DialogPortal",[A,j]=w(P,{forceMount:void 0}),T=e=>{let{__scopeDialog:t,forceMount:n,children:o,container:i}=e,l=C(P,t);return(0,y.jsx)(A,{scope:t,forceMount:n,children:r.Children.map(o,e=>(0,y.jsx)(f.C,{present:n||l.open,children:(0,y.jsx)(d.Z,{asChild:!0,container:i,children:e})}))})};T.displayName=P;var _="DialogOverlay",N=r.forwardRef((e,t)=>{let n=j(_,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=C(_,e.__scopeDialog);return i.modal?(0,y.jsx)(f.C,{present:r||i.open,children:(0,y.jsx)(L,{...o,ref:t})}):null});N.displayName=_;var k=(0,v.TL)("DialogOverlay.RemoveScroll"),L=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,o=C(_,n);return(0,y.jsx)(h.A,{as:k,allowPinchZoom:!0,shards:[o.contentRef],children:(0,y.jsx)(p.sG.div,{"data-state":G(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),M="DialogContent",D=r.forwardRef((e,t)=>{let n=j(M,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,i=C(M,e.__scopeDialog);return(0,y.jsx)(f.C,{present:r||i.open,children:i.modal?(0,y.jsx)(I,{...o,ref:t}):(0,y.jsx)(F,{...o,ref:t})})});D.displayName=M;var I=r.forwardRef((e,t)=>{let n=C(M,e.__scopeDialog),l=r.useRef(null),a=(0,i.s)(t,n.contentRef,l);return r.useEffect(()=>{let e=l.current;if(e)return(0,g.Eq)(e)},[]),(0,y.jsx)(z,{...e,ref:a,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:(0,o.mK)(e.onCloseAutoFocus,e=>{var t;e.preventDefault(),null==(t=n.triggerRef.current)||t.focus()}),onPointerDownOutside:(0,o.mK)(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey;(2===t.button||n)&&e.preventDefault()}),onFocusOutside:(0,o.mK)(e.onFocusOutside,e=>e.preventDefault())})}),F=r.forwardRef((e,t)=>{let n=C(M,e.__scopeDialog),o=r.useRef(!1),i=r.useRef(!1);return(0,y.jsx)(z,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var r,l;null==(r=e.onCloseAutoFocus)||r.call(e,t),t.defaultPrevented||(o.current||null==(l=n.triggerRef.current)||l.focus(),t.preventDefault()),o.current=!1,i.current=!1},onInteractOutside:t=>{var r,l;null==(r=e.onInteractOutside)||r.call(e,t),t.defaultPrevented||(o.current=!0,"pointerdown"===t.detail.originalEvent.type&&(i.current=!0));let a=t.target;(null==(l=n.triggerRef.current)?void 0:l.contains(a))&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&i.current&&t.preventDefault()}})}),z=r.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:o,onOpenAutoFocus:l,onCloseAutoFocus:a,...u}=e,d=C(M,n),f=r.useRef(null),p=(0,i.s)(t,f);return(0,m.Oh)(),(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(c.n,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:l,onUnmountAutoFocus:a,children:(0,y.jsx)(s.qW,{role:"dialog",id:d.contentId,"aria-describedby":d.descriptionId,"aria-labelledby":d.titleId,"data-state":G(d.open),...u,ref:p,onDismiss:()=>d.onOpenChange(!1)})}),(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(Y,{titleId:d.titleId}),(0,y.jsx)(Z,{contentRef:f,descriptionId:d.descriptionId})]})]})}),W="DialogTitle",B=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,o=C(W,n);return(0,y.jsx)(p.sG.h2,{id:o.titleId,...r,ref:t})});B.displayName=W;var U="DialogDescription",H=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,o=C(U,n);return(0,y.jsx)(p.sG.p,{id:o.descriptionId,...r,ref:t})});H.displayName=U;var K="DialogClose",q=r.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=C(K,n);return(0,y.jsx)(p.sG.button,{type:"button",...r,ref:t,onClick:(0,o.mK)(e.onClick,()=>i.onOpenChange(!1))})});function G(e){return e?"open":"closed"}q.displayName=K;var V="DialogTitleWarning",[X,$]=(0,l.q)(V,{contentName:M,titleName:W,docsSlug:"dialog"}),Y=e=>{let{titleId:t}=e,n=$(V),o="`".concat(n.contentName,"` requires a `").concat(n.titleName,"` for the component to be accessible for screen reader users.\n\nIf you want to hide the `").concat(n.titleName,"`, you can wrap it with our VisuallyHidden component.\n\nFor more information, see https://radix-ui.com/primitives/docs/components/").concat(n.docsSlug);return r.useEffect(()=>{t&&(document.getElementById(t)||console.error(o))},[o,t]),null},Z=e=>{let{contentRef:t,descriptionId:n}=e,o=$("DialogDescriptionWarning"),i="Warning: Missing `Description` or `aria-describedby={undefined}` for {".concat(o.contentName,"}.");return r.useEffect(()=>{var e;let r=null==(e=t.current)?void 0:e.getAttribute("aria-describedby");n&&r&&(document.getElementById(n)||console.warn(i))},[i,t,n]),null},J=R,Q=S,ee=T,et=N,en=D,er=B,eo=H,ei=q},4450:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{formatUrl:function(){return i},formatWithValidation:function(){return a},urlObjectKeys:function(){return l}});let r=n(4900)._(n(3674)),o=/https?|ftp|gopher|file/;function i(e){let{auth:t,hostname:n}=e,i=e.protocol||"",l=e.pathname||"",a=e.hash||"",u=e.query||"",s=!1;t=t?encodeURIComponent(t).replace(/%3A/i,":")+"@":"",e.host?s=t+e.host:n&&(s=t+(~n.indexOf(":")?"["+n+"]":n),e.port&&(s+=":"+e.port)),u&&"object"==typeof u&&(u=String(r.urlQueryToSearchParams(u)));let c=e.search||u&&"?"+u||"";return i&&!i.endsWith(":")&&(i+=":"),e.slashes||(!i||o.test(i))&&!1!==s?(s="//"+(s||""),l&&"/"!==l[0]&&(l="/"+l)):s||(s=""),a&&"#"!==a[0]&&(a="#"+a),c&&"?"!==c[0]&&(c="?"+c),""+i+s+(l=l.replace(/[?#]/g,encodeURIComponent))+(c=c.replace("#","%23"))+a}let l=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function a(e){return i(e)}},4653:(e,t,n)=>{var r=n(3124);Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{default:function(){return g},defaultHead:function(){return f}});let o=n(5348),i=n(4900),l=n(3422),a=i._(n(4398)),u=o._(n(5178)),s=n(9749),c=n(5157),d=n(2305);function f(e){void 0===e&&(e=!1);let t=[(0,l.jsx)("meta",{charSet:"utf-8"},"charset")];return e||t.push((0,l.jsx)("meta",{name:"viewport",content:"width=device-width"},"viewport")),t}function p(e,t){return"string"==typeof t||"number"==typeof t?e:t.type===a.default.Fragment?e.concat(a.default.Children.toArray(t.props.children).reduce((e,t)=>"string"==typeof t||"number"==typeof t?e:e.concat(t),[])):e.concat(t)}n(5145);let m=["name","httpEquiv","charSet","itemProp"];function h(e,t){let{inAmpMode:n}=t;return e.reduce(p,[]).reverse().concat(f(n).reverse()).filter(function(){let e=new Set,t=new Set,n=new Set,r={};return o=>{let i=!0,l=!1;if(o.key&&"number"!=typeof o.key&&o.key.indexOf("$")>0){l=!0;let t=o.key.slice(o.key.indexOf("$")+1);e.has(t)?i=!1:e.add(t)}switch(o.type){case"title":case"base":t.has(o.type)?i=!1:t.add(o.type);break;case"meta":for(let e=0,t=m.length;e{let o=e.key||t;if(r.env.__NEXT_OPTIMIZE_FONTS&&!n&&"link"===e.type&&e.props.href&&["https://fonts.googleapis.com/css","https://use.typekit.net/"].some(t=>e.props.href.startsWith(t))){let t={...e.props||{}};return t["data-href"]=t.href,t.href=void 0,t["data-optimized-fonts"]=!0,a.default.cloneElement(e,t)}return a.default.cloneElement(e,{key:o})})}let g=function(e){let{children:t}=e,n=(0,a.useContext)(s.AmpStateContext),r=(0,a.useContext)(c.HeadManagerContext);return(0,l.jsx)(u.default,{reduceComponentsToState:h,headManager:r,inAmpMode:(0,d.isInAmpMode)(n),children:t})};("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},4753:(e,t,n)=>{n.d(t,{X:()=>i});var r=n(4398),o=n(3177);function i(e){let[t,n]=r.useState(void 0);return(0,o.N)(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{let r,o;if(!Array.isArray(t)||!t.length)return;let i=t[0];if("borderBoxSize"in i){let e=i.borderBoxSize,t=Array.isArray(e)?e[0]:e;r=t.inlineSize,o=t.blockSize}else r=e.offsetWidth,o=e.offsetHeight;n({width:r,height:o})});return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)},[e]),t}},5178:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return l}});let r=n(4398),o=r.useLayoutEffect,i=r.useEffect;function l(e){let{headManager:t,reduceComponentsToState:n}=e;function l(){if(t&&t.mountedInstances){let o=r.Children.toArray(Array.from(t.mountedInstances).filter(Boolean));t.updateHead(n(o,e))}}return o(()=>{var n;return null==t||null==(n=t.mountedInstances)||n.add(e.children),()=>{var n;null==t||null==(n=t.mountedInstances)||n.delete(e.children)}}),o(()=>(t&&(t._pendingUpdate=l),()=>{t&&(t._pendingUpdate=l)})),i(()=>(t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null),()=>{t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null)})),null}},6175:(e,t,n)=>{n.d(t,{C:()=>l});var r=n(4398),o=n(2050),i=n(3177),l=e=>{let{present:t,children:n}=e,l=function(e){var t,n;let[o,l]=r.useState(),u=r.useRef(null),s=r.useRef(e),c=r.useRef("none"),[d,f]=(t=e?"mounted":"unmounted",n={mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}},r.useReducer((e,t)=>{let r=n[e][t];return null!=r?r:e},t));return r.useEffect(()=>{let e=a(u.current);c.current="mounted"===d?e:"none"},[d]),(0,i.N)(()=>{let t=u.current,n=s.current;if(n!==e){let r=c.current,o=a(t);e?f("MOUNT"):"none"===o||(null==t?void 0:t.display)==="none"?f("UNMOUNT"):n&&r!==o?f("ANIMATION_OUT"):f("UNMOUNT"),s.current=e}},[e,f]),(0,i.N)(()=>{if(o){var e;let t,n=null!=(e=o.ownerDocument.defaultView)?e:window,r=e=>{let r=a(u.current).includes(CSS.escape(e.animationName));if(e.target===o&&r&&(f("ANIMATION_END"),!s.current)){let e=o.style.animationFillMode;o.style.animationFillMode="forwards",t=n.setTimeout(()=>{"forwards"===o.style.animationFillMode&&(o.style.animationFillMode=e)})}},i=e=>{e.target===o&&(c.current=a(u.current))};return o.addEventListener("animationstart",i),o.addEventListener("animationcancel",r),o.addEventListener("animationend",r),()=>{n.clearTimeout(t),o.removeEventListener("animationstart",i),o.removeEventListener("animationcancel",r),o.removeEventListener("animationend",r)}}f("ANIMATION_END")},[o,f]),{isPresent:["mounted","unmountSuspended"].includes(d),ref:r.useCallback(e=>{u.current=e?getComputedStyle(e):null,l(e)},[])}}(t),u="function"==typeof n?n({present:l.isPresent}):r.Children.only(n),s=(0,o.s)(l.ref,function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?e.ref:(o=(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get)&&"isReactWarning"in r&&r.isReactWarning)?e.props.ref:e.props.ref||e.ref}(u));return"function"==typeof n||l.isPresent?r.cloneElement(u,{ref:s}):null};function a(e){return(null==e?void 0:e.animationName)||"none"}l.displayName="Presence"},6387:(e,t,n)=>{n.d(t,{Mz:()=>te,i3:()=>tn,UC:()=>tt,bL:()=>e6,Bk:()=>eV});var r=n(4398);let o=["top","right","bottom","left"],i=Math.min,l=Math.max,a=Math.round,u=Math.floor,s=e=>({x:e,y:e}),c={left:"right",right:"left",bottom:"top",top:"bottom"},d={start:"end",end:"start"};function f(e,t){return"function"==typeof e?e(t):e}function p(e){return e.split("-")[0]}function m(e){return e.split("-")[1]}function h(e){return"x"===e?"y":"x"}function g(e){return"y"===e?"height":"width"}let v=new Set(["top","bottom"]);function y(e){return v.has(p(e))?"y":"x"}function b(e){return e.replace(/start|end/g,e=>d[e])}let w=["left","right"],x=["right","left"],E=["top","bottom"],C=["bottom","top"];function R(e){return e.replace(/left|right|bottom|top/g,e=>c[e])}function O(e){return"number"!=typeof e?{top:0,right:0,bottom:0,left:0,...e}:{top:e,right:e,bottom:e,left:e}}function S(e){let{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function P(e,t,n){let r,{reference:o,floating:i}=e,l=y(t),a=h(y(t)),u=g(a),s=p(t),c="y"===l,d=o.x+o.width/2-i.width/2,f=o.y+o.height/2-i.height/2,v=o[u]/2-i[u]/2;switch(s){case"top":r={x:d,y:o.y-i.height};break;case"bottom":r={x:d,y:o.y+o.height};break;case"right":r={x:o.x+o.width,y:f};break;case"left":r={x:o.x-i.width,y:f};break;default:r={x:o.x,y:o.y}}switch(m(t)){case"start":r[a]-=v*(n&&c?-1:1);break;case"end":r[a]+=v*(n&&c?-1:1)}return r}let A=async(e,t,n)=>{let{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:l}=n,a=i.filter(Boolean),u=await (null==l.isRTL?void 0:l.isRTL(t)),s=await l.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:d}=P(s,r,u),f=r,p={},m=0;for(let n=0;ne[t]>=0)}let N=new Set(["left","top"]);async function k(e,t){let{placement:n,platform:r,elements:o}=e,i=await (null==r.isRTL?void 0:r.isRTL(o.floating)),l=p(n),a=m(n),u="y"===y(n),s=N.has(l)?-1:1,c=i&&u?-1:1,d=f(t,e),{mainAxis:h,crossAxis:g,alignmentAxis:v}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&"number"==typeof v&&(g="end"===a?-1*v:v),u?{x:g*c,y:h*s}:{x:h*s,y:g*c}}function L(){return"undefined"!=typeof window}function M(e){return F(e)?(e.nodeName||"").toLowerCase():"#document"}function D(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function I(e){var t;return null==(t=(F(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function F(e){return!!L()&&(e instanceof Node||e instanceof D(e).Node)}function z(e){return!!L()&&(e instanceof Element||e instanceof D(e).Element)}function W(e){return!!L()&&(e instanceof HTMLElement||e instanceof D(e).HTMLElement)}function B(e){return!!L()&&"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof D(e).ShadowRoot)}let U=new Set(["inline","contents"]);function H(e){let{overflow:t,overflowX:n,overflowY:r,display:o}=ee(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!U.has(o)}let K=new Set(["table","td","th"]),q=[":popover-open",":modal"];function G(e){return q.some(t=>{try{return e.matches(t)}catch(e){return!1}})}let V=["transform","translate","scale","rotate","perspective"],X=["transform","translate","scale","rotate","perspective","filter"],$=["paint","layout","strict","content"];function Y(e){let t=Z(),n=z(e)?ee(e):e;return V.some(e=>!!n[e]&&"none"!==n[e])||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||X.some(e=>(n.willChange||"").includes(e))||$.some(e=>(n.contain||"").includes(e))}function Z(){return"undefined"!=typeof CSS&&!!CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")}let J=new Set(["html","body","#document"]);function Q(e){return J.has(M(e))}function ee(e){return D(e).getComputedStyle(e)}function et(e){return z(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function en(e){if("html"===M(e))return e;let t=e.assignedSlot||e.parentNode||B(e)&&e.host||I(e);return B(t)?t.host:t}function er(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);let o=function e(t){let n=en(t);return Q(n)?t.ownerDocument?t.ownerDocument.body:t.body:W(n)&&H(n)?n:e(n)}(e),i=o===(null==(r=e.ownerDocument)?void 0:r.body),l=D(o);if(i){let e=eo(l);return t.concat(l,l.visualViewport||[],H(o)?o:[],e&&n?er(e):[])}return t.concat(o,er(o,[],n))}function eo(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ei(e){let t=ee(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,o=W(e),i=o?e.offsetWidth:n,l=o?e.offsetHeight:r,u=a(n)!==i||a(r)!==l;return u&&(n=i,r=l),{width:n,height:r,$:u}}function el(e){return z(e)?e:e.contextElement}function ea(e){let t=el(e);if(!W(t))return s(1);let n=t.getBoundingClientRect(),{width:r,height:o,$:i}=ei(t),l=(i?a(n.width):n.width)/r,u=(i?a(n.height):n.height)/o;return l&&Number.isFinite(l)||(l=1),u&&Number.isFinite(u)||(u=1),{x:l,y:u}}let eu=s(0);function es(e){let t=D(e);return Z()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:eu}function ec(e,t,n,r){var o;void 0===t&&(t=!1),void 0===n&&(n=!1);let i=e.getBoundingClientRect(),l=el(e),a=s(1);t&&(r?z(r)&&(a=ea(r)):a=ea(e));let u=(void 0===(o=n)&&(o=!1),r&&(!o||r===D(l))&&o)?es(l):s(0),c=(i.left+u.x)/a.x,d=(i.top+u.y)/a.y,f=i.width/a.x,p=i.height/a.y;if(l){let e=D(l),t=r&&z(r)?D(r):r,n=e,o=eo(n);for(;o&&r&&t!==n;){let e=ea(o),t=o.getBoundingClientRect(),r=ee(o),i=t.left+(o.clientLeft+parseFloat(r.paddingLeft))*e.x,l=t.top+(o.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,d*=e.y,f*=e.x,p*=e.y,c+=i,d+=l,o=eo(n=D(o))}}return S({width:f,height:p,x:c,y:d})}function ed(e,t){let n=et(e).scrollLeft;return t?t.left+n:ec(I(e)).left+n}function ef(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-ed(e,n),y:n.top+t.scrollTop}}let ep=new Set(["absolute","fixed"]);function em(e,t,n){let r;if("viewport"===t)r=function(e,t){let n=D(e),r=I(e),o=n.visualViewport,i=r.clientWidth,l=r.clientHeight,a=0,u=0;if(o){i=o.width,l=o.height;let e=Z();(!e||e&&"fixed"===t)&&(a=o.offsetLeft,u=o.offsetTop)}let s=ed(r);if(s<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),o="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,l=Math.abs(r.clientWidth-t.clientWidth-o);l<=25&&(i-=l)}else s<=25&&(i+=s);return{width:i,height:l,x:a,y:u}}(e,n);else if("document"===t)r=function(e){let t=I(e),n=et(e),r=e.ownerDocument.body,o=l(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=l(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),a=-n.scrollLeft+ed(e),u=-n.scrollTop;return"rtl"===ee(r).direction&&(a+=l(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:a,y:u}}(I(e));else if(z(t))r=function(e,t){let n=ec(e,!0,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=W(e)?ea(e):s(1),l=e.clientWidth*i.x,a=e.clientHeight*i.y;return{width:l,height:a,x:o*i.x,y:r*i.y}}(t,n);else{let n=es(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return S(r)}function eh(e){return"static"===ee(e).position}function eg(e,t){if(!W(e)||"fixed"===ee(e).position)return null;if(t)return t(e);let n=e.offsetParent;return I(e)===n&&(n=n.ownerDocument.body),n}function ev(e,t){var n;let r=D(e);if(G(e))return r;if(!W(e)){let t=en(e);for(;t&&!Q(t);){if(z(t)&&!eh(t))return t;t=en(t)}return r}let o=eg(e,t);for(;o&&(n=o,K.has(M(n)))&&eh(o);)o=eg(o,t);return o&&Q(o)&&eh(o)&&!Y(o)?r:o||function(e){let t=en(e);for(;W(t)&&!Q(t);){if(Y(t))return t;if(G(t))break;t=en(t)}return null}(e)||r}let ey=async function(e){let t=this.getOffsetParent||ev,n=this.getDimensions,r=await n(e.floating);return{reference:function(e,t,n){let r=W(t),o=I(t),i="fixed"===n,l=ec(e,!0,i,t),a={scrollLeft:0,scrollTop:0},u=s(0);if(r||!r&&!i)if(("body"!==M(t)||H(o))&&(a=et(t)),r){let e=ec(t,!0,i,t);u.x=e.x+t.clientLeft,u.y=e.y+t.clientTop}else o&&(u.x=ed(o));i&&!r&&o&&(u.x=ed(o));let c=!o||r||i?s(0):ef(o,a);return{x:l.left+a.scrollLeft-u.x-c.x,y:l.top+a.scrollTop-u.y-c.y,width:l.width,height:l.height}}(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},eb={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e,i="fixed"===o,l=I(r),a=!!t&&G(t.floating);if(r===l||a&&i)return n;let u={scrollLeft:0,scrollTop:0},c=s(1),d=s(0),f=W(r);if((f||!f&&!i)&&(("body"!==M(r)||H(l))&&(u=et(r)),W(r))){let e=ec(r);c=ea(r),d.x=e.x+r.clientLeft,d.y=e.y+r.clientTop}let p=!l||f||i?s(0):ef(l,u);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-u.scrollLeft*c.x+d.x+p.x,y:n.y*c.y-u.scrollTop*c.y+d.y+p.y}},getDocumentElement:I,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e,a=[..."clippingAncestors"===n?G(t)?[]:function(e,t){let n=t.get(e);if(n)return n;let r=er(e,[],!1).filter(e=>z(e)&&"body"!==M(e)),o=null,i="fixed"===ee(e).position,l=i?en(e):e;for(;z(l)&&!Q(l);){let t=ee(l),n=Y(l);n||"fixed"!==t.position||(o=null),(i?!n&&!o:!n&&"static"===t.position&&!!o&&ep.has(o.position)||H(l)&&!n&&function e(t,n){let r=en(t);return!(r===n||!z(r)||Q(r))&&("fixed"===ee(r).position||e(r,n))}(e,l))?r=r.filter(e=>e!==l):o=t,l=en(l)}return t.set(e,r),r}(t,this._c):[].concat(n),r],u=a[0],s=a.reduce((e,n)=>{let r=em(t,n,o);return e.top=l(r.top,e.top),e.right=i(r.right,e.right),e.bottom=i(r.bottom,e.bottom),e.left=l(r.left,e.left),e},em(t,u,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:ev,getElementRects:ey,getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){let{width:t,height:n}=ei(e);return{width:t,height:n}},getScale:ea,isElement:z,isRTL:function(e){return"rtl"===ee(e).direction}};function ew(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}let ex=e=>({name:"arrow",options:e,async fn(t){let{x:n,y:r,placement:o,rects:a,platform:u,elements:s,middlewareData:c}=t,{element:d,padding:p=0}=f(e,t)||{};if(null==d)return{};let v=O(p),b={x:n,y:r},w=h(y(o)),x=g(w),E=await u.getDimensions(d),C="y"===w,R=C?"clientHeight":"clientWidth",S=a.reference[x]+a.reference[w]-b[w]-a.floating[x],P=b[w]-a.reference[w],A=await (null==u.getOffsetParent?void 0:u.getOffsetParent(d)),j=A?A[R]:0;j&&await (null==u.isElement?void 0:u.isElement(A))||(j=s.floating[R]||a.floating[x]);let T=j/2-E[x]/2-1,_=i(v[C?"top":"left"],T),N=i(v[C?"bottom":"right"],T),k=j-E[x]-N,L=j/2-E[x]/2+(S/2-P/2),M=l(_,i(L,k)),D=!c.arrow&&null!=m(o)&&L!==M&&a.reference[x]/2-(L<_?_:N)-E[x]/2<0,I=D?L<_?L-_:L-k:0;return{[w]:b[w]+I,data:{[w]:M,centerOffset:L-M-I,...D&&{alignmentOffset:I}},reset:D}}}),eE=(e,t,n)=>{let r=new Map,o={platform:eb,...n},i={...o.platform,_c:r};return A(e,t,{...o,platform:i})};var eC=n(5707),eR="undefined"!=typeof document?r.useLayoutEffect:function(){};function eO(e,t){let n,r,o;if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if((n=e.length)!==t.length)return!1;for(r=n;0!=r--;)if(!eO(e[r],t[r]))return!1;return!0}if((n=(o=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!({}).hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){let n=o[r];if(("_owner"!==n||!e.$$typeof)&&!eO(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function eS(e){return"undefined"==typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function eP(e,t){let n=eS(e);return Math.round(t*n)/n}function eA(e){let t=r.useRef(e);return eR(()=>{t.current=e}),t}let ej=e=>({name:"arrow",options:e,fn(t){let{element:n,padding:r}="function"==typeof e?e(t):e;return n&&({}).hasOwnProperty.call(n,"current")?null!=n.current?ex({element:n.current,padding:r}).fn(t):{}:n?ex({element:n,padding:r}).fn(t):{}}}),eT=(e,t)=>({...function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;let{x:o,y:i,placement:l,middlewareData:a}=t,u=await k(t,e);return l===(null==(n=a.offset)?void 0:n.placement)&&null!=(r=a.arrow)&&r.alignmentOffset?{}:{x:o+u.x,y:i+u.y,data:{...u,placement:l}}}}}(e),options:[e,t]}),e_=(e,t)=>({...function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){let{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:u=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...c}=f(e,t),d={x:n,y:r},m=await j(t,c),g=y(p(o)),v=h(g),b=d[v],w=d[g];if(a){let e="y"===v?"top":"left",t="y"===v?"bottom":"right",n=b+m[e],r=b-m[t];b=l(n,i(b,r))}if(u){let e="y"===g?"top":"left",t="y"===g?"bottom":"right",n=w+m[e],r=w-m[t];w=l(n,i(w,r))}let x=s.fn({...t,[v]:b,[g]:w});return{...x,data:{x:x.x-n,y:x.y-r,enabled:{[v]:a,[g]:u}}}}}}(e),options:[e,t]}),eN=(e,t)=>({...function(e){return void 0===e&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:o,rects:i,middlewareData:l}=t,{offset:a=0,mainAxis:u=!0,crossAxis:s=!0}=f(e,t),c={x:n,y:r},d=y(o),m=h(d),g=c[m],v=c[d],b=f(a,t),w="number"==typeof b?{mainAxis:b,crossAxis:0}:{mainAxis:0,crossAxis:0,...b};if(u){let e="y"===m?"height":"width",t=i.reference[m]-i.floating[e]+w.mainAxis,n=i.reference[m]+i.reference[e]-w.mainAxis;gn&&(g=n)}if(s){var x,E;let e="y"===m?"width":"height",t=N.has(p(o)),n=i.reference[d]-i.floating[e]+(t&&(null==(x=l.offset)?void 0:x[d])||0)+(t?0:w.crossAxis),r=i.reference[d]+i.reference[e]+(t?0:(null==(E=l.offset)?void 0:E[d])||0)-(t?w.crossAxis:0);vr&&(v=r)}return{[m]:g,[d]:v}}}}(e),options:[e,t]}),ek=(e,t)=>({...function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r,o,i,l;let{placement:a,middlewareData:u,rects:s,initialPlacement:c,platform:d,elements:v}=t,{mainAxis:O=!0,crossAxis:S=!0,fallbackPlacements:P,fallbackStrategy:A="bestFit",fallbackAxisSideDirection:T="none",flipAlignment:_=!0,...N}=f(e,t);if(null!=(n=u.arrow)&&n.alignmentOffset)return{};let k=p(a),L=y(c),M=p(c)===c,D=await (null==d.isRTL?void 0:d.isRTL(v.floating)),I=P||(M||!_?[R(c)]:function(e){let t=R(e);return[b(e),t,b(t)]}(c)),F="none"!==T;!P&&F&&I.push(...function(e,t,n,r){let o=m(e),i=function(e,t,n){switch(e){case"top":case"bottom":if(n)return t?x:w;return t?w:x;case"left":case"right":return t?E:C;default:return[]}}(p(e),"start"===n,r);return o&&(i=i.map(e=>e+"-"+o),t&&(i=i.concat(i.map(b)))),i}(c,_,T,D));let z=[c,...I],W=await j(t,N),B=[],U=(null==(r=u.flip)?void 0:r.overflows)||[];if(O&&B.push(W[k]),S){let e=function(e,t,n){void 0===n&&(n=!1);let r=m(e),o=h(y(e)),i=g(o),l="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[i]>t.floating[i]&&(l=R(l)),[l,R(l)]}(a,s,D);B.push(W[e[0]],W[e[1]])}if(U=[...U,{placement:a,overflows:B}],!B.every(e=>e<=0)){let e=((null==(o=u.flip)?void 0:o.index)||0)+1,t=z[e];if(t&&("alignment"!==S||L===y(t)||U.every(e=>y(e.placement)!==L||e.overflows[0]>0)))return{data:{index:e,overflows:U},reset:{placement:t}};let n=null==(i=U.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:i.placement;if(!n)switch(A){case"bestFit":{let e=null==(l=U.filter(e=>{if(F){let t=y(e.placement);return t===L||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:l[0];e&&(n=e);break}case"initialPlacement":n=c}if(a!==n)return{reset:{placement:n}}}return{}}}}(e),options:[e,t]}),eL=(e,t)=>({...function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;let o,a,{placement:u,rects:s,platform:c,elements:d}=t,{apply:h=()=>{},...g}=f(e,t),v=await j(t,g),b=p(u),w=m(u),x="y"===y(u),{width:E,height:C}=s.floating;"top"===b||"bottom"===b?(o=b,a=w===(await (null==c.isRTL?void 0:c.isRTL(d.floating))?"start":"end")?"left":"right"):(a=b,o="end"===w?"top":"bottom");let R=C-v.top-v.bottom,O=E-v.left-v.right,S=i(C-v[o],R),P=i(E-v[a],O),A=!t.middlewareData.shift,T=S,_=P;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(_=O),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(T=R),A&&!w){let e=l(v.left,0),t=l(v.right,0),n=l(v.top,0),r=l(v.bottom,0);x?_=E-2*(0!==e||0!==t?e+t:l(v.left,v.right)):T=C-2*(0!==n||0!==r?n+r:l(v.top,v.bottom))}await h({...t,availableWidth:_,availableHeight:T});let N=await c.getDimensions(d.floating);return E!==N.width||C!==N.height?{reset:{rects:!0}}:{}}}}(e),options:[e,t]}),eM=(e,t)=>({...function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){let{rects:n}=t,{strategy:r="referenceHidden",...o}=f(e,t);switch(r){case"referenceHidden":{let e=T(await j(t,{...o,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:_(e)}}}case"escaped":{let e=T(await j(t,{...o,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:_(e)}}}default:return{}}}}}(e),options:[e,t]}),eD=(e,t)=>({...ej(e),options:[e,t]});var eI=n(3780),eF=n(3422),ez=r.forwardRef((e,t)=>{let{children:n,width:r=10,height:o=5,...i}=e;return(0,eF.jsx)(eI.sG.svg,{...i,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:(0,eF.jsx)("polygon",{points:"0,0 30,0 15,10"})})});ez.displayName="Arrow";var eW=n(2050),eB=n(940),eU=n(7589),eH=n(3177),eK=n(4753),eq="Popper",[eG,eV]=(0,eB.A)(eq),[eX,e$]=eG(eq),eY=e=>{let{__scopePopper:t,children:n}=e,[o,i]=r.useState(null);return(0,eF.jsx)(eX,{scope:t,anchor:o,onAnchorChange:i,children:n})};eY.displayName=eq;var eZ="PopperAnchor",eJ=r.forwardRef((e,t)=>{let{__scopePopper:n,virtualRef:o,...i}=e,l=e$(eZ,n),a=r.useRef(null),u=(0,eW.s)(t,a),s=r.useRef(null);return r.useEffect(()=>{let e=s.current;s.current=(null==o?void 0:o.current)||a.current,e!==s.current&&l.onAnchorChange(s.current)}),o?null:(0,eF.jsx)(eI.sG.div,{...i,ref:u})});eJ.displayName=eZ;var eQ="PopperContent",[e0,e1]=eG(eQ),e2=r.forwardRef((e,t)=>{var n,o,a,s,c,d,f,p;let{__scopePopper:m,side:h="bottom",sideOffset:g=0,align:v="center",alignOffset:y=0,arrowPadding:b=0,avoidCollisions:w=!0,collisionBoundary:x=[],collisionPadding:E=0,sticky:C="partial",hideWhenDetached:R=!1,updatePositionStrategy:O="optimized",onPlaced:S,...P}=e,A=e$(eQ,m),[j,T]=r.useState(null),_=(0,eW.s)(t,e=>T(e)),[N,k]=r.useState(null),L=(0,eK.X)(N),M=null!=(f=null==L?void 0:L.width)?f:0,D=null!=(p=null==L?void 0:L.height)?p:0,F="number"==typeof E?E:{top:0,right:0,bottom:0,left:0,...E},z=Array.isArray(x)?x:[x],W=z.length>0,B={padding:F,boundary:z.filter(e5),altBoundary:W},{refs:U,floatingStyles:H,placement:K,isPositioned:q,middlewareData:G}=function(e){void 0===e&&(e={});let{placement:t="bottom",strategy:n="absolute",middleware:o=[],platform:i,elements:{reference:l,floating:a}={},transform:u=!0,whileElementsMounted:s,open:c}=e,[d,f]=r.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,m]=r.useState(o);eO(p,o)||m(o);let[h,g]=r.useState(null),[v,y]=r.useState(null),b=r.useCallback(e=>{e!==C.current&&(C.current=e,g(e))},[]),w=r.useCallback(e=>{e!==R.current&&(R.current=e,y(e))},[]),x=l||h,E=a||v,C=r.useRef(null),R=r.useRef(null),O=r.useRef(d),S=null!=s,P=eA(s),A=eA(i),j=eA(c),T=r.useCallback(()=>{if(!C.current||!R.current)return;let e={placement:t,strategy:n,middleware:p};A.current&&(e.platform=A.current),eE(C.current,R.current,e).then(e=>{let t={...e,isPositioned:!1!==j.current};_.current&&!eO(O.current,t)&&(O.current=t,eC.flushSync(()=>{f(t)}))})},[p,t,n,A,j]);eR(()=>{!1===c&&O.current.isPositioned&&(O.current.isPositioned=!1,f(e=>({...e,isPositioned:!1})))},[c]);let _=r.useRef(!1);eR(()=>(_.current=!0,()=>{_.current=!1}),[]),eR(()=>{if(x&&(C.current=x),E&&(R.current=E),x&&E){if(P.current)return P.current(x,E,T);T()}},[x,E,T,P,S]);let N=r.useMemo(()=>({reference:C,floating:R,setReference:b,setFloating:w}),[b,w]),k=r.useMemo(()=>({reference:x,floating:E}),[x,E]),L=r.useMemo(()=>{let e={position:n,left:0,top:0};if(!k.floating)return e;let t=eP(k.floating,d.x),r=eP(k.floating,d.y);return u?{...e,transform:"translate("+t+"px, "+r+"px)",...eS(k.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}},[n,u,k.floating,d.x,d.y]);return r.useMemo(()=>({...d,update:T,refs:N,elements:k,floatingStyles:L}),[d,T,N,k,L])}({strategy:"fixed",placement:h+("center"!==v?"-"+v:""),whileElementsMounted:function(){for(var e=arguments.length,t=Array(e),n=0;n{a&&e.addEventListener("scroll",n,{passive:!0}),s&&e.addEventListener("resize",n)});let h=p&&d?function(e,t){let n,r=null,o=I(e);function a(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return!function s(c,d){void 0===c&&(c=!1),void 0===d&&(d=1),a();let f=e.getBoundingClientRect(),{left:p,top:m,width:h,height:g}=f;if(c||t(),!h||!g)return;let v=u(m),y=u(o.clientWidth-(p+h)),b={rootMargin:-v+"px "+-y+"px "+-u(o.clientHeight-(m+g))+"px "+-u(p)+"px",threshold:l(0,i(1,d))||1},w=!0;function x(t){let r=t[0].intersectionRatio;if(r!==d){if(!w)return s();r?s(!1,r):n=setTimeout(()=>{s(!1,1e-7)},1e3)}1!==r||ew(f,e.getBoundingClientRect())||s(),w=!1}try{r=new IntersectionObserver(x,{...b,root:o.ownerDocument})}catch(e){r=new IntersectionObserver(x,b)}r.observe(e)}(!0),a}(p,n):null,g=-1,v=null;c&&(v=new ResizeObserver(e=>{let[r]=e;r&&r.target===p&&v&&(v.unobserve(t),cancelAnimationFrame(g),g=requestAnimationFrame(()=>{var e;null==(e=v)||e.observe(t)})),n()}),p&&!f&&v.observe(p),v.observe(t));let y=f?ec(e):null;return f&&function t(){let r=ec(e);y&&!ew(y,r)&&n(),y=r,o=requestAnimationFrame(t)}(),n(),()=>{var e;m.forEach(e=>{a&&e.removeEventListener("scroll",n),s&&e.removeEventListener("resize",n)}),null==h||h(),null==(e=v)||e.disconnect(),v=null,f&&cancelAnimationFrame(o)}}(...t,{animationFrame:"always"===O})},elements:{reference:A.anchor},middleware:[eT({mainAxis:g+D,alignmentAxis:y}),w&&e_({mainAxis:!0,crossAxis:!1,limiter:"partial"===C?eN():void 0,...B}),w&&ek({...B}),eL({...B,apply:e=>{let{elements:t,rects:n,availableWidth:r,availableHeight:o}=e,{width:i,height:l}=n.reference,a=t.floating.style;a.setProperty("--radix-popper-available-width","".concat(r,"px")),a.setProperty("--radix-popper-available-height","".concat(o,"px")),a.setProperty("--radix-popper-anchor-width","".concat(i,"px")),a.setProperty("--radix-popper-anchor-height","".concat(l,"px"))}}),N&&eD({element:N,padding:b}),e4({arrowWidth:M,arrowHeight:D}),R&&eM({strategy:"referenceHidden",...B})]}),[V,X]=e9(K),$=(0,eU.c)(S);(0,eH.N)(()=>{q&&(null==$||$())},[q,$]);let Y=null==(n=G.arrow)?void 0:n.x,Z=null==(o=G.arrow)?void 0:o.y,J=(null==(a=G.arrow)?void 0:a.centerOffset)!==0,[Q,ee]=r.useState();return(0,eH.N)(()=>{j&&ee(window.getComputedStyle(j).zIndex)},[j]),(0,eF.jsx)("div",{ref:U.setFloating,"data-radix-popper-content-wrapper":"",style:{...H,transform:q?H.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Q,"--radix-popper-transform-origin":[null==(s=G.transformOrigin)?void 0:s.x,null==(c=G.transformOrigin)?void 0:c.y].join(" "),...(null==(d=G.hide)?void 0:d.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:(0,eF.jsx)(e0,{scope:m,placedSide:V,onArrowChange:k,arrowX:Y,arrowY:Z,shouldHideArrow:J,children:(0,eF.jsx)(eI.sG.div,{"data-side":V,"data-align":X,...P,ref:_,style:{...P.style,animation:q?void 0:"none"}})})})});e2.displayName=eQ;var e3="PopperArrow",e7={top:"bottom",right:"left",bottom:"top",left:"right"},e8=r.forwardRef(function(e,t){let{__scopePopper:n,...r}=e,o=e1(e3,n),i=e7[o.placedSide];return(0,eF.jsx)("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0},children:(0,eF.jsx)(ez,{...r,ref:t,style:{...r.style,display:"block"}})})});function e5(e){return null!==e}e8.displayName=e3;var e4=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,l;let{placement:a,rects:u,middlewareData:s}=t,c=(null==(n=s.arrow)?void 0:n.centerOffset)!==0,d=c?0:e.arrowWidth,f=c?0:e.arrowHeight,[p,m]=e9(a),h={start:"0%",center:"50%",end:"100%"}[m],g=(null!=(i=null==(r=s.arrow)?void 0:r.x)?i:0)+d/2,v=(null!=(l=null==(o=s.arrow)?void 0:o.y)?l:0)+f/2,y="",b="";return"bottom"===p?(y=c?h:"".concat(g,"px"),b="".concat(-f,"px")):"top"===p?(y=c?h:"".concat(g,"px"),b="".concat(u.floating.height+f,"px")):"right"===p?(y="".concat(-f,"px"),b=c?h:"".concat(v,"px")):"left"===p&&(y="".concat(u.floating.width+f,"px"),b=c?h:"".concat(v,"px")),{data:{x:y,y:b}}}});function e9(e){let[t,n="center"]=e.split("-");return[t,n]}var e6=eY,te=eJ,tt=e2,tn=e8},6565:(e,t,n)=>{n.d(t,{B:()=>u});var r,o=n(4398),i=n(3177),l=(r||(r=n.t(o,2)))[" useId ".trim().toString()]||(()=>void 0),a=0;function u(e){let[t,n]=o.useState(l());return(0,i.N)(()=>{e||n(e=>e??String(a++))},[e]),e||(t?`radix-${t}`:"")}},6631:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{default:function(){return g},useLinkStatus:function(){return y}});let r=n(4900),o=n(3422),i=r._(n(4398)),l=n(4450),a=n(9260),u=n(3051),s=n(7525),c=n(3276),d=n(2886);n(5145);let f=n(6863),p=n(7179),m=n(5747);function h(e){return"string"==typeof e?e:(0,l.formatUrl)(e)}function g(e){let t,n,r,[l,g]=(0,i.useOptimistic)(f.IDLE_LINK_STATUS),y=(0,i.useRef)(null),{href:b,as:w,children:x,prefetch:E=null,passHref:C,replace:R,shallow:O,scroll:S,onClick:P,onMouseEnter:A,onTouchStart:j,legacyBehavior:T=!1,onNavigate:_,ref:N,unstable_dynamicOnHover:k,...L}=e;t=x,T&&("string"==typeof t||"number"==typeof t)&&(t=(0,o.jsx)("a",{children:t}));let M=i.default.useContext(a.AppRouterContext),D=!1!==E,I=null===E?u.PrefetchKind.AUTO:u.PrefetchKind.FULL,{href:F,as:z}=i.default.useMemo(()=>{let e=h(b);return{href:e,as:w?h(w):e}},[b,w]);T&&(n=i.default.Children.only(t));let W=T?n&&"object"==typeof n&&n.ref:N,B=i.default.useCallback(e=>(null!==M&&(y.current=(0,f.mountLinkInstance)(e,F,M,I,D,g)),()=>{y.current&&((0,f.unmountLinkForCurrentNavigation)(y.current),y.current=null),(0,f.unmountPrefetchableInstance)(e)}),[D,F,M,I,g]),U={ref:(0,s.useMergedRef)(B,W),onClick(e){T||"function"!=typeof P||P(e),T&&n.props&&"function"==typeof n.props.onClick&&n.props.onClick(e),M&&(e.defaultPrevented||function(e,t,n,r,o,l,a){let{nodeName:u}=e.currentTarget;if(!("A"===u.toUpperCase()&&function(e){let t=e.currentTarget.getAttribute("target");return t&&"_self"!==t||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey||e.nativeEvent&&2===e.nativeEvent.which}(e)||e.currentTarget.hasAttribute("download"))){if(!(0,p.isLocalURL)(t)){o&&(e.preventDefault(),location.replace(t));return}e.preventDefault(),i.default.startTransition(()=>{if(a){let e=!1;if(a({preventDefault:()=>{e=!0}}),e)return}(0,m.dispatchNavigateAction)(n||t,o?"replace":"push",null==l||l,r.current)})}}(e,F,z,y,R,S,_))},onMouseEnter(e){T||"function"!=typeof A||A(e),T&&n.props&&"function"==typeof n.props.onMouseEnter&&n.props.onMouseEnter(e),M&&D&&(0,f.onNavigationIntent)(e.currentTarget,!0===k)},onTouchStart:function(e){T||"function"!=typeof j||j(e),T&&n.props&&"function"==typeof n.props.onTouchStart&&n.props.onTouchStart(e),M&&D&&(0,f.onNavigationIntent)(e.currentTarget,!0===k)}};return(0,c.isAbsoluteUrl)(z)?U.href=z:T&&!C&&("a"!==n.type||"href"in n.props)||(U.href=(0,d.addBasePath)(z)),r=T?i.default.cloneElement(n,U):(0,o.jsx)("a",{...L,...U,children:t}),(0,o.jsx)(v.Provider,{value:l,children:r})}n(777);let v=(0,i.createContext)(f.IDLE_LINK_STATUS),y=()=>(0,i.useContext)(v);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},6657:(e,t,n)=>{n.d(t,{i:()=>a});var r,o=n(4398),i=n(3177),l=(r||(r=n.t(o,2)))[" useInsertionEffect ".trim().toString()]||i.N;function a({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){let[i,a,u]=function({defaultProp:e,onChange:t}){let[n,r]=o.useState(e),i=o.useRef(n),a=o.useRef(t);return l(()=>{a.current=t},[t]),o.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}({defaultProp:t,onChange:n}),s=void 0!==e,c=s?e:i;{let t=o.useRef(void 0!==e);o.useEffect(()=>{let e=t.current;if(e!==s){let t=s?"controlled":"uncontrolled";console.warn(`${r} is changing from ${e?"controlled":"uncontrolled"} to ${t}. 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.`)}t.current=s},[s,r])}return[c,o.useCallback(t=>{if(s){let n="function"==typeof t?t(e):t;n!==e&&u.current?.(n)}else a(t)},[s,e,a,u])]}Symbol("RADIX:SYNC_STATE")},6687:(e,t,n)=>{n.d(t,{mK:()=>o});var r=!!("undefined"!=typeof window&&window.document&&window.document.createElement);function o(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r.defaultPrevented)return t?.(r)}}},6701:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]])},7179:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"isLocalURL",{enumerable:!0,get:function(){return i}});let r=n(3276),o=n(4970);function i(e){if(!(0,r.isAbsoluteUrl)(e))return!0;try{let t=(0,r.getLocationOrigin)(),n=new URL(e,t);return n.origin===t&&(0,o.hasBasePath)(n.pathname)}catch(e){return!1}}},7352:(e,t)=>{function n(e){var t;let{config:n,src:r,width:o,quality:i}=e,l=i||(null==(t=n.qualities)?void 0:t.reduce((e,t)=>Math.abs(t-75){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"useMergedRef",{enumerable:!0,get:function(){return o}});let r=n(4398);function o(e,t){let n=(0,r.useRef)(null),o=(0,r.useRef)(null);return(0,r.useCallback)(r=>{if(null===r){let e=n.current;e&&(n.current=null,e());let t=o.current;t&&(o.current=null,t())}else e&&(n.current=i(e,r)),t&&(o.current=i(t,r))},[e,t])}function i(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let n=e(t);return"function"==typeof n?n:()=>e(null)}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},7589:(e,t,n)=>{n.d(t,{c:()=>o});var r=n(4398);function o(e){let t=r.useRef(e);return r.useEffect(()=>{t.current=e}),r.useMemo(()=>(...e)=>t.current?.(...e),[])}},8019:(e,t,n)=>{n.d(t,{default:()=>o.a});var r=n(4059),o=n.n(r)},8585:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{VALID_LOADERS:function(){return n},imageConfigDefault:function(){return r}});let n=["default","imgix","cloudinary","akamai","custom"],r={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",loaderFile:"",domains:[],disableStaticImages:!1,minimumCacheTTL:60,formats:["image/webp"],dangerouslyAllowSVG:!1,contentSecurityPolicy:"script-src 'none'; frame-src 'none'; sandbox;",contentDispositionType:"attachment",localPatterns:void 0,remotePatterns:[],qualities:void 0,unoptimized:!1}},9285:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]])},9675:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("circle-alert",[["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"}]])},9680:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},9749:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"AmpStateContext",{enumerable:!0,get:function(){return r}});let r=n(5348)._(n(4398)).default.createContext({})},9779:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(3929).A)("log-out",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]])}}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/826-c15935d1c2416e5d.js b/ui_out/_next/static/chunks/826-03658aa28a2a895d.js similarity index 100% rename from ui_out/_next/static/chunks/826-c15935d1c2416e5d.js rename to ui_out/_next/static/chunks/826-03658aa28a2a895d.js diff --git a/ui_out/_next/static/chunks/900-4ce6a1afa7029035.js b/ui_out/_next/static/chunks/900-4ce6a1afa7029035.js new file mode 100644 index 00000000..4aaff6a6 --- /dev/null +++ b/ui_out/_next/static/chunks/900-4ce6a1afa7029035.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[900],{268:(e,t,a)=>{a.d(t,{p:()=>i});var r=a(3422);a(4398);var n=a(9183);function i(e){let{className:t,type:a,...i}=e;return(0,r.jsx)("input",{type:a,"data-slot":"input",className:(0,n.cn)("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input flex 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",t),...i})}},532:(e,t,a)=>{a.d(t,{SiteHeader:()=>f});var r=a(3422),n=a(5349),i=a(953),s=a(3648),o=a(9779),l=a(1064),d=a(3270),c=a(3831);a(4398);var u=a(5746),h=a(4357),g=a(1262);function p(){let{setTheme:e,theme:t}=(0,g.D)();return(0,r.jsxs)(s.$,{variant:"ghost",size:"sm",onClick:()=>e("light"===t?"dark":"light"),className:"gap-2",children:[(0,r.jsx)(u.A,{className:"h-4 w-4 scale-100 rotate-0 transition-all dark:scale-0 dark:-rotate-90"}),(0,r.jsx)(h.A,{className:"h-4 w-4 scale-0 rotate-90 transition-all dark:scale-100 dark:rotate-0"}),(0,r.jsx)("span",{className:"sr-only",children:"Toggle theme"})]})}function f(){let e=(0,l.useRouter)(),t=async()=>{try{await (0,d.wu)(),c.oR.success("Logged out successfully"),e.push("/login")}catch(e){console.error("Logout error:",e),c.oR.error("Failed to logout")}};return(0,r.jsx)("header",{className:"flex h-12 shrink-0 items-center gap-2 border-b transition-[width,height] ease-linear group-has-data-[collapsible=icon]/sidebar-wrapper:h-12",children:(0,r.jsxs)("div",{className:"flex w-full items-center justify-between gap-1 px-4 lg:gap-2 lg:px-6",children:[(0,r.jsxs)("div",{className:"flex items-center gap-1 lg:gap-2",children:[(0,r.jsx)(i.x2,{className:"-ml-1"}),(0,r.jsx)(n.w,{orientation:"vertical",className:"mx-2 data-[orientation=vertical]:h-4"}),(0,r.jsx)("h1",{className:"text-base font-medium",children:"Routstr"})]}),(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)(p,{}),(0,r.jsxs)(s.$,{variant:"ghost",size:"sm",onClick:t,className:"gap-2",children:[(0,r.jsx)(o.A,{className:"h-4 w-4"}),(0,r.jsx)("span",{className:"hidden sm:inline",children:"Logout"})]})]})]})})}},953:(e,t,a)=>{a.d(t,{Bx:()=>k,Yv:()=>C,Cn:()=>A,rQ:()=>z,Gh:()=>S,SidebarInset:()=>_,wZ:()=>I,Uj:()=>U,FX:()=>B,SidebarProvider:()=>j,x2:()=>N});var r=a(3422),n=a(4398),i=a(6950),s=a(4676),o=a(3712),l=a(9183),d=a(3648);a(268),a(5349);var c=a(4316),u=a(9680);function h(e){let{...t}=e;return(0,r.jsx)(c.bL,{"data-slot":"sheet",...t})}function g(e){let{...t}=e;return(0,r.jsx)(c.ZL,{"data-slot":"sheet-portal",...t})}function p(e){let{className:t,...a}=e;return(0,r.jsx)(c.hJ,{"data-slot":"sheet-overlay",className:(0,l.cn)("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",t),...a})}function f(e){let{className:t,children:a,side:n="right",...i}=e;return(0,r.jsxs)(g,{children:[(0,r.jsx)(p,{}),(0,r.jsxs)(c.UC,{"data-slot":"sheet-content",className:(0,l.cn)("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","right"===n&&"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","left"===n&&"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","top"===n&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b","bottom"===n&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",t),...i,children:[a,(0,r.jsxs)(c.bm,{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:[(0,r.jsx)(u.A,{className:"size-4"}),(0,r.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function m(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sheet-header",className:(0,l.cn)("flex flex-col gap-1.5 p-4",t),...a})}function b(e){let{className:t,...a}=e;return(0,r.jsx)(c.hE,{"data-slot":"sheet-title",className:(0,l.cn)("text-foreground font-semibold",t),...a})}function x(e){let{className:t,...a}=e;return(0,r.jsx)(c.VY,{"data-slot":"sheet-description",className:(0,l.cn)("text-muted-foreground text-sm",t),...a})}a(2745);var v=a(6545);let w=n.createContext(null);function y(){let e=n.useContext(w);if(!e)throw Error("useSidebar must be used within a SidebarProvider.");return e}function j(e){let{defaultOpen:t=!0,open:a,onOpenChange:i,className:s,style:o,children:d,...c}=e,u=function(){let[e,t]=n.useState(void 0);return n.useEffect(()=>{let e=window.matchMedia("(max-width: ".concat(767,"px)")),a=()=>{t(window.innerWidth<768)};return e.addEventListener("change",a),t(window.innerWidth<768),()=>e.removeEventListener("change",a)},[]),!!e}(),[h,g]=n.useState(!1),[p,f]=n.useState(t),m=null!=a?a:p,b=n.useCallback(e=>{let t="function"==typeof e?e(m):e;i?i(t):f(t),document.cookie="".concat("sidebar_state","=").concat(t,"; path=/; max-age=").concat(604800)},[i,m]),x=n.useCallback(()=>u?g(e=>!e):b(e=>!e),[u,b,g]);n.useEffect(()=>{let e=e=>{"b"===e.key&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),x())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[x]);let y=m?"expanded":"collapsed",j=n.useMemo(()=>({state:y,open:m,setOpen:b,isMobile:u,openMobile:h,setOpenMobile:g,toggleSidebar:x}),[y,m,b,u,h,g,x]);return(0,r.jsx)(w.Provider,{value:j,children:(0,r.jsx)(v.Bc,{delayDuration:0,children:(0,r.jsx)("div",{"data-slot":"sidebar-wrapper",style:{"--sidebar-width":"16rem","--sidebar-width-icon":"3rem",...o},className:(0,l.cn)("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full",s),...c,children:d})})})}function k(e){let{side:t="left",variant:a="sidebar",collapsible:n="offcanvas",className:i,children:s,...o}=e,{isMobile:d,state:c,openMobile:u,setOpenMobile:g}=y();return"none"===n?(0,r.jsx)("div",{"data-slot":"sidebar",className:(0,l.cn)("bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col",i),...o,children:s}):d?(0,r.jsx)(h,{open:u,onOpenChange:g,...o,children:(0,r.jsxs)(f,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"bg-sidebar text-sidebar-foreground fixed z-50 w-(--sidebar-width) p-0 [&>button]:hidden",style:{"--sidebar-width":"18rem"},side:t,children:[(0,r.jsxs)(m,{className:"sr-only",children:[(0,r.jsx)(b,{children:"Sidebar"}),(0,r.jsx)(x,{children:"Displays the mobile sidebar."})]}),(0,r.jsx)("div",{className:"flex h-full w-full flex-col overflow-y-auto",children:s})]})}):(0,r.jsxs)("div",{className:"group peer text-sidebar-foreground hidden md:block","data-state":c,"data-collapsible":"collapsed"===c?n:"","data-variant":a,"data-side":t,"data-slot":"sidebar",children:[(0,r.jsx)("div",{"data-slot":"sidebar-gap",className:(0,l.cn)("relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180","floating"===a||"inset"===a?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon)")}),(0,r.jsx)("div",{"data-slot":"sidebar-container",className:(0,l.cn)("fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex","left"===t?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]","floating"===a||"inset"===a?"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",i),...o,children:(0,r.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:s})})]})}function N(e){let{className:t,onClick:a,...n}=e,{toggleSidebar:i}=y();return(0,r.jsxs)(d.$,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:(0,l.cn)("size-7",t),onClick:e=>{null==a||a(e),i()},...n,children:[(0,r.jsx)(o.A,{}),(0,r.jsx)("span",{className:"sr-only",children:"Toggle Sidebar"})]})}function _(e){let{className:t,...a}=e;return(0,r.jsx)("main",{"data-slot":"sidebar-inset",className:(0,l.cn)("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","overflow-x-hidden",t),...a})}function S(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:(0,l.cn)("flex flex-col gap-2 p-2",t),...a})}function C(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:(0,l.cn)("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",t),...a})}function A(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:(0,l.cn)("relative flex w-full min-w-0 flex-col p-2",t),...a})}function z(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:(0,l.cn)("w-full text-sm",t),...a})}function I(e){let{className:t,...a}=e;return(0,r.jsx)("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:(0,l.cn)("flex w-full min-w-0 flex-col gap-1",t),...a})}function B(e){let{className:t,...a}=e;return(0,r.jsx)("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:(0,l.cn)("group/menu-item relative",t),...a})}let E=(0,s.F)("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 U(e){let{asChild:t=!1,isActive:a=!1,variant:n="default",size:s="default",tooltip:o,className:d,...c}=e,u=t?i.DX:"button",{isMobile:h,state:g}=y(),p=(0,r.jsx)(u,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":s,"data-active":a,className:(0,l.cn)(E({variant:n,size:s}),d),...c});return o?("string"==typeof o&&(o={children:o}),(0,r.jsxs)(v.m_,{children:[(0,r.jsx)(v.k$,{asChild:!0,children:p}),(0,r.jsx)(v.ZI,{side:"right",align:"center",hidden:"collapsed"!==g||h,...o})]})):p}},2745:(e,t,a)=>{a.d(t,{E:()=>i});var r=a(3422),n=a(9183);function i(e){let{className:t,...a}=e;return(0,r.jsx)("div",{"data-slot":"skeleton",className:(0,n.cn)("bg-accent animate-pulse rounded-md",t),...a})}},3234:(e,t,a)=>{a.d(t,{s:()=>i});var r=a(9945),n=a(5842);r.Ik({endpoint:r.Yj().url().or(r.eu("")),apiKey:r.Yj(),enabled:r.zM()});class i{static getServerConfig(){return{endpoint:localStorage.getItem("server_endpoint")||"",apiKey:localStorage.getItem("server_api_key")||"",enabled:"true"===localStorage.getItem("server_enabled")}}static saveServerConfig(e){localStorage.setItem("server_endpoint",e.endpoint),localStorage.setItem("server_api_key",e.apiKey),localStorage.setItem("server_enabled",e.enabled.toString())}static isServerConfigValid(){let e=this.getServerConfig();return e.enabled&&!!e.endpoint&&!!e.apiKey}static getLocalBaseUrl(){return"http://127.0.0.1:8000"}static getBaseUrl(){let e=this.getServerConfig();return e.enabled&&e.endpoint?e.endpoint:this.getLocalBaseUrl()}static getAuthHeaders(){let e={"Content-Type":"application/json"};try{{let t=localStorage.getItem("admin_token"),a=localStorage.getItem("admin_token_expiry");if(t&&a){let r=parseInt(a,10);if(Date.now(){a.d(t,{bN:()=>s,wu:()=>o});var r=a(9945);a(7916);var n=a(3234),i=a(5842);async function s(e){try{let t=n.s.getLocalBaseUrl(),a=await i.A.post("".concat(t,"/admin/api/login"),{password:e},{headers:{"Content-Type":"application/json"}});return a.data.token&&a.data.expires_in&&n.s.setToken(a.data.token,a.data.expires_in),a.data}catch(e){throw console.error("Admin login error:",e),e}}async function o(){try{let e=localStorage.getItem("admin_token");if(e){let t=n.s.getLocalBaseUrl();await i.A.post("".concat(t,"/admin/api/logout"),{},{headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)}})}}catch(e){console.error("Admin logout error:",e)}finally{n.s.clearToken()}}r.Ik({username:r.Yj().optional(),password:r.Yj().optional()}),r.Ik({id:r.Yj()}),r.Ik({password:r.Yj().min(1,"Password is required")}),r.Ik({ok:r.zM(),token:r.Yj(),expires_in:r.ai()}),r.Ik({npub:r.Yj().min(10,{message:"must have at least 10 character"}),name:r.Yj().optional()}),r.Ik({user_id:r.Yj(),theme:r.Yj()})},3648:(e,t,a)=>{a.d(t,{$:()=>l,r:()=>o});var r=a(3422);a(4398);var n=a(6950),i=a(4676),s=a(9183);let o=(0,i.F)("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 shadow-xs hover:bg-primary/90",destructive:"bg-destructive text-white shadow-xs 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 shadow-xs 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"}},defaultVariants:{variant:"default",size:"default"}});function l(e){let{className:t,variant:a,size:i,asChild:l=!1,...d}=e,c=l?n.DX:"button";return(0,r.jsx)(c,{"data-slot":"button",className:(0,s.cn)(o({variant:a,size:i,className:t})),...d})}},5349:(e,t,a)=>{a.d(t,{w:()=>s});var r=a(3422);a(4398);var n=a(3292),i=a(9183);function s(e){let{className:t,orientation:a="horizontal",decorative:s=!0,...o}=e;return(0,r.jsx)(n.b,{"data-slot":"separator-root",decorative:s,orientation:a,className:(0,i.cn)("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",t),...o})}},6545:(e,t,a)=>{a.d(t,{Bc:()=>s,ZI:()=>d,k$:()=>l,m_:()=>o});var r=a(3422);a(4398);var n=a(4032),i=a(9183);function s(e){let{delayDuration:t=0,...a}=e;return(0,r.jsx)(n.Kq,{"data-slot":"tooltip-provider",delayDuration:t,...a})}function o(e){let{...t}=e;return(0,r.jsx)(s,{children:(0,r.jsx)(n.bL,{"data-slot":"tooltip",...t})})}function l(e){let{...t}=e;return(0,r.jsx)(n.l9,{"data-slot":"tooltip-trigger",...t})}function d(e){let{className:t,sideOffset:a=0,children:s,...o}=e;return(0,r.jsx)(n.ZL,{children:(0,r.jsxs)(n.UC,{"data-slot":"tooltip-content",sideOffset:a,className:(0,i.cn)("bg-primary text-primary-foreground 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",t),...o,children:[s,(0,r.jsx)(n.i3,{className:"bg-primary fill-primary z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px]"})]})})}},7569:(e,t,a)=>{a.d(t,{AppSidebar:()=>p});var r=a(3422);a(4398);var n=a(2727),i=a(9285),s=a(2335),o=a(6701),l=a(8019),d=a(6631),c=a.n(d),u=a(953);function h(e){let{items:t,...a}=e;return(0,r.jsx)(u.Cn,{...a,children:(0,r.jsx)(u.rQ,{children:(0,r.jsx)(u.wZ,{children:t.map(e=>(0,r.jsx)(u.FX,{children:(0,r.jsx)(u.Uj,{asChild:!0,tooltip:e.title,children:(0,r.jsxs)(c(),{href:e.url,children:[(0,r.jsx)(e.icon,{}),(0,r.jsx)("span",{children:e.title})]})})},e.title))})})})}let g={navMain:[{title:"Dashboard",url:"/",icon:n.A}],navClouds:[],navSecondary:[{title:"Dashboard",url:"/",icon:n.A},{title:"Models",url:"/model",icon:i.A},{title:"Providers",url:"/providers",icon:s.A},{title:"Settings",url:"/settings",icon:o.A}],documents:[]};function p(e){let{...t}=e;return(0,r.jsxs)(u.Bx,{collapsible:"offcanvas",...t,children:[(0,r.jsx)(u.Gh,{children:(0,r.jsx)(u.wZ,{children:(0,r.jsx)(u.FX,{children:(0,r.jsx)(u.Uj,{asChild:!0,className:"data-[slot=sidebar-menu-button]:!p-1.5",children:(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)(l.default,{src:"/icon.ico",alt:"Routstr",width:24,height:24,className:"rounded"}),(0,r.jsx)("span",{className:"text-base font-semibold",children:"Routstr"})]})})})})}),(0,r.jsx)(u.Yv,{className:"flex-1 overflow-y-auto",children:(0,r.jsx)(h,{items:g.navSecondary,className:"mt-auto"})})]})}},7916:(e,t,a)=>{a.d(t,{apiClient:()=>s});var r=a(5842),n=a(3234);class i{getBaseUrl(){return n.s.getLocalBaseUrl()}getHeaders(){return n.s.getAuthHeaders()}handleAuthError(e){if(r.A.isAxiosError(e)){var t,a;((null==(t=e.response)?void 0:t.status)===401||(null==(a=e.response)?void 0:a.status)===403)&&(n.s.clearToken(),window.location.href="/login")}}async get(e,t){let a={headers:this.getHeaders(),params:t,withCredentials:!1};try{return console.log("Making GET request to ".concat(this.getBaseUrl()).concat(e)),(await r.A.get("".concat(this.getBaseUrl()).concat(e),a)).data}catch(e){throw this.handleAuthError(e),e}}async post(e,t){let a={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making POST request to ".concat(this.getBaseUrl()).concat(e),t),(await r.A.post("".concat(this.getBaseUrl()).concat(e),t,a)).data}catch(t){throw this.handleAuthError(t),console.error("Error posting to ".concat(e,":"),t),t}}async put(e,t){let a={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making PUT request to ".concat(this.getBaseUrl()).concat(e),t),(await r.A.put("".concat(this.getBaseUrl()).concat(e),t,a)).data}catch(t){throw this.handleAuthError(t),console.error("Error updating ".concat(e,":"),t),t}}async patch(e,t){let a={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making PATCH request to ".concat(this.getBaseUrl()).concat(e),t),(await r.A.patch("".concat(this.getBaseUrl()).concat(e),t,a)).data}catch(t){throw this.handleAuthError(t),console.error("Error patching ".concat(e,":"),t),t}}async delete(e){let t={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making DELETE request to ".concat(this.getBaseUrl()).concat(e)),(await r.A.delete("".concat(this.getBaseUrl()).concat(e),t)).data}catch(t){throw this.handleAuthError(t),console.error("Error deleting from ".concat(e,":"),t),t}}}let s=new i},9183:(e,t,a)=>{a.d(t,{cn:()=>i});var r=a(8082),n=a(4966);function i(){for(var e=arguments.length,t=Array(e),a=0;a{"use strict";r.d(t,{s:()=>o});var a=r(9945),n=r(5842);a.Ik({endpoint:a.Yj().url().or(a.eu("")),apiKey:a.Yj(),enabled:a.zM()});class o{static getServerConfig(){return{endpoint:localStorage.getItem("server_endpoint")||"",apiKey:localStorage.getItem("server_api_key")||"",enabled:"true"===localStorage.getItem("server_enabled")}}static saveServerConfig(e){localStorage.setItem("server_endpoint",e.endpoint),localStorage.setItem("server_api_key",e.apiKey),localStorage.setItem("server_enabled",e.enabled.toString())}static isServerConfigValid(){let e=this.getServerConfig();return e.enabled&&!!e.endpoint&&!!e.apiKey}static getLocalBaseUrl(){return"http://127.0.0.1:8000"}static getBaseUrl(){let e=this.getServerConfig();return e.enabled&&e.endpoint?e.endpoint:this.getLocalBaseUrl()}static getAuthHeaders(){let e={"Content-Type":"application/json"};try{{let t=localStorage.getItem("admin_token"),r=localStorage.getItem("admin_token_expiry");if(t&&r){let a=parseInt(r,10);if(Date.now(){Promise.resolve().then(r.bind(r,5414)),Promise.resolve().then(r.t.bind(r,8368,23)),Promise.resolve().then(r.t.bind(r,7248,23)),Promise.resolve().then(r.t.bind(r,8770,23))},5414:(e,t,r)=>{"use strict";r.d(t,{Providers:()=>w});var a=r(3422),n=r(5235),o=r(100),s=r(6126),i=r(4398),c=r(3831),l=r(7916);class u{static async listUsers(e){try{let t={};return e&&(t.organization_id=e),await l.apiClient.get("/api/users",t)}catch(e){throw console.error("Error fetching users:",e),e}}static async getUser(e){try{return await l.apiClient.get("/api/users/".concat(e))}catch(t){throw console.error("Error fetching user ".concat(e,":"),t),t}}static async createUser(e){try{return await l.apiClient.post("/api/users",e)}catch(e){throw console.error("Error creating user:",e),e}}static async updateUser(e,t){try{return await l.apiClient.put("/api/users/".concat(e),t)}catch(t){throw console.error("Error updating user ".concat(e,":"),t),t}}static async deleteUser(e){try{await l.apiClient.delete("/api/users/".concat(e))}catch(t){throw console.error("Error deleting user ".concat(e,":"),t),t}}}let d=(0,i.createContext)({user:null,isLoading:!1,error:null,isAuthenticated:!1,nostrPublicKey:null,signin:async()=>{},signout:()=>{},connectNostr:async()=>null});function h(e){let{children:t}=e,[r,n]=(0,i.useState)(null),[o,s]=(0,i.useState)(!0),[c,l]=(0,i.useState)(null),[h,g]=(0,i.useState)(null),p=async()=>{try{if(!("nostr"in window))return console.error("Nostr extension not found"),null;{let e=await window.nostr.getPublicKey();return g(e),localStorage.setItem("nostr_public_key",e),e}}catch(e){return console.error("Error connecting to Nostr:",e),null}},y=async()=>{s(!0),l(null);try{let e=await u.getUser("1");if(!e)throw Error("Admin user not found");n(e),localStorage.setItem("auth_user",JSON.stringify(e)),h||await p()}catch(e){throw l(e instanceof Error?e:Error("Sign in failed")),e}finally{s(!1)}};return(0,a.jsx)(d.Provider,{value:{user:r,isLoading:o,error:c,isAuthenticated:!0,nostrPublicKey:h,signin:y,signout:()=>{n(null),localStorage.removeItem("auth_user")},connectNostr:p},children:t})}var g=r(1064),p=r(3234);function y(e){let{children:t}=e,r=(0,g.useRouter)(),n=(0,g.usePathname)();return(0,i.useEffect)(()=>{["/login","/_register","/unauthorized"].some(e=>n.startsWith(e))||p.s.isTokenValid()||r.push("/login")},[r,n]),(0,a.jsx)(a.Fragment,{children:t})}function w(e){let{children:t}=e,[r]=(0,i.useState)(()=>new n.E({defaultOptions:{queries:{staleTime:3e5,refetchOnWindowFocus:!1,retry:2}}}));return(0,a.jsxs)(o.Ht,{client:r,children:[(0,a.jsx)(h,{children:(0,a.jsxs)(y,{children:[t,(0,a.jsx)(c.l$,{position:"top-right"})]})}),(0,a.jsx)(s.E,{initialIsOpen:!1})]})}},7916:(e,t,r)=>{"use strict";r.d(t,{apiClient:()=>s});var a=r(5842),n=r(3234);class o{getBaseUrl(){return n.s.getLocalBaseUrl()}getHeaders(){return n.s.getAuthHeaders()}handleAuthError(e){if(a.A.isAxiosError(e)){var t,r;((null==(t=e.response)?void 0:t.status)===401||(null==(r=e.response)?void 0:r.status)===403)&&(n.s.clearToken(),window.location.href="/login")}}async get(e,t){let r={headers:this.getHeaders(),params:t,withCredentials:!1};try{return console.log("Making GET request to ".concat(this.getBaseUrl()).concat(e)),(await a.A.get("".concat(this.getBaseUrl()).concat(e),r)).data}catch(e){throw this.handleAuthError(e),e}}async post(e,t){let r={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making POST request to ".concat(this.getBaseUrl()).concat(e),t),(await a.A.post("".concat(this.getBaseUrl()).concat(e),t,r)).data}catch(t){throw this.handleAuthError(t),console.error("Error posting to ".concat(e,":"),t),t}}async put(e,t){let r={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making PUT request to ".concat(this.getBaseUrl()).concat(e),t),(await a.A.put("".concat(this.getBaseUrl()).concat(e),t,r)).data}catch(t){throw this.handleAuthError(t),console.error("Error updating ".concat(e,":"),t),t}}async patch(e,t){let r={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making PATCH request to ".concat(this.getBaseUrl()).concat(e),t),(await a.A.patch("".concat(this.getBaseUrl()).concat(e),t,r)).data}catch(t){throw this.handleAuthError(t),console.error("Error patching ".concat(e,":"),t),t}}async delete(e){let t={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making DELETE request to ".concat(this.getBaseUrl()).concat(e)),(await a.A.delete("".concat(this.getBaseUrl()).concat(e),t)).data}catch(t){throw this.handleAuthError(t),console.error("Error deleting from ".concat(e,":"),t),t}}}let s=new o},8770:()=>{}},e=>{var t=t=>e(e.s=t);e.O(0,[699,273,363,29,578,945,497,358],()=>t(3372)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/layout-8cbedc9fb3669ba4.js b/ui_out/_next/static/chunks/app/layout-8cbedc9fb3669ba4.js new file mode 100644 index 00000000..94c93eb0 --- /dev/null +++ b/ui_out/_next/static/chunks/app/layout-8cbedc9fb3669ba4.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[177],{3234:(e,t,r)=>{"use strict";r.d(t,{s:()=>o});var a=r(9945),n=r(5842);a.Ik({endpoint:a.Yj().url().or(a.eu("")),apiKey:a.Yj(),enabled:a.zM()});class o{static getServerConfig(){return{endpoint:localStorage.getItem("server_endpoint")||"",apiKey:localStorage.getItem("server_api_key")||"",enabled:"true"===localStorage.getItem("server_enabled")}}static saveServerConfig(e){localStorage.setItem("server_endpoint",e.endpoint),localStorage.setItem("server_api_key",e.apiKey),localStorage.setItem("server_enabled",e.enabled.toString())}static isServerConfigValid(){let e=this.getServerConfig();return e.enabled&&!!e.endpoint&&!!e.apiKey}static getLocalBaseUrl(){return"http://127.0.0.1:8000"}static getBaseUrl(){let e=this.getServerConfig();return e.enabled&&e.endpoint?e.endpoint:this.getLocalBaseUrl()}static getAuthHeaders(){let e={"Content-Type":"application/json"};try{{let t=localStorage.getItem("admin_token"),r=localStorage.getItem("admin_token_expiry");if(t&&r){let a=parseInt(r,10);if(Date.now(){Promise.resolve().then(r.bind(r,7895)),Promise.resolve().then(r.bind(r,8748)),Promise.resolve().then(r.t.bind(r,8368,23)),Promise.resolve().then(r.t.bind(r,7248,23)),Promise.resolve().then(r.t.bind(r,8770,23))},7895:(e,t,r)=>{"use strict";r.d(t,{Providers:()=>f});var a=r(3422),n=r(5235),o=r(100),s=r(6126),i=r(4398),c=r(3831),l=r(7916);class u{static async listUsers(e){try{let t={};return e&&(t.organization_id=e),await l.apiClient.get("/api/users",t)}catch(e){throw console.error("Error fetching users:",e),e}}static async getUser(e){try{return await l.apiClient.get("/api/users/".concat(e))}catch(t){throw console.error("Error fetching user ".concat(e,":"),t),t}}static async createUser(e){try{return await l.apiClient.post("/api/users",e)}catch(e){throw console.error("Error creating user:",e),e}}static async updateUser(e,t){try{return await l.apiClient.put("/api/users/".concat(e),t)}catch(t){throw console.error("Error updating user ".concat(e,":"),t),t}}static async deleteUser(e){try{await l.apiClient.delete("/api/users/".concat(e))}catch(t){throw console.error("Error deleting user ".concat(e,":"),t),t}}}let d=(0,i.createContext)({user:null,isLoading:!1,error:null,isAuthenticated:!1,nostrPublicKey:null,signin:async()=>{},signout:()=>{},connectNostr:async()=>null});function h(e){let{children:t}=e,[r,n]=(0,i.useState)(null),[o,s]=(0,i.useState)(!0),[c,l]=(0,i.useState)(null),[h,g]=(0,i.useState)(null),p=async()=>{try{if(!("nostr"in window))return console.error("Nostr extension not found"),null;{let e=await window.nostr.getPublicKey();return g(e),localStorage.setItem("nostr_public_key",e),e}}catch(e){return console.error("Error connecting to Nostr:",e),null}},y=async()=>{s(!0),l(null);try{let e=await u.getUser("1");if(!e)throw Error("Admin user not found");n(e),localStorage.setItem("auth_user",JSON.stringify(e)),h||await p()}catch(e){throw l(e instanceof Error?e:Error("Sign in failed")),e}finally{s(!1)}};return(0,a.jsx)(d.Provider,{value:{user:r,isLoading:o,error:c,isAuthenticated:!0,nostrPublicKey:h,signin:y,signout:()=>{n(null),localStorage.removeItem("auth_user")},connectNostr:p},children:t})}var g=r(1064),p=r(3234);function y(e){let{children:t}=e,r=(0,g.useRouter)(),n=(0,g.usePathname)();return(0,i.useEffect)(()=>{["/login","/_register","/unauthorized"].some(e=>n.startsWith(e))||p.s.isTokenValid()||r.push("/login")},[r,n]),(0,a.jsx)(a.Fragment,{children:t})}var m=r(1262);function w(e){let{children:t,...r}=e;return(0,a.jsx)(m.N,{...r,children:t})}function f(e){let{children:t}=e,[r]=(0,i.useState)(()=>new n.E({defaultOptions:{queries:{staleTime:3e5,refetchOnWindowFocus:!1,retry:2}}}));return(0,a.jsx)(o.Ht,{client:r,children:(0,a.jsxs)(w,{attribute:"class",defaultTheme:"system",enableSystem:!0,disableTransitionOnChange:!0,children:[(0,a.jsx)(h,{children:(0,a.jsxs)(y,{children:[t,(0,a.jsx)(c.l$,{position:"top-right"})]})}),(0,a.jsx)(s.E,{initialIsOpen:!1})]})})}},7916:(e,t,r)=>{"use strict";r.d(t,{apiClient:()=>s});var a=r(5842),n=r(3234);class o{getBaseUrl(){return n.s.getLocalBaseUrl()}getHeaders(){return n.s.getAuthHeaders()}handleAuthError(e){if(a.A.isAxiosError(e)){var t,r;((null==(t=e.response)?void 0:t.status)===401||(null==(r=e.response)?void 0:r.status)===403)&&(n.s.clearToken(),window.location.href="/login")}}async get(e,t){let r={headers:this.getHeaders(),params:t,withCredentials:!1};try{return console.log("Making GET request to ".concat(this.getBaseUrl()).concat(e)),(await a.A.get("".concat(this.getBaseUrl()).concat(e),r)).data}catch(e){throw this.handleAuthError(e),e}}async post(e,t){let r={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making POST request to ".concat(this.getBaseUrl()).concat(e),t),(await a.A.post("".concat(this.getBaseUrl()).concat(e),t,r)).data}catch(t){throw this.handleAuthError(t),console.error("Error posting to ".concat(e,":"),t),t}}async put(e,t){let r={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making PUT request to ".concat(this.getBaseUrl()).concat(e),t),(await a.A.put("".concat(this.getBaseUrl()).concat(e),t,r)).data}catch(t){throw this.handleAuthError(t),console.error("Error updating ".concat(e,":"),t),t}}async patch(e,t){let r={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making PATCH request to ".concat(this.getBaseUrl()).concat(e),t),(await a.A.patch("".concat(this.getBaseUrl()).concat(e),t,r)).data}catch(t){throw this.handleAuthError(t),console.error("Error patching ".concat(e,":"),t),t}}async delete(e){let t={headers:this.getHeaders(),withCredentials:!1};try{return console.log("Making DELETE request to ".concat(this.getBaseUrl()).concat(e)),(await a.A.delete("".concat(this.getBaseUrl()).concat(e),t)).data}catch(t){throw this.handleAuthError(t),console.error("Error deleting from ".concat(e,":"),t),t}}}let s=new o},8748:(e,t,r)=>{"use strict";r.d(t,{SuppressHydrationWarning:()=>o});var a=r(3422),n=r(4398);function o(e){let{children:t}=e,[r,o]=(0,n.useState)(!1);return((0,n.useEffect)(()=>{o(!0)},[]),r)?(0,a.jsx)(a.Fragment,{children:t}):null}},8770:()=>{}},e=>{var t=t=>e(e.s=t);e.O(0,[699,273,363,29,375,945,497,358],()=>t(7075)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/login/page-9d2abe7b74a0707f.js b/ui_out/_next/static/chunks/app/login/page-603b845ae6bd54c9.js similarity index 100% rename from ui_out/_next/static/chunks/app/login/page-9d2abe7b74a0707f.js rename to ui_out/_next/static/chunks/app/login/page-603b845ae6bd54c9.js diff --git a/ui_out/_next/static/chunks/app/model/page-8be1c146fd1f0602.js b/ui_out/_next/static/chunks/app/model/page-862224df2a15ab65.js similarity index 93% rename from ui_out/_next/static/chunks/app/model/page-8be1c146fd1f0602.js rename to ui_out/_next/static/chunks/app/model/page-862224df2a15ab65.js index 9930b6b4..0054df04 100644 --- a/ui_out/_next/static/chunks/app/model/page-8be1c146fd1f0602.js +++ b/ui_out/_next/static/chunks/app/model/page-862224df2a15ab65.js @@ -1 +1 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[552],{834:(e,s,t)=>{"use strict";t.d(s,{T:()=>l});var a=t(3422);t(4398);var r=t(9183);function l(e){let{className:s,...t}=e;return(0,a.jsx)("textarea",{"data-slot":"textarea",className:(0,r.cn)("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",s),...t})}},2264:(e,s,t)=>{"use strict";t.d(s,{bq:()=>u,eb:()=>p,gC:()=>m,l6:()=>d,yv:()=>c});var a=t(3422);t(4398);var r=t(3439),l=t(9994),i=t(8940),n=t(4967),o=t(9183);function d(e){let{...s}=e;return(0,a.jsx)(r.bL,{"data-slot":"select",...s})}function c(e){let{...s}=e;return(0,a.jsx)(r.WT,{"data-slot":"select-value",...s})}function u(e){let{className:s,size:t="default",children:i,...n}=e;return(0,a.jsxs)(r.l9,{"data-slot":"select-trigger","data-size":t,className:(0,o.cn)("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",s),...n,children:[i,(0,a.jsx)(r.In,{asChild:!0,children:(0,a.jsx)(l.A,{className:"size-4 opacity-50"})})]})}function m(e){let{className:s,children:t,position:l="popper",...i}=e;return(0,a.jsx)(r.ZL,{children:(0,a.jsxs)(r.UC,{"data-slot":"select-content",className:(0,o.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--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","popper"===l&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",s),position:l,...i,children:[(0,a.jsx)(x,{}),(0,a.jsx)(r.LM,{className:(0,o.cn)("p-1","popper"===l&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:t}),(0,a.jsx)(h,{})]})})}function p(e){let{className:s,children:t,...l}=e;return(0,a.jsxs)(r.q7,{"data-slot":"select-item",className:(0,o.cn)("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",s),...l,children:[(0,a.jsx)("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:(0,a.jsx)(r.VF,{children:(0,a.jsx)(i.A,{className:"size-4"})})}),(0,a.jsx)(r.p4,{children:t})]})}function x(e){let{className:s,...t}=e;return(0,a.jsx)(r.PP,{"data-slot":"select-scroll-up-button",className:(0,o.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(n.A,{className:"size-4"})})}function h(e){let{className:s,...t}=e;return(0,a.jsx)(r.wn,{"data-slot":"select-scroll-down-button",className:(0,o.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(l.A,{className:"size-4"})})}},6320:(e,s,t)=>{"use strict";t.d(s,{Cf:()=>u,Es:()=>p,L3:()=>x,c7:()=>m,lG:()=>n,rr:()=>h,zM:()=>o});var a=t(3422);t(4398);var r=t(4316),l=t(9680),i=t(9183);function n(e){let{...s}=e;return(0,a.jsx)(r.bL,{"data-slot":"dialog",...s})}function o(e){let{...s}=e;return(0,a.jsx)(r.l9,{"data-slot":"dialog-trigger",...s})}function d(e){let{...s}=e;return(0,a.jsx)(r.ZL,{"data-slot":"dialog-portal",...s})}function c(e){let{className:s,...t}=e;return(0,a.jsx)(r.hJ,{"data-slot":"dialog-overlay",className:(0,i.cn)("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",s),...t})}function u(e){let{className:s,children:t,...n}=e;return(0,a.jsxs)(d,{"data-slot":"dialog-portal",children:[(0,a.jsx)(c,{}),(0,a.jsxs)(r.UC,{"data-slot":"dialog-content",className:(0,i.cn)("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",s),...n,children:[t,(0,a.jsxs)(r.bm,{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:[(0,a.jsx)(l.A,{}),(0,a.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function m(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-header",className:(0,i.cn)("flex flex-col gap-2 text-center sm:text-left",s),...t})}function p(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-footer",className:(0,i.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",s),...t})}function x(e){let{className:s,...t}=e;return(0,a.jsx)(r.hE,{"data-slot":"dialog-title",className:(0,i.cn)("text-lg leading-none font-semibold",s),...t})}function h(e){let{className:s,...t}=e;return(0,a.jsx)(r.VY,{"data-slot":"dialog-description",className:(0,i.cn)("text-muted-foreground text-sm",s),...t})}},6568:(e,s,t)=>{"use strict";t.d(s,{d:()=>i});var a=t(3422);t(4398);var r=t(2495),l=t(9183);function i(e){let{className:s,...t}=e;return(0,a.jsx)(r.bL,{"data-slot":"switch",className:(0,l.cn)("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",s),...t,children:(0,a.jsx)(r.zi,{"data-slot":"switch-thumb",className:(0,l.cn)("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")})})}},6715:(e,s,t)=>{Promise.resolve().then(t.bind(t,7678))},6839:(e,s,t)=>{"use strict";t.d(s,{Xi:()=>o,av:()=>d,j7:()=>n,tU:()=>i});var a=t(3422);t(4398);var r=t(1749),l=t(9183);function i(e){let{className:s,...t}=e;return(0,a.jsx)(r.bL,{"data-slot":"tabs",className:(0,l.cn)("flex flex-col gap-2",s),...t})}function n(e){let{className:s,...t}=e;return(0,a.jsx)(r.B8,{"data-slot":"tabs-list",className:(0,l.cn)("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",s),...t})}function o(e){let{className:s,...t}=e;return(0,a.jsx)(r.l9,{"data-slot":"tabs-trigger",className:(0,l.cn)("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",s),...t})}function d(e){let{className:s,...t}=e;return(0,a.jsx)(r.UC,{"data-slot":"tabs-content",className:(0,l.cn)("flex-1 outline-none",s),...t})}},7678:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>e9});var a=t(3422),r=t(4398),l=t(100),i=t(2349),n=t(6013),o=t(9119),d=t(1407),c=t(552),u=t(9945);let m=u.Ik({id:u.Yj(),name:u.Yj(),full_name:u.Yj(),description:u.Yj().optional(),modelType:u.Yj(),isEnabled:u.zM(),createdAt:u.Yj().datetime(),updatedAt:u.Yj().datetime(),provider:u.Yj(),url:u.Yj().url(),api_key:u.Yj().optional(),input_cost:u.ai().min(0),output_cost:u.ai().min(0),min_cost_per_request:u.ai().min(0,"Minimum cost per request must be non-negative").default(0),min_cash_per_request:u.ai().min(0,"Minimum cash per request must be non-negative").default(0),contextLength:u.ai().int().optional(),apiKeyRequired:u.zM().default(!0),provider_id:u.Yj().optional(),is_free:u.zM().default(!1),soft_deleted:u.zM().optional(),has_own_api_key:u.zM(),api_key_type:u.Yj()});m.extend({settings:u.g1(u.L5()).optional(),pricing:u.Ik({inputCostPer1kTokens:u.ai().optional(),outputCostPer1kTokens:u.ai().optional(),unitCost:u.ai().optional()}).optional()}),m.omit({id:!0,createdAt:!0,updatedAt:!0,has_own_api_key:!0,api_key_type:!0}).extend({settings:u.g1(u.L5()).optional()}),m.partial().omit({id:!0,createdAt:!0,updatedAt:!0,has_own_api_key:!0,api_key_type:!0});let p=u.Ik({name:u.Yj().min(1,"Name is required"),full_name:u.Yj().optional(),input_cost:u.ai().min(0,"Input cost must be non-negative"),output_cost:u.ai().min(0,"Output cost must be non-negative"),provider:u.Yj().min(1,"Provider is required"),modelType:u.k5(["text","embedding","image","audio","multimodal"]),description:u.Yj().optional().transform(e=>""===e?void 0:e),contextLength:u.ai().int().min(0).optional().transform(e=>0===e?void 0:e)}).transform(e=>({...e})),x=u.Ik({provider:u.Yj().min(1,"Provider is required"),group_api_key:u.Yj().transform(e=>""===e?void 0:e).optional(),group_url:u.Yj().transform(e=>""===e?void 0:e).pipe(u.Yj().url("Please enter a valid URL").optional()).optional()});u.Ik({data:u.YO(m),pagination:u.Ik({total:u.ai(),page:u.ai(),pageSize:u.ai(),totalPages:u.ai()})}),u.Ik({modelId:u.Yj(),input:u.Yj(),parameters:u.g1(u.L5()).optional()}),u.Ik({output:u.Yj(),usage:u.Ik({promptTokens:u.ai().optional(),completionTokens:u.ai().optional(),totalTokens:u.ai().optional()}).optional(),timings:u.Ik({totalMs:u.ai()}).optional()});var h=t(3648),g=t(268),v=t(834),j=t(6320),f=t(2264),y=t(6950),b=t(9183),N=t(3130);let w=d.Op,_=r.createContext({}),k=e=>{let{...s}=e;return(0,a.jsx)(_.Provider,{value:{name:s.name},children:(0,a.jsx)(d.xI,{...s})})},C=()=>{let e=r.useContext(_),s=r.useContext(M),{getFieldState:t}=(0,d.xW)(),a=(0,d.lN)({name:e.name}),l=t(e.name,a);if(!e)throw Error("useFormField should be used within ");let{id:i}=s;return{id:i,name:e.name,formItemId:"".concat(i,"-form-item"),formDescriptionId:"".concat(i,"-form-item-description"),formMessageId:"".concat(i,"-form-item-message"),...l}},M=r.createContext({});function A(e){let{className:s,...t}=e,l=r.useId();return(0,a.jsx)(M.Provider,{value:{id:l},children:(0,a.jsx)("div",{"data-slot":"form-item",className:(0,b.cn)("grid gap-2",s),...t})})}function S(e){let{className:s,...t}=e,{error:r,formItemId:l}=C();return(0,a.jsx)(N.J,{"data-slot":"form-label","data-error":!!r,className:(0,b.cn)("data-[error=true]:text-destructive",s),htmlFor:l,...t})}function F(e){let{...s}=e,{error:t,formItemId:r,formDescriptionId:l,formMessageId:i}=C();return(0,a.jsx)(y.DX,{"data-slot":"form-control",id:r,"aria-describedby":t?"".concat(l," ").concat(i):"".concat(l),"aria-invalid":!!t,...s})}function P(e){let{className:s,...t}=e,{formDescriptionId:r}=C();return(0,a.jsx)("p",{"data-slot":"form-description",id:r,className:(0,b.cn)("text-muted-foreground text-sm",s),...t})}function R(e){var s;let{className:t,...r}=e,{error:l,formMessageId:i}=C(),n=l?String(null!=(s=null==l?void 0:l.message)?s:""):r.children;return n?(0,a.jsx)("p",{"data-slot":"form-message",id:i,className:(0,b.cn)("text-destructive text-sm",t),...r,children:n}):null}var T=t(856),z=t(2434),E=t(3831);function I(e){let{onModelAdd:s,onCancel:t,isOpen:l}=e,[i,n]=(0,r.useState)(!1),o=(0,d.mN)({resolver:(0,c.u)(p),defaultValues:{name:"",full_name:"",input_cost:0,output_cost:0,provider:"",modelType:"text",description:"",contextLength:void 0}}),u=async e=>{n(!0);try{await s(e),E.oR.success("Model added successfully!"),o.reset(),null==t||t()}catch(e){E.oR.error("Failed to add model. Please try again."),console.error("Error adding model:",e)}finally{n(!1)}},m=()=>{i||(o.reset(),null==t||t())};return(0,a.jsx)(j.lG,{open:l,onOpenChange:m,children:(0,a.jsxs)(j.Cf,{className:"max-h-[90vh] overflow-y-auto sm:max-w-[600px]",children:[(0,a.jsxs)(j.c7,{children:[(0,a.jsxs)(j.L3,{className:"flex items-center gap-2",children:[(0,a.jsx)(T.A,{className:"h-5 w-5"}),"Add New Model"]}),(0,a.jsx)(j.rr,{children:"Manually add a new AI model to your collection"})]}),(0,a.jsx)(w,{...o,children:(0,a.jsxs)("form",{onSubmit:o.handleSubmit(u),className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:o.control,name:"name",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Model Name *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"e.g., GPT-4o",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"Display name for the model"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:o.control,name:"provider",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Provider *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"e.g., OpenAI, Anthropic",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"AI model provider or company"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:o.control,name:"input_cost",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Input Cost (per 1M tokens) *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",step:"0.001",min:"0",placeholder:"5.00",...s,value:s.value?parseFloat(s.value.toFixed(3)):"",onChange:e=>{let t=Math.round(1e3*(parseFloat(e.target.value)||0))/1e3;s.onChange(t)},className:"w-full"})}),(0,a.jsx)(P,{children:"Cost in USD per 1,000,000 input tokens (max 3 decimals)"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:o.control,name:"output_cost",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Output Cost (per 1M tokens) *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",step:"0.001",min:"0",placeholder:"15.00",...s,value:s.value?parseFloat(s.value.toFixed(3)):"",onChange:e=>{let t=Math.round(1e3*(parseFloat(e.target.value)||0))/1e3;s.onChange(t)},className:"w-full"})}),(0,a.jsx)(P,{children:"Cost in USD per 1,000,000 output tokens (max 3 decimals)"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:o.control,name:"modelType",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Model Type"}),(0,a.jsxs)(f.l6,{onValueChange:s.onChange,defaultValue:s.value,children:[(0,a.jsx)(F,{children:(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{placeholder:"Select model type"})})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"text",children:"Text/Chat"}),(0,a.jsx)(f.eb,{value:"embedding",children:"Embedding"}),(0,a.jsx)(f.eb,{value:"image",children:"Image Generation"}),(0,a.jsx)(f.eb,{value:"audio",children:"Audio"}),(0,a.jsx)(f.eb,{value:"multimodal",children:"Multimodal"})]})]}),(0,a.jsx)(P,{children:"Type of AI model functionality"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:o.control,name:"contextLength",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Context Length"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",min:"0",placeholder:"8192",value:s.value||"",onChange:e=>{let t=parseInt(e.target.value);s.onChange(isNaN(t)||0===t?void 0:t)},className:"w-full"})}),(0,a.jsx)(P,{children:"Maximum context length in tokens (optional, leave empty for default)"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsx)(k,{control:o.control,name:"description",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Description"}),(0,a.jsx)(F,{children:(0,a.jsx)(v.T,{placeholder:"Brief description of the model...",...s,rows:3,className:"w-full"})}),(0,a.jsx)(P,{children:"Optional description or notes about the model"}),(0,a.jsx)(R,{})]})}}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 pt-4",children:[(0,a.jsx)(h.$,{type:"button",variant:"outline",onClick:m,disabled:i,children:"Cancel"}),(0,a.jsx)(h.$,{type:"submit",disabled:i,children:i?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Adding..."]}):"Add Model"})]})]})})]})})}var q=t(7996),L=t(6568);let Y=u.Ik({name:u.Yj().min(1,"Name is required"),description:u.Yj().optional(),context_length:u.au.number().min(0),prompt:u.au.number().min(0),completion:u.au.number().min(0),enabled:u.zM()}),U=e=>null==e||isNaN(e)?0:Math.round(1e5*e)/1e5;function O(e){let{model:s,providerId:t,onModelUpdate:l,onCancel:i,isOpen:n}=e,[u,m]=(0,r.useState)(!1),[p,x]=(0,r.useState)(null),[f,y]=(0,r.useState)(!1),b=(0,d.mN)({resolver:(0,c.u)(Y),defaultValues:{name:s.name,description:s.description||"",context_length:s.contextLength||4096,prompt:U(s.input_cost),completion:U(s.output_cost),enabled:!1!==s.isEnabled}}),N=(0,r.useCallback)(async()=>{if(!t)return void console.error("loadAdminModel called without providerId");try{console.log("Loading admin model:",{providerId:t,modelId:s.full_name});let e=await o.zQ.getProviderModel(t,s.full_name);x(e),y(!1),b.reset({name:e.name,description:e.description||"",context_length:e.context_length,prompt:U(e.pricing.prompt),completion:U(e.pricing.completion),enabled:!1!==e.enabled})}catch(e){console.log("Model not in database, will create new override:",e),y(!0),x({id:s.full_name,name:s.name,description:s.description||"",created:Math.floor(Date.now()/1e3),context_length:s.contextLength||4096,architecture:{modality:s.modelType||"text",input_modalities:[s.modelType||"text"],output_modalities:[s.modelType||"text"],tokenizer:"",instruct_type:null},pricing:{prompt:U(s.input_cost),completion:U(s.output_cost),request:0,image:0,web_search:0,internal_reasoning:0},per_request_limits:null,top_provider:null,upstream_provider_id:t,enabled:!1!==s.isEnabled}),b.reset({name:s.name,description:s.description||"",context_length:s.contextLength||4096,prompt:U(s.input_cost),completion:U(s.output_cost),enabled:!1!==s.isEnabled})}},[t,s,b]);(0,r.useEffect)(()=>{n&&t?N():n&&!t&&(console.error("EditModelForm opened without providerId",{model:s,providerId:t}),E.oR.error("Missing provider information for this model"))},[n,t,s,N]);let _=async e=>{if(!t){console.error("onSubmit called without providerId",{model:s,providerId:t}),E.oR.error("Missing provider ID - cannot update model");return}if(!p){console.error("onSubmit called without adminModelData",{model:s,providerId:t,adminModelData:p}),E.oR.error("Model data not loaded - please try reopening the form");return}m(!0);try{let s={id:p.id,name:e.name,description:e.description||"",created:p.created||Math.floor(Date.now()/1e3),context_length:e.context_length,architecture:p.architecture||{modality:"text",input_modalities:["text"],output_modalities:["text"],tokenizer:"",instruct_type:null},pricing:{prompt:U(e.prompt),completion:U(e.completion),request:0,image:0,web_search:0,internal_reasoning:0},per_request_limits:p.per_request_limits,top_provider:p.top_provider,upstream_provider_id:t,enabled:e.enabled};f?(console.log("Creating new model override"),await o.zQ.createProviderModel(t,s),E.oR.success("Model override created successfully!")):(console.log("Updating existing model override"),await o.zQ.updateProviderModel(t,p.id,s),E.oR.success("Model updated successfully!")),null==l||l(),null==i||i()}catch(s){let e=f?"create":"update";E.oR.error("Failed to ".concat(e," model. Please try again.")),console.error("Error ".concat(e,"ing model:"),s)}finally{m(!1)}},C=()=>{u||null==i||i()};return(0,a.jsx)(j.lG,{open:n,onOpenChange:C,children:(0,a.jsxs)(j.Cf,{className:"max-h-[90vh] overflow-y-auto sm:max-w-[600px]",children:[(0,a.jsxs)(j.c7,{children:[(0,a.jsxs)(j.L3,{className:"flex items-center gap-2",children:[(0,a.jsx)(q.A,{className:"h-5 w-5"}),f?"Create Model Override":"Edit Model Override"]}),(0,a.jsx)(j.rr,{children:f?"Create an override for "".concat(s.name,"""):"Update the model override for "".concat(s.name,""")})]}),(0,a.jsx)(w,{...b,children:(0,a.jsxs)("form",{onSubmit:b.handleSubmit(_),className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:b.control,name:"name",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Display Name *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"e.g., GPT-4",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"Custom display name for the model"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:b.control,name:"context_length",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Context Length *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",min:"0",placeholder:"4096",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"Maximum context window size"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsx)(k,{control:b.control,name:"description",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Description"}),(0,a.jsx)(F,{children:(0,a.jsx)(v.T,{placeholder:"Brief description of the model...",...s,rows:3,className:"w-full"})}),(0,a.jsx)(P,{children:"Optional description or notes about the model"}),(0,a.jsx)(R,{})]})}}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:b.control,name:"prompt",render:e=>{var s;let{field:t}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Input Cost (per 1M tokens) *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",step:"0.00001",min:"0",placeholder:"5.00000",value:null!=(s=t.value)?s:"",onChange:e=>{let s=e.target.value;t.onChange(""===s?0:parseFloat(s))},onBlur:e=>{let s=parseFloat(e.target.value);t.onChange(U(s))},className:"w-full"})}),(0,a.jsx)(P,{children:"Cost in USD per 1,000,000 input tokens (max 5 decimals)"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:b.control,name:"completion",render:e=>{var s;let{field:t}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Output Cost (per 1M tokens) *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",step:"0.00001",min:"0",placeholder:"15.00000",value:null!=(s=t.value)?s:"",onChange:e=>{let s=e.target.value;t.onChange(""===s?0:parseFloat(s))},onBlur:e=>{let s=parseFloat(e.target.value);t.onChange(U(s))},className:"w-full"})}),(0,a.jsx)(P,{children:"Cost in USD per 1,000,000 output tokens (max 5 decimals)"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsx)(k,{control:b.control,name:"enabled",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{className:"flex flex-row items-center justify-between rounded-lg border p-4",children:[(0,a.jsxs)("div",{className:"space-y-0.5",children:[(0,a.jsx)(S,{className:"text-base",children:"Model Enabled"}),(0,a.jsx)(P,{children:"Enable or disable this model override"})]}),(0,a.jsx)(F,{children:(0,a.jsx)(L.d,{checked:s.value,onCheckedChange:s.onChange})})]})}}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 pt-4",children:[(0,a.jsx)(h.$,{type:"button",variant:"outline",onClick:C,disabled:u,children:"Cancel"}),(0,a.jsx)(h.$,{type:"submit",disabled:u,children:u?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),f?"Creating...":"Updating..."]}):f?"Create Override":"Update Model"})]})]})})]})})}var J=t(1935),Q=t(5195),K=t(9906),D=t(2267),G=t(1220),V=t(9442);function $(e){let{provider:s,models:t,groupSettings:l,onGroupUpdate:i,onCancel:n,isOpen:o}=e,[u,m]=(0,r.useState)(!1),[p,v]=(0,r.useState)(!1),[f,y]=(0,r.useState)(!!(null==l?void 0:l.group_url)),b=(0,d.mN)({resolver:(0,c.u)(x),defaultValues:{provider:s,group_api_key:(null==l?void 0:l.group_api_key)||"",group_url:(null==l?void 0:l.group_url)||""}}),N=async e=>{m(!0);try{var t,a;let r={...e,group_api_key:(null==(t=e.group_api_key)?void 0:t.trim())||void 0,group_url:f&&(null==(a=e.group_url)?void 0:a.trim())||void 0};await i(s,r),E.oR.success('Group "'.concat(s,'" updated successfully!')),null==n||n()}catch(e){E.oR.error("Failed to update group. Please try again."),console.error("Error updating group:",e)}finally{m(!1)}},_=t.filter(e=>!e.api_key).length,C=t.filter(e=>!e.api_key&&(!e.url||e.url.startsWith("/"))).length,M=()=>{u||null==n||n()};return(0,a.jsx)(j.lG,{open:o,onOpenChange:M,children:(0,a.jsxs)(j.Cf,{className:"max-h-[90vh] overflow-y-auto sm:max-w-[700px]",children:[(0,a.jsxs)(j.c7,{children:[(0,a.jsxs)(j.L3,{className:"flex items-center gap-2",children:[(0,a.jsx)(J.A,{className:"h-5 w-5"}),"Edit Provider Group: ",s]}),(0,a.jsxs)(j.rr,{children:["Update settings for all ",t.length," models in this group. Group settings provide defaults for models without individual configurations."]})]}),(0,a.jsxs)("div",{className:"mb-6 space-y-4",children:[(0,a.jsxs)("div",{className:"rounded-md border p-4",children:[(0,a.jsxs)("h4",{className:"mb-2 flex items-center gap-2 text-sm font-medium",children:[(0,a.jsx)(Q.A,{className:"h-4 w-4"}),"API Key Configuration"]}),(0,a.jsx)("div",{className:"space-y-2 text-sm",children:(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{children:"Models using group API key:"}),(0,a.jsx)("span",{className:"font-medium text-blue-600",children:_})]})})]}),(0,a.jsxs)("div",{className:"rounded-md border p-4",children:[(0,a.jsxs)("h4",{className:"mb-2 flex items-center gap-2 text-sm font-medium",children:[(0,a.jsx)(K.A,{className:"h-4 w-4"}),"URL Configuration"]}),(0,a.jsxs)("div",{className:"space-y-2 text-sm",children:[(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{children:"Models using group URL:"}),(0,a.jsx)("span",{className:"font-medium text-blue-600",children:C})]}),(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{children:"Models with individual URLs:"}),(0,a.jsx)("span",{className:"font-medium text-green-600",children:t.length-C})]}),(null==l?void 0:l.group_url)&&(0,a.jsxs)("div",{className:"mt-2 rounded bg-blue-50 p-2 text-xs",children:[(0,a.jsx)("span",{className:"font-medium",children:"Current group URL:"})," ",l.group_url]})]})]}),(0,a.jsxs)("div",{className:"rounded-md border p-4",children:[(0,a.jsx)("h4",{className:"mb-2 text-sm font-medium",children:"Models in this group:"}),(0,a.jsx)("div",{className:"max-h-32 overflow-y-auto",children:(0,a.jsx)("div",{className:"flex flex-wrap gap-2",children:t.map(e=>(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-medium ".concat(e.api_key?"bg-green-100 text-green-800":"bg-blue-100 text-blue-800"),title:e.api_key?"Has individual API key and URL":"Uses group API key and URL",children:[e.name,e.api_key&&" \uD83D\uDD11",e.url&&!e.url.startsWith("/")&&e.api_key&&" \uD83C\uDF10"]},e.id))})})]})]}),(0,a.jsx)(w,{...b,children:(0,a.jsxs)("form",{onSubmit:b.handleSubmit(N),className:"space-y-6",children:[(0,a.jsx)(k,{control:b.control,name:"provider",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Provider Name *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"e.g., OpenAI, Anthropic",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"This will update the provider name for all models in this group"}),(0,a.jsx)(R,{})]})}}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"space-y-0.5",children:[(0,a.jsx)(S,{className:"text-base",children:"Group Base URL"}),(0,a.jsx)(P,{children:"Provide a custom base URL for this provider group"})]}),(0,a.jsx)(L.d,{checked:f,onCheckedChange:y})]}),f&&(0,a.jsx)(k,{control:b.control,name:"group_url",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Base URL"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"https://api.openai.com/v1 or https://your-proxy.com/v1",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"This base URL will be used for models without individual URLs. Models will append their endpoint path (e.g., /chat/completions) to this base."}),(0,a.jsx)(R,{})]})}}),!f&&(null==l?void 0:l.group_url)&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(D.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Removing the group URL will make models in this group fall back to the default system endpoint. Models with individual URLs will be unaffected."})]}),f&&!(null==l?void 0:l.group_url)&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(G.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Adding a group URL will allow models in this group to use a custom endpoint instead of the default system endpoint."})]})]}),(0,a.jsx)(k,{control:b.control,name:"group_api_key",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Group API Key"}),(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:p?"text":"password",placeholder:"sk-... (leave empty to remove)",...s,className:"w-full pr-24"})}),(0,a.jsx)(h.$,{type:"button",variant:"ghost",size:"sm",className:"absolute top-0 right-0 h-full px-3 py-2 hover:bg-transparent",onClick:()=>v(!p),children:p?"Hide":"Show"})]}),(0,a.jsxs)(P,{children:["This API key will be used for models that don't have individual API keys (",_," models). Leave empty to remove the group API key."]}),(0,a.jsx)(R,{})]})}}),(0,a.jsxs)("div",{className:"rounded-md border border-amber-200 bg-amber-50 p-4",children:[(0,a.jsx)("p",{className:"text-sm text-amber-800",children:(0,a.jsx)("strong",{children:"How group settings work:"})}),(0,a.jsxs)("ul",{className:"mt-2 list-inside list-disc space-y-1 text-sm text-amber-800",children:[(0,a.jsx)("li",{children:"Models with individual API keys and URLs will keep their specific settings"}),(0,a.jsx)("li",{children:"Models without individual settings will use the group defaults"}),(0,a.jsx)("li",{children:"Removing the group URL makes models fall back to the system default endpoint"}),(0,a.jsx)("li",{children:'You can use "Apply Group Settings" to force models to use group configurations'})]})]}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 pt-4",children:[(0,a.jsx)(h.$,{type:"button",variant:"outline",onClick:M,disabled:u,children:"Cancel"}),(0,a.jsx)(h.$,{type:"submit",disabled:u,children:u?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Updating..."]}):"Update Group"})]})]})})]})})}var B=t(7228),W=t(9675),Z=t(246),H=t(1853),X=t(8940);function ee(e){let{className:s,...t}=e;return(0,a.jsx)(H.bL,{"data-slot":"checkbox",className:(0,b.cn)("peer border-input dark:bg-input/30 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:data-[state=checked]:bg-primary data-[state=checked]:border-primary focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive size-4 shrink-0 rounded-[4px] border shadow-xs transition-shadow outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",s),...t,children:(0,a.jsx)(H.C1,{"data-slot":"checkbox-indicator",className:"flex items-center justify-center text-current transition-none",children:(0,a.jsx)(X.A,{className:"size-3.5"})})})}var es=t(9625);function et(e){let{className:s,children:t,...r}=e;return(0,a.jsxs)(es.bL,{"data-slot":"scroll-area",className:(0,b.cn)("relative",s),...r,children:[(0,a.jsx)(es.LM,{"data-slot":"scroll-area-viewport",className:"focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1",children:t}),(0,a.jsx)(ea,{}),(0,a.jsx)(es.OK,{})]})}function ea(e){let{className:s,orientation:t="vertical",...r}=e;return(0,a.jsx)(es.VM,{"data-slot":"scroll-area-scrollbar",orientation:t,className:(0,b.cn)("flex touch-none p-px transition-colors select-none","vertical"===t&&"h-full w-2.5 border-l border-l-transparent","horizontal"===t&&"h-2.5 flex-col border-t border-t-transparent",s),...r,children:(0,a.jsx)(es.lr,{"data-slot":"scroll-area-thumb",className:"bg-border relative flex-1 rounded-full"})})}var er=t(8561);function el(e){let{isOpen:s,onClose:t,onSuccess:l}=e,[i,n]=(0,r.useState)(null),[d,c]=(0,r.useState)([]),[u,m]=(0,r.useState)([]),[p,x]=(0,r.useState)(new Set),[g,v]=(0,r.useState)(!1),[y,b]=(0,r.useState)(!1),[N,w]=(0,r.useState)(!1),[_,k]=(0,r.useState)(null),C=(0,r.useCallback)(async()=>{if(i){b(!0),m([]),x(new Set);try{let e=await o.zQ.getProviderModels(i),s=new Set(e.db_models.map(e=>e.id)),t=e.remote_models.filter(e=>!s.has(e.id));m(t)}catch(e){E.oR.error("Failed to fetch models from provider")}finally{b(!1)}}},[i]);(0,r.useEffect)(()=>{s&&M()},[s]),(0,r.useEffect)(()=>{i&&C()},[i,C]);let M=async()=>{v(!0);try{let e=await o.zQ.getUpstreamProviders();c(e)}catch(e){E.oR.error("Failed to load providers")}finally{v(!1)}},A=e=>{let s=new Set(p);s.has(e)?s.delete(e):s.add(e),x(s)},S=async()=>{if(0===p.size)return void E.oR.error("Please select at least one model");w(!0);let e=0,s=0,t=[];try{for(let a of Array.from(p)){let r=u.find(e=>e.id===a);if(r)try{await o.zQ.createModel({...r,upstream_provider_id:i,enabled:!0,created:Math.floor(Date.now()/1e3)}),e++}catch(r){let e=r instanceof Error?r.message:"Unknown error";e.includes("already exists")?s++:t.push("".concat(a,": ").concat(e))}}k({added:e,skipped:s,errors:t}),e>0&&(E.oR.success("Successfully added ".concat(e," models")),null==l||l()),t.length>0&&E.oR.warning("Completed with ".concat(t.length," errors"))}catch(e){E.oR.error("Failed to collect models")}finally{w(!1)}},F=()=>{N||(n(null),m([]),x(new Set),k(null),t())};return(0,a.jsx)(j.lG,{open:s,onOpenChange:F,children:(0,a.jsxs)(j.Cf,{className:"max-h-[80vh] sm:max-w-[700px]",children:[(0,a.jsxs)(j.c7,{children:[(0,a.jsxs)(j.L3,{className:"flex items-center gap-2",children:[(0,a.jsx)(B.A,{className:"h-5 w-5"}),"Collect Models from Provider"]}),(0,a.jsx)(j.rr,{children:"Fetch models from an upstream provider and add them to your database"})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("label",{className:"text-sm font-medium",children:"Select Provider"}),(0,a.jsxs)(f.l6,{value:null==i?void 0:i.toString(),onValueChange:e=>n(parseInt(e)),disabled:g,children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{placeholder:"Choose an upstream provider"})}),(0,a.jsx)(f.gC,{children:d.map(e=>(0,a.jsxs)(f.eb,{value:e.id.toString(),children:[e.provider_type," - ",e.base_url]},e.id))})]})]}),y&&(0,a.jsxs)("div",{className:"flex items-center justify-center py-8",children:[(0,a.jsx)(z.A,{className:"h-8 w-8 animate-spin"}),(0,a.jsx)("span",{className:"ml-2",children:"Loading models from provider..."})]}),!y&&i&&u.length>0&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"text-sm font-medium",children:[u.length," models available"]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(h.$,{variant:"outline",size:"sm",onClick:()=>{x(new Set(u.map(e=>e.id)))},disabled:N,children:"Select All"}),(0,a.jsx)(h.$,{variant:"outline",size:"sm",onClick:()=>{x(new Set)},disabled:N,children:"Deselect All"})]})]}),(0,a.jsx)(et,{className:"h-[300px] rounded-md border p-4",children:(0,a.jsx)("div",{className:"space-y-2",children:u.map(e=>(0,a.jsxs)("div",{className:"hover:bg-accent flex items-start space-x-3 rounded-lg border p-3",children:[(0,a.jsx)(ee,{checked:p.has(e.id),onCheckedChange:()=>A(e.id),disabled:N}),(0,a.jsxs)("div",{className:"flex-1 space-y-1",children:[(0,a.jsx)("div",{className:"font-mono text-sm font-medium",children:e.id}),(0,a.jsx)("div",{className:"text-muted-foreground text-xs",children:e.description||e.name}),e.context_length&&(0,a.jsxs)(er.E,{variant:"secondary",className:"text-xs",children:[e.context_length.toLocaleString()," tokens"]})]})]},e.id))})})]}),!y&&i&&0===u.length&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"No new models available from this provider. All models may already be in your database."})]}),_&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(Z.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Collection Results:"}),(0,a.jsx)("br",{}),"• ",_.added," models added",(0,a.jsx)("br",{}),"• ",_.skipped," models skipped",_.errors.length>0&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("br",{}),"• ",_.errors.length," errors occurred"]})]})]}),_.errors.length>0&&(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Errors:"}),(0,a.jsxs)("ul",{className:"mt-1 list-inside list-disc text-sm",children:[_.errors.slice(0,3).map((e,s)=>(0,a.jsx)("li",{children:e},s)),_.errors.length>3&&(0,a.jsxs)("li",{children:["... and ",_.errors.length-3," more errors"]})]})]})]})]}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 pt-4",children:[(0,a.jsx)(h.$,{variant:"outline",onClick:F,disabled:N,children:_?"Close":"Cancel"}),(0,a.jsx)(h.$,{onClick:S,disabled:N||!i||0===p.size||y,children:N?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Adding Models..."]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(B.A,{className:"mr-2 h-4 w-4"}),"Add ",p.size," Models"]})})]})]})]})})}function ei(e){return 0===e?"Free":e<1e-6?"$".concat(e.toFixed(8)):e<.001?"$".concat(e.toFixed(6)):e<.01?"$".concat(e.toFixed(4)):"$".concat(e.toFixed(3))}var en=t(2738),eo=t(2745),ed=t(8815);function ec(e){let{...s}=e;return(0,a.jsx)(ed.bL,{"data-slot":"alert-dialog",...s})}function eu(e){let{...s}=e;return(0,a.jsx)(ed.ZL,{"data-slot":"alert-dialog-portal",...s})}function em(e){let{className:s,...t}=e;return(0,a.jsx)(ed.hJ,{"data-slot":"alert-dialog-overlay",className:(0,b.cn)("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",s),...t})}function ep(e){let{className:s,...t}=e;return(0,a.jsxs)(eu,{children:[(0,a.jsx)(em,{}),(0,a.jsx)(ed.UC,{"data-slot":"alert-dialog-content",className:(0,b.cn)("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",s),...t})]})}function ex(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"alert-dialog-header",className:(0,b.cn)("flex flex-col gap-2 text-center sm:text-left",s),...t})}function eh(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"alert-dialog-footer",className:(0,b.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",s),...t})}function eg(e){let{className:s,...t}=e;return(0,a.jsx)(ed.hE,{"data-slot":"alert-dialog-title",className:(0,b.cn)("text-lg font-semibold",s),...t})}function ev(e){let{className:s,...t}=e;return(0,a.jsx)(ed.VY,{"data-slot":"alert-dialog-description",className:(0,b.cn)("text-muted-foreground text-sm",s),...t})}function ej(e){let{className:s,...t}=e;return(0,a.jsx)(ed.rc,{className:(0,b.cn)((0,h.r)(),s),...t})}function ef(e){let{className:s,...t}=e;return(0,a.jsx)(ed.ZD,{className:(0,b.cn)((0,h.r)({variant:"outline"}),s),...t})}var ey=t(6049);function eb(e){let{...s}=e;return(0,a.jsx)(ey.bL,{"data-slot":"dropdown-menu",...s})}function eN(e){let{...s}=e;return(0,a.jsx)(ey.l9,{"data-slot":"dropdown-menu-trigger",...s})}function ew(e){let{className:s,sideOffset:t=4,...r}=e;return(0,a.jsx)(ey.ZL,{children:(0,a.jsx)(ey.UC,{"data-slot":"dropdown-menu-content",sideOffset:t,className:(0,b.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 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",s),...r})})}function e_(e){let{className:s,inset:t,variant:r="default",...l}=e;return(0,a.jsx)(ey.q7,{"data-slot":"dropdown-menu-item","data-inset":t,"data-variant":r,className:(0,b.cn)("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",s),...l})}function ek(e){let{className:s,...t}=e;return(0,a.jsx)(ey.wv,{"data-slot":"dropdown-menu-separator",className:(0,b.cn)("bg-border -mx-1 my-1 h-px",s),...t})}var eC=t(2034),eM=t(9987),eA=t(3545),eS=t(4963),eF=t(6541),eP=t(9197),eR=t(3732),eT=t(3728);function ez(e){let{filterProvider:s,groupData:t,filteredModels:d}=e,[c,u]=(0,r.useState)(""),[,m]=(0,r.useState)(null),[p,x]=(0,r.useState)(!1),[g,v]=(0,r.useState)(null),[j,f]=(0,r.useState)(null),[y,N]=(0,r.useState)(!1),[w,_]=(0,r.useState)(new Set),[k,C]=(0,r.useState)(!1),[M,A]=(0,r.useState)(!1),[S,F]=(0,r.useState)(!1),[P]=(0,r.useState)([]),R=(0,l.jE)(),{data:T,isLoading:z,error:L,refetch:Y}=(0,i.I)({queryKey:["models-with-providers"],queryFn:()=>o.zQ.getModelsWithProviders(),refetchOnWindowFocus:!1}),{models:U=[],groups:G=[]}=T||{},V=(0,r.useMemo)(()=>s?U.filter(e=>e.provider===s):U,[U,s]),B=(0,n.n)({mutationFn:async e=>{let s=U.filter(s=>e.includes(s.id)).reduce((e,s)=>{let t=s.provider_id||"unknown";return e[t]||(e[t]=[]),e[t].push(s),e},{}),t=0;for(let[e,a]of Object.entries(s)){if("unknown"===e)continue;let s=a.map(e=>e.full_name);t+=(await o.zQ.deleteModels(s,e)).deleted_count}return{deleted_count:t,message:"Models deleted"}},onSuccess:e=>{E.oR.success("Successfully deleted ".concat(e.deleted_count," model overrides")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to delete model overrides: ".concat(e.message))}}),W=(0,n.n)({mutationFn:async e=>{let s=U.filter(s=>e.includes(s.id)).reduce((e,s)=>{let t=s.provider_id||"unknown";return e[t]||(e[t]=[]),e[t].push(s),e},{}),t=0;for(let[e,r]of Object.entries(s))if("unknown"!==e)for(let s of r){let r=parseInt(e);try{let e=await o.zQ.getProviderModel(r,s.full_name);await o.zQ.updateProviderModel(r,s.full_name,{...e,enabled:!1}),t++}catch(e){var a;if((null==(a=e.message)?void 0:a.includes("404"))||404===e.status){let e={id:s.full_name,name:s.name,description:s.description||"",created:Math.floor(Date.now()/1e3),context_length:s.contextLength||4096,architecture:{modality:s.modelType||"text",input_modalities:[s.modelType||"text"],output_modalities:[s.modelType||"text"],tokenizer:"",instruct_type:null},pricing:{prompt:s.input_cost,completion:s.output_cost,request:0,image:0,web_search:0,internal_reasoning:0},per_request_limits:null,top_provider:null,upstream_provider_id:r,enabled:!1};await o.zQ.createProviderModel(r,e),t++}}}return{deleted_count:t,message:"Models disabled"}},onSuccess:e=>{E.oR.success("Successfully disabled ".concat(e.deleted_count," models")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to disable models: ".concat(e.message))}}),H=(0,n.n)({mutationFn:async e=>{if(!t)throw Error("No group data available");let s={};return s.api_key="",t.group_url&&(s.url=t.group_url),o.zQ.bulkUpdateModels(e,s)},onSuccess:e=>{E.oR.success("Successfully applied group settings to ".concat(e.updated_count," models")),e.errors.length>0&&(E.oR.warning("".concat(e.errors.length," models had errors during update")),console.warn("Bulk update errors:",e.errors)),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to apply group settings: ".concat(e.message))}}),X=(0,n.n)({mutationFn:()=>o.zQ.deleteAllModels(),onSuccess:e=>{E.oR.success("Successfully permanently deleted ".concat(e.deleted_count," models")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to permanently delete all models: ".concat(e.message))}}),es=(0,n.n)({mutationFn:e=>o.zQ.deleteModelsByProvider(e),onSuccess:e=>{E.oR.success("Successfully permanently deleted ".concat(e.deleted_count," models from provider")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to permanently delete provider models: ".concat(e.message))}}),et=(0,n.n)({mutationFn:async e=>{let s=U.find(s=>s.id===e);if(!s)throw Error("Model not found");if(!s.provider_id)throw Error("Provider ID not available for this model");let t=parseInt(s.provider_id),a=await o.zQ.getProviderModel(t,s.full_name);return await o.zQ.updateProviderModel(t,s.full_name,{...a,enabled:!0}),{restored_count:1}},onSuccess:()=>{E.oR.success("Model enabled successfully"),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to enable model: ".concat(e.message))}}),ea=(0,n.n)({mutationFn:async e=>{let s=U.filter(s=>e.includes(s.id)).reduce((e,s)=>{let t=s.provider_id||"unknown";return e[t]||(e[t]=[]),e[t].push(s),e},{}),t=0;for(let[e,a]of Object.entries(s))if("unknown"!==e)for(let s of a){let a=parseInt(e);try{let e=await o.zQ.getProviderModel(a,s.full_name);await o.zQ.updateProviderModel(a,s.full_name,{...e,enabled:!0}),t++}catch(e){console.error("Failed to enable model ".concat(s.full_name,":"),e)}}return{restored_count:t,message:"Models enabled"}},onSuccess:e=>{E.oR.success("Successfully enabled ".concat(e.restored_count," models")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to enable models: ".concat(e.message))}}),er=(0,r.useMemo)(()=>{let e=d&&d.length>0?d:P.length>0?P:V;return s?{[s]:e}:e?e.reduce((e,s)=>{let t=s.provider;return e[t]||(e[t]=[]),e[t].push(s),e},{}):{}},[V,P,d,s]),ed=(0,r.useMemo)(()=>new Map(G.map(e=>[e.provider,e])),[G]),eu=(0,r.useMemo)(()=>{let e={};return G.forEach(s=>{e[s.provider]={group_api_key:s.group_api_key,group_url:s.group_url}}),e},[G]),em=e=>{var s;return e.api_key?e.api_key:null==(s=eu[e.provider])?void 0:s.group_api_key},ey=e=>{let s=ed.get(e.provider),t=!!(e.api_key&&"string"==typeof e.api_key&&e.api_key!==(null==s?void 0:s.group_api_key)),a=!!(e.url&&"string"==typeof e.url&&!e.url.startsWith("/")&&e.url!==(null==s?void 0:s.group_url));return t||a},ez=async e=>{try{let s=G.find(s=>s.provider===e.provider);s||(s=await o.zQ.createModelGroup({provider:e.provider,group_api_key:void 0}));let t={name:e.name,full_name:e.name,input_cost:e.input_cost,output_cost:e.output_cost,provider:e.provider,modelType:e.modelType,description:e.description||void 0,contextLength:e.contextLength};await o.zQ.createModel(t),await Y(),E.oR.success('Model "'.concat(e.name,'" added successfully!'))}catch(e){throw console.error("Error adding model:",e),E.oR.error("Failed to add model. Please try again."),e}},eE=async()=>{await Y(),v(null)},eI=async(e,s)=>{try{let t=ed.get(e);t&&(await o.zQ.updateModelGroup(t.id,{provider:s.provider,group_api_key:s.group_api_key||void 0,group_url:s.group_url||void 0}),await Y(),f(null),E.oR.success("Group updated successfully!"))}catch(e){console.error("Error updating group:",e),E.oR.error("Failed to update group. Please try again.")}},eq=async()=>{await Y(),N(!1)},eL=async e=>{let s=ed.get(e);if(!(null==s?void 0:s.id))return void E.oR.error("No group configuration found for this provider");try{let e=await o.zQ.refreshModels({provider_id:s.id});E.oR.info(e.message),await Y(),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})}catch(t){console.error("Error refreshing provider models:",t);let s=t instanceof Error?t.message:"Unknown error";E.oR.error("Failed to refresh ".concat(e," models: ").concat(s))}},eY=e=>{switch(e.toLowerCase()){case"text":default:return(0,a.jsx)(eC.A,{className:"h-4 w-4"});case"embedding":return(0,a.jsx)(eM.A,{className:"h-4 w-4"});case"image":return(0,a.jsx)(K.A,{className:"h-4 w-4"})}},eU=e=>{switch(e.toLowerCase()){case"text":return"bg-blue-100 text-blue-800";case"embedding":return"bg-purple-100 text-purple-800";case"image":return"bg-green-100 text-green-800";case"audio":return"bg-orange-100 text-orange-800";case"multimodal":return"bg-pink-100 text-pink-800";default:return"bg-gray-100 text-gray-800"}},eO=e=>{let s=new Set(w);s.has(e)?s.delete(e):s.add(e),_(s)},eJ=e=>{let s=(d&&d.length>0?d:P.length>0?P:V).filter(s=>s.provider===e).map(e=>e.id),t=new Set(w);s.forEach(e=>t.add(e)),_(t)},eQ=e=>{let s=ed.get(e);(null==s?void 0:s.id)&&es.mutate(s.id)},eK=async e=>{let s=U.find(s=>s.id===e);if(!s)return void E.oR.error("Model not found");if(!s.provider_id)return void E.oR.error("Provider ID not available for this model");try{let e=parseInt(s.provider_id);await o.zQ.deleteProviderModel(e,s.full_name),E.oR.success("Model override deleted successfully"),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})}catch(s){let e=s instanceof Error?s.message:"Unknown error";E.oR.error("Failed to delete model override: ".concat(e))}},eD=async e=>{let s=U.find(s=>s.id===e);if(!s)return void E.oR.error("Model not found");if(!s.provider_id)return void E.oR.error("Provider ID not available for this model");try{let e=parseInt(s.provider_id);try{let t=await o.zQ.getProviderModel(e,s.full_name);await o.zQ.updateProviderModel(e,s.full_name,{...t,enabled:!1}),E.oR.success("Model disabled successfully")}catch(a){var t;if((null==(t=a.message)?void 0:t.includes("404"))||404===a.status){let t={id:s.full_name,name:s.name,description:s.description||"",created:Math.floor(Date.now()/1e3),context_length:s.contextLength||4096,architecture:{modality:s.modelType||"text",input_modalities:[s.modelType||"text"],output_modalities:[s.modelType||"text"],tokenizer:"",instruct_type:null},pricing:{prompt:s.input_cost,completion:s.output_cost,request:0,image:0,web_search:0,internal_reasoning:0},per_request_limits:null,top_provider:null,upstream_provider_id:e,enabled:!1};await o.zQ.createProviderModel(e,t),E.oR.success("Model disabled successfully")}else throw a}R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})}catch(s){let e=s instanceof Error?s.message:"Unknown error";E.oR.error("Failed to disable model: ".concat(e))}};return z?(0,a.jsxs)("div",{className:"grid gap-4",children:[(0,a.jsx)(eo.E,{className:"h-[200px]"}),(0,a.jsx)(eo.E,{className:"h-[200px]"})]}):L?(0,a.jsx)("div",{className:"rounded-lg border border-red-200 bg-red-50 p-4",children:(0,a.jsx)("p",{className:"text-sm text-red-800",children:"Error loading models. Please try again later."})}):(0,a.jsxs)("div",{className:"grid gap-6",children:[(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,a.jsxs)(h.$,{onClick:()=>{_(new Set((d&&d.length>0?d:P.length>0?P:V).map(e=>e.id)))},children:[(0,a.jsx)(eA.A,{className:"mr-2 h-4 w-4"}),"Select All Models"]}),(0,a.jsxs)(h.$,{onClick:()=>{_(new Set)},children:[(0,a.jsx)(eS.A,{className:"mr-2 h-4 w-4"}),"Deselect All"]}),(0,a.jsxs)(h.$,{onClick:()=>{A(!0)},className:"text-destructive focus:text-destructive",children:[(0,a.jsx)(D.A,{className:"mr-2 h-4 w-4"}),"Delete All Models Permanently"]}),w.size>0&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"bg-border h-6 w-px"}),(0,a.jsxs)("span",{className:"text-muted-foreground text-sm",children:[w.size," selected"]}),(()=>{let e=(d&&d.length>0?d:P.length>0?P:V).filter(e=>w.has(e.id)&&e.soft_deleted);return e.length>0&&(0,a.jsxs)(h.$,{onClick:()=>ea.mutate(e.map(e=>e.id)),variant:"outline",size:"sm",className:"gap-2 border-green-300 text-green-600 hover:border-green-400 hover:text-green-700",disabled:ea.isPending,children:[(0,a.jsx)(Z.A,{className:"h-4 w-4"}),"Enable Selected (",e.length,")"]})})(),(0,a.jsxs)(h.$,{onClick:()=>{C(!0)},variant:"destructive",size:"sm",className:"gap-2",disabled:B.isPending,children:[(0,a.jsx)(eF.A,{className:"h-4 w-4"}),"Delete Selected Overrides"]}),(0,a.jsxs)(h.$,{onClick:()=>{W.mutate(Array.from(w))},variant:"outline",size:"sm",className:"gap-2 border-orange-300 text-orange-600 hover:border-orange-400 hover:text-orange-700",disabled:W.isPending,children:[(0,a.jsx)(eP.A,{className:"h-4 w-4"}),"Disable Selected"]})]})]}),Object.entries(er).map(e=>{let[t,r]=e;if(s&&t!==s)return null;let l=ed.get(t),i=r.every(e=>w.has(e.id)),n=r.some(e=>w.has(e.id));return(0,a.jsxs)(en.Zp,{className:"overflow-hidden",children:[!s&&(0,a.jsx)(en.aR,{className:"pb-3",children:(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"flex items-center gap-3",children:[(0,a.jsx)(ee,{checked:i,ref:e=>{e&&"indeterminate"in e&&(e.indeterminate=n&&!i)},onCheckedChange:e=>{if(e)eJ(t);else{let e=r.map(e=>e.id),s=new Set(w);e.forEach(e=>s.delete(e)),_(s)}}}),(0,a.jsxs)("div",{children:[(0,a.jsxs)(en.ZB,{className:"flex items-center gap-2 text-lg",children:[(0,a.jsx)(J.A,{className:"h-5 w-5"}),t,(0,a.jsxs)("span",{className:"text-muted-foreground text-sm font-normal",children:["(",r.length," models)"]})]}),(0,a.jsxs)(en.BT,{children:[(null==l?void 0:l.group_url)?(0,a.jsxs)("span",{className:"flex items-center gap-1",children:[(0,a.jsx)(K.A,{className:"h-3 w-3"}),l.group_url]}):"Using default endpoint",(null==l?void 0:l.group_api_key)&&(0,a.jsxs)("span",{className:"ml-2 flex items-center gap-1",children:[(0,a.jsx)(Q.A,{className:"h-3 w-3"}),"Group API Key"]})]})]})]}),(0,a.jsx)("div",{className:"flex items-center gap-2",children:(0,a.jsxs)(eb,{children:[(0,a.jsx)(eN,{asChild:!0,children:(0,a.jsx)(h.$,{variant:"ghost",size:"sm",children:(0,a.jsx)(eR.A,{className:"h-4 w-4"})})}),(0,a.jsxs)(ew,{align:"end",children:[(0,a.jsxs)(e_,{onClick:()=>{l&&f({provider:t,models:r,groupData:l})},children:[(0,a.jsx)(q.A,{className:"mr-2 h-4 w-4"}),"Edit Group"]}),(0,a.jsxs)(e_,{onClick:()=>eJ(t),children:[(0,a.jsx)(eA.A,{className:"mr-2 h-4 w-4"}),"Select All"]}),(0,a.jsxs)(e_,{onClick:()=>eL(t),children:[(0,a.jsx)(eT.A,{className:"mr-2 h-4 w-4"}),"Refresh Models"]}),(0,a.jsx)(ek,{}),(0,a.jsxs)(e_,{onClick:()=>eQ(t),className:"text-destructive focus:text-destructive",children:[(0,a.jsx)(eF.A,{className:"mr-2 h-4 w-4"}),"Delete All Models Permanently"]})]})]})})]})}),(0,a.jsx)(en.Wu,{className:s?"pt-6":"pt-0",children:(0,a.jsx)("div",{className:"grid gap-3 md:grid-cols-2 lg:grid-cols-3",children:r.map(e=>(0,a.jsxs)(en.Zp,{className:(0,b.cn)("relative cursor-pointer overflow-hidden transition-all duration-200 hover:shadow-md",w.has(e.id)&&"ring-primary ring-2",c===e.id&&"ring-2 ring-blue-500",e.soft_deleted&&"border-red-200 bg-red-50 opacity-75"),onMouseEnter:()=>m(e.id),onMouseLeave:()=>m(null),children:[(0,a.jsx)(en.aR,{className:"pb-2",children:(0,a.jsxs)("div",{className:"flex items-start gap-2 pr-10",children:[(0,a.jsx)(ee,{checked:w.has(e.id),onCheckedChange:()=>eO(e.id),onClick:e=>e.stopPropagation(),className:"mt-1 flex-shrink-0"}),(0,a.jsxs)("div",{className:"flex w-[calc(100%-3rem)] items-start gap-2 overflow-hidden",children:[(0,a.jsx)("div",{className:"mt-1 flex-shrink-0",children:eY(e.modelType)}),(0,a.jsxs)("div",{className:"w-full overflow-hidden",children:[(0,a.jsx)("h3",{className:(0,b.cn)("overflow-hidden text-sm font-medium text-ellipsis whitespace-nowrap",e.soft_deleted&&"text-red-600 line-through"),children:e.name}),e.full_name!==e.name&&(0,a.jsx)("p",{className:"text-muted-foreground overflow-hidden text-xs text-ellipsis whitespace-nowrap",children:e.full_name})]})]}),(0,a.jsx)("div",{className:"absolute top-3 right-2",children:(0,a.jsxs)(eb,{children:[(0,a.jsx)(eN,{asChild:!0,children:(0,a.jsx)(h.$,{variant:"ghost",size:"sm",onClick:e=>e.stopPropagation(),className:"h-8 w-8 p-0",children:(0,a.jsx)(eR.A,{className:"h-4 w-4"})})}),(0,a.jsxs)(ew,{align:"end",children:[(0,a.jsxs)(e_,{onClick:s=>{s.stopPropagation(),v(e)},children:[(0,a.jsx)(q.A,{className:"mr-2 h-4 w-4"}),"Edit Model"]}),(0,a.jsx)(ek,{}),e.soft_deleted?(0,a.jsxs)(e_,{onClick:s=>{s.stopPropagation(),et.mutate(e.id)},className:"text-green-600 focus:text-green-700",children:[(0,a.jsx)(Z.A,{className:"mr-2 h-4 w-4"}),"Enable Model"]}):(0,a.jsxs)(e_,{onClick:s=>{s.stopPropagation(),eD(e.id)},className:"text-orange-600 focus:text-orange-700",children:[(0,a.jsx)(eP.A,{className:"mr-2 h-4 w-4"}),"Disable Model"]}),(0,a.jsxs)(e_,{onClick:s=>{s.stopPropagation(),eK(e.id)},className:"text-destructive focus:text-destructive",children:[(0,a.jsx)(eF.A,{className:"mr-2 h-4 w-4"}),"Delete"]})]})]})})]})}),(0,a.jsxs)(en.Wu,{className:"space-y-2 pt-0",onClick:()=>u(e.id),children:[(0,a.jsxs)("div",{className:"flex flex-wrap gap-1",children:[(0,a.jsx)("span",{className:(0,b.cn)("inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-medium",eU(e.modelType)),children:e.modelType}),"remote"===e.api_key_type&&(0,a.jsx)("span",{className:"inline-flex items-center rounded-full border border-blue-200 bg-blue-100 px-2.5 py-0.5 text-xs font-medium text-blue-800",children:"Remote"}),"remote"!==e.api_key_type&&(0,a.jsx)("span",{className:"inline-flex items-center rounded-full border border-emerald-200 bg-emerald-100 px-2.5 py-0.5 text-xs font-medium text-emerald-800",children:"Database"}),e.is_free&&(0,a.jsx)("span",{className:"inline-flex items-center rounded-full bg-yellow-100 px-2.5 py-0.5 text-xs font-medium text-yellow-800",children:"Free"}),!em(e)&&(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full bg-red-100 px-2.5 py-0.5 text-xs font-medium text-red-800",children:[(0,a.jsx)(Q.A,{className:"mr-1 h-3 w-3"}),"No API Key"]}),em(e)&&!ey(e)&&(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full bg-green-100 px-2.5 py-0.5 text-xs font-medium text-green-800",children:[(0,a.jsx)(J.A,{className:"mr-1 h-3 w-3"}),"Group Key"]}),ey(e)&&(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full bg-purple-100 px-2.5 py-0.5 text-xs font-medium text-purple-800",children:[(0,a.jsx)(Q.A,{className:"mr-1 h-3 w-3"}),"Individual Key"]}),e.soft_deleted&&(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full border border-red-300 bg-red-100 px-2.5 py-0.5 text-xs font-medium text-red-800",children:[(0,a.jsx)(eF.A,{className:"mr-1 h-3 w-3"}),"Deleted"]})]}),!e.is_free&&(0,a.jsxs)("div",{className:"text-muted-foreground space-y-1 text-xs",children:[(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{className:"truncate",children:"Input:"}),(0,a.jsxs)("span",{className:"ml-2 truncate",children:[ei(e.input_cost),"/1M tokens"]})]}),(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{className:"truncate",children:"Output:"}),(0,a.jsxs)("span",{className:"ml-2 truncate",children:[ei(e.output_cost),"/1M tokens"]})]})]}),e.description&&(0,a.jsx)("p",{className:"text-muted-foreground line-clamp-2 overflow-hidden text-xs break-words text-ellipsis",children:e.description})]})]},e.id))})})]},t)}),(0,a.jsx)(I,{isOpen:p,onModelAdd:ez,onCancel:()=>x(!1)}),g&&(0,a.jsx)(O,{model:g,providerId:g.provider_id?parseInt(g.provider_id):void 0,onModelUpdate:eE,onCancel:()=>v(null),isOpen:!!g}),j&&(0,a.jsx)($,{provider:j.provider,models:j.models,groupSettings:{group_api_key:j.groupData.group_api_key,group_url:j.groupData.group_url},onGroupUpdate:eI,onCancel:()=>f(null),isOpen:!!j}),(0,a.jsx)(el,{isOpen:y,onClose:()=>N(!1),onSuccess:eq}),(0,a.jsx)(ec,{open:k,onOpenChange:C,children:(0,a.jsxs)(ep,{children:[(0,a.jsxs)(ex,{children:[(0,a.jsx)(eg,{children:"Permanently Delete Selected Models"}),(0,a.jsxs)(ev,{children:["Are you sure you want to permanently delete ",w.size," ","selected models? This will completely remove them from the database and cannot be undone."]})]}),(0,a.jsxs)(eh,{children:[(0,a.jsx)(ef,{children:"Cancel"}),(0,a.jsx)(ej,{onClick:()=>{B.mutate(Array.from(w)),C(!1)},className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:"Delete Models"})]})]})}),(0,a.jsx)(ec,{open:S,onOpenChange:F,children:(0,a.jsxs)(ep,{children:[(0,a.jsxs)(ex,{children:[(0,a.jsxs)(eg,{children:["Apply Group Settings to"," ",w.size===P.length&&s?"All Models in ".concat(s):"Selected Models"]}),(0,a.jsxs)(ev,{children:[w.size===P.length&&s?(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{children:["Are you sure you want to force ALL ",w.size," ","models in the ",(0,a.jsx)("strong",{children:s})," group to use group settings?"]}),(0,a.jsx)("p",{className:"mt-2 text-sm text-amber-600",children:(0,a.jsx)("strong",{children:"⚠️ This will override individual model configurations:"})})]}):(0,a.jsxs)("p",{children:["Are you sure you want to apply the group settings to"," ",w.size," selected models?"]}),(0,a.jsxs)("ul",{className:"mt-2 list-inside list-disc space-y-1 text-sm",children:[(0,a.jsx)("li",{children:"Remove individual API keys (models will use the group API key)"}),(null==t?void 0:t.group_url)&&(0,a.jsxs)("li",{children:["Set the URL to:"," ",(0,a.jsx)("code",{className:"rounded bg-gray-100 px-1",children:t.group_url})]}),(0,a.jsx)("li",{children:"Force models to use group configurations"}),w.size===P.length&&s&&(0,a.jsx)("li",{className:"font-medium text-amber-600",children:"This will affect ALL models in this provider group"})]})]})]}),(0,a.jsxs)(eh,{children:[(0,a.jsx)(ef,{children:"Cancel"}),(0,a.jsx)(ej,{onClick:()=>{H.mutate(Array.from(w)),F(!1)},className:"bg-blue-600 text-white hover:bg-blue-700",children:w.size===P.length&&s?"Force All ".concat(w.size," Models"):"Apply Group Settings"})]})]})}),(0,a.jsx)(ec,{open:M,onOpenChange:A,children:(0,a.jsxs)(ep,{children:[(0,a.jsxs)(ex,{children:[(0,a.jsx)(eg,{children:"Permanently Delete All Models"}),(0,a.jsxs)(ev,{children:["Are you sure you want to permanently delete ALL models? This will completely remove all ",U.length," models from the database. This action cannot be undone."]})]}),(0,a.jsxs)(eh,{children:[(0,a.jsx)(ef,{children:"Cancel"}),(0,a.jsx)(ej,{onClick:()=>{X.mutate(),A(!1)},className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:"Delete All Models"})]})]})})]})}var eE=t(7916);u.Ik({id:u.Yj(),created_at:u.Yj(),updated_at:u.Yj(),provider:u.Yj(),group_api_key:u.Yj().optional(),group_url:u.Yj().optional()}),u.Ik({provider:u.Yj(),group_api_key:u.Yj().optional(),group_url:u.Yj().optional()}),u.Ik({provider:u.Yj().optional(),group_api_key:u.Yj().optional(),group_url:u.Yj().optional()}),u.Ik({base_endpoint:u.Yj(),api_key:u.Yj().optional(),provider_name:u.Yj(),default_input_cost:u.ai(),default_output_cost:u.ai(),default_min_cost:u.ai()}),u.Ik({collected_count:u.ai(),skipped_count:u.ai(),models:u.YO(u.bz()),errors:u.YO(u.Yj())}),u.Ik({provider_id:u.Yj()}),u.Ik({refreshed_count:u.ai(),created_count:u.ai(),restored_count:u.ai(),deleted_count:u.ai(),errors:u.YO(u.Yj())}),u.Ik({total_refreshed_count:u.ai(),total_created_count:u.ai(),total_restored_count:u.ai(),total_deleted_count:u.ai(),provider_results:u.YO(u.Ik({provider_name:u.Yj(),refreshed_count:u.ai(),created_count:u.ai(),restored_count:u.ai(),deleted_count:u.ai(),errors:u.YO(u.Yj())})),errors:u.YO(u.Yj())});let eI=u.Ik({id:u.Yj(),canonical_slug:u.Yj().optional(),hugging_face_id:u.Yj().optional(),name:u.Yj().optional(),created:u.ai(),description:u.Yj().optional(),context_length:u.ai().optional(),architecture:u.bz().optional(),pricing:u.bz().optional(),top_provider:u.bz().optional(),per_request_limits:u.bz().optional(),supported_parameters:u.YO(u.Yj()).optional(),provider_url:u.Yj(),provider_name:u.Yj().optional(),group_id:u.Yj().optional()});function eq(e,s){var t,a;return{id:e.id,name:e.name,full_name:e.full_name,description:e.description,modelType:e.model_type||"text",isEnabled:!e.soft_deleted,createdAt:e.created_at,updatedAt:e.updated_at,provider:e.provider||s||"",url:e.url,api_key:e.api_key,input_cost:Number(e.input_cost),output_cost:Number(e.output_cost),min_cost_per_request:Number(e.min_cost_per_request||"0"),min_cash_per_request:Number(e.min_cash_per_request||"0"),contextLength:e.context_length,apiKeyRequired:!0,provider_id:e.provider_id,is_free:null!=(t=e.is_free)&&t,soft_deleted:null!=(a=e.soft_deleted)&&a,has_own_api_key:e.has_own_api_key,api_key_type:e.api_key_type}}u.Ik({object:u.Yj(),data:u.YO(eI)}),u.Ik({id:u.Yj(),created_at:u.Yj(),updated_at:u.Yj(),full_name:u.Yj(),name:u.Yj(),url:u.Yj(),input_cost:u.Yj(),output_cost:u.Yj(),api_key:u.Yj().optional(),min_cash_per_request:u.Yj(),min_cost_per_request:u.Yj().optional(),provider_id:u.Yj().optional(),provider:u.Yj().optional(),soft_deleted:u.zM().optional(),architecture:u.bz().optional(),model_type:u.Yj().optional(),description:u.Yj().optional(),context_length:u.ai().optional(),is_free:u.zM().optional(),has_own_api_key:u.zM(),api_key_type:u.Yj()});class eL{static async createModelGroup(e){return await eE.apiClient.post("/api/model-groups",{provider:e.provider,group_api_key:e.group_api_key,group_url:e.group_url})}static async getModelGroups(){return await eE.apiClient.get("/api/model-groups")}static async getModelGroup(e){return await eE.apiClient.get("/api/model-groups/".concat(e))}static async updateModelGroup(e,s){return await eE.apiClient.put("/api/model-groups/".concat(e),{provider:s.provider,group_api_key:s.group_api_key,group_url:s.group_url})}static async deleteModelGroup(e){return await eE.apiClient.delete("/api/model-groups/".concat(e))}static async createModel(e){let s={full_name:e.name,name:e.name,url:e.url,api_key:e.api_key,input_cost:e.input_cost,output_cost:e.output_cost,min_cost_per_request:e.min_cost_per_request,min_cash_per_request:e.min_cash_per_request,provider:e.provider,model_type:e.modelType,description:e.description,context_length:e.contextLength,is_free:e.is_free};return eq(await eE.apiClient.post("/api/models",s))}static async getModels(){return(await eE.apiClient.get("/api/models")).map(e=>eq(e))}static async getModel(e){return eq(await eE.apiClient.get("/api/models/".concat(e)))}static async getModelsByProvider(e){return(await eE.apiClient.get("/api/models/provider/".concat(e))).map(e=>eq(e))}static async updateModel(e,s){let t={name:s.name,url:s.url,api_key:s.api_key,input_cost:s.input_cost,output_cost:s.output_cost,min_cost_per_request:s.min_cost_per_request,min_cash_per_request:s.min_cash_per_request,provider:s.provider,model_type:s.modelType,description:s.description,context_length:s.contextLength,is_free:s.is_free};return eq(await eE.apiClient.put("/api/models/".concat(e),t))}static async deleteModel(e){return await eE.apiClient.delete("/api/models/".concat(e))}static async softDeleteModel(e){return await eE.apiClient.put("/api/models/".concat(e,"/soft-delete"),{})}static async deleteModels(e){return await eE.apiClient.post("/api/models/bulk/delete",{model_ids:e})}static async softDeleteModels(e){return await eE.apiClient.post("/api/models/bulk/soft-delete",{model_ids:e})}static async bulkUpdateModels(e,s){return await eE.apiClient.post("/api/models/bulk/update",{model_ids:e,api_key:s.api_key,url:s.url})}static async deleteAllModels(){return await eE.apiClient.post("/api/models/all/delete",{})}static async deleteModelsByProvider(e){return await eE.apiClient.post("/api/models/provider/".concat(e,"/delete"),{})}static async restoreModels(e){return await eE.apiClient.post("/api/models/bulk/restore",{model_ids:e})}static async getSoftDeletedModels(){return(await eE.apiClient.get("/api/models/deleted")).map(e=>eq(e))}static async collectModels(e){return await eE.apiClient.post("/api/models/collect",e)}static async getModelsWithProviders(){let[e,s]=await Promise.all([eE.apiClient.get("/api/models"),this.getModelGroups()]),t=new Map(s.map(e=>[e.id,e.provider]));return{models:e.map(e=>eq(e,t.get(e.provider_id||"")||"Unknown")),groups:s}}static async listModels(e){let{models:s}=await this.getModelsWithProviders();return(null==e?void 0:e.enabled)!==!1?s.filter(e=>e.isEnabled):s}static async getModelInfo(e){return await this.getModel(e)}static async refreshModels(e){return await eE.apiClient.post("/api/models/refresh",e)}static async refreshAllModels(){return await eE.apiClient.post("/api/models/refresh-all",{})}static async getEnhancedModels(){return await eE.apiClient.get("/api/enhanced-models")}static async getEnhancedModelsByProvider(e){return await eE.apiClient.get("/api/enhanced-models/".concat(encodeURIComponent(e)))}static downloadModelsAsJson(e){let s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"models.json",t=new Blob([JSON.stringify(e,null,2)],{type:"application/json"}),a=URL.createObjectURL(t),r=document.createElement("a");r.href=a,r.download=s,r.click(),URL.revokeObjectURL(a)}static async downloadAllEnhancedModels(){try{let e=await this.getEnhancedModels();this.downloadModelsAsJson(e,"enhanced-models-all.json")}catch(e){throw console.error("Error downloading all enhanced models:",e),e}}static async downloadEnhancedModelsByProvider(e){try{let s=await this.getEnhancedModelsByProvider(e);this.downloadModelsAsJson(s,"enhanced-models-".concat(e.toLowerCase(),".json"))}catch(s){throw console.error("Error downloading enhanced models for provider ".concat(e,":"),s),s}}static async testModel(e,s,t){return await eE.apiClient.post("/api/models/test",{model_id:e,endpoint_type:s,request_data:t})}}var eY=t(2390),eU=t(4717);function eO(e){var s,t;let{models:l}=e,[o,d]=(0,r.useState)(""),[c,u]=(0,r.useState)("You are a helpful assistant. Please respond concisely."),[m,p]=(0,r.useState)("Hello! Can you tell me what model you are and confirm that you are working correctly?"),[x,g]=(0,r.useState)(150),[j,y]=(0,r.useState)(.7),[b,w]=(0,r.useState)(null),[_,k]=(0,r.useState)(null),{data:C=[]}=(0,i.I)({queryKey:["model-groups"],queryFn:()=>eL.getModelGroups(),refetchOnWindowFocus:!1}),M=l.find(e=>e.id===o),A=(0,n.n)({mutationFn:async e=>{if(!M)throw Error("No model selected");k(null),w(null);try{console.log("Testing model via proxy: ".concat(M.name)),console.log("Request payload:",e);let s=await eL.testModel(M.id,"chat-completions",e);if(!s.success)throw Error(s.error||"Test failed");return s.data}catch(e){throw console.error("Model test error via proxy:",e),Error(e instanceof Error?e.message:"Failed to test model via proxy")}},onSuccess:e=>{w(e),E.oR.success("Model test completed successfully!")},onError:e=>{let s=(null==e?void 0:e.message)||"Unknown error occurred";k(s),E.oR.error("Model test failed: ".concat(s))}}),S=async()=>{if(!M)return void E.oR.error("Please select a model to test");if(!m.trim())return void E.oR.error("Please enter a test message");let e=[];c.trim()&&e.push({role:"system",content:c.trim()}),e.push({role:"user",content:m.trim()});let s={model:M.name,messages:e,max_tokens:x,temperature:j};A.mutate(s)},F=l.filter(e=>e.isEnabled),P=M?(e=>{let s=C.find(s=>s.provider===e.provider),t=e.api_key||(null==s?void 0:s.group_api_key),a=e.url;return e.url.startsWith("/")&&(null==s?void 0:s.group_url)&&(a="".concat(s.group_url.replace(/\/$/,"")).concat(e.url)),"text"!==e.modelType||a.includes("/chat/completions")||(a=a.replace(/\/$/,"")+"/chat/completions"),{apiKey:t,endpointUrl:a,group:s}})(M):null;return(0,a.jsxs)(en.Zp,{className:"w-full",children:[(0,a.jsxs)(en.aR,{children:[(0,a.jsxs)(en.ZB,{className:"flex items-center gap-2",children:[(0,a.jsx)(eY.A,{className:"h-5 w-5"}),"Model Credential Tester"]}),(0,a.jsx)(en.BT,{children:"Test model functionality by sending chat completion requests through the secure proxy (resolves CORS and network issues)"})]}),(0,a.jsxs)(en.Wu,{className:"space-y-6",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"model-select",children:"Select Model"}),(0,a.jsxs)(f.l6,{value:o,onValueChange:d,children:[(0,a.jsx)(f.bq,{id:"model-select",children:(0,a.jsx)(f.yv,{placeholder:"Choose a model to test..."})}),(0,a.jsx)(f.gC,{children:F.map(e=>(0,a.jsx)(f.eb,{value:e.id,children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{children:e.name}),(0,a.jsx)(er.E,{variant:"outline",className:"text-xs",children:e.provider}),e.is_free&&(0,a.jsx)(er.E,{variant:"secondary",className:"text-xs",children:"Free"})]})},e.id))})]}),M&&P&&(0,a.jsxs)("div",{className:"text-muted-foreground bg-muted space-y-2 rounded-md p-3 text-sm",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(K.A,{className:"h-4 w-4"}),(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Endpoint:"})," ",P.endpointUrl]})]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(Q.A,{className:"h-4 w-4"}),(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"API Key:"})," ",P.apiKey?"".concat(P.apiKey.substring(0,8),"..."):"Not configured"]}),(0,a.jsx)(er.E,{variant:P.apiKey?"default":"destructive",className:"text-xs",children:M.api_key_type||"Unknown"})]}),(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Provider:"})," ",M.provider]})}),(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Type:"})," ",M.modelType]})}),M.contextLength&&(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Context Length:"})," ",M.contextLength.toLocaleString()]})}),!P.apiKey&&(0,a.jsxs)(V.Fc,{variant:"default",className:"mt-2",children:[(0,a.jsx)(G.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"No API key configured for this model. Testing may still work if the model is free or if authentication is handled elsewhere. For models requiring authentication, please add an API key to the model or its provider group."})]})]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"max-tokens",children:"Max Tokens"}),(0,a.jsx)("input",{id:"max-tokens",type:"number",min:1,max:4e3,value:x,onChange:e=>g(parseInt(e.target.value)||150),className:"border-input bg-background w-full rounded-md border px-3 py-2 text-sm"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"temperature",children:"Temperature"}),(0,a.jsx)("input",{id:"temperature",type:"number",min:0,max:2,step:.1,value:j,onChange:e=>y(parseFloat(e.target.value)||.7),className:"border-input bg-background w-full rounded-md border px-3 py-2 text-sm"})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"system-message",children:"System Message (Optional)"}),(0,a.jsx)(v.T,{id:"system-message",placeholder:"Enter system message...",value:c,onChange:e=>u(e.target.value),rows:2})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"user-message",children:"Test Message"}),(0,a.jsx)(v.T,{id:"user-message",placeholder:"Enter your test message...",value:m,onChange:e=>p(e.target.value),rows:3})]}),(0,a.jsx)(h.$,{onClick:S,disabled:!o||A.isPending,className:"w-full",children:A.isPending?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Testing Model..."]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(eY.A,{className:"mr-2 h-4 w-4"}),"Test Model (via Proxy)"]})}),_&&(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(eU.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Test Failed:"})," ",_]})]}),b&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(Z.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Test Successful!"})," Model responded correctly via secure proxy."]})]}),b&&(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Model Response"}),(0,a.jsx)("div",{className:"bg-muted rounded-md p-4",children:(0,a.jsx)("p",{className:"text-sm whitespace-pre-wrap",children:(null==(t=b.choices[0])||null==(s=t.message)?void 0:s.content)||"No content in response"})})]}),b.usage&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Usage Statistics"}),(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-4 text-sm",children:[(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:b.usage.prompt_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Prompt Tokens"})]}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:b.usage.completion_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Completion Tokens"})]}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:b.usage.total_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Total Tokens"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Raw Response"}),(0,a.jsxs)("details",{className:"group",children:[(0,a.jsxs)("summary",{className:"text-muted-foreground hover:text-foreground cursor-pointer text-sm",children:[(0,a.jsx)(G.A,{className:"mr-1 inline h-4 w-4"}),"Show detailed response data"]}),(0,a.jsx)("pre",{className:"bg-muted mt-2 max-h-60 overflow-auto rounded-md p-4 text-xs",children:JSON.stringify(b,null,2)})]})]})]})]})]})}var eJ=t(4938),eQ=t(7137),eK=t(9472),eD=t(413),eG=t(9911),eV=t(4713),e$=t(9935),eB=t(8019);let eW={"chat-completions":{name:"Chat Completions",path:"/chat/completions",icon:eJ.A,description:"Test conversational AI with chat completion requests"},"vision-chat":{name:"Vision Chat (Image + Text)",path:"/chat/completions",icon:eQ.A,description:"Analyze images with text prompts using vision models"},embeddings:{name:"Embeddings",path:"/embeddings",icon:eK.A,description:"Generate embeddings for text input"},images:{name:"Image Generation",path:"/images/generations",icon:eD.A,description:"Generate images from text prompts"},"audio-speech":{name:"Text-to-Speech",path:"/audio/speech",icon:eG.A,description:"Convert text to speech audio"},"audio-transcription":{name:"Audio Transcription",path:"/audio/transcriptions",icon:eV.A,description:"Transcribe audio files to text"},models:{name:"List Models",path:"/model",icon:eK.A,description:"List all available models from the provider"}},eZ={"chat-completions":{systemMessage:"You are a helpful assistant. Please respond concisely.",userMessage:"Hello! Can you tell me what model you are and confirm that you are working correctly?",maxTokens:150,temperature:.7},"vision-chat":{systemMessage:"You are a helpful assistant that can analyze images. Please describe what you see.",userMessage:"What do you see in this image? Please provide a detailed description.",maxTokens:300,temperature:.7,imageDetail:"auto"},embeddings:{input:"The quick brown fox jumps over the lazy dog.",encoding_format:"float"},images:{prompt:"A beautiful sunset over a mountain landscape",n:1,size:"1024x1024",quality:"standard",style:"vivid"},"audio-speech":{input:"Hello, this is a test of the text-to-speech functionality.",voice:"alloy",response_format:"mp3",speed:1},"audio-transcription":{prompt:"This is a test transcription.",response_format:"json",temperature:0,language:""}};function eH(e){var s,t,l,o,d,c,u,m,p,x,j;let y,b,w,_,k,C,{models:M}=e,[A,S]=(0,r.useState)(""),[F,P]=(0,r.useState)("chat-completions"),[R,T]=(0,r.useState)(null),[I,q]=(0,r.useState)(null),[L,Y]=(0,r.useState)(eZ["chat-completions"].systemMessage),[U,O]=(0,r.useState)(eZ["chat-completions"].userMessage),[J,D]=(0,r.useState)(eZ["chat-completions"].maxTokens),[$,B]=(0,r.useState)(eZ["chat-completions"].temperature),[W,H]=(0,r.useState)(eZ["vision-chat"].systemMessage),[X,ee]=(0,r.useState)(eZ["vision-chat"].userMessage),[es,et]=(0,r.useState)(eZ["vision-chat"].maxTokens),[ea,el]=(0,r.useState)(eZ["vision-chat"].temperature),[ei,eo]=(0,r.useState)(eZ["vision-chat"].imageDetail),[ed,ec]=(0,r.useState)(null),[eu,em]=(0,r.useState)(null),[ep,ex]=(0,r.useState)(!1),[eh,eg]=(0,r.useState)(null),[ev,ej]=(0,r.useState)(null),[ef,ey]=(0,r.useState)(null),[eb,eN]=(0,r.useState)(eZ["audio-transcription"].prompt),[ew,e_]=(0,r.useState)(eZ["audio-transcription"].response_format),[ek,eC]=(0,r.useState)(eZ["audio-transcription"].temperature),[eM,eA]=(0,r.useState)(eZ["audio-transcription"].language),eS=(0,r.useRef)(null),eF=(0,r.useRef)(null),[eP,eR]=(0,r.useState)(eZ.embeddings.input),[eT,ez]=(0,r.useState)(eZ.embeddings.encoding_format),[eE,eI]=(0,r.useState)(eZ.images.prompt),[eq,eO]=(0,r.useState)(eZ.images.n),[eJ,eQ]=(0,r.useState)(eZ.images.size),[eH,eX]=(0,r.useState)(eZ.images.quality),[e0,e2]=(0,r.useState)(eZ.images.style),[e4,e1]=(0,r.useState)(eZ["audio-speech"].input),[e3,e5]=(0,r.useState)(eZ["audio-speech"].voice),[e6,e9]=(0,r.useState)(eZ["audio-speech"].response_format),[e8,e7]=(0,r.useState)(eZ["audio-speech"].speed),{data:se=[]}=(0,i.I)({queryKey:["model-groups"],queryFn:()=>eL.getModelGroups(),refetchOnWindowFocus:!1}),ss=M.find(e=>e.id===A),st=e=>{var s;let t=null==(s=e.target.files)?void 0:s[0];t&&(t.type.startsWith("image/")?(ec(t),em(URL.createObjectURL(t))):E.oR.error("Please select a valid image file"))},sa=e=>{var s;let t=null==(s=e.target.files)?void 0:s[0];t&&(t.type.startsWith("audio/")?(eg(t),ej(URL.createObjectURL(t))):E.oR.error("Please select a valid audio file"))},sr=async()=>{try{let e=await navigator.mediaDevices.getUserMedia({audio:!0}),s=new MediaRecorder(e),t=[];s.ondataavailable=e=>{e.data.size>0&&t.push(e.data)},s.onstop=()=>{let s=new Blob(t,{type:"audio/webm"}),a=new File([s],"recording.webm",{type:"audio/webm"});eg(a);let r=URL.createObjectURL(s);ej(r),e.getTracks().forEach(e=>e.stop())},s.start(),ey(s),ex(!0),E.oR.success("Recording started")}catch(e){console.error("Error starting recording:",e),E.oR.error("Failed to start recording. Please check microphone permissions.")}},sl=()=>{ef&&(ef.stop(),ey(null),ex(!1),E.oR.success("Recording stopped"))},si=e=>new Promise((s,t)=>{let a=new FileReader;a.readAsDataURL(e),a.onload=()=>s(a.result),a.onerror=e=>t(e)}),sn=async()=>{if(!ss)return null;switch(F){case"chat-completions":let e=[];return L.trim()&&e.push({role:"system",content:L.trim()}),e.push({role:"user",content:U.trim()}),{model:ss.name,messages:e,max_tokens:J,temperature:$};case"vision-chat":if(!ed)throw Error("Please select an image for vision analysis");let s=await si(ed),t=[];return W.trim()&&t.push({role:"system",content:W.trim()}),t.push({role:"user",content:[{type:"text",text:X.trim()},{type:"image_url",image_url:{url:s,detail:ei}}]}),{model:ss.name,messages:t,max_tokens:es,temperature:ea};case"embeddings":return{model:ss.name,input:eP,encoding_format:eT};case"images":return{model:ss.name,prompt:eE,n:eq,size:eJ,quality:eH,style:e0};case"audio-speech":return{model:ss.name,input:e4,voice:e3,response_format:e6,speed:e8};case"audio-transcription":if(!eh)throw Error("Please record or upload an audio file for transcription");return{model:ss.name,file:eh,prompt:eb.trim()||void 0,response_format:ew,temperature:ek,language:eM.trim()||void 0};default:return null}},so=(0,n.n)({mutationFn:async e=>{if(!ss)throw Error("No model selected");q(null),T(null);try{console.log("Testing endpoint via proxy: ".concat(F)),console.log("Request payload:",e);let s=await eL.testModel(ss.id,F,e);if(!s.success)throw Error(s.error||"Test failed");return s.data}catch(e){throw console.error("API endpoint test error via proxy:",e),Error(e instanceof Error?e.message:"Failed to test endpoint via proxy")}},onSuccess:e=>{T(e),E.oR.success("".concat(eW[F].name," test completed successfully!"))},onError:e=>{let s=(null==e?void 0:e.message)||"Unknown error occurred";q(s),E.oR.error("".concat(eW[F].name," test failed: ").concat(s))}}),sd=async()=>{if(!ss)return void E.oR.error("Please select a model to test");if("chat-completions"===F&&!U.trim())return void E.oR.error("Please enter a test message");if("vision-chat"===F){if(!X.trim())return void E.oR.error("Please enter a test message");if(!ed)return void E.oR.error("Please select an image for vision analysis")}if("embeddings"===F&&!eP.trim())return void E.oR.error("Please enter text for embedding");if("images"===F&&!eE.trim())return void E.oR.error("Please enter an image prompt");if("audio-speech"===F&&!e4.trim())return void E.oR.error("Please enter text for speech synthesis");if("audio-transcription"===F&&!eh)return void E.oR.error("Please record or upload an audio file for transcription");let e=await sn();so.mutate(e)},sc=M.filter(e=>e.isEnabled),su=ss?(e=>{let s=se.find(s=>s.provider===e.provider),t=e.api_key||(null==s?void 0:s.group_api_key),a=e.url;return e.url.startsWith("/")&&(null==s?void 0:s.group_url)&&(a="".concat(s.group_url.replace(/\/$/,"")).concat(e.url)),{apiKey:t,baseUrl:a=a.replace(/\/v1\/.*$/,"").replace(/\/$/,""),group:s}})(ss):null,sm=su?(k=su.baseUrl,C=eW[F].path,"".concat(k).concat(C)):"";return(0,a.jsxs)(en.Zp,{className:"w-full",children:[(0,a.jsxs)(en.aR,{children:[(0,a.jsxs)(en.ZB,{className:"flex items-center gap-2",children:[(0,a.jsx)(eY.A,{className:"h-5 w-5"}),"API Endpoint Tester"]}),(0,a.jsx)(en.BT,{children:"Comprehensive testing of OpenAI-compatible API endpoints through the secure proxy (resolves CORS and network issues)"})]}),(0,a.jsxs)(en.Wu,{className:"space-y-6",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"model-select",children:"Select Model"}),(0,a.jsxs)(f.l6,{value:A,onValueChange:S,children:[(0,a.jsx)(f.bq,{id:"model-select",children:(0,a.jsx)(f.yv,{placeholder:"Choose a model to test..."})}),(0,a.jsx)(f.gC,{children:sc.map(e=>(0,a.jsx)(f.eb,{value:e.id,children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{children:e.name}),(0,a.jsx)(er.E,{variant:"outline",className:"text-xs",children:e.provider}),e.is_free&&(0,a.jsx)(er.E,{variant:"secondary",className:"text-xs",children:"Free"})]})},e.id))})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"endpoint-select",children:"API Endpoint"}),(0,a.jsxs)(f.l6,{value:F,onValueChange:e=>P(e),children:[(0,a.jsx)(f.bq,{id:"endpoint-select",children:(0,a.jsx)(f.yv,{})}),(0,a.jsx)(f.gC,{children:Object.entries(eW).map(e=>{let[s,t]=e,r=t.icon;return(0,a.jsx)(f.eb,{value:s,children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(r,{className:"h-4 w-4"}),(0,a.jsx)("span",{children:t.name})]})},s)})})]})]})]}),ss&&su&&(0,a.jsxs)("div",{className:"text-muted-foreground bg-muted space-y-2 rounded-md p-3 text-sm",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(K.A,{className:"h-4 w-4"}),(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Endpoint:"})," ",sm]})]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(Q.A,{className:"h-4 w-4"}),(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"API Key:"})," ",su.apiKey?"".concat(su.apiKey.substring(0,8),"..."):"Not configured"]}),(0,a.jsx)(er.E,{variant:su.apiKey?"default":"destructive",className:"text-xs",children:ss.api_key_type||"Unknown"})]}),(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Provider:"})," ",ss.provider]})}),(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Description:"})," ",eW[F].description]})}),!su.apiKey&&(0,a.jsxs)(V.Fc,{variant:"default",className:"mt-2",children:[(0,a.jsx)(G.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"No API key configured for this model. Testing may still work if the model is free or if authentication is handled elsewhere. For models requiring authentication, please add an API key to the model or its provider group."})]})]}),(()=>{switch(F){case"chat-completions":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"max-tokens",children:"Max Tokens"}),(0,a.jsx)(g.p,{id:"max-tokens",type:"number",min:1,max:4e3,value:J,onChange:e=>D(parseInt(e.target.value)||150)})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"temperature",children:"Temperature"}),(0,a.jsx)(g.p,{id:"temperature",type:"number",min:0,max:2,step:.1,value:$,onChange:e=>B(parseFloat(e.target.value)||.7)})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"system-message",children:"System Message (Optional)"}),(0,a.jsx)(v.T,{id:"system-message",placeholder:"Enter system message...",value:L,onChange:e=>Y(e.target.value),rows:2})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"user-message",children:"Test Message"}),(0,a.jsx)(v.T,{id:"user-message",placeholder:"Enter your test message...",value:U,onChange:e=>O(e.target.value),rows:3})]})]});case"vision-chat":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"vision-max-tokens",children:"Max Tokens"}),(0,a.jsx)(g.p,{id:"vision-max-tokens",type:"number",min:1,max:4e3,value:es,onChange:e=>et(parseInt(e.target.value)||300)})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"vision-temperature",children:"Temperature"}),(0,a.jsx)(g.p,{id:"vision-temperature",type:"number",min:0,max:2,step:.1,value:ea,onChange:e=>el(parseFloat(e.target.value)||.7)})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"vision-system-message",children:"System Message (Optional)"}),(0,a.jsx)(v.T,{id:"vision-system-message",placeholder:"Enter system message...",value:W,onChange:e=>H(e.target.value),rows:2})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"vision-user-message",children:"Test Message"}),(0,a.jsx)(v.T,{id:"vision-user-message",placeholder:"Enter your test message...",value:X,onChange:e=>ee(e.target.value),rows:3})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-detail",children:"Image Detail"}),(0,a.jsxs)(f.l6,{value:ei,onValueChange:e=>eo(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"low",children:"Low"}),(0,a.jsx)(f.eb,{value:"high",children:"High"}),(0,a.jsx)(f.eb,{value:"auto",children:"Auto"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-upload",children:"Upload Image (Optional)"}),(0,a.jsx)(g.p,{type:"file",accept:"image/*",onChange:st,ref:eS,className:"file:mr-4 file:rounded-full file:border-0 file:bg-blue-50 file:px-4 file:py-2 file:text-sm file:font-semibold file:text-blue-700 hover:file:bg-blue-100"}),ed&&(0,a.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[(0,a.jsx)(eD.A,{className:"h-5 w-5 text-blue-500"}),(0,a.jsxs)("span",{className:"text-muted-foreground text-sm",children:["Selected image: ",ed.name]}),(0,a.jsx)(h.$,{variant:"outline",size:"sm",onClick:()=>ec(null),className:"ml-auto",children:"Remove"})]}),eu&&(0,a.jsx)("div",{className:"relative mt-2 aspect-square w-32 overflow-hidden rounded-md border",children:(0,a.jsx)(eB.default,{src:eu,alt:"Image preview",fill:!0,className:"object-cover"})})]})]});case"embeddings":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"encoding-format",children:"Encoding Format"}),(0,a.jsxs)(f.l6,{value:eT,onValueChange:e=>ez(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"float",children:"Float"}),(0,a.jsx)(f.eb,{value:"base64",children:"Base64"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"embedding-input",children:"Text Input"}),(0,a.jsx)(v.T,{id:"embedding-input",placeholder:"Enter text to generate embeddings for...",value:eP,onChange:e=>eR(e.target.value),rows:4})]})]});case"images":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2 lg:grid-cols-3",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-count",children:"Number of Images"}),(0,a.jsx)(g.p,{id:"image-count",type:"number",min:1,max:10,value:eq,onChange:e=>eO(parseInt(e.target.value)||1)})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-size",children:"Size"}),(0,a.jsxs)(f.l6,{value:eJ,onValueChange:e=>eQ(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"256x256",children:"256x256"}),(0,a.jsx)(f.eb,{value:"512x512",children:"512x512"}),(0,a.jsx)(f.eb,{value:"1024x1024",children:"1024x1024"}),(0,a.jsx)(f.eb,{value:"1792x1024",children:"1792x1024"}),(0,a.jsx)(f.eb,{value:"1024x1792",children:"1024x1792"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-quality",children:"Quality"}),(0,a.jsxs)(f.l6,{value:eH,onValueChange:e=>eX(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"standard",children:"Standard"}),(0,a.jsx)(f.eb,{value:"hd",children:"HD"})]})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-style",children:"Style"}),(0,a.jsxs)(f.l6,{value:e0,onValueChange:e=>e2(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"vivid",children:"Vivid"}),(0,a.jsx)(f.eb,{value:"natural",children:"Natural"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-prompt",children:"Image Prompt"}),(0,a.jsx)(v.T,{id:"image-prompt",placeholder:"Describe the image you want to generate...",value:eE,onChange:e=>eI(e.target.value),rows:3})]})]});case"audio-speech":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-3",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"speech-voice",children:"Voice"}),(0,a.jsxs)(f.l6,{value:e3,onValueChange:e=>e5(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"alloy",children:"Alloy"}),(0,a.jsx)(f.eb,{value:"echo",children:"Echo"}),(0,a.jsx)(f.eb,{value:"fable",children:"Fable"}),(0,a.jsx)(f.eb,{value:"onyx",children:"Onyx"}),(0,a.jsx)(f.eb,{value:"nova",children:"Nova"}),(0,a.jsx)(f.eb,{value:"shimmer",children:"Shimmer"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"speech-format",children:"Response Format"}),(0,a.jsxs)(f.l6,{value:e6,onValueChange:e=>e9(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"mp3",children:"MP3"}),(0,a.jsx)(f.eb,{value:"opus",children:"Opus"}),(0,a.jsx)(f.eb,{value:"aac",children:"AAC"}),(0,a.jsx)(f.eb,{value:"flac",children:"FLAC"}),(0,a.jsx)(f.eb,{value:"wav",children:"WAV"}),(0,a.jsx)(f.eb,{value:"pcm",children:"PCM"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"speech-speed",children:"Speed"}),(0,a.jsx)(g.p,{id:"speech-speed",type:"number",min:.25,max:4,step:.25,value:e8,onChange:e=>e7(parseFloat(e.target.value)||1)})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"speech-input",children:"Text to Synthesize"}),(0,a.jsx)(v.T,{id:"speech-input",placeholder:"Enter text to convert to speech...",value:e4,onChange:e=>e1(e.target.value),rows:4})]})]});case"audio-transcription":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-prompt",children:"Prompt (Optional)"}),(0,a.jsx)(v.T,{id:"audio-transcription-prompt",placeholder:"Enter a prompt for the transcription...",value:eb,onChange:e=>eN(e.target.value),rows:2})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-temperature",children:"Temperature"}),(0,a.jsx)(g.p,{id:"audio-transcription-temperature",type:"number",min:0,max:1,step:.1,value:ek,onChange:e=>eC(parseFloat(e.target.value)||0)})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-language",children:"Language (Optional)"}),(0,a.jsx)(g.p,{id:"audio-transcription-language",placeholder:"e.g., en-US, fr-FR",value:eM,onChange:e=>eA(e.target.value)})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-response-format",children:"Response Format"}),(0,a.jsxs)(f.l6,{value:ew,onValueChange:e=>e_(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"json",children:"JSON"}),(0,a.jsx)(f.eb,{value:"text",children:"Text"}),(0,a.jsx)(f.eb,{value:"srt",children:"SRT"}),(0,a.jsx)(f.eb,{value:"verbose_json",children:"Verbose JSON"}),(0,a.jsx)(f.eb,{value:"vtt",children:"VTT"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Voice Recording"}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(h.$,{type:"button",variant:ep?"destructive":"default",size:"sm",onClick:ep?sl:sr,className:"flex items-center gap-2",children:ep?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(e$.A,{className:"h-4 w-4"}),"Stop Recording"]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(eG.A,{className:"h-4 w-4"}),"Start Recording"]})}),ep&&(0,a.jsxs)("div",{className:"flex items-center gap-2 text-red-600",children:[(0,a.jsx)("div",{className:"h-2 w-2 animate-pulse rounded-full bg-red-600"}),(0,a.jsx)("span",{className:"text-sm",children:"Recording..."})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-upload",children:"Or Upload Audio File"}),(0,a.jsx)(g.p,{type:"file",accept:"audio/*",onChange:sa,ref:eF,className:"file:mr-4 file:rounded-full file:border-0 file:bg-blue-50 file:px-4 file:py-2 file:text-sm file:font-semibold file:text-blue-700 hover:file:bg-blue-100"}),eh&&(0,a.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[(0,a.jsx)(eV.A,{className:"h-5 w-5 text-blue-500"}),(0,a.jsxs)("span",{className:"text-muted-foreground text-sm",children:["Selected audio: ",eh.name]}),(0,a.jsx)(h.$,{variant:"outline",size:"sm",onClick:()=>{eg(null),ej(null)},className:"ml-auto",children:"Remove"})]}),ev&&(0,a.jsx)("div",{className:"bg-muted mt-2 rounded-md p-4",children:(0,a.jsx)("audio",{controls:!0,src:ev,className:"w-full",children:"Your browser does not support the audio element."})})]})]})]});case"models":return(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(eK.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"This endpoint lists all available models from the provider. No additional parameters are required."})]})});default:return null}})(),(0,a.jsx)(h.$,{onClick:sd,disabled:!A||so.isPending,className:"w-full",children:so.isPending?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Testing ",eW[F].name,"..."]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(eY.A,{className:"mr-2 h-4 w-4"}),"Test ",eW[F].name]})}),I&&(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(eU.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Test Failed:"})," ",I]})]}),R&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(Z.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Test Successful!"})," ",eW[F].name," endpoint responded correctly."]})]}),R&&(R?"type"in(y=R)&&"audio"===y.type?(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Generated Audio"}),(0,a.jsxs)("div",{className:"bg-muted rounded-md p-4",children:[(0,a.jsx)("audio",{controls:!0,src:R.url,className:"w-full",children:"Your browser does not support the audio element."}),(0,a.jsxs)("p",{className:"text-muted-foreground mt-2 text-sm",children:["Audio file size: ",(R.size/1024).toFixed(2)," KB"]})]})]})}):"text"in R?(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Transcription Result"}),(0,a.jsx)("div",{className:"bg-muted rounded-md p-4",children:(0,a.jsx)("p",{className:"text-sm whitespace-pre-wrap",children:R.text||"No transcription result available"})})]})}):"choices"in R?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Model Response"}),(0,a.jsx)("div",{className:"bg-muted rounded-md p-4",children:(0,a.jsx)("p",{className:"text-sm whitespace-pre-wrap",children:(null==(l=R.choices)||null==(t=l[0])||null==(s=t.message)?void 0:s.content)||"No content in response"})})]}),R.usage&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Usage Statistics"}),(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-4 text-sm",children:[(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:R.usage.prompt_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Prompt Tokens"})]}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:R.usage.completion_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Completion Tokens"})]}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:R.usage.total_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Total Tokens"})]})]})]})]}):"data"in(b=R)&&Array.isArray(b.data)&&b.data.length>0&&"embedding"in b.data[0]?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Embedding Vector"}),(0,a.jsxs)("div",{className:"bg-muted rounded-md p-4",children:[(0,a.jsxs)("p",{className:"text-muted-foreground mb-2 text-sm",children:["Generated ",(null==(c=R.data)||null==(d=c[0])||null==(o=d.embedding)?void 0:o.length)||0," ","dimensional embedding vector"]}),(0,a.jsxs)("details",{className:"group",children:[(0,a.jsx)("summary",{className:"hover:text-foreground cursor-pointer text-sm",children:"Show first 10 values"}),(0,a.jsxs)("pre",{className:"mt-2 text-xs",children:[JSON.stringify(null==(p=R.data)||null==(m=p[0])||null==(u=m.embedding)?void 0:u.slice(0,10),null,2),"..."]})]})]})]}),R.usage&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Usage Statistics"}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center text-sm",children:[(0,a.jsx)("div",{className:"font-semibold",children:R.usage.total_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Total Tokens"})]})]})]}):"data"in(w=R)&&Array.isArray(w.data)&&w.data.length>0&&"url"in w.data[0]?(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Generated Images"}),(0,a.jsx)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:null==(x=R.data)?void 0:x.map((e,s)=>(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("div",{className:"relative aspect-square w-full",children:(0,a.jsx)(eB.default,{src:e.url,alt:"Generated image ".concat(s+1),fill:!0,className:"rounded-md border object-cover",unoptimized:!0})}),e.revised_prompt&&(0,a.jsxs)("p",{className:"text-muted-foreground text-xs",children:["Revised prompt: ",e.revised_prompt]})]},s))})]})}):"data"in(_=R)&&Array.isArray(_.data)&&_.data.length>0&&"id"in _.data[0]?(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Available Models"}),(0,a.jsx)("div",{className:"max-h-60 overflow-auto",children:(0,a.jsx)("div",{className:"grid gap-2",children:null==(j=R.data)?void 0:j.map(e=>(0,a.jsxs)("div",{className:"bg-muted rounded-md p-3",children:[(0,a.jsx)("div",{className:"font-medium",children:e.id}),e.object&&(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Type: ",e.object]}),e.created&&(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Created:"," ",new Date(1e3*e.created).toLocaleDateString()]})]},e.id))})})]})}):null:null),R&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Raw Response"}),(0,a.jsxs)("details",{className:"group",children:[(0,a.jsxs)("summary",{className:"text-muted-foreground hover:text-foreground cursor-pointer text-sm",children:[(0,a.jsx)(G.A,{className:"mr-1 inline h-4 w-4"}),"Show detailed response data"]}),(0,a.jsx)("pre",{className:"bg-muted mt-2 max-h-60 overflow-auto rounded-md p-4 text-xs",children:JSON.stringify(R,null,2)})]})]})]})]})}var eX=t(484),e0=t(2612),e2=t(9680);function e4(e){let{models:s,onFilteredModelsChange:t,className:l}=e,[i,n]=(0,r.useState)(""),[o,d]=(0,r.useState)("name-asc"),c=(0,r.useMemo)(()=>{let e=[...s];if(i.trim()){let s=i.toLowerCase().trim();e=e.filter(e=>e.name.toLowerCase().includes(s)||e.full_name.toLowerCase().includes(s)||e.provider.toLowerCase().includes(s)||e.description&&e.description.toLowerCase().includes(s)||e.modelType.toLowerCase().includes(s))}return e.sort((e,s)=>{switch(o){case"name-asc":return e.name.localeCompare(s.name);case"name-desc":return s.name.localeCompare(e.name);case"price-asc":return(e.is_free?0:(e.input_cost||0)+(e.output_cost||0))-(s.is_free?0:(s.input_cost||0)+(s.output_cost||0));case"price-desc":{let t=e.is_free?0:(e.input_cost||0)+(e.output_cost||0);return(s.is_free?0:(s.input_cost||0)+(s.output_cost||0))-t}default:return 0}}),e},[s,i,o]);r.useEffect(()=>{t(c)},[c,t]);let u=""!==i.trim()||"name-asc"!==o;return(0,a.jsxs)("div",{className:(0,b.cn)("flex flex-col gap-4 sm:flex-row sm:items-center sm:gap-3",l),children:[(0,a.jsxs)("div",{className:"relative flex-1",children:[(0,a.jsx)(eX.A,{className:"text-muted-foreground absolute top-1/2 left-3 h-4 w-4 -translate-y-1/2"}),(0,a.jsx)(g.p,{placeholder:"Search models by name, provider, or description...",value:i,onChange:e=>n(e.target.value),className:"pl-9"})]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsxs)(f.l6,{value:o,onValueChange:e=>d(e),children:[(0,a.jsxs)(f.bq,{className:"w-full sm:w-[180px]",children:[(0,a.jsx)(e0.A,{className:"mr-2 h-4 w-4"}),(0,a.jsx)(f.yv,{placeholder:"Sort by"})]}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"name-asc",children:"Name (A-Z)"}),(0,a.jsx)(f.eb,{value:"name-desc",children:"Name (Z-A)"}),(0,a.jsx)(f.eb,{value:"price-asc",children:"Price (Low to High)"}),(0,a.jsx)(f.eb,{value:"price-desc",children:"Price (High to Low)"})]})]}),u&&(0,a.jsx)(h.$,{variant:"outline",size:"icon",onClick:()=>{n(""),d("name-asc")},className:"h-9 w-9",title:"Clear filters",children:(0,a.jsx)(e2.A,{className:"h-4 w-4"})})]})]})}var e1=t(953),e3=t(7569),e5=t(4756),e6=t(6839);function e9(){let[e,s]=(0,r.useState)([]),{data:t,isLoading:l,error:n}=(0,i.I)({queryKey:["admin-models-with-providers"],queryFn:()=>o.zQ.getModelsWithProviders(),refetchOnWindowFocus:!1}),{models:d=[],groups:c=[]}=t||{},u=(0,r.useMemo)(()=>d?d.reduce((e,s)=>{let t=s.provider;return e[t]||(e[t]=[]),e[t].push(s),e},{}):{},[d]),m=(0,r.useMemo)(()=>new Map(c.map(e=>[e.provider,e])),[c]),p=(0,r.useMemo)(()=>Object.entries(u).map(e=>{let[s,t]=e,a=m.get(s);return{provider:s,activeModels:t.filter(e=>!e.soft_deleted).length,totalModels:t.length,groupData:a,hasGroupUrl:!!(null==a?void 0:a.group_url),hasGroupApiKey:!!(null==a?void 0:a.group_api_key)}}),[u,m]);return(0,a.jsxs)(e1.SidebarProvider,{children:[(0,a.jsx)(e3.AppSidebar,{variant:"inset"}),(0,a.jsxs)(e1.SidebarInset,{children:[(0,a.jsx)(e5.SiteHeader,{}),(0,a.jsx)("div",{className:"flex flex-1 flex-col",children:(0,a.jsxs)("div",{className:"@container/main flex flex-1 flex-col gap-4 p-4 md:gap-8 md:p-8",children:[(0,a.jsx)("div",{className:"mb-6 flex items-center justify-between",children:(0,a.jsx)("h1",{className:"text-2xl font-bold tracking-tight",children:"Model Management & API Testing"})}),(0,a.jsxs)(e6.tU,{defaultValue:"manage",className:"w-full",children:[(0,a.jsx)(e6.j7,{className:"grid w-full grid-cols-3",children:(0,a.jsx)(e6.Xi,{value:"manage",children:"Manage Models"})}),(0,a.jsxs)(e6.av,{value:"manage",className:"space-y-4",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-sm",children:"Manage your AI models organized by provider groups. Configure API keys, and organize models by provider groups."}),l?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)(eo.E,{className:"h-[60px] w-full"}),(0,a.jsx)(eo.E,{className:"h-[400px] w-full"})]}):n?(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Failed to load models. Please try refreshing the page."})]}):(0,a.jsx)(e6.tU,{defaultValue:"all",className:"w-full",children:(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("div",{className:"overflow-x-auto rounded-lg border p-1",children:(0,a.jsxs)(e6.j7,{className:"grid w-full max-w-full min-w-max auto-cols-fr grid-flow-col gap-1 sm:gap-2",children:[(0,a.jsxs)(e6.Xi,{value:"all",className:"flex items-center gap-1 text-xs whitespace-nowrap sm:gap-2 sm:text-sm",children:[(0,a.jsx)(K.A,{className:"h-3 w-3 sm:h-4 sm:w-4"}),(0,a.jsx)("span",{className:"hidden sm:inline",children:"All Models"}),(0,a.jsx)("span",{className:"sm:hidden",children:"All"}),(0,a.jsx)(er.E,{variant:"secondary",className:"ml-1 text-xs",children:d.length})]}),p.map(e=>{let{provider:s,activeModels:t,totalModels:r}=e;return(0,a.jsxs)(e6.Xi,{value:s,className:"flex min-w-fit items-center gap-1 text-xs whitespace-nowrap sm:gap-2 sm:text-sm",children:[(0,a.jsx)(J.A,{className:"h-3 w-3 sm:h-4 sm:w-4"}),(0,a.jsx)("span",{className:"max-w-20 truncate sm:max-w-none",children:s}),(0,a.jsx)("div",{className:"flex items-center gap-1",children:(0,a.jsxs)(er.E,{variant:"secondary",className:"ml-1 text-xs",children:[t,"/",r]})})]},s)})]})}),(0,a.jsx)(e6.av,{value:"all",children:(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-sm",children:"Overview of all models across all provider groups."}),(0,a.jsx)(e4,{models:d,onFilteredModelsChange:s}),(0,a.jsx)(ez,{filteredModels:e})]})}),Object.entries(u).map(e=>{let[s,t]=e,r=m.get(s);return(0,a.jsx)(e6.av,{value:s,children:(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("div",{className:"flex items-center justify-between",children:(0,a.jsxs)("div",{children:[(0,a.jsxs)("h3",{className:"flex items-center gap-2 text-lg font-semibold",children:[(0,a.jsx)(J.A,{className:"h-5 w-5"}),s]}),(0,a.jsxs)("div",{className:"text-muted-foreground flex items-center gap-4 text-sm",children:[t.filter(e=>e.soft_deleted).length>0&&(0,a.jsxs)("span",{className:"text-orange-600",children:[t.filter(e=>e.soft_deleted).length," ","soft deleted"]}),(null==r?void 0:r.group_url)&&(0,a.jsxs)("span",{className:"flex items-center gap-1",children:[(0,a.jsx)(K.A,{className:"h-3 w-3"}),r.group_url]})]})]})}),(0,a.jsx)(ez,{filterProvider:s,groupData:r,showProviderActions:!0})]})},s)})]})})]}),(0,a.jsxs)(e6.av,{value:"test-basic",className:"space-y-4",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-sm",children:"Test model credentials and connectivity with basic chat completion requests through the secure proxy (resolves CORS and Docker network issues). Models can be tested even without API keys configured (useful for free models or when authentication is handled elsewhere)."}),l?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)(eo.E,{className:"h-[200px] w-full"}),(0,a.jsx)(eo.E,{className:"h-[100px] w-full"})]}):n?(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Failed to load models for testing. Please try refreshing the page."})]}):(0,a.jsx)(eO,{models:d})]}),(0,a.jsxs)(e6.av,{value:"test-api",className:"space-y-4",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-sm",children:"Comprehensive testing of all OpenAI API endpoints including chat completions, embeddings, image generation, audio synthesis, and model listing through the secure proxy (resolves CORS and Docker network issues). Models can be tested with or without API keys configured."}),l?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)(eo.E,{className:"h-[300px] w-full"}),(0,a.jsx)(eo.E,{className:"h-[200px] w-full"})]}):n?(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Failed to load models for API testing. Please try refreshing the page."})]}):(0,a.jsx)(eH,{models:d})]})]})]})})]})]})}},8561:(e,s,t)=>{"use strict";t.d(s,{E:()=>n});var a=t(3422);t(4398);var r=t(4676),l=t(9183);let i=(0,r.F)("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground",success:"border-transparent bg-green-500 text-white hover:bg-green-500/80",warning:"border-transparent bg-yellow-500 text-white hover:bg-yellow-500/80",error:"border-transparent bg-red-500 text-white hover:bg-red-500/80"}},defaultVariants:{variant:"default"}});function n(e){let{className:s,variant:t,...r}=e;return(0,a.jsx)("div",{className:(0,l.cn)(i({variant:t}),s),...r})}},9442:(e,s,t)=>{"use strict";t.d(s,{Fc:()=>n,TN:()=>o});var a=t(3422);t(4398);var r=t(4676),l=t(9183);let i=(0,r.F)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"}},defaultVariants:{variant:"default"}});function n(e){let{className:s,variant:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,l.cn)(i({variant:t}),s),...r})}function o(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"alert-description",className:(0,l.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",s),...t})}}},e=>{var s=s=>e(e.s=s);e.O(0,[363,222,808,29,730,978,481,982,826,236,601,945,497,358],()=>s(6715)),_N_E=e.O()}]); \ No newline at end of file +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[552],{834:(e,s,t)=>{"use strict";t.d(s,{T:()=>l});var a=t(3422);t(4398);var r=t(9183);function l(e){let{className:s,...t}=e;return(0,a.jsx)("textarea",{"data-slot":"textarea",className:(0,r.cn)("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",s),...t})}},2264:(e,s,t)=>{"use strict";t.d(s,{bq:()=>u,eb:()=>p,gC:()=>m,l6:()=>d,yv:()=>c});var a=t(3422);t(4398);var r=t(3439),l=t(9994),i=t(8940),n=t(4967),o=t(9183);function d(e){let{...s}=e;return(0,a.jsx)(r.bL,{"data-slot":"select",...s})}function c(e){let{...s}=e;return(0,a.jsx)(r.WT,{"data-slot":"select-value",...s})}function u(e){let{className:s,size:t="default",children:i,...n}=e;return(0,a.jsxs)(r.l9,{"data-slot":"select-trigger","data-size":t,className:(0,o.cn)("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",s),...n,children:[i,(0,a.jsx)(r.In,{asChild:!0,children:(0,a.jsx)(l.A,{className:"size-4 opacity-50"})})]})}function m(e){let{className:s,children:t,position:l="popper",...i}=e;return(0,a.jsx)(r.ZL,{children:(0,a.jsxs)(r.UC,{"data-slot":"select-content",className:(0,o.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--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","popper"===l&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",s),position:l,...i,children:[(0,a.jsx)(x,{}),(0,a.jsx)(r.LM,{className:(0,o.cn)("p-1","popper"===l&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:t}),(0,a.jsx)(h,{})]})})}function p(e){let{className:s,children:t,...l}=e;return(0,a.jsxs)(r.q7,{"data-slot":"select-item",className:(0,o.cn)("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",s),...l,children:[(0,a.jsx)("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:(0,a.jsx)(r.VF,{children:(0,a.jsx)(i.A,{className:"size-4"})})}),(0,a.jsx)(r.p4,{children:t})]})}function x(e){let{className:s,...t}=e;return(0,a.jsx)(r.PP,{"data-slot":"select-scroll-up-button",className:(0,o.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(n.A,{className:"size-4"})})}function h(e){let{className:s,...t}=e;return(0,a.jsx)(r.wn,{"data-slot":"select-scroll-down-button",className:(0,o.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(l.A,{className:"size-4"})})}},6320:(e,s,t)=>{"use strict";t.d(s,{Cf:()=>u,Es:()=>p,L3:()=>x,c7:()=>m,lG:()=>n,rr:()=>h,zM:()=>o});var a=t(3422);t(4398);var r=t(4316),l=t(9680),i=t(9183);function n(e){let{...s}=e;return(0,a.jsx)(r.bL,{"data-slot":"dialog",...s})}function o(e){let{...s}=e;return(0,a.jsx)(r.l9,{"data-slot":"dialog-trigger",...s})}function d(e){let{...s}=e;return(0,a.jsx)(r.ZL,{"data-slot":"dialog-portal",...s})}function c(e){let{className:s,...t}=e;return(0,a.jsx)(r.hJ,{"data-slot":"dialog-overlay",className:(0,i.cn)("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",s),...t})}function u(e){let{className:s,children:t,...n}=e;return(0,a.jsxs)(d,{"data-slot":"dialog-portal",children:[(0,a.jsx)(c,{}),(0,a.jsxs)(r.UC,{"data-slot":"dialog-content",className:(0,i.cn)("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",s),...n,children:[t,(0,a.jsxs)(r.bm,{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:[(0,a.jsx)(l.A,{}),(0,a.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function m(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-header",className:(0,i.cn)("flex flex-col gap-2 text-center sm:text-left",s),...t})}function p(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-footer",className:(0,i.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",s),...t})}function x(e){let{className:s,...t}=e;return(0,a.jsx)(r.hE,{"data-slot":"dialog-title",className:(0,i.cn)("text-lg leading-none font-semibold",s),...t})}function h(e){let{className:s,...t}=e;return(0,a.jsx)(r.VY,{"data-slot":"dialog-description",className:(0,i.cn)("text-muted-foreground text-sm",s),...t})}},6568:(e,s,t)=>{"use strict";t.d(s,{d:()=>i});var a=t(3422);t(4398);var r=t(2495),l=t(9183);function i(e){let{className:s,...t}=e;return(0,a.jsx)(r.bL,{"data-slot":"switch",className:(0,l.cn)("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",s),...t,children:(0,a.jsx)(r.zi,{"data-slot":"switch-thumb",className:(0,l.cn)("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")})})}},6715:(e,s,t)=>{Promise.resolve().then(t.bind(t,7678))},6839:(e,s,t)=>{"use strict";t.d(s,{Xi:()=>o,av:()=>d,j7:()=>n,tU:()=>i});var a=t(3422);t(4398);var r=t(1749),l=t(9183);function i(e){let{className:s,...t}=e;return(0,a.jsx)(r.bL,{"data-slot":"tabs",className:(0,l.cn)("flex flex-col gap-2",s),...t})}function n(e){let{className:s,...t}=e;return(0,a.jsx)(r.B8,{"data-slot":"tabs-list",className:(0,l.cn)("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",s),...t})}function o(e){let{className:s,...t}=e;return(0,a.jsx)(r.l9,{"data-slot":"tabs-trigger",className:(0,l.cn)("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",s),...t})}function d(e){let{className:s,...t}=e;return(0,a.jsx)(r.UC,{"data-slot":"tabs-content",className:(0,l.cn)("flex-1 outline-none",s),...t})}},7678:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>e9});var a=t(3422),r=t(4398),l=t(100),i=t(2349),n=t(6013),o=t(9119),d=t(1407),c=t(552),u=t(9945);let m=u.Ik({id:u.Yj(),name:u.Yj(),full_name:u.Yj(),description:u.Yj().optional(),modelType:u.Yj(),isEnabled:u.zM(),createdAt:u.Yj().datetime(),updatedAt:u.Yj().datetime(),provider:u.Yj(),url:u.Yj().url(),api_key:u.Yj().optional(),input_cost:u.ai().min(0),output_cost:u.ai().min(0),min_cost_per_request:u.ai().min(0,"Minimum cost per request must be non-negative").default(0),min_cash_per_request:u.ai().min(0,"Minimum cash per request must be non-negative").default(0),contextLength:u.ai().int().optional(),apiKeyRequired:u.zM().default(!0),provider_id:u.Yj().optional(),is_free:u.zM().default(!1),soft_deleted:u.zM().optional(),has_own_api_key:u.zM(),api_key_type:u.Yj()});m.extend({settings:u.g1(u.L5()).optional(),pricing:u.Ik({inputCostPer1kTokens:u.ai().optional(),outputCostPer1kTokens:u.ai().optional(),unitCost:u.ai().optional()}).optional()}),m.omit({id:!0,createdAt:!0,updatedAt:!0,has_own_api_key:!0,api_key_type:!0}).extend({settings:u.g1(u.L5()).optional()}),m.partial().omit({id:!0,createdAt:!0,updatedAt:!0,has_own_api_key:!0,api_key_type:!0});let p=u.Ik({name:u.Yj().min(1,"Name is required"),full_name:u.Yj().optional(),input_cost:u.ai().min(0,"Input cost must be non-negative"),output_cost:u.ai().min(0,"Output cost must be non-negative"),provider:u.Yj().min(1,"Provider is required"),modelType:u.k5(["text","embedding","image","audio","multimodal"]),description:u.Yj().optional().transform(e=>""===e?void 0:e),contextLength:u.ai().int().min(0).optional().transform(e=>0===e?void 0:e)}).transform(e=>({...e})),x=u.Ik({provider:u.Yj().min(1,"Provider is required"),group_api_key:u.Yj().transform(e=>""===e?void 0:e).optional(),group_url:u.Yj().transform(e=>""===e?void 0:e).pipe(u.Yj().url("Please enter a valid URL").optional()).optional()});u.Ik({data:u.YO(m),pagination:u.Ik({total:u.ai(),page:u.ai(),pageSize:u.ai(),totalPages:u.ai()})}),u.Ik({modelId:u.Yj(),input:u.Yj(),parameters:u.g1(u.L5()).optional()}),u.Ik({output:u.Yj(),usage:u.Ik({promptTokens:u.ai().optional(),completionTokens:u.ai().optional(),totalTokens:u.ai().optional()}).optional(),timings:u.Ik({totalMs:u.ai()}).optional()});var h=t(3648),g=t(268),v=t(834),j=t(6320),f=t(2264),y=t(6950),b=t(9183),N=t(3130);let w=d.Op,_=r.createContext({}),k=e=>{let{...s}=e;return(0,a.jsx)(_.Provider,{value:{name:s.name},children:(0,a.jsx)(d.xI,{...s})})},C=()=>{let e=r.useContext(_),s=r.useContext(M),{getFieldState:t}=(0,d.xW)(),a=(0,d.lN)({name:e.name}),l=t(e.name,a);if(!e)throw Error("useFormField should be used within ");let{id:i}=s;return{id:i,name:e.name,formItemId:"".concat(i,"-form-item"),formDescriptionId:"".concat(i,"-form-item-description"),formMessageId:"".concat(i,"-form-item-message"),...l}},M=r.createContext({});function A(e){let{className:s,...t}=e,l=r.useId();return(0,a.jsx)(M.Provider,{value:{id:l},children:(0,a.jsx)("div",{"data-slot":"form-item",className:(0,b.cn)("grid gap-2",s),...t})})}function S(e){let{className:s,...t}=e,{error:r,formItemId:l}=C();return(0,a.jsx)(N.J,{"data-slot":"form-label","data-error":!!r,className:(0,b.cn)("data-[error=true]:text-destructive",s),htmlFor:l,...t})}function F(e){let{...s}=e,{error:t,formItemId:r,formDescriptionId:l,formMessageId:i}=C();return(0,a.jsx)(y.DX,{"data-slot":"form-control",id:r,"aria-describedby":t?"".concat(l," ").concat(i):"".concat(l),"aria-invalid":!!t,...s})}function P(e){let{className:s,...t}=e,{formDescriptionId:r}=C();return(0,a.jsx)("p",{"data-slot":"form-description",id:r,className:(0,b.cn)("text-muted-foreground text-sm",s),...t})}function R(e){var s;let{className:t,...r}=e,{error:l,formMessageId:i}=C(),n=l?String(null!=(s=null==l?void 0:l.message)?s:""):r.children;return n?(0,a.jsx)("p",{"data-slot":"form-message",id:i,className:(0,b.cn)("text-destructive text-sm",t),...r,children:n}):null}var T=t(856),z=t(2434),E=t(3831);function I(e){let{onModelAdd:s,onCancel:t,isOpen:l}=e,[i,n]=(0,r.useState)(!1),o=(0,d.mN)({resolver:(0,c.u)(p),defaultValues:{name:"",full_name:"",input_cost:0,output_cost:0,provider:"",modelType:"text",description:"",contextLength:void 0}}),u=async e=>{n(!0);try{await s(e),E.oR.success("Model added successfully!"),o.reset(),null==t||t()}catch(e){E.oR.error("Failed to add model. Please try again."),console.error("Error adding model:",e)}finally{n(!1)}},m=()=>{i||(o.reset(),null==t||t())};return(0,a.jsx)(j.lG,{open:l,onOpenChange:m,children:(0,a.jsxs)(j.Cf,{className:"max-h-[90vh] overflow-y-auto sm:max-w-[600px]",children:[(0,a.jsxs)(j.c7,{children:[(0,a.jsxs)(j.L3,{className:"flex items-center gap-2",children:[(0,a.jsx)(T.A,{className:"h-5 w-5"}),"Add New Model"]}),(0,a.jsx)(j.rr,{children:"Manually add a new AI model to your collection"})]}),(0,a.jsx)(w,{...o,children:(0,a.jsxs)("form",{onSubmit:o.handleSubmit(u),className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:o.control,name:"name",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Model Name *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"e.g., GPT-4o",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"Display name for the model"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:o.control,name:"provider",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Provider *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"e.g., OpenAI, Anthropic",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"AI model provider or company"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:o.control,name:"input_cost",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Input Cost (per 1M tokens) *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",step:"0.001",min:"0",placeholder:"5.00",...s,value:s.value?parseFloat(s.value.toFixed(3)):"",onChange:e=>{let t=Math.round(1e3*(parseFloat(e.target.value)||0))/1e3;s.onChange(t)},className:"w-full"})}),(0,a.jsx)(P,{children:"Cost in USD per 1,000,000 input tokens (max 3 decimals)"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:o.control,name:"output_cost",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Output Cost (per 1M tokens) *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",step:"0.001",min:"0",placeholder:"15.00",...s,value:s.value?parseFloat(s.value.toFixed(3)):"",onChange:e=>{let t=Math.round(1e3*(parseFloat(e.target.value)||0))/1e3;s.onChange(t)},className:"w-full"})}),(0,a.jsx)(P,{children:"Cost in USD per 1,000,000 output tokens (max 3 decimals)"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:o.control,name:"modelType",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Model Type"}),(0,a.jsxs)(f.l6,{onValueChange:s.onChange,defaultValue:s.value,children:[(0,a.jsx)(F,{children:(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{placeholder:"Select model type"})})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"text",children:"Text/Chat"}),(0,a.jsx)(f.eb,{value:"embedding",children:"Embedding"}),(0,a.jsx)(f.eb,{value:"image",children:"Image Generation"}),(0,a.jsx)(f.eb,{value:"audio",children:"Audio"}),(0,a.jsx)(f.eb,{value:"multimodal",children:"Multimodal"})]})]}),(0,a.jsx)(P,{children:"Type of AI model functionality"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:o.control,name:"contextLength",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Context Length"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",min:"0",placeholder:"8192",value:s.value||"",onChange:e=>{let t=parseInt(e.target.value);s.onChange(isNaN(t)||0===t?void 0:t)},className:"w-full"})}),(0,a.jsx)(P,{children:"Maximum context length in tokens (optional, leave empty for default)"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsx)(k,{control:o.control,name:"description",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Description"}),(0,a.jsx)(F,{children:(0,a.jsx)(v.T,{placeholder:"Brief description of the model...",...s,rows:3,className:"w-full"})}),(0,a.jsx)(P,{children:"Optional description or notes about the model"}),(0,a.jsx)(R,{})]})}}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 pt-4",children:[(0,a.jsx)(h.$,{type:"button",variant:"outline",onClick:m,disabled:i,children:"Cancel"}),(0,a.jsx)(h.$,{type:"submit",disabled:i,children:i?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Adding..."]}):"Add Model"})]})]})})]})})}var q=t(7996),L=t(6568);let Y=u.Ik({name:u.Yj().min(1,"Name is required"),description:u.Yj().optional(),context_length:u.au.number().min(0),prompt:u.au.number().min(0),completion:u.au.number().min(0),enabled:u.zM()}),U=e=>null==e||isNaN(e)?0:Math.round(1e5*e)/1e5;function O(e){let{model:s,providerId:t,onModelUpdate:l,onCancel:i,isOpen:n}=e,[u,m]=(0,r.useState)(!1),[p,x]=(0,r.useState)(null),[f,y]=(0,r.useState)(!1),b=(0,d.mN)({resolver:(0,c.u)(Y),defaultValues:{name:s.name,description:s.description||"",context_length:s.contextLength||4096,prompt:U(s.input_cost),completion:U(s.output_cost),enabled:!1!==s.isEnabled}}),N=(0,r.useCallback)(async()=>{if(!t)return void console.error("loadAdminModel called without providerId");try{console.log("Loading admin model:",{providerId:t,modelId:s.full_name});let e=await o.zQ.getProviderModel(t,s.full_name);x(e),y(!1),b.reset({name:e.name,description:e.description||"",context_length:e.context_length,prompt:U(e.pricing.prompt),completion:U(e.pricing.completion),enabled:!1!==e.enabled})}catch(e){console.log("Model not in database, will create new override:",e),y(!0),x({id:s.full_name,name:s.name,description:s.description||"",created:Math.floor(Date.now()/1e3),context_length:s.contextLength||4096,architecture:{modality:s.modelType||"text",input_modalities:[s.modelType||"text"],output_modalities:[s.modelType||"text"],tokenizer:"",instruct_type:null},pricing:{prompt:U(s.input_cost),completion:U(s.output_cost),request:0,image:0,web_search:0,internal_reasoning:0},per_request_limits:null,top_provider:null,upstream_provider_id:t,enabled:!1!==s.isEnabled}),b.reset({name:s.name,description:s.description||"",context_length:s.contextLength||4096,prompt:U(s.input_cost),completion:U(s.output_cost),enabled:!1!==s.isEnabled})}},[t,s,b]);(0,r.useEffect)(()=>{n&&t?N():n&&!t&&(console.error("EditModelForm opened without providerId",{model:s,providerId:t}),E.oR.error("Missing provider information for this model"))},[n,t,s,N]);let _=async e=>{if(!t){console.error("onSubmit called without providerId",{model:s,providerId:t}),E.oR.error("Missing provider ID - cannot update model");return}if(!p){console.error("onSubmit called without adminModelData",{model:s,providerId:t,adminModelData:p}),E.oR.error("Model data not loaded - please try reopening the form");return}m(!0);try{let s={id:p.id,name:e.name,description:e.description||"",created:p.created||Math.floor(Date.now()/1e3),context_length:e.context_length,architecture:p.architecture||{modality:"text",input_modalities:["text"],output_modalities:["text"],tokenizer:"",instruct_type:null},pricing:{prompt:U(e.prompt),completion:U(e.completion),request:0,image:0,web_search:0,internal_reasoning:0},per_request_limits:p.per_request_limits,top_provider:p.top_provider,upstream_provider_id:t,enabled:e.enabled};f?(console.log("Creating new model override"),await o.zQ.createProviderModel(t,s),E.oR.success("Model override created successfully!")):(console.log("Updating existing model override"),await o.zQ.updateProviderModel(t,p.id,s),E.oR.success("Model updated successfully!")),null==l||l(),null==i||i()}catch(s){let e=f?"create":"update";E.oR.error("Failed to ".concat(e," model. Please try again.")),console.error("Error ".concat(e,"ing model:"),s)}finally{m(!1)}},C=()=>{u||null==i||i()};return(0,a.jsx)(j.lG,{open:n,onOpenChange:C,children:(0,a.jsxs)(j.Cf,{className:"max-h-[90vh] overflow-y-auto sm:max-w-[600px]",children:[(0,a.jsxs)(j.c7,{children:[(0,a.jsxs)(j.L3,{className:"flex items-center gap-2",children:[(0,a.jsx)(q.A,{className:"h-5 w-5"}),f?"Create Model Override":"Edit Model Override"]}),(0,a.jsx)(j.rr,{children:f?"Create an override for "".concat(s.name,"""):"Update the model override for "".concat(s.name,""")})]}),(0,a.jsx)(w,{...b,children:(0,a.jsxs)("form",{onSubmit:b.handleSubmit(_),className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:b.control,name:"name",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Display Name *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"e.g., GPT-4",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"Custom display name for the model"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:b.control,name:"context_length",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Context Length *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",min:"0",placeholder:"4096",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"Maximum context window size"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsx)(k,{control:b.control,name:"description",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Description"}),(0,a.jsx)(F,{children:(0,a.jsx)(v.T,{placeholder:"Brief description of the model...",...s,rows:3,className:"w-full"})}),(0,a.jsx)(P,{children:"Optional description or notes about the model"}),(0,a.jsx)(R,{})]})}}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,a.jsx)(k,{control:b.control,name:"prompt",render:e=>{var s;let{field:t}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Input Cost (per 1M tokens) *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",step:"0.00001",min:"0",placeholder:"5.00000",value:null!=(s=t.value)?s:"",onChange:e=>{let s=e.target.value;t.onChange(""===s?0:parseFloat(s))},onBlur:e=>{let s=parseFloat(e.target.value);t.onChange(U(s))},className:"w-full"})}),(0,a.jsx)(P,{children:"Cost in USD per 1,000,000 input tokens (max 5 decimals)"}),(0,a.jsx)(R,{})]})}}),(0,a.jsx)(k,{control:b.control,name:"completion",render:e=>{var s;let{field:t}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Output Cost (per 1M tokens) *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:"number",step:"0.00001",min:"0",placeholder:"15.00000",value:null!=(s=t.value)?s:"",onChange:e=>{let s=e.target.value;t.onChange(""===s?0:parseFloat(s))},onBlur:e=>{let s=parseFloat(e.target.value);t.onChange(U(s))},className:"w-full"})}),(0,a.jsx)(P,{children:"Cost in USD per 1,000,000 output tokens (max 5 decimals)"}),(0,a.jsx)(R,{})]})}})]}),(0,a.jsx)(k,{control:b.control,name:"enabled",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{className:"flex flex-row items-center justify-between rounded-lg border p-4",children:[(0,a.jsxs)("div",{className:"space-y-0.5",children:[(0,a.jsx)(S,{className:"text-base",children:"Model Enabled"}),(0,a.jsx)(P,{children:"Enable or disable this model override"})]}),(0,a.jsx)(F,{children:(0,a.jsx)(L.d,{checked:s.value,onCheckedChange:s.onChange})})]})}}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 pt-4",children:[(0,a.jsx)(h.$,{type:"button",variant:"outline",onClick:C,disabled:u,children:"Cancel"}),(0,a.jsx)(h.$,{type:"submit",disabled:u,children:u?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),f?"Creating...":"Updating..."]}):f?"Create Override":"Update Model"})]})]})})]})})}var J=t(1935),Q=t(5195),K=t(9906),D=t(2267),G=t(1220),V=t(9442);function $(e){let{provider:s,models:t,groupSettings:l,onGroupUpdate:i,onCancel:n,isOpen:o}=e,[u,m]=(0,r.useState)(!1),[p,v]=(0,r.useState)(!1),[f,y]=(0,r.useState)(!!(null==l?void 0:l.group_url)),b=(0,d.mN)({resolver:(0,c.u)(x),defaultValues:{provider:s,group_api_key:(null==l?void 0:l.group_api_key)||"",group_url:(null==l?void 0:l.group_url)||""}}),N=async e=>{m(!0);try{var t,a;let r={...e,group_api_key:(null==(t=e.group_api_key)?void 0:t.trim())||void 0,group_url:f&&(null==(a=e.group_url)?void 0:a.trim())||void 0};await i(s,r),E.oR.success('Group "'.concat(s,'" updated successfully!')),null==n||n()}catch(e){E.oR.error("Failed to update group. Please try again."),console.error("Error updating group:",e)}finally{m(!1)}},_=t.filter(e=>!e.api_key).length,C=t.filter(e=>!e.api_key&&(!e.url||e.url.startsWith("/"))).length,M=()=>{u||null==n||n()};return(0,a.jsx)(j.lG,{open:o,onOpenChange:M,children:(0,a.jsxs)(j.Cf,{className:"max-h-[90vh] overflow-y-auto sm:max-w-[700px]",children:[(0,a.jsxs)(j.c7,{children:[(0,a.jsxs)(j.L3,{className:"flex items-center gap-2",children:[(0,a.jsx)(J.A,{className:"h-5 w-5"}),"Edit Provider Group: ",s]}),(0,a.jsxs)(j.rr,{children:["Update settings for all ",t.length," models in this group. Group settings provide defaults for models without individual configurations."]})]}),(0,a.jsxs)("div",{className:"mb-6 space-y-4",children:[(0,a.jsxs)("div",{className:"rounded-md border p-4",children:[(0,a.jsxs)("h4",{className:"mb-2 flex items-center gap-2 text-sm font-medium",children:[(0,a.jsx)(Q.A,{className:"h-4 w-4"}),"API Key Configuration"]}),(0,a.jsx)("div",{className:"space-y-2 text-sm",children:(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{children:"Models using group API key:"}),(0,a.jsx)("span",{className:"font-medium text-blue-600",children:_})]})})]}),(0,a.jsxs)("div",{className:"rounded-md border p-4",children:[(0,a.jsxs)("h4",{className:"mb-2 flex items-center gap-2 text-sm font-medium",children:[(0,a.jsx)(K.A,{className:"h-4 w-4"}),"URL Configuration"]}),(0,a.jsxs)("div",{className:"space-y-2 text-sm",children:[(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{children:"Models using group URL:"}),(0,a.jsx)("span",{className:"font-medium text-blue-600",children:C})]}),(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{children:"Models with individual URLs:"}),(0,a.jsx)("span",{className:"font-medium text-green-600",children:t.length-C})]}),(null==l?void 0:l.group_url)&&(0,a.jsxs)("div",{className:"mt-2 rounded bg-blue-50 p-2 text-xs",children:[(0,a.jsx)("span",{className:"font-medium",children:"Current group URL:"})," ",l.group_url]})]})]}),(0,a.jsxs)("div",{className:"rounded-md border p-4",children:[(0,a.jsx)("h4",{className:"mb-2 text-sm font-medium",children:"Models in this group:"}),(0,a.jsx)("div",{className:"max-h-32 overflow-y-auto",children:(0,a.jsx)("div",{className:"flex flex-wrap gap-2",children:t.map(e=>(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-medium ".concat(e.api_key?"bg-green-100 text-green-800":"bg-blue-100 text-blue-800"),title:e.api_key?"Has individual API key and URL":"Uses group API key and URL",children:[e.name,e.api_key&&" \uD83D\uDD11",e.url&&!e.url.startsWith("/")&&e.api_key&&" \uD83C\uDF10"]},e.id))})})]})]}),(0,a.jsx)(w,{...b,children:(0,a.jsxs)("form",{onSubmit:b.handleSubmit(N),className:"space-y-6",children:[(0,a.jsx)(k,{control:b.control,name:"provider",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Provider Name *"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"e.g., OpenAI, Anthropic",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"This will update the provider name for all models in this group"}),(0,a.jsx)(R,{})]})}}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"space-y-0.5",children:[(0,a.jsx)(S,{className:"text-base",children:"Group Base URL"}),(0,a.jsx)(P,{children:"Provide a custom base URL for this provider group"})]}),(0,a.jsx)(L.d,{checked:f,onCheckedChange:y})]}),f&&(0,a.jsx)(k,{control:b.control,name:"group_url",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Base URL"}),(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{placeholder:"https://api.openai.com/v1 or https://your-proxy.com/v1",...s,className:"w-full"})}),(0,a.jsx)(P,{children:"This base URL will be used for models without individual URLs. Models will append their endpoint path (e.g., /chat/completions) to this base."}),(0,a.jsx)(R,{})]})}}),!f&&(null==l?void 0:l.group_url)&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(D.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Removing the group URL will make models in this group fall back to the default system endpoint. Models with individual URLs will be unaffected."})]}),f&&!(null==l?void 0:l.group_url)&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(G.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Adding a group URL will allow models in this group to use a custom endpoint instead of the default system endpoint."})]})]}),(0,a.jsx)(k,{control:b.control,name:"group_api_key",render:e=>{let{field:s}=e;return(0,a.jsxs)(A,{children:[(0,a.jsx)(S,{children:"Group API Key"}),(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)(F,{children:(0,a.jsx)(g.p,{type:p?"text":"password",placeholder:"sk-... (leave empty to remove)",...s,className:"w-full pr-24"})}),(0,a.jsx)(h.$,{type:"button",variant:"ghost",size:"sm",className:"absolute top-0 right-0 h-full px-3 py-2 hover:bg-transparent",onClick:()=>v(!p),children:p?"Hide":"Show"})]}),(0,a.jsxs)(P,{children:["This API key will be used for models that don't have individual API keys (",_," models). Leave empty to remove the group API key."]}),(0,a.jsx)(R,{})]})}}),(0,a.jsxs)("div",{className:"rounded-md border border-amber-200 bg-amber-50 p-4",children:[(0,a.jsx)("p",{className:"text-sm text-amber-800",children:(0,a.jsx)("strong",{children:"How group settings work:"})}),(0,a.jsxs)("ul",{className:"mt-2 list-inside list-disc space-y-1 text-sm text-amber-800",children:[(0,a.jsx)("li",{children:"Models with individual API keys and URLs will keep their specific settings"}),(0,a.jsx)("li",{children:"Models without individual settings will use the group defaults"}),(0,a.jsx)("li",{children:"Removing the group URL makes models fall back to the system default endpoint"}),(0,a.jsx)("li",{children:'You can use "Apply Group Settings" to force models to use group configurations'})]})]}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 pt-4",children:[(0,a.jsx)(h.$,{type:"button",variant:"outline",onClick:M,disabled:u,children:"Cancel"}),(0,a.jsx)(h.$,{type:"submit",disabled:u,children:u?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Updating..."]}):"Update Group"})]})]})})]})})}var B=t(7228),W=t(9675),Z=t(246),H=t(1853),X=t(8940);function ee(e){let{className:s,...t}=e;return(0,a.jsx)(H.bL,{"data-slot":"checkbox",className:(0,b.cn)("peer border-input dark:bg-input/30 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:data-[state=checked]:bg-primary data-[state=checked]:border-primary focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive size-4 shrink-0 rounded-[4px] border shadow-xs transition-shadow outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",s),...t,children:(0,a.jsx)(H.C1,{"data-slot":"checkbox-indicator",className:"flex items-center justify-center text-current transition-none",children:(0,a.jsx)(X.A,{className:"size-3.5"})})})}var es=t(9625);function et(e){let{className:s,children:t,...r}=e;return(0,a.jsxs)(es.bL,{"data-slot":"scroll-area",className:(0,b.cn)("relative",s),...r,children:[(0,a.jsx)(es.LM,{"data-slot":"scroll-area-viewport",className:"focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1",children:t}),(0,a.jsx)(ea,{}),(0,a.jsx)(es.OK,{})]})}function ea(e){let{className:s,orientation:t="vertical",...r}=e;return(0,a.jsx)(es.VM,{"data-slot":"scroll-area-scrollbar",orientation:t,className:(0,b.cn)("flex touch-none p-px transition-colors select-none","vertical"===t&&"h-full w-2.5 border-l border-l-transparent","horizontal"===t&&"h-2.5 flex-col border-t border-t-transparent",s),...r,children:(0,a.jsx)(es.lr,{"data-slot":"scroll-area-thumb",className:"bg-border relative flex-1 rounded-full"})})}var er=t(8561);function el(e){let{isOpen:s,onClose:t,onSuccess:l}=e,[i,n]=(0,r.useState)(null),[d,c]=(0,r.useState)([]),[u,m]=(0,r.useState)([]),[p,x]=(0,r.useState)(new Set),[g,v]=(0,r.useState)(!1),[y,b]=(0,r.useState)(!1),[N,w]=(0,r.useState)(!1),[_,k]=(0,r.useState)(null),C=(0,r.useCallback)(async()=>{if(i){b(!0),m([]),x(new Set);try{let e=await o.zQ.getProviderModels(i),s=new Set(e.db_models.map(e=>e.id)),t=e.remote_models.filter(e=>!s.has(e.id));m(t)}catch(e){E.oR.error("Failed to fetch models from provider")}finally{b(!1)}}},[i]);(0,r.useEffect)(()=>{s&&M()},[s]),(0,r.useEffect)(()=>{i&&C()},[i,C]);let M=async()=>{v(!0);try{let e=await o.zQ.getUpstreamProviders();c(e)}catch(e){E.oR.error("Failed to load providers")}finally{v(!1)}},A=e=>{let s=new Set(p);s.has(e)?s.delete(e):s.add(e),x(s)},S=async()=>{if(0===p.size)return void E.oR.error("Please select at least one model");w(!0);let e=0,s=0,t=[];try{for(let a of Array.from(p)){let r=u.find(e=>e.id===a);if(r)try{await o.zQ.createModel({...r,upstream_provider_id:i,enabled:!0,created:Math.floor(Date.now()/1e3)}),e++}catch(r){let e=r instanceof Error?r.message:"Unknown error";e.includes("already exists")?s++:t.push("".concat(a,": ").concat(e))}}k({added:e,skipped:s,errors:t}),e>0&&(E.oR.success("Successfully added ".concat(e," models")),null==l||l()),t.length>0&&E.oR.warning("Completed with ".concat(t.length," errors"))}catch(e){E.oR.error("Failed to collect models")}finally{w(!1)}},F=()=>{N||(n(null),m([]),x(new Set),k(null),t())};return(0,a.jsx)(j.lG,{open:s,onOpenChange:F,children:(0,a.jsxs)(j.Cf,{className:"max-h-[80vh] sm:max-w-[700px]",children:[(0,a.jsxs)(j.c7,{children:[(0,a.jsxs)(j.L3,{className:"flex items-center gap-2",children:[(0,a.jsx)(B.A,{className:"h-5 w-5"}),"Collect Models from Provider"]}),(0,a.jsx)(j.rr,{children:"Fetch models from an upstream provider and add them to your database"})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("label",{className:"text-sm font-medium",children:"Select Provider"}),(0,a.jsxs)(f.l6,{value:null==i?void 0:i.toString(),onValueChange:e=>n(parseInt(e)),disabled:g,children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{placeholder:"Choose an upstream provider"})}),(0,a.jsx)(f.gC,{children:d.map(e=>(0,a.jsxs)(f.eb,{value:e.id.toString(),children:[e.provider_type," - ",e.base_url]},e.id))})]})]}),y&&(0,a.jsxs)("div",{className:"flex items-center justify-center py-8",children:[(0,a.jsx)(z.A,{className:"h-8 w-8 animate-spin"}),(0,a.jsx)("span",{className:"ml-2",children:"Loading models from provider..."})]}),!y&&i&&u.length>0&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"text-sm font-medium",children:[u.length," models available"]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(h.$,{variant:"outline",size:"sm",onClick:()=>{x(new Set(u.map(e=>e.id)))},disabled:N,children:"Select All"}),(0,a.jsx)(h.$,{variant:"outline",size:"sm",onClick:()=>{x(new Set)},disabled:N,children:"Deselect All"})]})]}),(0,a.jsx)(et,{className:"h-[300px] rounded-md border p-4",children:(0,a.jsx)("div",{className:"space-y-2",children:u.map(e=>(0,a.jsxs)("div",{className:"hover:bg-accent flex items-start space-x-3 rounded-lg border p-3",children:[(0,a.jsx)(ee,{checked:p.has(e.id),onCheckedChange:()=>A(e.id),disabled:N}),(0,a.jsxs)("div",{className:"flex-1 space-y-1",children:[(0,a.jsx)("div",{className:"font-mono text-sm font-medium",children:e.id}),(0,a.jsx)("div",{className:"text-muted-foreground text-xs",children:e.description||e.name}),e.context_length&&(0,a.jsxs)(er.E,{variant:"secondary",className:"text-xs",children:[e.context_length.toLocaleString()," tokens"]})]})]},e.id))})})]}),!y&&i&&0===u.length&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"No new models available from this provider. All models may already be in your database."})]}),_&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(Z.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Collection Results:"}),(0,a.jsx)("br",{}),"• ",_.added," models added",(0,a.jsx)("br",{}),"• ",_.skipped," models skipped",_.errors.length>0&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("br",{}),"• ",_.errors.length," errors occurred"]})]})]}),_.errors.length>0&&(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Errors:"}),(0,a.jsxs)("ul",{className:"mt-1 list-inside list-disc text-sm",children:[_.errors.slice(0,3).map((e,s)=>(0,a.jsx)("li",{children:e},s)),_.errors.length>3&&(0,a.jsxs)("li",{children:["... and ",_.errors.length-3," more errors"]})]})]})]})]}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 pt-4",children:[(0,a.jsx)(h.$,{variant:"outline",onClick:F,disabled:N,children:_?"Close":"Cancel"}),(0,a.jsx)(h.$,{onClick:S,disabled:N||!i||0===p.size||y,children:N?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Adding Models..."]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(B.A,{className:"mr-2 h-4 w-4"}),"Add ",p.size," Models"]})})]})]})]})})}function ei(e){return 0===e?"Free":e<1e-6?"$".concat(e.toFixed(8)):e<.001?"$".concat(e.toFixed(6)):e<.01?"$".concat(e.toFixed(4)):"$".concat(e.toFixed(3))}var en=t(2738),eo=t(2745),ed=t(8815);function ec(e){let{...s}=e;return(0,a.jsx)(ed.bL,{"data-slot":"alert-dialog",...s})}function eu(e){let{...s}=e;return(0,a.jsx)(ed.ZL,{"data-slot":"alert-dialog-portal",...s})}function em(e){let{className:s,...t}=e;return(0,a.jsx)(ed.hJ,{"data-slot":"alert-dialog-overlay",className:(0,b.cn)("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",s),...t})}function ep(e){let{className:s,...t}=e;return(0,a.jsxs)(eu,{children:[(0,a.jsx)(em,{}),(0,a.jsx)(ed.UC,{"data-slot":"alert-dialog-content",className:(0,b.cn)("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",s),...t})]})}function ex(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"alert-dialog-header",className:(0,b.cn)("flex flex-col gap-2 text-center sm:text-left",s),...t})}function eh(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"alert-dialog-footer",className:(0,b.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",s),...t})}function eg(e){let{className:s,...t}=e;return(0,a.jsx)(ed.hE,{"data-slot":"alert-dialog-title",className:(0,b.cn)("text-lg font-semibold",s),...t})}function ev(e){let{className:s,...t}=e;return(0,a.jsx)(ed.VY,{"data-slot":"alert-dialog-description",className:(0,b.cn)("text-muted-foreground text-sm",s),...t})}function ej(e){let{className:s,...t}=e;return(0,a.jsx)(ed.rc,{className:(0,b.cn)((0,h.r)(),s),...t})}function ef(e){let{className:s,...t}=e;return(0,a.jsx)(ed.ZD,{className:(0,b.cn)((0,h.r)({variant:"outline"}),s),...t})}var ey=t(6049);function eb(e){let{...s}=e;return(0,a.jsx)(ey.bL,{"data-slot":"dropdown-menu",...s})}function eN(e){let{...s}=e;return(0,a.jsx)(ey.l9,{"data-slot":"dropdown-menu-trigger",...s})}function ew(e){let{className:s,sideOffset:t=4,...r}=e;return(0,a.jsx)(ey.ZL,{children:(0,a.jsx)(ey.UC,{"data-slot":"dropdown-menu-content",sideOffset:t,className:(0,b.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 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",s),...r})})}function e_(e){let{className:s,inset:t,variant:r="default",...l}=e;return(0,a.jsx)(ey.q7,{"data-slot":"dropdown-menu-item","data-inset":t,"data-variant":r,className:(0,b.cn)("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",s),...l})}function ek(e){let{className:s,...t}=e;return(0,a.jsx)(ey.wv,{"data-slot":"dropdown-menu-separator",className:(0,b.cn)("bg-border -mx-1 my-1 h-px",s),...t})}var eC=t(2034),eM=t(9987),eA=t(3545),eS=t(4963),eF=t(6541),eP=t(9197),eR=t(3732),eT=t(3728);function ez(e){let{filterProvider:s,groupData:t,filteredModels:d}=e,[c,u]=(0,r.useState)(""),[,m]=(0,r.useState)(null),[p,x]=(0,r.useState)(!1),[g,v]=(0,r.useState)(null),[j,f]=(0,r.useState)(null),[y,N]=(0,r.useState)(!1),[w,_]=(0,r.useState)(new Set),[k,C]=(0,r.useState)(!1),[M,A]=(0,r.useState)(!1),[S,F]=(0,r.useState)(!1),[P]=(0,r.useState)([]),R=(0,l.jE)(),{data:T,isLoading:z,error:L,refetch:Y}=(0,i.I)({queryKey:["models-with-providers"],queryFn:()=>o.zQ.getModelsWithProviders(),refetchOnWindowFocus:!1}),{models:U=[],groups:G=[]}=T||{},V=(0,r.useMemo)(()=>s?U.filter(e=>e.provider===s):U,[U,s]),B=(0,n.n)({mutationFn:async e=>{let s=U.filter(s=>e.includes(s.id)).reduce((e,s)=>{let t=s.provider_id||"unknown";return e[t]||(e[t]=[]),e[t].push(s),e},{}),t=0;for(let[e,a]of Object.entries(s)){if("unknown"===e)continue;let s=a.map(e=>e.full_name);t+=(await o.zQ.deleteModels(s,e)).deleted_count}return{deleted_count:t,message:"Models deleted"}},onSuccess:e=>{E.oR.success("Successfully deleted ".concat(e.deleted_count," model overrides")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to delete model overrides: ".concat(e.message))}}),W=(0,n.n)({mutationFn:async e=>{let s=U.filter(s=>e.includes(s.id)).reduce((e,s)=>{let t=s.provider_id||"unknown";return e[t]||(e[t]=[]),e[t].push(s),e},{}),t=0;for(let[e,r]of Object.entries(s))if("unknown"!==e)for(let s of r){let r=parseInt(e);try{let e=await o.zQ.getProviderModel(r,s.full_name);await o.zQ.updateProviderModel(r,s.full_name,{...e,enabled:!1}),t++}catch(e){var a;if((null==(a=e.message)?void 0:a.includes("404"))||404===e.status){let e={id:s.full_name,name:s.name,description:s.description||"",created:Math.floor(Date.now()/1e3),context_length:s.contextLength||4096,architecture:{modality:s.modelType||"text",input_modalities:[s.modelType||"text"],output_modalities:[s.modelType||"text"],tokenizer:"",instruct_type:null},pricing:{prompt:s.input_cost,completion:s.output_cost,request:0,image:0,web_search:0,internal_reasoning:0},per_request_limits:null,top_provider:null,upstream_provider_id:r,enabled:!1};await o.zQ.createProviderModel(r,e),t++}}}return{deleted_count:t,message:"Models disabled"}},onSuccess:e=>{E.oR.success("Successfully disabled ".concat(e.deleted_count," models")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to disable models: ".concat(e.message))}}),H=(0,n.n)({mutationFn:async e=>{if(!t)throw Error("No group data available");let s={};return s.api_key="",t.group_url&&(s.url=t.group_url),o.zQ.bulkUpdateModels(e,s)},onSuccess:e=>{E.oR.success("Successfully applied group settings to ".concat(e.updated_count," models")),e.errors.length>0&&(E.oR.warning("".concat(e.errors.length," models had errors during update")),console.warn("Bulk update errors:",e.errors)),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to apply group settings: ".concat(e.message))}}),X=(0,n.n)({mutationFn:()=>o.zQ.deleteAllModels(),onSuccess:e=>{E.oR.success("Successfully permanently deleted ".concat(e.deleted_count," models")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to permanently delete all models: ".concat(e.message))}}),es=(0,n.n)({mutationFn:e=>o.zQ.deleteModelsByProvider(e),onSuccess:e=>{E.oR.success("Successfully permanently deleted ".concat(e.deleted_count," models from provider")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to permanently delete provider models: ".concat(e.message))}}),et=(0,n.n)({mutationFn:async e=>{let s=U.find(s=>s.id===e);if(!s)throw Error("Model not found");if(!s.provider_id)throw Error("Provider ID not available for this model");let t=parseInt(s.provider_id),a=await o.zQ.getProviderModel(t,s.full_name);return await o.zQ.updateProviderModel(t,s.full_name,{...a,enabled:!0}),{restored_count:1}},onSuccess:()=>{E.oR.success("Model enabled successfully"),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to enable model: ".concat(e.message))}}),ea=(0,n.n)({mutationFn:async e=>{let s=U.filter(s=>e.includes(s.id)).reduce((e,s)=>{let t=s.provider_id||"unknown";return e[t]||(e[t]=[]),e[t].push(s),e},{}),t=0;for(let[e,a]of Object.entries(s))if("unknown"!==e)for(let s of a){let a=parseInt(e);try{let e=await o.zQ.getProviderModel(a,s.full_name);await o.zQ.updateProviderModel(a,s.full_name,{...e,enabled:!0}),t++}catch(e){console.error("Failed to enable model ".concat(s.full_name,":"),e)}}return{restored_count:t,message:"Models enabled"}},onSuccess:e=>{E.oR.success("Successfully enabled ".concat(e.restored_count," models")),_(new Set),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})},onError:e=>{E.oR.error("Failed to enable models: ".concat(e.message))}}),er=(0,r.useMemo)(()=>{let e=d&&d.length>0?d:P.length>0?P:V;return s?{[s]:e}:e?e.reduce((e,s)=>{let t=s.provider;return e[t]||(e[t]=[]),e[t].push(s),e},{}):{}},[V,P,d,s]),ed=(0,r.useMemo)(()=>new Map(G.map(e=>[e.provider,e])),[G]),eu=(0,r.useMemo)(()=>{let e={};return G.forEach(s=>{e[s.provider]={group_api_key:s.group_api_key,group_url:s.group_url}}),e},[G]),em=e=>{var s;return e.api_key?e.api_key:null==(s=eu[e.provider])?void 0:s.group_api_key},ey=e=>{let s=ed.get(e.provider),t=!!(e.api_key&&"string"==typeof e.api_key&&e.api_key!==(null==s?void 0:s.group_api_key)),a=!!(e.url&&"string"==typeof e.url&&!e.url.startsWith("/")&&e.url!==(null==s?void 0:s.group_url));return t||a},ez=async e=>{try{let s=G.find(s=>s.provider===e.provider);s||(s=await o.zQ.createModelGroup({provider:e.provider,group_api_key:void 0}));let t={name:e.name,full_name:e.name,input_cost:e.input_cost,output_cost:e.output_cost,provider:e.provider,modelType:e.modelType,description:e.description||void 0,contextLength:e.contextLength};await o.zQ.createModel(t),await Y(),E.oR.success('Model "'.concat(e.name,'" added successfully!'))}catch(e){throw console.error("Error adding model:",e),E.oR.error("Failed to add model. Please try again."),e}},eE=async()=>{await Y(),v(null)},eI=async(e,s)=>{try{let t=ed.get(e);t&&(await o.zQ.updateModelGroup(t.id,{provider:s.provider,group_api_key:s.group_api_key||void 0,group_url:s.group_url||void 0}),await Y(),f(null),E.oR.success("Group updated successfully!"))}catch(e){console.error("Error updating group:",e),E.oR.error("Failed to update group. Please try again.")}},eq=async()=>{await Y(),N(!1)},eL=async e=>{let s=ed.get(e);if(!(null==s?void 0:s.id))return void E.oR.error("No group configuration found for this provider");try{let e=await o.zQ.refreshModels({provider_id:s.id});E.oR.info(e.message),await Y(),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})}catch(t){console.error("Error refreshing provider models:",t);let s=t instanceof Error?t.message:"Unknown error";E.oR.error("Failed to refresh ".concat(e," models: ").concat(s))}},eY=e=>{switch(e.toLowerCase()){case"text":default:return(0,a.jsx)(eC.A,{className:"h-4 w-4"});case"embedding":return(0,a.jsx)(eM.A,{className:"h-4 w-4"});case"image":return(0,a.jsx)(K.A,{className:"h-4 w-4"})}},eU=e=>{switch(e.toLowerCase()){case"text":return"bg-blue-100 text-blue-800";case"embedding":return"bg-purple-100 text-purple-800";case"image":return"bg-green-100 text-green-800";case"audio":return"bg-orange-100 text-orange-800";case"multimodal":return"bg-pink-100 text-pink-800";default:return"bg-gray-100 text-gray-800"}},eO=e=>{let s=new Set(w);s.has(e)?s.delete(e):s.add(e),_(s)},eJ=e=>{let s=(d&&d.length>0?d:P.length>0?P:V).filter(s=>s.provider===e).map(e=>e.id),t=new Set(w);s.forEach(e=>t.add(e)),_(t)},eQ=e=>{let s=ed.get(e);(null==s?void 0:s.id)&&es.mutate(s.id)},eK=async e=>{let s=U.find(s=>s.id===e);if(!s)return void E.oR.error("Model not found");if(!s.provider_id)return void E.oR.error("Provider ID not available for this model");try{let e=parseInt(s.provider_id);await o.zQ.deleteProviderModel(e,s.full_name),E.oR.success("Model override deleted successfully"),R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})}catch(s){let e=s instanceof Error?s.message:"Unknown error";E.oR.error("Failed to delete model override: ".concat(e))}},eD=async e=>{let s=U.find(s=>s.id===e);if(!s)return void E.oR.error("Model not found");if(!s.provider_id)return void E.oR.error("Provider ID not available for this model");try{let e=parseInt(s.provider_id);try{let t=await o.zQ.getProviderModel(e,s.full_name);await o.zQ.updateProviderModel(e,s.full_name,{...t,enabled:!1}),E.oR.success("Model disabled successfully")}catch(a){var t;if((null==(t=a.message)?void 0:t.includes("404"))||404===a.status){let t={id:s.full_name,name:s.name,description:s.description||"",created:Math.floor(Date.now()/1e3),context_length:s.contextLength||4096,architecture:{modality:s.modelType||"text",input_modalities:[s.modelType||"text"],output_modalities:[s.modelType||"text"],tokenizer:"",instruct_type:null},pricing:{prompt:s.input_cost,completion:s.output_cost,request:0,image:0,web_search:0,internal_reasoning:0},per_request_limits:null,top_provider:null,upstream_provider_id:e,enabled:!1};await o.zQ.createProviderModel(e,t),E.oR.success("Model disabled successfully")}else throw a}R.invalidateQueries({queryKey:["models-with-providers"]}),R.invalidateQueries({queryKey:["all-provider-models"]}),R.invalidateQueries({queryKey:["upstream-providers"]})}catch(s){let e=s instanceof Error?s.message:"Unknown error";E.oR.error("Failed to disable model: ".concat(e))}};return z?(0,a.jsxs)("div",{className:"grid gap-4",children:[(0,a.jsx)(eo.E,{className:"h-[200px]"}),(0,a.jsx)(eo.E,{className:"h-[200px]"})]}):L?(0,a.jsx)("div",{className:"rounded-lg border border-red-200 bg-red-50 p-4",children:(0,a.jsx)("p",{className:"text-sm text-red-800",children:"Error loading models. Please try again later."})}):(0,a.jsxs)("div",{className:"grid gap-6",children:[(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,a.jsxs)(h.$,{onClick:()=>{_(new Set((d&&d.length>0?d:P.length>0?P:V).map(e=>e.id)))},children:[(0,a.jsx)(eA.A,{className:"mr-2 h-4 w-4"}),"Select All Models"]}),(0,a.jsxs)(h.$,{onClick:()=>{_(new Set)},children:[(0,a.jsx)(eS.A,{className:"mr-2 h-4 w-4"}),"Deselect All"]}),(0,a.jsxs)(h.$,{onClick:()=>{A(!0)},className:"text-destructive focus:text-destructive",children:[(0,a.jsx)(D.A,{className:"mr-2 h-4 w-4"}),"Delete All Models Permanently"]}),w.size>0&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"bg-border h-6 w-px"}),(0,a.jsxs)("span",{className:"text-muted-foreground text-sm",children:[w.size," selected"]}),(()=>{let e=(d&&d.length>0?d:P.length>0?P:V).filter(e=>w.has(e.id)&&e.soft_deleted);return e.length>0&&(0,a.jsxs)(h.$,{onClick:()=>ea.mutate(e.map(e=>e.id)),variant:"outline",size:"sm",className:"gap-2 border-green-300 text-green-600 hover:border-green-400 hover:text-green-700",disabled:ea.isPending,children:[(0,a.jsx)(Z.A,{className:"h-4 w-4"}),"Enable Selected (",e.length,")"]})})(),(0,a.jsxs)(h.$,{onClick:()=>{C(!0)},variant:"destructive",size:"sm",className:"gap-2",disabled:B.isPending,children:[(0,a.jsx)(eF.A,{className:"h-4 w-4"}),"Delete Selected Overrides"]}),(0,a.jsxs)(h.$,{onClick:()=>{W.mutate(Array.from(w))},variant:"outline",size:"sm",className:"gap-2 border-orange-300 text-orange-600 hover:border-orange-400 hover:text-orange-700",disabled:W.isPending,children:[(0,a.jsx)(eP.A,{className:"h-4 w-4"}),"Disable Selected"]})]})]}),Object.entries(er).map(e=>{let[t,r]=e;if(s&&t!==s)return null;let l=ed.get(t),i=r.every(e=>w.has(e.id)),n=r.some(e=>w.has(e.id));return(0,a.jsxs)(en.Zp,{className:"overflow-hidden",children:[!s&&(0,a.jsx)(en.aR,{className:"pb-3",children:(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"flex items-center gap-3",children:[(0,a.jsx)(ee,{checked:i,ref:e=>{e&&"indeterminate"in e&&(e.indeterminate=n&&!i)},onCheckedChange:e=>{if(e)eJ(t);else{let e=r.map(e=>e.id),s=new Set(w);e.forEach(e=>s.delete(e)),_(s)}}}),(0,a.jsxs)("div",{children:[(0,a.jsxs)(en.ZB,{className:"flex items-center gap-2 text-lg",children:[(0,a.jsx)(J.A,{className:"h-5 w-5"}),t,(0,a.jsxs)("span",{className:"text-muted-foreground text-sm font-normal",children:["(",r.length," models)"]})]}),(0,a.jsxs)(en.BT,{children:[(null==l?void 0:l.group_url)?(0,a.jsxs)("span",{className:"flex items-center gap-1",children:[(0,a.jsx)(K.A,{className:"h-3 w-3"}),l.group_url]}):"Using default endpoint",(null==l?void 0:l.group_api_key)&&(0,a.jsxs)("span",{className:"ml-2 flex items-center gap-1",children:[(0,a.jsx)(Q.A,{className:"h-3 w-3"}),"Group API Key"]})]})]})]}),(0,a.jsx)("div",{className:"flex items-center gap-2",children:(0,a.jsxs)(eb,{children:[(0,a.jsx)(eN,{asChild:!0,children:(0,a.jsx)(h.$,{variant:"ghost",size:"sm",children:(0,a.jsx)(eR.A,{className:"h-4 w-4"})})}),(0,a.jsxs)(ew,{align:"end",children:[(0,a.jsxs)(e_,{onClick:()=>{l&&f({provider:t,models:r,groupData:l})},children:[(0,a.jsx)(q.A,{className:"mr-2 h-4 w-4"}),"Edit Group"]}),(0,a.jsxs)(e_,{onClick:()=>eJ(t),children:[(0,a.jsx)(eA.A,{className:"mr-2 h-4 w-4"}),"Select All"]}),(0,a.jsxs)(e_,{onClick:()=>eL(t),children:[(0,a.jsx)(eT.A,{className:"mr-2 h-4 w-4"}),"Refresh Models"]}),(0,a.jsx)(ek,{}),(0,a.jsxs)(e_,{onClick:()=>eQ(t),className:"text-destructive focus:text-destructive",children:[(0,a.jsx)(eF.A,{className:"mr-2 h-4 w-4"}),"Delete All Models Permanently"]})]})]})})]})}),(0,a.jsx)(en.Wu,{className:s?"pt-6":"pt-0",children:(0,a.jsx)("div",{className:"grid gap-3 md:grid-cols-2 lg:grid-cols-3",children:r.map(e=>(0,a.jsxs)(en.Zp,{className:(0,b.cn)("relative cursor-pointer overflow-hidden transition-all duration-200 hover:shadow-md",w.has(e.id)&&"ring-primary ring-2",c===e.id&&"ring-2 ring-blue-500",e.soft_deleted&&"border-red-200 bg-red-50 opacity-75"),onMouseEnter:()=>m(e.id),onMouseLeave:()=>m(null),children:[(0,a.jsx)(en.aR,{className:"pb-2",children:(0,a.jsxs)("div",{className:"flex items-start gap-2 pr-10",children:[(0,a.jsx)(ee,{checked:w.has(e.id),onCheckedChange:()=>eO(e.id),onClick:e=>e.stopPropagation(),className:"mt-1 flex-shrink-0"}),(0,a.jsxs)("div",{className:"flex w-[calc(100%-3rem)] items-start gap-2 overflow-hidden",children:[(0,a.jsx)("div",{className:"mt-1 flex-shrink-0",children:eY(e.modelType)}),(0,a.jsxs)("div",{className:"w-full overflow-hidden",children:[(0,a.jsx)("h3",{className:(0,b.cn)("overflow-hidden text-sm font-medium text-ellipsis whitespace-nowrap",e.soft_deleted&&"text-red-600 line-through"),children:e.name}),e.full_name!==e.name&&(0,a.jsx)("p",{className:"text-muted-foreground overflow-hidden text-xs text-ellipsis whitespace-nowrap",children:e.full_name})]})]}),(0,a.jsx)("div",{className:"absolute top-3 right-2",children:(0,a.jsxs)(eb,{children:[(0,a.jsx)(eN,{asChild:!0,children:(0,a.jsx)(h.$,{variant:"ghost",size:"sm",onClick:e=>e.stopPropagation(),className:"h-8 w-8 p-0",children:(0,a.jsx)(eR.A,{className:"h-4 w-4"})})}),(0,a.jsxs)(ew,{align:"end",children:[(0,a.jsxs)(e_,{onClick:s=>{s.stopPropagation(),v(e)},children:[(0,a.jsx)(q.A,{className:"mr-2 h-4 w-4"}),"Edit Model"]}),(0,a.jsx)(ek,{}),e.soft_deleted?(0,a.jsxs)(e_,{onClick:s=>{s.stopPropagation(),et.mutate(e.id)},className:"text-green-600 focus:text-green-700",children:[(0,a.jsx)(Z.A,{className:"mr-2 h-4 w-4"}),"Enable Model"]}):(0,a.jsxs)(e_,{onClick:s=>{s.stopPropagation(),eD(e.id)},className:"text-orange-600 focus:text-orange-700",children:[(0,a.jsx)(eP.A,{className:"mr-2 h-4 w-4"}),"Disable Model"]}),(0,a.jsxs)(e_,{onClick:s=>{s.stopPropagation(),eK(e.id)},className:"text-destructive focus:text-destructive",children:[(0,a.jsx)(eF.A,{className:"mr-2 h-4 w-4"}),"Delete"]})]})]})})]})}),(0,a.jsxs)(en.Wu,{className:"space-y-2 pt-0",onClick:()=>u(e.id),children:[(0,a.jsxs)("div",{className:"flex flex-wrap gap-1",children:[(0,a.jsx)("span",{className:(0,b.cn)("inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-medium",eU(e.modelType)),children:e.modelType}),"remote"===e.api_key_type&&(0,a.jsx)("span",{className:"inline-flex items-center rounded-full border border-blue-200 bg-blue-100 px-2.5 py-0.5 text-xs font-medium text-blue-800",children:"Remote"}),"remote"!==e.api_key_type&&(0,a.jsx)("span",{className:"inline-flex items-center rounded-full border border-emerald-200 bg-emerald-100 px-2.5 py-0.5 text-xs font-medium text-emerald-800",children:"Database"}),e.is_free&&(0,a.jsx)("span",{className:"inline-flex items-center rounded-full bg-yellow-100 px-2.5 py-0.5 text-xs font-medium text-yellow-800",children:"Free"}),!em(e)&&(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full bg-red-100 px-2.5 py-0.5 text-xs font-medium text-red-800",children:[(0,a.jsx)(Q.A,{className:"mr-1 h-3 w-3"}),"No API Key"]}),em(e)&&!ey(e)&&(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full bg-green-100 px-2.5 py-0.5 text-xs font-medium text-green-800",children:[(0,a.jsx)(J.A,{className:"mr-1 h-3 w-3"}),"Group Key"]}),ey(e)&&(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full bg-purple-100 px-2.5 py-0.5 text-xs font-medium text-purple-800",children:[(0,a.jsx)(Q.A,{className:"mr-1 h-3 w-3"}),"Individual Key"]}),e.soft_deleted&&(0,a.jsxs)("span",{className:"inline-flex items-center rounded-full border border-red-300 bg-red-100 px-2.5 py-0.5 text-xs font-medium text-red-800",children:[(0,a.jsx)(eF.A,{className:"mr-1 h-3 w-3"}),"Deleted"]})]}),!e.is_free&&(0,a.jsxs)("div",{className:"text-muted-foreground space-y-1 text-xs",children:[(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{className:"truncate",children:"Input:"}),(0,a.jsxs)("span",{className:"ml-2 truncate",children:[ei(e.input_cost),"/1M tokens"]})]}),(0,a.jsxs)("div",{className:"flex justify-between",children:[(0,a.jsx)("span",{className:"truncate",children:"Output:"}),(0,a.jsxs)("span",{className:"ml-2 truncate",children:[ei(e.output_cost),"/1M tokens"]})]})]}),e.description&&(0,a.jsx)("p",{className:"text-muted-foreground line-clamp-2 overflow-hidden text-xs break-words text-ellipsis",children:e.description})]})]},e.id))})})]},t)}),(0,a.jsx)(I,{isOpen:p,onModelAdd:ez,onCancel:()=>x(!1)}),g&&(0,a.jsx)(O,{model:g,providerId:g.provider_id?parseInt(g.provider_id):void 0,onModelUpdate:eE,onCancel:()=>v(null),isOpen:!!g}),j&&(0,a.jsx)($,{provider:j.provider,models:j.models,groupSettings:{group_api_key:j.groupData.group_api_key,group_url:j.groupData.group_url},onGroupUpdate:eI,onCancel:()=>f(null),isOpen:!!j}),(0,a.jsx)(el,{isOpen:y,onClose:()=>N(!1),onSuccess:eq}),(0,a.jsx)(ec,{open:k,onOpenChange:C,children:(0,a.jsxs)(ep,{children:[(0,a.jsxs)(ex,{children:[(0,a.jsx)(eg,{children:"Permanently Delete Selected Models"}),(0,a.jsxs)(ev,{children:["Are you sure you want to permanently delete ",w.size," ","selected models? This will completely remove them from the database and cannot be undone."]})]}),(0,a.jsxs)(eh,{children:[(0,a.jsx)(ef,{children:"Cancel"}),(0,a.jsx)(ej,{onClick:()=>{B.mutate(Array.from(w)),C(!1)},className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:"Delete Models"})]})]})}),(0,a.jsx)(ec,{open:S,onOpenChange:F,children:(0,a.jsxs)(ep,{children:[(0,a.jsxs)(ex,{children:[(0,a.jsxs)(eg,{children:["Apply Group Settings to"," ",w.size===P.length&&s?"All Models in ".concat(s):"Selected Models"]}),(0,a.jsxs)(ev,{children:[w.size===P.length&&s?(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{children:["Are you sure you want to force ALL ",w.size," ","models in the ",(0,a.jsx)("strong",{children:s})," group to use group settings?"]}),(0,a.jsx)("p",{className:"mt-2 text-sm text-amber-600",children:(0,a.jsx)("strong",{children:"⚠️ This will override individual model configurations:"})})]}):(0,a.jsxs)("p",{children:["Are you sure you want to apply the group settings to"," ",w.size," selected models?"]}),(0,a.jsxs)("ul",{className:"mt-2 list-inside list-disc space-y-1 text-sm",children:[(0,a.jsx)("li",{children:"Remove individual API keys (models will use the group API key)"}),(null==t?void 0:t.group_url)&&(0,a.jsxs)("li",{children:["Set the URL to:"," ",(0,a.jsx)("code",{className:"rounded bg-gray-100 px-1",children:t.group_url})]}),(0,a.jsx)("li",{children:"Force models to use group configurations"}),w.size===P.length&&s&&(0,a.jsx)("li",{className:"font-medium text-amber-600",children:"This will affect ALL models in this provider group"})]})]})]}),(0,a.jsxs)(eh,{children:[(0,a.jsx)(ef,{children:"Cancel"}),(0,a.jsx)(ej,{onClick:()=>{H.mutate(Array.from(w)),F(!1)},className:"bg-blue-600 text-white hover:bg-blue-700",children:w.size===P.length&&s?"Force All ".concat(w.size," Models"):"Apply Group Settings"})]})]})}),(0,a.jsx)(ec,{open:M,onOpenChange:A,children:(0,a.jsxs)(ep,{children:[(0,a.jsxs)(ex,{children:[(0,a.jsx)(eg,{children:"Permanently Delete All Models"}),(0,a.jsxs)(ev,{children:["Are you sure you want to permanently delete ALL models? This will completely remove all ",U.length," models from the database. This action cannot be undone."]})]}),(0,a.jsxs)(eh,{children:[(0,a.jsx)(ef,{children:"Cancel"}),(0,a.jsx)(ej,{onClick:()=>{X.mutate(),A(!1)},className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:"Delete All Models"})]})]})})]})}var eE=t(7916);u.Ik({id:u.Yj(),created_at:u.Yj(),updated_at:u.Yj(),provider:u.Yj(),group_api_key:u.Yj().optional(),group_url:u.Yj().optional()}),u.Ik({provider:u.Yj(),group_api_key:u.Yj().optional(),group_url:u.Yj().optional()}),u.Ik({provider:u.Yj().optional(),group_api_key:u.Yj().optional(),group_url:u.Yj().optional()}),u.Ik({base_endpoint:u.Yj(),api_key:u.Yj().optional(),provider_name:u.Yj(),default_input_cost:u.ai(),default_output_cost:u.ai(),default_min_cost:u.ai()}),u.Ik({collected_count:u.ai(),skipped_count:u.ai(),models:u.YO(u.bz()),errors:u.YO(u.Yj())}),u.Ik({provider_id:u.Yj()}),u.Ik({refreshed_count:u.ai(),created_count:u.ai(),restored_count:u.ai(),deleted_count:u.ai(),errors:u.YO(u.Yj())}),u.Ik({total_refreshed_count:u.ai(),total_created_count:u.ai(),total_restored_count:u.ai(),total_deleted_count:u.ai(),provider_results:u.YO(u.Ik({provider_name:u.Yj(),refreshed_count:u.ai(),created_count:u.ai(),restored_count:u.ai(),deleted_count:u.ai(),errors:u.YO(u.Yj())})),errors:u.YO(u.Yj())});let eI=u.Ik({id:u.Yj(),canonical_slug:u.Yj().optional(),hugging_face_id:u.Yj().optional(),name:u.Yj().optional(),created:u.ai(),description:u.Yj().optional(),context_length:u.ai().optional(),architecture:u.bz().optional(),pricing:u.bz().optional(),top_provider:u.bz().optional(),per_request_limits:u.bz().optional(),supported_parameters:u.YO(u.Yj()).optional(),provider_url:u.Yj(),provider_name:u.Yj().optional(),group_id:u.Yj().optional()});function eq(e,s){var t,a;return{id:e.id,name:e.name,full_name:e.full_name,description:e.description,modelType:e.model_type||"text",isEnabled:!e.soft_deleted,createdAt:e.created_at,updatedAt:e.updated_at,provider:e.provider||s||"",url:e.url,api_key:e.api_key,input_cost:Number(e.input_cost),output_cost:Number(e.output_cost),min_cost_per_request:Number(e.min_cost_per_request||"0"),min_cash_per_request:Number(e.min_cash_per_request||"0"),contextLength:e.context_length,apiKeyRequired:!0,provider_id:e.provider_id,is_free:null!=(t=e.is_free)&&t,soft_deleted:null!=(a=e.soft_deleted)&&a,has_own_api_key:e.has_own_api_key,api_key_type:e.api_key_type}}u.Ik({object:u.Yj(),data:u.YO(eI)}),u.Ik({id:u.Yj(),created_at:u.Yj(),updated_at:u.Yj(),full_name:u.Yj(),name:u.Yj(),url:u.Yj(),input_cost:u.Yj(),output_cost:u.Yj(),api_key:u.Yj().optional(),min_cash_per_request:u.Yj(),min_cost_per_request:u.Yj().optional(),provider_id:u.Yj().optional(),provider:u.Yj().optional(),soft_deleted:u.zM().optional(),architecture:u.bz().optional(),model_type:u.Yj().optional(),description:u.Yj().optional(),context_length:u.ai().optional(),is_free:u.zM().optional(),has_own_api_key:u.zM(),api_key_type:u.Yj()});class eL{static async createModelGroup(e){return await eE.apiClient.post("/api/model-groups",{provider:e.provider,group_api_key:e.group_api_key,group_url:e.group_url})}static async getModelGroups(){return await eE.apiClient.get("/api/model-groups")}static async getModelGroup(e){return await eE.apiClient.get("/api/model-groups/".concat(e))}static async updateModelGroup(e,s){return await eE.apiClient.put("/api/model-groups/".concat(e),{provider:s.provider,group_api_key:s.group_api_key,group_url:s.group_url})}static async deleteModelGroup(e){return await eE.apiClient.delete("/api/model-groups/".concat(e))}static async createModel(e){let s={full_name:e.name,name:e.name,url:e.url,api_key:e.api_key,input_cost:e.input_cost,output_cost:e.output_cost,min_cost_per_request:e.min_cost_per_request,min_cash_per_request:e.min_cash_per_request,provider:e.provider,model_type:e.modelType,description:e.description,context_length:e.contextLength,is_free:e.is_free};return eq(await eE.apiClient.post("/api/models",s))}static async getModels(){return(await eE.apiClient.get("/api/models")).map(e=>eq(e))}static async getModel(e){return eq(await eE.apiClient.get("/api/models/".concat(e)))}static async getModelsByProvider(e){return(await eE.apiClient.get("/api/models/provider/".concat(e))).map(e=>eq(e))}static async updateModel(e,s){let t={name:s.name,url:s.url,api_key:s.api_key,input_cost:s.input_cost,output_cost:s.output_cost,min_cost_per_request:s.min_cost_per_request,min_cash_per_request:s.min_cash_per_request,provider:s.provider,model_type:s.modelType,description:s.description,context_length:s.contextLength,is_free:s.is_free};return eq(await eE.apiClient.put("/api/models/".concat(e),t))}static async deleteModel(e){return await eE.apiClient.delete("/api/models/".concat(e))}static async softDeleteModel(e){return await eE.apiClient.put("/api/models/".concat(e,"/soft-delete"),{})}static async deleteModels(e){return await eE.apiClient.post("/api/models/bulk/delete",{model_ids:e})}static async softDeleteModels(e){return await eE.apiClient.post("/api/models/bulk/soft-delete",{model_ids:e})}static async bulkUpdateModels(e,s){return await eE.apiClient.post("/api/models/bulk/update",{model_ids:e,api_key:s.api_key,url:s.url})}static async deleteAllModels(){return await eE.apiClient.post("/api/models/all/delete",{})}static async deleteModelsByProvider(e){return await eE.apiClient.post("/api/models/provider/".concat(e,"/delete"),{})}static async restoreModels(e){return await eE.apiClient.post("/api/models/bulk/restore",{model_ids:e})}static async getSoftDeletedModels(){return(await eE.apiClient.get("/api/models/deleted")).map(e=>eq(e))}static async collectModels(e){return await eE.apiClient.post("/api/models/collect",e)}static async getModelsWithProviders(){let[e,s]=await Promise.all([eE.apiClient.get("/api/models"),this.getModelGroups()]),t=new Map(s.map(e=>[e.id,e.provider]));return{models:e.map(e=>eq(e,t.get(e.provider_id||"")||"Unknown")),groups:s}}static async listModels(e){let{models:s}=await this.getModelsWithProviders();return(null==e?void 0:e.enabled)!==!1?s.filter(e=>e.isEnabled):s}static async getModelInfo(e){return await this.getModel(e)}static async refreshModels(e){return await eE.apiClient.post("/api/models/refresh",e)}static async refreshAllModels(){return await eE.apiClient.post("/api/models/refresh-all",{})}static async getEnhancedModels(){return await eE.apiClient.get("/api/enhanced-models")}static async getEnhancedModelsByProvider(e){return await eE.apiClient.get("/api/enhanced-models/".concat(encodeURIComponent(e)))}static downloadModelsAsJson(e){let s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"models.json",t=new Blob([JSON.stringify(e,null,2)],{type:"application/json"}),a=URL.createObjectURL(t),r=document.createElement("a");r.href=a,r.download=s,r.click(),URL.revokeObjectURL(a)}static async downloadAllEnhancedModels(){try{let e=await this.getEnhancedModels();this.downloadModelsAsJson(e,"enhanced-models-all.json")}catch(e){throw console.error("Error downloading all enhanced models:",e),e}}static async downloadEnhancedModelsByProvider(e){try{let s=await this.getEnhancedModelsByProvider(e);this.downloadModelsAsJson(s,"enhanced-models-".concat(e.toLowerCase(),".json"))}catch(s){throw console.error("Error downloading enhanced models for provider ".concat(e,":"),s),s}}static async testModel(e,s,t){return await eE.apiClient.post("/api/models/test",{model_id:e,endpoint_type:s,request_data:t})}}var eY=t(2390),eU=t(4717);function eO(e){var s,t;let{models:l}=e,[o,d]=(0,r.useState)(""),[c,u]=(0,r.useState)("You are a helpful assistant. Please respond concisely."),[m,p]=(0,r.useState)("Hello! Can you tell me what model you are and confirm that you are working correctly?"),[x,g]=(0,r.useState)(150),[j,y]=(0,r.useState)(.7),[b,w]=(0,r.useState)(null),[_,k]=(0,r.useState)(null),{data:C=[]}=(0,i.I)({queryKey:["model-groups"],queryFn:()=>eL.getModelGroups(),refetchOnWindowFocus:!1}),M=l.find(e=>e.id===o),A=(0,n.n)({mutationFn:async e=>{if(!M)throw Error("No model selected");k(null),w(null);try{console.log("Testing model via proxy: ".concat(M.name)),console.log("Request payload:",e);let s=await eL.testModel(M.id,"chat-completions",e);if(!s.success)throw Error(s.error||"Test failed");return s.data}catch(e){throw console.error("Model test error via proxy:",e),Error(e instanceof Error?e.message:"Failed to test model via proxy")}},onSuccess:e=>{w(e),E.oR.success("Model test completed successfully!")},onError:e=>{let s=(null==e?void 0:e.message)||"Unknown error occurred";k(s),E.oR.error("Model test failed: ".concat(s))}}),S=async()=>{if(!M)return void E.oR.error("Please select a model to test");if(!m.trim())return void E.oR.error("Please enter a test message");let e=[];c.trim()&&e.push({role:"system",content:c.trim()}),e.push({role:"user",content:m.trim()});let s={model:M.name,messages:e,max_tokens:x,temperature:j};A.mutate(s)},F=l.filter(e=>e.isEnabled),P=M?(e=>{let s=C.find(s=>s.provider===e.provider),t=e.api_key||(null==s?void 0:s.group_api_key),a=e.url;return e.url.startsWith("/")&&(null==s?void 0:s.group_url)&&(a="".concat(s.group_url.replace(/\/$/,"")).concat(e.url)),"text"!==e.modelType||a.includes("/chat/completions")||(a=a.replace(/\/$/,"")+"/chat/completions"),{apiKey:t,endpointUrl:a,group:s}})(M):null;return(0,a.jsxs)(en.Zp,{className:"w-full",children:[(0,a.jsxs)(en.aR,{children:[(0,a.jsxs)(en.ZB,{className:"flex items-center gap-2",children:[(0,a.jsx)(eY.A,{className:"h-5 w-5"}),"Model Credential Tester"]}),(0,a.jsx)(en.BT,{children:"Test model functionality by sending chat completion requests through the secure proxy (resolves CORS and network issues)"})]}),(0,a.jsxs)(en.Wu,{className:"space-y-6",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"model-select",children:"Select Model"}),(0,a.jsxs)(f.l6,{value:o,onValueChange:d,children:[(0,a.jsx)(f.bq,{id:"model-select",children:(0,a.jsx)(f.yv,{placeholder:"Choose a model to test..."})}),(0,a.jsx)(f.gC,{children:F.map(e=>(0,a.jsx)(f.eb,{value:e.id,children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{children:e.name}),(0,a.jsx)(er.E,{variant:"outline",className:"text-xs",children:e.provider}),e.is_free&&(0,a.jsx)(er.E,{variant:"secondary",className:"text-xs",children:"Free"})]})},e.id))})]}),M&&P&&(0,a.jsxs)("div",{className:"text-muted-foreground bg-muted space-y-2 rounded-md p-3 text-sm",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(K.A,{className:"h-4 w-4"}),(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Endpoint:"})," ",P.endpointUrl]})]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(Q.A,{className:"h-4 w-4"}),(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"API Key:"})," ",P.apiKey?"".concat(P.apiKey.substring(0,8),"..."):"Not configured"]}),(0,a.jsx)(er.E,{variant:P.apiKey?"default":"destructive",className:"text-xs",children:M.api_key_type||"Unknown"})]}),(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Provider:"})," ",M.provider]})}),(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Type:"})," ",M.modelType]})}),M.contextLength&&(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Context Length:"})," ",M.contextLength.toLocaleString()]})}),!P.apiKey&&(0,a.jsxs)(V.Fc,{variant:"default",className:"mt-2",children:[(0,a.jsx)(G.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"No API key configured for this model. Testing may still work if the model is free or if authentication is handled elsewhere. For models requiring authentication, please add an API key to the model or its provider group."})]})]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"max-tokens",children:"Max Tokens"}),(0,a.jsx)("input",{id:"max-tokens",type:"number",min:1,max:4e3,value:x,onChange:e=>g(parseInt(e.target.value)||150),className:"border-input bg-background w-full rounded-md border px-3 py-2 text-sm"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"temperature",children:"Temperature"}),(0,a.jsx)("input",{id:"temperature",type:"number",min:0,max:2,step:.1,value:j,onChange:e=>y(parseFloat(e.target.value)||.7),className:"border-input bg-background w-full rounded-md border px-3 py-2 text-sm"})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"system-message",children:"System Message (Optional)"}),(0,a.jsx)(v.T,{id:"system-message",placeholder:"Enter system message...",value:c,onChange:e=>u(e.target.value),rows:2})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"user-message",children:"Test Message"}),(0,a.jsx)(v.T,{id:"user-message",placeholder:"Enter your test message...",value:m,onChange:e=>p(e.target.value),rows:3})]}),(0,a.jsx)(h.$,{onClick:S,disabled:!o||A.isPending,className:"w-full",children:A.isPending?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Testing Model..."]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(eY.A,{className:"mr-2 h-4 w-4"}),"Test Model (via Proxy)"]})}),_&&(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(eU.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Test Failed:"})," ",_]})]}),b&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(Z.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Test Successful!"})," Model responded correctly via secure proxy."]})]}),b&&(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Model Response"}),(0,a.jsx)("div",{className:"bg-muted rounded-md p-4",children:(0,a.jsx)("p",{className:"text-sm whitespace-pre-wrap",children:(null==(t=b.choices[0])||null==(s=t.message)?void 0:s.content)||"No content in response"})})]}),b.usage&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Usage Statistics"}),(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-4 text-sm",children:[(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:b.usage.prompt_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Prompt Tokens"})]}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:b.usage.completion_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Completion Tokens"})]}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:b.usage.total_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Total Tokens"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Raw Response"}),(0,a.jsxs)("details",{className:"group",children:[(0,a.jsxs)("summary",{className:"text-muted-foreground hover:text-foreground cursor-pointer text-sm",children:[(0,a.jsx)(G.A,{className:"mr-1 inline h-4 w-4"}),"Show detailed response data"]}),(0,a.jsx)("pre",{className:"bg-muted mt-2 max-h-60 overflow-auto rounded-md p-4 text-xs",children:JSON.stringify(b,null,2)})]})]})]})]})]})}var eJ=t(4938),eQ=t(7137),eK=t(9472),eD=t(413),eG=t(9911),eV=t(4713),e$=t(9935),eB=t(8019);let eW={"chat-completions":{name:"Chat Completions",path:"/chat/completions",icon:eJ.A,description:"Test conversational AI with chat completion requests"},"vision-chat":{name:"Vision Chat (Image + Text)",path:"/chat/completions",icon:eQ.A,description:"Analyze images with text prompts using vision models"},embeddings:{name:"Embeddings",path:"/embeddings",icon:eK.A,description:"Generate embeddings for text input"},images:{name:"Image Generation",path:"/images/generations",icon:eD.A,description:"Generate images from text prompts"},"audio-speech":{name:"Text-to-Speech",path:"/audio/speech",icon:eG.A,description:"Convert text to speech audio"},"audio-transcription":{name:"Audio Transcription",path:"/audio/transcriptions",icon:eV.A,description:"Transcribe audio files to text"},models:{name:"List Models",path:"/model",icon:eK.A,description:"List all available models from the provider"}},eZ={"chat-completions":{systemMessage:"You are a helpful assistant. Please respond concisely.",userMessage:"Hello! Can you tell me what model you are and confirm that you are working correctly?",maxTokens:150,temperature:.7},"vision-chat":{systemMessage:"You are a helpful assistant that can analyze images. Please describe what you see.",userMessage:"What do you see in this image? Please provide a detailed description.",maxTokens:300,temperature:.7,imageDetail:"auto"},embeddings:{input:"The quick brown fox jumps over the lazy dog.",encoding_format:"float"},images:{prompt:"A beautiful sunset over a mountain landscape",n:1,size:"1024x1024",quality:"standard",style:"vivid"},"audio-speech":{input:"Hello, this is a test of the text-to-speech functionality.",voice:"alloy",response_format:"mp3",speed:1},"audio-transcription":{prompt:"This is a test transcription.",response_format:"json",temperature:0,language:""}};function eH(e){var s,t,l,o,d,c,u,m,p,x,j;let y,b,w,_,k,C,{models:M}=e,[A,S]=(0,r.useState)(""),[F,P]=(0,r.useState)("chat-completions"),[R,T]=(0,r.useState)(null),[I,q]=(0,r.useState)(null),[L,Y]=(0,r.useState)(eZ["chat-completions"].systemMessage),[U,O]=(0,r.useState)(eZ["chat-completions"].userMessage),[J,D]=(0,r.useState)(eZ["chat-completions"].maxTokens),[$,B]=(0,r.useState)(eZ["chat-completions"].temperature),[W,H]=(0,r.useState)(eZ["vision-chat"].systemMessage),[X,ee]=(0,r.useState)(eZ["vision-chat"].userMessage),[es,et]=(0,r.useState)(eZ["vision-chat"].maxTokens),[ea,el]=(0,r.useState)(eZ["vision-chat"].temperature),[ei,eo]=(0,r.useState)(eZ["vision-chat"].imageDetail),[ed,ec]=(0,r.useState)(null),[eu,em]=(0,r.useState)(null),[ep,ex]=(0,r.useState)(!1),[eh,eg]=(0,r.useState)(null),[ev,ej]=(0,r.useState)(null),[ef,ey]=(0,r.useState)(null),[eb,eN]=(0,r.useState)(eZ["audio-transcription"].prompt),[ew,e_]=(0,r.useState)(eZ["audio-transcription"].response_format),[ek,eC]=(0,r.useState)(eZ["audio-transcription"].temperature),[eM,eA]=(0,r.useState)(eZ["audio-transcription"].language),eS=(0,r.useRef)(null),eF=(0,r.useRef)(null),[eP,eR]=(0,r.useState)(eZ.embeddings.input),[eT,ez]=(0,r.useState)(eZ.embeddings.encoding_format),[eE,eI]=(0,r.useState)(eZ.images.prompt),[eq,eO]=(0,r.useState)(eZ.images.n),[eJ,eQ]=(0,r.useState)(eZ.images.size),[eH,eX]=(0,r.useState)(eZ.images.quality),[e0,e2]=(0,r.useState)(eZ.images.style),[e4,e1]=(0,r.useState)(eZ["audio-speech"].input),[e3,e5]=(0,r.useState)(eZ["audio-speech"].voice),[e6,e9]=(0,r.useState)(eZ["audio-speech"].response_format),[e8,e7]=(0,r.useState)(eZ["audio-speech"].speed),{data:se=[]}=(0,i.I)({queryKey:["model-groups"],queryFn:()=>eL.getModelGroups(),refetchOnWindowFocus:!1}),ss=M.find(e=>e.id===A),st=e=>{var s;let t=null==(s=e.target.files)?void 0:s[0];t&&(t.type.startsWith("image/")?(ec(t),em(URL.createObjectURL(t))):E.oR.error("Please select a valid image file"))},sa=e=>{var s;let t=null==(s=e.target.files)?void 0:s[0];t&&(t.type.startsWith("audio/")?(eg(t),ej(URL.createObjectURL(t))):E.oR.error("Please select a valid audio file"))},sr=async()=>{try{let e=await navigator.mediaDevices.getUserMedia({audio:!0}),s=new MediaRecorder(e),t=[];s.ondataavailable=e=>{e.data.size>0&&t.push(e.data)},s.onstop=()=>{let s=new Blob(t,{type:"audio/webm"}),a=new File([s],"recording.webm",{type:"audio/webm"});eg(a);let r=URL.createObjectURL(s);ej(r),e.getTracks().forEach(e=>e.stop())},s.start(),ey(s),ex(!0),E.oR.success("Recording started")}catch(e){console.error("Error starting recording:",e),E.oR.error("Failed to start recording. Please check microphone permissions.")}},sl=()=>{ef&&(ef.stop(),ey(null),ex(!1),E.oR.success("Recording stopped"))},si=e=>new Promise((s,t)=>{let a=new FileReader;a.readAsDataURL(e),a.onload=()=>s(a.result),a.onerror=e=>t(e)}),sn=async()=>{if(!ss)return null;switch(F){case"chat-completions":let e=[];return L.trim()&&e.push({role:"system",content:L.trim()}),e.push({role:"user",content:U.trim()}),{model:ss.name,messages:e,max_tokens:J,temperature:$};case"vision-chat":if(!ed)throw Error("Please select an image for vision analysis");let s=await si(ed),t=[];return W.trim()&&t.push({role:"system",content:W.trim()}),t.push({role:"user",content:[{type:"text",text:X.trim()},{type:"image_url",image_url:{url:s,detail:ei}}]}),{model:ss.name,messages:t,max_tokens:es,temperature:ea};case"embeddings":return{model:ss.name,input:eP,encoding_format:eT};case"images":return{model:ss.name,prompt:eE,n:eq,size:eJ,quality:eH,style:e0};case"audio-speech":return{model:ss.name,input:e4,voice:e3,response_format:e6,speed:e8};case"audio-transcription":if(!eh)throw Error("Please record or upload an audio file for transcription");return{model:ss.name,file:eh,prompt:eb.trim()||void 0,response_format:ew,temperature:ek,language:eM.trim()||void 0};default:return null}},so=(0,n.n)({mutationFn:async e=>{if(!ss)throw Error("No model selected");q(null),T(null);try{console.log("Testing endpoint via proxy: ".concat(F)),console.log("Request payload:",e);let s=await eL.testModel(ss.id,F,e);if(!s.success)throw Error(s.error||"Test failed");return s.data}catch(e){throw console.error("API endpoint test error via proxy:",e),Error(e instanceof Error?e.message:"Failed to test endpoint via proxy")}},onSuccess:e=>{T(e),E.oR.success("".concat(eW[F].name," test completed successfully!"))},onError:e=>{let s=(null==e?void 0:e.message)||"Unknown error occurred";q(s),E.oR.error("".concat(eW[F].name," test failed: ").concat(s))}}),sd=async()=>{if(!ss)return void E.oR.error("Please select a model to test");if("chat-completions"===F&&!U.trim())return void E.oR.error("Please enter a test message");if("vision-chat"===F){if(!X.trim())return void E.oR.error("Please enter a test message");if(!ed)return void E.oR.error("Please select an image for vision analysis")}if("embeddings"===F&&!eP.trim())return void E.oR.error("Please enter text for embedding");if("images"===F&&!eE.trim())return void E.oR.error("Please enter an image prompt");if("audio-speech"===F&&!e4.trim())return void E.oR.error("Please enter text for speech synthesis");if("audio-transcription"===F&&!eh)return void E.oR.error("Please record or upload an audio file for transcription");let e=await sn();so.mutate(e)},sc=M.filter(e=>e.isEnabled),su=ss?(e=>{let s=se.find(s=>s.provider===e.provider),t=e.api_key||(null==s?void 0:s.group_api_key),a=e.url;return e.url.startsWith("/")&&(null==s?void 0:s.group_url)&&(a="".concat(s.group_url.replace(/\/$/,"")).concat(e.url)),{apiKey:t,baseUrl:a=a.replace(/\/v1\/.*$/,"").replace(/\/$/,""),group:s}})(ss):null,sm=su?(k=su.baseUrl,C=eW[F].path,"".concat(k).concat(C)):"";return(0,a.jsxs)(en.Zp,{className:"w-full",children:[(0,a.jsxs)(en.aR,{children:[(0,a.jsxs)(en.ZB,{className:"flex items-center gap-2",children:[(0,a.jsx)(eY.A,{className:"h-5 w-5"}),"API Endpoint Tester"]}),(0,a.jsx)(en.BT,{children:"Comprehensive testing of OpenAI-compatible API endpoints through the secure proxy (resolves CORS and network issues)"})]}),(0,a.jsxs)(en.Wu,{className:"space-y-6",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"model-select",children:"Select Model"}),(0,a.jsxs)(f.l6,{value:A,onValueChange:S,children:[(0,a.jsx)(f.bq,{id:"model-select",children:(0,a.jsx)(f.yv,{placeholder:"Choose a model to test..."})}),(0,a.jsx)(f.gC,{children:sc.map(e=>(0,a.jsx)(f.eb,{value:e.id,children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{children:e.name}),(0,a.jsx)(er.E,{variant:"outline",className:"text-xs",children:e.provider}),e.is_free&&(0,a.jsx)(er.E,{variant:"secondary",className:"text-xs",children:"Free"})]})},e.id))})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"endpoint-select",children:"API Endpoint"}),(0,a.jsxs)(f.l6,{value:F,onValueChange:e=>P(e),children:[(0,a.jsx)(f.bq,{id:"endpoint-select",children:(0,a.jsx)(f.yv,{})}),(0,a.jsx)(f.gC,{children:Object.entries(eW).map(e=>{let[s,t]=e,r=t.icon;return(0,a.jsx)(f.eb,{value:s,children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(r,{className:"h-4 w-4"}),(0,a.jsx)("span",{children:t.name})]})},s)})})]})]})]}),ss&&su&&(0,a.jsxs)("div",{className:"text-muted-foreground bg-muted space-y-2 rounded-md p-3 text-sm",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(K.A,{className:"h-4 w-4"}),(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Endpoint:"})," ",sm]})]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(Q.A,{className:"h-4 w-4"}),(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"API Key:"})," ",su.apiKey?"".concat(su.apiKey.substring(0,8),"..."):"Not configured"]}),(0,a.jsx)(er.E,{variant:su.apiKey?"default":"destructive",className:"text-xs",children:ss.api_key_type||"Unknown"})]}),(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Provider:"})," ",ss.provider]})}),(0,a.jsx)("div",{children:(0,a.jsxs)("span",{children:[(0,a.jsx)("strong",{children:"Description:"})," ",eW[F].description]})}),!su.apiKey&&(0,a.jsxs)(V.Fc,{variant:"default",className:"mt-2",children:[(0,a.jsx)(G.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"No API key configured for this model. Testing may still work if the model is free or if authentication is handled elsewhere. For models requiring authentication, please add an API key to the model or its provider group."})]})]}),(()=>{switch(F){case"chat-completions":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"max-tokens",children:"Max Tokens"}),(0,a.jsx)(g.p,{id:"max-tokens",type:"number",min:1,max:4e3,value:J,onChange:e=>D(parseInt(e.target.value)||150)})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"temperature",children:"Temperature"}),(0,a.jsx)(g.p,{id:"temperature",type:"number",min:0,max:2,step:.1,value:$,onChange:e=>B(parseFloat(e.target.value)||.7)})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"system-message",children:"System Message (Optional)"}),(0,a.jsx)(v.T,{id:"system-message",placeholder:"Enter system message...",value:L,onChange:e=>Y(e.target.value),rows:2})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"user-message",children:"Test Message"}),(0,a.jsx)(v.T,{id:"user-message",placeholder:"Enter your test message...",value:U,onChange:e=>O(e.target.value),rows:3})]})]});case"vision-chat":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"vision-max-tokens",children:"Max Tokens"}),(0,a.jsx)(g.p,{id:"vision-max-tokens",type:"number",min:1,max:4e3,value:es,onChange:e=>et(parseInt(e.target.value)||300)})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"vision-temperature",children:"Temperature"}),(0,a.jsx)(g.p,{id:"vision-temperature",type:"number",min:0,max:2,step:.1,value:ea,onChange:e=>el(parseFloat(e.target.value)||.7)})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"vision-system-message",children:"System Message (Optional)"}),(0,a.jsx)(v.T,{id:"vision-system-message",placeholder:"Enter system message...",value:W,onChange:e=>H(e.target.value),rows:2})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"vision-user-message",children:"Test Message"}),(0,a.jsx)(v.T,{id:"vision-user-message",placeholder:"Enter your test message...",value:X,onChange:e=>ee(e.target.value),rows:3})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-detail",children:"Image Detail"}),(0,a.jsxs)(f.l6,{value:ei,onValueChange:e=>eo(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"low",children:"Low"}),(0,a.jsx)(f.eb,{value:"high",children:"High"}),(0,a.jsx)(f.eb,{value:"auto",children:"Auto"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-upload",children:"Upload Image (Optional)"}),(0,a.jsx)(g.p,{type:"file",accept:"image/*",onChange:st,ref:eS,className:"file:mr-4 file:rounded-full file:border-0 file:bg-blue-50 file:px-4 file:py-2 file:text-sm file:font-semibold file:text-blue-700 hover:file:bg-blue-100"}),ed&&(0,a.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[(0,a.jsx)(eD.A,{className:"h-5 w-5 text-blue-500"}),(0,a.jsxs)("span",{className:"text-muted-foreground text-sm",children:["Selected image: ",ed.name]}),(0,a.jsx)(h.$,{variant:"outline",size:"sm",onClick:()=>ec(null),className:"ml-auto",children:"Remove"})]}),eu&&(0,a.jsx)("div",{className:"relative mt-2 aspect-square w-32 overflow-hidden rounded-md border",children:(0,a.jsx)(eB.default,{src:eu,alt:"Image preview",fill:!0,className:"object-cover"})})]})]});case"embeddings":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"encoding-format",children:"Encoding Format"}),(0,a.jsxs)(f.l6,{value:eT,onValueChange:e=>ez(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"float",children:"Float"}),(0,a.jsx)(f.eb,{value:"base64",children:"Base64"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"embedding-input",children:"Text Input"}),(0,a.jsx)(v.T,{id:"embedding-input",placeholder:"Enter text to generate embeddings for...",value:eP,onChange:e=>eR(e.target.value),rows:4})]})]});case"images":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2 lg:grid-cols-3",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-count",children:"Number of Images"}),(0,a.jsx)(g.p,{id:"image-count",type:"number",min:1,max:10,value:eq,onChange:e=>eO(parseInt(e.target.value)||1)})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-size",children:"Size"}),(0,a.jsxs)(f.l6,{value:eJ,onValueChange:e=>eQ(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"256x256",children:"256x256"}),(0,a.jsx)(f.eb,{value:"512x512",children:"512x512"}),(0,a.jsx)(f.eb,{value:"1024x1024",children:"1024x1024"}),(0,a.jsx)(f.eb,{value:"1792x1024",children:"1792x1024"}),(0,a.jsx)(f.eb,{value:"1024x1792",children:"1024x1792"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-quality",children:"Quality"}),(0,a.jsxs)(f.l6,{value:eH,onValueChange:e=>eX(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"standard",children:"Standard"}),(0,a.jsx)(f.eb,{value:"hd",children:"HD"})]})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-style",children:"Style"}),(0,a.jsxs)(f.l6,{value:e0,onValueChange:e=>e2(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"vivid",children:"Vivid"}),(0,a.jsx)(f.eb,{value:"natural",children:"Natural"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"image-prompt",children:"Image Prompt"}),(0,a.jsx)(v.T,{id:"image-prompt",placeholder:"Describe the image you want to generate...",value:eE,onChange:e=>eI(e.target.value),rows:3})]})]});case"audio-speech":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-3",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"speech-voice",children:"Voice"}),(0,a.jsxs)(f.l6,{value:e3,onValueChange:e=>e5(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"alloy",children:"Alloy"}),(0,a.jsx)(f.eb,{value:"echo",children:"Echo"}),(0,a.jsx)(f.eb,{value:"fable",children:"Fable"}),(0,a.jsx)(f.eb,{value:"onyx",children:"Onyx"}),(0,a.jsx)(f.eb,{value:"nova",children:"Nova"}),(0,a.jsx)(f.eb,{value:"shimmer",children:"Shimmer"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"speech-format",children:"Response Format"}),(0,a.jsxs)(f.l6,{value:e6,onValueChange:e=>e9(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"mp3",children:"MP3"}),(0,a.jsx)(f.eb,{value:"opus",children:"Opus"}),(0,a.jsx)(f.eb,{value:"aac",children:"AAC"}),(0,a.jsx)(f.eb,{value:"flac",children:"FLAC"}),(0,a.jsx)(f.eb,{value:"wav",children:"WAV"}),(0,a.jsx)(f.eb,{value:"pcm",children:"PCM"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"speech-speed",children:"Speed"}),(0,a.jsx)(g.p,{id:"speech-speed",type:"number",min:.25,max:4,step:.25,value:e8,onChange:e=>e7(parseFloat(e.target.value)||1)})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"speech-input",children:"Text to Synthesize"}),(0,a.jsx)(v.T,{id:"speech-input",placeholder:"Enter text to convert to speech...",value:e4,onChange:e=>e1(e.target.value),rows:4})]})]});case"audio-transcription":return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-prompt",children:"Prompt (Optional)"}),(0,a.jsx)(v.T,{id:"audio-transcription-prompt",placeholder:"Enter a prompt for the transcription...",value:eb,onChange:e=>eN(e.target.value),rows:2})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-temperature",children:"Temperature"}),(0,a.jsx)(g.p,{id:"audio-transcription-temperature",type:"number",min:0,max:1,step:.1,value:ek,onChange:e=>eC(parseFloat(e.target.value)||0)})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-language",children:"Language (Optional)"}),(0,a.jsx)(g.p,{id:"audio-transcription-language",placeholder:"e.g., en-US, fr-FR",value:eM,onChange:e=>eA(e.target.value)})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-response-format",children:"Response Format"}),(0,a.jsxs)(f.l6,{value:ew,onValueChange:e=>e_(e),children:[(0,a.jsx)(f.bq,{children:(0,a.jsx)(f.yv,{})}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"json",children:"JSON"}),(0,a.jsx)(f.eb,{value:"text",children:"Text"}),(0,a.jsx)(f.eb,{value:"srt",children:"SRT"}),(0,a.jsx)(f.eb,{value:"verbose_json",children:"Verbose JSON"}),(0,a.jsx)(f.eb,{value:"vtt",children:"VTT"})]})]})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Voice Recording"}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(h.$,{type:"button",variant:ep?"destructive":"default",size:"sm",onClick:ep?sl:sr,className:"flex items-center gap-2",children:ep?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(e$.A,{className:"h-4 w-4"}),"Stop Recording"]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(eG.A,{className:"h-4 w-4"}),"Start Recording"]})}),ep&&(0,a.jsxs)("div",{className:"flex items-center gap-2 text-red-600",children:[(0,a.jsx)("div",{className:"h-2 w-2 animate-pulse rounded-full bg-red-600"}),(0,a.jsx)("span",{className:"text-sm",children:"Recording..."})]})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{htmlFor:"audio-transcription-upload",children:"Or Upload Audio File"}),(0,a.jsx)(g.p,{type:"file",accept:"audio/*",onChange:sa,ref:eF,className:"file:mr-4 file:rounded-full file:border-0 file:bg-blue-50 file:px-4 file:py-2 file:text-sm file:font-semibold file:text-blue-700 hover:file:bg-blue-100"}),eh&&(0,a.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[(0,a.jsx)(eV.A,{className:"h-5 w-5 text-blue-500"}),(0,a.jsxs)("span",{className:"text-muted-foreground text-sm",children:["Selected audio: ",eh.name]}),(0,a.jsx)(h.$,{variant:"outline",size:"sm",onClick:()=>{eg(null),ej(null)},className:"ml-auto",children:"Remove"})]}),ev&&(0,a.jsx)("div",{className:"bg-muted mt-2 rounded-md p-4",children:(0,a.jsx)("audio",{controls:!0,src:ev,className:"w-full",children:"Your browser does not support the audio element."})})]})]})]});case"models":return(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(eK.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"This endpoint lists all available models from the provider. No additional parameters are required."})]})});default:return null}})(),(0,a.jsx)(h.$,{onClick:sd,disabled:!A||so.isPending,className:"w-full",children:so.isPending?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(z.A,{className:"mr-2 h-4 w-4 animate-spin"}),"Testing ",eW[F].name,"..."]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(eY.A,{className:"mr-2 h-4 w-4"}),"Test ",eW[F].name]})}),I&&(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(eU.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Test Failed:"})," ",I]})]}),R&&(0,a.jsxs)(V.Fc,{children:[(0,a.jsx)(Z.A,{className:"h-4 w-4"}),(0,a.jsxs)(V.TN,{children:[(0,a.jsx)("strong",{children:"Test Successful!"})," ",eW[F].name," endpoint responded correctly."]})]}),R&&(R?"type"in(y=R)&&"audio"===y.type?(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Generated Audio"}),(0,a.jsxs)("div",{className:"bg-muted rounded-md p-4",children:[(0,a.jsx)("audio",{controls:!0,src:R.url,className:"w-full",children:"Your browser does not support the audio element."}),(0,a.jsxs)("p",{className:"text-muted-foreground mt-2 text-sm",children:["Audio file size: ",(R.size/1024).toFixed(2)," KB"]})]})]})}):"text"in R?(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Transcription Result"}),(0,a.jsx)("div",{className:"bg-muted rounded-md p-4",children:(0,a.jsx)("p",{className:"text-sm whitespace-pre-wrap",children:R.text||"No transcription result available"})})]})}):"choices"in R?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Model Response"}),(0,a.jsx)("div",{className:"bg-muted rounded-md p-4",children:(0,a.jsx)("p",{className:"text-sm whitespace-pre-wrap",children:(null==(l=R.choices)||null==(t=l[0])||null==(s=t.message)?void 0:s.content)||"No content in response"})})]}),R.usage&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Usage Statistics"}),(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-4 text-sm",children:[(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:R.usage.prompt_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Prompt Tokens"})]}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:R.usage.completion_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Completion Tokens"})]}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center",children:[(0,a.jsx)("div",{className:"font-semibold",children:R.usage.total_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Total Tokens"})]})]})]})]}):"data"in(b=R)&&Array.isArray(b.data)&&b.data.length>0&&"embedding"in b.data[0]?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Embedding Vector"}),(0,a.jsxs)("div",{className:"bg-muted rounded-md p-4",children:[(0,a.jsxs)("p",{className:"text-muted-foreground mb-2 text-sm",children:["Generated ",(null==(c=R.data)||null==(d=c[0])||null==(o=d.embedding)?void 0:o.length)||0," ","dimensional embedding vector"]}),(0,a.jsxs)("details",{className:"group",children:[(0,a.jsx)("summary",{className:"hover:text-foreground cursor-pointer text-sm",children:"Show first 10 values"}),(0,a.jsxs)("pre",{className:"mt-2 text-xs",children:[JSON.stringify(null==(p=R.data)||null==(m=p[0])||null==(u=m.embedding)?void 0:u.slice(0,10),null,2),"..."]})]})]})]}),R.usage&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Usage Statistics"}),(0,a.jsxs)("div",{className:"bg-muted rounded p-2 text-center text-sm",children:[(0,a.jsx)("div",{className:"font-semibold",children:R.usage.total_tokens}),(0,a.jsx)("div",{className:"text-muted-foreground",children:"Total Tokens"})]})]})]}):"data"in(w=R)&&Array.isArray(w.data)&&w.data.length>0&&"url"in w.data[0]?(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Generated Images"}),(0,a.jsx)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2",children:null==(x=R.data)?void 0:x.map((e,s)=>(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("div",{className:"relative aspect-square w-full",children:(0,a.jsx)(eB.default,{src:e.url,alt:"Generated image ".concat(s+1),fill:!0,className:"rounded-md border object-cover",unoptimized:!0})}),e.revised_prompt&&(0,a.jsxs)("p",{className:"text-muted-foreground text-xs",children:["Revised prompt: ",e.revised_prompt]})]},s))})]})}):"data"in(_=R)&&Array.isArray(_.data)&&_.data.length>0&&"id"in _.data[0]?(0,a.jsx)("div",{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Available Models"}),(0,a.jsx)("div",{className:"max-h-60 overflow-auto",children:(0,a.jsx)("div",{className:"grid gap-2",children:null==(j=R.data)?void 0:j.map(e=>(0,a.jsxs)("div",{className:"bg-muted rounded-md p-3",children:[(0,a.jsx)("div",{className:"font-medium",children:e.id}),e.object&&(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Type: ",e.object]}),e.created&&(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Created:"," ",new Date(1e3*e.created).toLocaleDateString()]})]},e.id))})})]})}):null:null),R&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(N.J,{children:"Raw Response"}),(0,a.jsxs)("details",{className:"group",children:[(0,a.jsxs)("summary",{className:"text-muted-foreground hover:text-foreground cursor-pointer text-sm",children:[(0,a.jsx)(G.A,{className:"mr-1 inline h-4 w-4"}),"Show detailed response data"]}),(0,a.jsx)("pre",{className:"bg-muted mt-2 max-h-60 overflow-auto rounded-md p-4 text-xs",children:JSON.stringify(R,null,2)})]})]})]})]})}var eX=t(484),e0=t(2612),e2=t(9680);function e4(e){let{models:s,onFilteredModelsChange:t,className:l}=e,[i,n]=(0,r.useState)(""),[o,d]=(0,r.useState)("name-asc"),c=(0,r.useMemo)(()=>{let e=[...s];if(i.trim()){let s=i.toLowerCase().trim();e=e.filter(e=>e.name.toLowerCase().includes(s)||e.full_name.toLowerCase().includes(s)||e.provider.toLowerCase().includes(s)||e.description&&e.description.toLowerCase().includes(s)||e.modelType.toLowerCase().includes(s))}return e.sort((e,s)=>{switch(o){case"name-asc":return e.name.localeCompare(s.name);case"name-desc":return s.name.localeCompare(e.name);case"price-asc":return(e.is_free?0:(e.input_cost||0)+(e.output_cost||0))-(s.is_free?0:(s.input_cost||0)+(s.output_cost||0));case"price-desc":{let t=e.is_free?0:(e.input_cost||0)+(e.output_cost||0);return(s.is_free?0:(s.input_cost||0)+(s.output_cost||0))-t}default:return 0}}),e},[s,i,o]);r.useEffect(()=>{t(c)},[c,t]);let u=""!==i.trim()||"name-asc"!==o;return(0,a.jsxs)("div",{className:(0,b.cn)("flex flex-col gap-4 sm:flex-row sm:items-center sm:gap-3",l),children:[(0,a.jsxs)("div",{className:"relative flex-1",children:[(0,a.jsx)(eX.A,{className:"text-muted-foreground absolute top-1/2 left-3 h-4 w-4 -translate-y-1/2"}),(0,a.jsx)(g.p,{placeholder:"Search models by name, provider, or description...",value:i,onChange:e=>n(e.target.value),className:"pl-9"})]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsxs)(f.l6,{value:o,onValueChange:e=>d(e),children:[(0,a.jsxs)(f.bq,{className:"w-full sm:w-[180px]",children:[(0,a.jsx)(e0.A,{className:"mr-2 h-4 w-4"}),(0,a.jsx)(f.yv,{placeholder:"Sort by"})]}),(0,a.jsxs)(f.gC,{children:[(0,a.jsx)(f.eb,{value:"name-asc",children:"Name (A-Z)"}),(0,a.jsx)(f.eb,{value:"name-desc",children:"Name (Z-A)"}),(0,a.jsx)(f.eb,{value:"price-asc",children:"Price (Low to High)"}),(0,a.jsx)(f.eb,{value:"price-desc",children:"Price (High to Low)"})]})]}),u&&(0,a.jsx)(h.$,{variant:"outline",size:"icon",onClick:()=>{n(""),d("name-asc")},className:"h-9 w-9",title:"Clear filters",children:(0,a.jsx)(e2.A,{className:"h-4 w-4"})})]})]})}var e1=t(953),e3=t(7569),e5=t(532),e6=t(6839);function e9(){let[e,s]=(0,r.useState)([]),{data:t,isLoading:l,error:n}=(0,i.I)({queryKey:["admin-models-with-providers"],queryFn:()=>o.zQ.getModelsWithProviders(),refetchOnWindowFocus:!1}),{models:d=[],groups:c=[]}=t||{},u=(0,r.useMemo)(()=>d?d.reduce((e,s)=>{let t=s.provider;return e[t]||(e[t]=[]),e[t].push(s),e},{}):{},[d]),m=(0,r.useMemo)(()=>new Map(c.map(e=>[e.provider,e])),[c]),p=(0,r.useMemo)(()=>Object.entries(u).map(e=>{let[s,t]=e,a=m.get(s);return{provider:s,activeModels:t.filter(e=>!e.soft_deleted).length,totalModels:t.length,groupData:a,hasGroupUrl:!!(null==a?void 0:a.group_url),hasGroupApiKey:!!(null==a?void 0:a.group_api_key)}}),[u,m]);return(0,a.jsxs)(e1.SidebarProvider,{children:[(0,a.jsx)(e3.AppSidebar,{variant:"inset"}),(0,a.jsxs)(e1.SidebarInset,{children:[(0,a.jsx)(e5.SiteHeader,{}),(0,a.jsx)("div",{className:"flex flex-1 flex-col",children:(0,a.jsxs)("div",{className:"@container/main flex flex-1 flex-col gap-4 p-4 md:gap-8 md:p-8",children:[(0,a.jsx)("div",{className:"mb-6 flex items-center justify-between",children:(0,a.jsx)("h1",{className:"text-2xl font-bold tracking-tight",children:"Model Management & API Testing"})}),(0,a.jsxs)(e6.tU,{defaultValue:"manage",className:"w-full",children:[(0,a.jsx)(e6.j7,{className:"grid w-full grid-cols-3",children:(0,a.jsx)(e6.Xi,{value:"manage",children:"Manage Models"})}),(0,a.jsxs)(e6.av,{value:"manage",className:"space-y-4",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-sm",children:"Manage your AI models organized by provider groups. Configure API keys, and organize models by provider groups."}),l?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)(eo.E,{className:"h-[60px] w-full"}),(0,a.jsx)(eo.E,{className:"h-[400px] w-full"})]}):n?(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Failed to load models. Please try refreshing the page."})]}):(0,a.jsx)(e6.tU,{defaultValue:"all",className:"w-full",children:(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("div",{className:"overflow-x-auto rounded-lg border p-1",children:(0,a.jsxs)(e6.j7,{className:"grid w-full max-w-full min-w-max auto-cols-fr grid-flow-col gap-1 sm:gap-2",children:[(0,a.jsxs)(e6.Xi,{value:"all",className:"flex items-center gap-1 text-xs whitespace-nowrap sm:gap-2 sm:text-sm",children:[(0,a.jsx)(K.A,{className:"h-3 w-3 sm:h-4 sm:w-4"}),(0,a.jsx)("span",{className:"hidden sm:inline",children:"All Models"}),(0,a.jsx)("span",{className:"sm:hidden",children:"All"}),(0,a.jsx)(er.E,{variant:"secondary",className:"ml-1 text-xs",children:d.length})]}),p.map(e=>{let{provider:s,activeModels:t,totalModels:r}=e;return(0,a.jsxs)(e6.Xi,{value:s,className:"flex min-w-fit items-center gap-1 text-xs whitespace-nowrap sm:gap-2 sm:text-sm",children:[(0,a.jsx)(J.A,{className:"h-3 w-3 sm:h-4 sm:w-4"}),(0,a.jsx)("span",{className:"max-w-20 truncate sm:max-w-none",children:s}),(0,a.jsx)("div",{className:"flex items-center gap-1",children:(0,a.jsxs)(er.E,{variant:"secondary",className:"ml-1 text-xs",children:[t,"/",r]})})]},s)})]})}),(0,a.jsx)(e6.av,{value:"all",children:(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-sm",children:"Overview of all models across all provider groups."}),(0,a.jsx)(e4,{models:d,onFilteredModelsChange:s}),(0,a.jsx)(ez,{filteredModels:e})]})}),Object.entries(u).map(e=>{let[s,t]=e,r=m.get(s);return(0,a.jsx)(e6.av,{value:s,children:(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("div",{className:"flex items-center justify-between",children:(0,a.jsxs)("div",{children:[(0,a.jsxs)("h3",{className:"flex items-center gap-2 text-lg font-semibold",children:[(0,a.jsx)(J.A,{className:"h-5 w-5"}),s]}),(0,a.jsxs)("div",{className:"text-muted-foreground flex items-center gap-4 text-sm",children:[t.filter(e=>e.soft_deleted).length>0&&(0,a.jsxs)("span",{className:"text-orange-600",children:[t.filter(e=>e.soft_deleted).length," ","soft deleted"]}),(null==r?void 0:r.group_url)&&(0,a.jsxs)("span",{className:"flex items-center gap-1",children:[(0,a.jsx)(K.A,{className:"h-3 w-3"}),r.group_url]})]})]})}),(0,a.jsx)(ez,{filterProvider:s,groupData:r,showProviderActions:!0})]})},s)})]})})]}),(0,a.jsxs)(e6.av,{value:"test-basic",className:"space-y-4",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-sm",children:"Test model credentials and connectivity with basic chat completion requests through the secure proxy (resolves CORS and Docker network issues). Models can be tested even without API keys configured (useful for free models or when authentication is handled elsewhere)."}),l?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)(eo.E,{className:"h-[200px] w-full"}),(0,a.jsx)(eo.E,{className:"h-[100px] w-full"})]}):n?(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Failed to load models for testing. Please try refreshing the page."})]}):(0,a.jsx)(eO,{models:d})]}),(0,a.jsxs)(e6.av,{value:"test-api",className:"space-y-4",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-sm",children:"Comprehensive testing of all OpenAI API endpoints including chat completions, embeddings, image generation, audio synthesis, and model listing through the secure proxy (resolves CORS and Docker network issues). Models can be tested with or without API keys configured."}),l?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)(eo.E,{className:"h-[300px] w-full"}),(0,a.jsx)(eo.E,{className:"h-[200px] w-full"})]}):n?(0,a.jsxs)(V.Fc,{variant:"destructive",children:[(0,a.jsx)(W.A,{className:"h-4 w-4"}),(0,a.jsx)(V.TN,{children:"Failed to load models for API testing. Please try refreshing the page."})]}):(0,a.jsx)(eH,{models:d})]})]})]})})]})]})}},8561:(e,s,t)=>{"use strict";t.d(s,{E:()=>n});var a=t(3422);t(4398);var r=t(4676),l=t(9183);let i=(0,r.F)("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground",success:"border-transparent bg-green-500 text-white hover:bg-green-500/80",warning:"border-transparent bg-yellow-500 text-white hover:bg-yellow-500/80",error:"border-transparent bg-red-500 text-white hover:bg-red-500/80"}},defaultVariants:{variant:"default"}});function n(e){let{className:s,variant:t,...r}=e;return(0,a.jsx)("div",{className:(0,l.cn)(i({variant:t}),s),...r})}},9442:(e,s,t)=>{"use strict";t.d(s,{Fc:()=>n,TN:()=>o});var a=t(3422);t(4398);var r=t(4676),l=t(9183);let i=(0,r.F)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"}},defaultVariants:{variant:"default"}});function n(e){let{className:s,variant:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,l.cn)(i({variant:t}),s),...r})}function o(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"alert-description",className:(0,l.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",s),...t})}}},e=>{var s=s=>e(e.s=s);e.O(0,[363,222,226,29,730,978,481,982,826,900,601,945,497,358],()=>s(6715)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/page-3876b4fb2023557a.js b/ui_out/_next/static/chunks/app/page-3876b4fb2023557a.js new file mode 100644 index 00000000..dedfdb01 --- /dev/null +++ b/ui_out/_next/static/chunks/app/page-3876b4fb2023557a.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[974],{159:(e,s,t)=>{"use strict";t.d(s,{DetailedWalletBalance:()=>k});var a=t(3422),l=t(4398),n=t(2349);let r=(0,t(3929).A)("wallet",[["path",{d:"M19 7V4a1 1 0 0 0-1-1H5a2 2 0 0 0 0 4h15a1 1 0 0 1 1 1v4h-3a2 2 0 0 0 0 4h3a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1",key:"18etb6"}],["path",{d:"M3 5v14a2 2 0 0 0 2 2h15a1 1 0 0 0 1-1v-4",key:"xoc0q4"}]]);var i=t(3728),c=t(2434),d=t(9675),o=t(9945),m=t(7916);o.Ik({token:o.Yj().min(1)}),o.Ik({success:o.zM(),amount:o.ai().optional(),message:o.Yj().optional()}),o.Ik({amount:o.ai().positive(),offline:o.zM().optional()}),o.Ik({token:o.Yj(),balance:o.ai(),npub:o.Yj().optional()});class x{static async redeemToken(e){try{return await m.apiClient.post("/api/wallet/redeem",{token:e})}catch(e){return console.error("Error redeeming token:",e),{success:!1,message:"Failed to redeem token. Please try again."}}}static async sendToken(e){try{return await m.apiClient.post("/api/wallet/send",{amount:e})}catch(e){throw console.error("Error generating token:",e),Error("Failed to generate token. Please try again.")}}static async getBalance(){try{return await m.apiClient.get("/api/wallet/balance")}catch(e){throw console.error("Error fetching balance:",e),e}}static async getDetailedBalances(){try{return await m.apiClient.get("/admin/api/balances")}catch(e){throw console.error("Error fetching detailed balances:",e),e}}static async withdraw(e,s){let t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"sat";try{return await m.apiClient.post("/admin/withdraw",{amount:e,mint_url:s,unit:t})}catch(e){throw console.error("Error withdrawing funds:",e),e}}}var h=t(2738),u=t(3648),p=t(6013),g=t(6320),f=t(268),j=t(3130),v=t(2264),N=t(246),b=t(2533);function y(e){let{open:s,onOpenChange:t,balances:n,onSuccess:r}=e,[i,c]=(0,l.useState)(""),[o,m]=(0,l.useState)(""),[h,y]=(0,l.useState)(""),[w,k]=(0,l.useState)(!1),_=n.filter(e=>!e.error&&e.wallet_balance>0),C=_.find(e=>"".concat(e.mint_url,"|").concat(e.unit)===i),A=(0,p.n)({mutationFn:async()=>{if(!C)throw Error("No balance selected");let e=parseInt(o);if(isNaN(e)||e<=0)throw Error("Invalid amount");return x.withdraw(e,C.mint_url,C.unit)},onSuccess:e=>{y(e.token),null==r||r()}});(0,l.useEffect)(()=>{C&&m((C.owner_balance>0?C.owner_balance:0).toString())},[C]),(0,l.useEffect)(()=>{s||(y(""),m(""),c(""),k(!1))},[s]);let S=parseInt(o)||0,z=C&&S>C.owner_balance&&S<=C.wallet_balance;return h?(0,a.jsx)(g.lG,{open:s,onOpenChange:t,children:(0,a.jsxs)(g.Cf,{className:"sm:max-w-xl",children:[(0,a.jsxs)(g.c7,{children:[(0,a.jsx)(g.L3,{children:"Withdrawal Successful"}),(0,a.jsx)(g.rr,{children:"Save this token! It represents your withdrawn balance."})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"rounded-lg border border-green-200 bg-green-50 p-4 dark:border-green-800 dark:bg-green-950",children:[(0,a.jsxs)("div",{className:"mb-2 flex items-center gap-2",children:[(0,a.jsx)(N.A,{className:"h-5 w-5 text-green-600"}),(0,a.jsx)("span",{className:"font-semibold text-green-900 dark:text-green-100",children:"Withdrawal Token"})]}),(0,a.jsx)("div",{className:"rounded-md bg-gray-900 p-3 font-mono text-xs break-all text-green-400",children:h})]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(u.$,{onClick:()=>{navigator.clipboard.writeText(h),k(!0),setTimeout(()=>k(!1),2e3)},className:"flex-1",variant:w?"outline":"default",children:w?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(N.A,{className:"mr-2 h-4 w-4"}),"Copied!"]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(b.A,{className:"mr-2 h-4 w-4"}),"Copy Token"]})}),(0,a.jsx)(u.$,{onClick:()=>t(!1),variant:"outline",children:"Close"})]})]})]})}):(0,a.jsx)(g.lG,{open:s,onOpenChange:t,children:(0,a.jsxs)(g.Cf,{className:"sm:max-w-md",children:[(0,a.jsxs)(g.c7,{children:[(0,a.jsx)(g.L3,{children:"Withdraw Balance"}),(0,a.jsx)(g.rr,{children:"Select mint and currency, then enter the amount to withdraw."})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(j.J,{htmlFor:"mint-select",children:"Mint / Currency"}),(0,a.jsxs)(v.l6,{value:i,onValueChange:c,children:[(0,a.jsx)(v.bq,{id:"mint-select",children:(0,a.jsx)(v.yv,{placeholder:"Select mint and currency"})}),(0,a.jsx)(v.gC,{children:_.map(e=>(0,a.jsxs)(v.eb,{value:"".concat(e.mint_url,"|").concat(e.unit),children:[e.mint_url.replace("https://","").replace("http://","")," ","• ",e.unit.toUpperCase()," (",e.owner_balance,")"]},"".concat(e.mint_url,"|").concat(e.unit)))})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(j.J,{htmlFor:"amount",children:"Amount"}),(0,a.jsx)(f.p,{id:"amount",type:"number",min:"1",value:o,onChange:e=>m(e.target.value),placeholder:"Enter amount"}),C&&(0,a.jsxs)("div",{className:"space-y-1 text-xs",children:[(0,a.jsxs)("p",{className:"text-muted-foreground",children:["Maximum:"," ",(0,a.jsxs)("span",{className:"font-semibold",children:[C.wallet_balance," ",C.unit]})]}),(0,a.jsxs)("p",{className:"text-muted-foreground",children:["Your recommended balance:"," ",(0,a.jsxs)("span",{className:"font-semibold",children:[C.owner_balance," ",C.unit]})]})]})]}),z&&(0,a.jsxs)("div",{className:"bg-destructive/10 text-destructive flex items-start gap-2 rounded-md p-3 text-sm",children:[(0,a.jsx)(d.A,{className:"mt-0.5 h-5 w-5 flex-shrink-0"}),(0,a.jsx)("span",{children:"Warning: Withdrawing more than your balance will use user funds!"})]}),A.isError&&(0,a.jsxs)("div",{className:"bg-destructive/10 text-destructive flex items-start gap-2 rounded-md p-3 text-sm",children:[(0,a.jsx)(d.A,{className:"mt-0.5 h-5 w-5 flex-shrink-0"}),(0,a.jsx)("span",{children:A.error.message||"Failed to withdraw"})]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(u.$,{onClick:()=>A.mutate(),disabled:!i||!o||A.isPending||S<=0||C&&S>C.wallet_balance,className:"flex-1",children:A.isPending?"Withdrawing...":"Withdraw"}),(0,a.jsx)(u.$,{onClick:()=>t(!1),variant:"outline",disabled:A.isPending,children:"Cancel"})]})]})]})})}var w=t(9183);function k(e){let s,t,o,{refreshInterval:m=1e4}=e,[p,g]=(0,l.useState)(!1),{data:f,isLoading:j,isError:v,error:N,isFetching:b,refetch:k}=(0,n.I)({queryKey:["detailed-wallet-balance"],queryFn:async()=>x.getDetailedBalances(),refetchInterval:m}),_=f?(s=0,t=0,o=0,f.forEach(e=>{e.error||(s+=e.wallet_balance||0,t+=e.user_balance||0,o+=e.owner_balance||0)}),{totalWallet:s,totalUser:t,totalOwner:o}):{totalWallet:0,totalUser:0,totalOwner:0};return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)(h.Zp,{className:"h-full w-full shadow-sm",children:[(0,a.jsxs)(h.aR,{className:"pb-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)(h.ZB,{className:"text-xl",children:"Cashu Wallet Balance"}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsxs)(u.$,{variant:"default",size:"sm",onClick:()=>g(!0),disabled:j||!f||0===f.length,children:[(0,a.jsx)(r,{className:"mr-2 h-4 w-4"}),"Withdraw"]}),(0,a.jsxs)(u.$,{variant:"ghost",size:"icon",onClick:()=>k(),disabled:j||b,className:"h-8 w-8",children:[(0,a.jsx)(i.A,{className:(0,w.cn)("h-4 w-4",(b||j)&&"animate-spin")}),(0,a.jsx)("span",{className:"sr-only",children:"Refresh balance"})]})]})]}),(0,a.jsx)(h.BT,{children:"Detailed balance breakdown by mint and currency"})]}),(0,a.jsx)(h.Wu,{children:j?(0,a.jsx)("div",{className:"flex items-center justify-center py-8",children:(0,a.jsx)(c.A,{className:"text-primary h-8 w-8 animate-spin"})}):v?(0,a.jsxs)("div",{className:"bg-destructive/10 text-destructive flex items-center space-x-2 rounded-md p-4",children:[(0,a.jsx)(d.A,{className:"h-5 w-5"}),(0,a.jsxs)("span",{children:["Error loading balance: ",N.message]})]}):(0,a.jsxs)("div",{className:"space-y-6",children:[(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-sm",children:"Your Balance (Total)"}),(0,a.jsxs)("span",{className:"text-2xl font-bold text-green-600",children:[_.totalOwner.toLocaleString()," sats"]})]}),(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-sm",children:"Total Wallet"}),(0,a.jsxs)("span",{className:"text-lg font-semibold",children:[_.totalWallet.toLocaleString()," sats"]})]}),(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-sm",children:"User Balance"}),(0,a.jsxs)("span",{className:"text-lg font-semibold",children:[_.totalUser.toLocaleString()," sats"]})]})]}),(0,a.jsx)("p",{className:"text-muted-foreground text-xs",children:"Your balance = Total wallet - User balance"}),(0,a.jsxs)("div",{className:"overflow-hidden rounded-lg border",children:[(0,a.jsxs)("div",{className:"bg-muted hidden grid-cols-4 gap-2 p-3 text-sm font-semibold md:grid",children:[(0,a.jsx)("div",{children:"Mint / Unit"}),(0,a.jsx)("div",{className:"text-right",children:"Wallet"}),(0,a.jsx)("div",{className:"text-right",children:"Users"}),(0,a.jsx)("div",{className:"text-right",children:"Owner"})]}),f&&f.length>0?f.filter(e=>e.wallet_balance&&e.wallet_balance>0||e.error).map((e,s)=>(0,a.jsxs)("div",{className:(0,w.cn)("border-t p-3 text-sm",e.error&&"bg-destructive/10 text-destructive"),children:[(0,a.jsxs)("div",{className:"hidden grid-cols-4 gap-2 md:grid",children:[(0,a.jsxs)("div",{className:"text-xs break-all",children:[e.mint_url.replace("https://","").replace("http://","")," ","• ",e.unit.toUpperCase()]}),(0,a.jsx)("div",{className:"text-right font-mono",children:e.error?"error":e.wallet_balance.toLocaleString()}),(0,a.jsx)("div",{className:"text-right font-mono",children:e.error?"-":e.user_balance.toLocaleString()}),(0,a.jsx)("div",{className:(0,w.cn)("text-right font-mono",!e.error&&e.owner_balance>0&&"font-semibold text-green-600"),children:e.error?"-":e.owner_balance.toLocaleString()})]}),(0,a.jsxs)("div",{className:"space-y-3 md:hidden",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-xs font-medium",children:"Mint / Unit"}),(0,a.jsxs)("div",{className:"font-mono text-xs break-all",children:[e.mint_url.replace("https://","").replace("http://","")," ","• ",e.unit.toUpperCase()]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-2",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Wallet"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:e.error?"error":e.wallet_balance.toLocaleString()})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Users"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:e.error?"-":e.user_balance.toLocaleString()})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Owner"}),(0,a.jsx)("div",{className:(0,w.cn)("truncate font-mono text-sm",!e.error&&e.owner_balance>0&&"font-semibold text-green-600"),children:e.error?"-":e.owner_balance.toLocaleString()})]})]})]})]},s)):(0,a.jsx)("div",{className:"text-muted-foreground p-4 text-center text-sm",children:"No balances to display"})]})]})})]}),(0,a.jsx)(y,{open:p,onOpenChange:g,balances:f||[],onSuccess:()=>{k()}})]})}},246:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("circle-check-big",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]])},1551:(e,s,t)=>{Promise.resolve().then(t.bind(t,7569)),Promise.resolve().then(t.bind(t,159)),Promise.resolve().then(t.bind(t,532)),Promise.resolve().then(t.bind(t,2483)),Promise.resolve().then(t.bind(t,953))},2264:(e,s,t)=>{"use strict";t.d(s,{bq:()=>m,eb:()=>h,gC:()=>x,l6:()=>d,yv:()=>o});var a=t(3422);t(4398);var l=t(3439),n=t(9994),r=t(8940),i=t(4967),c=t(9183);function d(e){let{...s}=e;return(0,a.jsx)(l.bL,{"data-slot":"select",...s})}function o(e){let{...s}=e;return(0,a.jsx)(l.WT,{"data-slot":"select-value",...s})}function m(e){let{className:s,size:t="default",children:r,...i}=e;return(0,a.jsxs)(l.l9,{"data-slot":"select-trigger","data-size":t,className:(0,c.cn)("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",s),...i,children:[r,(0,a.jsx)(l.In,{asChild:!0,children:(0,a.jsx)(n.A,{className:"size-4 opacity-50"})})]})}function x(e){let{className:s,children:t,position:n="popper",...r}=e;return(0,a.jsx)(l.ZL,{children:(0,a.jsxs)(l.UC,{"data-slot":"select-content",className:(0,c.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--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","popper"===n&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",s),position:n,...r,children:[(0,a.jsx)(u,{}),(0,a.jsx)(l.LM,{className:(0,c.cn)("p-1","popper"===n&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:t}),(0,a.jsx)(p,{})]})})}function h(e){let{className:s,children:t,...n}=e;return(0,a.jsxs)(l.q7,{"data-slot":"select-item",className:(0,c.cn)("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",s),...n,children:[(0,a.jsx)("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:(0,a.jsx)(l.VF,{children:(0,a.jsx)(r.A,{className:"size-4"})})}),(0,a.jsx)(l.p4,{children:t})]})}function u(e){let{className:s,...t}=e;return(0,a.jsx)(l.PP,{"data-slot":"select-scroll-up-button",className:(0,c.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(i.A,{className:"size-4"})})}function p(e){let{className:s,...t}=e;return(0,a.jsx)(l.wn,{"data-slot":"select-scroll-down-button",className:(0,c.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(n.A,{className:"size-4"})})}},2434:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("loader-circle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]])},2483:(e,s,t)=>{"use strict";t.d(s,{TemporaryBalances:()=>j});var a=t(3422),l=t(4398),n=t(2349),r=t(5195),i=t(3728),c=t(2434),d=t(9675),o=t(3929);let m=(0,o.A)("dollar-sign",[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]]),x=(0,o.A)("activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]),h=(0,o.A)("clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);var u=t(9119),p=t(2738),g=t(3648),f=t(9183);function j(e){let s,t,o,{refreshInterval:j=1e4}=e,[v,N]=(0,l.useState)(""),{data:b,isLoading:y,isError:w,error:k,isFetching:_,refetch:C}=(0,n.I)({queryKey:["temporary-balances"],queryFn:async()=>u.zQ.getTemporaryBalances(),refetchInterval:j}),A=e=>"".concat(e.toLocaleString()," msat"),S=b?b.filter(e=>{var s;return e.hashed_key.toLowerCase().includes(v.toLowerCase())||(null==(s=e.refund_address)?void 0:s.toLowerCase().includes(v.toLowerCase()))}):[],z=b?(s=0,t=0,o=0,b.forEach(e=>{s+=e.balance||0,t+=e.total_spent||0,o+=e.total_requests||0}),{totalBalance:s,totalSpent:t,totalRequests:o}):{totalBalance:0,totalSpent:0,totalRequests:0};return(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)(p.Zp,{className:"h-full w-full shadow-sm",children:[(0,a.jsxs)(p.aR,{className:"pb-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)(p.ZB,{className:"flex items-center gap-2 text-xl",children:[(0,a.jsx)(r.A,{className:"h-5 w-5"}),"Temporary Balances"]}),(0,a.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row sm:gap-2",children:[(0,a.jsxs)("div",{className:"relative flex-1 sm:flex-initial",children:[(0,a.jsx)("input",{type:"text",placeholder:"Search by key or address...",value:v,onChange:e=>N(e.target.value),className:"focus:ring-primary/20 w-full rounded-md border py-2 pr-3 pl-8 text-sm focus:ring-2 focus:outline-none sm:w-64"}),(0,a.jsx)(r.A,{className:"text-muted-foreground absolute top-2.5 left-2 h-4 w-4"})]}),(0,a.jsxs)(g.$,{variant:"ghost",size:"icon",onClick:()=>C(),disabled:y||_,className:"h-8 w-8",children:[(0,a.jsx)(i.A,{className:(0,f.cn)("h-4 w-4",(_||y)&&"animate-spin")}),(0,a.jsx)("span",{className:"sr-only",children:"Refresh temporary balances"})]})]})]}),(0,a.jsx)(p.BT,{children:"API keys with their current balances and usage statistics"})]}),(0,a.jsx)(p.Wu,{children:y?(0,a.jsx)("div",{className:"flex items-center justify-center py-8",children:(0,a.jsx)(c.A,{className:"text-primary h-8 w-8 animate-spin"})}):w?(0,a.jsxs)("div",{className:"bg-destructive/10 text-destructive flex items-center space-x-2 rounded-md p-4",children:[(0,a.jsx)(d.A,{className:"h-5 w-5"}),(0,a.jsxs)("span",{children:["Error loading temporary balances: ",k.message]})]}):(0,a.jsxs)("div",{className:"space-y-6",children:[(0,a.jsxs)("div",{className:"mb-6 grid grid-cols-1 gap-4 md:grid-cols-3",children:[(0,a.jsxs)("div",{className:"rounded-lg border border-blue-200 bg-gradient-to-r from-blue-50 to-indigo-50 p-4",children:[(0,a.jsx)("div",{className:"flex items-center justify-between",children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(m,{className:"h-5 w-5 text-blue-600"}),(0,a.jsx)("span",{className:"text-sm font-medium text-blue-800",children:"Total Balance"})]})}),(0,a.jsx)("div",{className:"mt-2 text-2xl font-bold text-blue-900",children:A(z.totalBalance)})]}),(0,a.jsxs)("div",{className:"rounded-lg border border-green-200 bg-gradient-to-r from-green-50 to-emerald-50 p-4",children:[(0,a.jsx)("div",{className:"flex items-center justify-between",children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(x,{className:"h-5 w-5 text-green-600"}),(0,a.jsx)("span",{className:"text-sm font-medium text-green-800",children:"Total Spent"})]})}),(0,a.jsx)("div",{className:"mt-2 text-2xl font-bold text-green-900",children:A(z.totalSpent)})]}),(0,a.jsxs)("div",{className:"rounded-lg border border-purple-200 bg-gradient-to-r from-purple-50 to-pink-50 p-4",children:[(0,a.jsx)("div",{className:"flex items-center justify-between",children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(r.A,{className:"h-5 w-5 text-purple-600"}),(0,a.jsx)("span",{className:"text-sm font-medium text-purple-800",children:"Total Requests"})]})}),(0,a.jsx)("div",{className:"mt-2 text-2xl font-bold text-purple-900",children:z.totalRequests.toLocaleString()})]})]}),(0,a.jsxs)("div",{className:"overflow-hidden rounded-lg border",children:[(0,a.jsxs)("div",{className:"bg-muted hidden grid-cols-6 gap-2 p-3 text-sm font-semibold md:grid",children:[(0,a.jsx)("div",{children:"Hashed Key"}),(0,a.jsx)("div",{className:"text-right",children:"Balance"}),(0,a.jsx)("div",{className:"text-right",children:"Total Spent"}),(0,a.jsx)("div",{className:"text-right",children:"Total Requests"}),(0,a.jsx)("div",{children:"Refund Address"}),(0,a.jsx)("div",{className:"text-right",children:"Expiry Time"})]}),S.length>0?S.map((e,s)=>(0,a.jsxs)("div",{className:(0,f.cn)("hover:bg-muted/50 border-t p-3 text-sm transition-colors",0===e.balance&&"opacity-60"),children:[(0,a.jsxs)("div",{className:"hidden grid-cols-6 gap-2 md:grid",children:[(0,a.jsx)("div",{className:"max-w-32 truncate font-mono text-xs break-all",children:e.hashed_key}),(0,a.jsx)("div",{className:"text-right font-mono",children:A(e.balance)}),(0,a.jsx)("div",{className:"text-right font-mono",children:A(e.total_spent)}),(0,a.jsx)("div",{className:"text-right font-mono",children:e.total_requests.toLocaleString()}),(0,a.jsx)("div",{className:"max-w-32 truncate font-mono text-xs break-all",children:e.refund_address||"-"}),(0,a.jsx)("div",{className:"text-right font-mono text-xs",children:e.key_expiry_time?(0,a.jsxs)("div",{className:"flex items-center justify-end gap-1",children:[(0,a.jsx)(h,{className:"h-3 w-3"}),(0,a.jsx)("span",{children:new Date(1e3*e.key_expiry_time).toLocaleDateString()})]}):"-"})]}),(0,a.jsxs)("div",{className:"space-y-3 md:hidden",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-xs font-medium",children:"Key"}),(0,a.jsx)("div",{className:"font-mono text-xs break-all",children:e.hashed_key})]}),(0,a.jsxs)("div",{className:"grid grid-cols-2 gap-3",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Balance"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:A(e.balance)})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Spent"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:A(e.total_spent)})]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-2 gap-3",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Requests"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:e.total_requests.toLocaleString()})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Expires"}),(0,a.jsx)("div",{className:"font-mono text-xs",children:e.key_expiry_time?(0,a.jsxs)("div",{className:"flex items-center gap-1",children:[(0,a.jsx)(h,{className:"h-3 w-3 flex-shrink-0"}),(0,a.jsx)("span",{className:"truncate",children:new Date(1e3*e.key_expiry_time).toLocaleDateString()})]}):"-"})]})]}),e.refund_address&&(0,a.jsxs)("div",{className:"space-y-1 border-t pt-2",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Refund Address"}),(0,a.jsx)("div",{className:"font-mono text-xs break-all",children:e.refund_address})]})]})]},s)):(0,a.jsx)("div",{className:"text-muted-foreground p-8 text-center text-sm",children:v?(0,a.jsxs)("div",{className:"flex flex-col items-center gap-2",children:[(0,a.jsx)(d.A,{className:"h-8 w-8"}),(0,a.jsx)("span",{children:"No temporary balances match your search"})]}):(0,a.jsxs)("div",{className:"flex flex-col items-center gap-2",children:[(0,a.jsx)(r.A,{className:"h-8 w-8"}),(0,a.jsx)("span",{children:"No temporary balances found"})]})})]}),b&&b.length>0&&(0,a.jsxs)("div",{className:"text-muted-foreground mt-4 text-xs",children:["Showing ",S.length," of ",b.length," temporary balances"]})]})})]})})}},2533:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]])},3728:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("refresh-cw",[["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"}]])},5195:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("key",[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4",key:"g0fldk"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}]])},6320:(e,s,t)=>{"use strict";t.d(s,{Cf:()=>m,Es:()=>h,L3:()=>u,c7:()=>x,lG:()=>i,rr:()=>p,zM:()=>c});var a=t(3422);t(4398);var l=t(4316),n=t(9680),r=t(9183);function i(e){let{...s}=e;return(0,a.jsx)(l.bL,{"data-slot":"dialog",...s})}function c(e){let{...s}=e;return(0,a.jsx)(l.l9,{"data-slot":"dialog-trigger",...s})}function d(e){let{...s}=e;return(0,a.jsx)(l.ZL,{"data-slot":"dialog-portal",...s})}function o(e){let{className:s,...t}=e;return(0,a.jsx)(l.hJ,{"data-slot":"dialog-overlay",className:(0,r.cn)("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",s),...t})}function m(e){let{className:s,children:t,...i}=e;return(0,a.jsxs)(d,{"data-slot":"dialog-portal",children:[(0,a.jsx)(o,{}),(0,a.jsxs)(l.UC,{"data-slot":"dialog-content",className:(0,r.cn)("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",s),...i,children:[t,(0,a.jsxs)(l.bm,{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:[(0,a.jsx)(n.A,{}),(0,a.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function x(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-header",className:(0,r.cn)("flex flex-col gap-2 text-center sm:text-left",s),...t})}function h(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-footer",className:(0,r.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",s),...t})}function u(e){let{className:s,...t}=e;return(0,a.jsx)(l.hE,{"data-slot":"dialog-title",className:(0,r.cn)("text-lg leading-none font-semibold",s),...t})}function p(e){let{className:s,...t}=e;return(0,a.jsx)(l.VY,{"data-slot":"dialog-description",className:(0,r.cn)("text-muted-foreground text-sm",s),...t})}}},e=>{var s=s=>e(e.s=s);e.O(0,[363,222,226,29,730,978,481,900,601,945,497,358],()=>s(1551)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/page-cf122f9b514899ca.js b/ui_out/_next/static/chunks/app/page-cf122f9b514899ca.js deleted file mode 100644 index d978ec0b..00000000 --- a/ui_out/_next/static/chunks/app/page-cf122f9b514899ca.js +++ /dev/null @@ -1 +0,0 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[974],{159:(e,s,t)=>{"use strict";t.d(s,{DetailedWalletBalance:()=>k});var a=t(3422),l=t(4398),n=t(2349);let r=(0,t(3929).A)("wallet",[["path",{d:"M19 7V4a1 1 0 0 0-1-1H5a2 2 0 0 0 0 4h15a1 1 0 0 1 1 1v4h-3a2 2 0 0 0 0 4h3a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1",key:"18etb6"}],["path",{d:"M3 5v14a2 2 0 0 0 2 2h15a1 1 0 0 0 1-1v-4",key:"xoc0q4"}]]);var i=t(3728),c=t(2434),d=t(9675),o=t(9945),m=t(7916);o.Ik({token:o.Yj().min(1)}),o.Ik({success:o.zM(),amount:o.ai().optional(),message:o.Yj().optional()}),o.Ik({amount:o.ai().positive(),offline:o.zM().optional()}),o.Ik({token:o.Yj(),balance:o.ai(),npub:o.Yj().optional()});class x{static async redeemToken(e){try{return await m.apiClient.post("/api/wallet/redeem",{token:e})}catch(e){return console.error("Error redeeming token:",e),{success:!1,message:"Failed to redeem token. Please try again."}}}static async sendToken(e){try{return await m.apiClient.post("/api/wallet/send",{amount:e})}catch(e){throw console.error("Error generating token:",e),Error("Failed to generate token. Please try again.")}}static async getBalance(){try{return await m.apiClient.get("/api/wallet/balance")}catch(e){throw console.error("Error fetching balance:",e),e}}static async getDetailedBalances(){try{return await m.apiClient.get("/admin/api/balances")}catch(e){throw console.error("Error fetching detailed balances:",e),e}}static async withdraw(e,s){let t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"sat";try{return await m.apiClient.post("/admin/withdraw",{amount:e,mint_url:s,unit:t})}catch(e){throw console.error("Error withdrawing funds:",e),e}}}var h=t(2738),u=t(3648),p=t(6013),g=t(6320),f=t(268),j=t(3130),v=t(2264),N=t(246),b=t(2533);function y(e){let{open:s,onOpenChange:t,balances:n,onSuccess:r}=e,[i,c]=(0,l.useState)(""),[o,m]=(0,l.useState)(""),[h,y]=(0,l.useState)(""),[w,k]=(0,l.useState)(!1),_=n.filter(e=>!e.error&&e.wallet_balance>0),C=_.find(e=>"".concat(e.mint_url,"|").concat(e.unit)===i),A=(0,p.n)({mutationFn:async()=>{if(!C)throw Error("No balance selected");let e=parseInt(o);if(isNaN(e)||e<=0)throw Error("Invalid amount");return x.withdraw(e,C.mint_url,C.unit)},onSuccess:e=>{y(e.token),null==r||r()}});(0,l.useEffect)(()=>{C&&m((C.owner_balance>0?C.owner_balance:0).toString())},[C]),(0,l.useEffect)(()=>{s||(y(""),m(""),c(""),k(!1))},[s]);let S=parseInt(o)||0,z=C&&S>C.owner_balance&&S<=C.wallet_balance;return h?(0,a.jsx)(g.lG,{open:s,onOpenChange:t,children:(0,a.jsxs)(g.Cf,{className:"sm:max-w-xl",children:[(0,a.jsxs)(g.c7,{children:[(0,a.jsx)(g.L3,{children:"Withdrawal Successful"}),(0,a.jsx)(g.rr,{children:"Save this token! It represents your withdrawn balance."})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"rounded-lg border border-green-200 bg-green-50 p-4 dark:border-green-800 dark:bg-green-950",children:[(0,a.jsxs)("div",{className:"mb-2 flex items-center gap-2",children:[(0,a.jsx)(N.A,{className:"h-5 w-5 text-green-600"}),(0,a.jsx)("span",{className:"font-semibold text-green-900 dark:text-green-100",children:"Withdrawal Token"})]}),(0,a.jsx)("div",{className:"rounded-md bg-gray-900 p-3 font-mono text-xs break-all text-green-400",children:h})]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(u.$,{onClick:()=>{navigator.clipboard.writeText(h),k(!0),setTimeout(()=>k(!1),2e3)},className:"flex-1",variant:w?"outline":"default",children:w?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(N.A,{className:"mr-2 h-4 w-4"}),"Copied!"]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(b.A,{className:"mr-2 h-4 w-4"}),"Copy Token"]})}),(0,a.jsx)(u.$,{onClick:()=>t(!1),variant:"outline",children:"Close"})]})]})]})}):(0,a.jsx)(g.lG,{open:s,onOpenChange:t,children:(0,a.jsxs)(g.Cf,{className:"sm:max-w-md",children:[(0,a.jsxs)(g.c7,{children:[(0,a.jsx)(g.L3,{children:"Withdraw Balance"}),(0,a.jsx)(g.rr,{children:"Select mint and currency, then enter the amount to withdraw."})]}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(j.J,{htmlFor:"mint-select",children:"Mint / Currency"}),(0,a.jsxs)(v.l6,{value:i,onValueChange:c,children:[(0,a.jsx)(v.bq,{id:"mint-select",children:(0,a.jsx)(v.yv,{placeholder:"Select mint and currency"})}),(0,a.jsx)(v.gC,{children:_.map(e=>(0,a.jsxs)(v.eb,{value:"".concat(e.mint_url,"|").concat(e.unit),children:[e.mint_url.replace("https://","").replace("http://","")," ","• ",e.unit.toUpperCase()," (",e.owner_balance,")"]},"".concat(e.mint_url,"|").concat(e.unit)))})]})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(j.J,{htmlFor:"amount",children:"Amount"}),(0,a.jsx)(f.p,{id:"amount",type:"number",min:"1",value:o,onChange:e=>m(e.target.value),placeholder:"Enter amount"}),C&&(0,a.jsxs)("div",{className:"space-y-1 text-xs",children:[(0,a.jsxs)("p",{className:"text-muted-foreground",children:["Maximum:"," ",(0,a.jsxs)("span",{className:"font-semibold",children:[C.wallet_balance," ",C.unit]})]}),(0,a.jsxs)("p",{className:"text-muted-foreground",children:["Your recommended balance:"," ",(0,a.jsxs)("span",{className:"font-semibold",children:[C.owner_balance," ",C.unit]})]})]})]}),z&&(0,a.jsxs)("div",{className:"bg-destructive/10 text-destructive flex items-start gap-2 rounded-md p-3 text-sm",children:[(0,a.jsx)(d.A,{className:"mt-0.5 h-5 w-5 flex-shrink-0"}),(0,a.jsx)("span",{children:"Warning: Withdrawing more than your balance will use user funds!"})]}),A.isError&&(0,a.jsxs)("div",{className:"bg-destructive/10 text-destructive flex items-start gap-2 rounded-md p-3 text-sm",children:[(0,a.jsx)(d.A,{className:"mt-0.5 h-5 w-5 flex-shrink-0"}),(0,a.jsx)("span",{children:A.error.message||"Failed to withdraw"})]}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(u.$,{onClick:()=>A.mutate(),disabled:!i||!o||A.isPending||S<=0||C&&S>C.wallet_balance,className:"flex-1",children:A.isPending?"Withdrawing...":"Withdraw"}),(0,a.jsx)(u.$,{onClick:()=>t(!1),variant:"outline",disabled:A.isPending,children:"Cancel"})]})]})]})})}var w=t(9183);function k(e){let s,t,o,{refreshInterval:m=1e4}=e,[p,g]=(0,l.useState)(!1),{data:f,isLoading:j,isError:v,error:N,isFetching:b,refetch:k}=(0,n.I)({queryKey:["detailed-wallet-balance"],queryFn:async()=>x.getDetailedBalances(),refetchInterval:m}),_=f?(s=0,t=0,o=0,f.forEach(e=>{e.error||(s+=e.wallet_balance||0,t+=e.user_balance||0,o+=e.owner_balance||0)}),{totalWallet:s,totalUser:t,totalOwner:o}):{totalWallet:0,totalUser:0,totalOwner:0};return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)(h.Zp,{className:"h-full w-full shadow-sm",children:[(0,a.jsxs)(h.aR,{className:"pb-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)(h.ZB,{className:"text-xl",children:"Cashu Wallet Balance"}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsxs)(u.$,{variant:"default",size:"sm",onClick:()=>g(!0),disabled:j||!f||0===f.length,children:[(0,a.jsx)(r,{className:"mr-2 h-4 w-4"}),"Withdraw"]}),(0,a.jsxs)(u.$,{variant:"ghost",size:"icon",onClick:()=>k(),disabled:j||b,className:"h-8 w-8",children:[(0,a.jsx)(i.A,{className:(0,w.cn)("h-4 w-4",(b||j)&&"animate-spin")}),(0,a.jsx)("span",{className:"sr-only",children:"Refresh balance"})]})]})]}),(0,a.jsx)(h.BT,{children:"Detailed balance breakdown by mint and currency"})]}),(0,a.jsx)(h.Wu,{children:j?(0,a.jsx)("div",{className:"flex items-center justify-center py-8",children:(0,a.jsx)(c.A,{className:"text-primary h-8 w-8 animate-spin"})}):v?(0,a.jsxs)("div",{className:"bg-destructive/10 text-destructive flex items-center space-x-2 rounded-md p-4",children:[(0,a.jsx)(d.A,{className:"h-5 w-5"}),(0,a.jsxs)("span",{children:["Error loading balance: ",N.message]})]}):(0,a.jsxs)("div",{className:"space-y-6",children:[(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-sm",children:"Your Balance (Total)"}),(0,a.jsxs)("span",{className:"text-2xl font-bold text-green-600",children:[_.totalOwner.toLocaleString()," sats"]})]}),(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-sm",children:"Total Wallet"}),(0,a.jsxs)("span",{className:"text-lg font-semibold",children:[_.totalWallet.toLocaleString()," sats"]})]}),(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-sm",children:"User Balance"}),(0,a.jsxs)("span",{className:"text-lg font-semibold",children:[_.totalUser.toLocaleString()," sats"]})]})]}),(0,a.jsx)("p",{className:"text-muted-foreground text-xs",children:"Your balance = Total wallet - User balance"}),(0,a.jsxs)("div",{className:"overflow-hidden rounded-lg border",children:[(0,a.jsxs)("div",{className:"bg-muted hidden grid-cols-4 gap-2 p-3 text-sm font-semibold md:grid",children:[(0,a.jsx)("div",{children:"Mint / Unit"}),(0,a.jsx)("div",{className:"text-right",children:"Wallet"}),(0,a.jsx)("div",{className:"text-right",children:"Users"}),(0,a.jsx)("div",{className:"text-right",children:"Owner"})]}),f&&f.length>0?f.filter(e=>e.wallet_balance&&e.wallet_balance>0||e.error).map((e,s)=>(0,a.jsxs)("div",{className:(0,w.cn)("border-t p-3 text-sm",e.error&&"bg-destructive/10 text-destructive"),children:[(0,a.jsxs)("div",{className:"hidden grid-cols-4 gap-2 md:grid",children:[(0,a.jsxs)("div",{className:"text-xs break-all",children:[e.mint_url.replace("https://","").replace("http://","")," ","• ",e.unit.toUpperCase()]}),(0,a.jsx)("div",{className:"text-right font-mono",children:e.error?"error":e.wallet_balance.toLocaleString()}),(0,a.jsx)("div",{className:"text-right font-mono",children:e.error?"-":e.user_balance.toLocaleString()}),(0,a.jsx)("div",{className:(0,w.cn)("text-right font-mono",!e.error&&e.owner_balance>0&&"font-semibold text-green-600"),children:e.error?"-":e.owner_balance.toLocaleString()})]}),(0,a.jsxs)("div",{className:"space-y-3 md:hidden",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-xs font-medium",children:"Mint / Unit"}),(0,a.jsxs)("div",{className:"font-mono text-xs break-all",children:[e.mint_url.replace("https://","").replace("http://","")," ","• ",e.unit.toUpperCase()]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-2",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Wallet"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:e.error?"error":e.wallet_balance.toLocaleString()})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Users"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:e.error?"-":e.user_balance.toLocaleString()})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Owner"}),(0,a.jsx)("div",{className:(0,w.cn)("truncate font-mono text-sm",!e.error&&e.owner_balance>0&&"font-semibold text-green-600"),children:e.error?"-":e.owner_balance.toLocaleString()})]})]})]})]},s)):(0,a.jsx)("div",{className:"text-muted-foreground p-4 text-center text-sm",children:"No balances to display"})]})]})})]}),(0,a.jsx)(y,{open:p,onOpenChange:g,balances:f||[],onSuccess:()=>{k()}})]})}},246:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("circle-check-big",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]])},1551:(e,s,t)=>{Promise.resolve().then(t.bind(t,7569)),Promise.resolve().then(t.bind(t,159)),Promise.resolve().then(t.bind(t,4756)),Promise.resolve().then(t.bind(t,2483)),Promise.resolve().then(t.bind(t,953))},2264:(e,s,t)=>{"use strict";t.d(s,{bq:()=>m,eb:()=>h,gC:()=>x,l6:()=>d,yv:()=>o});var a=t(3422);t(4398);var l=t(3439),n=t(9994),r=t(8940),i=t(4967),c=t(9183);function d(e){let{...s}=e;return(0,a.jsx)(l.bL,{"data-slot":"select",...s})}function o(e){let{...s}=e;return(0,a.jsx)(l.WT,{"data-slot":"select-value",...s})}function m(e){let{className:s,size:t="default",children:r,...i}=e;return(0,a.jsxs)(l.l9,{"data-slot":"select-trigger","data-size":t,className:(0,c.cn)("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",s),...i,children:[r,(0,a.jsx)(l.In,{asChild:!0,children:(0,a.jsx)(n.A,{className:"size-4 opacity-50"})})]})}function x(e){let{className:s,children:t,position:n="popper",...r}=e;return(0,a.jsx)(l.ZL,{children:(0,a.jsxs)(l.UC,{"data-slot":"select-content",className:(0,c.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--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","popper"===n&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",s),position:n,...r,children:[(0,a.jsx)(u,{}),(0,a.jsx)(l.LM,{className:(0,c.cn)("p-1","popper"===n&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:t}),(0,a.jsx)(p,{})]})})}function h(e){let{className:s,children:t,...n}=e;return(0,a.jsxs)(l.q7,{"data-slot":"select-item",className:(0,c.cn)("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",s),...n,children:[(0,a.jsx)("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:(0,a.jsx)(l.VF,{children:(0,a.jsx)(r.A,{className:"size-4"})})}),(0,a.jsx)(l.p4,{children:t})]})}function u(e){let{className:s,...t}=e;return(0,a.jsx)(l.PP,{"data-slot":"select-scroll-up-button",className:(0,c.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(i.A,{className:"size-4"})})}function p(e){let{className:s,...t}=e;return(0,a.jsx)(l.wn,{"data-slot":"select-scroll-down-button",className:(0,c.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(n.A,{className:"size-4"})})}},2434:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("loader-circle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]])},2483:(e,s,t)=>{"use strict";t.d(s,{TemporaryBalances:()=>j});var a=t(3422),l=t(4398),n=t(2349),r=t(5195),i=t(3728),c=t(2434),d=t(9675),o=t(3929);let m=(0,o.A)("dollar-sign",[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]]),x=(0,o.A)("activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]),h=(0,o.A)("clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);var u=t(9119),p=t(2738),g=t(3648),f=t(9183);function j(e){let s,t,o,{refreshInterval:j=1e4}=e,[v,N]=(0,l.useState)(""),{data:b,isLoading:y,isError:w,error:k,isFetching:_,refetch:C}=(0,n.I)({queryKey:["temporary-balances"],queryFn:async()=>u.zQ.getTemporaryBalances(),refetchInterval:j}),A=e=>"".concat(e.toLocaleString()," msat"),S=b?b.filter(e=>{var s;return e.hashed_key.toLowerCase().includes(v.toLowerCase())||(null==(s=e.refund_address)?void 0:s.toLowerCase().includes(v.toLowerCase()))}):[],z=b?(s=0,t=0,o=0,b.forEach(e=>{s+=e.balance||0,t+=e.total_spent||0,o+=e.total_requests||0}),{totalBalance:s,totalSpent:t,totalRequests:o}):{totalBalance:0,totalSpent:0,totalRequests:0};return(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)(p.Zp,{className:"h-full w-full shadow-sm",children:[(0,a.jsxs)(p.aR,{className:"pb-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)(p.ZB,{className:"flex items-center gap-2 text-xl",children:[(0,a.jsx)(r.A,{className:"h-5 w-5"}),"Temporary Balances"]}),(0,a.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row sm:gap-2",children:[(0,a.jsxs)("div",{className:"relative flex-1 sm:flex-initial",children:[(0,a.jsx)("input",{type:"text",placeholder:"Search by key or address...",value:v,onChange:e=>N(e.target.value),className:"focus:ring-primary/20 w-full rounded-md border py-2 pr-3 pl-8 text-sm focus:ring-2 focus:outline-none sm:w-64"}),(0,a.jsx)(r.A,{className:"text-muted-foreground absolute top-2.5 left-2 h-4 w-4"})]}),(0,a.jsxs)(g.$,{variant:"ghost",size:"icon",onClick:()=>C(),disabled:y||_,className:"h-8 w-8",children:[(0,a.jsx)(i.A,{className:(0,f.cn)("h-4 w-4",(_||y)&&"animate-spin")}),(0,a.jsx)("span",{className:"sr-only",children:"Refresh temporary balances"})]})]})]}),(0,a.jsx)(p.BT,{children:"API keys with their current balances and usage statistics"})]}),(0,a.jsx)(p.Wu,{children:y?(0,a.jsx)("div",{className:"flex items-center justify-center py-8",children:(0,a.jsx)(c.A,{className:"text-primary h-8 w-8 animate-spin"})}):w?(0,a.jsxs)("div",{className:"bg-destructive/10 text-destructive flex items-center space-x-2 rounded-md p-4",children:[(0,a.jsx)(d.A,{className:"h-5 w-5"}),(0,a.jsxs)("span",{children:["Error loading temporary balances: ",k.message]})]}):(0,a.jsxs)("div",{className:"space-y-6",children:[(0,a.jsxs)("div",{className:"mb-6 grid grid-cols-1 gap-4 md:grid-cols-3",children:[(0,a.jsxs)("div",{className:"rounded-lg border border-blue-200 bg-gradient-to-r from-blue-50 to-indigo-50 p-4",children:[(0,a.jsx)("div",{className:"flex items-center justify-between",children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(m,{className:"h-5 w-5 text-blue-600"}),(0,a.jsx)("span",{className:"text-sm font-medium text-blue-800",children:"Total Balance"})]})}),(0,a.jsx)("div",{className:"mt-2 text-2xl font-bold text-blue-900",children:A(z.totalBalance)})]}),(0,a.jsxs)("div",{className:"rounded-lg border border-green-200 bg-gradient-to-r from-green-50 to-emerald-50 p-4",children:[(0,a.jsx)("div",{className:"flex items-center justify-between",children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(x,{className:"h-5 w-5 text-green-600"}),(0,a.jsx)("span",{className:"text-sm font-medium text-green-800",children:"Total Spent"})]})}),(0,a.jsx)("div",{className:"mt-2 text-2xl font-bold text-green-900",children:A(z.totalSpent)})]}),(0,a.jsxs)("div",{className:"rounded-lg border border-purple-200 bg-gradient-to-r from-purple-50 to-pink-50 p-4",children:[(0,a.jsx)("div",{className:"flex items-center justify-between",children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(r.A,{className:"h-5 w-5 text-purple-600"}),(0,a.jsx)("span",{className:"text-sm font-medium text-purple-800",children:"Total Requests"})]})}),(0,a.jsx)("div",{className:"mt-2 text-2xl font-bold text-purple-900",children:z.totalRequests.toLocaleString()})]})]}),(0,a.jsxs)("div",{className:"overflow-hidden rounded-lg border",children:[(0,a.jsxs)("div",{className:"bg-muted hidden grid-cols-6 gap-2 p-3 text-sm font-semibold md:grid",children:[(0,a.jsx)("div",{children:"Hashed Key"}),(0,a.jsx)("div",{className:"text-right",children:"Balance"}),(0,a.jsx)("div",{className:"text-right",children:"Total Spent"}),(0,a.jsx)("div",{className:"text-right",children:"Total Requests"}),(0,a.jsx)("div",{children:"Refund Address"}),(0,a.jsx)("div",{className:"text-right",children:"Expiry Time"})]}),S.length>0?S.map((e,s)=>(0,a.jsxs)("div",{className:(0,f.cn)("hover:bg-muted/50 border-t p-3 text-sm transition-colors",0===e.balance&&"opacity-60"),children:[(0,a.jsxs)("div",{className:"hidden grid-cols-6 gap-2 md:grid",children:[(0,a.jsx)("div",{className:"max-w-32 truncate font-mono text-xs break-all",children:e.hashed_key}),(0,a.jsx)("div",{className:"text-right font-mono",children:A(e.balance)}),(0,a.jsx)("div",{className:"text-right font-mono",children:A(e.total_spent)}),(0,a.jsx)("div",{className:"text-right font-mono",children:e.total_requests.toLocaleString()}),(0,a.jsx)("div",{className:"max-w-32 truncate font-mono text-xs break-all",children:e.refund_address||"-"}),(0,a.jsx)("div",{className:"text-right font-mono text-xs",children:e.key_expiry_time?(0,a.jsxs)("div",{className:"flex items-center justify-end gap-1",children:[(0,a.jsx)(h,{className:"h-3 w-3"}),(0,a.jsx)("span",{children:new Date(1e3*e.key_expiry_time).toLocaleDateString()})]}):"-"})]}),(0,a.jsxs)("div",{className:"space-y-3 md:hidden",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("span",{className:"text-muted-foreground text-xs font-medium",children:"Key"}),(0,a.jsx)("div",{className:"font-mono text-xs break-all",children:e.hashed_key})]}),(0,a.jsxs)("div",{className:"grid grid-cols-2 gap-3",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Balance"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:A(e.balance)})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Spent"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:A(e.total_spent)})]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-2 gap-3",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Requests"}),(0,a.jsx)("div",{className:"truncate font-mono text-sm",children:e.total_requests.toLocaleString()})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Expires"}),(0,a.jsx)("div",{className:"font-mono text-xs",children:e.key_expiry_time?(0,a.jsxs)("div",{className:"flex items-center gap-1",children:[(0,a.jsx)(h,{className:"h-3 w-3 flex-shrink-0"}),(0,a.jsx)("span",{className:"truncate",children:new Date(1e3*e.key_expiry_time).toLocaleDateString()})]}):"-"})]})]}),e.refund_address&&(0,a.jsxs)("div",{className:"space-y-1 border-t pt-2",children:[(0,a.jsx)("div",{className:"text-muted-foreground text-xs font-medium",children:"Refund Address"}),(0,a.jsx)("div",{className:"font-mono text-xs break-all",children:e.refund_address})]})]})]},s)):(0,a.jsx)("div",{className:"text-muted-foreground p-8 text-center text-sm",children:v?(0,a.jsxs)("div",{className:"flex flex-col items-center gap-2",children:[(0,a.jsx)(d.A,{className:"h-8 w-8"}),(0,a.jsx)("span",{children:"No temporary balances match your search"})]}):(0,a.jsxs)("div",{className:"flex flex-col items-center gap-2",children:[(0,a.jsx)(r.A,{className:"h-8 w-8"}),(0,a.jsx)("span",{children:"No temporary balances found"})]})})]}),b&&b.length>0&&(0,a.jsxs)("div",{className:"text-muted-foreground mt-4 text-xs",children:["Showing ",S.length," of ",b.length," temporary balances"]})]})})]})})}},2533:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]])},3728:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("refresh-cw",[["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"}]])},5195:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("key",[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4",key:"g0fldk"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}]])},6320:(e,s,t)=>{"use strict";t.d(s,{Cf:()=>m,Es:()=>h,L3:()=>u,c7:()=>x,lG:()=>i,rr:()=>p,zM:()=>c});var a=t(3422);t(4398);var l=t(4316),n=t(9680),r=t(9183);function i(e){let{...s}=e;return(0,a.jsx)(l.bL,{"data-slot":"dialog",...s})}function c(e){let{...s}=e;return(0,a.jsx)(l.l9,{"data-slot":"dialog-trigger",...s})}function d(e){let{...s}=e;return(0,a.jsx)(l.ZL,{"data-slot":"dialog-portal",...s})}function o(e){let{className:s,...t}=e;return(0,a.jsx)(l.hJ,{"data-slot":"dialog-overlay",className:(0,r.cn)("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",s),...t})}function m(e){let{className:s,children:t,...i}=e;return(0,a.jsxs)(d,{"data-slot":"dialog-portal",children:[(0,a.jsx)(o,{}),(0,a.jsxs)(l.UC,{"data-slot":"dialog-content",className:(0,r.cn)("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",s),...i,children:[t,(0,a.jsxs)(l.bm,{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:[(0,a.jsx)(n.A,{}),(0,a.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function x(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-header",className:(0,r.cn)("flex flex-col gap-2 text-center sm:text-left",s),...t})}function h(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-footer",className:(0,r.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",s),...t})}function u(e){let{className:s,...t}=e;return(0,a.jsx)(l.hE,{"data-slot":"dialog-title",className:(0,r.cn)("text-lg leading-none font-semibold",s),...t})}function p(e){let{className:s,...t}=e;return(0,a.jsx)(l.VY,{"data-slot":"dialog-description",className:(0,r.cn)("text-muted-foreground text-sm",s),...t})}}},e=>{var s=s=>e(e.s=s);e.O(0,[363,222,808,29,730,978,481,236,601,945,497,358],()=>s(1551)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/providers/page-24027db6adfd0b9b.js b/ui_out/_next/static/chunks/app/providers/page-24027db6adfd0b9b.js deleted file mode 100644 index 6d9c957f..00000000 --- a/ui_out/_next/static/chunks/app/providers/page-24027db6adfd0b9b.js +++ /dev/null @@ -1 +0,0 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[387],{989:(e,s,t)=>{"use strict";t.d(s,{A:()=>a});let a=(0,t(3929).A)("eye-off",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]])},2264:(e,s,t)=>{"use strict";t.d(s,{bq:()=>u,eb:()=>p,gC:()=>x,l6:()=>o,yv:()=>c});var a=t(3422);t(4398);var r=t(3439),n=t(9994),i=t(8940),l=t(4967),d=t(9183);function o(e){let{...s}=e;return(0,a.jsx)(r.bL,{"data-slot":"select",...s})}function c(e){let{...s}=e;return(0,a.jsx)(r.WT,{"data-slot":"select-value",...s})}function u(e){let{className:s,size:t="default",children:i,...l}=e;return(0,a.jsxs)(r.l9,{"data-slot":"select-trigger","data-size":t,className:(0,d.cn)("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",s),...l,children:[i,(0,a.jsx)(r.In,{asChild:!0,children:(0,a.jsx)(n.A,{className:"size-4 opacity-50"})})]})}function x(e){let{className:s,children:t,position:n="popper",...i}=e;return(0,a.jsx)(r.ZL,{children:(0,a.jsxs)(r.UC,{"data-slot":"select-content",className:(0,d.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--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","popper"===n&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",s),position:n,...i,children:[(0,a.jsx)(m,{}),(0,a.jsx)(r.LM,{className:(0,d.cn)("p-1","popper"===n&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:t}),(0,a.jsx)(h,{})]})})}function p(e){let{className:s,children:t,...n}=e;return(0,a.jsxs)(r.q7,{"data-slot":"select-item",className:(0,d.cn)("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",s),...n,children:[(0,a.jsx)("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:(0,a.jsx)(r.VF,{children:(0,a.jsx)(i.A,{className:"size-4"})})}),(0,a.jsx)(r.p4,{children:t})]})}function m(e){let{className:s,...t}=e;return(0,a.jsx)(r.PP,{"data-slot":"select-scroll-up-button",className:(0,d.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(l.A,{className:"size-4"})})}function h(e){let{className:s,...t}=e;return(0,a.jsx)(r.wn,{"data-slot":"select-scroll-down-button",className:(0,d.cn)("flex cursor-default items-center justify-center py-1",s),...t,children:(0,a.jsx)(n.A,{className:"size-4"})})}},6078:(e,s,t)=>{Promise.resolve().then(t.bind(t,8288))},6320:(e,s,t)=>{"use strict";t.d(s,{Cf:()=>u,Es:()=>p,L3:()=>m,c7:()=>x,lG:()=>l,rr:()=>h,zM:()=>d});var a=t(3422);t(4398);var r=t(4316),n=t(9680),i=t(9183);function l(e){let{...s}=e;return(0,a.jsx)(r.bL,{"data-slot":"dialog",...s})}function d(e){let{...s}=e;return(0,a.jsx)(r.l9,{"data-slot":"dialog-trigger",...s})}function o(e){let{...s}=e;return(0,a.jsx)(r.ZL,{"data-slot":"dialog-portal",...s})}function c(e){let{className:s,...t}=e;return(0,a.jsx)(r.hJ,{"data-slot":"dialog-overlay",className:(0,i.cn)("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",s),...t})}function u(e){let{className:s,children:t,...l}=e;return(0,a.jsxs)(o,{"data-slot":"dialog-portal",children:[(0,a.jsx)(c,{}),(0,a.jsxs)(r.UC,{"data-slot":"dialog-content",className:(0,i.cn)("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",s),...l,children:[t,(0,a.jsxs)(r.bm,{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:[(0,a.jsx)(n.A,{}),(0,a.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function x(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-header",className:(0,i.cn)("flex flex-col gap-2 text-center sm:text-left",s),...t})}function p(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"dialog-footer",className:(0,i.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",s),...t})}function m(e){let{className:s,...t}=e;return(0,a.jsx)(r.hE,{"data-slot":"dialog-title",className:(0,i.cn)("text-lg leading-none font-semibold",s),...t})}function h(e){let{className:s,...t}=e;return(0,a.jsx)(r.VY,{"data-slot":"dialog-description",className:(0,i.cn)("text-muted-foreground text-sm",s),...t})}},6568:(e,s,t)=>{"use strict";t.d(s,{d:()=>i});var a=t(3422);t(4398);var r=t(2495),n=t(9183);function i(e){let{className:s,...t}=e;return(0,a.jsx)(r.bL,{"data-slot":"switch",className:(0,n.cn)("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",s),...t,children:(0,a.jsx)(r.zi,{"data-slot":"switch-thumb",className:(0,n.cn)("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")})})}},6839:(e,s,t)=>{"use strict";t.d(s,{Xi:()=>d,av:()=>o,j7:()=>l,tU:()=>i});var a=t(3422);t(4398);var r=t(1749),n=t(9183);function i(e){let{className:s,...t}=e;return(0,a.jsx)(r.bL,{"data-slot":"tabs",className:(0,n.cn)("flex flex-col gap-2",s),...t})}function l(e){let{className:s,...t}=e;return(0,a.jsx)(r.B8,{"data-slot":"tabs-list",className:(0,n.cn)("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",s),...t})}function d(e){let{className:s,...t}=e;return(0,a.jsx)(r.l9,{"data-slot":"tabs-trigger",className:(0,n.cn)("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",s),...t})}function o(e){let{className:s,...t}=e;return(0,a.jsx)(r.UC,{"data-slot":"tabs-content",className:(0,n.cn)("flex-1 outline-none",s),...t})}},8288:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>L});var a=t(3422),r=t(953),n=t(7569),i=t(4756),l=t(3648),d=t(2738),o=t(8561),c=t(100),u=t(2349),x=t(6013),p=t(9119),m=t(2745),h=t(856),v=t(9675),g=t(2335),f=t(9285),j=t(4967),b=t(9994);let y=(0,t(3929).A)("pencil",[["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"}]]);var N=t(6541),_=t(989),w=t(7137),k=t(9442),z=t(6320),C=t(268),A=t(3130),P=t(2264),E=t(6568),F=t(6839),S=t(4398),I=t(3831);function L(){let e=(0,c.jE)(),[s,t]=(0,S.useState)(null),[L,U]=(0,S.useState)(!1),[O,R]=(0,S.useState)(!1),[M,q]=(0,S.useState)(null),[J,V]=(0,S.useState)(new Set),[$,K]=(0,S.useState)(null),[Q,T]=(0,S.useState)({provider_type:"openrouter",base_url:"",api_key:"",api_version:null,enabled:!0}),{data:D=[],isLoading:G,error:B}=(0,u.I)({queryKey:["upstream-providers"],queryFn:()=>p.zQ.getUpstreamProviders(),refetchOnWindowFocus:!1}),{data:W,isLoading:Z}=(0,u.I)({queryKey:["provider-models",$],queryFn:()=>$?p.zQ.getProviderModels($):Promise.resolve(null),enabled:!!$,refetchOnWindowFocus:!1}),X=(0,x.n)({mutationFn:e=>p.zQ.createUpstreamProvider(e),onSuccess:()=>{e.invalidateQueries({queryKey:["upstream-providers"]}),U(!1),I.oR.success("Provider created successfully"),ee()},onError:e=>{I.oR.error("Failed to create provider: ".concat(e.message))}}),H=(0,x.n)({mutationFn:e=>{let{id:s,data:t}=e;return p.zQ.updateUpstreamProvider(s,t)},onSuccess:()=>{e.invalidateQueries({queryKey:["upstream-providers"]}),R(!1),t(null),I.oR.success("Provider updated successfully")},onError:e=>{I.oR.error("Failed to update provider: ".concat(e.message))}}),Y=(0,x.n)({mutationFn:e=>p.zQ.deleteUpstreamProvider(e),onSuccess:()=>{e.invalidateQueries({queryKey:["upstream-providers"]}),I.oR.success("Provider deleted successfully")},onError:e=>{I.oR.error("Failed to delete provider: ".concat(e.message))}}),ee=()=>{T({provider_type:"openrouter",base_url:"",api_key:"",api_version:null,enabled:!0})},es=e=>{t(e),T({provider_type:e.provider_type,base_url:e.base_url,api_key:"",api_version:e.api_version||null,enabled:e.enabled}),R(!0)},et=e=>{confirm("Are you sure you want to delete this provider?")&&Y.mutate(e)},ea=e=>({openrouter:"https://openrouter.ai/api/v1",openai:"https://api.openai.com/v1",anthropic:"https://api.anthropic.com/v1",azure:"",ollama:"http://localhost:11434",generic:""})[e]||"",er=e=>{let s=new Set(J);s.has(e)?s.delete(e):s.add(e),V(s),s.has(e)?K(e):K(null)};return(0,a.jsxs)(r.SidebarProvider,{children:[(0,a.jsx)(n.AppSidebar,{variant:"inset"}),(0,a.jsxs)(r.SidebarInset,{children:[(0,a.jsx)(i.SiteHeader,{}),(0,a.jsx)("div",{className:"flex flex-1 flex-col",children:(0,a.jsxs)("div",{className:"@container/main flex flex-1 flex-col gap-4 p-4 md:gap-8 md:p-8",children:[(0,a.jsxs)("div",{className:"mb-6 flex items-center justify-between",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("h1",{className:"text-2xl font-bold tracking-tight",children:"Upstream Providers"}),(0,a.jsx)("p",{className:"text-muted-foreground mt-2 text-sm",children:"Manage your AI provider connections and credentials"})]}),(0,a.jsxs)(z.lG,{open:L,onOpenChange:U,children:[(0,a.jsx)(z.zM,{asChild:!0,children:(0,a.jsxs)(l.$,{className:"flex items-center gap-2",children:[(0,a.jsx)(h.A,{className:"h-4 w-4"}),"Add Provider"]})}),(0,a.jsxs)(z.Cf,{className:"sm:max-w-[500px]",children:[(0,a.jsxs)(z.c7,{children:[(0,a.jsx)(z.L3,{children:"Add Upstream Provider"}),(0,a.jsx)(z.rr,{children:"Configure a new AI provider connection"})]}),(0,a.jsxs)("div",{className:"grid gap-4 py-4",children:[(0,a.jsxs)("div",{className:"grid gap-2",children:[(0,a.jsx)(A.J,{htmlFor:"provider_type",children:"Provider Type"}),(0,a.jsxs)(P.l6,{value:Q.provider_type,onValueChange:e=>{T({...Q,provider_type:e,base_url:ea(e)})},children:[(0,a.jsx)(P.bq,{children:(0,a.jsx)(P.yv,{})}),(0,a.jsxs)(P.gC,{children:[(0,a.jsx)(P.eb,{value:"openrouter",children:"OpenRouter"}),(0,a.jsx)(P.eb,{value:"openai",children:"OpenAI"}),(0,a.jsx)(P.eb,{value:"anthropic",children:"Anthropic"}),(0,a.jsx)(P.eb,{value:"azure",children:"Azure OpenAI"}),(0,a.jsx)(P.eb,{value:"ollama",children:"Ollama"}),(0,a.jsx)(P.eb,{value:"generic",children:"Generic"})]})]})]}),(0,a.jsxs)("div",{className:"grid gap-2",children:[(0,a.jsx)(A.J,{htmlFor:"base_url",children:"Base URL"}),(0,a.jsx)(C.p,{id:"base_url",value:Q.base_url,onChange:e=>T({...Q,base_url:e.target.value}),placeholder:"https://api.example.com/v1"})]}),(0,a.jsxs)("div",{className:"grid gap-2",children:[(0,a.jsx)(A.J,{htmlFor:"api_key",children:"API Key"}),(0,a.jsx)(C.p,{id:"api_key",type:"password",value:Q.api_key,onChange:e=>T({...Q,api_key:e.target.value}),placeholder:"sk-..."})]}),"azure"===Q.provider_type&&(0,a.jsxs)("div",{className:"grid gap-2",children:[(0,a.jsx)(A.J,{htmlFor:"api_version",children:"API Version"}),(0,a.jsx)(C.p,{id:"api_version",value:Q.api_version||"",onChange:e=>T({...Q,api_version:e.target.value||null}),placeholder:"2024-02-15-preview"})]}),(0,a.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,a.jsx)(E.d,{id:"enabled",checked:Q.enabled,onCheckedChange:e=>T({...Q,enabled:e})}),(0,a.jsx)(A.J,{htmlFor:"enabled",children:"Enabled"})]})]}),(0,a.jsxs)(z.Es,{children:[(0,a.jsx)(l.$,{variant:"outline",onClick:()=>U(!1),children:"Cancel"}),(0,a.jsx)(l.$,{onClick:()=>{X.mutate(Q)},disabled:X.isPending,children:X.isPending?"Creating...":"Create"})]})]})]})]}),G?(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)(m.E,{className:"h-[100px] w-full"}),(0,a.jsx)(m.E,{className:"h-[100px] w-full"})]}):B?(0,a.jsxs)(k.Fc,{variant:"destructive",children:[(0,a.jsx)(v.A,{className:"h-4 w-4"}),(0,a.jsx)(k.TN,{children:"Failed to load providers. Please try refreshing the page."})]}):0===D.length?(0,a.jsx)(d.Zp,{children:(0,a.jsxs)(d.Wu,{className:"flex flex-col items-center justify-center py-12",children:[(0,a.jsx)(g.A,{className:"text-muted-foreground mb-4 h-12 w-12"}),(0,a.jsx)("h3",{className:"mb-2 text-lg font-semibold",children:"No providers configured"}),(0,a.jsx)("p",{className:"text-muted-foreground mb-4 text-sm",children:"Get started by adding your first upstream provider"}),(0,a.jsxs)(l.$,{onClick:()=>U(!0),children:[(0,a.jsx)(h.A,{className:"mr-2 h-4 w-4"}),"Add Provider"]})]})}):(0,a.jsx)("div",{className:"grid gap-4",children:D.map(e=>(0,a.jsxs)(d.Zp,{children:[(0,a.jsx)(d.aR,{children:(0,a.jsxs)("div",{className:"flex items-start justify-between",children:[(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)(d.ZB,{className:"text-lg",children:e.provider_type}),(0,a.jsx)(o.E,{variant:e.enabled?"default":"secondary",children:e.enabled?"Enabled":"Disabled"})]}),(0,a.jsx)(d.BT,{className:"mt-1",children:e.base_url})]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsxs)(l.$,{variant:"outline",size:"sm",onClick:()=>er(e.id),children:[(0,a.jsx)(f.A,{className:"mr-1 h-4 w-4"}),"Models",J.has(e.id)?(0,a.jsx)(j.A,{className:"ml-1 h-4 w-4"}):(0,a.jsx)(b.A,{className:"ml-1 h-4 w-4"})]}),(0,a.jsx)(l.$,{variant:"outline",size:"sm",onClick:()=>es(e),children:(0,a.jsx)(y,{className:"h-4 w-4"})}),(0,a.jsx)(l.$,{variant:"outline",size:"sm",onClick:()=>et(e.id),children:(0,a.jsx)(N.A,{className:"h-4 w-4"})})]})]})}),(0,a.jsx)(d.Wu,{children:(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,a.jsx)("span",{className:"text-muted-foreground",children:"Provider ID:"}),(0,a.jsx)("span",{className:"font-mono",children:e.id})]}),e.api_version&&(0,a.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,a.jsx)("span",{className:"text-muted-foreground",children:"API Version:"}),(0,a.jsx)("span",{className:"font-mono",children:e.api_version})]}),(0,a.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,a.jsx)("span",{className:"text-muted-foreground",children:"API Key:"}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"font-mono",children:M===e.id?e.api_key||"[REDACTED]":"••••••••"}),(0,a.jsx)(l.$,{variant:"ghost",size:"sm",onClick:()=>q(M===e.id?null:e.id),children:M===e.id?(0,a.jsx)(_.A,{className:"h-4 w-4"}):(0,a.jsx)(w.A,{className:"h-4 w-4"})})]})]})]}),J.has(e.id)&&(0,a.jsx)("div",{className:"mt-4 border-t pt-4",children:Z&&$===e.id?(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(m.E,{className:"h-[40px] w-full"}),(0,a.jsx)(m.E,{className:"h-[40px] w-full"})]}):W&&$===e.id?(0,a.jsxs)(F.tU,{defaultValue:"remote",className:"w-full",children:[(0,a.jsxs)(F.j7,{className:"grid w-full grid-cols-2",children:[(0,a.jsxs)(F.Xi,{value:"remote",children:["Remote Models",(0,a.jsx)(o.E,{variant:"secondary",className:"ml-2",children:W.remote_models.length})]}),(0,a.jsxs)(F.Xi,{value:"db",children:["Database Models",(0,a.jsx)(o.E,{variant:"secondary",className:"ml-2",children:W.db_models.length})]})]}),(0,a.jsx)(F.av,{value:"db",className:"mt-4 space-y-2",children:0===W.db_models.length?(0,a.jsx)("div",{className:"text-muted-foreground py-4 text-center text-sm",children:"No database models configured"}):(0,a.jsx)("div",{className:"space-y-2",children:W.db_models.map(e=>{var s;return(0,a.jsxs)("div",{className:"hover:bg-accent flex items-center justify-between rounded-lg border p-3 transition-colors",children:[(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"font-mono text-sm font-medium",children:e.id}),(0,a.jsx)(o.E,{variant:e.enabled?"default":"secondary",className:"text-xs",children:e.enabled?"Enabled":"Disabled"})]}),(0,a.jsx)("div",{className:"text-muted-foreground mt-1 text-xs",children:e.description||e.name})]}),(0,a.jsxs)("div",{className:"text-muted-foreground text-xs",children:[null==(s=e.context_length)?void 0:s.toLocaleString()," ","tokens"]})]},e.id)})})}),(0,a.jsx)(F.av,{value:"remote",className:"mt-4 space-y-2",children:0===W.remote_models.length?(0,a.jsx)("div",{className:"text-muted-foreground py-4 text-center text-sm",children:"No remote models available"}):(0,a.jsx)("div",{className:"space-y-2",children:W.remote_models.map(e=>{var s;return(0,a.jsxs)("div",{className:"hover:bg-accent flex items-center justify-between rounded-lg border p-3 transition-colors",children:[(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsx)("div",{className:"font-mono text-sm font-medium",children:e.id}),(0,a.jsx)("div",{className:"text-muted-foreground mt-1 text-xs",children:e.description||e.name})]}),(0,a.jsxs)("div",{className:"text-muted-foreground text-xs",children:[null==(s=e.context_length)?void 0:s.toLocaleString()," ","tokens"]})]},e.id)})})})]}):null})]})})]},e.id))})]})}),(0,a.jsx)(z.lG,{open:O,onOpenChange:R,children:(0,a.jsxs)(z.Cf,{className:"sm:max-w-[500px]",children:[(0,a.jsxs)(z.c7,{children:[(0,a.jsx)(z.L3,{children:"Edit Upstream Provider"}),(0,a.jsx)(z.rr,{children:"Update provider configuration"})]}),(0,a.jsxs)("div",{className:"grid gap-4 py-4",children:[(0,a.jsxs)("div",{className:"grid gap-2",children:[(0,a.jsx)(A.J,{htmlFor:"edit_provider_type",children:"Provider Type"}),(0,a.jsxs)(P.l6,{value:Q.provider_type,onValueChange:e=>{T({...Q,provider_type:e})},children:[(0,a.jsx)(P.bq,{children:(0,a.jsx)(P.yv,{})}),(0,a.jsxs)(P.gC,{children:[(0,a.jsx)(P.eb,{value:"openrouter",children:"OpenRouter"}),(0,a.jsx)(P.eb,{value:"openai",children:"OpenAI"}),(0,a.jsx)(P.eb,{value:"anthropic",children:"Anthropic"}),(0,a.jsx)(P.eb,{value:"azure",children:"Azure OpenAI"}),(0,a.jsx)(P.eb,{value:"ollama",children:"Ollama"}),(0,a.jsx)(P.eb,{value:"generic",children:"Generic"})]})]})]}),(0,a.jsxs)("div",{className:"grid gap-2",children:[(0,a.jsx)(A.J,{htmlFor:"edit_base_url",children:"Base URL"}),(0,a.jsx)(C.p,{id:"edit_base_url",value:Q.base_url,onChange:e=>T({...Q,base_url:e.target.value}),placeholder:"https://api.example.com/v1"})]}),(0,a.jsxs)("div",{className:"grid gap-2",children:[(0,a.jsx)(A.J,{htmlFor:"edit_api_key",children:"API Key (leave blank to keep current)"}),(0,a.jsx)(C.p,{id:"edit_api_key",type:"password",value:Q.api_key,onChange:e=>T({...Q,api_key:e.target.value}),placeholder:"Leave blank to keep current"})]}),"azure"===Q.provider_type&&(0,a.jsxs)("div",{className:"grid gap-2",children:[(0,a.jsx)(A.J,{htmlFor:"edit_api_version",children:"API Version"}),(0,a.jsx)(C.p,{id:"edit_api_version",value:Q.api_version||"",onChange:e=>T({...Q,api_version:e.target.value||null}),placeholder:"2024-02-15-preview"})]}),(0,a.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,a.jsx)(E.d,{id:"edit_enabled",checked:Q.enabled,onCheckedChange:e=>T({...Q,enabled:e})}),(0,a.jsx)(A.J,{htmlFor:"edit_enabled",children:"Enabled"})]})]}),(0,a.jsxs)(z.Es,{children:[(0,a.jsx)(l.$,{variant:"outline",onClick:()=>R(!1),children:"Cancel"}),(0,a.jsx)(l.$,{onClick:()=>{if(!s)return;let e={provider_type:Q.provider_type,base_url:Q.base_url,api_version:Q.api_version,enabled:Q.enabled};Q.api_key&&(e.api_key=Q.api_key),H.mutate({id:s.id,data:e})},disabled:H.isPending,children:H.isPending?"Updating...":"Update"})]})]})})]})]})}},8561:(e,s,t)=>{"use strict";t.d(s,{E:()=>l});var a=t(3422);t(4398);var r=t(4676),n=t(9183);let i=(0,r.F)("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground",success:"border-transparent bg-green-500 text-white hover:bg-green-500/80",warning:"border-transparent bg-yellow-500 text-white hover:bg-yellow-500/80",error:"border-transparent bg-red-500 text-white hover:bg-red-500/80"}},defaultVariants:{variant:"default"}});function l(e){let{className:s,variant:t,...r}=e;return(0,a.jsx)("div",{className:(0,n.cn)(i({variant:t}),s),...r})}},9442:(e,s,t)=>{"use strict";t.d(s,{Fc:()=>l,TN:()=>d});var a=t(3422);t(4398);var r=t(4676),n=t(9183);let i=(0,r.F)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"}},defaultVariants:{variant:"default"}});function l(e){let{className:s,variant:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,n.cn)(i({variant:t}),s),...r})}function d(e){let{className:s,...t}=e;return(0,a.jsx)("div",{"data-slot":"alert-description",className:(0,n.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",s),...t})}}},e=>{var s=s=>e(e.s=s);e.O(0,[363,222,808,29,730,978,481,982,236,601,945,497,358],()=>s(6078)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/providers/page-d7c9b193573b160c.js b/ui_out/_next/static/chunks/app/providers/page-d7c9b193573b160c.js new file mode 100644 index 00000000..e51a1f0c --- /dev/null +++ b/ui_out/_next/static/chunks/app/providers/page-d7c9b193573b160c.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[387],{989:(e,s,a)=>{"use strict";a.d(s,{A:()=>t});let t=(0,a(3929).A)("eye-off",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]])},2264:(e,s,a)=>{"use strict";a.d(s,{bq:()=>u,eb:()=>m,gC:()=>x,l6:()=>o,yv:()=>c});var t=a(3422);a(4398);var r=a(3439),n=a(9994),l=a(8940),i=a(4967),d=a(9183);function o(e){let{...s}=e;return(0,t.jsx)(r.bL,{"data-slot":"select",...s})}function c(e){let{...s}=e;return(0,t.jsx)(r.WT,{"data-slot":"select-value",...s})}function u(e){let{className:s,size:a="default",children:l,...i}=e;return(0,t.jsxs)(r.l9,{"data-slot":"select-trigger","data-size":a,className:(0,d.cn)("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",s),...i,children:[l,(0,t.jsx)(r.In,{asChild:!0,children:(0,t.jsx)(n.A,{className:"size-4 opacity-50"})})]})}function x(e){let{className:s,children:a,position:n="popper",...l}=e;return(0,t.jsx)(r.ZL,{children:(0,t.jsxs)(r.UC,{"data-slot":"select-content",className:(0,d.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--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","popper"===n&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",s),position:n,...l,children:[(0,t.jsx)(p,{}),(0,t.jsx)(r.LM,{className:(0,d.cn)("p-1","popper"===n&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:a}),(0,t.jsx)(h,{})]})})}function m(e){let{className:s,children:a,...n}=e;return(0,t.jsxs)(r.q7,{"data-slot":"select-item",className:(0,d.cn)("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",s),...n,children:[(0,t.jsx)("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:(0,t.jsx)(r.VF,{children:(0,t.jsx)(l.A,{className:"size-4"})})}),(0,t.jsx)(r.p4,{children:a})]})}function p(e){let{className:s,...a}=e;return(0,t.jsx)(r.PP,{"data-slot":"select-scroll-up-button",className:(0,d.cn)("flex cursor-default items-center justify-center py-1",s),...a,children:(0,t.jsx)(i.A,{className:"size-4"})})}function h(e){let{className:s,...a}=e;return(0,t.jsx)(r.wn,{"data-slot":"select-scroll-down-button",className:(0,d.cn)("flex cursor-default items-center justify-center py-1",s),...a,children:(0,t.jsx)(n.A,{className:"size-4"})})}},6078:(e,s,a)=>{Promise.resolve().then(a.bind(a,8288))},6320:(e,s,a)=>{"use strict";a.d(s,{Cf:()=>u,Es:()=>m,L3:()=>p,c7:()=>x,lG:()=>i,rr:()=>h,zM:()=>d});var t=a(3422);a(4398);var r=a(4316),n=a(9680),l=a(9183);function i(e){let{...s}=e;return(0,t.jsx)(r.bL,{"data-slot":"dialog",...s})}function d(e){let{...s}=e;return(0,t.jsx)(r.l9,{"data-slot":"dialog-trigger",...s})}function o(e){let{...s}=e;return(0,t.jsx)(r.ZL,{"data-slot":"dialog-portal",...s})}function c(e){let{className:s,...a}=e;return(0,t.jsx)(r.hJ,{"data-slot":"dialog-overlay",className:(0,l.cn)("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",s),...a})}function u(e){let{className:s,children:a,...i}=e;return(0,t.jsxs)(o,{"data-slot":"dialog-portal",children:[(0,t.jsx)(c,{}),(0,t.jsxs)(r.UC,{"data-slot":"dialog-content",className:(0,l.cn)("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",s),...i,children:[a,(0,t.jsxs)(r.bm,{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:[(0,t.jsx)(n.A,{}),(0,t.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function x(e){let{className:s,...a}=e;return(0,t.jsx)("div",{"data-slot":"dialog-header",className:(0,l.cn)("flex flex-col gap-2 text-center sm:text-left",s),...a})}function m(e){let{className:s,...a}=e;return(0,t.jsx)("div",{"data-slot":"dialog-footer",className:(0,l.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",s),...a})}function p(e){let{className:s,...a}=e;return(0,t.jsx)(r.hE,{"data-slot":"dialog-title",className:(0,l.cn)("text-lg leading-none font-semibold",s),...a})}function h(e){let{className:s,...a}=e;return(0,t.jsx)(r.VY,{"data-slot":"dialog-description",className:(0,l.cn)("text-muted-foreground text-sm",s),...a})}},6568:(e,s,a)=>{"use strict";a.d(s,{d:()=>l});var t=a(3422);a(4398);var r=a(2495),n=a(9183);function l(e){let{className:s,...a}=e;return(0,t.jsx)(r.bL,{"data-slot":"switch",className:(0,n.cn)("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",s),...a,children:(0,t.jsx)(r.zi,{"data-slot":"switch-thumb",className:(0,n.cn)("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")})})}},6839:(e,s,a)=>{"use strict";a.d(s,{Xi:()=>d,av:()=>o,j7:()=>i,tU:()=>l});var t=a(3422);a(4398);var r=a(1749),n=a(9183);function l(e){let{className:s,...a}=e;return(0,t.jsx)(r.bL,{"data-slot":"tabs",className:(0,n.cn)("flex flex-col gap-2",s),...a})}function i(e){let{className:s,...a}=e;return(0,t.jsx)(r.B8,{"data-slot":"tabs-list",className:(0,n.cn)("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",s),...a})}function d(e){let{className:s,...a}=e;return(0,t.jsx)(r.l9,{"data-slot":"tabs-trigger",className:(0,n.cn)("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",s),...a})}function o(e){let{className:s,...a}=e;return(0,t.jsx)(r.UC,{"data-slot":"tabs-content",className:(0,n.cn)("flex-1 outline-none",s),...a})}},8288:(e,s,a)=>{"use strict";a.r(s),a.d(s,{default:()=>L});var t=a(3422),r=a(953),n=a(7569),l=a(532),i=a(3648),d=a(2738),o=a(8561),c=a(100),u=a(2349),x=a(6013),m=a(9119),p=a(2745),h=a(856),v=a(9675),g=a(2335),f=a(9285),j=a(4967),b=a(9994);let y=(0,a(3929).A)("pencil",[["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"}]]);var N=a(6541),_=a(989),w=a(7137),k=a(9442),z=a(6320),C=a(268),A=a(3130),P=a(2264),E=a(6568),F=a(6839),S=a(4398),I=a(3831);function L(){let e=(0,c.jE)(),[s,a]=(0,S.useState)(null),[L,U]=(0,S.useState)(!1),[O,R]=(0,S.useState)(!1),[M,q]=(0,S.useState)(null),[J,V]=(0,S.useState)(new Set),[$,K]=(0,S.useState)(null),[Q,D]=(0,S.useState)({provider_type:"openrouter",base_url:"",api_key:"",api_version:null,enabled:!0}),{data:T=[],isLoading:B,error:G}=(0,u.I)({queryKey:["upstream-providers"],queryFn:()=>m.zQ.getUpstreamProviders(),refetchOnWindowFocus:!1}),{data:W,isLoading:Z}=(0,u.I)({queryKey:["provider-models",$],queryFn:()=>$?m.zQ.getProviderModels($):Promise.resolve(null),enabled:!!$,refetchOnWindowFocus:!1}),X=(0,x.n)({mutationFn:e=>m.zQ.createUpstreamProvider(e),onSuccess:()=>{e.invalidateQueries({queryKey:["upstream-providers"]}),U(!1),I.oR.success("Provider created successfully"),ee()},onError:e=>{I.oR.error("Failed to create provider: ".concat(e.message))}}),H=(0,x.n)({mutationFn:e=>{let{id:s,data:a}=e;return m.zQ.updateUpstreamProvider(s,a)},onSuccess:()=>{e.invalidateQueries({queryKey:["upstream-providers"]}),R(!1),a(null),I.oR.success("Provider updated successfully")},onError:e=>{I.oR.error("Failed to update provider: ".concat(e.message))}}),Y=(0,x.n)({mutationFn:e=>m.zQ.deleteUpstreamProvider(e),onSuccess:()=>{e.invalidateQueries({queryKey:["upstream-providers"]}),I.oR.success("Provider deleted successfully")},onError:e=>{I.oR.error("Failed to delete provider: ".concat(e.message))}}),ee=()=>{D({provider_type:"openrouter",base_url:"",api_key:"",api_version:null,enabled:!0})},es=e=>{a(e),D({provider_type:e.provider_type,base_url:e.base_url,api_key:"",api_version:e.api_version||null,enabled:e.enabled}),R(!0)},ea=e=>{confirm("Are you sure you want to delete this provider?")&&Y.mutate(e)},et=e=>({openrouter:"https://openrouter.ai/api/v1",openai:"https://api.openai.com/v1",anthropic:"https://api.anthropic.com/v1",azure:"",ollama:"http://localhost:11434",generic:""})[e]||"",er=e=>{let s=new Set(J);s.has(e)?s.delete(e):s.add(e),V(s),s.has(e)?K(e):K(null)};return(0,t.jsxs)(r.SidebarProvider,{children:[(0,t.jsx)(n.AppSidebar,{variant:"inset"}),(0,t.jsxs)(r.SidebarInset,{children:[(0,t.jsx)(l.SiteHeader,{}),(0,t.jsx)("div",{className:"flex flex-1 flex-col",children:(0,t.jsxs)("div",{className:"@container/main flex flex-1 flex-col gap-4 p-4 md:gap-8 md:p-8",children:[(0,t.jsxs)("div",{className:"mb-6 flex items-center justify-between",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h1",{className:"text-2xl font-bold tracking-tight",children:"Upstream Providers"}),(0,t.jsx)("p",{className:"text-muted-foreground mt-2 text-sm",children:"Manage your AI provider connections and credentials"})]}),(0,t.jsxs)(z.lG,{open:L,onOpenChange:U,children:[(0,t.jsx)(z.zM,{asChild:!0,children:(0,t.jsxs)(i.$,{className:"flex items-center gap-2",children:[(0,t.jsx)(h.A,{className:"h-4 w-4"}),"Add Provider"]})}),(0,t.jsxs)(z.Cf,{className:"sm:max-w-[500px]",children:[(0,t.jsxs)(z.c7,{children:[(0,t.jsx)(z.L3,{children:"Add Upstream Provider"}),(0,t.jsx)(z.rr,{children:"Configure a new AI provider connection"})]}),(0,t.jsxs)("div",{className:"grid gap-4 py-4",children:[(0,t.jsxs)("div",{className:"grid gap-2",children:[(0,t.jsx)(A.J,{htmlFor:"provider_type",children:"Provider Type"}),(0,t.jsxs)(P.l6,{value:Q.provider_type,onValueChange:e=>{D({...Q,provider_type:e,base_url:et(e)})},children:[(0,t.jsx)(P.bq,{children:(0,t.jsx)(P.yv,{})}),(0,t.jsxs)(P.gC,{children:[(0,t.jsx)(P.eb,{value:"openrouter",children:"OpenRouter"}),(0,t.jsx)(P.eb,{value:"openai",children:"OpenAI"}),(0,t.jsx)(P.eb,{value:"anthropic",children:"Anthropic"}),(0,t.jsx)(P.eb,{value:"azure",children:"Azure OpenAI"}),(0,t.jsx)(P.eb,{value:"ollama",children:"Ollama"}),(0,t.jsx)(P.eb,{value:"generic",children:"Generic"})]})]})]}),(0,t.jsxs)("div",{className:"grid gap-2",children:[(0,t.jsx)(A.J,{htmlFor:"base_url",children:"Base URL"}),(0,t.jsx)(C.p,{id:"base_url",value:Q.base_url,onChange:e=>D({...Q,base_url:e.target.value}),placeholder:"https://api.example.com/v1"})]}),(0,t.jsxs)("div",{className:"grid gap-2",children:[(0,t.jsx)(A.J,{htmlFor:"api_key",children:"API Key"}),(0,t.jsx)(C.p,{id:"api_key",type:"password",value:Q.api_key,onChange:e=>D({...Q,api_key:e.target.value}),placeholder:"sk-..."})]}),"azure"===Q.provider_type&&(0,t.jsxs)("div",{className:"grid gap-2",children:[(0,t.jsx)(A.J,{htmlFor:"api_version",children:"API Version"}),(0,t.jsx)(C.p,{id:"api_version",value:Q.api_version||"",onChange:e=>D({...Q,api_version:e.target.value||null}),placeholder:"2024-02-15-preview"})]}),(0,t.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,t.jsx)(E.d,{id:"enabled",checked:Q.enabled,onCheckedChange:e=>D({...Q,enabled:e})}),(0,t.jsx)(A.J,{htmlFor:"enabled",children:"Enabled"})]})]}),(0,t.jsxs)(z.Es,{children:[(0,t.jsx)(i.$,{variant:"outline",onClick:()=>U(!1),children:"Cancel"}),(0,t.jsx)(i.$,{onClick:()=>{X.mutate(Q)},disabled:X.isPending,children:X.isPending?"Creating...":"Create"})]})]})]})]}),B?(0,t.jsxs)("div",{className:"space-y-4",children:[(0,t.jsx)(p.E,{className:"h-[100px] w-full"}),(0,t.jsx)(p.E,{className:"h-[100px] w-full"})]}):G?(0,t.jsxs)(k.Fc,{variant:"destructive",children:[(0,t.jsx)(v.A,{className:"h-4 w-4"}),(0,t.jsx)(k.TN,{children:"Failed to load providers. Please try refreshing the page."})]}):0===T.length?(0,t.jsx)(d.Zp,{children:(0,t.jsxs)(d.Wu,{className:"flex flex-col items-center justify-center py-12",children:[(0,t.jsx)(g.A,{className:"text-muted-foreground mb-4 h-12 w-12"}),(0,t.jsx)("h3",{className:"mb-2 text-lg font-semibold",children:"No providers configured"}),(0,t.jsx)("p",{className:"text-muted-foreground mb-4 text-sm",children:"Get started by adding your first upstream provider"}),(0,t.jsxs)(i.$,{onClick:()=>U(!0),children:[(0,t.jsx)(h.A,{className:"mr-2 h-4 w-4"}),"Add Provider"]})]})}):(0,t.jsx)("div",{className:"grid gap-4",children:T.map(e=>(0,t.jsxs)(d.Zp,{children:[(0,t.jsx)(d.aR,{children:(0,t.jsxs)("div",{className:"flex flex-col gap-4 sm:flex-row sm:items-start sm:justify-between",children:[(0,t.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,t.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row sm:items-center",children:[(0,t.jsx)(d.ZB,{className:"truncate text-lg",children:e.provider_type}),(0,t.jsx)(o.E,{variant:e.enabled?"default":"secondary",className:"w-fit sm:ml-2",children:e.enabled?"Enabled":"Disabled"})]}),(0,t.jsx)(d.BT,{className:"mt-1 break-all",children:e.base_url})]}),(0,t.jsxs)("div",{className:"grid grid-cols-3 gap-2 sm:flex sm:flex-nowrap",children:[(0,t.jsxs)(i.$,{variant:"outline",size:"sm",onClick:()=>er(e.id),className:"w-full sm:w-auto",children:[(0,t.jsx)(f.A,{className:"mr-1 h-4 w-4"}),(0,t.jsx)("span",{className:"hidden sm:inline",children:"Models"}),J.has(e.id)?(0,t.jsx)(j.A,{className:"ml-1 h-4 w-4"}):(0,t.jsx)(b.A,{className:"ml-1 h-4 w-4"})]}),(0,t.jsx)(i.$,{variant:"outline",size:"sm",onClick:()=>es(e),className:"w-full sm:w-auto",children:(0,t.jsx)(y,{className:"h-4 w-4"})}),(0,t.jsx)(i.$,{variant:"outline",size:"sm",onClick:()=>ea(e.id),className:"w-full sm:w-auto",children:(0,t.jsx)(N.A,{className:"h-4 w-4"})})]})]})}),(0,t.jsx)(d.Wu,{children:(0,t.jsxs)("div",{className:"space-y-4",children:[(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,t.jsx)("span",{className:"text-muted-foreground",children:"Provider ID:"}),(0,t.jsx)("span",{className:"font-mono",children:e.id})]}),e.api_version&&(0,t.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,t.jsx)("span",{className:"text-muted-foreground",children:"API Version:"}),(0,t.jsx)("span",{className:"font-mono",children:e.api_version})]}),(0,t.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,t.jsx)("span",{className:"text-muted-foreground",children:"API Key:"}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("span",{className:"font-mono",children:M===e.id?e.api_key||"[REDACTED]":"••••••••"}),(0,t.jsx)(i.$,{variant:"ghost",size:"sm",onClick:()=>q(M===e.id?null:e.id),children:M===e.id?(0,t.jsx)(_.A,{className:"h-4 w-4"}):(0,t.jsx)(w.A,{className:"h-4 w-4"})})]})]})]}),J.has(e.id)&&(0,t.jsx)("div",{className:"mt-4 border-t pt-4",children:Z&&$===e.id?(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)(p.E,{className:"h-[40px] w-full"}),(0,t.jsx)(p.E,{className:"h-[40px] w-full"})]}):W&&$===e.id?(0,t.jsxs)(F.tU,{defaultValue:"remote",className:"w-full",children:[(0,t.jsxs)(F.j7,{className:"grid w-full grid-cols-2",children:[(0,t.jsxs)(F.Xi,{value:"remote",className:"text-xs sm:text-sm",children:[(0,t.jsx)("span",{className:"hidden sm:inline",children:"Remote Models"}),(0,t.jsx)("span",{className:"sm:hidden",children:"Remote"}),(0,t.jsx)(o.E,{variant:"secondary",className:"ml-1 text-xs sm:ml-2",children:W.remote_models.length})]}),(0,t.jsxs)(F.Xi,{value:"db",className:"text-xs sm:text-sm",children:[(0,t.jsx)("span",{className:"hidden sm:inline",children:"Database Models"}),(0,t.jsx)("span",{className:"sm:hidden",children:"DB"}),(0,t.jsx)(o.E,{variant:"secondary",className:"ml-1 text-xs sm:ml-2",children:W.db_models.length})]})]}),(0,t.jsx)(F.av,{value:"db",className:"mt-4 space-y-2",children:0===W.db_models.length?(0,t.jsx)("div",{className:"text-muted-foreground py-4 text-center text-sm",children:"No database models configured"}):(0,t.jsx)("div",{className:"space-y-2",children:W.db_models.map(e=>{var s;return(0,t.jsxs)("div",{className:"hover:bg-accent flex flex-col gap-2 rounded-lg border p-3 transition-colors sm:flex-row sm:items-center sm:justify-between",children:[(0,t.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,t.jsxs)("div",{className:"flex flex-col gap-1 sm:flex-row sm:items-center sm:gap-2",children:[(0,t.jsx)("span",{className:"truncate font-mono text-sm font-medium",children:e.id}),(0,t.jsx)(o.E,{variant:e.enabled?"default":"secondary",className:"w-fit text-xs",children:e.enabled?"Enabled":"Disabled"})]}),(0,t.jsx)("div",{className:"text-muted-foreground mt-1 text-xs break-words",children:e.description||e.name})]}),(0,t.jsxs)("div",{className:"text-muted-foreground text-xs whitespace-nowrap",children:[null==(s=e.context_length)?void 0:s.toLocaleString()," ","tokens"]})]},e.id)})})}),(0,t.jsx)(F.av,{value:"remote",className:"mt-4 space-y-2",children:0===W.remote_models.length?(0,t.jsx)("div",{className:"text-muted-foreground py-4 text-center text-sm",children:"No remote models available"}):(0,t.jsx)("div",{className:"space-y-2",children:W.remote_models.map(e=>{var s;return(0,t.jsxs)("div",{className:"hover:bg-accent flex flex-col gap-2 rounded-lg border p-3 transition-colors sm:flex-row sm:items-center sm:justify-between",children:[(0,t.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,t.jsx)("div",{className:"truncate font-mono text-sm font-medium",children:e.id}),(0,t.jsx)("div",{className:"text-muted-foreground mt-1 text-xs break-words",children:e.description||e.name})]}),(0,t.jsxs)("div",{className:"text-muted-foreground text-xs whitespace-nowrap",children:[null==(s=e.context_length)?void 0:s.toLocaleString()," ","tokens"]})]},e.id)})})})]}):null})]})})]},e.id))})]})}),(0,t.jsx)(z.lG,{open:O,onOpenChange:R,children:(0,t.jsxs)(z.Cf,{className:"sm:max-w-[500px]",children:[(0,t.jsxs)(z.c7,{children:[(0,t.jsx)(z.L3,{children:"Edit Upstream Provider"}),(0,t.jsx)(z.rr,{children:"Update provider configuration"})]}),(0,t.jsxs)("div",{className:"grid gap-4 py-4",children:[(0,t.jsxs)("div",{className:"grid gap-2",children:[(0,t.jsx)(A.J,{htmlFor:"edit_provider_type",children:"Provider Type"}),(0,t.jsxs)(P.l6,{value:Q.provider_type,onValueChange:e=>{D({...Q,provider_type:e})},children:[(0,t.jsx)(P.bq,{children:(0,t.jsx)(P.yv,{})}),(0,t.jsxs)(P.gC,{children:[(0,t.jsx)(P.eb,{value:"openrouter",children:"OpenRouter"}),(0,t.jsx)(P.eb,{value:"openai",children:"OpenAI"}),(0,t.jsx)(P.eb,{value:"anthropic",children:"Anthropic"}),(0,t.jsx)(P.eb,{value:"azure",children:"Azure OpenAI"}),(0,t.jsx)(P.eb,{value:"ollama",children:"Ollama"}),(0,t.jsx)(P.eb,{value:"generic",children:"Generic"})]})]})]}),(0,t.jsxs)("div",{className:"grid gap-2",children:[(0,t.jsx)(A.J,{htmlFor:"edit_base_url",children:"Base URL"}),(0,t.jsx)(C.p,{id:"edit_base_url",value:Q.base_url,onChange:e=>D({...Q,base_url:e.target.value}),placeholder:"https://api.example.com/v1"})]}),(0,t.jsxs)("div",{className:"grid gap-2",children:[(0,t.jsx)(A.J,{htmlFor:"edit_api_key",children:"API Key (leave blank to keep current)"}),(0,t.jsx)(C.p,{id:"edit_api_key",type:"password",value:Q.api_key,onChange:e=>D({...Q,api_key:e.target.value}),placeholder:"Leave blank to keep current"})]}),"azure"===Q.provider_type&&(0,t.jsxs)("div",{className:"grid gap-2",children:[(0,t.jsx)(A.J,{htmlFor:"edit_api_version",children:"API Version"}),(0,t.jsx)(C.p,{id:"edit_api_version",value:Q.api_version||"",onChange:e=>D({...Q,api_version:e.target.value||null}),placeholder:"2024-02-15-preview"})]}),(0,t.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,t.jsx)(E.d,{id:"edit_enabled",checked:Q.enabled,onCheckedChange:e=>D({...Q,enabled:e})}),(0,t.jsx)(A.J,{htmlFor:"edit_enabled",children:"Enabled"})]})]}),(0,t.jsxs)(z.Es,{children:[(0,t.jsx)(i.$,{variant:"outline",onClick:()=>R(!1),children:"Cancel"}),(0,t.jsx)(i.$,{onClick:()=>{if(!s)return;let e={provider_type:Q.provider_type,base_url:Q.base_url,api_version:Q.api_version,enabled:Q.enabled};Q.api_key&&(e.api_key=Q.api_key),H.mutate({id:s.id,data:e})},disabled:H.isPending,children:H.isPending?"Updating...":"Update"})]})]})})]})]})}},8561:(e,s,a)=>{"use strict";a.d(s,{E:()=>i});var t=a(3422);a(4398);var r=a(4676),n=a(9183);let l=(0,r.F)("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground",success:"border-transparent bg-green-500 text-white hover:bg-green-500/80",warning:"border-transparent bg-yellow-500 text-white hover:bg-yellow-500/80",error:"border-transparent bg-red-500 text-white hover:bg-red-500/80"}},defaultVariants:{variant:"default"}});function i(e){let{className:s,variant:a,...r}=e;return(0,t.jsx)("div",{className:(0,n.cn)(l({variant:a}),s),...r})}},9442:(e,s,a)=>{"use strict";a.d(s,{Fc:()=>i,TN:()=>d});var t=a(3422);a(4398);var r=a(4676),n=a(9183);let l=(0,r.F)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"}},defaultVariants:{variant:"default"}});function i(e){let{className:s,variant:a,...r}=e;return(0,t.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,n.cn)(l({variant:a}),s),...r})}function d(e){let{className:s,...a}=e;return(0,t.jsx)("div",{"data-slot":"alert-description",className:(0,n.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",s),...a})}}},e=>{var s=s=>e(e.s=s);e.O(0,[363,222,226,29,730,978,481,982,900,601,945,497,358],()=>s(6078)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/settings/page-abf398be5044bf9e.js b/ui_out/_next/static/chunks/app/settings/page-36e251683a0d492c.js similarity index 74% rename from ui_out/_next/static/chunks/app/settings/page-abf398be5044bf9e.js rename to ui_out/_next/static/chunks/app/settings/page-36e251683a0d492c.js index 1649f93f..75ce7584 100644 --- a/ui_out/_next/static/chunks/app/settings/page-abf398be5044bf9e.js +++ b/ui_out/_next/static/chunks/app/settings/page-36e251683a0d492c.js @@ -1 +1 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[662],{834:(e,s,r)=>{"use strict";r.d(s,{T:()=>n});var a=r(3422);r(4398);var t=r(9183);function n(e){let{className:s,...r}=e;return(0,a.jsx)("textarea",{"data-slot":"textarea",className:(0,t.cn)("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",s),...r})}},2739:(e,s,r)=>{Promise.resolve().then(r.bind(r,4961))},4961:(e,s,r)=>{"use strict";r.r(s),r.d(s,{default:()=>R});var a=r(3422),t=r(4398),n=r(6839),i=r(3234),l=r(3831),c=r(2738),o=r(268),d=r(3130),u=r(3648),x=r(8561),h=r(9675),p=r(246),m=r(4717);function g(){let{config:e,updateField:s,saveConfig:r,isSyncing:n}=function(){let[e,s]=(0,t.useState)({endpoint:"",apiKey:"",enabled:!1}),[r,a]=(0,t.useState)(!1),[n,c]=(0,t.useState)(!1);(0,t.useEffect)(()=>{(async()=>{s(i.s.getServerConfig()),a(!0);try{c(!0);let e=await i.s.loadServerConfigFromBackend();e&&s(e)}catch(e){console.error("Error loading configuration from backend:",e)}finally{c(!1)}})()},[]);let o=(0,t.useCallback)(async e=>{i.s.saveServerConfig(e),s(e);try{c(!0),await i.s.saveServerConfigToBackend(e)||l.oR.warning("Configuration saved locally, but failed to sync with server")}catch(e){console.error("Error saving configuration to backend:",e),l.oR.error("Failed to sync configuration with server")}finally{c(!1)}},[]),d=(0,t.useCallback)((s,r)=>{o({...e,[s]:r})},[e,o]),u=(0,t.useCallback)(()=>{o({...e,enabled:!e.enabled})},[e,o]);return{config:e,isLoaded:r,isSyncing:n,saveConfig:o,updateField:d,toggleEnabled:u,isConfigValid:(0,t.useCallback)(()=>i.s.isServerConfigValid(),[])}}(),[g,v]=(0,t.useState)("idle"),f=(e,r)=>{s(e,r),v("idle")},j=async()=>{if(e.endpoint){v("testing");try{await i.s.testConnection(e)?(v("success"),l.oR.success("Connection successful!")):(v("error"),l.oR.error("Connection failed. Please check your settings."))}catch(e){console.error("Connection test error:",e),v("error"),l.oR.error("Connection failed. Please check your settings.")}}};return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"mb-6 flex items-center justify-between",children:[(0,a.jsx)("h2",{className:"text-xl font-semibold tracking-tight",children:"External Server Configuration"}),n&&(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(h.A,{className:"h-4 w-4 animate-spin text-blue-500"}),"Syncing..."]})]}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsx)(c.aR,{children:(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)(c.ZB,{children:"Request Forwarding Settings"}),(0,a.jsx)(c.BT,{children:"Configure external server endpoint and authentication for API request forwarding"})]}),e.enabled&&("idle"===g?(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(h.A,{className:"h-4 w-4 text-yellow-500"}),"Not tested"]}):"testing"===g?(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(h.A,{className:"h-4 w-4 animate-pulse text-blue-500"}),"Testing..."]}):"success"===g?(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(p.A,{className:"h-4 w-4 text-green-500"}),"Connected"]}):(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(m.A,{className:"h-4 w-4 text-red-500"}),"Failed"]}))]})}),(0,a.jsx)(c.Wu,{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"server-endpoint",children:"Server Endpoint URL"}),(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)(o.p,{id:"server-endpoint",placeholder:"https://ecash.routstr.info",value:e.endpoint,onChange:e=>f("endpoint",e.target.value),className:"pr-24"}),(0,a.jsx)(u.$,{type:"button",variant:"ghost",size:"sm",className:"absolute top-0 right-0 h-full px-3 py-2 text-xs",onClick:()=>f("endpoint","https://ecash.routstr.info"),children:"Use Default"})]})]})}),(0,a.jsxs)(c.wL,{className:"flex justify-between",children:[(0,a.jsx)(u.$,{variant:"outline",onClick:j,disabled:!e.endpoint||"testing"===g,children:"Test Connection"}),(0,a.jsx)(u.$,{onClick:()=>{try{r(e),l.oR.success("Server configuration saved successfully")}catch(e){l.oR.error("Failed to save configuration"),console.error("Configuration save error:",e)}},children:"Save Configuration"})]})]})]})}var v=r(9119),f=r(834),j=r(9442),w=r(989),b=r(7137),y=r(3728),N=r(7829);function C(){let[e,s]=(0,t.useState)({}),[n,i]=(0,t.useState)(!0),[x,p]=(0,t.useState)(!1),[m,g]=(0,t.useState)(""),[C,_]=(0,t.useState)(!1),[S,k]=(0,t.useState)(""),[R,F]=(0,t.useState)({current_password:"",new_password:"",confirm_password:""}),[A,E]=(0,t.useState)(""),[P,B]=(0,t.useState)(!1);(0,t.useEffect)(()=>{T()},[]);let T=async()=>{try{i(!0),g("");let e=await v.zQ.getSettings();s(e)}catch(s){let e=s instanceof Error?s.message:"Failed to load settings";g(e),l.oR.error(e)}finally{i(!1)}},Z=async()=>{try{p(!0),g("");let r=await v.zQ.updateSettings(e);s(r),l.oR.success("Settings saved successfully")}catch(s){let e=s instanceof Error?s.message:"Failed to save settings";g(e),l.oR.error(e)}finally{p(!1)}},J=async()=>{try{if(B(!0),E(""),R.new_password!==R.confirm_password)return void E("New passwords do not match");if(R.new_password.length<6)return void E("New password must be at least 6 characters");let{apiClient:e}=await Promise.resolve().then(r.bind(r,7916));await e.patch("/admin/api/password",{current_password:R.current_password,new_password:R.new_password}),F({current_password:"",new_password:"",confirm_password:""}),l.oR.success("Password updated successfully")}catch(s){let e=s instanceof Error?s.message:"Failed to update password";E(e),l.oR.error(e)}finally{B(!1)}},U=(e,r)=>{s(s=>({...s,[e]:r}))},$=e=>{s(s=>{var r;return{...s,cashu_mints:(null==(r=s.cashu_mints)?void 0:r.filter((s,r)=>r!==e))||[]}})},z=(s,r,t)=>{let n=e[s]||"";return(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:s,children:r}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(o.p,{id:s,type:C?"text":"password",value:C?n:n?"••••••••":"",onChange:e=>U(s,e.target.value),placeholder:t,className:"flex-1"}),(0,a.jsx)(u.$,{type:"button",variant:"outline",size:"icon",onClick:()=>_(!C),children:C?(0,a.jsx)(w.A,{className:"h-4 w-4"}):(0,a.jsx)(b.A,{className:"h-4 w-4"})})]})]})};return n?(0,a.jsx)("div",{className:"flex items-center justify-center py-8",children:(0,a.jsx)("div",{className:"text-muted-foreground",children:"Loading settings..."})}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"mb-6",children:[(0,a.jsx)("h2",{className:"text-xl font-semibold tracking-tight",children:"Admin Settings"}),(0,a.jsx)("p",{className:"text-muted-foreground",children:"Configure your Routstr node settings"})]}),m&&(0,a.jsxs)(j.Fc,{variant:"destructive",className:"mb-6",children:[(0,a.jsx)(h.A,{className:"h-4 w-4"}),(0,a.jsx)(j.TN,{children:m})]}),(0,a.jsxs)("div",{className:"space-y-6",children:[(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Basic Information"}),(0,a.jsx)(c.BT,{children:"Configure the basic node information and branding"})]}),(0,a.jsxs)(c.Wu,{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"name",children:"Node Name"}),(0,a.jsx)(o.p,{id:"name",value:e.name||"",onChange:e=>U("name",e.target.value),placeholder:"ARoutstrNode"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"description",children:"Description"}),(0,a.jsx)(f.T,{id:"description",value:e.description||"",onChange:e=>U("description",e.target.value),placeholder:"A Routstr Node",rows:3})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"http_url",children:"HTTP URL"}),(0,a.jsx)(o.p,{id:"http_url",value:e.http_url||"",onChange:e=>U("http_url",e.target.value),placeholder:"https://your-node.com"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"onion_url",children:"Onion URL (Optional)"}),(0,a.jsx)(o.p,{id:"onion_url",value:e.onion_url||"",onChange:e=>U("onion_url",e.target.value),placeholder:"http://your-node.onion"})]})]})]}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Nostr Configuration"}),(0,a.jsx)(c.BT,{children:"Configure Nostr public and private keys"})]}),(0,a.jsxs)(c.Wu,{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"npub",children:"Public Key (npub)"}),(0,a.jsx)(o.p,{id:"npub",value:e.npub||"",onChange:e=>U("npub",e.target.value),placeholder:"npub1..."})]}),z("nsec","Private Key (nsec)","nsec1...")]})]}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Security Settings"}),(0,a.jsx)(c.BT,{children:"Configure authentication and API access"})]}),(0,a.jsx)(c.Wu,{className:"space-y-4",children:z("upstream_api_key","Upstream API Key","Enter API key")})]}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Cashu Mints"}),(0,a.jsx)(c.BT,{children:"Configure Cashu mint endpoints for payments"})]}),(0,a.jsxs)(c.Wu,{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"newMint",children:"Add Mint URL"}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(o.p,{id:"newMint",value:S,onChange:e=>k(e.target.value),placeholder:"https://mint.example.com"}),(0,a.jsx)(u.$,{onClick:()=>{S.trim()&&(s(e=>({...e,cashu_mints:[...e.cashu_mints||[],S.trim()]})),k(""))},disabled:!S.trim(),children:"Add Mint"})]})]}),e.cashu_mints&&e.cashu_mints.length>0&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{children:"Configured Mints"}),(0,a.jsx)("div",{className:"space-y-2",children:e.cashu_mints.map((e,s)=>(0,a.jsxs)("div",{className:"flex items-center gap-2 rounded border p-2",children:[(0,a.jsx)("span",{className:"flex-1 text-sm",children:e}),(0,a.jsx)(u.$,{variant:"outline",size:"sm",onClick:()=>$(s),children:"Remove"})]},s))})]})]})]}),(0,a.jsx)(c.Zp,{className:"mt-6",children:(0,a.jsxs)(c.wL,{className:"flex justify-between",children:[(0,a.jsxs)(u.$,{variant:"outline",onClick:T,disabled:n||x,children:[(0,a.jsx)(y.A,{className:"mr-2 h-4 w-4"}),"Reload"]}),(0,a.jsxs)(u.$,{onClick:Z,disabled:n||x,children:[(0,a.jsx)(N.A,{className:"mr-2 h-4 w-4"}),x?"Saving...":"Save Settings"]})]})}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Change Admin Password"}),(0,a.jsx)(c.BT,{children:"Update your admin password for enhanced security"})]}),(0,a.jsxs)(c.Wu,{className:"space-y-4",children:[A&&(0,a.jsxs)(j.Fc,{variant:"destructive",children:[(0,a.jsx)(h.A,{className:"h-4 w-4"}),(0,a.jsx)(j.TN,{children:A})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"current_password",children:"Current Password"}),(0,a.jsx)(o.p,{id:"current_password",type:"password",value:R.current_password,onChange:e=>F(s=>({...s,current_password:e.target.value})),placeholder:"Enter current password"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"new_password",children:"New Password"}),(0,a.jsx)(o.p,{id:"new_password",type:"password",value:R.new_password,onChange:e=>F(s=>({...s,new_password:e.target.value})),placeholder:"Enter new password (min 6 characters)"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"confirm_password",children:"Confirm New Password"}),(0,a.jsx)(o.p,{id:"confirm_password",type:"password",value:R.confirm_password,onChange:e=>F(s=>({...s,confirm_password:e.target.value})),placeholder:"Confirm new password"})]})]}),(0,a.jsx)(c.wL,{children:(0,a.jsxs)(u.$,{onClick:J,disabled:P||!R.current_password||!R.new_password||!R.confirm_password,children:[(0,a.jsx)(N.A,{className:"mr-2 h-4 w-4"}),P?"Updating...":"Update Password"]})})]})]})]})}var _=r(4756),S=r(7569),k=r(953);function R(){return(0,a.jsxs)(k.SidebarProvider,{children:[(0,a.jsx)(S.AppSidebar,{variant:"inset"}),(0,a.jsxs)(k.SidebarInset,{children:[(0,a.jsx)(_.SiteHeader,{}),(0,a.jsx)("div",{className:"flex flex-1 flex-col",children:(0,a.jsxs)("div",{className:"@container/main flex flex-1 flex-col gap-4 p-4 md:gap-8 md:p-8",children:[(0,a.jsx)("div",{className:"flex items-center",children:(0,a.jsx)("h1",{className:"text-2xl font-bold tracking-tight",children:"Settings"})}),(0,a.jsxs)(n.tU,{defaultValue:"admin",className:"w-full",children:[(0,a.jsx)(n.j7,{className:"mb-4",children:(0,a.jsx)(n.Xi,{value:"admin",children:"Admin Settings"})}),(0,a.jsx)(n.av,{value:"server",children:(0,a.jsx)(g,{})}),(0,a.jsx)(n.av,{value:"admin",children:(0,a.jsx)(C,{})})]})]})})]}),(0,a.jsx)(l.l$,{})]})}},6839:(e,s,r)=>{"use strict";r.d(s,{Xi:()=>c,av:()=>o,j7:()=>l,tU:()=>i});var a=r(3422);r(4398);var t=r(1749),n=r(9183);function i(e){let{className:s,...r}=e;return(0,a.jsx)(t.bL,{"data-slot":"tabs",className:(0,n.cn)("flex flex-col gap-2",s),...r})}function l(e){let{className:s,...r}=e;return(0,a.jsx)(t.B8,{"data-slot":"tabs-list",className:(0,n.cn)("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",s),...r})}function c(e){let{className:s,...r}=e;return(0,a.jsx)(t.l9,{"data-slot":"tabs-trigger",className:(0,n.cn)("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",s),...r})}function o(e){let{className:s,...r}=e;return(0,a.jsx)(t.UC,{"data-slot":"tabs-content",className:(0,n.cn)("flex-1 outline-none",s),...r})}},8561:(e,s,r)=>{"use strict";r.d(s,{E:()=>l});var a=r(3422);r(4398);var t=r(4676),n=r(9183);let i=(0,t.F)("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground",success:"border-transparent bg-green-500 text-white hover:bg-green-500/80",warning:"border-transparent bg-yellow-500 text-white hover:bg-yellow-500/80",error:"border-transparent bg-red-500 text-white hover:bg-red-500/80"}},defaultVariants:{variant:"default"}});function l(e){let{className:s,variant:r,...t}=e;return(0,a.jsx)("div",{className:(0,n.cn)(i({variant:r}),s),...t})}},9442:(e,s,r)=>{"use strict";r.d(s,{Fc:()=>l,TN:()=>c});var a=r(3422);r(4398);var t=r(4676),n=r(9183);let i=(0,t.F)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"}},defaultVariants:{variant:"default"}});function l(e){let{className:s,variant:r,...t}=e;return(0,a.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,n.cn)(i({variant:r}),s),...t})}function c(e){let{className:s,...r}=e;return(0,a.jsx)("div",{"data-slot":"alert-description",className:(0,n.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",s),...r})}}},e=>{var s=s=>e(e.s=s);e.O(0,[363,222,808,978,651,236,601,945,497,358],()=>s(2739)),_N_E=e.O()}]); \ No newline at end of file +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[662],{834:(e,s,r)=>{"use strict";r.d(s,{T:()=>n});var a=r(3422);r(4398);var t=r(9183);function n(e){let{className:s,...r}=e;return(0,a.jsx)("textarea",{"data-slot":"textarea",className:(0,t.cn)("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",s),...r})}},2739:(e,s,r)=>{Promise.resolve().then(r.bind(r,4961))},4961:(e,s,r)=>{"use strict";r.r(s),r.d(s,{default:()=>R});var a=r(3422),t=r(4398),n=r(6839),i=r(3234),l=r(3831),c=r(2738),o=r(268),d=r(3130),u=r(3648),x=r(8561),h=r(9675),p=r(246),m=r(4717);function g(){let{config:e,updateField:s,saveConfig:r,isSyncing:n}=function(){let[e,s]=(0,t.useState)({endpoint:"",apiKey:"",enabled:!1}),[r,a]=(0,t.useState)(!1),[n,c]=(0,t.useState)(!1);(0,t.useEffect)(()=>{(async()=>{s(i.s.getServerConfig()),a(!0);try{c(!0);let e=await i.s.loadServerConfigFromBackend();e&&s(e)}catch(e){console.error("Error loading configuration from backend:",e)}finally{c(!1)}})()},[]);let o=(0,t.useCallback)(async e=>{i.s.saveServerConfig(e),s(e);try{c(!0),await i.s.saveServerConfigToBackend(e)||l.oR.warning("Configuration saved locally, but failed to sync with server")}catch(e){console.error("Error saving configuration to backend:",e),l.oR.error("Failed to sync configuration with server")}finally{c(!1)}},[]),d=(0,t.useCallback)((s,r)=>{o({...e,[s]:r})},[e,o]),u=(0,t.useCallback)(()=>{o({...e,enabled:!e.enabled})},[e,o]);return{config:e,isLoaded:r,isSyncing:n,saveConfig:o,updateField:d,toggleEnabled:u,isConfigValid:(0,t.useCallback)(()=>i.s.isServerConfigValid(),[])}}(),[g,v]=(0,t.useState)("idle"),f=(e,r)=>{s(e,r),v("idle")},j=async()=>{if(e.endpoint){v("testing");try{await i.s.testConnection(e)?(v("success"),l.oR.success("Connection successful!")):(v("error"),l.oR.error("Connection failed. Please check your settings."))}catch(e){console.error("Connection test error:",e),v("error"),l.oR.error("Connection failed. Please check your settings.")}}};return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"mb-6 flex items-center justify-between",children:[(0,a.jsx)("h2",{className:"text-xl font-semibold tracking-tight",children:"External Server Configuration"}),n&&(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(h.A,{className:"h-4 w-4 animate-spin text-blue-500"}),"Syncing..."]})]}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsx)(c.aR,{children:(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)(c.ZB,{children:"Request Forwarding Settings"}),(0,a.jsx)(c.BT,{children:"Configure external server endpoint and authentication for API request forwarding"})]}),e.enabled&&("idle"===g?(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(h.A,{className:"h-4 w-4 text-yellow-500"}),"Not tested"]}):"testing"===g?(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(h.A,{className:"h-4 w-4 animate-pulse text-blue-500"}),"Testing..."]}):"success"===g?(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(p.A,{className:"h-4 w-4 text-green-500"}),"Connected"]}):(0,a.jsxs)(x.E,{variant:"outline",className:"flex items-center gap-1",children:[(0,a.jsx)(m.A,{className:"h-4 w-4 text-red-500"}),"Failed"]}))]})}),(0,a.jsx)(c.Wu,{className:"space-y-4",children:(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"server-endpoint",children:"Server Endpoint URL"}),(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)(o.p,{id:"server-endpoint",placeholder:"https://ecash.routstr.info",value:e.endpoint,onChange:e=>f("endpoint",e.target.value),className:"pr-24"}),(0,a.jsx)(u.$,{type:"button",variant:"ghost",size:"sm",className:"absolute top-0 right-0 h-full px-3 py-2 text-xs",onClick:()=>f("endpoint","https://ecash.routstr.info"),children:"Use Default"})]})]})}),(0,a.jsxs)(c.wL,{className:"flex justify-between",children:[(0,a.jsx)(u.$,{variant:"outline",onClick:j,disabled:!e.endpoint||"testing"===g,children:"Test Connection"}),(0,a.jsx)(u.$,{onClick:()=>{try{r(e),l.oR.success("Server configuration saved successfully")}catch(e){l.oR.error("Failed to save configuration"),console.error("Configuration save error:",e)}},children:"Save Configuration"})]})]})]})}var v=r(9119),f=r(834),j=r(9442),w=r(989),b=r(7137),y=r(3728),N=r(7829);function C(){let[e,s]=(0,t.useState)({}),[n,i]=(0,t.useState)(!0),[x,p]=(0,t.useState)(!1),[m,g]=(0,t.useState)(""),[C,_]=(0,t.useState)(!1),[S,k]=(0,t.useState)(""),[R,F]=(0,t.useState)({current_password:"",new_password:"",confirm_password:""}),[A,E]=(0,t.useState)(""),[P,B]=(0,t.useState)(!1);(0,t.useEffect)(()=>{T()},[]);let T=async()=>{try{i(!0),g("");let e=await v.zQ.getSettings();s(e)}catch(s){let e=s instanceof Error?s.message:"Failed to load settings";g(e),l.oR.error(e)}finally{i(!1)}},Z=async()=>{try{p(!0),g("");let r=await v.zQ.updateSettings(e);s(r),l.oR.success("Settings saved successfully")}catch(s){let e=s instanceof Error?s.message:"Failed to save settings";g(e),l.oR.error(e)}finally{p(!1)}},J=async()=>{try{if(B(!0),E(""),R.new_password!==R.confirm_password)return void E("New passwords do not match");if(R.new_password.length<6)return void E("New password must be at least 6 characters");let{apiClient:e}=await Promise.resolve().then(r.bind(r,7916));await e.patch("/admin/api/password",{current_password:R.current_password,new_password:R.new_password}),F({current_password:"",new_password:"",confirm_password:""}),l.oR.success("Password updated successfully")}catch(s){let e=s instanceof Error?s.message:"Failed to update password";E(e),l.oR.error(e)}finally{B(!1)}},U=(e,r)=>{s(s=>({...s,[e]:r}))},$=e=>{s(s=>{var r;return{...s,cashu_mints:(null==(r=s.cashu_mints)?void 0:r.filter((s,r)=>r!==e))||[]}})},z=(s,r,t)=>{let n=e[s]||"";return(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:s,children:r}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(o.p,{id:s,type:C?"text":"password",value:C?n:n?"••••••••":"",onChange:e=>U(s,e.target.value),placeholder:t,className:"flex-1"}),(0,a.jsx)(u.$,{type:"button",variant:"outline",size:"icon",onClick:()=>_(!C),children:C?(0,a.jsx)(w.A,{className:"h-4 w-4"}):(0,a.jsx)(b.A,{className:"h-4 w-4"})})]})]})};return n?(0,a.jsx)("div",{className:"flex items-center justify-center py-8",children:(0,a.jsx)("div",{className:"text-muted-foreground",children:"Loading settings..."})}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"mb-6",children:[(0,a.jsx)("h2",{className:"text-xl font-semibold tracking-tight",children:"Admin Settings"}),(0,a.jsx)("p",{className:"text-muted-foreground",children:"Configure your Routstr node settings"})]}),m&&(0,a.jsxs)(j.Fc,{variant:"destructive",className:"mb-6",children:[(0,a.jsx)(h.A,{className:"h-4 w-4"}),(0,a.jsx)(j.TN,{children:m})]}),(0,a.jsxs)("div",{className:"space-y-6",children:[(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Basic Information"}),(0,a.jsx)(c.BT,{children:"Configure the basic node information and branding"})]}),(0,a.jsxs)(c.Wu,{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"name",children:"Node Name"}),(0,a.jsx)(o.p,{id:"name",value:e.name||"",onChange:e=>U("name",e.target.value),placeholder:"ARoutstrNode"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"description",children:"Description"}),(0,a.jsx)(f.T,{id:"description",value:e.description||"",onChange:e=>U("description",e.target.value),placeholder:"A Routstr Node",rows:3})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"http_url",children:"HTTP URL"}),(0,a.jsx)(o.p,{id:"http_url",value:e.http_url||"",onChange:e=>U("http_url",e.target.value),placeholder:"https://your-node.com"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"onion_url",children:"Onion URL (Optional)"}),(0,a.jsx)(o.p,{id:"onion_url",value:e.onion_url||"",onChange:e=>U("onion_url",e.target.value),placeholder:"http://your-node.onion"})]})]})]}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Nostr Configuration"}),(0,a.jsx)(c.BT,{children:"Configure Nostr public and private keys"})]}),(0,a.jsxs)(c.Wu,{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"npub",children:"Public Key (npub)"}),(0,a.jsx)(o.p,{id:"npub",value:e.npub||"",onChange:e=>U("npub",e.target.value),placeholder:"npub1..."})]}),z("nsec","Private Key (nsec)","nsec1...")]})]}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Security Settings"}),(0,a.jsx)(c.BT,{children:"Configure authentication and API access"})]}),(0,a.jsx)(c.Wu,{className:"space-y-4",children:z("upstream_api_key","Upstream API Key","Enter API key")})]}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Cashu Mints"}),(0,a.jsx)(c.BT,{children:"Configure Cashu mint endpoints for payments"})]}),(0,a.jsxs)(c.Wu,{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"newMint",children:"Add Mint URL"}),(0,a.jsxs)("div",{className:"flex gap-2",children:[(0,a.jsx)(o.p,{id:"newMint",value:S,onChange:e=>k(e.target.value),placeholder:"https://mint.example.com"}),(0,a.jsx)(u.$,{onClick:()=>{S.trim()&&(s(e=>({...e,cashu_mints:[...e.cashu_mints||[],S.trim()]})),k(""))},disabled:!S.trim(),children:"Add Mint"})]})]}),e.cashu_mints&&e.cashu_mints.length>0&&(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{children:"Configured Mints"}),(0,a.jsx)("div",{className:"space-y-2",children:e.cashu_mints.map((e,s)=>(0,a.jsxs)("div",{className:"flex items-center gap-2 rounded border p-2",children:[(0,a.jsx)("span",{className:"flex-1 text-sm",children:e}),(0,a.jsx)(u.$,{variant:"outline",size:"sm",onClick:()=>$(s),children:"Remove"})]},s))})]})]})]}),(0,a.jsx)(c.Zp,{className:"mt-6",children:(0,a.jsxs)(c.wL,{className:"flex justify-between",children:[(0,a.jsxs)(u.$,{variant:"outline",onClick:T,disabled:n||x,children:[(0,a.jsx)(y.A,{className:"mr-2 h-4 w-4"}),"Reload"]}),(0,a.jsxs)(u.$,{onClick:Z,disabled:n||x,children:[(0,a.jsx)(N.A,{className:"mr-2 h-4 w-4"}),x?"Saving...":"Save Settings"]})]})}),(0,a.jsxs)(c.Zp,{children:[(0,a.jsxs)(c.aR,{children:[(0,a.jsx)(c.ZB,{children:"Change Admin Password"}),(0,a.jsx)(c.BT,{children:"Update your admin password for enhanced security"})]}),(0,a.jsxs)(c.Wu,{className:"space-y-4",children:[A&&(0,a.jsxs)(j.Fc,{variant:"destructive",children:[(0,a.jsx)(h.A,{className:"h-4 w-4"}),(0,a.jsx)(j.TN,{children:A})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"current_password",children:"Current Password"}),(0,a.jsx)(o.p,{id:"current_password",type:"password",value:R.current_password,onChange:e=>F(s=>({...s,current_password:e.target.value})),placeholder:"Enter current password"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"new_password",children:"New Password"}),(0,a.jsx)(o.p,{id:"new_password",type:"password",value:R.new_password,onChange:e=>F(s=>({...s,new_password:e.target.value})),placeholder:"Enter new password (min 6 characters)"})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(d.J,{htmlFor:"confirm_password",children:"Confirm New Password"}),(0,a.jsx)(o.p,{id:"confirm_password",type:"password",value:R.confirm_password,onChange:e=>F(s=>({...s,confirm_password:e.target.value})),placeholder:"Confirm new password"})]})]}),(0,a.jsx)(c.wL,{children:(0,a.jsxs)(u.$,{onClick:J,disabled:P||!R.current_password||!R.new_password||!R.confirm_password,children:[(0,a.jsx)(N.A,{className:"mr-2 h-4 w-4"}),P?"Updating...":"Update Password"]})})]})]})]})}var _=r(532),S=r(7569),k=r(953);function R(){return(0,a.jsxs)(k.SidebarProvider,{children:[(0,a.jsx)(S.AppSidebar,{variant:"inset"}),(0,a.jsxs)(k.SidebarInset,{children:[(0,a.jsx)(_.SiteHeader,{}),(0,a.jsx)("div",{className:"flex flex-1 flex-col",children:(0,a.jsxs)("div",{className:"@container/main flex flex-1 flex-col gap-4 p-4 md:gap-8 md:p-8",children:[(0,a.jsx)("div",{className:"flex items-center",children:(0,a.jsx)("h1",{className:"text-2xl font-bold tracking-tight",children:"Settings"})}),(0,a.jsxs)(n.tU,{defaultValue:"admin",className:"w-full",children:[(0,a.jsx)(n.j7,{className:"mb-4",children:(0,a.jsx)(n.Xi,{value:"admin",children:"Admin Settings"})}),(0,a.jsx)(n.av,{value:"server",children:(0,a.jsx)(g,{})}),(0,a.jsx)(n.av,{value:"admin",children:(0,a.jsx)(C,{})})]})]})})]}),(0,a.jsx)(l.l$,{})]})}},6839:(e,s,r)=>{"use strict";r.d(s,{Xi:()=>c,av:()=>o,j7:()=>l,tU:()=>i});var a=r(3422);r(4398);var t=r(1749),n=r(9183);function i(e){let{className:s,...r}=e;return(0,a.jsx)(t.bL,{"data-slot":"tabs",className:(0,n.cn)("flex flex-col gap-2",s),...r})}function l(e){let{className:s,...r}=e;return(0,a.jsx)(t.B8,{"data-slot":"tabs-list",className:(0,n.cn)("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",s),...r})}function c(e){let{className:s,...r}=e;return(0,a.jsx)(t.l9,{"data-slot":"tabs-trigger",className:(0,n.cn)("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",s),...r})}function o(e){let{className:s,...r}=e;return(0,a.jsx)(t.UC,{"data-slot":"tabs-content",className:(0,n.cn)("flex-1 outline-none",s),...r})}},8561:(e,s,r)=>{"use strict";r.d(s,{E:()=>l});var a=r(3422);r(4398);var t=r(4676),n=r(9183);let i=(0,t.F)("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground",success:"border-transparent bg-green-500 text-white hover:bg-green-500/80",warning:"border-transparent bg-yellow-500 text-white hover:bg-yellow-500/80",error:"border-transparent bg-red-500 text-white hover:bg-red-500/80"}},defaultVariants:{variant:"default"}});function l(e){let{className:s,variant:r,...t}=e;return(0,a.jsx)("div",{className:(0,n.cn)(i({variant:r}),s),...t})}},9442:(e,s,r)=>{"use strict";r.d(s,{Fc:()=>l,TN:()=>c});var a=r(3422);r(4398);var t=r(4676),n=r(9183);let i=(0,t.F)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"}},defaultVariants:{variant:"default"}});function l(e){let{className:s,variant:r,...t}=e;return(0,a.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,n.cn)(i({variant:r}),s),...t})}function c(e){let{className:s,...r}=e;return(0,a.jsx)("div",{"data-slot":"alert-description",className:(0,n.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",s),...r})}}},e=>{var s=s=>e(e.s=s);e.O(0,[363,222,226,978,651,900,601,945,497,358],()=>s(2739)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/transactions/page-114770ed3af4ceb6.js b/ui_out/_next/static/chunks/app/transactions/page-114770ed3af4ceb6.js deleted file mode 100644 index bcb11f75..00000000 --- a/ui_out/_next/static/chunks/app/transactions/page-114770ed3af4ceb6.js +++ /dev/null @@ -1 +0,0 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[790],{2127:(e,t,s)=>{Promise.resolve().then(s.bind(s,7082))},2533:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(3929).A)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]])},3728:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(3929).A)("refresh-cw",[["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"}]])},7082:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>E});var a=s(3422),r=s(4398),n=s(953),i=s(7569),l=s(4756),c=s(2349),o=s(2745),d=s(3728),x=s(9675),h=s(2533),m=s(3929);let u=(0,m.A)("chevron-left",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]),v=(0,m.A)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);var f=s(9442),g=s(3648),p=s(9183);function j(e){let{className:t,...s}=e;return(0,a.jsx)("div",{"data-slot":"table-container",className:"relative w-full overflow-x-auto",children:(0,a.jsx)("table",{"data-slot":"table",className:(0,p.cn)("w-full caption-bottom text-sm",t),...s})})}function b(e){let{className:t,...s}=e;return(0,a.jsx)("thead",{"data-slot":"table-header",className:(0,p.cn)("[&_tr]:border-b",t),...s})}function y(e){let{className:t,...s}=e;return(0,a.jsx)("tbody",{"data-slot":"table-body",className:(0,p.cn)("[&_tr:last-child]:border-0",t),...s})}function N(e){let{className:t,...s}=e;return(0,a.jsx)("tr",{"data-slot":"table-row",className:(0,p.cn)("hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",t),...s})}function w(e){let{className:t,...s}=e;return(0,a.jsx)("th",{"data-slot":"table-head",className:(0,p.cn)("text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",t),...s})}function k(e){let{className:t,...s}=e;return(0,a.jsx)("td",{"data-slot":"table-cell",className:(0,p.cn)("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",t),...s})}var _=s(8561),A=s(6545),C=s(3831),F=s(7916);let T={getPaginatedTransactions:async(e,t)=>{try{return await F.apiClient.get("/api/transactions/paginated/".concat(e,"/").concat(t))}catch(e){throw console.error("Failed to fetch paginated transactions:",e),Error("Failed to fetch paginated transactions")}}};function E(){let[e,t]=(0,r.useState)(1),{data:s,isLoading:m,error:p,refetch:F}=(0,c.I)({queryKey:["transactions",e,20],queryFn:()=>T.getPaginatedTransactions(e,20),refetchOnWindowFocus:!1,retry:1,staleTime:3e4}),E=(null==s?void 0:s.transactions)||[],P=(null==s?void 0:s.total_pages)||0,S=(null==s?void 0:s.total)||0,z=e=>new Date(e).toLocaleString(),M=e=>"".concat(parseInt(e).toLocaleString()," msats"),$=e=>e.length<=20?e:"".concat(e.slice(0,10),"...").concat(e.slice(-10)),I=async e=>{try{await navigator.clipboard.writeText(e),C.oR.success("Token copied to clipboard!")}catch(e){console.error("Failed to copy to clipboard:",e),C.oR.error("Failed to copy token")}},q=e=>{e>=1&&e<=P&&t(e)};return(0,a.jsx)(A.Bc,{children:(0,a.jsxs)(n.SidebarProvider,{children:[(0,a.jsx)(i.AppSidebar,{variant:"inset"}),(0,a.jsxs)(n.SidebarInset,{children:[(0,a.jsx)(l.SiteHeader,{}),(0,a.jsx)("div",{className:"flex flex-1 flex-col",children:(0,a.jsxs)("div",{className:"@container/main flex flex-1 flex-col gap-4 p-4 md:gap-8 md:p-8",children:[(0,a.jsxs)("div",{className:"mb-6 flex items-center justify-between",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("h1",{className:"text-2xl font-bold tracking-tight",children:"Transaction History"}),(0,a.jsx)("p",{className:"text-muted-foreground text-sm",children:"View all Cashu token transactions processed by the system"})]}),(0,a.jsxs)(g.$,{onClick:()=>F(),variant:"outline",size:"sm",disabled:m,children:[(0,a.jsx)(d.A,{className:"mr-2 h-4 w-4 ".concat(m?"animate-spin":"")}),"Refresh"]})]}),m?(0,a.jsx)("div",{className:"space-y-4",children:[void 0,void 0,void 0,void 0,void 0].map((e,t)=>(0,a.jsx)(o.E,{className:"h-[120px] w-full"},t))}):p?(0,a.jsxs)(f.Fc,{variant:"destructive",children:[(0,a.jsx)(x.A,{className:"h-4 w-4"}),(0,a.jsxs)(f.TN,{children:["Failed to load transactions."," ",p instanceof Error?p.message:"Please check if the server is running and try refreshing the page."]})]}):0===E.length?(0,a.jsx)("div",{className:"py-8 text-center",children:(0,a.jsx)("p",{className:"text-muted-foreground",children:"No transactions found."})}):(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Showing ",(e-1)*20+1," to"," ",Math.min(20*e,S)," of ",S," ","transactions"]}),(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Page ",e," of ",P]})]}),(0,a.jsx)("div",{className:"rounded-md border",children:(0,a.jsxs)(j,{children:[(0,a.jsx)(b,{children:(0,a.jsxs)(N,{children:[(0,a.jsx)(w,{className:"w-[100px]",children:"ID"}),(0,a.jsx)(w,{children:"Date & Time"}),(0,a.jsx)(w,{children:"Amount"}),(0,a.jsx)(w,{className:"w-[400px]",children:"Cashu Token"}),(0,a.jsx)(w,{className:"w-[60px]",children:"Actions"})]})}),(0,a.jsx)(y,{children:E.map(e=>(0,a.jsxs)(N,{children:[(0,a.jsx)(k,{className:"font-mono text-xs",children:e.id.slice(0,8)}),(0,a.jsx)(k,{children:(0,a.jsx)("div",{className:"text-sm",children:z(e.created_at)})}),(0,a.jsx)(k,{children:(0,a.jsx)(_.E,{variant:"secondary",children:M(e.amount)})}),(0,a.jsx)(k,{children:(0,a.jsx)("div",{className:"flex items-center gap-2",children:(0,a.jsxs)(A.m_,{children:[(0,a.jsx)(A.k$,{asChild:!0,children:(0,a.jsx)("p",{className:"max-w-[300px] cursor-pointer truncate rounded px-1 py-0.5 font-mono text-xs hover:bg-gray-100",children:$(e.token)})}),(0,a.jsx)(A.ZI,{className:"max-w-md break-all",children:(0,a.jsx)("p",{className:"font-mono text-xs",children:e.token})})]})})}),(0,a.jsx)(k,{children:(0,a.jsx)(g.$,{variant:"ghost",size:"sm",onClick:()=>I(e.token),className:"h-8 w-8 p-0",children:(0,a.jsx)(h.A,{className:"h-4 w-4"})})})]},e.id))})]})}),P>1&&(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Page ",e," of ",P]}),(0,a.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,a.jsxs)(g.$,{variant:"outline",size:"sm",onClick:()=>{e>1&&t(e-1)},disabled:1===e,children:[(0,a.jsx)(u,{className:"mr-1 h-4 w-4"}),"Previous"]}),(0,a.jsx)("div",{className:"flex items-center space-x-1",children:Array.from({length:Math.min(5,P)},(t,s)=>{let r=e<=3?s+1:e>=P-2?P-4+s:e-2+s;return r<1||r>P?null:(0,a.jsx)(g.$,{variant:e===r?"default":"outline",size:"sm",onClick:()=>q(r),className:"h-9 w-9 p-0",children:r},r)})}),(0,a.jsxs)(g.$,{variant:"outline",size:"sm",onClick:()=>{e{"use strict";s.d(t,{E:()=>l});var a=s(3422);s(4398);var r=s(4676),n=s(9183);let i=(0,r.F)("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground",success:"border-transparent bg-green-500 text-white hover:bg-green-500/80",warning:"border-transparent bg-yellow-500 text-white hover:bg-yellow-500/80",error:"border-transparent bg-red-500 text-white hover:bg-red-500/80"}},defaultVariants:{variant:"default"}});function l(e){let{className:t,variant:s,...r}=e;return(0,a.jsx)("div",{className:(0,n.cn)(i({variant:s}),t),...r})}},9442:(e,t,s)=>{"use strict";s.d(t,{Fc:()=>l,TN:()=>c});var a=s(3422);s(4398);var r=s(4676),n=s(9183);let i=(0,r.F)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"}},defaultVariants:{variant:"default"}});function l(e){let{className:t,variant:s,...r}=e;return(0,a.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,n.cn)(i({variant:s}),t),...r})}function c(e){let{className:t,...s}=e;return(0,a.jsx)("div",{"data-slot":"alert-description",className:(0,n.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",t),...s})}}},e=>{var t=t=>e(e.s=t);e.O(0,[363,222,808,29,730,236,945,497,358],()=>t(2127)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/transactions/page-b9cef669e0e237ee.js b/ui_out/_next/static/chunks/app/transactions/page-b9cef669e0e237ee.js new file mode 100644 index 00000000..9bae57ba --- /dev/null +++ b/ui_out/_next/static/chunks/app/transactions/page-b9cef669e0e237ee.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[790],{2127:(e,t,s)=>{Promise.resolve().then(s.bind(s,7082))},2533:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(3929).A)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]])},3728:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(3929).A)("refresh-cw",[["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"}]])},7082:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>E});var a=s(3422),r=s(4398),n=s(953),i=s(7569),l=s(532),c=s(2349),o=s(2745),d=s(3728),x=s(9675),h=s(2533),m=s(3929);let u=(0,m.A)("chevron-left",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]),v=(0,m.A)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);var f=s(9442),g=s(3648),p=s(9183);function j(e){let{className:t,...s}=e;return(0,a.jsx)("div",{"data-slot":"table-container",className:"relative w-full overflow-x-auto",children:(0,a.jsx)("table",{"data-slot":"table",className:(0,p.cn)("w-full caption-bottom text-sm",t),...s})})}function b(e){let{className:t,...s}=e;return(0,a.jsx)("thead",{"data-slot":"table-header",className:(0,p.cn)("[&_tr]:border-b",t),...s})}function y(e){let{className:t,...s}=e;return(0,a.jsx)("tbody",{"data-slot":"table-body",className:(0,p.cn)("[&_tr:last-child]:border-0",t),...s})}function N(e){let{className:t,...s}=e;return(0,a.jsx)("tr",{"data-slot":"table-row",className:(0,p.cn)("hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",t),...s})}function w(e){let{className:t,...s}=e;return(0,a.jsx)("th",{"data-slot":"table-head",className:(0,p.cn)("text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",t),...s})}function k(e){let{className:t,...s}=e;return(0,a.jsx)("td",{"data-slot":"table-cell",className:(0,p.cn)("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",t),...s})}var _=s(8561),A=s(6545),C=s(3831),F=s(7916);let T={getPaginatedTransactions:async(e,t)=>{try{return await F.apiClient.get("/api/transactions/paginated/".concat(e,"/").concat(t))}catch(e){throw console.error("Failed to fetch paginated transactions:",e),Error("Failed to fetch paginated transactions")}}};function E(){let[e,t]=(0,r.useState)(1),{data:s,isLoading:m,error:p,refetch:F}=(0,c.I)({queryKey:["transactions",e,20],queryFn:()=>T.getPaginatedTransactions(e,20),refetchOnWindowFocus:!1,retry:1,staleTime:3e4}),E=(null==s?void 0:s.transactions)||[],P=(null==s?void 0:s.total_pages)||0,S=(null==s?void 0:s.total)||0,z=e=>new Date(e).toLocaleString(),M=e=>"".concat(parseInt(e).toLocaleString()," msats"),$=e=>e.length<=20?e:"".concat(e.slice(0,10),"...").concat(e.slice(-10)),I=async e=>{try{await navigator.clipboard.writeText(e),C.oR.success("Token copied to clipboard!")}catch(e){console.error("Failed to copy to clipboard:",e),C.oR.error("Failed to copy token")}},q=e=>{e>=1&&e<=P&&t(e)};return(0,a.jsx)(A.Bc,{children:(0,a.jsxs)(n.SidebarProvider,{children:[(0,a.jsx)(i.AppSidebar,{variant:"inset"}),(0,a.jsxs)(n.SidebarInset,{children:[(0,a.jsx)(l.SiteHeader,{}),(0,a.jsx)("div",{className:"flex flex-1 flex-col",children:(0,a.jsxs)("div",{className:"@container/main flex flex-1 flex-col gap-4 p-4 md:gap-8 md:p-8",children:[(0,a.jsxs)("div",{className:"mb-6 flex items-center justify-between",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("h1",{className:"text-2xl font-bold tracking-tight",children:"Transaction History"}),(0,a.jsx)("p",{className:"text-muted-foreground text-sm",children:"View all Cashu token transactions processed by the system"})]}),(0,a.jsxs)(g.$,{onClick:()=>F(),variant:"outline",size:"sm",disabled:m,children:[(0,a.jsx)(d.A,{className:"mr-2 h-4 w-4 ".concat(m?"animate-spin":"")}),"Refresh"]})]}),m?(0,a.jsx)("div",{className:"space-y-4",children:[void 0,void 0,void 0,void 0,void 0].map((e,t)=>(0,a.jsx)(o.E,{className:"h-[120px] w-full"},t))}):p?(0,a.jsxs)(f.Fc,{variant:"destructive",children:[(0,a.jsx)(x.A,{className:"h-4 w-4"}),(0,a.jsxs)(f.TN,{children:["Failed to load transactions."," ",p instanceof Error?p.message:"Please check if the server is running and try refreshing the page."]})]}):0===E.length?(0,a.jsx)("div",{className:"py-8 text-center",children:(0,a.jsx)("p",{className:"text-muted-foreground",children:"No transactions found."})}):(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Showing ",(e-1)*20+1," to"," ",Math.min(20*e,S)," of ",S," ","transactions"]}),(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Page ",e," of ",P]})]}),(0,a.jsx)("div",{className:"rounded-md border",children:(0,a.jsxs)(j,{children:[(0,a.jsx)(b,{children:(0,a.jsxs)(N,{children:[(0,a.jsx)(w,{className:"w-[100px]",children:"ID"}),(0,a.jsx)(w,{children:"Date & Time"}),(0,a.jsx)(w,{children:"Amount"}),(0,a.jsx)(w,{className:"w-[400px]",children:"Cashu Token"}),(0,a.jsx)(w,{className:"w-[60px]",children:"Actions"})]})}),(0,a.jsx)(y,{children:E.map(e=>(0,a.jsxs)(N,{children:[(0,a.jsx)(k,{className:"font-mono text-xs",children:e.id.slice(0,8)}),(0,a.jsx)(k,{children:(0,a.jsx)("div",{className:"text-sm",children:z(e.created_at)})}),(0,a.jsx)(k,{children:(0,a.jsx)(_.E,{variant:"secondary",children:M(e.amount)})}),(0,a.jsx)(k,{children:(0,a.jsx)("div",{className:"flex items-center gap-2",children:(0,a.jsxs)(A.m_,{children:[(0,a.jsx)(A.k$,{asChild:!0,children:(0,a.jsx)("p",{className:"max-w-[300px] cursor-pointer truncate rounded px-1 py-0.5 font-mono text-xs hover:bg-gray-100",children:$(e.token)})}),(0,a.jsx)(A.ZI,{className:"max-w-md break-all",children:(0,a.jsx)("p",{className:"font-mono text-xs",children:e.token})})]})})}),(0,a.jsx)(k,{children:(0,a.jsx)(g.$,{variant:"ghost",size:"sm",onClick:()=>I(e.token),className:"h-8 w-8 p-0",children:(0,a.jsx)(h.A,{className:"h-4 w-4"})})})]},e.id))})]})}),P>1&&(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"text-muted-foreground text-sm",children:["Page ",e," of ",P]}),(0,a.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,a.jsxs)(g.$,{variant:"outline",size:"sm",onClick:()=>{e>1&&t(e-1)},disabled:1===e,children:[(0,a.jsx)(u,{className:"mr-1 h-4 w-4"}),"Previous"]}),(0,a.jsx)("div",{className:"flex items-center space-x-1",children:Array.from({length:Math.min(5,P)},(t,s)=>{let r=e<=3?s+1:e>=P-2?P-4+s:e-2+s;return r<1||r>P?null:(0,a.jsx)(g.$,{variant:e===r?"default":"outline",size:"sm",onClick:()=>q(r),className:"h-9 w-9 p-0",children:r},r)})}),(0,a.jsxs)(g.$,{variant:"outline",size:"sm",onClick:()=>{e{"use strict";s.d(t,{E:()=>l});var a=s(3422);s(4398);var r=s(4676),n=s(9183);let i=(0,r.F)("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground",success:"border-transparent bg-green-500 text-white hover:bg-green-500/80",warning:"border-transparent bg-yellow-500 text-white hover:bg-yellow-500/80",error:"border-transparent bg-red-500 text-white hover:bg-red-500/80"}},defaultVariants:{variant:"default"}});function l(e){let{className:t,variant:s,...r}=e;return(0,a.jsx)("div",{className:(0,n.cn)(i({variant:s}),t),...r})}},9442:(e,t,s)=>{"use strict";s.d(t,{Fc:()=>l,TN:()=>c});var a=s(3422);s(4398);var r=s(4676),n=s(9183);let i=(0,r.F)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"}},defaultVariants:{variant:"default"}});function l(e){let{className:t,variant:s,...r}=e;return(0,a.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,n.cn)(i({variant:s}),t),...r})}function c(e){let{className:t,...s}=e;return(0,a.jsx)("div",{"data-slot":"alert-description",className:(0,n.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",t),...s})}}},e=>{var t=t=>e(e.s=t);e.O(0,[363,222,226,29,730,900,945,497,358],()=>t(2127)),_N_E=e.O()}]); \ No newline at end of file diff --git a/ui_out/_next/static/chunks/app/unauthorized/page-bd10c76db4782139.js b/ui_out/_next/static/chunks/app/unauthorized/page-96bd6a23715af694.js similarity index 100% rename from ui_out/_next/static/chunks/app/unauthorized/page-bd10c76db4782139.js rename to ui_out/_next/static/chunks/app/unauthorized/page-96bd6a23715af694.js diff --git a/ui_out/_next/static/css/2dee0244dc7d99bd.css b/ui_out/_next/static/css/2dee0244dc7d99bd.css deleted file mode 100644 index d70d8d7b..00000000 --- a/ui_out/_next/static/css/2dee0244dc7d99bd.css +++ /dev/null @@ -1 +0,0 @@ -/*! tailwindcss v4.1.14 | 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)))){*,::backdrop,:after,:before{--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-gradient-position:initial;--tw-gradient-from:#0000;--tw-gradient-via:#0000;--tw-gradient-to:#0000;--tw-gradient-stops:initial;--tw-gradient-via-stops:initial;--tw-gradient-from-position:0%;--tw-gradient-via-position:50%;--tw-gradient-to-position:100%;--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{:host,:root{--color-red-50:oklch(97.1% .013 17.38);--color-red-100:oklch(93.6% .032 17.717);--color-red-200:oklch(88.5% .062 18.334);--color-red-300:oklch(80.8% .114 19.571);--color-red-400:oklch(70.4% .191 22.216);--color-red-500:oklch(63.7% .237 25.331);--color-red-600:oklch(57.7% .245 27.325);--color-red-800:oklch(44.4% .177 26.899);--color-orange-100:oklch(95.4% .038 75.164);--color-orange-300:oklch(83.7% .128 66.29);--color-orange-400:oklch(75% .183 55.934);--color-orange-600:oklch(64.6% .222 41.116);--color-orange-700:oklch(55.3% .195 38.402);--color-orange-800:oklch(47% .157 37.304);--color-amber-50:oklch(98.7% .022 95.277);--color-amber-200:oklch(92.4% .12 95.746);--color-amber-600:oklch(66.6% .179 58.318);--color-amber-800:oklch(47.3% .137 46.201);--color-yellow-100:oklch(97.3% .071 103.193);--color-yellow-500:oklch(79.5% .184 86.047);--color-yellow-800:oklch(47.6% .114 61.907);--color-green-50:oklch(98.2% .018 155.826);--color-green-100:oklch(96.2% .044 156.743);--color-green-200:oklch(92.5% .084 155.995);--color-green-300:oklch(87.1% .15 154.449);--color-green-400:oklch(79.2% .209 151.711);--color-green-500:oklch(72.3% .219 149.579);--color-green-600:oklch(62.7% .194 149.214);--color-green-700:oklch(52.7% .154 150.069);--color-green-800:oklch(44.8% .119 151.328);--color-green-900:oklch(39.3% .095 152.535);--color-green-950:oklch(26.6% .065 152.934);--color-emerald-50:oklch(97.9% .021 166.113);--color-emerald-100:oklch(95% .052 163.051);--color-emerald-200:oklch(90.5% .093 164.15);--color-emerald-800:oklch(43.2% .095 166.913);--color-blue-50:oklch(97% .014 254.604);--color-blue-100:oklch(93.2% .032 255.585);--color-blue-200:oklch(88.2% .059 254.128);--color-blue-500:oklch(62.3% .214 259.815);--color-blue-600:oklch(54.6% .245 262.881);--color-blue-700:oklch(48.8% .243 264.376);--color-blue-800:oklch(42.4% .199 265.638);--color-blue-900:oklch(37.9% .146 265.522);--color-indigo-50:oklch(96.2% .018 272.314);--color-purple-50:oklch(97.7% .014 308.299);--color-purple-100:oklch(94.6% .033 307.174);--color-purple-200:oklch(90.2% .063 306.703);--color-purple-600:oklch(55.8% .288 302.321);--color-purple-800:oklch(43.8% .218 303.724);--color-purple-900:oklch(38.1% .176 304.987);--color-pink-50:oklch(97.1% .014 343.198);--color-pink-100:oklch(94.8% .028 342.258);--color-pink-800:oklch(45.9% .187 3.815);--color-gray-50:oklch(98.5% .002 247.839);--color-gray-100:oklch(96.7% .003 264.542);--color-gray-800:oklch(27.8% .033 256.848);--color-gray-900:oklch(21% .034 264.665);--color-black:#000;--color-white:#fff;--spacing:.25rem;--container-sm:24rem;--container-md:28rem;--container-lg:32rem;--container-xl:36rem;--container-6xl:72rem;--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);--text-3xl:1.875rem;--text-3xl--line-height:calc(2.25/1.875);--text-4xl:2.25rem;--text-4xl--line-height:calc(2.5/2.25);--text-5xl:3rem;--text-5xl--line-height:1;--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--tracking-tight:-.025em;--tracking-widest:.1em;--leading-tight:1.25;--leading-relaxed:1.625;--radius-xs:.125rem;--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-geist-sans);--default-mono-font-family:var(--font-geist-mono);--color-border:var(--border)}}@layer base{*,::backdrop,:after,:before{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}:host,html{-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;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{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}menu,ol,ul{list-style:none}audio,canvas,embed,iframe,img,object,svg,video{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,optgroup,select,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,::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-second-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,::-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{container:card/inline-size}.\@container\/card-header{container:card-header/inline-size}.\@container\/main{container:main/inline-size}.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden}.absolute,.sr-only{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.sticky{position:sticky}.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{top:calc(var(--spacing)*2)}.top-2\.5{top:calc(var(--spacing)*2.5)}.top-3{top:calc(var(--spacing)*3)}.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-3{left:calc(var(--spacing)*3)}.left-\[50\%\]{left:50%}.isolate{isolation:isolate}.z-0{z-index:0}.z-10{z-index:10}.z-20{z-index:20}.z-50{z-index:50}.z-\[1\]{z-index:1}.z-\[100\]{z-index:100}.col-span-full{grid-column:1/-1}.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}}.-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-0\.5{margin-block:calc(var(--spacing)*.5)}.my-1{margin-block:calc(var(--spacing)*1)}.my-2{margin-block:calc(var(--spacing)*2)}.-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-6{margin-top:calc(var(--spacing)*6)}.mt-auto{margin-top:auto}.mr-1{margin-right:calc(var(--spacing)*1)}.mr-2{margin-right:calc(var(--spacing)*2)}.mb-2{margin-bottom:calc(var(--spacing)*2)}.mb-3{margin-bottom:calc(var(--spacing)*3)}.mb-4{margin-bottom:calc(var(--spacing)*4)}.mb-6{margin-bottom:calc(var(--spacing)*6)}.mb-8{margin-bottom:calc(var(--spacing)*8)}.-ml-1{margin-left:calc(var(--spacing)*-1)}.-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-auto{margin-left:auto}.line-clamp-1{-webkit-line-clamp:1}.line-clamp-1,.line-clamp-2{-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-2{-webkit-line-clamp:2}.block{display:block}.contents{display:contents}.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-auto{aspect-ratio:auto}.aspect-square{aspect-ratio:1}.aspect-video{aspect-ratio:var(--aspect-video)}.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-full{width:100%;height:100%}.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-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-24{height:calc(var(--spacing)*24)}.h-\[1\.15rem\]{height:1.15rem}.h-\[40px\]{height:40px}.h-\[60px\]{height:60px}.h-\[100px\]{height:100px}.h-\[120px\]{height:120px}.h-\[200px\]{height:200px}.h-\[250px\]{height:250px}.h-\[300px\]{height:300px}.h-\[400px\]{height:400px}.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-32{max-height:calc(var(--spacing)*32)}.max-h-60{max-height:calc(var(--spacing)*60)}.max-h-\[80vh\]{max-height:80vh}.max-h-\[90vh\]{max-height:90vh}.max-h-\[300px\]{max-height:300px}.max-h-screen{max-height:100vh}.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-screen{min-height:100vh}.min-h-svh{min-height:100svh}.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\/4{width:75%}.w-4{width:calc(var(--spacing)*4)}.w-5{width:calc(var(--spacing)*5)}.w-8{width:calc(var(--spacing)*8)}.w-9{width:calc(var(--spacing)*9)}.w-12{width:calc(var(--spacing)*12)}.w-16{width:calc(var(--spacing)*16)}.w-20{width:calc(var(--spacing)*20)}.w-24{width:calc(var(--spacing)*24)}.w-32{width:calc(var(--spacing)*32)}.w-40{width:calc(var(--spacing)*40)}.w-56{width:calc(var(--spacing)*56)}.w-64{width:calc(var(--spacing)*64)}.w-72{width:calc(var(--spacing)*72)}.w-\[--radix-dropdown-menu-trigger-width\]{width:--radix-dropdown-menu-trigger-width}.w-\[60px\]{width:60px}.w-\[100px\]{width:100px}.w-\[400px\]{width:400px}.w-\[calc\(100\%-3rem\)\]{width:calc(100% - 3rem)}.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-6xl{max-width:var(--container-6xl)}.max-w-20{max-width:calc(var(--spacing)*20)}.max-w-32{max-width:calc(var(--spacing)*32)}.max-w-\[300px\]{max-width:300px}.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)}.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-56{min-width:calc(var(--spacing)*56)}.min-w-\[8rem\]{min-width:8rem}.min-w-\[12rem\]{min-width:12rem}.min-w-\[var\(--radix-select-trigger-width\)\]{min-width:var(--radix-select-trigger-width)}.min-w-fit{min-width:fit-content}.min-w-max{min-width:max-content}.flex-1{flex:1}.flex-shrink-0,.shrink-0{flex-shrink:0}.grow-0{flex-grow:0}.basis-full{flex-basis:100%}.caption-bottom{caption-side:bottom}.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-x-1\/2,.-translate-x-px{translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-x-px{--tw-translate-x:-1px}.translate-x-\[-50\%\]{--tw-translate-x:-50%}.translate-x-\[-50\%\],.translate-x-px{translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-x-px{--tw-translate-x:1px}.-translate-y-1\/2{--tw-translate-y:calc(calc(1/2*100%)*-1)}.-translate-y-1\/2,.translate-y-\[-50\%\]{translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-\[-50\%\]{--tw-translate-y:-50%}.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:caret-blink 1.25s ease-out infinite}.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}.touch-none{touch-action:none}.scroll-my-1{scroll-margin-block:calc(var(--spacing)*1)}.scroll-py-1{scroll-padding-block:calc(var(--spacing)*1)}.list-inside{list-style-position:inside}.list-disc{list-style-type:disc}.list-none{list-style-type:none}.auto-cols-fr{grid-auto-columns:minmax(0,1fr)}.grid-flow-col{grid-auto-flow:column}.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-3{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.grid-cols-6{grid-template-columns:repeat(6,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}.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-1{gap:calc(var(--spacing)*1)}.gap-1\.5{gap:calc(var(--spacing)*1.5)}.gap-2{gap:calc(var(--spacing)*2)}.gap-3{gap:calc(var(--spacing)*3)}.gap-4{gap:calc(var(--spacing)*4)}.gap-6{gap:calc(var(--spacing)*6)}.gap-8{gap:calc(var(--spacing)*8)}:where(.space-y-0\.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-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-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-1>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*1)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*1)*calc(1 - var(--tw-space-x-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)))}:where(.space-x-3>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*3)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*3)*calc(1 - var(--tw-space-x-reverse)))}:where(.space-x-4>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*4)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*4)*calc(1 - var(--tw-space-x-reverse)))}.gap-y-0\.5{row-gap:calc(var(--spacing)*.5)}.self-start{align-self:flex-start}.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-\[2px\]{border-radius:2px}.rounded-\[4px\]{border-radius:4px}.rounded-\[inherit\]{border-radius:inherit}.rounded-full{border-radius:3.40282e+38px}.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-tl-sm{border-top-left-radius:calc(var(--radius) - 4px)}.border{border-style:var(--tw-border-style);border-width:1px}.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-blue-200{border-color:var(--color-blue-200)}.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-emerald-200{border-color:var(--color-emerald-200)}.border-green-200{border-color:var(--color-green-200)}.border-green-300{border-color:var(--color-green-300)}.border-green-500{border-color:var(--color-green-500)}.border-input{border-color:var(--input)}.border-orange-300{border-color:var(--color-orange-300)}.border-purple-200{border-color:var(--color-purple-200)}.border-red-200{border-color:var(--color-red-200)}.border-red-300{border-color:var(--color-red-300)}.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-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-blue-50{background-color:var(--color-blue-50)}.bg-blue-100{background-color:var(--color-blue-100)}.bg-blue-600{background-color:var(--color-blue-600)}.bg-border{background-color:var(--border)}.bg-card{background-color:var(--card)}.bg-destructive,.bg-destructive\/10{background-color:var(--destructive)}@supports (color:color-mix(in lab,red,red)){.bg-destructive\/10{background-color:color-mix(in oklab,var(--destructive)10%,transparent)}}.bg-emerald-100{background-color:var(--color-emerald-100)}.bg-foreground{background-color:var(--foreground)}.bg-gray-50{background-color:var(--color-gray-50)}.bg-gray-100{background-color:var(--color-gray-100)}.bg-gray-900{background-color:var(--color-gray-900)}.bg-green-50{background-color:var(--color-green-50)}.bg-green-100{background-color:var(--color-green-100)}.bg-green-500{background-color:var(--color-green-500)}.bg-muted{background-color:var(--muted)}.bg-muted-foreground\/30{background-color:var(--muted-foreground)}@supports (color:color-mix(in lab,red,red)){.bg-muted-foreground\/30{background-color:color-mix(in oklab,var(--muted-foreground)30%,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-orange-100{background-color:var(--color-orange-100)}.bg-pink-100{background-color:var(--color-pink-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-purple-100{background-color:var(--color-purple-100)}.bg-red-50{background-color:var(--color-red-50)}.bg-red-100{background-color:var(--color-red-100)}.bg-red-500{background-color:var(--color-red-500)}.bg-red-600{background-color:var(--color-red-600)}.bg-secondary{background-color:var(--secondary)}.bg-sidebar{background-color:var(--sidebar)}.bg-sidebar-border{background-color:var(--sidebar-border)}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.bg-yellow-100{background-color:var(--color-yellow-100)}.bg-yellow-500{background-color:var(--color-yellow-500)}.bg-gradient-to-r{--tw-gradient-position:to right in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}.from-blue-50{--tw-gradient-from:var(--color-blue-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.from-green-50{--tw-gradient-from:var(--color-green-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.from-purple-50{--tw-gradient-from:var(--color-purple-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-emerald-50{--tw-gradient-to:var(--color-emerald-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-indigo-50{--tw-gradient-to:var(--color-indigo-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-pink-50{--tw-gradient-to:var(--color-pink-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.fill-current{fill:currentColor}.fill-primary{fill:var(--primary)}.object-cover{object-fit:cover}.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-8{padding:calc(var(--spacing)*8)}.p-\[3px\]{padding:3px}.p-px{padding:1px}.px-0{padding-inline:calc(var(--spacing)*0)}.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\.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-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)}.pt-6{padding-top:calc(var(--spacing)*6)}.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-8{padding-right:calc(var(--spacing)*8)}.pr-10{padding-right:calc(var(--spacing)*10)}.pr-24{padding-right:calc(var(--spacing)*24)}.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-4{padding-left:calc(var(--spacing)*4)}.pl-8{padding-left:calc(var(--spacing)*8)}.pl-9{padding-left:calc(var(--spacing)*9)}.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-geist-mono)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.text-4xl{font-size:var(--text-4xl);line-height:var(--tw-leading,var(--text-4xl--line-height))}.text-5xl{font-size:var(--text-5xl);line-height:var(--tw-leading,var(--text-5xl--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-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.leading-none{--tw-leading:1;line-height:1}.leading-tight{--tw-leading:var(--leading-tight);line-height:var(--leading-tight)}.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-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}.text-ellipsis{text-overflow:ellipsis}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-wrap{white-space:pre-wrap}.text-amber-600{color:var(--color-amber-600)}.text-amber-800{color:var(--color-amber-800)}.text-blue-500{color:var(--color-blue-500)}.text-blue-600{color:var(--color-blue-600)}.text-blue-800{color:var(--color-blue-800)}.text-blue-900{color:var(--color-blue-900)}.text-card-foreground{color:var(--card-foreground)}.text-current{color:currentColor}.text-destructive{color:var(--destructive)}.text-emerald-800{color:var(--color-emerald-800)}.text-foreground,.text-foreground\/50{color:var(--foreground)}@supports (color:color-mix(in lab,red,red)){.text-foreground\/50{color:color-mix(in oklab,var(--foreground)50%,transparent)}}.text-gray-800{color:var(--color-gray-800)}.text-green-400{color:var(--color-green-400)}.text-green-500{color:var(--color-green-500)}.text-green-600{color:var(--color-green-600)}.text-green-800{color:var(--color-green-800)}.text-green-900{color:var(--color-green-900)}.text-muted-foreground{color:var(--muted-foreground)}.text-orange-600{color:var(--color-orange-600)}.text-orange-800{color:var(--color-orange-800)}.text-pink-800{color:var(--color-pink-800)}.text-popover-foreground{color:var(--popover-foreground)}.text-primary{color:var(--primary)}.text-primary-foreground{color:var(--primary-foreground)}.text-purple-600{color:var(--color-purple-600)}.text-purple-800{color:var(--color-purple-800)}.text-purple-900{color:var(--color-purple-900)}.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-white{color:var(--color-white)}.text-yellow-500{color:var(--color-yellow-500)}.text-yellow-800{color:var(--color-yellow-800)}.capitalize{text-transform:capitalize}.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,)}.line-through{text-decoration-line:line-through}.underline{text-decoration-line:underline}.underline-offset-4{text-underline-offset:4px}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-75{opacity:.75}.opacity-90{opacity:.9}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a)}.shadow,.shadow-\[0_0_0_1px_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-\[0_0_0_1px_hsl\(var\(--sidebar-border\)\)\]{--tw-shadow:0 0 0 1px var(--tw-shadow-color,hsl(var(--sidebar-border)))}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a)}.shadow-lg,.shadow-md{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)}.shadow-none{--tw-shadow:0 0 #0000}.shadow-none,.shadow-sm{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)}.shadow-xl{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a),0 8px 10px -6px var(--tw-shadow-color,#0000001a)}.shadow-xl,.shadow-xs{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)}.ring-0{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(0px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor)}.ring-0,.ring-2{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-2{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(2px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor)}.ring-blue-500{--tw-ring-color:var(--color-blue-500)}.ring-primary{--tw-ring-color:var(--primary)}.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}.grayscale{--tw-grayscale:grayscale(100%)}.filter,.grayscale{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\,height\]{transition-property:width,height;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-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}.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 *),.group-hover\:opacity-100:is(:where(.group):hover *){opacity:1}}.group-has-data-\[collapsible\=icon\]\/sidebar-wrapper\:h-12:is(:where(.group\/sidebar-wrapper):has([data-collapsible=icon]) *){height:calc(var(--spacing)*12)}.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-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] *){opacity:.5}.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-\[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}.group-\[\.destructive\]\:border-muted\/40:is(:where(.group).destructive *){border-color:var(--muted)}@supports (color:color-mix(in lab,red,red)){.group-\[\.destructive\]\:border-muted\/40:is(:where(.group).destructive *){border-color:color-mix(in oklab,var(--muted)40%,transparent)}}.group-\[\.destructive\]\:text-red-300:is(:where(.group).destructive *){color:var(--color-red-300)}@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{background-color:var(--primary)}.selection\:bg-primary::selection{background-color:var(--primary)}.selection\:text-primary-foreground ::selection{color:var(--primary-foreground)}.selection\:text-primary-foreground::selection{color:var(--primary-foreground)}.file\:mr-4::file-selector-button{margin-right:calc(var(--spacing)*4)}.file\:inline-flex::file-selector-button{display:inline-flex}.file\:h-7::file-selector-button{height:calc(var(--spacing)*7)}.file\:rounded-full::file-selector-button{border-radius:3.40282e+38px}.file\:border-0::file-selector-button{border-style:var(--tw-border-style);border-width:0}.file\:bg-blue-50::file-selector-button{background-color:var(--color-blue-50)}.file\:bg-transparent::file-selector-button{background-color:#0000}.file\:px-4::file-selector-button{padding-inline:calc(var(--spacing)*4)}.file\:py-2::file-selector-button{padding-block:calc(var(--spacing)*2)}.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\:font-semibold::file-selector-button{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.file\:text-blue-700::file-selector-button{color:var(--color-blue-700)}.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-0:after{content:var(--tw-content);inset:calc(var(--spacing)*0)}.after\:inset-y-0:after{content:var(--tw-content);inset-block:calc(var(--spacing)*0)}.after\:top-1\/2:after{content:var(--tw-content);top:50%}.after\:left-1\/2:after{content:var(--tw-content);left:50%}.after\:z-0:after{content:var(--tw-content);z-index:0}.after\:flex:after{content:var(--tw-content);display:flex}.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)}.after\:items-center:after{content:var(--tw-content);align-items:center}.after\:border-t:after{content:var(--tw-content);border-top-style:var(--tw-border-style);border-top-width:1px}.after\:border-border:after{content:var(--tw-content);border-color:var(--border)}.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\:rounded-r-md:last-child{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}@media (hover:hover){.hover\:border-green-400:hover{border-color:var(--color-green-400)}.hover\:border-orange-400:hover{border-color:var(--color-orange-400)}.hover\:bg-accent:hover{background-color:var(--accent)}.hover\:bg-blue-700:hover{background-color:var(--color-blue-700)}.hover\:bg-destructive\/80:hover{background-color:var(--destructive)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-destructive\/80:hover{background-color:color-mix(in oklab,var(--destructive)80%,transparent)}}.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-gray-100:hover{background-color:var(--color-gray-100)}.hover\:bg-green-500\/80:hover{background-color:#00c758cc}@supports (color:color-mix(in lab,red,red)){.hover\:bg-green-500\/80:hover{background-color:color-mix(in oklab,var(--color-green-500)80%,transparent)}}.hover\:bg-input\/30:hover{background-color:var(--input)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-input\/30:hover{background-color:color-mix(in oklab,var(--input)30%,transparent)}}.hover\:bg-muted:hover,.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\/80:hover{background-color:var(--primary)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-primary\/80:hover{background-color:color-mix(in oklab,var(--primary)80%,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-red-500\/80:hover{background-color:#fb2c36cc}@supports (color:color-mix(in lab,red,red)){.hover\:bg-red-500\/80:hover{background-color:color-mix(in oklab,var(--color-red-500)80%,transparent)}}.hover\:bg-secondary:hover,.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\:bg-transparent:hover{background-color:#0000}.hover\:bg-yellow-500\/80:hover{background-color:#edb200cc}@supports (color:color-mix(in lab,red,red)){.hover\:bg-yellow-500\/80:hover{background-color:color-mix(in oklab,var(--color-yellow-500)80%,transparent)}}.hover\:text-accent-foreground:hover{color:var(--accent-foreground)}.hover\:text-foreground:hover{color:var(--foreground)}.hover\:text-green-700:hover{color:var(--color-green-700)}.hover\:text-muted-foreground:hover{color:var(--muted-foreground)}.hover\:text-orange-700:hover{color:var(--color-orange-700)}.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)))}.hover\:shadow-\[0_0_0_1px_hsl\(var\(--sidebar-accent\)\)\]:hover,.hover\:shadow-md:hover{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.hover\:shadow-md:hover{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a),0 2px 4px -2px var(--tw-shadow-color,#0000001a)}.hover\:group-data-\[collapsible\=offcanvas\]\:bg-sidebar:hover:is(:where(.group)[data-collapsible=offcanvas] *){background-color:var(--sidebar)}.group-\[\.destructive\]\:hover\:border-destructive\/30:is(:where(.group).destructive *):hover{border-color:var(--destructive)}@supports (color:color-mix(in lab,red,red)){.group-\[\.destructive\]\:hover\:border-destructive\/30:is(:where(.group).destructive *):hover{border-color:color-mix(in oklab,var(--destructive)30%,transparent)}}.group-\[\.destructive\]\:hover\:bg-destructive:is(:where(.group).destructive *):hover{background-color:var(--destructive)}.group-\[\.destructive\]\:hover\:text-red-50:is(:where(.group).destructive *):hover{color:var(--color-red-50)}.hover\:file\:bg-blue-100:hover::file-selector-button{background-color:var(--color-blue-100)}.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-destructive:focus{color:var(--destructive)}.focus\:text-green-700:focus{color:var(--color-green-700)}.focus\:text-orange-700:focus{color:var(--color-orange-700)}.focus\:opacity-100:focus{opacity:1}.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-primary\/20:focus{--tw-ring-color:var(--primary)}@supports (color:color-mix(in lab,red,red)){.focus\:ring-primary\/20:focus{--tw-ring-color:color-mix(in oklab,var(--primary)20%,transparent)}}.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\:outline-none:focus{--tw-outline-style:none;outline-style:none}.group-\[\.destructive\]\:focus\:ring-destructive:is(:where(.group).destructive *):focus{--tw-ring-color:var(--destructive)}.group-\[\.destructive\]\:focus\:ring-red-400:is(:where(.group).destructive *):focus{--tw-ring-color:var(--color-red-400)}.group-\[\.destructive\]\:focus\:ring-offset-red-600:is(:where(.group).destructive *):focus{--tw-ring-offset-color:var(--color-red-600)}.focus-visible\:z-10:focus-visible{z-index:10}.focus-visible\:border:focus-visible{border-style:var(--tw-border-style);border-width:1px}.focus-visible\:border-ring:focus-visible{border-color:var(--ring)}.focus-visible\:bg-background:focus-visible{background-color:var(--background)}.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-\[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\/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\: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)}.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-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-\[variant\=inset\]\:bg-sidebar:has([data-variant=inset]){background-color:var(--sidebar)}.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\]\: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)}.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)}}.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-\[dragging\=true\]\:z-10[data-dragging=true]{z-index:10}.data-\[dragging\=true\]\:opacity-80[data-dragging=true]{opacity:.8}.data-\[error\=true\]\:text-destructive[data-error=true]{color:var(--destructive)}.data-\[inset\]\:pl-8[data-inset]{padding-left:calc(var(--spacing)*8)}.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-px[data-orientation=horizontal]{height:1px}.data-\[orientation\=horizontal\]\:w-full[data-orientation=horizontal]{width:100%}.data-\[orientation\=vertical\]\:h-4[data-orientation=vertical]{height:calc(var(--spacing)*4)}.data-\[orientation\=vertical\]\:h-full[data-orientation=vertical]{height:100%}.data-\[orientation\=vertical\]\:w-px[data-orientation=vertical]{width:1px}.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-\[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)}}:is(.\*\:data-\[slot\=card\]\:bg-gradient-to-t>*)[data-slot=card]{--tw-gradient-position:to top in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}:is(.\*\:data-\[slot\=card\]\:from-primary\/5>*)[data-slot=card]{--tw-gradient-from:var(--primary)}@supports (color:color-mix(in lab,red,red)){:is(.\*\:data-\[slot\=card\]\:from-primary\/5>*)[data-slot=card]{--tw-gradient-from:color-mix(in oklab,var(--primary)5%,transparent)}}:is(.\*\:data-\[slot\=card\]\:from-primary\/5>*)[data-slot=card]{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}:is(.\*\:data-\[slot\=card\]\:to-card>*)[data-slot=card]{--tw-gradient-to:var(--card);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}:is(.\*\:data-\[slot\=card\]\:shadow-xs>*)[data-slot=card]{--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)}: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-\[slot\=sidebar-menu-button\]\:\!p-1\.5[data-slot=sidebar-menu-button]{padding:calc(var(--spacing)*1.5)!important}:is(.\*\*\:data-\[slot\=table-cell\]\:first\:w-8 *)[data-slot=table-cell]:first-child{width:calc(var(--spacing)*8)}.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-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\]\:fade-out-80[data-state=closed]{--tw-exit-opacity:.8}.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-right-full[data-state=closed]{--tw-exit-translate-x:calc(1*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-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-muted[data-state=open]{background-color:var(--muted)}.data-\[state\=open\]\:bg-secondary[data-state=open]{background-color:var(--secondary)}.data-\[state\=open\]\:bg-sidebar-accent[data-state=open]{background-color:var(--sidebar-accent)}.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\]\:text-sidebar-accent-foreground[data-state=open]{color:var(--sidebar-accent-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%}.data-\[state\=open\]\:slide-in-from-top-full[data-state=open]{--tw-enter-translate-y:calc(1*-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-\[swipe\=cancel\]\:translate-x-0[data-swipe=cancel]{--tw-translate-x:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[swipe\=end\]\:translate-x-\[var\(--radix-toast-swipe-end-x\)\][data-swipe=end]{--tw-translate-x:var(--radix-toast-swipe-end-x);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[swipe\=end\]\:animate-out[data-swipe=end]{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-\[swipe\=move\]\:translate-x-\[var\(--radix-toast-swipe-move-x\)\][data-swipe=move]{--tw-translate-x:var(--radix-toast-swipe-move-x);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[swipe\=move\]\:transition-none[data-swipe=move]{transition-property:none}.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\=outline\]\:border-l-0[data-variant=outline]{border-left-style:var(--tw-border-style);border-left-width:0}.data-\[variant\=outline\]\:shadow-xs[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-\[variant\=outline\]\:first\:border-l[data-variant=outline]:first-child{border-left-style:var(--tw-border-style);border-left-width:1px}@media (min-width:40rem){.sm\:top-auto{top:auto}.sm\:right-0{right:calc(var(--spacing)*0)}.sm\:bottom-0{bottom:calc(var(--spacing)*0)}.sm\:flex{display:flex}.sm\:hidden{display:none}.sm\:inline{display:inline}.sm\:h-4{height:calc(var(--spacing)*4)}.sm\:w-4{width:calc(var(--spacing)*4)}.sm\:w-64{width:calc(var(--spacing)*64)}.sm\:w-\[180px\]{width:180px}.sm\:max-w-\[500px\]{max-width:500px}.sm\:max-w-\[600px\]{max-width:600px}.sm\:max-w-\[700px\]{max-width:700px}.sm\:max-w-lg{max-width:var(--container-lg)}.sm\:max-w-md{max-width:var(--container-md)}.sm\:max-w-none{max-width:none}.sm\:max-w-sm{max-width:var(--container-sm)}.sm\:max-w-xl{max-width:var(--container-xl)}.sm\:flex-initial{flex:0 auto}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\:flex-col{flex-direction:column}.sm\:flex-row{flex-direction:row}.sm\:items-center{align-items:center}.sm\:justify-end{justify-content:flex-end}.sm\:gap-2{gap:calc(var(--spacing)*2)}.sm\:gap-3{gap:calc(var(--spacing)*3)}:where(.sm\:space-x-0>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*0)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*0)*calc(1 - var(--tw-space-x-reverse)))}.sm\:px-6{padding-inline:calc(var(--spacing)*6)}.sm\:pt-6{padding-top:calc(var(--spacing)*6)}.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-\[state\=open\]\:sm\:slide-in-from-bottom-full[data-state=open]{--tw-enter-translate-y:calc(1*100%)}}@media (min-width:48rem){.md\:absolute{position:absolute}.md\:block{display:block}.md\:flex{display:flex}.md\:grid{display:grid}.md\:hidden{display:none}.md\:w-\[var\(--radix-navigation-menu-viewport-width\)\]{width:var(--radix-navigation-menu-viewport-width)}.md\:w-auto{width:auto}.md\:max-w-\[420px\]{max-width:420px}.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\:gap-8{gap:calc(var(--spacing)*8)}.md\:p-8{padding:calc(var(--spacing)*8)}.md\:px-6{padding-inline:calc(var(--spacing)*6)}.md\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--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\:ml-0{margin-left:calc(var(--spacing)*0)}.lg\:flex{display:flex}.lg\:hidden{display:none}.lg\:inline{display:inline}.lg\:w-fit{width:fit-content}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.lg\:gap-2{gap:calc(var(--spacing)*2)}.lg\:px-6{padding-inline:calc(var(--spacing)*6)}.lg\:px-8{padding-inline:calc(var(--spacing)*8)}}@container card (min-width:250px){.\@\[250px\]\/card\:text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}}@container card (min-width:540px){.\@\[540px\]\/card\:block{display:block}.\@\[540px\]\/card\:hidden{display:none}}@container card (min-width:767px){.\@\[767px\]\/card\:flex{display:flex}.\@\[767px\]\/card\:hidden{display:none}}@container main (min-width:36rem){.\@xl\/main\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@container main (min-width:56rem){.\@4xl\/main\:flex{display:flex}.\@4xl\/main\:hidden{display:none}}@container main (min-width:64rem){.\@5xl\/main\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}}.dark\:border-green-800:is(.dark *){border-color:var(--color-green-800)}.dark\:border-input:is(.dark *){border-color:var(--input)}.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-green-950:is(.dark *){background-color:var(--color-green-950)}.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\:text-green-100:is(.dark *){color:var(--color-green-100)}.dark\:text-green-400:is(.dark *){color:var(--color-green-400)}.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\: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\: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)}}:is(.dark\:\*\:data-\[slot\=card\]\:bg-card:is(.dark *)>*)[data-slot=card]{background-color:var(--card)}.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)}.\[\&_a\]\:underline a{text-decoration-line:underline}.\[\&_a\]\:underline-offset-4 a{text-underline-offset:4px}@media (hover:hover){.hover\:\[\&_a\]\:text-primary:hover a{color:var(--primary)}}.\[\&_p\]\:leading-relaxed p{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}.\[\&_svg\]\:pointer-events-none svg{pointer-events:none}.\[\&_svg\]\:size-3 svg{width:calc(var(--spacing)*3);height:calc(var(--spacing)*3)}.\[\&_svg\]\:shrink-0 svg{flex-shrink:0}.\[\&_svg\:not\(\[class\*\=\'size-\'\]\)\]\:size-4 svg:not([class*=size-]){width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.\[\&_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}.\[\&\:has\(\[role\=checkbox\]\)\]\:pr-0:has([role=checkbox]){padding-right:calc(var(--spacing)*0)}.\[\.border-b\]\:pb-6.border-b{padding-bottom:calc(var(--spacing)*6)}.\[\.border-t\]\:pt-6.border-t{padding-top:calc(var(--spacing)*6)}: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}.\[\&\>\[role\=checkbox\]\]\:translate-y-\[2px\]>[role=checkbox]{--tw-translate-y:2px;translate:var(--tw-translate-x)var(--tw-translate-y)}.\[\&\>button\]\:hidden>button{display:none}.\[\&\>span\:last-child\]\:truncate>span:last-child{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.\[\&\>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)}.\[\&\>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-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}}@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:oklch(100% 0 0);--foreground:oklch(14.7% .004 49.25);--card:oklch(100% 0 0);--card-foreground:oklch(14.7% .004 49.25);--popover:oklch(100% 0 0);--popover-foreground:oklch(14.7% .004 49.25);--primary:oklch(21.6% .006 56.043);--primary-foreground:oklch(98.5% .001 106.423);--secondary:oklch(97% .001 106.424);--secondary-foreground:oklch(21.6% .006 56.043);--muted:oklch(97% .001 106.424);--muted-foreground:oklch(55.3% .013 58.071);--accent:oklch(97% .001 106.424);--accent-foreground:oklch(21.6% .006 56.043);--destructive:oklch(57.7% .245 27.325);--border:oklch(92.3% .003 48.717);--input:oklch(92.3% .003 48.717);--ring:oklch(70.9% .01 56.259);--chart-1:oklch(64.6% .222 41.116);--chart-2:oklch(60% .118 184.704);--chart-3:oklch(39.8% .07 227.392);--chart-4:oklch(82.8% .189 84.429);--chart-5:oklch(76.9% .188 70.08);--sidebar:oklch(98.5% .001 106.423);--sidebar-foreground:oklch(14.7% .004 49.25);--sidebar-primary:oklch(21.6% .006 56.043);--sidebar-primary-foreground:oklch(98.5% .001 106.423);--sidebar-accent:oklch(97% .001 106.424);--sidebar-accent-foreground:oklch(21.6% .006 56.043);--sidebar-border:oklch(92.3% .003 48.717);--sidebar-ring:oklch(70.9% .01 56.259)}.dark{--background:oklch(14.7% .004 49.25);--foreground:oklch(98.5% .001 106.423);--card:oklch(21.6% .006 56.043);--card-foreground:oklch(98.5% .001 106.423);--popover:oklch(21.6% .006 56.043);--popover-foreground:oklch(98.5% .001 106.423);--primary:oklch(92.3% .003 48.717);--primary-foreground:oklch(21.6% .006 56.043);--secondary:oklch(26.8% .007 34.298);--secondary-foreground:oklch(98.5% .001 106.423);--muted:oklch(26.8% .007 34.298);--muted-foreground:oklch(70.9% .01 56.259);--accent:oklch(26.8% .007 34.298);--accent-foreground:oklch(98.5% .001 106.423);--destructive:oklch(70.4% .191 22.216);--border:oklch(100% 0 0/.1);--input:oklch(100% 0 0/.15);--ring:oklch(55.3% .013 58.071);--chart-1:oklch(48.8% .243 264.376);--chart-2:oklch(69.6% .17 162.48);--chart-3:oklch(76.9% .188 70.08);--chart-4:oklch(62.7% .265 303.9);--chart-5:oklch(64.5% .246 16.439);--sidebar:oklch(21.6% .006 56.043);--sidebar-foreground:oklch(98.5% .001 106.423);--sidebar-primary:oklch(48.8% .243 264.376);--sidebar-primary-foreground:oklch(98.5% .001 106.423);--sidebar-accent:oklch(26.8% .007 34.298);--sidebar-accent-foreground:oklch(98.5% .001 106.423);--sidebar-border:oklch(100% 0 0/.1);--sidebar-ring:oklch(55.3% .013 58.071)}@keyframes shimmer{0%{transform:translate(-100%)}to{transform:translate(100%)}}.animate-shimmer{animation:shimmer 2s infinite}@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-gradient-position{syntax:"*";inherits:false}@property --tw-gradient-from{syntax:"";inherits:false;initial-value:#0000}@property --tw-gradient-via{syntax:"";inherits:false;initial-value:#0000}@property --tw-gradient-to{syntax:"";inherits:false;initial-value:#0000}@property --tw-gradient-stops{syntax:"*";inherits:false}@property --tw-gradient-via-stops{syntax:"*";inherits:false}@property --tw-gradient-from-position{syntax:"";inherits:false;initial-value:0}@property --tw-gradient-via-position{syntax:"";inherits:false;initial-value:50%}@property --tw-gradient-to-position{syntax:"";inherits:false;initial-value:100%}@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(1turn)}}@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 caret-blink{0%,70%,to{opacity:1}20%,50%{opacity:0}} \ No newline at end of file diff --git a/ui_out/_next/static/css/a2fcfb52b8f42d80.css b/ui_out/_next/static/css/a2fcfb52b8f42d80.css new file mode 100644 index 00000000..19c69169 --- /dev/null +++ b/ui_out/_next/static/css/a2fcfb52b8f42d80.css @@ -0,0 +1 @@ +/*! tailwindcss v4.1.14 | 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)))){*,::backdrop,:after,:before{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--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-gradient-position:initial;--tw-gradient-from:#0000;--tw-gradient-via:#0000;--tw-gradient-to:#0000;--tw-gradient-stops:initial;--tw-gradient-via-stops:initial;--tw-gradient-from-position:0%;--tw-gradient-via-position:50%;--tw-gradient-to-position:100%;--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{:host,:root{--color-red-50:oklch(97.1% .013 17.38);--color-red-100:oklch(93.6% .032 17.717);--color-red-200:oklch(88.5% .062 18.334);--color-red-300:oklch(80.8% .114 19.571);--color-red-400:oklch(70.4% .191 22.216);--color-red-500:oklch(63.7% .237 25.331);--color-red-600:oklch(57.7% .245 27.325);--color-red-800:oklch(44.4% .177 26.899);--color-orange-100:oklch(95.4% .038 75.164);--color-orange-300:oklch(83.7% .128 66.29);--color-orange-400:oklch(75% .183 55.934);--color-orange-600:oklch(64.6% .222 41.116);--color-orange-700:oklch(55.3% .195 38.402);--color-orange-800:oklch(47% .157 37.304);--color-amber-50:oklch(98.7% .022 95.277);--color-amber-200:oklch(92.4% .12 95.746);--color-amber-600:oklch(66.6% .179 58.318);--color-amber-800:oklch(47.3% .137 46.201);--color-yellow-100:oklch(97.3% .071 103.193);--color-yellow-500:oklch(79.5% .184 86.047);--color-yellow-800:oklch(47.6% .114 61.907);--color-green-50:oklch(98.2% .018 155.826);--color-green-100:oklch(96.2% .044 156.743);--color-green-200:oklch(92.5% .084 155.995);--color-green-300:oklch(87.1% .15 154.449);--color-green-400:oklch(79.2% .209 151.711);--color-green-500:oklch(72.3% .219 149.579);--color-green-600:oklch(62.7% .194 149.214);--color-green-700:oklch(52.7% .154 150.069);--color-green-800:oklch(44.8% .119 151.328);--color-green-900:oklch(39.3% .095 152.535);--color-green-950:oklch(26.6% .065 152.934);--color-emerald-50:oklch(97.9% .021 166.113);--color-emerald-100:oklch(95% .052 163.051);--color-emerald-200:oklch(90.5% .093 164.15);--color-emerald-800:oklch(43.2% .095 166.913);--color-blue-50:oklch(97% .014 254.604);--color-blue-100:oklch(93.2% .032 255.585);--color-blue-200:oklch(88.2% .059 254.128);--color-blue-500:oklch(62.3% .214 259.815);--color-blue-600:oklch(54.6% .245 262.881);--color-blue-700:oklch(48.8% .243 264.376);--color-blue-800:oklch(42.4% .199 265.638);--color-blue-900:oklch(37.9% .146 265.522);--color-indigo-50:oklch(96.2% .018 272.314);--color-purple-50:oklch(97.7% .014 308.299);--color-purple-100:oklch(94.6% .033 307.174);--color-purple-200:oklch(90.2% .063 306.703);--color-purple-600:oklch(55.8% .288 302.321);--color-purple-800:oklch(43.8% .218 303.724);--color-purple-900:oklch(38.1% .176 304.987);--color-pink-50:oklch(97.1% .014 343.198);--color-pink-100:oklch(94.8% .028 342.258);--color-pink-800:oklch(45.9% .187 3.815);--color-gray-50:oklch(98.5% .002 247.839);--color-gray-100:oklch(96.7% .003 264.542);--color-gray-800:oklch(27.8% .033 256.848);--color-gray-900:oklch(21% .034 264.665);--color-black:#000;--color-white:#fff;--spacing:.25rem;--container-sm:24rem;--container-md:28rem;--container-lg:32rem;--container-xl:36rem;--container-6xl:72rem;--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);--text-3xl:1.875rem;--text-3xl--line-height:calc(2.25/1.875);--text-4xl:2.25rem;--text-4xl--line-height:calc(2.5/2.25);--text-5xl:3rem;--text-5xl--line-height:1;--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--tracking-tight:-.025em;--tracking-widest:.1em;--leading-tight:1.25;--leading-relaxed:1.625;--radius-xs:.125rem;--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-geist-sans);--default-mono-font-family:var(--font-geist-mono);--color-border:var(--border)}}@layer base{*,::backdrop,:after,:before{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}:host,html{-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;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{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}menu,ol,ul{list-style:none}audio,canvas,embed,iframe,img,object,svg,video{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,optgroup,select,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,::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-second-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,::-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{container:card/inline-size}.\@container\/card-header{container:card-header/inline-size}.\@container\/main{container:main/inline-size}.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden}.absolute,.sr-only{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.sticky{position:sticky}.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{top:calc(var(--spacing)*2)}.top-2\.5{top:calc(var(--spacing)*2.5)}.top-3{top:calc(var(--spacing)*3)}.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-3{left:calc(var(--spacing)*3)}.left-\[50\%\]{left:50%}.isolate{isolation:isolate}.z-0{z-index:0}.z-10{z-index:10}.z-20{z-index:20}.z-50{z-index:50}.z-\[1\]{z-index:1}.z-\[100\]{z-index:100}.col-span-full{grid-column:1/-1}.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}}.-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-0\.5{margin-block:calc(var(--spacing)*.5)}.my-1{margin-block:calc(var(--spacing)*1)}.my-2{margin-block:calc(var(--spacing)*2)}.-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-6{margin-top:calc(var(--spacing)*6)}.mt-auto{margin-top:auto}.mr-1{margin-right:calc(var(--spacing)*1)}.mr-2{margin-right:calc(var(--spacing)*2)}.mb-2{margin-bottom:calc(var(--spacing)*2)}.mb-3{margin-bottom:calc(var(--spacing)*3)}.mb-4{margin-bottom:calc(var(--spacing)*4)}.mb-6{margin-bottom:calc(var(--spacing)*6)}.mb-8{margin-bottom:calc(var(--spacing)*8)}.-ml-1{margin-left:calc(var(--spacing)*-1)}.-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-auto{margin-left:auto}.line-clamp-1{-webkit-line-clamp:1}.line-clamp-1,.line-clamp-2{-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-2{-webkit-line-clamp:2}.block{display:block}.contents{display:contents}.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-auto{aspect-ratio:auto}.aspect-square{aspect-ratio:1}.aspect-video{aspect-ratio:var(--aspect-video)}.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-full{width:100%;height:100%}.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-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-24{height:calc(var(--spacing)*24)}.h-\[1\.15rem\]{height:1.15rem}.h-\[40px\]{height:40px}.h-\[60px\]{height:60px}.h-\[100px\]{height:100px}.h-\[120px\]{height:120px}.h-\[200px\]{height:200px}.h-\[250px\]{height:250px}.h-\[300px\]{height:300px}.h-\[400px\]{height:400px}.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-32{max-height:calc(var(--spacing)*32)}.max-h-60{max-height:calc(var(--spacing)*60)}.max-h-\[80vh\]{max-height:80vh}.max-h-\[90vh\]{max-height:90vh}.max-h-\[300px\]{max-height:300px}.max-h-screen{max-height:100vh}.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-screen{min-height:100vh}.min-h-svh{min-height:100svh}.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\/4{width:75%}.w-4{width:calc(var(--spacing)*4)}.w-5{width:calc(var(--spacing)*5)}.w-8{width:calc(var(--spacing)*8)}.w-9{width:calc(var(--spacing)*9)}.w-12{width:calc(var(--spacing)*12)}.w-16{width:calc(var(--spacing)*16)}.w-20{width:calc(var(--spacing)*20)}.w-24{width:calc(var(--spacing)*24)}.w-32{width:calc(var(--spacing)*32)}.w-40{width:calc(var(--spacing)*40)}.w-56{width:calc(var(--spacing)*56)}.w-64{width:calc(var(--spacing)*64)}.w-72{width:calc(var(--spacing)*72)}.w-\[--radix-dropdown-menu-trigger-width\]{width:--radix-dropdown-menu-trigger-width}.w-\[60px\]{width:60px}.w-\[100px\]{width:100px}.w-\[400px\]{width:400px}.w-\[calc\(100\%-3rem\)\]{width:calc(100% - 3rem)}.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-6xl{max-width:var(--container-6xl)}.max-w-20{max-width:calc(var(--spacing)*20)}.max-w-32{max-width:calc(var(--spacing)*32)}.max-w-\[300px\]{max-width:300px}.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)}.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-56{min-width:calc(var(--spacing)*56)}.min-w-\[8rem\]{min-width:8rem}.min-w-\[12rem\]{min-width:12rem}.min-w-\[var\(--radix-select-trigger-width\)\]{min-width:var(--radix-select-trigger-width)}.min-w-fit{min-width:fit-content}.min-w-max{min-width:max-content}.flex-1{flex:1}.flex-shrink-0,.shrink-0{flex-shrink:0}.grow-0{flex-grow:0}.basis-full{flex-basis:100%}.caption-bottom{caption-side:bottom}.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-x-1\/2,.-translate-x-px{translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-x-px{--tw-translate-x:-1px}.translate-x-\[-50\%\]{--tw-translate-x:-50%}.translate-x-\[-50\%\],.translate-x-px{translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-x-px{--tw-translate-x:1px}.-translate-y-1\/2{--tw-translate-y:calc(calc(1/2*100%)*-1)}.-translate-y-1\/2,.translate-y-\[-50\%\]{translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-\[-50\%\]{--tw-translate-y:-50%}.translate-y-\[calc\(-50\%_-_2px\)\]{--tw-translate-y:calc(-50% - 2px);translate:var(--tw-translate-x)var(--tw-translate-y)}.scale-0{--tw-scale-x:0%;--tw-scale-y:0%;--tw-scale-z:0%}.scale-0,.scale-100{scale:var(--tw-scale-x)var(--tw-scale-y)}.scale-100{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%}.rotate-0{rotate:none}.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:caret-blink 1.25s ease-out infinite}.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}.touch-none{touch-action:none}.scroll-my-1{scroll-margin-block:calc(var(--spacing)*1)}.scroll-py-1{scroll-padding-block:calc(var(--spacing)*1)}.list-inside{list-style-position:inside}.list-disc{list-style-type:disc}.list-none{list-style-type:none}.auto-cols-fr{grid-auto-columns:minmax(0,1fr)}.grid-flow-col{grid-auto-flow:column}.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-3{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.grid-cols-6{grid-template-columns:repeat(6,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}.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-1{gap:calc(var(--spacing)*1)}.gap-1\.5{gap:calc(var(--spacing)*1.5)}.gap-2{gap:calc(var(--spacing)*2)}.gap-3{gap:calc(var(--spacing)*3)}.gap-4{gap:calc(var(--spacing)*4)}.gap-6{gap:calc(var(--spacing)*6)}.gap-8{gap:calc(var(--spacing)*8)}:where(.space-y-0\.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-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-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-1>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*1)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*1)*calc(1 - var(--tw-space-x-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)))}:where(.space-x-3>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*3)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*3)*calc(1 - var(--tw-space-x-reverse)))}:where(.space-x-4>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*4)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*4)*calc(1 - var(--tw-space-x-reverse)))}.gap-y-0\.5{row-gap:calc(var(--spacing)*.5)}.self-start{align-self:flex-start}.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-\[2px\]{border-radius:2px}.rounded-\[4px\]{border-radius:4px}.rounded-\[inherit\]{border-radius:inherit}.rounded-full{border-radius:3.40282e+38px}.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-tl-sm{border-top-left-radius:calc(var(--radius) - 4px)}.border{border-style:var(--tw-border-style);border-width:1px}.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-blue-200{border-color:var(--color-blue-200)}.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-emerald-200{border-color:var(--color-emerald-200)}.border-green-200{border-color:var(--color-green-200)}.border-green-300{border-color:var(--color-green-300)}.border-green-500{border-color:var(--color-green-500)}.border-input{border-color:var(--input)}.border-orange-300{border-color:var(--color-orange-300)}.border-purple-200{border-color:var(--color-purple-200)}.border-red-200{border-color:var(--color-red-200)}.border-red-300{border-color:var(--color-red-300)}.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-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-blue-50{background-color:var(--color-blue-50)}.bg-blue-100{background-color:var(--color-blue-100)}.bg-blue-600{background-color:var(--color-blue-600)}.bg-border{background-color:var(--border)}.bg-card{background-color:var(--card)}.bg-destructive,.bg-destructive\/10{background-color:var(--destructive)}@supports (color:color-mix(in lab,red,red)){.bg-destructive\/10{background-color:color-mix(in oklab,var(--destructive)10%,transparent)}}.bg-emerald-100{background-color:var(--color-emerald-100)}.bg-foreground{background-color:var(--foreground)}.bg-gray-50{background-color:var(--color-gray-50)}.bg-gray-100{background-color:var(--color-gray-100)}.bg-gray-900{background-color:var(--color-gray-900)}.bg-green-50{background-color:var(--color-green-50)}.bg-green-100{background-color:var(--color-green-100)}.bg-green-500{background-color:var(--color-green-500)}.bg-muted{background-color:var(--muted)}.bg-muted-foreground\/30{background-color:var(--muted-foreground)}@supports (color:color-mix(in lab,red,red)){.bg-muted-foreground\/30{background-color:color-mix(in oklab,var(--muted-foreground)30%,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-orange-100{background-color:var(--color-orange-100)}.bg-pink-100{background-color:var(--color-pink-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-purple-100{background-color:var(--color-purple-100)}.bg-red-50{background-color:var(--color-red-50)}.bg-red-100{background-color:var(--color-red-100)}.bg-red-500{background-color:var(--color-red-500)}.bg-red-600{background-color:var(--color-red-600)}.bg-secondary{background-color:var(--secondary)}.bg-sidebar{background-color:var(--sidebar)}.bg-sidebar-border{background-color:var(--sidebar-border)}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.bg-yellow-100{background-color:var(--color-yellow-100)}.bg-yellow-500{background-color:var(--color-yellow-500)}.bg-gradient-to-r{--tw-gradient-position:to right in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}.from-blue-50{--tw-gradient-from:var(--color-blue-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.from-green-50{--tw-gradient-from:var(--color-green-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.from-purple-50{--tw-gradient-from:var(--color-purple-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-emerald-50{--tw-gradient-to:var(--color-emerald-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-indigo-50{--tw-gradient-to:var(--color-indigo-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-pink-50{--tw-gradient-to:var(--color-pink-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.fill-current{fill:currentColor}.fill-primary{fill:var(--primary)}.object-cover{object-fit:cover}.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-8{padding:calc(var(--spacing)*8)}.p-\[3px\]{padding:3px}.p-px{padding:1px}.px-0{padding-inline:calc(var(--spacing)*0)}.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\.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-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)}.pt-6{padding-top:calc(var(--spacing)*6)}.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-8{padding-right:calc(var(--spacing)*8)}.pr-10{padding-right:calc(var(--spacing)*10)}.pr-24{padding-right:calc(var(--spacing)*24)}.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-4{padding-left:calc(var(--spacing)*4)}.pl-8{padding-left:calc(var(--spacing)*8)}.pl-9{padding-left:calc(var(--spacing)*9)}.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-geist-mono)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.text-4xl{font-size:var(--text-4xl);line-height:var(--tw-leading,var(--text-4xl--line-height))}.text-5xl{font-size:var(--text-5xl);line-height:var(--tw-leading,var(--text-5xl--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-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.leading-none{--tw-leading:1;line-height:1}.leading-tight{--tw-leading:var(--leading-tight);line-height:var(--leading-tight)}.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-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}.text-ellipsis{text-overflow:ellipsis}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-wrap{white-space:pre-wrap}.text-amber-600{color:var(--color-amber-600)}.text-amber-800{color:var(--color-amber-800)}.text-blue-500{color:var(--color-blue-500)}.text-blue-600{color:var(--color-blue-600)}.text-blue-800{color:var(--color-blue-800)}.text-blue-900{color:var(--color-blue-900)}.text-card-foreground{color:var(--card-foreground)}.text-current{color:currentColor}.text-destructive{color:var(--destructive)}.text-emerald-800{color:var(--color-emerald-800)}.text-foreground,.text-foreground\/50{color:var(--foreground)}@supports (color:color-mix(in lab,red,red)){.text-foreground\/50{color:color-mix(in oklab,var(--foreground)50%,transparent)}}.text-gray-800{color:var(--color-gray-800)}.text-green-400{color:var(--color-green-400)}.text-green-500{color:var(--color-green-500)}.text-green-600{color:var(--color-green-600)}.text-green-800{color:var(--color-green-800)}.text-green-900{color:var(--color-green-900)}.text-muted-foreground{color:var(--muted-foreground)}.text-orange-600{color:var(--color-orange-600)}.text-orange-800{color:var(--color-orange-800)}.text-pink-800{color:var(--color-pink-800)}.text-popover-foreground{color:var(--popover-foreground)}.text-primary{color:var(--primary)}.text-primary-foreground{color:var(--primary-foreground)}.text-purple-600{color:var(--color-purple-600)}.text-purple-800{color:var(--color-purple-800)}.text-purple-900{color:var(--color-purple-900)}.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-white{color:var(--color-white)}.text-yellow-500{color:var(--color-yellow-500)}.text-yellow-800{color:var(--color-yellow-800)}.capitalize{text-transform:capitalize}.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,)}.line-through{text-decoration-line:line-through}.underline{text-decoration-line:underline}.underline-offset-4{text-underline-offset:4px}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-75{opacity:.75}.opacity-90{opacity:.9}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a)}.shadow,.shadow-\[0_0_0_1px_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-\[0_0_0_1px_hsl\(var\(--sidebar-border\)\)\]{--tw-shadow:0 0 0 1px var(--tw-shadow-color,hsl(var(--sidebar-border)))}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a)}.shadow-lg,.shadow-md{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)}.shadow-none{--tw-shadow:0 0 #0000}.shadow-none,.shadow-sm{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)}.shadow-xl{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a),0 8px 10px -6px var(--tw-shadow-color,#0000001a)}.shadow-xl,.shadow-xs{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)}.ring-0{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(0px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor)}.ring-0,.ring-2{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-2{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(2px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor)}.ring-blue-500{--tw-ring-color:var(--color-blue-500)}.ring-primary{--tw-ring-color:var(--primary)}.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}.grayscale{--tw-grayscale:grayscale(100%)}.filter,.grayscale{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\,height\]{transition-property:width,height;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-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}.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 *),.group-hover\:opacity-100:is(:where(.group):hover *){opacity:1}}.group-has-data-\[collapsible\=icon\]\/sidebar-wrapper\:h-12:is(:where(.group\/sidebar-wrapper):has([data-collapsible=icon]) *){height:calc(var(--spacing)*12)}.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-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] *){opacity:.5}.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-\[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}.group-\[\.destructive\]\:border-muted\/40:is(:where(.group).destructive *){border-color:var(--muted)}@supports (color:color-mix(in lab,red,red)){.group-\[\.destructive\]\:border-muted\/40:is(:where(.group).destructive *){border-color:color-mix(in oklab,var(--muted)40%,transparent)}}.group-\[\.destructive\]\:text-red-300:is(:where(.group).destructive *){color:var(--color-red-300)}@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{background-color:var(--primary)}.selection\:bg-primary::selection{background-color:var(--primary)}.selection\:text-primary-foreground ::selection{color:var(--primary-foreground)}.selection\:text-primary-foreground::selection{color:var(--primary-foreground)}.file\:mr-4::file-selector-button{margin-right:calc(var(--spacing)*4)}.file\:inline-flex::file-selector-button{display:inline-flex}.file\:h-7::file-selector-button{height:calc(var(--spacing)*7)}.file\:rounded-full::file-selector-button{border-radius:3.40282e+38px}.file\:border-0::file-selector-button{border-style:var(--tw-border-style);border-width:0}.file\:bg-blue-50::file-selector-button{background-color:var(--color-blue-50)}.file\:bg-transparent::file-selector-button{background-color:#0000}.file\:px-4::file-selector-button{padding-inline:calc(var(--spacing)*4)}.file\:py-2::file-selector-button{padding-block:calc(var(--spacing)*2)}.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\:font-semibold::file-selector-button{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.file\:text-blue-700::file-selector-button{color:var(--color-blue-700)}.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-0:after{content:var(--tw-content);inset:calc(var(--spacing)*0)}.after\:inset-y-0:after{content:var(--tw-content);inset-block:calc(var(--spacing)*0)}.after\:top-1\/2:after{content:var(--tw-content);top:50%}.after\:left-1\/2:after{content:var(--tw-content);left:50%}.after\:z-0:after{content:var(--tw-content);z-index:0}.after\:flex:after{content:var(--tw-content);display:flex}.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)}.after\:items-center:after{content:var(--tw-content);align-items:center}.after\:border-t:after{content:var(--tw-content);border-top-style:var(--tw-border-style);border-top-width:1px}.after\:border-border:after{content:var(--tw-content);border-color:var(--border)}.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\:rounded-r-md:last-child{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}@media (hover:hover){.hover\:border-green-400:hover{border-color:var(--color-green-400)}.hover\:border-orange-400:hover{border-color:var(--color-orange-400)}.hover\:bg-accent:hover{background-color:var(--accent)}.hover\:bg-blue-700:hover{background-color:var(--color-blue-700)}.hover\:bg-destructive\/80:hover{background-color:var(--destructive)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-destructive\/80:hover{background-color:color-mix(in oklab,var(--destructive)80%,transparent)}}.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-gray-100:hover{background-color:var(--color-gray-100)}.hover\:bg-green-500\/80:hover{background-color:#00c758cc}@supports (color:color-mix(in lab,red,red)){.hover\:bg-green-500\/80:hover{background-color:color-mix(in oklab,var(--color-green-500)80%,transparent)}}.hover\:bg-input\/30:hover{background-color:var(--input)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-input\/30:hover{background-color:color-mix(in oklab,var(--input)30%,transparent)}}.hover\:bg-muted:hover,.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\/80:hover{background-color:var(--primary)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-primary\/80:hover{background-color:color-mix(in oklab,var(--primary)80%,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-red-500\/80:hover{background-color:#fb2c36cc}@supports (color:color-mix(in lab,red,red)){.hover\:bg-red-500\/80:hover{background-color:color-mix(in oklab,var(--color-red-500)80%,transparent)}}.hover\:bg-secondary:hover,.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\:bg-transparent:hover{background-color:#0000}.hover\:bg-yellow-500\/80:hover{background-color:#edb200cc}@supports (color:color-mix(in lab,red,red)){.hover\:bg-yellow-500\/80:hover{background-color:color-mix(in oklab,var(--color-yellow-500)80%,transparent)}}.hover\:text-accent-foreground:hover{color:var(--accent-foreground)}.hover\:text-foreground:hover{color:var(--foreground)}.hover\:text-green-700:hover{color:var(--color-green-700)}.hover\:text-muted-foreground:hover{color:var(--muted-foreground)}.hover\:text-orange-700:hover{color:var(--color-orange-700)}.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)))}.hover\:shadow-\[0_0_0_1px_hsl\(var\(--sidebar-accent\)\)\]:hover,.hover\:shadow-md:hover{box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.hover\:shadow-md:hover{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a),0 2px 4px -2px var(--tw-shadow-color,#0000001a)}.hover\:group-data-\[collapsible\=offcanvas\]\:bg-sidebar:hover:is(:where(.group)[data-collapsible=offcanvas] *){background-color:var(--sidebar)}.group-\[\.destructive\]\:hover\:border-destructive\/30:is(:where(.group).destructive *):hover{border-color:var(--destructive)}@supports (color:color-mix(in lab,red,red)){.group-\[\.destructive\]\:hover\:border-destructive\/30:is(:where(.group).destructive *):hover{border-color:color-mix(in oklab,var(--destructive)30%,transparent)}}.group-\[\.destructive\]\:hover\:bg-destructive:is(:where(.group).destructive *):hover{background-color:var(--destructive)}.group-\[\.destructive\]\:hover\:text-red-50:is(:where(.group).destructive *):hover{color:var(--color-red-50)}.hover\:file\:bg-blue-100:hover::file-selector-button{background-color:var(--color-blue-100)}.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-destructive:focus{color:var(--destructive)}.focus\:text-green-700:focus{color:var(--color-green-700)}.focus\:text-orange-700:focus{color:var(--color-orange-700)}.focus\:opacity-100:focus{opacity:1}.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-primary\/20:focus{--tw-ring-color:var(--primary)}@supports (color:color-mix(in lab,red,red)){.focus\:ring-primary\/20:focus{--tw-ring-color:color-mix(in oklab,var(--primary)20%,transparent)}}.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\:outline-none:focus{--tw-outline-style:none;outline-style:none}.group-\[\.destructive\]\:focus\:ring-destructive:is(:where(.group).destructive *):focus{--tw-ring-color:var(--destructive)}.group-\[\.destructive\]\:focus\:ring-red-400:is(:where(.group).destructive *):focus{--tw-ring-color:var(--color-red-400)}.group-\[\.destructive\]\:focus\:ring-offset-red-600:is(:where(.group).destructive *):focus{--tw-ring-offset-color:var(--color-red-600)}.focus-visible\:z-10:focus-visible{z-index:10}.focus-visible\:border:focus-visible{border-style:var(--tw-border-style);border-width:1px}.focus-visible\:border-ring:focus-visible{border-color:var(--ring)}.focus-visible\:bg-background:focus-visible{background-color:var(--background)}.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-\[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\/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\: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)}.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-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-\[variant\=inset\]\:bg-sidebar:has([data-variant=inset]){background-color:var(--sidebar)}.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\]\: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)}.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)}}.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-\[dragging\=true\]\:z-10[data-dragging=true]{z-index:10}.data-\[dragging\=true\]\:opacity-80[data-dragging=true]{opacity:.8}.data-\[error\=true\]\:text-destructive[data-error=true]{color:var(--destructive)}.data-\[inset\]\:pl-8[data-inset]{padding-left:calc(var(--spacing)*8)}.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-px[data-orientation=horizontal]{height:1px}.data-\[orientation\=horizontal\]\:w-full[data-orientation=horizontal]{width:100%}.data-\[orientation\=vertical\]\:h-4[data-orientation=vertical]{height:calc(var(--spacing)*4)}.data-\[orientation\=vertical\]\:h-full[data-orientation=vertical]{height:100%}.data-\[orientation\=vertical\]\:w-px[data-orientation=vertical]{width:1px}.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-\[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)}}:is(.\*\:data-\[slot\=card\]\:bg-gradient-to-t>*)[data-slot=card]{--tw-gradient-position:to top in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}:is(.\*\:data-\[slot\=card\]\:from-primary\/5>*)[data-slot=card]{--tw-gradient-from:var(--primary)}@supports (color:color-mix(in lab,red,red)){:is(.\*\:data-\[slot\=card\]\:from-primary\/5>*)[data-slot=card]{--tw-gradient-from:color-mix(in oklab,var(--primary)5%,transparent)}}:is(.\*\:data-\[slot\=card\]\:from-primary\/5>*)[data-slot=card]{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}:is(.\*\:data-\[slot\=card\]\:to-card>*)[data-slot=card]{--tw-gradient-to:var(--card);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}:is(.\*\:data-\[slot\=card\]\:shadow-xs>*)[data-slot=card]{--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)}: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-\[slot\=sidebar-menu-button\]\:\!p-1\.5[data-slot=sidebar-menu-button]{padding:calc(var(--spacing)*1.5)!important}:is(.\*\*\:data-\[slot\=table-cell\]\:first\:w-8 *)[data-slot=table-cell]:first-child{width:calc(var(--spacing)*8)}.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-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\]\:fade-out-80[data-state=closed]{--tw-exit-opacity:.8}.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-right-full[data-state=closed]{--tw-exit-translate-x:calc(1*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-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-muted[data-state=open]{background-color:var(--muted)}.data-\[state\=open\]\:bg-secondary[data-state=open]{background-color:var(--secondary)}.data-\[state\=open\]\:bg-sidebar-accent[data-state=open]{background-color:var(--sidebar-accent)}.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\]\:text-sidebar-accent-foreground[data-state=open]{color:var(--sidebar-accent-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%}.data-\[state\=open\]\:slide-in-from-top-full[data-state=open]{--tw-enter-translate-y:calc(1*-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-\[swipe\=cancel\]\:translate-x-0[data-swipe=cancel]{--tw-translate-x:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[swipe\=end\]\:translate-x-\[var\(--radix-toast-swipe-end-x\)\][data-swipe=end]{--tw-translate-x:var(--radix-toast-swipe-end-x);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[swipe\=end\]\:animate-out[data-swipe=end]{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-\[swipe\=move\]\:translate-x-\[var\(--radix-toast-swipe-move-x\)\][data-swipe=move]{--tw-translate-x:var(--radix-toast-swipe-move-x);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[swipe\=move\]\:transition-none[data-swipe=move]{transition-property:none}.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\=outline\]\:border-l-0[data-variant=outline]{border-left-style:var(--tw-border-style);border-left-width:0}.data-\[variant\=outline\]\:shadow-xs[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-\[variant\=outline\]\:first\:border-l[data-variant=outline]:first-child{border-left-style:var(--tw-border-style);border-left-width:1px}@media (min-width:40rem){.sm\:top-auto{top:auto}.sm\:right-0{right:calc(var(--spacing)*0)}.sm\:bottom-0{bottom:calc(var(--spacing)*0)}.sm\:ml-2{margin-left:calc(var(--spacing)*2)}.sm\:flex{display:flex}.sm\:hidden{display:none}.sm\:inline{display:inline}.sm\:h-4{height:calc(var(--spacing)*4)}.sm\:w-4{width:calc(var(--spacing)*4)}.sm\:w-64{width:calc(var(--spacing)*64)}.sm\:w-\[180px\]{width:180px}.sm\:w-auto{width:auto}.sm\:max-w-\[500px\]{max-width:500px}.sm\:max-w-\[600px\]{max-width:600px}.sm\:max-w-\[700px\]{max-width:700px}.sm\:max-w-lg{max-width:var(--container-lg)}.sm\:max-w-md{max-width:var(--container-md)}.sm\:max-w-none{max-width:none}.sm\:max-w-sm{max-width:var(--container-sm)}.sm\:max-w-xl{max-width:var(--container-xl)}.sm\:flex-initial{flex:0 auto}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\:flex-col{flex-direction:column}.sm\:flex-row{flex-direction:row}.sm\:flex-nowrap{flex-wrap:nowrap}.sm\:items-center{align-items:center}.sm\:items-start{align-items:flex-start}.sm\:justify-between{justify-content:space-between}.sm\:justify-end{justify-content:flex-end}.sm\:gap-2{gap:calc(var(--spacing)*2)}.sm\:gap-3{gap:calc(var(--spacing)*3)}:where(.sm\:space-x-0>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*0)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*0)*calc(1 - var(--tw-space-x-reverse)))}.sm\:px-6{padding-inline:calc(var(--spacing)*6)}.sm\:pt-6{padding-top:calc(var(--spacing)*6)}.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-\[state\=open\]\:sm\:slide-in-from-bottom-full[data-state=open]{--tw-enter-translate-y:calc(1*100%)}}@media (min-width:48rem){.md\:absolute{position:absolute}.md\:block{display:block}.md\:flex{display:flex}.md\:grid{display:grid}.md\:hidden{display:none}.md\:w-\[var\(--radix-navigation-menu-viewport-width\)\]{width:var(--radix-navigation-menu-viewport-width)}.md\:w-auto{width:auto}.md\:max-w-\[420px\]{max-width:420px}.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\:gap-8{gap:calc(var(--spacing)*8)}.md\:p-8{padding:calc(var(--spacing)*8)}.md\:px-6{padding-inline:calc(var(--spacing)*6)}.md\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--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\:ml-0{margin-left:calc(var(--spacing)*0)}.lg\:flex{display:flex}.lg\:hidden{display:none}.lg\:inline{display:inline}.lg\:w-fit{width:fit-content}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.lg\:gap-2{gap:calc(var(--spacing)*2)}.lg\:px-6{padding-inline:calc(var(--spacing)*6)}.lg\:px-8{padding-inline:calc(var(--spacing)*8)}}@container card (min-width:250px){.\@\[250px\]\/card\:text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}}@container card (min-width:540px){.\@\[540px\]\/card\:block{display:block}.\@\[540px\]\/card\:hidden{display:none}}@container card (min-width:767px){.\@\[767px\]\/card\:flex{display:flex}.\@\[767px\]\/card\:hidden{display:none}}@container main (min-width:36rem){.\@xl\/main\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@container main (min-width:56rem){.\@4xl\/main\:flex{display:flex}.\@4xl\/main\:hidden{display:none}}@container main (min-width:64rem){.\@5xl\/main\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}}.dark\:scale-0:is(.dark *){--tw-scale-x:0%;--tw-scale-y:0%;--tw-scale-z:0%;scale:var(--tw-scale-x)var(--tw-scale-y)}.dark\:scale-100:is(.dark *){--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x)var(--tw-scale-y)}.dark\:-rotate-90:is(.dark *){rotate:-90deg}.dark\:rotate-0:is(.dark *){rotate:none}.dark\:border-green-800:is(.dark *){border-color:var(--color-green-800)}.dark\:border-input:is(.dark *){border-color:var(--input)}.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-green-950:is(.dark *){background-color:var(--color-green-950)}.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\:text-green-100:is(.dark *){color:var(--color-green-100)}.dark\:text-green-400:is(.dark *){color:var(--color-green-400)}.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\: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\: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)}}:is(.dark\:\*\:data-\[slot\=card\]\:bg-card:is(.dark *)>*)[data-slot=card]{background-color:var(--card)}.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)}.\[\&_a\]\:underline a{text-decoration-line:underline}.\[\&_a\]\:underline-offset-4 a{text-underline-offset:4px}@media (hover:hover){.hover\:\[\&_a\]\:text-primary:hover a{color:var(--primary)}}.\[\&_p\]\:leading-relaxed p{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}.\[\&_svg\]\:pointer-events-none svg{pointer-events:none}.\[\&_svg\]\:size-3 svg{width:calc(var(--spacing)*3);height:calc(var(--spacing)*3)}.\[\&_svg\]\:shrink-0 svg{flex-shrink:0}.\[\&_svg\:not\(\[class\*\=\'size-\'\]\)\]\:size-4 svg:not([class*=size-]){width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.\[\&_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}.\[\&\:has\(\[role\=checkbox\]\)\]\:pr-0:has([role=checkbox]){padding-right:calc(var(--spacing)*0)}.\[\.border-b\]\:pb-6.border-b{padding-bottom:calc(var(--spacing)*6)}.\[\.border-t\]\:pt-6.border-t{padding-top:calc(var(--spacing)*6)}: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}.\[\&\>\[role\=checkbox\]\]\:translate-y-\[2px\]>[role=checkbox]{--tw-translate-y:2px;translate:var(--tw-translate-x)var(--tw-translate-y)}.\[\&\>button\]\:hidden>button{display:none}.\[\&\>span\:last-child\]\:truncate>span:last-child{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.\[\&\>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)}.\[\&\>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-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}}@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:oklch(100% 0 0);--foreground:oklch(14.7% .004 49.25);--card:oklch(100% 0 0);--card-foreground:oklch(14.7% .004 49.25);--popover:oklch(100% 0 0);--popover-foreground:oklch(14.7% .004 49.25);--primary:oklch(21.6% .006 56.043);--primary-foreground:oklch(98.5% .001 106.423);--secondary:oklch(97% .001 106.424);--secondary-foreground:oklch(21.6% .006 56.043);--muted:oklch(97% .001 106.424);--muted-foreground:oklch(55.3% .013 58.071);--accent:oklch(97% .001 106.424);--accent-foreground:oklch(21.6% .006 56.043);--destructive:oklch(57.7% .245 27.325);--border:oklch(92.3% .003 48.717);--input:oklch(92.3% .003 48.717);--ring:oklch(70.9% .01 56.259);--chart-1:oklch(64.6% .222 41.116);--chart-2:oklch(60% .118 184.704);--chart-3:oklch(39.8% .07 227.392);--chart-4:oklch(82.8% .189 84.429);--chart-5:oklch(76.9% .188 70.08);--sidebar:oklch(98.5% .001 106.423);--sidebar-foreground:oklch(14.7% .004 49.25);--sidebar-primary:oklch(21.6% .006 56.043);--sidebar-primary-foreground:oklch(98.5% .001 106.423);--sidebar-accent:oklch(97% .001 106.424);--sidebar-accent-foreground:oklch(21.6% .006 56.043);--sidebar-border:oklch(92.3% .003 48.717);--sidebar-ring:oklch(70.9% .01 56.259)}.dark{--background:oklch(14.7% .004 49.25);--foreground:oklch(98.5% .001 106.423);--card:oklch(21.6% .006 56.043);--card-foreground:oklch(98.5% .001 106.423);--popover:oklch(21.6% .006 56.043);--popover-foreground:oklch(98.5% .001 106.423);--primary:oklch(92.3% .003 48.717);--primary-foreground:oklch(21.6% .006 56.043);--secondary:oklch(26.8% .007 34.298);--secondary-foreground:oklch(98.5% .001 106.423);--muted:oklch(26.8% .007 34.298);--muted-foreground:oklch(70.9% .01 56.259);--accent:oklch(26.8% .007 34.298);--accent-foreground:oklch(98.5% .001 106.423);--destructive:oklch(70.4% .191 22.216);--border:oklch(100% 0 0/.1);--input:oklch(100% 0 0/.15);--ring:oklch(55.3% .013 58.071);--chart-1:oklch(48.8% .243 264.376);--chart-2:oklch(69.6% .17 162.48);--chart-3:oklch(76.9% .188 70.08);--chart-4:oklch(62.7% .265 303.9);--chart-5:oklch(64.5% .246 16.439);--sidebar:oklch(21.6% .006 56.043);--sidebar-foreground:oklch(98.5% .001 106.423);--sidebar-primary:oklch(48.8% .243 264.376);--sidebar-primary-foreground:oklch(98.5% .001 106.423);--sidebar-accent:oklch(26.8% .007 34.298);--sidebar-accent-foreground:oklch(98.5% .001 106.423);--sidebar-border:oklch(100% 0 0/.1);--sidebar-ring:oklch(55.3% .013 58.071)}@keyframes shimmer{0%{transform:translate(-100%)}to{transform:translate(100%)}}.animate-shimmer{animation:shimmer 2s infinite}@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-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@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-gradient-position{syntax:"*";inherits:false}@property --tw-gradient-from{syntax:"";inherits:false;initial-value:#0000}@property --tw-gradient-via{syntax:"";inherits:false;initial-value:#0000}@property --tw-gradient-to{syntax:"";inherits:false;initial-value:#0000}@property --tw-gradient-stops{syntax:"*";inherits:false}@property --tw-gradient-via-stops{syntax:"*";inherits:false}@property --tw-gradient-from-position{syntax:"";inherits:false;initial-value:0}@property --tw-gradient-via-position{syntax:"";inherits:false;initial-value:50%}@property --tw-gradient-to-position{syntax:"";inherits:false;initial-value:100%}@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(1turn)}}@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 caret-blink{0%,70%,to{opacity:1}20%,50%{opacity:0}} \ No newline at end of file diff --git a/ui_out/index.html b/ui_out/index.html index 64d5c074..9873ae62 100644 --- a/ui_out/index.html +++ b/ui_out/index.html @@ -1 +1 @@ -Routstr

Routstr

Admin Dashboard

Monitor and manage wallet balances

Cashu Wallet Balance
Detailed balance breakdown by mint and currency
Temporary Balances
API keys with their current balances and usage statistics
\ No newline at end of file + \ No newline at end of file diff --git a/ui_out/index.txt b/ui_out/index.txt index 5f91d5dc..b730a5af 100644 --- a/ui_out/index.txt +++ b/ui_out/index.txt @@ -1,28 +1,29 @@ 1:"$Sreact.fragment" -2:I[5414,["363","static/chunks/363-119b32fca35baa33.js","29","static/chunks/29-e3557fb1dd82bdc3.js","578","static/chunks/578-9e08cd45b1eda688.js","177","static/chunks/app/layout-1e4148ea2d359141.js"],"Providers"] -3:I[8754,[],""] -4:I[768,[],""] -5:I[953,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","29","static/chunks/29-e3557fb1dd82bdc3.js","730","static/chunks/730-892209af1fa345bd.js","978","static/chunks/978-cd938190a9f5efa7.js","481","static/chunks/481-48cd0f8fe547e418.js","236","static/chunks/236-d1820fdf10fbc413.js","601","static/chunks/601-bd77b408e968f9da.js","974","static/chunks/app/page-cf122f9b514899ca.js"],"SidebarProvider"] -6:I[7569,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","29","static/chunks/29-e3557fb1dd82bdc3.js","730","static/chunks/730-892209af1fa345bd.js","978","static/chunks/978-cd938190a9f5efa7.js","481","static/chunks/481-48cd0f8fe547e418.js","236","static/chunks/236-d1820fdf10fbc413.js","601","static/chunks/601-bd77b408e968f9da.js","974","static/chunks/app/page-cf122f9b514899ca.js"],"AppSidebar"] -7:I[953,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","29","static/chunks/29-e3557fb1dd82bdc3.js","730","static/chunks/730-892209af1fa345bd.js","978","static/chunks/978-cd938190a9f5efa7.js","481","static/chunks/481-48cd0f8fe547e418.js","236","static/chunks/236-d1820fdf10fbc413.js","601","static/chunks/601-bd77b408e968f9da.js","974","static/chunks/app/page-cf122f9b514899ca.js"],"SidebarInset"] -8:I[4756,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","29","static/chunks/29-e3557fb1dd82bdc3.js","730","static/chunks/730-892209af1fa345bd.js","978","static/chunks/978-cd938190a9f5efa7.js","481","static/chunks/481-48cd0f8fe547e418.js","236","static/chunks/236-d1820fdf10fbc413.js","601","static/chunks/601-bd77b408e968f9da.js","974","static/chunks/app/page-cf122f9b514899ca.js"],"SiteHeader"] -9:I[159,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","29","static/chunks/29-e3557fb1dd82bdc3.js","730","static/chunks/730-892209af1fa345bd.js","978","static/chunks/978-cd938190a9f5efa7.js","481","static/chunks/481-48cd0f8fe547e418.js","236","static/chunks/236-d1820fdf10fbc413.js","601","static/chunks/601-bd77b408e968f9da.js","974","static/chunks/app/page-cf122f9b514899ca.js"],"DetailedWalletBalance"] -a:I[2483,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","29","static/chunks/29-e3557fb1dd82bdc3.js","730","static/chunks/730-892209af1fa345bd.js","978","static/chunks/978-cd938190a9f5efa7.js","481","static/chunks/481-48cd0f8fe547e418.js","236","static/chunks/236-d1820fdf10fbc413.js","601","static/chunks/601-bd77b408e968f9da.js","974","static/chunks/app/page-cf122f9b514899ca.js"],"TemporaryBalances"] -b:I[4826,[],"MetadataBoundary"] -d:I[4826,[],"OutletBoundary"] -10:I[394,[],"AsyncMetadataOutlet"] -12:I[4826,[],"ViewportBoundary"] -14:I[6613,[],""] +2:I[8748,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"SuppressHydrationWarning"] +3:I[7895,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"Providers"] +4:I[8754,[],""] +5:I[768,[],""] +6:I[953,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","29","static/chunks/29-2e340e48c1ca61fb.js","730","static/chunks/730-eb609e4385533b6b.js","978","static/chunks/978-960e423dcb2d179d.js","481","static/chunks/481-7440db9fd9bb94b2.js","900","static/chunks/900-4ce6a1afa7029035.js","601","static/chunks/601-3f92835872ce1c3b.js","974","static/chunks/app/page-3876b4fb2023557a.js"],"SidebarProvider"] +7:I[7569,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","29","static/chunks/29-2e340e48c1ca61fb.js","730","static/chunks/730-eb609e4385533b6b.js","978","static/chunks/978-960e423dcb2d179d.js","481","static/chunks/481-7440db9fd9bb94b2.js","900","static/chunks/900-4ce6a1afa7029035.js","601","static/chunks/601-3f92835872ce1c3b.js","974","static/chunks/app/page-3876b4fb2023557a.js"],"AppSidebar"] +8:I[953,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","29","static/chunks/29-2e340e48c1ca61fb.js","730","static/chunks/730-eb609e4385533b6b.js","978","static/chunks/978-960e423dcb2d179d.js","481","static/chunks/481-7440db9fd9bb94b2.js","900","static/chunks/900-4ce6a1afa7029035.js","601","static/chunks/601-3f92835872ce1c3b.js","974","static/chunks/app/page-3876b4fb2023557a.js"],"SidebarInset"] +9:I[532,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","29","static/chunks/29-2e340e48c1ca61fb.js","730","static/chunks/730-eb609e4385533b6b.js","978","static/chunks/978-960e423dcb2d179d.js","481","static/chunks/481-7440db9fd9bb94b2.js","900","static/chunks/900-4ce6a1afa7029035.js","601","static/chunks/601-3f92835872ce1c3b.js","974","static/chunks/app/page-3876b4fb2023557a.js"],"SiteHeader"] +a:I[159,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","29","static/chunks/29-2e340e48c1ca61fb.js","730","static/chunks/730-eb609e4385533b6b.js","978","static/chunks/978-960e423dcb2d179d.js","481","static/chunks/481-7440db9fd9bb94b2.js","900","static/chunks/900-4ce6a1afa7029035.js","601","static/chunks/601-3f92835872ce1c3b.js","974","static/chunks/app/page-3876b4fb2023557a.js"],"DetailedWalletBalance"] +b:I[2483,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","29","static/chunks/29-2e340e48c1ca61fb.js","730","static/chunks/730-eb609e4385533b6b.js","978","static/chunks/978-960e423dcb2d179d.js","481","static/chunks/481-7440db9fd9bb94b2.js","900","static/chunks/900-4ce6a1afa7029035.js","601","static/chunks/601-3f92835872ce1c3b.js","974","static/chunks/app/page-3876b4fb2023557a.js"],"TemporaryBalances"] +c:I[4826,[],"MetadataBoundary"] +e:I[4826,[],"OutletBoundary"] +11:I[394,[],"AsyncMetadataOutlet"] +13:I[4826,[],"ViewportBoundary"] +15:I[6613,[],""] :HL["/_next/static/media/4cf2300e9c8272f7-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/media/93f479601ee12b01-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/css/de70bee13400563f.css","style"] -:HL["/_next/static/css/2dee0244dc7d99bd.css","style"] -0:{"P":null,"b":"4bJrP3zJGhvVQWjndHhpS","p":"","c":["",""],"i":false,"f":[[["",{"children":["__PAGE__",{}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/2dee0244dc7d99bd.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L5",null,{"children":[["$","$L6",null,{"variant":"inset"}],["$","$L7",null,{"className":"p-0","children":[["$","$L8",null,{}],["$","div",null,{"className":"container max-w-6xl px-4 py-8 md:px-6 lg:px-8","children":[["$","div",null,{"className":"mb-8","children":[["$","h1",null,{"className":"text-3xl font-bold tracking-tight","children":"Admin Dashboard"}],["$","p",null,{"className":"text-muted-foreground mt-2","children":"Monitor and manage wallet balances"}]]}],["$","div",null,{"className":"grid gap-6","children":[["$","div",null,{"className":"col-span-full","children":["$","$L9",null,{"refreshInterval":5000}]}],["$","div",null,{"className":"col-span-full","children":["$","$La",null,{"refreshInterval":10000}]}]]}]]}]]}]]}],["$","$Lb",null,{"children":"$Lc"}],null,["$","$Ld",null,{"children":["$Le","$Lf",["$","$L10",null,{"promise":"$@11"}]]}]]}],{},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","cEgtAAVDC5CV7Ay82-7rS",{"children":[["$","$L12",null,{"children":"$L13"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$14","$undefined"],"s":false,"S":true} -15:"$Sreact.suspense" -16:I[394,[],"AsyncMetadata"] -c:["$","$15",null,{"fallback":null,"children":["$","$L16",null,{"promise":"$@17"}]}] +:HL["/_next/static/css/a2fcfb52b8f42d80.css","style"] +0:{"P":null,"b":"6UzBhGpyRdJjWoKvuuFgP","p":"","c":["",""],"i":false,"f":[[["",{"children":["__PAGE__",{}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/a2fcfb52b8f42d80.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","suppressHydrationWarning":true,"children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"children":["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L6",null,{"children":[["$","$L7",null,{"variant":"inset"}],["$","$L8",null,{"className":"p-0","children":[["$","$L9",null,{}],["$","div",null,{"className":"container max-w-6xl px-4 py-8 md:px-6 lg:px-8","children":[["$","div",null,{"className":"mb-8","children":[["$","h1",null,{"className":"text-3xl font-bold tracking-tight","children":"Admin Dashboard"}],["$","p",null,{"className":"text-muted-foreground mt-2","children":"Monitor and manage wallet balances"}]]}],["$","div",null,{"className":"grid gap-6","children":[["$","div",null,{"className":"col-span-full","children":["$","$La",null,{"refreshInterval":5000}]}],["$","div",null,{"className":"col-span-full","children":["$","$Lb",null,{"refreshInterval":10000}]}]]}]]}]]}]]}],["$","$Lc",null,{"children":"$Ld"}],null,["$","$Le",null,{"children":["$Lf","$L10",["$","$L11",null,{"promise":"$@12"}]]}]]}],{},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","cp8Lf9ddLwvBdmRWrEuSL",{"children":[["$","$L13",null,{"children":"$L14"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$15","$undefined"],"s":false,"S":true} +16:"$Sreact.suspense" +17:I[394,[],"AsyncMetadata"] +d:["$","$16",null,{"fallback":null,"children":["$","$L17",null,{"promise":"$@18"}]}] +10:null +14:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] f:null -13:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] -e:null -17:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} -11:{"metadata":"$17:metadata","error":null,"digest":"$undefined"} +18:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} +12:{"metadata":"$18:metadata","error":null,"digest":"$undefined"} diff --git a/ui_out/login/index.html b/ui_out/login/index.html index 6ea1db28..5d7032bb 100644 --- a/ui_out/login/index.html +++ b/ui_out/login/index.html @@ -1 +1 @@ -Routstr
Admin Login
Enter your admin password to access the dashboard
\ No newline at end of file + \ No newline at end of file diff --git a/ui_out/login/index.txt b/ui_out/login/index.txt index 5baf2dc6..1b896637 100644 --- a/ui_out/login/index.txt +++ b/ui_out/login/index.txt @@ -1,26 +1,27 @@ 1:"$Sreact.fragment" -2:I[5414,["363","static/chunks/363-119b32fca35baa33.js","29","static/chunks/29-e3557fb1dd82bdc3.js","578","static/chunks/578-9e08cd45b1eda688.js","177","static/chunks/app/layout-1e4148ea2d359141.js"],"Providers"] -3:I[8754,[],""] -4:I[768,[],""] -5:I[3971,[],"ClientPageRoot"] -6:I[9079,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","520","static/chunks/app/login/page-9d2abe7b74a0707f.js"],"default"] -9:I[4826,[],"MetadataBoundary"] -b:I[4826,[],"OutletBoundary"] -e:I[394,[],"AsyncMetadataOutlet"] -10:I[4826,[],"ViewportBoundary"] -12:I[6613,[],""] +2:I[8748,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"SuppressHydrationWarning"] +3:I[7895,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"Providers"] +4:I[8754,[],""] +5:I[768,[],""] +6:I[3971,[],"ClientPageRoot"] +7:I[9079,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","520","static/chunks/app/login/page-603b845ae6bd54c9.js"],"default"] +a:I[4826,[],"MetadataBoundary"] +c:I[4826,[],"OutletBoundary"] +f:I[394,[],"AsyncMetadataOutlet"] +11:I[4826,[],"ViewportBoundary"] +13:I[6613,[],""] :HL["/_next/static/media/4cf2300e9c8272f7-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/media/93f479601ee12b01-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/css/de70bee13400563f.css","style"] -:HL["/_next/static/css/2dee0244dc7d99bd.css","style"] -0:{"P":null,"b":"4bJrP3zJGhvVQWjndHhpS","p":"","c":["","login",""],"i":false,"f":[[["",{"children":["login",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/2dee0244dc7d99bd.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]]}],{"children":["login",["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L5",null,{"Component":"$6","searchParams":{},"params":{},"promises":["$@7","$@8"]}],["$","$L9",null,{"children":"$La"}],null,["$","$Lb",null,{"children":["$Lc","$Ld",["$","$Le",null,{"promise":"$@f"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","JRij8gy-wbUVJvu7U2oPb",{"children":[["$","$L10",null,{"children":"$L11"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$12","$undefined"],"s":false,"S":true} -13:"$Sreact.suspense" -14:I[394,[],"AsyncMetadata"] -7:{} +:HL["/_next/static/css/a2fcfb52b8f42d80.css","style"] +0:{"P":null,"b":"6UzBhGpyRdJjWoKvuuFgP","p":"","c":["","login",""],"i":false,"f":[[["",{"children":["login",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/a2fcfb52b8f42d80.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","suppressHydrationWarning":true,"children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"children":["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]}]]}],{"children":["login",["$","$1","c",{"children":[null,["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L6",null,{"Component":"$7","searchParams":{},"params":{},"promises":["$@8","$@9"]}],["$","$La",null,{"children":"$Lb"}],null,["$","$Lc",null,{"children":["$Ld","$Le",["$","$Lf",null,{"promise":"$@10"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","DwhzpJZp87NqNWUfhSxXx",{"children":[["$","$L11",null,{"children":"$L12"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$13","$undefined"],"s":false,"S":true} +14:"$Sreact.suspense" +15:I[394,[],"AsyncMetadata"] 8:{} -a:["$","$13",null,{"fallback":null,"children":["$","$L14",null,{"promise":"$@15"}]}] +9:{} +b:["$","$14",null,{"fallback":null,"children":["$","$L15",null,{"promise":"$@16"}]}] +e:null +12:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] d:null -11:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] -c:null -15:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} -f:{"metadata":"$15:metadata","error":null,"digest":"$undefined"} +16:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} +10:{"metadata":"$16:metadata","error":null,"digest":"$undefined"} diff --git a/ui_out/model/index.html b/ui_out/model/index.html index ab9e9a4d..322fc59d 100644 --- a/ui_out/model/index.html +++ b/ui_out/model/index.html @@ -1 +1 @@ -Routstr

Routstr

Model Management & API Testing

Manage your AI models organized by provider groups. Configure API keys, and organize models by provider groups.
\ No newline at end of file + \ No newline at end of file diff --git a/ui_out/model/index.txt b/ui_out/model/index.txt index 19b94d8e..1cd2cff1 100644 --- a/ui_out/model/index.txt +++ b/ui_out/model/index.txt @@ -1,26 +1,27 @@ 1:"$Sreact.fragment" -2:I[5414,["363","static/chunks/363-119b32fca35baa33.js","29","static/chunks/29-e3557fb1dd82bdc3.js","578","static/chunks/578-9e08cd45b1eda688.js","177","static/chunks/app/layout-1e4148ea2d359141.js"],"Providers"] -3:I[8754,[],""] -4:I[768,[],""] -5:I[3971,[],"ClientPageRoot"] -6:I[7678,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","29","static/chunks/29-e3557fb1dd82bdc3.js","730","static/chunks/730-892209af1fa345bd.js","978","static/chunks/978-cd938190a9f5efa7.js","481","static/chunks/481-48cd0f8fe547e418.js","982","static/chunks/982-5588ad0e30e6255e.js","826","static/chunks/826-c15935d1c2416e5d.js","236","static/chunks/236-d1820fdf10fbc413.js","601","static/chunks/601-bd77b408e968f9da.js","552","static/chunks/app/model/page-8be1c146fd1f0602.js"],"default"] -9:I[4826,[],"MetadataBoundary"] -b:I[4826,[],"OutletBoundary"] -e:I[394,[],"AsyncMetadataOutlet"] -10:I[4826,[],"ViewportBoundary"] -12:I[6613,[],""] +2:I[8748,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"SuppressHydrationWarning"] +3:I[7895,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"Providers"] +4:I[8754,[],""] +5:I[768,[],""] +6:I[3971,[],"ClientPageRoot"] +7:I[7678,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","29","static/chunks/29-2e340e48c1ca61fb.js","730","static/chunks/730-eb609e4385533b6b.js","978","static/chunks/978-960e423dcb2d179d.js","481","static/chunks/481-7440db9fd9bb94b2.js","982","static/chunks/982-dc9d2de6dd23b183.js","826","static/chunks/826-03658aa28a2a895d.js","900","static/chunks/900-4ce6a1afa7029035.js","601","static/chunks/601-3f92835872ce1c3b.js","552","static/chunks/app/model/page-862224df2a15ab65.js"],"default"] +a:I[4826,[],"MetadataBoundary"] +c:I[4826,[],"OutletBoundary"] +f:I[394,[],"AsyncMetadataOutlet"] +11:I[4826,[],"ViewportBoundary"] +13:I[6613,[],""] :HL["/_next/static/media/4cf2300e9c8272f7-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/media/93f479601ee12b01-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/css/de70bee13400563f.css","style"] -:HL["/_next/static/css/2dee0244dc7d99bd.css","style"] -0:{"P":null,"b":"4bJrP3zJGhvVQWjndHhpS","p":"","c":["","model",""],"i":false,"f":[[["",{"children":["model",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/2dee0244dc7d99bd.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]]}],{"children":["model",["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L5",null,{"Component":"$6","searchParams":{},"params":{},"promises":["$@7","$@8"]}],["$","$L9",null,{"children":"$La"}],null,["$","$Lb",null,{"children":["$Lc","$Ld",["$","$Le",null,{"promise":"$@f"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","0FqHPIdeK-6v6UK3aOKPM",{"children":[["$","$L10",null,{"children":"$L11"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$12","$undefined"],"s":false,"S":true} -13:"$Sreact.suspense" -14:I[394,[],"AsyncMetadata"] -7:{} +:HL["/_next/static/css/a2fcfb52b8f42d80.css","style"] +0:{"P":null,"b":"6UzBhGpyRdJjWoKvuuFgP","p":"","c":["","model",""],"i":false,"f":[[["",{"children":["model",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/a2fcfb52b8f42d80.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","suppressHydrationWarning":true,"children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"children":["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]}]]}],{"children":["model",["$","$1","c",{"children":[null,["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L6",null,{"Component":"$7","searchParams":{},"params":{},"promises":["$@8","$@9"]}],["$","$La",null,{"children":"$Lb"}],null,["$","$Lc",null,{"children":["$Ld","$Le",["$","$Lf",null,{"promise":"$@10"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","Z8BLDBXXUzAH4PRhY-CS8",{"children":[["$","$L11",null,{"children":"$L12"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$13","$undefined"],"s":false,"S":true} +14:"$Sreact.suspense" +15:I[394,[],"AsyncMetadata"] 8:{} -a:["$","$13",null,{"fallback":null,"children":["$","$L14",null,{"promise":"$@15"}]}] +9:{} +b:["$","$14",null,{"fallback":null,"children":["$","$L15",null,{"promise":"$@16"}]}] +e:null +12:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] d:null -11:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] -c:null -15:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} -f:{"metadata":"$15:metadata","error":null,"digest":"$undefined"} +16:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} +10:{"metadata":"$16:metadata","error":null,"digest":"$undefined"} diff --git a/ui_out/providers/index.html b/ui_out/providers/index.html index 0c315450..24e2cc84 100644 --- a/ui_out/providers/index.html +++ b/ui_out/providers/index.html @@ -1 +1 @@ -Routstr

Routstr

Upstream Providers

Manage your AI provider connections and credentials

\ No newline at end of file + \ No newline at end of file diff --git a/ui_out/providers/index.txt b/ui_out/providers/index.txt index bdb061f9..67864e8c 100644 --- a/ui_out/providers/index.txt +++ b/ui_out/providers/index.txt @@ -1,26 +1,27 @@ 1:"$Sreact.fragment" -2:I[5414,["363","static/chunks/363-119b32fca35baa33.js","29","static/chunks/29-e3557fb1dd82bdc3.js","578","static/chunks/578-9e08cd45b1eda688.js","177","static/chunks/app/layout-1e4148ea2d359141.js"],"Providers"] -3:I[8754,[],""] -4:I[768,[],""] -5:I[3971,[],"ClientPageRoot"] -6:I[8288,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","29","static/chunks/29-e3557fb1dd82bdc3.js","730","static/chunks/730-892209af1fa345bd.js","978","static/chunks/978-cd938190a9f5efa7.js","481","static/chunks/481-48cd0f8fe547e418.js","982","static/chunks/982-5588ad0e30e6255e.js","236","static/chunks/236-d1820fdf10fbc413.js","601","static/chunks/601-bd77b408e968f9da.js","387","static/chunks/app/providers/page-24027db6adfd0b9b.js"],"default"] -9:I[4826,[],"MetadataBoundary"] -b:I[4826,[],"OutletBoundary"] -e:I[394,[],"AsyncMetadataOutlet"] -10:I[4826,[],"ViewportBoundary"] -12:I[6613,[],""] +2:I[8748,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"SuppressHydrationWarning"] +3:I[7895,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"Providers"] +4:I[8754,[],""] +5:I[768,[],""] +6:I[3971,[],"ClientPageRoot"] +7:I[8288,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","29","static/chunks/29-2e340e48c1ca61fb.js","730","static/chunks/730-eb609e4385533b6b.js","978","static/chunks/978-960e423dcb2d179d.js","481","static/chunks/481-7440db9fd9bb94b2.js","982","static/chunks/982-dc9d2de6dd23b183.js","900","static/chunks/900-4ce6a1afa7029035.js","601","static/chunks/601-3f92835872ce1c3b.js","387","static/chunks/app/providers/page-d7c9b193573b160c.js"],"default"] +a:I[4826,[],"MetadataBoundary"] +c:I[4826,[],"OutletBoundary"] +f:I[394,[],"AsyncMetadataOutlet"] +11:I[4826,[],"ViewportBoundary"] +13:I[6613,[],""] :HL["/_next/static/media/4cf2300e9c8272f7-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/media/93f479601ee12b01-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/css/de70bee13400563f.css","style"] -:HL["/_next/static/css/2dee0244dc7d99bd.css","style"] -0:{"P":null,"b":"4bJrP3zJGhvVQWjndHhpS","p":"","c":["","providers",""],"i":false,"f":[[["",{"children":["providers",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/2dee0244dc7d99bd.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]]}],{"children":["providers",["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L5",null,{"Component":"$6","searchParams":{},"params":{},"promises":["$@7","$@8"]}],["$","$L9",null,{"children":"$La"}],null,["$","$Lb",null,{"children":["$Lc","$Ld",["$","$Le",null,{"promise":"$@f"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","HJT10d9ZgQpwxY9_5pDAF",{"children":[["$","$L10",null,{"children":"$L11"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$12","$undefined"],"s":false,"S":true} -13:"$Sreact.suspense" -14:I[394,[],"AsyncMetadata"] -7:{} +:HL["/_next/static/css/a2fcfb52b8f42d80.css","style"] +0:{"P":null,"b":"6UzBhGpyRdJjWoKvuuFgP","p":"","c":["","providers",""],"i":false,"f":[[["",{"children":["providers",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/a2fcfb52b8f42d80.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","suppressHydrationWarning":true,"children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"children":["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]}]]}],{"children":["providers",["$","$1","c",{"children":[null,["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L6",null,{"Component":"$7","searchParams":{},"params":{},"promises":["$@8","$@9"]}],["$","$La",null,{"children":"$Lb"}],null,["$","$Lc",null,{"children":["$Ld","$Le",["$","$Lf",null,{"promise":"$@10"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","vAZN46n5znVMiTetRPp4v",{"children":[["$","$L11",null,{"children":"$L12"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$13","$undefined"],"s":false,"S":true} +14:"$Sreact.suspense" +15:I[394,[],"AsyncMetadata"] 8:{} -a:["$","$13",null,{"fallback":null,"children":["$","$L14",null,{"promise":"$@15"}]}] +9:{} +b:["$","$14",null,{"fallback":null,"children":["$","$L15",null,{"promise":"$@16"}]}] +e:null +12:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] d:null -11:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] -c:null -15:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} -f:{"metadata":"$15:metadata","error":null,"digest":"$undefined"} +16:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} +10:{"metadata":"$16:metadata","error":null,"digest":"$undefined"} diff --git a/ui_out/settings/index.html b/ui_out/settings/index.html index 55d0dc27..812e67de 100644 --- a/ui_out/settings/index.html +++ b/ui_out/settings/index.html @@ -1 +1 @@ -Routstr

Routstr

Settings

Loading settings...
\ No newline at end of file + \ No newline at end of file diff --git a/ui_out/settings/index.txt b/ui_out/settings/index.txt index e24d4ac9..15d5936d 100644 --- a/ui_out/settings/index.txt +++ b/ui_out/settings/index.txt @@ -1,26 +1,27 @@ 1:"$Sreact.fragment" -2:I[5414,["363","static/chunks/363-119b32fca35baa33.js","29","static/chunks/29-e3557fb1dd82bdc3.js","578","static/chunks/578-9e08cd45b1eda688.js","177","static/chunks/app/layout-1e4148ea2d359141.js"],"Providers"] -3:I[8754,[],""] -4:I[768,[],""] -5:I[3971,[],"ClientPageRoot"] -6:I[4961,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","978","static/chunks/978-cd938190a9f5efa7.js","651","static/chunks/651-4a58f299a4aa4df7.js","236","static/chunks/236-d1820fdf10fbc413.js","601","static/chunks/601-bd77b408e968f9da.js","662","static/chunks/app/settings/page-abf398be5044bf9e.js"],"default"] -9:I[4826,[],"MetadataBoundary"] -b:I[4826,[],"OutletBoundary"] -e:I[394,[],"AsyncMetadataOutlet"] -10:I[4826,[],"ViewportBoundary"] -12:I[6613,[],""] +2:I[8748,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"SuppressHydrationWarning"] +3:I[7895,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"Providers"] +4:I[8754,[],""] +5:I[768,[],""] +6:I[3971,[],"ClientPageRoot"] +7:I[4961,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","978","static/chunks/978-960e423dcb2d179d.js","651","static/chunks/651-7f1a745b0e3db11d.js","900","static/chunks/900-4ce6a1afa7029035.js","601","static/chunks/601-3f92835872ce1c3b.js","662","static/chunks/app/settings/page-36e251683a0d492c.js"],"default"] +a:I[4826,[],"MetadataBoundary"] +c:I[4826,[],"OutletBoundary"] +f:I[394,[],"AsyncMetadataOutlet"] +11:I[4826,[],"ViewportBoundary"] +13:I[6613,[],""] :HL["/_next/static/media/4cf2300e9c8272f7-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/media/93f479601ee12b01-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/css/de70bee13400563f.css","style"] -:HL["/_next/static/css/2dee0244dc7d99bd.css","style"] -0:{"P":null,"b":"4bJrP3zJGhvVQWjndHhpS","p":"","c":["","settings",""],"i":false,"f":[[["",{"children":["settings",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/2dee0244dc7d99bd.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]]}],{"children":["settings",["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L5",null,{"Component":"$6","searchParams":{},"params":{},"promises":["$@7","$@8"]}],["$","$L9",null,{"children":"$La"}],null,["$","$Lb",null,{"children":["$Lc","$Ld",["$","$Le",null,{"promise":"$@f"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","7RoZ0yOAWY46P9Cy_1nUl",{"children":[["$","$L10",null,{"children":"$L11"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$12","$undefined"],"s":false,"S":true} -13:"$Sreact.suspense" -14:I[394,[],"AsyncMetadata"] -7:{} +:HL["/_next/static/css/a2fcfb52b8f42d80.css","style"] +0:{"P":null,"b":"6UzBhGpyRdJjWoKvuuFgP","p":"","c":["","settings",""],"i":false,"f":[[["",{"children":["settings",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/a2fcfb52b8f42d80.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","suppressHydrationWarning":true,"children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"children":["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]}]]}],{"children":["settings",["$","$1","c",{"children":[null,["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L6",null,{"Component":"$7","searchParams":{},"params":{},"promises":["$@8","$@9"]}],["$","$La",null,{"children":"$Lb"}],null,["$","$Lc",null,{"children":["$Ld","$Le",["$","$Lf",null,{"promise":"$@10"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","GRhq_ixpIL1wdYr43WP7y",{"children":[["$","$L11",null,{"children":"$L12"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$13","$undefined"],"s":false,"S":true} +14:"$Sreact.suspense" +15:I[394,[],"AsyncMetadata"] 8:{} -a:["$","$13",null,{"fallback":null,"children":["$","$L14",null,{"promise":"$@15"}]}] +9:{} +b:["$","$14",null,{"fallback":null,"children":["$","$L15",null,{"promise":"$@16"}]}] +e:null +12:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] d:null -11:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] -c:null -15:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} -f:{"metadata":"$15:metadata","error":null,"digest":"$undefined"} +16:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} +10:{"metadata":"$16:metadata","error":null,"digest":"$undefined"} diff --git a/ui_out/transactions/index.html b/ui_out/transactions/index.html index f791ee7f..be65c9cf 100644 --- a/ui_out/transactions/index.html +++ b/ui_out/transactions/index.html @@ -1 +1 @@ -Routstr

Routstr

Transaction History

View all Cashu token transactions processed by the system

\ No newline at end of file + \ No newline at end of file diff --git a/ui_out/transactions/index.txt b/ui_out/transactions/index.txt index 927625c5..0a6358eb 100644 --- a/ui_out/transactions/index.txt +++ b/ui_out/transactions/index.txt @@ -1,26 +1,27 @@ 1:"$Sreact.fragment" -2:I[5414,["363","static/chunks/363-119b32fca35baa33.js","29","static/chunks/29-e3557fb1dd82bdc3.js","578","static/chunks/578-9e08cd45b1eda688.js","177","static/chunks/app/layout-1e4148ea2d359141.js"],"Providers"] -3:I[8754,[],""] -4:I[768,[],""] -5:I[3971,[],"ClientPageRoot"] -6:I[7082,["363","static/chunks/363-119b32fca35baa33.js","222","static/chunks/222-4bb848975c01d467.js","808","static/chunks/808-6da586a06e4a6738.js","29","static/chunks/29-e3557fb1dd82bdc3.js","730","static/chunks/730-892209af1fa345bd.js","236","static/chunks/236-d1820fdf10fbc413.js","790","static/chunks/app/transactions/page-114770ed3af4ceb6.js"],"default"] -9:I[4826,[],"MetadataBoundary"] -b:I[4826,[],"OutletBoundary"] -e:I[394,[],"AsyncMetadataOutlet"] -10:I[4826,[],"ViewportBoundary"] -12:I[6613,[],""] +2:I[8748,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"SuppressHydrationWarning"] +3:I[7895,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"Providers"] +4:I[8754,[],""] +5:I[768,[],""] +6:I[3971,[],"ClientPageRoot"] +7:I[7082,["363","static/chunks/363-c1e2b04767a3c84b.js","222","static/chunks/222-23a547ab56ff9638.js","226","static/chunks/226-b955dd578f372adc.js","29","static/chunks/29-2e340e48c1ca61fb.js","730","static/chunks/730-eb609e4385533b6b.js","900","static/chunks/900-4ce6a1afa7029035.js","790","static/chunks/app/transactions/page-b9cef669e0e237ee.js"],"default"] +a:I[4826,[],"MetadataBoundary"] +c:I[4826,[],"OutletBoundary"] +f:I[394,[],"AsyncMetadataOutlet"] +11:I[4826,[],"ViewportBoundary"] +13:I[6613,[],""] :HL["/_next/static/media/4cf2300e9c8272f7-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/media/93f479601ee12b01-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/css/de70bee13400563f.css","style"] -:HL["/_next/static/css/2dee0244dc7d99bd.css","style"] -0:{"P":null,"b":"4bJrP3zJGhvVQWjndHhpS","p":"","c":["","transactions",""],"i":false,"f":[[["",{"children":["transactions",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/2dee0244dc7d99bd.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]]}],{"children":["transactions",["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L5",null,{"Component":"$6","searchParams":{},"params":{},"promises":["$@7","$@8"]}],["$","$L9",null,{"children":"$La"}],null,["$","$Lb",null,{"children":["$Lc","$Ld",["$","$Le",null,{"promise":"$@f"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","qT8pEXQc7U_7STQJcsGNg",{"children":[["$","$L10",null,{"children":"$L11"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$12","$undefined"],"s":false,"S":true} -13:"$Sreact.suspense" -14:I[394,[],"AsyncMetadata"] -7:{} +:HL["/_next/static/css/a2fcfb52b8f42d80.css","style"] +0:{"P":null,"b":"6UzBhGpyRdJjWoKvuuFgP","p":"","c":["","transactions",""],"i":false,"f":[[["",{"children":["transactions",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/a2fcfb52b8f42d80.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","suppressHydrationWarning":true,"children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"children":["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]}]]}],{"children":["transactions",["$","$1","c",{"children":[null,["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L6",null,{"Component":"$7","searchParams":{},"params":{},"promises":["$@8","$@9"]}],["$","$La",null,{"children":"$Lb"}],null,["$","$Lc",null,{"children":["$Ld","$Le",["$","$Lf",null,{"promise":"$@10"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","L3Dvx8vyrhqvmybL5zeqh",{"children":[["$","$L11",null,{"children":"$L12"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$13","$undefined"],"s":false,"S":true} +14:"$Sreact.suspense" +15:I[394,[],"AsyncMetadata"] 8:{} -a:["$","$13",null,{"fallback":null,"children":["$","$L14",null,{"promise":"$@15"}]}] +9:{} +b:["$","$14",null,{"fallback":null,"children":["$","$L15",null,{"promise":"$@16"}]}] +e:null +12:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] d:null -11:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] -c:null -15:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} -f:{"metadata":"$15:metadata","error":null,"digest":"$undefined"} +16:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} +10:{"metadata":"$16:metadata","error":null,"digest":"$undefined"} diff --git a/ui_out/unauthorized/index.html b/ui_out/unauthorized/index.html index dbf75af2..e1523b08 100644 --- a/ui_out/unauthorized/index.html +++ b/ui_out/unauthorized/index.html @@ -1 +1 @@ -Routstr

Access Denied

You don't have permission to access this page. Please contact your administrator if you believe this is an error.

\ No newline at end of file + \ No newline at end of file diff --git a/ui_out/unauthorized/index.txt b/ui_out/unauthorized/index.txt index f2f9ce79..2d080fd4 100644 --- a/ui_out/unauthorized/index.txt +++ b/ui_out/unauthorized/index.txt @@ -1,26 +1,27 @@ 1:"$Sreact.fragment" -2:I[5414,["363","static/chunks/363-119b32fca35baa33.js","29","static/chunks/29-e3557fb1dd82bdc3.js","578","static/chunks/578-9e08cd45b1eda688.js","177","static/chunks/app/layout-1e4148ea2d359141.js"],"Providers"] -3:I[8754,[],""] -4:I[768,[],""] -5:I[3971,[],"ClientPageRoot"] -6:I[2818,["222","static/chunks/222-4bb848975c01d467.js","305","static/chunks/app/unauthorized/page-bd10c76db4782139.js"],"default"] -9:I[4826,[],"MetadataBoundary"] -b:I[4826,[],"OutletBoundary"] -e:I[394,[],"AsyncMetadataOutlet"] -10:I[4826,[],"ViewportBoundary"] -12:I[6613,[],""] +2:I[8748,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"SuppressHydrationWarning"] +3:I[7895,["363","static/chunks/363-c1e2b04767a3c84b.js","29","static/chunks/29-2e340e48c1ca61fb.js","375","static/chunks/375-7943a6dae9b88f03.js","177","static/chunks/app/layout-8cbedc9fb3669ba4.js"],"Providers"] +4:I[8754,[],""] +5:I[768,[],""] +6:I[3971,[],"ClientPageRoot"] +7:I[2818,["222","static/chunks/222-23a547ab56ff9638.js","305","static/chunks/app/unauthorized/page-96bd6a23715af694.js"],"default"] +a:I[4826,[],"MetadataBoundary"] +c:I[4826,[],"OutletBoundary"] +f:I[394,[],"AsyncMetadataOutlet"] +11:I[4826,[],"ViewportBoundary"] +13:I[6613,[],""] :HL["/_next/static/media/4cf2300e9c8272f7-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/media/93f479601ee12b01-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] :HL["/_next/static/css/de70bee13400563f.css","style"] -:HL["/_next/static/css/2dee0244dc7d99bd.css","style"] -0:{"P":null,"b":"4bJrP3zJGhvVQWjndHhpS","p":"","c":["","unauthorized",""],"i":false,"f":[[["",{"children":["unauthorized",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/2dee0244dc7d99bd.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]]}],{"children":["unauthorized",["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L5",null,{"Component":"$6","searchParams":{},"params":{},"promises":["$@7","$@8"]}],["$","$L9",null,{"children":"$La"}],null,["$","$Lb",null,{"children":["$Lc","$Ld",["$","$Le",null,{"promise":"$@f"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","b35ngZb5vx9FNM5ZONxrs",{"children":[["$","$L10",null,{"children":"$L11"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$12","$undefined"],"s":false,"S":true} -13:"$Sreact.suspense" -14:I[394,[],"AsyncMetadata"] -7:{} +:HL["/_next/static/css/a2fcfb52b8f42d80.css","style"] +0:{"P":null,"b":"6UzBhGpyRdJjWoKvuuFgP","p":"","c":["","unauthorized",""],"i":false,"f":[[["",{"children":["unauthorized",{"children":["__PAGE__",{}]}]},"$undefined","$undefined",true],["",["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/de70bee13400563f.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/a2fcfb52b8f42d80.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","suppressHydrationWarning":true,"children":["$","body",null,{"className":"__variable_188709 __variable_9a8899 antialiased","children":["$","$L2",null,{"children":["$","$L3",null,{"children":["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]}]}]]}],{"children":["unauthorized",["$","$1","c",{"children":[null,["$","$L4",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":["__PAGE__",["$","$1","c",{"children":[["$","$L6",null,{"Component":"$7","searchParams":{},"params":{},"promises":["$@8","$@9"]}],["$","$La",null,{"children":"$Lb"}],null,["$","$Lc",null,{"children":["$Ld","$Le",["$","$Lf",null,{"promise":"$@10"}]]}]]}],{},null,false]},null,false]},null,false],["$","$1","h",{"children":[null,["$","$1","F1il2Ns7soCyi-Scygy1s",{"children":[["$","$L11",null,{"children":"$L12"}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],null]}],false]],"m":"$undefined","G":["$13","$undefined"],"s":false,"S":true} +14:"$Sreact.suspense" +15:I[394,[],"AsyncMetadata"] 8:{} -a:["$","$13",null,{"fallback":null,"children":["$","$L14",null,{"promise":"$@15"}]}] +9:{} +b:["$","$14",null,{"fallback":null,"children":["$","$L15",null,{"promise":"$@16"}]}] +e:null +12:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] d:null -11:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]] -c:null -15:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} -f:{"metadata":"$15:metadata","error":null,"digest":"$undefined"} +16:{"metadata":[["$","title","0",{"children":"Routstr"}],["$","meta","1",{"name":"description","content":"Routstr model management"}],["$","link","2",{"rel":"icon","href":"/favicon.ico","type":"image/x-icon","sizes":"16x16"}],["$","link","3",{"rel":"icon","href":"/icon.ico"}]],"error":null,"digest":"$undefined"} +10:{"metadata":"$16:metadata","error":null,"digest":"$undefined"}