@gv-tech/ui-web 2.29.2 → 2.29.3
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.
- package/dist/accordion.cjs +1 -1
- package/dist/accordion.mjs +53 -1
- package/dist/alert-dialog.cjs +1 -1
- package/dist/alert-dialog.mjs +99 -1
- package/dist/alert.cjs +1 -1
- package/dist/alert.mjs +1 -1
- package/dist/aspect-ratio.cjs +1 -1
- package/dist/aspect-ratio.mjs +10 -1
- package/dist/attachment.cjs +1 -1
- package/dist/attachment.mjs +25 -24
- package/dist/avatar.cjs +1 -1
- package/dist/avatar.mjs +49 -1
- package/dist/badge.cjs +1 -1
- package/dist/badge.mjs +5 -4
- package/dist/breadcrumb.cjs +1 -1
- package/dist/breadcrumb.mjs +12 -11
- package/dist/bubble.cjs +1 -1
- package/dist/bubble.mjs +4 -3
- package/dist/button-group.cjs +1 -1
- package/dist/button-group.mjs +12 -11
- package/dist/button.cjs +1 -1
- package/dist/button.mjs +4 -3
- package/dist/calendar.cjs +1 -1
- package/dist/calendar.mjs +97 -1
- package/dist/card.cjs +1 -1
- package/dist/card.mjs +1 -1
- package/dist/carousel.cjs +1 -1
- package/dist/carousel.mjs +107 -1
- package/dist/chart.cjs +2 -2
- package/dist/chart.mjs +1 -1
- package/dist/checkbox.cjs +1 -1
- package/dist/checkbox.mjs +19 -1
- package/dist/collapsible.cjs +1 -1
- package/dist/collapsible.mjs +12 -12
- package/dist/combobox.cjs +1 -1
- package/dist/combobox.mjs +161 -1
- package/dist/command.cjs +1 -1
- package/dist/command.mjs +89 -1
- package/dist/context-menu.cjs +1 -1
- package/dist/context-menu.mjs +123 -1
- package/dist/dialog.cjs +1 -1
- package/dist/dialog.mjs +40 -40
- package/dist/direction.cjs +1 -1
- package/dist/direction.mjs +7 -7
- package/dist/drawer.cjs +1 -1
- package/dist/drawer.mjs +1 -1
- package/dist/dropdown-menu.cjs +1 -1
- package/dist/dropdown-menu.mjs +126 -1
- package/dist/empty.cjs +1 -1
- package/dist/empty.mjs +1 -1
- package/dist/field.cjs +1 -1
- package/dist/field.mjs +36 -36
- package/dist/form.cjs +1 -1
- package/dist/form.mjs +36 -36
- package/dist/hover-card.cjs +1 -1
- package/dist/hover-card.mjs +30 -1
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +36 -36
- package/dist/input-group.cjs +1 -1
- package/dist/input-group.mjs +26 -26
- package/dist/input-otp.cjs +1 -1
- package/dist/input-otp.mjs +45 -1
- package/dist/input.cjs +1 -1
- package/dist/input.mjs +1 -1
- package/dist/item.cjs +1 -1
- package/dist/item.mjs +28 -27
- package/dist/kbd.cjs +1 -1
- package/dist/kbd.mjs +1 -1
- package/dist/label.cjs +1 -1
- package/dist/label.mjs +13 -1
- package/dist/marker.cjs +1 -1
- package/dist/marker.mjs +4 -3
- package/dist/menubar.cjs +1 -1
- package/dist/menubar.mjs +133 -1
- package/dist/message-scroller.cjs +1 -1
- package/dist/message-scroller.mjs +59 -1
- package/dist/message.cjs +1 -1
- package/dist/message.mjs +1 -1
- package/dist/native-select.cjs +1 -1
- package/dist/native-select.mjs +1 -1
- package/dist/navigation-menu.cjs +1 -1
- package/dist/navigation-menu.mjs +79 -1
- package/dist/pagination.cjs +1 -1
- package/dist/pagination.mjs +14 -14
- package/dist/popover.cjs +1 -1
- package/dist/popover.mjs +54 -1
- package/dist/progress.cjs +1 -1
- package/dist/progress.mjs +19 -1
- package/dist/questionnaire.cjs +1 -1
- package/dist/questionnaire.mjs +168 -1
- package/dist/radio-group.cjs +1 -1
- package/dist/radio-group.mjs +25 -1
- package/dist/resizable.cjs +1 -1
- package/dist/resizable.mjs +26 -1
- package/dist/rolldown-runtime-BocRIvOZ.js +1 -0
- package/dist/scroll-area.cjs +1 -1
- package/dist/scroll-area.mjs +35 -1
- package/dist/scroll-to-top.cjs +1 -1
- package/dist/search.cjs +1 -1
- package/dist/search.mjs +1 -1
- package/dist/select.cjs +1 -1
- package/dist/select.mjs +98 -1
- package/dist/separator.cjs +1 -1
- package/dist/separator.mjs +15 -1
- package/dist/sheet.cjs +1 -1
- package/dist/sheet.mjs +38 -38
- package/dist/{sidebar-C2ax_A0G.mjs → sidebar-DrU3nKaL.mjs} +138 -134
- package/dist/sidebar-uOtFHnBs.js +1 -0
- package/dist/sidebar.cjs +1 -1
- package/dist/sidebar.mjs +3 -1
- package/dist/skeleton.cjs +1 -1
- package/dist/skeleton.mjs +1 -1
- package/dist/slider.cjs +1 -1
- package/dist/slider.mjs +34 -1
- package/dist/spinner.cjs +1 -1
- package/dist/spinner.mjs +1 -1
- package/dist/support-fab.cjs +1 -1
- package/dist/switch.cjs +1 -1
- package/dist/switch.mjs +18 -1
- package/dist/table-of-contents.cjs +1 -1
- package/dist/table.cjs +1 -1
- package/dist/table.mjs +1 -1
- package/dist/tabs.cjs +1 -1
- package/dist/tabs.mjs +44 -1
- package/dist/text.cjs +1 -1
- package/dist/textarea.cjs +1 -1
- package/dist/textarea.mjs +1 -1
- package/dist/{theme-toggle-BSMwXb8o.mjs → theme-toggle-9KtAIRxy.mjs} +6 -6
- package/dist/theme-toggle-DkNI3bfh.js +1 -0
- package/dist/theme-toggle.cjs +1 -1
- package/dist/theme-toggle.mjs +2 -1
- package/dist/toast.cjs +1 -1
- package/dist/toast.mjs +52 -1
- package/dist/{toaster-D2BV6jez.mjs → toaster-8RrHPtlc.mjs} +8 -8
- package/dist/toaster-AFud4l6l.js +1 -0
- package/dist/toaster.cjs +1 -1
- package/dist/toaster.mjs +2 -1
- package/dist/toggle-group.cjs +1 -1
- package/dist/toggle-group.mjs +49 -1
- package/dist/toggle.cjs +1 -1
- package/dist/toggle.mjs +35 -1
- package/dist/tooltip.cjs +1 -1
- package/dist/tooltip.mjs +34 -1
- package/package.json +1 -1
- package/dist/accordion-Bd0-CZQn.js +0 -1
- package/dist/accordion-Cf6DNbLH.mjs +0 -244
- package/dist/alert-dialog-BxFH0Lwn.mjs +0 -180
- package/dist/alert-dialog-C6vNmGBL.js +0 -1
- package/dist/aspect-ratio-CdQevcDV.mjs +0 -38
- package/dist/aspect-ratio-Z4Nkc56X.js +0 -1
- package/dist/avatar-B5PWwGhY.mjs +0 -136
- package/dist/avatar-CFhYRM52.js +0 -1
- package/dist/calendar-D5qgt2o2.js +0 -1
- package/dist/calendar-DIqXNjOR.mjs +0 -3029
- package/dist/carousel-D-xEqRCX.js +0 -1
- package/dist/carousel-DPjWmM_A.mjs +0 -1169
- package/dist/checkbox-DEPm1BBc.mjs +0 -184
- package/dist/checkbox-DI9Hn_e_.js +0 -1
- package/dist/chunk-HBS6WEDP-D2-yWzIN.js +0 -1
- package/dist/chunk-HBS6WEDP-DD8ZmxRM.mjs +0 -62
- package/dist/combobox-C4y8AbZX.mjs +0 -5644
- package/dist/combobox-boXp-mix.js +0 -3
- package/dist/command-BnW6UIVk.js +0 -1
- package/dist/command-Cbsp7PBx.mjs +0 -542
- package/dist/context-menu-CwsdFpx1.js +0 -1
- package/dist/context-menu-FNgV55ZV.mjs +0 -315
- package/dist/dist-7YyzJonC.mjs +0 -39
- package/dist/dist-AlmToDtO.mjs +0 -17
- package/dist/dist-B76UOZbx.mjs +0 -40
- package/dist/dist-B7Ph9-T6.mjs +0 -44
- package/dist/dist-B7jnFMko.js +0 -1
- package/dist/dist-BOiFyvyS.mjs +0 -10
- package/dist/dist-BQkDLAY7.js +0 -1
- package/dist/dist-Bal96K8t.js +0 -1
- package/dist/dist-Blgp9lfa.js +0 -1
- package/dist/dist-BnlI08Je.mjs +0 -96
- package/dist/dist-Bu-uFV1C.mjs +0 -191
- package/dist/dist-C2BHd5i1.mjs +0 -460
- package/dist/dist-C516Vwxy.mjs +0 -116
- package/dist/dist-CBlqVBTk.js +0 -1
- package/dist/dist-CDcZ8WMF.js +0 -1
- package/dist/dist-CDksSmTD.mjs +0 -189
- package/dist/dist-CF-qVmmV.js +0 -1
- package/dist/dist-CIgGRTmJ.js +0 -1
- package/dist/dist-CJqVmdrU.js +0 -1
- package/dist/dist-COqM3IM6.mjs +0 -89
- package/dist/dist-CbWpCWog.mjs +0 -180
- package/dist/dist-CcGLWbPa.mjs +0 -19
- package/dist/dist-Cn4F8XlY.mjs +0 -220
- package/dist/dist-CoTs6T03.js +0 -1
- package/dist/dist-Co_xSt6d.js +0 -1
- package/dist/dist-Cu0GG-3j.mjs +0 -15
- package/dist/dist-DJqkhIXb.js +0 -1
- package/dist/dist-DKI-XYwI.mjs +0 -98
- package/dist/dist-DQeXXRYL.mjs +0 -201
- package/dist/dist-DW2ltK5-.js +0 -1
- package/dist/dist-DWcKY_sJ.js +0 -1
- package/dist/dist-DZiOPWLp.js +0 -1
- package/dist/dist-DdAeWIwf.js +0 -1
- package/dist/dist-DhubV_gU.mjs +0 -4
- package/dist/dist-DmY7elIQ.js +0 -1
- package/dist/dist-DoWtzxYc.mjs +0 -684
- package/dist/dist-DuQlxGyN.js +0 -1
- package/dist/dist-KFF7QKuL.js +0 -1
- package/dist/dist-RXrZgzkO.js +0 -1
- package/dist/dist-R_G5UQRm.js +0 -1
- package/dist/dist-dwRwxUPt.mjs +0 -22
- package/dist/dist-fzmUl3YX.mjs +0 -553
- package/dist/dist-hBsne-A2.mjs +0 -92
- package/dist/dist-ljiGYyay.mjs +0 -29
- package/dist/dist-pqMcQ1Nk.js +0 -1
- package/dist/dist-zmnQp5Xf.js +0 -1
- package/dist/dropdown-menu-ChuqZeix.js +0 -1
- package/dist/dropdown-menu-DU7KNoXP.mjs +0 -311
- package/dist/es2015-BooeZGhO.mjs +0 -554
- package/dist/es2015-Dggv0vx3.js +0 -41
- package/dist/floating-ui.react-dom-2hihjuTL.mjs +0 -1057
- package/dist/floating-ui.react-dom-BtFIezY4.js +0 -1
- package/dist/hover-card-BeqCs_2R.js +0 -1
- package/dist/hover-card-w8PmCyw2.mjs +0 -176
- package/dist/input-otp-Bn_Uy1mR.mjs +0 -398
- package/dist/input-otp-CTRB_0Xp.js +0 -20
- package/dist/label-Da0kELfR.mjs +0 -26
- package/dist/label-JMa1tFfC.js +0 -1
- package/dist/menubar-B7sRxpE4.mjs +0 -405
- package/dist/menubar-Bd-QKMcw.js +0 -1
- package/dist/message-scroller-B8AU0v3Y.mjs +0 -805
- package/dist/message-scroller-BJb4Mh_I.js +0 -1
- package/dist/navigation-menu-B-RwfscB.mjs +0 -638
- package/dist/navigation-menu-kPwxYZCR.js +0 -1
- package/dist/popover-Cq5cTNtC.js +0 -1
- package/dist/popover-T6Ra737i.mjs +0 -241
- package/dist/progress-e9YzxvRo.mjs +0 -90
- package/dist/progress-iUSEI7J9.js +0 -6
- package/dist/questionnaire-BLCvUX1C.mjs +0 -1137
- package/dist/questionnaire-CcymIPae.js +0 -1
- package/dist/radio-group-BKpiDcIb.mjs +0 -264
- package/dist/radio-group-DPEzCmxe.js +0 -1
- package/dist/resizable-ByF0NmN9.mjs +0 -2153
- package/dist/resizable-oL3v42zT.js +0 -1
- package/dist/rolldown-runtime-D7yIeQp2.mjs +0 -13
- package/dist/rolldown-runtime-DbbDpzbe.js +0 -1
- package/dist/scroll-area-BzNeOQ6C.mjs +0 -568
- package/dist/scroll-area-s4_ZJK59.js +0 -1
- package/dist/select-B_nRxX2Y.mjs +0 -831
- package/dist/select-j5_dph9S.js +0 -1
- package/dist/separator-Bn-3XUSJ.js +0 -1
- package/dist/separator-CCcMNS78.mjs +0 -38
- package/dist/sidebar-Cnem2n5A.js +0 -1
- package/dist/slider-B2PUTc7W.mjs +0 -484
- package/dist/slider-wZuXwuib.js +0 -1
- package/dist/switch-CD675xU7.js +0 -1
- package/dist/switch-ikzIzrme.mjs +0 -172
- package/dist/tabs-DCm5zOYB.mjs +0 -158
- package/dist/tabs-fcahDQDp.js +0 -1
- package/dist/theme-toggle-BGTJsIA-.js +0 -1
- package/dist/toast-C31v9P1K.js +0 -1
- package/dist/toast-vU5ISM03.mjs +0 -445
- package/dist/toaster-CaJyOCyC.js +0 -1
- package/dist/toggle-CSZdCCwX.js +0 -1
- package/dist/toggle-Cv9YYwLI.mjs +0 -58
- package/dist/toggle-group-RT8wyBwK.js +0 -1
- package/dist/toggle-group-qvjasXS-.mjs +0 -166
- package/dist/tooltip-7ERoN5mV.mjs +0 -386
- package/dist/tooltip-CC9_spXT.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const e=require("./rolldown-runtime-DbbDpzbe.js");let t=require("react"),n=e.r(t,1);t=e.r(t);let r=require("react-dom");r=e.r(r,1);var i=[`top`,`right`,`bottom`,`left`],a=Math.min,o=Math.max,s=Math.round,c=Math.floor,l=e=>({x:e,y:e}),u={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function d(e,t,n){return o(e,a(t,n))}function f(e,t){return typeof e==`function`?e(t):e}function p(e){return e.split(`-`)[0]}function m(e){return e.split(`-`)[1]}function h(e){return e===`x`?`y`:`x`}function g(e){return e===`y`?`height`:`width`}function _(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function v(e){return h(_(e))}function y(e,t,n){n===void 0&&(n=!1);let r=m(e),i=v(e),a=g(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=D(o)),[o,D(o)]}function b(e){let t=D(e);return[x(e),t,x(t)]}function x(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var S=[`left`,`right`],C=[`right`,`left`],w=[`top`,`bottom`],T=[`bottom`,`top`];function E(e,t,n){switch(e){case`top`:case`bottom`:return n?t?C:S:t?S:C;case`left`:case`right`:return t?w:T;default:return[]}}function ee(e,t,n,r){let i=m(e),a=E(p(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(x)))),a}function D(e){let t=p(e);return u[t]+e.slice(t.length)}function O(e){return{top:e.top??0,right:e.right??0,bottom:e.bottom??0,left:e.left??0}}function k(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:O(e)}function A(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function j(e,t,n){let{reference:r,floating:i}=e,a=_(t),o=v(t),s=g(o),c=p(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,h;switch(c){case`top`:h={x:u,y:r.y-i.height};break;case`bottom`:h={x:u,y:r.y+r.height};break;case`right`:h={x:r.x+r.width,y:d};break;case`left`:h={x:r.x-i.width,y:d};break;default:h={x:r.x,y:r.y}}let y=m(t);return y&&(h[o]+=f*(y===`end`?1:-1)*(n&&l?-1:1)),h}async function M(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:p=0}=f(t,e),m=k(p),h=o[d?u===`floating`?`reference`:`floating`:u],g=A(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(h))??!0?h:h.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),_=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,v=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),y=await(i.isElement==null?void 0:i.isElement(v))&&await(i.getScale==null?void 0:i.getScale(v))||{x:1,y:1},b=A(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:_,offsetParent:v,strategy:s}):_);return{top:(g.top-b.top+m.top)/y.y,bottom:(b.bottom-g.bottom+m.bottom)/y.y,left:(g.left-b.left+m.left)/y.x,right:(b.right-g.right+m.right)/y.x}}var N=50,P=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:M},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=j(l,r,c),f=r,p=0,m={};for(let n=0;n<a.length;n++){let h=a[n];if(!h)continue;let{name:g,fn:_}=h,{x:v,y,data:b,reset:x}=await _({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:m,rects:l,platform:s,elements:{reference:e,floating:t}});u=v??u,d=y??d,m[g]={...m[g],...b},x&&p<N&&(p++,typeof x==`object`&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=j(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},F=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:o,platform:s,elements:c,middlewareData:l}=t,{element:u,padding:p=0}=f(e,t)||{};if(u==null)return{};let h=k(p),_={x:n,y:r},y=v(i),b=g(y),x=await s.getDimensions(u),S=y===`y`,C=S?`top`:`left`,w=S?`bottom`:`right`,T=S?`clientHeight`:`clientWidth`,E=o.reference[b]+o.reference[y]-_[y]-o.floating[b],ee=_[y]-o.reference[y],D=await(s.getOffsetParent==null?void 0:s.getOffsetParent(u)),O=D?D[T]:0;O&&await(s.isElement==null?void 0:s.isElement(D))||(O=c.floating[T]||o.floating[b]);let A=E/2-ee/2,j=O/2-x[b]/2-1,M=a(h[C],j),N=a(h[w],j),P=O-x[b]-N,F=O/2-x[b]/2+A,te=d(M,F,P),I=!l.arrow&&m(i)!=null&&F!==te&&o.reference[b]/2-(F<M?M:N)-x[b]/2<0,L=I?F<M?F-M:F-P:0;return{[y]:_[y]+L,data:{[y]:te,centerOffset:F-te-L,...I&&{alignmentOffset:L}},reset:I}}}),te=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n;let{placement:r,middlewareData:i,rects:a,initialPlacement:o,platform:s,elements:c}=t,{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:m=`bestFit`,fallbackAxisSideDirection:h=`none`,flipAlignment:g=!0,...v}=f(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let x=p(r),S=_(o),C=p(o)===o,w=await(s.isRTL==null?void 0:s.isRTL(c.floating)),T=d||(C||!g?[D(o)]:b(o)),E=h!==`none`;!d&&E&&T.push(...ee(o,g,h,w));let O=[o,...T],k=await s.detectOverflow(t,v),A=[],j=i.flip?.overflows||[];if(l&&A.push(k[x]),u){let e=y(r,a,w);A.push(k[e[0]],k[e[1]])}if(j=[...j,{placement:r,overflows:A}],!A.every(e=>e<=0)){let e=(i.flip?.index||0)+1,t=O[e];if(t&&(u!==`alignment`||S===_(t)||j.every(e=>_(e.placement)!==S||e.overflows[0]>0)))return{data:{index:e,overflows:j},reset:{placement:t}};let n=j.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(m){case`bestFit`:{let e=j.filter(e=>{if(E){let t=_(e.placement);return t===S||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o}if(r!==n)return{reset:{placement:n}}}return{}}}};function I(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function L(e){return i.some(t=>e[t]>=0)}var ne=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=f(e,t);switch(i){case`referenceHidden`:{let e=I(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:L(e)}}}case`escaped`:{let e=I(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:L(e)}}}default:return{}}}}},re=new Set([`left`,`top`]);async function ie(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=p(n),s=m(n),c=_(n)===`y`,l=re.has(o)?-1:1,u=a&&c?-1:1,d=f(t,e),{mainAxis:h,crossAxis:g,alignmentAxis:v}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof v==`number`&&(g=s===`end`?v*-1:v),c?{x:g*u,y:h*l}:{x:h*l,y:g*u}}var ae=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await ie(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},oe=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=f(e,t),u={x:n,y:r},p=await a.detectOverflow(t,l),m=_(i),g=h(m),v=u[g],y=u[m],b=(e,t)=>d(t+p[e===`y`?`top`:`left`],t,t-p[e===`y`?`bottom`:`right`]);o&&(v=b(g,v)),s&&(y=b(m,y));let x=c.fn({...t,[g]:v,[m]:y});return{...x,data:{x:x.x-n,y:x.y-r,enabled:{[g]:o,[m]:s}}}}}},se=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=f(e,t),u={x:n,y:r},d=_(i),m=h(d),g=u[m],v=u[d],y=f(s,t),b=typeof y==`number`?{mainAxis:y,crossAxis:0}:{mainAxis:y.mainAxis??0,crossAxis:y.crossAxis??0};if(c){let e=m===`y`?`height`:`width`,t=a.reference[m]-a.floating[e]+b.mainAxis,n=a.reference[m]+a.reference[e]-b.mainAxis;g<t?g=t:g>n&&(g=n)}if(l){let e=m===`y`?`width`:`height`,t=re.has(p(i)),n=a.reference[d]-a.floating[e]+(t&&o.offset?.[d]||0)+(t?0:b.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:o.offset?.[d]||0)-(t?b.crossAxis:0);v<n?v=n:v>r&&(v=r)}return{[m]:g,[d]:v}}}},ce=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){let{placement:n,rects:r,platform:i,elements:s}=t,{apply:c=()=>{},...l}=f(e,t),u=await i.detectOverflow(t,l),d=p(n),h=m(n),g=_(n)===`y`,{width:v,height:y}=r.floating,b,x;d===`top`||d===`bottom`?(b=d,x=h===(await(i.isRTL==null?void 0:i.isRTL(s.floating))?`start`:`end`)?`left`:`right`):(x=d,b=h===`end`?`top`:`bottom`);let S=y-u.top-u.bottom,C=v-u.left-u.right,w=a(y-u[b],S),T=a(v-u[x],C),E=t.middlewareData.shift,ee=!E,D=w,O=T;E!=null&&E.enabled.x&&(O=C),E!=null&&E.enabled.y&&(D=S),ee&&!h&&(g?O=v-2*o(u.left,u.right):D=y-2*o(u.top,u.bottom)),await c({...t,availableWidth:O,availableHeight:D});let k=await i.getDimensions(s.floating);return v!==k.width||y!==k.height?{reset:{rects:!0}}:{}}}};function R(){return typeof window<`u`}function z(e){return le(e)?(e.nodeName||``).toLowerCase():`#document`}function B(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function V(e){return((le(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function le(e){return R()?e instanceof Node||e instanceof B(e).Node:!1}function H(e){return R()?e instanceof Element||e instanceof B(e).Element:!1}function U(e){return R()?e instanceof HTMLElement||e instanceof B(e).HTMLElement:!1}function ue(e){return!R()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof B(e).ShadowRoot}function W(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=J(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function de(e){return/^(table|td|th)$/.test(z(e))}function G(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var fe=/transform|translate|scale|rotate|perspective|filter/,pe=/paint|layout|strict|content/,K=e=>!!e&&e!==`none`,me;function he(e){let t=H(e)?J(e):e;return K(t.transform)||K(t.translate)||K(t.scale)||K(t.rotate)||K(t.perspective)||!_e()&&(K(t.backdropFilter)||K(t.filter))||fe.test(t.willChange||``)||pe.test(t.contain||``)}function ge(e){let t=X(e);for(;U(t)&&!q(t);){if(he(t))return t;if(G(t))return null;t=X(t)}return null}function _e(){return me??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),me}function q(e){return/^(html|body|#document)$/.test(z(e))}function J(e){return B(e).getComputedStyle(e)}function Y(e){return H(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function X(e){if(z(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||ue(e)&&e.host||V(e);return ue(t)?t.host:t}function ve(e){let t=X(e);return q(t)?(e.ownerDocument||e).body:U(t)&&W(t)?t:ve(t)}function Z(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=ve(e),i=r===e.ownerDocument?.body,a=B(r);if(i){let e=ye(a);return t.concat(a,a.visualViewport||[],W(r)?r:[],e&&n?Z(e):[])}return t.concat(r,Z(r,[],n))}function ye(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function be(e){let t=J(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=U(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,c=s(n)!==a||s(r)!==o;return c&&(n=a,r=o),{width:n,height:r,$:c}}function xe(e){return H(e)?e:e.contextElement}function Q(e){let t=xe(e);if(!U(t))return l(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=be(t),o=(a?s(n.width):n.width)/r,c=(a?s(n.height):n.height)/i;return o&&Number.isFinite(o)||(o=1),c&&Number.isFinite(c)||(c=1),{x:o,y:c}}var Se=l(0);function Ce(e){let t=B(e);return!_e()||!t.visualViewport?Se:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function we(e,t,n){return t===void 0&&(t=!1),!!n&&t&&n===B(e)}function $(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=xe(e),o=l(1);t&&(r?H(r)&&(o=Q(r)):o=Q(e));let s=we(a,n,r)?Ce(a):l(0),c=(i.left+s.x)/o.x,u=(i.top+s.y)/o.y,d=i.width/o.x,f=i.height/o.y;if(a&&r){let e=B(a),t=H(r)?B(r):r,n=e,i=ye(n);for(;i&&t!==n;){let e=Q(i),t=i.getBoundingClientRect(),r=J(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,u*=e.y,d*=e.x,f*=e.y,c+=a,u+=o,n=B(i),i=ye(n)}}return A({width:d,height:f,x:c,y:u})}function Te(e,t){let n=Y(e).scrollLeft;return t?t.left+n:$(V(e)).left+n}function Ee(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Te(e,n),y:n.top+t.scrollTop}}function De(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=V(r),s=t?G(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},u=l(1),d=l(0),f=U(r);if((f||!a)&&((z(r)!==`body`||W(o))&&(c=Y(r)),f)){let e=$(r);u=Q(r),d.x=e.x+r.clientLeft,d.y=e.y+r.clientTop}let p=o&&!f&&!a?Ee(o,c):l(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-c.scrollLeft*u.x+d.x+p.x,y:n.y*u.y-c.scrollTop*u.y+d.y+p.y}}function Oe(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function ke(e){let t=Y(e),n=e.ownerDocument.body,r=o(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),i=o(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight),a=-t.scrollLeft+Te(e),s=-t.scrollTop;return J(n).direction===`rtl`&&(a+=o(e.clientWidth,n.clientWidth)-r),{width:r,height:i,x:a,y:s}}var Ae=25;function je(e,t,n){n===void 0&&(n=`viewport`);let r=n===`layoutViewport`,i=B(e),a=V(e),o=i.visualViewport,s=a.clientWidth,c=a.clientHeight,l=0,u=0;if(o){let e=!_e()||t===`fixed`;r?e||(l=-o.offsetLeft,u=-o.offsetTop):(s=o.width,c=o.height,e&&(l=o.offsetLeft,u=o.offsetTop))}if(Te(a)<=0){let e=a.ownerDocument,t=e.body,n=getComputedStyle(t),r=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(a.clientWidth-t.clientWidth-r),o=getComputedStyle(a).scrollbarGutter===`stable both-edges`?i/2:i;o<=Ae&&(s-=o)}return{width:s,height:c,x:l,y:u}}function Me(e,t){let n=$(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=Q(e);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function Ne(e,t,n){let r;if(t===`viewport`||t===`layoutViewport`)r=je(e,n,t);else if(t===`document`)r=ke(V(e));else if(H(t))r=Me(t,n);else{let n=Ce(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return A(r)}function Pe(e,t){let n=t.get(e);if(n)return n;let r=Z(e,[],!1).filter(e=>H(e)&&z(e)!==`body`),i=null,a=J(e).position===`fixed`,o=a?X(e):e;for(;H(o)&&!q(o);){let e=J(o),t=he(o),n=i?i.position:a?`fixed`:``;!t&&(n===`fixed`||n===`absolute`&&e.position===`static`)?r=r.filter(e=>e!==o):i=e,o=X(o)}return t.set(e,r),r}function Fe(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,s=[...n===`clippingAncestors`?G(t)?[]:Pe(t,this._c):[].concat(n),r],c=Ne(t,s[0],i),l=c.top,u=c.right,d=c.bottom,f=c.left;for(let e=1;e<s.length;e++){let n=Ne(t,s[e],i);l=o(n.top,l),u=a(n.right,u),d=a(n.bottom,d),f=o(n.left,f)}return{width:u-f,height:d-l,x:f,y:l}}function Ie(e){let{width:t,height:n}=be(e);return{width:t,height:n}}function Le(e,t,n){let r=U(t),i=V(t),a=n===`fixed`,o=$(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=l(0);if((r||!a)&&((z(t)!==`body`||W(i))&&(s=Y(t)),r)){let e=$(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}!r&&i&&(c.x=Te(i));let u=i&&!r&&!a?Ee(i,s):l(0);return{x:o.left+s.scrollLeft-c.x-u.x,y:o.top+s.scrollTop-c.y-u.y,width:o.width,height:o.height}}function Re(e){return J(e).position===`static`}function ze(e,t){if(!U(e)||J(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return V(e)===n&&(n=n.ownerDocument.body),n}function Be(e,t){let n=B(e);if(G(e))return n;if(!U(e)){let t=X(e);for(;t&&!q(t);){if(H(t)&&!Re(t))return t;t=X(t)}return n}let r=ze(e,t);for(;r&&de(r)&&Re(r);)r=ze(r,t);return r&&q(r)&&Re(r)&&!he(r)?n:r||ge(e)||n}var Ve=async function(e){let t=this.getOffsetParent||Be,n=this.getDimensions,r=await n(e.floating);return{reference:Le(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function He(e){return J(e).direction===`rtl`}var Ue={convertOffsetParentRelativeRectToViewportRelativeRect:De,getDocumentElement:V,getClippingRect:Fe,getOffsetParent:Be,getElementRects:Ve,getClientRects:Oe,getDimensions:Ie,getScale:Q,isElement:H,isRTL:He};function We(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Ge(e,t,n){let r=null,i,s=V(e);function l(){var e;clearTimeout(i),(e=r)==null||e.disconnect(),r=null}function u(n,d){n===void 0&&(n=!1),d===void 0&&(d=1),l();let f=e.getBoundingClientRect(),{left:p,top:m,width:h,height:g}=f;if(n||t(),!h||!g)return;let _=c(m),v=c(s.clientWidth-(p+h)),y=c(s.clientHeight-(m+g)),b=c(p),x={rootMargin:-_+`px `+-v+`px `+-y+`px `+-b+`px`,threshold:o(0,a(1,d))||1},S=!0;function C(t){let n=t[0].intersectionRatio;if(!We(f,e.getBoundingClientRect()))return u();if(n!==d){if(!S)return u();n?u(!1,n):i=setTimeout(()=>{u(!1,1e-7)},1e3)}S=!1}try{r=new IntersectionObserver(C,{...x,root:s.ownerDocument})}catch{r=new IntersectionObserver(C,x)}r.observe(e)}let d=B(e),f=()=>u(n);return d.addEventListener(`resize`,f),u(!0),()=>{d.removeEventListener(`resize`,f),l()}}function Ke(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=xe(e),u=i||a?[...l?Z(l):[],...t?Z(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n),a&&e.addEventListener(`resize`,n)});let d=l&&s?Ge(l,n,a):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),t&&p.observe(t));let m,h=c?$(e):null;c&&g();function g(){let t=$(e);h&&!We(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d?.(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}var qe=ae,Je=oe,Ye=te,Xe=ce,Ze=ne,Qe=F,$e=se,et=(e,t,n)=>{let r=new Map,i=n??{},a={...Ue,...i.platform,_c:r};return P(e,t,{...i,platform:a})},tt=typeof document<`u`?n.useLayoutEffect:function(){};function nt(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e==`function`&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!nt(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!nt(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function rt(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function it(e,t){let n=rt(e);return Math.round(t*n)/n}function at(e){let t=n.useRef(e);return tt(()=>{t.current=e}),t}function ot(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o,elements:{reference:s,floating:c}={},transform:l=!0,whileElementsMounted:u,open:d}=e,[f,p]=n.useState({x:0,y:0,strategy:i,placement:t,middlewareData:{},isPositioned:!1}),[m,h]=n.useState(a);nt(m,a)||h(a);let[g,_]=n.useState(null),[v,y]=n.useState(null),b=n.useCallback(e=>{e!==w.current&&(w.current=e,_(e))},[]),x=n.useCallback(e=>{e!==T.current&&(T.current=e,y(e))},[]),S=s||g,C=c||v,w=n.useRef(null),T=n.useRef(null),E=n.useRef(f),ee=u!=null,D=at(u),O=at(o),k=at(d),A=n.useCallback(()=>{if(!w.current||!T.current)return;let e={placement:t,strategy:i,middleware:m};O.current&&(e.platform=O.current),et(w.current,T.current,e).then(e=>{let t={...e,isPositioned:k.current!==!1};j.current&&!nt(E.current,t)&&(E.current=t,r.flushSync(()=>{p(t)}))})},[m,t,i,O,k]);tt(()=>{d===!1&&E.current.isPositioned&&(E.current.isPositioned=!1,p(e=>({...e,isPositioned:!1})))},[d]);let j=n.useRef(!1);tt(()=>(j.current=!0,()=>{j.current=!1}),[]),tt(()=>{if(S&&(w.current=S),C&&(T.current=C),S&&C){if(D.current)return D.current(S,C,A);A()}},[S,C,A,D,ee]);let M=n.useMemo(()=>({reference:w,floating:T,setReference:b,setFloating:x}),[b,x]),N=n.useMemo(()=>({reference:S,floating:C}),[S,C]),P=n.useMemo(()=>{let e={position:i,left:0,top:0};if(!N.floating)return e;let t=it(N.floating,f.x),n=it(N.floating,f.y);return l?{...e,transform:`translate(`+t+`px, `+n+`px)`,...rt(N.floating)>=1.5&&{willChange:`transform`}}:{position:i,left:t,top:n}},[i,l,N.floating,f.x,f.y]);return n.useMemo(()=>({...f,update:A,refs:M,elements:N,floatingStyles:P}),[f,A,M,N,P])}var st=e=>{function t(e){return{}.hasOwnProperty.call(e,`current`)}return{name:`arrow`,options:e,fn(n){let{element:r,padding:i}=typeof e==`function`?e(n):e;return r&&t(r)?r.current==null?{}:Qe({element:r.current,padding:i}).fn(n):r?Qe({element:r,padding:i}).fn(n):{}}}},ct=(e,t)=>{let n=qe(e);return{name:n.name,fn:n.fn,options:[e,t]}},lt=(e,t)=>{let n=Je(e);return{name:n.name,fn:n.fn,options:[e,t]}},ut=(e,t)=>({fn:$e(e).fn,options:[e,t]}),dt=(e,t)=>{let n=Ye(e);return{name:n.name,fn:n.fn,options:[e,t]}},ft=(e,t)=>{let n=Xe(e);return{name:n.name,fn:n.fn,options:[e,t]}},pt=(e,t)=>{let n=Ze(e);return{name:n.name,fn:n.fn,options:[e,t]}},mt=(e,t)=>{let n=st(e);return{name:n.name,fn:n.fn,options:[e,t]}};Object.defineProperty(exports,"C",{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,"D",{enumerable:!0,get:function(){return k}}),Object.defineProperty(exports,"E",{enumerable:!0,get:function(){return g}}),Object.defineProperty(exports,"O",{enumerable:!0,get:function(){return p}}),Object.defineProperty(exports,"S",{enumerable:!0,get:function(){return f}}),Object.defineProperty(exports,"T",{enumerable:!0,get:function(){return v}}),Object.defineProperty(exports,"_",{enumerable:!0,get:function(){return q}}),Object.defineProperty(exports,"a",{enumerable:!0,get:function(){return ct}}),Object.defineProperty(exports,"b",{enumerable:!0,get:function(){return ue}}),Object.defineProperty(exports,"c",{enumerable:!0,get:function(){return ot}}),Object.defineProperty(exports,"d",{enumerable:!0,get:function(){return z}}),Object.defineProperty(exports,"f",{enumerable:!0,get:function(){return Z}}),Object.defineProperty(exports,"g",{enumerable:!0,get:function(){return U}}),Object.defineProperty(exports,"h",{enumerable:!0,get:function(){return H}}),Object.defineProperty(exports,"i",{enumerable:!0,get:function(){return ut}}),Object.defineProperty(exports,"k",{enumerable:!0,get:function(){return _}}),Object.defineProperty(exports,"l",{enumerable:!0,get:function(){return Ke}}),Object.defineProperty(exports,"m",{enumerable:!0,get:function(){return B}}),Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return dt}}),Object.defineProperty(exports,"o",{enumerable:!0,get:function(){return lt}}),Object.defineProperty(exports,"p",{enumerable:!0,get:function(){return X}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return pt}}),Object.defineProperty(exports,"s",{enumerable:!0,get:function(){return ft}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return mt}}),Object.defineProperty(exports,"u",{enumerable:!0,get:function(){return J}}),Object.defineProperty(exports,"v",{enumerable:!0,get:function(){return le}}),Object.defineProperty(exports,"w",{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,"x",{enumerable:!0,get:function(){return d}}),Object.defineProperty(exports,"y",{enumerable:!0,get:function(){return W}});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const e=require("./rolldown-runtime-DbbDpzbe.js"),t=require("./dist-CoTs6T03.js"),n=require("./dist-DZiOPWLp.js"),r=require("./dist-DW2ltK5-.js"),i=require("./dist-zmnQp5Xf.js"),a=require("./dist-CJqVmdrU.js"),o=require("./dist-CIgGRTmJ.js"),s=require("./dist-CDcZ8WMF.js"),c=require("./dist-Blgp9lfa.js"),l=require("./dist-CBlqVBTk.js"),u=require("./dist-R_G5UQRm.js"),d=require("./dist-DmY7elIQ.js");let f=require("react"),p=e.r(f,1);f=e.r(f);let m=require("react/jsx-runtime");var h=Object.defineProperty,g=(e,t)=>h(e,`name`,{value:t,configurable:!0}),_,v=`HoverCard`,[y,b]=r.t(v,[o.a]),x=o.a(),[S,C]=y(v),w=g(e=>{let{__scopeHoverCard:t,children:n,open:r,defaultOpen:a,onOpenChange:s,openDelay:c=700,closeDelay:l=300}=e,u=x(t),d=p.useRef(0),f=p.useRef(0),h=p.useRef(!1),g=p.useRef(!1),[_,y]=i.t({prop:r,defaultProp:a??!1,onChange:s,caller:v}),b=p.useCallback(()=>{clearTimeout(f.current),d.current=window.setTimeout(()=>y(!0),c)},[c,y]),C=p.useCallback(()=>{clearTimeout(d.current),!h.current&&!g.current&&(f.current=window.setTimeout(()=>y(!1),l))},[l,y]),w=p.useCallback(()=>y(!1),[y]);return p.useEffect(()=>()=>{clearTimeout(d.current),clearTimeout(f.current)},[]),(0,m.jsx)(S,{scope:t,open:_,onOpenChange:y,onOpen:b,onClose:C,onDismiss:w,hasSelectionRef:h,isPointerDownOnContentRef:g,children:(0,m.jsx)(o.t,{...u,children:n})})},`HoverCard`),T=`HoverCardTrigger`,E=p.forwardRef(g(function(e,t){let{__scopeHoverCard:r,...i}=e,a=C(T,r),s=x(r);return(0,m.jsx)(o.n,{asChild:!0,...s,children:(0,m.jsx)(l.t.a,{"data-state":a.open?`open`:`closed`,...i,ref:t,onPointerEnter:n.t(e.onPointerEnter,P(a.onOpen)),onPointerLeave:n.t(e.onPointerLeave,P(a.onClose)),onFocus:n.t(e.onFocus,a.onOpen),onBlur:n.t(e.onBlur,a.onClose),onTouchStart:n.t(e.onTouchStart,e=>e.preventDefault())})})},`HoverCardTrigger`)),D=`HoverCardPortal`,[O,k]=y(D,{forceMount:void 0}),A=g(e=>{let{__scopeHoverCard:t,forceMount:n,children:r,container:i}=e,a=C(D,t);return(0,m.jsx)(O,{scope:t,forceMount:n,children:(0,m.jsx)(c.t,{present:n||a.open,children:(0,m.jsx)(s.t,{asChild:!0,container:i,children:r})})})},`HoverCardPortal`),j=`HoverCardContent`,M=p.forwardRef(g(function(e,t){let r=k(j,e.__scopeHoverCard),{forceMount:i=r.forceMount,...a}=e,o=C(j,e.__scopeHoverCard);return(0,m.jsx)(c.t,{present:i||o.open,children:(0,m.jsx)(N,{"data-state":o.open?`open`:`closed`,...a,onPointerEnter:n.t(e.onPointerEnter,P(o.onOpen)),onPointerLeave:n.t(e.onPointerLeave,P(o.onClose)),ref:t})})},`HoverCardContent`)),N=p.forwardRef(g(function(e,t){let{__scopeHoverCard:r,onEscapeKeyDown:i,onPointerDownOutside:s,onFocusOutside:c,onInteractOutside:l,...f}=e,h=C(j,r),v=x(r),y=p.useRef(null),[b,S]=p.useState(null),w=a.a(t,y,S);d.r(b);let[T,E]=p.useState(!1);return p.useEffect(()=>{if(T){let e=document.body;return _=e.style.userSelect||e.style.webkitUserSelect,e.style.userSelect=`none`,e.style.webkitUserSelect=`none`,()=>{e.style.userSelect=_,e.style.webkitUserSelect=_}}},[T]),p.useEffect(()=>{if(y.current){let e=g(()=>{E(!1),h.isPointerDownOnContentRef.current=!1,setTimeout(()=>{document.getSelection()?.toString()!==``&&(h.hasSelectionRef.current=!0)})},`handlePointerUp`);return document.addEventListener(`pointerup`,e),()=>{document.removeEventListener(`pointerup`,e),h.hasSelectionRef.current=!1,h.isPointerDownOnContentRef.current=!1}}},[h.isPointerDownOnContentRef,h.hasSelectionRef]),p.useEffect(()=>{y.current&&F(y.current).forEach(e=>e.setAttribute(`tabindex`,`-1`))}),(0,m.jsx)(u.t,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:l,onEscapeKeyDown:i,onPointerDownOutside:s,onFocusOutside:n.t(c,e=>{e.preventDefault()}),onDismiss:h.onDismiss,children:(0,m.jsx)(o.i,{...v,...f,onPointerDown:n.t(f.onPointerDown,e=>{e.currentTarget.contains(e.target)&&E(!0),h.hasSelectionRef.current=!1,h.isPointerDownOnContentRef.current=!0}),ref:w,style:{...f.style,userSelect:T?`text`:void 0,WebkitUserSelect:T?`text`:void 0,"--radix-hover-card-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-hover-card-content-available-width":`var(--radix-popper-available-width)`,"--radix-hover-card-content-available-height":`var(--radix-popper-available-height)`,"--radix-hover-card-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-hover-card-trigger-height":`var(--radix-popper-anchor-height)`}})})},`HoverCardContentImpl`));function P(e){return t=>t.pointerType===`touch`?void 0:e()}g(P,`excludeTouch`);function F(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:g(e=>e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP,`acceptNode`)});for(;n.nextNode();)t.push(n.currentNode);return t}g(F,`getTabbableNodes`);function I({...e}){return(0,m.jsx)(w,{"data-slot":`hover-card`,...e})}function L({...e}){return(0,m.jsx)(E,{"data-slot":`hover-card-trigger`,...e})}function R({className:e,align:n=`center`,sideOffset:r=4,...i}){return(0,m.jsx)(A,{"data-slot":`hover-card-portal`,children:(0,m.jsx)(M,{"data-slot":`hover-card-content`,align:n,sideOffset:r,className:t.t(`bg-popover text-popover-foreground ring-foreground/10 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 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 z-50 w-64 origin-(--radix-hover-card-content-transform-origin) rounded-lg p-2.5 text-sm shadow-md ring-1 outline-hidden duration-100`,e),...i})})}Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return R}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return L}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return I}});
|
|
@@ -1,176 +0,0 @@
|
|
|
1
|
-
import { t as e } from "./dist-DoWtzxYc.mjs";
|
|
2
|
-
import { t } from "./dist-B76UOZbx.mjs";
|
|
3
|
-
import { t as n } from "./dist-COqM3IM6.mjs";
|
|
4
|
-
import { t as r } from "./dist-DKI-XYwI.mjs";
|
|
5
|
-
import { a as i } from "./dist-C516Vwxy.mjs";
|
|
6
|
-
import { a, i as o, n as s, t as c } from "./dist-Cn4F8XlY.mjs";
|
|
7
|
-
import { t as l } from "./dist-CcGLWbPa.mjs";
|
|
8
|
-
import { t as u } from "./dist-BnlI08Je.mjs";
|
|
9
|
-
import { t as d } from "./dist-B7Ph9-T6.mjs";
|
|
10
|
-
import { t as f } from "./dist-CbWpCWog.mjs";
|
|
11
|
-
import { r as p } from "./dist-CDksSmTD.mjs";
|
|
12
|
-
import * as m from "react";
|
|
13
|
-
import { jsx as h } from "react/jsx-runtime";
|
|
14
|
-
// ../../node_modules/.bun/@radix-ui+react-hover-card@1.2.1+2b23df507bdda662/node_modules/@radix-ui/react-hover-card/dist/index.mjs
|
|
15
|
-
var g = Object.defineProperty, _ = (e, t) => g(e, "name", {
|
|
16
|
-
value: t,
|
|
17
|
-
configurable: !0
|
|
18
|
-
}), v, y = "HoverCard", [b, x] = n(y, [a]), S = a(), [C, w] = b(y), T = /* @__PURE__ */ _((e) => {
|
|
19
|
-
let { __scopeHoverCard: t, children: n, open: i, defaultOpen: a, onOpenChange: o, openDelay: s = 700, closeDelay: l = 300 } = e, u = S(t), d = m.useRef(0), f = m.useRef(0), p = m.useRef(!1), g = m.useRef(!1), [_, v] = r({
|
|
20
|
-
prop: i,
|
|
21
|
-
defaultProp: a ?? !1,
|
|
22
|
-
onChange: o,
|
|
23
|
-
caller: y
|
|
24
|
-
}), b = m.useCallback(() => {
|
|
25
|
-
clearTimeout(f.current), d.current = window.setTimeout(() => v(!0), s);
|
|
26
|
-
}, [s, v]), x = m.useCallback(() => {
|
|
27
|
-
clearTimeout(d.current), !p.current && !g.current && (f.current = window.setTimeout(() => v(!1), l));
|
|
28
|
-
}, [l, v]), w = m.useCallback(() => v(!1), [v]);
|
|
29
|
-
return m.useEffect(() => () => {
|
|
30
|
-
clearTimeout(d.current), clearTimeout(f.current);
|
|
31
|
-
}, []), /* @__PURE__ */ h(C, {
|
|
32
|
-
scope: t,
|
|
33
|
-
open: _,
|
|
34
|
-
onOpenChange: v,
|
|
35
|
-
onOpen: b,
|
|
36
|
-
onClose: x,
|
|
37
|
-
onDismiss: w,
|
|
38
|
-
hasSelectionRef: p,
|
|
39
|
-
isPointerDownOnContentRef: g,
|
|
40
|
-
children: /* @__PURE__ */ h(c, {
|
|
41
|
-
...u,
|
|
42
|
-
children: n
|
|
43
|
-
})
|
|
44
|
-
});
|
|
45
|
-
}, "HoverCard"), E = "HoverCardTrigger", D = /* @__PURE__ */ m.forwardRef(/* @__PURE__ */ _(function(e, n) {
|
|
46
|
-
let { __scopeHoverCard: r, ...i } = e, a = w(E, r), o = S(r);
|
|
47
|
-
return /* @__PURE__ */ h(s, {
|
|
48
|
-
asChild: !0,
|
|
49
|
-
...o,
|
|
50
|
-
children: /* @__PURE__ */ h(d.a, {
|
|
51
|
-
"data-state": a.open ? "open" : "closed",
|
|
52
|
-
...i,
|
|
53
|
-
ref: n,
|
|
54
|
-
onPointerEnter: t(e.onPointerEnter, F(a.onOpen)),
|
|
55
|
-
onPointerLeave: t(e.onPointerLeave, F(a.onClose)),
|
|
56
|
-
onFocus: t(e.onFocus, a.onOpen),
|
|
57
|
-
onBlur: t(e.onBlur, a.onClose),
|
|
58
|
-
onTouchStart: t(e.onTouchStart, (e) => e.preventDefault())
|
|
59
|
-
})
|
|
60
|
-
});
|
|
61
|
-
}, "HoverCardTrigger")), O = "HoverCardPortal", [k, A] = b(O, { forceMount: void 0 }), j = /* @__PURE__ */ _((e) => {
|
|
62
|
-
let { __scopeHoverCard: t, forceMount: n, children: r, container: i } = e, a = w(O, t);
|
|
63
|
-
return /* @__PURE__ */ h(k, {
|
|
64
|
-
scope: t,
|
|
65
|
-
forceMount: n,
|
|
66
|
-
children: /* @__PURE__ */ h(u, {
|
|
67
|
-
present: n || a.open,
|
|
68
|
-
children: /* @__PURE__ */ h(l, {
|
|
69
|
-
asChild: !0,
|
|
70
|
-
container: i,
|
|
71
|
-
children: r
|
|
72
|
-
})
|
|
73
|
-
})
|
|
74
|
-
});
|
|
75
|
-
}, "HoverCardPortal"), M = "HoverCardContent", N = /* @__PURE__ */ m.forwardRef(/* @__PURE__ */ _(function(e, n) {
|
|
76
|
-
let r = A(M, e.__scopeHoverCard), { forceMount: i = r.forceMount, ...a } = e, o = w(M, e.__scopeHoverCard);
|
|
77
|
-
return /* @__PURE__ */ h(u, {
|
|
78
|
-
present: i || o.open,
|
|
79
|
-
children: /* @__PURE__ */ h(P, {
|
|
80
|
-
"data-state": o.open ? "open" : "closed",
|
|
81
|
-
...a,
|
|
82
|
-
onPointerEnter: t(e.onPointerEnter, F(o.onOpen)),
|
|
83
|
-
onPointerLeave: t(e.onPointerLeave, F(o.onClose)),
|
|
84
|
-
ref: n
|
|
85
|
-
})
|
|
86
|
-
});
|
|
87
|
-
}, "HoverCardContent")), P = /* @__PURE__ */ m.forwardRef(/* @__PURE__ */ _(function(e, n) {
|
|
88
|
-
let { __scopeHoverCard: r, onEscapeKeyDown: a, onPointerDownOutside: s, onFocusOutside: c, onInteractOutside: l, ...u } = e, d = w(M, r), g = S(r), y = m.useRef(null), [b, x] = m.useState(null), C = i(n, y, x);
|
|
89
|
-
p(b);
|
|
90
|
-
let [T, E] = m.useState(!1);
|
|
91
|
-
return m.useEffect(() => {
|
|
92
|
-
if (T) {
|
|
93
|
-
let e = document.body;
|
|
94
|
-
return v = e.style.userSelect || e.style.webkitUserSelect, e.style.userSelect = "none", e.style.webkitUserSelect = "none", () => {
|
|
95
|
-
e.style.userSelect = v, e.style.webkitUserSelect = v;
|
|
96
|
-
};
|
|
97
|
-
}
|
|
98
|
-
}, [T]), m.useEffect(() => {
|
|
99
|
-
if (y.current) {
|
|
100
|
-
let e = /* @__PURE__ */ _(() => {
|
|
101
|
-
E(!1), d.isPointerDownOnContentRef.current = !1, setTimeout(() => {
|
|
102
|
-
document.getSelection()?.toString() !== "" && (d.hasSelectionRef.current = !0);
|
|
103
|
-
});
|
|
104
|
-
}, "handlePointerUp");
|
|
105
|
-
return document.addEventListener("pointerup", e), () => {
|
|
106
|
-
document.removeEventListener("pointerup", e), d.hasSelectionRef.current = !1, d.isPointerDownOnContentRef.current = !1;
|
|
107
|
-
};
|
|
108
|
-
}
|
|
109
|
-
}, [d.isPointerDownOnContentRef, d.hasSelectionRef]), m.useEffect(() => {
|
|
110
|
-
y.current && I(y.current).forEach((e) => e.setAttribute("tabindex", "-1"));
|
|
111
|
-
}), /* @__PURE__ */ h(f, {
|
|
112
|
-
asChild: !0,
|
|
113
|
-
disableOutsidePointerEvents: !1,
|
|
114
|
-
onInteractOutside: l,
|
|
115
|
-
onEscapeKeyDown: a,
|
|
116
|
-
onPointerDownOutside: s,
|
|
117
|
-
onFocusOutside: t(c, (e) => {
|
|
118
|
-
e.preventDefault();
|
|
119
|
-
}),
|
|
120
|
-
onDismiss: d.onDismiss,
|
|
121
|
-
children: /* @__PURE__ */ h(o, {
|
|
122
|
-
...g,
|
|
123
|
-
...u,
|
|
124
|
-
onPointerDown: t(u.onPointerDown, (e) => {
|
|
125
|
-
e.currentTarget.contains(e.target) && E(!0), d.hasSelectionRef.current = !1, d.isPointerDownOnContentRef.current = !0;
|
|
126
|
-
}),
|
|
127
|
-
ref: C,
|
|
128
|
-
style: {
|
|
129
|
-
...u.style,
|
|
130
|
-
userSelect: T ? "text" : void 0,
|
|
131
|
-
WebkitUserSelect: T ? "text" : void 0,
|
|
132
|
-
"--radix-hover-card-content-transform-origin": "var(--radix-popper-transform-origin)",
|
|
133
|
-
"--radix-hover-card-content-available-width": "var(--radix-popper-available-width)",
|
|
134
|
-
"--radix-hover-card-content-available-height": "var(--radix-popper-available-height)",
|
|
135
|
-
"--radix-hover-card-trigger-width": "var(--radix-popper-anchor-width)",
|
|
136
|
-
"--radix-hover-card-trigger-height": "var(--radix-popper-anchor-height)"
|
|
137
|
-
}
|
|
138
|
-
})
|
|
139
|
-
});
|
|
140
|
-
}, "HoverCardContentImpl"));
|
|
141
|
-
function F(e) {
|
|
142
|
-
return (t) => t.pointerType === "touch" ? void 0 : e();
|
|
143
|
-
}
|
|
144
|
-
_(F, "excludeTouch");
|
|
145
|
-
function I(e) {
|
|
146
|
-
let t = [], n = document.createTreeWalker(e, NodeFilter.SHOW_ELEMENT, { acceptNode: /* @__PURE__ */ _((e) => e.tabIndex >= 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP, "acceptNode") });
|
|
147
|
-
for (; n.nextNode();) t.push(n.currentNode);
|
|
148
|
-
return t;
|
|
149
|
-
}
|
|
150
|
-
_(I, "getTabbableNodes");
|
|
151
|
-
// src/hover-card.tsx
|
|
152
|
-
function L({ ...e }) {
|
|
153
|
-
return /* @__PURE__ */ h(T, {
|
|
154
|
-
"data-slot": "hover-card",
|
|
155
|
-
...e
|
|
156
|
-
});
|
|
157
|
-
}
|
|
158
|
-
function R({ ...e }) {
|
|
159
|
-
return /* @__PURE__ */ h(D, {
|
|
160
|
-
"data-slot": "hover-card-trigger",
|
|
161
|
-
...e
|
|
162
|
-
});
|
|
163
|
-
}
|
|
164
|
-
function z({ className: t, align: n = "center", sideOffset: r = 4, ...i }) {
|
|
165
|
-
return /* @__PURE__ */ h(j, {
|
|
166
|
-
"data-slot": "hover-card-portal",
|
|
167
|
-
children: /* @__PURE__ */ h(N, {
|
|
168
|
-
"data-slot": "hover-card-content",
|
|
169
|
-
align: n,
|
|
170
|
-
sideOffset: r,
|
|
171
|
-
className: e("bg-popover text-popover-foreground ring-foreground/10 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 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 z-50 w-64 origin-(--radix-hover-card-content-transform-origin) rounded-lg p-2.5 text-sm shadow-md ring-1 outline-hidden duration-100", t),
|
|
172
|
-
...i
|
|
173
|
-
})
|
|
174
|
-
});
|
|
175
|
-
}
|
|
176
|
-
export { z as n, R as r, L as t };
|
|
@@ -1,398 +0,0 @@
|
|
|
1
|
-
import { t as e } from "./dist-DoWtzxYc.mjs";
|
|
2
|
-
import { MinusIcon as t } from "lucide-react";
|
|
3
|
-
import * as n from "react";
|
|
4
|
-
import { jsx as r, jsxs as i } from "react/jsx-runtime";
|
|
5
|
-
// ../../node_modules/.bun/input-otp@1.5.0+6f4b9a1cfb20c0ae/node_modules/input-otp/dist/index.mjs
|
|
6
|
-
var a = Object.defineProperty, o = Object.defineProperties, s = Object.getOwnPropertyDescriptors, c = Object.getOwnPropertySymbols, l = Object.prototype.hasOwnProperty, u = Object.prototype.propertyIsEnumerable, d = (e, t, n) => t in e ? a(e, t, {
|
|
7
|
-
enumerable: !0,
|
|
8
|
-
configurable: !0,
|
|
9
|
-
writable: !0,
|
|
10
|
-
value: n
|
|
11
|
-
}) : e[t] = n, f = (e, t) => {
|
|
12
|
-
for (var n in t ||= {}) l.call(t, n) && d(e, n, t[n]);
|
|
13
|
-
if (c) for (var n of c(t)) u.call(t, n) && d(e, n, t[n]);
|
|
14
|
-
return e;
|
|
15
|
-
}, p = (e, t) => o(e, s(t)), m = (e, t) => {
|
|
16
|
-
var n = {};
|
|
17
|
-
for (var r in e) l.call(e, r) && t.indexOf(r) < 0 && (n[r] = e[r]);
|
|
18
|
-
if (e != null && c) for (var r of c(e)) t.indexOf(r) < 0 && u.call(e, r) && (n[r] = e[r]);
|
|
19
|
-
return n;
|
|
20
|
-
};
|
|
21
|
-
function h(e) {
|
|
22
|
-
return [
|
|
23
|
-
setTimeout(e, 0),
|
|
24
|
-
setTimeout(e, 10),
|
|
25
|
-
setTimeout(e, 50)
|
|
26
|
-
];
|
|
27
|
-
}
|
|
28
|
-
function g(e) {
|
|
29
|
-
let t = n.useRef();
|
|
30
|
-
return n.useEffect(() => {
|
|
31
|
-
t.current = e;
|
|
32
|
-
}), t.current;
|
|
33
|
-
}
|
|
34
|
-
var _ = 18, v = 40, y = `${v}px`;
|
|
35
|
-
function b(e) {
|
|
36
|
-
let t = e.getBoundingClientRect().right, n = e;
|
|
37
|
-
for (; n;) {
|
|
38
|
-
if (getComputedStyle(n).overflowX !== "visible") return n.getBoundingClientRect().left + n.clientLeft + n.clientWidth - t;
|
|
39
|
-
n = n.parentElement;
|
|
40
|
-
}
|
|
41
|
-
return document.documentElement.clientWidth - t;
|
|
42
|
-
}
|
|
43
|
-
var x = "[data-lastpass-icon-root],com-1password-button,[data-dashlanecreated],[style$=\"2147483647 !important;\"]";
|
|
44
|
-
function S({ containerRef: e, inputRef: t, pushPasswordManagerStrategy: r, isFocused: i }) {
|
|
45
|
-
let [a, o] = n.useState(!1), [s, c] = n.useState(!1), [l, u] = n.useState(!1), d = n.useMemo(() => r !== "none" && (r === "increase-width" || r === "experimental-no-flickering") && a && s, [
|
|
46
|
-
a,
|
|
47
|
-
s,
|
|
48
|
-
r
|
|
49
|
-
]), f = n.useCallback(() => {
|
|
50
|
-
let n = e.current, i = t.current;
|
|
51
|
-
if (!n || !i || l || r === "none") return;
|
|
52
|
-
let a = n, s = a.getBoundingClientRect().left + a.offsetWidth, d = a.getBoundingClientRect().top + a.offsetHeight / 2, f = s - _, p = d;
|
|
53
|
-
document.querySelectorAll(x).length === 0 && document.elementFromPoint(f, p) === n || (c(b(n) >= v), o(!0), u(!0));
|
|
54
|
-
}, [
|
|
55
|
-
e,
|
|
56
|
-
t,
|
|
57
|
-
l,
|
|
58
|
-
r
|
|
59
|
-
]);
|
|
60
|
-
return n.useEffect(() => {
|
|
61
|
-
let t = e.current;
|
|
62
|
-
if (!t || r === "none") return;
|
|
63
|
-
function n() {
|
|
64
|
-
c(b(t) >= v);
|
|
65
|
-
}
|
|
66
|
-
n();
|
|
67
|
-
let i = setInterval(n, 1e3);
|
|
68
|
-
return () => {
|
|
69
|
-
clearInterval(i);
|
|
70
|
-
};
|
|
71
|
-
}, [e, r]), n.useEffect(() => {
|
|
72
|
-
let e = i || document.activeElement === t.current;
|
|
73
|
-
if (r === "none" || !e) return;
|
|
74
|
-
let n = setTimeout(f, 0), a = setTimeout(f, 2e3), o = setTimeout(f, 5e3), s = setTimeout(() => {
|
|
75
|
-
u(!0);
|
|
76
|
-
}, 6e3);
|
|
77
|
-
return () => {
|
|
78
|
-
clearTimeout(n), clearTimeout(a), clearTimeout(o), clearTimeout(s);
|
|
79
|
-
};
|
|
80
|
-
}, [
|
|
81
|
-
t,
|
|
82
|
-
i,
|
|
83
|
-
r,
|
|
84
|
-
f
|
|
85
|
-
]), {
|
|
86
|
-
hasPWMBadge: a,
|
|
87
|
-
willPushPWMBadge: d,
|
|
88
|
-
PWM_BADGE_SPACE_WIDTH: y
|
|
89
|
-
};
|
|
90
|
-
}
|
|
91
|
-
var C = n.createContext({}), w = n.forwardRef((e, t) => {
|
|
92
|
-
var r = e, { value: i, onChange: a, maxLength: o, textAlign: s = "left", pattern: c, placeholder: l, inputMode: u = "numeric", onComplete: d, pushPasswordManagerStrategy: _ = "increase-width", pasteTransformer: v, containerClassName: y, noScriptCSSFallback: b = E, nonce: x, render: w, children: D } = r, O = m(r, [
|
|
93
|
-
"value",
|
|
94
|
-
"onChange",
|
|
95
|
-
"maxLength",
|
|
96
|
-
"textAlign",
|
|
97
|
-
"pattern",
|
|
98
|
-
"placeholder",
|
|
99
|
-
"inputMode",
|
|
100
|
-
"onComplete",
|
|
101
|
-
"pushPasswordManagerStrategy",
|
|
102
|
-
"pasteTransformer",
|
|
103
|
-
"containerClassName",
|
|
104
|
-
"noScriptCSSFallback",
|
|
105
|
-
"nonce",
|
|
106
|
-
"render",
|
|
107
|
-
"children"
|
|
108
|
-
]), k;
|
|
109
|
-
let [A, j] = n.useState(typeof O.defaultValue == "string" ? O.defaultValue : ""), M = i ?? A, N = g(M), P = n.useCallback((e) => {
|
|
110
|
-
a?.(e), j(e);
|
|
111
|
-
}, [a]), F = n.useMemo(() => c ? typeof c == "string" ? new RegExp(c) : c : null, [c]), I = n.useRef(null), L = n.useRef(null), R = n.useRef({
|
|
112
|
-
value: M,
|
|
113
|
-
onChange: P,
|
|
114
|
-
isIOS: typeof window < "u" && ((k = window == null ? void 0 : window.CSS)?.supports)?.call(k, "-webkit-touch-callout", "none")
|
|
115
|
-
}), z = n.useRef({ prev: [
|
|
116
|
-
I.current?.selectionStart,
|
|
117
|
-
I.current?.selectionEnd,
|
|
118
|
-
I.current?.selectionDirection
|
|
119
|
-
] });
|
|
120
|
-
n.useImperativeHandle(t, () => I.current, []), n.useEffect(() => {
|
|
121
|
-
let e = I.current, t = L.current;
|
|
122
|
-
if (!e || !t) return;
|
|
123
|
-
R.current.value !== e.value && R.current.onChange(e.value), z.current.prev = [
|
|
124
|
-
e.selectionStart,
|
|
125
|
-
e.selectionEnd,
|
|
126
|
-
e.selectionDirection
|
|
127
|
-
];
|
|
128
|
-
function n() {
|
|
129
|
-
if (document.activeElement !== e) {
|
|
130
|
-
G(null), q(null);
|
|
131
|
-
return;
|
|
132
|
-
}
|
|
133
|
-
let t = e.selectionStart, n = e.selectionEnd, r = e.selectionDirection, i = e.maxLength, a = e.value, o = z.current.prev, s = -1, c = -1, l;
|
|
134
|
-
if (a.length !== 0 && t !== null && n !== null) {
|
|
135
|
-
let r = t === n, u = t === a.length && a.length < i;
|
|
136
|
-
if (r && !u) {
|
|
137
|
-
let e = t;
|
|
138
|
-
if (e === 0) s = 0, c = 1, l = "forward";
|
|
139
|
-
else if (e === i) s = e - 1, c = e, l = "backward";
|
|
140
|
-
else if (i > 1 && a.length > 1) {
|
|
141
|
-
let t = 0;
|
|
142
|
-
if (o[0] !== null && o[1] !== null) {
|
|
143
|
-
l = e < o[1] ? "backward" : "forward";
|
|
144
|
-
let n = o[0] === o[1] && o[0] < i;
|
|
145
|
-
l === "backward" && !n && (t = -1);
|
|
146
|
-
}
|
|
147
|
-
s = t + e, c = t + e + 1;
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
s !== -1 && c !== -1 && s !== c && e.setSelectionRange(s, c, l);
|
|
151
|
-
}
|
|
152
|
-
let u = s === -1 ? t : s, d = c === -1 ? n : c, f = l ?? r;
|
|
153
|
-
G(u), q(d), z.current.prev = [
|
|
154
|
-
u,
|
|
155
|
-
d,
|
|
156
|
-
f
|
|
157
|
-
];
|
|
158
|
-
}
|
|
159
|
-
if (document.addEventListener("selectionchange", n, { capture: !0 }), n(), document.activeElement === e && U(!0), !document.getElementById("input-otp-style")) {
|
|
160
|
-
let e = document.createElement("style");
|
|
161
|
-
if (e.id = "input-otp-style", x && e.setAttribute("nonce", x), document.head.appendChild(e), e.sheet) {
|
|
162
|
-
let t = "background: transparent !important; color: transparent !important; border-color: transparent !important; opacity: 0 !important; box-shadow: none !important; -webkit-box-shadow: none !important; -webkit-text-fill-color: transparent !important;";
|
|
163
|
-
T(e.sheet, "[data-input-otp]::selection { background: transparent !important; color: transparent !important; }"), T(e.sheet, `[data-input-otp]:autofill { ${t} }`), T(e.sheet, `[data-input-otp]:-webkit-autofill { ${t} }`), T(e.sheet, "@supports (-webkit-touch-callout: none) { [data-input-otp] { letter-spacing: -.6em !important; font-weight: 100 !important; font-stretch: ultra-condensed; font-optical-sizing: none !important; left: -1px !important; right: 1px !important; } }"), T(e.sheet, "[data-input-otp] + * { pointer-events: all !important; }");
|
|
164
|
-
}
|
|
165
|
-
}
|
|
166
|
-
let r = () => {
|
|
167
|
-
t && t.style.setProperty("--root-height", `${e.clientHeight}px`);
|
|
168
|
-
};
|
|
169
|
-
r();
|
|
170
|
-
let i = typeof ResizeObserver > "u" ? null : new ResizeObserver(r);
|
|
171
|
-
return i?.observe(e), () => {
|
|
172
|
-
document.removeEventListener("selectionchange", n, { capture: !0 }), i?.disconnect();
|
|
173
|
-
};
|
|
174
|
-
}, []);
|
|
175
|
-
let [B, V] = n.useState(!1), [H, U] = n.useState(!1), [W, G] = n.useState(null), [K, q] = n.useState(null);
|
|
176
|
-
n.useEffect(() => {
|
|
177
|
-
let e = h(() => {
|
|
178
|
-
var e;
|
|
179
|
-
(e = I.current) == null || e.dispatchEvent(new Event("input"));
|
|
180
|
-
let t = I.current?.selectionStart, n = I.current?.selectionEnd, r = I.current?.selectionDirection;
|
|
181
|
-
t !== null && n !== null && (G(t), q(n), z.current.prev = [
|
|
182
|
-
t,
|
|
183
|
-
n,
|
|
184
|
-
r
|
|
185
|
-
]);
|
|
186
|
-
});
|
|
187
|
-
return () => {
|
|
188
|
-
e.forEach((e) => clearTimeout(e));
|
|
189
|
-
};
|
|
190
|
-
}, [M, H]), n.useEffect(() => {
|
|
191
|
-
N !== void 0 && M !== N && N.length < o && M.length === o && d?.(M);
|
|
192
|
-
}, [
|
|
193
|
-
o,
|
|
194
|
-
d,
|
|
195
|
-
N,
|
|
196
|
-
M
|
|
197
|
-
]);
|
|
198
|
-
let J = S({
|
|
199
|
-
containerRef: L,
|
|
200
|
-
inputRef: I,
|
|
201
|
-
pushPasswordManagerStrategy: _,
|
|
202
|
-
isFocused: H
|
|
203
|
-
}), Y = n.useCallback((e) => {
|
|
204
|
-
let t = e.currentTarget.value.slice(0, o);
|
|
205
|
-
t.length > 0 && F && !F.test(t) ? e.preventDefault() : (typeof N == "string" && t.length < N.length && document.dispatchEvent(new Event("selectionchange")), P(t));
|
|
206
|
-
}, [
|
|
207
|
-
o,
|
|
208
|
-
P,
|
|
209
|
-
N,
|
|
210
|
-
F
|
|
211
|
-
]), X = n.useCallback(() => {
|
|
212
|
-
var e;
|
|
213
|
-
if (I.current) {
|
|
214
|
-
let t = Math.min(I.current.value.length, o - 1), n = I.current.value.length;
|
|
215
|
-
(e = I.current) == null || e.setSelectionRange(t, n), G(t), q(n);
|
|
216
|
-
}
|
|
217
|
-
U(!0);
|
|
218
|
-
}, [o]), Z = n.useCallback((e) => {
|
|
219
|
-
let t = I.current;
|
|
220
|
-
if (!v && (!R.current.isIOS || !e.clipboardData || !t)) return;
|
|
221
|
-
let n = e.clipboardData.getData("text/plain"), r = v ? v(n) : n;
|
|
222
|
-
e.preventDefault();
|
|
223
|
-
let i = I.current?.selectionStart, a = I.current?.selectionEnd, s = (i === a ? M.slice(0, i) + r + M.slice(i) : M.slice(0, i) + r + M.slice(a)).slice(0, o);
|
|
224
|
-
if (s.length > 0 && F && !F.test(s)) return;
|
|
225
|
-
t.value = s, P(s);
|
|
226
|
-
let c = Math.min(s.length, o - 1), l = s.length;
|
|
227
|
-
t.setSelectionRange(c, l), G(c), q(l);
|
|
228
|
-
}, [
|
|
229
|
-
o,
|
|
230
|
-
P,
|
|
231
|
-
v,
|
|
232
|
-
F,
|
|
233
|
-
M
|
|
234
|
-
]), ee = n.useMemo(() => ({
|
|
235
|
-
position: "relative",
|
|
236
|
-
cursor: O.disabled ? "default" : "text",
|
|
237
|
-
userSelect: "none",
|
|
238
|
-
WebkitUserSelect: "none",
|
|
239
|
-
pointerEvents: "none"
|
|
240
|
-
}), [O.disabled]), Q = n.useMemo(() => ({
|
|
241
|
-
position: "absolute",
|
|
242
|
-
inset: 0,
|
|
243
|
-
width: J.willPushPWMBadge ? `calc(100% + ${J.PWM_BADGE_SPACE_WIDTH})` : "100%",
|
|
244
|
-
clipPath: J.willPushPWMBadge ? `inset(0 ${J.PWM_BADGE_SPACE_WIDTH} 0 0)` : void 0,
|
|
245
|
-
height: "100%",
|
|
246
|
-
display: "flex",
|
|
247
|
-
textAlign: s,
|
|
248
|
-
opacity: "1",
|
|
249
|
-
color: "transparent",
|
|
250
|
-
pointerEvents: "all",
|
|
251
|
-
background: "transparent",
|
|
252
|
-
caretColor: "transparent",
|
|
253
|
-
border: "0 solid transparent",
|
|
254
|
-
outline: "0 solid transparent",
|
|
255
|
-
boxShadow: "none",
|
|
256
|
-
lineHeight: "1",
|
|
257
|
-
letterSpacing: "-.5em",
|
|
258
|
-
fontSize: "var(--root-height, 16px)",
|
|
259
|
-
fontFamily: "monospace",
|
|
260
|
-
fontVariantNumeric: "tabular-nums"
|
|
261
|
-
}), [
|
|
262
|
-
J.PWM_BADGE_SPACE_WIDTH,
|
|
263
|
-
J.willPushPWMBadge,
|
|
264
|
-
s
|
|
265
|
-
]), te = n.useMemo(() => n.createElement("input", p(f({ autoComplete: O.autoComplete || "one-time-code" }, O), {
|
|
266
|
-
"data-input-otp": !0,
|
|
267
|
-
"data-input-otp-placeholder-shown": M.length === 0 || void 0,
|
|
268
|
-
"data-input-otp-mss": W,
|
|
269
|
-
"data-input-otp-mse": K,
|
|
270
|
-
inputMode: u,
|
|
271
|
-
pattern: F?.source,
|
|
272
|
-
"aria-placeholder": l,
|
|
273
|
-
style: Q,
|
|
274
|
-
maxLength: o,
|
|
275
|
-
value: M,
|
|
276
|
-
ref: I,
|
|
277
|
-
spellCheck: O.spellCheck ?? !1,
|
|
278
|
-
onPaste: (e) => {
|
|
279
|
-
var t;
|
|
280
|
-
Z(e), (t = O.onPaste) == null || t.call(O, e);
|
|
281
|
-
},
|
|
282
|
-
onChange: Y,
|
|
283
|
-
onMouseOver: (e) => {
|
|
284
|
-
var t;
|
|
285
|
-
V(!0), (t = O.onMouseOver) == null || t.call(O, e);
|
|
286
|
-
},
|
|
287
|
-
onMouseLeave: (e) => {
|
|
288
|
-
var t;
|
|
289
|
-
V(!1), (t = O.onMouseLeave) == null || t.call(O, e);
|
|
290
|
-
},
|
|
291
|
-
onFocus: (e) => {
|
|
292
|
-
var t;
|
|
293
|
-
X(), (t = O.onFocus) == null || t.call(O, e);
|
|
294
|
-
},
|
|
295
|
-
onBlur: (e) => {
|
|
296
|
-
var t;
|
|
297
|
-
U(!1), (t = O.onBlur) == null || t.call(O, e);
|
|
298
|
-
}
|
|
299
|
-
})), [
|
|
300
|
-
Y,
|
|
301
|
-
X,
|
|
302
|
-
Z,
|
|
303
|
-
u,
|
|
304
|
-
Q,
|
|
305
|
-
o,
|
|
306
|
-
K,
|
|
307
|
-
W,
|
|
308
|
-
l,
|
|
309
|
-
O,
|
|
310
|
-
F?.source,
|
|
311
|
-
M
|
|
312
|
-
]), $ = n.useMemo(() => ({
|
|
313
|
-
slots: Array.from({ length: o }).map((e, t) => {
|
|
314
|
-
let n = H && W !== null && K !== null && (W === K && t === W || t >= W && t < K), r = M[t] === void 0 ? null : M[t];
|
|
315
|
-
return {
|
|
316
|
-
char: r,
|
|
317
|
-
placeholderChar: M[0] === void 0 ? l?.[t] ?? null : null,
|
|
318
|
-
isActive: n,
|
|
319
|
-
hasFakeCaret: n && r === null
|
|
320
|
-
};
|
|
321
|
-
}),
|
|
322
|
-
isFocused: H,
|
|
323
|
-
isHovering: !O.disabled && B
|
|
324
|
-
}), [
|
|
325
|
-
H,
|
|
326
|
-
B,
|
|
327
|
-
o,
|
|
328
|
-
K,
|
|
329
|
-
W,
|
|
330
|
-
l,
|
|
331
|
-
O.disabled,
|
|
332
|
-
M
|
|
333
|
-
]), ne = n.useMemo(() => w ? w($) : n.createElement(C.Provider, { value: $ }, D), [
|
|
334
|
-
D,
|
|
335
|
-
$,
|
|
336
|
-
w
|
|
337
|
-
]);
|
|
338
|
-
return n.createElement(n.Fragment, null, b !== null && n.createElement("noscript", null, n.createElement("style", null, b)), n.createElement("div", {
|
|
339
|
-
ref: L,
|
|
340
|
-
"data-input-otp-container": !0,
|
|
341
|
-
translate: "no",
|
|
342
|
-
style: ee,
|
|
343
|
-
className: y
|
|
344
|
-
}, ne, n.createElement("div", { style: {
|
|
345
|
-
position: "absolute",
|
|
346
|
-
inset: 0,
|
|
347
|
-
pointerEvents: "none"
|
|
348
|
-
} }, te)));
|
|
349
|
-
});
|
|
350
|
-
w.displayName = "Input";
|
|
351
|
-
function T(e, t) {
|
|
352
|
-
try {
|
|
353
|
-
e.insertRule(t);
|
|
354
|
-
} catch {
|
|
355
|
-
console.warn("input-otp could not insert CSS rule:", t);
|
|
356
|
-
}
|
|
357
|
-
}
|
|
358
|
-
var E = "\n[data-input-otp] {\n --nojs-bg: white !important;\n --nojs-fg: black !important;\n\n background-color: var(--nojs-bg) !important;\n color: var(--nojs-fg) !important;\n caret-color: var(--nojs-fg) !important;\n letter-spacing: .25em !important;\n text-align: center !important;\n border: 1px solid var(--nojs-fg) !important;\n border-radius: 4px !important;\n width: 100% !important;\n}\n@media (prefers-color-scheme: dark) {\n [data-input-otp] {\n --nojs-bg: black !important;\n --nojs-fg: white !important;\n }\n}";
|
|
359
|
-
// src/input-otp.tsx
|
|
360
|
-
function D({ className: t, containerClassName: n, ...i }) {
|
|
361
|
-
return /* @__PURE__ */ r(w, {
|
|
362
|
-
"data-slot": "input-otp",
|
|
363
|
-
containerClassName: e("cn-input-otp flex items-center has-disabled:opacity-50", n),
|
|
364
|
-
spellCheck: !1,
|
|
365
|
-
className: e("disabled:cursor-not-allowed", t),
|
|
366
|
-
...i
|
|
367
|
-
});
|
|
368
|
-
}
|
|
369
|
-
function O({ className: t, ...n }) {
|
|
370
|
-
return /* @__PURE__ */ r("div", {
|
|
371
|
-
"data-slot": "input-otp-group",
|
|
372
|
-
className: e("has-aria-invalid:border-destructive has-aria-invalid:ring-destructive/20 dark:has-aria-invalid:ring-destructive/40 flex items-center rounded-lg has-aria-invalid:ring-3", t),
|
|
373
|
-
...n
|
|
374
|
-
});
|
|
375
|
-
}
|
|
376
|
-
function k({ index: t, className: a, ...o }) {
|
|
377
|
-
let { char: s, hasFakeCaret: c, isActive: l } = n.useContext(C)?.slots[t] ?? {};
|
|
378
|
-
return /* @__PURE__ */ i("div", {
|
|
379
|
-
"data-slot": "input-otp-slot",
|
|
380
|
-
"data-active": l,
|
|
381
|
-
className: e("border-input aria-invalid:border-destructive data-[active=true]:border-ring data-[active=true]:ring-ring/50 data-[active=true]:aria-invalid:border-destructive data-[active=true]:aria-invalid:ring-destructive/20 dark:bg-input/30 dark:data-[active=true]:aria-invalid:ring-destructive/40 relative flex size-8 items-center justify-center border-y border-e text-sm transition-all outline-none first:rounded-s-lg first:border-s last:rounded-e-lg data-[active=true]:z-10 data-[active=true]:ring-3", a),
|
|
382
|
-
...o,
|
|
383
|
-
children: [s, c && /* @__PURE__ */ r("div", {
|
|
384
|
-
className: "pointer-events-none absolute inset-0 flex items-center justify-center",
|
|
385
|
-
children: /* @__PURE__ */ r("div", { className: "animate-caret-blink bg-foreground h-4 w-px duration-1000" })
|
|
386
|
-
})]
|
|
387
|
-
});
|
|
388
|
-
}
|
|
389
|
-
function A({ ...e }) {
|
|
390
|
-
return /* @__PURE__ */ r("div", {
|
|
391
|
-
"data-slot": "input-otp-separator",
|
|
392
|
-
className: "flex items-center [&_svg:not([class*='size-'])]:size-4",
|
|
393
|
-
"aria-hidden": "true",
|
|
394
|
-
...e,
|
|
395
|
-
children: /* @__PURE__ */ r(t, {})
|
|
396
|
-
});
|
|
397
|
-
}
|
|
398
|
-
export { k as i, O as n, A as r, D as t };
|