@gv-tech/ui-web 2.29.1 → 2.29.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/accordion-Bd0-CZQn.js +1 -0
- package/dist/{accordion-D5QXSsCK.mjs → accordion-Cf6DNbLH.mjs} +47 -51
- package/dist/accordion.cjs +1 -1
- package/dist/accordion.mjs +1 -2
- package/dist/{alert-dialog-B-a0Wa1M.mjs → alert-dialog-BxFH0Lwn.mjs} +43 -45
- package/dist/alert-dialog-C6vNmGBL.js +1 -0
- package/dist/alert-dialog.cjs +1 -1
- package/dist/alert-dialog.mjs +1 -2
- package/dist/alert.cjs +1 -1
- package/dist/alert.mjs +2 -3
- package/dist/{aspect-ratio-s7Ji1MSr.mjs → aspect-ratio-CdQevcDV.mjs} +4 -6
- package/dist/aspect-ratio-Z4Nkc56X.js +1 -0
- package/dist/aspect-ratio.cjs +1 -1
- package/dist/aspect-ratio.mjs +1 -2
- package/dist/attachment.cjs +1 -1
- package/dist/attachment.mjs +3 -4
- package/dist/{avatar-d8Di248f.mjs → avatar-B5PWwGhY.mjs} +50 -52
- package/dist/avatar-CFhYRM52.js +1 -0
- package/dist/avatar.cjs +1 -1
- package/dist/avatar.mjs +1 -2
- package/dist/badge.cjs +1 -1
- package/dist/badge.mjs +5 -6
- package/dist/breadcrumb.cjs +1 -1
- package/dist/breadcrumb.mjs +3 -4
- package/dist/bubble.cjs +1 -1
- package/dist/bubble.mjs +3 -4
- package/dist/button-group.cjs +1 -1
- package/dist/button-group.mjs +4 -5
- package/dist/button.cjs +1 -1
- package/dist/button.mjs +3 -4
- package/dist/calendar-D5qgt2o2.js +1 -0
- package/dist/{calendar-UW8h9dfh.mjs → calendar-DIqXNjOR.mjs} +687 -840
- package/dist/calendar.cjs +1 -1
- package/dist/calendar.mjs +1 -2
- package/dist/card.cjs +1 -1
- package/dist/card.mjs +2 -3
- package/dist/carousel-D-xEqRCX.js +1 -0
- package/dist/{carousel-DG9xGJns.mjs → carousel-DPjWmM_A.mjs} +13 -15
- package/dist/carousel.cjs +1 -1
- package/dist/carousel.mjs +1 -2
- package/dist/chart.cjs +2 -2
- package/dist/chart.mjs +14 -15
- package/dist/{checkbox-Dq8VHKDH.mjs → checkbox-DEPm1BBc.mjs} +36 -38
- package/dist/checkbox-DI9Hn_e_.js +1 -0
- package/dist/checkbox.cjs +1 -1
- package/dist/checkbox.mjs +1 -2
- package/dist/chunk-HBS6WEDP-D2-yWzIN.js +1 -0
- package/dist/{chunk-HBS6WEDP-aK8IuEX9.mjs → chunk-HBS6WEDP-DD8ZmxRM.mjs} +3 -4
- package/dist/collapsible.cjs +1 -1
- package/dist/collapsible.mjs +2 -3
- package/dist/{combobox-b4OmCNw1.mjs → combobox-C4y8AbZX.mjs} +348 -591
- package/dist/combobox-boXp-mix.js +3 -0
- package/dist/combobox.cjs +1 -1
- package/dist/combobox.mjs +1 -2
- package/dist/command-BnW6UIVk.js +1 -0
- package/dist/{command-5hobOyGG.mjs → command-Cbsp7PBx.mjs} +121 -124
- package/dist/command.cjs +1 -1
- package/dist/command.mjs +1 -2
- package/dist/context-menu-CwsdFpx1.js +1 -0
- package/dist/{context-menu-DzzU-_v8.mjs → context-menu-FNgV55ZV.mjs} +117 -119
- package/dist/context-menu.cjs +1 -1
- package/dist/context-menu.mjs +1 -2
- package/dist/dialog.cjs +1 -1
- package/dist/dialog.mjs +3 -4
- package/dist/direction.cjs +1 -1
- package/dist/direction.mjs +2 -3
- package/dist/{dist-Bb5W_J2F.mjs → dist-7YyzJonC.mjs} +4 -4
- package/dist/{dist-BPL7gUpg.mjs → dist-AlmToDtO.mjs} +2 -3
- package/dist/{dist-BB78QQyQ.mjs → dist-B76UOZbx.mjs} +1 -2
- package/dist/{dist-BEbV0Hal.mjs → dist-B7Ph9-T6.mjs} +2 -3
- package/dist/dist-B7jnFMko.js +1 -0
- package/dist/{dist-CS572Be42.mjs → dist-BOiFyvyS.mjs} +1 -2
- package/dist/dist-BQkDLAY7.js +1 -0
- package/dist/dist-Bal96K8t.js +1 -0
- package/dist/dist-Blgp9lfa.js +1 -0
- package/dist/{dist-CpKLY_uZ.mjs → dist-BnlI08Je.mjs} +4 -4
- package/dist/{dist-BexAB6yo.mjs → dist-Bu-uFV1C.mjs} +33 -34
- package/dist/{dist-OqDzLHTa.mjs → dist-C2BHd5i1.mjs} +31 -31
- package/dist/{dist-Dq-h6VAy.mjs → dist-C516Vwxy.mjs} +4 -6
- package/dist/dist-CBlqVBTk.js +1 -0
- package/dist/dist-CDcZ8WMF.js +1 -0
- package/dist/{dist-E8ieJTBC.mjs → dist-CDksSmTD.mjs} +5 -6
- package/dist/dist-CF-qVmmV.js +1 -0
- package/dist/dist-CIgGRTmJ.js +1 -0
- package/dist/dist-CJqVmdrU.js +1 -0
- package/dist/{dist-CPAF050o.mjs → dist-COqM3IM6.mjs} +3 -4
- package/dist/{dist-s7ibhASj.mjs → dist-CbWpCWog.mjs} +12 -13
- package/dist/{dist-DI1vapnL.mjs → dist-CcGLWbPa.mjs} +3 -4
- package/dist/{dist-Dt6m-kwU.mjs → dist-Cn4F8XlY.mjs} +50 -51
- package/dist/dist-CoTs6T03.js +1 -0
- package/dist/dist-Co_xSt6d.js +1 -0
- package/dist/{dist-UkWa-Arh.mjs → dist-Cu0GG-3j.mjs} +2 -3
- package/dist/{dist-Bvfb4y_L.mjs → dist-DKI-XYwI.mjs} +3 -5
- package/dist/{dist-DatgTWLz.mjs → dist-DQeXXRYL.mjs} +81 -82
- package/dist/dist-DW2ltK5-.js +1 -0
- package/dist/dist-DWcKY_sJ.js +1 -0
- package/dist/dist-DdAeWIwf.js +1 -0
- package/dist/dist-DhubV_gU.mjs +4 -0
- package/dist/dist-DmY7elIQ.js +1 -0
- package/dist/{dist-Dm3IQk5b.mjs → dist-DoWtzxYc.mjs} +234 -235
- package/dist/dist-DuQlxGyN.js +1 -0
- package/dist/dist-KFF7QKuL.js +1 -0
- package/dist/dist-RXrZgzkO.js +1 -0
- package/dist/dist-R_G5UQRm.js +1 -0
- package/dist/{dist-BbI6NHqR.mjs → dist-dwRwxUPt.mjs} +1 -2
- package/dist/dist-fzmUl3YX.mjs +553 -0
- package/dist/{dist-vu20fMUK.mjs → dist-hBsne-A2.mjs} +22 -23
- package/dist/{dist-B057I8ju.mjs → dist-ljiGYyay.mjs} +2 -3
- package/dist/dist-pqMcQ1Nk.js +1 -0
- package/dist/dist-zmnQp5Xf.js +1 -0
- package/dist/drawer.cjs +1 -1
- package/dist/drawer.mjs +2 -3
- package/dist/dropdown-menu-ChuqZeix.js +1 -0
- package/dist/{dropdown-menu-BqAhn64y.mjs → dropdown-menu-DU7KNoXP.mjs} +75 -77
- package/dist/dropdown-menu.cjs +1 -1
- package/dist/dropdown-menu.mjs +1 -2
- package/dist/empty.cjs +1 -1
- package/dist/empty.mjs +2 -3
- package/dist/{es2015-DbsmTzuc.mjs → es2015-BooeZGhO.mjs} +94 -111
- package/dist/es2015-Dggv0vx3.js +41 -0
- package/dist/field.cjs +1 -1
- package/dist/field.mjs +4 -5
- package/dist/{floating-ui.react-dom-CyupHsR6.mjs → floating-ui.react-dom-2hihjuTL.mjs} +12 -17
- package/dist/floating-ui.react-dom-BtFIezY4.js +1 -0
- package/dist/form.cjs +1 -1
- package/dist/form.mjs +19 -20
- package/dist/hooks/use-theme.d.ts +52 -52
- package/dist/hover-card-BeqCs_2R.js +1 -0
- package/dist/{hover-card-DMsxpR9G.mjs → hover-card-w8PmCyw2.mjs} +62 -64
- package/dist/hover-card.cjs +1 -1
- package/dist/hover-card.mjs +1 -2
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +66 -66
- package/dist/input-group.cjs +1 -1
- package/dist/input-group.mjs +2 -3
- package/dist/{input-otp-D49Y9VcH.mjs → input-otp-Bn_Uy1mR.mjs} +6 -17
- package/dist/input-otp-CTRB_0Xp.js +20 -0
- package/dist/input-otp.cjs +1 -1
- package/dist/input-otp.mjs +1 -2
- package/dist/input.cjs +1 -1
- package/dist/input.mjs +2 -3
- package/dist/item.cjs +1 -1
- package/dist/item.mjs +4 -5
- package/dist/kbd.cjs +1 -1
- package/dist/kbd.mjs +2 -3
- package/dist/{label-DsSICLPc.mjs → label-Da0kELfR.mjs} +4 -6
- package/dist/label-JMa1tFfC.js +1 -0
- package/dist/label.cjs +1 -1
- package/dist/label.mjs +1 -2
- package/dist/marker.cjs +1 -1
- package/dist/marker.mjs +3 -4
- package/dist/{menubar-DZqEj6S1.mjs → menubar-B7sRxpE4.mjs} +179 -181
- package/dist/menubar-Bd-QKMcw.js +1 -0
- package/dist/menubar.cjs +1 -1
- package/dist/menubar.mjs +1 -2
- package/dist/{message-scroller-CS4t7Ypn.mjs → message-scroller-B8AU0v3Y.mjs} +83 -102
- package/dist/message-scroller-BJb4Mh_I.js +1 -0
- package/dist/message-scroller.cjs +1 -1
- package/dist/message-scroller.mjs +1 -2
- package/dist/message.cjs +1 -1
- package/dist/message.mjs +2 -3
- package/dist/native-select.cjs +1 -1
- package/dist/native-select.mjs +2 -3
- package/dist/{navigation-menu-RO6thDOF.mjs → navigation-menu-B-RwfscB.mjs} +161 -159
- package/dist/navigation-menu-kPwxYZCR.js +1 -0
- package/dist/navigation-menu.cjs +1 -1
- package/dist/navigation-menu.mjs +1 -2
- package/dist/pagination.cjs +1 -1
- package/dist/pagination.mjs +2 -3
- package/dist/popover-Cq5cTNtC.js +1 -0
- package/dist/{popover-DSBkc70V.mjs → popover-T6Ra737i.mjs} +79 -81
- package/dist/popover.cjs +1 -1
- package/dist/popover.mjs +1 -2
- package/dist/{progress-CQ4nQ85t.mjs → progress-e9YzxvRo.mjs} +11 -13
- package/dist/progress-iUSEI7J9.js +6 -0
- package/dist/progress.cjs +1 -1
- package/dist/progress.mjs +1 -2
- package/dist/{questionnaire-CVED7G7R.mjs → questionnaire-BLCvUX1C.mjs} +153 -175
- package/dist/questionnaire-CcymIPae.js +1 -0
- package/dist/questionnaire.cjs +1 -1
- package/dist/questionnaire.mjs +1 -2
- package/dist/{radio-group-TRiAhMZB.mjs → radio-group-BKpiDcIb.mjs} +58 -60
- package/dist/radio-group-DPEzCmxe.js +1 -0
- package/dist/radio-group.cjs +1 -1
- package/dist/radio-group.mjs +1 -2
- package/dist/resizable-ByF0NmN9.mjs +2153 -0
- package/dist/resizable-oL3v42zT.js +1 -0
- package/dist/resizable.cjs +1 -1
- package/dist/resizable.mjs +1 -2
- package/dist/{chunk-BmowowmI.mjs → rolldown-runtime-D7yIeQp2.mjs} +2 -3
- package/dist/rolldown-runtime-DbbDpzbe.js +1 -0
- package/dist/{scroll-area-D6MiNHnJ.mjs → scroll-area-BzNeOQ6C.mjs} +109 -105
- package/dist/scroll-area-s4_ZJK59.js +1 -0
- package/dist/scroll-area.cjs +1 -1
- package/dist/scroll-area.mjs +1 -2
- package/dist/scroll-to-top.cjs +1 -1
- package/dist/scroll-to-top.mjs +6 -11
- package/dist/search.cjs +1 -1
- package/dist/search.mjs +12 -13
- package/dist/{select-BFJUmjvX.mjs → select-B_nRxX2Y.mjs} +280 -279
- package/dist/select-j5_dph9S.js +1 -0
- package/dist/select.cjs +1 -1
- package/dist/select.mjs +1 -2
- package/dist/separator-Bn-3XUSJ.js +1 -0
- package/dist/{separator-2kr96SyF.mjs → separator-CCcMNS78.mjs} +4 -6
- package/dist/separator.cjs +1 -1
- package/dist/separator.mjs +1 -2
- package/dist/sheet.cjs +1 -1
- package/dist/sheet.mjs +3 -4
- package/dist/{sidebar-DM9ee9wf.mjs → sidebar-C2ax_A0G.mjs} +47 -49
- package/dist/sidebar-Cnem2n5A.js +1 -0
- package/dist/sidebar.cjs +1 -1
- package/dist/sidebar.mjs +1 -2
- package/dist/skeleton.cjs +1 -1
- package/dist/skeleton.mjs +2 -3
- package/dist/{slider-CdTCoQu1.mjs → slider-B2PUTc7W.mjs} +103 -104
- package/dist/slider-wZuXwuib.js +1 -0
- package/dist/slider.cjs +1 -1
- package/dist/slider.mjs +1 -2
- package/dist/sonner.mjs +1 -2
- package/dist/spinner.cjs +1 -1
- package/dist/spinner.mjs +2 -3
- package/dist/support-fab.cjs +1 -1
- package/dist/support-fab.mjs +21 -22
- package/dist/switch-CD675xU7.js +1 -0
- package/dist/{switch-zUBdj7jK.mjs → switch-ikzIzrme.mjs} +29 -31
- package/dist/switch.cjs +1 -1
- package/dist/switch.mjs +1 -2
- package/dist/table-of-contents.cjs +1 -1
- package/dist/table-of-contents.mjs +5 -6
- package/dist/table.cjs +1 -1
- package/dist/table.mjs +2 -3
- package/dist/{tabs-DaE9pEbo.mjs → tabs-DCm5zOYB.mjs} +45 -47
- package/dist/tabs-fcahDQDp.js +1 -0
- package/dist/tabs.cjs +1 -1
- package/dist/tabs.mjs +1 -2
- package/dist/text.cjs +1 -1
- package/dist/text.mjs +14 -12
- package/dist/textarea.cjs +1 -1
- package/dist/textarea.mjs +2 -3
- package/dist/theme-provider.mjs +1 -2
- package/dist/{theme-toggle-DKh8WFLT.js → theme-toggle-BGTJsIA-.js} +1 -1
- package/dist/{theme-toggle-3RStptYf.mjs → theme-toggle-BSMwXb8o.mjs} +13 -15
- package/dist/theme-toggle.cjs +1 -1
- package/dist/theme-toggle.mjs +1 -2
- package/dist/toast-C31v9P1K.js +1 -0
- package/dist/{toast-D0Yb-K84.mjs → toast-vU5ISM03.mjs} +181 -181
- package/dist/toast.cjs +1 -1
- package/dist/toast.mjs +1 -2
- package/dist/toaster-CaJyOCyC.js +1 -0
- package/dist/{toaster-gT2b7mfE.mjs → toaster-D2BV6jez.mjs} +3 -5
- package/dist/toaster.cjs +1 -1
- package/dist/toaster.mjs +1 -2
- package/dist/toggle-CSZdCCwX.js +1 -0
- package/dist/{toggle-BAeKd2N0.mjs → toggle-Cv9YYwLI.mjs} +8 -9
- package/dist/toggle-group-RT8wyBwK.js +1 -0
- package/dist/{toggle-group-CEKhUozD.mjs → toggle-group-qvjasXS-.mjs} +44 -45
- package/dist/toggle-group.cjs +1 -1
- package/dist/toggle-group.mjs +1 -2
- package/dist/toggle.cjs +1 -1
- package/dist/toggle.mjs +1 -2
- package/dist/{tooltip-R_nK_Qh5.mjs → tooltip-7ERoN5mV.mjs} +97 -101
- package/dist/tooltip-CC9_spXT.js +1 -0
- package/dist/tooltip.cjs +1 -1
- package/dist/tooltip.mjs +1 -2
- package/dist/{utils-A_oVsYw5.mjs → utils-DQKc9joa.mjs} +1 -2
- package/package.json +3 -3
- package/dist/accordion-DjyDOX-h.js +0 -1
- package/dist/alert-dialog-DYQAhGBC.js +0 -1
- package/dist/aspect-ratio-C-KOOyGP.js +0 -1
- package/dist/avatar-4K3XjhP8.js +0 -1
- package/dist/calendar-DFj14O6r.js +0 -1
- package/dist/carousel-CNGpg5df.js +0 -1
- package/dist/checkbox-BCgbTAdU.js +0 -1
- package/dist/chunk-HBS6WEDP-CQNaACTf.js +0 -1
- package/dist/chunk-mLOUI7ql.js +0 -1
- package/dist/combobox-CpPIGtPJ.js +0 -4
- package/dist/command-Dbqnm9kI.js +0 -1
- package/dist/context-menu-DyTUismw.js +0 -1
- package/dist/dist-1zUKVGvf.js +0 -1
- package/dist/dist-BBvidwzC.js +0 -1
- package/dist/dist-BTUvBzOm.js +0 -1
- package/dist/dist-BU-TFzJf.js +0 -1
- package/dist/dist-BgXIqHHq.js +0 -1
- package/dist/dist-C8Pm6LRc.js +0 -1
- package/dist/dist-CGgemr2V.js +0 -1
- package/dist/dist-CUvxOuXM.mjs +0 -551
- package/dist/dist-C_iFkwIX.js +0 -1
- package/dist/dist-ClYM7l1t.js +0 -1
- package/dist/dist-D1qkELLT.js +0 -1
- package/dist/dist-D7-Fky36.js +0 -1
- package/dist/dist-DEpkkABT.js +0 -1
- package/dist/dist-DKXojpVG.js +0 -1
- package/dist/dist-DYUvPCPC.js +0 -1
- package/dist/dist-DoivLw3t.js +0 -1
- package/dist/dist-GazS1kfR.mjs +0 -5
- package/dist/dist-N97cIp0_.js +0 -1
- package/dist/dist-Qm9hFvM1.js +0 -1
- package/dist/dist-UnTrOmPV.js +0 -1
- package/dist/dist-YAADIsyo.js +0 -1
- package/dist/dist-Zs2sjYhL.js +0 -1
- package/dist/dist-hFLuJoMi.js +0 -1
- package/dist/dropdown-menu-BtKOr--r.js +0 -1
- package/dist/es2015-DbAsWDbs.js +0 -41
- package/dist/floating-ui.react-dom-BwFRxNGc.js +0 -1
- package/dist/hover-card-DWXusgiI.js +0 -1
- package/dist/input-otp-u3obpt-Q.js +0 -20
- package/dist/label-Dacwh21G.js +0 -1
- package/dist/menubar-BYNeRuzx.js +0 -1
- package/dist/message-scroller-DqLu0YI6.js +0 -1
- package/dist/navigation-menu-B36G3O83.js +0 -1
- package/dist/popover-DUHbvKB8.js +0 -1
- package/dist/progress-B9z08UXf.js +0 -6
- package/dist/questionnaire-PWClWvST.js +0 -1
- package/dist/radio-group-Bd3WbH5I.js +0 -1
- package/dist/resizable-Cq60hEWB.js +0 -1
- package/dist/resizable-Qc8cVUKd.mjs +0 -2857
- package/dist/scroll-area-DFUdJeSZ.js +0 -1
- package/dist/select-iQFoKU1s.js +0 -1
- package/dist/separator-Bo49G2aj.js +0 -1
- package/dist/sidebar-C6O8hLkz.js +0 -1
- package/dist/slider-CagVxozY.js +0 -1
- package/dist/switch-CoeAC1Wk.js +0 -1
- package/dist/tabs-TMhXe20x.js +0 -1
- package/dist/toast-B0S3F09s.js +0 -1
- package/dist/toaster-CX9im8R_.js +0 -1
- package/dist/toggle-B0hXPsi7.js +0 -1
- package/dist/toggle-group-htyug3G7.js +0 -1
- package/dist/tooltip-BZazhXDZ.js +0 -1
- /package/dist/{dist-DJqkhIXb2.js → dist-DJqkhIXb.js} +0 -0
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { t as e } from "./dist-
|
|
2
|
-
import {
|
|
3
|
-
import { t as n } from "./dist-
|
|
4
|
-
import {
|
|
5
|
-
import { t as i } from "./dist-
|
|
6
|
-
import { t as a } from "./dist-
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import { t as c } from "./dist-
|
|
10
|
-
import { t as l } from "./dist-
|
|
1
|
+
import { t as e } from "./dist-DoWtzxYc.mjs";
|
|
2
|
+
import { t } from "./dist-BOiFyvyS.mjs";
|
|
3
|
+
import { t as n } from "./dist-B76UOZbx.mjs";
|
|
4
|
+
import { a as r } from "./dist-C516Vwxy.mjs";
|
|
5
|
+
import { t as i } from "./dist-COqM3IM6.mjs";
|
|
6
|
+
import { t as a } from "./dist-DKI-XYwI.mjs";
|
|
7
|
+
import { n as o } from "./dist-dwRwxUPt.mjs";
|
|
8
|
+
import { t as s } from "./dist-7YyzJonC.mjs";
|
|
9
|
+
import { t as c } from "./dist-B7Ph9-T6.mjs";
|
|
10
|
+
import { t as l } from "./dist-C2BHd5i1.mjs";
|
|
11
11
|
import * as u from "react";
|
|
12
12
|
import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
13
|
-
|
|
13
|
+
// ../../node_modules/.bun/@radix-ui+react-slider@1.6.1+2b23df507bdda662/node_modules/@radix-ui/react-slider/dist/index.mjs
|
|
14
14
|
var m = Object.defineProperty, h = (e, t) => m(e, "name", {
|
|
15
15
|
value: t,
|
|
16
16
|
configurable: !0
|
|
@@ -50,8 +50,8 @@ var m = Object.defineProperty, h = (e, t) => m(e, "name", {
|
|
|
50
50
|
"ArrowUp",
|
|
51
51
|
"ArrowLeft"
|
|
52
52
|
]
|
|
53
|
-
}, x = "Slider", [S, C, w] =
|
|
54
|
-
let { name:
|
|
53
|
+
}, x = "Slider", [S, C, w] = l(x), [T, E] = i(x, [w]), [ee, D] = T(x), O = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e, i) {
|
|
54
|
+
let { name: o, min: s = 0, max: c = 100, step: l = 1, orientation: d = g.Horizontal, disabled: p = !1, minStepsBetweenThumbs: m = 0, preserveThumbOrder: _ = !1, defaultValue: b = [s], value: x, onValueChange: C = /* @__PURE__ */ h(() => {}, "onValueChange"), onValueCommit: w = /* @__PURE__ */ h(() => {}, "onValueCommit"), inverted: T = !1, form: E, ...D } = e, O = u.useRef(/* @__PURE__ */ new Set()), k = u.useRef(0), A = u.useRef(!1), [j, M] = u.useState(null), N = d === g.Horizontal ? te : ne, [P, re] = u.useState(null), F = r(i, re), [I = [], L] = a({
|
|
55
55
|
prop: x,
|
|
56
56
|
defaultProp: b,
|
|
57
57
|
onChange: /* @__PURE__ */ h((e) => {
|
|
@@ -84,29 +84,29 @@ var m = Object.defineProperty, h = (e, t) => m(e, "name", {
|
|
|
84
84
|
String(I) !== String(R.current) && w(I);
|
|
85
85
|
}
|
|
86
86
|
h(H, "handleSlideEnd");
|
|
87
|
-
function U(e,
|
|
88
|
-
let
|
|
89
|
-
function
|
|
90
|
-
let
|
|
91
|
-
return X(
|
|
92
|
-
nextValues:
|
|
93
|
-
changedIndex: _ ?
|
|
94
|
-
hasChanged: String(
|
|
87
|
+
function U(e, n, { commit: r } = { commit: !1 }) {
|
|
88
|
+
let i = Q(l), a = $(Math.round((e - s) / l) * l + s, i), o = t(a, [s, c]), u = m * l;
|
|
89
|
+
function d(e) {
|
|
90
|
+
let r = _ ? t(o, [e[n - 1] === void 0 ? s : e[n - 1] + u, e[n + 1] === void 0 ? c : e[n + 1] - u]) : o, i = W(e, r, n);
|
|
91
|
+
return X(i, u) ? {
|
|
92
|
+
nextValues: i,
|
|
93
|
+
changedIndex: _ ? n : i.indexOf(r),
|
|
94
|
+
hasChanged: String(i) !== String(e)
|
|
95
95
|
} : null;
|
|
96
96
|
}
|
|
97
|
-
h(
|
|
98
|
-
let
|
|
99
|
-
|
|
100
|
-
let t =
|
|
101
|
-
return t ? (k.current = t.changedIndex, t.hasChanged &&
|
|
97
|
+
h(d, "getNextValues");
|
|
98
|
+
let f = d(I);
|
|
99
|
+
f?.hasChanged && M(f.nextValues), L((e = []) => {
|
|
100
|
+
let t = d(e);
|
|
101
|
+
return t ? (k.current = t.changedIndex, t.hasChanged && r && w(t.nextValues), t.hasChanged ? t.nextValues : e) : e;
|
|
102
102
|
});
|
|
103
103
|
}
|
|
104
104
|
return h(U, "updateValues"), /* @__PURE__ */ f(ee, {
|
|
105
105
|
scope: e.__scopeSlider,
|
|
106
|
-
name:
|
|
106
|
+
name: o,
|
|
107
107
|
disabled: p,
|
|
108
|
-
min:
|
|
109
|
-
max:
|
|
108
|
+
min: s,
|
|
109
|
+
max: c,
|
|
110
110
|
valueIndexToChangeRef: k,
|
|
111
111
|
thumbs: O.current,
|
|
112
112
|
values: I,
|
|
@@ -122,28 +122,28 @@ var m = Object.defineProperty, h = (e, t) => m(e, "name", {
|
|
|
122
122
|
"data-disabled": p ? "" : void 0,
|
|
123
123
|
...D,
|
|
124
124
|
ref: F,
|
|
125
|
-
onPointerDown:
|
|
125
|
+
onPointerDown: n(D.onPointerDown, () => {
|
|
126
126
|
p || (R.current = I, A.current = !1);
|
|
127
127
|
}),
|
|
128
|
-
min:
|
|
129
|
-
max:
|
|
128
|
+
min: s,
|
|
129
|
+
max: c,
|
|
130
130
|
inverted: T,
|
|
131
131
|
onSlideStart: p ? void 0 : B,
|
|
132
132
|
onSlideMove: p ? void 0 : V,
|
|
133
133
|
onSlideEnd: p ? void 0 : H,
|
|
134
134
|
onHomeKeyDown: () => {
|
|
135
|
-
p || (A.current = !0, U(
|
|
135
|
+
p || (A.current = !0, U(s, 0, { commit: !0 }));
|
|
136
136
|
},
|
|
137
137
|
onEndKeyDown: () => {
|
|
138
|
-
p || (A.current = !0, U(
|
|
138
|
+
p || (A.current = !0, U(c, I.length - 1, { commit: !0 }));
|
|
139
139
|
},
|
|
140
140
|
onStepKeyDown: ({ event: e, direction: t }) => {
|
|
141
141
|
if (!p) {
|
|
142
142
|
A.current = !0;
|
|
143
|
-
let n = v.includes(e.key) || e.shiftKey && y.includes(e.key) ? 10 : 1, r = k.current,
|
|
144
|
-
U(ie(
|
|
145
|
-
min:
|
|
146
|
-
step:
|
|
143
|
+
let n = v.includes(e.key) || e.shiftKey && y.includes(e.key) ? 10 : 1, r = k.current, i = I[r];
|
|
144
|
+
U(ie(i, {
|
|
145
|
+
min: s,
|
|
146
|
+
step: l,
|
|
147
147
|
direction: t,
|
|
148
148
|
multiplier: n
|
|
149
149
|
}), r, { commit: !0 });
|
|
@@ -158,11 +158,11 @@ var m = Object.defineProperty, h = (e, t) => m(e, "name", {
|
|
|
158
158
|
endEdge: "right",
|
|
159
159
|
size: "width",
|
|
160
160
|
direction: 1
|
|
161
|
-
}), te = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e,
|
|
162
|
-
let { min:
|
|
161
|
+
}), te = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e, t) {
|
|
162
|
+
let { min: n, max: i, dir: a, inverted: s, onSlideStart: c, onSlideMove: l, onSlideEnd: d, onStepKeyDown: p, ...m } = e, [g, v] = u.useState(null), y = r(t, v), x = u.useRef(void 0), S = o(a), C = S === _.LTR, w = C && !s || !C && s;
|
|
163
163
|
function T(e) {
|
|
164
|
-
let t = x.current || g.getBoundingClientRect(),
|
|
165
|
-
return x.current = t,
|
|
164
|
+
let t = x.current || g.getBoundingClientRect(), r = Z([0, t.width], w ? [n, i] : [i, n]);
|
|
165
|
+
return x.current = t, r(e - t.left);
|
|
166
166
|
}
|
|
167
167
|
return h(T, "getValueFromPointer"), /* @__PURE__ */ f(k, {
|
|
168
168
|
scope: e.__scopeSlider,
|
|
@@ -199,11 +199,11 @@ var m = Object.defineProperty, h = (e, t) => m(e, "name", {
|
|
|
199
199
|
}
|
|
200
200
|
})
|
|
201
201
|
});
|
|
202
|
-
}, "SliderHorizontal")), ne = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e,
|
|
203
|
-
let { min:
|
|
202
|
+
}, "SliderHorizontal")), ne = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e, t) {
|
|
203
|
+
let { min: n, max: i, inverted: a, onSlideStart: o, onSlideMove: s, onSlideEnd: c, onStepKeyDown: l, ...d } = e, p = u.useRef(null), m = r(t, p), g = u.useRef(void 0), _ = !a;
|
|
204
204
|
function v(e) {
|
|
205
|
-
let t = g.current || p.current.getBoundingClientRect(),
|
|
206
|
-
return g.current = t,
|
|
205
|
+
let t = g.current || p.current.getBoundingClientRect(), r = Z([0, t.height], _ ? [i, n] : [n, i]);
|
|
206
|
+
return g.current = t, r(e - t.top);
|
|
207
207
|
}
|
|
208
208
|
return h(v, "getValueFromPointer"), /* @__PURE__ */ f(k, {
|
|
209
209
|
scope: e.__scopeSlider,
|
|
@@ -240,64 +240,64 @@ var m = Object.defineProperty, h = (e, t) => m(e, "name", {
|
|
|
240
240
|
})
|
|
241
241
|
});
|
|
242
242
|
}, "SliderVertical")), j = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e, t) {
|
|
243
|
-
let { __scopeSlider: r, onSlideStart: i, onSlideMove:
|
|
244
|
-
return /* @__PURE__ */ f(
|
|
243
|
+
let { __scopeSlider: r, onSlideStart: i, onSlideMove: a, onSlideEnd: o, onHomeKeyDown: s, onEndKeyDown: l, onStepKeyDown: u, ...d } = e, p = D(x, r);
|
|
244
|
+
return /* @__PURE__ */ f(c.span, {
|
|
245
245
|
...d,
|
|
246
246
|
ref: t,
|
|
247
|
-
onKeyDown:
|
|
248
|
-
e.key === "Home" ? (
|
|
247
|
+
onKeyDown: n(e.onKeyDown, (e) => {
|
|
248
|
+
e.key === "Home" ? (s(e), e.preventDefault()) : e.key === "End" ? (l(e), e.preventDefault()) : v.concat(y).includes(e.key) && (u(e), e.preventDefault());
|
|
249
249
|
}),
|
|
250
|
-
onPointerDown:
|
|
250
|
+
onPointerDown: n(e.onPointerDown, (e) => {
|
|
251
251
|
let t = e.target;
|
|
252
252
|
t.setPointerCapture(e.pointerId), e.preventDefault(), p.thumbs.has(t) ? t.focus({
|
|
253
253
|
preventScroll: !0,
|
|
254
254
|
focusVisible: !1
|
|
255
255
|
}) : i(e);
|
|
256
256
|
}),
|
|
257
|
-
onPointerMove:
|
|
258
|
-
e.target.hasPointerCapture(e.pointerId) &&
|
|
257
|
+
onPointerMove: n(e.onPointerMove, (e) => {
|
|
258
|
+
e.target.hasPointerCapture(e.pointerId) && a(e);
|
|
259
259
|
}),
|
|
260
|
-
onPointerUp:
|
|
260
|
+
onPointerUp: n(e.onPointerUp, (e) => {
|
|
261
261
|
let t = e.target;
|
|
262
|
-
t.hasPointerCapture(e.pointerId) && (t.releasePointerCapture(e.pointerId),
|
|
262
|
+
t.hasPointerCapture(e.pointerId) && (t.releasePointerCapture(e.pointerId), o(e));
|
|
263
263
|
})
|
|
264
264
|
});
|
|
265
265
|
}, "SliderImpl")), M = "SliderTrack", N = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e, t) {
|
|
266
|
-
let { __scopeSlider:
|
|
267
|
-
return /* @__PURE__ */ f(
|
|
268
|
-
"data-disabled":
|
|
269
|
-
"data-orientation":
|
|
270
|
-
...
|
|
266
|
+
let { __scopeSlider: n, ...r } = e, i = D(M, n);
|
|
267
|
+
return /* @__PURE__ */ f(c.span, {
|
|
268
|
+
"data-disabled": i.disabled ? "" : void 0,
|
|
269
|
+
"data-orientation": i.orientation,
|
|
270
|
+
...r,
|
|
271
271
|
ref: t
|
|
272
272
|
});
|
|
273
|
-
}, "SliderTrack")), P = "SliderRange", re = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e,
|
|
274
|
-
let { __scopeSlider:
|
|
275
|
-
return /* @__PURE__ */ f(
|
|
276
|
-
"data-orientation":
|
|
277
|
-
"data-disabled":
|
|
278
|
-
...
|
|
279
|
-
ref:
|
|
273
|
+
}, "SliderTrack")), P = "SliderRange", re = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e, t) {
|
|
274
|
+
let { __scopeSlider: n, ...i } = e, a = D(P, n), o = A(P, n), s = u.useRef(null), l = r(t, s), d = a.values.length, p = a.values.map((e) => G(e, a.min, a.max)), m = d > 1 ? Math.min(...p) : 0, h = 100 - Math.max(...p);
|
|
275
|
+
return /* @__PURE__ */ f(c.span, {
|
|
276
|
+
"data-orientation": a.orientation,
|
|
277
|
+
"data-disabled": a.disabled ? "" : void 0,
|
|
278
|
+
...i,
|
|
279
|
+
ref: l,
|
|
280
280
|
style: {
|
|
281
281
|
...e.style,
|
|
282
|
-
[
|
|
283
|
-
[
|
|
282
|
+
[o.startEdge]: m + "%",
|
|
283
|
+
[o.endEdge]: h + "%"
|
|
284
284
|
}
|
|
285
285
|
});
|
|
286
286
|
}, "SliderRange")), [F, I] = T("SliderThumb"), L = "SliderThumbProvider";
|
|
287
287
|
function R(e) {
|
|
288
|
-
let { __scopeSlider: t, name: n, children: r, internal_do_not_use_render: i } = e, a = D(L, t), o = C(t), [
|
|
288
|
+
let { __scopeSlider: t, name: n, children: r, internal_do_not_use_render: i } = e, a = D(L, t), o = C(t), [c, l] = u.useState(null), d = u.useMemo(() => c ? o().findIndex((e) => e.ref.current === c) : -1, [o, c]), p = s(c), m = !c || !!a.form || !!c.closest("form"), h = a.values[d], g = n ?? (a.name ? a.name + (a.values.length > 1 ? "[]" : "") : void 0), _ = h === void 0 ? 0 : G(h, a.min, a.max);
|
|
289
289
|
u.useEffect(() => {
|
|
290
|
-
if (
|
|
291
|
-
a.thumbs.delete(
|
|
290
|
+
if (c) return a.thumbs.add(c), () => {
|
|
291
|
+
a.thumbs.delete(c);
|
|
292
292
|
};
|
|
293
|
-
}, [
|
|
293
|
+
}, [c, a.thumbs]);
|
|
294
294
|
let v = {
|
|
295
295
|
value: h,
|
|
296
296
|
name: g,
|
|
297
297
|
form: a.form,
|
|
298
298
|
isFormControl: m,
|
|
299
299
|
index: d,
|
|
300
|
-
thumb:
|
|
300
|
+
thumb: c,
|
|
301
301
|
onThumbChange: l,
|
|
302
302
|
percent: _,
|
|
303
303
|
size: p
|
|
@@ -309,31 +309,31 @@ function R(e) {
|
|
|
309
309
|
});
|
|
310
310
|
}
|
|
311
311
|
h(R, "SliderThumbProvider");
|
|
312
|
-
var z = "SliderThumbTrigger", B = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e,
|
|
313
|
-
let { __scopeSlider: i, ...
|
|
312
|
+
var z = "SliderThumbTrigger", B = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function(e, t) {
|
|
313
|
+
let { __scopeSlider: i, ...a } = e, o = D(z, i), s = A(z, i), { index: l, value: u, percent: d, size: p, onThumbChange: m } = I(z, i), h = r(t, m), g = K(l, o.values.length), _ = p?.[s.size], v = _ ? J(_, d, s.direction) : 0;
|
|
314
314
|
return /* @__PURE__ */ f("span", {
|
|
315
315
|
style: {
|
|
316
316
|
transform: "var(--radix-slider-thumb-transform)",
|
|
317
317
|
position: "absolute",
|
|
318
|
-
[
|
|
318
|
+
[s.startEdge]: `calc(${d}% + ${v}px)`
|
|
319
319
|
},
|
|
320
320
|
children: /* @__PURE__ */ f(S.ItemSlot, {
|
|
321
321
|
scope: i,
|
|
322
|
-
children: /* @__PURE__ */ f(
|
|
322
|
+
children: /* @__PURE__ */ f(c.span, {
|
|
323
323
|
role: "slider",
|
|
324
324
|
"aria-label": e["aria-label"] || g,
|
|
325
|
-
"aria-valuemin":
|
|
325
|
+
"aria-valuemin": o.min,
|
|
326
326
|
"aria-valuenow": u,
|
|
327
|
-
"aria-valuemax":
|
|
328
|
-
"aria-orientation":
|
|
329
|
-
"data-orientation":
|
|
330
|
-
"data-disabled":
|
|
331
|
-
tabIndex:
|
|
332
|
-
...
|
|
327
|
+
"aria-valuemax": o.max,
|
|
328
|
+
"aria-orientation": o.orientation,
|
|
329
|
+
"data-orientation": o.orientation,
|
|
330
|
+
"data-disabled": o.disabled ? "" : void 0,
|
|
331
|
+
tabIndex: o.disabled ? void 0 : 0,
|
|
332
|
+
...a,
|
|
333
333
|
ref: h,
|
|
334
334
|
style: u === void 0 ? { display: "none" } : e.style,
|
|
335
|
-
onFocus:
|
|
336
|
-
|
|
335
|
+
onFocus: n(e.onFocus, () => {
|
|
336
|
+
o.valueIndexToChangeRef.current = l;
|
|
337
337
|
})
|
|
338
338
|
})
|
|
339
339
|
})
|
|
@@ -349,34 +349,34 @@ var z = "SliderThumbTrigger", B = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h
|
|
|
349
349
|
__scopeSlider: n
|
|
350
350
|
}), r ? /* @__PURE__ */ f(U, { __scopeSlider: n }, e) : null] })
|
|
351
351
|
});
|
|
352
|
-
}, "SliderThumb")), H = "SliderBubbleInput", U = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function({ __scopeSlider: e, onInput:
|
|
353
|
-
let { index:
|
|
352
|
+
}, "SliderThumb")), H = "SliderBubbleInput", U = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ h(function({ __scopeSlider: e, onInput: t, ...i }, a) {
|
|
353
|
+
let { index: o, value: s, name: l, form: d } = I(H, e), { userRequestedValues: p } = D(H, e), m = u.useRef(null), h = r(m, a), g = u.useRef(!1), _ = u.useRef(s), v = u.useRef(p), y = u.useRef(p);
|
|
354
354
|
return u.useEffect(() => {
|
|
355
355
|
let e = m.current;
|
|
356
356
|
if (!e) return;
|
|
357
|
-
let t = window.HTMLInputElement.prototype, n = Object.getOwnPropertyDescriptor(t, "value").set, r = _.current, i = r !==
|
|
358
|
-
_.current =
|
|
357
|
+
let t = window.HTMLInputElement.prototype, n = Object.getOwnPropertyDescriptor(t, "value").set, r = _.current, i = r !== s;
|
|
358
|
+
_.current = s;
|
|
359
359
|
let a = p !== y.current;
|
|
360
360
|
if (y.current = p, i && n) {
|
|
361
361
|
let t = p !== v.current;
|
|
362
362
|
v.current = p;
|
|
363
|
-
let i = p?.[
|
|
364
|
-
g.current = !(t && (a && i !== r || i ===
|
|
365
|
-
let
|
|
366
|
-
n.call(e,
|
|
363
|
+
let i = p?.[o];
|
|
364
|
+
g.current = !(t && (a && i !== r || i === s));
|
|
365
|
+
let c = new Event("input", { bubbles: !0 });
|
|
366
|
+
n.call(e, s), e.dispatchEvent(c), g.current = !1;
|
|
367
367
|
}
|
|
368
368
|
}, [
|
|
369
|
+
o,
|
|
369
370
|
s,
|
|
370
|
-
c,
|
|
371
371
|
p
|
|
372
|
-
]), /* @__PURE__ */ f(
|
|
372
|
+
]), /* @__PURE__ */ f(c.input, {
|
|
373
373
|
style: { display: "none" },
|
|
374
374
|
name: l,
|
|
375
375
|
form: d,
|
|
376
376
|
...i,
|
|
377
377
|
ref: h,
|
|
378
|
-
defaultValue:
|
|
379
|
-
onInput:
|
|
378
|
+
defaultValue: s,
|
|
379
|
+
onInput: n(t, (e) => {
|
|
380
380
|
g.current && e.stopPropagation();
|
|
381
381
|
})
|
|
382
382
|
});
|
|
@@ -386,8 +386,9 @@ function W(e = [], t, n) {
|
|
|
386
386
|
return r[n] = t, r.sort((e, t) => e - t);
|
|
387
387
|
}
|
|
388
388
|
h(W, "getNextSortedValues");
|
|
389
|
-
function G(e,
|
|
390
|
-
|
|
389
|
+
function G(e, n, r) {
|
|
390
|
+
let i = 100 / (r - n) * (e - n);
|
|
391
|
+
return t(i, [0, 100]);
|
|
391
392
|
}
|
|
392
393
|
h(G, "convertValueToPercentage");
|
|
393
394
|
function K(e, t) {
|
|
@@ -451,8 +452,7 @@ function ae(e) {
|
|
|
451
452
|
return typeof e == "function";
|
|
452
453
|
}
|
|
453
454
|
h(ae, "isFunction");
|
|
454
|
-
|
|
455
|
-
//#region src/slider.tsx
|
|
455
|
+
// src/slider.tsx
|
|
456
456
|
function oe({ className: t, defaultValue: n, value: r, min: i = 0, max: a = 100, ...o }) {
|
|
457
457
|
let s = u.useMemo(() => Array.isArray(r) ? r : Array.isArray(n) ? n : [i, a], [
|
|
458
458
|
r,
|
|
@@ -481,5 +481,4 @@ function oe({ className: t, defaultValue: n, value: r, min: i = 0, max: a = 100,
|
|
|
481
481
|
}, t))]
|
|
482
482
|
});
|
|
483
483
|
}
|
|
484
|
-
//#endregion
|
|
485
484
|
export { oe as t };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=require("./rolldown-runtime-DbbDpzbe.js"),t=require("./dist-CoTs6T03.js"),n=require("./dist-DJqkhIXb.js"),r=require("./dist-DZiOPWLp.js"),i=require("./dist-CJqVmdrU.js"),a=require("./dist-DW2ltK5-.js"),o=require("./dist-zmnQp5Xf.js"),s=require("./dist-DdAeWIwf.js"),c=require("./dist-Bal96K8t.js"),l=require("./dist-CBlqVBTk.js"),u=require("./dist-Co_xSt6d.js");let d=require("react"),f=e.r(d,1);d=e.r(d);let p=require("react/jsx-runtime");var m=Object.defineProperty,h=(e,t)=>m(e,`name`,{value:t,configurable:!0}),g={Vertical:`vertical`,Horizontal:`horizontal`},_={LTR:`ltr`,RTL:`rtl`},v=[`PageUp`,`PageDown`],y=[`ArrowUp`,`ArrowDown`,`ArrowLeft`,`ArrowRight`],b={"from-left":[`Home`,`PageDown`,`ArrowDown`,`ArrowLeft`],"from-right":[`Home`,`PageDown`,`ArrowDown`,`ArrowRight`],"from-bottom":[`Home`,`PageDown`,`ArrowDown`,`ArrowLeft`],"from-top":[`Home`,`PageDown`,`ArrowUp`,`ArrowLeft`]},x=`Slider`,[S,C,w]=u.t(x),[T,E]=a.t(x,[w]),[ee,D]=T(x),O=f.forwardRef(h(function(e,t){let{name:a,min:s=0,max:c=100,step:l=1,orientation:u=g.Horizontal,disabled:d=!1,minStepsBetweenThumbs:m=0,preserveThumbOrder:_=!1,defaultValue:b=[s],value:x,onValueChange:C=h(()=>{},`onValueChange`),onValueCommit:w=h(()=>{},`onValueCommit`),inverted:T=!1,form:E,...D}=e,O=f.useRef(new Set),k=f.useRef(0),A=f.useRef(!1),[j,M]=f.useState(null),N=u===g.Horizontal?te:ne,[P,re]=f.useState(null),F=i.a(t,re),[I=[],L]=o.t({prop:x,defaultProp:b,onChange:h(e=>{[...O.current][k.current]?.focus({preventScroll:!0,focusVisible:A.current}),A.current=!1,C(e)},`onChange`)}),R=f.useRef(I),z=f.useRef(I);f.useEffect(()=>{let e=E?P?.ownerDocument.getElementById(E):P?.closest(`form`);if(e instanceof HTMLFormElement){let t=h(()=>L(z.current),`reset`);return e.addEventListener(`reset`,t),()=>e.removeEventListener(`reset`,t)}},[P,E,L]);function B(e){U(e,q(I,e))}h(B,`handleSlideStart`);function V(e){U(e,k.current)}h(V,`handleSlideMove`);function H(){String(I)!==String(R.current)&&w(I)}h(H,`handleSlideEnd`);function U(e,t,{commit:r}={commit:!1}){let i=Q(l),a=$(Math.round((e-s)/l)*l+s,i),o=n.t(a,[s,c]),u=m*l;function d(e){let r=_?n.t(o,[e[t-1]===void 0?s:e[t-1]+u,e[t+1]===void 0?c:e[t+1]-u]):o,i=W(e,r,t);return X(i,u)?{nextValues:i,changedIndex:_?t:i.indexOf(r),hasChanged:String(i)!==String(e)}:null}h(d,`getNextValues`);let f=d(I);f?.hasChanged&&M(f.nextValues),L((e=[])=>{let t=d(e);return t?(k.current=t.changedIndex,t.hasChanged&&r&&w(t.nextValues),t.hasChanged?t.nextValues:e):e})}return h(U,`updateValues`),(0,p.jsx)(ee,{scope:e.__scopeSlider,name:a,disabled:d,min:s,max:c,valueIndexToChangeRef:k,thumbs:O.current,values:I,orientation:u,form:E,userRequestedValues:j,children:(0,p.jsx)(S.Provider,{scope:e.__scopeSlider,children:(0,p.jsx)(S.Slot,{scope:e.__scopeSlider,children:(0,p.jsx)(N,{"aria-disabled":d,"data-disabled":d?``:void 0,...D,ref:F,onPointerDown:r.t(D.onPointerDown,()=>{d||(R.current=I,A.current=!1)}),min:s,max:c,inverted:T,onSlideStart:d?void 0:B,onSlideMove:d?void 0:V,onSlideEnd:d?void 0:H,onHomeKeyDown:()=>{d||(A.current=!0,U(s,0,{commit:!0}))},onEndKeyDown:()=>{d||(A.current=!0,U(c,I.length-1,{commit:!0}))},onStepKeyDown:({event:e,direction:t})=>{if(!d){A.current=!0;let n=v.includes(e.key)||e.shiftKey&&y.includes(e.key)?10:1,r=k.current,i=I[r];U(ie(i,{min:s,step:l,direction:t,multiplier:n}),r,{commit:!0})}}})})})})},`Slider`)),[k,A]=T(x,{startEdge:`left`,endEdge:`right`,size:`width`,direction:1}),te=f.forwardRef(h(function(e,t){let{min:n,max:r,dir:a,inverted:o,onSlideStart:c,onSlideMove:l,onSlideEnd:u,onStepKeyDown:d,...m}=e,[g,v]=f.useState(null),y=i.a(t,v),x=f.useRef(void 0),S=s.n(a),C=S===_.LTR,w=C&&!o||!C&&o;function T(e){let t=x.current||g.getBoundingClientRect(),i=Z([0,t.width],w?[n,r]:[r,n]);return x.current=t,i(e-t.left)}return h(T,`getValueFromPointer`),(0,p.jsx)(k,{scope:e.__scopeSlider,startEdge:w?`left`:`right`,endEdge:w?`right`:`left`,direction:w?1:-1,size:`width`,children:(0,p.jsx)(j,{dir:S,"data-orientation":`horizontal`,...m,ref:y,style:{...m.style,"--radix-slider-thumb-transform":`translateX(-50%)`},onSlideStart:e=>{let t=T(e.clientX);c?.(t)},onSlideMove:e=>{let t=T(e.clientX);l?.(t)},onSlideEnd:()=>{x.current=void 0,u?.()},onStepKeyDown:e=>{let t=b[w?`from-left`:`from-right`].includes(e.key);d?.({event:e,direction:t?-1:1})}})})},`SliderHorizontal`)),ne=f.forwardRef(h(function(e,t){let{min:n,max:r,inverted:a,onSlideStart:o,onSlideMove:s,onSlideEnd:c,onStepKeyDown:l,...u}=e,d=f.useRef(null),m=i.a(t,d),g=f.useRef(void 0),_=!a;function v(e){let t=g.current||d.current.getBoundingClientRect(),i=Z([0,t.height],_?[r,n]:[n,r]);return g.current=t,i(e-t.top)}return h(v,`getValueFromPointer`),(0,p.jsx)(k,{scope:e.__scopeSlider,startEdge:_?`bottom`:`top`,endEdge:_?`top`:`bottom`,size:`height`,direction:_?1:-1,children:(0,p.jsx)(j,{"data-orientation":`vertical`,...u,ref:m,style:{...u.style,"--radix-slider-thumb-transform":`translateY(50%)`},onSlideStart:e=>{let t=v(e.clientY);o?.(t)},onSlideMove:e=>{let t=v(e.clientY);s?.(t)},onSlideEnd:()=>{g.current=void 0,c?.()},onStepKeyDown:e=>{let t=b[_?`from-bottom`:`from-top`].includes(e.key);l?.({event:e,direction:t?-1:1})}})})},`SliderVertical`)),j=f.forwardRef(h(function(e,t){let{__scopeSlider:n,onSlideStart:i,onSlideMove:a,onSlideEnd:o,onHomeKeyDown:s,onEndKeyDown:c,onStepKeyDown:u,...d}=e,f=D(x,n);return(0,p.jsx)(l.t.span,{...d,ref:t,onKeyDown:r.t(e.onKeyDown,e=>{e.key===`Home`?(s(e),e.preventDefault()):e.key===`End`?(c(e),e.preventDefault()):v.concat(y).includes(e.key)&&(u(e),e.preventDefault())}),onPointerDown:r.t(e.onPointerDown,e=>{let t=e.target;t.setPointerCapture(e.pointerId),e.preventDefault(),f.thumbs.has(t)?t.focus({preventScroll:!0,focusVisible:!1}):i(e)}),onPointerMove:r.t(e.onPointerMove,e=>{e.target.hasPointerCapture(e.pointerId)&&a(e)}),onPointerUp:r.t(e.onPointerUp,e=>{let t=e.target;t.hasPointerCapture(e.pointerId)&&(t.releasePointerCapture(e.pointerId),o(e))})})},`SliderImpl`)),M=`SliderTrack`,N=f.forwardRef(h(function(e,t){let{__scopeSlider:n,...r}=e,i=D(M,n);return(0,p.jsx)(l.t.span,{"data-disabled":i.disabled?``:void 0,"data-orientation":i.orientation,...r,ref:t})},`SliderTrack`)),P=`SliderRange`,re=f.forwardRef(h(function(e,t){let{__scopeSlider:n,...r}=e,a=D(P,n),o=A(P,n),s=f.useRef(null),c=i.a(t,s),u=a.values.length,d=a.values.map(e=>G(e,a.min,a.max)),m=u>1?Math.min(...d):0,h=100-Math.max(...d);return(0,p.jsx)(l.t.span,{"data-orientation":a.orientation,"data-disabled":a.disabled?``:void 0,...r,ref:c,style:{...e.style,[o.startEdge]:m+`%`,[o.endEdge]:h+`%`}})},`SliderRange`)),[F,I]=T(`SliderThumb`),L=`SliderThumbProvider`;function R(e){let{__scopeSlider:t,name:n,children:r,internal_do_not_use_render:i}=e,a=D(L,t),o=C(t),[s,l]=f.useState(null),u=f.useMemo(()=>s?o().findIndex(e=>e.ref.current===s):-1,[o,s]),d=c.t(s),m=!s||!!a.form||!!s.closest(`form`),h=a.values[u],g=n??(a.name?a.name+(a.values.length>1?`[]`:``):void 0),_=h===void 0?0:G(h,a.min,a.max);f.useEffect(()=>{if(s)return a.thumbs.add(s),()=>{a.thumbs.delete(s)}},[s,a.thumbs]);let v={value:h,name:g,form:a.form,isFormControl:m,index:u,thumb:s,onThumbChange:l,percent:_,size:d};return(0,p.jsx)(F,{scope:t,...v,children:ae(i)?i(v):r})}h(R,`SliderThumbProvider`);var z=`SliderThumbTrigger`,B=f.forwardRef(h(function(e,t){let{__scopeSlider:n,...a}=e,o=D(z,n),s=A(z,n),{index:c,value:u,percent:d,size:f,onThumbChange:m}=I(z,n),h=i.a(t,m),g=K(c,o.values.length),_=f?.[s.size],v=_?J(_,d,s.direction):0;return(0,p.jsx)(`span`,{style:{transform:`var(--radix-slider-thumb-transform)`,position:`absolute`,[s.startEdge]:`calc(${d}% + ${v}px)`},children:(0,p.jsx)(S.ItemSlot,{scope:n,children:(0,p.jsx)(l.t.span,{role:`slider`,"aria-label":e[`aria-label`]||g,"aria-valuemin":o.min,"aria-valuenow":u,"aria-valuemax":o.max,"aria-orientation":o.orientation,"data-orientation":o.orientation,"data-disabled":o.disabled?``:void 0,tabIndex:o.disabled?void 0:0,...a,ref:h,style:u===void 0?{display:`none`}:e.style,onFocus:r.t(e.onFocus,()=>{o.valueIndexToChangeRef.current=c})})})})},`SliderThumbTrigger`)),V=f.forwardRef(h(function(e,t){let{__scopeSlider:n,name:r,...i}=e;return(0,p.jsx)(R,{__scopeSlider:n,name:r,internal_do_not_use_render:({index:e,isFormControl:r})=>(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(B,{...i,ref:t,__scopeSlider:n}),r?(0,p.jsx)(U,{__scopeSlider:n},e):null]})})},`SliderThumb`)),H=`SliderBubbleInput`,U=f.forwardRef(h(function({__scopeSlider:e,onInput:t,...n},a){let{index:o,value:s,name:c,form:u}=I(H,e),{userRequestedValues:d}=D(H,e),m=f.useRef(null),h=i.a(m,a),g=f.useRef(!1),_=f.useRef(s),v=f.useRef(d),y=f.useRef(d);return f.useEffect(()=>{let e=m.current;if(!e)return;let t=window.HTMLInputElement.prototype,n=Object.getOwnPropertyDescriptor(t,`value`).set,r=_.current,i=r!==s;_.current=s;let a=d!==y.current;if(y.current=d,i&&n){let t=d!==v.current;v.current=d;let i=d?.[o];g.current=!(t&&(a&&i!==r||i===s));let c=new Event(`input`,{bubbles:!0});n.call(e,s),e.dispatchEvent(c),g.current=!1}},[o,s,d]),(0,p.jsx)(l.t.input,{style:{display:`none`},name:c,form:u,...n,ref:h,defaultValue:s,onInput:r.t(t,e=>{g.current&&e.stopPropagation()})})},`SliderBubbleInput`));function W(e=[],t,n){let r=[...e];return r[n]=t,r.sort((e,t)=>e-t)}h(W,`getNextSortedValues`);function G(e,t,r){let i=100/(r-t)*(e-t);return n.t(i,[0,100])}h(G,`convertValueToPercentage`);function K(e,t){if(t>2)return`Value ${e+1} of ${t}`;if(t===2)return[`Minimum`,`Maximum`][e]}h(K,`getLabel`);function q(e,t){if(e.length===1)return 0;let n=e.map(e=>Math.abs(e-t)),r=Math.min(...n);return n.indexOf(r)}h(q,`getClosestValueIndex`);function J(e,t,n){let r=e/2;return(r-Z([0,50],[0,r])(t)*n)*n}h(J,`getThumbInBoundsOffset`);function Y(e){return e.slice(0,-1).map((t,n)=>e[n+1]-t)}h(Y,`getStepsBetweenValues`);function X(e,t){if(t>0){let n=Y(e);return Math.min(...n)>=t}return!0}h(X,`hasMinStepsBetweenValues`);function Z(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];let r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}h(Z,`linearScale`);function Q(e){if(!Number.isFinite(e))return 0;let t=e.toString();if(t.includes(`e`)){let[e,n]=t.split(`e`),r=e.split(`.`)[1]||``,i=Number(n);return Math.max(0,r.length-i)}let n=t.split(`.`)[1];return n?n.length:0}h(Q,`getDecimalCount`);function $(e,t){let n=10**t;return Math.round(e*n)/n}h($,`roundValue`);function ie(e,{min:t,step:n,direction:r,multiplier:i}){let a=Q(n),o=(e-t)/n,s=Math.round(o),c=$(s*n+t,a)===$(e,a),l;return l=c?s+i*r:r>0?Math.ceil(o):Math.floor(o),$(l*n+t,a)}h(ie,`getNextStepValue`);function ae(e){return typeof e==`function`}h(ae,`isFunction`);function oe({className:e,defaultValue:n,value:r,min:i=0,max:a=100,...o}){let s=d.useMemo(()=>Array.isArray(r)?r:Array.isArray(n)?n:[i,a],[r,n,i,a]);return(0,p.jsxs)(O,{"data-slot":`slider`,defaultValue:n,value:r,min:i,max:a,className:t.t(`relative flex w-full touch-none items-center select-none data-disabled:opacity-50 data-vertical:h-full data-vertical:min-h-40 data-vertical:w-auto data-vertical:flex-col`,e),...o,children:[(0,p.jsx)(N,{"data-slot":`slider-track`,className:`bg-muted relative grow overflow-hidden rounded-full data-horizontal:h-1 data-horizontal:w-full data-vertical:h-full data-vertical:w-1`,children:(0,p.jsx)(re,{"data-slot":`slider-range`,className:`bg-primary absolute select-none data-horizontal:h-full data-vertical:w-full`})}),Array.from({length:s.length},(e,t)=>(0,p.jsx)(V,{"data-slot":`slider-thumb`,className:`border-ring ring-ring/50 relative block size-3 shrink-0 rounded-full border bg-white transition-[color,box-shadow] select-none after:absolute after:-inset-2 hover:ring-3 focus-visible:ring-3 focus-visible:outline-hidden active:ring-3 disabled:pointer-events-none disabled:opacity-50`},t))]})}Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return oe}});
|
package/dist/slider.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./slider-
|
|
1
|
+
"use client";"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./slider-wZuXwuib.js");exports.Slider=e.t;
|
package/dist/slider.mjs
CHANGED
package/dist/sonner.mjs
CHANGED
|
@@ -3,7 +3,7 @@ import { CircleCheckIcon as e, InfoIcon as t, Loader2Icon as n, OctagonXIcon as
|
|
|
3
3
|
import { jsx as a } from "react/jsx-runtime";
|
|
4
4
|
import { useTheme as o } from "next-themes";
|
|
5
5
|
import { Toaster as s } from "sonner";
|
|
6
|
-
|
|
6
|
+
// src/sonner.tsx
|
|
7
7
|
var c = ({ ...c }) => {
|
|
8
8
|
let { theme: l = "system" } = o();
|
|
9
9
|
return /* @__PURE__ */ a(s, {
|
|
@@ -26,5 +26,4 @@ var c = ({ ...c }) => {
|
|
|
26
26
|
...c
|
|
27
27
|
});
|
|
28
28
|
};
|
|
29
|
-
//#endregion
|
|
30
29
|
export { c as Toaster };
|
package/dist/spinner.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./
|
|
1
|
+
"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./rolldown-runtime-DbbDpzbe.js"),t=require("./dist-CoTs6T03.js");let n=require("lucide-react"),r=require("react");r=e.r(r);let i=require("react/jsx-runtime");function a({className:e,...r}){return(0,i.jsx)(`output`,{"data-slot":`spinner`,"aria-label":`Loading`,className:t.t(`inline-flex size-4 animate-spin`,e),...r,children:(0,i.jsx)(n.Loader2Icon,{"aria-hidden":`true`,className:`size-full`})})}exports.Spinner=a;
|
package/dist/spinner.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { t as e } from "./dist-
|
|
2
|
+
import { t as e } from "./dist-DoWtzxYc.mjs";
|
|
3
3
|
import { Loader2Icon as t } from "lucide-react";
|
|
4
4
|
import "react";
|
|
5
5
|
import { jsx as n } from "react/jsx-runtime";
|
|
6
|
-
|
|
6
|
+
// src/spinner.tsx
|
|
7
7
|
function r({ className: r, ...i }) {
|
|
8
8
|
return /* @__PURE__ */ n("output", {
|
|
9
9
|
"data-slot": "spinner",
|
|
@@ -16,5 +16,4 @@ function r({ className: r, ...i }) {
|
|
|
16
16
|
})
|
|
17
17
|
});
|
|
18
18
|
}
|
|
19
|
-
//#endregion
|
|
20
19
|
export { r as Spinner };
|
package/dist/support-fab.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./
|
|
1
|
+
"use client";"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./rolldown-runtime-DbbDpzbe.js"),t=require("./button.cjs"),n=require("./dialog.cjs"),r=require("./drawer.cjs"),i=require("./utils-ChMUqofy.js");let a=require("lucide-react"),o=require("react");o=e.r(o);let s=require("react/jsx-runtime");var c=`(max-width: 767px)`,l=`https://www.buymeacoffee.com`,u=new Set([`buymeacoffee.com`,`www.buymeacoffee.com`]),d=e=>{let t=e.trim();try{let n=new URL(t),r=n.hostname.toLowerCase();return n.protocol!==`https:`||!u.has(r)?(console.warn(`Invalid supportUrl: ${e}. Falling back to default.`),l):t}catch{return console.warn(`Invalid supportUrl: ${e}. Falling back to default.`),l}},f=e=>{let t=d(e);return t.endsWith(`/`)?t.slice(0,-1):t},p=e=>e.trim().replace(/^@+/,``),m=(e,t)=>`${f(e)}/${encodeURIComponent(p(t))}`,h=(e,t)=>`${f(e)}/widget/page/${encodeURIComponent(p(t))}`,g=()=>{let[e,t]=o.useState(()=>typeof window>`u`||typeof window.matchMedia!=`function`?!1:window.matchMedia(c).matches);return o.useEffect(()=>{if(typeof window>`u`||typeof window.matchMedia!=`function`)return;let e=window.matchMedia(c),n=e=>t(e.matches);return t(e.matches),e.addEventListener(`change`,n),()=>{e.removeEventListener(`change`,n)}},[]),e};function _({supportUrl:e=l,creatorId:c,title:u=`Buy me a coffee`,description:d=`Support the project directly from this panel.`,iframeTitle:f=`Buy Me a Coffee support form`,open:p,defaultOpen:_=!1,onOpenChange:v,positionClassName:y,buttonClassName:b,panelClassName:x,className:S,type:C,onClick:w,...T}){let E=g(),D=p!==void 0,[O,k]=o.useState(_),A=D?p:O,j=o.useCallback(e=>{D||k(e),v?.(e)},[D,v]),M=o.useMemo(()=>m(e,c),[c,e]),N=o.useMemo(()=>h(e,c),[c,e]),P=(0,s.jsxs)(`div`,{className:`flex max-h-[75vh] flex-col gap-3`,children:[(0,s.jsx)(`div`,{className:`overflow-hidden rounded-md border`,children:(0,s.jsx)(`iframe`,{title:f,src:N,className:`h-[560px] w-full border-0`,loading:`lazy`,referrerPolicy:`strict-origin-when-cross-origin`})}),(0,s.jsxs)(`div`,{className:`text-muted-foreground flex items-center justify-between gap-2 text-xs`,children:[(0,s.jsx)(`span`,{children:`If the embedded checkout is unavailable, open the support page directly.`}),(0,s.jsxs)(`a`,{href:M,target:`_blank`,rel:`noopener noreferrer`,className:`text-foreground inline-flex items-center gap-1 font-medium underline underline-offset-2`,children:[`Open Buy Me a Coffee`,(0,s.jsx)(a.ExternalLink,{className:`h-3.5 w-3.5`})]})]})]}),F=(0,s.jsx)(`div`,{className:i.t(`fixed right-6 bottom-6 z-50`,y),children:(0,s.jsxs)(t.Button,{"aria-label":`Support this project`,type:C??`button`,className:i.t(`inline-flex h-14 w-14 items-center justify-center rounded-full border border-black/15 bg-[#ffdd00] text-black shadow-[0_16px_36px_-18px_rgba(0,0,0,0.8)] transition hover:-translate-y-0.5 hover:scale-105 hover:bg-[#ffe347] focus-visible:ring-2 focus-visible:ring-offset-2 active:translate-y-0 active:scale-95`,b,S),onClick:e=>{w?.(e),e.defaultPrevented||j(!0)},...T,children:[(0,s.jsx)(a.Coffee,{className:`h-6 w-6`}),(0,s.jsx)(`span`,{className:`sr-only`,children:`Support this project`})]})});return E?(0,s.jsxs)(s.Fragment,{children:[F,(0,s.jsx)(r.Drawer,{open:A,onOpenChange:j,children:(0,s.jsxs)(r.DrawerContent,{className:i.t(`mx-auto w-full max-w-xl`,x),children:[(0,s.jsxs)(r.DrawerHeader,{children:[(0,s.jsx)(r.DrawerTitle,{children:u}),(0,s.jsx)(r.DrawerDescription,{children:d})]}),(0,s.jsx)(`div`,{className:`px-4 pb-4`,children:P})]})})]}):(0,s.jsxs)(s.Fragment,{children:[F,(0,s.jsx)(n.Dialog,{open:A,onOpenChange:j,children:(0,s.jsxs)(n.DialogContent,{className:i.t(`max-w-xl p-5`,x),children:[(0,s.jsxs)(n.DialogHeader,{children:[(0,s.jsx)(n.DialogTitle,{children:u}),(0,s.jsx)(n.DialogDescription,{children:d})]}),P]})})]})}exports.SupportFab=_;
|
package/dist/support-fab.mjs
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
"use client";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
3
|
+
import { Button as e } from "./button.mjs";
|
|
4
|
+
import { Dialog as t, DialogContent as n, DialogDescription as r, DialogHeader as i, DialogTitle as a } from "./dialog.mjs";
|
|
5
|
+
import { Drawer as o, DrawerContent as s, DrawerDescription as c, DrawerHeader as l, DrawerTitle as u } from "./drawer.mjs";
|
|
6
|
+
import { t as d } from "./utils-DQKc9joa.mjs";
|
|
7
7
|
import { Coffee as f, ExternalLink as p } from "lucide-react";
|
|
8
8
|
import * as m from "react";
|
|
9
9
|
import { Fragment as h, jsx as g, jsxs as _ } from "react/jsx-runtime";
|
|
10
|
-
|
|
11
|
-
var v = "(max-width: 767px)", y = "https://www.buymeacoffee.com", b = new Set(["buymeacoffee.com", "www.buymeacoffee.com"]), x = (e) => {
|
|
10
|
+
// src/support-fab.tsx
|
|
11
|
+
var v = "(max-width: 767px)", y = "https://www.buymeacoffee.com", b = /* @__PURE__ */ new Set(["buymeacoffee.com", "www.buymeacoffee.com"]), x = (e) => {
|
|
12
12
|
let t = e.trim();
|
|
13
13
|
try {
|
|
14
14
|
let n = new URL(t), r = n.hostname.toLowerCase();
|
|
@@ -32,13 +32,13 @@ var v = "(max-width: 767px)", y = "https://www.buymeacoffee.com", b = new Set(["
|
|
|
32
32
|
function D({ supportUrl: v = y, creatorId: b, title: x = "Buy me a coffee", description: S = "Support the project directly from this panel.", iframeTitle: C = "Buy Me a Coffee support form", open: D, defaultOpen: O = !1, onOpenChange: k, positionClassName: A, buttonClassName: j, panelClassName: M, className: N, type: P, onClick: F, ...I }) {
|
|
33
33
|
let L = E(), R = D !== void 0, [z, B] = m.useState(O), V = R ? D : z, H = m.useCallback((e) => {
|
|
34
34
|
R || B(e), k?.(e);
|
|
35
|
-
}, [R, k]), U = m.useMemo(() => w(v, b), [b, v]), W = /* @__PURE__ */ _("div", {
|
|
35
|
+
}, [R, k]), U = m.useMemo(() => w(v, b), [b, v]), W = m.useMemo(() => T(v, b), [b, v]), G = /* @__PURE__ */ _("div", {
|
|
36
36
|
className: "flex max-h-[75vh] flex-col gap-3",
|
|
37
37
|
children: [/* @__PURE__ */ g("div", {
|
|
38
38
|
className: "overflow-hidden rounded-md border",
|
|
39
39
|
children: /* @__PURE__ */ g("iframe", {
|
|
40
40
|
title: C,
|
|
41
|
-
src:
|
|
41
|
+
src: W,
|
|
42
42
|
className: "h-[560px] w-full border-0",
|
|
43
43
|
loading: "lazy",
|
|
44
44
|
referrerPolicy: "strict-origin-when-cross-origin"
|
|
@@ -53,12 +53,12 @@ function D({ supportUrl: v = y, creatorId: b, title: x = "Buy me a coffee", desc
|
|
|
53
53
|
children: ["Open Buy Me a Coffee", /* @__PURE__ */ g(p, { className: "h-3.5 w-3.5" })]
|
|
54
54
|
})]
|
|
55
55
|
})]
|
|
56
|
-
}),
|
|
57
|
-
className:
|
|
58
|
-
children: /* @__PURE__ */ _(
|
|
56
|
+
}), K = /* @__PURE__ */ g("div", {
|
|
57
|
+
className: d("fixed right-6 bottom-6 z-50", A),
|
|
58
|
+
children: /* @__PURE__ */ _(e, {
|
|
59
59
|
"aria-label": "Support this project",
|
|
60
60
|
type: P ?? "button",
|
|
61
|
-
className:
|
|
61
|
+
className: d("inline-flex h-14 w-14 items-center justify-center rounded-full border border-black/15 bg-[#ffdd00] text-black shadow-[0_16px_36px_-18px_rgba(0,0,0,0.8)] transition hover:-translate-y-0.5 hover:scale-105 hover:bg-[#ffe347] focus-visible:ring-2 focus-visible:ring-offset-2 active:translate-y-0 active:scale-95", j, N),
|
|
62
62
|
onClick: (e) => {
|
|
63
63
|
F?.(e), e.defaultPrevented || H(!0);
|
|
64
64
|
},
|
|
@@ -69,24 +69,23 @@ function D({ supportUrl: v = y, creatorId: b, title: x = "Buy me a coffee", desc
|
|
|
69
69
|
})]
|
|
70
70
|
})
|
|
71
71
|
});
|
|
72
|
-
return L ? /* @__PURE__ */ _(h, { children: [
|
|
72
|
+
return L ? /* @__PURE__ */ _(h, { children: [K, /* @__PURE__ */ g(o, {
|
|
73
73
|
open: V,
|
|
74
74
|
onOpenChange: H,
|
|
75
|
-
children: /* @__PURE__ */ _(
|
|
76
|
-
className:
|
|
77
|
-
children: [/* @__PURE__ */ _(
|
|
75
|
+
children: /* @__PURE__ */ _(s, {
|
|
76
|
+
className: d("mx-auto w-full max-w-xl", M),
|
|
77
|
+
children: [/* @__PURE__ */ _(l, { children: [/* @__PURE__ */ g(u, { children: x }), /* @__PURE__ */ g(c, { children: S })] }), /* @__PURE__ */ g("div", {
|
|
78
78
|
className: "px-4 pb-4",
|
|
79
|
-
children:
|
|
79
|
+
children: G
|
|
80
80
|
})]
|
|
81
81
|
})
|
|
82
|
-
})] }) : /* @__PURE__ */ _(h, { children: [
|
|
82
|
+
})] }) : /* @__PURE__ */ _(h, { children: [K, /* @__PURE__ */ g(t, {
|
|
83
83
|
open: V,
|
|
84
84
|
onOpenChange: H,
|
|
85
|
-
children: /* @__PURE__ */ _(
|
|
86
|
-
className:
|
|
87
|
-
children: [/* @__PURE__ */ _(
|
|
85
|
+
children: /* @__PURE__ */ _(n, {
|
|
86
|
+
className: d("max-w-xl p-5", M),
|
|
87
|
+
children: [/* @__PURE__ */ _(i, { children: [/* @__PURE__ */ g(a, { children: x }), /* @__PURE__ */ g(r, { children: S })] }), G]
|
|
88
88
|
})
|
|
89
89
|
})] });
|
|
90
90
|
}
|
|
91
|
-
//#endregion
|
|
92
91
|
export { D as SupportFab };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=require("./rolldown-runtime-DbbDpzbe.js"),t=require("./dist-CoTs6T03.js"),n=require("./dist-DZiOPWLp.js"),r=require("./dist-CJqVmdrU.js"),i=require("./dist-DW2ltK5-.js"),a=require("./dist-zmnQp5Xf.js"),o=require("./dist-Bal96K8t.js"),s=require("./dist-CBlqVBTk.js");let c=require("react"),l=e.r(c,1);c=e.r(c);let u=require("react/jsx-runtime");var d=Object.defineProperty,f=(e,t)=>d(e,`name`,{value:t,configurable:!0}),p=`Switch`,[m,h]=i.t(p),[g,_]=m(p);function v(e){let{__scopeSwitch:t,checked:n,children:r,defaultChecked:i,disabled:o,form:s,name:c,onCheckedChange:d,required:f,value:m=`on`,internal_do_not_use_render:h}=e,[_,v]=a.t({prop:n,defaultProp:i??!1,onChange:d,caller:p}),[y,b]=l.useState(null),[x,S]=l.useState(null),[C,w]=l.useState(null),T={checked:_,setChecked:v,disabled:o,control:y,setControl:b,name:c,form:s,value:m,userClick:C,onUserClick:w,required:f,defaultChecked:i,isFormControl:!y||!!s||!!y.closest(`form`),bubbleInput:x,setBubbleInput:S};return(0,u.jsx)(g,{scope:t,...T,children:E(h)?h(T):r})}f(v,`SwitchProvider`);var y=`SwitchTrigger`,b=l.forwardRef(f(function({__scopeSwitch:e,onClick:t,...i},a){let{control:o,form:c,value:d,disabled:p,checked:m,required:h,setControl:g,setChecked:v,onUserClick:b,isFormControl:x,bubbleInput:S}=_(y,e),C=r.a(a,g),w=l.useRef(m);return l.useEffect(()=>{let e=c?o?.ownerDocument.getElementById(c):o?.form;if(e instanceof HTMLFormElement){let t=f(()=>v(w.current),`reset`);return e.addEventListener(`reset`,t),()=>e.removeEventListener(`reset`,t)}},[o,c,v]),(0,u.jsx)(s.t.button,{type:`button`,role:`switch`,"aria-checked":m,"aria-required":h,"data-state":D(m),"data-disabled":p?``:void 0,disabled:p,value:d,...i,ref:C,onClick:n.t(t,e=>{let t=e.isPropagationStopped();b({requestedChecked:!m,hasConsumerStoppedPropagation:t}),v(e=>!e),S&&x&&(t||e.stopPropagation())})})},`SwitchTrigger`)),x=l.forwardRef(f(function(e,t){let{__scopeSwitch:n,name:r,checked:i,defaultChecked:a,required:o,disabled:s,value:c,onCheckedChange:l,form:d,...f}=e;return(0,u.jsx)(v,{__scopeSwitch:n,checked:i,defaultChecked:a,disabled:s,required:o,onCheckedChange:l,name:r,form:d,value:c,internal_do_not_use_render:({isFormControl:e})=>(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(b,{...f,ref:t,__scopeSwitch:n}),e&&(0,u.jsx)(T,{__scopeSwitch:n})]})})},`Switch`)),S=`SwitchThumb`,C=l.forwardRef(f(function(e,t){let{__scopeSwitch:n,...r}=e,i=_(S,n);return(0,u.jsx)(s.t.span,{"data-state":D(i.checked),"data-disabled":i.disabled?``:void 0,...r,ref:t})},`SwitchThumb`)),w=`SwitchBubbleInput`,T=l.forwardRef(f(function({__scopeSwitch:e,onClick:t,...i},a){let{control:c,userClick:d,checked:f,defaultChecked:p,required:m,disabled:h,name:g,value:v,form:y,bubbleInput:b,setBubbleInput:x}=_(w,e),S=r.a(a,x),C=o.t(c),T=l.useRef(!1),E=l.useRef(f),D=l.useRef(d),O=l.useRef(null);l.useEffect(()=>{let e=b;if(!e)return;let t=window.HTMLInputElement.prototype,n=Object.getOwnPropertyDescriptor(t,`checked`).set;if(!n)return;let r=E.current!==f;E.current=f;let i=d!==null&&d!==D.current;if(D.current=d,i)O.current=r?null:d,r&&n.call(e,f),e.dispatchEvent(new Event(`click`,{bubbles:!d.hasConsumerStoppedPropagation}));else if(r){let t=O.current;O.current=null;let r=t?.requestedChecked===f;T.current=!0,n.call(e,f),e.dispatchEvent(new Event(`click`,{bubbles:!(r&&t.hasConsumerStoppedPropagation)})),T.current=!1}},[b,f,d]);let k=l.useRef(f);return(0,u.jsx)(s.t.input,{type:`checkbox`,"aria-hidden":!0,defaultChecked:p??k.current,required:m,disabled:h,name:g,value:v,form:y,...i,tabIndex:-1,ref:S,onClick:n.t(t,e=>{T.current&&e.stopPropagation()}),style:{...i.style,...C,position:`absolute`,pointerEvents:`none`,opacity:0,margin:0,transform:`translateX(-100%)`}})},`SwitchBubbleInput`));function E(e){return typeof e==`function`}f(E,`isFunction`);function D(e){return e?`checked`:`unchecked`}f(D,`getState`);function O({className:e,size:n=`default`,...r}){return(0,u.jsx)(x,{"data-slot":`switch`,"data-size":n,className:t.t(`peer group/switch focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:bg-primary data-unchecked:bg-input dark:data-unchecked:bg-input/80 relative inline-flex shrink-0 items-center rounded-full border border-transparent transition-all outline-none group-has-[:focus-visible]/field-label:border-transparent group-has-[:focus-visible]/field-label:ring-0 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:ring-3 aria-invalid:ring-3 data-disabled:cursor-not-allowed data-disabled:opacity-50 data-[size=default]:h-[18.4px] data-[size=default]:w-[32px] data-[size=sm]:h-[14px] data-[size=sm]:w-[24px]`,e),...r,children:(0,u.jsx)(C,{"data-slot":`switch-thumb`,className:`bg-background dark:data-checked:bg-primary-foreground dark:data-unchecked:bg-foreground pointer-events-none block rounded-full ring-0 transition-transform group-data-[size=default]/switch:size-4 group-data-[size=sm]/switch:size-3 group-data-[size=default]/switch:data-checked:translate-x-[calc(100%-2px)] group-data-[size=sm]/switch:data-checked:translate-x-[calc(100%-2px)] group-data-[size=default]/switch:data-unchecked:translate-x-0 group-data-[size=sm]/switch:data-unchecked:translate-x-0 rtl:group-data-[size=default]/switch:data-checked:-translate-x-[calc(100%-2px)] rtl:group-data-[size=sm]/switch:data-checked:-translate-x-[calc(100%-2px)] rtl:group-data-[size=default]/switch:data-unchecked:-translate-x-0 rtl:group-data-[size=sm]/switch:data-unchecked:-translate-x-0`})})}Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return O}});
|