omnigateway 0.11.2 → 0.11.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/bin/omni.js +1533 -751
  2. package/gateway.js +2040 -1258
  3. package/package.json +2 -4
  4. package/public/assets/{Chip-77Q04h7S.js → Chip-roGX6zyg.js} +5 -1
  5. package/public/assets/CopyValue-FO5yNkRC.js +27 -0
  6. package/public/assets/{Field-56pmSGrh.js → Field-BYBri2NV.js} +1 -1
  7. package/public/assets/Lamp-DsUSnxN4.js +26 -0
  8. package/public/assets/{Panel-BV18WuL1.js → Panel-CWmOTDAP.js} +5 -0
  9. package/public/assets/Rack-CSpeYQ1D.js +483 -0
  10. package/public/assets/{Readout-Dxwka1JI.js → Readout-BTh732hP.js} +1 -1
  11. package/public/assets/{RequestTable-I395emqH.js → RequestTable-xpG3dPST.js} +1 -1
  12. package/public/assets/{SummaryDeck-pAZ93jBW.js → SummaryDeck-DwRGp7mB.js} +1 -1
  13. package/public/assets/{Toggle-y17mtXCV.js → Toggle-BTJVC9Se.js} +1 -1
  14. package/public/assets/TokenBreakdown-DT7or6C9.js +32 -0
  15. package/public/assets/{WindowChart-DWZtz4Ps.js → WindowChart-C-oJo3fW.js} +1 -1
  16. package/public/assets/{_app-0fHLZIC7.js → _app-Drf03PWk.js} +1 -1
  17. package/public/assets/{_app.accounts-DBlImnPw.js → _app.accounts-D8eynNaM.js} +12 -12
  18. package/public/assets/{_app.console-in_iVnep.js → _app.console-DbM7Zbgu.js} +1 -1
  19. package/public/assets/{_app.database-CPj-Juag.js → _app.database-Bj4UJUBZ.js} +7 -7
  20. package/public/assets/{_app.index-DGz9njXx.js → _app.index-2hdPR1Le.js} +1 -1
  21. package/public/assets/_app.keys-BYk7HsiW.js +92 -0
  22. package/public/assets/{_app.logs-C7BhBRjg.js → _app.logs-sG1w9y1i.js} +1 -1
  23. package/public/assets/_app.models-BqdGSdg4.js +148 -0
  24. package/public/assets/{_app.plugins._pluginId-Bx1LgcDj.js → _app.plugins._pluginId-Bf9D8Qiz.js} +1 -1
  25. package/public/assets/{_app.settings-s6K98CA2.js → _app.settings-TzCc7Sd3.js} +1 -1
  26. package/public/assets/{_app.usage-Bp45JtBe.js → _app.usage-XQHmzx-j.js} +1 -1
  27. package/public/assets/chevron-right-DgdKbG-g.js +1 -0
  28. package/public/assets/{client-Bl_FA5jI.js → client-B_g7bcxd.js} +1 -1
  29. package/public/assets/index-C_8ChaGY.js +14 -0
  30. package/public/assets/{login-Qc9iIepG.js → login-Dgd5jBoq.js} +1 -1
  31. package/public/assets/plus-UgaZwucC.js +1 -0
  32. package/public/assets/preload-helper-CvG2RSKd.js +1 -0
  33. package/public/assets/{shared-ChaZCaBz.js → shared-wEQ9LHZa.js} +1 -1
  34. package/public/assets/trash-IE0YvGCJ.js +1 -0
  35. package/public/index.html +5 -5
  36. package/public/shared/chunks/react-DK6rpPfu.js +1 -0
  37. package/public/shared/chunks/react-dom-Wr82bmbV.js +1 -0
  38. package/public/shared/dashboard-sdk.js +1 -1
  39. package/public/shared/react-dom-client.js +5 -5
  40. package/public/shared/react-dom.js +1 -1
  41. package/public/shared/react-query.js +1 -1
  42. package/public/shared/react.js +1 -1
  43. package/public/shared/styled-components.js +1 -1
  44. package/public/assets/CopyValue-DDJId-Zo.js +0 -27
  45. package/public/assets/Lamp-Drd1fFwQ.js +0 -25
  46. package/public/assets/Rack-D3iFlR6e.js +0 -482
  47. package/public/assets/TokenBreakdown-BIwuEVs8.js +0 -32
  48. package/public/assets/_app.keys-C-Fk39-U.js +0 -92
  49. package/public/assets/_app.models-BuiRrOrz.js +0 -148
  50. package/public/assets/chevron-right-BE-3EQR5.js +0 -1
  51. package/public/assets/index-nvJxJ9Gp.js +0 -13
  52. package/public/assets/plus-DhyoE7aH.js +0 -1
  53. package/public/assets/preload-helper-DYShfVEU.js +0 -1
  54. package/public/assets/trash-2-zGGJ7VE_.js +0 -1
  55. package/public/shared/chunks/react-GitiQ0dt.js +0 -1
  56. package/public/shared/chunks/react-dom-BFxyned6.js +0 -1
