ivt 0.2.5 → 0.2.6

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 (154) hide show
  1. package/dist/accordion/index.mjs +1 -1
  2. package/dist/alert/index.mjs +1 -1
  3. package/dist/alert-dialog/index.mjs +1 -1
  4. package/dist/avatar/index.mjs +1 -1
  5. package/dist/badge/index.mjs +1 -1
  6. package/dist/base/index.d.ts +27 -2
  7. package/dist/base/index.mjs +1 -1
  8. package/dist/base/index.mjs.map +1 -1
  9. package/dist/button/index.mjs +1 -1
  10. package/dist/calendar/index.mjs +1 -1
  11. package/dist/card/index.mjs +1 -1
  12. package/dist/checkbox/index.mjs +1 -1
  13. package/dist/checkbox/index.mjs.map +1 -1
  14. package/dist/chunks/{accordion-BD1JRhVx.mjs → accordion-0MI-Gnhr.mjs} +2 -2
  15. package/dist/chunks/{accordion-BD1JRhVx.mjs.map → accordion-0MI-Gnhr.mjs.map} +1 -1
  16. package/dist/chunks/{badge-BlZWYqiz.mjs → badge-CORNh0AZ.mjs} +2 -2
  17. package/dist/chunks/{badge-BlZWYqiz.mjs.map → badge-CORNh0AZ.mjs.map} +1 -1
  18. package/dist/chunks/{bundle-mjs-p2tkjPN1.mjs → bundle-mjs-D9tdROnD.mjs} +1 -1
  19. package/dist/chunks/{bundle-mjs-p2tkjPN1.mjs.map → bundle-mjs-D9tdROnD.mjs.map} +1 -1
  20. package/dist/chunks/{button-DrtQQeut.mjs → button-C-N34JAH.mjs} +2 -2
  21. package/dist/chunks/{button-DrtQQeut.mjs.map → button-C-N34JAH.mjs.map} +1 -1
  22. package/dist/chunks/{calendar-Dtopgd_k.mjs → calendar--a2-dYhD.mjs} +2 -2
  23. package/dist/chunks/{calendar-Dtopgd_k.mjs.map → calendar--a2-dYhD.mjs.map} +1 -1
  24. package/dist/chunks/check-C1kmNajw.mjs +2 -0
  25. package/dist/chunks/{check-XiDheatr.mjs.map → check-C1kmNajw.mjs.map} +1 -1
  26. package/dist/chunks/chevron-down-V04oa9sD.mjs +2 -0
  27. package/dist/chunks/{chevron-down-B1yMwors.mjs.map → chevron-down-V04oa9sD.mjs.map} +1 -1
  28. package/dist/chunks/chevron-left-B3kOPqDD.mjs +2 -0
  29. package/dist/chunks/{chevron-left-HipRXZQ8.mjs.map → chevron-left-B3kOPqDD.mjs.map} +1 -1
  30. package/dist/chunks/chevron-right-PpLc5ALc.mjs +2 -0
  31. package/dist/chunks/{chevron-right-BS1_kgp8.mjs.map → chevron-right-PpLc5ALc.mjs.map} +1 -1
  32. package/dist/chunks/circle-U4u29qXG.mjs +2 -0
  33. package/dist/chunks/circle-U4u29qXG.mjs.map +1 -0
  34. package/dist/chunks/{command-DzL_b7f4.mjs → command-C7dK8ZE6.mjs} +2 -2
  35. package/dist/chunks/{command-DzL_b7f4.mjs.map → command-C7dK8ZE6.mjs.map} +1 -1
  36. package/dist/chunks/{createLucideIcon-CsAdJd--.mjs → createLucideIcon-CXSR1bEP.mjs} +1 -1
  37. package/dist/chunks/{createLucideIcon-CsAdJd--.mjs.map → createLucideIcon-CXSR1bEP.mjs.map} +1 -1
  38. package/dist/chunks/{dialog-D8zOlPrU.mjs → dialog-CJ5QhsSB.mjs} +2 -2
  39. package/dist/chunks/{dialog-D8zOlPrU.mjs.map → dialog-CJ5QhsSB.mjs.map} +1 -1
  40. package/dist/chunks/{hover-card-Cd6sPuv9.mjs → hover-card-Bok4BVC-.mjs} +2 -2
  41. package/dist/chunks/{hover-card-Cd6sPuv9.mjs.map → hover-card-Bok4BVC-.mjs.map} +1 -1
  42. package/dist/chunks/{index-CgLDADnA.mjs → index-BJZ14-gh.mjs} +1 -1
  43. package/dist/chunks/{index-CgLDADnA.mjs.map → index-BJZ14-gh.mjs.map} +1 -1
  44. package/dist/chunks/{index-B_x_ais9.mjs → index-BMe6PFsX.mjs} +2 -2
  45. package/dist/chunks/{index-B_x_ais9.mjs.map → index-BMe6PFsX.mjs.map} +1 -1
  46. package/dist/chunks/{index-LYeASA5N.mjs → index-BNzQ3c3A.mjs} +2 -2
  47. package/dist/chunks/{index-LYeASA5N.mjs.map → index-BNzQ3c3A.mjs.map} +1 -1
  48. package/dist/chunks/{index-B70-2oxO.mjs → index-BO-2wsZH.mjs} +1 -1
  49. package/dist/chunks/{index-B70-2oxO.mjs.map → index-BO-2wsZH.mjs.map} +1 -1
  50. package/dist/chunks/{index-CTsIdIko.mjs → index-BVACT7xe.mjs} +2 -2
  51. package/dist/chunks/{index-CTsIdIko.mjs.map → index-BVACT7xe.mjs.map} +1 -1
  52. package/dist/chunks/{index-C2Fe0koc.mjs → index-BzvNkDmM.mjs} +1 -1
  53. package/dist/chunks/{index-C2Fe0koc.mjs.map → index-BzvNkDmM.mjs.map} +1 -1
  54. package/dist/chunks/{index-DRqB8wXi.mjs → index-C20HgOT7.mjs} +2 -2
  55. package/dist/chunks/{index-DRqB8wXi.mjs.map → index-C20HgOT7.mjs.map} +1 -1
  56. package/dist/chunks/{index-fgRlmr40.mjs → index-C3QHFNp7.mjs} +1 -1
  57. package/dist/chunks/{index-fgRlmr40.mjs.map → index-C3QHFNp7.mjs.map} +1 -1
  58. package/dist/chunks/index-CO0WWuYX.mjs +2 -0
  59. package/dist/chunks/index-CO0WWuYX.mjs.map +1 -0
  60. package/dist/chunks/{index-Dxh10iPI.mjs → index-CZMSgrEB.mjs} +1 -1
  61. package/dist/chunks/{index-Dxh10iPI.mjs.map → index-CZMSgrEB.mjs.map} +1 -1
  62. package/dist/chunks/{index-ZEFtUcMw.mjs → index-D532f2iM.mjs} +2 -2
  63. package/dist/chunks/{index-ZEFtUcMw.mjs.map → index-D532f2iM.mjs.map} +1 -1
  64. package/dist/chunks/{index-CIJFMEHT.mjs → index-D5ESKExj.mjs} +2 -2
  65. package/dist/chunks/{index-CIJFMEHT.mjs.map → index-D5ESKExj.mjs.map} +1 -1
  66. package/dist/chunks/{index-CQLZqpi3.mjs → index-DCzuZZz4.mjs} +1 -1
  67. package/dist/chunks/{index-CQLZqpi3.mjs.map → index-DCzuZZz4.mjs.map} +1 -1
  68. package/dist/chunks/{index-C5Y3Sf57.mjs → index-DOiEGiat.mjs} +2 -2
  69. package/dist/chunks/{index-C5Y3Sf57.mjs.map → index-DOiEGiat.mjs.map} +1 -1
  70. package/dist/chunks/{index-g_YR6VZJ.mjs → index-DtAARIfz.mjs} +1 -1
  71. package/dist/chunks/{index-g_YR6VZJ.mjs.map → index-DtAARIfz.mjs.map} +1 -1
  72. package/dist/chunks/{index-CDjTdrNO.mjs → index-L0FTCOiH.mjs} +2 -2
  73. package/dist/chunks/{index-CDjTdrNO.mjs.map → index-L0FTCOiH.mjs.map} +1 -1
  74. package/dist/chunks/{index-C-Of5QmS.mjs → index-PTRe4YNS.mjs} +2 -2
  75. package/dist/chunks/{index-C-Of5QmS.mjs.map → index-PTRe4YNS.mjs.map} +1 -1
  76. package/dist/chunks/{index-Dx9q9PhQ.mjs → index-qj95ftFz.mjs} +2 -2
  77. package/dist/chunks/{index-Dx9q9PhQ.mjs.map → index-qj95ftFz.mjs.map} +1 -1
  78. package/dist/chunks/index-yLvhFHpw.mjs +2 -0
  79. package/dist/chunks/index-yLvhFHpw.mjs.map +1 -0
  80. package/dist/chunks/{input-B-LMt_h_.mjs → input-BlNrkN6W.mjs} +2 -2
  81. package/dist/chunks/{input-B-LMt_h_.mjs.map → input-BlNrkN6W.mjs.map} +1 -1
  82. package/dist/chunks/{label-D5csAh9b.mjs → label-BDU0LXe-.mjs} +2 -2
  83. package/dist/chunks/{label-D5csAh9b.mjs.map → label-BDU0LXe-.mjs.map} +1 -1
  84. package/dist/chunks/{pagination-BsXOOwtn.mjs → pagination-nctvfVO2.mjs} +2 -2
  85. package/dist/chunks/{pagination-BsXOOwtn.mjs.map → pagination-nctvfVO2.mjs.map} +1 -1
  86. package/dist/chunks/{popover-Dov1Buds.mjs → popover-BPna4ATX.mjs} +2 -2
  87. package/dist/chunks/{popover-Dov1Buds.mjs.map → popover-BPna4ATX.mjs.map} +1 -1
  88. package/dist/chunks/{progress-C3Y_Swsn.mjs → progress-D5dklJPH.mjs} +2 -2
  89. package/dist/chunks/{progress-C3Y_Swsn.mjs.map → progress-D5dklJPH.mjs.map} +1 -1
  90. package/dist/chunks/{scroll-area-DW059l0P.mjs → scroll-area-BUsoZk7w.mjs} +2 -2
  91. package/dist/chunks/{scroll-area-DW059l0P.mjs.map → scroll-area-BUsoZk7w.mjs.map} +1 -1
  92. package/dist/chunks/{select-vTAesIVv.mjs → select-Dsju3pcN.mjs} +2 -2
  93. package/dist/chunks/{select-vTAesIVv.mjs.map → select-Dsju3pcN.mjs.map} +1 -1
  94. package/dist/chunks/{separator-20h7d7UI.mjs → separator-yvrmazzo.mjs} +2 -2
  95. package/dist/chunks/{separator-20h7d7UI.mjs.map → separator-yvrmazzo.mjs.map} +1 -1
  96. package/dist/chunks/{skeleton-B4z6D5eV.mjs → skeleton-CgM54DVd.mjs} +2 -2
  97. package/dist/chunks/{skeleton-B4z6D5eV.mjs.map → skeleton-CgM54DVd.mjs.map} +1 -1
  98. package/dist/chunks/{sortable-D7jRCUMx.mjs → sortable-r5LNLyFY.mjs} +2 -2
  99. package/dist/chunks/{sortable-D7jRCUMx.mjs.map → sortable-r5LNLyFY.mjs.map} +1 -1
  100. package/dist/chunks/{table-CvqlUil9.mjs → table-C7HL2RQX.mjs} +2 -2
  101. package/dist/chunks/{table-CvqlUil9.mjs.map → table-C7HL2RQX.mjs.map} +1 -1
  102. package/dist/chunks/{toggle-BsT2kdMw.mjs → toggle-BNsCXJfn.mjs} +2 -2
  103. package/dist/chunks/{toggle-BsT2kdMw.mjs.map → toggle-BNsCXJfn.mjs.map} +1 -1
  104. package/dist/chunks/{tslib.es6-CISrQAm2.mjs → tslib.es6-BPlpgYSG.mjs} +1 -1
  105. package/dist/chunks/{tslib.es6-CISrQAm2.mjs.map → tslib.es6-BPlpgYSG.mjs.map} +1 -1
  106. package/dist/chunks/{utils-Dp2SHrBW.mjs → utils-CplKzw61.mjs} +2 -2
  107. package/dist/chunks/{utils-Dp2SHrBW.mjs.map → utils-CplKzw61.mjs.map} +1 -1
  108. package/dist/chunks/x-CXgTi8Ya.mjs +2 -0
  109. package/dist/chunks/{x-CrlN9yY1.mjs.map → x-CXgTi8Ya.mjs.map} +1 -1
  110. package/dist/combobox/index.mjs +1 -1
  111. package/dist/command/index.mjs +1 -1
  112. package/dist/data-table/index.mjs +1 -1
  113. package/dist/dialog/index.mjs +1 -1
  114. package/dist/dropdown-menu/index.mjs +1 -1
  115. package/dist/dropdown-menu/index.mjs.map +1 -1
  116. package/dist/dropzone/index.mjs +1 -1
  117. package/dist/form/index.mjs +1 -1
  118. package/dist/hover-card/index.mjs +1 -1
  119. package/dist/icon/index.mjs +1 -1
  120. package/dist/index.css +1 -1
  121. package/dist/input/index.mjs +1 -1
  122. package/dist/ivt.css +1 -1
  123. package/dist/label/index.mjs +1 -1
  124. package/dist/menubar/index.d.ts +29 -0
  125. package/dist/menubar/index.mjs +2 -0
  126. package/dist/menubar/index.mjs.map +1 -0
  127. package/dist/multi-select/index.mjs +1 -1
  128. package/dist/pagination/index.mjs +1 -1
  129. package/dist/popover/index.mjs +1 -1
  130. package/dist/progress/index.mjs +1 -1
  131. package/dist/radio-group/index.d.ts +7 -1
  132. package/dist/radio-group/index.mjs +1 -1
  133. package/dist/radio-group/index.mjs.map +1 -1
  134. package/dist/scroll-area/index.mjs +1 -1
  135. package/dist/select/index.mjs +1 -1
  136. package/dist/separator/index.mjs +1 -1
  137. package/dist/sheet/index.mjs +1 -1
  138. package/dist/skeleton/index.mjs +1 -1
  139. package/dist/sortable/index.mjs +1 -1
  140. package/dist/table/index.mjs +1 -1
  141. package/dist/tabs/index.mjs +1 -1
  142. package/dist/textarea/index.d.ts +5 -1
  143. package/dist/textarea/index.mjs +1 -1
  144. package/dist/textarea/index.mjs.map +1 -1
  145. package/dist/toast/index.mjs +1 -1
  146. package/dist/toggle/index.mjs +1 -1
  147. package/dist/toggle-group/index.mjs +1 -1
  148. package/dist/tooltip/index.mjs +1 -1
  149. package/package.json +6 -1
  150. package/dist/chunks/check-XiDheatr.mjs +0 -2
  151. package/dist/chunks/chevron-down-B1yMwors.mjs +0 -2
  152. package/dist/chunks/chevron-left-HipRXZQ8.mjs +0 -2
  153. package/dist/chunks/chevron-right-BS1_kgp8.mjs +0 -2
  154. package/dist/chunks/x-CrlN9yY1.mjs +0 -2
