@quixomatic/rpf 0.3.1 → 0.3.2

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 (128) hide show
  1. package/CHANGELOG.md +46 -0
  2. package/assets/dev-host/boot.js +7 -223
  3. package/assets/dev-host/boot.js.LEGAL.txt +0 -22
  4. package/assets/dev-host/chunks/{accordion-O6VUPQ32.js → accordion-7MNNAFNO.js} +2 -2
  5. package/assets/dev-host/chunks/{alert-PRAGKG5L.js → alert-GIZIVENB.js} +2 -2
  6. package/assets/dev-host/chunks/{alert-dialog-SCBXM23J.js → alert-dialog-7NG5WNXK.js} +2 -2
  7. package/assets/dev-host/chunks/{avatar-WXPKQ3Z5.js → avatar-BCPZUJGX.js} +2 -2
  8. package/assets/dev-host/chunks/{breadcrumb-IJQJQ5JV.js → breadcrumb-T2XOHRDG.js} +2 -2
  9. package/assets/dev-host/chunks/button-TGT2523L.js +2 -0
  10. package/assets/dev-host/chunks/calendar-TOTKKMY2.js +2 -0
  11. package/assets/dev-host/chunks/{card-EY3LK2GB.js → card-LOSZVZYW.js} +2 -2
  12. package/assets/dev-host/chunks/{chart-2PHC6UIE.js → chart-43TBOZGK.js} +2 -2
  13. package/assets/dev-host/chunks/{chart-blocks-PZPCWCNT.js → chart-blocks-HLNNWNB5.js} +2 -2
  14. package/assets/dev-host/chunks/{chart-frame-MNUFXAPU.js → chart-frame-FNM5OPZU.js} +2 -2
  15. package/assets/dev-host/chunks/{chat-TTESCYES.js → chat-QVZ4BUWR.js} +2 -2
  16. package/assets/dev-host/chunks/{checkbox-Y2UGSRR4.js → checkbox-AFUTB4DV.js} +2 -2
  17. package/assets/dev-host/chunks/{chunk-UWANBOC6.js → chunk-2FVHAZMZ.js} +2 -2
  18. package/assets/dev-host/chunks/{chunk-CWDPAB6V.js → chunk-34RXMJIM.js} +2 -2
  19. package/assets/dev-host/chunks/chunk-354OFHNU.js +219 -0
  20. package/assets/dev-host/chunks/chunk-354OFHNU.js.LEGAL.txt +23 -0
  21. package/assets/dev-host/chunks/{chunk-CCXMDKVL.js → chunk-3LMPMW3Q.js} +2 -2
  22. package/assets/dev-host/chunks/{chunk-3H6F4X7R.js → chunk-4XESWRTW.js} +2 -2
  23. package/assets/dev-host/chunks/{chunk-PYWKHILP.js → chunk-7FCGD4LS.js} +2 -2
  24. package/assets/dev-host/chunks/{chunk-AVSRGCSF.js → chunk-7JQIKRBV.js} +2 -2
  25. package/assets/dev-host/chunks/{chunk-PHK25MY7.js → chunk-DU3VFETH.js} +2 -2
  26. package/assets/dev-host/chunks/{chunk-2IZ44WWI.js → chunk-E5JYU6CR.js} +2 -2
  27. package/assets/dev-host/chunks/{chunk-BB4IX5QA.js → chunk-FBZMZ5S2.js} +2 -2
  28. package/assets/dev-host/chunks/{chunk-GWDGPUGM.js → chunk-GSJT5YWB.js} +2 -2
  29. package/assets/dev-host/chunks/{chunk-OXJ6LWKI.js → chunk-HCQR5YME.js} +3 -3
  30. package/assets/dev-host/chunks/{chunk-APP2HKWR.js → chunk-HGBRF6KW.js} +2 -2
  31. package/assets/dev-host/chunks/{chunk-6ARM5VDH.js → chunk-HVTUE7NV.js} +2 -2
  32. package/assets/dev-host/chunks/{chunk-M7A47ZSM.js → chunk-IY3GAGI7.js} +2 -2
  33. package/assets/dev-host/chunks/{chunk-MGLBTOXD.js → chunk-KY2HARU6.js} +2 -2
  34. package/assets/dev-host/chunks/{chunk-EDEL6XSO.js → chunk-ND526XXU.js} +2 -2
  35. package/assets/dev-host/chunks/{chunk-UXUS6DNI.js → chunk-NMFZMT4R.js} +2 -2
  36. package/assets/dev-host/chunks/{chunk-XE5RQ73V.js → chunk-NPJXSRRT.js} +2 -2
  37. package/assets/dev-host/chunks/{chunk-FJRWQRLM.js → chunk-OUCK2LIZ.js} +2 -2
  38. package/assets/dev-host/chunks/{chunk-Z76KXEPD.js → chunk-OXLXEX2R.js} +2 -2
  39. package/assets/dev-host/chunks/{chunk-BH6FGVDP.js → chunk-PB5RYDO5.js} +2 -2
  40. package/assets/dev-host/chunks/{chunk-TQPXDAVH.js → chunk-QJVIEN5R.js} +2 -2
  41. package/assets/dev-host/chunks/{chunk-57M36GYM.js → chunk-QZ3NJHFR.js} +2 -2
  42. package/assets/dev-host/chunks/{chunk-FZPMZMFU.js → chunk-SC7J7HFI.js} +2 -2
  43. package/assets/dev-host/chunks/{chunk-X34AFUS2.js → chunk-SKBWMIS5.js} +2 -2
  44. package/assets/dev-host/chunks/{chunk-LTVKSGLG.js → chunk-UCEBXCOI.js} +2 -2
  45. package/assets/dev-host/chunks/{chunk-T7JFBQSG.js → chunk-UNKI7HPL.js} +2 -2
  46. package/assets/dev-host/chunks/{chunk-F5MKIWPQ.js → chunk-UPZXXDXM.js} +2 -2
  47. package/assets/dev-host/chunks/{chunk-ML6HCGK5.js → chunk-XBWE3IIB.js} +2 -2
  48. package/assets/dev-host/chunks/{chunk-NJX7QY3Z.js → chunk-YFI7GTF6.js} +2 -2
  49. package/assets/dev-host/chunks/{chunk-NI6ZJ6DH.js → chunk-YJM2Y722.js} +2 -2
  50. package/assets/dev-host/chunks/{chunk-WLBNJ4K3.js → chunk-ZNWVTDCV.js} +2 -2
  51. package/assets/dev-host/chunks/{chunk-UUJ5X322.js → chunk-ZTMZ7LJW.js} +2 -2
  52. package/assets/dev-host/chunks/{chunk-OW6AVFQA.js → chunk-ZZ2RYU7S.js} +2 -2
  53. package/assets/dev-host/chunks/{code-block-H2ETQV3M.js → code-block-IKYEIWY2.js} +2 -2
  54. package/assets/dev-host/chunks/code-editor-KDRLM33B.js +2 -0
  55. package/assets/dev-host/chunks/{collapsible-4ZOFMWLB.js → collapsible-WK7PDWEV.js} +2 -2
  56. package/assets/dev-host/chunks/{color-picker-RRCCLR54.js → color-picker-VPSOGTDM.js} +2 -2
  57. package/assets/dev-host/chunks/{combobox-U4455OMJ.js → combobox-GYLAHYVX.js} +2 -2
  58. package/assets/dev-host/chunks/{contrast-badge-KDF65X7J.js → contrast-badge-QZW62DMF.js} +2 -2
  59. package/assets/dev-host/chunks/{date-range-picker-WJYHAHRM.js → date-range-picker-6Q2JGR43.js} +2 -2
  60. package/assets/dev-host/chunks/{dialog-I6AGHWB3.js → dialog-HDQAIAFZ.js} +2 -2
  61. package/assets/dev-host/chunks/{dropdown-menu-LSOMXDWG.js → dropdown-menu-E7K3YNXS.js} +2 -2
  62. package/assets/dev-host/chunks/{empty-NLQODUSK.js → empty-JCVCSM3V.js} +2 -2
  63. package/assets/dev-host/chunks/{font-picker-3TLYYZJH.js → font-picker-7FBJCSTQ.js} +2 -2
  64. package/assets/dev-host/chunks/{frame-HA7UIYZF.js → frame-LZ2IUISE.js} +2 -2
  65. package/assets/dev-host/chunks/{heading-7M24WKK6.js → heading-GX36VR3U.js} +2 -2
  66. package/assets/dev-host/chunks/{hover-card-HSHOQPOI.js → hover-card-ONEUZ7TU.js} +2 -2
  67. package/assets/dev-host/chunks/{image-R7XGYKVH.js → image-E3BYZ2HA.js} +2 -2
  68. package/assets/dev-host/chunks/{input-YECXNM53.js → input-G7S4OLSN.js} +2 -2
  69. package/assets/dev-host/chunks/{input-group-GFKXSZM7.js → input-group-54JRMLWQ.js} +2 -2
  70. package/assets/dev-host/chunks/{kbd-V25ZMVCM.js → kbd-TKMXF542.js} +2 -2
  71. package/assets/dev-host/chunks/label-YIVRPKQJ.js +2 -0
  72. package/assets/dev-host/chunks/{label-value-6Z6ATP55.js → label-value-V7QDIDAP.js} +2 -2
  73. package/assets/dev-host/chunks/{logo-AAMBHX2W.js → logo-DBA4NHQE.js} +2 -2
  74. package/assets/dev-host/chunks/{number-field-6TCQAVTR.js → number-field-FPC3YXDC.js} +2 -2
  75. package/assets/dev-host/chunks/{pill-7L57ZNRJ.js → pill-4WVEOBR4.js} +2 -2
  76. package/assets/dev-host/chunks/{popover-3P6YNKH3.js → popover-GQD2U5SP.js} +2 -2
  77. package/assets/dev-host/chunks/{progress-RBCJRVM7.js → progress-TITSWD2A.js} +2 -2
  78. package/assets/dev-host/chunks/{radio-group-NJWXZCX3.js → radio-group-YA3OUIPB.js} +2 -2
  79. package/assets/dev-host/chunks/{resizable-XF4P6OKR.js → resizable-XQKUCHIS.js} +2 -2
  80. package/assets/dev-host/chunks/rich-text-2RYBPVRF.js +2 -0
  81. package/assets/dev-host/chunks/{rich-text-editor-T6KWD4P3.js → rich-text-editor-IX7RIMLI.js} +2 -2
  82. package/assets/dev-host/chunks/{scroll-row-LMI7JCFR.js → scroll-row-MZZQZYLM.js} +2 -2
  83. package/assets/dev-host/chunks/{select-F3MZWTTS.js → select-5U37ZHLQ.js} +2 -2
  84. package/assets/dev-host/chunks/separator-JATMMEKS.js +2 -0
  85. package/assets/dev-host/chunks/{sheet-EXRT4MFB.js → sheet-KTVNRYAO.js} +2 -2
  86. package/assets/dev-host/chunks/{side-panel-IBHLEANN.js → side-panel-2UVNFRIF.js} +2 -2
  87. package/assets/dev-host/chunks/{sidebar-VKQMQMF2.js → sidebar-GR4A2LDD.js} +2 -2
  88. package/assets/dev-host/chunks/{skeleton-KIRVQ4EO.js → skeleton-XE2TGBGQ.js} +2 -2
  89. package/assets/dev-host/chunks/{slider-XKYDL5MR.js → slider-BGGGQLSH.js} +2 -2
  90. package/assets/dev-host/chunks/{split-button-WP6LALDS.js → split-button-KLVGWHNN.js} +2 -2
  91. package/assets/dev-host/chunks/{stepper-KR6PXZHW.js → stepper-AY3NGEDC.js} +2 -2
  92. package/assets/dev-host/chunks/{switch-P6NJELJJ.js → switch-A2VSCLHA.js} +2 -2
  93. package/assets/dev-host/chunks/{tabs-PFPRJNVZ.js → tabs-2IO6EIED.js} +2 -2
  94. package/assets/dev-host/chunks/textarea-YQH2OPGH.js +2 -0
  95. package/assets/dev-host/chunks/{toggle-group-PS7JN2JM.js → toggle-group-3SDBWJ2G.js} +2 -2
  96. package/assets/dev-host/chunks/{tooltip-S4RBC3O4.js → tooltip-4QJ2SWCS.js} +2 -2
  97. package/assets/dev-host/chunks/{tree-NQF6ZJLH.js → tree-CFIKTPFC.js} +2 -2
  98. package/assets/dev-host/kit-candidates.json +1 -1
  99. package/assets/dev-host/kit-manifest.json +1 -1
  100. package/assets/dev-host/stage.js +54 -0
  101. package/assets/forge-app/app/assets/{_forge-shiki-langs-DaJjT17w.js → _forge-shiki-langs-nxHsAEiY.js} +1 -1
  102. package/assets/forge-app/app/assets/{appendItems-CWJJlOE7.js → appendItems-CLsiMCGq.js} +1 -1
  103. package/assets/forge-app/app/assets/{core-Dl2d1S-D.js → core-DEkUYqk0.js} +1 -1
  104. package/assets/forge-app/app/assets/{diff-view-Chujmqzi.js → diff-view-ctlXj2p5.js} +1 -1
  105. package/assets/forge-app/app/assets/{file-panel-le_M5nHe.js → file-panel-BnUdO2N6.js} +1 -1
  106. package/assets/forge-app/app/assets/{highlights-BxaWC1ve.js → highlights-CEbVTJAm.js} +1 -1
  107. package/assets/forge-app/app/assets/index-DYFQser1.js +291 -0
  108. package/assets/forge-app/app/assets/index-Ddi87x2p.css +1 -0
  109. package/assets/forge-app/app/assets/{loader-BMv9OYvr.js → loader-V5V4Ad0d.js} +1 -1
  110. package/assets/forge-app/app/assets/{shiki-CoRI3zWj.js → shiki-B5GY8Ub_.js} +2 -2
  111. package/assets/forge-app/app/assets/{stream-tokenizer-BMtK_3oz.js → stream-tokenizer-CZZoarTM.js} +1 -1
  112. package/assets/forge-app/app/assets/{terminal-view-D3CiLjfu.js → terminal-view-BR9EXBM5.js} +1 -1
  113. package/assets/forge-app/app/assets/{themes-CLX9vH7e.js → themes-BMbfM7BC.js} +2 -2
  114. package/assets/forge-app/app/assets/{useNextRenderData-dgMkjxGZ.js → useNextRenderData-ICppXFTX.js} +1 -1
  115. package/assets/forge-app/app/index.html +2 -2
  116. package/assets/forge-app/server.mjs +283 -34
  117. package/dist/cli.mjs +1906 -718
  118. package/package.json +1 -1
  119. package/assets/dev-host/chunks/button-4JMBKYN4.js +0 -2
  120. package/assets/dev-host/chunks/calendar-XXLCAUPG.js +0 -2
  121. package/assets/dev-host/chunks/code-editor-2JYERJLS.js +0 -2
  122. package/assets/dev-host/chunks/label-LJT4V2CT.js +0 -2
  123. package/assets/dev-host/chunks/rich-text-7OMYZ564.js +0 -2
  124. package/assets/dev-host/chunks/separator-JRJYKM4Z.js +0 -2
  125. package/assets/dev-host/chunks/textarea-2JXA5XWS.js +0 -2
  126. package/assets/forge-app/app/assets/index-BwYJlfwT.css +0 -1
  127. package/assets/forge-app/app/assets/index-UP3KtgHV.js +0 -291
  128. /package/assets/dev-host/chunks/{chunk-OXJ6LWKI.js.LEGAL.txt → chunk-HCQR5YME.js.LEGAL.txt} +0 -0