@@ -0,0 +1,483 @@
1
+ import{Ct as e,Dt as t,F as n,L as r,P as i,Ut as a,Xt as o,Yt as s,i as c,jt as l,t as u,wt as d,x as f,xt as p}from"./Lamp-DsUSnxN4.js";import{C as m,D as h,E as g,O as _,S as v,T as y,_ as b,b as x,o as S,v as C}from"./Panel-CWmOTDAP.js";import*as w from"react";import{createContext as T,createElement as E,forwardRef as D,use as ee,useCallback as te,useContext as ne,useEffect as re,useId as ie,useMemo as ae,useState as O}from"react";import{Fragment as k,jsx as A,jsxs as j}from"react/jsx-runtime";import M,{ThemeProvider as oe,createGlobalStyle as se,css as ce}from"styled-components";import{LiveProvider as le,useLive as ue}from"@omnigateway/dashboard-sdk";import*as de from"react-dom";var fe=e=>e?.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase();function pe(e,t,n=[]){if(t==null)throw Error(`[lucide]: iconNode is required when icon name is used`);return{name:fe(e),size:24,node:t,...n.length>0?{aliases:n}:{}}}var me=e=>{let t=``,n=!1;for(let r of e){if(r===`-`||r===`_`||r<=` `){n=t.length>0;continue}t.length===0?t+=r.toLowerCase():t+=n?r.toUpperCase():r,n=!1}return t},he=e=>{let t=me(e);return t.charAt(0).toUpperCase()+t.slice(1)},ge=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),N={xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":2,"stroke-linecap":`round`,"stroke-linejoin":`round`};function _e(e){return e!=null}function ve(e,t={}){let n=t.attributeNames??{},r=e=>n[e]??e,i=e.size??e.width??N.width,a=e.size??e.height??N.height,o=e.aliases?.filter(e=>typeof e==`string`&&e.trim()!==``).map(e=>`lucide-${e}`)??[],s=[...e.name?[`lucide-${e.name}`]:[],...o],c=t.className?.split(` `).filter(Boolean)??[],l=t.includeDefaultClasses===!1?ge(...c):ge(`lucide`,...s,...c),u=t.absoluteStrokeWidth?Number(t.strokeWidth??N[`stroke-width`])*Number(e.size??e.width??N.width)/Number(t.size??t.width??N.width):t.strokeWidth??N[`stroke-width`];return[`svg`,{...Object.entries(N).reduce((e,[t,n])=>(e[r(t)]=n,e),{}),...`color`in t&&t.color&&{[r(`stroke`)]:t.color},...`size`in t&&_e(t.size)&&{[r(`width`)]:t.size,[r(`height`)]:t.size},...`width`in t&&_e(t.width)&&{[r(`width`)]:t.width},...`height`in t&&_e(t.height)&&{[r(`height`)]:t.height},[r(`stroke-width`)]:u,...l&&{[r(`class`)]:l},[r(`viewBox`)]:`0 0 ${i} ${a}`,...t.hasA11yProp===!1?{[r(`aria-hidden`)]:`true`}:{},...`attributes`in t&&t.attributes},e.node.map(e=>{let[n,i,a]=e,o=t.nonScalingStroke?{[r(`vector-effect`)]:`non-scaling-stroke`,...i}:i;return a?[n,o,a]:[n,o]})]}function ye(e,t={}){return ve(e,{...t,attributeNames:{...t.attributeNames,class:`className`,"stroke-width":`strokeWidth`,"stroke-linecap":`strokeLinecap`,"stroke-linejoin":`strokeLinejoin`,"vector-effect":`vectorEffect`}})}var be=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},xe=T({}),Se=()=>ne(xe),Ce=D(({color:e,size:t,width:n,height:r,strokeWidth:i,absoluteStrokeWidth:a,nonScalingStroke:o,className:s=``,children:c,iconNode:l=[],icon:u={node:l,aliases:[],size:24},...d},f)=>{let{size:p=24,strokeWidth:m=2,absoluteStrokeWidth:h=!1,nonScalingStroke:g=!1,color:_=`currentColor`,className:v=``}=Se()??{},y=!!c||be(d),[b,x,S=[]]=ye(u,{color:e??_,width:n??t??p,height:r??t??p,strokeWidth:i??m,absoluteStrokeWidth:a??h,nonScalingStroke:o??g,className:ge(v,s),hasA11yProp:y,attributes:d});return E(b,{ref:f,...x},[...S.map(([e,t])=>E(e,t)),...Array.isArray(c)?c:[c]])});function P(e,t=[],n=[]){let r=typeof e==`string`?pe(e,t,n):e,i=D(({className:e,...t},n)=>E(Ce,{ref:n,icon:r,className:e,...t}));return r.name&&(i.displayName=he(r.name)),i}var we={name:`activity`,size:24,node:[[`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`}]]};we.node;var Te=P(we),Ee={name:`blocks`,size:24,node:[[`path`,{d:`M10 22V7a1 1 0 0 0-1-1H4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-5a1 1 0 0 0-1-1H2`,key:`1ah6g2`}],[`rect`,{x:`14`,y:`2`,width:`8`,height:`8`,rx:`1`,key:`88lufb`}]]};Ee.node;var De=P(Ee),Oe={name:`boxes`,size:24,node:[[`path`,{d:`M2.97 12.92A2 2 0 0 0 2 14.63v3.24a2 2 0 0 0 .97 1.71l3 1.8a2 2 0 0 0 2.06 0L12 19v-5.5l-5-3-4.03 2.42Z`,key:`lc1i9w`}],[`path`,{d:`m7 16.5-4.74-2.85`,key:`1o9zyk`}],[`path`,{d:`m7 16.5 5-3`,key:`va8pkn`}],[`path`,{d:`M7 16.5v5.17`,key:`jnp8gn`}],[`path`,{d:`M12 13.5V19l3.97 2.38a2 2 0 0 0 2.06 0l3-1.8a2 2 0 0 0 .97-1.71v-3.24a2 2 0 0 0-.97-1.71L17 10.5l-5 3Z`,key:`8zsnat`}],[`path`,{d:`m17 16.5-5-3`,key:`8arw3v`}],[`path`,{d:`m17 16.5 4.74-2.85`,key:`8rfmw`}],[`path`,{d:`M17 16.5v5.17`,key:`k6z78m`}],[`path`,{d:`M7.97 4.42A2 2 0 0 0 7 6.13v4.37l5 3 5-3V6.13a2 2 0 0 0-.97-1.71l-3-1.8a2 2 0 0 0-2.06 0l-3 1.8Z`,key:`1xygjf`}],[`path`,{d:`M12 8 7.26 5.15`,key:`1vbdud`}],[`path`,{d:`m12 8 4.74-2.85`,key:`3rx089`}],[`path`,{d:`M12 13.5V8`,key:`1io7kd`}]]};Oe.node;var ke=P(Oe),Ae={name:`cable`,size:24,node:[[`path`,{d:`M17 19a1 1 0 0 1-1-1v-2a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v2a1 1 0 0 1-1 1z`,key:`trhst0`}],[`path`,{d:`M17 21v-2`,key:`ds4u3f`}],[`path`,{d:`M19 14V6.5a1 1 0 0 0-7 0v11a1 1 0 0 1-7 0V10`,key:`1mo9zo`}],[`path`,{d:`M21 21v-2`,key:`eo0ou`}],[`path`,{d:`M3 5V3`,key:`1k5hjh`}],[`path`,{d:`M4 10a2 2 0 0 1-2-2V6a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v2a2 2 0 0 1-2 2z`,key:`1dd30t`}],[`path`,{d:`M7 5V3`,key:`1t1388`}]]};Ae.node;var je=P(Ae),Me={name:`database`,size:24,node:[[`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`}]]};Me.node;var Ne=P(Me),Pe={name:`gauge`,size:24,node:[[`path`,{d:`m12 14 4-4`,key:`9kzdfg`}],[`path`,{d:`M3.34 19a10 10 0 1 1 17.32 0`,key:`19p75a`}]]};Pe.node;var Fe=P(Pe),Ie={name:`key-round`,size:24,node:[[`path`,{d:`M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z`,key:`1s6t7t`}],[`circle`,{cx:`16.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`w0ekpg`}]]};Ie.node;var Le=P(Ie),Re={name:`log-out`,size:24,node:[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]};Re.node;var ze=P(Re),Be={name:`monitor-cog`,size:24,node:[[`path`,{d:`M12 17v4`,key:`1riwvh`}],[`path`,{d:`m14.305 7.53.923-.382`,key:`1mlnsw`}],[`path`,{d:`m15.228 4.852-.923-.383`,key:`82mpwg`}],[`path`,{d:`m16.852 3.228-.383-.924`,key:`ln4sir`}],[`path`,{d:`m16.852 8.772-.383.923`,key:`1dejw0`}],[`path`,{d:`m19.148 3.228.383-.924`,key:`192kgf`}],[`path`,{d:`m19.53 9.696-.382-.924`,key:`fiavlr`}],[`path`,{d:`m20.772 4.852.924-.383`,key:`1j8mgp`}],[`path`,{d:`m20.772 7.148.924.383`,key:`zix9be`}],[`path`,{d:`M22 13v2a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7`,key:`1tnzv8`}],[`path`,{d:`M8 21h8`,key:`1ev6f3`}],[`circle`,{cx:`18`,cy:`6`,r:`3`,key:`1h7g24`}]]};Be.node;var Ve=P(Be),He={name:`moon`,size:24,node:[[`path`,{d:`M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401`,key:`kfwtm`}]]};He.node;var Ue=P(He),We={name:`power`,size:24,node:[[`path`,{d:`M12 2v10`,key:`mnfbl`}],[`path`,{d:`M18.4 6.6a9 9 0 1 1-12.77.04`,key:`obofu9`}]]};We.node;var Ge=P(We),Ke={name:`rotate-cw`,size:24,node:[[`path`,{d:`M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8`,key:`1p45f6`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}]]};Ke.node;var qe=P(Ke),Je={name:`scroll-text`,size:24,node:[[`path`,{d:`M15 12h-5`,key:`r7krc0`}],[`path`,{d:`M15 8h-5`,key:`1khuty`}],[`path`,{d:`M19 17V5a2 2 0 0 0-2-2H4`,key:`zz82l3`}],[`path`,{d:`M8 21h12a2 2 0 0 0 2-2v-1a1 1 0 0 0-1-1H11a1 1 0 0 0-1 1v1a2 2 0 1 1-4 0V5a2 2 0 1 0-4 0v2a1 1 0 0 0 1 1h3`,key:`1ph1d7`}]]};Je.node;var Ye=P(Je),Xe={name:`sliders-horizontal`,size:24,node:[[`path`,{d:`M10 5H3`,key:`1qgfaw`}],[`path`,{d:`M12 19H3`,key:`yhmn1j`}],[`path`,{d:`M14 3v4`,key:`1sua03`}],[`path`,{d:`M16 17v4`,key:`1q0r14`}],[`path`,{d:`M21 12h-9`,key:`1o4lsq`}],[`path`,{d:`M21 19h-5`,key:`1rlt1p`}],[`path`,{d:`M21 5h-7`,key:`1oszz2`}],[`path`,{d:`M8 10v4`,key:`tgpxqk`}],[`path`,{d:`M8 12H3`,key:`a7s4jb`}]]};Xe.node;var Ze=P(Xe),Qe={name:`sun`,size:24,node:[[`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`}]]};Qe.node;var $e=P(Qe),et={name:`terminal`,size:24,node:[[`path`,{d:`M12 19h8`,key:`baeox8`}],[`path`,{d:`m4 17 6-6-6-6`,key:`1yngyt`}]]};et.node;var tt=P(et),nt={name:`x`,size:24,node:[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]};nt.node;var rt=P(nt);function it(e,t){return e.flatMap(({id:e,colour:n})=>{let r=n?.[t];return typeof r==`string`?[`--p-${e}: ${r};`]:[]}).join(`
2
+ `)}var at=se`
3
+ :root {
4
+ ${({$providers:e})=>it(e,`light`)}
5
+ }
6
+
7
+ .dark {
8
+ ${({$providers:e})=>it(e,`dark`)}
9
+ }
10
+ `,ot=se`
11
+ :root {
12
+ color-scheme: light;
13
+
14
+ --rack: oklch(0.962 0.004 258);
15
+ --panel: oklch(1 0 0);
16
+ --panel-sunk: oklch(0.972 0.004 258);
17
+ --panel-raised: oklch(0.988 0.003 258);
18
+ --rule: oklch(0.9 0.006 258);
19
+ --rule-strong: oklch(0.82 0.008 258);
20
+
21
+ --ink: oklch(0.22 0.017 258);
22
+ --ink-dim: oklch(0.45 0.015 258);
23
+ --ink-faint: oklch(0.62 0.012 258);
24
+
25
+ --accent: oklch(0.52 0.17 262);
26
+ --accent-ink: oklch(0.99 0 0);
27
+ --accent-wash: oklch(0.52 0.17 262 / 0.11);
28
+
29
+ --ok: oklch(0.52 0.13 162);
30
+ --warn: oklch(0.58 0.13 72);
31
+ --down: oklch(0.53 0.2 27);
32
+ --ok-wash: oklch(0.52 0.13 162 / 0.12);
33
+ --warn-wash: oklch(0.58 0.13 72 / 0.14);
34
+ --down-wash: oklch(0.53 0.2 27 / 0.11);
35
+
36
+ --grid-line: oklch(0.22 0.017 258 / 0.055);
37
+ --shadow: 0 1px 2px oklch(0.22 0.017 258 / 0.06);
38
+ }
39
+
40
+ .dark {
41
+ color-scheme: dark;
42
+
43
+ --rack: oklch(0.163 0.013 258);
44
+ --panel: oklch(0.204 0.013 258);
45
+ --panel-sunk: oklch(0.183 0.013 258);
46
+ --panel-raised: oklch(0.246 0.013 258);
47
+ --rule: oklch(0.3 0.012 258);
48
+ --rule-strong: oklch(0.4 0.014 258);
49
+
50
+ --ink: oklch(0.94 0.006 250);
51
+ --ink-dim: oklch(0.72 0.011 253);
52
+ --ink-faint: oklch(0.55 0.012 255);
53
+
54
+ --accent: oklch(0.74 0.13 262);
55
+ --accent-ink: oklch(0.17 0.02 262);
56
+ --accent-wash: oklch(0.74 0.13 262 / 0.18);
57
+
58
+ --ok: oklch(0.75 0.14 162);
59
+ --warn: oklch(0.82 0.14 80);
60
+ --down: oklch(0.68 0.19 25);
61
+ --ok-wash: oklch(0.75 0.14 162 / 0.16);
62
+ --warn-wash: oklch(0.82 0.14 80 / 0.16);
63
+ --down-wash: oklch(0.68 0.19 25 / 0.16);
64
+
65
+ --grid-line: oklch(0.94 0.006 250 / 0.045);
66
+ --shadow: 0 1px 2px oklch(0 0 0 / 0.3);
67
+ }
68
+
69
+ *,
70
+ *::before,
71
+ *::after {
72
+ box-sizing: border-box;
73
+ }
74
+
75
+ html,
76
+ body,
77
+ #root {
78
+ height: 100%;
79
+ }
80
+
81
+ html {
82
+ background: ${({theme:e})=>e.color.rack};
83
+ }
84
+
85
+ body {
86
+ margin: 0;
87
+ background: ${({theme:e})=>e.color.rack};
88
+ color: ${({theme:e})=>e.color.ink};
89
+ font-family: ${({theme:e})=>e.font.sans};
90
+ font-size: 14px;
91
+ line-height: 1.45;
92
+ -webkit-font-smoothing: antialiased;
93
+ }
94
+
95
+ h1, h2, h3, h4, p, figure, dl, dd {
96
+ margin: 0;
97
+ }
98
+
99
+ ul, ol {
100
+ margin: 0;
101
+ padding: 0;
102
+ list-style: none;
103
+ }
104
+
105
+ button, input, select, textarea {
106
+ font: inherit;
107
+ color: inherit;
108
+ }
109
+
110
+ svg {
111
+ display: block;
112
+ flex-shrink: 0;
113
+ }
114
+
115
+ a {
116
+ color: inherit;
117
+ text-decoration: none;
118
+ }
119
+
120
+ :focus-visible {
121
+ outline: 2px solid ${({theme:e})=>e.color.accent};
122
+ outline-offset: 1px;
123
+ border-radius: 2px;
124
+ }
125
+
126
+ ::selection {
127
+ background: ${({theme:e})=>e.color.accentWash};
128
+ }
129
+
130
+ ::-webkit-scrollbar {
131
+ width: 10px;
132
+ height: 10px;
133
+ }
134
+
135
+ ::-webkit-scrollbar-track {
136
+ background: transparent;
137
+ }
138
+
139
+ ::-webkit-scrollbar-thumb {
140
+ background: ${({theme:e})=>e.color.ruleStrong};
141
+ border: 3px solid transparent;
142
+ background-clip: padding-box;
143
+ border-radius: 6px;
144
+ }
145
+
146
+ @media (prefers-reduced-motion: reduce) {
147
+ *,
148
+ *::before,
149
+ *::after {
150
+ animation-duration: 0.01ms !important;
151
+ animation-iteration-count: 1 !important;
152
+ transition-duration: 0.01ms !important;
153
+ scroll-behavior: auto !important;
154
+ }
155
+ }
156
+ `,st={color:{rack:`var(--rack)`,panel:`var(--panel)`,panelSunk:`var(--panel-sunk)`,panelRaised:`var(--panel-raised)`,rule:`var(--rule)`,ruleStrong:`var(--rule-strong)`,ink:`var(--ink)`,inkDim:`var(--ink-dim)`,inkFaint:`var(--ink-faint)`,accent:`var(--accent)`,accentInk:`var(--accent-ink)`,accentWash:`var(--accent-wash)`,ok:`var(--ok)`,warn:`var(--warn)`,down:`var(--down)`,okWash:`var(--ok-wash)`,warnWash:`var(--warn-wash)`,downWash:`var(--down-wash)`,shadow:`var(--shadow)`},font:{sans:`"Archivo Variable", ui-sans-serif, system-ui, sans-serif`,mono:`"Spline Sans Mono Variable", ui-monospace, "SF Mono", Menlo, monospace`},radius:{panel:`4px`,control:`3px`,chip:`2px`},space:e=>`${e*4}px`,z:{rail:20,chassis:30,overlay:40,dialog:50,toast:60}},ct=/^[a-z][a-z0-9-]{0,31}$/;function lt(e){return ct.test(e)?`var(--p-${e}, var(--ink-faint))`:`var(--ink-faint)`}var ut=`omni-theme`;function dt(e){return e===`light`||e===`dark`||e===`system`}function ft(){try{let e=localStorage.getItem(ut);return dt(e)?e:`system`}catch{return`system`}}function pt(){return typeof matchMedia==`function`&&matchMedia(`(prefers-color-scheme: dark)`).matches}function mt(e){return e===`system`?pt()?`dark`:`light`:e}function ht(e){let t=document.documentElement;t.classList.toggle(`dark`,e===`dark`),t.dataset.theme=e}var gt=T(null);function _t(){let e=ee(gt);if(e===null)throw Error(`useTheme must be used inside <ThemeProvider>`);return e}function vt({children:e}){let[t,n]=O(ft),[r,i]=O(()=>mt(ft())),a=te(e=>{n(e);try{localStorage.setItem(ut,e)}catch{}},[]);return re(()=>{let e=mt(t);i(e),ht(e)},[t]),re(()=>{if(t!==`system`||typeof matchMedia!=`function`)return;let e=matchMedia(`(prefers-color-scheme: dark)`),n=()=>{let e=pt()?`dark`:`light`;i(e),ht(e)};return e.addEventListener(`change`,n),()=>e.removeEventListener(`change`,n)},[t]),A(gt,{value:{mode:t,resolved:r,setMode:a},children:j(oe,{theme:st,children:[A(ot,{}),e]})})}var yt=M.svg`
157
+ display: block;
158
+ width: 100%;
159
+ height: 100%;
160
+ overflow: visible;
161
+ `;function bt(e,t,n,r){if(e.length===0)return``;let i=e.length===1?0:t/(e.length-1);return e.map((e,t)=>{let a=t*i,o=n-(r===0?0:e/r*n);return`${t===0?`M`:`L`}${a.toFixed(2)},${o.toFixed(2)}`}).join(` `)}function xt({values:e,overlay:t,height:n=28,color:r,overlayColor:i,scaleTo:a,label:o,className:s}){let c=ie(),l=a===void 0?Math.max(1,...e,...t??[]):Math.max(1,a),u=bt(e,100,n,l),d=u.length===0?``:`${u} L100,${n} L0,${n} Z`;return j(yt,{className:s,viewBox:`0 0 100 ${n}`,preserveAspectRatio:`none`,role:`img`,"aria-label":o,style:{height:n},children:[A(`defs`,{children:j(`linearGradient`,{id:c,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[A(`stop`,{offset:`0%`,stopColor:r??`var(--accent)`,stopOpacity:`0.28`}),A(`stop`,{offset:`100%`,stopColor:r??`var(--accent)`,stopOpacity:`0`})]})}),d.length===0?null:A(`path`,{d,fill:`url(#${c})`}),t===void 0?null:A(`path`,{d:bt(t,100,n,l),fill:`none`,stroke:i??`var(--down)`,strokeWidth:`1.25`,vectorEffect:`non-scaling-stroke`}),A(`path`,{d:u,fill:`none`,stroke:r??`var(--accent)`,strokeWidth:`1.5`,strokeLinejoin:`round`,vectorEffect:`non-scaling-stroke`})]})}var St=M.header`
162
+ grid-area: chassis;
163
+ display: flex;
164
+ align-items: center;
165
+ gap: ${({theme:e})=>e.space(3)};
166
+ height: 48px;
167
+ padding: 0 ${({theme:e})=>e.space(3)};
168
+ border-bottom: 1px solid ${({theme:e})=>e.color.rule};
169
+ background: ${({theme:e})=>e.color.panel};
170
+ ${g}
171
+ position: sticky;
172
+ top: 0;
173
+ z-index: ${({theme:e})=>e.z.chassis};
174
+ `,Ct=M.div`
175
+ display: flex;
176
+ align-items: center;
177
+ gap: 7px;
178
+ font-stretch: 74%;
179
+ font-weight: 700;
180
+ letter-spacing: 0.2em;
181
+ font-size: 12px;
182
+ text-transform: uppercase;
183
+ flex: none;
184
+ `,wt=M(x)`
185
+ gap: ${({theme:e})=>e.space(3)};
186
+ overflow: hidden;
187
+
188
+ @media (max-width: 860px) {
189
+ display: none;
190
+ }
191
+ `,Tt=M.div`
192
+ display: flex;
193
+ align-items: baseline;
194
+ gap: 6px;
195
+ padding-left: ${({theme:e})=>e.space(3)};
196
+ border-left: 1px solid ${({theme:e})=>e.color.rule};
197
+ white-space: nowrap;
198
+ `,Et=M(Tt)`
199
+ width: 96px;
200
+ align-items: center;
201
+ `,Dt=M.div`
202
+ flex: 1;
203
+ min-width: 0;
204
+ `,Ot=M(h)`
205
+ gap: 6px;
206
+ font-family: ${({theme:e})=>e.font.mono};
207
+ letter-spacing: 0.08em;
208
+ `,kt=M.span`
209
+ color: ${({theme:e})=>e.color.inkFaint};
210
+ `,At={push:{name:`live, pushing`,lamp:`live`,head:`LIVE`,tail:`PUSH`,title:`Refreshing on gateway push — pause refreshing`},poll:{name:`live, polling`,lamp:`ok`,head:`LIVE`,tail:`POLL`,title:`Refreshing on a timer — pause refreshing`},paused:{name:`paused`,lamp:`idle`,head:`PAUSED`,tail:null,title:`Resume refreshing`},offline:{name:`offline`,lamp:`down`,head:`OFFLINE`,tail:null,title:`Not refreshing — this session ended, sign in again`}},jt=[`system`,`light`,`dark`],Mt={system:`Match system theme`,light:`Light theme`,dark:`Dark theme`},Nt=6e5;function Pt({logs:e,logsFailed:t,signOut:a}){let{live:o,toggle:s,connection:l}=ue(),{mode:d,setMode:p}=_t(),m=Date.now(),h=ae(()=>e.filter(e=>m-e.at<=Nt),[e,m]),g=f(h,Nt),y=c(h,{now:m,spanMs:Nt,count:24}),x=jt[(jt.indexOf(d)+1)%jt.length]??`system`,S=d===`light`?$e:d===`dark`?Ue:Ve,w=At[o?l.status===`offline`?`offline`:l.status===`push`?`push`:`poll`:`paused`],T=t||g.errorRate>=.25?`down`:g.errorRate>=.05?`warn`:h.length===0?`idle`:`ok`;return j(St,{children:[j(Ct,{children:[A(u,{state:T,label:t?`request log unreadable`:`error rate ${n(g.errorRate)}`}),`Omnigateway`]}),j(wt,{children:[j(Et,{children:[A(b,{children:`req`}),A(Dt,{children:A(xt,{values:y.map(e=>e.total),overlay:y.map(e=>e.errors),height:22,label:`${g.requests} requests in the last 10 minutes`})})]}),j(Tt,{children:[A(b,{children:`rate`}),A(C,{children:g.ratePerMin.toFixed(1)}),A(b,{children:`/min`})]}),j(Tt,{children:[A(b,{children:`err`}),A(C,{style:{color:g.errorRate>=.05?`var(--down)`:void 0},children:n(g.errorRate)})]}),j(Tt,{children:[A(b,{children:`ttft p50`}),A(C,{children:i(g.ttftP50)})]}),j(Tt,{children:[A(b,{children:`spend`}),A(C,{children:r(g.costUsd)})]})]}),A(v,{}),j(Ot,{type:`button`,$size:`sm`,onClick:s,"aria-pressed":o,"aria-label":w.name,title:w.title,children:[A(u,{state:w.lamp,label:w.name}),w.head,w.tail===null?null:j(k,{children:[A(kt,{"aria-hidden":`true`,children:`·`}),w.tail]})]}),A(_,{type:`button`,$variant:`ghost`,$size:`sm`,onClick:()=>p(x),"aria-label":Mt[d],title:`${Mt[d]} — switch to ${Mt[x].toLowerCase()}`,children:A(S,{})}),A(_,{type:`button`,$variant:`ghost`,$size:`sm`,"aria-label":`Sign out`,title:`Sign out`,disabled:a.pending,onClick:a.run,children:A(ze,{})})]})}function Ft(){let t=o(),{cadence:n}=ue(),r=e(),i=d(200,n(1e4,`res:logs`));return A(Pt,{logs:i.data??[],logsFailed:i.isError,signOut:{pending:r.isPending,run:()=>{r.mutate(void 0,{onSuccess:()=>void t({to:`/login`})})}}})}function It(e){return`/plugins/${e}`}function Lt(e){return e.filter(e=>e.nav!==null&&e.ui!==null).sort((e,t)=>e.id.localeCompare(t.id)).map(e=>({id:e.id,label:e.nav?.label??e.name,disabledReason:Rt(e)}))}function Rt(e){let t=e.ui;return t===null||t.compatible&&t.entry!==null?null:t.reason??`This plugin's interface does not match this gateway.`}var zt=Object.defineProperty,Bt=(e,t)=>zt(e,`name`,{value:t,configurable:!0});function Vt(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}Bt(Vt,`setRef`);function Ht(...e){return t=>{let n=!1,r=e.map(e=>{let r=Vt(e,t);return!n&&typeof r==`function`&&(n=!0),r});if(n)return()=>{for(let t=0;t<r.length;t++){let n=r[t];typeof n==`function`?n():Vt(e[t],null)}}}}Bt(Ht,`composeRefs`);function F(...e){return w.useCallback(Ht(...e),e)}Bt(F,`useComposedRefs`);var Ut=Object.defineProperty,I=(e,t)=>Ut(e,`name`,{value:t,configurable:!0});function Wt(e){let t=w.forwardRef((t,n)=>{let{children:r,...i}=t,a=null,o=!1,s=[];Qt(r)&&typeof nn==`function`&&(r=nn(r._payload)),w.Children.forEach(r,e=>{if(Xt(e)){o=!0;let t=e,n=`child`in t.props?t.props.child:t.props.children;Qt(n)&&typeof nn==`function`&&(n=nn(n._payload)),a=qt(t,n),s.push(a?.props?.children)}else s.push(e)}),a?a=w.cloneElement(a,void 0,s):!o&&w.Children.count(r)===1&&w.isValidElement(r)&&(a=r);let c=a?Yt(a):void 0,l=F(n,c);if(!a){if(r||r===0)throw Error(o?tn(e):en(e));return r}let u=Jt(i,a.props??{});return a.type!==w.Fragment&&(u.ref=n?l:c),w.cloneElement(a,u)});return t.displayName=`${e}.Slot`,t}I(Wt,`createSlot`);var Gt=Symbol.for(`radix.slottable`);function Kt(e){let t=I(e=>`child`in e?e.children(e.child):e.children,`Slottable`);return t.displayName=`${e}.Slottable`,t.__radixId=Gt,t}I(Kt,`createSlottable`);var qt=I((e,t)=>{if(`child`in e.props){let t=e.props.child;return w.isValidElement(t)?w.cloneElement(t,void 0,e.props.children(t.props.children)):null}return w.isValidElement(t)?t:null},`getSlottableElementFromSlottable`);function Jt(e,t){let n={...t};for(let r in t){let i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...e)=>{let t=a(...e);return i(...e),t}:i&&(n[r]=i):r===`style`?n[r]={...i,...a}:r===`className`&&(n[r]=[i,a].filter(Boolean).join(` `))}return{...e,...n}}I(Jt,`mergeProps`);function Yt(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}I(Yt,`getElementRef`);function Xt(e){return w.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===Gt}I(Xt,`isSlottable`);var Zt=Symbol.for(`react.lazy`);function Qt(e){return typeof e==`object`&&!!e&&`$$typeof`in e&&e.$$typeof===Zt&&`_payload`in e&&$t(e._payload)}I(Qt,`isLazyComponent`);function $t(e){return typeof e==`object`&&!!e&&`then`in e}I($t,`isPromiseLike`);var en=I(e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,`createSlotError`),tn=I(e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,`createSlottableError`),nn=w.use,rn=Object.defineProperty,an=(e,t)=>rn(e,`name`,{value:t,configurable:!0}),L=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,t)=>{let n=Wt(`Primitive.${t}`),r=w.forwardRef((e,r)=>{let{asChild:i,...a}=e,o=i?n:t;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),A(o,{...a,ref:r})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function on(e,t){e&&de.flushSync(()=>e.dispatchEvent(t))}an(on,`dispatchDiscreteCustomEvent`);var sn=Object.defineProperty,R=(e,t)=>sn(e,`name`,{value:t,configurable:!0});function cn(e,t){let n=w.createContext(t);n.displayName=e+`Context`;let r=R(e=>{let{children:t,...r}=e,i=w.useMemo(()=>r,Object.values(r));return A(n.Provider,{value:i,children:t})},`Provider`);r.displayName=e+`Provider`;function i(r,i={}){let{optional:a=!1}=i,o=w.useContext(n);if(o)return o;if(t!==void 0)return t;if(!a)throw Error(`\`${r}\` must be used within \`${e}\``)}return R(i,`useContext`),[r,i]}R(cn,`createContext`);function ln(e,t=[]){let n=[];function r(t,r){let i=w.createContext(r);i.displayName=t+`Context`;let a=n.length;n=[...n,r];let o=R(t=>{let{scope:n,children:r,...o}=t,s=n?.[e]?.[a]||i,c=w.useMemo(()=>o,Object.values(o));return A(s.Provider,{value:c,children:r})},`Provider`);o.displayName=t+`Provider`;function s(n,o,s={}){let{optional:c=!1}=s,l=o?.[e]?.[a]||i,u=w.useContext(l);if(u)return u;if(r!==void 0)return r;if(!c)throw Error(`\`${n}\` must be used within \`${t}\``)}return R(s,`useContext`),[o,s]}R(r,`createContext`);let i=R(()=>{let t=n.map(e=>w.createContext(e));return R(function(n){let r=n?.[e]||t;return w.useMemo(()=>({[`__scope${e}`]:{...n,[e]:r}}),[n,r])},`useScope`)},`createScope`);return i.scopeName=e,[r,un(i,...t)]}R(ln,`createContextScope`);function un(...e){let t=e[0];if(e.length===1)return t;let n=R(()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return R(function(e){let r=n.reduce((t,{useScope:n,scopeName:r})=>{let i=n(e)[`__scope${r}`];return{...t,...i}},{});return w.useMemo(()=>({[`__scope${t.scopeName}`]:r}),[r])},`useComposedScopes`)},`createScope`);return n.scopeName=t.scopeName,n}R(un,`composeContextScopes`);var dn=Object.defineProperty,z=(e,t)=>dn(e,`name`,{value:t,configurable:!0}),fn=!!(typeof window<`u`&&window.document&&window.document.createElement);function B(e,t,{checkForDefaultPrevented:n=!0}={}){return z(function(r){if(e?.(r),n===!1||!r||!r.defaultPrevented)return t?.(r)},`handleEvent`)}z(B,`composeEventHandlers`);function pn(e){if(!fn)throw Error(`Cannot access window outside of the DOM`);return e?.ownerDocument?.defaultView??window}z(pn,`getOwnerWindow`);function mn(e){if(!fn)throw Error(`Cannot access document outside of the DOM`);return e?.ownerDocument??document}z(mn,`getOwnerDocument`);function hn(e,t=!1){let{activeElement:n}=mn(e);if(!n?.nodeName)return null;if(gn(n)&&n.contentDocument)return hn(n.contentDocument.body,t);if(t){let e=n.getAttribute(`aria-activedescendant`);if(e){let t=mn(n).getElementById(e);if(t)return t}}return n}z(hn,`getActiveElement`);function gn(e){return e.tagName===`IFRAME`}z(gn,`isFrame`);var V=globalThis?.document?w.useLayoutEffect:()=>{},_n=Object.defineProperty,vn=(e,t)=>_n(e,`name`,{value:t,configurable:!0}),yn=w.useEffectEvent,bn=w.useInsertionEffect;function xn(e){if(typeof yn==`function`)return yn(e);let t=w.useRef(()=>{throw Error(`Cannot call an event handler while rendering.`)});return typeof bn==`function`?bn(()=>{t.current=e}):V(()=>{t.current=e}),w.useMemo(()=>((...e)=>t.current?.(...e)),[])}vn(xn,`useEffectEvent`);var Sn=Object.defineProperty,Cn=(e,t)=>Sn(e,`name`,{value:t,configurable:!0}),wn=w.useInsertionEffect||V;function Tn({prop:e,defaultProp:t,onChange:n=Cn(()=>{},`onChange`),caller:r}){let[i,a,o]=En({defaultProp:t,onChange:n}),s=e!==void 0;return[s?e:i,w.useCallback(t=>{if(s){let n=Dn(t)?t(e):t;n!==e&&o.current?.(n)}else a(t)},[s,e,a,o])]}Cn(Tn,`useControllableState`);function En({defaultProp:e,onChange:t}){let[n,r]=w.useState(e),i=w.useRef(n),a=w.useRef(t);return wn(()=>{a.current=t},[t]),w.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}Cn(En,`useUncontrolledState`);function Dn(e){return typeof e==`function`}Cn(Dn,`isFunction`);var On=Symbol(`RADIX:SYNC_STATE`);function kn(e,t,n,r){let{prop:i,defaultProp:a,onChange:o,caller:s}=t,c=i!==void 0,l=xn(o),u=[{...n,state:a}];r&&u.push(r);let[d,f]=w.useReducer((t,n)=>{if(n.type===On)return{...t,state:n.state};let r=e(t,n);return c&&!Object.is(r.state,t.state)&&l(r.state),r},...u),p=d.state,m=w.useRef(p);w.useEffect(()=>{m.current!==p&&(m.current=p,c||l(p))},[p,m,c]);let h=w.useMemo(()=>i===void 0?d:{...d,state:i},[d,i]);return w.useEffect(()=>{c&&!Object.is(i,d.state)&&f({type:On,state:i})},[i,d.state,c]),[h,f]}Cn(kn,`useControllableStateReducer`);var An=Object.defineProperty,H=(e,t)=>An(e,`name`,{value:t,configurable:!0});function jn(e,t){return w.useReducer((e,n)=>t[e][n]??e,e)}H(jn,`useStateMachine`);var Mn=H(e=>{let{present:t,children:n}=e,r=Nn(t),i=typeof n==`function`?n({present:r.isPresent}):w.Children.only(n),a=Fn(r.ref,In(i));return typeof n==`function`||r.isPresent?w.cloneElement(i,{ref:a}):null},`Presence`);function Nn(e){let[t,n]=w.useState(),r=w.useRef(null),i=w.useRef(e),a=w.useRef(`none`),o=w.useRef(void 0),[s,c]=jn(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return w.useEffect(()=>{s===`mounted`?(a.current=o.current??U(r.current),o.current=void 0):a.current=`none`},[s]),V(()=>{let t=r.current,n=i.current;if(n!==e){let r=a.current,s=U(t);e?(o.current=s,c(`MOUNT`)):s===`none`||t?.display===`none`?c(`UNMOUNT`):c(n&&r!==s?`ANIMATION_OUT`:`UNMOUNT`),i.current=e}},[e,c]),V(()=>{if(t){let e,n=t.ownerDocument.defaultView??window,o=H(a=>{let o=U(r.current).includes(CSS.escape(a.animationName));if(a.target===t&&o&&(c(`ANIMATION_END`),!i.current)){let r=t.style.animationFillMode;t.style.animationFillMode=`forwards`,e=n.setTimeout(()=>{t.style.animationFillMode===`forwards`&&(t.style.animationFillMode=r)})}},`handleAnimationEnd`),s=H(e=>{e.target===t&&(a.current=U(r.current))},`handleAnimationStart`);return t.addEventListener(`animationstart`,s),t.addEventListener(`animationcancel`,o),t.addEventListener(`animationend`,o),()=>{n.clearTimeout(e),t.removeEventListener(`animationstart`,s),t.removeEventListener(`animationcancel`,o),t.removeEventListener(`animationend`,o)}}c(`ANIMATION_END`)},[t,c]),{isPresent:[`mounted`,`unmountSuspended`].includes(s),ref:w.useCallback(e=>{if(e){let t=getComputedStyle(e);r.current=t,o.current=U(t)}else r.current=null;n(e)},[])}}H(Nn,`usePresence`);function Pn(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}H(Pn,`setRef`);function Fn(...e){let t=w.useRef(e);return t.current=e,w.useCallback(e=>{let n=t.current,r=!1,i=n.map(t=>{let n=Pn(t,e);return!r&&typeof n==`function`&&(r=!0),n});if(r)return()=>{for(let e=0;e<i.length;e++){let t=i[e];typeof t==`function`?t():Pn(n[e],null)}}},[])}H(Fn,`useStableComposedRefs`);function U(e){return e?.animationName||`none`}H(U,`getAnimationName`);function In(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}H(In,`getElementRef`);var Ln=Object.defineProperty,Rn=(e,t)=>Ln(e,`name`,{value:t,configurable:!0}),zn=w.useId||(()=>void 0),Bn=0;function Vn(e){let[t,n]=w.useState(zn());return V(()=>{e||n(e=>e??String(Bn++))},[e]),e||(t?`radix-${t}`:``)}Rn(Vn,`useId`);var Hn=Object.defineProperty,Un=(e,t)=>Hn(e,`name`,{value:t,configurable:!0});function W(e){let t=w.useRef(e);return w.useEffect(()=>{t.current=e}),w.useMemo(()=>((...e)=>t.current?.(...e)),[])}Un(W,`useCallbackRef`);var Wn=Object.defineProperty,G=(e,t)=>Wn(e,`name`,{value:t,configurable:!0}),Gn=`dismissableLayer.update`,Kn=`dismissableLayer.pointerDownOutside`,qn=`dismissableLayer.focusOutside`,Jn,Yn=w.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),Xn=w.forwardRef(G(function(e,t){let{disableOutsidePointerEvents:n=!1,deferPointerDownOutside:r=!1,onEscapeKeyDown:i,onPointerDownOutside:a,onFocusOutside:o,onInteractOutside:s,onDismiss:c,...l}=e,u=w.useContext(Yn),[d,f]=w.useState(null),p=d?.ownerDocument??globalThis?.document,[,m]=w.useState({}),h=F(t,f),g=Array.from(u.layers),[_]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),v=_?g.indexOf(_):-1,y=d?g.indexOf(d):-1,b=u.layersWithOutsidePointerEventsDisabled.size>0,x=y>=v,S=w.useRef(!1),C=$n(e=>{a?.(e),s?.(e),e.defaultPrevented||c?.()},{ownerDocument:p,deferPointerDownOutside:r,isDeferredPointerDownOutsideRef:S,dismissableSurfaces:u.dismissableSurfaces,shouldHandlePointerDownOutside:w.useCallback(e=>{if(!(e instanceof Node))return!1;let t=[...u.branches].some(t=>t.contains(e));return x&&!t},[u.branches,x])}),T=er(e=>{if(r&&S.current)return;let t=e.target;[...u.branches].some(e=>e.contains(t))||(o?.(e),s?.(e),e.defaultPrevented||c?.())},p),E=d?y===g.length-1:!1,D=W(e=>{e.key===`Escape`&&(i?.(e),!e.defaultPrevented&&c&&(e.preventDefault(),c()))});return w.useEffect(()=>{if(E)return p.addEventListener(`keydown`,D,{capture:!0}),()=>p.removeEventListener(`keydown`,D,{capture:!0})},[p,E,D]),w.useEffect(()=>{if(d)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Jn=p.body.style.pointerEvents,p.body.style.pointerEvents=`none`),u.layersWithOutsidePointerEventsDisabled.add(d)),u.layers.add(d),tr(),()=>{n&&(u.layersWithOutsidePointerEventsDisabled.delete(d),u.layersWithOutsidePointerEventsDisabled.size===0&&(p.body.style.pointerEvents=Jn))}},[d,p,n,u]),w.useEffect(()=>()=>{d&&(u.layers.delete(d),u.layersWithOutsidePointerEventsDisabled.delete(d),tr())},[d,u]),w.useEffect(()=>{let e=G(()=>m({}),`handleUpdate`);return document.addEventListener(Gn,e),()=>document.removeEventListener(Gn,e)},[]),A(L.div,{...l,ref:h,style:{pointerEvents:b?x?`auto`:`none`:void 0,...e.style},onFocusCapture:B(e.onFocusCapture,T.onFocusCapture),onBlurCapture:B(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:B(e.onPointerDownCapture,C.onPointerDownCapture)})},`DismissableLayer`));function Zn(){let e=w.useContext(Yn),[t,n]=w.useState(null);return w.useEffect(()=>{if(t)return e.dismissableSurfaces.add(t),()=>{e.dismissableSurfaces.delete(t)}},[t,e.dismissableSurfaces]),n}G(Zn,`useDismissableLayerSurface`);var Qn=G(()=>!0,`IS_TRUE`);function $n(e,t){let{ownerDocument:n=globalThis?.document,deferPointerDownOutside:r=!1,isDeferredPointerDownOutsideRef:i,dismissableSurfaces:a,shouldHandlePointerDownOutside:o=Qn}=t,s=W(e),c=w.useRef(!1),l=w.useRef(!1),u=w.useRef(new Map),d=w.useRef(()=>{});return w.useEffect(()=>{function e(){l.current=!1,i.current=!1,u.current.clear()}G(e,`resetOutsideInteraction`);function t(){return Array.from(u.current.values()).some(Boolean)}G(t,`isOutsideInteractionIntercepted`);function f(e){if(!l.current)return;let t=e.target;t instanceof Node&&[...a].some(e=>e.contains(t))||u.current.set(e.type,!0),e.type===`click`&&window.setTimeout(()=>{l.current&&d.current()},0)}G(f,`handleInteractionCapture`);function p(e){l.current&&u.current.set(e.type,!1)}G(p,`handleInteractionBubble`);let m=G(a=>{if(a.target&&!c.current){let f=function(){n.removeEventListener(`click`,d.current);let r=t();e(),r||nr(Kn,s,p,{discrete:!0})};if(G(f,`handleAndDispatchPointerDownOutsideEvent`),!o(a.target)){n.removeEventListener(`click`,d.current),e(),c.current=!1;return}let p={originalEvent:a};l.current=!0,i.current=r&&a.button===0,u.current.clear(),!r||a.button!==0?f():(n.removeEventListener(`click`,d.current),d.current=f,n.addEventListener(`click`,d.current,{once:!0}))}else n.removeEventListener(`click`,d.current),e();c.current=!1},`handlePointerDown`),h=[`pointerup`,`mousedown`,`mouseup`,`touchstart`,`touchend`,`click`];for(let e of h)n.addEventListener(e,f,!0),n.addEventListener(e,p);let g=window.setTimeout(()=>{n.addEventListener(`pointerdown`,m)},0);return()=>{window.clearTimeout(g),n.removeEventListener(`pointerdown`,m),n.removeEventListener(`click`,d.current);for(let e of h)n.removeEventListener(e,f,!0),n.removeEventListener(e,p)}},[n,s,r,i,a,o]),{onPointerDownCapture:G(()=>c.current=!0,`onPointerDownCapture`)}}G($n,`usePointerDownOutside`);function er(e,t=globalThis?.document){let n=W(e),r=w.useRef(!1);return w.useEffect(()=>{let e=G(e=>{e.target&&!r.current&&nr(qn,n,{originalEvent:e},{discrete:!1})},`handleFocus`);return t.addEventListener(`focusin`,e),()=>t.removeEventListener(`focusin`,e)},[t,n]),{onFocusCapture:G(()=>r.current=!0,`onFocusCapture`),onBlurCapture:G(()=>r.current=!1,`onBlurCapture`)}}G(er,`useFocusOutside`);function tr(){let e=new CustomEvent(Gn);document.dispatchEvent(e)}G(tr,`dispatchUpdate`);function nr(e,t,n,{discrete:r}){let i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?on(i,a):i.dispatchEvent(a)}G(nr,`handleAndDispatchCustomEvent`);var rr=Object.defineProperty,K=(e,t)=>rr(e,`name`,{value:t,configurable:!0}),ir=`focusScope.autoFocusOnMount`,ar=`focusScope.autoFocusOnUnmount`,or={bubbles:!1,cancelable:!0},sr=w.forwardRef(K(function(e,t){let{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,c]=w.useState(null),l=W(i),u=W(a),d=w.useRef(null),f=F(t,c),p=w.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;w.useEffect(()=>{if(r){let e=function(e){if(p.paused||!s)return;let t=e.target;s.contains(t)?d.current=t:q(d.current,{select:!0})},t=function(e){if(p.paused||!s)return;let t=e.relatedTarget;t!==null&&(s.contains(t)||q(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&q(s)};K(e,`handleFocusIn`),K(t,`handleFocusOut`),K(n,`handleMutations`),document.addEventListener(`focusin`,e),document.addEventListener(`focusout`,t);let r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener(`focusin`,e),document.removeEventListener(`focusout`,t),r.disconnect()}}},[r,s,p.paused]),w.useEffect(()=>{if(s){mr.add(p);let e=document.activeElement;if(!s.contains(e)){let t=new CustomEvent(ir,or);s.addEventListener(ir,l),s.dispatchEvent(t),t.defaultPrevented||(cr(_r(ur(s)),{select:!0}),document.activeElement===e&&q(s))}return()=>{s.removeEventListener(ir,l),setTimeout(()=>{let t=new CustomEvent(ar,or);s.addEventListener(ar,u),s.dispatchEvent(t),t.defaultPrevented||q(e??document.body,{select:!0}),s.removeEventListener(ar,u),mr.remove(p)},0)}}},[s,l,u,p]);let m=w.useCallback(e=>{if(!n&&!r||p.paused)return;let t=e.key===`Tab`&&!e.altKey&&!e.ctrlKey&&!e.metaKey,i=document.activeElement;if(t&&i){let t=e.currentTarget,[r,a]=lr(t);r&&a?!e.shiftKey&&i===a?(e.preventDefault(),n&&q(r,{select:!0})):e.shiftKey&&i===r&&(e.preventDefault(),n&&q(a,{select:!0})):i===t&&e.preventDefault()}},[n,r,p.paused]);return A(L.div,{tabIndex:-1,...o,ref:f,onKeyDown:m})},`FocusScope`));function cr(e,{select:t=!1}={}){let n=document.activeElement;for(let r of e)if(q(r,{select:t}),document.activeElement!==n)return}K(cr,`focusFirst`);function lr(e){let t=ur(e);return[dr(t,e),dr(t.reverse(),e)]}K(lr,`getTabbableEdges`);function ur(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:K(e=>{let t=e.tagName===`INPUT`&&e.type===`hidden`;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP},`acceptNode`)});for(;n.nextNode();)t.push(n.currentNode);return t}K(ur,`getTabbableCandidates`);function dr(e,t){let n=typeof t.checkVisibility==`function`&&t.checkVisibility({checkVisibilityCSS:!0});for(let r of e)if(!(n?!r.checkVisibility({checkVisibilityCSS:!0}):fr(r,{upTo:t})))return r}K(dr,`findVisible`);function fr(e,{upTo:t}){if(getComputedStyle(e).visibility===`hidden`)return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display===`none`)return!0;e=e.parentElement}return!1}K(fr,`isHidden`);function pr(e){return e instanceof HTMLInputElement&&`select`in e}K(pr,`isSelectableInput`);function q(e,{select:t=!1}={}){if(e&&e.focus){let n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&pr(e)&&t&&e.select()}}K(q,`focus`);var mr=hr();function hr(){let e=[];return{add(t){let n=e[0];t!==n&&n?.pause(),e=gr(e,t),e.unshift(t)},remove(t){e=gr(e,t),e[0]?.resume()}}}K(hr,`createFocusScopesStack`);function gr(e,t){let n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}K(gr,`arrayRemove`);function _r(e){return e.filter(e=>e.tagName!==`A`)}K(_r,`removeLinks`);var vr=Object.defineProperty,yr=w.forwardRef(((e,t)=>vr(e,`name`,{value:t,configurable:!0}))(function(e,t){let{container:n,...r}=e,[i,a]=w.useState(!1);V(()=>a(!0),[]);let o=n||i&&globalThis?.document?.body;return o?de.createPortal(A(L.div,{...r,ref:t}),o):null},`Portal`)),br=Object.defineProperty,xr=(e,t)=>br(e,`name`,{value:t,configurable:!0}),Sr=0,Cr=null;function wr(e){return Tr(),e.children}xr(wr,`FocusGuards`);function Tr(){w.useEffect(()=>{Cr||={start:Er(),end:Er()};let{start:e,end:t}=Cr;return document.body.firstElementChild!==e&&document.body.insertAdjacentElement(`afterbegin`,e),document.body.lastElementChild!==t&&document.body.insertAdjacentElement(`beforeend`,t),Sr++,()=>{Sr===1&&(Cr?.start.remove(),Cr?.end.remove(),Cr=null),Sr=Math.max(0,Sr-1)}},[])}xr(Tr,`useFocusGuards`);function Er(){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}xr(Er,`createFocusGuard`);var J=function(){return J=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},J.apply(this,arguments)};function Dr(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function Or(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,a;r<i;r++)(a||!(r in t))&&(a||=Array.prototype.slice.call(t,0,r),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}var kr=`right-scroll-bar-position`,Ar=`width-before-scroll-bar`,jr=`with-scroll-bars-hidden`,Mr=`--removed-body-scroll-bar-size`;function Nr(e,t){return typeof e==`function`?e(t):e&&(e.current=t),e}function Pr(e,t){var n=O(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(e){var t=n.value;t!==e&&(n.value=e,n.callback(e,t))}}}})[0];return n.callback=t,n.facade}var Fr=typeof window<`u`?w.useLayoutEffect:w.useEffect,Ir=new WeakMap;function Lr(e,t){var n=Pr(t||null,function(t){return e.forEach(function(e){return Nr(e,t)})});return Fr(function(){var t=Ir.get(n);if(t){var r=new Set(t),i=new Set(e),a=n.current;r.forEach(function(e){i.has(e)||Nr(e,null)}),i.forEach(function(e){r.has(e)||Nr(e,a)})}Ir.set(n,e)},[e]),n}function Rr(e){return e}function zr(e,t){t===void 0&&(t=Rr);var n=[],r=!1;return{read:function(){if(r)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(e){var i=t(e,r);return n.push(i),function(){n=n.filter(function(e){return e!==i})}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var i=n;n=[],i.forEach(e),t=n}var a=function(){var n=t;t=[],n.forEach(e)},o=function(){return Promise.resolve().then(a)};o(),n={push:function(e){t.push(e),o()},filter:function(e){return t=t.filter(e),n}}}}}function Br(e){e===void 0&&(e={});var t=zr(null);return t.options=J({async:!0,ssr:!1},e),t}var Vr=function(e){var t=e.sideCar,n=Dr(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 w.createElement(r,J({},n))};Vr.isSideCarExport=!0;function Hr(e,t){return e.useMedium(t),Vr}var Ur=Br(),Wr=function(){},Gr=w.forwardRef(function(e,t){var n=w.useRef(null),r=w.useState({onScrollCapture:Wr,onWheelCapture:Wr,onTouchMoveCapture:Wr}),i=r[0],a=r[1],o=e.forwardProps,s=e.children,c=e.className,l=e.removeScrollBar,u=e.enabled,d=e.shards,f=e.sideCar,p=e.noRelative,m=e.noIsolation,h=e.inert,g=e.allowPinchZoom,_=e.as,v=_===void 0?`div`:_,y=e.gapMode,b=Dr(e,[`forwardProps`,`children`,`className`,`removeScrollBar`,`enabled`,`shards`,`sideCar`,`noRelative`,`noIsolation`,`inert`,`allowPinchZoom`,`as`,`gapMode`]),x=f,S=Lr([n,t]),C=J(J({},b),i);return w.createElement(w.Fragment,null,u&&w.createElement(x,{sideCar:Ur,removeScrollBar:l,shards:d,noRelative:p,noIsolation:m,inert:h,setCallbacks:a,allowPinchZoom:!!g,lockRef:n,gapMode:y}),o?w.cloneElement(w.Children.only(s),J(J({},C),{ref:S})):w.createElement(v,J({},C,{className:c,ref:S}),s))});Gr.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Gr.classNames={fullWidth:Ar,zeroRight:kr};var Kr=function(){if(typeof __webpack_nonce__<`u`)return __webpack_nonce__};function qr(){if(!document)return null;var e=document.createElement(`style`);e.type=`text/css`;var t=Kr();return t&&e.setAttribute(`nonce`,t),e}function Jr(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Yr(e){(document.head||document.getElementsByTagName(`head`)[0]).appendChild(e)}var Xr=function(){var e=0,t=null;return{add:function(n){e==0&&(t=qr())&&(Jr(t,n),Yr(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Zr=function(){var e=Xr();return function(t,n){w.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Qr=function(){var e=Zr();return function(t){var n=t.styles,r=t.dynamic;return e(n,r),null}},$r={left:0,top:0,right:0,gap:0},ei=function(e){return parseInt(e||``,10)||0},ti=function(e){var t=window.getComputedStyle(document.body),n=t[e===`padding`?`paddingLeft`:`marginLeft`],r=t[e===`padding`?`paddingTop`:`marginTop`],i=t[e===`padding`?`paddingRight`:`marginRight`];return[ei(n),ei(r),ei(i)]},ni=function(e){if(e===void 0&&(e=`margin`),typeof window>`u`)return $r;var t=ti(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])}},ri=Qr(),ii=`data-scroll-locked`,ai=function(e,t,n,r){var i=e.left,a=e.top,o=e.right,s=e.gap;return n===void 0&&(n=`margin`),`
211
+ .${jr} {
212
+ overflow: hidden ${r};
213
+ padding-right: ${s}px ${r};
214
+ }
215
+ body[${ii}] {
216
+ overflow: hidden ${r};
217
+ overscroll-behavior: contain;
218
+ ${[t&&`position: relative ${r};`,n===`margin`&&`
219
+ padding-left: ${i}px;
220
+ padding-top: ${a}px;
221
+ padding-right: ${o}px;
222
+ margin-left:0;
223
+ margin-top:0;
224
+ margin-right: ${s}px ${r};
225
+ `,n===`padding`&&`padding-right: ${s}px ${r};`].filter(Boolean).join(``)}
226
+ }
227
+
228
+ .${kr} {
229
+ right: ${s}px ${r};
230
+ }
231
+
232
+ .${Ar} {
233
+ margin-right: ${s}px ${r};
234
+ }
235
+
236
+ .${kr} .${kr} {
237
+ right: 0 ${r};
238
+ }
239
+
240
+ .${Ar} .${Ar} {
241
+ margin-right: 0 ${r};
242
+ }
243
+
244
+ body[${ii}] {
245
+ ${Mr}: ${s}px;
246
+ }
247
+ `},oi=function(){var e=parseInt(document.body.getAttribute(`data-scroll-locked`)||`0`,10);return isFinite(e)?e:0},si=function(){w.useEffect(function(){return document.body.setAttribute(ii,(oi()+1).toString()),function(){var e=oi()-1;e<=0?document.body.removeAttribute(ii):document.body.setAttribute(ii,e.toString())}},[])},ci=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?`margin`:r;si();var a=w.useMemo(function(){return ni(i)},[i]);return w.createElement(ri,{styles:ai(a,!t,i,n?``:`!important`)})},li=!1;if(typeof window<`u`)try{var ui=Object.defineProperty({},"passive",{get:function(){return li=!0,!0}});window.addEventListener(`test`,ui,ui),window.removeEventListener(`test`,ui,ui)}catch{li=!1}var Y=li?{passive:!1}:!1,di=function(e){return e.tagName===`TEXTAREA`},fi=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!==`hidden`&&!(n.overflowY===n.overflowX&&!di(e)&&n[t]===`visible`)},pi=function(e){return fi(e,`overflowY`)},mi=function(e){return fi(e,`overflowX`)},hi=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<`u`&&r instanceof ShadowRoot&&(r=r.host),vi(e,r)){var i=yi(e,r);if(i[1]>i[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},gi=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},_i=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},vi=function(e,t){return e===`v`?pi(t):mi(t)},yi=function(e,t){return e===`v`?gi(t):_i(t)},bi=function(e,t){return e===`h`&&t===`rtl`?-1:1},xi=function(e,t,n,r,i){var a=bi(e,window.getComputedStyle(t).direction),o=a*r,s=n.target,c=t.contains(s),l=!1,u=o>0,d=0,f=0;do{if(!s)break;var p=yi(e,s),m=p[0],h=p[1]-p[2]-a*m;(m||h)&&vi(e,s)&&(d+=h,f+=m);var g=s.parentNode;s=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!c&&s!==document.body||c&&(t.contains(s)||t===s));return(u&&(i&&Math.abs(d)<1||!i&&o>d)||!u&&(i&&Math.abs(f)<1||!i&&-o>f))&&(l=!0),l},Si=function(e){return`changedTouches`in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Ci=function(e){return[e.deltaX,e.deltaY]},wi=function(e){return e&&`current`in e?e.current:e},Ti=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Ei=function(e){return`
248
+ .block-interactivity-${e} {pointer-events: none;}
249
+ .allow-interactivity-${e} {pointer-events: all;}
250
+ `},Di=0,X=[];function Oi(e){var t=w.useRef([]),n=w.useRef([0,0]),r=w.useRef(),i=w.useState(Di++)[0],a=w.useState(Qr)[0],o=w.useRef(e);w.useEffect(function(){o.current=e},[e]),w.useEffect(function(){if(e.inert){document.body.classList.add(`block-interactivity-${i}`);var t=Or([e.lockRef.current],(e.shards||[]).map(wi),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add(`allow-interactivity-${i}`)}),function(){document.body.classList.remove(`block-interactivity-${i}`),t.forEach(function(e){return e.classList.remove(`allow-interactivity-${i}`)})}}},[e.inert,e.lockRef.current,e.shards]);var s=w.useCallback(function(e,t){if(`touches`in e&&e.touches.length===2||e.type===`wheel`&&e.ctrlKey)return!o.current.allowPinchZoom;var i=Si(e),a=n.current,s=`deltaX`in e?e.deltaX:a[0]-i[0],c=`deltaY`in e?e.deltaY:a[1]-i[1],l,u=e.target,d=Math.abs(s)>Math.abs(c)?`h`:`v`;if(`touches`in e&&d===`h`&&u.type===`range`)return!1;var f=window.getSelection(),p=f&&f.anchorNode;if(p&&(p===u||p.contains(u)))return!1;var m=hi(d,u);if(!m)return!0;if(m?l=d:(l=d===`v`?`h`:`v`,m=hi(d,u)),!m)return!1;if(!r.current&&`changedTouches`in e&&(s||c)&&(r.current=l),!l)return!0;var h=r.current||l;return xi(h,t,e,h===`h`?s:c,!0)},[]),c=w.useCallback(function(e){var n=e;if(X.length&&X[X.length-1]===a){var r=`deltaY`in n?Ci(n):Si(n),i=t.current.filter(function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&Ti(e.delta,r)})[0];if(i&&i.should){n.cancelable&&n.preventDefault();return}if(!i){var c=(o.current.shards||[]).map(wi).filter(Boolean).filter(function(e){return e.contains(n.target)});(c.length>0?s(n,c[0]):!o.current.noIsolation)&&n.cancelable&&n.preventDefault()}}},[]),l=w.useCallback(function(e,n,r,i){var a={name:e,delta:n,target:r,should:i,shadowParent:ki(r)};t.current.push(a),setTimeout(function(){t.current=t.current.filter(function(e){return e!==a})},1)},[]),u=w.useCallback(function(e){n.current=Si(e),r.current=void 0},[]),d=w.useCallback(function(t){l(t.type,Ci(t),t.target,s(t,e.lockRef.current))},[]),f=w.useCallback(function(t){l(t.type,Si(t),t.target,s(t,e.lockRef.current))},[]);w.useEffect(function(){return X.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener(`wheel`,c,Y),document.addEventListener(`touchmove`,c,Y),document.addEventListener(`touchstart`,u,Y),function(){X=X.filter(function(e){return e!==a}),document.removeEventListener(`wheel`,c,Y),document.removeEventListener(`touchmove`,c,Y),document.removeEventListener(`touchstart`,u,Y)}},[]);var p=e.removeScrollBar,m=e.inert;return w.createElement(w.Fragment,null,m?w.createElement(a,{styles:Ei(i)}):null,p?w.createElement(ci,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function ki(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}var Ai=Hr(Ur,Oi),ji=w.forwardRef(function(e,t){return w.createElement(Gr,J({},e,{ref:t,sideCar:Ai}))});ji.classNames=Gr.classNames;var Mi=function(e){return typeof document>`u`?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},Z=new WeakMap,Ni=new WeakMap,Pi={},Fi=0,Ii=function(e){return e&&(e.host||Ii(e.parentNode))},Li=function(e,t){return t.map(function(t){if(e.contains(t))return t;var n=Ii(t);return n&&e.contains(n)?n:(console.error(`aria-hidden`,t,`in not contained inside`,e,`. Doing nothing`),null)}).filter(function(e){return!!e})},Ri=function(e,t,n,r){var i=Li(t,Array.isArray(e)?e:[e]);Pi[n]||(Pi[n]=new WeakMap);var a=Pi[n],o=[],s=new Set,c=new Set(i),l=function(e){e&&!s.has(e)&&(s.add(e),l(e.parentNode))};i.forEach(l);var u=function(e){e&&!c.has(e)&&Array.prototype.forEach.call(e.children,function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),i=t!==null&&t!==`false`,c=(Z.get(e)||0)+1,l=(a.get(e)||0)+1;Z.set(e,c),a.set(e,l),o.push(e),c===1&&i&&Ni.set(e,!0),l===1&&e.setAttribute(n,`true`),i||e.setAttribute(r,`true`)}catch(t){console.error(`aria-hidden: cannot operate on `,e,t)}})};return u(t),s.clear(),Fi++,function(){o.forEach(function(e){var t=Z.get(e)-1,i=a.get(e)-1;Z.set(e,t),a.set(e,i),t||(Ni.has(e)||e.removeAttribute(r),Ni.delete(e)),i||e.removeAttribute(n)}),Fi--,Fi||(Z=new WeakMap,Z=new WeakMap,Ni=new WeakMap,Pi={})}},zi=function(e,t,n){n===void 0&&(n=`data-aria-hidden`);var r=Array.from(Array.isArray(e)?e:[e]),i=t||Mi(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll(`[aria-live], script`))),Ri(r,i,n,`aria-hidden`)):function(){return null}},Bi=Object.defineProperty,Q=(e,t)=>Bi(e,`name`,{value:t,configurable:!0}),Vi=`Dialog`,[Hi,Ui]=ln(Vi),[Wi,$]=Hi(Vi),Gi=Q(e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=w.useRef(null),c=w.useRef(null),[l,u]=Tn({prop:r,defaultProp:i??!1,onChange:a,caller:Vi}),[d,f]=w.useState(0),[p,m]=w.useState(0);return A(Wi,{scope:t,triggerRef:s,contentRef:c,contentId:Vn(),titleId:Vn(),descriptionId:Vn(),titlePresent:d>0,descriptionPresent:p>0,setTitleCount:f,setDescriptionCount:m,open:l,onOpenChange:u,onOpenToggle:w.useCallback(()=>u(e=>!e),[u]),modal:o,children:n})},`Dialog`),Ki=`DialogPortal`,[qi,Ji]=Hi(Ki,{forceMount:void 0}),Yi=Q(e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=$(Ki,t);return A(qi,{scope:t,forceMount:n,children:w.Children.map(r,e=>A(Mn,{present:n||a.open,children:A(yr,{asChild:!0,container:i,children:e})}))})},`DialogPortal`),Xi=`DialogOverlay`,Zi=w.forwardRef(Q(function(e,t){let n=Ji(Xi,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=$(Xi,e.__scopeDialog);return a.modal?A(Mn,{present:r||a.open,children:A($i,{...i,ref:t})}):null},`DialogOverlay`)),Qi=Wt(`DialogOverlay.RemoveScroll`),$i=w.forwardRef(Q(function(e,t){let{__scopeDialog:n,...r}=e,i=$(Xi,n),a=F(t,Zn());return A(ji,{as:Qi,allowPinchZoom:!0,shards:[i.contentRef],children:A(L.div,{"data-state":da(i.open),...r,ref:a,style:{pointerEvents:`auto`,...r.style}})})},`DialogOverlayImpl`)),ea=`DialogContent`,ta=w.forwardRef(Q(function(e,t){let n=Ji(ea,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=$(ea,e.__scopeDialog);return A(Mn,{present:r||a.open,children:a.modal?A(na,{...i,ref:t}):A(ra,{...i,ref:t})})},`DialogContent`)),na=w.forwardRef(Q(function(e,t){let n=$(ea,e.__scopeDialog),r=w.useRef(null),i=F(t,n.contentRef,r);return w.useEffect(()=>{let e=r.current;if(e)return zi(e)},[]),A(ia,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,onCloseAutoFocus:B(e.onCloseAutoFocus,e=>{e.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:B(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:B(e.onFocusOutside,e=>e.preventDefault())})},`DialogContentModal`)),ra=w.forwardRef(Q(function(e,t){let n=$(ea,e.__scopeDialog),r=w.useRef(!1),i=w.useRef(!1);return A(ia,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})},`DialogContentNonModal`)),ia=w.forwardRef(Q(function(e,t){let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=e,s=$(ea,n);return Tr(),A(k,{children:A(sr,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:A(Xn,{role:`dialog`,id:s.contentId,"aria-describedby":s.descriptionPresent?s.descriptionId:void 0,"aria-labelledby":s.titlePresent?s.titleId:void 0,"data-state":da(s.open),...o,ref:t,deferPointerDownOutside:!0,onDismiss:()=>s.onOpenChange(!1)})})})},`DialogContentImpl`)),aa=`DialogTitle`,oa=w.forwardRef(Q(function(e,t){let{__scopeDialog:n,...r}=e,i=$(aa,n),{setTitleCount:a}=i;return V(()=>(a(e=>e+1),()=>a(e=>e-1)),[a]),A(L.h2,{id:i.titleId,...r,ref:t})},`DialogTitle`)),sa=`DialogDescription`,ca=w.forwardRef(Q(function(e,t){let{__scopeDialog:n,...r}=e,i=$(sa,n),{setDescriptionCount:a}=i;return V(()=>(a(e=>e+1),()=>a(e=>e-1)),[a]),A(L.p,{id:i.descriptionId,...r,ref:t})},`DialogDescription`)),la=`DialogClose`,ua=w.forwardRef(Q(function(e,t){let{__scopeDialog:n,...r}=e,i=$(la,n);return A(L.button,{type:`button`,...r,ref:t,onClick:B(e.onClick,()=>i.onOpenChange(!1))})},`DialogClose`));function da(e){return e?`open`:`closed`}Q(da,`getState`);var fa=M(Zi)`
251
+ position: fixed;
252
+ inset: 0;
253
+ z-index: ${({theme:e})=>e.z.overlay};
254
+ background: oklch(0 0 0 / 0.5);
255
+ backdrop-filter: blur(2px);
256
+ `,pa=M(ta)`
257
+ position: fixed;
258
+ z-index: ${({theme:e})=>e.z.dialog};
259
+ top: 50%;
260
+ left: 50%;
261
+ transform: translate(-50%, -50%);
262
+ width: min(${({$width:e})=>e}, calc(100vw - 32px));
263
+ max-height: calc(100vh - 64px);
264
+ display: flex;
265
+ flex-direction: column;
266
+ background: ${({theme:e})=>e.color.panel};
267
+ border: 1px solid ${({theme:e})=>e.color.ruleStrong};
268
+ border-radius: ${({theme:e})=>e.radius.panel};
269
+ box-shadow: 0 12px 40px oklch(0 0 0 / 0.35);
270
+ `,ma=M.div`
271
+ display: flex;
272
+ align-items: center;
273
+ gap: ${({theme:e})=>e.space(2)};
274
+ padding: ${({theme:e})=>`${e.space(2)} ${e.space(2)} ${e.space(2)} ${e.space(3)}`};
275
+ border-bottom: 1px solid ${({theme:e})=>e.color.rule};
276
+ background: ${({theme:e})=>e.color.panelSunk};
277
+ `,ha=M.div`
278
+ padding: ${({theme:e})=>e.space(3)};
279
+ overflow-y: auto;
280
+ `,ga=M.div`
281
+ display: flex;
282
+ justify-content: flex-end;
283
+ gap: ${({theme:e})=>e.space(2)};
284
+ padding: ${({theme:e})=>`${e.space(2)} ${e.space(3)}`};
285
+ border-top: 1px solid ${({theme:e})=>e.color.rule};
286
+ background: ${({theme:e})=>e.color.panelSunk};
287
+ `,_a=M(ca)`
288
+ margin: 0 0 ${({theme:e})=>e.space(3)};
289
+ font-size: 12px;
290
+ color: ${({theme:e})=>e.color.inkDim};
291
+ `;function va({open:e,onOpenChange:t,title:n,description:r,footer:i,width:a=`560px`,children:o}){return A(Gi,{open:e,onOpenChange:t,children:j(Yi,{children:[A(fa,{}),j(pa,{$width:a,children:[j(ma,{children:[A(oa,{asChild:!0,children:A(b,{as:`h2`,children:n})}),A(v,{}),A(ua,{asChild:!0,children:A(_,{type:`button`,$variant:`ghost`,$size:`sm`,"aria-label":`Close`,children:A(rt,{})})})]}),j(ha,{children:[r===void 0?null:A(_a,{children:r}),o]}),i===void 0?null:A(ga,{children:i})]})]})})}var ya=M.p`
292
+ font-size: 13px;
293
+ color: ${({theme:e})=>e.color.inkDim};
294
+ `;function ba({open:e,onOpenChange:t,title:n,body:r,confirmLabel:i,busy:a,onConfirm:o}){return A(va,{open:e,onOpenChange:t,title:n,width:`420px`,footer:j(k,{children:[A(h,{type:`button`,onClick:()=>t(!1),children:`Cancel`}),A(h,{type:`button`,$variant:`danger`,disabled:a===!0,onClick:o,children:i})]}),children:A(ya,{children:r})})}var xa={systemd:`systemd is capturing this process, so a restart asks the manager to bring the unit back rather than signalling the gateway itself.`,container:`This gateway is running in a container, so a restart is an exit and the container's restart policy decides what happens next.`,none:`Nothing is supervising this process. It was started directly, and whatever stops it leaves it stopped.`},Sa=M.hr`
295
+ flex: none;
296
+ border: 0;
297
+ margin: 0;
298
+ height: 1px;
299
+ align-self: stretch;
300
+ background: ${({theme:e})=>e.color.rule};
301
+
302
+ /* The rail turns on its side below 720px, and so does the rule that closes it. */
303
+ @media (max-width: 720px) {
304
+ height: auto;
305
+ width: 1px;
306
+ margin-left: ${({theme:e})=>e.space(2)};
307
+ }
308
+ `,Ca=M.div`
309
+ display: flex;
310
+ flex-direction: column;
311
+ gap: 6px;
312
+ padding-top: ${({theme:e})=>e.space(2)};
313
+
314
+ @media (max-width: 720px) {
315
+ padding-top: 0;
316
+ padding-left: ${({theme:e})=>e.space(2)};
317
+ flex-direction: row;
318
+ align-items: center;
319
+ }
320
+ `,wa=M(h)`
321
+ justify-content: flex-start;
322
+ width: 100%;
323
+
324
+ @media (max-width: 720px) {
325
+ width: auto;
326
+ }
327
+ `,Ta=M.p`
328
+ font-size: 10.5px;
329
+ line-height: 1.3;
330
+ color: ${({theme:e})=>e.color.warn};
331
+ `,Ea=M.p`
332
+ font-size: 10.5px;
333
+ line-height: 1.3;
334
+ color: ${({theme:e})=>e.color.down};
335
+ `,Da=M.p`
336
+ font-size: 10.5px;
337
+ line-height: 1.3;
338
+ color: ${({theme:e})=>e.color.inkDim};
339
+ ${y}
340
+ `,Oa=M.span`
341
+ flex: none;
342
+ font-size: 10.5px;
343
+ line-height: 1.3;
344
+ color: ${({theme:e})=>e.color.inkFaint};
345
+ padding: 0 ${({theme:e})=>e.space(2)} 6px;
346
+
347
+ @media (max-width: 720px) {
348
+ padding: 0 ${({theme:e})=>e.space(2)};
349
+ }
350
+ `,ka=M.p`
351
+ font-size: 10.5px;
352
+ line-height: 1.3;
353
+ color: ${({theme:e})=>e.color.inkDim};
354
+ `,Aa=9e4;async function ja(){try{return(await fetch(`/health`,{cache:`no-store`})).ok}catch{return!1}}function Ma({pollMs:e=750}){let t=p(),n=l(),r=a(),[i,o]=O(null),[s,c]=O(!1),[u,d]=O(!1),[f,h]=O(`idle`),g=t.data;re(()=>{if(!s)return;let t=!1,n,r=!1,i=0,a=Math.max(1,Math.ceil(Aa/e)),o=async()=>{let s=await ja();if(!t){if(!r&&!s)r=!0,h(`returning`);else if(r&&s){window.location.reload();return}if(i+=1,i>=a){h(`lost`),c(!1);return}n=setTimeout(()=>void o(),e)}};return n=setTimeout(()=>void o(),e),()=>{t=!0,n!==void 0&&clearTimeout(n)}},[s,e]);let _=()=>{h(`leaving`),n.mutate(void 0,{onSuccess:()=>c(!0),onError:()=>h(`idle`)})};return u?j(k,{children:[A(v,{}),g===void 0?null:j(Oa,{children:[`omnigateway v`,g.version]}),A(Sa,{}),A(Ca,{children:j(m,{$gap:1,children:[A(b,{children:`Gateway stopped`}),j(ka,{children:[`Nothing on this screen will update again, and nothing here can start it: that needs`,` `,g?.supervisor===`container`?`the host that runs this container`:`a shell on the machine it runs on`,`.`]})]})})]}):j(k,{children:[A(v,{}),g===void 0?null:j(Oa,{children:[`omnigateway v`,g.version]}),A(Sa,{}),j(Ca,{title:g===void 0?void 0:xa[g.supervisor],children:[j(wa,{type:`button`,$size:`sm`,"aria-label":`Restart gateway`,disabled:g===void 0||!g.canRestart||n.isPending||s,onClick:()=>o(`restart`),children:[A(qe,{}),`Restart`]}),j(wa,{type:`button`,$size:`sm`,$variant:`danger`,"aria-label":`Shut down gateway`,disabled:g===void 0||!g.canShutdown||r.isPending||s,onClick:()=>o(`shutdown`),children:[A(Ge,{}),`Shut down`]}),g?.note===void 0?null:A(Ta,{children:g.note}),f===`leaving`?A(Da,{role:`status`,children:`Restarting. Waiting for the gateway to stop answering.`}):f===`returning`?A(Da,{role:`status`,children:`The gateway has stopped answering. Waiting for it to come back, then this page reloads.`}):f===`lost`?A(Ea,{role:`alert`,children:`The gateway has not come back. Reload this page once it is running again, or check the machine it runs on.`}):null,n.isError?A(Ea,{role:`alert`,children:S(n.error)}):null,r.isError?A(Ea,{role:`alert`,children:S(r.error)}):null]}),A(ba,{open:i===`restart`,onOpenChange:e=>{e||o(null)},title:`Restart gateway`,body:`${g===void 0?``:`${xa[g.supervisor]} `}Requests in flight are dropped when the process goes. This console waits for the gateway to stop answering and to answer again, then reloads itself.`,confirmLabel:`Restart now`,busy:n.isPending,onConfirm:()=>{o(null),_()}}),A(ba,{open:i===`shutdown`,onOpenChange:e=>{e||o(null)},title:`Shut down gateway`,body:g?.supervisor===`container`?`Stopping the only process in this container takes this dashboard with it, and the dashboard is what would have restarted the gateway. Unless the container's restart policy brings it back, getting it running again needs access to the host.`:`The gateway stops serving and stays stopped. This console goes with it, so starting the gateway again needs a shell on the machine it runs on.`,confirmLabel:`Shut down now`,busy:r.isPending,onConfirm:()=>{o(null),r.mutate(void 0,{onSuccess:()=>d(!0)})}})]})}var Na=[{to:`/`,label:`Rack`,blurb:`Live state of every account and model`,Icon:Te},{to:`/accounts`,label:`Accounts`,blurb:`Provider credentials and their health`,Icon:je},{to:`/models`,label:`Models`,blurb:`Virtual models, targets, and routing`,Icon:ke},{to:`/keys`,label:`Keys`,blurb:`Gateway API keys and their limits`,Icon:Le},{to:`/usage`,label:`Usage`,blurb:`Requests, tokens, and spend over time`,Icon:Fe},{to:`/logs`,label:`Logs`,blurb:`Recent requests, one row each`,Icon:Ye},{to:`/console`,label:`Console`,blurb:`The gateway's own output, as it was printed`,Icon:tt},{to:`/settings`,label:`Settings`,blurb:`Routing weights, retries, retention`,Icon:Ze},{to:`/database`,label:`Database`,blurb:`Size, snapshots, and retention`,Icon:Ne}],Pa=M.nav`
355
+ grid-area: rail;
356
+ display: flex;
357
+ flex-direction: column;
358
+ gap: 2px;
359
+ padding: ${({theme:e})=>e.space(2)};
360
+ border-right: 1px solid ${({theme:e})=>e.color.rule};
361
+ background: ${({theme:e})=>e.color.panel};
362
+ overflow-y: auto;
363
+
364
+ @media (max-width: 720px) {
365
+ flex-direction: row;
366
+ overflow-x: auto;
367
+ border-right: 0;
368
+ border-bottom: 1px solid ${({theme:e})=>e.color.rule};
369
+ }
370
+ `,Fa=ce`
371
+ display: flex;
372
+ align-items: center;
373
+ line-height: 1;
374
+ gap: ${({theme:e})=>e.space(2)};
375
+ padding: 7px ${({theme:e})=>e.space(2)};
376
+ border-radius: ${({theme:e})=>e.radius.control};
377
+ border-left: 2px solid transparent;
378
+ color: ${({theme:e})=>e.color.inkDim};
379
+ font-size: 12.5px;
380
+ font-weight: 500;
381
+ white-space: nowrap;
382
+ transition:
383
+ background 120ms ease,
384
+ color 120ms ease;
385
+
386
+ svg {
387
+ width: 15px;
388
+ height: 15px;
389
+ flex: none;
390
+ transform: translateY(-1px);
391
+ }
392
+ `,Ia=M(s)`
393
+ ${Fa}
394
+
395
+ &:hover {
396
+ background: ${({theme:e})=>e.color.panelSunk};
397
+ color: ${({theme:e})=>e.color.ink};
398
+ }
399
+
400
+ &[data-status="active"] {
401
+ background: ${({theme:e})=>e.color.accentWash};
402
+ border-left-color: ${({theme:e})=>e.color.accent};
403
+ color: ${({theme:e})=>e.color.accent};
404
+ }
405
+ `,La=M.button`
406
+ ${Fa}
407
+ align-items: flex-start;
408
+ width: 100%;
409
+ text-align: left;
410
+ white-space: normal;
411
+ background: none;
412
+ border-top: 0;
413
+ border-right: 0;
414
+ border-bottom: 0;
415
+ color: ${({theme:e})=>e.color.inkFaint};
416
+ cursor: not-allowed;
417
+ font-family: inherit;
418
+
419
+ svg {
420
+ margin-top: 2px;
421
+ }
422
+ `,Ra=M.span`
423
+ display: flex;
424
+ flex-direction: column;
425
+ gap: 2px;
426
+ min-width: 0;
427
+ `,za=M.span`
428
+ font-size: 10.5px;
429
+ font-weight: 400;
430
+ line-height: 1.3;
431
+ color: ${({theme:e})=>e.color.warn};
432
+ `;function Ba(){let e=t();return j(Pa,{"aria-label":`Console sections`,children:[Na.map(({to:e,label:t,blurb:n,Icon:r})=>j(Ia,{to:e,title:n,activeOptions:{exact:e===`/`},children:[A(r,{}),t]},e)),Lt(e.data??[]).map(({id:e,label:t,disabledReason:n})=>n===null?j(Ia,{to:It(e),title:`Provided by the ${e} plugin`,children:[A(De,{}),t]},e):j(La,{type:`button`,disabled:!0,children:[A(De,{}),j(Ra,{children:[t,A(za,{children:n})]})]},e)),A(Ma,{})]})}var Va=M.div`
433
+ display: grid;
434
+ grid-template-areas:
435
+ "chassis chassis"
436
+ "rail main";
437
+ grid-template-columns: 168px minmax(0, 1fr);
438
+ grid-template-rows: auto minmax(0, 1fr);
439
+ height: 100vh;
440
+ min-height: 0;
441
+ overflow: hidden;
442
+
443
+ @media (max-width: 720px) {
444
+ grid-template-areas:
445
+ "chassis"
446
+ "rail"
447
+ "main";
448
+ grid-template-columns: minmax(0, 1fr);
449
+ grid-template-rows: auto auto minmax(0, 1fr);
450
+ }
451
+ `,Ha=M.main`
452
+ grid-area: main;
453
+ padding: ${({theme:e})=>e.space(4)};
454
+ display: flex;
455
+ flex-direction: column;
456
+ gap: ${({theme:e})=>e.space(4)};
457
+ min-width: 0;
458
+ min-height: 0;
459
+ overflow-y: auto;
460
+
461
+ @media (max-width: 720px) {
462
+ padding: ${({theme:e})=>e.space(3)};
463
+ }
464
+ `;function Ua({children:e}){return j(Va,{"data-testid":`rack-shell`,children:[A(Ft,{}),A(Ba,{}),A(Ha,{children:e})]})}var Wa=M.div`
465
+ display: flex;
466
+ align-items: flex-end;
467
+ gap: ${({theme:e})=>e.space(3)};
468
+ flex-wrap: wrap;
469
+ `,Ga=M.h1`
470
+ font-size: 20px;
471
+ font-weight: 600;
472
+ font-stretch: 88%;
473
+ letter-spacing: -0.01em;
474
+ `,Ka=M.p`
475
+ font-size: 13px;
476
+ color: ${({theme:e})=>e.color.inkDim};
477
+ max-width: 68ch;
478
+ `,qa=M.div`
479
+ display: flex;
480
+ flex-direction: column;
481
+ gap: 6px;
482
+ min-width: 0;
483
+ `;function Ja({legend:e,title:t,summary:n,actions:r}){return j(Wa,{children:[j(qa,{children:[A(b,{children:e}),A(Ga,{children:t}),A(Ka,{children:n})]}),A(v,{}),r]})}export{ue as _,Tn as a,P as b,ln as c,Pt as d,xt as f,le as g,at as h,va as i,L as l,lt as m,Ua as n,V as o,vt as p,ba as r,B as s,Ja as t,F as u,Ze as v,Ne as y};
@@ -1,4 +1,4 @@
1
- import{_ as e}from"./Panel-BV18WuL1.js";import{jsx as t,jsxs as n}from"react/jsx-runtime";import r from"styled-components";var i=r.div`
1
+ import{_ as e}from"./Panel-CWmOTDAP.js";import{jsx as t,jsxs as n}from"react/jsx-runtime";import r from"styled-components";var i=r.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  gap: 6px;
@@ -1,4 +1,4 @@
1
- import{A as e,L as t,M as n,N as r,P as i,f as a,j as o,l as s,p as c,t as l,u,z as d}from"./Lamp-Drd1fFwQ.js";import{C as f,_ as p,b as m,v as h,w as g}from"./Panel-BV18WuL1.js";import{n as _,r as v,t as y}from"./TokenBreakdown-BIwuEVs8.js";import{n as b,t as x}from"./Chip-77Q04h7S.js";import{i as S,n as C,r as w,t as T}from"./Table-CVDZ69Zx.js";import{useEffect as E,useState as D}from"react";import{Fragment as O,jsx as k,jsxs as A}from"react/jsx-runtime";import j from"styled-components";function M(e){let[t,n]=D(Date.now);return E(()=>{if(!e)return;n(Date.now());let t=window.setInterval(()=>n(Date.now()),1e3);return()=>window.clearInterval(t)},[e]),t}function N(e,t,n){if(t.length===0||e.requestedModel.toLowerCase().includes(t)||(e.resolvedModel??``).toLowerCase().includes(t)||(e.errorCode??``).toLowerCase().includes(t))return!0;if(n===void 0)return!1;let r=e.credentialId==null?``:n.accounts.get(e.credentialId)??``,i=e.apiKeyId==null?``:n.keys.get(e.apiKeyId)??e.apiKeyId;return r.toLowerCase().includes(t)||i.toLowerCase().includes(t)}function P(e,t,n,r){let i=n.trim().toLowerCase();return e.filter(e=>(t!==`failed`||s(e))&&N(e,i,r))}function F({log:e}){return k(C,{$align:`right`,$mono:!0,...u(e)?{"aria-label":`processing`}:{title:v(e)},children:u(e)?k(y,{}):k(_,{tokens:e})})}function I({rows:o,now:s,names:f,onOpen:_}){return A(T,{children:[k(`thead`,{children:A(`tr`,{children:[k(w,{}),k(w,{$align:`right`,children:`Time`}),k(w,{children:`Requested`}),k(w,{children:`Routed to`}),f===void 0?null:A(O,{children:[k(w,{children:`Account`}),k(w,{children:`Key`})]}),k(w,{$align:`right`,children:`Try`}),k(w,{$align:`right`,children:`TTFT`}),k(w,{$align:`right`,children:`Total`}),k(w,{$align:`right`,children:`Tokens`}),k(w,{$align:`right`,children:`Cost`}),k(w,{children:`Outcome`})]})}),k(`tbody`,{children:o.map(o=>A(S,{$selectable:!0,onClick:()=>_(o),children:[k(C,{children:k(l,{state:c(o),label:a(o)})}),k(C,{$align:`right`,$mono:!0,title:n(o.at),children:e(o.at)}),k(C,{$mono:!0,children:k(g,{style:{display:`block`,maxWidth:`20ch`},children:o.requestedModel||`—`})}),k(C,{children:o.resolvedProvider===null?k(p,{children:u(o)?`routing…`:`not routed`}):A(m,{$gap:1,children:[k(b,{provider:o.resolvedProvider}),k(h,{$dim:!0,children:o.resolvedModel??`—`})]})}),f===void 0?null:A(O,{children:[k(C,{children:k(g,{style:{display:`block`,maxWidth:`18ch`},children:o.credentialId==null?`—`:f.accounts.get(o.credentialId)??d(o.credentialId)})}),k(C,{children:k(g,{style:{display:`block`,maxWidth:`16ch`},title:o.apiKeyId??void 0,children:o.apiKeyId==null?`—`:f.keys.get(o.apiKeyId)??d(o.apiKeyId)})})]}),k(C,{$align:`right`,$mono:!0,children:u(o)?`—`:o.attempts}),k(C,{$align:`right`,$mono:!0,children:u(o)?`—`:i(o.ttftMs)}),k(C,{$align:`right`,$mono:!0,children:u(o)?r(Math.max(0,s-o.at)):i(o.durationMs)}),k(F,{log:o}),k(C,{$align:`right`,$mono:!0,children:u(o)?`—`:t(o.costUsd)}),k(C,{children:u(o)?k(x,{$tone:`accent`,children:`live`}):o.errorCode===null?k(x,{$tone:`ok`,children:o.status}):k(x,{$tone:`down`,children:o.errorCode})})]},o.id))})]})}var L=j.dl`
1
+ import{A as e,L as t,M as n,N as r,P as i,f as a,j as o,l as s,p as c,t as l,u,z as d}from"./Lamp-DsUSnxN4.js";import{C as f,_ as p,b as m,v as h,w as g}from"./Panel-CWmOTDAP.js";import{n as _,r as v,t as y}from"./TokenBreakdown-DT7or6C9.js";import{n as b,t as x}from"./Chip-roGX6zyg.js";import{i as S,n as C,r as w,t as T}from"./Table-CVDZ69Zx.js";import{useEffect as E,useState as D}from"react";import{Fragment as O,jsx as k,jsxs as A}from"react/jsx-runtime";import j from"styled-components";function M(e){let[t,n]=D(Date.now);return E(()=>{if(!e)return;n(Date.now());let t=window.setInterval(()=>n(Date.now()),1e3);return()=>window.clearInterval(t)},[e]),t}function N(e,t,n){if(t.length===0||e.requestedModel.toLowerCase().includes(t)||(e.resolvedModel??``).toLowerCase().includes(t)||(e.errorCode??``).toLowerCase().includes(t))return!0;if(n===void 0)return!1;let r=e.credentialId==null?``:n.accounts.get(e.credentialId)??``,i=e.apiKeyId==null?``:n.keys.get(e.apiKeyId)??e.apiKeyId;return r.toLowerCase().includes(t)||i.toLowerCase().includes(t)}function P(e,t,n,r){let i=n.trim().toLowerCase();return e.filter(e=>(t!==`failed`||s(e))&&N(e,i,r))}function F({log:e}){return k(C,{$align:`right`,$mono:!0,...u(e)?{"aria-label":`processing`}:{title:v(e)},children:u(e)?k(y,{}):k(_,{tokens:e})})}function I({rows:o,now:s,names:f,onOpen:_}){return A(T,{children:[k(`thead`,{children:A(`tr`,{children:[k(w,{}),k(w,{$align:`right`,children:`Time`}),k(w,{children:`Requested`}),k(w,{children:`Routed to`}),f===void 0?null:A(O,{children:[k(w,{children:`Account`}),k(w,{children:`Key`})]}),k(w,{$align:`right`,children:`Try`}),k(w,{$align:`right`,children:`TTFT`}),k(w,{$align:`right`,children:`Total`}),k(w,{$align:`right`,children:`Tokens`}),k(w,{$align:`right`,children:`Cost`}),k(w,{children:`Outcome`})]})}),k(`tbody`,{children:o.map(o=>A(S,{$selectable:!0,onClick:()=>_(o),children:[k(C,{children:k(l,{state:c(o),label:a(o)})}),k(C,{$align:`right`,$mono:!0,title:n(o.at),children:e(o.at)}),k(C,{$mono:!0,children:k(g,{style:{display:`block`,maxWidth:`20ch`},children:o.requestedModel||`—`})}),k(C,{children:o.resolvedProvider===null?k(p,{children:u(o)?`routing…`:`not routed`}):A(m,{$gap:1,children:[k(b,{provider:o.resolvedProvider}),k(h,{$dim:!0,children:o.resolvedModel??`—`})]})}),f===void 0?null:A(O,{children:[k(C,{children:k(g,{style:{display:`block`,maxWidth:`18ch`},children:o.credentialId==null?`—`:f.accounts.get(o.credentialId)??d(o.credentialId)})}),k(C,{children:k(g,{style:{display:`block`,maxWidth:`16ch`},title:o.apiKeyId??void 0,children:o.apiKeyId==null?`—`:f.keys.get(o.apiKeyId)??d(o.apiKeyId)})})]}),k(C,{$align:`right`,$mono:!0,children:u(o)?`—`:o.attempts}),k(C,{$align:`right`,$mono:!0,children:u(o)?`—`:i(o.ttftMs)}),k(C,{$align:`right`,$mono:!0,children:u(o)?r(Math.max(0,s-o.at)):i(o.durationMs)}),k(F,{log:o}),k(C,{$align:`right`,$mono:!0,children:u(o)?`—`:t(o.costUsd)}),k(C,{children:u(o)?k(x,{$tone:`accent`,children:`live`}):o.errorCode===null?k(x,{$tone:`ok`,children:o.status}):k(x,{$tone:`down`,children:o.errorCode})})]},o.id))})]})}var L=j.dl`
2
2
  display: grid;
3
3
  grid-template-columns: minmax(120px, auto) minmax(0, 1fr);
4
4
  gap: 6px ${({theme:e})=>e.space(3)};
@@ -1,4 +1,4 @@
1
- import{S as e,h as t,x as n}from"./shared-ChaZCaBz.js";import{F as r,L as i,P as a,j as o}from"./Lamp-Drd1fFwQ.js";import{D as s,a as c,b as l,i as u,r as d,t as f}from"./Panel-BV18WuL1.js";import{f as p}from"./Rack-D3iFlR6e.js";import{t as m}from"./Readout-Dxwka1JI.js";import{jsx as h,jsxs as g}from"react/jsx-runtime";import _ from"styled-components";function v({legend:e,meta:t,actions:n,footer:r,query:i,failure:a,empty:o,isEmpty:s,children:l}){return h(f,{legend:e,...t===void 0?{}:{meta:t},...n===void 0?{}:{actions:n},...r===void 0?{}:{footer:r},children:i.isError?h(u,{...a===void 0?{}:{legend:a},error:i.error,onRetry:i.refetch}):i.isLoading?h(c,{rows:4}):s?h(d,{legend:o.legend,message:o.message}):l})}var y=_(s)`
1
+ import{S as e,h as t,x as n}from"./shared-wEQ9LHZa.js";import{F as r,L as i,P as a,j as o}from"./Lamp-DsUSnxN4.js";import{D as s,a as c,b as l,i as u,r as d,t as f}from"./Panel-CWmOTDAP.js";import{f as p}from"./Rack-CSpeYQ1D.js";import{t as m}from"./Readout-BTh732hP.js";import{jsx as h,jsxs as g}from"react/jsx-runtime";import _ from"styled-components";function v({legend:e,meta:t,actions:n,footer:r,query:i,failure:a,empty:o,isEmpty:s,children:l}){return h(f,{legend:e,...t===void 0?{}:{meta:t},...n===void 0?{}:{actions:n},...r===void 0?{}:{footer:r},children:i.isError?h(u,{...a===void 0?{}:{legend:a},error:i.error,onRetry:i.refetch}):i.isLoading?h(c,{rows:4}):s?h(d,{legend:o.legend,message:o.message}):l})}var y=_(s)`
2
2
  border-color: ${({theme:e,$on:t})=>t?e.color.accent:e.color.ruleStrong};
3
3
  color: ${({theme:e,$on:t})=>t?e.color.accent:e.color.inkDim};
4
4
  background: ${({theme:e,$on:t})=>t?e.color.accentWash:e.color.panelRaised};
@@ -1,4 +1,4 @@
1
- import{a as e,c as t,l as n,o as r,s as i,u as a}from"./Rack-D3iFlR6e.js";import*as o from"react";import{Fragment as s,jsx as c,jsxs as l}from"react/jsx-runtime";import u from"styled-components";var d=Object.defineProperty,f=(e,t)=>d(e,`name`,{value:t,configurable:!0});function p(e){let[t,n]=o.useState(void 0);return r(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{if(!Array.isArray(t)||!t.length)return;let r=t[0],i,a;if(`borderBoxSize`in r){let e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;i=t.inlineSize,a=t.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return t.observe(e,{box:`border-box`}),()=>t.unobserve(e)}n(void 0)},[e]),t}f(p,`useSize`);var m=Object.defineProperty,h=(e,t)=>m(e,`name`,{value:t,configurable:!0}),g=`Switch`,[_,v]=t(g),[y,b]=_(g);function x(t){let{__scopeSwitch:n,checked:r,children:i,defaultChecked:a,disabled:s,form:l,name:u,onCheckedChange:d,required:f,value:p=`on`,internal_do_not_use_render:m}=t,[h,_]=e({prop:r,defaultProp:a??!1,onChange:d,caller:g}),[v,b]=o.useState(null),[x,S]=o.useState(null),C=o.useRef(!1),[w,T]=o.useReducer(e=>e+1,0),E={checked:h,setChecked:_,disabled:s,control:v,setControl:b,name:u,form:l,value:p,hasConsumerStoppedPropagationRef:C,userInteractionCount:w,onUserInteraction:T,required:f,defaultChecked:a,isFormControl:!v||!!l||!!v.closest(`form`),bubbleInput:x,setBubbleInput:S};return c(y,{scope:n,...E,children:k(m)?m(E):i})}h(x,`SwitchProvider`);var S=`SwitchTrigger`,C=o.forwardRef(h(function({__scopeSwitch:e,onClick:t,...r},s){let{control:l,form:u,value:d,disabled:f,checked:p,required:m,setControl:g,setChecked:_,hasConsumerStoppedPropagationRef:v,onUserInteraction:y,isFormControl:x,bubbleInput:C}=b(S,e),w=a(s,g),T=o.useRef(p);return o.useEffect(()=>{let e=u?l?.ownerDocument.getElementById(u):l?.form;if(e instanceof HTMLFormElement){let t=h(()=>_(T.current),`reset`);return e.addEventListener(`reset`,t),()=>e.removeEventListener(`reset`,t)}},[l,u,_]),c(n.button,{type:`button`,role:`switch`,"aria-checked":p,"aria-required":m,"data-state":A(p),"data-disabled":f?``:void 0,disabled:f,value:d,...r,ref:w,onClick:i(t,e=>{y(),_(e=>!e),C&&x&&(v.current=e.isPropagationStopped(),v.current||e.stopPropagation())})})},`SwitchTrigger`)),w=o.forwardRef(h(function(e,t){let{__scopeSwitch:n,name:r,checked:i,defaultChecked:a,required:o,disabled:u,value:d,onCheckedChange:f,form:p,...m}=e;return c(x,{__scopeSwitch:n,checked:i,defaultChecked:a,disabled:u,required:o,onCheckedChange:f,name:r,form:p,value:d,internal_do_not_use_render:({isFormControl:e})=>l(s,{children:[c(C,{...m,ref:t,__scopeSwitch:n}),e&&c(O,{__scopeSwitch:n})]})})},`Switch`)),T=`SwitchThumb`,E=o.forwardRef(h(function(e,t){let{__scopeSwitch:r,...i}=e,a=b(T,r);return c(n.span,{"data-state":A(a.checked),"data-disabled":a.disabled?``:void 0,...i,ref:t})},`SwitchThumb`)),D=`SwitchBubbleInput`,O=o.forwardRef(h(function({__scopeSwitch:e,onClick:t,...r},s){let{control:l,hasConsumerStoppedPropagationRef:u,userInteractionCount:d,checked:f,defaultChecked:m,required:h,disabled:g,name:_,value:v,form:y,bubbleInput:x,setBubbleInput:S}=b(D,e),C=a(s,S),w=p(l),T=o.useRef(!1),E=o.useRef(f),O=o.useRef(d);o.useEffect(()=>{let e=x;if(!e)return;let t=window.HTMLInputElement.prototype,n=Object.getOwnPropertyDescriptor(t,`checked`).set,r=d!==O.current;O.current=d;let i=E.current!==f;E.current=f;let a=!(r&&u.current);if(i&&n){T.current=!r;let t=new Event(`click`,{bubbles:a});n.call(e,f),e.dispatchEvent(t),T.current=!1}},[x,f,u,d]);let k=o.useRef(f);return c(n.input,{type:`checkbox`,"aria-hidden":!0,defaultChecked:m??k.current,required:h,disabled:g,name:_,value:v,form:y,...r,tabIndex:-1,ref:C,onClick:i(t,e=>{T.current&&e.stopPropagation()}),style:{...r.style,...w,position:`absolute`,pointerEvents:`none`,opacity:0,margin:0,transform:`translateX(-100%)`}})},`SwitchBubbleInput`));function k(e){return typeof e==`function`}h(k,`isFunction`);function A(e){return e?`checked`:`unchecked`}h(A,`getState`);var j=u(w)`
1
+ import{a as e,c as t,l as n,o as r,s as i,u as a}from"./Rack-CSpeYQ1D.js";import*as o from"react";import{Fragment as s,jsx as c,jsxs as l}from"react/jsx-runtime";import u from"styled-components";var d=Object.defineProperty,f=(e,t)=>d(e,`name`,{value:t,configurable:!0});function p(e){let[t,n]=o.useState(void 0);return r(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{if(!Array.isArray(t)||!t.length)return;let r=t[0],i,a;if(`borderBoxSize`in r){let e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;i=t.inlineSize,a=t.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return t.observe(e,{box:`border-box`}),()=>t.unobserve(e)}n(void 0)},[e]),t}f(p,`useSize`);var m=Object.defineProperty,h=(e,t)=>m(e,`name`,{value:t,configurable:!0}),g=`Switch`,[_,v]=t(g),[y,b]=_(g);function x(t){let{__scopeSwitch:n,checked:r,children:i,defaultChecked:a,disabled:s,form:l,name:u,onCheckedChange:d,required:f,value:p=`on`,internal_do_not_use_render:m}=t,[h,_]=e({prop:r,defaultProp:a??!1,onChange:d,caller:g}),[v,b]=o.useState(null),[x,S]=o.useState(null),C=o.useRef(!1),[w,T]=o.useReducer(e=>e+1,0),E={checked:h,setChecked:_,disabled:s,control:v,setControl:b,name:u,form:l,value:p,hasConsumerStoppedPropagationRef:C,userInteractionCount:w,onUserInteraction:T,required:f,defaultChecked:a,isFormControl:!v||!!l||!!v.closest(`form`),bubbleInput:x,setBubbleInput:S};return c(y,{scope:n,...E,children:k(m)?m(E):i})}h(x,`SwitchProvider`);var S=`SwitchTrigger`,C=o.forwardRef(h(function({__scopeSwitch:e,onClick:t,...r},s){let{control:l,form:u,value:d,disabled:f,checked:p,required:m,setControl:g,setChecked:_,hasConsumerStoppedPropagationRef:v,onUserInteraction:y,isFormControl:x,bubbleInput:C}=b(S,e),w=a(s,g),T=o.useRef(p);return o.useEffect(()=>{let e=u?l?.ownerDocument.getElementById(u):l?.form;if(e instanceof HTMLFormElement){let t=h(()=>_(T.current),`reset`);return e.addEventListener(`reset`,t),()=>e.removeEventListener(`reset`,t)}},[l,u,_]),c(n.button,{type:`button`,role:`switch`,"aria-checked":p,"aria-required":m,"data-state":A(p),"data-disabled":f?``:void 0,disabled:f,value:d,...r,ref:w,onClick:i(t,e=>{y(),_(e=>!e),C&&x&&(v.current=e.isPropagationStopped(),v.current||e.stopPropagation())})})},`SwitchTrigger`)),w=o.forwardRef(h(function(e,t){let{__scopeSwitch:n,name:r,checked:i,defaultChecked:a,required:o,disabled:u,value:d,onCheckedChange:f,form:p,...m}=e;return c(x,{__scopeSwitch:n,checked:i,defaultChecked:a,disabled:u,required:o,onCheckedChange:f,name:r,form:p,value:d,internal_do_not_use_render:({isFormControl:e})=>l(s,{children:[c(C,{...m,ref:t,__scopeSwitch:n}),e&&c(O,{__scopeSwitch:n})]})})},`Switch`)),T=`SwitchThumb`,E=o.forwardRef(h(function(e,t){let{__scopeSwitch:r,...i}=e,a=b(T,r);return c(n.span,{"data-state":A(a.checked),"data-disabled":a.disabled?``:void 0,...i,ref:t})},`SwitchThumb`)),D=`SwitchBubbleInput`,O=o.forwardRef(h(function({__scopeSwitch:e,onClick:t,...r},s){let{control:l,hasConsumerStoppedPropagationRef:u,userInteractionCount:d,checked:f,defaultChecked:m,required:h,disabled:g,name:_,value:v,form:y,bubbleInput:x,setBubbleInput:S}=b(D,e),C=a(s,S),w=p(l),T=o.useRef(!1),E=o.useRef(f),O=o.useRef(d);o.useEffect(()=>{let e=x;if(!e)return;let t=window.HTMLInputElement.prototype,n=Object.getOwnPropertyDescriptor(t,`checked`).set,r=d!==O.current;O.current=d;let i=E.current!==f;E.current=f;let a=!(r&&u.current);if(i&&n){T.current=!r;let t=new Event(`click`,{bubbles:a});n.call(e,f),e.dispatchEvent(t),T.current=!1}},[x,f,u,d]);let k=o.useRef(f);return c(n.input,{type:`checkbox`,"aria-hidden":!0,defaultChecked:m??k.current,required:h,disabled:g,name:_,value:v,form:y,...r,tabIndex:-1,ref:C,onClick:i(t,e=>{T.current&&e.stopPropagation()}),style:{...r.style,...w,position:`absolute`,pointerEvents:`none`,opacity:0,margin:0,transform:`translateX(-100%)`}})},`SwitchBubbleInput`));function k(e){return typeof e==`function`}h(k,`isFunction`);function A(e){return e?`checked`:`unchecked`}h(A,`getState`);var j=u(w)`
2
2
  all: unset;
3
3
  width: 30px;
4
4
  height: 16px;