@@ -1 +1 @@
1
- {"version":3,"file":"index-CgLDADnA.mjs","sources":["../../node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs"],"sourcesContent":["// packages/react/use-callback-ref/src/use-callback-ref.tsx\nimport * as React from \"react\";\nfunction useCallbackRef(callback) {\n const callbackRef = React.useRef(callback);\n React.useEffect(() => {\n callbackRef.current = callback;\n });\n return React.useMemo(() => (...args) => callbackRef.current?.(...args), []);\n}\nexport {\n useCallbackRef\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["useCallbackRef","callback","callbackRef","React","useRef","useEffect","current","useMemo","args"],"mappings":"wBAMA,SAASA,EAAkDC,GACzD,MAAMC,EAAoBC,EAAAC,OAAOH,GAOjC,OALME,EAAAE,UAAU,KACdH,EAAYI,QAAUL,IAIXE,EAAAI,QAAQ,IAAO,IAAIC,IAASN,EAAYI,aAAaE,GAAa,GACjF","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index-BJZ14-gh.mjs","sources":["../../node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs"],"sourcesContent":["// packages/react/use-callback-ref/src/use-callback-ref.tsx\nimport * as React from \"react\";\nfunction useCallbackRef(callback) {\n const callbackRef = React.useRef(callback);\n React.useEffect(() => {\n callbackRef.current = callback;\n });\n return React.useMemo(() => (...args) => callbackRef.current?.(...args), []);\n}\nexport {\n useCallbackRef\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["useCallbackRef","callback","callbackRef","React","useRef","useEffect","current","useMemo","args"],"mappings":"wBAMA,SAASA,EAAkDC,GACzD,MAAMC,EAAoBC,EAAAC,OAAOH,GAOjC,OALME,EAAAE,UAAU,KACdH,EAAYI,QAAUL,IAIXE,EAAAI,QAAQ,IAAO,IAAIC,IAASN,EAAYI,aAAaE,GAAa,GACjF","x_google_ignoreList":[0]}
@@ -1,2 +1,2 @@
1
- import*as t from"react";import{useLayoutEffect as e}from"react";import*as n from"react-dom";import{P as o}from"./index-Dxh10iPI.mjs";import{jsx as r}from"react/jsx-runtime";import{u as i}from"./index-fgRlmr40.mjs";import{c as a}from"./index-B70-2oxO.mjs";import{u as l}from"./index-CgLDADnA.mjs";import{u as s}from"./index-g_YR6VZJ.mjs";import{u as c}from"./index-DRqB8wXi.mjs";const f=["top","right","bottom","left"],u=Math.min,d=Math.max,p=Math.round,m=Math.floor,h=t=>({x:t,y:t}),g={left:"right",right:"left",bottom:"top",top:"bottom"},y={start:"end",end:"start"};function w(t,e,n){return d(t,u(e,n))}function x(t,e){return"function"==typeof t?t(e):t}function v(t){return t.split("-")[0]}function b(t){return t.split("-")[1]}function R(t){return"x"===t?"y":"x"}function A(t){return"y"===t?"height":"width"}const P=new Set(["top","bottom"]);function S(t){return P.has(v(t))?"y":"x"}function O(t){return R(S(t))}function T(t){return t.replace(/start|end/g,t=>y[t])}const L=["left","right"],C=["right","left"],E=["top","bottom"],D=["bottom","top"];function H(t,e,n,o){const r=b(t);let i=function(t,e,n){switch(t){case"top":case"bottom":return n?e?C:L:e?L:C;case"left":case"right":return e?E:D;default:return[]}}(v(t),"start"===n,o);return r&&(i=i.map(t=>t+"-"+r),e&&(i=i.concat(i.map(T)))),i}function k(t){return t.replace(/left|right|bottom|top/g,t=>g[t])}function F(t){return"number"!=typeof t?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(t):{top:t,right:t,bottom:t,left:t}}function W(t){const{x:e,y:n,width:o,height:r}=t;return{width:o,height:r,top:n,left:e,right:e+o,bottom:n+r,x:e,y:n}}function B(t,e,n){let{reference:o,floating:r}=t;const i=S(e),a=O(e),l=A(a),s=v(e),c="y"===i,f=o.x+o.width/2-r.width/2,u=o.y+o.height/2-r.height/2,d=o[l]/2-r[l]/2;let p;switch(s){case"top":p={x:f,y:o.y-r.height};break;case"bottom":p={x:f,y:o.y+o.height};break;case"right":p={x:o.x+o.width,y:u};break;case"left":p={x:o.x-r.width,y:u};break;default:p={x:o.x,y:o.y}}switch(b(e)){case"start":p[a]-=d*(n&&c?-1:1);break;case"end":p[a]+=d*(n&&c?-1:1)}return p}async function M(t,e){var n;void 0===e&&(e={});const{x:o,y:r,platform:i,rects:a,elements:l,strategy:s}=t,{boundary:c="clippingAncestors",rootBoundary:f="viewport",elementContext:u="floating",altBoundary:d=!1,padding:p=0}=x(e,t),m=F(p),h=l[d?"floating"===u?"reference":"floating":u],g=W(await i.getClippingRect({element:null==(n=await(null==i.isElement?void 0:i.isElement(h)))||n?h:h.contextElement||await(null==i.getDocumentElement?void 0:i.getDocumentElement(l.floating)),boundary:c,rootBoundary:f,strategy:s})),y="floating"===u?{x:o,y:r,width:a.floating.width,height:a.floating.height}:a.reference,w=await(null==i.getOffsetParent?void 0:i.getOffsetParent(l.floating)),v=await(null==i.isElement?void 0:i.isElement(w))&&await(null==i.getScale?void 0:i.getScale(w))||{x:1,y:1},b=W(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:y,offsetParent:w,strategy:s}):y);return{top:(g.top-b.top+m.top)/v.y,bottom:(b.bottom-g.bottom+m.bottom)/v.y,left:(g.left-b.left+m.left)/v.x,right:(b.right-g.right+m.right)/v.x}}function $(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function j(t){return f.some(e=>t[e]>=0)}const N=new Set(["left","top"]);function _(){return"undefined"!=typeof window}function z(t){return X(t)?(t.nodeName||"").toLowerCase():"#document"}function V(t){var e;return(null==t||null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function Y(t){var e;return null==(e=(X(t)?t.ownerDocument:t.document)||window.document)?void 0:e.documentElement}function X(t){return!!_()&&(t instanceof Node||t instanceof V(t).Node)}function I(t){return!!_()&&(t instanceof Element||t instanceof V(t).Element)}function q(t){return!!_()&&(t instanceof HTMLElement||t instanceof V(t).HTMLElement)}function G(t){return!(!_()||"undefined"==typeof ShadowRoot)&&(t instanceof ShadowRoot||t instanceof V(t).ShadowRoot)}const J=new Set(["inline","contents"]);function K(t){const{overflow:e,overflowX:n,overflowY:o,display:r}=st(t);return/auto|scroll|overlay|hidden|clip/.test(e+o+n)&&!J.has(r)}const Q=new Set(["table","td","th"]);function U(t){return Q.has(z(t))}const Z=[":popover-open",":modal"];function tt(t){return Z.some(e=>{try{return t.matches(e)}catch(t){return!1}})}const et=["transform","translate","scale","rotate","perspective"],nt=["transform","translate","scale","rotate","perspective","filter"],ot=["paint","layout","strict","content"];function rt(t){const e=it(),n=I(t)?st(t):t;return et.some(t=>!!n[t]&&"none"!==n[t])||!!n.containerType&&"normal"!==n.containerType||!e&&!!n.backdropFilter&&"none"!==n.backdropFilter||!e&&!!n.filter&&"none"!==n.filter||nt.some(t=>(n.willChange||"").includes(t))||ot.some(t=>(n.contain||"").includes(t))}function it(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}const at=new Set(["html","body","#document"]);function lt(t){return at.has(z(t))}function st(t){return V(t).getComputedStyle(t)}function ct(t){return I(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function ft(t){if("html"===z(t))return t;const e=t.assignedSlot||t.parentNode||G(t)&&t.host||Y(t);return G(e)?e.host:e}function ut(t){const e=ft(t);return lt(e)?t.ownerDocument?t.ownerDocument.body:t.body:q(e)&&K(e)?e:ut(e)}function dt(t,e,n){var o;void 0===e&&(e=[]),void 0===n&&(n=!0);const r=ut(t),i=r===(null==(o=t.ownerDocument)?void 0:o.body),a=V(r);if(i){const t=pt(a);return e.concat(a,a.visualViewport||[],K(r)?r:[],t&&n?dt(t):[])}return e.concat(r,dt(r,[],n))}function pt(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function mt(t){const e=st(t);let n=parseFloat(e.width)||0,o=parseFloat(e.height)||0;const r=q(t),i=r?t.offsetWidth:n,a=r?t.offsetHeight:o,l=p(n)!==i||p(o)!==a;return l&&(n=i,o=a),{width:n,height:o,$:l}}function ht(t){return I(t)?t:t.contextElement}function gt(t){const e=ht(t);if(!q(e))return h(1);const n=e.getBoundingClientRect(),{width:o,height:r,$:i}=mt(e);let a=(i?p(n.width):n.width)/o,l=(i?p(n.height):n.height)/r;return a&&Number.isFinite(a)||(a=1),l&&Number.isFinite(l)||(l=1),{x:a,y:l}}const yt=h(0);function wt(t){const e=V(t);return it()&&e.visualViewport?{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}:yt}function xt(t,e,n,o){void 0===e&&(e=!1),void 0===n&&(n=!1);const r=t.getBoundingClientRect(),i=ht(t);let a=h(1);e&&(o?I(o)&&(a=gt(o)):a=gt(t));const l=function(t,e,n){return void 0===e&&(e=!1),!(!n||e&&n!==V(t))&&e}(i,n,o)?wt(i):h(0);let s=(r.left+l.x)/a.x,c=(r.top+l.y)/a.y,f=r.width/a.x,u=r.height/a.y;if(i){const t=V(i),e=o&&I(o)?V(o):o;let n=t,r=pt(n);for(;r&&o&&e!==n;){const t=gt(r),e=r.getBoundingClientRect(),o=st(r),i=e.left+(r.clientLeft+parseFloat(o.paddingLeft))*t.x,a=e.top+(r.clientTop+parseFloat(o.paddingTop))*t.y;s*=t.x,c*=t.y,f*=t.x,u*=t.y,s+=i,c+=a,n=V(r),r=pt(n)}}return W({width:f,height:u,x:s,y:c})}function vt(t,e){const n=ct(t).scrollLeft;return e?e.left+n:xt(Y(t)).left+n}function bt(t,e,n){void 0===n&&(n=!1);const o=t.getBoundingClientRect();return{x:o.left+e.scrollLeft-(n?0:vt(t,o)),y:o.top+e.scrollTop}}const Rt=new Set(["absolute","fixed"]);function At(t,e,n){let o;if("viewport"===e)o=function(t,e){const n=V(t),o=Y(t),r=n.visualViewport;let i=o.clientWidth,a=o.clientHeight,l=0,s=0;if(r){i=r.width,a=r.height;const t=it();(!t||t&&"fixed"===e)&&(l=r.offsetLeft,s=r.offsetTop)}return{width:i,height:a,x:l,y:s}}(t,n);else if("document"===e)o=function(t){const e=Y(t),n=ct(t),o=t.ownerDocument.body,r=d(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),i=d(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight);let a=-n.scrollLeft+vt(t);const l=-n.scrollTop;return"rtl"===st(o).direction&&(a+=d(e.clientWidth,o.clientWidth)-r),{width:r,height:i,x:a,y:l}}(Y(t));else if(I(e))o=function(t,e){const n=xt(t,!0,"fixed"===e),o=n.top+t.clientTop,r=n.left+t.clientLeft,i=q(t)?gt(t):h(1);return{width:t.clientWidth*i.x,height:t.clientHeight*i.y,x:r*i.x,y:o*i.y}}(e,n);else{const n=wt(t);o={x:e.x-n.x,y:e.y-n.y,width:e.width,height:e.height}}return W(o)}function Pt(t,e){const n=ft(t);return!(n===e||!I(n)||lt(n))&&("fixed"===st(n).position||Pt(n,e))}function St(t,e,n){const o=q(e),r=Y(e),i="fixed"===n,a=xt(t,!0,i,e);let l={scrollLeft:0,scrollTop:0};const s=h(0);function c(){s.x=vt(r)}if(o||!o&&!i)if(("body"!==z(e)||K(r))&&(l=ct(e)),o){const t=xt(e,!0,i,e);s.x=t.x+e.clientLeft,s.y=t.y+e.clientTop}else r&&c();i&&!o&&r&&c();const f=!r||o||i?h(0):bt(r,l);return{x:a.left+l.scrollLeft-s.x-f.x,y:a.top+l.scrollTop-s.y-f.y,width:a.width,height:a.height}}function Ot(t){return"static"===st(t).position}function Tt(t,e){if(!q(t)||"fixed"===st(t).position)return null;if(e)return e(t);let n=t.offsetParent;return Y(t)===n&&(n=n.ownerDocument.body),n}function Lt(t,e){const n=V(t);if(tt(t))return n;if(!q(t)){let e=ft(t);for(;e&&!lt(e);){if(I(e)&&!Ot(e))return e;e=ft(e)}return n}let o=Tt(t,e);for(;o&&U(o)&&Ot(o);)o=Tt(o,e);return o&&lt(o)&&Ot(o)&&!rt(o)?n:o||function(t){let e=ft(t);for(;q(e)&&!lt(e);){if(rt(e))return e;if(tt(e))return null;e=ft(e)}return null}(t)||n}const Ct={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{elements:e,rect:n,offsetParent:o,strategy:r}=t;const i="fixed"===r,a=Y(o),l=!!e&&tt(e.floating);if(o===a||l&&i)return n;let s={scrollLeft:0,scrollTop:0},c=h(1);const f=h(0),u=q(o);if((u||!u&&!i)&&(("body"!==z(o)||K(a))&&(s=ct(o)),q(o))){const t=xt(o);c=gt(o),f.x=t.x+o.clientLeft,f.y=t.y+o.clientTop}const d=!a||u||i?h(0):bt(a,s,!0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-s.scrollLeft*c.x+f.x+d.x,y:n.y*c.y-s.scrollTop*c.y+f.y+d.y}},getDocumentElement:Y,getClippingRect:function(t){let{element:e,boundary:n,rootBoundary:o,strategy:r}=t;const i=[..."clippingAncestors"===n?tt(e)?[]:function(t,e){const n=e.get(t);if(n)return n;let o=dt(t,[],!1).filter(t=>I(t)&&"body"!==z(t)),r=null;const i="fixed"===st(t).position;let a=i?ft(t):t;for(;I(a)&&!lt(a);){const e=st(a),n=rt(a);n||"fixed"!==e.position||(r=null),(i?!n&&!r:!n&&"static"===e.position&&r&&Rt.has(r.position)||K(a)&&!n&&Pt(t,a))?o=o.filter(t=>t!==a):r=e,a=ft(a)}return e.set(t,o),o}(e,this._c):[].concat(n),o],a=i[0],l=i.reduce((t,n)=>{const o=At(e,n,r);return t.top=d(o.top,t.top),t.right=u(o.right,t.right),t.bottom=u(o.bottom,t.bottom),t.left=d(o.left,t.left),t},At(e,a,r));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},getOffsetParent:Lt,getElementRects:async function(t){const e=this.getOffsetParent||Lt,n=this.getDimensions,o=await n(t.floating);return{reference:St(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}},getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){const{width:e,height:n}=mt(t);return{width:e,height:n}},getScale:gt,isElement:I,isRTL:function(t){return"rtl"===st(t).direction}};function Et(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function Dt(t,e,n,o){void 0===o&&(o={});const{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:s=!1}=o,c=ht(t),f=r||i?[...c?dt(c):[],...dt(e)]:[];f.forEach(t=>{r&&t.addEventListener("scroll",n,{passive:!0}),i&&t.addEventListener("resize",n)});const p=c&&l?function(t,e){let n,o=null;const r=Y(t);function i(){var t;clearTimeout(n),null==(t=o)||t.disconnect(),o=null}return function a(l,s){void 0===l&&(l=!1),void 0===s&&(s=1),i();const c=t.getBoundingClientRect(),{left:f,top:p,width:h,height:g}=c;if(l||e(),!h||!g)return;const y={rootMargin:-m(p)+"px "+-m(r.clientWidth-(f+h))+"px "+-m(r.clientHeight-(p+g))+"px "+-m(f)+"px",threshold:d(0,u(1,s))||1};let w=!0;function x(e){const o=e[0].intersectionRatio;if(o!==s){if(!w)return a();o?a(!1,o):n=setTimeout(()=>{a(!1,1e-7)},1e3)}1!==o||Et(c,t.getBoundingClientRect())||a(),w=!1}try{o=new IntersectionObserver(x,{...y,root:r.ownerDocument})}catch(t){o=new IntersectionObserver(x,y)}o.observe(t)}(!0),i}(c,n):null;let h,g=-1,y=null;a&&(y=new ResizeObserver(t=>{let[o]=t;o&&o.target===c&&y&&(y.unobserve(e),cancelAnimationFrame(g),g=requestAnimationFrame(()=>{var t;null==(t=y)||t.observe(e)})),n()}),c&&!s&&y.observe(c),y.observe(e));let w=s?xt(t):null;return s&&function e(){const o=xt(t);w&&!Et(w,o)&&n();w=o,h=requestAnimationFrame(e)}(),n(),()=>{var t;f.forEach(t=>{r&&t.removeEventListener("scroll",n),i&&t.removeEventListener("resize",n)}),null==p||p(),null==(t=y)||t.disconnect(),y=null,s&&cancelAnimationFrame(h)}}const Ht=function(t){return void 0===t&&(t=0),{name:"offset",options:t,async fn(e){var n,o;const{x:r,y:i,placement:a,middlewareData:l}=e,s=await async function(t,e){const{placement:n,platform:o,elements:r}=t,i=await(null==o.isRTL?void 0:o.isRTL(r.floating)),a=v(n),l=b(n),s="y"===S(n),c=N.has(a)?-1:1,f=i&&s?-1:1,u=x(e,t);let{mainAxis:d,crossAxis:p,alignmentAxis:m}="number"==typeof u?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return l&&"number"==typeof m&&(p="end"===l?-1*m:m),s?{x:p*f,y:d*c}:{x:d*c,y:p*f}}(e,t);return a===(null==(n=l.offset)?void 0:n.placement)&&null!=(o=l.arrow)&&o.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},kt=function(t){return void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:o,placement:r}=e,{mainAxis:i=!0,crossAxis:a=!1,limiter:l={fn:t=>{let{x:e,y:n}=t;return{x:e,y:n}}},...s}=x(t,e),c={x:n,y:o},f=await M(e,s),u=S(v(r)),d=R(u);let p=c[d],m=c[u];if(i){const t="y"===d?"bottom":"right";p=w(p+f["y"===d?"top":"left"],p,p-f[t])}if(a){const t="y"===u?"bottom":"right";m=w(m+f["y"===u?"top":"left"],m,m-f[t])}const h=l.fn({...e,[d]:p,[u]:m});return{...h,data:{x:h.x-n,y:h.y-o,enabled:{[d]:i,[u]:a}}}}}},Ft=function(t){return void 0===t&&(t={}),{name:"flip",options:t,async fn(e){var n,o;const{placement:r,middlewareData:i,rects:a,initialPlacement:l,platform:s,elements:c}=e,{mainAxis:f=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:h=!0,...g}=x(t,e);if(null!=(n=i.arrow)&&n.alignmentOffset)return{};const y=v(r),w=S(l),R=v(l)===l,P=await(null==s.isRTL?void 0:s.isRTL(c.floating)),L=d||(R||!h?[k(l)]:function(t){const e=k(t);return[T(t),e,T(e)]}(l)),C="none"!==m;!d&&C&&L.push(...H(l,h,m,P));const E=[l,...L],D=await M(e,g),F=[];let W=(null==(o=i.flip)?void 0:o.overflows)||[];if(f&&F.push(D[y]),u){const t=function(t,e,n){void 0===n&&(n=!1);const o=b(t),r=O(t),i=A(r);let a="x"===r?o===(n?"end":"start")?"right":"left":"start"===o?"bottom":"top";return e.reference[i]>e.floating[i]&&(a=k(a)),[a,k(a)]}(r,a,P);F.push(D[t[0]],D[t[1]])}if(W=[...W,{placement:r,overflows:F}],!F.every(t=>t<=0)){var B,$;const t=((null==(B=i.flip)?void 0:B.index)||0)+1,e=E[t];if(e){if(!("alignment"===u&&w!==S(e))||W.every(t=>t.overflows[0]>0&&S(t.placement)===w))return{data:{index:t,overflows:W},reset:{placement:e}}}let n=null==($=W.filter(t=>t.overflows[0]<=0).sort((t,e)=>t.overflows[1]-e.overflows[1])[0])?void 0:$.placement;if(!n)switch(p){case"bestFit":{var j;const t=null==(j=W.filter(t=>{if(C){const e=S(t.placement);return e===w||"y"===e}return!0}).map(t=>[t.placement,t.overflows.filter(t=>t>0).reduce((t,e)=>t+e,0)]).sort((t,e)=>t[1]-e[1])[0])?void 0:j[0];t&&(n=t);break}case"initialPlacement":n=l}if(r!==n)return{reset:{placement:n}}}return{}}}},Wt=function(t){return void 0===t&&(t={}),{name:"size",options:t,async fn(e){var n,o;const{placement:r,rects:i,platform:a,elements:l}=e,{apply:s=()=>{},...c}=x(t,e),f=await M(e,c),p=v(r),m=b(r),h="y"===S(r),{width:g,height:y}=i.floating;let w,R;"top"===p||"bottom"===p?(w=p,R=m===(await(null==a.isRTL?void 0:a.isRTL(l.floating))?"start":"end")?"left":"right"):(R=p,w="end"===m?"top":"bottom");const A=y-f.top-f.bottom,P=g-f.left-f.right,O=u(y-f[w],A),T=u(g-f[R],P),L=!e.middlewareData.shift;let C=O,E=T;if(null!=(n=e.middlewareData.shift)&&n.enabled.x&&(E=P),null!=(o=e.middlewareData.shift)&&o.enabled.y&&(C=A),L&&!m){const t=d(f.left,0),e=d(f.right,0),n=d(f.top,0),o=d(f.bottom,0);h?E=g-2*(0!==t||0!==e?t+e:d(f.left,f.right)):C=y-2*(0!==n||0!==o?n+o:d(f.top,f.bottom))}await s({...e,availableWidth:E,availableHeight:C});const D=await a.getDimensions(l.floating);return g!==D.width||y!==D.height?{reset:{rects:!0}}:{}}}},Bt=function(t){return void 0===t&&(t={}),{name:"hide",options:t,async fn(e){const{rects:n}=e,{strategy:o="referenceHidden",...r}=x(t,e);switch(o){case"referenceHidden":{const t=$(await M(e,{...r,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:t,referenceHidden:j(t)}}}case"escaped":{const t=$(await M(e,{...r,altBoundary:!0}),n.floating);return{data:{escapedOffsets:t,escaped:j(t)}}}default:return{}}}}},Mt=t=>({name:"arrow",options:t,async fn(e){const{x:n,y:o,placement:r,rects:i,platform:a,elements:l,middlewareData:s}=e,{element:c,padding:f=0}=x(t,e)||{};if(null==c)return{};const d=F(f),p={x:n,y:o},m=O(r),h=A(m),g=await a.getDimensions(c),y="y"===m,v=y?"top":"left",R=y?"bottom":"right",P=y?"clientHeight":"clientWidth",S=i.reference[h]+i.reference[m]-p[m]-i.floating[h],T=p[m]-i.reference[m],L=await(null==a.getOffsetParent?void 0:a.getOffsetParent(c));let C=L?L[P]:0;C&&await(null==a.isElement?void 0:a.isElement(L))||(C=l.floating[P]||i.floating[h]);const E=S/2-T/2,D=C/2-g[h]/2-1,H=u(d[v],D),k=u(d[R],D),W=H,B=C-g[h]-k,M=C/2-g[h]/2+E,$=w(W,M,B),j=!s.arrow&&null!=b(r)&&M!==$&&i.reference[h]/2-(M<W?H:k)-g[h]/2<0,N=j?M<W?M-W:M-B:0;return{[m]:p[m]+N,data:{[m]:$,centerOffset:M-$-N,...j&&{alignmentOffset:N}},reset:j}}}),$t=function(t){return void 0===t&&(t={}),{options:t,fn(e){const{x:n,y:o,placement:r,rects:i,middlewareData:a}=e,{offset:l=0,mainAxis:s=!0,crossAxis:c=!0}=x(t,e),f={x:n,y:o},u=S(r),d=R(u);let p=f[d],m=f[u];const h=x(l,e),g="number"==typeof h?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(s){const t="y"===d?"height":"width",e=i.reference[d]-i.floating[t]+g.mainAxis,n=i.reference[d]+i.reference[t]-g.mainAxis;p<e?p=e:p>n&&(p=n)}if(c){var y,w;const t="y"===d?"width":"height",e=N.has(v(r)),n=i.reference[u]-i.floating[t]+(e&&(null==(y=a.offset)?void 0:y[u])||0)+(e?0:g.crossAxis),o=i.reference[u]+i.reference[t]+(e?0:(null==(w=a.offset)?void 0:w[u])||0)-(e?g.crossAxis:0);m<n?m=n:m>o&&(m=o)}return{[d]:p,[u]:m}}}},jt=(t,e,n)=>{const o=new Map,r={platform:Ct,...n},i={...r.platform,_c:o};return(async(t,e,n)=>{const{placement:o="bottom",strategy:r="absolute",middleware:i=[],platform:a}=n,l=i.filter(Boolean),s=await(null==a.isRTL?void 0:a.isRTL(e));let c=await a.getElementRects({reference:t,floating:e,strategy:r}),{x:f,y:u}=B(c,o,s),d=o,p={},m=0;for(let n=0;n<l.length;n++){const{name:i,fn:h}=l[n],{x:g,y:y,data:w,reset:x}=await h({x:f,y:u,initialPlacement:o,placement:d,strategy:r,middlewareData:p,rects:c,platform:a,elements:{reference:t,floating:e}});f=null!=g?g:f,u=null!=y?y:u,p={...p,[i]:{...p[i],...w}},x&&m<=50&&(m++,"object"==typeof x&&(x.placement&&(d=x.placement),x.rects&&(c=!0===x.rects?await a.getElementRects({reference:t,floating:e,strategy:r}):x.rects),({x:f,y:u}=B(c,d,s))),n=-1)}return{x:f,y:u,placement:d,strategy:r,middlewareData:p}})(t,e,{...r,platform:i})};var Nt="undefined"!=typeof document?e:function(){};function _t(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if("function"==typeof t&&t.toString()===e.toString())return!0;let n,o,r;if(t&&e&&"object"==typeof t){if(Array.isArray(t)){if(n=t.length,n!==e.length)return!1;for(o=n;0!==o--;)if(!_t(t[o],e[o]))return!1;return!0}if(r=Object.keys(t),n=r.length,n!==Object.keys(e).length)return!1;for(o=n;0!==o--;)if(!{}.hasOwnProperty.call(e,r[o]))return!1;for(o=n;0!==o--;){const n=r[o];if(("_owner"!==n||!t.$$typeof)&&!_t(t[n],e[n]))return!1}return!0}return t!=t&&e!=e}function zt(t){if("undefined"==typeof window)return 1;return(t.ownerDocument.defaultView||window).devicePixelRatio||1}function Vt(t,e){const n=zt(t);return Math.round(e*n)/n}function Yt(e){const n=t.useRef(e);return Nt(()=>{n.current=e}),n}const Xt=t=>({name:"arrow",options:t,fn(e){const{element:n,padding:o}="function"==typeof t?t(e):t;return n&&(r=n,{}.hasOwnProperty.call(r,"current"))?null!=n.current?Mt({element:n.current,padding:o}).fn(e):{}:n?Mt({element:n,padding:o}).fn(e):{};var r}}),It=(t,e)=>({...kt(t),options:[t,e]}),qt=(t,e)=>({...$t(t),options:[t,e]}),Gt=(t,e)=>({...Ft(t),options:[t,e]}),Jt=(t,e)=>({...Wt(t),options:[t,e]}),Kt=(t,e)=>({...Bt(t),options:[t,e]}),Qt=(t,e)=>({...Xt(t),options:[t,e]});var Ut=t.forwardRef((t,e)=>{const{children:n,width:i=10,height:a=5,...l}=t;return r(o.svg,{...l,ref:e,width:i,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:t.asChild?n:r("polygon",{points:"0,0 30,0 15,10"})})});Ut.displayName="Arrow";var Zt=Ut,te="Popper",[ee,ne]=a(te),[oe,re]=ee(te),ie=e=>{const{__scopePopper:n,children:o}=e,[i,a]=t.useState(null);return r(oe,{scope:n,anchor:i,onAnchorChange:a,children:o})};ie.displayName=te;var ae="PopperAnchor",le=t.forwardRef((e,n)=>{const{__scopePopper:a,virtualRef:l,...s}=e,c=re(ae,a),f=t.useRef(null),u=i(n,f);return t.useEffect(()=>{c.onAnchorChange(l?.current||f.current)}),l?null:r(o.div,{...s,ref:u})});le.displayName=ae;var se="PopperContent",[ce,fe]=ee(se),ue=t.forwardRef((e,a)=>{const{__scopePopper:f,side:u="bottom",sideOffset:d=0,align:p="center",alignOffset:m=0,arrowPadding:h=0,avoidCollisions:g=!0,collisionBoundary:y=[],collisionPadding:w=0,sticky:x="partial",hideWhenDetached:v=!1,updatePositionStrategy:b="optimized",onPlaced:R,...A}=e,P=re(se,f),[S,O]=t.useState(null),T=i(a,t=>O(t)),[L,C]=t.useState(null),E=c(L),D=E?.width??0,H=E?.height??0,k=u+("center"!==p?"-"+p:""),F="number"==typeof w?w:{top:0,right:0,bottom:0,left:0,...w},W=Array.isArray(y)?y:[y],B=W.length>0,M={padding:F,boundary:W.filter(he),altBoundary:B},{refs:$,floatingStyles:j,placement:N,isPositioned:_,middlewareData:z}=function(e){void 0===e&&(e={});const{placement:o="bottom",strategy:r="absolute",middleware:i=[],platform:a,elements:{reference:l,floating:s}={},transform:c=!0,whileElementsMounted:f,open:u}=e,[d,p]=t.useState({x:0,y:0,strategy:r,placement:o,middlewareData:{},isPositioned:!1}),[m,h]=t.useState(i);_t(m,i)||h(i);const[g,y]=t.useState(null),[w,x]=t.useState(null),v=t.useCallback(t=>{t!==P.current&&(P.current=t,y(t))},[]),b=t.useCallback(t=>{t!==S.current&&(S.current=t,x(t))},[]),R=l||g,A=s||w,P=t.useRef(null),S=t.useRef(null),O=t.useRef(d),T=null!=f,L=Yt(f),C=Yt(a),E=Yt(u),D=t.useCallback(()=>{if(!P.current||!S.current)return;const t={placement:o,strategy:r,middleware:m};C.current&&(t.platform=C.current),jt(P.current,S.current,t).then(t=>{const e={...t,isPositioned:!1!==E.current};H.current&&!_t(O.current,e)&&(O.current=e,n.flushSync(()=>{p(e)}))})},[m,o,r,C,E]);Nt(()=>{!1===u&&O.current.isPositioned&&(O.current.isPositioned=!1,p(t=>({...t,isPositioned:!1})))},[u]);const H=t.useRef(!1);Nt(()=>(H.current=!0,()=>{H.current=!1}),[]),Nt(()=>{if(R&&(P.current=R),A&&(S.current=A),R&&A){if(L.current)return L.current(R,A,D);D()}},[R,A,D,L,T]);const k=t.useMemo(()=>({reference:P,floating:S,setReference:v,setFloating:b}),[v,b]),F=t.useMemo(()=>({reference:R,floating:A}),[R,A]),W=t.useMemo(()=>{const t={position:r,left:0,top:0};if(!F.floating)return t;const e=Vt(F.floating,d.x),n=Vt(F.floating,d.y);return c?{...t,transform:"translate("+e+"px, "+n+"px)",...zt(F.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:e,top:n}},[r,c,F.floating,d.x,d.y]);return t.useMemo(()=>({...d,update:D,refs:k,elements:F,floatingStyles:W}),[d,D,k,F,W])}({strategy:"fixed",placement:k,whileElementsMounted:(...t)=>Dt(...t,{animationFrame:"always"===b}),elements:{reference:P.anchor},middleware:[(V={mainAxis:d+H,alignmentAxis:m},{...Ht(V),options:[V,Y]}),g&&It({mainAxis:!0,crossAxis:!1,limiter:"partial"===x?qt():void 0,...M}),g&&Gt({...M}),Jt({...M,apply:({elements:t,rects:e,availableWidth:n,availableHeight:o})=>{const{width:r,height:i}=e.reference,a=t.floating.style;a.setProperty("--radix-popper-available-width",`${n}px`),a.setProperty("--radix-popper-available-height",`${o}px`),a.setProperty("--radix-popper-anchor-width",`${r}px`),a.setProperty("--radix-popper-anchor-height",`${i}px`)}}),L&&Qt({element:L,padding:h}),ge({arrowWidth:D,arrowHeight:H}),v&&Kt({strategy:"referenceHidden",...M})]});var V,Y;const[X,I]=ye(N),q=l(R);s(()=>{_&&q?.()},[_,q]);const G=z.arrow?.x,J=z.arrow?.y,K=0!==z.arrow?.centerOffset,[Q,U]=t.useState();return s(()=>{S&&U(window.getComputedStyle(S).zIndex)},[S]),r("div",{ref:$.setFloating,"data-radix-popper-content-wrapper":"",style:{...j,transform:_?j.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Q,"--radix-popper-transform-origin":[z.transformOrigin?.x,z.transformOrigin?.y].join(" "),...z.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:r(ce,{scope:f,placedSide:X,onArrowChange:C,arrowX:G,arrowY:J,shouldHideArrow:K,children:r(o.div,{"data-side":X,"data-align":I,...A,ref:T,style:{...A.style,animation:_?void 0:"none"}})})})});ue.displayName=se;var de="PopperArrow",pe={top:"bottom",right:"left",bottom:"top",left:"right"},me=t.forwardRef(function(t,e){const{__scopePopper:n,...o}=t,i=fe(de,n),a=pe[i.placedSide];return r("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0},children:r(Zt,{...o,ref:e,style:{...o.style,display:"block"}})})});function he(t){return null!==t}me.displayName=de;var ge=t=>({name:"transformOrigin",options:t,fn(e){const{placement:n,rects:o,middlewareData:r}=e,i=0!==r.arrow?.centerOffset,a=i?0:t.arrowWidth,l=i?0:t.arrowHeight,[s,c]=ye(n),f={start:"0%",center:"50%",end:"100%"}[c],u=(r.arrow?.x??0)+a/2,d=(r.arrow?.y??0)+l/2;let p="",m="";return"bottom"===s?(p=i?f:`${u}px`,m=-l+"px"):"top"===s?(p=i?f:`${u}px`,m=`${o.floating.height+l}px`):"right"===s?(p=-l+"px",m=i?f:`${d}px`):"left"===s&&(p=`${o.floating.width+l}px`,m=i?f:`${d}px`),{data:{x:p,y:m}}}});function ye(t){const[e,n="center"]=t.split("-");return[e,n]}var we=ie,xe=le,ve=ue,be=me;export{xe as A,ve as C,we as R,be as a,ne as c};
2
- //# sourceMappingURL=index-B_x_ais9.mjs.map
1
+ import*as t from"react";import{useLayoutEffect as e}from"react";import*as n from"react-dom";import{P as o}from"./index-CZMSgrEB.mjs";import{jsx as r}from"react/jsx-runtime";import{u as i}from"./index-C3QHFNp7.mjs";import{c as a}from"./index-BO-2wsZH.mjs";import{u as l}from"./index-BJZ14-gh.mjs";import{u as s}from"./index-DtAARIfz.mjs";import{u as c}from"./index-C20HgOT7.mjs";const f=["top","right","bottom","left"],u=Math.min,d=Math.max,p=Math.round,m=Math.floor,h=t=>({x:t,y:t}),g={left:"right",right:"left",bottom:"top",top:"bottom"},y={start:"end",end:"start"};function w(t,e,n){return d(t,u(e,n))}function x(t,e){return"function"==typeof t?t(e):t}function v(t){return t.split("-")[0]}function b(t){return t.split("-")[1]}function R(t){return"x"===t?"y":"x"}function A(t){return"y"===t?"height":"width"}const P=new Set(["top","bottom"]);function S(t){return P.has(v(t))?"y":"x"}function O(t){return R(S(t))}function T(t){return t.replace(/start|end/g,t=>y[t])}const L=["left","right"],C=["right","left"],E=["top","bottom"],D=["bottom","top"];function H(t,e,n,o){const r=b(t);let i=function(t,e,n){switch(t){case"top":case"bottom":return n?e?C:L:e?L:C;case"left":case"right":return e?E:D;default:return[]}}(v(t),"start"===n,o);return r&&(i=i.map(t=>t+"-"+r),e&&(i=i.concat(i.map(T)))),i}function k(t){return t.replace(/left|right|bottom|top/g,t=>g[t])}function F(t){return"number"!=typeof t?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(t):{top:t,right:t,bottom:t,left:t}}function W(t){const{x:e,y:n,width:o,height:r}=t;return{width:o,height:r,top:n,left:e,right:e+o,bottom:n+r,x:e,y:n}}function B(t,e,n){let{reference:o,floating:r}=t;const i=S(e),a=O(e),l=A(a),s=v(e),c="y"===i,f=o.x+o.width/2-r.width/2,u=o.y+o.height/2-r.height/2,d=o[l]/2-r[l]/2;let p;switch(s){case"top":p={x:f,y:o.y-r.height};break;case"bottom":p={x:f,y:o.y+o.height};break;case"right":p={x:o.x+o.width,y:u};break;case"left":p={x:o.x-r.width,y:u};break;default:p={x:o.x,y:o.y}}switch(b(e)){case"start":p[a]-=d*(n&&c?-1:1);break;case"end":p[a]+=d*(n&&c?-1:1)}return p}async function M(t,e){var n;void 0===e&&(e={});const{x:o,y:r,platform:i,rects:a,elements:l,strategy:s}=t,{boundary:c="clippingAncestors",rootBoundary:f="viewport",elementContext:u="floating",altBoundary:d=!1,padding:p=0}=x(e,t),m=F(p),h=l[d?"floating"===u?"reference":"floating":u],g=W(await i.getClippingRect({element:null==(n=await(null==i.isElement?void 0:i.isElement(h)))||n?h:h.contextElement||await(null==i.getDocumentElement?void 0:i.getDocumentElement(l.floating)),boundary:c,rootBoundary:f,strategy:s})),y="floating"===u?{x:o,y:r,width:a.floating.width,height:a.floating.height}:a.reference,w=await(null==i.getOffsetParent?void 0:i.getOffsetParent(l.floating)),v=await(null==i.isElement?void 0:i.isElement(w))&&await(null==i.getScale?void 0:i.getScale(w))||{x:1,y:1},b=W(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:y,offsetParent:w,strategy:s}):y);return{top:(g.top-b.top+m.top)/v.y,bottom:(b.bottom-g.bottom+m.bottom)/v.y,left:(g.left-b.left+m.left)/v.x,right:(b.right-g.right+m.right)/v.x}}function $(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function j(t){return f.some(e=>t[e]>=0)}const N=new Set(["left","top"]);function _(){return"undefined"!=typeof window}function z(t){return X(t)?(t.nodeName||"").toLowerCase():"#document"}function V(t){var e;return(null==t||null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function Y(t){var e;return null==(e=(X(t)?t.ownerDocument:t.document)||window.document)?void 0:e.documentElement}function X(t){return!!_()&&(t instanceof Node||t instanceof V(t).Node)}function I(t){return!!_()&&(t instanceof Element||t instanceof V(t).Element)}function q(t){return!!_()&&(t instanceof HTMLElement||t instanceof V(t).HTMLElement)}function G(t){return!(!_()||"undefined"==typeof ShadowRoot)&&(t instanceof ShadowRoot||t instanceof V(t).ShadowRoot)}const J=new Set(["inline","contents"]);function K(t){const{overflow:e,overflowX:n,overflowY:o,display:r}=st(t);return/auto|scroll|overlay|hidden|clip/.test(e+o+n)&&!J.has(r)}const Q=new Set(["table","td","th"]);function U(t){return Q.has(z(t))}const Z=[":popover-open",":modal"];function tt(t){return Z.some(e=>{try{return t.matches(e)}catch(t){return!1}})}const et=["transform","translate","scale","rotate","perspective"],nt=["transform","translate","scale","rotate","perspective","filter"],ot=["paint","layout","strict","content"];function rt(t){const e=it(),n=I(t)?st(t):t;return et.some(t=>!!n[t]&&"none"!==n[t])||!!n.containerType&&"normal"!==n.containerType||!e&&!!n.backdropFilter&&"none"!==n.backdropFilter||!e&&!!n.filter&&"none"!==n.filter||nt.some(t=>(n.willChange||"").includes(t))||ot.some(t=>(n.contain||"").includes(t))}function it(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}const at=new Set(["html","body","#document"]);function lt(t){return at.has(z(t))}function st(t){return V(t).getComputedStyle(t)}function ct(t){return I(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function ft(t){if("html"===z(t))return t;const e=t.assignedSlot||t.parentNode||G(t)&&t.host||Y(t);return G(e)?e.host:e}function ut(t){const e=ft(t);return lt(e)?t.ownerDocument?t.ownerDocument.body:t.body:q(e)&&K(e)?e:ut(e)}function dt(t,e,n){var o;void 0===e&&(e=[]),void 0===n&&(n=!0);const r=ut(t),i=r===(null==(o=t.ownerDocument)?void 0:o.body),a=V(r);if(i){const t=pt(a);return e.concat(a,a.visualViewport||[],K(r)?r:[],t&&n?dt(t):[])}return e.concat(r,dt(r,[],n))}function pt(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function mt(t){const e=st(t);let n=parseFloat(e.width)||0,o=parseFloat(e.height)||0;const r=q(t),i=r?t.offsetWidth:n,a=r?t.offsetHeight:o,l=p(n)!==i||p(o)!==a;return l&&(n=i,o=a),{width:n,height:o,$:l}}function ht(t){return I(t)?t:t.contextElement}function gt(t){const e=ht(t);if(!q(e))return h(1);const n=e.getBoundingClientRect(),{width:o,height:r,$:i}=mt(e);let a=(i?p(n.width):n.width)/o,l=(i?p(n.height):n.height)/r;return a&&Number.isFinite(a)||(a=1),l&&Number.isFinite(l)||(l=1),{x:a,y:l}}const yt=h(0);function wt(t){const e=V(t);return it()&&e.visualViewport?{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}:yt}function xt(t,e,n,o){void 0===e&&(e=!1),void 0===n&&(n=!1);const r=t.getBoundingClientRect(),i=ht(t);let a=h(1);e&&(o?I(o)&&(a=gt(o)):a=gt(t));const l=function(t,e,n){return void 0===e&&(e=!1),!(!n||e&&n!==V(t))&&e}(i,n,o)?wt(i):h(0);let s=(r.left+l.x)/a.x,c=(r.top+l.y)/a.y,f=r.width/a.x,u=r.height/a.y;if(i){const t=V(i),e=o&&I(o)?V(o):o;let n=t,r=pt(n);for(;r&&o&&e!==n;){const t=gt(r),e=r.getBoundingClientRect(),o=st(r),i=e.left+(r.clientLeft+parseFloat(o.paddingLeft))*t.x,a=e.top+(r.clientTop+parseFloat(o.paddingTop))*t.y;s*=t.x,c*=t.y,f*=t.x,u*=t.y,s+=i,c+=a,n=V(r),r=pt(n)}}return W({width:f,height:u,x:s,y:c})}function vt(t,e){const n=ct(t).scrollLeft;return e?e.left+n:xt(Y(t)).left+n}function bt(t,e,n){void 0===n&&(n=!1);const o=t.getBoundingClientRect();return{x:o.left+e.scrollLeft-(n?0:vt(t,o)),y:o.top+e.scrollTop}}const Rt=new Set(["absolute","fixed"]);function At(t,e,n){let o;if("viewport"===e)o=function(t,e){const n=V(t),o=Y(t),r=n.visualViewport;let i=o.clientWidth,a=o.clientHeight,l=0,s=0;if(r){i=r.width,a=r.height;const t=it();(!t||t&&"fixed"===e)&&(l=r.offsetLeft,s=r.offsetTop)}return{width:i,height:a,x:l,y:s}}(t,n);else if("document"===e)o=function(t){const e=Y(t),n=ct(t),o=t.ownerDocument.body,r=d(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),i=d(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight);let a=-n.scrollLeft+vt(t);const l=-n.scrollTop;return"rtl"===st(o).direction&&(a+=d(e.clientWidth,o.clientWidth)-r),{width:r,height:i,x:a,y:l}}(Y(t));else if(I(e))o=function(t,e){const n=xt(t,!0,"fixed"===e),o=n.top+t.clientTop,r=n.left+t.clientLeft,i=q(t)?gt(t):h(1);return{width:t.clientWidth*i.x,height:t.clientHeight*i.y,x:r*i.x,y:o*i.y}}(e,n);else{const n=wt(t);o={x:e.x-n.x,y:e.y-n.y,width:e.width,height:e.height}}return W(o)}function Pt(t,e){const n=ft(t);return!(n===e||!I(n)||lt(n))&&("fixed"===st(n).position||Pt(n,e))}function St(t,e,n){const o=q(e),r=Y(e),i="fixed"===n,a=xt(t,!0,i,e);let l={scrollLeft:0,scrollTop:0};const s=h(0);function c(){s.x=vt(r)}if(o||!o&&!i)if(("body"!==z(e)||K(r))&&(l=ct(e)),o){const t=xt(e,!0,i,e);s.x=t.x+e.clientLeft,s.y=t.y+e.clientTop}else r&&c();i&&!o&&r&&c();const f=!r||o||i?h(0):bt(r,l);return{x:a.left+l.scrollLeft-s.x-f.x,y:a.top+l.scrollTop-s.y-f.y,width:a.width,height:a.height}}function Ot(t){return"static"===st(t).position}function Tt(t,e){if(!q(t)||"fixed"===st(t).position)return null;if(e)return e(t);let n=t.offsetParent;return Y(t)===n&&(n=n.ownerDocument.body),n}function Lt(t,e){const n=V(t);if(tt(t))return n;if(!q(t)){let e=ft(t);for(;e&&!lt(e);){if(I(e)&&!Ot(e))return e;e=ft(e)}return n}let o=Tt(t,e);for(;o&&U(o)&&Ot(o);)o=Tt(o,e);return o&&lt(o)&&Ot(o)&&!rt(o)?n:o||function(t){let e=ft(t);for(;q(e)&&!lt(e);){if(rt(e))return e;if(tt(e))return null;e=ft(e)}return null}(t)||n}const Ct={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{elements:e,rect:n,offsetParent:o,strategy:r}=t;const i="fixed"===r,a=Y(o),l=!!e&&tt(e.floating);if(o===a||l&&i)return n;let s={scrollLeft:0,scrollTop:0},c=h(1);const f=h(0),u=q(o);if((u||!u&&!i)&&(("body"!==z(o)||K(a))&&(s=ct(o)),q(o))){const t=xt(o);c=gt(o),f.x=t.x+o.clientLeft,f.y=t.y+o.clientTop}const d=!a||u||i?h(0):bt(a,s,!0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-s.scrollLeft*c.x+f.x+d.x,y:n.y*c.y-s.scrollTop*c.y+f.y+d.y}},getDocumentElement:Y,getClippingRect:function(t){let{element:e,boundary:n,rootBoundary:o,strategy:r}=t;const i=[..."clippingAncestors"===n?tt(e)?[]:function(t,e){const n=e.get(t);if(n)return n;let o=dt(t,[],!1).filter(t=>I(t)&&"body"!==z(t)),r=null;const i="fixed"===st(t).position;let a=i?ft(t):t;for(;I(a)&&!lt(a);){const e=st(a),n=rt(a);n||"fixed"!==e.position||(r=null),(i?!n&&!r:!n&&"static"===e.position&&r&&Rt.has(r.position)||K(a)&&!n&&Pt(t,a))?o=o.filter(t=>t!==a):r=e,a=ft(a)}return e.set(t,o),o}(e,this._c):[].concat(n),o],a=i[0],l=i.reduce((t,n)=>{const o=At(e,n,r);return t.top=d(o.top,t.top),t.right=u(o.right,t.right),t.bottom=u(o.bottom,t.bottom),t.left=d(o.left,t.left),t},At(e,a,r));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},getOffsetParent:Lt,getElementRects:async function(t){const e=this.getOffsetParent||Lt,n=this.getDimensions,o=await n(t.floating);return{reference:St(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}},getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){const{width:e,height:n}=mt(t);return{width:e,height:n}},getScale:gt,isElement:I,isRTL:function(t){return"rtl"===st(t).direction}};function Et(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function Dt(t,e,n,o){void 0===o&&(o={});const{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:s=!1}=o,c=ht(t),f=r||i?[...c?dt(c):[],...dt(e)]:[];f.forEach(t=>{r&&t.addEventListener("scroll",n,{passive:!0}),i&&t.addEventListener("resize",n)});const p=c&&l?function(t,e){let n,o=null;const r=Y(t);function i(){var t;clearTimeout(n),null==(t=o)||t.disconnect(),o=null}return function a(l,s){void 0===l&&(l=!1),void 0===s&&(s=1),i();const c=t.getBoundingClientRect(),{left:f,top:p,width:h,height:g}=c;if(l||e(),!h||!g)return;const y={rootMargin:-m(p)+"px "+-m(r.clientWidth-(f+h))+"px "+-m(r.clientHeight-(p+g))+"px "+-m(f)+"px",threshold:d(0,u(1,s))||1};let w=!0;function x(e){const o=e[0].intersectionRatio;if(o!==s){if(!w)return a();o?a(!1,o):n=setTimeout(()=>{a(!1,1e-7)},1e3)}1!==o||Et(c,t.getBoundingClientRect())||a(),w=!1}try{o=new IntersectionObserver(x,{...y,root:r.ownerDocument})}catch(t){o=new IntersectionObserver(x,y)}o.observe(t)}(!0),i}(c,n):null;let h,g=-1,y=null;a&&(y=new ResizeObserver(t=>{let[o]=t;o&&o.target===c&&y&&(y.unobserve(e),cancelAnimationFrame(g),g=requestAnimationFrame(()=>{var t;null==(t=y)||t.observe(e)})),n()}),c&&!s&&y.observe(c),y.observe(e));let w=s?xt(t):null;return s&&function e(){const o=xt(t);w&&!Et(w,o)&&n();w=o,h=requestAnimationFrame(e)}(),n(),()=>{var t;f.forEach(t=>{r&&t.removeEventListener("scroll",n),i&&t.removeEventListener("resize",n)}),null==p||p(),null==(t=y)||t.disconnect(),y=null,s&&cancelAnimationFrame(h)}}const Ht=function(t){return void 0===t&&(t=0),{name:"offset",options:t,async fn(e){var n,o;const{x:r,y:i,placement:a,middlewareData:l}=e,s=await async function(t,e){const{placement:n,platform:o,elements:r}=t,i=await(null==o.isRTL?void 0:o.isRTL(r.floating)),a=v(n),l=b(n),s="y"===S(n),c=N.has(a)?-1:1,f=i&&s?-1:1,u=x(e,t);let{mainAxis:d,crossAxis:p,alignmentAxis:m}="number"==typeof u?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return l&&"number"==typeof m&&(p="end"===l?-1*m:m),s?{x:p*f,y:d*c}:{x:d*c,y:p*f}}(e,t);return a===(null==(n=l.offset)?void 0:n.placement)&&null!=(o=l.arrow)&&o.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},kt=function(t){return void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:o,placement:r}=e,{mainAxis:i=!0,crossAxis:a=!1,limiter:l={fn:t=>{let{x:e,y:n}=t;return{x:e,y:n}}},...s}=x(t,e),c={x:n,y:o},f=await M(e,s),u=S(v(r)),d=R(u);let p=c[d],m=c[u];if(i){const t="y"===d?"bottom":"right";p=w(p+f["y"===d?"top":"left"],p,p-f[t])}if(a){const t="y"===u?"bottom":"right";m=w(m+f["y"===u?"top":"left"],m,m-f[t])}const h=l.fn({...e,[d]:p,[u]:m});return{...h,data:{x:h.x-n,y:h.y-o,enabled:{[d]:i,[u]:a}}}}}},Ft=function(t){return void 0===t&&(t={}),{name:"flip",options:t,async fn(e){var n,o;const{placement:r,middlewareData:i,rects:a,initialPlacement:l,platform:s,elements:c}=e,{mainAxis:f=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:h=!0,...g}=x(t,e);if(null!=(n=i.arrow)&&n.alignmentOffset)return{};const y=v(r),w=S(l),R=v(l)===l,P=await(null==s.isRTL?void 0:s.isRTL(c.floating)),L=d||(R||!h?[k(l)]:function(t){const e=k(t);return[T(t),e,T(e)]}(l)),C="none"!==m;!d&&C&&L.push(...H(l,h,m,P));const E=[l,...L],D=await M(e,g),F=[];let W=(null==(o=i.flip)?void 0:o.overflows)||[];if(f&&F.push(D[y]),u){const t=function(t,e,n){void 0===n&&(n=!1);const o=b(t),r=O(t),i=A(r);let a="x"===r?o===(n?"end":"start")?"right":"left":"start"===o?"bottom":"top";return e.reference[i]>e.floating[i]&&(a=k(a)),[a,k(a)]}(r,a,P);F.push(D[t[0]],D[t[1]])}if(W=[...W,{placement:r,overflows:F}],!F.every(t=>t<=0)){var B,$;const t=((null==(B=i.flip)?void 0:B.index)||0)+1,e=E[t];if(e){if(!("alignment"===u&&w!==S(e))||W.every(t=>t.overflows[0]>0&&S(t.placement)===w))return{data:{index:t,overflows:W},reset:{placement:e}}}let n=null==($=W.filter(t=>t.overflows[0]<=0).sort((t,e)=>t.overflows[1]-e.overflows[1])[0])?void 0:$.placement;if(!n)switch(p){case"bestFit":{var j;const t=null==(j=W.filter(t=>{if(C){const e=S(t.placement);return e===w||"y"===e}return!0}).map(t=>[t.placement,t.overflows.filter(t=>t>0).reduce((t,e)=>t+e,0)]).sort((t,e)=>t[1]-e[1])[0])?void 0:j[0];t&&(n=t);break}case"initialPlacement":n=l}if(r!==n)return{reset:{placement:n}}}return{}}}},Wt=function(t){return void 0===t&&(t={}),{name:"size",options:t,async fn(e){var n,o;const{placement:r,rects:i,platform:a,elements:l}=e,{apply:s=()=>{},...c}=x(t,e),f=await M(e,c),p=v(r),m=b(r),h="y"===S(r),{width:g,height:y}=i.floating;let w,R;"top"===p||"bottom"===p?(w=p,R=m===(await(null==a.isRTL?void 0:a.isRTL(l.floating))?"start":"end")?"left":"right"):(R=p,w="end"===m?"top":"bottom");const A=y-f.top-f.bottom,P=g-f.left-f.right,O=u(y-f[w],A),T=u(g-f[R],P),L=!e.middlewareData.shift;let C=O,E=T;if(null!=(n=e.middlewareData.shift)&&n.enabled.x&&(E=P),null!=(o=e.middlewareData.shift)&&o.enabled.y&&(C=A),L&&!m){const t=d(f.left,0),e=d(f.right,0),n=d(f.top,0),o=d(f.bottom,0);h?E=g-2*(0!==t||0!==e?t+e:d(f.left,f.right)):C=y-2*(0!==n||0!==o?n+o:d(f.top,f.bottom))}await s({...e,availableWidth:E,availableHeight:C});const D=await a.getDimensions(l.floating);return g!==D.width||y!==D.height?{reset:{rects:!0}}:{}}}},Bt=function(t){return void 0===t&&(t={}),{name:"hide",options:t,async fn(e){const{rects:n}=e,{strategy:o="referenceHidden",...r}=x(t,e);switch(o){case"referenceHidden":{const t=$(await M(e,{...r,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:t,referenceHidden:j(t)}}}case"escaped":{const t=$(await M(e,{...r,altBoundary:!0}),n.floating);return{data:{escapedOffsets:t,escaped:j(t)}}}default:return{}}}}},Mt=t=>({name:"arrow",options:t,async fn(e){const{x:n,y:o,placement:r,rects:i,platform:a,elements:l,middlewareData:s}=e,{element:c,padding:f=0}=x(t,e)||{};if(null==c)return{};const d=F(f),p={x:n,y:o},m=O(r),h=A(m),g=await a.getDimensions(c),y="y"===m,v=y?"top":"left",R=y?"bottom":"right",P=y?"clientHeight":"clientWidth",S=i.reference[h]+i.reference[m]-p[m]-i.floating[h],T=p[m]-i.reference[m],L=await(null==a.getOffsetParent?void 0:a.getOffsetParent(c));let C=L?L[P]:0;C&&await(null==a.isElement?void 0:a.isElement(L))||(C=l.floating[P]||i.floating[h]);const E=S/2-T/2,D=C/2-g[h]/2-1,H=u(d[v],D),k=u(d[R],D),W=H,B=C-g[h]-k,M=C/2-g[h]/2+E,$=w(W,M,B),j=!s.arrow&&null!=b(r)&&M!==$&&i.reference[h]/2-(M<W?H:k)-g[h]/2<0,N=j?M<W?M-W:M-B:0;return{[m]:p[m]+N,data:{[m]:$,centerOffset:M-$-N,...j&&{alignmentOffset:N}},reset:j}}}),$t=function(t){return void 0===t&&(t={}),{options:t,fn(e){const{x:n,y:o,placement:r,rects:i,middlewareData:a}=e,{offset:l=0,mainAxis:s=!0,crossAxis:c=!0}=x(t,e),f={x:n,y:o},u=S(r),d=R(u);let p=f[d],m=f[u];const h=x(l,e),g="number"==typeof h?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(s){const t="y"===d?"height":"width",e=i.reference[d]-i.floating[t]+g.mainAxis,n=i.reference[d]+i.reference[t]-g.mainAxis;p<e?p=e:p>n&&(p=n)}if(c){var y,w;const t="y"===d?"width":"height",e=N.has(v(r)),n=i.reference[u]-i.floating[t]+(e&&(null==(y=a.offset)?void 0:y[u])||0)+(e?0:g.crossAxis),o=i.reference[u]+i.reference[t]+(e?0:(null==(w=a.offset)?void 0:w[u])||0)-(e?g.crossAxis:0);m<n?m=n:m>o&&(m=o)}return{[d]:p,[u]:m}}}},jt=(t,e,n)=>{const o=new Map,r={platform:Ct,...n},i={...r.platform,_c:o};return(async(t,e,n)=>{const{placement:o="bottom",strategy:r="absolute",middleware:i=[],platform:a}=n,l=i.filter(Boolean),s=await(null==a.isRTL?void 0:a.isRTL(e));let c=await a.getElementRects({reference:t,floating:e,strategy:r}),{x:f,y:u}=B(c,o,s),d=o,p={},m=0;for(let n=0;n<l.length;n++){const{name:i,fn:h}=l[n],{x:g,y:y,data:w,reset:x}=await h({x:f,y:u,initialPlacement:o,placement:d,strategy:r,middlewareData:p,rects:c,platform:a,elements:{reference:t,floating:e}});f=null!=g?g:f,u=null!=y?y:u,p={...p,[i]:{...p[i],...w}},x&&m<=50&&(m++,"object"==typeof x&&(x.placement&&(d=x.placement),x.rects&&(c=!0===x.rects?await a.getElementRects({reference:t,floating:e,strategy:r}):x.rects),({x:f,y:u}=B(c,d,s))),n=-1)}return{x:f,y:u,placement:d,strategy:r,middlewareData:p}})(t,e,{...r,platform:i})};var Nt="undefined"!=typeof document?e:function(){};function _t(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if("function"==typeof t&&t.toString()===e.toString())return!0;let n,o,r;if(t&&e&&"object"==typeof t){if(Array.isArray(t)){if(n=t.length,n!==e.length)return!1;for(o=n;0!==o--;)if(!_t(t[o],e[o]))return!1;return!0}if(r=Object.keys(t),n=r.length,n!==Object.keys(e).length)return!1;for(o=n;0!==o--;)if(!{}.hasOwnProperty.call(e,r[o]))return!1;for(o=n;0!==o--;){const n=r[o];if(("_owner"!==n||!t.$$typeof)&&!_t(t[n],e[n]))return!1}return!0}return t!=t&&e!=e}function zt(t){if("undefined"==typeof window)return 1;return(t.ownerDocument.defaultView||window).devicePixelRatio||1}function Vt(t,e){const n=zt(t);return Math.round(e*n)/n}function Yt(e){const n=t.useRef(e);return Nt(()=>{n.current=e}),n}const Xt=t=>({name:"arrow",options:t,fn(e){const{element:n,padding:o}="function"==typeof t?t(e):t;return n&&(r=n,{}.hasOwnProperty.call(r,"current"))?null!=n.current?Mt({element:n.current,padding:o}).fn(e):{}:n?Mt({element:n,padding:o}).fn(e):{};var r}}),It=(t,e)=>({...kt(t),options:[t,e]}),qt=(t,e)=>({...$t(t),options:[t,e]}),Gt=(t,e)=>({...Ft(t),options:[t,e]}),Jt=(t,e)=>({...Wt(t),options:[t,e]}),Kt=(t,e)=>({...Bt(t),options:[t,e]}),Qt=(t,e)=>({...Xt(t),options:[t,e]});var Ut=t.forwardRef((t,e)=>{const{children:n,width:i=10,height:a=5,...l}=t;return r(o.svg,{...l,ref:e,width:i,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:t.asChild?n:r("polygon",{points:"0,0 30,0 15,10"})})});Ut.displayName="Arrow";var Zt=Ut,te="Popper",[ee,ne]=a(te),[oe,re]=ee(te),ie=e=>{const{__scopePopper:n,children:o}=e,[i,a]=t.useState(null);return r(oe,{scope:n,anchor:i,onAnchorChange:a,children:o})};ie.displayName=te;var ae="PopperAnchor",le=t.forwardRef((e,n)=>{const{__scopePopper:a,virtualRef:l,...s}=e,c=re(ae,a),f=t.useRef(null),u=i(n,f);return t.useEffect(()=>{c.onAnchorChange(l?.current||f.current)}),l?null:r(o.div,{...s,ref:u})});le.displayName=ae;var se="PopperContent",[ce,fe]=ee(se),ue=t.forwardRef((e,a)=>{const{__scopePopper:f,side:u="bottom",sideOffset:d=0,align:p="center",alignOffset:m=0,arrowPadding:h=0,avoidCollisions:g=!0,collisionBoundary:y=[],collisionPadding:w=0,sticky:x="partial",hideWhenDetached:v=!1,updatePositionStrategy:b="optimized",onPlaced:R,...A}=e,P=re(se,f),[S,O]=t.useState(null),T=i(a,t=>O(t)),[L,C]=t.useState(null),E=c(L),D=E?.width??0,H=E?.height??0,k=u+("center"!==p?"-"+p:""),F="number"==typeof w?w:{top:0,right:0,bottom:0,left:0,...w},W=Array.isArray(y)?y:[y],B=W.length>0,M={padding:F,boundary:W.filter(he),altBoundary:B},{refs:$,floatingStyles:j,placement:N,isPositioned:_,middlewareData:z}=function(e){void 0===e&&(e={});const{placement:o="bottom",strategy:r="absolute",middleware:i=[],platform:a,elements:{reference:l,floating:s}={},transform:c=!0,whileElementsMounted:f,open:u}=e,[d,p]=t.useState({x:0,y:0,strategy:r,placement:o,middlewareData:{},isPositioned:!1}),[m,h]=t.useState(i);_t(m,i)||h(i);const[g,y]=t.useState(null),[w,x]=t.useState(null),v=t.useCallback(t=>{t!==P.current&&(P.current=t,y(t))},[]),b=t.useCallback(t=>{t!==S.current&&(S.current=t,x(t))},[]),R=l||g,A=s||w,P=t.useRef(null),S=t.useRef(null),O=t.useRef(d),T=null!=f,L=Yt(f),C=Yt(a),E=Yt(u),D=t.useCallback(()=>{if(!P.current||!S.current)return;const t={placement:o,strategy:r,middleware:m};C.current&&(t.platform=C.current),jt(P.current,S.current,t).then(t=>{const e={...t,isPositioned:!1!==E.current};H.current&&!_t(O.current,e)&&(O.current=e,n.flushSync(()=>{p(e)}))})},[m,o,r,C,E]);Nt(()=>{!1===u&&O.current.isPositioned&&(O.current.isPositioned=!1,p(t=>({...t,isPositioned:!1})))},[u]);const H=t.useRef(!1);Nt(()=>(H.current=!0,()=>{H.current=!1}),[]),Nt(()=>{if(R&&(P.current=R),A&&(S.current=A),R&&A){if(L.current)return L.current(R,A,D);D()}},[R,A,D,L,T]);const k=t.useMemo(()=>({reference:P,floating:S,setReference:v,setFloating:b}),[v,b]),F=t.useMemo(()=>({reference:R,floating:A}),[R,A]),W=t.useMemo(()=>{const t={position:r,left:0,top:0};if(!F.floating)return t;const e=Vt(F.floating,d.x),n=Vt(F.floating,d.y);return c?{...t,transform:"translate("+e+"px, "+n+"px)",...zt(F.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:e,top:n}},[r,c,F.floating,d.x,d.y]);return t.useMemo(()=>({...d,update:D,refs:k,elements:F,floatingStyles:W}),[d,D,k,F,W])}({strategy:"fixed",placement:k,whileElementsMounted:(...t)=>Dt(...t,{animationFrame:"always"===b}),elements:{reference:P.anchor},middleware:[(V={mainAxis:d+H,alignmentAxis:m},{...Ht(V),options:[V,Y]}),g&&It({mainAxis:!0,crossAxis:!1,limiter:"partial"===x?qt():void 0,...M}),g&&Gt({...M}),Jt({...M,apply:({elements:t,rects:e,availableWidth:n,availableHeight:o})=>{const{width:r,height:i}=e.reference,a=t.floating.style;a.setProperty("--radix-popper-available-width",`${n}px`),a.setProperty("--radix-popper-available-height",`${o}px`),a.setProperty("--radix-popper-anchor-width",`${r}px`),a.setProperty("--radix-popper-anchor-height",`${i}px`)}}),L&&Qt({element:L,padding:h}),ge({arrowWidth:D,arrowHeight:H}),v&&Kt({strategy:"referenceHidden",...M})]});var V,Y;const[X,I]=ye(N),q=l(R);s(()=>{_&&q?.()},[_,q]);const G=z.arrow?.x,J=z.arrow?.y,K=0!==z.arrow?.centerOffset,[Q,U]=t.useState();return s(()=>{S&&U(window.getComputedStyle(S).zIndex)},[S]),r("div",{ref:$.setFloating,"data-radix-popper-content-wrapper":"",style:{...j,transform:_?j.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Q,"--radix-popper-transform-origin":[z.transformOrigin?.x,z.transformOrigin?.y].join(" "),...z.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:r(ce,{scope:f,placedSide:X,onArrowChange:C,arrowX:G,arrowY:J,shouldHideArrow:K,children:r(o.div,{"data-side":X,"data-align":I,...A,ref:T,style:{...A.style,animation:_?void 0:"none"}})})})});ue.displayName=se;var de="PopperArrow",pe={top:"bottom",right:"left",bottom:"top",left:"right"},me=t.forwardRef(function(t,e){const{__scopePopper:n,...o}=t,i=fe(de,n),a=pe[i.placedSide];return r("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0},children:r(Zt,{...o,ref:e,style:{...o.style,display:"block"}})})});function he(t){return null!==t}me.displayName=de;var ge=t=>({name:"transformOrigin",options:t,fn(e){const{placement:n,rects:o,middlewareData:r}=e,i=0!==r.arrow?.centerOffset,a=i?0:t.arrowWidth,l=i?0:t.arrowHeight,[s,c]=ye(n),f={start:"0%",center:"50%",end:"100%"}[c],u=(r.arrow?.x??0)+a/2,d=(r.arrow?.y??0)+l/2;let p="",m="";return"bottom"===s?(p=i?f:`${u}px`,m=-l+"px"):"top"===s?(p=i?f:`${u}px`,m=`${o.floating.height+l}px`):"right"===s?(p=-l+"px",m=i?f:`${d}px`):"left"===s&&(p=`${o.floating.width+l}px`,m=i?f:`${d}px`),{data:{x:p,y:m}}}});function ye(t){const[e,n="center"]=t.split("-");return[e,n]}var we=ie,xe=le,ve=ue,be=me;export{xe as A,ve as C,we as R,be as a,ne as c};
2
+ //# sourceMappingURL=index-BMe6PFsX.mjs.map