@@ -1,6 +1,6 @@
1
- import{Ia as P,Ya as F,k as A}from"./chunk-IQ2XSDFU.js";import{a as T}from"./chunk-CT4EH2K2.js";import{a as k}from"./chunk-SVQCDOZ3.js";import{a as K}from"./chunk-IJQ26FTX.js";import{c as M}from"./chunk-KVMUXFPB.js";var p=M(K());var n=M(T()),R=null,S=null,j=new Set;function q(){return S?Promise.resolve(S):(R||(R=import("./charts-SKK6UTYU.js").then(t=>(S=t,j.forEach(e=>e()),t)).catch(t=>{throw R=null,t})),R)}function ee(){return!!S}function D(){let[t,e]=p.useState(()=>S?{status:"ready",error:null}:{status:"loading",error:null}),o=p.useCallback(()=>{if(S){e({status:"ready",error:null});return}e({status:"loading",error:null}),q().then(()=>e({status:"ready",error:null}),r=>e({status:"error",error:r}))},[]);return p.useEffect(()=>{S||o();let r=()=>e({status:"ready",error:null});return j.add(r),()=>{j.delete(r)}},[o]),{engine:t.status==="ready"?S:null,status:t.status,error:t.error,retry:o}}function te(){return D().engine}var H={light:[""],dark:[":host(.dark) ",".dark "]},B={width:320,height:200},V=p.createContext(null);function L(){let t=p.useContext(V);if(!t)throw new Error("useChart must be used within a <ChartContainer />");return t}function O(t){return String(t??"").replace(/[^a-zA-Z0-9_-]/g,"_")}function Z(t){return`var(--chart-${(Math.max(1,Math.floor(t||1))-1)%5+1})`}var G="flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden [&_.recharts-wrapper]:outline-hidden";function J({status:t,error:e,retry:o}){return t==="error"?(0,n.jsxs)("div",{role:"alert",className:"flex h-full w-full flex-col items-center justify-center gap-2 rounded-lg border border-dashed p-4 text-center text-muted-foreground",children:[(0,n.jsxs)("span",{children:["Chart could not load",e&&e.message?`: ${e.message}`:""]}),(0,n.jsxs)("button",{type:"button",onClick:o,className:"inline-flex items-center gap-1.5 rounded-md border bg-background px-2.5 py-1 text-xs font-medium text-foreground hover:bg-muted",children:[(0,n.jsx)(P,{className:"size-3.5","aria-hidden":"true"}),"Retry"]})]}):(0,n.jsx)("div",{"data-slot":"chart-loading","aria-busy":"true","aria-label":"Loading chart",className:"h-full w-full animate-pulse rounded-lg bg-muted/60"})}function re({id:t,className:e,children:o,config:r,initialDimension:a=B,...c}){let s=p.useId(),m=`chart-${O(t??s)}`,{engine:d,status:u,error:g,retry:h}=D(),v=p.useMemo(()=>({config:r||{},engine:d,id:m}),[r,d,m]),l=null;if(d){let b=typeof o=="function"?o(d):o;l=(0,n.jsx)(d.ResponsiveContainer,{initialDimension:a,children:b})}else l=(0,n.jsx)(J,{status:u,error:g,retry:h});return(0,n.jsx)(V.Provider,{value:v,children:(0,n.jsxs)("div",{"data-slot":"chart","data-chart":m,className:k(G,e),...c,children:[(0,n.jsx)(Q,{id:m,config:r||{}}),l]})})}function Q({id:t,config:e}){let o=Object.entries(e||{}).filter(([,a])=>a&&(a.theme||a.color));if(!o.length)return null;let r=Object.entries(H).map(([a,c])=>{let s=o.map(([d,u])=>{let g=u.theme&&u.theme[a]||u.color;return g?` --color-${O(d)}: ${String(g).replace(/[;{}<>]/g,"")};`:null}).filter(Boolean).join(`
1
+ import{Ia as P,Ya as F,k as A}from"./chunk-IQ2XSDFU.js";import{a as k}from"./chunk-SVQCDOZ3.js";import{a as T}from"./chunk-CT4EH2K2.js";import{a as K}from"./chunk-IJQ26FTX.js";import{c as M}from"./chunk-KVMUXFPB.js";var p=M(K());var n=M(T()),R=null,S=null,j=new Set;function q(){return S?Promise.resolve(S):(R||(R=import("./charts-SKK6UTYU.js").then(t=>(S=t,j.forEach(e=>e()),t)).catch(t=>{throw R=null,t})),R)}function ee(){return!!S}function D(){let[t,e]=p.useState(()=>S?{status:"ready",error:null}:{status:"loading",error:null}),o=p.useCallback(()=>{if(S){e({status:"ready",error:null});return}e({status:"loading",error:null}),q().then(()=>e({status:"ready",error:null}),r=>e({status:"error",error:r}))},[]);return p.useEffect(()=>{S||o();let r=()=>e({status:"ready",error:null});return j.add(r),()=>{j.delete(r)}},[o]),{engine:t.status==="ready"?S:null,status:t.status,error:t.error,retry:o}}function te(){return D().engine}var H={light:[""],dark:[":host(.dark) ",".dark "]},B={width:320,height:200},V=p.createContext(null);function L(){let t=p.useContext(V);if(!t)throw new Error("useChart must be used within a <ChartContainer />");return t}function O(t){return String(t??"").replace(/[^a-zA-Z0-9_-]/g,"_")}function Z(t){return`var(--chart-${(Math.max(1,Math.floor(t||1))-1)%5+1})`}var G="flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden [&_.recharts-wrapper]:outline-hidden";function J({status:t,error:e,retry:o}){return t==="error"?(0,n.jsxs)("div",{role:"alert",className:"flex h-full w-full flex-col items-center justify-center gap-2 rounded-lg border border-dashed p-4 text-center text-muted-foreground",children:[(0,n.jsxs)("span",{children:["Chart could not load",e&&e.message?`: ${e.message}`:""]}),(0,n.jsxs)("button",{type:"button",onClick:o,className:"inline-flex items-center gap-1.5 rounded-md border bg-background px-2.5 py-1 text-xs font-medium text-foreground hover:bg-muted",children:[(0,n.jsx)(P,{className:"size-3.5","aria-hidden":"true"}),"Retry"]})]}):(0,n.jsx)("div",{"data-slot":"chart-loading","aria-busy":"true","aria-label":"Loading chart",className:"h-full w-full animate-pulse rounded-lg bg-muted/60"})}function re({id:t,className:e,children:o,config:r,initialDimension:a=B,...c}){let s=p.useId(),m=`chart-${O(t??s)}`,{engine:d,status:u,error:g,retry:h}=D(),v=p.useMemo(()=>({config:r||{},engine:d,id:m}),[r,d,m]),l=null;if(d){let b=typeof o=="function"?o(d):o;l=(0,n.jsx)(d.ResponsiveContainer,{initialDimension:a,children:b})}else l=(0,n.jsx)(J,{status:u,error:g,retry:h});return(0,n.jsx)(V.Provider,{value:v,children:(0,n.jsxs)("div",{"data-slot":"chart","data-chart":m,className:k(G,e),...c,children:[(0,n.jsx)(Q,{id:m,config:r||{}}),l]})})}function Q({id:t,config:e}){let o=Object.entries(e||{}).filter(([,a])=>a&&(a.theme||a.color));if(!o.length)return null;let r=Object.entries(H).map(([a,c])=>{let s=o.map(([d,u])=>{let g=u.theme&&u.theme[a]||u.color;return g?` --color-${O(d)}: ${String(g).replace(/[;{}<>]/g,"")};`:null}).filter(Boolean).join(`
2
2
  `);return`${c.map(d=>`${d}[data-chart=${t}]`).join(", ")} {
3
3
  ${s}
4
4
  }`}).join(`
5
5
  `);return(0,n.jsx)("style",{dangerouslySetInnerHTML:{__html:r}})}function ne(t){let{engine:e}=L();return e?(0,n.jsx)(e.Tooltip,{...t}):null}function oe(t){let{engine:e}=L();return e?(0,n.jsx)(e.Legend,{...t}):null}function E(t,e,o){if(typeof e!="object"||e===null)return;let r="payload"in e&&typeof e.payload=="object"&&e.payload!==null?e.payload:void 0,a=o;return o in e&&typeof e[o]=="string"?a=e[o]:r&&o in r&&typeof r[o]=="string"&&(a=r[o]),a in t?t[a]:t[o]}function U(t){return typeof t=="number"?t.toLocaleString():String(t)}function ae({active:t,payload:e,className:o,indicator:r="dot",hideLabel:a=!1,hideIndicator:c=!1,label:s,labelFormatter:m,labelClassName:d,formatter:u,valueFormatter:g,color:h,nameKey:v,labelKey:l}){let{config:b}=L(),w=p.useMemo(()=>{if(a||!e||!e.length)return null;let i=e[0],C=`${l||i&&i.dataKey||i&&i.name||"value"}`,N=E(b,i,C),f=!l&&typeof s=="string"?b[s]&&b[s].label||s:N&&N.label;return m?(0,n.jsx)("div",{className:k("font-medium",d),children:m(f,e)}):f?(0,n.jsx)("div",{className:k("font-medium",d),children:f}):null},[s,m,e,a,d,b,l]);if(!t||!e||!e.length)return null;let y=e.length===1&&r!=="dot",x=g||U;return(0,n.jsxs)("div",{className:k("grid min-w-[8rem] items-start gap-1.5 rounded-lg border border-border/50 bg-background px-2.5 py-1.5 text-xs shadow-xl",o),children:[y?null:w,(0,n.jsx)("div",{className:"grid gap-1.5",children:e.filter(i=>i.type!=="none").map((i,C)=>{let N=`${v||i.name||i.dataKey||"value"}`,f=E(b,i,N),$=h||i.payload&&i.payload.fill||i.color;return(0,n.jsx)("div",{className:k("flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5 [&>svg]:text-muted-foreground",r==="dot"&&"items-center"),children:u&&i.value!==void 0&&i.name?u(i.value,i.name,i,C,i.payload):(0,n.jsxs)(n.Fragment,{children:[f&&f.icon?(0,n.jsx)(f.icon,{}):!c&&(0,n.jsx)("div",{className:k("shrink-0 rounded-[2px] border-(--color-border) bg-(--color-bg)",{"h-2.5 w-2.5":r==="dot","w-1":r==="line","w-0 border-[1.5px] border-dashed bg-transparent":r==="dashed","my-0.5":y&&r==="dashed"}),style:{"--color-bg":$,"--color-border":$}}),(0,n.jsxs)("div",{className:k("flex flex-1 justify-between gap-4 leading-none",y?"items-end":"items-center"),children:[(0,n.jsxs)("div",{className:"grid gap-1.5",children:[y?w:null,(0,n.jsx)("span",{className:"text-muted-foreground",children:f&&f.label||i.name})]}),i.value!=null&&(0,n.jsx)("span",{className:"font-mono font-medium text-foreground tabular-nums",children:x(i.value,i)})]})]})},C)})})]})}function se({className:t,hideIcon:e=!1,payload:o,verticalAlign:r="bottom",nameKey:a}){let{config:c}=L();return!o||!o.length?null:(0,n.jsx)("div",{className:k("flex flex-wrap items-center justify-center gap-x-4 gap-y-1.5",r==="top"?"pb-3":"pt-3",t),children:o.filter(s=>s.type!=="none").map((s,m)=>{let d=`${a||s.dataKey||"value"}`,u=E(c,s,d);return(0,n.jsxs)("div",{className:"flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3 [&>svg]:text-muted-foreground",children:[u&&u.icon&&!e?(0,n.jsx)(u.icon,{}):(0,n.jsx)("div",{className:"h-2 w-2 shrink-0 rounded-[2px]",style:{backgroundColor:s.color}}),u&&u.label||s.value]},m)})})}function z(t,e){return(Array.isArray(t)&&t.length?t:Object.keys(e||{})).map((r,a)=>{let c=typeof r=="string"?{key:r}:r||{},s=e&&e[c.key]||{};return{key:String(c.key),label:c.label!=null?c.label:s.label!=null?s.label:String(c.key),color:c.color||s.color||Z(a+1)}})}function le(t){let e={};return t.forEach(o=>{e[o.key]={label:o.label,color:o.color}}),e}function I(t){let e=typeof t=="number"?t:parseFloat(t);return Number.isFinite(e)?e:null}function _(t){return typeof t=="string"||typeof t=="number"?String(t):""}function ie({type:t="chart",title:e,data:o,index:r,series:a,config:c,valueFormatter:s,timeSeries:m,total:d=!0}={}){let u=Array.isArray(o)?o:[],g=z(a,c),h=s||(y=>typeof y=="number"?y.toLocaleString():String(y)),v=e?`${e}: `:"",l=`${t} chart`;if(!u.length||!g.length)return`${v}${l} with no data.`;let b=y=>_(y[r]);if(g.length===1){let y=g[0].key,x=u.map(f=>({label:b(f),value:I(f[y])})).filter(f=>f.value!=null);if(!x.length)return`${v}${l} with no data.`;let i=x.reduce((f,$)=>f+$.value,0),C=x.reduce((f,$)=>$.value>f.value?$:f),N=x.reduce((f,$)=>$.value<f.value?$:f);if(m){let f=x[0],$=x[x.length-1];return`${v}${l} of ${_(g[0].label)} over ${x.length} periods, from ${f.label} (${h(f.value)}) to ${$.label} (${h($.value)}). Peak ${h(C.value)} in ${C.label}; low ${h(N.value)} in ${N.label}.`}return`${v}${l} of ${_(g[0].label)} across ${x.length} groups${d?`, total ${h(i)}`:""}. Highest: ${C.label} (${h(C.value)}). Lowest: ${N.label} (${h(N.value)}).`}let w=g.map(y=>{let x=u.reduce((i,C)=>i+(I(C[y.key])||0),0);return`${_(y.label)} ${h(x)}`}).join(", ");return`${v}${l} of ${g.length} series across ${u.length} ${m?"periods":"groups"}. Totals: ${w}.`}function ue({data:t,index:e,indexLabel:o,series:r,config:a,valueFormatter:c,caption:s,onRowClick:m,className:d,maxHeight:u=320}){let g=Array.isArray(t)?t:[],h=z(r,a),v=c||(l=>typeof l=="number"?l.toLocaleString():l==null?"":String(l));return(0,n.jsx)("div",{"data-slot":"chart-table",className:k("w-full overflow-auto rounded-lg border",d),style:u?{maxHeight:u}:void 0,children:(0,n.jsxs)("table",{className:"w-full border-collapse text-left text-sm",children:[s?(0,n.jsx)("caption",{className:"sr-only",children:s}):null,(0,n.jsx)("thead",{className:"sticky top-0 bg-muted/80 text-xs text-muted-foreground backdrop-blur",children:(0,n.jsxs)("tr",{children:[(0,n.jsx)("th",{scope:"col",className:"px-3 py-2 font-medium",children:o||e}),h.map(l=>(0,n.jsx)("th",{scope:"col",className:"px-3 py-2 text-right font-medium",children:l.label},l.key))]})}),(0,n.jsx)("tbody",{children:g.map((l,b)=>(0,n.jsxs)("tr",{className:"border-t",children:[(0,n.jsx)("th",{scope:"row",className:"px-3 py-1.5 font-normal",children:m?(0,n.jsx)("button",{type:"button",onClick:()=>m(l,b),className:"text-left underline-offset-4 hover:underline focus-visible:underline",children:_(l[e])||"(empty)"}):_(l[e])||"(empty)"}),h.map(w=>(0,n.jsx)("td",{className:"px-3 py-1.5 text-right font-mono tabular-nums",children:l[w.key]==null?"":v(l[w.key],{dataKey:w.key,payload:l})},w.key))]},b))})]})})}function W({view:t="chart",onViewChange:e,className:o}){let r=t==="table";return(0,n.jsxs)("button",{type:"button","aria-pressed":r,onClick:()=>e&&e(r?"chart":"table"),title:r?"View as chart":"View as table",className:k("inline-flex h-7 items-center gap-1.5 rounded-md px-2 text-xs font-medium text-muted-foreground outline-none hover:bg-muted hover:text-foreground focus-visible:ring-2 focus-visible:ring-ring/50",o),children:[r?(0,n.jsx)(A,{className:"size-3.5","aria-hidden":"true"}):(0,n.jsx)(F,{className:"size-3.5","aria-hidden":"true"}),(0,n.jsx)("span",{children:r?"View as chart":"View as table"})]})}function ce({title:t,summary:e,showSummary:o=!1,view:r,defaultView:a="chart",onViewChange:c,toggle:s=!1,table:m,className:d,children:u}){let[g,h]=p.useState(a),v=r||g,l=w=>{r||h(w),c&&c(w)},b=p.useId();return(0,n.jsxs)("figure",{"data-slot":"chart-figure",role:"group","aria-label":_(t)||void 0,"aria-describedby":e?b:void 0,className:k("m-0 flex min-w-0 flex-col gap-2",d),children:[s?(0,n.jsx)("div",{className:"flex justify-end",children:(0,n.jsx)(W,{view:v,onViewChange:l})}):null,v==="table"&&m?m:u,e?(0,n.jsx)("figcaption",{id:b,className:o?"text-xs text-muted-foreground":"sr-only",children:e}):null]})}function de(t,e){let o=I(t);if(o==null)return t==null?"":String(t);let r=e||{},a={};return r.compact?(a.notation="compact",a.maximumFractionDigits=r.decimals!=null?r.decimals:1):a.maximumFractionDigits=r.decimals!=null?r.decimals:Math.abs(o)<10&&o%1?2:o%1?1:0,r.percent?(a.style="percent",new Intl.NumberFormat(r.locale,a).format(o/100)):new Intl.NumberFormat(r.locale,a).format(o)}function fe(t,e=2){let o=I(t);if(o==null)return"";let r=[["d",86400],["h",3600],["m",60],["s",1]],a=Math.round(Math.abs(o)),c=r.findIndex(([,d])=>a>=d);c<0&&(c=r.length-1);let s=[],m=a;return r.slice(c,c+Math.max(1,e)).forEach(([d,u],g)=>{let h=Math.floor(m/u);m-=h*u,(g===0||h>0)&&s.push(`${h}${d}`)}),(o<0?"-":"")+s.join(" ")}function me(){try{return!!(window.matchMedia&&window.matchMedia("(prefers-reduced-motion: reduce)").matches)}catch{return!1}}export{q as a,ee as b,D as c,te as d,L as e,O as f,Z as g,J as h,re as i,Q as j,ne as k,oe as l,E as m,ae as n,se as o,z as p,le as q,ie as r,ue as s,W as t,ce as u,de as v,fe as w,me as x};
6
- //# sourceMappingURL=chunk-MGLBTOXD.js.map
6
+ //# sourceMappingURL=chunk-KY2HARU6.js.map
@@ -1,2 +1,2 @@
1
- import{a as V}from"./chunk-CT4EH2K2.js";import{a as w}from"./chunk-SVQCDOZ3.js";import{a as A}from"./chunk-IJQ26FTX.js";import{c as k}from"./chunk-KVMUXFPB.js";var n=k(A());var o=k(V()),N=null,S=null;function B(){return S?Promise.resolve(S):(N||(N=import("./portal-code-Z5G6AEMM.js").then(u=>(S=u,u)).catch(u=>{throw N=null,u})),N)}function T(){return!!S}function q(u){let e=String(u||"").toLowerCase();return e==="script"||e==="script_plain"||e==="script_server"||e==="condition_string"?"javascript":e==="json"||e==="json_translations"?"json":e==="css"?"css":e==="xml"?"xml":e==="html_script"||e==="html_template"?"html":"text"}function L(u){let e=n.useRef(u);return e.current=u,e}function O(u={}){let{value:e="",language:f="text",readOnly:m=!1,attributes:C}=u,[g,h]=n.useState(()=>({status:S?"ready":"loading",error:null})),[i,p]=n.useState(null),[v,_]=n.useState(0),t=n.useRef(null),c=n.useRef(e||""),y=n.useRef(!1),r=L(u);n.useEffect(()=>{if(!i)return;let a=!0,l=null;return B().then(b=>{a&&(l=b.createCodeEditor({parent:i,value:c.current,language:f,readOnly:m,placeholder:r.current.placeholder,lineNumbers:r.current.lineNumbers,tabSize:r.current.tabSize,minLines:r.current.minLines,attributes:r.current.attributes||{},onChange:s=>{y.current=!0,c.current=s,r.current.onChange&&r.current.onChange(s)},onFocus:()=>r.current.onFocus&&r.current.onFocus(),onBlur:s=>r.current.onBlur&&r.current.onBlur(s,{changed:y.current}),onSubmit:r.current.onSubmit?s=>r.current.onSubmit(s):void 0}),t.current=l,h({status:"ready",error:null}))}).catch(b=>a&&h({status:"error",error:b})),()=>{a=!1,l&&l.destroy(),t.current=null}},[i,v]),n.useEffect(()=>{let a=e||"";a!==c.current&&(c.current=a,y.current=!1,t.current&&t.current.setValue(a))},[e]),n.useEffect(()=>{t.current&&t.current.setReadOnly(m)},[m,g.status]),n.useEffect(()=>{t.current&&t.current.setLanguage(f)},[f,g.status]);let R=JSON.stringify(C||{});return n.useEffect(()=>{t.current&&t.current.setAttributes(C||{})},[R,g.status]),{mountRef:p,status:g.status,error:g.error,retry:()=>{h({status:"loading",error:null}),_(a=>a+1)},focus:()=>t.current&&t.current.focus(),getValue:()=>t.current?t.current.getValue():c.current,get changed(){return y.current}}}function J({className:u,value:e="",onChange:f,onBlur:m,onFocus:C,onSubmit:g,language:h="javascript",readOnly:i=!1,disabled:p=!1,invalid:v=!1,required:_=!1,placeholder:t,lineNumbers:c=!0,tabSize:y=4,minLines:r=3,maxHeight:R="24rem",id:a,"aria-label":l,"aria-labelledby":b,"aria-describedby":s,...F}){let d={};a&&(d.id=a),l&&(d["aria-label"]=l),b&&(d["aria-labelledby"]=b),s&&(d["aria-describedby"]=s),v&&(d["aria-invalid"]="true"),_&&(d["aria-required"]="true"),(i||p)&&(d["aria-readonly"]="true");let x=O({value:e,onChange:f,onBlur:m,onFocus:C,onSubmit:g,language:h,readOnly:i||p,placeholder:t,lineNumbers:c,tabSize:y,minLines:r,attributes:d}),z=w("relative w-full min-w-0 overflow-hidden rounded-md border border-input bg-transparent shadow-xs transition-[color,box-shadow] dark:bg-input/30","focus-within:border-ring focus-within:ring-[3px] focus-within:ring-ring/50",v&&"border-destructive ring-destructive/20 focus-within:border-destructive",(i||p)&&"bg-muted/40 shadow-none dark:bg-muted/30",p&&"opacity-60",u),j=`calc(${r} * 1.55em + 14px)`;return x.status==="error"?(0,o.jsxs)("div",{"data-slot":"code-editor","data-status":"error",className:w(z,"flex flex-col"),...F,children:[(0,o.jsx)("textarea",{id:a,"aria-label":l,"aria-labelledby":b,"aria-describedby":s,"aria-invalid":v||void 0,readOnly:i,disabled:p,spellCheck:!1,value:e,placeholder:t,onChange:E=>f&&f(E.target.value),onBlur:E=>m&&m(E.target.value,{changed:E.target.value!==e}),style:{minHeight:j,maxHeight:R},className:"w-full resize-y bg-transparent p-2 font-mono text-[13px] leading-[1.55] outline-none"}),(0,o.jsxs)("div",{className:"flex items-center justify-between gap-2 border-t border-border px-2 py-1 text-xs text-muted-foreground",children:[(0,o.jsx)("span",{children:"The code editor didn't load; editing as plain text."}),(0,o.jsx)("button",{type:"button",onClick:x.retry,className:"rounded px-1.5 py-0.5 font-medium hover:bg-muted",children:"Retry"})]})]}):(0,o.jsxs)("div",{"data-slot":"code-editor","data-status":x.status,"data-language":h,className:z,...F,children:[(0,o.jsx)("div",{ref:x.mountRef,style:{minHeight:j,maxHeight:R},className:w("flex flex-col overflow-auto [&>.cm-editor]:min-h-[inherit] [&>.cm-editor]:flex-1",x.status!=="ready"&&"hidden")}),x.status!=="ready"?(0,o.jsx)("pre",{"aria-busy":"true",style:{minHeight:j,maxHeight:R},className:w("m-0 overflow-auto py-1.5 font-mono text-[13px] leading-[1.55] whitespace-pre-wrap text-muted-foreground",c?"pl-11":"pl-2"),children:e||t||" "}):null]})}export{B as a,T as b,q as c,O as d,J as e};
2
- //# sourceMappingURL=chunk-EDEL6XSO.js.map
1
+ import{a as w}from"./chunk-SVQCDOZ3.js";import{a as V}from"./chunk-CT4EH2K2.js";import{a as A}from"./chunk-IJQ26FTX.js";import{c as k}from"./chunk-KVMUXFPB.js";var n=k(A());var o=k(V()),N=null,S=null;function B(){return S?Promise.resolve(S):(N||(N=import("./portal-code-Z5G6AEMM.js").then(u=>(S=u,u)).catch(u=>{throw N=null,u})),N)}function T(){return!!S}function q(u){let e=String(u||"").toLowerCase();return e==="script"||e==="script_plain"||e==="script_server"||e==="condition_string"?"javascript":e==="json"||e==="json_translations"?"json":e==="css"?"css":e==="xml"?"xml":e==="html_script"||e==="html_template"?"html":"text"}function L(u){let e=n.useRef(u);return e.current=u,e}function O(u={}){let{value:e="",language:f="text",readOnly:m=!1,attributes:C}=u,[g,h]=n.useState(()=>({status:S?"ready":"loading",error:null})),[i,p]=n.useState(null),[v,_]=n.useState(0),t=n.useRef(null),c=n.useRef(e||""),y=n.useRef(!1),r=L(u);n.useEffect(()=>{if(!i)return;let a=!0,l=null;return B().then(b=>{a&&(l=b.createCodeEditor({parent:i,value:c.current,language:f,readOnly:m,placeholder:r.current.placeholder,lineNumbers:r.current.lineNumbers,tabSize:r.current.tabSize,minLines:r.current.minLines,attributes:r.current.attributes||{},onChange:s=>{y.current=!0,c.current=s,r.current.onChange&&r.current.onChange(s)},onFocus:()=>r.current.onFocus&&r.current.onFocus(),onBlur:s=>r.current.onBlur&&r.current.onBlur(s,{changed:y.current}),onSubmit:r.current.onSubmit?s=>r.current.onSubmit(s):void 0}),t.current=l,h({status:"ready",error:null}))}).catch(b=>a&&h({status:"error",error:b})),()=>{a=!1,l&&l.destroy(),t.current=null}},[i,v]),n.useEffect(()=>{let a=e||"";a!==c.current&&(c.current=a,y.current=!1,t.current&&t.current.setValue(a))},[e]),n.useEffect(()=>{t.current&&t.current.setReadOnly(m)},[m,g.status]),n.useEffect(()=>{t.current&&t.current.setLanguage(f)},[f,g.status]);let R=JSON.stringify(C||{});return n.useEffect(()=>{t.current&&t.current.setAttributes(C||{})},[R,g.status]),{mountRef:p,status:g.status,error:g.error,retry:()=>{h({status:"loading",error:null}),_(a=>a+1)},focus:()=>t.current&&t.current.focus(),getValue:()=>t.current?t.current.getValue():c.current,get changed(){return y.current}}}function J({className:u,value:e="",onChange:f,onBlur:m,onFocus:C,onSubmit:g,language:h="javascript",readOnly:i=!1,disabled:p=!1,invalid:v=!1,required:_=!1,placeholder:t,lineNumbers:c=!0,tabSize:y=4,minLines:r=3,maxHeight:R="24rem",id:a,"aria-label":l,"aria-labelledby":b,"aria-describedby":s,...F}){let d={};a&&(d.id=a),l&&(d["aria-label"]=l),b&&(d["aria-labelledby"]=b),s&&(d["aria-describedby"]=s),v&&(d["aria-invalid"]="true"),_&&(d["aria-required"]="true"),(i||p)&&(d["aria-readonly"]="true");let x=O({value:e,onChange:f,onBlur:m,onFocus:C,onSubmit:g,language:h,readOnly:i||p,placeholder:t,lineNumbers:c,tabSize:y,minLines:r,attributes:d}),z=w("relative w-full min-w-0 overflow-hidden rounded-md border border-input bg-transparent shadow-xs transition-[color,box-shadow] dark:bg-input/30","focus-within:border-ring focus-within:ring-[3px] focus-within:ring-ring/50",v&&"border-destructive ring-destructive/20 focus-within:border-destructive",(i||p)&&"bg-muted/40 shadow-none dark:bg-muted/30",p&&"opacity-60",u),j=`calc(${r} * 1.55em + 14px)`;return x.status==="error"?(0,o.jsxs)("div",{"data-slot":"code-editor","data-status":"error",className:w(z,"flex flex-col"),...F,children:[(0,o.jsx)("textarea",{id:a,"aria-label":l,"aria-labelledby":b,"aria-describedby":s,"aria-invalid":v||void 0,readOnly:i,disabled:p,spellCheck:!1,value:e,placeholder:t,onChange:E=>f&&f(E.target.value),onBlur:E=>m&&m(E.target.value,{changed:E.target.value!==e}),style:{minHeight:j,maxHeight:R},className:"w-full resize-y bg-transparent p-2 font-mono text-[13px] leading-[1.55] outline-none"}),(0,o.jsxs)("div",{className:"flex items-center justify-between gap-2 border-t border-border px-2 py-1 text-xs text-muted-foreground",children:[(0,o.jsx)("span",{children:"The code editor didn't load; editing as plain text."}),(0,o.jsx)("button",{type:"button",onClick:x.retry,className:"rounded px-1.5 py-0.5 font-medium hover:bg-muted",children:"Retry"})]})]}):(0,o.jsxs)("div",{"data-slot":"code-editor","data-status":x.status,"data-language":h,className:z,...F,children:[(0,o.jsx)("div",{ref:x.mountRef,style:{minHeight:j,maxHeight:R},className:w("flex flex-col overflow-auto [&>.cm-editor]:min-h-[inherit] [&>.cm-editor]:flex-1",x.status!=="ready"&&"hidden")}),x.status!=="ready"?(0,o.jsx)("pre",{"aria-busy":"true",style:{minHeight:j,maxHeight:R},className:w("m-0 overflow-auto py-1.5 font-mono text-[13px] leading-[1.55] whitespace-pre-wrap text-muted-foreground",c?"pl-11":"pl-2"),children:e||t||" "}):null]})}export{B as a,T as b,q as c,O as d,J as e};
2
+ //# sourceMappingURL=chunk-ND526XXU.js.map
@@ -1,2 +1,2 @@
1
- import{a as r}from"./chunk-PHK25MY7.js";import{e,f as o,l as s}from"./chunk-JIAVZ3V7.js";function P(t){let{render:d,className:E,style:R,state:m=o,props:p=e,refs:i=e,metadata:a,stateAttributesMapping:n,tag:f="div",...c}=t,{compositeProps:u,compositeRef:l}=r({metadata:a});return s(f,t,{state:m,ref:[l,...i],props:[u,...p,c],stateAttributesMapping:n})}export{P as a};
2
- //# sourceMappingURL=chunk-UXUS6DNI.js.map
1
+ import{a as r}from"./chunk-DU3VFETH.js";import{e,f as o,l as s}from"./chunk-JIAVZ3V7.js";function P(t){let{render:d,className:E,style:R,state:m=o,props:p=e,refs:i=e,metadata:a,stateAttributesMapping:n,tag:f="div",...c}=t,{compositeProps:u,compositeRef:l}=r({metadata:a});return s(f,t,{state:m,ref:[l,...i],props:[u,...p,c],stateAttributesMapping:n})}export{P as a};
2
+ //# sourceMappingURL=chunk-NMFZMT4R.js.map
@@ -1,2 +1,2 @@
1
- import{a as e}from"./chunk-LTVKSGLG.js";import{Ma as g}from"./chunk-OXJ6LWKI.js";import{b as d}from"./chunk-CWDPAB6V.js";import{pb as u}from"./chunk-IQ2XSDFU.js";import{a as s}from"./chunk-CT4EH2K2.js";import{a as l}from"./chunk-SVQCDOZ3.js";import{a as m}from"./chunk-IJQ26FTX.js";import{c as n}from"./chunk-KVMUXFPB.js";var p=n(m());var o=n(s());function P({...a}){return(0,o.jsx)(e.Root,{"data-slot":"dialog",...a})}function N({...a}){return(0,o.jsx)(e.Trigger,{"data-slot":"dialog-trigger",...a})}function c({...a}){return(0,o.jsx)(e.Portal,{container:g(),"data-slot":"dialog-portal",...a})}function h({...a}){return(0,o.jsx)(e.Close,{"data-slot":"dialog-close",...a})}function f({className:a,...t}){return(0,o.jsx)(e.Backdrop,{"data-slot":"dialog-overlay",className:l("fixed inset-0 isolate z-50 bg-black/20 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",a),...t})}function y({className:a,children:t,showCloseButton:r=!0,...i}){return(0,o.jsxs)(c,{children:[(0,o.jsx)(f,{}),(0,o.jsxs)(e.Popup,{"data-slot":"dialog-content",className:l("fixed top-1/2 left-1/2 z-50 grid max-h-[calc(100dvh-2rem)] w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 overflow-y-auto rounded-xl bg-popover p-4 text-sm text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",a),...i,children:[t,r?(0,o.jsxs)(e.Close,{"data-slot":"dialog-close",render:(0,o.jsx)(d,{variant:"ghost",className:"absolute top-2 right-2",size:"icon-sm"}),children:[(0,o.jsx)(u,{}),(0,o.jsx)("span",{className:"sr-only",children:"Close"})]}):null]})]})}function w({className:a,...t}){return(0,o.jsx)("div",{"data-slot":"dialog-header",className:l("flex flex-col gap-2 pr-6",a),...t})}function z({className:a,showCloseButton:t=!1,children:r,...i}){return(0,o.jsxs)("div",{"data-slot":"dialog-footer",className:l("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end",a),...i,children:[r,t?(0,o.jsx)(e.Close,{render:(0,o.jsx)(d,{variant:"outline"}),children:"Close"}):null]})}function k({className:a,...t}){return(0,o.jsx)(e.Title,{"data-slot":"dialog-title",className:l("text-base leading-none font-medium",a),...t})}function T({className:a,...t}){return(0,o.jsx)(e.Description,{"data-slot":"dialog-description",className:l("text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",a),...t})}export{P as a,N as b,c,h as d,f as e,y as f,w as g,z as h,k as i,T as j};
2
- //# sourceMappingURL=chunk-XE5RQ73V.js.map
1
+ import{a as e}from"./chunk-UCEBXCOI.js";import{Ma as g}from"./chunk-HCQR5YME.js";import{b as d}from"./chunk-34RXMJIM.js";import{pb as u}from"./chunk-IQ2XSDFU.js";import{a as l}from"./chunk-SVQCDOZ3.js";import{a as s}from"./chunk-CT4EH2K2.js";import{a as m}from"./chunk-IJQ26FTX.js";import{c as n}from"./chunk-KVMUXFPB.js";var p=n(m());var o=n(s());function P({...a}){return(0,o.jsx)(e.Root,{"data-slot":"dialog",...a})}function N({...a}){return(0,o.jsx)(e.Trigger,{"data-slot":"dialog-trigger",...a})}function c({...a}){return(0,o.jsx)(e.Portal,{container:g(),"data-slot":"dialog-portal",...a})}function h({...a}){return(0,o.jsx)(e.Close,{"data-slot":"dialog-close",...a})}function f({className:a,...t}){return(0,o.jsx)(e.Backdrop,{"data-slot":"dialog-overlay",className:l("fixed inset-0 isolate z-50 bg-black/20 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",a),...t})}function y({className:a,children:t,showCloseButton:r=!0,...i}){return(0,o.jsxs)(c,{children:[(0,o.jsx)(f,{}),(0,o.jsxs)(e.Popup,{"data-slot":"dialog-content",className:l("fixed top-1/2 left-1/2 z-50 grid max-h-[calc(100dvh-2rem)] w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 overflow-y-auto rounded-xl bg-popover p-4 text-sm text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",a),...i,children:[t,r?(0,o.jsxs)(e.Close,{"data-slot":"dialog-close",render:(0,o.jsx)(d,{variant:"ghost",className:"absolute top-2 right-2",size:"icon-sm"}),children:[(0,o.jsx)(u,{}),(0,o.jsx)("span",{className:"sr-only",children:"Close"})]}):null]})]})}function w({className:a,...t}){return(0,o.jsx)("div",{"data-slot":"dialog-header",className:l("flex flex-col gap-2 pr-6",a),...t})}function z({className:a,showCloseButton:t=!1,children:r,...i}){return(0,o.jsxs)("div",{"data-slot":"dialog-footer",className:l("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end",a),...i,children:[r,t?(0,o.jsx)(e.Close,{render:(0,o.jsx)(d,{variant:"outline"}),children:"Close"}):null]})}function k({className:a,...t}){return(0,o.jsx)(e.Title,{"data-slot":"dialog-title",className:l("text-base leading-none font-medium",a),...t})}function T({className:a,...t}){return(0,o.jsx)(e.Description,{"data-slot":"dialog-description",className:l("text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",a),...t})}export{P as a,N as b,c,h as d,f as e,y as f,w as g,z as h,k as i,T as j};
2
+ //# sourceMappingURL=chunk-NPJXSRRT.js.map
@@ -1,2 +1,2 @@
1
- import{a as f,c as b,d as h,f as w,g,n as m}from"./chunk-2IZ44WWI.js";import{b as d}from"./chunk-CWDPAB6V.js";import{o as c}from"./chunk-IQ2XSDFU.js";import{a as p}from"./chunk-CT4EH2K2.js";import{a as l}from"./chunk-SVQCDOZ3.js";import{a as S}from"./chunk-IJQ26FTX.js";import{c as u}from"./chunk-KVMUXFPB.js";var L=u(S());var t=u(p());function I({className:e,orientation:o="horizontal",...r}){return(0,t.jsx)("div",{role:"group","data-slot":"button-group","data-orientation":o,className:l("flex w-fit items-stretch *:focus-visible:relative *:focus-visible:z-10",o==="vertical"?"flex-col *:not-first:border-t-0 [&>*:not(:nth-child(1_of_:not(input[aria-hidden=true])))]:rounded-t-none [&>*:not(:nth-last-child(1_of_:not(input[aria-hidden=true])))]:rounded-b-none":"*:not-first:border-l-0 [&>*:not(:nth-child(1_of_:not(input[aria-hidden=true])))]:rounded-l-none [&>*:not(:nth-last-child(1_of_:not(input[aria-hidden=true])))]:rounded-r-none",e),...r})}function G({className:e,...o}){return(0,t.jsx)("div",{role:"separator","aria-orientation":"vertical","data-slot":"button-group-separator",className:l("w-px self-stretch bg-primary-foreground/25",e),...o})}function z(e){return(e||[]).map((o,r)=>o?o.type==="separator"?(0,t.jsx)(m,{},"sep-"+r):o.type==="label"?(0,t.jsx)(w,{children:o.label},"label-"+r):(0,t.jsxs)(g,{disabled:o.disabled,variant:o.variant==="destructive"?"destructive":"default",onClick:o.onSelect,children:[o.icon||null,(0,t.jsx)("span",{className:"min-w-0 flex-1 truncate",children:o.label}),o.shortcut?(0,t.jsx)("span",{className:"ml-auto pl-4 text-xs tracking-widest text-muted-foreground",children:o.shortcut}):null]},o.id||o.label||r):null)}function E({className:e,children:o,onClick:r,variant:n="default",size:a="default",disabled:s=!1,menuDisabled:D=!1,items:M,menu:v,menuLabel:x="More options",align:y="end",type:N="button",buttonProps:_,...k}){let i=n==="default"||n==="destructive"||n==="destructive-soft"||n==="secondary",B=n==="default"?"":n==="destructive"?"bg-white/30":"bg-foreground/15",C=a==="sm"?"icon-sm":a==="xs"?"icon-xs":a==="lg"?"icon-lg":"icon";return(0,t.jsxs)(I,{"data-slot":"split-button",className:e,...k,children:[(0,t.jsx)(d,{type:N,variant:n,size:a,disabled:s,onClick:r,..._,children:o}),i?(0,t.jsx)(G,{className:B}):null,(0,t.jsxs)(f,{children:[(0,t.jsx)(b,{disabled:s||D,"aria-label":x,render:(0,t.jsx)(d,{variant:n,size:C,className:l(i&&"border-l-0")}),children:(0,t.jsx)(c,{"aria-hidden":"true"})}),(0,t.jsx)(h,{align:y,className:"w-auto min-w-44",children:v||z(M)})]})]})}export{I as a,G as b,E as c};
2
- //# sourceMappingURL=chunk-FJRWQRLM.js.map
1
+ import{a as f,c as b,d as h,f as w,g,n as m}from"./chunk-E5JYU6CR.js";import{b as d}from"./chunk-34RXMJIM.js";import{o as c}from"./chunk-IQ2XSDFU.js";import{a as l}from"./chunk-SVQCDOZ3.js";import{a as p}from"./chunk-CT4EH2K2.js";import{a as S}from"./chunk-IJQ26FTX.js";import{c as u}from"./chunk-KVMUXFPB.js";var L=u(S());var t=u(p());function I({className:e,orientation:o="horizontal",...r}){return(0,t.jsx)("div",{role:"group","data-slot":"button-group","data-orientation":o,className:l("flex w-fit items-stretch *:focus-visible:relative *:focus-visible:z-10",o==="vertical"?"flex-col *:not-first:border-t-0 [&>*:not(:nth-child(1_of_:not(input[aria-hidden=true])))]:rounded-t-none [&>*:not(:nth-last-child(1_of_:not(input[aria-hidden=true])))]:rounded-b-none":"*:not-first:border-l-0 [&>*:not(:nth-child(1_of_:not(input[aria-hidden=true])))]:rounded-l-none [&>*:not(:nth-last-child(1_of_:not(input[aria-hidden=true])))]:rounded-r-none",e),...r})}function G({className:e,...o}){return(0,t.jsx)("div",{role:"separator","aria-orientation":"vertical","data-slot":"button-group-separator",className:l("w-px self-stretch bg-primary-foreground/25",e),...o})}function z(e){return(e||[]).map((o,r)=>o?o.type==="separator"?(0,t.jsx)(m,{},"sep-"+r):o.type==="label"?(0,t.jsx)(w,{children:o.label},"label-"+r):(0,t.jsxs)(g,{disabled:o.disabled,variant:o.variant==="destructive"?"destructive":"default",onClick:o.onSelect,children:[o.icon||null,(0,t.jsx)("span",{className:"min-w-0 flex-1 truncate",children:o.label}),o.shortcut?(0,t.jsx)("span",{className:"ml-auto pl-4 text-xs tracking-widest text-muted-foreground",children:o.shortcut}):null]},o.id||o.label||r):null)}function E({className:e,children:o,onClick:r,variant:n="default",size:a="default",disabled:s=!1,menuDisabled:D=!1,items:M,menu:v,menuLabel:x="More options",align:y="end",type:N="button",buttonProps:_,...k}){let i=n==="default"||n==="destructive"||n==="destructive-soft"||n==="secondary",B=n==="default"?"":n==="destructive"?"bg-white/30":"bg-foreground/15",C=a==="sm"?"icon-sm":a==="xs"?"icon-xs":a==="lg"?"icon-lg":"icon";return(0,t.jsxs)(I,{"data-slot":"split-button",className:e,...k,children:[(0,t.jsx)(d,{type:N,variant:n,size:a,disabled:s,onClick:r,..._,children:o}),i?(0,t.jsx)(G,{className:B}):null,(0,t.jsxs)(f,{children:[(0,t.jsx)(b,{disabled:s||D,"aria-label":x,render:(0,t.jsx)(d,{variant:n,size:C,className:l(i&&"border-l-0")}),children:(0,t.jsx)(c,{"aria-hidden":"true"})}),(0,t.jsx)(h,{align:y,className:"w-auto min-w-44",children:v||z(M)})]})]})}export{I as a,G as b,E as c};
2
+ //# sourceMappingURL=chunk-OUCK2LIZ.js.map
@@ -1,2 +1,2 @@
1
- import{ka as g,la as m}from"./chunk-OXJ6LWKI.js";import{a as O}from"./chunk-RCNX6LVJ.js";import{a as p,c as l}from"./chunk-FTWKUXER.js";import{a as h}from"./chunk-2L7NK6SJ.js";import{d,f as i}from"./chunk-JIAVZ3V7.js";import{a as w}from"./chunk-IJQ26FTX.js";import{c}from"./chunk-KVMUXFPB.js";var f=class{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(t,o,n=!0){this.fallbackStore=t,this.componentName=o,this.throwOnMissingTrigger=n}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(t){return this.storeListeners.add(t),()=>{this.storeListeners.delete(t)}}attachStore(t){if(this.attachedStores.push(t),this.setActiveStore(t),this.attachedStores.length>1){let o=this;(o.overlapWarningFrame??=h.create()).request(()=>{this.attachedStores.length>1&&console.warn("Base UI: A handle is attached to more than one mounted root at the same time. The most recently mounted root takes over and the previous one stops being controlled by the handle. A handle should be used by a single root that stays mounted for the lifetime of the handle.")})}return()=>{let o=this.attachedStores.lastIndexOf(t);o!==-1&&this.attachedStores.splice(o,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(t){this.attachedStoreValue!==t&&(this.attachedStoreValue=t,this.storeListeners.forEach(o=>{o()}))}openByTrigger(t){let o=this.attachedStore;if(o===null){console.warn(`Base UI: ${this.componentName}Handle.open() was called while no root using this handle is mounted. The call was ignored; mount a root with this handle before opening it imperatively.`);return}let n;if(t){for(let a=this.attachedStores.length-1;a>=0&&!n;a-=1)n=this.attachedStores[a].context.triggerElements.getById(t);n??=this.fallbackStore.context.triggerElements.getById(t)}if(t&&!n){if(this.throwOnMissingTrigger)throw new Error(`Base UI: ${this.componentName}Handle.open() was called with the trigger id "${t}", but no matching trigger is registered with this handle. An anchored popup cannot open without a trigger to anchor to. Pass the id of a mounted ${this.componentName}.Trigger that has this handle set on its "handle" prop.`);console.warn(`Base UI: ${this.componentName}Handle.open: No trigger found with id "${t}". The popup will open, but the trigger will not be associated with it.`)}o.setOpen(!0,p(l.imperativeAction,void 0,n))}closePopup(){let t=this.attachedStore;if(t===null){console.warn(`Base UI: ${this.componentName}Handle.close() was called while no root using this handle is mounted. The call was ignored.`);return}t.setOpen(!1,p(l.imperativeAction))}};var u=c(w(),1),S=c(O(),1);function I(e){let t=u.useCallback(n=>e===void 0?d:e.subscribeStore(n),[e]),o=u.useCallback(()=>e===void 0?void 0:e.store,[e]);return(0,S.useSyncExternalStore)(t,o,()=>e?.serverStore)}function V(e,t,o=!1){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:new m({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:o,onOpenChange:void 0}),floatingId:t,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,openedWithoutTrigger:!1,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:i,inactiveTriggerProps:i,popupProps:i}}var r=e=>e.triggerIdProp??e.activeTriggerId,s=e=>e.openProp??e.open,v=e=>(e.popupElement?.id??e.floatingId)||void 0;function E(e,t){return t!==void 0&&s(e)&&r(e)===t}function b(e,t){return E(e,t)?!0:t!==void 0&&s(e)&&r(e)==null&&!e.openedWithoutTrigger&&e.triggerCount===1}var R={open:s,mounted:e=>e.mounted,transitionStatus:e=>s(e)&&!e.mounted?"starting":e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:r,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:v,isTriggerActive:(e,t)=>t!==void 0&&r(e)===t,isOpenedByTrigger:(e,t)=>E(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&r(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>b(e,t)?v(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement};var T=class extends g{setState(t){}update(t){}set(t,o){}notifyAll(){}};export{f as a,V as b,R as c,I as d,T as e};
2
- //# sourceMappingURL=chunk-Z76KXEPD.js.map
1
+ import{ka as g,la as m}from"./chunk-HCQR5YME.js";import{a as O}from"./chunk-RCNX6LVJ.js";import{a as p,c as l}from"./chunk-FTWKUXER.js";import{a as h}from"./chunk-2L7NK6SJ.js";import{d,f as i}from"./chunk-JIAVZ3V7.js";import{a as w}from"./chunk-IJQ26FTX.js";import{c}from"./chunk-KVMUXFPB.js";var f=class{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(t,o,n=!0){this.fallbackStore=t,this.componentName=o,this.throwOnMissingTrigger=n}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(t){return this.storeListeners.add(t),()=>{this.storeListeners.delete(t)}}attachStore(t){if(this.attachedStores.push(t),this.setActiveStore(t),this.attachedStores.length>1){let o=this;(o.overlapWarningFrame??=h.create()).request(()=>{this.attachedStores.length>1&&console.warn("Base UI: A handle is attached to more than one mounted root at the same time. The most recently mounted root takes over and the previous one stops being controlled by the handle. A handle should be used by a single root that stays mounted for the lifetime of the handle.")})}return()=>{let o=this.attachedStores.lastIndexOf(t);o!==-1&&this.attachedStores.splice(o,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(t){this.attachedStoreValue!==t&&(this.attachedStoreValue=t,this.storeListeners.forEach(o=>{o()}))}openByTrigger(t){let o=this.attachedStore;if(o===null){console.warn(`Base UI: ${this.componentName}Handle.open() was called while no root using this handle is mounted. The call was ignored; mount a root with this handle before opening it imperatively.`);return}let n;if(t){for(let a=this.attachedStores.length-1;a>=0&&!n;a-=1)n=this.attachedStores[a].context.triggerElements.getById(t);n??=this.fallbackStore.context.triggerElements.getById(t)}if(t&&!n){if(this.throwOnMissingTrigger)throw new Error(`Base UI: ${this.componentName}Handle.open() was called with the trigger id "${t}", but no matching trigger is registered with this handle. An anchored popup cannot open without a trigger to anchor to. Pass the id of a mounted ${this.componentName}.Trigger that has this handle set on its "handle" prop.`);console.warn(`Base UI: ${this.componentName}Handle.open: No trigger found with id "${t}". The popup will open, but the trigger will not be associated with it.`)}o.setOpen(!0,p(l.imperativeAction,void 0,n))}closePopup(){let t=this.attachedStore;if(t===null){console.warn(`Base UI: ${this.componentName}Handle.close() was called while no root using this handle is mounted. The call was ignored.`);return}t.setOpen(!1,p(l.imperativeAction))}};var u=c(w(),1),S=c(O(),1);function I(e){let t=u.useCallback(n=>e===void 0?d:e.subscribeStore(n),[e]),o=u.useCallback(()=>e===void 0?void 0:e.store,[e]);return(0,S.useSyncExternalStore)(t,o,()=>e?.serverStore)}function V(e,t,o=!1){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:new m({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:o,onOpenChange:void 0}),floatingId:t,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,openedWithoutTrigger:!1,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:i,inactiveTriggerProps:i,popupProps:i}}var r=e=>e.triggerIdProp??e.activeTriggerId,s=e=>e.openProp??e.open,v=e=>(e.popupElement?.id??e.floatingId)||void 0;function E(e,t){return t!==void 0&&s(e)&&r(e)===t}function b(e,t){return E(e,t)?!0:t!==void 0&&s(e)&&r(e)==null&&!e.openedWithoutTrigger&&e.triggerCount===1}var R={open:s,mounted:e=>e.mounted,transitionStatus:e=>s(e)&&!e.mounted?"starting":e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:r,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:v,isTriggerActive:(e,t)=>t!==void 0&&r(e)===t,isOpenedByTrigger:(e,t)=>E(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&r(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>b(e,t)?v(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement};var T=class extends g{setState(t){}update(t){}set(t,o){}notifyAll(){}};export{f as a,V as b,R as c,I as d,T as e};
2
+ //# sourceMappingURL=chunk-OXLXEX2R.js.map
@@ -1,2 +1,2 @@
1
- import{a}from"./chunk-4UUMO65R.js";import{a as m}from"./chunk-RCNX6LVJ.js";import{a as f}from"./chunk-CT4EH2K2.js";import{h as i}from"./chunk-JIAVZ3V7.js";import{a as o}from"./chunk-IJQ26FTX.js";import{c as t}from"./chunk-KVMUXFPB.js";var e=t(o(),1),u=t(m(),1);var p=()=>()=>{},y=()=>!0,H=()=>!1;function g(){return(0,u.useSyncExternalStore)(p,y,H)}function l(){let[r,s]=e.useState(!1);return e.useEffect(()=>{s(!0)},[]),r}var x=i(18)?g:l;function n(){return!x()}var _=t(o(),1);var c=t(f(),1);function C(r){let{script:s}=r,{nonce:d}=a();return n()?(0,c.jsx)("script",{nonce:d,dangerouslySetInnerHTML:{__html:s},suppressHydrationWarning:!0}):null}export{n as a,C as b};
2
- //# sourceMappingURL=chunk-BH6FGVDP.js.map
1
+ import{a}from"./chunk-4UUMO65R.js";import{a as m}from"./chunk-RCNX6LVJ.js";import{h as i}from"./chunk-JIAVZ3V7.js";import{a as f}from"./chunk-CT4EH2K2.js";import{a as o}from"./chunk-IJQ26FTX.js";import{c as t}from"./chunk-KVMUXFPB.js";var e=t(o(),1),u=t(m(),1);var p=()=>()=>{},y=()=>!0,H=()=>!1;function g(){return(0,u.useSyncExternalStore)(p,y,H)}function l(){let[r,s]=e.useState(!1);return e.useEffect(()=>{s(!0)},[]),r}var x=i(18)?g:l;function n(){return!x()}var _=t(o(),1);var c=t(f(),1);function C(r){let{script:s}=r,{nonce:d}=a();return n()?(0,c.jsx)("script",{nonce:d,dangerouslySetInnerHTML:{__html:s},suppressHydrationWarning:!0}):null}export{n as a,C as b};
2
+ //# sourceMappingURL=chunk-PB5RYDO5.js.map
@@ -1,2 +1,2 @@
1
- import{a as at}from"./chunk-33RMFA4P.js";import{Aa as nt,Ba as ot,Ca as it,D as et,Da as rt,Ea as st,Fa as ct,L as tt,za as Se}from"./chunk-OXJ6LWKI.js";import{l as Je,m as qe,n as G,o as _,q as Ke,r as we,s as Qe,x as Ze}from"./chunk-QFN6XL4O.js";import{o as Ge}from"./chunk-7OCTAHT6.js";import{b as re}from"./chunk-R5KQ2GRA.js";import{b as je,e as Ne,t as Xe}from"./chunk-LYT7LQS3.js";import{a as ze}from"./chunk-SFI7YWVR.js";import{b as W}from"./chunk-NZ73KS2Y.js";import{f as Ue,l as Ye}from"./chunk-JIAVZ3V7.js";import{a as _e}from"./chunk-IJQ26FTX.js";import{c as We}from"./chunk-KVMUXFPB.js";function lt(n){return n==="starting"?et:Ue}var p=We(_e(),1);var x=We(_e(),1);function ft(n){let{nodeId:l,externalTree:a,rootContext:e}=n,i=e.useState("referenceElement"),r=e.useState("floatingElement"),f=e.useState("domReferenceElement"),y=e.useState("open"),b=e.useState("floatingId"),[L,V]=x.useState(null),C=x.useRef(null),w=tt(a),d=x.useMemo(()=>({reference:i,floating:r,domReference:f}),[i,r,f]),o=nt({...n,elements:{...d,...L&&{reference:L}}}),g=x.useCallback(h=>{let P=Ne(h)?{getBoundingClientRect:()=>h.getBoundingClientRect(),getClientRects:()=>h.getClientRects(),contextElement:h}:h;V(P),o.refs.setReference(P)},[o.refs]),s=x.useMemo(()=>({...o.refs,setPositionReference:g,domReference:C}),[o.refs,g]),S=x.useMemo(()=>({...o.elements,domReference:f}),[o.elements,f]),E=x.useMemo(()=>({...o,dataRef:e.context.dataRef,open:y,onOpenChange:e.setOpen,events:e.context.events,floatingId:b,refs:s,elements:S,nodeId:l,rootStore:e}),[o,s,S,l,e,y,b]);return W(()=>{f&&(C.current=f)},[f]),W(()=>{e.context.dataRef.current.floatingContext=E;let h=w?.nodesRef.current.find(P=>P.id===l);h&&(h.context=E)}),x.useMemo(()=>({...o,context:E,refs:s,elements:S,rootStore:e}),[o,s,S,E,e])}var Vt=n=>({name:"arrow",options:n,async fn(l){let{x:a,y:e,placement:i,rects:r,platform:f,elements:y,middlewareData:b}=l,{element:L,padding:V=0}=qe(n,l)||{};if(L==null)return{};let C=Ze(V),w={x:a,y:e},d=Qe(i),o=Ke(d),g=await f.getDimensions(L),s=d==="y",S=s?"top":"left",E=s?"bottom":"right",h=s?"clientHeight":"clientWidth",P=r.reference[o]+r.reference[d]-w[d]-r.floating[o],J=w[d]-r.reference[d],q=y.floating[h]||r.floating[o],B=P/2-J/2,M=q/2-g[o]/2-1,se=Math.min(C[S],M),$=Math.min(C[E],M),k=se,K=q-g[o]-$,O=q/2-g[o]/2+B,z=Je(k,O,K),v=!b.arrow&&_(i)!=null&&O!==z&&r.reference[o]/2-(O<k?se:$)-g[o]/2<0,Q=v?O<k?O-k:O-K:0;return{[d]:w[d]+Q,data:{[d]:z,centerOffset:O-z-Q,...v&&{alignmentOffset:Q}},reset:v}}}),dt=(n,l)=>{let{name:a,fn:e}=Vt(n);return{name:a,fn:e,options:[n,l]}};var ut={name:"hide",async fn(n){let{width:l,height:a,x:e,y:i}=n.rects.reference,r=l===0&&a===0&&e===0&&i===0,f=await n.platform.detectOverflow(n,{elementContext:"reference"});return{data:{referenceHidden:f.top-a>=0||f.right-l>=0||f.bottom-a>=0||f.left-l>=0||r}}}};var mt={sideX:"left",sideY:"top"};var pt="--available-width",gt="--available-height",ht="--anchor-width",Rt="--anchor-height",xt="--transform-origin",Kt="--positioner-width",Qt="--positioner-height";var yt=pt,At=gt;function St(n,l,a){let e=n==="inline-start"||n==="inline-end";return{top:"top",right:e?a?"inline-start":"inline-end":"right",bottom:"bottom",left:e?a?"inline-end":"inline-start":"left"}[l]}function bt(n,l,a){let{rects:e,placement:i}=n;return{side:St(l,G(i),a),align:_(i)||"center",anchor:{width:e.reference.width,height:e.reference.height},positioner:{width:e.floating.width,height:e.floating.height}}}function dn(n){return $t(n,ft)}function $t(n,l){let{anchor:a,positionMethod:e="absolute",side:i="bottom",sideOffset:r=0,align:f="center",alignOffset:y=0,collisionBoundary:b,collisionPadding:L=5,sticky:V=!1,arrowPadding:C=5,disableAnchorTracking:w=!1,inline:d,keepMounted:o=!1,floatingRootContext:g,mounted:s,collisionAvoidance:S,shift:E,nodeId:h,adaptiveOrigin:P,lazyFlip:J=!1,externalTree:q}=n,B=S.side||"flip",M=S.align||"flip",se=S.fallbackAxisSide||"end",$=E?.crossAxis??!1,k=E?.rootBoundary,K=typeof a=="function"?a:void 0,O=ze(K),z=K?O:a,v=re(a),Q=re(s),U=at()==="rtl",[Z,Pe]=p.useState(null);!s&&Z!==null&&Pe(null);let Re=J==="placement",Pt=Z?G(Z):null,Et=Z&&Re?_(Z)||"center":null,ce=Pt||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":U?"left":"right","inline-start":U?"right":"left"}[i],ee=Et||f,Ot=ee==="center"?ce:`${ce}-${ee}`,c=L;typeof c=="number"?c={top:c,right:c,bottom:c,left:c}:c&&(c={top:c.top||0,right:c.right||0,bottom:c.bottom||0,left:c.left||0});let D=1,Ct=i==="bottom"?D:0,Mt=i==="top"?D:0,vt=i==="right"?D:0,Dt=i==="left"?D:0,ae={boundary:b==="clipping-ancestors"?"clippingAncestors":b,padding:c},F=p.useRef(null),xe=re(r),ye=re(y),Ht=typeof r!="function"?r:0,It=typeof y!="function"?y:0,Y=[];d&&Y.push(d),Y.push(ot(t=>{let m=bt(t,i,U),R=typeof xe.current=="function"?xe.current(m):xe.current,u=typeof ye.current=="function"?ye.current(m):ye.current;return{mainAxis:R,crossAxis:u,alignmentAxis:u}},[Ht,It,U,i]));let Ee=M==="none"&&B!=="shift",Oe=!Ee&&(V||$||B==="shift"),Ce=B==="none"?null:st({...ae,padding:{top:c.top+D+Ct,right:c.right+D+Dt,bottom:c.bottom+D+Mt,left:c.left+D+vt},mainAxis:!$&&B==="flip",crossAxis:M==="flip"?"alignment":!1,fallbackAxisSideDirection:se}),Me=Ee?null:it({...ae,rootBoundary:k,mainAxis:M!=="none",crossAxis:Oe,limiter:V||$?void 0:rt(t=>{if(!F.current)return{};let{width:m,height:R}=F.current.getBoundingClientRect(),u=we(G(t.placement)),I=u==="y"?m:R,A=u==="y"?c.left+c.right:c.top+c.bottom;return{offset:I/2+A/2}})},[ae,V,$,k,c,M]);B==="shift"||M==="shift"||ee==="center"?Y.push(Me,Ce):Y.push(Ce,Me),Y.push(ct({...ae,apply({elements:{floating:t},availableWidth:m,availableHeight:R,rects:u}){if(!Q.current)return;let I=t.style;I.setProperty(yt,`${m}px`),I.setProperty(At,`${R}px`);let A=je(t).devicePixelRatio||1,{x:pe,y:X,width:ge,height:T}=u.reference,oe=(Math.round((pe+ge)*A)-Math.round(pe*A))/A,ie=(Math.round((X+T)*A)-Math.round(X*A))/A;I.setProperty(ht,`${oe}px`),I.setProperty(Rt,`${ie}px`)}}),dt(t=>({element:F.current||Xe(t.elements.floating).createElement("div"),padding:F.current?C:0}),[C]),{name:"transformOrigin",fn(t){let{elements:{floating:m},middlewareData:R,placement:u,platform:I,rects:A,y:pe}=t,X=G(u),ge=_(u),T=we(X)==="y",oe=F.current,ie=typeof r=="function"?r(bt(t,i,U)):r,he;if(!oe&&ge&&Math.abs(T?R.shift?.x||0:R.shift?.y||0)<=1)he=ge==="start"===(T&&I.isRTL?.(m)===!0)?"100%":"0%";else{let Tt=T?R.arrow?.x||0:R.arrow?.y||0,Lt=T?oe?.clientWidth||0:oe?.clientHeight||0;he=`${Tt+Lt/2}px`}let be=X==="top"||X==="left"?`calc(100% + ${ie}px)`:`${-ie}px`;return Oe&&T&&Math.abs(R.shift?.y||0)>ie&&(be=`${A.reference.y+A.reference.height/2-pe}px`),m.style.setProperty(xt,T?`${he} ${be}`:`${be} ${he}`),{}}},ut,P),W(()=>{!s&&g&&g.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[s,g]);let Ae=p.useMemo(()=>({ancestorScroll:!w,elementResize:!w&&typeof ResizeObserver<"u",layoutShift:!w&&typeof IntersectionObserver<"u"}),[w]),{refs:j,elements:te,x:ve,y:De,middlewareData:N,update:le,placement:fe,context:He,isPositioned:H,floatingStyles:Ie}=l({rootContext:g,open:o?s:void 0,placement:Ot,middleware:Y,strategy:e,whileElementsMounted:o?void 0:(...t)=>Se(...t,Ae),nodeId:h,externalTree:q}),{sideX:Te,sideY:Le}=N.adaptiveOrigin||mt,de=H?e:"fixed",Ve=p.useMemo(()=>{let t;return H?P?t={position:de,[Te]:ve,[Le]:De}:t={...Ie,position:de}:t={position:de,top:0,left:0},t[yt]="100vw",t[At]="100vh",H||(t.opacity=0),t},[P,de,Te,ve,Le,De,Ie,H]),ue=p.useRef(null);W(()=>{if(!s)return;let t=v.current,m=typeof t=="function"?t():t,u=(wt(m)?m.current:m)||null||null;u!==ue.current&&(j.setPositionReference(u),ue.current=u)},[s,j,z,v]),p.useEffect(()=>{if(!s)return;let t=v.current;typeof t!="function"&&wt(t)&&t.current!==ue.current&&(j.setPositionReference(t.current),ue.current=t.current)},[s,j,z,v]),p.useEffect(()=>{if(o&&s&&te.reference&&te.floating)return Se(te.reference,te.floating,le,Ae)},[o,s,te,le,Ae]);let ne=G(fe),Be=St(i,ne,U),me=_(fe)||"center",$e=!!N.hide?.referenceHidden;W(()=>{J&&s&&H&&(ne!==ce||Re&&me!==ee)&&Pe(fe)},[J,Re,s,H,fe,ne,me,ce,ee]);let ke=p.useMemo(()=>({position:"absolute",top:N.arrow?.y,left:N.arrow?.x}),[N.arrow]),Fe=N.arrow?.centerOffset!==0;return p.useMemo(()=>({positionerStyles:Ve,arrowStyles:ke,arrowRef:F,arrowUncentered:Fe,side:Be,align:me,physicalSide:ne,anchorHidden:$e,refs:j,context:He,isPositioned:H,update:le}),[Ve,ke,F,Fe,Be,me,ne,$e,j,He,H,le])}function wt(n){return n!=null&&"current"in n}function hn(n,l,{styles:a,transitionStatus:e,props:i,refs:r,hidden:f,inert:y=!1}){let b={...a};return y&&(b.pointerEvents="none"),Ye("div",n,{state:l,ref:r,props:[{role:"presentation",hidden:f,style:b},lt(e),i],stateAttributesMapping:Ge})}export{lt as a,mt as b,pt as c,gt as d,Kt as e,Qt as f,dn as g,hn as h};
2
- //# sourceMappingURL=chunk-TQPXDAVH.js.map
1
+ import{a as at}from"./chunk-33RMFA4P.js";import{Aa as nt,Ba as ot,Ca as it,D as et,Da as rt,Ea as st,Fa as ct,L as tt,za as Se}from"./chunk-HCQR5YME.js";import{l as Je,m as qe,n as G,o as _,q as Ke,r as we,s as Qe,x as Ze}from"./chunk-QFN6XL4O.js";import{o as Ge}from"./chunk-7OCTAHT6.js";import{b as re}from"./chunk-R5KQ2GRA.js";import{b as je,e as Ne,t as Xe}from"./chunk-LYT7LQS3.js";import{a as ze}from"./chunk-SFI7YWVR.js";import{b as W}from"./chunk-NZ73KS2Y.js";import{f as Ue,l as Ye}from"./chunk-JIAVZ3V7.js";import{a as _e}from"./chunk-IJQ26FTX.js";import{c as We}from"./chunk-KVMUXFPB.js";function lt(n){return n==="starting"?et:Ue}var p=We(_e(),1);var x=We(_e(),1);function ft(n){let{nodeId:l,externalTree:a,rootContext:e}=n,i=e.useState("referenceElement"),r=e.useState("floatingElement"),f=e.useState("domReferenceElement"),y=e.useState("open"),b=e.useState("floatingId"),[L,V]=x.useState(null),C=x.useRef(null),w=tt(a),d=x.useMemo(()=>({reference:i,floating:r,domReference:f}),[i,r,f]),o=nt({...n,elements:{...d,...L&&{reference:L}}}),g=x.useCallback(h=>{let P=Ne(h)?{getBoundingClientRect:()=>h.getBoundingClientRect(),getClientRects:()=>h.getClientRects(),contextElement:h}:h;V(P),o.refs.setReference(P)},[o.refs]),s=x.useMemo(()=>({...o.refs,setPositionReference:g,domReference:C}),[o.refs,g]),S=x.useMemo(()=>({...o.elements,domReference:f}),[o.elements,f]),E=x.useMemo(()=>({...o,dataRef:e.context.dataRef,open:y,onOpenChange:e.setOpen,events:e.context.events,floatingId:b,refs:s,elements:S,nodeId:l,rootStore:e}),[o,s,S,l,e,y,b]);return W(()=>{f&&(C.current=f)},[f]),W(()=>{e.context.dataRef.current.floatingContext=E;let h=w?.nodesRef.current.find(P=>P.id===l);h&&(h.context=E)}),x.useMemo(()=>({...o,context:E,refs:s,elements:S,rootStore:e}),[o,s,S,E,e])}var Vt=n=>({name:"arrow",options:n,async fn(l){let{x:a,y:e,placement:i,rects:r,platform:f,elements:y,middlewareData:b}=l,{element:L,padding:V=0}=qe(n,l)||{};if(L==null)return{};let C=Ze(V),w={x:a,y:e},d=Qe(i),o=Ke(d),g=await f.getDimensions(L),s=d==="y",S=s?"top":"left",E=s?"bottom":"right",h=s?"clientHeight":"clientWidth",P=r.reference[o]+r.reference[d]-w[d]-r.floating[o],J=w[d]-r.reference[d],q=y.floating[h]||r.floating[o],B=P/2-J/2,M=q/2-g[o]/2-1,se=Math.min(C[S],M),$=Math.min(C[E],M),k=se,K=q-g[o]-$,O=q/2-g[o]/2+B,z=Je(k,O,K),v=!b.arrow&&_(i)!=null&&O!==z&&r.reference[o]/2-(O<k?se:$)-g[o]/2<0,Q=v?O<k?O-k:O-K:0;return{[d]:w[d]+Q,data:{[d]:z,centerOffset:O-z-Q,...v&&{alignmentOffset:Q}},reset:v}}}),dt=(n,l)=>{let{name:a,fn:e}=Vt(n);return{name:a,fn:e,options:[n,l]}};var ut={name:"hide",async fn(n){let{width:l,height:a,x:e,y:i}=n.rects.reference,r=l===0&&a===0&&e===0&&i===0,f=await n.platform.detectOverflow(n,{elementContext:"reference"});return{data:{referenceHidden:f.top-a>=0||f.right-l>=0||f.bottom-a>=0||f.left-l>=0||r}}}};var mt={sideX:"left",sideY:"top"};var pt="--available-width",gt="--available-height",ht="--anchor-width",Rt="--anchor-height",xt="--transform-origin",Kt="--positioner-width",Qt="--positioner-height";var yt=pt,At=gt;function St(n,l,a){let e=n==="inline-start"||n==="inline-end";return{top:"top",right:e?a?"inline-start":"inline-end":"right",bottom:"bottom",left:e?a?"inline-end":"inline-start":"left"}[l]}function bt(n,l,a){let{rects:e,placement:i}=n;return{side:St(l,G(i),a),align:_(i)||"center",anchor:{width:e.reference.width,height:e.reference.height},positioner:{width:e.floating.width,height:e.floating.height}}}function dn(n){return $t(n,ft)}function $t(n,l){let{anchor:a,positionMethod:e="absolute",side:i="bottom",sideOffset:r=0,align:f="center",alignOffset:y=0,collisionBoundary:b,collisionPadding:L=5,sticky:V=!1,arrowPadding:C=5,disableAnchorTracking:w=!1,inline:d,keepMounted:o=!1,floatingRootContext:g,mounted:s,collisionAvoidance:S,shift:E,nodeId:h,adaptiveOrigin:P,lazyFlip:J=!1,externalTree:q}=n,B=S.side||"flip",M=S.align||"flip",se=S.fallbackAxisSide||"end",$=E?.crossAxis??!1,k=E?.rootBoundary,K=typeof a=="function"?a:void 0,O=ze(K),z=K?O:a,v=re(a),Q=re(s),U=at()==="rtl",[Z,Pe]=p.useState(null);!s&&Z!==null&&Pe(null);let Re=J==="placement",Pt=Z?G(Z):null,Et=Z&&Re?_(Z)||"center":null,ce=Pt||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":U?"left":"right","inline-start":U?"right":"left"}[i],ee=Et||f,Ot=ee==="center"?ce:`${ce}-${ee}`,c=L;typeof c=="number"?c={top:c,right:c,bottom:c,left:c}:c&&(c={top:c.top||0,right:c.right||0,bottom:c.bottom||0,left:c.left||0});let D=1,Ct=i==="bottom"?D:0,Mt=i==="top"?D:0,vt=i==="right"?D:0,Dt=i==="left"?D:0,ae={boundary:b==="clipping-ancestors"?"clippingAncestors":b,padding:c},F=p.useRef(null),xe=re(r),ye=re(y),Ht=typeof r!="function"?r:0,It=typeof y!="function"?y:0,Y=[];d&&Y.push(d),Y.push(ot(t=>{let m=bt(t,i,U),R=typeof xe.current=="function"?xe.current(m):xe.current,u=typeof ye.current=="function"?ye.current(m):ye.current;return{mainAxis:R,crossAxis:u,alignmentAxis:u}},[Ht,It,U,i]));let Ee=M==="none"&&B!=="shift",Oe=!Ee&&(V||$||B==="shift"),Ce=B==="none"?null:st({...ae,padding:{top:c.top+D+Ct,right:c.right+D+Dt,bottom:c.bottom+D+Mt,left:c.left+D+vt},mainAxis:!$&&B==="flip",crossAxis:M==="flip"?"alignment":!1,fallbackAxisSideDirection:se}),Me=Ee?null:it({...ae,rootBoundary:k,mainAxis:M!=="none",crossAxis:Oe,limiter:V||$?void 0:rt(t=>{if(!F.current)return{};let{width:m,height:R}=F.current.getBoundingClientRect(),u=we(G(t.placement)),I=u==="y"?m:R,A=u==="y"?c.left+c.right:c.top+c.bottom;return{offset:I/2+A/2}})},[ae,V,$,k,c,M]);B==="shift"||M==="shift"||ee==="center"?Y.push(Me,Ce):Y.push(Ce,Me),Y.push(ct({...ae,apply({elements:{floating:t},availableWidth:m,availableHeight:R,rects:u}){if(!Q.current)return;let I=t.style;I.setProperty(yt,`${m}px`),I.setProperty(At,`${R}px`);let A=je(t).devicePixelRatio||1,{x:pe,y:X,width:ge,height:T}=u.reference,oe=(Math.round((pe+ge)*A)-Math.round(pe*A))/A,ie=(Math.round((X+T)*A)-Math.round(X*A))/A;I.setProperty(ht,`${oe}px`),I.setProperty(Rt,`${ie}px`)}}),dt(t=>({element:F.current||Xe(t.elements.floating).createElement("div"),padding:F.current?C:0}),[C]),{name:"transformOrigin",fn(t){let{elements:{floating:m},middlewareData:R,placement:u,platform:I,rects:A,y:pe}=t,X=G(u),ge=_(u),T=we(X)==="y",oe=F.current,ie=typeof r=="function"?r(bt(t,i,U)):r,he;if(!oe&&ge&&Math.abs(T?R.shift?.x||0:R.shift?.y||0)<=1)he=ge==="start"===(T&&I.isRTL?.(m)===!0)?"100%":"0%";else{let Tt=T?R.arrow?.x||0:R.arrow?.y||0,Lt=T?oe?.clientWidth||0:oe?.clientHeight||0;he=`${Tt+Lt/2}px`}let be=X==="top"||X==="left"?`calc(100% + ${ie}px)`:`${-ie}px`;return Oe&&T&&Math.abs(R.shift?.y||0)>ie&&(be=`${A.reference.y+A.reference.height/2-pe}px`),m.style.setProperty(xt,T?`${he} ${be}`:`${be} ${he}`),{}}},ut,P),W(()=>{!s&&g&&g.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[s,g]);let Ae=p.useMemo(()=>({ancestorScroll:!w,elementResize:!w&&typeof ResizeObserver<"u",layoutShift:!w&&typeof IntersectionObserver<"u"}),[w]),{refs:j,elements:te,x:ve,y:De,middlewareData:N,update:le,placement:fe,context:He,isPositioned:H,floatingStyles:Ie}=l({rootContext:g,open:o?s:void 0,placement:Ot,middleware:Y,strategy:e,whileElementsMounted:o?void 0:(...t)=>Se(...t,Ae),nodeId:h,externalTree:q}),{sideX:Te,sideY:Le}=N.adaptiveOrigin||mt,de=H?e:"fixed",Ve=p.useMemo(()=>{let t;return H?P?t={position:de,[Te]:ve,[Le]:De}:t={...Ie,position:de}:t={position:de,top:0,left:0},t[yt]="100vw",t[At]="100vh",H||(t.opacity=0),t},[P,de,Te,ve,Le,De,Ie,H]),ue=p.useRef(null);W(()=>{if(!s)return;let t=v.current,m=typeof t=="function"?t():t,u=(wt(m)?m.current:m)||null||null;u!==ue.current&&(j.setPositionReference(u),ue.current=u)},[s,j,z,v]),p.useEffect(()=>{if(!s)return;let t=v.current;typeof t!="function"&&wt(t)&&t.current!==ue.current&&(j.setPositionReference(t.current),ue.current=t.current)},[s,j,z,v]),p.useEffect(()=>{if(o&&s&&te.reference&&te.floating)return Se(te.reference,te.floating,le,Ae)},[o,s,te,le,Ae]);let ne=G(fe),Be=St(i,ne,U),me=_(fe)||"center",$e=!!N.hide?.referenceHidden;W(()=>{J&&s&&H&&(ne!==ce||Re&&me!==ee)&&Pe(fe)},[J,Re,s,H,fe,ne,me,ce,ee]);let ke=p.useMemo(()=>({position:"absolute",top:N.arrow?.y,left:N.arrow?.x}),[N.arrow]),Fe=N.arrow?.centerOffset!==0;return p.useMemo(()=>({positionerStyles:Ve,arrowStyles:ke,arrowRef:F,arrowUncentered:Fe,side:Be,align:me,physicalSide:ne,anchorHidden:$e,refs:j,context:He,isPositioned:H,update:le}),[Ve,ke,F,Fe,Be,me,ne,$e,j,He,H,le])}function wt(n){return n!=null&&"current"in n}function hn(n,l,{styles:a,transitionStatus:e,props:i,refs:r,hidden:f,inert:y=!1}){let b={...a};return y&&(b.pointerEvents="none"),Ye("div",n,{state:l,ref:r,props:[{role:"presentation",hidden:f,style:b},lt(e),i],stateAttributesMapping:Ge})}export{lt as a,mt as b,pt as c,gt as d,Kt as e,Qt as f,dn as g,hn as h};
2
+ //# sourceMappingURL=chunk-QJVIEN5R.js.map
@@ -1,2 +1,2 @@
1
- import{a as Qe,b as oe,d as Xe}from"./chunk-GZJCEDUU.js";import{a as Ge,b as ce}from"./chunk-MTHCFDUE.js";import{a as We}from"./chunk-AZWODE64.js";import{a as $e,c as A,e as ze,f as P,g as qe,h as He,i as k,j as Je,k as z,l as Ye}from"./chunk-GQYRJYJV.js";import{a as Ke}from"./chunk-E75HEEMN.js";import{a as Te,c as _e}from"./chunk-FTWKUXER.js";import{c as Q}from"./chunk-AAL6V4Y3.js";import{a as xe}from"./chunk-5EK7QOB6.js";import{b as je}from"./chunk-XIXCIQKJ.js";import{a as ue,d as Ue}from"./chunk-EGZKG2B2.js";import{d as ke}from"./chunk-MQ67DRDE.js";import{a as N}from"./chunk-SFI7YWVR.js";import{a as Ce,b as T}from"./chunk-NZ73KS2Y.js";import{a as $}from"./chunk-CT4EH2K2.js";import{b as Oe,l as w}from"./chunk-JIAVZ3V7.js";import{a as Be}from"./chunk-SVQCDOZ3.js";import{a as O}from"./chunk-IJQ26FTX.js";import{b as dt,c as g}from"./chunk-KVMUXFPB.js";var Gr=g(O());var it=g(O(),1);var Re={};dt(Re,{Control:()=>Ne,Description:()=>De,Error:()=>Ee,Item:()=>Me,Label:()=>Ve,Root:()=>Ie,Validity:()=>Se});var v=g(O(),1);var q=g(O(),1);var Ze=g($(),1),ie=function(o){let i=Q(),[y,V]=q.useState(i),[m,c]=q.useState(),[a,f]=q.useState([]),s=y===void 0?i:y,t=Oe(()=>new Map),{messageIds:u}=k(),l=N((p,F)=>{let n=t.current;F===void 0?n.delete(p):n.set(p,F),V(h=>{if(n.size===0)return h;let L;for(let e of n.values()){if(e===h)return h;L===void 0&&(L=e)}return L})}),b=N(()=>{t.current.size===0&&V(i)}),d=q.useCallback(p=>{let F=p["aria-describedby"]?p["aria-describedby"].split(" "):[];return F.push(...u,...a),{...p,"aria-describedby":Array.from(new Set(F)).join(" ")||void 0}},[u,a]),x=q.useMemo(()=>({controlId:s,registerControlId:l,resetControlId:b,labelId:m,setLabelId:c,messageIds:a,setMessageIds:f,getDescriptionProps:d}),[s,l,b,m,c,a,f,d]);return(0,Ze.jsx)(He.Provider,{value:x,children:o.children})};ie.displayName="LabelableProvider";var fe=g(O(),1);function et(S){let{change:o,commit:i,invalid:y,markedDirtyRef:V,name:m,setRegisteredFieldName:c,registeredFieldIdRef:a,setValidityData:f,validityData:s}=S,{formRef:t}=z(),u=fe.useRef(null),l=fe.useRef(null),b=fe.useRef(!1),d=N(()=>{let e=l.current;if(e)return e.getValue?e.getValue():e.value});function x(e){return e.value===void 0?d():e.value}let p=N(()=>{let e=l.current;if(V.current=!0,!e){i(s.value);return}i(x(e))});function F(){let e=l.current;!e||!e.id||t.current.fields.set(e.id,{getValue:d,name:m??e.name,controlRef:e.controlRef,validityData:oe(s,y),validate:p})}function n(e=l.current?.id){e&&t.current.fields.delete(e)}function h(e){if(b.current)return;b.current=!0;let r=x(e);f(E=>E.initialValue===r?E:{...E,initialValue:r})}T(()=>{let e=l.current;!e||!e.id||(c(m?void 0:e.name),t.current.fields.set(e.id,{getValue:d,name:m??e.name,controlRef:e.controlRef,validityData:oe(s,y),validate:p}))},[t,d,y,m,c,p,s]),T(()=>{let e=t.current.fields;return()=>{let r=l.current?.id;r&&e.delete(r)}},[t]);let L=N((e,r)=>{if(!r){u.current===e&&(u.current=null,o(void 0,!0),n(),l.current=null,c(void 0),a.current=void 0);return}let E=l.current?.id,U=u.current;U&&U!==e&&o(void 0,!0),u.current=e,l.current=r,m||c(r.name),a.current=r.id,E&&E!==r.id&&n(E),h(r),F()});return[p,L]}var me=g($(),1),tt=v.forwardRef(function(o,i){let{errors:y,validationMode:V,submitCountRef:m}=z(),{render:c,className:a,validate:f,validationDebounceTime:s=0,validationMode:t=V,name:u,disabled:l=!1,invalid:b,dirty:d,touched:x,actionsRef:p,style:F,...n}=o,h=Qe(!0)?.disabled,L=N(f||(()=>null)),e=h||l,[r,E]=v.useState(!1),[U,W]=v.useState(!1),[_,C]=v.useState(!1),[B,H]=v.useState(!1),Y=v.useRef(void 0),j=d??U,I=x??r,K=v.useRef(j),Z=v.useRef(void 0),[ae,ve]=v.useState(),G=u??ae;T(()=>{d!==void 0&&(K.current=d)},[d]);let R=N(de=>{d===void 0&&(de&&(K.current=!0),W(de))}),M=N(de=>{x===void 0&&E(de)}),D=N(()=>t==="onChange"||t==="onSubmit"&&m.current>0),ee=G&&Object.hasOwn(y,G)?y[G]:null,Fe=!!(Array.isArray(ee)?ee.length:ee),te=b===!0||Fe,[re,ye]=v.useState({state:$e,error:"",errors:[],value:null,initialValue:null}),we=!te&&(e?null:re.state.valid),se=v.useMemo(()=>({disabled:e,touched:I,dirty:j,valid:we,filled:_,focused:B}),[e,I,j,we,_,B]),le=Xe({setValidityData:ye,validate:L,validityData:re,validationDebounceTime:s,invalid:te,markedDirtyRef:K,state:se,shouldValidateOnChange:D,validationMode:t,registeredFieldIdRef:Z}),[Ae,Pe]=et({change:le.change,commit:le.commit,invalid:te,markedDirtyRef:K,name:u,setRegisteredFieldName:ve,registeredFieldIdRef:Z,setValidityData:ye,validityData:re});v.useImperativeHandle(p,()=>({validate:Ae}),[Ae]);let st=v.useMemo(()=>({invalid:te,name:G,validityData:re,setValidityData:ye,disabled:e,setTouched:M,setDirty:R,setFilled:C,setFocused:H,focusOwnerRef:Y,validationMode:t,shouldValidateOnChange:D,state:se,registerFieldControl:Pe,validation:le}),[te,G,re,e,M,R,C,H,t,D,se,Pe,le]),lt=w("div",o,{ref:i,state:se,props:n,stateAttributesMapping:A});return(0,me.jsx)(ze.Provider,{value:st,children:lt})});tt.displayName="FieldRootInner";var Ie=v.forwardRef(function(o,i){return(0,me.jsx)(ie,{children:(0,me.jsx)(tt,{...o,ref:i})})});Ie.displayName="FieldRoot";var X=g(O(),1);var Ve=X.forwardRef(function(o,i){let{render:y,className:V,style:m,id:c,nativeLabel:a=!0,...f}=o,s=P(!1),t=ce(),{labelId:u}=k(),l={...s.state,disabled:s.disabled||t.disabled},b=X.useRef(null),d=We({id:u??c,native:a});return X.useEffect(()=>{if(!b.current)return;let p=b.current.tagName==="LABEL";if(a){if(!p){let F=Ce.captureOwnerStack?.()||"";xe(`<Field.Label> expected a <label> element because the \`nativeLabel\` prop is true. Rendering a non-<label> disables native label association, so \`htmlFor\` will not work. Use a real <label> in the \`render\` prop, or set \`nativeLabel\` to \`false\`.${F}`)}}else if(p){let F=Ce.captureOwnerStack?.()||"";xe(`<Field.Label> expected a non-<label> element because the \`nativeLabel\` prop is false. Rendering a <label> assumes native label behavior while Base UI treats it as non-native, which can cause unexpected pointer behavior. Use a non-<label> in the \`render\` prop, or set \`nativeLabel\` to \`true\`.${F}`)}},[a]),w("label",o,{ref:[i,b],state:l,props:[d,f],stateAttributesMapping:A})});Ve.displayName="FieldLabel";var J=g(O(),1);var he=g($(),1),ut={...A,...ke},Ee=J.forwardRef(function(o,i){let{render:y,id:V,className:m,match:c,style:a,...f}=o,s=Q(V),{validityData:t,state:u,name:l}=P(!1),{setMessageIds:b}=k(),{errors:d}=z(),x=l&&Object.hasOwn(d,l)?d[l]:null,p=!!(Array.isArray(x)?x.length:x),F=typeof c=="string",n=!1;c===!0?n=!0:u.disabled?n=!1:F?n=!!t.state[c]:n=p||t.state.valid===!1;let{mounted:h,transitionStatus:L,setMounted:e}=ue(n);T(()=>{if(!(!n||!s))return b(I=>I.concat(s)),()=>{b(I=>I.filter(K=>K!==s))}},[n,s,b]);let r=J.useRef(null),[E,U]=J.useState(null),[W,_]=J.useState(null),C=t.error;!F&&p?C=x:t.errors.length>1&&(C=t.errors);let B=C;Array.isArray(C)&&(B=C.length>1?(0,he.jsx)("ul",{children:C.map(I=>(0,he.jsx)("li",{children:I},I))}):C[0]);let H=Array.isArray(C)?JSON.stringify(C):C;n&&H!==W&&(_(H),U(B)),Ue({open:n,ref:r,onComplete(){n||e(!1)}});let Y={...u,transitionStatus:L},j=w("div",o,{ref:[i,r],state:Y,props:[{id:s,children:n?B:E},f],stateAttributesMapping:ut,enabled:h});return h?j:null});Ee.displayName="FieldError";var rt=g(O(),1);var De=rt.forwardRef(function(o,i){let{render:y,id:V,className:m,style:c,...a}=o,f=Q(V),s=P(!1),t=ce(),{setMessageIds:u}=k(),l={...s.state,disabled:s.disabled||t.disabled};return T(()=>{if(f)return u(d=>d.concat(f)),()=>{u(d=>d.filter(x=>x!==f))}},[f,u]),w("p",o,{ref:i,state:l,props:[{id:f},a],stateAttributesMapping:A})});De.displayName="FieldDescription";var pe=g(O(),1);var Ne=pe.forwardRef(function(o,i){let{render:y,className:V,id:m,name:c,value:a,disabled:f=!1,onValueChange:s,defaultValue:t,autoFocus:u=!1,style:l,...b}=o,{state:d,name:x,disabled:p,setTouched:F,setDirty:n,validityData:h,setFilled:L,validationMode:e,validation:r}=P(),{clearErrors:E,elementRef:U,submitCountRef:W}=z(),_=p||f,C=x??c,B={...d,disabled:_},{labelId:H}=k(),Y=Je({id:m}),j=a!==void 0,I=a==null?void 0:String(a),K=N(()=>r.inputRef.current?.value);qe(r.inputRef,Y,I,K,!_,c),T(()=>{let R=I??r.inputRef.current?.value;R!==void 0&&L(R!=="")},[I,t,r.inputRef,L]),Ke(I,()=>{I!==void 0&&(E(C),n(I!==(h.initialValue??"")),r.change(I))});let Z=pe.useRef(null),ae=Ye(_,Z),ve=je();return w("input",o,{ref:[i,Z],state:B,props:[{id:Y,disabled:_,name:C,ref:r.inputRef,"aria-labelledby":H,autoFocus:u,...j?{value:a}:{defaultValue:t},onChange(R){let M=R.currentTarget.value,D=Te(_e.none,R.nativeEvent);s?.(M,D),!j&&(n(M!==(h.initialValue??"")),L(M!==""),!R.nativeEvent.defaultPrevented&&!D.isCanceled&&(E(C),r.change(M)))},onFocus(){ae(!0)},onBlur(R){if(F(!0),ae(!1),e==="onBlur"){let M=R.currentTarget.value;r.commit(M),j&&queueMicrotask(()=>{let D=r.inputRef.current?.value;D!==void 0&&D!==M&&D!==(h.initialValue??"")&&r.commit(D)})}},onKeyDown(R){if(R.currentTarget.tagName==="INPUT"&&R.key==="Enter"){F(!0);let M=R.currentTarget.value,D=R.currentTarget.form;if(D&&D===U.current&&!R.defaultPrevented){let ee=R.currentTarget,Fe=W.current;ve.start(0,()=>{W.current===Fe&&r.commit(ee.value)})}else r.commit(M)}}},b,R=>r.getValidationProps(_,R)],stateAttributesMapping:A})});Ne.displayName="FieldControl";var ne=g(O(),1);var ot=g($(),1),Se=function(o){let{children:i}=o,{validityData:y,invalid:V}=P(!1),m=ne.useMemo(()=>oe(y,V),[y,V]),c=m.state.valid===!1,{transitionStatus:a}=ue(c),f=ne.useMemo(()=>({...m,validity:m.state,transitionStatus:a}),[m,a]);return(0,ot.jsx)(ne.Fragment,{children:i(f)})};Se.displayName="FieldValidity";var be=g(O(),1);var Le=g($(),1),Me=be.forwardRef(function(o,i){let{render:y,className:V,style:m,disabled:c=!1,...a}=o,{state:f,disabled:s}=P(!1),t=s||c,u={...f,disabled:t},l=be.useMemo(()=>({disabled:t}),[t]),b=w("div",o,{ref:i,state:u,props:a,stateAttributesMapping:A});return(0,Le.jsx)(ie,{children:(0,Le.jsx)(Ge.Provider,{value:l,children:b})})});Me.displayName="FieldItem";var nt=g($(),1),ge=it.forwardRef(function(o,i){return(0,nt.jsx)(Re.Control,{ref:i,...o})});ge.displayName="Input";var at=g($());function Zr({className:S,type:o,...i}){return(0,at.jsx)(ge,{type:o,"data-slot":"input",className:Be("h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",S),...i})}export{Zr as a};
2
- //# sourceMappingURL=chunk-57M36GYM.js.map
1
+ import{a as Qe,b as oe,d as Xe}from"./chunk-GZJCEDUU.js";import{a as We}from"./chunk-AZWODE64.js";import{a as Ge,b as ce}from"./chunk-MTHCFDUE.js";import{a as $e,c as A,e as ze,f as P,g as qe,h as He,i as k,j as Je,k as z,l as Ye}from"./chunk-GQYRJYJV.js";import{a as Ke}from"./chunk-E75HEEMN.js";import{a as Te,c as _e}from"./chunk-FTWKUXER.js";import{c as Q}from"./chunk-AAL6V4Y3.js";import{a as xe}from"./chunk-5EK7QOB6.js";import{b as je}from"./chunk-XIXCIQKJ.js";import{a as ue,d as Ue}from"./chunk-EGZKG2B2.js";import{d as ke}from"./chunk-MQ67DRDE.js";import{a as N}from"./chunk-SFI7YWVR.js";import{a as Ce,b as T}from"./chunk-NZ73KS2Y.js";import{b as Oe,l as w}from"./chunk-JIAVZ3V7.js";import{a as Be}from"./chunk-SVQCDOZ3.js";import{a as $}from"./chunk-CT4EH2K2.js";import{a as O}from"./chunk-IJQ26FTX.js";import{b as dt,c as g}from"./chunk-KVMUXFPB.js";var Gr=g(O());var it=g(O(),1);var Re={};dt(Re,{Control:()=>Ne,Description:()=>De,Error:()=>Ee,Item:()=>Me,Label:()=>Ve,Root:()=>Ie,Validity:()=>Se});var v=g(O(),1);var q=g(O(),1);var Ze=g($(),1),ie=function(o){let i=Q(),[y,V]=q.useState(i),[m,c]=q.useState(),[a,f]=q.useState([]),s=y===void 0?i:y,t=Oe(()=>new Map),{messageIds:u}=k(),l=N((p,F)=>{let n=t.current;F===void 0?n.delete(p):n.set(p,F),V(h=>{if(n.size===0)return h;let L;for(let e of n.values()){if(e===h)return h;L===void 0&&(L=e)}return L})}),b=N(()=>{t.current.size===0&&V(i)}),d=q.useCallback(p=>{let F=p["aria-describedby"]?p["aria-describedby"].split(" "):[];return F.push(...u,...a),{...p,"aria-describedby":Array.from(new Set(F)).join(" ")||void 0}},[u,a]),x=q.useMemo(()=>({controlId:s,registerControlId:l,resetControlId:b,labelId:m,setLabelId:c,messageIds:a,setMessageIds:f,getDescriptionProps:d}),[s,l,b,m,c,a,f,d]);return(0,Ze.jsx)(He.Provider,{value:x,children:o.children})};ie.displayName="LabelableProvider";var fe=g(O(),1);function et(S){let{change:o,commit:i,invalid:y,markedDirtyRef:V,name:m,setRegisteredFieldName:c,registeredFieldIdRef:a,setValidityData:f,validityData:s}=S,{formRef:t}=z(),u=fe.useRef(null),l=fe.useRef(null),b=fe.useRef(!1),d=N(()=>{let e=l.current;if(e)return e.getValue?e.getValue():e.value});function x(e){return e.value===void 0?d():e.value}let p=N(()=>{let e=l.current;if(V.current=!0,!e){i(s.value);return}i(x(e))});function F(){let e=l.current;!e||!e.id||t.current.fields.set(e.id,{getValue:d,name:m??e.name,controlRef:e.controlRef,validityData:oe(s,y),validate:p})}function n(e=l.current?.id){e&&t.current.fields.delete(e)}function h(e){if(b.current)return;b.current=!0;let r=x(e);f(E=>E.initialValue===r?E:{...E,initialValue:r})}T(()=>{let e=l.current;!e||!e.id||(c(m?void 0:e.name),t.current.fields.set(e.id,{getValue:d,name:m??e.name,controlRef:e.controlRef,validityData:oe(s,y),validate:p}))},[t,d,y,m,c,p,s]),T(()=>{let e=t.current.fields;return()=>{let r=l.current?.id;r&&e.delete(r)}},[t]);let L=N((e,r)=>{if(!r){u.current===e&&(u.current=null,o(void 0,!0),n(),l.current=null,c(void 0),a.current=void 0);return}let E=l.current?.id,U=u.current;U&&U!==e&&o(void 0,!0),u.current=e,l.current=r,m||c(r.name),a.current=r.id,E&&E!==r.id&&n(E),h(r),F()});return[p,L]}var me=g($(),1),tt=v.forwardRef(function(o,i){let{errors:y,validationMode:V,submitCountRef:m}=z(),{render:c,className:a,validate:f,validationDebounceTime:s=0,validationMode:t=V,name:u,disabled:l=!1,invalid:b,dirty:d,touched:x,actionsRef:p,style:F,...n}=o,h=Qe(!0)?.disabled,L=N(f||(()=>null)),e=h||l,[r,E]=v.useState(!1),[U,W]=v.useState(!1),[_,C]=v.useState(!1),[B,H]=v.useState(!1),Y=v.useRef(void 0),j=d??U,I=x??r,K=v.useRef(j),Z=v.useRef(void 0),[ae,ve]=v.useState(),G=u??ae;T(()=>{d!==void 0&&(K.current=d)},[d]);let R=N(de=>{d===void 0&&(de&&(K.current=!0),W(de))}),M=N(de=>{x===void 0&&E(de)}),D=N(()=>t==="onChange"||t==="onSubmit"&&m.current>0),ee=G&&Object.hasOwn(y,G)?y[G]:null,Fe=!!(Array.isArray(ee)?ee.length:ee),te=b===!0||Fe,[re,ye]=v.useState({state:$e,error:"",errors:[],value:null,initialValue:null}),we=!te&&(e?null:re.state.valid),se=v.useMemo(()=>({disabled:e,touched:I,dirty:j,valid:we,filled:_,focused:B}),[e,I,j,we,_,B]),le=Xe({setValidityData:ye,validate:L,validityData:re,validationDebounceTime:s,invalid:te,markedDirtyRef:K,state:se,shouldValidateOnChange:D,validationMode:t,registeredFieldIdRef:Z}),[Ae,Pe]=et({change:le.change,commit:le.commit,invalid:te,markedDirtyRef:K,name:u,setRegisteredFieldName:ve,registeredFieldIdRef:Z,setValidityData:ye,validityData:re});v.useImperativeHandle(p,()=>({validate:Ae}),[Ae]);let st=v.useMemo(()=>({invalid:te,name:G,validityData:re,setValidityData:ye,disabled:e,setTouched:M,setDirty:R,setFilled:C,setFocused:H,focusOwnerRef:Y,validationMode:t,shouldValidateOnChange:D,state:se,registerFieldControl:Pe,validation:le}),[te,G,re,e,M,R,C,H,t,D,se,Pe,le]),lt=w("div",o,{ref:i,state:se,props:n,stateAttributesMapping:A});return(0,me.jsx)(ze.Provider,{value:st,children:lt})});tt.displayName="FieldRootInner";var Ie=v.forwardRef(function(o,i){return(0,me.jsx)(ie,{children:(0,me.jsx)(tt,{...o,ref:i})})});Ie.displayName="FieldRoot";var X=g(O(),1);var Ve=X.forwardRef(function(o,i){let{render:y,className:V,style:m,id:c,nativeLabel:a=!0,...f}=o,s=P(!1),t=ce(),{labelId:u}=k(),l={...s.state,disabled:s.disabled||t.disabled},b=X.useRef(null),d=We({id:u??c,native:a});return X.useEffect(()=>{if(!b.current)return;let p=b.current.tagName==="LABEL";if(a){if(!p){let F=Ce.captureOwnerStack?.()||"";xe(`<Field.Label> expected a <label> element because the \`nativeLabel\` prop is true. Rendering a non-<label> disables native label association, so \`htmlFor\` will not work. Use a real <label> in the \`render\` prop, or set \`nativeLabel\` to \`false\`.${F}`)}}else if(p){let F=Ce.captureOwnerStack?.()||"";xe(`<Field.Label> expected a non-<label> element because the \`nativeLabel\` prop is false. Rendering a <label> assumes native label behavior while Base UI treats it as non-native, which can cause unexpected pointer behavior. Use a non-<label> in the \`render\` prop, or set \`nativeLabel\` to \`true\`.${F}`)}},[a]),w("label",o,{ref:[i,b],state:l,props:[d,f],stateAttributesMapping:A})});Ve.displayName="FieldLabel";var J=g(O(),1);var he=g($(),1),ut={...A,...ke},Ee=J.forwardRef(function(o,i){let{render:y,id:V,className:m,match:c,style:a,...f}=o,s=Q(V),{validityData:t,state:u,name:l}=P(!1),{setMessageIds:b}=k(),{errors:d}=z(),x=l&&Object.hasOwn(d,l)?d[l]:null,p=!!(Array.isArray(x)?x.length:x),F=typeof c=="string",n=!1;c===!0?n=!0:u.disabled?n=!1:F?n=!!t.state[c]:n=p||t.state.valid===!1;let{mounted:h,transitionStatus:L,setMounted:e}=ue(n);T(()=>{if(!(!n||!s))return b(I=>I.concat(s)),()=>{b(I=>I.filter(K=>K!==s))}},[n,s,b]);let r=J.useRef(null),[E,U]=J.useState(null),[W,_]=J.useState(null),C=t.error;!F&&p?C=x:t.errors.length>1&&(C=t.errors);let B=C;Array.isArray(C)&&(B=C.length>1?(0,he.jsx)("ul",{children:C.map(I=>(0,he.jsx)("li",{children:I},I))}):C[0]);let H=Array.isArray(C)?JSON.stringify(C):C;n&&H!==W&&(_(H),U(B)),Ue({open:n,ref:r,onComplete(){n||e(!1)}});let Y={...u,transitionStatus:L},j=w("div",o,{ref:[i,r],state:Y,props:[{id:s,children:n?B:E},f],stateAttributesMapping:ut,enabled:h});return h?j:null});Ee.displayName="FieldError";var rt=g(O(),1);var De=rt.forwardRef(function(o,i){let{render:y,id:V,className:m,style:c,...a}=o,f=Q(V),s=P(!1),t=ce(),{setMessageIds:u}=k(),l={...s.state,disabled:s.disabled||t.disabled};return T(()=>{if(f)return u(d=>d.concat(f)),()=>{u(d=>d.filter(x=>x!==f))}},[f,u]),w("p",o,{ref:i,state:l,props:[{id:f},a],stateAttributesMapping:A})});De.displayName="FieldDescription";var pe=g(O(),1);var Ne=pe.forwardRef(function(o,i){let{render:y,className:V,id:m,name:c,value:a,disabled:f=!1,onValueChange:s,defaultValue:t,autoFocus:u=!1,style:l,...b}=o,{state:d,name:x,disabled:p,setTouched:F,setDirty:n,validityData:h,setFilled:L,validationMode:e,validation:r}=P(),{clearErrors:E,elementRef:U,submitCountRef:W}=z(),_=p||f,C=x??c,B={...d,disabled:_},{labelId:H}=k(),Y=Je({id:m}),j=a!==void 0,I=a==null?void 0:String(a),K=N(()=>r.inputRef.current?.value);qe(r.inputRef,Y,I,K,!_,c),T(()=>{let R=I??r.inputRef.current?.value;R!==void 0&&L(R!=="")},[I,t,r.inputRef,L]),Ke(I,()=>{I!==void 0&&(E(C),n(I!==(h.initialValue??"")),r.change(I))});let Z=pe.useRef(null),ae=Ye(_,Z),ve=je();return w("input",o,{ref:[i,Z],state:B,props:[{id:Y,disabled:_,name:C,ref:r.inputRef,"aria-labelledby":H,autoFocus:u,...j?{value:a}:{defaultValue:t},onChange(R){let M=R.currentTarget.value,D=Te(_e.none,R.nativeEvent);s?.(M,D),!j&&(n(M!==(h.initialValue??"")),L(M!==""),!R.nativeEvent.defaultPrevented&&!D.isCanceled&&(E(C),r.change(M)))},onFocus(){ae(!0)},onBlur(R){if(F(!0),ae(!1),e==="onBlur"){let M=R.currentTarget.value;r.commit(M),j&&queueMicrotask(()=>{let D=r.inputRef.current?.value;D!==void 0&&D!==M&&D!==(h.initialValue??"")&&r.commit(D)})}},onKeyDown(R){if(R.currentTarget.tagName==="INPUT"&&R.key==="Enter"){F(!0);let M=R.currentTarget.value,D=R.currentTarget.form;if(D&&D===U.current&&!R.defaultPrevented){let ee=R.currentTarget,Fe=W.current;ve.start(0,()=>{W.current===Fe&&r.commit(ee.value)})}else r.commit(M)}}},b,R=>r.getValidationProps(_,R)],stateAttributesMapping:A})});Ne.displayName="FieldControl";var ne=g(O(),1);var ot=g($(),1),Se=function(o){let{children:i}=o,{validityData:y,invalid:V}=P(!1),m=ne.useMemo(()=>oe(y,V),[y,V]),c=m.state.valid===!1,{transitionStatus:a}=ue(c),f=ne.useMemo(()=>({...m,validity:m.state,transitionStatus:a}),[m,a]);return(0,ot.jsx)(ne.Fragment,{children:i(f)})};Se.displayName="FieldValidity";var be=g(O(),1);var Le=g($(),1),Me=be.forwardRef(function(o,i){let{render:y,className:V,style:m,disabled:c=!1,...a}=o,{state:f,disabled:s}=P(!1),t=s||c,u={...f,disabled:t},l=be.useMemo(()=>({disabled:t}),[t]),b=w("div",o,{ref:i,state:u,props:a,stateAttributesMapping:A});return(0,Le.jsx)(ie,{children:(0,Le.jsx)(Ge.Provider,{value:l,children:b})})});Me.displayName="FieldItem";var nt=g($(),1),ge=it.forwardRef(function(o,i){return(0,nt.jsx)(Re.Control,{ref:i,...o})});ge.displayName="Input";var at=g($());function Zr({className:S,type:o,...i}){return(0,at.jsx)(ge,{type:o,"data-slot":"input",className:Be("h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",S),...i})}export{Zr as a};
2
+ //# sourceMappingURL=chunk-QZ3NJHFR.js.map
@@ -1,2 +1,2 @@
1
- import{a as No,b as wo}from"./chunk-ML6HCGK5.js";import{a as Oo}from"./chunk-DG6LRRQT.js";import{a as bo}from"./chunk-FROPNHO5.js";import{a as Mo,b as _o}from"./chunk-F5MKIWPQ.js";import{a as To,g as yo,h as Io}from"./chunk-TQPXDAVH.js";import{a as Xe,b as mo,c as Q,d as fo,e as Ro}from"./chunk-Z76KXEPD.js";import{i as xo}from"./chunk-H6TI5TWN.js";import{b as ho,d as So}from"./chunk-IAEAQCYR.js";import{$ as ro,A as Re,E as Ge,G as Le,I as ze,M as Ke,Ma as Eo,N as We,O as Ye,P as qe,Q as Je,S as Qe,V as Ze,W as $e,X as eo,Y as oo,_ as to,ba as no,ca as so,da as io,ea as ao,fa as po,ga as xe,ha as co,ia as uo,ka as lo,pa as go,qa as Po,xa as vo}from"./chunk-OXJ6LWKI.js";import{a as Co}from"./chunk-B4MRCKT4.js";import{m as He,n as je,o as Ue,p as ie}from"./chunk-7OCTAHT6.js";import{a as ne,c as g}from"./chunk-FTWKUXER.js";import{c as U}from"./chunk-AAL6V4Y3.js";import{d as se}from"./chunk-CLVPTZ4G.js";import{f as Ve}from"./chunk-LYT7LQS3.js";import{a as ke}from"./chunk-XIXCIQKJ.js";import{d as Be}from"./chunk-EGZKG2B2.js";import{a as et}from"./chunk-UH726PMV.js";import{a as re}from"./chunk-SFI7YWVR.js";import{b as Ae}from"./chunk-NZ73KS2Y.js";import{a as F}from"./chunk-CT4EH2K2.js";import{d as Fe,l as x}from"./chunk-JIAVZ3V7.js";import{a as J}from"./chunk-SVQCDOZ3.js";import{a as R}from"./chunk-IJQ26FTX.js";import{b as $o,c as u}from"./chunk-KVMUXFPB.js";var Cn=u(R());var T={};$o(T,{Arrow:()=>Ne,Backdrop:()=>Ie,Close:()=>Me,Description:()=>we,Handle:()=>oe,Popup:()=>ye,Portal:()=>Ee,Positioner:()=>Oe,Root:()=>Bo,Title:()=>be,Trigger:()=>he,Viewport:()=>_e,createHandle:()=>Xo});var Z=u(R(),1);var ae=u(R(),1),pe=ae.createContext(void 0);pe.displayName="PopoverRootContext";function m(e){let o=ae.useContext(pe);if(o===void 0&&!e)throw new Error("Base UI: PopoverRootContext is missing. Popover parts must be placed within <Popover.Root>.");return o}var X=u(R(),1),Do=u(et(),1);var Fo={...Q,disabled:e=>e.disabled,instantType:e=>e.instantType==="trigger-change"&&!Q.open(e)?void 0:e.instantType,openMethod:e=>e.openMethod,openChangeReason:e=>e.openChangeReason,isPressOpenedByTrigger:(e,o)=>e.openChangeReason===g.triggerPress&&Q.isOpenedByTrigger(e,o),isTouchPressOpen:(e,o)=>o&&e.openMethod==="touch"&&e.openChangeReason===g.triggerPress,hasTriggerFocusGuards:(e,o)=>Q.isOpenedByTrigger(e,o)&&!e.focusManagerModal,modal:e=>e.modal,titleElementId:e=>e.titleElementId,descriptionElementId:e=>e.descriptionElementId,openOnHover:e=>e.openOnHover,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin},ce=class extends lo{constructor(o,t,i){let s=new xe;super(Vo(o,s,t,i),ko(s),Fo)}setOpen=(o,t)=>{let i=t.reason===g.triggerHover,s=t.reason===g.triggerPress&&t.event.detail===0,P=!o&&(t.reason===g.escapeKey||t.reason==null),a=ro(t),c=this.select("activeTriggerId");if(!o&&t.reason===g.closePress&&t.trigger==null&&c!=null&&(t.trigger=this.context.triggerElements.getById(c)??this.select("activeTriggerElement")??void 0),this.context.onOpenChange?.(o,t),t.isCanceled)return;this.state.floatingRootContext.dispatchOpenChange(o,t);let p=()=>{let d=to(this.state,o,t.trigger,a());d.openChangeReason=t.reason,this.update(d)};i?(this.context.stickIfOpen=!0,this.context.stickIfOpenTimeout.start(500,()=>{this.context.stickIfOpen=!1}),Do.flushSync(p)):p();let r;s?r="click":P?r="dismiss":t.reason===g.focusOut&&(r="focus"),this.set("instantType",r)}};function Ao(){let e=new xe,o=new Ro(Object.freeze(Vo(void 0,e)),Object.freeze(ko(e)),Fo);return Object.assign(o,{setOpen:Fe})}function Vo(e,o,t,i=!1){let s={...mo(o,t,i),disabled:!1,modal:!1,focusManagerModal:!1,instantType:void 0,openMethod:null,openChangeReason:null,titleElementId:void 0,descriptionElementId:void 0,openOnHover:!1,closeDelay:0,adaptiveOrigin:void 0,...e};return s.open&&e?.mounted===void 0&&(s.mounted=!0),s}function ko(e){return{popupRef:X.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerFocusTargetRef:X.createRef(),beforeTriggerFocusGuardRef:X.createRef(),beforeContentFocusGuardRef:X.createRef(),stickIfOpenTimeout:new ke,stickIfOpen:!0,triggerElements:e}}var b=u(F(),1),Ce=co(function({props:o}){let{children:t,open:i,defaultOpen:s=!1,onOpenChange:P,onOpenChangeComplete:a,modal:c=!1,handle:p,triggerId:r,defaultTriggerId:d=null}=o,n=ot(p,{modal:c,open:s,openProp:i,activeTriggerId:d,triggerIdProp:r});n.useControlledProp("openProp",i),n.useControlledProp("triggerIdProp",r);let f=n.useState("open"),C=n.useState("mounted"),S=n.useState("payload");n.useContextCallback("onOpenChange",P),n.useContextCallback("onOpenChangeComplete",a),po(n,f),so(n);let{forceUnmount:y}=io(f,n,()=>{n.context.stickIfOpen=!0,n.set("openChangeReason",null)});n.useSyncedValues({modal:c}),Z.useEffect(()=>{f||n.context.stickIfOpenTimeout.clear()},[n,f]),Z.useImperativeHandle(o.actionsRef,()=>({unmount:y,close:()=>n.setOpen(!1,ne(g.imperativeAction))}),[y,n]);let A=f||C||p!=null;return(0,b.jsxs)(pe.Provider,{value:n,children:[p&&(0,b.jsx)(oo,{handle:p,store:n}),A&&(0,b.jsx)(tt,{store:n,modal:c}),typeof t=="function"?t({payload:S}):t]})});Ce.displayName="PopoverRootComponent";function Bo(e){return m(!0)?(0,b.jsx)(Ce,{props:e}):(0,b.jsx)(Ye,{children:(0,b.jsx)(Ce,{props:e})})}function ot(e,o){let t=eo((i,s)=>new ce(o,i,s));return Z.useEffect(()=>t.context.stickIfOpenTimeout.disposeEffect(),[t]),t}function tt({store:e,modal:o}){let t=e.useState("floatingRootContext"),i=Qe(t,{outsidePressEvent:{mouse:o==="trap-focus"?"sloppy":"intentional",touch:"sloppy"}}),s=i.reference,P=i.floating;return ao(e,{activeTriggerProps:s,inactiveTriggerProps:s,popupProps:P}),null}var $=u(R(),1);var G=u(F(),1),he=uo(function(o,t){let{render:i,className:s,style:P,disabled:a=!1,nativeButton:c=!0,handle:p,payload:r,openOnHover:d=!1,delay:n=300,closeDelay:f=0,id:C,...S}=o,y=m(!0),l=fo(p)??y;if(!l)throw new Error("Base UI: <Popover.Trigger> must be either used within a <Popover.Root> component or provided with a handle.");let h=U(C),v=l.useState("isTriggerActive",h),V=l.useState("floatingRootContext"),M=l.useState("isOpenedByTrigger",h),k=l.useState("triggerPopupId",h),E=$.useRef(null),{registerTrigger:O,isMountedByThisTrigger:_}=no(h,E,l,{payload:r,disabled:a,openOnHover:d,closeDelay:f}),B=l.useState("isPressOpenedByTrigger",h),z=l.useState("isTouchPressOpen",d),K=l.useState("hasTriggerFocusGuards",h),H=Po(V,{enabled:!a&&d&&!z,mouseOnly:!0,move:!1,handleClose:vo(),restMs:n,delay:{close:f},triggerElementRef:E,isActiveTrigger:v,isClosing:()=>l.select("transitionStatus")==="ending"}),W=re(()=>l.context.stickIfOpen),j=Je(V,{stickIfOpen:W}),Y=So(()=>l.select("open"),te=>{l.set("openMethod",te)}),N=l.useState("triggerProps",_),{getButtonProps:q,buttonRef:D}=se({disabled:a,native:c}),ge={open(te){return B?je.open(te):He.open(te)}},{handlePreFocusGuardFocus:Pe,handleFocusTargetFocus:ve}=wo(l,E),Zo=x("button",o,{state:{disabled:a,open:M},ref:[D,t,O,E],props:[j.reference,H,N,Y,{[Ge]:"",id:h,"aria-haspopup":"dialog","aria-expanded":M,"aria-controls":k},S,q],stateAttributesMapping:ge}),De=(0,G.jsx)($.Fragment,{children:Zo},h);return K?(0,G.jsxs)($.Fragment,{children:[(0,G.jsx)(Re,{ref:l.context.beforeTriggerFocusGuardRef,onFocus:Pe}),De,(0,G.jsx)(Re,{ref:l.context.triggerFocusTargetRef,onFocus:ve})]}):De});he.displayName="PopoverTrigger";var jo=u(R(),1);var ue=u(R(),1),le=ue.createContext(void 0);le.displayName="PopoverPortalContext";function Ho(){let e=ue.useContext(le);if(e===void 0)throw new Error("Base UI: <Popover.Portal> is missing.");return e}var Se=u(F(),1),Ee=jo.forwardRef(function(o,t){let{keepMounted:i=!1,...s}=o;return m().useState("mounted")||i?(0,Se.jsx)(le.Provider,{value:i,children:(0,Se.jsx)(ze,{ref:t,...s})}):null});Ee.displayName="PopoverPortal";var Uo=u(R(),1);var me=u(R(),1),de=me.createContext(void 0);de.displayName="PopoverPositionerContext";function L(){let e=me.useContext(de);if(!e)throw new Error("Base UI: PopoverPositionerContext is missing. PopoverPositioner parts must be placed within <Popover.Positioner>.");return e}var ee=u(F(),1),Oe=Uo.forwardRef(function(o,t){let{render:i,className:s,style:P,anchor:a,positionMethod:c,side:p,align:r,sideOffset:d,alignOffset:n,collisionBoundary:f="clipping-ancestors",collisionPadding:C,arrowPadding:S,sticky:y,disableAnchorTracking:A=!1,collisionAvoidance:l=Le,...h}=o,v=m(),V=Ho(),M=Ke(),k=v.useState("floatingRootContext"),E=v.useState("mounted"),O=v.useState("open"),_=v.useState("openChangeReason"),B=v.useState("activeTriggerElement"),z=v.useState("modal"),K=v.useState("openMethod"),H=v.useState("positionerElement"),W=v.useState("instantType"),j=v.useState("transitionStatus"),Y=v.useState("adaptiveOrigin"),N=yo({anchor:a,floatingRootContext:k,positionMethod:c,mounted:E,side:p,sideOffset:d,align:r,alignOffset:n,arrowPadding:S,collisionBoundary:f,collisionPadding:C,sticky:y,disableAnchorTracking:A,keepMounted:V,nodeId:M,collisionAvoidance:l,adaptiveOrigin:Y}),q=k.useState("domReferenceElement");No({store:v,domReference:q,positionerElement:H,open:O});let D=z===!0&&_!==g.triggerHover;bo(O&&D,K==="touch",H,B);let ge=v.useStateSetter("positionerElement"),Pe={open:O,side:N.side,align:N.align,anchorHidden:N.anchorHidden,instant:W},ve=Io(o,Pe,{styles:N.positionerStyles,transitionStatus:j,props:h,refs:[t,ge],hidden:!E,inert:!O});return(0,ee.jsxs)(de.Provider,{value:N,children:[E&&D&&(0,ee.jsx)(ho,{inert:Co(!O),cutout:B}),(0,ee.jsx)(We,{id:M,children:ve})]})});Oe.displayName="PopoverPositioner";var zo=u(R(),1);var w=u(R(),1);var fe=w.createContext(void 0);fe.displayName="ClosePartContext";function Go(){let[e,o]=w.useState(0),t=re(()=>(o(s=>s+1),()=>{o(s=>Math.max(0,s-1))}));return{context:w.useMemo(()=>({register:t}),[t]),hasClosePart:e>0}}function Lo(){let e=w.useContext(fe);Ae(()=>e?.register(),[e])}var Te=u(F(),1),ye=zo.forwardRef(function(o,t){let{render:i,className:s,style:P,initialFocus:a,finalFocus:c,...p}=o,r=m(),d=L(),n=Oo(!0)!=null,{context:f,hasClosePart:C}=Go(),S=r.useState("open"),y=r.useState("openMethod"),A=r.useState("instantType"),l=r.useState("transitionStatus"),h=r.useState("popupProps"),v=r.useState("titleElementId"),V=r.useState("descriptionElementId"),M=r.useState("modal"),k=r.useState("mounted"),E=r.useState("openChangeReason"),O=r.useState("activeTriggerElement"),_=r.useState("floatingRootContext"),B=_.useState("floatingId"),z=r.useState("disabled"),K=r.useState("openOnHover"),H=r.useState("closeDelay");Be({open:S,ref:r.context.popupRef,onComplete(){S&&r.context.onOpenChangeComplete?.(!0)}}),go(_,{enabled:K&&!z,closeDelay:H});let W=a===void 0?$e(r.context.popupRef):a,j=M!==!1&&C;r.useSyncedValue("focusManagerModal",j);let Y=r.useStateSetter("popupElement"),N={open:S,side:d.side,align:d.align,instant:A,transitionStatus:l},q=x("div",o,{state:N,ref:[t,r.context.popupRef,Y],props:[h,{id:B,role:"dialog",...Ze,"aria-labelledby":v,"aria-describedby":V,onKeyDown(D){n&&xo.has(D.key)&&D.stopPropagation()}},To(l),p],stateAttributesMapping:ie});return(0,Te.jsx)(qe,{context:_,openInteractionType:y,modal:j,disabled:!k||E===g.triggerHover,initialFocus:W,returnFocus:c,restoreFocus:"popup",getInsideElements:()=>[r.context.beforeTriggerFocusGuardRef.current],previousFocusableElement:Ve(O)?O:void 0,nextFocusableElement:r.context.triggerFocusTargetRef,beforeContentFocusGuardRef:r.context.beforeContentFocusGuardRef,children:(0,Te.jsx)(fe.Provider,{value:f,children:q})})});ye.displayName="PopoverPopup";var Ko=u(R(),1);var Ne=Ko.forwardRef(function(o,t){let{render:i,className:s,style:P,...a}=o,p=m().useState("open"),{arrowRef:r,side:d,align:n,arrowUncentered:f,arrowStyles:C}=L();return x("div",o,{state:{open:p,side:d,align:n,uncentered:f},ref:[t,r],props:[{style:C,"aria-hidden":!0},a],stateAttributesMapping:Ue})});Ne.displayName="PopoverArrow";var Wo=u(R(),1);var Ie=Wo.forwardRef(function(o,t){let{render:i,className:s,style:P,...a}=o,c=m(),p=c.useState("open"),r=c.useState("mounted"),d=c.useState("transitionStatus"),n=c.useState("openChangeReason");return x("div",o,{state:{open:p,transitionStatus:d},ref:t,props:[{role:"presentation",hidden:!r,style:{pointerEvents:n===g.triggerHover?"none":void 0,userSelect:"none",WebkitUserSelect:"none"}},a],stateAttributesMapping:ie})});Ie.displayName="PopoverBackdrop";var Yo=u(R(),1);var be=Yo.forwardRef(function(o,t){let{render:i,className:s,style:P,...a}=o,c=m(),p=U(a.id);return c.useSyncedValueWithCleanup("titleElementId",p),x("h2",o,{ref:t,props:[{id:p},a]})});be.displayName="PopoverTitle";var qo=u(R(),1);var we=qo.forwardRef(function(o,t){let{render:i,className:s,style:P,...a}=o,c=m(),p=U(a.id);return c.useSyncedValueWithCleanup("descriptionElementId",p),x("p",o,{ref:t,props:[{id:p},a]})});we.displayName="PopoverDescription";var Jo=u(R(),1);var Me=Jo.forwardRef(function(o,t){let{render:i,className:s,style:P,disabled:a=!1,nativeButton:c=!0,...p}=o,{buttonRef:r,getButtonProps:d}=se({disabled:a,focusableWhenDisabled:!1,native:c}),n=m();return Lo(),x("button",o,{ref:[t,r],props:[{onClick(C){n.setOpen(!1,ne(g.closePress,C.nativeEvent))}},p,d]})});Me.displayName="PopoverClose";var Qo=u(R(),1);var _e=Qo.forwardRef(function(o,t){let{render:i,className:s,style:P,children:a,...c}=o,p=m(),{side:r}=L(),d=p.useState("instantType"),{children:n,state:f}=_o({store:p,side:r,children:a}),C={activationDirection:f.activationDirection,transitioning:f.transitioning,instant:d};return x("div",o,{state:C,ref:t,props:[c,{children:n}],stateAttributesMapping:Mo})});_e.displayName="PopoverViewport";var oe=class extends Xe{constructor(){super(Ao(),"Popover")}open(o){this.openByTrigger(o)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function Xo(){return new oe}var I=u(F());function On({...e}){return(0,I.jsx)(T.Root,{"data-slot":"popover",...e})}function Tn({...e}){return(0,I.jsx)(T.Trigger,{"data-slot":"popover-trigger",...e})}function yn({className:e,align:o="center",alignOffset:t=0,side:i="bottom",sideOffset:s=4,...P}){return(0,I.jsx)(T.Portal,{container:Eo(),children:(0,I.jsx)(T.Positioner,{align:o,alignOffset:t,side:i,sideOffset:s,className:"isolate z-50",children:(0,I.jsx)(T.Popup,{"data-slot":"popover-content",className:J("z-50 flex w-72 origin-(--transform-origin) flex-col gap-2.5 rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-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 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...P})})})}function Nn({className:e,...o}){return(0,I.jsx)("div",{"data-slot":"popover-header",className:J("flex flex-col gap-0.5 text-sm",e),...o})}function In({className:e,...o}){return(0,I.jsx)(T.Title,{"data-slot":"popover-title",className:J("font-medium",e),...o})}function bn({className:e,...o}){return(0,I.jsx)(T.Description,{"data-slot":"popover-description",className:J("text-muted-foreground",e),...o})}export{On as a,Tn as b,yn as c,Nn as d,In as e,bn as f};
2
- //# sourceMappingURL=chunk-FZPMZMFU.js.map
1
+ import{a as No,b as wo}from"./chunk-XBWE3IIB.js";import{a as Oo}from"./chunk-DG6LRRQT.js";import{a as bo}from"./chunk-FROPNHO5.js";import{a as Mo,b as _o}from"./chunk-UPZXXDXM.js";import{a as To,g as yo,h as Io}from"./chunk-QJVIEN5R.js";import{a as Xe,b as mo,c as Q,d as fo,e as Ro}from"./chunk-OXLXEX2R.js";import{i as xo}from"./chunk-H6TI5TWN.js";import{b as ho,d as So}from"./chunk-IAEAQCYR.js";import{$ as ro,A as Re,E as Ge,G as Le,I as ze,M as Ke,Ma as Eo,N as We,O as Ye,P as qe,Q as Je,S as Qe,V as Ze,W as $e,X as eo,Y as oo,_ as to,ba as no,ca as so,da as io,ea as ao,fa as po,ga as xe,ha as co,ia as uo,ka as lo,pa as go,qa as Po,xa as vo}from"./chunk-HCQR5YME.js";import{a as Co}from"./chunk-B4MRCKT4.js";import{m as He,n as je,o as Ue,p as ie}from"./chunk-7OCTAHT6.js";import{a as ne,c as g}from"./chunk-FTWKUXER.js";import{c as U}from"./chunk-AAL6V4Y3.js";import{d as se}from"./chunk-CLVPTZ4G.js";import{f as Ve}from"./chunk-LYT7LQS3.js";import{a as ke}from"./chunk-XIXCIQKJ.js";import{d as Be}from"./chunk-EGZKG2B2.js";import{a as et}from"./chunk-UH726PMV.js";import{a as re}from"./chunk-SFI7YWVR.js";import{b as Ae}from"./chunk-NZ73KS2Y.js";import{d as Fe,l as x}from"./chunk-JIAVZ3V7.js";import{a as J}from"./chunk-SVQCDOZ3.js";import{a as F}from"./chunk-CT4EH2K2.js";import{a as R}from"./chunk-IJQ26FTX.js";import{b as $o,c as u}from"./chunk-KVMUXFPB.js";var Cn=u(R());var T={};$o(T,{Arrow:()=>Ne,Backdrop:()=>Ie,Close:()=>Me,Description:()=>we,Handle:()=>oe,Popup:()=>ye,Portal:()=>Ee,Positioner:()=>Oe,Root:()=>Bo,Title:()=>be,Trigger:()=>he,Viewport:()=>_e,createHandle:()=>Xo});var Z=u(R(),1);var ae=u(R(),1),pe=ae.createContext(void 0);pe.displayName="PopoverRootContext";function m(e){let o=ae.useContext(pe);if(o===void 0&&!e)throw new Error("Base UI: PopoverRootContext is missing. Popover parts must be placed within <Popover.Root>.");return o}var X=u(R(),1),Do=u(et(),1);var Fo={...Q,disabled:e=>e.disabled,instantType:e=>e.instantType==="trigger-change"&&!Q.open(e)?void 0:e.instantType,openMethod:e=>e.openMethod,openChangeReason:e=>e.openChangeReason,isPressOpenedByTrigger:(e,o)=>e.openChangeReason===g.triggerPress&&Q.isOpenedByTrigger(e,o),isTouchPressOpen:(e,o)=>o&&e.openMethod==="touch"&&e.openChangeReason===g.triggerPress,hasTriggerFocusGuards:(e,o)=>Q.isOpenedByTrigger(e,o)&&!e.focusManagerModal,modal:e=>e.modal,titleElementId:e=>e.titleElementId,descriptionElementId:e=>e.descriptionElementId,openOnHover:e=>e.openOnHover,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin},ce=class extends lo{constructor(o,t,i){let s=new xe;super(Vo(o,s,t,i),ko(s),Fo)}setOpen=(o,t)=>{let i=t.reason===g.triggerHover,s=t.reason===g.triggerPress&&t.event.detail===0,P=!o&&(t.reason===g.escapeKey||t.reason==null),a=ro(t),c=this.select("activeTriggerId");if(!o&&t.reason===g.closePress&&t.trigger==null&&c!=null&&(t.trigger=this.context.triggerElements.getById(c)??this.select("activeTriggerElement")??void 0),this.context.onOpenChange?.(o,t),t.isCanceled)return;this.state.floatingRootContext.dispatchOpenChange(o,t);let p=()=>{let d=to(this.state,o,t.trigger,a());d.openChangeReason=t.reason,this.update(d)};i?(this.context.stickIfOpen=!0,this.context.stickIfOpenTimeout.start(500,()=>{this.context.stickIfOpen=!1}),Do.flushSync(p)):p();let r;s?r="click":P?r="dismiss":t.reason===g.focusOut&&(r="focus"),this.set("instantType",r)}};function Ao(){let e=new xe,o=new Ro(Object.freeze(Vo(void 0,e)),Object.freeze(ko(e)),Fo);return Object.assign(o,{setOpen:Fe})}function Vo(e,o,t,i=!1){let s={...mo(o,t,i),disabled:!1,modal:!1,focusManagerModal:!1,instantType:void 0,openMethod:null,openChangeReason:null,titleElementId:void 0,descriptionElementId:void 0,openOnHover:!1,closeDelay:0,adaptiveOrigin:void 0,...e};return s.open&&e?.mounted===void 0&&(s.mounted=!0),s}function ko(e){return{popupRef:X.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerFocusTargetRef:X.createRef(),beforeTriggerFocusGuardRef:X.createRef(),beforeContentFocusGuardRef:X.createRef(),stickIfOpenTimeout:new ke,stickIfOpen:!0,triggerElements:e}}var b=u(F(),1),Ce=co(function({props:o}){let{children:t,open:i,defaultOpen:s=!1,onOpenChange:P,onOpenChangeComplete:a,modal:c=!1,handle:p,triggerId:r,defaultTriggerId:d=null}=o,n=ot(p,{modal:c,open:s,openProp:i,activeTriggerId:d,triggerIdProp:r});n.useControlledProp("openProp",i),n.useControlledProp("triggerIdProp",r);let f=n.useState("open"),C=n.useState("mounted"),S=n.useState("payload");n.useContextCallback("onOpenChange",P),n.useContextCallback("onOpenChangeComplete",a),po(n,f),so(n);let{forceUnmount:y}=io(f,n,()=>{n.context.stickIfOpen=!0,n.set("openChangeReason",null)});n.useSyncedValues({modal:c}),Z.useEffect(()=>{f||n.context.stickIfOpenTimeout.clear()},[n,f]),Z.useImperativeHandle(o.actionsRef,()=>({unmount:y,close:()=>n.setOpen(!1,ne(g.imperativeAction))}),[y,n]);let A=f||C||p!=null;return(0,b.jsxs)(pe.Provider,{value:n,children:[p&&(0,b.jsx)(oo,{handle:p,store:n}),A&&(0,b.jsx)(tt,{store:n,modal:c}),typeof t=="function"?t({payload:S}):t]})});Ce.displayName="PopoverRootComponent";function Bo(e){return m(!0)?(0,b.jsx)(Ce,{props:e}):(0,b.jsx)(Ye,{children:(0,b.jsx)(Ce,{props:e})})}function ot(e,o){let t=eo((i,s)=>new ce(o,i,s));return Z.useEffect(()=>t.context.stickIfOpenTimeout.disposeEffect(),[t]),t}function tt({store:e,modal:o}){let t=e.useState("floatingRootContext"),i=Qe(t,{outsidePressEvent:{mouse:o==="trap-focus"?"sloppy":"intentional",touch:"sloppy"}}),s=i.reference,P=i.floating;return ao(e,{activeTriggerProps:s,inactiveTriggerProps:s,popupProps:P}),null}var $=u(R(),1);var G=u(F(),1),he=uo(function(o,t){let{render:i,className:s,style:P,disabled:a=!1,nativeButton:c=!0,handle:p,payload:r,openOnHover:d=!1,delay:n=300,closeDelay:f=0,id:C,...S}=o,y=m(!0),l=fo(p)??y;if(!l)throw new Error("Base UI: <Popover.Trigger> must be either used within a <Popover.Root> component or provided with a handle.");let h=U(C),v=l.useState("isTriggerActive",h),V=l.useState("floatingRootContext"),M=l.useState("isOpenedByTrigger",h),k=l.useState("triggerPopupId",h),E=$.useRef(null),{registerTrigger:O,isMountedByThisTrigger:_}=no(h,E,l,{payload:r,disabled:a,openOnHover:d,closeDelay:f}),B=l.useState("isPressOpenedByTrigger",h),z=l.useState("isTouchPressOpen",d),K=l.useState("hasTriggerFocusGuards",h),H=Po(V,{enabled:!a&&d&&!z,mouseOnly:!0,move:!1,handleClose:vo(),restMs:n,delay:{close:f},triggerElementRef:E,isActiveTrigger:v,isClosing:()=>l.select("transitionStatus")==="ending"}),W=re(()=>l.context.stickIfOpen),j=Je(V,{stickIfOpen:W}),Y=So(()=>l.select("open"),te=>{l.set("openMethod",te)}),N=l.useState("triggerProps",_),{getButtonProps:q,buttonRef:D}=se({disabled:a,native:c}),ge={open(te){return B?je.open(te):He.open(te)}},{handlePreFocusGuardFocus:Pe,handleFocusTargetFocus:ve}=wo(l,E),Zo=x("button",o,{state:{disabled:a,open:M},ref:[D,t,O,E],props:[j.reference,H,N,Y,{[Ge]:"",id:h,"aria-haspopup":"dialog","aria-expanded":M,"aria-controls":k},S,q],stateAttributesMapping:ge}),De=(0,G.jsx)($.Fragment,{children:Zo},h);return K?(0,G.jsxs)($.Fragment,{children:[(0,G.jsx)(Re,{ref:l.context.beforeTriggerFocusGuardRef,onFocus:Pe}),De,(0,G.jsx)(Re,{ref:l.context.triggerFocusTargetRef,onFocus:ve})]}):De});he.displayName="PopoverTrigger";var jo=u(R(),1);var ue=u(R(),1),le=ue.createContext(void 0);le.displayName="PopoverPortalContext";function Ho(){let e=ue.useContext(le);if(e===void 0)throw new Error("Base UI: <Popover.Portal> is missing.");return e}var Se=u(F(),1),Ee=jo.forwardRef(function(o,t){let{keepMounted:i=!1,...s}=o;return m().useState("mounted")||i?(0,Se.jsx)(le.Provider,{value:i,children:(0,Se.jsx)(ze,{ref:t,...s})}):null});Ee.displayName="PopoverPortal";var Uo=u(R(),1);var me=u(R(),1),de=me.createContext(void 0);de.displayName="PopoverPositionerContext";function L(){let e=me.useContext(de);if(!e)throw new Error("Base UI: PopoverPositionerContext is missing. PopoverPositioner parts must be placed within <Popover.Positioner>.");return e}var ee=u(F(),1),Oe=Uo.forwardRef(function(o,t){let{render:i,className:s,style:P,anchor:a,positionMethod:c,side:p,align:r,sideOffset:d,alignOffset:n,collisionBoundary:f="clipping-ancestors",collisionPadding:C,arrowPadding:S,sticky:y,disableAnchorTracking:A=!1,collisionAvoidance:l=Le,...h}=o,v=m(),V=Ho(),M=Ke(),k=v.useState("floatingRootContext"),E=v.useState("mounted"),O=v.useState("open"),_=v.useState("openChangeReason"),B=v.useState("activeTriggerElement"),z=v.useState("modal"),K=v.useState("openMethod"),H=v.useState("positionerElement"),W=v.useState("instantType"),j=v.useState("transitionStatus"),Y=v.useState("adaptiveOrigin"),N=yo({anchor:a,floatingRootContext:k,positionMethod:c,mounted:E,side:p,sideOffset:d,align:r,alignOffset:n,arrowPadding:S,collisionBoundary:f,collisionPadding:C,sticky:y,disableAnchorTracking:A,keepMounted:V,nodeId:M,collisionAvoidance:l,adaptiveOrigin:Y}),q=k.useState("domReferenceElement");No({store:v,domReference:q,positionerElement:H,open:O});let D=z===!0&&_!==g.triggerHover;bo(O&&D,K==="touch",H,B);let ge=v.useStateSetter("positionerElement"),Pe={open:O,side:N.side,align:N.align,anchorHidden:N.anchorHidden,instant:W},ve=Io(o,Pe,{styles:N.positionerStyles,transitionStatus:j,props:h,refs:[t,ge],hidden:!E,inert:!O});return(0,ee.jsxs)(de.Provider,{value:N,children:[E&&D&&(0,ee.jsx)(ho,{inert:Co(!O),cutout:B}),(0,ee.jsx)(We,{id:M,children:ve})]})});Oe.displayName="PopoverPositioner";var zo=u(R(),1);var w=u(R(),1);var fe=w.createContext(void 0);fe.displayName="ClosePartContext";function Go(){let[e,o]=w.useState(0),t=re(()=>(o(s=>s+1),()=>{o(s=>Math.max(0,s-1))}));return{context:w.useMemo(()=>({register:t}),[t]),hasClosePart:e>0}}function Lo(){let e=w.useContext(fe);Ae(()=>e?.register(),[e])}var Te=u(F(),1),ye=zo.forwardRef(function(o,t){let{render:i,className:s,style:P,initialFocus:a,finalFocus:c,...p}=o,r=m(),d=L(),n=Oo(!0)!=null,{context:f,hasClosePart:C}=Go(),S=r.useState("open"),y=r.useState("openMethod"),A=r.useState("instantType"),l=r.useState("transitionStatus"),h=r.useState("popupProps"),v=r.useState("titleElementId"),V=r.useState("descriptionElementId"),M=r.useState("modal"),k=r.useState("mounted"),E=r.useState("openChangeReason"),O=r.useState("activeTriggerElement"),_=r.useState("floatingRootContext"),B=_.useState("floatingId"),z=r.useState("disabled"),K=r.useState("openOnHover"),H=r.useState("closeDelay");Be({open:S,ref:r.context.popupRef,onComplete(){S&&r.context.onOpenChangeComplete?.(!0)}}),go(_,{enabled:K&&!z,closeDelay:H});let W=a===void 0?$e(r.context.popupRef):a,j=M!==!1&&C;r.useSyncedValue("focusManagerModal",j);let Y=r.useStateSetter("popupElement"),N={open:S,side:d.side,align:d.align,instant:A,transitionStatus:l},q=x("div",o,{state:N,ref:[t,r.context.popupRef,Y],props:[h,{id:B,role:"dialog",...Ze,"aria-labelledby":v,"aria-describedby":V,onKeyDown(D){n&&xo.has(D.key)&&D.stopPropagation()}},To(l),p],stateAttributesMapping:ie});return(0,Te.jsx)(qe,{context:_,openInteractionType:y,modal:j,disabled:!k||E===g.triggerHover,initialFocus:W,returnFocus:c,restoreFocus:"popup",getInsideElements:()=>[r.context.beforeTriggerFocusGuardRef.current],previousFocusableElement:Ve(O)?O:void 0,nextFocusableElement:r.context.triggerFocusTargetRef,beforeContentFocusGuardRef:r.context.beforeContentFocusGuardRef,children:(0,Te.jsx)(fe.Provider,{value:f,children:q})})});ye.displayName="PopoverPopup";var Ko=u(R(),1);var Ne=Ko.forwardRef(function(o,t){let{render:i,className:s,style:P,...a}=o,p=m().useState("open"),{arrowRef:r,side:d,align:n,arrowUncentered:f,arrowStyles:C}=L();return x("div",o,{state:{open:p,side:d,align:n,uncentered:f},ref:[t,r],props:[{style:C,"aria-hidden":!0},a],stateAttributesMapping:Ue})});Ne.displayName="PopoverArrow";var Wo=u(R(),1);var Ie=Wo.forwardRef(function(o,t){let{render:i,className:s,style:P,...a}=o,c=m(),p=c.useState("open"),r=c.useState("mounted"),d=c.useState("transitionStatus"),n=c.useState("openChangeReason");return x("div",o,{state:{open:p,transitionStatus:d},ref:t,props:[{role:"presentation",hidden:!r,style:{pointerEvents:n===g.triggerHover?"none":void 0,userSelect:"none",WebkitUserSelect:"none"}},a],stateAttributesMapping:ie})});Ie.displayName="PopoverBackdrop";var Yo=u(R(),1);var be=Yo.forwardRef(function(o,t){let{render:i,className:s,style:P,...a}=o,c=m(),p=U(a.id);return c.useSyncedValueWithCleanup("titleElementId",p),x("h2",o,{ref:t,props:[{id:p},a]})});be.displayName="PopoverTitle";var qo=u(R(),1);var we=qo.forwardRef(function(o,t){let{render:i,className:s,style:P,...a}=o,c=m(),p=U(a.id);return c.useSyncedValueWithCleanup("descriptionElementId",p),x("p",o,{ref:t,props:[{id:p},a]})});we.displayName="PopoverDescription";var Jo=u(R(),1);var Me=Jo.forwardRef(function(o,t){let{render:i,className:s,style:P,disabled:a=!1,nativeButton:c=!0,...p}=o,{buttonRef:r,getButtonProps:d}=se({disabled:a,focusableWhenDisabled:!1,native:c}),n=m();return Lo(),x("button",o,{ref:[t,r],props:[{onClick(C){n.setOpen(!1,ne(g.closePress,C.nativeEvent))}},p,d]})});Me.displayName="PopoverClose";var Qo=u(R(),1);var _e=Qo.forwardRef(function(o,t){let{render:i,className:s,style:P,children:a,...c}=o,p=m(),{side:r}=L(),d=p.useState("instantType"),{children:n,state:f}=_o({store:p,side:r,children:a}),C={activationDirection:f.activationDirection,transitioning:f.transitioning,instant:d};return x("div",o,{state:C,ref:t,props:[c,{children:n}],stateAttributesMapping:Mo})});_e.displayName="PopoverViewport";var oe=class extends Xe{constructor(){super(Ao(),"Popover")}open(o){this.openByTrigger(o)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function Xo(){return new oe}var I=u(F());function On({...e}){return(0,I.jsx)(T.Root,{"data-slot":"popover",...e})}function Tn({...e}){return(0,I.jsx)(T.Trigger,{"data-slot":"popover-trigger",...e})}function yn({className:e,align:o="center",alignOffset:t=0,side:i="bottom",sideOffset:s=4,...P}){return(0,I.jsx)(T.Portal,{container:Eo(),children:(0,I.jsx)(T.Positioner,{align:o,alignOffset:t,side:i,sideOffset:s,className:"isolate z-50",children:(0,I.jsx)(T.Popup,{"data-slot":"popover-content",className:J("z-50 flex w-72 origin-(--transform-origin) flex-col gap-2.5 rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-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 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...P})})})}function Nn({className:e,...o}){return(0,I.jsx)("div",{"data-slot":"popover-header",className:J("flex flex-col gap-0.5 text-sm",e),...o})}function In({className:e,...o}){return(0,I.jsx)(T.Title,{"data-slot":"popover-title",className:J("font-medium",e),...o})}function bn({className:e,...o}){return(0,I.jsx)(T.Description,{"data-slot":"popover-description",className:J("text-muted-foreground",e),...o})}export{On as a,Tn as b,yn as c,Nn as d,In as e,bn as f};
2
+ //# sourceMappingURL=chunk-SC7J7HFI.js.map
@@ -1,2 +1,2 @@
1
- import{b as K}from"./chunk-XIXCIQKJ.js";import{a as H,d as Q}from"./chunk-EGZKG2B2.js";import{d as J}from"./chunk-MQ67DRDE.js";import{a as $}from"./chunk-SFI7YWVR.js";import{b}from"./chunk-NZ73KS2Y.js";import{a as V}from"./chunk-CT4EH2K2.js";import{d as F,l as A}from"./chunk-JIAVZ3V7.js";import{a as X}from"./chunk-7TG23VIV.js";import{a as g}from"./chunk-SVQCDOZ3.js";import{a as x}from"./chunk-IJQ26FTX.js";import{b as lt,c as m}from"./chunk-KVMUXFPB.js";var v=m(x());var h={};lt(h,{Fallback:()=>B,Image:()=>j,Root:()=>D});var z=m(x(),1);var L=m(x(),1),w=L.createContext(void 0);w.displayName="AvatarRootContext";function M(){let e=L.useContext(w);if(e===void 0)throw new Error("Base UI: AvatarRootContext is missing. Avatar parts must be placed within <Avatar.Root>.");return e}var R={imageLoadingStatus:()=>null};var Y=m(V(),1),D=z.forwardRef(function(t,a){let{className:r,render:l,style:n,...s}=t,[i,d]=z.useState("idle"),o={imageLoadingStatus:i},c=z.useMemo(()=>({imageLoadingStatus:i,setImageLoadingStatus:d}),[i,d]),f=A("span",t,{state:o,ref:a,props:s,stateAttributesMapping:R});return(0,Y.jsx)(w.Provider,{value:c,children:f})});D.displayName="AvatarRoot";var y=m(x(),1);var tt=m(x(),1);function et(e,{referrerPolicy:t,crossOrigin:a,sizes:r,srcSet:l},n){let s=tt.useState("idle"),i=s[1];return b(()=>{if(!n)return F;if(!e&&!l)return i("error"),F;let d=!0,o=new window.Image,c=f=>()=>{d&&i(f)};return i("loading"),o.onload=c("loaded"),o.onerror=c("error"),t&&(o.referrerPolicy=t),o.crossOrigin=a??null,r&&(o.sizes=r),l&&(o.srcset=l),e&&(o.src=e),o.complete&&i(o.naturalWidth>0?"loaded":"error"),()=>{d=!1}},[n,e,l,r,a,t,i]),s}var ut={...R,...J},j=y.forwardRef(function(t,a){let{className:r,render:l,onLoadingStatusChange:n,keepMounted:s=!1,style:i,sizes:d,srcSet:o,src:c,...f}=t,{setImageLoadingStatus:C}=M(),[p,S]=et(c,t,!s),E=p==="loaded",{mounted:ot,transitionStatus:G,setMounted:O}=H(E),P=y.useRef(null),T=y.useRef(!0);b(()=>{if(!s)return;let I=T.current;T.current=!1;let _=P.current;if(!_)return;if(!_.complete){S("loading");return}let Z=_.naturalWidth>0?"loaded":"error";S(Z),Z==="loaded"&&I&&O(!0)},[s,c,o,d,f.crossOrigin,f.referrerPolicy,l,S,O]);let nt=s?{"data-loading":p==="loading"?"":void 0,"data-error":p==="error"?"":void 0,"aria-hidden":p!=="loaded"||void 0,onLoad(){S("loaded")},onError(){S("error")}}:void 0,W=$(I=>{n?.(I),C(I)});b(()=>{p!=="idle"&&W(p)},[p,W]),b(()=>()=>C("idle"),[C]),Q({enabled:!E,open:E,ref:P,onComplete(){E||O(!1)}});let st={imageLoadingStatus:p,transitionStatus:s&&G==="ending"?void 0:G},q=s||ot,k={};d!==void 0&&(k.sizes=d),o!==void 0&&(k.srcSet=o),c!==void 0&&(k.src=c);let it=A("img",t,{state:st,ref:[a,P],props:[nt,f,k],stateAttributesMapping:ut,enabled:q});return q?it:null});j.displayName="AvatarImage";var N=m(x(),1);var B=N.forwardRef(function(t,a){let{className:r,render:l,delay:n=0,style:s,...i}=t,{imageLoadingStatus:d}=M(),[o,c]=N.useState(n===0),f=K();return N.useEffect(()=>(n>0?f.start(n,()=>c(!0)):c(!0),f.clear),[f,n]),A("span",t,{state:{imageLoadingStatus:d},ref:a,props:i,stateAttributesMapping:R,enabled:d!=="loaded"&&(n===0||o)})});B.displayName="AvatarFallback";var u=m(V()),at=X("group/avatar relative flex shrink-0 rounded-full select-none after:pointer-events-none after:absolute after:inset-0 after:rounded-full after:border after:border-border after:mix-blend-darken dark:after:mix-blend-lighten",{variants:{size:{xs:"size-5 text-[9px]",sm:"size-6 text-[10px]",default:"size-8 text-xs",lg:"size-10 text-sm",xl:"size-12 text-base"}},defaultVariants:{size:"default"}}),U=v.createContext(null);function dt({className:e,size:t,...a}){let r=v.useContext(U),l=t||r||"default";return(0,u.jsx)(h.Root,{"data-slot":"avatar","data-size":l,className:g(at({size:l}),e),...a})}function ct({className:e,...t}){return(0,u.jsx)(h.Image,{"data-slot":"avatar-image",className:g("aspect-square size-full rounded-full object-cover",e),...t})}function ft({className:e,...t}){return(0,u.jsx)(h.Fallback,{"data-slot":"avatar-fallback",className:g("flex size-full items-center justify-center rounded-full bg-muted font-semibold tracking-tight text-muted-foreground","[[data-slot=avatar-group]>[data-slot=avatar]:not(:last-child)_&]:pr-[calc(var(--avatar-group-overlap)+2px)] [[data-slot=avatar-group]>[data-slot=avatar]:not(:last-child)_&]:tracking-tighter",e),...t})}var rt={online:{className:"bg-emerald-500",label:"Online"},away:{className:"bg-amber-500",label:"Away"},busy:{className:"bg-destructive",label:"Busy"},offline:{className:"bg-muted-foreground/60",label:"Offline"}};function pt({className:e,status:t,label:a,children:r,...l}){let n=t?rt[t]:null,s=a!==void 0?a:n?n.label:void 0;return(0,u.jsxs)("span",{"data-slot":"avatar-badge","data-status":t,className:g("absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-primary text-primary-foreground ring-2 ring-background select-none","group-data-[size=xs]/avatar:size-1.5 group-data-[size=sm]/avatar:size-2 group-data-[size=default]/avatar:size-2.5 group-data-[size=lg]/avatar:size-3 group-data-[size=xl]/avatar:size-3.5","[&>svg]:size-[70%]",n?n.className:"",e),...l,children:[r,s?(0,u.jsx)("span",{className:"sr-only",children:s}):null]})}function mt(e,t){let a=Array.isArray(e)?e:[];if(!t||t<=0||a.length<=t)return{visible:a,hidden:[],overflow:0};let r=Math.max(1,t-1);return{visible:a.slice(0,r),hidden:a.slice(r),overflow:a.length-r}}function Jt({className:e,children:t,max:a,size:r,renderCount:l,...n}){let s=v.Children.toArray(t).filter(Boolean),{visible:i,hidden:d,overflow:o}=mt(s,a);return(0,u.jsx)(U.Provider,{value:r||null,children:(0,u.jsxs)("div",{"data-slot":"avatar-group","data-size":r||"default",className:g("group/avatar-group flex items-center -space-x-(--avatar-group-overlap) *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-background","[--avatar-group-overlap:7px] data-[size=xs]:[--avatar-group-overlap:3px] data-[size=sm]:[--avatar-group-overlap:4px] data-[size=lg]:[--avatar-group-overlap:9px] data-[size=xl]:[--avatar-group-overlap:11px]","data-[size=xs]:*:text-[8px] data-[size=sm]:*:text-[9px]",e),...n,children:[i,o>0?l?l(o,d):(0,u.jsxs)(gt,{size:r,children:["+",o]}):null]})})}function gt({className:e,size:t,children:a,...r}){let l=v.useContext(U),n=t||l||"default",s=typeof a=="string"?a:"",i=/^\+(\d+)$/.exec(s);return(0,u.jsxs)("span",{"data-slot":"avatar-group-count",className:g(at({size:n}),"items-center justify-center bg-muted font-medium text-muted-foreground ring-2 ring-background after:hidden",e),...r,children:[(0,u.jsx)("span",{"aria-hidden":i?"true":void 0,children:a}),i?(0,u.jsxs)("span",{className:"sr-only",children:[i[1]," more"]}):null]})}function vt(e){let t=String(e||"").split(/[\s,()[\]{}<>"/\\|]+/).filter(a=>/^[A-Za-z0-9À-￿]/.test(a));return t.length?t.length===1?t[0].slice(0,2).toUpperCase():(t[0][0]+t[t.length-1][0]).toUpperCase():"?"}function Kt({name:e,src:t,initials:a,status:r,size:l,labelled:n=!1,className:s,title:i,...d}){let o=r?rt[r]:null,c=n?{role:"img","aria-label":[e,o?o.label:""].filter(Boolean).join(", ")}:{"aria-hidden":!0};return(0,u.jsxs)(dt,{size:l,className:s,title:i===void 0?e:i,...c,...d,children:[t?(0,u.jsx)(ct,{src:t,alt:""}):null,(0,u.jsx)(ft,{children:a||vt(e)}),r?(0,u.jsx)(pt,{status:r,label:n?"":void 0}):null]})}export{at as a,dt as b,ct as c,ft as d,rt as e,pt as f,mt as g,Jt as h,gt as i,vt as j,Kt as k};
2
- //# sourceMappingURL=chunk-X34AFUS2.js.map
1
+ import{b as K}from"./chunk-XIXCIQKJ.js";import{a as H,d as Q}from"./chunk-EGZKG2B2.js";import{d as J}from"./chunk-MQ67DRDE.js";import{a as $}from"./chunk-SFI7YWVR.js";import{b}from"./chunk-NZ73KS2Y.js";import{d as F,l as A}from"./chunk-JIAVZ3V7.js";import{a as X}from"./chunk-7TG23VIV.js";import{a as g}from"./chunk-SVQCDOZ3.js";import{a as V}from"./chunk-CT4EH2K2.js";import{a as x}from"./chunk-IJQ26FTX.js";import{b as lt,c as m}from"./chunk-KVMUXFPB.js";var v=m(x());var h={};lt(h,{Fallback:()=>B,Image:()=>j,Root:()=>D});var z=m(x(),1);var L=m(x(),1),w=L.createContext(void 0);w.displayName="AvatarRootContext";function M(){let e=L.useContext(w);if(e===void 0)throw new Error("Base UI: AvatarRootContext is missing. Avatar parts must be placed within <Avatar.Root>.");return e}var R={imageLoadingStatus:()=>null};var Y=m(V(),1),D=z.forwardRef(function(t,a){let{className:r,render:l,style:n,...s}=t,[i,d]=z.useState("idle"),o={imageLoadingStatus:i},c=z.useMemo(()=>({imageLoadingStatus:i,setImageLoadingStatus:d}),[i,d]),f=A("span",t,{state:o,ref:a,props:s,stateAttributesMapping:R});return(0,Y.jsx)(w.Provider,{value:c,children:f})});D.displayName="AvatarRoot";var y=m(x(),1);var tt=m(x(),1);function et(e,{referrerPolicy:t,crossOrigin:a,sizes:r,srcSet:l},n){let s=tt.useState("idle"),i=s[1];return b(()=>{if(!n)return F;if(!e&&!l)return i("error"),F;let d=!0,o=new window.Image,c=f=>()=>{d&&i(f)};return i("loading"),o.onload=c("loaded"),o.onerror=c("error"),t&&(o.referrerPolicy=t),o.crossOrigin=a??null,r&&(o.sizes=r),l&&(o.srcset=l),e&&(o.src=e),o.complete&&i(o.naturalWidth>0?"loaded":"error"),()=>{d=!1}},[n,e,l,r,a,t,i]),s}var ut={...R,...J},j=y.forwardRef(function(t,a){let{className:r,render:l,onLoadingStatusChange:n,keepMounted:s=!1,style:i,sizes:d,srcSet:o,src:c,...f}=t,{setImageLoadingStatus:C}=M(),[p,S]=et(c,t,!s),E=p==="loaded",{mounted:ot,transitionStatus:G,setMounted:O}=H(E),P=y.useRef(null),T=y.useRef(!0);b(()=>{if(!s)return;let I=T.current;T.current=!1;let _=P.current;if(!_)return;if(!_.complete){S("loading");return}let Z=_.naturalWidth>0?"loaded":"error";S(Z),Z==="loaded"&&I&&O(!0)},[s,c,o,d,f.crossOrigin,f.referrerPolicy,l,S,O]);let nt=s?{"data-loading":p==="loading"?"":void 0,"data-error":p==="error"?"":void 0,"aria-hidden":p!=="loaded"||void 0,onLoad(){S("loaded")},onError(){S("error")}}:void 0,W=$(I=>{n?.(I),C(I)});b(()=>{p!=="idle"&&W(p)},[p,W]),b(()=>()=>C("idle"),[C]),Q({enabled:!E,open:E,ref:P,onComplete(){E||O(!1)}});let st={imageLoadingStatus:p,transitionStatus:s&&G==="ending"?void 0:G},q=s||ot,k={};d!==void 0&&(k.sizes=d),o!==void 0&&(k.srcSet=o),c!==void 0&&(k.src=c);let it=A("img",t,{state:st,ref:[a,P],props:[nt,f,k],stateAttributesMapping:ut,enabled:q});return q?it:null});j.displayName="AvatarImage";var N=m(x(),1);var B=N.forwardRef(function(t,a){let{className:r,render:l,delay:n=0,style:s,...i}=t,{imageLoadingStatus:d}=M(),[o,c]=N.useState(n===0),f=K();return N.useEffect(()=>(n>0?f.start(n,()=>c(!0)):c(!0),f.clear),[f,n]),A("span",t,{state:{imageLoadingStatus:d},ref:a,props:i,stateAttributesMapping:R,enabled:d!=="loaded"&&(n===0||o)})});B.displayName="AvatarFallback";var u=m(V()),at=X("group/avatar relative flex shrink-0 rounded-full select-none after:pointer-events-none after:absolute after:inset-0 after:rounded-full after:border after:border-border after:mix-blend-darken dark:after:mix-blend-lighten",{variants:{size:{xs:"size-5 text-[9px]",sm:"size-6 text-[10px]",default:"size-8 text-xs",lg:"size-10 text-sm",xl:"size-12 text-base"}},defaultVariants:{size:"default"}}),U=v.createContext(null);function dt({className:e,size:t,...a}){let r=v.useContext(U),l=t||r||"default";return(0,u.jsx)(h.Root,{"data-slot":"avatar","data-size":l,className:g(at({size:l}),e),...a})}function ct({className:e,...t}){return(0,u.jsx)(h.Image,{"data-slot":"avatar-image",className:g("aspect-square size-full rounded-full object-cover",e),...t})}function ft({className:e,...t}){return(0,u.jsx)(h.Fallback,{"data-slot":"avatar-fallback",className:g("flex size-full items-center justify-center rounded-full bg-muted font-semibold tracking-tight text-muted-foreground","[[data-slot=avatar-group]>[data-slot=avatar]:not(:last-child)_&]:pr-[calc(var(--avatar-group-overlap)+2px)] [[data-slot=avatar-group]>[data-slot=avatar]:not(:last-child)_&]:tracking-tighter",e),...t})}var rt={online:{className:"bg-emerald-500",label:"Online"},away:{className:"bg-amber-500",label:"Away"},busy:{className:"bg-destructive",label:"Busy"},offline:{className:"bg-muted-foreground/60",label:"Offline"}};function pt({className:e,status:t,label:a,children:r,...l}){let n=t?rt[t]:null,s=a!==void 0?a:n?n.label:void 0;return(0,u.jsxs)("span",{"data-slot":"avatar-badge","data-status":t,className:g("absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-primary text-primary-foreground ring-2 ring-background select-none","group-data-[size=xs]/avatar:size-1.5 group-data-[size=sm]/avatar:size-2 group-data-[size=default]/avatar:size-2.5 group-data-[size=lg]/avatar:size-3 group-data-[size=xl]/avatar:size-3.5","[&>svg]:size-[70%]",n?n.className:"",e),...l,children:[r,s?(0,u.jsx)("span",{className:"sr-only",children:s}):null]})}function mt(e,t){let a=Array.isArray(e)?e:[];if(!t||t<=0||a.length<=t)return{visible:a,hidden:[],overflow:0};let r=Math.max(1,t-1);return{visible:a.slice(0,r),hidden:a.slice(r),overflow:a.length-r}}function Jt({className:e,children:t,max:a,size:r,renderCount:l,...n}){let s=v.Children.toArray(t).filter(Boolean),{visible:i,hidden:d,overflow:o}=mt(s,a);return(0,u.jsx)(U.Provider,{value:r||null,children:(0,u.jsxs)("div",{"data-slot":"avatar-group","data-size":r||"default",className:g("group/avatar-group flex items-center -space-x-(--avatar-group-overlap) *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-background","[--avatar-group-overlap:7px] data-[size=xs]:[--avatar-group-overlap:3px] data-[size=sm]:[--avatar-group-overlap:4px] data-[size=lg]:[--avatar-group-overlap:9px] data-[size=xl]:[--avatar-group-overlap:11px]","data-[size=xs]:*:text-[8px] data-[size=sm]:*:text-[9px]",e),...n,children:[i,o>0?l?l(o,d):(0,u.jsxs)(gt,{size:r,children:["+",o]}):null]})})}function gt({className:e,size:t,children:a,...r}){let l=v.useContext(U),n=t||l||"default",s=typeof a=="string"?a:"",i=/^\+(\d+)$/.exec(s);return(0,u.jsxs)("span",{"data-slot":"avatar-group-count",className:g(at({size:n}),"items-center justify-center bg-muted font-medium text-muted-foreground ring-2 ring-background after:hidden",e),...r,children:[(0,u.jsx)("span",{"aria-hidden":i?"true":void 0,children:a}),i?(0,u.jsxs)("span",{className:"sr-only",children:[i[1]," more"]}):null]})}function vt(e){let t=String(e||"").split(/[\s,()[\]{}<>"/\\|]+/).filter(a=>/^[A-Za-z0-9À-￿]/.test(a));return t.length?t.length===1?t[0].slice(0,2).toUpperCase():(t[0][0]+t[t.length-1][0]).toUpperCase():"?"}function Kt({name:e,src:t,initials:a,status:r,size:l,labelled:n=!1,className:s,title:i,...d}){let o=r?rt[r]:null,c=n?{role:"img","aria-label":[e,o?o.label:""].filter(Boolean).join(", ")}:{"aria-hidden":!0};return(0,u.jsxs)(dt,{size:l,className:s,title:i===void 0?e:i,...c,...d,children:[t?(0,u.jsx)(ct,{src:t,alt:""}):null,(0,u.jsx)(ft,{children:a||vt(e)}),r?(0,u.jsx)(pt,{status:r,label:n?"":void 0}):null]})}export{at as a,dt as b,ct as c,ft as d,rt as e,pt as f,mt as g,Jt as h,gt as i,vt as j,Kt as k};
2
+ //# sourceMappingURL=chunk-SKBWMIS5.js.map
@@ -1,2 +1,2 @@
1
- import{a,b as t,c as e,d as i,e as p,f as s,g as l,h as D,i as g,j as m,k as f}from"./chunk-UUJ5X322.js";import{ha as r}from"./chunk-OXJ6LWKI.js";import{b as u}from"./chunk-KVMUXFPB.js";var x={};u(x,{Backdrop:()=>t,Close:()=>e,Description:()=>i,Handle:()=>m,Popup:()=>p,Portal:()=>s,Root:()=>o,Title:()=>l,Trigger:()=>D,Viewport:()=>g,createHandle:()=>f});var o=r(function(n){return a("dialog",n)});o.displayName="DialogRoot";export{x as a};
2
- //# sourceMappingURL=chunk-LTVKSGLG.js.map
1
+ import{a,b as t,c as e,d as i,e as p,f as s,g as l,h as D,i as g,j as m,k as f}from"./chunk-ZTMZ7LJW.js";import{ha as r}from"./chunk-HCQR5YME.js";import{b as u}from"./chunk-KVMUXFPB.js";var x={};u(x,{Backdrop:()=>t,Close:()=>e,Description:()=>i,Handle:()=>m,Popup:()=>p,Portal:()=>s,Root:()=>o,Title:()=>l,Trigger:()=>D,Viewport:()=>g,createHandle:()=>f});var o=r(function(n){return a("dialog",n)});o.displayName="DialogRoot";export{x as a};
2
+ //# sourceMappingURL=chunk-UCEBXCOI.js.map